From: Rcmaniac25 Date: Fri, 24 Jan 2014 10:33:38 +0000 (+0000) Subject: Added (though commented out) support for setting window position X-Git-Url: http://git.mutantstargoat.com/user/nuclear/?a=commitdiff_plain;h=53897b97e617ca478288b78b9ff363d97ba3f74e;p=freeglut Added (though commented out) support for setting window position git-svn-id: svn+ssh://svn.code.sf.net/p/freeglut/code/trunk/freeglut/freeglut@1669 7f0cb862-5218-0410-a997-914c9d46530a --- diff --git a/src/blackberry/fg_window_blackberry.c b/src/blackberry/fg_window_blackberry.c index 9f35750..61bd58d 100644 --- a/src/blackberry/fg_window_blackberry.c +++ b/src/blackberry/fg_window_blackberry.c @@ -78,12 +78,22 @@ void fgPlatformOpenWindow( SFG_Window* window, const char* title, return; } - /* Could set size based on what is specified for window. Work on another time - int size[2]; + /* Uncomment when multiple windows are supported + int value[2]; + if(positionUse) { + value[0] = x; + value[1] = y; + if (screen_set_window_property_iv(sWindow, SCREEN_PROPERTY_POSITION, value)) { + screen_destroy_window(sWindow); + fgError("Could not set window position"); + return; + } + } + if(sizeUse) { - size[0] = w; - size[1] = h; - if (screen_set_window_property_iv(sWindow, SCREEN_PROPERTY_BUFFER_SIZE, size)) { + value[0] = w; + value[1] = h; + if (screen_set_window_property_iv(sWindow, SCREEN_PROPERTY_BUFFER_SIZE, value)) { screen_destroy_window(sWindow); fgError("Could not set window buffer size"); return;