diff options
-rw-r--r-- | src/screenshot.cpp | 10 | ||||
-rw-r--r-- | src/screenshot.h | 2 | ||||
-rw-r--r-- | src/screenshot_gui.cpp | 2 | ||||
-rw-r--r-- | src/toolbar_gui.cpp | 16 |
4 files changed, 15 insertions, 15 deletions
diff --git a/src/screenshot.cpp b/src/screenshot.cpp index d2bb6a1f3..c89586226 100644 --- a/src/screenshot.cpp +++ b/src/screenshot.cpp @@ -845,12 +845,12 @@ static void ScreenshotConfirmationCallback(Window *w, bool confirmed) } /** - * Take a screenshot. - * Ask for confirmation if the screenshot will be huge. Delegates to \c MakeScreenshot to perform the action. + * Make a screenshot. + * Ask for confirmation first if the screenshot will be huge. * @param t Screenshot type: World, defaultzoom, heightmap or viewport screenshot * @see MakeScreenshot */ -void TakeScreenshot(ScreenshotType t) +void MakeScreenshotWithConfirm(ScreenshotType t) { ViewPort vp; SetupScreenshotViewport(t, &vp); @@ -868,11 +868,11 @@ void TakeScreenshot(ScreenshotType t) /** * Make a screenshot. - * No questions asked, just do it. + * Unconditionally take a screenshot of the requested type. * @param t the type of screenshot to make. * @param name the name to give to the screenshot. * @return true iff the screenshot was made successfully - * @see TakeScreenshot + * @see MakeScreenshotWithConfirm */ bool MakeScreenshot(ScreenshotType t, const char *name) { diff --git a/src/screenshot.h b/src/screenshot.h index 2f6324c22..b87259363 100644 --- a/src/screenshot.h +++ b/src/screenshot.h @@ -27,7 +27,7 @@ enum ScreenshotType { void SetupScreenshotViewport(ScreenshotType t, struct ViewPort *vp); bool MakeHeightmapScreenshot(const char *filename); -void TakeScreenshot(ScreenshotType t); +void MakeScreenshotWithConfirm(ScreenshotType t); bool MakeScreenshot(ScreenshotType t, const char *name); bool MakeMinimapWorldScreenshot(); diff --git a/src/screenshot_gui.cpp b/src/screenshot_gui.cpp index ae5854fb7..c0e65f13d 100644 --- a/src/screenshot_gui.cpp +++ b/src/screenshot_gui.cpp @@ -39,7 +39,7 @@ struct ScreenshotWindow : Window { case WID_SC_TAKE_HEIGHTMAP: st = SC_HEIGHTMAP; break; case WID_SC_TAKE_MINIMAP: st = SC_MINIMAP; break; } - TakeScreenshot(st); + MakeScreenshotWithConfirm(st); } }; diff --git a/src/toolbar_gui.cpp b/src/toolbar_gui.cpp index 4d97abb72..f471ac115 100644 --- a/src/toolbar_gui.cpp +++ b/src/toolbar_gui.cpp @@ -2086,10 +2086,10 @@ struct MainToolbarWindow : Window { case MTHK_BUILD_TREES: ShowBuildTreesToolbar(); break; case MTHK_MUSIC: ShowMusicWindow(); break; case MTHK_AI_DEBUG: ShowAIDebugWindow(); break; - case MTHK_SMALL_SCREENSHOT: TakeScreenshot(SC_VIEWPORT); break; - case MTHK_ZOOMEDIN_SCREENSHOT: TakeScreenshot(SC_ZOOMEDIN); break; - case MTHK_DEFAULTZOOM_SCREENSHOT: TakeScreenshot(SC_DEFAULTZOOM); break; - case MTHK_GIANT_SCREENSHOT: TakeScreenshot(SC_WORLD); break; + case MTHK_SMALL_SCREENSHOT: MakeScreenshotWithConfirm(SC_VIEWPORT); break; + case MTHK_ZOOMEDIN_SCREENSHOT: MakeScreenshotWithConfirm(SC_ZOOMEDIN); break; + case MTHK_DEFAULTZOOM_SCREENSHOT: MakeScreenshotWithConfirm(SC_DEFAULTZOOM); break; + case MTHK_GIANT_SCREENSHOT: MakeScreenshotWithConfirm(SC_WORLD); break; case MTHK_CHEATS: if (!_networking) ShowCheatWindow(); break; case MTHK_TERRAFORM: ShowTerraformToolbar(); break; case MTHK_EXTRA_VIEWPORT: ShowExtraViewPortWindowForTileUnderCursor(); break; @@ -2461,10 +2461,10 @@ struct ScenarioEditorToolbarWindow : Window { case MTEHK_SIGN: cbf = ToolbarScenPlaceSign(this); break; case MTEHK_MUSIC: ShowMusicWindow(); break; case MTEHK_LANDINFO: cbf = PlaceLandBlockInfo(); break; - case MTEHK_SMALL_SCREENSHOT: TakeScreenshot(SC_VIEWPORT); break; - case MTEHK_ZOOMEDIN_SCREENSHOT: TakeScreenshot(SC_ZOOMEDIN); break; - case MTEHK_DEFAULTZOOM_SCREENSHOT: TakeScreenshot(SC_DEFAULTZOOM); break; - case MTEHK_GIANT_SCREENSHOT: TakeScreenshot(SC_WORLD); break; + case MTEHK_SMALL_SCREENSHOT: MakeScreenshotWithConfirm(SC_VIEWPORT); break; + case MTEHK_ZOOMEDIN_SCREENSHOT: MakeScreenshotWithConfirm(SC_ZOOMEDIN); break; + case MTEHK_DEFAULTZOOM_SCREENSHOT: MakeScreenshotWithConfirm(SC_DEFAULTZOOM); break; + case MTEHK_GIANT_SCREENSHOT: MakeScreenshotWithConfirm(SC_WORLD); break; case MTEHK_ZOOM_IN: ToolbarZoomInClick(this); break; case MTEHK_ZOOM_OUT: ToolbarZoomOutClick(this); break; case MTEHK_TERRAFORM: ShowEditorTerraformToolbar(); break; |