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

Diff of /jsampler/trunk/src/org/jsampler/view/JSMainFrame.java

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

revision 911 by iliev, Mon Aug 7 18:25:58 2006 UTC revision 1143 by iliev, Mon Apr 2 21:18:31 2007 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 Grigor Kirilov Iliev   *   Copyright (C) 2005-2006 Grigor Iliev <grigor@grigoriliev.com>
5   *   *
6   *   This file is part of JSampler.   *   This file is part of JSampler.
7   *   *
# Line 71  public abstract class JSMainFrame extend Line 71  public abstract class JSMainFrame extend
71          }          }
72                    
73          /**          /**
74             * Invoked on startup when no JSampler home directory is specified
75             * or the specified JSampler home directory doesn't exist.
76             * This method should ask the user to specify a JSampler
77             * home directory and then set the specified JSampler home directory using
78             * {@link org.jsampler.CC#setJSamplerHome} method.
79             * @see org.jsampler.CC#getJSamplerHome
80             * @see org.jsampler.CC#setJSamplerHome
81             */
82            public abstract void installJSamplerHome();
83            
84            /**
85           * Returns a list containing all <code>JSChannelsPane</code>s added to the view.           * Returns a list containing all <code>JSChannelsPane</code>s added to the view.
86           * @return A list containing all <code>JSChannelsPane</code>s added to the view.           * @return A list containing all <code>JSChannelsPane</code>s added to the view.
87           * @see #addChannelsPane           * @see #addChannelsPane
# Line 147  public abstract class JSMainFrame extend Line 158  public abstract class JSMainFrame extend
158                   */                   */
159                  public void                  public void
160                  channelAdded(SamplerChannelListEvent e) {                  channelAdded(SamplerChannelListEvent e) {
161                          Integer id = e.getChannelModel().getChannelID();                          Integer id = e.getChannelModel().getChannelId();
162                          if(findChannel(id) != null) {                          if(findChannel(id) != null) {
163                                  CC.getLogger().log(Level.WARNING, "JSMainFrame.channelExist!", id);                                  CC.getLogger().log(Level.WARNING, "JSMainFrame.channelExist!", id);
164                                  return;                                  return;
# Line 163  public abstract class JSMainFrame extend Line 174  public abstract class JSMainFrame extend
174                   */                   */
175                  public void                  public void
176                  channelRemoved(SamplerChannelListEvent e) {                  channelRemoved(SamplerChannelListEvent e) {
177                          removeChannel(e.getChannelModel().getChannelID());                          removeChannel(e.getChannelModel().getChannelId());
178                  }                  }
179          }          }
180                    
# Line 177  public abstract class JSMainFrame extend Line 188  public abstract class JSMainFrame extend
188                  if(id < 0) return null;                  if(id < 0) return null;
189                                    
190                  for(JSChannelsPane cp : getChannelsPaneList()) {                  for(JSChannelsPane cp : getChannelsPaneList()) {
191                          for(JSChannel c : cp.getChannels()) if(c.getChannelID() == id) return c;                          for(JSChannel c : cp.getChannels()) if(c.getChannelId() == id) return c;
192                  }                  }
193                                    
194                  return null;                  return null;
# Line 195  public abstract class JSMainFrame extend Line 206  public abstract class JSMainFrame extend
206                                    
207                  for(JSChannelsPane cp : getChannelsPaneList()) {                  for(JSChannelsPane cp : getChannelsPaneList()) {
208                          for(JSChannel c : cp.getChannels()) {                          for(JSChannel c : cp.getChannels()) {
209                                  if(c.getChannelID() == id) {                                  if(c.getChannelId() == id) {
210                                          cp.removeChannel(c);                                          cp.removeChannel(c);
211                                          return c;                                          return c;
212                                  }                                  }

Legend:
Removed from v.911  
changed lines
  Added in v.1143

  ViewVC Help
Powered by ViewVC