From: <fle...@us...> - 2007-03-23 13:36:25
|
Revision: 615 http://svn.sourceforge.net/magicmap/?rev=615&view=rev Author: flederohr Date: 2007-03-23 06:36:21 -0700 (Fri, 23 Mar 2007) Log Message: ----------- formating with codingconventions Modified Paths: -------------- trunk/magicmapclient/src/net/sf/magicmap/client/plugin/action/ShowPluginsAction.java trunk/magicmapclient/src/net/sf/magicmap/client/plugin/forms/PluginsForm.java Modified: trunk/magicmapclient/src/net/sf/magicmap/client/plugin/action/ShowPluginsAction.java =================================================================== --- trunk/magicmapclient/src/net/sf/magicmap/client/plugin/action/ShowPluginsAction.java 2007-03-23 13:34:29 UTC (rev 614) +++ trunk/magicmapclient/src/net/sf/magicmap/client/plugin/action/ShowPluginsAction.java 2007-03-23 13:36:21 UTC (rev 615) @@ -1,3 +1,4 @@ + package net.sf.magicmap.client.plugin.action; import java.awt.event.ActionEvent; @@ -18,19 +19,21 @@ * To change this template use File | Settings | File Templates. */ public class ShowPluginsAction extends MagicAction { - private final JFrame mainFrame; - private final net.sf.magicmap.client.plugin.PluginManager manager; - public ShowPluginsAction(JFrame mainFrame, PluginManager manager){ - super ("plugins.show", GUIConstants.ICON_PROPERTIES, "plugins.show.tooltip"); - this.mainFrame = mainFrame; - this.manager = manager; - } - public void actionPerformed(ActionEvent e) { - JDialog dlg = new JDialog(mainFrame); - dlg.setModal(true); - dlg.setContentPane(manager.visualProxy("", null)); - dlg.pack(); - dlg.setVisible(true); - } + private final JFrame mainFrame; + private final net.sf.magicmap.client.plugin.PluginManager manager; + + public ShowPluginsAction(JFrame mainFrame, PluginManager manager) { + super("plugins.show", GUIConstants.ICON_PROPERTIES, "plugins.show.tooltip"); + this.mainFrame = mainFrame; + this.manager = manager; + } + + public void actionPerformed(ActionEvent e){ + JDialog dlg = new JDialog(mainFrame); + dlg.setModal(true); + dlg.setContentPane(manager.visualProxy("", null)); + dlg.pack(); + dlg.setVisible(true); + } } Modified: trunk/magicmapclient/src/net/sf/magicmap/client/plugin/forms/PluginsForm.java =================================================================== --- trunk/magicmapclient/src/net/sf/magicmap/client/plugin/forms/PluginsForm.java 2007-03-23 13:34:29 UTC (rev 614) +++ trunk/magicmapclient/src/net/sf/magicmap/client/plugin/forms/PluginsForm.java 2007-03-23 13:36:21 UTC (rev 615) @@ -1,3 +1,4 @@ + package net.sf.magicmap.client.plugin.forms; import static net.sf.magicmap.client.plugin.PluginManager.Attributes.AvailablePlugins; @@ -32,47 +33,48 @@ */ public final class PluginsForm extends FormLayoutForm { - private TabForm tabs; - private Form settingsForm; - private Form detailsForm; + private TabForm tabs; + private Form settingsForm; + private Form detailsForm; - /** - */ - public PluginsForm(final PluginManager manager){ - super ("p:grow,3dlu,p:grow", "p,3dlu, p:grow"); - tabs = new TabForm(); - tabs.addAttribute(AvailablePlugins.getName(), "", - new TabForm.TabConstraints(GUIUtils.i18n("plugins.available"), "TT", null)); - tabs.addAttribute(InstalledPlugins.getName(), "", - new TabForm.TabConstraints(GUIUtils.i18n("plugins.installed"), "TT", null)); - addForm(tabs, new CellConstraints(1,3, CellConstraints.FILL, CellConstraints.FILL)); + /** + */ + public PluginsForm(final PluginManager manager) { + super("p:grow,3dlu,p:grow", "p,3dlu, p:grow"); + tabs = new TabForm(); + tabs.addAttribute(AvailablePlugins.getName(), "", new TabForm.TabConstraints( + GUIUtils.i18n("plugins.available"), "TT", null)); + tabs.addAttribute(InstalledPlugins.getName(), "", new TabForm.TabConstraints( + GUIUtils.i18n("plugins.installed"), "TT", null)); + addForm(tabs, new CellConstraints(1, 3, CellConstraints.FILL, CellConstraints.FILL)); - detailsForm = new FormLayoutForm("p,3dlu,p:grow", "p,3dlu,p:grow"); - detailsForm.addLabel(PluginName.getName(), new JLabel(GUIUtils.i18n("plugins.name")), new CellConstraints(1,1)); - detailsForm.addAttribute(PluginName.getName(), "", new CellConstraints(3,1)); - detailsForm.addLabel(PluginDependencies.getName(), new JLabel(GUIUtils.i18n("plugins.dependencies")), new CellConstraints(1,3)); - detailsForm.addAttribute(PluginDependencies.getName(), "", new CellConstraints(3,3)); + detailsForm = new FormLayoutForm("p,3dlu,p:grow", "p,3dlu,p:grow"); + detailsForm + .addLabel(PluginName.getName(), new JLabel(GUIUtils.i18n("plugins.name")), new CellConstraints(1, 1)); + detailsForm.addAttribute(PluginName.getName(), "", new CellConstraints(3, 1)); + detailsForm.addLabel(PluginDependencies.getName(), new JLabel(GUIUtils.i18n("plugins.dependencies")), + new CellConstraints(1, 3)); + detailsForm.addAttribute(PluginDependencies.getName(), "", new CellConstraints(3, 3)); + detailsForm.setBorder(BorderFactory.createCompoundBorder(BorderFactory.createTitledBorder(GUIUtils + .i18n("plugins.detailview")), BorderFactory.createEmptyBorder(5, 5, 5, 5))); + addForm(detailsForm, new CellConstraints(3, 3, CellConstraints.FILL, CellConstraints.FILL)); + setBorder(BorderFactory.createCompoundBorder(BorderFactory.createTitledBorder("Plugin"), BorderFactory + .createEmptyBorder(5, 5, 5, 5))); - detailsForm.setBorder(BorderFactory.createCompoundBorder( - BorderFactory.createTitledBorder(GUIUtils.i18n("plugins.detailview")), - BorderFactory.createEmptyBorder(5,5,5,5))); - addForm(detailsForm, new CellConstraints(3,3, CellConstraints.FILL, CellConstraints.FILL)); - setBorder(BorderFactory.createCompoundBorder( - BorderFactory.createTitledBorder("Plugin"), - BorderFactory.createEmptyBorder(5,5,5,5))); + // Actions! + FormLayoutForm actionButton = new FormLayoutForm("p,3dlu,p,6dlu,p,3dlu,p:grow", "p"); + actionButton.addLabel("", new JButton(new net.sf.magicmap.client.plugin.action.InstallPluginAction(manager)), + new CellConstraints(1, 1)); + actionButton.addLabel("", new JButton(new UninstallPluginAction(manager)), new CellConstraints(3, 1)); + actionButton.addLabel("", new JButton(new LoadPluginsAction(manager)), new CellConstraints(5, 1, + CellConstraints.DEFAULT, CellConstraints.FILL)); + actionButton.addAttribute(PluginRepository.getName(), "", new CellConstraints(7, 1)); + addForm(actionButton, new CellConstraints(1, 1, 3, 1, CellConstraints.FILL, CellConstraints.FILL)); + } - // Actions! - FormLayoutForm actionButton = new FormLayoutForm("p,3dlu,p,6dlu,p,3dlu,p:grow", "p"); - actionButton.addLabel("", new JButton(new net.sf.magicmap.client.plugin.action.InstallPluginAction(manager)), new CellConstraints(1,1)); - actionButton.addLabel("", new JButton(new UninstallPluginAction(manager)), new CellConstraints(3,1)); - actionButton.addLabel("", new JButton(new LoadPluginsAction(manager)), new CellConstraints(5,1,CellConstraints.DEFAULT, CellConstraints.FILL)); - actionButton.addAttribute(PluginRepository.getName(), "", new CellConstraints(7,1)); - addForm(actionButton, new CellConstraints(1,1,3,1,CellConstraints.FILL, CellConstraints.FILL)); - } - - public JComponent attatch(UserInterface ui) { - JComponent c = super.attatch(ui); - return c; - } + public JComponent attatch(UserInterface ui){ + JComponent c = super.attatch(ui); + return c; + } } This was sent by the SourceForge.net collaborative development platform, the world's largest Open Source development site. |