From: terencehill Date: Fri, 6 Aug 2010 11:45:38 +0000 (+0200) Subject: UNIX eols, please! X-Git-Tag: xonotic-v0.8.0~139^2~1^2~155^2~67 X-Git-Url: https://git.rm.cloudns.org/?a=commitdiff_plain;h=ec3059d4e6181e9f577157963ad8623300631640;p=xonotic%2Fxonotic-data.pk3dir.git UNIX eols, please! --- diff --git a/qcsrc/menu/xonotic/dialog_multiplayer_screenshot_screenshotviewer.c b/qcsrc/menu/xonotic/dialog_multiplayer_screenshot_screenshotviewer.c index 4e31e21f3..4c7ead456 100644 --- a/qcsrc/menu/xonotic/dialog_multiplayer_screenshot_screenshotviewer.c +++ b/qcsrc/menu/xonotic/dialog_multiplayer_screenshot_screenshotviewer.c @@ -1,45 +1,45 @@ -#ifdef INTERFACE -CLASS(XonoticScreenshotViewerDialog) EXTENDS(XonoticRootDialog) - METHOD(XonoticScreenshotViewerDialog, fill, void(entity)) - METHOD(XonoticScreenshotViewerDialog, loadScreenshot, void(entity, string)) - ATTRIB(XonoticScreenshotViewerDialog, title, string, "Screenshot Viewer") - ATTRIB(XonoticScreenshotViewerDialog, intendedWidth, float, 1) - ATTRIB(XonoticScreenshotViewerDialog, rows, float, 25) - ATTRIB(XonoticScreenshotViewerDialog, columns, float, 6.5) - ATTRIB(XonoticScreenshotViewerDialog, screenshotImage, entity, NULL) - ATTRIB(XonoticScreenshotViewerDialog, scrList, entity, NULL) -ENDCLASS(XonoticScreenshotViewerDialog) -#endif - -#ifdef IMPLEMENTATION -void XonoticScreenshotViewerDialog_loadScreenshot(entity me, string scrImage) -{ +#ifdef INTERFACE +CLASS(XonoticScreenshotViewerDialog) EXTENDS(XonoticRootDialog) + METHOD(XonoticScreenshotViewerDialog, fill, void(entity)) + METHOD(XonoticScreenshotViewerDialog, loadScreenshot, void(entity, string)) + ATTRIB(XonoticScreenshotViewerDialog, title, string, "Screenshot Viewer") + ATTRIB(XonoticScreenshotViewerDialog, intendedWidth, float, 1) + ATTRIB(XonoticScreenshotViewerDialog, rows, float, 25) + ATTRIB(XonoticScreenshotViewerDialog, columns, float, 6.5) + ATTRIB(XonoticScreenshotViewerDialog, screenshotImage, entity, NULL) + ATTRIB(XonoticScreenshotViewerDialog, scrList, entity, NULL) +ENDCLASS(XonoticScreenshotViewerDialog) +#endif + +#ifdef IMPLEMENTATION +void XonoticScreenshotViewerDialog_loadScreenshot(entity me, string scrImage) +{ if (me.screenshotImage.src) - strunzone(me.screenshotImage.src); - me.screenshotImage.src = strzone(scrImage); - me.screenshotImage.updateAspect(me.screenshotImage); -} -void prevScreenshot_Click(entity btn, entity me) -{ - me.scrList.goScreenshot(me.scrList, -1); -} -void nextScreenshot_Click(entity btn, entity me) -{ - me.scrList.goScreenshot(me.scrList, +1); -} -void XonoticScreenshotViewerDialog_fill(entity me) -{ - entity e; - - me.TR(me); - me.TD(me, me.rows - 1, me.columns, e = makeXonoticImage(string_null, -1)); - me.screenshotImage = e; - me.gotoRC(me, me.rows - 1, 0); - me.TD(me, 1, me.columns/2, e = makeXonoticButton("Prev", '0 0 0')); - e.onClick = prevScreenshot_Click; - e.onClickEntity = me; - me.TD(me, 1, me.columns/2, e = makeXonoticButton("Next", '0 0 0')); - e.onClick = nextScreenshot_Click; - e.onClickEntity = me; -} -#endif + strunzone(me.screenshotImage.src); + me.screenshotImage.src = strzone(scrImage); + me.screenshotImage.updateAspect(me.screenshotImage); +} +void prevScreenshot_Click(entity btn, entity me) +{ + me.scrList.goScreenshot(me.scrList, -1); +} +void nextScreenshot_Click(entity btn, entity me) +{ + me.scrList.goScreenshot(me.scrList, +1); +} +void XonoticScreenshotViewerDialog_fill(entity me) +{ + entity e; + + me.TR(me); + me.TD(me, me.rows - 1, me.columns, e = makeXonoticImage(string_null, -1)); + me.screenshotImage = e; + me.gotoRC(me, me.rows - 1, 0); + me.TD(me, 1, me.columns/2, e = makeXonoticButton("Prev", '0 0 0')); + e.onClick = prevScreenshot_Click; + e.onClickEntity = me; + me.TD(me, 1, me.columns/2, e = makeXonoticButton("Next", '0 0 0')); + e.onClick = nextScreenshot_Click; + e.onClickEntity = me; +} +#endif