diff options
author | mathias <mathias> | 2006-10-30 19:31:15 (GMT) |
---|---|---|
committer | mathias <mathias> | 2006-10-30 19:31:15 (GMT) |
commit | e5e76e7761f52ba7c0deca75bcecae4fbd3e2ff5 (patch) | |
tree | c84838a84802805e9b1463045e86200b7cef917f /src/Toolbar.cc | |
parent | 426c12c25c2ef095a882619ad7424684b88465b8 (diff) | |
download | fluxbox-e5e76e7761f52ba7c0deca75bcecae4fbd3e2ff5.zip fluxbox-e5e76e7761f52ba7c0deca75bcecae4fbd3e2ff5.tar.bz2 |
Cosmetic patch from Slava Semushin
Diffstat (limited to 'src/Toolbar.cc')
-rw-r--r-- | src/Toolbar.cc | 24 |
1 files changed, 13 insertions, 11 deletions
diff --git a/src/Toolbar.cc b/src/Toolbar.cc index f93465c..f012570 100644 --- a/src/Toolbar.cc +++ b/src/Toolbar.cc | |||
@@ -76,7 +76,9 @@ | |||
76 | #include <iterator> | 76 | #include <iterator> |
77 | #include <typeinfo> | 77 | #include <typeinfo> |
78 | 78 | ||
79 | using namespace std; | 79 | using std::string; |
80 | using std::pair; | ||
81 | using std::list; | ||
80 | 82 | ||
81 | namespace FbTk { | 83 | namespace FbTk { |
82 | 84 | ||
@@ -376,7 +378,7 @@ void Toolbar::reconfigure() { | |||
376 | 378 | ||
377 | bool need_update = false; | 379 | bool need_update = false; |
378 | // parse and transform to lower case | 380 | // parse and transform to lower case |
379 | std::list<std::string> tools; | 381 | list<string> tools; |
380 | FbTk::StringUtil::stringtok(tools, *m_rc_tools, ", "); | 382 | FbTk::StringUtil::stringtok(tools, *m_rc_tools, ", "); |
381 | transform(tools.begin(), | 383 | transform(tools.begin(), |
382 | tools.end(), | 384 | tools.end(), |
@@ -427,7 +429,7 @@ void Toolbar::reconfigure() { | |||
427 | // show all items | 429 | // show all items |
428 | frame.window.showSubwindows(); | 430 | frame.window.showSubwindows(); |
429 | } | 431 | } |
430 | 432 | ||
431 | } else { // just update the menu | 433 | } else { // just update the menu |
432 | menu().reconfigure(); | 434 | menu().reconfigure(); |
433 | } | 435 | } |
@@ -542,7 +544,7 @@ void Toolbar::buttonReleaseEvent(XButtonEvent &re) { | |||
542 | screen().nextWorkspace(1); | 544 | screen().nextWorkspace(1); |
543 | } | 545 | } |
544 | } else if (re.button == 5) { //mousewheel scroll down | 546 | } else if (re.button == 5) { //mousewheel scroll down |
545 | if(screen().isReverseWheeling()) { | 547 | if(screen().isReverseWheeling()) { |
546 | screen().nextWorkspace(1); | 548 | screen().nextWorkspace(1); |
547 | } else { | 549 | } else { |
548 | screen().prevWorkspace(1); | 550 | screen().prevWorkspace(1); |
@@ -828,7 +830,7 @@ void Toolbar::setupMenus(bool skip_new_placement) { | |||
828 | visible_macro->add(reconfig_toolbar); | 830 | visible_macro->add(reconfig_toolbar); |
829 | visible_macro->add(save_resources); | 831 | visible_macro->add(save_resources); |
830 | RefCommand toggle_visible_cmd(visible_macro); | 832 | RefCommand toggle_visible_cmd(visible_macro); |
831 | menu().insert(new BoolMenuItem(_FB_XTEXT(Common, Visible, | 833 | menu().insert(new BoolMenuItem(_FB_XTEXT(Common, Visible, |
832 | "Visible", "Whether this item is visible"), | 834 | "Visible", "Whether this item is visible"), |
833 | *m_rc_visible, toggle_visible_cmd)); | 835 | *m_rc_visible, toggle_visible_cmd)); |
834 | 836 | ||
@@ -837,9 +839,9 @@ void Toolbar::setupMenus(bool skip_new_placement) { | |||
837 | *m_rc_auto_hide, | 839 | *m_rc_auto_hide, |
838 | reconfig_toolbar_and_save_resource)); | 840 | reconfig_toolbar_and_save_resource)); |
839 | 841 | ||
840 | MenuItem *toolbar_menuitem = | 842 | MenuItem *toolbar_menuitem = |
841 | new IntResMenuItem(_FB_XTEXT(Toolbar, WidthPercent, | 843 | new IntResMenuItem(_FB_XTEXT(Toolbar, WidthPercent, |
842 | "Toolbar width percent", | 844 | "Toolbar width percent", |
843 | "Percentage of screen width taken by toolbar"), | 845 | "Percentage of screen width taken by toolbar"), |
844 | m_rc_width_percent, | 846 | m_rc_width_percent, |
845 | 0, 100, menu()); // min/max value | 847 | 0, 100, menu()); // min/max value |
@@ -849,7 +851,7 @@ void Toolbar::setupMenus(bool skip_new_placement) { | |||
849 | menu().insert(toolbar_menuitem); | 851 | menu().insert(toolbar_menuitem); |
850 | 852 | ||
851 | menu().insert(new BoolMenuItem(_FB_XTEXT(Common, MaximizeOver, | 853 | menu().insert(new BoolMenuItem(_FB_XTEXT(Common, MaximizeOver, |
852 | "Maximize Over", | 854 | "Maximize Over", |
853 | "Maximize over this thing when maximizing"), | 855 | "Maximize over this thing when maximizing"), |
854 | *m_rc_maximize_over, | 856 | *m_rc_maximize_over, |
855 | reconfig_toolbar_and_save_resource)); | 857 | reconfig_toolbar_and_save_resource)); |
@@ -862,7 +864,7 @@ void Toolbar::setupMenus(bool skip_new_placement) { | |||
862 | screen().imageControl(), | 864 | screen().imageControl(), |
863 | *screen().layerManager().getLayer(::Layer::MENU), | 865 | *screen().layerManager().getLayer(::Layer::MENU), |
864 | *this, | 866 | *this, |
865 | _FB_XTEXT(Toolbar, OnHead, "Toolbar on Head", | 867 | _FB_XTEXT(Toolbar, OnHead, "Toolbar on Head", |
866 | "Title of toolbar on head menu"))); | 868 | "Title of toolbar on head menu"))); |
867 | } | 869 | } |
868 | #endif // XINERAMA | 870 | #endif // XINERAMA |
@@ -911,7 +913,7 @@ void Toolbar::setupMenus(bool skip_new_placement) { | |||
911 | 913 | ||
912 | menu().insert(_FB_XTEXT(Menu, Placement, "Placement", "Title of Placement menu"), &placementMenu()); | 914 | menu().insert(_FB_XTEXT(Menu, Placement, "Placement", "Title of Placement menu"), &placementMenu()); |
913 | placementMenu().updateMenu(); | 915 | placementMenu().updateMenu(); |
914 | 916 | ||
915 | 917 | ||
916 | // this saves resources and clears the slit window to update alpha value | 918 | // this saves resources and clears the slit window to update alpha value |
917 | FbTk::MenuItem *alpha_menuitem = | 919 | FbTk::MenuItem *alpha_menuitem = |