Skip to content

Commit c99a809

Browse files
author
Fraser J. Gordon
committed
[[ iOS 64-bit ]] Code changes required to get 64-bit iOS to compile
1 parent e6ee584 commit c99a809

File tree

23 files changed

+84
-59
lines changed

23 files changed

+84
-59
lines changed

engine/src/cmdss.cpp

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -733,7 +733,7 @@ Exec_stat MCGo::exec(MCExecPoint &ep)
733733
MCeerror->add(EE_GO_BADWINDOWEXP, line, pos);
734734
return ES_ERROR;
735735
}
736-
if (ep.ton() == ES_NORMAL && MCscreen->uint4towindow(ep.getuint4(), w))
736+
if (ep.ton() == ES_NORMAL && MCscreen->uinttowindow(ep.getuint4(), w))
737737
oldstack = MCdispatcher->findstackd(w);
738738
else
739739
oldstack = ep.getobj()->getstack()->findstackname(ep.getsvalue());

engine/src/desktop-dc.cpp

Lines changed: 2 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -458,7 +458,7 @@ void MCScreenDC::setinputfocus(Window window)
458458
MCPlatformFocusWindow(window);
459459
}
460460

461-
uint4 MCScreenDC::dtouint4(Drawable d)
461+
uintptr_t MCScreenDC::dtouint(Drawable d)
462462
{
463463
if (d == nil)
464464
return 0;
@@ -472,7 +472,7 @@ uint4 MCScreenDC::dtouint4(Drawable d)
472472
return t_id;
473473
}
474474

475-
Boolean MCScreenDC::uint4towindow(uint4 p_id, Window &w)
475+
Boolean MCScreenDC::uinttowindow(uintptr_t p_id, Window &w)
476476
{
477477
// MW-2014-07-15: [[ Bug 12800 ]] Map the windowId to a platform window if one exists.
478478
MCPlatformWindowRef t_window;

engine/src/desktop-dc.h

Lines changed: 2 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -96,8 +96,8 @@ class MCScreenDC: public MCUIDC
9696
virtual void uniconifywindow(Window window);
9797
virtual void setname(Window window, const char *newname);
9898
virtual void setinputfocus(Window window);
99-
virtual uint4 dtouint4(Drawable d);
100-
virtual Boolean uint4towindow(uint4, Window &w);
99+
virtual uintptr_t dtouint(Drawable d);
100+
virtual Boolean uinttowindow(uintptr_t, Window &w);
101101

102102
virtual void enablebackdrop(bool p_hard);
103103
virtual void disablebackdrop(bool p_hard);

engine/src/dispatch.cpp

Lines changed: 2 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -1637,7 +1637,7 @@ bool MCDispatch::foreachchildstack(MCStack *p_stack, MCStackForEachCallback p_ca
16371637
return t_continue;
16381638
}
16391639

1640-
MCStack *MCDispatch::findstackwindowid(uint32_t p_win_id)
1640+
MCStack *MCDispatch::findstackwindowid(uintptr_t p_win_id)
16411641
{
16421642
if (p_win_id == 0)
16431643
return NULL;
@@ -1686,7 +1686,7 @@ MCStack *MCDispatch::findstackwindowid(uint32_t p_win_id)
16861686
MCStack *MCDispatch::findstackd(Window w)
16871687
{
16881688
// IM-2014-07-09: [[ Bug 12225 ]] Use window ID to find stack
1689-
return findstackwindowid(MCscreen->dtouint4((Drawable)w));
1689+
return findstackwindowid(MCscreen->dtouint((Drawable)w));
16901690
}
16911691

16921692
MCObject *MCDispatch::getobjid(Chunk_term type, uint4 inid)

engine/src/dispatch.h

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -196,7 +196,7 @@ class MCDispatch : public MCObject
196196
MCStack *findstackname(const MCString &);
197197
MCStack *findstackid(uint4 fid);
198198
// IM-2014-07-09: [[ Bug 12225 ]] Find the stack by window ID
199-
MCStack *findstackwindowid(uint32_t p_win_id);
199+
MCStack *findstackwindowid(uintptr_t p_win_id);
200200
MCStack *findstackd(Window w);
201201

202202
// IM-2014-07-23: [[ Bug 12930 ]] Replace findchildstack method with iterating method

engine/src/externalv0.cpp

Lines changed: 4 additions & 4 deletions
Original file line numberDiff line numberDiff line change
@@ -757,8 +757,8 @@ static char *runloop_wait(const char *arg1, const char *arg2,
757757
static char *stack_to_window_rect(const char *arg1, const char *arg2,
758758
const char *arg3, int *retval)
759759
{
760-
uint32_t t_win_id;
761-
t_win_id = (uint32_t)arg1;
760+
uintptr_t t_win_id;
761+
t_win_id = (uintptr_t)arg1;
762762

763763
MCStack *t_stack;
764764
t_stack = MCdispatcher->findstackwindowid(t_win_id);
@@ -785,8 +785,8 @@ static char *stack_to_window_rect(const char *arg1, const char *arg2,
785785
static char *window_to_stack_rect(const char *arg1, const char *arg2,
786786
const char *arg3, int *retval)
787787
{
788-
uint32_t t_win_id;
789-
t_win_id = (uint32_t)arg1;
788+
uintptr_t t_win_id;
789+
t_win_id = (uintptr_t)arg1;
790790

791791
MCStack *t_stack;
792792
t_stack = MCdispatcher->findstackwindowid(t_win_id);

engine/src/lnxdc.h

Lines changed: 2 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -225,8 +225,8 @@ class MCScreenDC : public MCUIDC
225225
virtual void freecursor(MCCursorRef c);
226226

227227
virtual void setfunction(uint4 rop);
228-
virtual uint4 dtouint4(Drawable d);
229-
virtual Boolean uint4towindow(uint4, Window &w);
228+
virtual uintptr_t dtouint(Drawable d);
229+
virtual Boolean uinttowindow(uintptr_t, Window &w);
230230
virtual void getbeep(uint4 property, MCExecPoint &ep);
231231
virtual void setbeep(uint4 property, int4 beep);
232232
virtual void getvendorstring(MCExecPoint &ep);

engine/src/lnxdcs.cpp

Lines changed: 2 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -882,12 +882,12 @@ void MCScreenDC::setfunction(uint4 rop)
882882
XSetFunction(dpy, getgc(), rop);
883883
}
884884

885-
uint4 MCScreenDC::dtouint4(Drawable d)
885+
uintptr_t MCScreenDC::dtouint(Drawable d)
886886
{
887887
return d;
888888
}
889889

890-
Boolean MCScreenDC::uint4towindow(uint4 id, Window &w)
890+
Boolean MCScreenDC::uinttowindow(uintptr_t id, Window &w)
891891
{
892892
w = id;
893893
return True;

engine/src/mbldc.cpp

Lines changed: 3 additions & 3 deletions
Original file line numberDiff line numberDiff line change
@@ -687,15 +687,15 @@ void MCScreenDC::freecursor(MCCursorRef c)
687687

688688
////////////////////////////////////////////////////////////////////////////////
689689

690-
uint4 MCScreenDC::dtouint4(Drawable d)
690+
uintptr_t MCScreenDC::dtouint(Drawable d)
691691
{
692692
if (d == DNULL)
693693
return 0;
694694

695-
return (uint4)d -> handle . pixmap;
695+
return (uintptr_t)d -> handle . pixmap;
696696
}
697697

698-
Boolean MCScreenDC::uint4towindow(uint4, Window &w)
698+
Boolean MCScreenDC::uinttowindow(uintptr_t, Window &w)
699699
{
700700
return False;
701701
}

engine/src/mbldc.h

Lines changed: 2 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -120,8 +120,8 @@ class MCScreenDC: public MCUIDC
120120
MCCursorRef createcursor(MCImageBitmap *p_image, int2 p_hotspot_x, int2 p_hotspot_y);
121121
void freecursor(MCCursorRef c);
122122

123-
uint4 dtouint4(Drawable d);
124-
Boolean uint4towindow(uint4, Window &w);
123+
uintptr_t dtouint(Drawable d);
124+
Boolean uinttowindow(uintptr_t, Window &w);
125125

126126
void beep();
127127
bool setbeepsound(const char *sound);

0 commit comments

Comments
 (0)