diff options
author | Mark Tiefenbruck <mark@fluxbox.org> | 2012-07-09 00:56:26 (GMT) |
---|---|---|
committer | Mark Tiefenbruck <mark@fluxbox.org> | 2012-07-09 00:56:26 (GMT) |
commit | 2944cd0014cde6a219822f120fff9588225e8776 (patch) | |
tree | ee412d25a26618d8352f777d2964e4731e3a7eb3 /src | |
parent | fb52be0c47bb41793fe1ac1eed710fb5375ec3d6 (diff) | |
download | fluxbox_pavel-2944cd0014cde6a219822f120fff9588225e8776.zip fluxbox_pavel-2944cd0014cde6a219822f120fff9588225e8776.tar.bz2 |
make the menu bit of decoration masks control whether or not menu button is shown on window (it did nothing before)
Diffstat (limited to 'src')
-rw-r--r-- | src/Window.cc | 17 | ||||
-rw-r--r-- | src/WindowState.hh | 8 |
2 files changed, 13 insertions, 12 deletions
diff --git a/src/Window.cc b/src/Window.cc index 3c8f87b..747c909 100644 --- a/src/Window.cc +++ b/src/Window.cc | |||
@@ -3613,15 +3613,16 @@ void FluxboxWindow::updateButtons() { | |||
3613 | } | 3613 | } |
3614 | break; | 3614 | break; |
3615 | case WinButton::MENUICON: | 3615 | case WinButton::MENUICON: |
3616 | winbtn = new WinButton(*this, m_button_theme, | 3616 | if (m_state.deco_mask & WindowState::DECORM_MENU) { |
3617 | screen().pressedWinButtonTheme(), | 3617 | winbtn = new WinButton(*this, m_button_theme, |
3618 | dir[i], | 3618 | screen().pressedWinButtonTheme(), |
3619 | frame().titlebar(), | 3619 | dir[i], |
3620 | 0, 0, 10, 10); | 3620 | frame().titlebar(), |
3621 | winbtn->join(titleSig(), | 3621 | 0, 0, 10, 10); |
3622 | winbtn->join(titleSig(), | ||
3622 | FbTk::MemFunIgnoreArgs(*winbtn, &WinButton::updateAll)); | 3623 | FbTk::MemFunIgnoreArgs(*winbtn, &WinButton::updateAll)); |
3623 | 3624 | winbtn->setOnClick(show_menu_cmd); | |
3624 | winbtn->setOnClick(show_menu_cmd); | 3625 | } |
3625 | break; | 3626 | break; |
3626 | } | 3627 | } |
3627 | 3628 | ||
diff --git a/src/WindowState.hh b/src/WindowState.hh index 58664fa..6b45a44 100644 --- a/src/WindowState.hh +++ b/src/WindowState.hh | |||
@@ -90,10 +90,10 @@ public: | |||
90 | enum Decoration { | 90 | enum Decoration { |
91 | DECOR_NONE = 0, | 91 | DECOR_NONE = 0, |
92 | DECOR_NORMAL = DECORM_LAST - 1, | 92 | DECOR_NORMAL = DECORM_LAST - 1, |
93 | DECOR_TINY = DECORM_TITLEBAR|DECORM_ICONIFY|DECORM_MENU|DECORM_TAB, | 93 | DECOR_TINY = DECORM_TITLEBAR|DECORM_ICONIFY, |
94 | DECOR_TOOL = DECORM_TITLEBAR|DECORM_MENU, | 94 | DECOR_TOOL = DECORM_TITLEBAR, |
95 | DECOR_BORDER = DECORM_BORDER|DECORM_MENU, | 95 | DECOR_BORDER = DECORM_BORDER, |
96 | DECOR_TAB = DECORM_BORDER|DECORM_MENU|DECORM_TAB | 96 | DECOR_TAB = DECORM_BORDER|DECORM_TAB |
97 | }; | 97 | }; |
98 | 98 | ||
99 | enum WindowType { | 99 | enum WindowType { |