diff options
author | Philipp Sehmisch <crush@themanaworld.org> | 2009-01-18 14:34:53 +0100 |
---|---|---|
committer | Bjørn Lindeijer <bjorn@lindeijer.nl> | 2009-01-20 20:48:19 +0100 |
commit | b032adccbc64ebe316c72c7b541d7edf61f27ef5 (patch) | |
tree | 7d5be9fc04d3312c226daee03bcf7fe77df57c63 /src/gui | |
parent | 8f741827bec1b615769a59014cbbd634056aaa25 (diff) | |
download | mana-client-b032adccbc64ebe316c72c7b541d7edf61f27ef5.tar.gz mana-client-b032adccbc64ebe316c72c7b541d7edf61f27ef5.tar.bz2 mana-client-b032adccbc64ebe316c72c7b541d7edf61f27ef5.tar.xz mana-client-b032adccbc64ebe316c72c7b541d7edf61f27ef5.zip |
Added current map filename to debug window.
(cherry picked from mainline commit 2a7c63f6070606e6623a9730aa1ca9d52c942055)
Diffstat (limited to 'src/gui')
-rw-r--r-- | src/gui/debugwindow.cpp | 35 | ||||
-rw-r--r-- | src/gui/debugwindow.h | 2 |
2 files changed, 23 insertions, 14 deletions
diff --git a/src/gui/debugwindow.cpp b/src/gui/debugwindow.cpp index f6e9414e..1509aa8b 100644 --- a/src/gui/debugwindow.cpp +++ b/src/gui/debugwindow.cpp @@ -43,27 +43,31 @@ DebugWindow::DebugWindow(): setResizable(true); setCloseButton(true); - setDefaultSize(0, 0, 400, 100); + setDefaultSize(0, 0, 400, 60); loadWindowState(); mFPSLabel = new gcn::Label("[0 FPS]"); mFPSLabel->setPosition(0,0); - mMusicFileLabel = new gcn::Label("Music File: "); - mMusicFileLabel->setPosition(0, 20); + mMusicFileLabel = new gcn::Label("Music: "); + mMusicFileLabel->setPosition(0, 15); - mMapFileLabel = new gcn::Label("Mini-Map File: "); - mMapFileLabel->setPosition(0, 40); + mMapLabel = new gcn::Label("Map: "); + mMapLabel->setPosition(0, 30); + + mMiniMapLabel = new gcn::Label("Mini-Map: "); + mMiniMapLabel->setPosition(0, 45); mTileMouseLabel = new gcn::Label("[Mouse: 0, 0]"); - mTileMouseLabel->setPosition(100, 0); + mTileMouseLabel->setPosition(200, 0); mParticleCountLabel = new gcn::Label("[Particle count: 0]"); - mParticleCountLabel->setPosition(100, 60); + mParticleCountLabel->setPosition(200, 15); add(mFPSLabel); add(mMusicFileLabel); - add(mMapFileLabel); + add(mMiniMapLabel); + add(mMapLabel); add(mTileMouseLabel); add(mParticleCountLabel); } @@ -77,7 +81,7 @@ DebugWindow::logic() int mouseTileX = mouseX / 32 + viewport->getCameraX(); int mouseTileY = mouseY / 32 + viewport->getCameraY(); - mFPSLabel->setCaption("[" + toString(fps) + " FPS"); + mFPSLabel->setCaption("[" + toString(fps) + " FPS]"); mFPSLabel->adjustSize(); mTileMouseLabel->setCaption("[Mouse: " + @@ -88,14 +92,19 @@ DebugWindow::logic() if (currentMap != NULL) { const std::string music = - " [Music File: " + currentMap->getProperty("music") + "]"; + " [Music: " + currentMap->getProperty("music") + "]"; mMusicFileLabel->setCaption(music); mMusicFileLabel->adjustSize(); const std::string minimap = - " [MiniMap File: " + currentMap->getProperty("minimap") + "]"; - mMapFileLabel->setCaption(minimap); - mMapFileLabel->adjustSize(); + " [MiniMap: " + currentMap->getProperty("minimap") + "]"; + mMiniMapLabel->setCaption(minimap); + mMiniMapLabel->adjustSize(); + + const std::string map = + " [Map: " + currentMap->getProperty("_filename") + "]"; + mMapLabel->setCaption(map); + mMapLabel->adjustSize(); } mParticleCountLabel->setCaption("[Particle count: " + diff --git a/src/gui/debugwindow.h b/src/gui/debugwindow.h index ae1d8b14..8d8b7822 100644 --- a/src/gui/debugwindow.h +++ b/src/gui/debugwindow.h @@ -49,7 +49,7 @@ class DebugWindow : public Window void logic(); private: - gcn::Label *mMusicFileLabel, *mMapFileLabel; + gcn::Label *mMusicFileLabel, *mMapLabel, *mMiniMapLabel; gcn::Label *mTileMouseLabel, *mFPSLabel; gcn::Label *mParticleCountLabel; }; |