remove unused stuff

git-svn-id: https://svn.wxwidgets.org/svn/wx/wxWidgets/trunk@41781 c3d73ce0-8a6f-49c7-b76d-6d57e0e08775
This commit is contained in:
Paul Cornett 2006-10-09 05:14:39 +00:00
parent eea2724a28
commit 716d032736
20 changed files with 29 additions and 131 deletions

View File

@ -71,10 +71,6 @@
// Keep linker from discarding wxStockGDIMac // Keep linker from discarding wxStockGDIMac
wxFORCE_LINK_MODULE(gdiobj) wxFORCE_LINK_MODULE(gdiobj)
#if wxUSE_THREADS
extern size_t g_numberOfThreads;
#endif
// statics for implementation // statics for implementation
static bool s_inYield = false; static bool s_inYield = false;
static bool s_inReceiveEvent = false ; static bool s_inReceiveEvent = false ;
@ -90,9 +86,7 @@ END_EVENT_TABLE()
// platform specific static variables // platform specific static variables
const short kMacMinHeap = (29 * 1024) ; static const short kwxMacAppleMenuId = 1 ;
const short kwxMacMenuBarResource = 1 ;
const short kwxMacAppleMenuId = 1 ;
wxWindow* wxApp::s_captureWindow = NULL ; wxWindow* wxApp::s_captureWindow = NULL ;
long wxApp::s_lastModifiers = 0 ; long wxApp::s_lastModifiers = 0 ;

View File

@ -59,7 +59,6 @@ static const int TEXTFOCUSBORDER = 3 ;
static const wxCoord MARGIN = 2; static const wxCoord MARGIN = 2;
static const int TEXTFOCUSBORDER = 0 ; static const int TEXTFOCUSBORDER = 0 ;
#endif #endif
static const int POPUPHEIGHT = 23;
// ---------------------------------------------------------------------------- // ----------------------------------------------------------------------------
@ -119,7 +118,7 @@ protected:
wxCommandEvent event( wxEVT_COMMAND_BUTTON_CLICKED, def->GetId() ); wxCommandEvent event( wxEVT_COMMAND_BUTTON_CLICKED, def->GetId() );
event.SetEventObject(def); event.SetEventObject(def);
def->Command(event); def->Command(event);
} }
} }
return; return;

View File

@ -46,8 +46,7 @@ protected:
long m_themeCursor; long m_themeCursor;
}; };
#define M_CURSORDATA ((wxCursorRefData *)m_refData) #define M_CURSORDATA wx_static_cast(wxCursorRefData*, m_refData)
#define M_CURSORHANDLERDATA ((wxCursorRefData *)bitmap->m_refData)
const short kwxCursorBullseye = 0; const short kwxCursorBullseye = 0;
const short kwxCursorBlank = 1; const short kwxCursorBlank = 1;

View File

@ -55,9 +55,6 @@ const double RAD2DEG = 180.0 / M_PI;
const short kEmulatedMode = -1 ; const short kEmulatedMode = -1 ;
const short kUnsupportedMode = -2 ; const short kUnsupportedMode = -2 ;
extern TECObjectRef s_TECNativeCToUnicode ;
wxMacPortSetter::wxMacPortSetter( const wxDC* dc ) : wxMacPortSetter::wxMacPortSetter( const wxDC* dc ) :
m_ph( (GrafPtr) dc->m_macPort ) m_ph( (GrafPtr) dc->m_macPort )
{ {
@ -154,13 +151,6 @@ wxMacWindowStateSaver::~wxMacWindowStateSaver()
SetThemeDrawingState( m_themeDrawingState , true ) ; SetThemeDrawingState( m_themeDrawingState , true ) ;
} }
//-----------------------------------------------------------------------------
// Local functions
//-----------------------------------------------------------------------------
static inline double dmin(double a, double b) { return a < b ? a : b; }
static inline double dmax(double a, double b) { return a > b ? a : b; }
static inline double DegToRad(double deg) { return (deg * M_PI) / 180.0; }
//----------------------------------------------------------------------------- //-----------------------------------------------------------------------------
// wxDC // wxDC
//----------------------------------------------------------------------------- //-----------------------------------------------------------------------------

View File

@ -29,8 +29,6 @@
// constants // constants
//----------------------------------------------------------------------------- //-----------------------------------------------------------------------------
#define RAD2DEG 57.2957795131
//----------------------------------------------------------------------------- //-----------------------------------------------------------------------------
// wxPaintDC // wxPaintDC
//----------------------------------------------------------------------------- //-----------------------------------------------------------------------------
@ -124,7 +122,6 @@ wxWindowDC::wxWindowDC(wxWindow *window)
WindowRef windowref = (WindowRef) rootwindow->MacGetWindowRef() ; WindowRef windowref = (WindowRef) rootwindow->MacGetWindowRef() ;
int x , y ; int x , y ;
x = y = 0 ; x = y = 0 ;
wxSize size = window->GetSize() ;
window->MacWindowToRootWindow( &x , &y ) ; window->MacWindowToRootWindow( &x , &y ) ;
m_macPort = UMAGetWindowPort( windowref ) ; m_macPort = UMAGetWindowPort( windowref ) ;
m_ok = true ; m_ok = true ;

View File

@ -1,5 +1,5 @@
///////////////////////////////////////////////////////////////////////////// /////////////////////////////////////////////////////////////////////////////
// Name: msw/dir.cpp // Name: mac/dirmac.cpp
// Purpose: wxDir implementation for Mac // Purpose: wxDir implementation for Mac
// Author: Stefan Csomor // Author: Stefan Csomor
// Modified by: // Modified by:
@ -24,37 +24,17 @@
#pragma hdrstop #pragma hdrstop
#endif #endif
#include "wx/dir.h"
#ifndef WX_PRECOMP #ifndef WX_PRECOMP
#include "wx/intl.h" #include "wx/intl.h"
#include "wx/log.h" #include "wx/log.h"
#endif // PCH #endif // PCH
#include "wx/dir.h"
#include "wx/filefn.h" // for wxDirExists() #include "wx/filefn.h" // for wxDirExists()
#ifndef __DARWIN__
#include <windows.h>
#endif
#include "wx/filename.h" #include "wx/filename.h"
#include "wx/mac/private.h" #include "wx/mac/private.h"
#include "MoreFilesX.h"
// ----------------------------------------------------------------------------
// constants
// ----------------------------------------------------------------------------
#ifndef MAX_PATH
#define MAX_PATH 260 // from VC++ headers
#endif
// ----------------------------------------------------------------------------
// macros
// ----------------------------------------------------------------------------
#define M_DIR ((wxDirData *)m_data)
// ---------------------------------------------------------------------------- // ----------------------------------------------------------------------------
// private classes // private classes
// ---------------------------------------------------------------------------- // ----------------------------------------------------------------------------
@ -226,7 +206,7 @@ wxDir::wxDir(const wxString& dirname)
bool wxDir::Open(const wxString& dirname) bool wxDir::Open(const wxString& dirname)
{ {
delete M_DIR; delete m_data;
m_data = new wxDirData(dirname); m_data = new wxDirData(dirname);
return true; return true;
@ -242,7 +222,7 @@ wxString wxDir::GetName() const
wxString name; wxString name;
if ( m_data ) if ( m_data )
{ {
name = M_DIR->GetName(); name = m_data->GetName();
if ( !name.empty() && (name.Last() == _T('/')) ) if ( !name.empty() && (name.Last() == _T('/')) )
{ {
// chop off the last (back)slash // chop off the last (back)slash
@ -255,10 +235,8 @@ wxString wxDir::GetName() const
wxDir::~wxDir() wxDir::~wxDir()
{ {
if (M_DIR != NULL) { delete m_data;
delete M_DIR; m_data = NULL;
m_data = NULL;
}
} }
// ---------------------------------------------------------------------------- // ----------------------------------------------------------------------------
@ -271,10 +249,10 @@ bool wxDir::GetFirst(wxString *filename,
{ {
wxCHECK_MSG( IsOpened(), false, _T("must wxDir::Open() first") ); wxCHECK_MSG( IsOpened(), false, _T("must wxDir::Open() first") );
M_DIR->Rewind(); m_data->Rewind();
M_DIR->SetFileSpec(filespec); m_data->SetFileSpec(filespec);
M_DIR->SetFlags(flags); m_data->SetFlags(flags);
return GetNext(filename); return GetNext(filename);
} }
@ -285,5 +263,5 @@ bool wxDir::GetNext(wxString *filename) const
wxCHECK_MSG( filename, false, _T("bad pointer in wxDir::GetNext()") ); wxCHECK_MSG( filename, false, _T("bad pointer in wxDir::GetNext()") );
return M_DIR->Read(filename); return m_data->Read(filename);
} }

View File

@ -17,7 +17,6 @@
#ifndef WX_PRECOMP #ifndef WX_PRECOMP
#include "wx/app.h" #include "wx/app.h"
#include "wx/window.h"
#include "wx/toplevel.h" #include "wx/toplevel.h"
#include "wx/gdicmn.h" #include "wx/gdicmn.h"
#endif // WX_PRECOMP #endif // WX_PRECOMP
@ -38,8 +37,7 @@ typedef struct
wxWindow *m_currentTargetWindow; wxWindow *m_currentTargetWindow;
wxDropTarget *m_currentTarget; wxDropTarget *m_currentTarget;
wxDropSource *m_currentSource; wxDropSource *m_currentSource;
} } MacTrackingGlobals;
MacTrackingGlobals;
MacTrackingGlobals gTrackingGlobals; MacTrackingGlobals gTrackingGlobals;
@ -113,7 +111,6 @@ bool wxDropTarget::CurrentDragHasSupportedFormat()
if ( !supported ) if ( !supported )
{ {
UInt16 items; UInt16 items;
OSErr result;
ItemReference theItem; ItemReference theItem;
FlavorType theType; FlavorType theType;
UInt16 flavors = 0; UInt16 flavors = 0;
@ -127,7 +124,7 @@ bool wxDropTarget::CurrentDragHasSupportedFormat()
for ( UInt16 flavor = 1; flavor <= flavors; ++flavor ) for ( UInt16 flavor = 1; flavor <= flavors; ++flavor )
{ {
result = GetFlavorType( (DragReference)m_currentDrag, theItem, flavor, &theType ); GetFlavorType( (DragReference)m_currentDrag, theItem, flavor, &theType );
if ( m_dataObject->IsSupportedFormat( wxDataFormat( theType ) ) ) if ( m_dataObject->IsSupportedFormat( wxDataFormat( theType ) ) )
{ {
supported = true; supported = true;
@ -338,11 +335,10 @@ wxDragResult wxDropSource::DoDragDrop(int flags)
if ((m_data == NULL) || (m_data->GetFormatCount() == 0)) if ((m_data == NULL) || (m_data->GetFormatCount() == 0))
return (wxDragResult)wxDragNone; return (wxDragResult)wxDragNone;
OSStatus result;
DragReference theDrag; DragReference theDrag;
RgnHandle dragRegion; RgnHandle dragRegion;
if ((result = NewDrag( &theDrag )) != noErr) if (NewDrag( &theDrag ) != noErr)
return wxDragNone; return wxDragNone;
// add data to drag // add data to drag
@ -454,7 +450,7 @@ wxDragResult wxDropSource::DoDragDrop(int flags)
// only when drag was successfully completed // only when drag was successfully completed
gTrackingGlobals.m_currentSource = this; gTrackingGlobals.m_currentSource = this;
result = TrackDrag( theDrag, ev, dragRegion ); TrackDrag( theDrag, ev, dragRegion );
DisposeRgn( dragRegion ); DisposeRgn( dragRegion );
DisposeDrag( theDrag ); DisposeDrag( theDrag );
gTrackingGlobals.m_currentSource = NULL; gTrackingGlobals.m_currentSource = NULL;

View File

@ -30,12 +30,8 @@
#include "PLStringFuncs.h" #include "PLStringFuncs.h"
#endif #endif
#include "MoreFilesX.h"
IMPLEMENT_CLASS(wxFileDialog, wxFileDialogBase) IMPLEMENT_CLASS(wxFileDialog, wxFileDialogBase)
extern bool gUseNavServices;
// the data we need to pass to our standard file hook routine // the data we need to pass to our standard file hook routine
// includes a pointer to the dialog, a pointer to the standard // includes a pointer to the dialog, a pointer to the standard
// file reply record (so we can inspect the current selection) // file reply record (so we can inspect the current selection)
@ -319,7 +315,6 @@ int wxFileDialog::ShowModal()
NavDialogRef dialog; NavDialogRef dialog;
NavObjectFilterUPP navFilterUPP = NULL; NavObjectFilterUPP navFilterUPP = NULL;
CFArrayRef cfArray = NULL; // for popupExtension
OpenUserDataRec myData; OpenUserDataRec myData;
myData.defaultLocation = m_dir; myData.defaultLocation = m_dir;
@ -386,8 +381,6 @@ int wxFileDialog::ShowModal()
// clean up filter related data, etc. // clean up filter related data, etc.
if (navFilterUPP) if (navFilterUPP)
::DisposeNavObjectFilterUPP(navFilterUPP); ::DisposeNavObjectFilterUPP(navFilterUPP);
if (cfArray)
::CFRelease(cfArray);
if (err != noErr) if (err != noErr)
return wxID_CANCEL; return wxID_CANCEL;

View File

@ -42,20 +42,11 @@ END_EVENT_TABLE()
static const wxChar *TRACE_MDI = _T("mdi"); static const wxChar *TRACE_MDI = _T("mdi");
static const int IDM_WINDOWTILE = 4001;
static const int IDM_WINDOWTILEHOR = 4001; static const int IDM_WINDOWTILEHOR = 4001;
static const int IDM_WINDOWCASCADE = 4002; static const int IDM_WINDOWCASCADE = 4002;
static const int IDM_WINDOWICONS = 4003; static const int IDM_WINDOWICONS = 4003;
static const int IDM_WINDOWNEXT = 4004; static const int IDM_WINDOWNEXT = 4004;
static const int IDM_WINDOWTILEVERT = 4005; static const int IDM_WINDOWTILEVERT = 4005;
static const int IDM_WINDOWPREV = 4006;
// This range gives a maximum of 500 MDI children. Should be enough :-)
static const int wxFIRST_MDI_CHILD = 4100;
static const int wxLAST_MDI_CHILD = 4600;
// Status border dimensions
static const int wxTHICK_LINE_BORDER = 3;
// ---------------------------------------------------------------------------- // ----------------------------------------------------------------------------
// Parent frame // Parent frame

View File

@ -24,7 +24,6 @@
#include "wx/log.h" #include "wx/log.h"
#include "wx/app.h" #include "wx/app.h"
#include "wx/utils.h" #include "wx/utils.h"
#include "wx/window.h"
#include "wx/frame.h" #include "wx/frame.h"
#include "wx/menuitem.h" #include "wx/menuitem.h"
#endif #endif
@ -41,8 +40,7 @@ IMPLEMENT_DYNAMIC_CLASS(wxMenuBar, wxEvtHandler)
// the (popup) menu title has this special id // the (popup) menu title has this special id
static const int idMenuTitle = -3; static const int idMenuTitle = -3;
const short kwxMacMenuBarResource = 1 ; static const short kwxMacAppleMenuId = 1 ;
const short kwxMacAppleMenuId = 1 ;
// Find an item given the Macintosh Menu Reference // Find an item given the Macintosh Menu Reference
@ -488,12 +486,10 @@ void wxMenu::MacAfterDisplay( bool isSubMenu )
if ( isSubMenu ) if ( isSubMenu )
::DeleteMenu(MacGetMenuId()); ::DeleteMenu(MacGetMenuId());
wxMenuItem* previousItem = NULL ;
wxMenuItemList::compatibility_iterator node; wxMenuItemList::compatibility_iterator node;
wxMenuItem *item; wxMenuItem *item;
int pos ;
for (pos = 0, node = GetMenuItems().GetFirst(); node; node = node->GetNext(), pos++) for (node = GetMenuItems().GetFirst(); node; node = node->GetNext())
{ {
item = (wxMenuItem *)node->GetData(); item = (wxMenuItem *)node->GetData();
wxMenu* subMenu = item->GetSubMenu() ; wxMenu* subMenu = item->GetSubMenu() ;
@ -505,8 +501,6 @@ void wxMenu::MacAfterDisplay( bool isSubMenu )
{ {
// no need to undo hidings // no need to undo hidings
} }
previousItem = item ;
} }
} }
@ -663,12 +657,11 @@ void wxMenuBar::MacInstallMenuBar()
{ {
wxMenuItemList::compatibility_iterator node; wxMenuItemList::compatibility_iterator node;
wxMenuItem *item; wxMenuItem *item;
int pos ;
wxMenu* menu = menuIter->GetData() , *subMenu = NULL ; wxMenu* menu = menuIter->GetData() , *subMenu = NULL ;
if ( m_titles[i] == wxT("?") || m_titles[i] == wxT("&?") || m_titles[i] == wxApp::s_macHelpMenuTitleName ) if ( m_titles[i] == wxT("?") || m_titles[i] == wxT("&?") || m_titles[i] == wxApp::s_macHelpMenuTitleName )
{ {
for (pos = 0 , node = menu->GetMenuItems().GetFirst(); node; node = node->GetNext(), pos++) for (node = menu->GetMenuItems().GetFirst(); node; node = node->GetNext())
{ {
item = (wxMenuItem *)node->GetData(); item = (wxMenuItem *)node->GetData();
subMenu = item->GetSubMenu() ; subMenu = item->GetSubMenu() ;

View File

@ -48,10 +48,6 @@ private:
#endif #endif
}; };
extern bool wxClipboardIsOpen;
wxMetafileRefData::wxMetafileRefData() wxMetafileRefData::wxMetafileRefData()
{ {
m_metafile = NULL; m_metafile = NULL;

View File

@ -1311,7 +1311,6 @@ private:
// ---------------------------------------------------------------------------- // ----------------------------------------------------------------------------
#define wxCFDATA_RELEASEBUFFER 1 #define wxCFDATA_RELEASEBUFFER 1
#define wxCFDATA_RETAINBUFFER 0
class wxCFData class wxCFData
{ {

View File

@ -321,14 +321,11 @@ void wxRadioBox::Command( wxCommandEvent& event )
// //
void wxRadioBox::SetFocus() void wxRadioBox::SetFocus()
{ {
int i;
wxRadioButton *current; wxRadioButton *current;
i = 0;
current = m_radioButtonCycle; current = m_radioButtonCycle;
while (!current->GetValue()) while (!current->GetValue())
{ {
i++;
current = current->NextInCycle(); current = current->NextInCycle();
} }

View File

@ -143,7 +143,7 @@ wxInt32 wxRadioButton::MacControlHit( WXEVENTHANDLERREF WXUNUSED(handler), WXEVE
wxRadioButton *wxRadioButton::AddInCycle(wxRadioButton *cycle) wxRadioButton *wxRadioButton::AddInCycle(wxRadioButton *cycle)
{ {
wxRadioButton *next, *current; wxRadioButton *current;
if (cycle == NULL) if (cycle == NULL)
{ {
@ -152,7 +152,7 @@ wxRadioButton *wxRadioButton::AddInCycle(wxRadioButton *cycle)
else else
{ {
current = cycle; current = cycle;
while ((next = current->m_cycle) != cycle) while (current->m_cycle != cycle)
current = current->m_cycle; current = current->m_cycle;
m_cycle = cycle; m_cycle = cycle;

View File

@ -22,7 +22,6 @@ BEGIN_EVENT_TABLE(wxSlider, wxControl)
END_EVENT_TABLE() END_EVENT_TABLE()
// The dimensions of the different styles of sliders (from Aqua document) // The dimensions of the different styles of sliders (from Aqua document)
#define wxSLIDER_DIMENSIONACROSS 15
#define wxSLIDER_DIMENSIONACROSS_WITHTICKMARKS 24 #define wxSLIDER_DIMENSIONACROSS_WITHTICKMARKS 24
#define wxSLIDER_DIMENSIONACROSS_ARROW 18 #define wxSLIDER_DIMENSIONACROSS_ARROW 18
@ -416,13 +415,11 @@ wxSize wxSlider::DoGetBestSize() const
void wxSlider::DoSetSize(int x, int y, int w, int h, int sizeFlags) void wxSlider::DoSetSize(int x, int y, int w, int h, int sizeFlags)
{ {
int xborder, yborder; int yborder = 0;
int minValWidth, maxValWidth, textheight; int minValWidth, maxValWidth, textheight;
int sliderBreadth; int sliderBreadth;
int width = w; int width = w;
xborder = yborder = 0;
if (GetWindowStyle() & wxSL_LABELS) if (GetWindowStyle() & wxSL_LABELS)
{ {
wxString text; wxString text;

View File

@ -64,13 +64,6 @@
#include "wx/mac/uma.h" #include "wx/mac/uma.h"
// if this is set to 1 then under OSX 10.2 the 'classic' MLTE implementation will be used
// if set to 0 then the unicode textctrl will be used
#ifndef wxMAC_AWAYS_USE_MLTE
#define wxMAC_AWAYS_USE_MLTE 1
#endif
#ifndef __WXMAC_OSX__ #ifndef __WXMAC_OSX__
enum enum
{ {

View File

@ -26,9 +26,6 @@
#include "wx/mac/uma.h" #include "wx/mac/uma.h"
// Button // Button
static const int kMacOSXHorizontalBorder = 2 ;
static const int kMacOSXVerticalBorder = 4 ;
// ---------------------------------------------------------------------------- // ----------------------------------------------------------------------------
// macros // macros
// ---------------------------------------------------------------------------- // ----------------------------------------------------------------------------

View File

@ -392,8 +392,6 @@ void wxToolBarTool::SetPosition( const wxPoint& position )
m_x = position.x; m_x = position.x;
m_y = position.y; m_y = position.y;
int x, y;
x = y = 0;
int mac_x = position.x; int mac_x = position.x;
int mac_y = position.y; int mac_y = position.y;
@ -714,6 +712,7 @@ CantCreateEvent :
return result ; return result ;
} }
#if wxMAC_USE_NATIVE_TOOLBAR
static const EventTypeSpec kToolbarEvents[] = static const EventTypeSpec kToolbarEvents[] =
{ {
{ kEventClassToolbar, kEventToolbarGetDefaultIdentifiers }, { kEventClassToolbar, kEventToolbarGetDefaultIdentifiers },
@ -777,6 +776,7 @@ static OSStatus ToolbarDelegateHandler( EventHandlerCallRef inCallRef, EventRef
} }
return result ; return result ;
} }
#endif // wxMAC_USE_NATIVE_TOOLBAR
// also for the toolbar we have the dual implementation: // also for the toolbar we have the dual implementation:
// only when MacInstallNativeToolbar is called is the native toolbar set as the window toolbar // only when MacInstallNativeToolbar is called is the native toolbar set as the window toolbar
@ -1070,7 +1070,6 @@ bool wxToolBar::Realize()
bool lastIsRadio = false; bool lastIsRadio = false;
bool curIsRadio = false; bool curIsRadio = false;
bool setChoiceInGroup = false;
#if wxMAC_USE_NATIVE_TOOLBAR #if wxMAC_USE_NATIVE_TOOLBAR
CFIndex currentPosition = 0; CFIndex currentPosition = 0;
@ -1165,8 +1164,6 @@ bool wxToolBar::Realize()
{ {
if ( tool->IsToggled() ) if ( tool->IsToggled() )
DoToggleTool( tool, true ); DoToggleTool( tool, true );
setChoiceInGroup = false;
} }
else else
{ {
@ -1175,7 +1172,6 @@ bool wxToolBar::Realize()
if ( tool->Toggle( true ) ) if ( tool->Toggle( true ) )
{ {
DoToggleTool( tool, true ); DoToggleTool( tool, true );
setChoiceInGroup = true;
} }
} }
else if ( tool->IsToggled() ) else if ( tool->IsToggled() )

View File

@ -81,8 +81,6 @@ END_EVENT_TABLE()
// Carbon Events // Carbon Events
// --------------------------------------------------------------------------- // ---------------------------------------------------------------------------
extern long wxMacTranslateKey(unsigned char key, unsigned char code) ;
static const EventTypeSpec eventList[] = static const EventTypeSpec eventList[] =
{ {
// TODO: remove control related event like key and mouse (except for WindowLeave events) // TODO: remove control related event like key and mouse (except for WindowLeave events)
@ -884,8 +882,7 @@ typedef struct
wxPoint m_position ; wxPoint m_position ;
wxSize m_size ; wxSize m_size ;
bool m_wasResizable ; bool m_wasResizable ;
} } FullScreenData ;
FullScreenData ;
void wxTopLevelWindowMac::Init() void wxTopLevelWindowMac::Init()
{ {
@ -1530,19 +1527,17 @@ void wxTopLevelWindowMac::MacPerformUpdates()
EventRef currentEvent = (EventRef) wxTheApp->MacGetCurrentEvent() ; EventRef currentEvent = (EventRef) wxTheApp->MacGetCurrentEvent() ;
UInt32 currentEventClass = 0 ; UInt32 currentEventClass = 0 ;
UInt32 currentEventKind = 0 ;
if ( currentEvent != NULL ) if ( currentEvent != NULL )
{ {
currentEventClass = ::GetEventClass( currentEvent ) ; currentEventClass = ::GetEventClass( currentEvent ) ;
currentEventKind = ::GetEventKind( currentEvent ) ; ::GetEventKind( currentEvent ) ;
} }
if ( currentEventClass != kEventClassMenu ) if ( currentEventClass != kEventClassMenu )
{ {
// when tracking a menu, strange redraw errors occur if we flush now, so leave.. // when tracking a menu, strange redraw errors occur if we flush now, so leave..
EventRef theEvent; EventRef theEvent;
OSStatus status = noErr ; ReceiveNextEvent( 0 , NULL , kEventDurationNoWait , false , &theEvent ) ;
status = ReceiveNextEvent( 0 , NULL , kEventDurationNoWait , false , &theEvent ) ;
} }
} }
} }

View File

@ -48,8 +48,6 @@ static bool sUMAHasAquaLayout = false ;
static bool sUMAHasInittedAppearance = false; static bool sUMAHasInittedAppearance = false;
extern int gAGABackgroundColor ;
bool UMAHasAppearance() { return sUMAHasAppearance ; } bool UMAHasAppearance() { return sUMAHasAppearance ; }
long UMAGetAppearanceVersion() { return sUMAAppearanceVersion ; } long UMAGetAppearanceVersion() { return sUMAAppearanceVersion ; }
long UMAGetSystemVersion() { return sUMASystemVersion ; } long UMAGetSystemVersion() { return sUMASystemVersion ; }