Revert "* Bug #11479 fixed - Under Ubuntu Unity, the color of the text menu was wrong." 36/11236/2
Vincent COUVERT [Mon, 8 Apr 2013 07:26:15 +0000 (09:26 +0200)]
This reverts commit 0c1eec5fc5440b5f4090944bcf813bd2f068e3d7

Change-Id: I28c5068012f1b9d1c17b9d9b60f46f1835dd9559

scilab/CHANGES_5.5.X
scilab/modules/gui/src/java/org/scilab/modules/gui/SwingViewMenu.java

index defca00..b6d3205 100644 (file)
@@ -81,8 +81,6 @@ Bug fixes
 * Bug #11343 fixed - The "isoview" figure property did not work when the axes
                      margins had been modified.
 
-* Bug #11479 fixed - Under Ubuntu Unity, the color of the text menu was wrong.
-
 * Bug #12163 fixed - unzoom did not work with a single input argument.
 
 * Bug #12443 fixed - Document behavior of mopen() in text file mode
index eaaa5a8..a65e64d 100644 (file)
@@ -26,7 +26,6 @@ import static org.scilab.modules.graphic_objects.graphicObject.GraphicObjectProp
 import java.awt.Color;
 
 import javax.swing.ImageIcon;
-import javax.swing.UIManager;
 
 import org.scilab.modules.commons.gui.ScilabKeyStroke;
 import org.scilab.modules.graphic_objects.graphicController.GraphicController;
@@ -80,7 +79,10 @@ public final class SwingViewMenu {
             uimenu.setVisible((Boolean) value);
             break;
         case __GO_UI_FOREGROUNDCOLOR__ :
-            uimenu.setForeground(UIManager.getColor("MenuBar.foreground"));
+            Double[] allColors = ((Double[]) value);
+            uimenu.setForeground(new Color((int) (allColors[0] * COLORS_COEFF),
+                                           (int) (allColors[1] * COLORS_COEFF),
+                                           (int) (allColors[2] * COLORS_COEFF)));
             break;
         case __GO_UI_ICON__ :
             if (!((String) value).equals("")) {