From 830ffc0c6f5263b2decdac4ba74aa75fd47c78e4 Mon Sep 17 00:00:00 2001 From: rathnor Date: Thu, 1 May 2003 15:03:36 +0000 Subject: fix slit auto hide triggering --- ChangeLog | 2 ++ src/Slit.cc | 14 +++++++++++++- 2 files changed, 15 insertions(+), 1 deletion(-) diff --git a/ChangeLog b/ChangeLog index 8a3da44..ac5decb 100644 --- a/ChangeLog +++ b/ChangeLog @@ -1,6 +1,8 @@ (Format: Year/Month/Day) Changes for 0.9.2: *03/05/01: + * Fix slit autohide triggering (Simon) + Slit.cc * Clean ups and optimising of redraw/reconfigures Also fixes warping in outline focus bug (Simon) Window.hh/cc FbWinFrame.hh/cc diff --git a/src/Slit.cc b/src/Slit.cc index 63b1eb4..df05b4f 100644 --- a/src/Slit.cc +++ b/src/Slit.cc @@ -22,7 +22,7 @@ // FROM, OUT OF OR IN CONNECTION WITH THE SOFTWARE OR THE USE OR OTHER // DEALINGS IN THE SOFTWARE. -// $Id: Slit.cc,v 1.42 2003/04/25 17:27:36 fluxgen Exp $ +// $Id: Slit.cc,v 1.43 2003/05/01 15:03:36 rathnor Exp $ #include "Slit.hh" @@ -761,6 +761,9 @@ void Slit::reconfigure() { break; } + if (do_auto_hide && !hidden && !timer.isTiming()) + timer.start(); + slitmenu.reconfigure(); updateClientmenu(); } @@ -1007,6 +1010,11 @@ void Slit::leaveNotifyEvent(XCrossingEvent &ev) { } else if (! slitmenu.isVisible()) { if (! timer.isTiming()) timer.start(); + } else { + // the menu is open, keep it firing until it closes + timer.fireOnce(false); + if (! timer.isTiming()) + timer.start(); } } @@ -1049,6 +1057,10 @@ void Slit::configureRequestEvent(XConfigureRequestEvent &event) { void Slit::timeout() { + if (!slitmenu.isVisible()) { + timer.fireOnce(true); + } else + return; hidden = ! hidden; // toggle hidden state if (hidden) frame.window.move(frame.x_hidden, frame.y_hidden); -- cgit v0.11.2