Tried to fix corrupted display of wxTextCtrl,

Corrected wxFileDialog's multiple file option.
  Corrected event mask for CaptureMouse(),
  Small change to "best visual" code.


git-svn-id: https://svn.wxwidgets.org/svn/wx/wxWidgets/trunk@5805 c3d73ce0-8a6f-49c7-b76d-6d57e0e08775
This commit is contained in:
Robert Roebling
2000-02-02 17:59:12 +00:00
parent 224ff7a50d
commit 68df5777c7
10 changed files with 78 additions and 22 deletions

View File

@@ -285,9 +285,6 @@ bool wxApp::OnInitGui()
visual = vis;
}
wxRootWindow = gtk_window_new( GTK_WINDOW_TOPLEVEL );
gtk_widget_realize( wxRootWindow );
/* Nothing to do for 15, 16, 24, 32 bit displays */
if (visual->depth > 8) return TRUE;
@@ -635,6 +632,9 @@ int wxEntry( int argc, char *argv[] )
if ( !wxTheApp->OnInitGui() )
retValue = -1;
wxRootWindow = gtk_window_new( GTK_WINDOW_TOPLEVEL );
gtk_widget_realize( wxRootWindow );
// Here frames insert themselves automatically into wxTopLevelWindows by
// getting created in OnInit().
if ( retValue == 0 )

View File

@@ -607,6 +607,26 @@ void wxTextCtrl::SetEditable( bool editable )
gtk_entry_set_editable( GTK_ENTRY(m_text), editable );
}
bool wxTextCtrl::Enable( bool enable )
{
if (!wxWindowBase::Enable(enable))
{
// nothing to do
return FALSE;
}
if (m_windowStyle & wxTE_MULTILINE)
{
gtk_text_set_editable( GTK_TEXT(m_text), enable );
}
else
{
gtk_widget_set_sensitive( m_text, enable );
}
return TRUE;
}
void wxTextCtrl::DiscardEdits()
{
m_modified = FALSE;

View File

@@ -3241,6 +3241,8 @@ void wxWindow::CaptureMouse()
(GdkEventMask)
(GDK_BUTTON_PRESS_MASK |
GDK_BUTTON_RELEASE_MASK |
GDK_KEY_PRESS_MASK |
GDK_KEY_RELEASE_MASK |
GDK_POINTER_MOTION_HINT_MASK |
GDK_POINTER_MOTION_MASK),
(GdkWindow *) NULL,