git-svn-id: https://svn.wxwidgets.org/svn/wx/wxWidgets/trunk@22378
c3d73ce0-8a6f-49c7-b76d-
6d57e0e08775
// send any activate events at all
static int g_sendActivateEvent = -1;
// send any activate events at all
static int g_sendActivateEvent = -1;
+// hack: we need something to pass to gtk_menu_popup, so we store the time of
+// the last click here
+static guint32 gs_timeLastClick = 0;
+
extern bool g_mainThreadLocked;
//-----------------------------------------------------------------------------
extern bool g_mainThreadLocked;
//-----------------------------------------------------------------------------
if ( !g_captureWindow )
win = FindWindowForMouseEvent(win, event.m_x, event.m_y);
if ( !g_captureWindow )
win = FindWindowForMouseEvent(win, event.m_x, event.m_y);
+ gs_timeLastClick = gdk_event->time;
+
/*
wxPrintf( wxT("2) OnButtonPress from ") );
if (win->GetClassInfo() && win->GetClassInfo()->GetClassName())
/*
wxPrintf( wxT("2) OnButtonPress from ") );
if (win->GetClassInfo() && win->GetClassInfo()->GetClassName())
#ifdef __WXGTK20__
gtk_get_current_event_time()
#else
#ifdef __WXGTK20__
gtk_get_current_event_time()
#else
+ gs_timeLastClick // the time of activation
// send any activate events at all
static int g_sendActivateEvent = -1;
// send any activate events at all
static int g_sendActivateEvent = -1;
+// hack: we need something to pass to gtk_menu_popup, so we store the time of
+// the last click here
+static guint32 gs_timeLastClick = 0;
+
extern bool g_mainThreadLocked;
//-----------------------------------------------------------------------------
extern bool g_mainThreadLocked;
//-----------------------------------------------------------------------------
if ( !g_captureWindow )
win = FindWindowForMouseEvent(win, event.m_x, event.m_y);
if ( !g_captureWindow )
win = FindWindowForMouseEvent(win, event.m_x, event.m_y);
+ gs_timeLastClick = gdk_event->time;
+
/*
wxPrintf( wxT("2) OnButtonPress from ") );
if (win->GetClassInfo() && win->GetClassInfo()->GetClassName())
/*
wxPrintf( wxT("2) OnButtonPress from ") );
if (win->GetClassInfo() && win->GetClassInfo()->GetClassName())
#ifdef __WXGTK20__
gtk_get_current_event_time()
#else
#ifdef __WXGTK20__
gtk_get_current_event_time()
#else
+ gs_timeLastClick // the time of activation