Subversion Repositories general

Rev

Details | Last modification | View Log | RSS feed

Rev Author Line No. Line
240 swalkenh 1
PK
348 swalkenh 2
 
3
 
240 swalkenh 4
Comment: this plugin is/was used during testing
5
Transform-To-File: src/plugins/dummyPlugin/DummyPluginTransform.xsl
6
Created-By: 1.4.0 (Sun Microsystems Inc.)
7
Description: ...(todo)
8
XMLEditor-Plugin-Name: dummy plugin
9
Class-Path: 
10
Transform-Fro-File: src/plugins/dummyPlugin/DummyPluginTransformBack.x
11
 sl
12
Main-Class: src.plugins.dummyPlugin.DummyPlugin
13
 
14
Name: src/plugins/dummyPlugin
15
Specification-Version: 0.4 (05/07/03)
16
Specification-Title: plugin for XMLEditor
17
Implementation-Version: 0.2 (05/07/03)
18
Implementation-Title: src.plugins.dummyPlugin
19
Implementation-Vendor: group5, software practice SS_2003, University B
20
 ielefeld, Germany
21
Specification-Vendor: group5, software practice SS_2003, University Bi
22
 elefeld, Germany
23
 
24
PK
348 swalkenh 25
 
26
 
27
 
28
 
29
 
30
 
31
 
32
 
33
 
34
 
35
	Isrc/gui/GuiInterfaceKsetPluginPanel(Ljavax/swing/JPanel;)VMNLOdummy plugin initializedQstart.(Lorg/w3c/dom/Element;Lorg/w3c/dom/Document;)Vjava/lang/StringBufferUgetText()Ljava/lang/String;WX
36
 
37
 
38
 
39
 
40
 
41
 
42
 
43
 
44
 
45
 
46
w…
setPluginMenu(Ljavax/swing/JMenu;)V‡ˆL‰dummy plugin has started‹elementenvironmentLorg/w3c/dom/Document;	dummyMenuLjavax/swing/JMenu;	dummyItemLjavax/swing/JMenuItem;stopsetOurEventListener!(Lsrc/control/OurEventListener;)V	—newListenerforceStatusReportfirePluginChangedElement-(Lorg/w3c/dom/Element;Lorg/w3c/dom/Element;)V›œ
47
 
48
 
49
 
50
SourceFileDummyPlugin.java!	
51
 
52
 
53
>@3A8CBDMESFZGdIlJD4mEFmmŽB+‘M ’“”B*¶5*´J¹Š±CQRSDEF•–>*+µ˜±C
54
 
55
bcD
EF›œo» Y½¢Y+SY,S·¥N*´˜-¹«±CghiD*EF¬­®¯°±U+¶¶|¦*»Y¸·º¶/±Cp	qsDEF»¼½¾PK
56
 
57
 
58
 
59
 
60
 
61
*/
62
 
63
 
64
 
65
import java.awt.*;
66
import java.awt.event.*;
67
68
import javax.swing.*;
69
70
 
71
72
 
73
import src.control.OurEventListener;
74
import src.gui.*;
75
 
76
77
 
78
/**
79
 
80
 * 
81
 * TODO should not be visible after 'init' (only after 'start')
82
 */
83
public class DummyPlugin extends JPanel
84
 
85
 
86
	private GuiInterface gui;
87
	private OurEventListener ourEventListener;
88
	
89
	private JLabel label = new JLabel("dummy plugin");
90
	private Element originalElement = null;
91
92
93
 
94
		setLayout(new BorderLayout());
95
		add(label, BorderLayout.CENTER);
96
 
97
98
		System.out.println("I'm a new instance of the dumb dummy-plugin!");
99
 
100
 
101
102
	/* (non-Javadoc)
103
	 * @see src.gui.PluginInterface#init(src.gui.GuiInterface)
104
	 */
105
 
106
		this.gui = gui;
107
		gui.setPluginPanel(this);
108
 
109
 
110
	}
111
112
113
	/* (non-Javadoc)
114
	 * @see src.gui.PluginInterface#start(org.w3c.dom.Element, org.w3c.dom.Document)
115
	 */
116
 
117
		originalElement = element; 
118
		
119
 
120
 
121
		
122
		JMenu dummyMenu = new JMenu("dummy plugin");
123
		JMenuItem dummyItem = new JMenuItem("dummy Item");
124
		dummyItem.addActionListener(this);
125
		dummyMenu.add(dummyItem);
126
 
127
		
128
		System.out.println("dummy plugin has started");
129
 
130
131
132
	/* (non-Javadoc)
133
	 * @see src.gui.PluginInterface#stop()
134
	 */
135
 
136
		setVisible(false);
137
		gui.setPluginMenu(null);
138
 
139
 
140
141
	/* (non-Javadoc)
142
	 * @see src.gui.PluginInterface#setOurEventListener(src.control.OurEventListener)
143
	 */
144
	public void setOurEventListener(OurEventListener newListener) {
145
		ourEventListener = newListener;
146
	}
147
 
148
 
149
	/* (non-Javadoc)
150
	 * @see src.gui.PluginInterface#forceStatusReport()
151
	 */
152
	public void forceStatusReport() {
153
		firePluginChangedElement(originalElement, originalElement);
154
	}
155
 
156
 
157
	private void firePluginChangedElement(Element oldNode, Element changedElement) {
158
		OurEvent e = new OurEvent(new Object[] {oldNode, changedElement});
159
		ourEventListener.firedOurEvent(e);
160
	}
161
162
163
 
164
 
165
	 */
166
	public void actionPerformed(ActionEvent arg0) {
167
		if (arg0.getActionCommand() == "dummy Item") {
168
			add(new JLabel("dummy Item in Menu clicked"), BorderLayout.NORTH);
169
 
170
 
171
172
}PK
173
]ç.Šv:··3src/plugins/dummyPlugin/DummyPluginManifestAdditionXMLEditor-Plugin-Name: dummy plugin
174
Comment: this plugin is/was used during testing
175
Description: ...(todo)
176
Main-Class: src.plugins.dummyPlugin.DummyPlugin
177
Class-Path: 
178
Transform-To-File: src/plugins/dummyPlugin/DummyPluginTransform.xsl
179
 
240 swalkenh 180
348 swalkenh 181
 
182
Specification-Title: plugin for XMLEditor
183
Specification-Version: 0.4 (05/07/03)
184
Specification-Vendor: group5, software practice SS_2003, University Bielefeld, Germany
185
Implementation-Title: src.plugins.dummyPlugin
186
Implementation-Version: 0.2 (05/07/03)
187
Implementation-Vendor: group5, software practice SS_2003, University Bielefeld, Germany
188
 
189
]ç.ÔʬþTT0src/plugins/dummyPlugin/DummyPluginTransform.xsl<!-- status: testing for dummy plugin -->
190
<xsl:stylesheet version="1.0" xmlns:xsl="http://www.w3.org/1999/XSL/Transform">
191
<xsl:output method="xml" indent="yes" />
192
193
<!-- simply copy the whole document -->
194
<xsl:template match="/"><!-- element-plugin association -->
195
	<xsl:copy-of select="node()" />
196
</xsl:template>
197
 
198
</xsl:stylesheet>PK
199
]ç.ÔʬþTT4src/plugins/dummyPlugin/DummyPluginTransformBack.xsl<!-- status: testing for dummy plugin -->
200
 
201
<xsl:output method="xml" indent="yes" />
202
203
<!-- simply copy the whole document -->
204
<xsl:template match="/"><!-- element-plugin association -->
205
 
240 swalkenh 206
</xsl:template>
348 swalkenh 207
 
208
</xsl:stylesheet>PK
209
210
 
211
212
mVë.­ª#+META-INF/MANIFEST.MFPK
213
214
Y<ë.asrc/plugins/dummyPlugin/CVS/PK
215
 
240 swalkenh 216
Të.ÑÊ:öó
ó
)›src/plugins/dummyPlugin/DummyPlugin.classPK
217
 
348 swalkenh 218
 
240 swalkenh 219
 
348 swalkenh 220
 
240 swalkenh 221
 
348 swalkenh 222
 
240 swalkenh 223
 
348 swalkenh 224