Revert part of 49140 on the 2.8 branch making it continue to use

wxNonControlNSControl where WXNSView would do except that on the 2.8
branch I use a hack to stuff the control label in there since
2.8 has no m_labelOrig field in wxControlBase.


git-svn-id: https://svn.wxwidgets.org/svn/wx/wxWidgets/branches/WX_2_8_BRANCH@49217 c3d73ce0-8a6f-49c7-b76d-6d57e0e08775
This commit is contained in:
David Elliott
2007-10-18 08:30:39 +00:00
parent 0d220868d4
commit df13d77add

View File

@@ -22,7 +22,6 @@
#include "wx/cocoa/string.h"
#include "wx/cocoa/trackingrectmanager.h"
#include "wx/cocoa/objc/objc_uniquifying.h"
#include "wx/cocoa/objc/NSView.h"
#import <AppKit/NSControl.h>
#import <AppKit/NSCell.h>
@@ -211,7 +210,7 @@ bool wxControl::Create(wxWindow *parent, wxWindowID winid,
return false;
wxLogTrace(wxTRACE_COCOA,wxT("Created control with id=%d"),GetId());
m_cocoaNSView = NULL;
SetNSControl([[WX_GET_OBJC_CLASS(WXNSView) alloc] initWithFrame: MakeDefaultNSRect(size)]);
SetNSControl([[WX_GET_OBJC_CLASS(wxNonControlNSControl) alloc] initWithFrame: MakeDefaultNSRect(size)]);
// NOTE: YES we want to release this (to match the alloc).
// DoAddChild(this) will retain us again since addSubView doesn't.
[m_cocoaNSView release];