- Added wxTaskBarIcon::Destroy()
- Added XRC handler for wxSearchCtrl (Sander Berents)
- Read image resolution from TIFF, JPEG and BMP images (Maycon Aparecido Gasoto)
+- Added wxSYS_DCLICK_TIME system metric constant
wxGTK:
clicks must fall to generate a double-click.}
\twocolitem{{\bf wxSYS\_DCLICK\_Y}}{Height in pixels of rectangle within which two successive mouse
clicks must fall to generate a double-click.}
+\twocolitem{{\bf wxSYS\_DCLICK\_MSEC}}{Maximal time, in milliseconds, which may
+pass between subsequent clicks for a double click to be generated.}
\twocolitem{{\bf wxSYS\_DRAG\_X}}{Width in pixels of a rectangle centered on a drag point
to allow for limited movement of the mouse pointer before a drag operation begins.}
\twocolitem{{\bf wxSYS\_DRAG\_Y}}{Height in pixels of a rectangle centered on a drag point
wxSYS_NETWORK_PRESENT,
wxSYS_PENWINDOWS_PRESENT,
wxSYS_SHOW_SOUNDS,
- wxSYS_SWAP_BUTTONS
+ wxSYS_SWAP_BUTTONS,
+ wxSYS_DCLICK_MSEC
};
// possible values for wxSystemSettings::HasFeature() parameter
#include "wx/dcclient.h"
#include "wx/dcscreen.h"
#include "wx/math.h"
+ #include "wx/settings.h"
#endif
#include "wx/imaglist.h"
(hitResult == wxLIST_HITTEST_ONITEMLABEL) &&
HasFlag(wxLC_EDIT_LABELS) )
{
- if (InReportView())
+ if ( !InReportView() ||
+ GetLineLabelRect(current).Contains(x, y) )
{
- wxRect label = GetLineLabelRect( current );
- if (label.Contains( x, y ))
- m_renameTimer->Start( 250, true );
-
+ int dclick = wxSystemSettings::GetMetric(wxSYS_DCLICK_MSEC);
+ m_renameTimer->Start(dclick > 0 ? dclick : 250, true);
}
- else
- m_renameTimer->Start( 250, true );
}
}
return dclick_distance * 2;
+ case wxSYS_DCLICK_MSEC:
+ gint dclick;
+ g_object_get(gtk_settings_get_default(),
+ "gtk-double-click-time", &dclick, NULL);
+ return dclick;
+
case wxSYS_DRAG_X:
case wxSYS_DRAG_Y:
gint drag_threshold;
#ifdef SM_SWAPBUTTON
SM_SWAPBUTTON,
#else
- -1
+ -1,
#endif
+ -1 // wxSYS_DCLICK_MSEC - not available as system metric
};
// Get a system metric, e.g. scrollbar size
wxCHECK_MSG( index > 0 && (size_t)index < WXSIZEOF(gs_metricsMap), 0,
_T("invalid metric") );
+ if ( index == wxSYS_DCLICK_MSEC )
+ {
+ // This one is not a Win32 system metric
+ return ::GetDoubleClickTime();
+ }
+
int indexMSW = gs_metricsMap[index];
if ( indexMSW == -1 )
{