No real changes, just restrict wxMacEditHelper interface.
There is no need to provide GetCurrentlyEditedView() when a simpler IsCurrentlyEditedView() suffices. git-svn-id: https://svn.wxwidgets.org/svn/wx/wxWidgets/trunk@75045 c3d73ce0-8a6f-49c7-b76d-6d57e0e08775
This commit is contained in:
@@ -89,8 +89,12 @@ public :
|
|||||||
ms_viewCurrentlyEdited = m_viewPreviouslyEdited;
|
ms_viewCurrentlyEdited = m_viewPreviouslyEdited;
|
||||||
}
|
}
|
||||||
|
|
||||||
// Returns the last view we were instantiated for or NULL.
|
// Returns true if this view is the one currently being changed by the
|
||||||
static NSView *GetCurrentlyEditedView() { return ms_viewCurrentlyEdited; }
|
// program.
|
||||||
|
static bool IsCurrentlyEditedView(NSView* v)
|
||||||
|
{
|
||||||
|
return v == ms_viewCurrentlyEdited;
|
||||||
|
}
|
||||||
|
|
||||||
protected :
|
protected :
|
||||||
BOOL m_formerEditable ;
|
BOOL m_formerEditable ;
|
||||||
@@ -334,7 +338,7 @@ NSView* wxMacEditHelper::ms_viewCurrentlyEdited = nil;
|
|||||||
{
|
{
|
||||||
wxUnusedVar(aNotification);
|
wxUnusedVar(aNotification);
|
||||||
|
|
||||||
if ( self == wxMacEditHelper::GetCurrentlyEditedView() )
|
if ( wxMacEditHelper::IsCurrentlyEditedView(self) )
|
||||||
{
|
{
|
||||||
// This notification is generated as the result of calling our own
|
// This notification is generated as the result of calling our own
|
||||||
// wxTextCtrl method (e.g. WriteText()) and doesn't correspond to any
|
// wxTextCtrl method (e.g. WriteText()) and doesn't correspond to any
|
||||||
|
Reference in New Issue
Block a user