nickdavis 01/06/21 09:01:58
Modified: src/java/org/apache/tools/ant/gui/core AntModule.java
Log:
add method "insertInto" which allows modules to update the main menu
Revision Changes Path
1.2 +11 -1
jakarta-ant-antidote/src/java/org/apache/tools/ant/gui/core/AntModule.java
Index: AntModule.java
===================================================================
RCS file:
/home/cvs/jakarta-ant-antidote/src/java/org/apache/tools/ant/gui/core/AntModule.java,v
retrieving revision 1.1
retrieving revision 1.2
diff -u -r1.1 -r1.2
--- AntModule.java 2001/04/08 23:42:11 1.1
+++ AntModule.java 2001/06/21 16:01:58 1.2
@@ -54,13 +54,14 @@
package org.apache.tools.ant.gui.core;
import javax.swing.JComponent;
+import javax.swing.JMenuBar;
import javax.swing.BorderFactory;
/**
* Abstract base class for a "module", which is really anything that
* can send or receive events, or edit or view the model.
*
- * @version $Revision: 1.1 $
+ * @version $Revision: 1.2 $
* @author Simeon Fitch
*/
public abstract class AntModule extends JComponent {
@@ -88,6 +89,15 @@
*/
public abstract void contextualize(AppContext context);
+ /**
+ * This method is called after the main menu bar has been created.
+ * It also the module to modify the main menu bar.
+ *
+ * @param menuBar Menu bar to insert into.
+ */
+ public void insertInto(JMenuBar menuBar) {
+ }
+
/**
* Set the application context.
*