From a6146af44f3ef1f44894d5545f449f46db8a3c79 Mon Sep 17 00:00:00 2001 From: simonb Date: Mon, 19 Jun 2006 08:39:00 +0000 Subject: fix placement issue with xinerama (only hit if screens are vertically aligned) --- ChangeLog | 4 ++++ src/FbTk/Menu.cc | 4 ++-- 2 files changed, 6 insertions(+), 2 deletions(-) diff --git a/ChangeLog b/ChangeLog index 7a2b5f8..2e01d40 100644 --- a/ChangeLog +++ b/ChangeLog @@ -1,6 +1,10 @@ (Format: Year/Month/Day) Changes for 1.0rc2: *06/06/19: + * Fix menu placement issue with (vertical) xinerama (Simon) + - note, doesn't fix "submenus open on wrong screen" issue, that requires + some more serious data movement. + FbTk/Menu.cc * Fix bug #1507671, clock not updating on multiple screens (Simon) - time() and gettimeofday() are inconsistent, only use gettimeofday - clean up Timer stuff a bit, fixed some other bugs diff --git a/src/FbTk/Menu.cc b/src/FbTk/Menu.cc index d400e00..b0e5c4e 100644 --- a/src/FbTk/Menu.cc +++ b/src/FbTk/Menu.cc @@ -1075,8 +1075,8 @@ void Menu::enterNotifyEvent(XCrossingEvent &ce) { m_shifted = true; } - if (y() + height() + 2*theme().borderWidth() > m_screen_height) { - menu.y_shift = m_screen_height - height() - 2*theme().borderWidth(); + if (y() + height() + 2*theme().borderWidth() > m_screen_y + m_screen_height) { + menu.y_shift = m_screen_y + m_screen_height - height() - 2*theme().borderWidth(); m_shifted = true; } else if (y() + (signed) theme().titleHeight() < 0) { menu.y_shift = 0; // -theme().borderWidth();; -- cgit v0.11.2