Welcome to mirror list, hosted at ThFree Co, Russian Federation.

git.blender.org/blender.git - Unnamed repository; edit this file 'description' to name the repository.
summaryrefslogtreecommitdiff
path: root/intern
diff options
context:
space:
mode:
authorNathan Letwory <nathan@letworyinteractive.com>2013-09-10 10:35:50 +0400
committerNathan Letwory <nathan@letworyinteractive.com>2013-09-10 10:35:50 +0400
commit46db99e7fdec050ffeef49faa05e6d34103217c4 (patch)
tree05ea1832095cdca89bd1fd8dcf00b61427c3aea0 /intern
parentb6a6074b56b3d575267c80fd250998e113e8f3bd (diff)
Remove dimension checks from window creation.
This should be (and is) done by the caller instead (windowmanager) to ensure new windows fit properly on the desktop. Saving stretched layouts and layouts with window over display boundaries now becomes possible on Windows too.
Diffstat (limited to 'intern')
-rw-r--r--intern/ghost/intern/GHOST_WindowWin32.cpp34
1 files changed, 0 insertions, 34 deletions
diff --git a/intern/ghost/intern/GHOST_WindowWin32.cpp b/intern/ghost/intern/GHOST_WindowWin32.cpp
index 8290f4ee205..10f8a507e35 100644
--- a/intern/ghost/intern/GHOST_WindowWin32.cpp
+++ b/intern/ghost/intern/GHOST_WindowWin32.cpp
@@ -177,46 +177,12 @@ GHOST_WindowWin32::GHOST_WindowWin32(
if (state != GHOST_kWindowStateFullScreen) {
RECT rect;
- MONITORINFO monitor;
- GHOST_TUns32 tw, th;
-
- width += GetSystemMetrics(SM_CXSIZEFRAME) * 2;
- height += GetSystemMetrics(SM_CYSIZEFRAME) * 2 + GetSystemMetrics(SM_CYCAPTION);
rect.left = left;
rect.right = left + width;
rect.top = top;
rect.bottom = top + height;
- monitor.cbSize = sizeof(monitor);
- monitor.dwFlags = 0;
-
- // take taskbar into account
- GetMonitorInfo(MonitorFromRect(&rect, MONITOR_DEFAULTTONEAREST), &monitor);
-
- th = monitor.rcWork.bottom - monitor.rcWork.top;
- tw = monitor.rcWork.right - monitor.rcWork.left;
-
- if (tw < width)
- {
- width = tw;
- left = monitor.rcWork.left;
- }
- else if (monitor.rcWork.right < left + (int)width)
- left = monitor.rcWork.right - width;
- else if (left < monitor.rcWork.left)
- left = monitor.rcWork.left;
-
- if (th < height)
- {
- height = th;
- top = monitor.rcWork.top;
- }
- else if (monitor.rcWork.bottom < top + (int)height)
- top = monitor.rcWork.bottom - height;
- else if (top < monitor.rcWork.top)
- top = monitor.rcWork.top;
-
int wintype = WS_OVERLAPPEDWINDOW;
if (m_parentWindowHwnd != 0)
{