aboutsummaryrefslogtreecommitdiff
path: root/src/FbTk/Menu.hh
diff options
context:
space:
mode:
authorrathnor <rathnor>2003-07-19 03:59:56 (GMT)
committerrathnor <rathnor>2003-07-19 03:59:56 (GMT)
commita827c24e36aa3cf42566fe44dde5848df7679d14 (patch)
treec92a16e1fa0eab7feb6c5f0caeee5b2e11460443 /src/FbTk/Menu.hh
parent2e3bd41f4e0e5d10c65888b277f944d75938fab8 (diff)
downloadfluxbox-a827c24e36aa3cf42566fe44dde5848df7679d14.zip
fluxbox-a827c24e36aa3cf42566fe44dde5848df7679d14.tar.bz2
fix alpha setting for menus when multiple screens by moving from static in menu
to part of MenuTheme
Diffstat (limited to 'src/FbTk/Menu.hh')
-rw-r--r--src/FbTk/Menu.hh9
1 files changed, 3 insertions, 6 deletions
diff --git a/src/FbTk/Menu.hh b/src/FbTk/Menu.hh
index 5ddd617..013c478 100644
--- a/src/FbTk/Menu.hh
+++ b/src/FbTk/Menu.hh
@@ -22,7 +22,7 @@
22// FROM, OUT OF OR IN CONNECTION WITH THE SOFTWARE OR THE USE OR OTHER 22// FROM, OUT OF OR IN CONNECTION WITH THE SOFTWARE OR THE USE OR OTHER
23// DEALINGS IN THE SOFTWARE. 23// DEALINGS IN THE SOFTWARE.
24 24
25// $Id: Menu.hh,v 1.18 2003/07/10 11:55:49 fluxgen Exp $ 25// $Id: Menu.hh,v 1.19 2003/07/19 03:59:56 rathnor Exp $
26 26
27#ifndef FBTK_MENU_HH 27#ifndef FBTK_MENU_HH
28#define FBTK_MENU_HH 28#define FBTK_MENU_HH
@@ -39,11 +39,11 @@
39#include "Observer.hh" 39#include "Observer.hh"
40#include "XLayerItem.hh" 40#include "XLayerItem.hh"
41#include "FbPixmap.hh" 41#include "FbPixmap.hh"
42#include "MenuTheme.hh"
42 43
43namespace FbTk { 44namespace FbTk {
44 45
45class MenuItem; 46class MenuItem;
46class MenuTheme;
47class ImageControl; 47class ImageControl;
48class Transparent; 48class Transparent;
49 49
@@ -95,8 +95,6 @@ public:
95 void disableTitle(); 95 void disableTitle();
96 void enableTitle(); 96 void enableTitle();
97 97
98 static void setAlpha(unsigned char alpha) { s_alpha = alpha; }
99
100 /** 98 /**
101 @name event handlers 99 @name event handlers
102 */ 100 */
@@ -153,7 +151,7 @@ public:
153 bool isItemSelected(unsigned int index) const; 151 bool isItemSelected(unsigned int index) const;
154 bool isItemEnabled(unsigned int index) const; 152 bool isItemEnabled(unsigned int index) const;
155 const MenuTheme &theme() const { return m_theme; } 153 const MenuTheme &theme() const { return m_theme; }
156 static unsigned char alpha() { return s_alpha; } 154 inline unsigned char alpha() const { return m_theme.alpha(); }
157 static Menu *focused() { return s_focused; } 155 static Menu *focused() { return s_focused; }
158 /// @return menuitem at index 156 /// @return menuitem at index
159 inline const MenuItem *find(unsigned int index) const { return menuitems[index]; } 157 inline const MenuItem *find(unsigned int index) const { return menuitems[index]; }
@@ -218,7 +216,6 @@ private:
218 ThemeObserver m_themeobserver; 216 ThemeObserver m_themeobserver;
219 std::auto_ptr<Transparent> m_trans; 217 std::auto_ptr<Transparent> m_trans;
220 Drawable m_root_pm; 218 Drawable m_root_pm;
221 static unsigned char s_alpha;
222 static Menu *s_focused; ///< holds current input focused menu, so one can determine if a menu is focused 219 static Menu *s_focused; ///< holds current input focused menu, so one can determine if a menu is focused
223 FbPixmap m_frame_pm; 220 FbPixmap m_frame_pm;
224 bool m_need_update; 221 bool m_need_update;