Package org.eclipse.jface.bindings

Examples of org.eclipse.jface.bindings.BindingManager


   * The widgets affected by this method are: scheme combo, bindings
   * table/tree model, and the when combo.
   */
  private final void fill() {
    // Make an internal binding manager to track changes.
    localChangeManager = new BindingManager(new ContextManager(),
        new CommandManager());
    final Scheme[] definedSchemes = bindingService.getDefinedSchemes();
    try {
      for (int i = 0; i < definedSchemes.length; i++) {
        final Scheme scheme = definedSchemes[i];
View Full Code Here


   
    StartupThreading.runWithoutExceptions(new StartupRunnable() {

      public void runWithException() {
        BindingManager.DEBUG = Policy.DEBUG_KEY_BINDINGS;
        bindingManager = new BindingManager(contextManager, commandManager);
        bindingService[0] = new BindingService(
            bindingManager, commandService[0], Workbench.this);
       
      }});
   
View Full Code Here

  {
  }

  private BindingManager getLocalChangeManager()
  {
    BindingManager manager =
      new BindingManager(new ContextManager(), new CommandManager());

    Scheme scheme = bindingService.getActiveScheme();
    try{
      try{
        manager.setActiveScheme(scheme);
      }catch(NotDefinedException nde){
        // KeysPreferencePage ignores this error as well... hmmm
      }
      manager.setLocale(bindingService.getLocale());
      manager.setPlatform(bindingService.getPlatform());
      manager.setBindings(bindingService.getBindings());
    }catch(Exception e){
      logger.error("Error initializing local binding manager.", e);
    }

    return manager;
View Full Code Here

  {
    if (!keysDisabled){
      logger.debug(
          "Disabling conflicting keybindings while vim editor is focused: " +
          Arrays.toString(keys));
      BindingManager localChangeManager = getLocalChangeManager();
      String schemeId = localChangeManager.getActiveScheme().getId();
      for(KeySequence keySequence : keySequences){
        for (String contextId : CONTEXT_IDS){
          localChangeManager.removeBindings(
              keySequence, schemeId, contextId, null, null, null, Binding.USER);
          localChangeManager.addBinding(new KeyBinding(
                keySequence, null, schemeId, contextId,
                null, null, null, Binding.USER));
        }
      }
      keysDisabled = true;
View Full Code Here

  private void enableKeys()
  {
    if (keysDisabled){
      logger.debug("Re-enabling conflicting keybindings.");
      BindingManager localChangeManager = getLocalChangeManager();
      String schemeId = localChangeManager.getActiveScheme().getId();
      for(KeySequence keySequence : keySequences){
        for (String contextId : CONTEXT_IDS){
          localChangeManager.removeBindings(
              keySequence, schemeId, contextId, null, null, null, Binding.USER);
        }
      }
      keysDisabled = false;
      saveKeyChanges(localChangeManager);
View Full Code Here

TOP

Related Classes of org.eclipse.jface.bindings.BindingManager

Copyright © 2018 www.massapicom. All rights reserved.
All source code are property of their respective owners. Java is a trademark of Sun Microsystems, Inc and owned by ORACLE Inc. Contact coftware#gmail.com.