sebb        2004/01/31 18:51:57

  Modified:    src/core/org/apache/jmeter/gui/util MenuFactory.java
  Log:
  Don't try to add JMeterTreeNode and TestBeanGUI to menus
  
  Revision  Changes    Path
  1.26      +14 -3     
jakarta-jmeter/src/core/org/apache/jmeter/gui/util/MenuFactory.java
  
  Index: MenuFactory.java
  ===================================================================
  RCS file: 
/home/cvs/jakarta-jmeter/src/core/org/apache/jmeter/gui/util/MenuFactory.java,v
  retrieving revision 1.25
  retrieving revision 1.26
  diff -u -r1.25 -r1.26
  --- MenuFactory.java  16 Jan 2004 03:08:14 -0000      1.25
  +++ MenuFactory.java  1 Feb 2004 02:51:57 -0000       1.26
  @@ -422,6 +422,17 @@
               while (iter.hasNext())
               {
                   String name= (String)iter.next();
  +
  +                /*
  +                 * JMeterTreeNode and TestBeanGUI are special GUI classes,
  +                 * and aren't intended to be added to menus
  +                 * 
  +                 * TODO: find a better way of checking this
  +                 */
  +                if (name.endsWith("JMeterTreeNode") || name.endsWith("TestBeanGUI"))
  +                {
  +                     continue;// Don't try to instantiate these
  +                }
                   
                   JMeterGUIComponent item;
                   try
  @@ -438,13 +449,13 @@
                   }
                   catch (Throwable e)
                   {
  -                    log.debug("Could not instantiate "+name, e);
  +                    log.info("Could not instantiate "+name, e);
                       continue;
                   }
                   if (elementsToSkip.contains(name)
                       || elementsToSkip.contains(item.getStaticLabel()))
                   {
  -                    log.debug("Skipping "+name);
  +                    log.info("Skipping "+name);
                       continue;
                   }
                   else
  
  
  

---------------------------------------------------------------------
To unsubscribe, e-mail: [EMAIL PROTECTED]
For additional commands, e-mail: [EMAIL PROTECTED]

Reply via email to