aboutsummaryrefslogtreecommitdiff
path: root/src/fluxbox.hh
diff options
context:
space:
mode:
Diffstat (limited to 'src/fluxbox.hh')
-rw-r--r--src/fluxbox.hh40
1 files changed, 33 insertions, 7 deletions
diff --git a/src/fluxbox.hh b/src/fluxbox.hh
index 6459385..5d3f505 100644
--- a/src/fluxbox.hh
+++ b/src/fluxbox.hh
@@ -22,7 +22,7 @@
22// FROM, OUT OF OR IN CONNECTION WITH THE SOFTWARE OR THE USE OR OTHER 22// FROM, OUT OF OR IN CONNECTION WITH THE SOFTWARE OR THE USE OR OTHER
23// DEALINGS IN THE SOFTWARE. 23// DEALINGS IN THE SOFTWARE.
24 24
25// $Id: fluxbox.hh,v 1.72 2003/09/10 09:51:58 fluxgen Exp $ 25// $Id: fluxbox.hh,v 1.73 2003/10/05 02:31:23 rathnor Exp $
26 26
27#ifndef FLUXBOX_HH 27#ifndef FLUXBOX_HH
28#define FLUXBOX_HH 28#define FLUXBOX_HH
@@ -148,13 +148,11 @@ public:
148 inline unsigned int getCacheLife() const { return *m_rc_cache_life * 60000; } 148 inline unsigned int getCacheLife() const { return *m_rc_cache_life * 60000; }
149 inline unsigned int getCacheMax() const { return *m_rc_cache_max; } 149 inline unsigned int getCacheMax() const { return *m_rc_cache_max; }
150 150
151 inline void maskWindowEvents(Window w, FluxboxWindow *bw)
152 { m_masked = w; m_masked_window = bw; }
153
154 void watchKeyRelease(BScreen &screen, unsigned int mods); 151 void watchKeyRelease(BScreen &screen, unsigned int mods);
155 152
156 void setFocusedWindow(WinClient *w); 153 void setFocusedWindow(WinClient *w);
157 void revertFocus(BScreen &screen); 154 // focus revert gets delayed until the end of the event handle
155 void revertFocus(BScreen &screen, bool wait_for_end = true);
158 void shutdown(); 156 void shutdown();
159 void load_rc(BScreen &scr); 157 void load_rc(BScreen &scr);
160 void loadRootCommand(BScreen &scr); 158 void loadRootCommand(BScreen &scr);
@@ -204,6 +202,21 @@ public:
204 // screen we are watching for modifier changes 202 // screen we are watching for modifier changes
205 BScreen *watchingScreen() { return m_watching_screen; } 203 BScreen *watchingScreen() { return m_watching_screen; }
206 const XEvent &lastEvent() const { return m_last_event; } 204 const XEvent &lastEvent() const { return m_last_event; }
205
206 /**
207 * Allows people to create special event exclusions/redirects
208 * useful for getting around X followup events, or for
209 * effectively grabbing things
210 * The ignore is automatically removed when it finds the stop_win
211 * with an event matching the stop_type
212 * ignore None means all windows
213 */
214 void addRedirectEvent(BScreen *screen, long catch_type, Window catch_win,
215 long stop_type, Window stop_win, Window redirect_win);
216
217 // So that an object may remove the ignore on its own
218 void removeRedirectEvent(long stop_type, Window stop_win);
219
207private: 220private:
208 221
209 typedef struct MenuTimestamp { 222 typedef struct MenuTimestamp {
@@ -264,9 +277,20 @@ private:
264 ScreenList m_screen_list; 277 ScreenList m_screen_list;
265 278
266 WinClient *m_focused_window; 279 WinClient *m_focused_window;
267 FluxboxWindow *m_masked_window;
268 FbTk::Timer m_timer; 280 FbTk::Timer m_timer;
269 281
282 typedef struct RedirectEvent {
283 BScreen *screen;
284 long catch_type;
285 Window catch_win;
286 long stop_type;
287 Window stop_win;
288 Window redirect_win;
289 } RedirectEvent;
290
291 typedef std::list<RedirectEvent *> RedirectEvents;
292
293 RedirectEvents m_redirect_events;
270 BScreen *m_mousescreen, *m_keyscreen; 294 BScreen *m_mousescreen, *m_keyscreen;
271 BScreen *m_watching_screen; 295 BScreen *m_watching_screen;
272 unsigned int m_watch_keyrelease; 296 unsigned int m_watch_keyrelease;
@@ -275,7 +299,6 @@ private:
275 299
276 bool m_reconfigure_wait, m_reread_menu_wait; 300 bool m_reconfigure_wait, m_reread_menu_wait;
277 Time m_last_time; 301 Time m_last_time;
278 Window m_masked;
279 std::string m_rc_file; ///< resource filename 302 std::string m_rc_file; ///< resource filename
280 char **m_argv; 303 char **m_argv;
281 int m_argc; 304 int m_argc;
@@ -296,6 +319,9 @@ private:
296 const char *m_RC_PATH; 319 const char *m_RC_PATH;
297 const char *m_RC_INIT_FILE; 320 const char *m_RC_INIT_FILE;
298 Atom m_kwm1_dockwindow, m_kwm2_dockwindow; 321 Atom m_kwm1_dockwindow, m_kwm2_dockwindow;
322
323 // each event can only affect one screen (right?)
324 BScreen *m_focus_revert_screen;
299}; 325};
300 326
301 327