Salome HOME
Check is added to avoid NullPointerException.
authorrkv <rkv@opencascade.com>
Wed, 14 Nov 2012 06:52:27 +0000 (06:52 +0000)
committerrkv <rkv@opencascade.com>
Wed, 14 Nov 2012 06:52:27 +0000 (06:52 +0000)
Workspace/Siman/src/org/splat/wapp/Menu.java

index 40a4f1cb5eae5f4466d9ffb2ca1684b39df7c49a..b9016e39a6bae42bb6ba64474a8a4bd1d1e2abdf 100644 (file)
@@ -173,7 +173,7 @@ public class Menu {
        public void selects(final String name) {
                Integer newdex = _indices.get(name);
 
-               if (_selection != null) {
+               if ((_selection != null) && _indices.containsKey(_selection)) {
                        _menu.get(_indices.get(_selection)).unselect();
                }
                if (newdex != null) {