]> git.saurik.com Git - wxWidgets.git/blobdiff - src/osx/cocoa/nonownedwnd.mm
applying editor part of patch, see #15003
[wxWidgets.git] / src / osx / cocoa / nonownedwnd.mm
index 103f97a7e3da0b52e16add3969c4646201f5b9e0..bbba049d28bba4b0e076600fe0fc9fde7256cdc3 100644 (file)
@@ -450,7 +450,7 @@ extern int wxOSXGetIdFromSelector(SEL action );
         if ( wxpeer )
         {
             wxpeer->HandleActivated(0, false);
-            // as for wx the deactivation also means loosing focus we
+            // as for wx the deactivation also means losing focus we
             // must trigger this manually
             [window makeFirstResponder:nil];
             
@@ -484,6 +484,19 @@ extern int wxOSXGetIdFromSelector(SEL action );
         }
         return editor;
     } 
+    else if ([anObject isKindOfClass:[wxNSComboBox class]])
+    {
+        wxNSComboBox * cb = (wxNSComboBox*) anObject;
+        wxNSTextFieldEditor* editor = [cb fieldEditor];
+        if ( editor == nil )
+        {
+            editor = [[wxNSTextFieldEditor alloc] init];
+            [editor setFieldEditor:YES];
+            [cb setFieldEditor:editor];
+            [editor release];
+        }
+        return editor;
+    }    
  
     return nil;
 }