From fc9cda8098a9a87d9662c57880770b4a0c85b7db Mon Sep 17 00:00:00 2001 From: handsome_feng <445865575@qq.com> Date: Fri, 11 Dec 2015 16:49:36 +0800 Subject: update (bzr r3999.7.11) --- dash/DashController.cpp | 14 ++++++-------- 1 file changed, 6 insertions(+), 8 deletions(-) (limited to 'dash') diff --git a/dash/DashController.cpp b/dash/DashController.cpp index 64aa27609..38a29449c 100644 --- a/dash/DashController.cpp +++ b/dash/DashController.cpp @@ -232,25 +232,23 @@ nux::Geometry Controller::GetIdealWindowGeometry() { UScreen *uscreen = UScreen::GetDefault(); auto monitor_geo = uscreen->GetMonitorGeometry(GetIdealMonitor()); + int launcher_size = unity::Settings::Instance().LauncherSize(monitor_); if (Settings::Instance().launcher_position() == LauncherPosition::LEFT) { - int launcher_width = unity::Settings::Instance().LauncherSize(monitor_); - - // We want to cover as much of the screen as possible to grab any mouse events outside - // of our window - return nux::Geometry (monitor_geo.x + launcher_width, + // We want to cover as much of the screen as possible to grab any mouse events outside + // of our window + return nux::Geometry (monitor_geo.x + launcher_size, monitor_geo.y, - monitor_geo.width - launcher_width, + monitor_geo.width - launcher_size, monitor_geo.height); } else { - int launcher_height = unity::Settings::Instance().LauncherSize(monitor_); return nux::Geometry (monitor_geo.x, monitor_geo.y, monitor_geo.width, - monitor_geo.height - launcher_height ); + monitor_geo.height - launcher_size ); } } -- cgit v1.2.3