1
0
mirror of https://github.com/OpenRCT2/OpenRCT2 synced 2026-01-28 17:24:47 +01:00

added GCC/MinGW-compatible assembler

This commit is contained in:
anyc
2014-05-19 22:53:14 +02:00
parent 872f4521a0
commit d34e2db9e1
28 changed files with 1536 additions and 5 deletions

View File

@@ -98,8 +98,18 @@ static void window_title_exit_mouseup()
short widgetIndex;
rct_window *w;
#ifdef _MSC_VER
__asm mov widgetIndex, dx
#else
__asm__ ( "mov %[widgetIndex], dx " : [widgetIndex] "+m" (widgetIndex) );
#endif
#ifdef _MSC_VER
__asm mov w, esi
#else
__asm__ ( "mov %[w], esi " : [w] "+m" (w) );
#endif
if (RCT2_GLOBAL(RCT2_ADDRESS_RUN_INTRO_TICK_PART, int) != 0)
return;
@@ -117,8 +127,18 @@ static void window_title_exit_paint()
rct_window *w;
rct_drawpixelinfo *dpi;
#ifdef _MSC_VER
__asm mov w, esi
#else
__asm__ ( "mov %[w], esi " : [w] "+m" (w) );
#endif
#ifdef _MSC_VER
__asm mov dpi, edi
#else
__asm__ ( "mov %[dpi], edi " : [dpi] "+m" (dpi) );
#endif
window_draw_widgets(w, dpi);
}