Package org.eclipse.swt.widgets

Examples of org.eclipse.swt.widgets.Composite.dispose()


   * Images, Colors and such SWT handles must be disposed by the class itself.
   */
  public void delete(){
    Composite comp = getComposite();
    if (comp != null && !comp.isDisposed())
      comp.dispose();
  }

  public String getData(){ return null; }

  /**
 
View Full Code Here


            /* Check if there are any other buttons on the button bar.
             * If not, throw away the button bar composite.  Otherwise
             * there is an unusually large button bar.
             */
            if (buttonBar.getChildren().length < 1) {
        buttonBar.dispose();
      }
        }
    }

 
View Full Code Here

        content.setLayout(new FillLayout());
       
        try {
      part.createPartControl(content);
    } catch (Exception e) {
      content.dispose();
      StatusManager.getManager().handle(
          StatusUtil.newStatus(WorkbenchPlugin.PI_WORKBENCH, e));
      return null;
    }
View Full Code Here

            content.setLayout(new FillLayout());
           
            try {
        part.createPartControl(content);
      } catch (Exception e) {
        content.dispose();
        StatusUtil.handleStatus(e, StatusManager.SHOW
            | StatusManager.LOG);
        return null;
      }
View Full Code Here

                // or something.
            } catch (Throwable t) {

                t.printStackTrace();
                // TODO log exception
                page.dispose();
                site.dispose();
                sites.remove(this);
            }
        }
View Full Code Here

        for (Iterator iter = tabs.iterator(); iter.hasNext();) {
            IFeaturePanel tab = (IFeaturePanel) iter.next();
            Composite composite = (Composite) tabToComposite.remove(tab);
            tab.dispose();
            if (composite != null) {
                composite.dispose();
            }
        }
    }

    /**
 
View Full Code Here

      editor.grabHorizontal = false;editor.horizontalAlignment = SWT.RIGHT;
      final TreeEditor _editor = editor;
      item.addListener(SWT.Dispose, new Listener() {
        public void handleEvent(Event event) {
          if (!c.isDisposed()) {
            c.dispose();
          }
          if (_editor.getEditor() == null)
            System.out.println("TreeEditor already disposed ?!");
          else
            _editor.dispose();
View Full Code Here

              public void run() {
                try {
                  location = AbstractHadoopCluster.createCluster(selection);
                  location.setConfPropValue(ConfProp.PI_HADOOP_VERSION, selection);
                  location.setConfPropValue(ConfProp.PI_LOCATION_NAME, locationName.getText());
                  panel.dispose();
                  createControl(parent);
                  parent.pack();
                  parent.getParent().layout(true);
                } catch (CoreException e) {
                  MessageDialog.openError(Display.getDefault().getActiveShell(), "HDFS Error", "Unable to create HDFS site :"
View Full Code Here

  }
 
  public void removeAll(){   
    while(bar.getItemCount() > 0){
      Composite composite = (Composite)bar.getItem(0).getControl();     
      if(composite != null ) composite.dispose();
      bar.getItem(0).dispose();
    }  
    bar.layout();
  }
 
View Full Code Here

            Composite temp = customRobotStatus;
            RobotGUI robotGUI = (RobotGUI)plugin.makeGUInstance(roboTemp);
            customRobotStatus =  robotGUI.getStatusPannel( robotStatus, robotStatus.getStyle());
           
            if ( temp != null  &&  !temp.isDisposed() )
              temp.dispose();
           
            if (customRobotStatus != null)
            {
              GridData customRobotStatusLData = new GridData();
              customRobotStatusLData.horizontalAlignment = GridData.FILL;
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.