From a0ed014d579e4f0eb3f5d5d747d58c2784770a09 Mon Sep 17 00:00:00 2001 From: Steve Checkoway Date: Sat, 14 Jan 2006 23:24:30 +0000 Subject: [PATCH] Remove hack for SDL. --- .../LowLevelWindow/LowLevelWindow_SDL.cpp | 15 ------ stepmania/src/archutils/Darwin/WindowHelper.m | 53 ------------------- 2 files changed, 68 deletions(-) delete mode 100644 stepmania/src/archutils/Darwin/WindowHelper.m diff --git a/stepmania/src/arch/LowLevelWindow/LowLevelWindow_SDL.cpp b/stepmania/src/arch/LowLevelWindow/LowLevelWindow_SDL.cpp index a663be88f3..f891a12d9a 100644 --- a/stepmania/src/arch/LowLevelWindow/LowLevelWindow_SDL.cpp +++ b/stepmania/src/arch/LowLevelWindow/LowLevelWindow_SDL.cpp @@ -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; diff --git a/stepmania/src/archutils/Darwin/WindowHelper.m b/stepmania/src/archutils/Darwin/WindowHelper.m deleted file mode 100644 index 24a531273a..0000000000 --- a/stepmania/src/archutils/Darwin/WindowHelper.m +++ /dev/null @@ -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. - */ -