Second try about: * Bug #12520 fixed - Improve the description of the size in... 10/11310/3
Sylvestre Ledru [Thu, 18 Apr 2013 08:37:13 +0000 (10:37 +0200)]
Change-Id: Id97c4834fd59a3c9821a4f0fb7f788c3b72dee98

scilab/modules/ui_data/src/cpp/UpdateBrowseVar.cpp
scilab/modules/ui_data/src/java/org/scilab/modules/ui_data/variablebrowser/SwingScilabVariableBrowser.java

index 8edcb13..ea117df 100644 (file)
@@ -150,8 +150,8 @@ void UpdateBrowseVar(BOOL update)
     {
         // name
         pstAllVariableNames[i] = getGlobalNamefromId(j);
-        // Bytes used
-        piAllVariableBytes[i] = getGlobalSizefromId(j);
+        // Bytes used - 8 is the number of bytes in a word
+        piAllVariableBytes[i] = getGlobalSizefromId(j) * 8;
         // type
         // Calling "API Scilab": not yet implemented for global variable
         //getNamedVarType(pvApiCtx, pstAllVariableNames[i], &piAllVariableTypes[i]);
index 4847932..4579434 100644 (file)
@@ -166,7 +166,7 @@ public final class SwingScilabVariableBrowser extends SwingScilabTab implements
                             /* Use the getModel() method because the
                              * column 5 has been removed from display
                              * but still exist in the model */
-                            tip = Messages.gettext("Words:") + " " + model.getValueAt(rowIndex, BrowseVar.BYTES_COLUMN_INDEX).toString();
+                            tip = Messages.gettext("Bytes:") + " " + model.getValueAt(rowIndex, BrowseVar.BYTES_COLUMN_INDEX).toString();
                         }
                     }
                 }