org.eclipse.ui.IPartListener2 Java Examples
The following examples show how to use
org.eclipse.ui.IPartListener2.
You can vote up the ones you like or vote down the ones you don't like,
and go to the original project or source file by following the links above each example. You may check out the related API usage on the sidebar.
Example #1
Source File: GamlEditor.java From gama with GNU General Public License v3.0 | 5 votes |
private void assignBoxPartListener() { final IPartService partService = getSite().getWorkbenchWindow().getPartService(); if (partService == null) { return; } if (partListeners == null) { partListeners = new HashMap<>(); } final IPartListener2 oldListener = partListeners.get(partService); if (oldListener == null) { final IPartListener2 listener = new BoxDecoratorPartListener(); partService.addPartListener(listener); partListeners.put(partService, listener); } }
Example #2
Source File: TecoRegister.java From e4macs with Eclipse Public License 1.0 | 5 votes |
public void removeListener(IPartListener2 listener) { IWorkbenchPage page = EmacsPlusUtils.getWorkbenchPage(); if (page != null && location != null) { page.removePartListener(listener); } location.clearListener(); location = null; }
Example #3
Source File: TecoRegister.java From e4macs with Eclipse Public License 1.0 | 4 votes |
public void addListener(IPartListener2 listener) { IWorkbenchPage page = EmacsPlusUtils.getWorkbenchPage(); if (page != null) { page.addPartListener(listener); } }
Example #4
Source File: SafePartListener2.java From saros with GNU General Public License v2.0 | 4 votes |
public SafePartListener2(Logger log, IPartListener2 toForwardTo) { this.toForwardTo = toForwardTo; this.log = log; }