forked from Segs/Segs
-
Notifications
You must be signed in to change notification settings - Fork 0
Commit
This commit does not belong to any branch on this repository, and may belong to a fork outside of the repository.
Merge branch 'misc-pigg-fix' of https://github.com/miles200/Segs into…
… miles200-misc-pigg-fix
- Loading branch information
Showing
12 changed files
with
323 additions
and
157 deletions.
There are no files selected for viewing
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Binary file not shown.
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,23 @@ | ||
#include "Helpers.h" | ||
#include "Settings.h" | ||
|
||
#include <QSettings> | ||
#include <QFileInfo> | ||
|
||
Helpers::Helpers() | ||
{ | ||
|
||
} | ||
|
||
QString Helpers::getMapsDir() | ||
{ | ||
// Get maps_dir from settings.cfg | ||
QFileInfo config_file_info = Settings::getSettingsPath(); | ||
QString config_file_path = config_file_info.absoluteFilePath(); | ||
QSettings config_file(config_file_path, QSettings::IniFormat); | ||
config_file.beginGroup("MapServer"); | ||
QString maps_dir = config_file.value("maps","").toString(); | ||
config_file.endGroup(); | ||
|
||
return maps_dir; | ||
} |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,13 @@ | ||
#ifndef HELPERS_H | ||
#define HELPERS_H | ||
|
||
#include <QObject> | ||
|
||
class Helpers | ||
{ | ||
public: | ||
Helpers(); | ||
static QString getMapsDir(); | ||
}; | ||
|
||
#endif // HELPERS_H |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Oops, something went wrong.