org.eclipse.swt.widgets.Table.getShell()方法的使用及代码示例

x33g5p2x  于2022-01-29 转载在 其他  
字(6.7k)|赞(0)|评价(0)|浏览(218)

本文整理了Java中org.eclipse.swt.widgets.Table.getShell()方法的一些代码示例,展示了Table.getShell()的具体用法。这些代码示例主要来源于Github/Stackoverflow/Maven等平台,是从一些精选项目中提取出来的代码,具有较强的参考意义,能在一定程度帮忙到你。Table.getShell()方法的具体详情如下:
包路径:org.eclipse.swt.widgets.Table
类名称:Table
方法名:getShell

Table.getShell介绍

暂无

代码示例

代码示例来源:origin: pentaho/pentaho-kettle

  1. Shell shell = ( (TableViewer) tableView.getManagedObject() ).getTable().getShell();
  2. MessageDialog md =
  3. new MessageDialog( shell,

代码示例来源:origin: pentaho/pentaho-kettle

  1. Shell shell = ( (TableViewer) tableView.getManagedObject() ).getTable().getShell();
  2. MessageDialog md =
  3. new MessageDialog( shell,

代码示例来源:origin: cbeust/testng-eclipse

  1. public Shell getShell() {
  2. return fTable.getShell();
  3. }

代码示例来源:origin: org.apache.uima/uimaj-ep-pear-packager

  1. /**
  2. * Close.
  3. */
  4. /*
  5. * Close the window and dispose of resources
  6. */
  7. public void close() {
  8. Shell shell = table.getShell();
  9. if (shell != null && !shell.isDisposed())
  10. shell.dispose();
  11. }

代码示例来源:origin: org.eclipse/org.eclipse.ajdt.ui

  1. private int computeScrollBarWidth() {
  2. Composite t= new Composite(fTable.getShell(), SWT.V_SCROLL);
  3. int result= t.computeTrim(0, 0, 0, 0).width;
  4. t.dispose();
  5. return result;
  6. }

代码示例来源:origin: org.eclipse.jdt/org.eclipse.jdt.ui

  1. private int computeScrollBarWidth() {
  2. Composite t= new Composite(fTable.getShell(), SWT.V_SCROLL);
  3. int result= t.computeTrim(0, 0, 0, 0).width;
  4. t.dispose();
  5. return result;
  6. }

代码示例来源:origin: org.eclipse/org.eclipse.jdt.ui

  1. private int computeScrollBarWidth() {
  2. Composite t= new Composite(fTable.getShell(), SWT.V_SCROLL);
  3. int result= t.computeTrim(0, 0, 0, 0).width;
  4. t.dispose();
  5. return result;
  6. }

代码示例来源:origin: org.eclipse.scout.sdk.deps/org.eclipse.jdt.ui

  1. private int computeScrollBarWidth() {
  2. Composite t= new Composite(fTable.getShell(), SWT.V_SCROLL);
  3. int result= t.computeTrim(0, 0, 0, 0).width;
  4. t.dispose();
  5. return result;
  6. }

代码示例来源:origin: BiglySoftware/BiglyBT

  1. public void addRange() {
  2. new IpFilterEditor(CoreFactory.getSingleton(),table.getShell(), null);
  3. //noChange = false;
  4. //refresh();
  5. }

代码示例来源:origin: BiglySoftware/BiglyBT

  1. public void editRange(IpRange range) {
  2. new IpFilterEditor(CoreFactory.getSingleton(),table.getShell(), range);
  3. noChange = false;
  4. //refresh();
  5. }

代码示例来源:origin: org.eclipse.platform/org.eclipse.jface.text

  1. @Override
  2. protected Point computeLocation(Rectangle subjectArea, Point controlSize, Anchor anchor) {
  3. Point location= super.computeLocation(subjectArea, controlSize, anchor);
  4. /*
  5. * The location is computed using subjectControl.toDisplay(), which does not include the
  6. * trim of the subject control. As we want the additional info popup aligned with the outer
  7. * coordinates of the proposal popup, adjust this here
  8. */
  9. Rectangle trim= fProposalTable.getShell().computeTrim(0, 0, 0, 0);
  10. location.x += trim.x;
  11. location.y += trim.y;
  12. return location;
  13. }

代码示例来源:origin: org.eclipse.scout.sdk.deps/org.eclipse.jface.text

  1. @Override
  2. protected Point computeLocation(Rectangle subjectArea, Point controlSize, Anchor anchor) {
  3. Point location= super.computeLocation(subjectArea, controlSize, anchor);
  4. /*
  5. * The location is computed using subjectControl.toDisplay(), which does not include the
  6. * trim of the subject control. As we want the additional info popup aligned with the outer
  7. * coordinates of the proposal popup, adjust this here
  8. */
  9. Rectangle trim= fProposalTable.getShell().computeTrim(0, 0, 0, 0);
  10. location.x += trim.x;
  11. location.y += trim.y;
  12. return location;
  13. }

代码示例来源:origin: org.codehaus.openxma/xmartclient

  1. protected void handleCopy() {
  2. // Context menu selected: copy cell value to clipboard
  3. if (copyMenuClipboardText_ != null && copyMenuClipboardText_.length()>0) {
  4. Display display = table_.getShell().getDisplay();
  5. Clipboard clipboard = new Clipboard(display);
  6. clipboard.setContents(new String[] {copyMenuClipboardText_}, new Transfer[] {TextTransfer.getInstance()});
  7. clipboard.dispose();
  8. }
  9. }

代码示例来源:origin: org.eclipse.equinox.security/ui

  1. void removeSelected() {
  2. try {
  3. // get the confirmation first
  4. ConfirmationDialog confirmationDilaog = new ConfirmationDialog(tableViewer.getTable().getShell(), currentSelection.cert);
  5. if (confirmationDilaog.open() == ConfirmationDialog.YES) {
  6. activeTrustEngines[currentSelection.trustEngineIndex].removeTrustAnchor(currentSelection.cert);
  7. tableViewer.setInput(getCertificates());
  8. removeBtn.setEnabled(false);
  9. }
  10. } catch (Exception e) {
  11. e.printStackTrace();
  12. }
  13. }

代码示例来源:origin: org.eclipse.platform/org.eclipse.jface.text

  1. @Override
  2. protected void computeInformation() {
  3. if (fProposal instanceof ICompletionProposalExtension3)
  4. setCustomInformationControlCreator(((ICompletionProposalExtension3) fProposal).getInformationControlCreator());
  5. else
  6. setCustomInformationControlCreator(null);
  7. // compute subject area
  8. Point size= fProposalTable.getShell().getSize();
  9. // set information & subject area
  10. setInformation(fInformation, new Rectangle(0, 0, size.x, size.y));
  11. }

代码示例来源:origin: org.eclipse.scout.sdk.deps/org.eclipse.jface.text

  1. @Override
  2. protected void computeInformation() {
  3. if (fProposal instanceof ICompletionProposalExtension3)
  4. setCustomInformationControlCreator(((ICompletionProposalExtension3) fProposal).getInformationControlCreator());
  5. else
  6. setCustomInformationControlCreator(null);
  7. // compute subject area
  8. Point size= fProposalTable.getShell().getSize();
  9. // set information & subject area
  10. setInformation(fInformation, new Rectangle(0, 0, size.x, size.y));
  11. }

代码示例来源:origin: openaudible/openaudible

  1. protected void createSortMenu(String menuNames[]) {
  2. if (table == null)
  3. return;
  4. sortMenu = new Menu(table.getShell(), SWT.POP_UP);
  5. for (int x = 0; x < menuNames.length; x++) {
  6. MenuItem item = new MenuItem(sortMenu, SWT.PUSH);
  7. Integer ID = x;
  8. item.setData(ID);
  9. item.setText(menuNames[x]);
  10. item.addSelectionListener(this);
  11. }
  12. table.setMenu(sortMenu);
  13. }

代码示例来源:origin: org.eclipse/org.eclipse.ajdt.ui

  1. private void addPopupMenu() {
  2. Menu menu= new Menu(fTable.getShell(), SWT.POP_UP);
  3. fTable.setMenu(menu);
  4. final MenuItem remove= new MenuItem(menu, SWT.NONE);
  5. remove.setText(JavaUIMessages.TypeInfoViewer_remove_from_history);
  6. menu.addMenuListener(new MenuAdapter() {
  7. public void menuShown(MenuEvent e) {
  8. TableItem[] selection= fTable.getSelection();
  9. remove.setEnabled(canEnable(selection));
  10. }
  11. });
  12. remove.addSelectionListener(new SelectionAdapter() {
  13. public void widgetSelected(SelectionEvent e) {
  14. deleteHistoryEntry();
  15. }
  16. });
  17. }

代码示例来源:origin: org.eclipse.scout.sdk.deps/org.eclipse.jdt.ui

  1. private void addPopupMenu() {
  2. Menu menu= new Menu(fTable.getShell(), SWT.POP_UP);
  3. fTable.setMenu(menu);
  4. final MenuItem remove= new MenuItem(menu, SWT.NONE);
  5. remove.setText(JavaUIMessages.TypeInfoViewer_remove_from_history);
  6. menu.addMenuListener(new MenuAdapter() {
  7. @Override
  8. public void menuShown(MenuEvent e) {
  9. TableItem[] selection= fTable.getSelection();
  10. remove.setEnabled(canEnable(selection));
  11. }
  12. });
  13. remove.addSelectionListener(new SelectionAdapter() {
  14. @Override
  15. public void widgetSelected(SelectionEvent e) {
  16. deleteHistoryEntry();
  17. }
  18. });
  19. }

代码示例来源:origin: org.eclipse.pde/org.eclipse.pde.ui

  1. private void showDialog(final ISiteArchive archive) {
  2. final ISiteModel model = (ISiteModel) getPage().getModel();
  3. BusyIndicator.showWhile(fTable.getDisplay(), () -> {
  4. NewArchiveDialog dialog = new NewArchiveDialog(fTable.getShell(), model, archive);
  5. dialog.create();
  6. SWTUtil.setDialogSize(dialog, 400, -1);
  7. dialog.open();
  8. });
  9. }

相关文章

Table类方法