diff options
author | markt <markt> | 2007-04-23 16:07:21 (GMT) |
---|---|---|
committer | markt <markt> | 2007-04-23 16:07:21 (GMT) |
commit | 6848e180a69cf55840f337f2ca3e70db44f25fd5 (patch) | |
tree | bda5a494abf5e7307f3190a5f6def6b138cdbc0d /src/FbCommands.cc | |
parent | f0e5b2ef3ac6a90cf8a0a97321d9f040b31145c4 (diff) | |
download | fluxbox-6848e180a69cf55840f337f2ca3e70db44f25fd5.zip fluxbox-6848e180a69cf55840f337f2ca3e70db44f25fd5.tar.bz2 |
added clientmenu command, set iconicstate properly, disabled resizing shaded windows
Diffstat (limited to 'src/FbCommands.cc')
-rw-r--r-- | src/FbCommands.cc | 30 |
1 files changed, 30 insertions, 0 deletions
diff --git a/src/FbCommands.cc b/src/FbCommands.cc index 060f4d3..dae4d6a 100644 --- a/src/FbCommands.cc +++ b/src/FbCommands.cc | |||
@@ -25,6 +25,7 @@ | |||
25 | #include "fluxbox.hh" | 25 | #include "fluxbox.hh" |
26 | #include "Screen.hh" | 26 | #include "Screen.hh" |
27 | #include "CommandDialog.hh" | 27 | #include "CommandDialog.hh" |
28 | #include "FocusControl.hh" | ||
28 | #include "Workspace.hh" | 29 | #include "Workspace.hh" |
29 | #include "Window.hh" | 30 | #include "Window.hh" |
30 | #include "Keys.hh" | 31 | #include "Keys.hh" |
@@ -273,6 +274,35 @@ void HideMenuCmd::execute() { | |||
273 | FbTk::Menu::shownMenu()->hide(); | 274 | FbTk::Menu::shownMenu()->hide(); |
274 | } | 275 | } |
275 | 276 | ||
277 | void ShowClientMenuCmd::execute() { | ||
278 | BScreen *screen = Fluxbox::instance()->mouseScreen(); | ||
279 | if (screen == 0) | ||
280 | return; | ||
281 | |||
282 | // TODO: ClientMenu only accepts lists of FluxboxWindows for now | ||
283 | FocusControl::Focusables *win_list = 0; | ||
284 | // if (m_option & FocusControl::CYCLEGROUPS) { | ||
285 | win_list = (m_option & FocusControl::CYCLELINEAR) ? | ||
286 | &screen->focusControl().creationOrderWinList() : | ||
287 | &screen->focusControl().focusedOrderWinList(); | ||
288 | /* } else { | ||
289 | win_list = (m_option & FocusControl::CYCLELINEAR) ? | ||
290 | &screen->focusControl().creationOrderList() : | ||
291 | &screen->focusControl().focusedOrderList(); | ||
292 | } */ | ||
293 | |||
294 | m_list.clear(); | ||
295 | FocusControl::Focusables::iterator it = win_list->begin(), | ||
296 | it_end = win_list->end(); | ||
297 | for (; it != it_end; ++it) { | ||
298 | if (typeid(**it) == typeid(FluxboxWindow) && m_pat.match(**it)) | ||
299 | m_list.push_back(static_cast<FluxboxWindow *>(*it)); | ||
300 | } | ||
301 | |||
302 | m_menu = new ClientMenu(*screen, m_list, 0); | ||
303 | ::showMenu(*screen, **m_menu); | ||
304 | } | ||
305 | |||
276 | ShowCustomMenuCmd::ShowCustomMenuCmd(const string &arguments) : custom_menu_file(arguments) {} | 306 | ShowCustomMenuCmd::ShowCustomMenuCmd(const string &arguments) : custom_menu_file(arguments) {} |
277 | 307 | ||
278 | void ShowCustomMenuCmd::execute() { | 308 | void ShowCustomMenuCmd::execute() { |