git-svn-id: https://svn.wxwidgets.org/svn/wx/wxWidgets/trunk@37931
c3d73ce0-8a6f-49c7-b76d-
6d57e0e08775
30 files changed:
+//-----------------------------------------------------------------------------
+// idle system
+//-----------------------------------------------------------------------------
+
+extern void wxapp_install_idle_handler();
+extern bool g_isIdle;
+
+//-----------------------------------------------------------------------------
+// GTK+ scroll types -> wxEventType
+//-----------------------------------------------------------------------------
+
// translate a GTK+ scroll type to a wxEventType
inline wxEventType GtkScrollTypeToWx(guint scrollType)
{
// translate a GTK+ scroll type to a wxEventType
inline wxEventType GtkScrollTypeToWx(guint scrollType)
{
wxEVT_SCROLLWIN_TOP - wxEVT_SCROLL_TOP;
}
wxEVT_SCROLLWIN_TOP - wxEVT_SCROLL_TOP;
}
+
+//-----------------------------------------------------------------------------
+// Misc. functions
+//-----------------------------------------------------------------------------
+
// Needed for implementing e.g. combobox on wxGTK within a modal dialog.
void wxAddGrab(wxWindow* window);
void wxRemoveGrab(wxWindow* window);
// Needed for implementing e.g. combobox on wxGTK within a modal dialog.
void wxAddGrab(wxWindow* window);
void wxRemoveGrab(wxWindow* window);
#include "wx/unix/private.h"
#include "wx/gtk/win_gtk.h"
#include "wx/unix/private.h"
#include "wx/gtk/win_gtk.h"
+#include "wx/gtk/private.h"
// idle system
//-----------------------------------------------------------------------------
// idle system
//-----------------------------------------------------------------------------
void wxapp_install_idle_handler();
#if wxUSE_THREADS
void wxapp_install_idle_handler();
#if wxUSE_THREADS
-//-----------------------------------------------------------------------------
-// idle system
-//-----------------------------------------------------------------------------
-
-extern void wxapp_install_idle_handler();
-extern bool g_isIdle;
-
//-----------------------------------------------------------------------------
// data
//-----------------------------------------------------------------------------
//-----------------------------------------------------------------------------
// data
//-----------------------------------------------------------------------------
-//-----------------------------------------------------------------------------
-// idle system
-//-----------------------------------------------------------------------------
-
-extern void wxapp_install_idle_handler();
-extern bool g_isIdle;
-
//-----------------------------------------------------------------------------
// data
//-----------------------------------------------------------------------------
//-----------------------------------------------------------------------------
// data
//-----------------------------------------------------------------------------
#include "wx/gtk/private.h"
#include "wx/gtk/private.h"
-//-----------------------------------------------------------------------------
-// idle system
-//-----------------------------------------------------------------------------
-
-extern void wxapp_install_idle_handler();
-extern bool g_isIdle;
-
//-----------------------------------------------------------------------------
// data
//-----------------------------------------------------------------------------
//-----------------------------------------------------------------------------
// data
//-----------------------------------------------------------------------------
#include "wx/gtk/private.h"
#include "wx/gtk/private.h"
-//-----------------------------------------------------------------------------
-// idle system
-//-----------------------------------------------------------------------------
-
-extern void wxapp_install_idle_handler();
-extern bool g_isIdle;
-
//-----------------------------------------------------------------------------
// data
//-----------------------------------------------------------------------------
//-----------------------------------------------------------------------------
// data
//-----------------------------------------------------------------------------
#endif
#include "wx/gtk/private.h"
#endif
#include "wx/gtk/private.h"
-//-----------------------------------------------------------------------------
-// idle system
-//-----------------------------------------------------------------------------
-
-extern void wxapp_install_idle_handler();
-extern bool g_isIdle;
-
//-----------------------------------------------------------------------------
// data
//-----------------------------------------------------------------------------
//-----------------------------------------------------------------------------
// data
//-----------------------------------------------------------------------------
#include "wx/utils.h"
#include "wx/app.h"
#include "wx/utils.h"
#include "wx/app.h"
+#include "wx/gtk/private.h" //for idle stuff
+
#include <gdk/gdk.h>
#include <gtk/gtk.h>
#include <gdk/gdk.h>
#include <gtk/gtk.h>
-//-----------------------------------------------------------------------------
-// idle system
-//-----------------------------------------------------------------------------
-
-extern void wxapp_install_idle_handler();
-extern bool g_isIdle;
-
//-----------------------------------------------------------------------------
// wxCursor
//-----------------------------------------------------------------------------
//-----------------------------------------------------------------------------
// wxCursor
//-----------------------------------------------------------------------------
-//-----------------------------------------------------------------------------
-// idle system
-//-----------------------------------------------------------------------------
-
-extern void wxapp_install_idle_handler();
-extern bool g_isIdle;
-
//-----------------------------------------------------------------------------
// data
//-----------------------------------------------------------------------------
//-----------------------------------------------------------------------------
// data
//-----------------------------------------------------------------------------
#include <gtk/gtkdnd.h>
#include <gtk/gtkselection.h>
#include <gtk/gtkdnd.h>
#include <gtk/gtkselection.h>
-//-----------------------------------------------------------------------------
-// idle system
-//-----------------------------------------------------------------------------
-
-extern void wxapp_install_idle_handler();
-extern bool g_isIdle;
-
//----------------------------------------------------------------------------
// global data
//----------------------------------------------------------------------------
//----------------------------------------------------------------------------
// global data
//----------------------------------------------------------------------------
#include "wx/gtk/private.h"
#include "wx/gtk/private.h"
-//-----------------------------------------------------------------------------
-// idle system
-//-----------------------------------------------------------------------------
-
-extern void wxapp_install_idle_handler();
-extern bool g_isIdle;
-
//-----------------------------------------------------------------------------
// "delete_event"
//-----------------------------------------------------------------------------
//-----------------------------------------------------------------------------
// "delete_event"
//-----------------------------------------------------------------------------
const int wxSTATUS_HEIGHT = 25;
const int wxPLACE_HOLDER = 0;
const int wxSTATUS_HEIGHT = 25;
const int wxPLACE_HOLDER = 0;
-// ----------------------------------------------------------------------------
-// idle system
-// ----------------------------------------------------------------------------
-
-extern void wxapp_install_idle_handler();
-extern bool g_isIdle;
-
// ----------------------------------------------------------------------------
// event tables
// ----------------------------------------------------------------------------
// ----------------------------------------------------------------------------
// event tables
// ----------------------------------------------------------------------------
//---------------------------------------------------------------------------
XVisualInfo *g_vi = (XVisualInfo*) NULL;
//---------------------------------------------------------------------------
XVisualInfo *g_vi = (XVisualInfo*) NULL;
-//-----------------------------------------------------------------------------
-// idle system
-//-----------------------------------------------------------------------------
-
-extern void wxapp_install_idle_handler();
-extern bool g_isIdle;
//---------------------------------------------------------------------------
// wxGLContext
//---------------------------------------------------------------------------
// wxGLContext
extern wxCursor g_globalCursor;
extern wxCursor g_globalCursor;
-//-----------------------------------------------------------------------------
-// idle system
-//-----------------------------------------------------------------------------
-
-extern void wxapp_install_idle_handler();
-extern bool g_isIdle;
//-----------------------------------------------------------------------------
// Macro to tell which row the strings are in (1 if native checklist, 0 if not)
//-----------------------------------------------------------------------------
// Macro to tell which row the strings are in (1 if native checklist, 0 if not)
const int wxMENU_HEIGHT = 27;
const int wxMENU_HEIGHT = 27;
-//-----------------------------------------------------------------------------
-// idle system
-//-----------------------------------------------------------------------------
-
-extern void wxapp_install_idle_handler();
-extern bool g_isIdle;
-
//-----------------------------------------------------------------------------
// globals
//-----------------------------------------------------------------------------
//-----------------------------------------------------------------------------
// globals
//-----------------------------------------------------------------------------
// idle system
//-----------------------------------------------------------------------------
// idle system
//-----------------------------------------------------------------------------
-extern void wxapp_install_idle_handler();
-extern bool g_isIdle;
-
#if wxUSE_ACCEL
static wxString GetGtkHotKey( const wxMenuItem& item );
#endif
#if wxUSE_ACCEL
static wxString GetGtkHotKey( const wxMenuItem& item );
#endif
#include <gdk/gdkprivate.h>
#include <gdk/gdkx.h>
#include <gdk/gdkprivate.h>
#include <gdk/gdkx.h>
-//-----------------------------------------------------------------------------
-// idle system
-//-----------------------------------------------------------------------------
-
-extern void wxapp_install_idle_handler();
-extern bool g_isIdle;
-
//-----------------------------------------------------------------------------
// data
//-----------------------------------------------------------------------------
//-----------------------------------------------------------------------------
// data
//-----------------------------------------------------------------------------
DEFINE_EVENT_TYPE(wxEVT_COMMAND_NOTEBOOK_PAGE_CHANGED)
DEFINE_EVENT_TYPE(wxEVT_COMMAND_NOTEBOOK_PAGE_CHANGING)
DEFINE_EVENT_TYPE(wxEVT_COMMAND_NOTEBOOK_PAGE_CHANGED)
DEFINE_EVENT_TYPE(wxEVT_COMMAND_NOTEBOOK_PAGE_CHANGING)
-//-----------------------------------------------------------------------------
-// idle system
-//-----------------------------------------------------------------------------
-
-extern void wxapp_install_idle_handler();
-extern bool g_isIdle;
-
//-----------------------------------------------------------------------------
// data
//-----------------------------------------------------------------------------
//-----------------------------------------------------------------------------
// data
//-----------------------------------------------------------------------------
#include <gtk/gtk.h>
#include <gdk/gdkkeysyms.h>
#include <gtk/gtk.h>
#include <gdk/gdkkeysyms.h>
+#include "wx/gtk/private.h" //for idle stuff
#include "wx/gtk/win_gtk.h"
#include "wx/gtk/win_gtk.h"
-//-----------------------------------------------------------------------------
-// idle system
-//-----------------------------------------------------------------------------
-
-extern void wxapp_install_idle_handler();
-extern bool g_isIdle;
-
//-----------------------------------------------------------------------------
// "button_press"
//-----------------------------------------------------------------------------
//-----------------------------------------------------------------------------
// "button_press"
//-----------------------------------------------------------------------------
#include "wx/gtk/win_gtk.h"
#include "wx/gtk/win_gtk.h"
-//-----------------------------------------------------------------------------
-// idle system
-//-----------------------------------------------------------------------------
-
-extern void wxapp_install_idle_handler();
-extern bool g_isIdle;
-
//-----------------------------------------------------------------------------
// data
//-----------------------------------------------------------------------------
//-----------------------------------------------------------------------------
// data
//-----------------------------------------------------------------------------
#include "wx/gtk/private.h"
#include "wx/gtk/private.h"
-//-----------------------------------------------------------------------------
-// idle system
-//-----------------------------------------------------------------------------
-
-extern void wxapp_install_idle_handler();
-extern bool g_isIdle;
-
//-----------------------------------------------------------------------------
// data
//-----------------------------------------------------------------------------
//-----------------------------------------------------------------------------
// data
//-----------------------------------------------------------------------------
#include "wx/math.h"
#include "wx/gtk/private.h"
#include "wx/math.h"
#include "wx/gtk/private.h"
-//-----------------------------------------------------------------------------
-// idle system
-//-----------------------------------------------------------------------------
-
-extern void wxapp_install_idle_handler();
-extern bool g_isIdle;
-
//-----------------------------------------------------------------------------
// data
//-----------------------------------------------------------------------------
//-----------------------------------------------------------------------------
// data
//-----------------------------------------------------------------------------
#include "wx/math.h"
#include "wx/gtk/private.h"
#include "wx/math.h"
#include "wx/gtk/private.h"
-//-----------------------------------------------------------------------------
-// idle system
-//-----------------------------------------------------------------------------
-
-extern void wxapp_install_idle_handler();
-extern bool g_isIdle;
-
//-----------------------------------------------------------------------------
// data
//-----------------------------------------------------------------------------
//-----------------------------------------------------------------------------
// data
//-----------------------------------------------------------------------------
#include "wx/math.h"
#include "wx/gtk/private.h"
#include "wx/math.h"
#include "wx/gtk/private.h"
-//-----------------------------------------------------------------------------
-// idle system
-//-----------------------------------------------------------------------------
-
-extern void wxapp_install_idle_handler();
-extern bool g_isIdle;
-
//-----------------------------------------------------------------------------
// data
//-----------------------------------------------------------------------------
//-----------------------------------------------------------------------------
// data
//-----------------------------------------------------------------------------
// idle system
//-----------------------------------------------------------------------------
// idle system
//-----------------------------------------------------------------------------
-extern void wxapp_install_idle_handler();
-extern bool g_isIdle;
-
static const float sensitivity = 0.02;
//-----------------------------------------------------------------------------
static const float sensitivity = 0.02;
//-----------------------------------------------------------------------------
// globals
// ----------------------------------------------------------------------------
// globals
// ----------------------------------------------------------------------------
-// idle system
-extern void wxapp_install_idle_handler();
-extern bool g_isIdle;
-
// data
extern bool g_blockEventsOnDrag;
extern wxCursor g_globalCursor;
// data
extern bool g_blockEventsOnDrag;
extern wxCursor g_globalCursor;
#include "wx/gtk/private.h"
#include <gdk/gdkkeysyms.h>
#include "wx/gtk/private.h"
#include <gdk/gdkkeysyms.h>
-//-----------------------------------------------------------------------------
-// idle system
-//-----------------------------------------------------------------------------
-
-extern void wxapp_install_idle_handler();
-extern bool g_isIdle;
-
//-----------------------------------------------------------------------------
// data
//-----------------------------------------------------------------------------
//-----------------------------------------------------------------------------
// data
//-----------------------------------------------------------------------------
#include "wx/gtk/private.h"
#include "wx/gtk/private.h"
-extern void wxapp_install_idle_handler();
-extern bool g_isIdle;
extern bool g_blockEventsOnDrag;
extern wxCursor g_globalCursor;
extern bool g_blockEventsOnDrag;
extern wxCursor g_globalCursor;
// XA_CARDINAL
#include <X11/Xatom.h>
// XA_CARDINAL
#include <X11/Xatom.h>
-// ----------------------------------------------------------------------------
-// idle system
-// ----------------------------------------------------------------------------
-
-extern void wxapp_install_idle_handler();
-extern bool g_isIdle;
-
// ----------------------------------------------------------------------------
// data
// ----------------------------------------------------------------------------
// ----------------------------------------------------------------------------
// data
// ----------------------------------------------------------------------------
-//-----------------------------------------------------------------------------
-// idle system
-//-----------------------------------------------------------------------------
-
-extern void wxapp_install_idle_handler();
-extern bool g_isIdle;
-
//-----------------------------------------------------------------------------
// local code (see below)
//-----------------------------------------------------------------------------
//-----------------------------------------------------------------------------
// local code (see below)
//-----------------------------------------------------------------------------