Author: tchemit Date: 2008-01-21 21:59:42 +0000 (Mon, 21 Jan 2008) New Revision: 345 Removed: trunk/simexplorer-is-swing/src/java/fr/cemagref/simexplorer/is/ui/swing/util/ActionConfig.java trunk/simexplorer-is-swing/src/java/fr/cemagref/simexplorer/is/ui/swing/util/GlueActionConfig.java trunk/simexplorer-is-swing/src/java/fr/cemagref/simexplorer/is/ui/swing/util/SelectActionConfig.java trunk/simexplorer-is-swing/src/java/fr/cemagref/simexplorer/is/ui/swing/util/TabContent.java trunk/simexplorer-is-swing/src/java/fr/cemagref/simexplorer/is/ui/swing/util/UIHelper.java Log: deplacement dans jaxx Deleted: trunk/simexplorer-is-swing/src/java/fr/cemagref/simexplorer/is/ui/swing/util/ActionConfig.java =================================================================== --- trunk/simexplorer-is-swing/src/java/fr/cemagref/simexplorer/is/ui/swing/util/ActionConfig.java 2008-01-21 21:59:11 UTC (rev 344) +++ trunk/simexplorer-is-swing/src/java/fr/cemagref/simexplorer/is/ui/swing/util/ActionConfig.java 2008-01-21 21:59:42 UTC (rev 345) @@ -1,122 +0,0 @@ -/* -* ##% Copyright (C) 2002, 2003, 2004, 2005, 2006, 2007, 2008 Code Lutin, -* Tony Chemit, Gabriel Landais -* -* This program is free software; you can redistribute it and/or -* modify it under the terms of the GNU General Public License -* as published by the Free Software Foundation; either version 2 -* of the License, or (at your option) any later version. -* -* This program is distributed in the hope that it will be useful, -* but WITHOUT ANY WARRANTY; without even the implied warranty of -* MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the -* GNU General Public License for more details. -* -* You should have received a copy of the GNU General Public License -* along with this program; if not, write to the Free Software -* Foundation, Inc., 59 Temple Place - Suite 330, Boston, MA 02111-1307, USA. -* ##% */ -package fr.cemagref.simexplorer.is.ui.swing.util; - -import jaxx.runtime.JAXXObject; - -import java.lang.annotation.ElementType; -import java.lang.annotation.Retention; -import java.lang.annotation.RetentionPolicy; -import java.lang.annotation.Target; - -/** - * Pour enregister une action. - * <p/> - * Placer cette annotation sur la classe implantant l'action, - * <p/> - * les informations décrites seront utilisées pour instancier l'action - * - * @author chemit - */ - at Retention(RetentionPolicy.RUNTIME) - - at Target(ElementType.TYPE) - -public @interface ActionConfig { - - /** - * @return la clef de la commande (doit être unique) - * @see javax.swing.Action#ACTION_COMMAND_KEY - */ - String actionCommand(); - - /** - * @return la clef i18n du texte de l'action, si vide ignoré - * @see javax.swing.Action#NAME - */ - String name() default ""; - - /** - * @return la clef i18n du tooltip de l'action, si vide ignoré - * @see javax.swing.Action#SHORT_DESCRIPTION - */ - String shortDescription() default ""; - - /** - * @return la clef i18n du texte de l'action, si vide ignoré - * @see javax.swing.Action#LONG_DESCRIPTION - */ - String longDescription() default ""; - - /** - * @return le nom de l'icone associé, si vide ignoré - * @see javax.swing.Action#SMALL_ICON - */ - String smallIcon() default ""; - - /** - * @return le nom du grande icone associé, si vide ignoré - * @see javax.swing.Action#LARGE_ICON_KEY - */ - String largeIcon() default ""; - - /** - * @return - * @see javax.swing.Action#ACCELERATOR_KEY - */ - String accelerator() default ""; - - /** - * @return - * @see javax.swing.Action#MNEMONIC_KEY - */ - int mnemonic() default '\0'; - - /** - * @return - * @see javax.swing.Action#DISPLAYED_MNEMONIC_INDEX_KEY - */ - int displayedMnemonicIndex() default '\0'; - - /** - * @return la valeur par défaut pour les component selectable - * @see javax.swing.Action#SELECTED_KEY - */ - boolean selected() default false; - - /** - * @return - * @see javax.swing.Action#isEnabled() - */ - boolean enabled() default true; - - /** - * @return - * @see javax.swing.Action#isEnabled() - */ - boolean hideActionText() default false; - - - /** - * @return la class du container jaxx associé - * @see javax.swing.Action#NAME - */ - Class<? extends JAXXObject> container(); - -} \ No newline at end of file Deleted: trunk/simexplorer-is-swing/src/java/fr/cemagref/simexplorer/is/ui/swing/util/GlueActionConfig.java =================================================================== --- trunk/simexplorer-is-swing/src/java/fr/cemagref/simexplorer/is/ui/swing/util/GlueActionConfig.java 2008-01-21 21:59:11 UTC (rev 344) +++ trunk/simexplorer-is-swing/src/java/fr/cemagref/simexplorer/is/ui/swing/util/GlueActionConfig.java 2008-01-21 21:59:42 UTC (rev 345) @@ -1,157 +0,0 @@ -/* -* ##% Copyright (C) 2002, 2003, 2004, 2005, 2006, 2007, 2008 Code Lutin, -* Tony Chemit, Gabriel Landais -* -* This program is free software; you can redistribute it and/or -* modify it under the terms of the GNU General Public License -* as published by the Free Software Foundation; either version 2 -* of the License, or (at your option) any later version. -* -* This program is distributed in the hope that it will be useful, -* but WITHOUT ANY WARRANTY; without even the implied warranty of -* MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the -* GNU General Public License for more details. -* -* You should have received a copy of the GNU General Public License -* along with this program; if not, write to the Free Software -* Foundation, Inc., 59 Temple Place - Suite 330, Boston, MA 02111-1307, USA. -* ##% */ -package fr.cemagref.simexplorer.is.ui.swing.util; - -import jaxx.runtime.JAXXObject; - -import java.lang.annotation.ElementType; -import java.lang.annotation.Retention; -import java.lang.annotation.RetentionPolicy; -import java.lang.annotation.Target; - -/** - * Pour enregister une action de type Glue (ToggleButton). - * <p/> - * Placer cette annotation sur la classe implantant l'action, - * <p/> - * les informations décrites seront utilisées pour instancier l'action - * - * @author chemit - */ - at Retention(RetentionPolicy.RUNTIME) - - at Target(ElementType.TYPE) - -public @interface GlueActionConfig { - /** - * @return la clef de la commande (doit être unique) - * @see javax.swing.Action#ACTION_COMMAND_KEY - */ - public abstract String actionCommand(); - - /** - * @return la clef i18n du texte de l'action, si vide ignoré - * @see javax.swing.Action#NAME - */ - public abstract String name() default ""; - - /** - * @return la clef i18n du tooltip de l'action, si vide ignoré - * @see javax.swing.Action#SHORT_DESCRIPTION - */ - public abstract String shortDescription() default ""; - - /** - * @return la clef i18n du texte de l'action, si vide ignoré - * @see javax.swing.Action#LONG_DESCRIPTION - */ - public abstract String longDescription() default ""; - - /** - * @return le nom de l'icone associé, si vide ignoré - * @see javax.swing.Action#SMALL_ICON - */ - public abstract String smallIcon() default ""; - - /** - * @return le nom du grande icone associé, si vide ignoré - * @see javax.swing.Action#LARGE_ICON_KEY - */ - public abstract String largeIcon() default ""; - - /** - * @return - * @see javax.swing.Action#ACCELERATOR_KEY - */ - public abstract String accelerator() default ""; - - /** - * @return - * @see javax.swing.Action#MNEMONIC_KEY - */ - public abstract int mnemonic() default '\0'; - - /** - * @return la clef i18n du texte de l'action, si vide ignoré - * @see javax.swing.Action#NAME - */ - public abstract String name2() default ""; - - /** - * @return la clef i18n du tooltip de l'action, si vide ignoré - * @see javax.swing.Action#SHORT_DESCRIPTION - */ - public abstract String shortDescription2() default ""; - - /** - * @return la clef i18n du texte de l'action, si vide ignoré - * @see javax.swing.Action#LONG_DESCRIPTION - */ - public abstract String longDescription2() default ""; - - /** - * @return le nom de l'icone associé, si vide ignoré - * @see javax.swing.Action#SMALL_ICON - */ - public abstract String smallIcon2() default ""; - - /** - * @return le nom du grande icone associé, si vide ignoré - * @see javax.swing.Action#LARGE_ICON_KEY - */ - public abstract String largeIcon2() default ""; - - /** - * @return - * @see javax.swing.Action#ACCELERATOR_KEY - */ - public abstract String accelerator2() default ""; - - /** - * @return - * @see javax.swing.Action#MNEMONIC_KEY - */ - public abstract int mnemonic2() default '\0'; - - /** - * @return la valeur par défaut pour les component selectable - * @see javax.swing.Action#SELECTED_KEY - */ - public abstract boolean selected() default false; - - /** - * @return - * @see javax.swing.Action#isEnabled() - */ - public abstract boolean enabled() default true; - - /** - * @return - * @see javax.swing.Action#isEnabled() - */ - public abstract boolean hideActionText() default false; - - - /** - * @return la class du container jaxx associé - * @see javax.swing.Action#NAME - */ - public abstract Class<? extends JAXXObject> container(); - -} \ No newline at end of file Deleted: trunk/simexplorer-is-swing/src/java/fr/cemagref/simexplorer/is/ui/swing/util/SelectActionConfig.java =================================================================== --- trunk/simexplorer-is-swing/src/java/fr/cemagref/simexplorer/is/ui/swing/util/SelectActionConfig.java 2008-01-21 21:59:11 UTC (rev 344) +++ trunk/simexplorer-is-swing/src/java/fr/cemagref/simexplorer/is/ui/swing/util/SelectActionConfig.java 2008-01-21 21:59:42 UTC (rev 345) @@ -1,91 +0,0 @@ -/* -* ##% Copyright (C) 2002, 2003, 2004, 2005, 2006, 2007, 2008 Code Lutin, -* Tony Chemit, Gabriel Landais -* -* This program is free software; you can redistribute it and/or -* modify it under the terms of the GNU General Public License -* as published by the Free Software Foundation; either version 2 -* of the License, or (at your option) any later version. -* -* This program is distributed in the hope that it will be useful, -* but WITHOUT ANY WARRANTY; without even the implied warranty of -* MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the -* GNU General Public License for more details. -* -* You should have received a copy of the GNU General Public License -* along with this program; if not, write to the Free Software -* Foundation, Inc., 59 Temple Place - Suite 330, Boston, MA 02111-1307, USA. -* ##% */ -package fr.cemagref.simexplorer.is.ui.swing.util; - -import jaxx.runtime.JAXXObject; - -import java.lang.annotation.ElementType; -import java.lang.annotation.Retention; -import java.lang.annotation.RetentionPolicy; -import java.lang.annotation.Target; - -/** - * Pour enregister une action. - * <p/> - * Placer cette annotation sur la classe implantant l'action, - * <p/> - * les informations décrites seront utilisées pour instancier l'action - * - * @author chemit - */ - at Retention(RetentionPolicy.RUNTIME) - - at Target(ElementType.TYPE) - -public @interface SelectActionConfig { - - /** - * @return la clef de la commande (doit être unique) - * @see javax.swing.Action#ACTION_COMMAND_KEY - */ - public abstract String actionCommand(); - - /** - * @return la clef i18n du texte de l'action, si vide ignoré - * @see javax.swing.Action#NAME - */ - public abstract String name() default ""; - - /** - * @return la clef i18n du tooltip de l'action, si vide ignoré - * @see javax.swing.Action#SHORT_DESCRIPTION - */ - public abstract String shortDescription() default ""; - - /** - * @return la clef i18n du texte de l'action, si vide ignoré - * @see javax.swing.Action#LONG_DESCRIPTION - */ - public abstract String longDescription() default ""; - - /** - * @return - * @see javax.swing.Action#ACCELERATOR_KEY - */ - public abstract String accelerator() default ""; - - /** - * @return la valeur par défaut pour les component selectable - * @see javax.swing.Action#SELECTED_KEY - */ - public abstract int selectedIndex() default 0; - - /** - * @return - * @see javax.swing.Action#isEnabled() - */ - public abstract boolean enabled() default true; - - /** - * @return la class du container jaxx associé - * @see javax.swing.Action#NAME - */ - public abstract Class<? extends JAXXObject> container(); - -} \ No newline at end of file Deleted: trunk/simexplorer-is-swing/src/java/fr/cemagref/simexplorer/is/ui/swing/util/TabContent.java =================================================================== --- trunk/simexplorer-is-swing/src/java/fr/cemagref/simexplorer/is/ui/swing/util/TabContent.java 2008-01-21 21:59:11 UTC (rev 344) +++ trunk/simexplorer-is-swing/src/java/fr/cemagref/simexplorer/is/ui/swing/util/TabContent.java 2008-01-21 21:59:42 UTC (rev 345) @@ -1,47 +0,0 @@ -/* -* ##% Copyright (C) 2002, 2003, 2004, 2005, 2006, 2007, 2008 Code Lutin, -* Tony Chemit, Gabriel Landais -* -* This program is free software; you can redistribute it and/or -* modify it under the terms of the GNU General Public License -* as published by the Free Software Foundation; either version 2 -* of the License, or (at your option) any later version. -* -* This program is distributed in the hope that it will be useful, -* but WITHOUT ANY WARRANTY; without even the implied warranty of -* MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the -* GNU General Public License for more details. -* -* You should have received a copy of the GNU General Public License -* along with this program; if not, write to the Free Software -* Foundation, Inc., 59 Temple Place - Suite 330, Boston, MA 02111-1307, USA. -* ##% */ -package fr.cemagref.simexplorer.is.ui.swing.util; - -import javax.swing.JComponent; -import javax.swing.JTabbedPane; -import java.lang.annotation.ElementType; -import java.lang.annotation.Retention; -import java.lang.annotation.RetentionPolicy; -import java.lang.annotation.Target; - -/** - * Pour enregister un tab - * - * @author chemit - */ - at Retention(RetentionPolicy.RUNTIME) - - at Target(ElementType.FIELD) - -public @interface TabContent { - - //String name(); - - Class<? extends JComponent> impl(); - - Class<? extends JTabbedPane> parentImpl(); - - boolean useToogle() default false; - -} Deleted: trunk/simexplorer-is-swing/src/java/fr/cemagref/simexplorer/is/ui/swing/util/UIHelper.java =================================================================== --- trunk/simexplorer-is-swing/src/java/fr/cemagref/simexplorer/is/ui/swing/util/UIHelper.java 2008-01-21 21:59:11 UTC (rev 344) +++ trunk/simexplorer-is-swing/src/java/fr/cemagref/simexplorer/is/ui/swing/util/UIHelper.java 2008-01-21 21:59:42 UTC (rev 345) @@ -1,35 +0,0 @@ -/* -* ##% Copyright (C) 2002, 2003, 2004, 2005, 2006, 2007, 2008 Code Lutin, -* Tony Chemit -* -* This program is free software; you can redistribute it and/or -* modify it under the terms of the GNU General Public License -* as published by the Free Software Foundation; either version 2 -* of the License, or (at your option) any later version. -* -* This program is distributed in the hope that it will be useful, -* but WITHOUT ANY WARRANTY; without even the implied warranty of -* MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the -* GNU General Public License for more details. -* -* You should have received a copy of the GNU General Public License -* along with this program; if not, write to the Free Software -* Foundation, Inc., 59 Temple Place - Suite 330, Boston, MA 02111-1307, USA. -* ##% */ -package fr.cemagref.simexplorer.is.ui.swing.util; - -import javax.swing.ImageIcon; - -/** @author tony */ -public class UIHelper { - - public static ImageIcon createImageIcon(String path) { - java.net.URL imgURL = UIHelper.class.getResource("/icons/" + path); - if (imgURL != null) { - return new ImageIcon(imgURL); - } else { - throw new RuntimeException("could not foind icon " + path); - } - } - -}