git-svn-id: https://svn.wxwidgets.org/svn/wx/wxWidgets/trunk@2604 
c3d73ce0-8a6f-49c7-b76d-
6d57e0e08775
     GDK_THREADS_LEAVE ();
 #endif
     
     GDK_THREADS_LEAVE ();
 #endif
     
-    wxTheApp->m_wakeUpTimerTag = gtk_timeout_add( 10, wxapp_wakeup_timerout_callback, (gpointer) NULL );
+    wxTheApp->m_wakeUpTimerTag = gtk_timeout_add( 20, wxapp_wakeup_timerout_callback, (gpointer) NULL );
     m_idleTag = gtk_idle_add( wxapp_idle_callback, (gpointer) NULL );
     
 #if wxUSE_THREADS
     m_idleTag = gtk_idle_add( wxapp_idle_callback, (gpointer) NULL );
     
 #if wxUSE_THREADS
-    m_wakeUpTimerTag = gtk_timeout_add( 10, wxapp_wakeup_timerout_callback, (gpointer) NULL );
+    m_wakeUpTimerTag = gtk_timeout_add( 20, wxapp_wakeup_timerout_callback, (gpointer) NULL );
 #endif
 
     m_colorCube = (unsigned char*) NULL;
 #endif
 
     m_colorCube = (unsigned char*) NULL;
 
     if ((!wxTheClipboard->m_ownsPrimarySelection) &&
         (!wxTheClipboard->m_ownsClipboard))
     {
     if ((!wxTheClipboard->m_ownsPrimarySelection) &&
         (!wxTheClipboard->m_ownsClipboard))
     {
-        /* the clipboard is no longer in our hands. we can the  clipboard data. */
-      
+        /* the clipboard is no longer in our hands. we can the delete clipboard data. */
         if (wxTheClipboard->m_dataBroker)
        {
            delete wxTheClipboard->m_dataBroker;
         if (wxTheClipboard->m_dataBroker)
        {
            delete wxTheClipboard->m_dataBroker;
     wxCHECK_MSG( data, FALSE, _T("data is invalid") );
     
     /* if clipboard has been cleared before, create new data broker */
     wxCHECK_MSG( data, FALSE, _T("data is invalid") );
     
     /* if clipboard has been cleared before, create new data broker */
     if (!m_dataBroker) m_dataBroker = new wxDataBroker();
   
     /* add new data to list of offered data objects */
     if (!m_dataBroker) m_dataBroker = new wxDataBroker();
   
     /* add new data to list of offered data objects */
     m_dataBroker->Add( data );
     
     /* get native format id of new data object */
     m_dataBroker->Add( data );
     
     /* get native format id of new data object */
     GdkAtom format = data->GetFormat().GetAtom();
        
     wxCHECK_MSG( format, FALSE, _T("data has invalid format") );
     
     /* This should happen automatically, but to be on the safe side */
     GdkAtom format = data->GetFormat().GetAtom();
        
     wxCHECK_MSG( format, FALSE, _T("data has invalid format") );
     
     /* This should happen automatically, but to be on the safe side */
     m_ownsClipboard = FALSE;
     m_ownsPrimarySelection = FALSE;
     
     /* Add handlers if someone requests data */
     m_ownsClipboard = FALSE;
     m_ownsPrimarySelection = FALSE;
     
     /* Add handlers if someone requests data */
 
 #if (GTK_MINOR_VERSION > 0)
 
 
 #if (GTK_MINOR_VERSION > 0)
 
                               selection_handler,
                               (gpointer) NULL );
 #endif
                               selection_handler,
                               (gpointer) NULL );
 #endif
+
+//    printf( "vorher.\n" );                          
     /* Tell the world we offer clipboard data */
     /* Tell the world we offer clipboard data */
     if (!gtk_selection_owner_set( m_clipboardWidget, 
                                   g_clipboardAtom,
                                  GDK_CURRENT_TIME ))
     if (!gtk_selection_owner_set( m_clipboardWidget, 
                                   g_clipboardAtom,
                                  GDK_CURRENT_TIME ))
     }
     m_ownsClipboard = TRUE;
     
     }
     m_ownsClipboard = TRUE;
     
+//    printf( "nachher.\n" );                         
+    
+    return TRUE;
+    
     if (!gtk_selection_owner_set( m_clipboardWidget, 
                                   GDK_SELECTION_PRIMARY,
                                  GDK_CURRENT_TIME ))
     if (!gtk_selection_owner_set( m_clipboardWidget, 
                                   GDK_SELECTION_PRIMARY,
                                  GDK_CURRENT_TIME ))
 
     GDK_THREADS_LEAVE ();
 #endif
     
     GDK_THREADS_LEAVE ();
 #endif
     
-    wxTheApp->m_wakeUpTimerTag = gtk_timeout_add( 10, wxapp_wakeup_timerout_callback, (gpointer) NULL );
+    wxTheApp->m_wakeUpTimerTag = gtk_timeout_add( 20, wxapp_wakeup_timerout_callback, (gpointer) NULL );
     m_idleTag = gtk_idle_add( wxapp_idle_callback, (gpointer) NULL );
     
 #if wxUSE_THREADS
     m_idleTag = gtk_idle_add( wxapp_idle_callback, (gpointer) NULL );
     
 #if wxUSE_THREADS
-    m_wakeUpTimerTag = gtk_timeout_add( 10, wxapp_wakeup_timerout_callback, (gpointer) NULL );
+    m_wakeUpTimerTag = gtk_timeout_add( 20, wxapp_wakeup_timerout_callback, (gpointer) NULL );
 #endif
 
     m_colorCube = (unsigned char*) NULL;
 #endif
 
     m_colorCube = (unsigned char*) NULL;
 
     if ((!wxTheClipboard->m_ownsPrimarySelection) &&
         (!wxTheClipboard->m_ownsClipboard))
     {
     if ((!wxTheClipboard->m_ownsPrimarySelection) &&
         (!wxTheClipboard->m_ownsClipboard))
     {
-        /* the clipboard is no longer in our hands. we can the  clipboard data. */
-      
+        /* the clipboard is no longer in our hands. we can the delete clipboard data. */
         if (wxTheClipboard->m_dataBroker)
        {
            delete wxTheClipboard->m_dataBroker;
         if (wxTheClipboard->m_dataBroker)
        {
            delete wxTheClipboard->m_dataBroker;
     wxCHECK_MSG( data, FALSE, _T("data is invalid") );
     
     /* if clipboard has been cleared before, create new data broker */
     wxCHECK_MSG( data, FALSE, _T("data is invalid") );
     
     /* if clipboard has been cleared before, create new data broker */
     if (!m_dataBroker) m_dataBroker = new wxDataBroker();
   
     /* add new data to list of offered data objects */
     if (!m_dataBroker) m_dataBroker = new wxDataBroker();
   
     /* add new data to list of offered data objects */
     m_dataBroker->Add( data );
     
     /* get native format id of new data object */
     m_dataBroker->Add( data );
     
     /* get native format id of new data object */
     GdkAtom format = data->GetFormat().GetAtom();
        
     wxCHECK_MSG( format, FALSE, _T("data has invalid format") );
     
     /* This should happen automatically, but to be on the safe side */
     GdkAtom format = data->GetFormat().GetAtom();
        
     wxCHECK_MSG( format, FALSE, _T("data has invalid format") );
     
     /* This should happen automatically, but to be on the safe side */
     m_ownsClipboard = FALSE;
     m_ownsPrimarySelection = FALSE;
     
     /* Add handlers if someone requests data */
     m_ownsClipboard = FALSE;
     m_ownsPrimarySelection = FALSE;
     
     /* Add handlers if someone requests data */
 
 #if (GTK_MINOR_VERSION > 0)
 
 
 #if (GTK_MINOR_VERSION > 0)
 
                               selection_handler,
                               (gpointer) NULL );
 #endif
                               selection_handler,
                               (gpointer) NULL );
 #endif
+
+//    printf( "vorher.\n" );                          
     /* Tell the world we offer clipboard data */
     /* Tell the world we offer clipboard data */
     if (!gtk_selection_owner_set( m_clipboardWidget, 
                                   g_clipboardAtom,
                                  GDK_CURRENT_TIME ))
     if (!gtk_selection_owner_set( m_clipboardWidget, 
                                   g_clipboardAtom,
                                  GDK_CURRENT_TIME ))
     }
     m_ownsClipboard = TRUE;
     
     }
     m_ownsClipboard = TRUE;
     
+//    printf( "nachher.\n" );                         
+    
+    return TRUE;
+    
     if (!gtk_selection_owner_set( m_clipboardWidget, 
                                   GDK_SELECTION_PRIMARY,
                                  GDK_CURRENT_TIME ))
     if (!gtk_selection_owner_set( m_clipboardWidget, 
                                   GDK_SELECTION_PRIMARY,
                                  GDK_CURRENT_TIME ))