public final void savePreferences(final Scheme activeScheme, final Binding[] bindings) throws IOException { BindingPersistence.write(activeScheme, bindings); try { bindingManager.setActiveScheme(activeScheme); } catch (final NotDefinedException e) { WorkbenchPlugin.log( "The active scheme is not currently defined.", //$NON-NLS-1$ WorkbenchPlugin.getStatus(e)); } bindingManager.setBindings(bindings); }
/** * Remove the specific binding by identity. Does nothing if the binding is not in the manager. * * @param binding The binding to be removed; must not be <code>null</code>. */ public final void removeBinding(final Binding binding) { bindingManager.removeBinding(binding); }
public final boolean isPerfectMatch(final TriggerSequence sequence) { return bindingManager.isPerfectMatch(sequence); }
public final Scheme getScheme(final String schemeId) { return bindingManager.getScheme(schemeId); }
public final String getPlatform() { return bindingManager.getPlatform(); }
public final Binding getPerfectMatch(final TriggerSequence trigger) { return bindingManager.getPerfectMatch(trigger); }
public final TriggerSequence[] getActiveBindingsFor( final ParameterizedCommand parameterizedCommand) { return bindingManager.getActiveBindingsFor(parameterizedCommand); }
/* * (non-Javadoc) * * @see * org.eclipse.ui.keys.IBindingService#removeBindingManagerListener(org. * eclipse.jface.bindings.IBindingManagerListener) */ public void removeBindingManagerListener(IBindingManagerListener listener) { bindingManager.removeBindingManagerListener(listener); }
public final Scheme[] getDefinedSchemes() { return bindingManager.getDefinedSchemes(); }
public final Binding[] getBindings() { return bindingManager.getBindings(); }
public final String getBestActiveBindingFormattedFor(final String commandId) { return bindingManager.getBestActiveBindingFormattedFor(commandId); }
/* (non-Javadoc) * @see org.eclipse.ui.keys.IBindingService#getBestActiveBindingFor(org.eclipse.core.commands.ParameterizedCommand) */ public TriggerSequence getBestActiveBindingFor(ParameterizedCommand command) { return bindingManager.getBestActiveBindingFor(command); }
public final TriggerSequence getBestActiveBindingFor(final String commandId) { return bindingManager.getBestActiveBindingFor(commandId); }
public final Scheme getActiveScheme() { return bindingManager.getActiveScheme(); }
public final String getLocale() { return bindingManager.getLocale(); }
/* * (non-Javadoc) * * @see * org.eclipse.ui.keys.IBindingService#addBindingManagerListener(org.eclipse * .jface.bindings.IBindingManagerListener) */ public void addBindingManagerListener(IBindingManagerListener listener) { bindingManager.addBindingManagerListener(listener); }
public final Map getPartialMatches(final TriggerSequence trigger) { return bindingManager.getPartialMatches(trigger); }
/* (non-Javadoc) * @see org.eclipse.ui.keys.IBindingService#getConflictsFor(org.eclipse.jface.bindings.TriggerSequence) */ public Collection getConflictsFor(TriggerSequence sequence) { return bindingManager.getConflictsFor(sequence); }
/** * TODO Promote this method to API. * * <p>Adds a single new binding to the existing array of bindings. If the array is currently * <code>null</code>, then a new array is created and this binding is added to it. This method * does not detect duplicates. * * <p>This method completes in amortized <code>O(1)</code>. * * @param binding The binding to be added; must not be <code>null</code>. */ public final void addBinding(final Binding binding) { bindingManager.addBinding(binding); }