本文整理匯總了Java中org.eclipse.swt.SWT.NO_FOCUS屬性的典型用法代碼示例。如果您正苦於以下問題:Java SWT.NO_FOCUS屬性的具體用法?Java SWT.NO_FOCUS怎麽用?Java SWT.NO_FOCUS使用的例子?那麽, 這裏精選的屬性代碼示例或許可以為您提供幫助。您也可以進一步了解該屬性所在類org.eclipse.swt.SWT
的用法示例。
在下文中一共展示了SWT.NO_FOCUS屬性的2個代碼示例,這些例子默認根據受歡迎程度排序。您可以為喜歡或者感覺有用的代碼點讚,您的評價將有助於係統推薦出更棒的Java代碼示例。
示例1: createMainPanel
/** Creates a composite within the specified composite and sets its layout
* to a default FillLayout().
*
* @param composite to create your Composite under
* @return The newly created composite
*/
@Override
public Composite createMainPanel(Composite composite) {
TableViewSWTPanelCreator mainPanelCreator = getMainPanelCreator();
if (mainPanelCreator != null) {
return mainPanelCreator.createTableViewPanel(composite);
}
Composite panel = new Composite(composite, SWT.NO_FOCUS);
composite.getLayout();
GridLayout layout = new GridLayout();
layout.marginHeight = 0;
layout.marginWidth = 0;
panel.setLayout(layout);
Object parentLayout = composite.getLayout();
if (parentLayout == null || (parentLayout instanceof GridLayout)) {
panel.setLayoutData(new GridData(GridData.FILL_BOTH));
}
return panel;
}
示例2: BookButtonBar
BookButtonBar(Composite parent, int gridStyle) {
toolbar = new ToolBar(parent, SWT.FLAT | SWT.NO_FOCUS);
gd = new GridData(gridStyle);
toolbar.setLayoutData(gd);
for (Command cmd : cmds) {
addIconButton(toolbar, cmd);
}
BookNotifier.getInstance().addListener(this);
refresh();
}