aboutsummaryrefslogtreecommitdiff
path: root/src/FbCommands.cc
diff options
context:
space:
mode:
Diffstat (limited to 'src/FbCommands.cc')
-rw-r--r--src/FbCommands.cc15
1 files changed, 15 insertions, 0 deletions
diff --git a/src/FbCommands.cc b/src/FbCommands.cc
index eb4e040..fc2426d 100644
--- a/src/FbCommands.cc
+++ b/src/FbCommands.cc
@@ -225,6 +225,21 @@ void SetStyleCmd::execute() {
225 Fluxbox::instance()->getStyleOverlayFilename()); 225 Fluxbox::instance()->getStyleOverlayFilename());
226} 226}
227 227
228KeyModeCmd::KeyModeCmd(const std::string &arguments):m_keymode(arguments),m_end_args("None Escape") {
229 string::size_type second_pos = m_keymode.find_first_of(" \t", 0);
230 if (second_pos != string::npos) {
231 // ok we have arguments, parsing them here
232 m_end_args = m_keymode.substr(second_pos);
233 m_keymode.erase(second_pos); // remove argument from command
234 }
235 if (m_keymode != "default")
236 Fluxbox::instance()->keys()->addBinding(m_keymode + ": " + m_end_args + " :keymode default");
237}
238
239void KeyModeCmd::execute() {
240 Fluxbox::instance()->keys()->keyMode(m_keymode);
241}
242
228void ShowRootMenuCmd::execute() { 243void ShowRootMenuCmd::execute() {
229 BScreen *screen = Fluxbox::instance()->mouseScreen(); 244 BScreen *screen = Fluxbox::instance()->mouseScreen();
230 if (screen == 0) 245 if (screen == 0)