From 7c412b5c786c36bac17759c359cc040fa228126d Mon Sep 17 00:00:00 2001 From: fluxgen Date: Sun, 27 Jun 2004 21:47:16 +0000 Subject: force old position on configure request, we dont know if the clients changed the position --- src/SystemTray.cc | 25 +++++++++++++++++-------- 1 file changed, 17 insertions(+), 8 deletions(-) diff --git a/src/SystemTray.cc b/src/SystemTray.cc index c1a4f53..728b6bb 100644 --- a/src/SystemTray.cc +++ b/src/SystemTray.cc @@ -19,7 +19,7 @@ // FROM, OUT OF OR IN CONNECTION WITH THE SOFTWARE OR THE USE OR OTHER // DEALINGS IN THE SOFTWARE. -// $Id: SystemTray.cc,v 1.11 2004/06/20 10:29:51 rathnor Exp $ +// $Id: SystemTray.cc,v 1.12 2004/06/27 21:47:16 fluxgen Exp $ #include "SystemTray.hh" @@ -209,6 +209,10 @@ bool SystemTray::clientMessage(const XClientMessageEvent &event) { int type = event.data.l[1]; if (type == SYSTEM_TRAY_REQUEST_DOCK) { +#ifndef DEBUG + cerr<<"SystemTray::"<<__FUNCTION__<<": SYSTEM_TRAY_REQUEST_DOCK"<reparent(m_window, 0, 0); traywin->show(); +#ifdef DEBUG + cerr<<"number of clients = "<(event.xconfigure.width) != (*it)->width() || static_cast(event.xconfigure.height) != (*it)->height()) { - (*it)->resize((*it)->width(), (*it)->height()); + // the position might differ so we update from our local + // copy of position + (*it)->moveResize((*it)->x(), (*it)->y(), + (*it)->width(), (*it)->height()); } } + } } @@ -313,10 +326,6 @@ void SystemTray::rearrangeClients() { int next_x = 0; for (; client_it != client_it_end; ++client_it, next_x += height()) { (*client_it)->moveResize(next_x, 0, height(), height()); - -#ifdef DEBUG - cerr<<__FILE__<<"("<<__FUNCTION__<<"): "<<(*client_it)->width()<<", "<<(*client_it)->height()<