]> git.saurik.com Git - wxWidgets.git/blobdiff - src/osx/carbon/taskbar.cpp
move wxGridCellRenderer::Draw before other derived classes implementations (no real...
[wxWidgets.git] / src / osx / carbon / taskbar.cpp
index 9bb02f5124e0c73dcf2e9e8bea5b6770ec381d98..58dc33c1a6bb9d25cdd457292853c9b94c277b61 100644 (file)
@@ -1,5 +1,5 @@
 ///////////////////////////////////////////////////////////////////////////////
 ///////////////////////////////////////////////////////////////////////////////
-// Name:        src/mac/carbon/taskbar.cpp
+// Name:        src/osx/carbon/taskbar.cpp
 // Purpose:     wxTaskBarIcon
 // Author:      Ryan Norton
 // Modified by:
 // Purpose:     wxTaskBarIcon
 // Author:      Ryan Norton
 // Modified by:
@@ -22,7 +22,7 @@
     #include "wx/icon.h"
 #endif
 
     #include "wx/icon.h"
 #endif
 
-#include "wx/mac/private.h"
+#include "wx/osx/private.h"
 
 class wxTaskBarIconImpl
 {
 
 class wxTaskBarIconImpl
 {
@@ -41,7 +41,7 @@ public:
     wxTaskBarIcon *m_parent;
     class wxTaskBarIconWindow *m_menuEventWindow;
 
     wxTaskBarIcon *m_parent;
     class wxTaskBarIconWindow *m_menuEventWindow;
 
-    DECLARE_NO_COPY_CLASS(wxTaskBarIconImpl)
+    wxDECLARE_NO_COPY_CLASS(wxTaskBarIconImpl);
 };
 
 //-----------------------------------------------------------------------------
 };
 
 //-----------------------------------------------------------------------------
@@ -186,9 +186,15 @@ wxDockEventHandler(EventHandlerCallRef WXUNUSED(inHandlerCallRef),
                     if (item && itemMenu )
                     {
                         if ( eventKind == kEventCommandProcess )
                     if (item && itemMenu )
                     {
                         if ( eventKind == kEventCommandProcess )
-                            err = itemMenu->MacHandleCommandProcess( item, id );
+                        {
+                            if ( itemMenu->HandleCommandProcess( item ) )
+                                err = noErr;
+                        }
                         else if ( eventKind == kEventCommandUpdateStatus )
                         else if ( eventKind == kEventCommandUpdateStatus )
-                            err = itemMenu->MacHandleCommandUpdateStatus( item, id );
+                        {
+                            if ( itemMenu->HandleCommandUpdateStatus( item ) )
+                                err = noErr;
+                        }
                     }
                 }
             }
                     }
                 }
             }
@@ -341,8 +347,7 @@ wxMenu * wxDockTaskBarIcon::DoCreatePopupMenu()
 
     if (theNewMenu)
     {
 
     if (theNewMenu)
     {
-        if (m_pMenu)
-            delete m_pMenu;
+        delete m_pMenu;
         m_pMenu = theNewMenu;
         m_pMenu->SetInvokingWindow(m_menuEventWindow);
     }
         m_pMenu = theNewMenu;
         m_pMenu->SetInvokingWindow(m_menuEventWindow);
     }
@@ -436,8 +441,7 @@ bool wxDockTaskBarIcon::PopupMenu(wxMenu *menu)
 {
     wxASSERT(menu != NULL);
 
 {
     wxASSERT(menu != NULL);
 
-    if (m_pMenu)
-        delete m_pMenu;
+    delete m_pMenu;
 
     // start copy of menu
     m_pMenu = wxDeepCopyMenu(menu);
 
     // start copy of menu
     m_pMenu = wxDeepCopyMenu(menu);