]> git.saurik.com Git - wxWidgets.git/commitdiff
draw the focus rect ourselves
authorStefan Csomor <csomor@advancedconcepts.ch>
Sun, 9 Jan 2005 05:58:58 +0000 (05:58 +0000)
committerStefan Csomor <csomor@advancedconcepts.ch>
Sun, 9 Jan 2005 05:58:58 +0000 (05:58 +0000)
git-svn-id: https://svn.wxwidgets.org/svn/wx/wxWidgets/trunk@31298 c3d73ce0-8a6f-49c7-b76d-6d57e0e08775

src/mac/carbon/textctrl.cpp

index b85c0b9abd8383c874703b0d244832732161886f..6cfe85a324ab14653d6cc64bd393e56292a74e4c 100644 (file)
@@ -300,6 +300,7 @@ public :
                              const wxSize& size, long style ) ;
     ~wxMacMLTEClassicControl() ;
     virtual void VisibilityChanged(bool shown) ;
+    virtual bool NeedsFocusRect() const;
 protected :
     OSStatus                 DoCreate();
 public :
@@ -1527,7 +1528,7 @@ void wxMacMLTEControl::TXNSetAttribute( const wxTextAttr& style , long from , lo
             fontStyle |= bold ;
         if ( font.GetStyle() == wxITALIC )
             fontStyle |= italic ;
-        
+
         typeAttr[attrCounter].tag = kTXNQDFontNameAttribute ;
         typeAttr[attrCounter].size = kTXNQDFontNameAttributeSize ;
         typeAttr[attrCounter].data.dataPtr = (void*) fontName ;
@@ -2067,7 +2068,7 @@ static void TPRedrawFocusOutline(STPTextPaneVars *varsp) {
        if (varsp->fFocusDrawState != (varsp->fIsActive && varsp->fInFocus)) 
        { 
                varsp->fFocusDrawState = (varsp->fIsActive && varsp->fInFocus);
-               DrawThemeFocusRect(&varsp->fRFocusOutline, varsp->fFocusDrawState);
+               // DrawThemeFocusRect(&varsp->fRFocusOutline, varsp->fFocusDrawState);
        }
 }
 
@@ -2411,6 +2412,11 @@ void wxMacMLTEClassicControl::VisibilityChanged(bool shown)
         InvalWindowRect( GetControlOwner( m_controlRef ) , &((STPTextPaneVars *)m_macTXNvars)->fRBounds ) ;
 }
 
+bool wxMacMLTEClassicControl::NeedsFocusRect() const 
+{
+    return true;
+}
+
 OSStatus wxMacMLTEClassicControl::DoCreate()
 {
     Rect bounds;