本文整理汇总了Java中org.eclipse.gef.ui.actions.ZoomComboContributionItem类的典型用法代码示例。如果您正苦于以下问题:Java ZoomComboContributionItem类的具体用法?Java ZoomComboContributionItem怎么用?Java ZoomComboContributionItem使用的例子?那么恭喜您, 这里精选的类代码示例或许可以为您提供帮助。
ZoomComboContributionItem类属于org.eclipse.gef.ui.actions包,在下文中一共展示了ZoomComboContributionItem类的17个代码示例,这些例子默认根据受欢迎程度排序。您可以为喜欢或者感觉有用的代码点赞,您的评价将有助于我们的系统推荐出更棒的Java代码示例。
示例1: contributeToToolBar
import org.eclipse.gef.ui.actions.ZoomComboContributionItem; //导入依赖的package包/类
/**
* Add actions to the given toolbar.
*
* @see org.eclipse.ui.part.EditorActionBarContributor#contributeToToolBar(org.eclipse.jface.action.IToolBarManager)
*/
public void contributeToToolBar(IToolBarManager toolBarManager) {
toolBarManager.add(getAction(ActionFactory.COPY.getId()));
toolBarManager.add(getAction(ActionFactory.PASTE.getId()));
toolBarManager.add(getAction(ActionFactory.UNDO.getId()));
toolBarManager.add(getAction(ActionFactory.REDO.getId()));
// Adding the zooming action for the editor.
String[] zoomStrings = new String[] { ZoomManager.FIT_ALL,
ZoomManager.FIT_WIDTH, ZoomManager.FIT_HEIGHT };
ZoomComboContributionItem zoomActionItem = new ZoomComboContributionItem(getPage(), zoomStrings);
toolBarManager.add(zoomActionItem);
//toolBarManager.add(getAction(GEFActionConstants.TOGGLE_GRID_VISIBILITY));
}
开发者ID:ShoukriKattan,项目名称:ForgedUI-Eclipse,代码行数:21,代码来源:GUIEditorActionBarContributor.java
示例2: MainDiagramEditor
import org.eclipse.gef.ui.actions.ZoomComboContributionItem; //导入依赖的package包/类
public MainDiagramEditor(ERDiagram diagram, ERDiagramEditPartFactory editPartFactory,
ZoomComboContributionItem zoomComboContributionItem, ERDiagramOutlinePage outlinePage) {
Activator.debug(this, "constructor", "...Creating diagram editor: " + diagram);
this.diagram = diagram;
this.editPartFactory = editPartFactory;
this.zoomComboContributionItem = zoomComboContributionItem;
this.propertySheetPage = new PropertySheetPage();
this.propertySheetPage.setPropertySourceProvider(new ERDiagramPropertySourceProvider());
try {
this.extensionLoader = new ExtensionLoader(this);
} catch (final CoreException e) {
Activator.showExceptionDialog(e);
}
setEditDomain(new DefaultEditDomain(this));
initializeOutlinePage(outlinePage);
}
开发者ID:dbflute-session,项目名称:erflute,代码行数:17,代码来源:MainDiagramEditor.java
示例3: setActivePage
import org.eclipse.gef.ui.actions.ZoomComboContributionItem; //导入依赖的package包/类
@Override
public void setActivePage(IEditorPart activeEditor) {
final MainDiagramEditor editor = (MainDiagramEditor) activeEditor;
final ERDiagramActionBarContributor actionBarContributor = editor.getActionBarContributor();
final IActionBars actionBars = getActionBars();
actionBars.clearGlobalActionHandlers();
actionBars.getToolBarManager().removeAll();
actionBarContributor.init(actionBars, editor.getEditorSite().getPage());
actionBarContributor.setActiveEditor(editor);
final ZoomComboContributionItem item =
(ZoomComboContributionItem) getActionBars().getToolBarManager().find(GEFActionConstants.ZOOM_TOOLBAR_WIDGET);
if (item != null) {
final ZoomManager zoomManager = (ZoomManager) editor.getAdapter(ZoomManager.class);
item.setZoomManager(zoomManager);
}
getActionBars().updateActionBars();
}
开发者ID:dbflute-session,项目名称:erflute,代码行数:18,代码来源:ERFluteMultiPageEditorActionBarContributor.java
示例4: setActivePage
import org.eclipse.gef.ui.actions.ZoomComboContributionItem; //导入依赖的package包/类
@Override
public void setActivePage(IEditorPart activeEditor) {
IActionBars actionBars = this.getActionBars();
actionBars.clearGlobalActionHandlers();
actionBars.getToolBarManager().removeAll();
BODesignerEditor editor = (BODesignerEditor) activeEditor;
BODiagramActionBarContributor activeContributor =editor.getActionBarContributor();
if (this.zoomComboContributionItem == null) {
this.zoomComboContributionItem = new ZoomComboContributionItem(
this.getPage());
}
activeContributor.contributeToToolBar(actionBars.getToolBarManager(),
this.zoomComboContributionItem);
activeContributor.setActiveEditor(editor);
ZoomComboContributionItem item = (ZoomComboContributionItem) getActionBars()
.getToolBarManager().find(
GEFActionConstants.ZOOM_TOOLBAR_WIDGET);
if (item != null) {
ZoomManager zoomManager = (ZoomManager) editor
.getAdapter(ZoomManager.class);
item.setZoomManager(zoomManager);
}
actionBars.updateActionBars();
}
开发者ID:winture,项目名称:wt-studio,代码行数:27,代码来源:BODiagramMultiActionBarContributor.java
示例5: contributeToToolBar
import org.eclipse.gef.ui.actions.ZoomComboContributionItem; //导入依赖的package包/类
/**
* Add actions to the given toolbar.
*
* @see org.eclipse.ui.part.EditorActionBarContributor#contributeToToolBar(org.eclipse.jface.action.IToolBarManager)
*/
public void contributeToToolBar(IToolBarManager toolBarManager) {
super.contributeToToolBar(toolBarManager);
toolBarManager.add(getAction(ActionFactory.UNDO.getId()));
toolBarManager.add(getAction(ActionFactory.REDO.getId()));
toolBarManager.add(new Separator());
toolBarManager.add(getAction(ActionFactory.COPY.getId()));
toolBarManager.add(getAction(ActionFactory.CUT.getId()));
toolBarManager.add(getAction(ActionFactory.PASTE.getId()));
toolBarManager.add(new Separator());
String[] zoomStrings = new String[] { ZoomManager.FIT_ALL, ZoomManager.FIT_HEIGHT, ZoomManager.FIT_WIDTH };
toolBarManager.add(new ZoomComboContributionItem(getPage(), zoomStrings));
/*
String[] modeStrings = new String[] {
Messages.getString("UCMActionBarContributor.viewAllElements"), Messages.getString("UCMActionBarContributor.hideEmptyPoints"), Messages.getString("UCMActionBarContributor.hideEmptyPointsAndStubLabels") }; //$NON-NLS-1$ //$NON-NLS-2$ //$NON-NLS-3$
toolBarManager.add(new ModeComboContributionItem(getPage(), modeStrings));
*/
}
开发者ID:McGill-DP-Group,项目名称:seg.jUCMNav,代码行数:24,代码来源:UCMActionBarContributor.java
示例6: contributeToToolBar
import org.eclipse.gef.ui.actions.ZoomComboContributionItem; //导入依赖的package包/类
public void contributeToToolBar(IToolBarManager toolBarManager) {
toolBarManager.add(getAction(ActionFactory.UNDO.getId()));
toolBarManager.add(getAction(ActionFactory.REDO.getId()));
toolBarManager.add(getAction(ActionFactory.DELETE.getId()));
toolBarManager.add(new Separator());
toolBarManager.add(getAction(GEFActionConstants.ZOOM_IN));
toolBarManager.add(getAction(GEFActionConstants.ZOOM_OUT));
toolBarManager.add(new ZoomComboContributionItem(getPage()));
toolBarManager.add(getAction(GEFActionConstants.TOGGLE_GRID_VISIBILITY));
toolBarManager.add(getAction(GEFActionConstants.TOGGLE_SNAP_TO_GEOMETRY));
toolBarManager.add(getAction(ActionFactory.COPY.getId()));
toolBarManager.add(getAction(ActionFactory.PASTE.getId()));
toolBarManager.add(new Separator());
toolBarManager.add(getAction(ClearEdgeBendpointLayoutAction.ID));
}
开发者ID:gw4e,项目名称:gw4e.project,代码行数:16,代码来源:GW4EEditorActionBarContributor.java
示例7: contributeToToolBar
import org.eclipse.gef.ui.actions.ZoomComboContributionItem; //导入依赖的package包/类
public void contributeToToolBar(IToolBarManager toolBarManager) {
toolBarManager.add(getAction(ActionFactory.DELETE.getId()));
toolBarManager.add(getAction(ActionFactory.UNDO.getId()));
toolBarManager.add(getAction(ActionFactory.REDO.getId()));
toolBarManager.add(new Separator());
toolBarManager.add(getAction(GEFActionConstants.TOGGLE_GRID_VISIBILITY));
toolBarManager.add(new Separator());
toolBarManager.add(getAction(GEFActionConstants.ZOOM_IN));
toolBarManager.add(getAction(GEFActionConstants.ZOOM_OUT));
String[] zoomStrings = new String[] { ZoomManager.FIT_ALL, ZoomManager.FIT_HEIGHT, ZoomManager.FIT_WIDTH };
toolBarManager.add(new ZoomComboContributionItem(getPage(), zoomStrings));
}
开发者ID:bsteker,项目名称:bdf2,代码行数:13,代码来源:DbToolGefEditorActionBarContributor.java
示例8: contributeToToolBar
import org.eclipse.gef.ui.actions.ZoomComboContributionItem; //导入依赖的package包/类
@Override
public void contributeToToolBar(IToolBarManager toolBarManager) {
super.contributeToToolBar(toolBarManager);
toolBarManager.add(getAction(ActionFactory.DELETE.getId()));
toolBarManager.add(getAction(DwFeatureModelAutoLayoutAction.ID));
toolBarManager.add(getAction(DwFeatureModelCreateOverviewAction.FEATUREMODEL_CREATE_OVERVIEW));
toolBarManager.add(getAction(DwFeatureModelCreateSVGAction.FEATUREMODEL_CREATE_SVG));
toolBarManager.add(new ZoomComboContributionItem(getPage()));
}
开发者ID:DarwinSPL,项目名称:DarwinSPL,代码行数:11,代码来源:DwGraphicalFeatureModelEditorActionBarContributor.java
示例9: setActivePage
import org.eclipse.gef.ui.actions.ZoomComboContributionItem; //导入依赖的package包/类
@Override
public void setActivePage(IEditorPart activeEditor) {
IActionBars actionBars = this.getActionBars();
actionBars.clearGlobalActionHandlers();
actionBars.getToolBarManager().removeAll();
ERDiagramEditor editor = (ERDiagramEditor) activeEditor;
ERDiagramActionBarContributor activeContributor = editor
.getActionBarContributor();
if (this.zoomComboContributionItem == null) {
this.zoomComboContributionItem = new ZoomComboContributionItem(
this.getPage());
}
activeContributor.setActiveEditor(editor);
EditPart editPart = editor.getGraphicalViewer().getContents();
ERDiagram diagram = (ERDiagram) editPart.getModel();
activeContributor.contributeToToolBar(diagram,
actionBars.getToolBarManager(), this.zoomComboContributionItem);
ZoomComboContributionItem item = (ZoomComboContributionItem) getActionBars()
.getToolBarManager().find(
GEFActionConstants.ZOOM_TOOLBAR_WIDGET);
if (item != null) {
ZoomManager zoomManager = (ZoomManager) editor
.getAdapter(ZoomManager.class);
item.setZoomManager(zoomManager);
}
actionBars.updateActionBars();
}
开发者ID:kozake,项目名称:ermaster-k,代码行数:36,代码来源:ERDiagramMultiPageEditorActionBarContributor.java
示例10: initMainPage
import org.eclipse.gef.ui.actions.ZoomComboContributionItem; //导入依赖的package包/类
private void initMainPage() {
try {
zoomComboContributionItem = new ZoomComboContributionItem(getSite().getPage());
final MainDiagramEditor editor = new MainDiagramEditor(diagram, editPartFactory, zoomComboContributionItem, outlinePage);
final int index = addPage(editor, getEditorInput()); // as main
setPageText(index, diagram.getName());
} catch (final PartInitException e) {
Activator.showExceptionDialog(e);
}
}
开发者ID:dbflute-session,项目名称:erflute,代码行数:11,代码来源:ERFluteMultiPageEditor.java
示例11: contributeToToolBar
import org.eclipse.gef.ui.actions.ZoomComboContributionItem; //导入依赖的package包/类
public void contributeToToolBar( IToolBarManager tbm )
{
tbm.add( new Separator( ) );
String[] zoomStrings = new String[]{
ZoomManager.FIT_ALL,
ZoomManager.FIT_HEIGHT,
ZoomManager.FIT_WIDTH
};
ZoomComboContributionItem zoomComboContributionItem = new ZoomComboContributionItem( getPage( ),
zoomStrings ) {
protected Control createControl( Composite parent )
{
Control control = super.createControl( parent );
control.setToolTipText( Messages.getString( "DesignerActionBarContributor.menu.zoomCombo.tooltip" ) );
return control;
}
};
if ( getPage( ) != null && getPage( ).getActivePart( ) != null )
{
zoomComboContributionItem.setZoomManager( (ZoomManager) getPage( ).getActivePart( )
.getAdapter( ZoomManager.class ) );
}
zoomComboContributionItem.setVisible( true );
tbm.add( zoomComboContributionItem );
toggleBreadcrumbAction = new ToggleBreadcrumbAction( getPage( ) );
tbm.add( toggleBreadcrumbAction );
}
开发者ID:eclipse,项目名称:birt,代码行数:33,代码来源:DesignerActionBarContributor.java
示例12: contributeToToolBar
import org.eclipse.gef.ui.actions.ZoomComboContributionItem; //导入依赖的package包/类
public void contributeToToolBar(IToolBarManager toolBarManager,
ZoomComboContributionItem zoomComboContributionItem) {
toolBarManager.add(this.getAction(ActionFactory.DELETE.getId()));
toolBarManager.add(this.getAction(ActionFactory.UNDO.getId()));
toolBarManager.add(this.getAction(ActionFactory.REDO.getId()));
toolBarManager.add(getActionRegistry().getAction(
GEFActionConstants.ZOOM_IN));
toolBarManager.add(getActionRegistry().getAction(
GEFActionConstants.ZOOM_OUT));
toolBarManager.add(getActionRegistry().getAction(ZoomAdjustAction.ID));
toolBarManager.add(zoomComboContributionItem);
this.getPage().addSelectionListener(new ISelectionListener() {
public void selectionChanged(IWorkbenchPart part,
ISelection selection) {
if (selection instanceof IStructuredSelection) {
List selectedEditParts = ((IStructuredSelection) selection)
.toList();
if (!selectedEditParts.isEmpty()) {
if (selectedEditParts.get(0) instanceof EditPart) {}
}
}
}
});
}
开发者ID:winture,项目名称:wt-studio,代码行数:30,代码来源:BODiagramActionBarContributor.java
示例13: contributeToToolBar
import org.eclipse.gef.ui.actions.ZoomComboContributionItem; //导入依赖的package包/类
public void contributeToToolBar(IToolBarManager toolBarManager) {
toolBarManager.add(getAction(ActionFactory.UNDO.getId()));
toolBarManager.add(getAction(ActionFactory.REDO.getId()));
toolBarManager.add(getAction(GEFActionConstants.ZOOM_IN));
toolBarManager.add(getAction(GEFActionConstants.ZOOM_OUT));
toolBarManager.add(new ZoomComboContributionItem(getPage()));
// toolBarManager.add(new Separator());
}
开发者ID:hejiehui,项目名称:xeda,代码行数:10,代码来源:XedaActionBarContributor.java
示例14: VirtualDiagramEditor
import org.eclipse.gef.ui.actions.ZoomComboContributionItem; //导入依赖的package包/类
public VirtualDiagramEditor(ERDiagram diagram, ERVirtualDiagram vdiagram, ERDiagramEditPartFactory editPartFactory,
ZoomComboContributionItem zoomComboContributionItem, ERDiagramOutlinePage outlinePage) {
super(diagram, editPartFactory, zoomComboContributionItem, outlinePage);
this.vdiagram = vdiagram;
}
开发者ID:dbflute-session,项目名称:erflute,代码行数:6,代码来源:VirtualDiagramEditor.java
示例15: ERDiagramActionBarContributor
import org.eclipse.gef.ui.actions.ZoomComboContributionItem; //导入依赖的package包/类
public ERDiagramActionBarContributor(ZoomComboContributionItem zoomComboContributionItem) {
this.zoomComboContributionItem = zoomComboContributionItem;
}
开发者ID:dbflute-session,项目名称:erflute,代码行数:4,代码来源:ERDiagramActionBarContributor.java
示例16: getZoomComboContributionItem
import org.eclipse.gef.ui.actions.ZoomComboContributionItem; //导入依赖的package包/类
public ZoomComboContributionItem getZoomComboContributionItem() {
return zoomComboContributionItem;
}
开发者ID:dbflute-session,项目名称:erflute,代码行数:4,代码来源:ERFluteMultiPageEditor.java
示例17: contributeToToolBar
import org.eclipse.gef.ui.actions.ZoomComboContributionItem; //导入依赖的package包/类
@Override
public void contributeToToolBar(IToolBarManager toolBarManager) {
super.contributeToToolBar(toolBarManager);
toolBarManager.add(new ZoomComboContributionItem(getPage()));
}
开发者ID:SERESLab,项目名称:OnionUmlVisualization,代码行数:6,代码来源:ModelViewerActionBarContributor.java
注:本文中的org.eclipse.gef.ui.actions.ZoomComboContributionItem类示例整理自Github/MSDocs等源码及文档管理平台,相关代码片段筛选自各路编程大神贡献的开源项目,源码版权归原作者所有,传播和使用请参考对应项目的License;未经允许,请勿转载。 |
请发表评论