ucode_error_report = FALSE; // don't report any more ucode errors from this game

}

}

}

-#ifdef _WIN32

-RECT prev_rect;

-#endif // _WIN32

-

void drawNoFullscreenMessage()

{

LOG ("drawNoFullscreenMessage ()\n");

-#ifdef _WIN32

- SIZE str_size;

- RECT win_rect;

- HWND active_wnd = GetForegroundWindow ();

-

- GetClientRect (gfx.hWnd, &win_rect);

- if (win_rect.bottom != prev_rect.bottom ||

- win_rect.right != prev_rect.right ||

- rdp.window_changed)

- {

- rdp.window_changed = FALSE;

-

- prev_rect.bottom = win_rect.bottom;

- prev_rect.right = win_rect.right;

-

- HDC hdc = GetDC(gfx.hWnd);

- SetBkMode (hdc, TRANSPARENT);

- SetTextColor (hdc, RGB(255,255,255));

-

- FillRect (hdc, &win_rect, (HBRUSH)GetStockObject(DKGRAY_BRUSH));

-

- win_rect.bottom >>= 1;

- win_rect.right >>= 1;

-

- sprintf (out_buf, "Glide64");

- GetTextExtentPoint32 (hdc, out_buf, strlen(out_buf), &str_size);

- TextOut (hdc, win_rect.right - (str_size.cx>>1),

- win_rect.bottom - str_size.cy - 32, out_buf, strlen(out_buf));

-

- sprintf (out_buf, "Gfx cannot be drawn in windowed mode");

- GetTextExtentPoint32 (hdc, out_buf, strlen(out_buf), &str_size);

- TextOut (hdc, win_rect.right - (str_size.cx>>1),

- win_rect.bottom - str_size.cy - 2, out_buf, strlen(out_buf));

-

- sprintf (out_buf, "Press Alt+Enter to switch to fullscreen");

- GetTextExtentPoint32 (hdc, out_buf, strlen(out_buf), &str_size);

- TextOut (hdc, win_rect.right - (str_size.cx>>1),

- win_rect.bottom + 2, out_buf, strlen(out_buf));

- }

-#endif // _WIN32

}

static WORD yuv_to_rgb(BYTE y, BYTE u, BYTE v)

return;

}

fullscreen = TRUE;

-#ifdef _WIN32

- if (gfx.hStatusBar)

- ShowWindow( gfx.hStatusBar, SW_HIDE );

- ShowCursor( FALSE );

-#endif // _WIN32

}

// Clear out the RDP log

} catch (...) {

if (fullscreen) ReleaseGfx ();

-# ifdef _WIN32

- if (MessageBox (gfx.hWnd, "The GFX plugin caused an exception and has been disabled.\nWould you like to turn it back on and attempt to continue?", "Glide64 Exception", MB_YESNO|MB_ICONEXCLAMATION) == IDNO)

+ if (messagebox("Glide64 Exception", MB_YESNO|MB_ICONEXCLAMATION, "The GFX plugin caused an exception and has been disabled.\nWould you like to turn it back on and attempt to continue?") == 2)

exception = TRUE;

-# else // _WIN32

- if (messagebox("Glide64 Exception", MB_YESNO|MB_ICONEXCLAMATION, "The GFX plugin caused an exception and has been disabled.\nWould you like to turn it back on and attempt to continue?") == 2)

- exception = TRUE;

-# endif // _WIN32

}

#endif

return;

}

fullscreen = TRUE;

-#ifdef _WIN32

- if (gfx.hStatusBar)

- ShowWindow( gfx.hStatusBar, SW_HIDE );

- ShowCursor( FALSE );

-#endif // _WIN32

}

// Clear out the RDP log

} catch (...) {

if (fullscreen) ReleaseGfx ();

-# ifdef _WIN32

- if (MessageBox (gfx.hWnd, "The GFX plugin caused an exception and has been disabled.\nWould you like to turn it back on and attempt to continue?", "Glide64 Exception", MB_YESNO|MB_ICONEXCLAMATION) == IDNO)

+ if (messagebox("Glide64 Exception", MB_YESNO|MB_ICONEXCLAMATION, "The GFX plugin caused an exception and has been disabled.\nWould you like to turn it back on and attempt to continue?") == 2)

exception = TRUE;

-# else // _WIN32

- if (messagebox("Glide64 Exception", MB_YESNO|MB_ICONEXCLAMATION, "The GFX plugin caused an exception and has been disabled.\nWould you like to turn it back on and attempt to continue?") == 2)