Fix recent compilation breakage by not using INT32_MAX
Apparently stdint.h doesn't define it on all platforms, even in 2016, so just hardcode 2147483647 instead. See #17629.
This commit is contained in:
@@ -19,8 +19,6 @@
|
|||||||
#include "wx/fontutil.h"
|
#include "wx/fontutil.h"
|
||||||
#include "wx/fontenum.h"
|
#include "wx/fontenum.h"
|
||||||
|
|
||||||
#include <stdint.h>
|
|
||||||
|
|
||||||
#include <gtk/gtk.h>
|
#include <gtk/gtk.h>
|
||||||
#include "wx/gtk/private/win_gtk.h"
|
#include "wx/gtk/private/win_gtk.h"
|
||||||
#include "wx/gtk/private/gtk2-compat.h"
|
#include "wx/gtk/private/gtk2-compat.h"
|
||||||
@@ -620,7 +618,7 @@ int wxSystemSettingsNative::GetMetric( wxSystemMetric index, wxWindow* win )
|
|||||||
// blinks and we handle any value that would overflow int after
|
// blinks and we handle any value that would overflow int after
|
||||||
// multiplication in the same manner as it looks quite
|
// multiplication in the same manner as it looks quite
|
||||||
// unnecessary to support cursor blinking once a month.
|
// unnecessary to support cursor blinking once a month.
|
||||||
if (timeout > 0 && timeout < INT32_MAX / 1000)
|
if (timeout > 0 && timeout < 2147483647 / 1000)
|
||||||
return timeout * 1000;
|
return timeout * 1000;
|
||||||
|
|
||||||
return -1; // no timeout, blink forever
|
return -1; // no timeout, blink forever
|
||||||
|
Reference in New Issue
Block a user