aboutsummaryrefslogtreecommitdiff
path: root/src/IconButton.cc
diff options
context:
space:
mode:
Diffstat (limited to 'src/IconButton.cc')
-rw-r--r--src/IconButton.cc14
1 files changed, 9 insertions, 5 deletions
diff --git a/src/IconButton.cc b/src/IconButton.cc
index 5733e2c..cea49c3 100644
--- a/src/IconButton.cc
+++ b/src/IconButton.cc
@@ -20,7 +20,7 @@
20// FROM, OUT OF OR IN CONNECTION WITH THE SOFTWARE OR THE USE OR OTHER 20// FROM, OUT OF OR IN CONNECTION WITH THE SOFTWARE OR THE USE OR OTHER
21// DEALINGS IN THE SOFTWARE. 21// DEALINGS IN THE SOFTWARE.
22 22
23// $Id: IconButton.cc,v 1.14 2004/01/11 16:08:07 fluxgen Exp $ 23// $Id: IconButton.cc,v 1.15 2004/01/13 12:27:51 fluxgen Exp $
24 24
25#include "IconButton.hh" 25#include "IconButton.hh"
26 26
@@ -77,10 +77,13 @@ IconButton::IconButton(const FbTk::FbWindow &parent, const FbTk::Font &font,
77 77
78 FbTk::RefCount<FbTk::Command> focus(new FbTk::SimpleCommand<FluxboxWindow>(m_win, &FluxboxWindow::raiseAndFocus)); 78 FbTk::RefCount<FbTk::Command> focus(new FbTk::SimpleCommand<FluxboxWindow>(m_win, &FluxboxWindow::raiseAndFocus));
79 FbTk::RefCount<FbTk::Command> hidemenus(new FbTk::SimpleCommand<BScreen>(win.screen(), &BScreen::hideMenus)); 79 FbTk::RefCount<FbTk::Command> hidemenus(new FbTk::SimpleCommand<BScreen>(win.screen(), &BScreen::hideMenus));
80 FbTk::MacroCommand *focus_macro = new FbTk::MacroCommand(); 80 //!! TODO: There're some issues with MacroCommand when
81 focus_macro->add(hidemenus); 81 // this object dies when the last macrocommand is executed (focused cmd)
82 focus_macro->add(focus); 82 // In iconbar mode Icons
83 FbTk::RefCount<FbTk::Command> focus_cmd(focus_macro); 83 // FbTk::MacroCommand *focus_macro = new FbTk::MacroCommand();
84 // focus_macro->add(hidemenus);
85 // focus_macro->add(focus);
86 FbTk::RefCount<FbTk::Command> focus_cmd(focus);
84 FbTk::RefCount<FbTk::Command> menu_cmd(new ::ShowMenu(m_win)); 87 FbTk::RefCount<FbTk::Command> menu_cmd(new ::ShowMenu(m_win));
85 setOnClick(focus_cmd, 1); 88 setOnClick(focus_cmd, 1);
86 setOnClick(menu_cmd, 3); 89 setOnClick(menu_cmd, 3);
@@ -95,6 +98,7 @@ IconButton::~IconButton() {
95 98
96} 99}
97 100
101
98void IconButton::exposeEvent(XExposeEvent &event) { 102void IconButton::exposeEvent(XExposeEvent &event) {
99 if (m_icon_window == event.window) 103 if (m_icon_window == event.window)
100 m_icon_window.clear(); 104 m_icon_window.clear();