Examples of ImageSelectionDialog


Examples of com.google.gdt.eclipse.designer.util.ui.ImageSelectionDialog

  //
  ////////////////////////////////////////////////////////////////////////////
  @Override
  protected void openDialog(Property property) throws Exception {
    GwtState state = getGWTState(property);
    ImageSelectionDialog dialog =
        new ImageSelectionDialog(getParentShell(),
            state.getResourcesProvider(),
            state.getModuleDescription(),
            property.getTitle());
    if (dialog.open() == Window.OK) {
      String resourcePath = dialog.getSelectedResourcePath();
      property.setValue(resourcePath);
    }
  }
View Full Code Here

Examples of org.dyno.visual.swing.base.ImageSelectionDialog

        openDialog(shell);
      }
    });
  }
  private void openDialog(Shell shell){
    ImageSelectionDialog isd = new ImageSelectionDialog(shell);
    if (isd.open() == Window.OK) {
      IFile file = isd.getImageFile();
      IPath location = file.getFullPath();
      location = location.removeFirstSegments(2);
      String path = location.toString();
      if (!path.startsWith("/"))
        path += "/" + path;
View Full Code Here

Examples of org.dyno.visual.swing.base.ImageSelectionDialog

  }

  private Image lblImage;

  private void selectIcon() {
    ImageSelectionDialog isd = new ImageSelectionDialog(getShell());
    if (imgFile != null)
      isd.setImageFile(imgFile);
    int ret = isd.open();
    if (ret == Window.OK) {
      IFile file = isd.getImageFile();
      setIcon(file);
      setImageFile(file);
    }
  }
View Full Code Here

Examples of org.dyno.visual.swing.base.ImageSelectionDialog

    return null;
  }

  protected Object openDialogBox(Control cellEditorWindow) {
    try {
      ImageSelectionDialog isd = new ImageSelectionDialog(
          cellEditorWindow.getShell());
      String text = iconText.getText();
      if (text != null && text.trim().length() > 0) {
        IJavaProject javaProject = VisualSwingPlugin.getCurrentProject();
        if (javaProject != null) {
          IPackageFragmentRoot src_root = getSourceRoot(javaProject);
          if (src_root != null) {
            String srcName = src_root.getElementName();
            IProject prj = javaProject.getProject();
            IFile file = prj.getFolder(srcName).getFile(text);
            if (file != null && file.exists())
              isd.setImageFile(file);
          }
        }
      }
      int ret = isd.open();
      if (ret == Window.OK) {
        IFile file = isd.getImageFile();
        if (file == null) {
          return "";
        } else {
          IPath location = file.getFullPath();
          location = location.removeFirstSegments(2);
View Full Code Here
TOP
Copyright © 2018 www.massapi.com. All rights reserved.
All source code are property of their respective owners. Java is a trademark of Sun Microsystems, Inc and owned by ORACLE Inc. Contact coftware#gmail.com.