diff --git a/cave/build/static/common/cave/etc/bundles/volume/ModelFamilyA.xml b/cave/build/static/common/cave/etc/bundles/volume/ModelFamilyA.xml index 7bfb35758e..ac3186ce95 100644 --- a/cave/build/static/common/cave/etc/bundles/volume/ModelFamilyA.xml +++ b/cave/build/static/common/cave/etc/bundles/volume/ModelFamilyA.xml @@ -59,7 +59,7 @@ ModFamA| |N|Conv: NonSupercell Tor Family| |OTHER | | \ PLAN_VIEW - + diff --git a/cave/build/static/common/cave/etc/bundles/volume/ModelFamilyB.xml b/cave/build/static/common/cave/etc/bundles/volume/ModelFamilyB.xml index dff95859dd..6589a91894 100644 --- a/cave/build/static/common/cave/etc/bundles/volume/ModelFamilyB.xml +++ b/cave/build/static/common/cave/etc/bundles/volume/ModelFamilyB.xml @@ -56,7 +56,7 @@ ModFamB| |N|Conv: Storm Init Family| |OTHER | | \ PLAN_VIEW - + @@ -188,7 +188,7 @@ ModFamB| |N|Conv: Storm Init Family| |OTHER | | \ PLAN_VIEW - + @@ -322,7 +322,7 @@ ModFamB| |N|Conv: Storm Init Family| |OTHER | | \ PLAN_VIEW - + @@ -488,7 +488,7 @@ ModFamB| |N|Conv: Storm Init Family| |OTHER | | \ PLAN_VIEW - + diff --git a/cave/build/static/common/cave/etc/bundles/volume/ModelFamilyC.xml b/cave/build/static/common/cave/etc/bundles/volume/ModelFamilyC.xml index 10a80f7b61..ab4de75eff 100644 --- a/cave/build/static/common/cave/etc/bundles/volume/ModelFamilyC.xml +++ b/cave/build/static/common/cave/etc/bundles/volume/ModelFamilyC.xml @@ -166,7 +166,7 @@ ModFamC| |N|Conv: Hail Family| |OTHER | | \ PLAN_VIEW - + diff --git a/cave/build/static/common/cave/etc/bundles/volume/ModelFamilyD.xml b/cave/build/static/common/cave/etc/bundles/volume/ModelFamilyD.xml index fb9cb3d22b..82af335064 100644 --- a/cave/build/static/common/cave/etc/bundles/volume/ModelFamilyD.xml +++ b/cave/build/static/common/cave/etc/bundles/volume/ModelFamilyD.xml @@ -70,7 +70,7 @@ ModFamD| |N|Winter: Family| |OTHER | | \ PLAN_VIEW - + @@ -169,7 +169,7 @@ ModFamD| |N|Winter: Family| |OTHER | | \ PLAN_VIEW - + @@ -268,7 +268,7 @@ ModFamD| |N|Winter: Family| |OTHER | | \ PLAN_VIEW - + @@ -367,7 +367,7 @@ ModFamD| |N|Winter: Family| |OTHER | | \ PLAN_VIEW - + @@ -466,7 +466,7 @@ ModFamD| |N|Winter: Family| |OTHER | | \ PLAN_VIEW - + @@ -702,7 +702,7 @@ ModFamD| |N|Winter: Family| |OTHER | | \ PLAN_VIEW - + @@ -981,7 +981,7 @@ ModFamD| |N|Winter: Family| |OTHER | | \ PLAN_VIEW - + @@ -1152,7 +1152,7 @@ ModFamD| |N|Winter: Family| |OTHER | | \ PLAN_VIEW - + @@ -1287,7 +1287,7 @@ ModFamD| |N|Winter: Family| |OTHER | | \ PLAN_VIEW - + @@ -1386,7 +1386,7 @@ ModFamD| |N|Winter: Family| |OTHER | | \ PLAN_VIEW - + @@ -1485,7 +1485,7 @@ ModFamD| |N|Winter: Family| |OTHER | | \ PLAN_VIEW - + diff --git a/cave/build/static/common/cave/etc/bundles/volume/ModelFamilyH.xml b/cave/build/static/common/cave/etc/bundles/volume/ModelFamilyH.xml index 6fbc209871..14ecfd1bfd 100644 --- a/cave/build/static/common/cave/etc/bundles/volume/ModelFamilyH.xml +++ b/cave/build/static/common/cave/etc/bundles/volume/ModelFamilyH.xml @@ -139,7 +139,7 @@ ModFamH | | N|Conv: QLCS/Wind Family| | OTHER| | PLAN_VIEW - + @@ -269,7 +269,7 @@ ModFamH | | N|Conv: QLCS/Wind Family| | OTHER| | PLAN_VIEW - + @@ -396,7 +396,7 @@ ModFamH | | N|Conv: QLCS/Wind Family| | OTHER| | PLAN_VIEW - + @@ -496,7 +496,7 @@ ModFamH | | N|Conv: QLCS/Wind Family| | OTHER| | PLAN_VIEW - + @@ -1025,7 +1025,7 @@ ModFamH | | N|Conv: QLCS/Wind Family| | OTHER| | PLAN_VIEW - + diff --git a/cave/build/static/common/cave/etc/bundles/volume/ModelFamilyU.xml b/cave/build/static/common/cave/etc/bundles/volume/ModelFamilyU.xml index ed14cd5b97..a8b7de6ee7 100644 --- a/cave/build/static/common/cave/etc/bundles/volume/ModelFamilyU.xml +++ b/cave/build/static/common/cave/etc/bundles/volume/ModelFamilyU.xml @@ -66,7 +66,7 @@ ModFamU| |N|Briefing Family| |OTHER | | \ PLAN_VIEW - + @@ -165,7 +165,7 @@ ModFamU| |N|Briefing Family| |OTHER | | \ PLAN_VIEW - + @@ -264,7 +264,7 @@ ModFamU| |N|Briefing Family| |OTHER | | \ PLAN_VIEW - + @@ -363,7 +363,7 @@ ModFamU| |N|Briefing Family| |OTHER | | \ PLAN_VIEW - + @@ -462,7 +462,7 @@ ModFamU| |N|Briefing Family| |OTHER | | \ PLAN_VIEW - + @@ -594,7 +594,7 @@ ModFamU| |N|Briefing Family| |OTHER | | \ PLAN_VIEW - + @@ -873,7 +873,7 @@ ModFamU| |N|Briefing Family| |OTHER | | \ PLAN_VIEW - + @@ -1044,7 +1044,7 @@ ModFamU| |N|Briefing Family| |OTHER | | \ PLAN_VIEW - + @@ -1179,7 +1179,7 @@ ModFamU| |N|Briefing Family| |OTHER | | \ PLAN_VIEW - + @@ -1278,7 +1278,7 @@ ModFamU| |N|Briefing Family| |OTHER | | \ PLAN_VIEW - + @@ -1377,7 +1377,7 @@ ModFamU| |N|Briefing Family| |OTHER | | \ PLAN_VIEW - + diff --git a/cave/build/static/common/cave/etc/bundles/volume/ModelFamilyV.xml b/cave/build/static/common/cave/etc/bundles/volume/ModelFamilyV.xml index b7fe7fff6a..f907b5f8a8 100644 --- a/cave/build/static/common/cave/etc/bundles/volume/ModelFamilyV.xml +++ b/cave/build/static/common/cave/etc/bundles/volume/ModelFamilyV.xml @@ -135,7 +135,7 @@ ModFamV | | N|Conv: Severe Type Family| | OTHER| | \ PLAN_VIEW - + @@ -341,7 +341,7 @@ ModFamV | | N|Conv: Severe Type Family| | OTHER| | \ PLAN_VIEW - + @@ -479,7 +479,7 @@ ModFamV | | N|Conv: Severe Type Family| | OTHER| | \ PLAN_VIEW - + @@ -902,7 +902,7 @@ ModFamV | | N|Conv: Severe Type Family| | OTHER| | \ PLAN_VIEW - + diff --git a/cave/build/static/common/cave/etc/bundles/volume/ModelFamilyW.xml b/cave/build/static/common/cave/etc/bundles/volume/ModelFamilyW.xml index 11ae214077..ec2f37ca3f 100644 --- a/cave/build/static/common/cave/etc/bundles/volume/ModelFamilyW.xml +++ b/cave/build/static/common/cave/etc/bundles/volume/ModelFamilyW.xml @@ -135,7 +135,7 @@ PLAN_VIEW - + @@ -235,7 +235,7 @@ PLAN_VIEW - + @@ -371,7 +371,7 @@ PLAN_VIEW - + @@ -544,7 +544,7 @@ PLAN_VIEW - + @@ -644,7 +644,7 @@ PLAN_VIEW - + @@ -1093,7 +1093,7 @@ PLAN_VIEW - + @@ -1194,7 +1194,7 @@ PLAN_VIEW - + diff --git a/cave/build/static/common/cave/etc/bundles/volume/ModelFamilyX.xml b/cave/build/static/common/cave/etc/bundles/volume/ModelFamilyX.xml index 13ea2f7a5c..b3f9a3011d 100644 --- a/cave/build/static/common/cave/etc/bundles/volume/ModelFamilyX.xml +++ b/cave/build/static/common/cave/etc/bundles/volume/ModelFamilyX.xml @@ -110,7 +110,7 @@ PLAN_VIEW - + diff --git a/cave/build/static/common/cave/etc/bundles/volume/ModelFamilyY.xml b/cave/build/static/common/cave/etc/bundles/volume/ModelFamilyY.xml index 1bb9f5a9cd..b1948592a0 100644 --- a/cave/build/static/common/cave/etc/bundles/volume/ModelFamilyY.xml +++ b/cave/build/static/common/cave/etc/bundles/volume/ModelFamilyY.xml @@ -127,7 +127,7 @@ PLAN_VIEW - + @@ -227,7 +227,7 @@ PLAN_VIEW - + @@ -327,7 +327,7 @@ PLAN_VIEW - + @@ -610,7 +610,7 @@ PLAN_VIEW - + diff --git a/cave/build/static/common/cave/etc/bundles/volume/ModelFamilyYY.xml b/cave/build/static/common/cave/etc/bundles/volume/ModelFamilyYY.xml index 67c3e4954d..9f7f9995c9 100644 --- a/cave/build/static/common/cave/etc/bundles/volume/ModelFamilyYY.xml +++ b/cave/build/static/common/cave/etc/bundles/volume/ModelFamilyYY.xml @@ -129,7 +129,7 @@ PLAN_VIEW - + @@ -229,7 +229,7 @@ PLAN_VIEW - + @@ -329,7 +329,7 @@ PLAN_VIEW - + @@ -429,7 +429,7 @@ PLAN_VIEW - + @@ -731,7 +731,7 @@ PLAN_VIEW - + diff --git a/cave/com.raytheon.viz.gfe/src/com/raytheon/viz/gfe/actions/ShowISCGridsAction.java b/cave/com.raytheon.viz.gfe/src/com/raytheon/viz/gfe/actions/ShowISCGridsAction.java index ae347f6d78..b4c634ff0f 100644 --- a/cave/com.raytheon.viz.gfe/src/com/raytheon/viz/gfe/actions/ShowISCGridsAction.java +++ b/cave/com.raytheon.viz.gfe/src/com/raytheon/viz/gfe/actions/ShowISCGridsAction.java @@ -45,68 +45,42 @@ import org.eclipse.swt.widgets.ToolItem; * 07/20/09 1995 bphillip Initial release * 12/06/12 DR 15574 jzeng Change the image of * the icon when it is activated + * 01/11/13 DR 15574 jzeng delete all fields to local variables * * * @author bphillip * @version 1 */ public class ShowISCGridsAction extends AbstractHandler { - /* - * non-active Image - */ - private Image orgImg = null; - /* - * active Image - */ - private Image actImg = null; - /* - * ImageDescriptor - */ - private ImageDescriptor id = null; - /* - * Tool item - */ - private ToolItem ti = null; - @Override + @Override public Object execute(ExecutionEvent arg0) throws ExecutionException { boolean current = Message.inquireLastMessage(ShowISCGridsMsg.class).show(); - /* - * Get toolItem - */ + if (arg0.getTrigger() instanceof Event) { - Event e = (Event) arg0.getTrigger(); - if ( e.widget instanceof ToolItem) { - ti = (ToolItem) e.widget; - } + Event e = (Event) arg0.getTrigger(); + if ( e.widget instanceof ToolItem) { + ToolItem ti = (ToolItem) e.widget; + if (ti != null ){ + ImageDescriptor id; + + if (!current){ + id = Activator.imageDescriptorFromPlugin( + Activator.PLUGIN_ID, "icons/isc1.gif" ); + } else { + id = Activator.imageDescriptorFromPlugin( + Activator.PLUGIN_ID, "icons/isc0.gif" ); + } + + if (id != null){ + Image img = id.createImage(); + ti.setImage(img); + img.dispose(); + } + } + } } - - /* - * Get Image when it is not activated - */ - if (orgImg == null) { - id = Activator.imageDescriptorFromPlugin( - Activator.PLUGIN_ID, "icons/isc0.gif" ); - orgImg = id.createImage(); - } - /* - * Get Image when it is activated - */ - if (actImg == null) { - id = Activator.imageDescriptorFromPlugin( - Activator.PLUGIN_ID, "icons/isc1.gif" ); - actImg = id.createImage(); - } - /* - * Change the image when it is active and - * change it back when it is not activated - */ - if (ti != null) { - if (!current) - ti.setImage(actImg); - else ti.setImage(orgImg); - } - + new ShowISCGridsMsg(!current).send(); return null; }