* Bugs 10476 12516 12532 fixed: browsevar() edits/views more vars content
[scilab.git] / scilab / modules / ui_data / src / java / org / scilab / modules / ui_data / variablebrowser / SwingScilabVariableBrowser.java
index fa3bc39..e552e94 100644 (file)
@@ -644,21 +644,25 @@ public final class SwingScilabVariableBrowser extends SwingScilabDockablePanel i
         try {
             asynchronousScilabExec(null,
                                    "if exists(\"" + variableName + "\") == 1 then "
-                                   + "  try "
-                                   + "    editvar(\"" + variableName + "\"); "
-                                   + "  catch "
-                                   + "    messagebox(\"Variables of type \"\"\" + typeof ("
-                                   + variableName + ") + \"\"\" can not be edited.\""
-                                   + ",\"" + UiDataMessages.VARIABLE_EDITOR + "\", \"error\", \"modal\");"
-                                   + "    clear ans;"   // clear return value of messagebox
-                                   + "  end "
-                                   + "else "
-                                   + "  messagebox(\"Variable \"\""
-                                   + variableName + "\"\" no more exists.\""
-                                   + ",\"" + UiDataMessages.VARIABLE_EDITOR + "\", \"error\", \"modal\");"
-                                   + "  clear ans;"  // clear return value of messagebox
-                                   + "  browsevar();" // Reload browsevar to remove cleared variables
-                                   + "end");
+                                 + "  if or(type(" + variableName + ")==[9 13 14 15 16 17]) "
+                                 + "    browsevar_seeSpecial(" + variableName + ",\"" + variableName + "\"); "
+                                 + "  else "
+                                 + "    try "
+                                 + "      editvar(\"" + variableName + "\"); "
+                                 + "    catch "
+                                 + "      messagebox(\"Variables of type \"\"\" + typeof ("
+                                 + variableName + ") + \"\"\" can not be edited.\""
+                                 + ",\"" + UiDataMessages.VARIABLE_EDITOR + "\", \"error\", \"modal\");"
+                                 + "      clear ans;"   // clear return value of messagebox
+                                 + "    end "
+                                 + "  end "
+                                 + "else "
+                                 + "  messagebox(\"Variable \"\""
+                                 + variableName + "\"\" no more exists.\""
+                                 + ",\"" + UiDataMessages.VARIABLE_EDITOR + "\", \"error\", \"modal\");"
+                                 + "  clear ans;"  // clear return value of messagebox
+                                 + "  browsevar();" // Reload browsevar to remove cleared variables
+                                 + "end");
         } catch (InterpreterException e1) {
             System.err.println("An error in the interpreter has been catched: " + e1.getLocalizedMessage());
         }