Remove hack for SDL.

This commit is contained in:
Steve Checkoway
2006-01-14 23:24:30 +00:00
parent ebb91dc6e1
commit a0ed014d57
2 changed files with 0 additions and 68 deletions
@@ -6,16 +6,6 @@
#include "arch/ArchHooks/ArchHooks.h"
#include "DisplayResolutions.h"
#if defined(MACOSX)
extern "C"
{
extern void SetupWindow();
extern void SM_ShowCursor( bool b );
}
// SDL_ShowCursor doesn't seem to work on OS X any longer
#define SDL_ShowCursor(x) SM_ShowCursor( (x) == SDL_ENABLE )
#endif
LowLevelWindow_SDL::LowLevelWindow_SDL()
{
/* By default, ignore all SDL events. We'll enable them as we need them.
@@ -149,11 +139,6 @@ CString LowLevelWindow_SDL::TryVideoMode( const VideoModeParams &p, bool &bNewDe
LOG->Info( "SDL version: %i.%i.%i", ver->major, ver->minor, ver->patch );
}
#if defined(MACOSX)
if (p.windowed)
SetupWindow();
#endif
{
/* Find out what we really got. */
int r,g,b,a, colorbits, depth, stencil;
@@ -1,53 +0,0 @@
void SM_ShowCursor( bool b )
{
if( b )
[NSCursor unhide];
else
[NSCursor hide];
}
void SetupWindow()
{
NSWindow *window = [[NSApp windows] objectAtIndex:0];
// There's only one window ever so don't display in the menu
[window setExcludedFromWindowsMenu:YES];
// Maybe make drawing faster (I would hope that SDL does this already)
[window useOptimizedDrawing:YES];
// Remove the zoom button
[[window standardWindowButton:NSWindowZoomButton] setEnabled:NO];
// Set the max size to the current size
NSSize size = [window frame].size;
[window setMaxSize:size];
[window setMinSize:size];
}
/*
* (c) 2005 Steve Checkoway
* All rights reserved.
*
* Permission is hereby granted, free of charge, to any person obtaining a
* copy of this software and associated documentation files (the
* "Software"), to deal in the Software without restriction, including
* without limitation the rights to use, copy, modify, merge, publish,
* distribute, and/or sell copies of the Software, and to permit persons to
* whom the Software is furnished to do so, provided that the above
* copyright notice(s) and this permission notice appear in all copies of
* the Software and that both the above copyright notice(s) and this
* permission notice appear in supporting documentation.
*
* THE SOFTWARE IS PROVIDED "AS IS", WITHOUT WARRANTY OF ANY KIND, EXPRESS
* OR IMPLIED, INCLUDING BUT NOT LIMITED TO THE WARRANTIES OF
* MERCHANTABILITY, FITNESS FOR A PARTICULAR PURPOSE AND NONINFRINGEMENT OF
* THIRD PARTY RIGHTS. IN NO EVENT SHALL THE COPYRIGHT HOLDER OR HOLDERS
* INCLUDED IN THIS NOTICE BE LIABLE FOR ANY CLAIM, OR ANY SPECIAL INDIRECT
* OR CONSEQUENTIAL DAMAGES, OR ANY DAMAGES WHATSOEVER RESULTING FROM LOSS
* OF USE, DATA OR PROFITS, WHETHER IN AN ACTION OF CONTRACT, NEGLIGENCE OR
* OTHER TORTIOUS ACTION, ARISING OUT OF OR IN CONNECTION WITH THE USE OR
* PERFORMANCE OF THIS SOFTWARE.
*/