m_foregroundColour = *wxBLACK;
m_foregroundColour.CalcPixel( (WXColormap) cm );
- Window xparent = (Window) parent->GetClientWindow();
+ Window xparent = (Window) parent->GetClientAreaWindow();
// Add window's own scrollbars to main window, not to client window
if (parent->GetInsertIntoMain())
if (wxWindowIsVisible(xwindow))
{
- XSetInputFocus( wxGlobalDisplay(), xwindow, RevertToParent, CurrentTime );
+ wxLogTrace( _T("focus"), _T("wxWindowX11::SetFocus: %s"), GetClassInfo()->GetClassName());
+ // XSetInputFocus( wxGlobalDisplay(), xwindow, RevertToParent, CurrentTime );
+ XSetInputFocus( wxGlobalDisplay(), xwindow, RevertToNone, CurrentTime );
m_needsInputFocus = FALSE;
}
else
{
m_needsInputFocus = TRUE;
}
-#if 0
- wxString msg;
- msg.Printf("SetFocus: %s\n", GetClassInfo()->GetClassName());
- printf(msg.c_str());
-#endif
}
// Get the window with the focus
m_clearRegion.Intersect( 0, 0, cw, ch );
}
- Window xwindow = (Window) GetClientWindow();
+ Window xwindow = (Window) GetClientAreaWindow();
wxCHECK_RET( xwindow, wxT("invalid window") );
if (!GetEventHandler()->ProcessEvent(erase_event) )
{
Display *xdisplay = wxGlobalDisplay();
- Window xwindow = (Window) GetClientWindow();
+ Window xwindow = (Window) GetClientAreaWindow();
XSetForeground( xdisplay, g_eraseGC, m_backgroundColour.GetPixel() );
wxRegionIterator upd( m_clearRegion );
}
}
+// See handler for InFocus case in app.cpp for details.
+wxWindow* g_GettingFocus = NULL;
+
void wxWindowX11::OnInternalIdle()
{
// Update invalidated regions.
// no point in trying again.
m_needsInputFocus = FALSE;
}
+ g_GettingFocus = NULL;
}
// ----------------------------------------------------------------------------
return m_mainWindow;
}
-WXWindow wxWindowX11::GetClientWindow() const
+WXWindow wxWindowX11::GetClientAreaWindow() const
{
return m_clientWindow;
}