Revision 670 trunk/org.gvsig.app.document.layout2.app/org.gvsig.app.document.layout2.app.mainplugin/src/main/java/org/gvsig/app/project/documents/layout/fframes/gui/dialogs/FFrameGraphicsDialog.java
FFrameGraphicsDialog.java | ||
---|---|---|
28 | 28 |
|
29 | 29 |
import org.slf4j.Logger; |
30 | 30 |
import org.slf4j.LoggerFactory; |
31 |
|
|
31 | 32 |
import org.gvsig.andami.PluginServices; |
32 | 33 |
import org.gvsig.andami.ui.mdiManager.WindowInfo; |
33 | 34 |
import org.gvsig.app.gui.styling.SymbolSelector; |
35 |
import org.gvsig.app.project.documents.layout.LayoutContext; |
|
34 | 36 |
import org.gvsig.app.project.documents.layout.fframes.FFrameGraphics; |
35 | 37 |
import org.gvsig.app.project.documents.layout.fframes.IFFrame; |
36 | 38 |
import org.gvsig.app.project.documents.layout.fframes.gui.JPRotation; |
... | ... | |
39 | 41 |
import org.gvsig.gui.beans.swing.GridBagLayoutPanel; |
40 | 42 |
import org.gvsig.tools.observer.ObservableHelper; |
41 | 43 |
import org.gvsig.tools.observer.Observer; |
44 |
import org.gvsig.tools.swing.api.ActionListenerSupport; |
|
42 | 45 |
|
43 | 46 |
/** |
44 | 47 |
* Di?logo de las propiedades de los gr?ficos. |
45 |
*
|
|
48 |
* |
|
46 | 49 |
* @author Vicente Caballero Navarro |
47 | 50 |
*/ |
48 | 51 |
public class FFrameGraphicsDialog extends SymbolSelector implements |
... | ... | |
54 | 57 |
.getLogger(FFrameGraphicsDialog.class); |
55 | 58 |
|
56 | 59 |
private Rectangle2D rect = new Rectangle2D.Double(); |
57 |
private LayoutPanel m_layout = null;
|
|
60 |
private LayoutPanel m_layout = null; |
|
58 | 61 |
|
59 | 62 |
private boolean isAcepted = false; |
60 | 63 |
private FFrameGraphics fframegraphics = null; |
... | ... | |
62 | 65 |
private FFrameGraphics newFFrameGraphics; |
63 | 66 |
private ObservableHelper observableHelper = new ObservableHelper(); |
64 | 67 |
|
68 |
private ActionListenerSupport actionListenerSupportHelper; |
|
65 | 69 |
|
66 | 70 |
public FFrameGraphicsDialog(LayoutPanel layout, FFrameGraphics fframe) { |
67 | 71 |
super(fframe.getFSymbol(), fframe.getType(), null, true); |
... | ... | |
95 | 99 |
} |
96 | 100 |
} |
97 | 101 |
}; |
98 |
|
|
102 |
|
|
99 | 103 |
ActionListener cancelAction = new ActionListener() { |
100 | 104 |
public void actionPerformed(ActionEvent e) { |
101 | 105 |
isAcepted = false; |
102 | 106 |
FFrameGraphicsDialog.this.notifyDialogClosed(); |
103 | 107 |
} |
104 | 108 |
}; |
105 |
|
|
109 |
|
|
106 | 110 |
okCancelPanel.addOkButtonActionListener(okAction); |
107 | 111 |
okCancelPanel.addCancelButtonActionListener(cancelAction); |
108 | 112 |
} |
... | ... | |
121 | 125 |
WindowInfo m_viewinfo = new WindowInfo(WindowInfo.MODALDIALOG); |
122 | 126 |
m_viewinfo |
123 | 127 |
.setTitle(PluginServices.getText(this, "propiedades_grafico")); |
124 |
|
|
128 |
|
|
125 | 129 |
m_viewinfo.setWidth(650); |
126 | 130 |
m_viewinfo.setHeight(625); |
127 |
|
|
128 | 131 |
|
132 |
|
|
129 | 133 |
return m_viewinfo; |
130 | 134 |
} |
131 | 135 |
|
... | ... | |
147 | 151 |
* @see com.iver.mdiApp.ui.MDIManager.IWindow#windowActivated() |
148 | 152 |
*/ |
149 | 153 |
public void viewActivated() { |
150 |
|
|
154 |
|
|
151 | 155 |
} |
152 | 156 |
|
153 | 157 |
/** |
154 | 158 |
* This method initializes pRotation |
155 |
*
|
|
159 |
* |
|
156 | 160 |
* @return javax.swing.JPanel |
157 | 161 |
*/ |
158 | 162 |
private JPRotation getPRotation() { |
... | ... | |
166 | 170 |
public IFFrame getFFrame() { |
167 | 171 |
return newFFrameGraphics; |
168 | 172 |
} |
169 |
|
|
170 | 173 |
|
174 |
|
|
171 | 175 |
public void addObserver(Observer observer) { |
172 | 176 |
observableHelper.addObserver(observer); |
173 | 177 |
} |
... | ... | |
179 | 183 |
public void deleteObservers() { |
180 | 184 |
observableHelper.deleteObservers(); |
181 | 185 |
} |
182 |
|
|
186 |
|
|
183 | 187 |
protected void notifyDialogClosed() { |
184 | 188 |
observableHelper.notifyObservers(this, new FFrameDialogNotification(FFrameDialogNotification.DIALOG_CLOSED)); |
185 | 189 |
} |
186 |
} |
|
190 |
|
|
191 |
@Override |
|
192 |
public void addActionListener(ActionListener listener) { |
|
193 |
actionListenerSupportHelper.addActionListener(listener); |
|
194 |
|
|
195 |
} |
|
196 |
|
|
197 |
@Override |
|
198 |
public ActionListener[] getActionListeners() { |
|
199 |
return actionListenerSupportHelper.getActionListeners(); |
|
200 |
} |
|
201 |
|
|
202 |
@Override |
|
203 |
public void removeActionListener(ActionListener listener) { |
|
204 |
actionListenerSupportHelper.removeActionListener(listener); |
|
205 |
|
|
206 |
} |
|
207 |
|
|
208 |
@Override |
|
209 |
public void removeAllActionListener() { |
|
210 |
actionListenerSupportHelper.removeAllActionListener(); |
|
211 |
|
|
212 |
} |
|
213 |
|
|
214 |
@Override |
|
215 |
public void fireActionEvent(ActionEvent event) { |
|
216 |
actionListenerSupportHelper.fireActionEvent(event); |
|
217 |
} |
|
218 |
} |
Also available in: Unified diff