Added Theme patch.

Upported mouse click detection change.


git-svn-id: https://svn.wxwidgets.org/svn/wx/wxWidgets/trunk@21757 c3d73ce0-8a6f-49c7-b76d-6d57e0e08775
This commit is contained in:
Robert Roebling 2003-07-08 11:26:04 +00:00
parent 865864592a
commit 2b904684fb
8 changed files with 40 additions and 8 deletions

View File

@ -502,5 +502,15 @@ wxSize wxChoice::DoGetBestSize() const
return ret;
}
bool wxChoice::IsOwnGtkWindow( GdkWindow *window )
{
#ifdef __WXGTK20__
return GTK_BUTTON(m_widget)->event_window;
#else
return (window == m_widget->window);
#endif
}
#endif // wxUSE_CHOICE

View File

@ -958,6 +958,8 @@ GtkWidget *wxListBox::GetConnectWidget()
bool wxListBox::IsOwnGtkWindow( GdkWindow *window )
{
if (m_widget->window == window) return TRUE;
if (GTK_WIDGET(m_list)->window == window) return TRUE;
GList *child = m_list->children;

View File

@ -282,7 +282,11 @@ void wxSpinCtrl::OnChar( wxKeyEvent &event )
bool wxSpinCtrl::IsOwnGtkWindow( GdkWindow *window )
{
return GTK_SPIN_BUTTON(m_widget)->panel == window;
if (GTK_SPIN_BUTTON(m_widget)->entry.text_area == window) return TRUE;
if (GTK_SPIN_BUTTON(m_widget)->panel == window) return TRUE;
return FALSE;
}
void wxSpinCtrl::ApplyWidgetStyle()

View File

@ -2195,10 +2195,10 @@ gtk_window_realized_callback( GtkWidget *m_widget, wxWindow *win )
if (g_isIdle)
wxapp_install_idle_handler();
if (win->m_delayedBackgroundColour)
if (win->m_delayedBackgroundColour && !win->GetThemeEnabled())
win->GtkSetBackgroundColour( win->GetBackgroundColour() );
if (win->m_delayedForegroundColour)
if (win->m_delayedForegroundColour && !win->GetThemeEnabled())
win->GtkSetForegroundColour( win->GetForegroundColour() );
#ifdef __WXGTK20__

View File

@ -502,5 +502,15 @@ wxSize wxChoice::DoGetBestSize() const
return ret;
}
bool wxChoice::IsOwnGtkWindow( GdkWindow *window )
{
#ifdef __WXGTK20__
return GTK_BUTTON(m_widget)->event_window;
#else
return (window == m_widget->window);
#endif
}
#endif // wxUSE_CHOICE

View File

@ -958,6 +958,8 @@ GtkWidget *wxListBox::GetConnectWidget()
bool wxListBox::IsOwnGtkWindow( GdkWindow *window )
{
if (m_widget->window == window) return TRUE;
if (GTK_WIDGET(m_list)->window == window) return TRUE;
GList *child = m_list->children;

View File

@ -282,7 +282,11 @@ void wxSpinCtrl::OnChar( wxKeyEvent &event )
bool wxSpinCtrl::IsOwnGtkWindow( GdkWindow *window )
{
return GTK_SPIN_BUTTON(m_widget)->panel == window;
if (GTK_SPIN_BUTTON(m_widget)->entry.text_area == window) return TRUE;
if (GTK_SPIN_BUTTON(m_widget)->panel == window) return TRUE;
return FALSE;
}
void wxSpinCtrl::ApplyWidgetStyle()

View File

@ -2195,10 +2195,10 @@ gtk_window_realized_callback( GtkWidget *m_widget, wxWindow *win )
if (g_isIdle)
wxapp_install_idle_handler();
if (win->m_delayedBackgroundColour)
if (win->m_delayedBackgroundColour && !win->GetThemeEnabled())
win->GtkSetBackgroundColour( win->GetBackgroundColour() );
if (win->m_delayedForegroundColour)
if (win->m_delayedForegroundColour && !win->GetThemeEnabled())
win->GtkSetForegroundColour( win->GetForegroundColour() );
#ifdef __WXGTK20__