aboutsummaryrefslogtreecommitdiffstats
path: root/lib/wx/c_src
diff options
context:
space:
mode:
Diffstat (limited to 'lib/wx/c_src')
-rw-r--r--lib/wx/c_src/gen/wxe_funcs.cpp2
-rw-r--r--lib/wx/c_src/wxe_callback_impl.cpp2
-rw-r--r--lib/wx/c_src/wxe_callback_impl.h9
3 files changed, 10 insertions, 3 deletions
diff --git a/lib/wx/c_src/gen/wxe_funcs.cpp b/lib/wx/c_src/gen/wxe_funcs.cpp
index 3f5cb4c0f5..8da517ee64 100644
--- a/lib/wx/c_src/gen/wxe_funcs.cpp
+++ b/lib/wx/c_src/gen/wxe_funcs.cpp
@@ -15875,7 +15875,7 @@ case wxListCtrl_SortItems: { // wxListCtrl::SortItems taylormade
callbackInfo* cb = new callbackInfo();
cb->port = Ecmd.port;
cb->callbackID = sortCallback;
- bool Result = This->SortItems(wxEListCtrlCompare, (long)cb);
+ bool Result = This->SortItems(wxEListCtrlCompare, (wxeIntPtr)cb);
delete cb;
/* Destroy the callback, see wxEPrintout::clear_cb */
diff --git a/lib/wx/c_src/wxe_callback_impl.cpp b/lib/wx/c_src/wxe_callback_impl.cpp
index e06f68dcbf..3a59004eb0 100644
--- a/lib/wx/c_src/wxe_callback_impl.cpp
+++ b/lib/wx/c_src/wxe_callback_impl.cpp
@@ -284,7 +284,7 @@ EwxListCtrl::~EwxListCtrl() {
* wxListCtrlCompare wrapper
* ****************************************************************************/
-int wxCALLBACK wxEListCtrlCompare(long item1, long item2, long callbackInfoPtr)
+int wxCALLBACK wxEListCtrlCompare(wxeIntPtr item1, wxeIntPtr item2, wxeIntPtr callbackInfoPtr)
{
callbackInfo * cb = (callbackInfo *)callbackInfoPtr;
wxeMemEnv * memenv = ((WxeApp *) wxTheApp)->getMemEnv(cb->port);
diff --git a/lib/wx/c_src/wxe_callback_impl.h b/lib/wx/c_src/wxe_callback_impl.h
index 1c355e4d38..ecfcd3db41 100644
--- a/lib/wx/c_src/wxe_callback_impl.h
+++ b/lib/wx/c_src/wxe_callback_impl.h
@@ -23,6 +23,13 @@
void pre_callback();
void handle_event_callback(ErlDrvPort port, ErlDrvTermData process);
+#if wxCHECK_VERSION(2,9,0)
+ #define wxeIntPtr wxIntPtr
+#else
+ // This is bad but how it was in wx-2.8
+ #define wxeIntPtr long
+#endif
+
/* Fun Callback id */
class wxeEvtListener : public wxEvtHandler
{
@@ -88,6 +95,6 @@ struct callbackInfo {
int callbackID;
};
-int wxCALLBACK wxEListCtrlCompare(long item1, long item2, long callbackInfoPtr);
+int wxCALLBACK wxEListCtrlCompare(wxeIntPtr item1, wxeIntPtr item2, wxeIntPtr callbackInfoPtr);
#endif