svn commit: r13345 - trunk/src_new/org/argouml: ui/targetmanager uml/ui

[email protected]
Newsgroups gmane.comp.lang.uml.argouml.cvs
Message-ID <[email protected]>
Author: tfmorris
Date: 2007-08-14 11:07:10-0700
New Revision: 13345

Modified:
   trunk/src_new/org/argouml/ui/targetmanager/TargetManager.java
   trunk/src_new/org/argouml/uml/ui/TabProps.java

Log:
Fix mistaken addTarget instead of addTargetListener.  Add check for other possible occurrences.

Modified: trunk/src_new/org/argouml/ui/targetmanager/TargetManager.java
Url: http://argouml.tigris.org/source/browse/argouml/trunk/src_new/org/argouml/ui/targetmanager/TargetManager.java?view=diff&rev=13345&p1=trunk/src_new/org/argouml/ui/targetmanager/TargetManager.java&p2=trunk/src_new/org/argouml/ui/targetmanager/TargetManager.java&r1=13344&r2=13345
==============================================================================
--- trunk/src_new/org/argouml/ui/targetmanager/TargetManager.java	(original)
+++ trunk/src_new/org/argouml/ui/targetmanager/TargetManager.java	2007-08-14 11:07:10-0700
@@ -581,6 +581,10 @@
      * @param target the target to be added.
      */
     public synchronized void addTarget(Object target) {
+        if (target instanceof TargetListener) {
+            LOG.warn("addTarget method received a TargetListener, "
+                    + "perhaps addTargetListener was intended! - " + target);
+        }
 	if (isInTargetTransaction()) {
             return;
         }

Modified: trunk/src_new/org/argouml/uml/ui/TabProps.java
Url: http://argouml.tigris.org/source/browse/argouml/trunk/src_new/org/argouml/uml/ui/TabProps.java?view=diff&rev=13345&p1=trunk/src_new/org/argouml/uml/ui/TabProps.java&p2=trunk/src_new/org/argouml/uml/ui/TabProps.java&r1=13344&r2=13345
==============================================================================
--- trunk/src_new/org/argouml/uml/ui/TabProps.java	(original)
+++ trunk/src_new/org/argouml/uml/ui/TabProps.java	2007-08-14 11:07:10-0700
@@ -191,7 +191,7 @@
      */
     public TabProps(String tabName, String panelClassBase) {
         super(tabName);
-        TargetManager.getInstance().addTarget(this);
+        TargetManager.getInstance().addTargetListener(this);
         setOrientation(ConfigLoader.getTabPropsOrientation());
         panelClassBaseName = panelClassBase;
         setLayout(new BorderLayout());
lmpx.com only provides a reader for public news (NNTP) servers. It is not affiliated with the servers or forums shown here and is not responsible for the content of articles, which is written by their respective authors.