From cc37b4a9153379d5c5529ba85305d36efba2cd85 Mon Sep 17 00:00:00 2001 From: Ira Rice Date: Fri, 30 Jan 2009 09:17:03 -0700 Subject: Changed the minimap to remember whether the minimap was toggled or not when the client was last exited. Signed-off-by: Ira Rice --- src/gui/minimap.cpp | 5 +++-- 1 file changed, 3 insertions(+), 2 deletions(-) diff --git a/src/gui/minimap.cpp b/src/gui/minimap.cpp index d1d3af46..0b156fc4 100644 --- a/src/gui/minimap.cpp +++ b/src/gui/minimap.cpp @@ -41,7 +41,7 @@ Minimap::Minimap(): mProportion(0.5) { setWindowName(_("MiniMap")); - mShow = config.getValue(getWindowName() + "Visible", true); + mShow = config.getValue(getWindowName() + "Show", true); setDefaultSize(5, 25, 100, 100); setResizable(true); @@ -52,6 +52,8 @@ Minimap::~Minimap() { if (mMapImage) mMapImage->decRef(); + + config.setValue(getWindowName() + "Show", mShow); } void Minimap::setMapImage(Image *img) @@ -106,7 +108,6 @@ void Minimap::setMapImage(Image *img) void Minimap::toggle() { mShow = !mShow; - config.setValue(getWindowName() + "Visible", mShow); } void Minimap::draw(gcn::Graphics *graphics) -- cgit v1.2.3-70-g09d2