From 6ad0f555d424eedb40f231b951a9ed7dd9bc4836 Mon Sep 17 00:00:00 2001 From: Andrei Drexler Date: Wed, 24 Jun 2009 22:45:58 +0000 Subject: [PATCH] UI_WIDTH and UI_HEIGHT symbols. --- reaction/ta_ui/ui_main.c | 11 +++++++---- 1 file changed, 7 insertions(+), 4 deletions(-) diff --git a/reaction/ta_ui/ui_main.c b/reaction/ta_ui/ui_main.c index 1babae94..affa1bbf 100644 --- a/reaction/ta_ui/ui_main.c +++ b/reaction/ta_ui/ui_main.c @@ -594,10 +594,13 @@ static void UI_ExportSymbols() const char* fname = s_symbols_temp_file_name; if (trap_FS_FOpenFile(fname, &f, FS_WRITE) >= 0) { - DefineSymbol(f, "UI_MINX", va("%.0f", uiInfo.uiDC.min[0])); - DefineSymbol(f, "UI_MINY", va("%.0f", uiInfo.uiDC.min[1])); - DefineSymbol(f, "UI_MAXX", va("%.0f", uiInfo.uiDC.max[0])); - DefineSymbol(f, "UI_MAXY", va("%.0f", uiInfo.uiDC.max[1])); + DefineSymbol(f, "UI_MINX", va("%f", uiInfo.uiDC.min[0])); + DefineSymbol(f, "UI_MINY", va("%f", uiInfo.uiDC.min[1])); + DefineSymbol(f, "UI_MAXX", va("%f", uiInfo.uiDC.max[0])); + DefineSymbol(f, "UI_MAXY", va("%f", uiInfo.uiDC.max[1])); + + DefineSymbol(f, "UI_WIDTH", va("%f", uiInfo.uiDC.max[0] - uiInfo.uiDC.min[0])); + DefineSymbol(f, "UI_HEIGHT", va("%f", uiInfo.uiDC.max[1] - uiInfo.uiDC.min[1])); trap_FS_FCloseFile(f); }