mirror of
https://port.numenaute.org/aleajactaest/khanat-code-old.git
synced 2024-11-27 09:16:18 +00:00
Changed: Minor changes
This commit is contained in:
parent
3fa369e73c
commit
bc50742bfe
4 changed files with 12 additions and 12 deletions
|
@ -1758,14 +1758,14 @@ bool CDriverGL::setWindowStyle(EWindowStyle windowStyle)
|
||||||
#elif defined(NL_OS_MAC)
|
#elif defined(NL_OS_MAC)
|
||||||
|
|
||||||
// leave fullscreen mode, enter windowed mode
|
// leave fullscreen mode, enter windowed mode
|
||||||
if(windowStyle == EWSWindowed && [containerView() isInFullScreenMode])
|
if (windowStyle == EWSWindowed && [containerView() isInFullScreenMode])
|
||||||
{
|
{
|
||||||
// disable manual setting of back buffer size, cocoa handles this
|
// disable manual setting of back buffer size, cocoa handles this
|
||||||
// automatically as soon as the view gets resized
|
// automatically as soon as the view gets resized
|
||||||
CGLError error = CGLDisable((CGLContextObj)[_ctx CGLContextObj],
|
CGLError error = CGLDisable((CGLContextObj)[_ctx CGLContextObj],
|
||||||
kCGLCESurfaceBackingSize);
|
kCGLCESurfaceBackingSize);
|
||||||
|
|
||||||
if(error != kCGLNoError)
|
if (error != kCGLNoError)
|
||||||
nlerror("cannot disable kCGLCESurfaceBackingSize (%s)",
|
nlerror("cannot disable kCGLCESurfaceBackingSize (%s)",
|
||||||
CGLErrorString(error));
|
CGLErrorString(error));
|
||||||
|
|
||||||
|
@ -1780,13 +1780,13 @@ bool CDriverGL::setWindowStyle(EWindowStyle windowStyle)
|
||||||
}
|
}
|
||||||
|
|
||||||
// enter fullscreen, leave windowed mode
|
// enter fullscreen, leave windowed mode
|
||||||
else if(windowStyle == EWSFullscreen && ![containerView() isInFullScreenMode])
|
else if (windowStyle == EWSFullscreen && ![containerView() isInFullScreenMode])
|
||||||
{
|
{
|
||||||
// enable manual back buffer size for mode setting in fullscreen
|
// enable manual back buffer size for mode setting in fullscreen
|
||||||
CGLError error = CGLEnable((CGLContextObj)[_ctx CGLContextObj],
|
CGLError error = CGLEnable((CGLContextObj)[_ctx CGLContextObj],
|
||||||
kCGLCESurfaceBackingSize);
|
kCGLCESurfaceBackingSize);
|
||||||
|
|
||||||
if(error != kCGLNoError)
|
if (error != kCGLNoError)
|
||||||
nlerror("cannot enable kCGLCESurfaceBackingSize (%s)",
|
nlerror("cannot enable kCGLCESurfaceBackingSize (%s)",
|
||||||
CGLErrorString(error));
|
CGLErrorString(error));
|
||||||
|
|
||||||
|
|
|
@ -31,8 +31,7 @@ static void windowDidMove(NSWindow* window, CDriverGL* driver)
|
||||||
driver->_WindowX = windowRect.origin.x;
|
driver->_WindowX = windowRect.origin.x;
|
||||||
|
|
||||||
// map y from cocoa to NeL coordinates before setting in driver
|
// map y from cocoa to NeL coordinates before setting in driver
|
||||||
driver->_WindowY =
|
driver->_WindowY = screenRect.size.height - windowRect.size.height - windowRect.origin.y;
|
||||||
screenRect.size.height - windowRect.size.height - windowRect.origin.y;
|
|
||||||
}
|
}
|
||||||
|
|
||||||
@implementation CocoaWindowDelegate
|
@implementation CocoaWindowDelegate
|
||||||
|
|
|
@ -298,7 +298,8 @@ void CRGBA::modulateColors(CRGBA *dest, const CRGBA *src1, const CRGBA *src2, ui
|
||||||
uint64 blank = 0;
|
uint64 blank = 0;
|
||||||
/// well, this could be further optimized when stride is 4
|
/// well, this could be further optimized when stride is 4
|
||||||
if (dup == 1)
|
if (dup == 1)
|
||||||
{ __asm
|
{
|
||||||
|
__asm
|
||||||
{
|
{
|
||||||
push ebp
|
push ebp
|
||||||
movq mm2, blank
|
movq mm2, blank
|
||||||
|
|
|
@ -217,7 +217,7 @@ void connectionRestoreVideoMode ()
|
||||||
mode.Depth = uint8(ClientCfg.Depth);
|
mode.Depth = uint8(ClientCfg.Depth);
|
||||||
mode.Width = ClientCfg.Width;
|
mode.Width = ClientCfg.Width;
|
||||||
mode.Height = ClientCfg.Height;
|
mode.Height = ClientCfg.Height;
|
||||||
mode.Frequency= ClientCfg.Frequency;
|
mode.Frequency = ClientCfg.Frequency;
|
||||||
setVideoMode(mode);
|
setVideoMode(mode);
|
||||||
}
|
}
|
||||||
|
|
||||||
|
|
Loading…
Reference in a new issue