summaryrefslogtreecommitdiffstats
path: root/Tools/QtBiomeVisualiser/MainWindow.h
diff options
context:
space:
mode:
authormadmaxoft <github@xoft.cz>2014-09-20 23:03:13 +0200
committermadmaxoft <github@xoft.cz>2014-09-20 23:03:13 +0200
commit14123c6d1653b79b6c58e7766dc97e5d06bf1fc9 (patch)
tree621cbf970666b86d239b3bba58a9217cc2ec9292 /Tools/QtBiomeVisualiser/MainWindow.h
parentFixed cParsedNBT::FindTagByPath(). (diff)
downloadcuberite-14123c6d1653b79b6c58e7766dc97e5d06bf1fc9.tar
cuberite-14123c6d1653b79b6c58e7766dc97e5d06bf1fc9.tar.gz
cuberite-14123c6d1653b79b6c58e7766dc97e5d06bf1fc9.tar.bz2
cuberite-14123c6d1653b79b6c58e7766dc97e5d06bf1fc9.tar.lz
cuberite-14123c6d1653b79b6c58e7766dc97e5d06bf1fc9.tar.xz
cuberite-14123c6d1653b79b6c58e7766dc97e5d06bf1fc9.tar.zst
cuberite-14123c6d1653b79b6c58e7766dc97e5d06bf1fc9.zip
Diffstat (limited to 'Tools/QtBiomeVisualiser/MainWindow.h')
-rw-r--r--Tools/QtBiomeVisualiser/MainWindow.h20
1 files changed, 20 insertions, 0 deletions
diff --git a/Tools/QtBiomeVisualiser/MainWindow.h b/Tools/QtBiomeVisualiser/MainWindow.h
index b37bf4120..997d7a5d2 100644
--- a/Tools/QtBiomeVisualiser/MainWindow.h
+++ b/Tools/QtBiomeVisualiser/MainWindow.h
@@ -1,5 +1,6 @@
#pragma once
+#include <QList>
#include <QMainWindow>
#include "BiomeView.h"
@@ -25,6 +26,9 @@ private slots:
/** Opens an existing world and displays the loaded biomes. */
void open();
+ /** Opens a vanilla world that is specified by the calling action. */
+ void openVanillaWorld();
+
protected:
// Actions:
QAction * m_actGen;
@@ -32,12 +36,28 @@ protected:
QAction * m_actReload;
QAction * m_actExit;
+ /** List of actions that open the specific vanilla world. */
+ QList<QAction *> m_WorldActions;
+
+ /** Path to the vanilla folder. */
+ QString m_MinecraftPath;
+
+
+ /** Initializes the m_MinecraftPath based on the proper MC path */
+ void initMinecraftPath();
/** Creates the actions that the UI supports. */
void createActions();
+ /** Creates the actions that open a specific vanilla world. Iterates over the minecraft saves folder. */
+ void createWorldActions();
+
/** Creates the menu bar and connects its events. */
void createMenus();
+
+ /** Returns the name of the vanilla world in the specified path.
+ Reads the level.dat file for the name. Returns an empty string on failure. */
+ QString getWorldName(const AString & a_Path);
};