/[svn]/jsampler/trunk/src/org/jsampler/view/std/JSInstrumentsDbTable.java
ViewVC logotype

Diff of /jsampler/trunk/src/org/jsampler/view/std/JSInstrumentsDbTable.java

Parent Directory Parent Directory | Revision Log Revision Log | View Patch Patch

revision 1540 by iliev, Mon Dec 3 23:22:02 2007 UTC revision 1743 by iliev, Sat May 31 23:04:01 2008 UTC
# Line 1  Line 1 
1  /*  /*
2   *   JSampler - a java front-end for LinuxSampler   *   JSampler - a java front-end for LinuxSampler
3   *   *
4   *   Copyright (C) 2005-2007 Grigor Iliev <grigor@grigoriliev.com>   *   Copyright (C) 2005-2008 Grigor Iliev <grigor@grigoriliev.com>
5   *   *
6   *   This file is part of JSampler.   *   This file is part of JSampler.
7   *   *
# Line 422  public class JSInstrumentsDbTable extend Line 422  public class JSInstrumentsDbTable extend
422                  actionPerformed(ActionEvent e) {                  actionPerformed(ActionEvent e) {
423                          DbDirectoryTreeNode n = instrumentsDbTree.getSelectedDirectoryNode();                          DbDirectoryTreeNode n = instrumentsDbTree.getSelectedDirectoryNode();
424                          if(n == null) return;                          if(n == null) return;
425                          instrumentsDbTree.refreshDirectoryContent(n.getInfo().getDirectoryPath());                          final String path = n.getInfo().getDirectoryPath();
426                            instrumentsDbTree.refreshDirectoryContent(path);
427                            CC.scheduleInTaskQueue(new Runnable() {
428                                    public void
429                                    run() { instrumentsDbTree.setSelectedDirectory(path); }
430                            });
431                  }                  }
432                                    
433                  public void                  public void
# Line 621  public class JSInstrumentsDbTable extend Line 626  public class JSInstrumentsDbTable extend
626                                    
627                  LoadInstrumentAction(SamplerChannelModel model) {                  LoadInstrumentAction(SamplerChannelModel model) {
628                          String s = "instrumentsdb.actions.loadInstrument.onChannel";                          String s = "instrumentsdb.actions.loadInstrument.onChannel";
629                          putValue(Action.NAME, i18n.getMenuLabel(s, model.getChannelId()));                          int i = CC.getSamplerModel().getChannelIndex(model) + 1;
630                            putValue(Action.NAME, i18n.getMenuLabel(s, i));
631                          channelModel = model;                          channelModel = model;
632                  }                  }
633                                    
# Line 1023  public class JSInstrumentsDbTable extend Line 1029  public class JSInstrumentsDbTable extend
1029                                    
1030                  public void                  public void
1031                  channelAdded(SamplerChannelListEvent e) {                  channelAdded(SamplerChannelListEvent e) {
1032                            if(CC.getSamplerModel().getChannelListIsAdjusting()) return;
1033                          updateLoadInstrumentMenus();                          updateLoadInstrumentMenus();
1034                  }                  }
1035                                    

Legend:
Removed from v.1540  
changed lines
  Added in v.1743

  ViewVC Help
Powered by ViewVC