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/source
diff options
context:
space:
mode:
authorNathan Letwory <nathan@letworyinteractive.com>2007-12-31 01:52:00 +0300
committerNathan Letwory <nathan@letworyinteractive.com>2007-12-31 01:52:00 +0300
commit1fec64a40219cdd3cf4a2248cb0b68efb83f33da (patch)
tree4c3a1290d20e6170ba52ebdf422f0e26c316ee82 /source
parentf25ce8d0fff3a05c7eeb0d75fe37601f42072edc (diff)
* revert my change to windowmanager move/size handling.
* made win32 ghost getClientBounds so that it returns area compatible with osx getClientBounds - if a window is non-fullscreen, substract decoration, since that'll be added by GHOST_WindowWin32() * use SetWindowLongPtr/GetWindowLongPtr (instead of SetWindowLong) as it is compatible with 64bit windows.
Diffstat (limited to 'source')
-rw-r--r--source/blender/windowmanager/intern/wm_window.c9
1 files changed, 3 insertions, 6 deletions
diff --git a/source/blender/windowmanager/intern/wm_window.c b/source/blender/windowmanager/intern/wm_window.c
index 0e135f9942f..00364414342 100644
--- a/source/blender/windowmanager/intern/wm_window.c
+++ b/source/blender/windowmanager/intern/wm_window.c
@@ -368,23 +368,20 @@ int ghost_event_proc(GHOST_EventHandle evt, GHOST_TUserDataPtr private)
}
case GHOST_kEventWindowSize:
case GHOST_kEventWindowMove: {
- GHOST_RectangleHandle client_rect, window_rect;
+ GHOST_RectangleHandle client_rect;
int l, t, r, b, scr_w, scr_h;
int wl, wt, wr, wb;
- window_rect = GHOST_GetWindowBounds(win->ghostwin);
client_rect= GHOST_GetClientBounds(win->ghostwin);
GHOST_GetRectangle(client_rect, &l, &t, &r, &b);
- GHOST_GetRectangle(window_rect, &wl, &wt, &wr, &wb);
GHOST_DisposeRectangle(client_rect);
- GHOST_DisposeRectangle(window_rect);
wm_get_screensize(&scr_w, &scr_h);
win->sizex= r-l;
win->sizey= b-t;
- win->posx= wl;
- win->posy= scr_h - wt - win->sizey;
+ win->posx= l;
+ win->posy= scr_h - t - win->sizey;
if(type!=GHOST_kEventWindowSize)
printf("win move event pos %d %d size %d %d\n", win->posx, win->posy, win->sizex, win->sizey);