]> git.saurik.com Git - wxWidgets.git/blobdiff - src/osx/cocoa/utils.mm
Applied #10639 (Not all previewed fonts are displayed with the correct nameface)
[wxWidgets.git] / src / osx / cocoa / utils.mm
index 3fdecac375f7bd83ea8a996eacdfaf4a3aed5cba..4b22268b3ff215ba75faa8d8548b48e7d0e6a0cf 100644 (file)
@@ -52,7 +52,9 @@ void wxBell()
 
 void wxMacWakeUp()
 {
-    // TODO
+       NSEvent* wakeupEvent = [NSEvent otherEventWithType:NSApplicationDefined location:NSZeroPoint
+                                                                                modifierFlags:NSAnyEventMask timestamp:0 windowNumber:0 context:nil subtype:0 data1:0 data2:0];
+       [NSApp postEvent:wakeupEvent atStart:NO];
 }
 
 #endif // wxUSE_BASE
@@ -146,9 +148,9 @@ void wxMacWakeUp()
 }
 @end
 
-/* 
+/*
     allows ShowModal to work when using sheets.
-    see include/wx/osx/cocoa/private.h for more info 
+    see include/wx/osx/cocoa/private.h for more info
 */
 @implementation ModalDialogDelegate
 - (id)init
@@ -159,7 +161,7 @@ void wxMacWakeUp()
     return self;
 }
 
-- (BOOL)finished 
+- (BOOL)finished
 {
     return sheetFinished;
 }
@@ -298,7 +300,7 @@ wxBitmap wxWindowDCImpl::DoGetAsBitmap(const wxRect *subrect) const
     // called from OnPaint, even with the window's paint dc as source (see wxHTMLWindow)
     NSBitmapImageRep *rep = [[[NSBitmapImageRep alloc] initWithFocusedViewRect: [view bounds]] retain];
     [view unlockFocus];
-    
+
     wxBitmap bitmap(width, height);
     if ( [rep respondsToSelector:@selector(CGImage)] )
     {