defer calling SetCanFocus() on wxGTK until after creation
git-svn-id: https://svn.wxwidgets.org/svn/wx/wxWidgets/trunk@74618 c3d73ce0-8a6f-49c7-b76d-6d57e0e08775
This commit is contained in:
@@ -27,7 +27,7 @@ extern WXDLLIMPEXP_DATA_CORE(const char) wxStaticBoxNameStr[];
|
|||||||
class WXDLLIMPEXP_CORE wxStaticBoxBase : public wxNavigationEnabled<wxControl>
|
class WXDLLIMPEXP_CORE wxStaticBoxBase : public wxNavigationEnabled<wxControl>
|
||||||
{
|
{
|
||||||
public:
|
public:
|
||||||
wxStaticBoxBase() { m_container.DisableSelfFocus(); }
|
wxStaticBoxBase();
|
||||||
|
|
||||||
// overridden base class virtuals
|
// overridden base class virtuals
|
||||||
virtual bool HasTransparentBackground() { return true; }
|
virtual bool HasTransparentBackground() { return true; }
|
||||||
|
@@ -29,6 +29,13 @@
|
|||||||
|
|
||||||
extern WXDLLEXPORT_DATA(const char) wxStaticBoxNameStr[] = "groupBox";
|
extern WXDLLEXPORT_DATA(const char) wxStaticBoxNameStr[] = "groupBox";
|
||||||
|
|
||||||
|
wxStaticBoxBase::wxStaticBoxBase()
|
||||||
|
{
|
||||||
|
#ifndef __WXGTK__
|
||||||
|
m_container.DisableSelfFocus();
|
||||||
|
#endif
|
||||||
|
}
|
||||||
|
|
||||||
// ----------------------------------------------------------------------------
|
// ----------------------------------------------------------------------------
|
||||||
// XTI
|
// XTI
|
||||||
// ----------------------------------------------------------------------------
|
// ----------------------------------------------------------------------------
|
||||||
|
@@ -108,6 +108,8 @@ bool wxStaticBox::Create( wxWindow *parent,
|
|||||||
}
|
}
|
||||||
#endif
|
#endif
|
||||||
|
|
||||||
|
m_container.DisableSelfFocus();
|
||||||
|
|
||||||
return true;
|
return true;
|
||||||
}
|
}
|
||||||
|
|
||||||
|
@@ -3375,8 +3375,9 @@ void wxWindowGTK::SetFocus()
|
|||||||
|
|
||||||
void wxWindowGTK::SetCanFocus(bool canFocus)
|
void wxWindowGTK::SetCanFocus(bool canFocus)
|
||||||
{
|
{
|
||||||
if ( m_widget )
|
wxCHECK_RET(m_widget, "invalid window");
|
||||||
gtk_widget_set_can_focus(m_widget, canFocus);
|
|
||||||
|
gtk_widget_set_can_focus(m_widget, canFocus);
|
||||||
|
|
||||||
if ( m_wxwindow && (m_widget != m_wxwindow) )
|
if ( m_wxwindow && (m_widget != m_wxwindow) )
|
||||||
{
|
{
|
||||||
|
Reference in New Issue
Block a user