devdraw: OS X: go full screen on largest device (Eric Nichols)
This commit is contained in:
parent
e05b0ff3eb
commit
cdead40b9b
1 changed files with 3 additions and 1 deletions
|
|
@ -529,6 +529,7 @@ fullscreen(void)
|
||||||
{
|
{
|
||||||
static Ptr restore;
|
static Ptr restore;
|
||||||
static WindowRef oldwindow;
|
static WindowRef oldwindow;
|
||||||
|
GDHandle device;
|
||||||
|
|
||||||
if(osx.isfullscreen){
|
if(osx.isfullscreen){
|
||||||
EndFullScreen(restore, 0);
|
EndFullScreen(restore, 0);
|
||||||
|
|
@ -538,7 +539,8 @@ fullscreen(void)
|
||||||
}else{
|
}else{
|
||||||
HideWindow(osx.window);
|
HideWindow(osx.window);
|
||||||
oldwindow = osx.window;
|
oldwindow = osx.window;
|
||||||
BeginFullScreen(&restore, 0, 0, 0, &osx.window, 0, 0);
|
GetWindowGreatestAreaDevice(osx.window, kWindowTitleBarRgn, &device, nil);
|
||||||
|
BeginFullScreen(&restore, device, 0, 0, &osx.window, 0, 0);
|
||||||
osx.isfullscreen = 1;
|
osx.isfullscreen = 1;
|
||||||
osx.fullscreentime = msec();
|
osx.fullscreentime = msec();
|
||||||
}
|
}
|
||||||
|
|
|
||||||
Loading…
Add table
Add a link
Reference in a new issue