From e5cc33fc678428d7898e428ef7f8a792fe120bfa Mon Sep 17 00:00:00 2001 From: charlie Date: Sun, 21 Jan 2018 22:07:23 -0500 Subject: [PATCH] Added SS version string --- include/Version.h | 6 ++++++ include/views/SettingsView.h | 2 ++ src/views/SettingsView.cpp | 4 ++++ xcode/SilverSprint.xcodeproj/project.pbxproj | 2 ++ 4 files changed, 14 insertions(+) create mode 100644 include/Version.h diff --git a/include/Version.h b/include/Version.h new file mode 100644 index 0000000..9572f16 --- /dev/null +++ b/include/Version.h @@ -0,0 +1,6 @@ + +// SILVERSPRINT_VERSION % 100 is the patch level +// SILVERSPRINT_VERSION / 100 % 1000 is the minor version +// SILVERSPRINT_VERSION / 100000 is the major version +#define SILVERSPRINT_VERSION 104 +#define SILVERSPRINT_VERSION_STR "0.1.4" diff --git a/include/views/SettingsView.h b/include/views/SettingsView.h index 7754ee5..c6789ab 100644 --- a/include/views/SettingsView.h +++ b/include/views/SettingsView.h @@ -13,6 +13,8 @@ #include "cinder/gl/gl.h" #include "cinder/Log.h" +#include "Version.h" + #include "data/StateManager.h" #include "data/Model.h" #include "data/GFXGlobal.h" diff --git a/src/views/SettingsView.cpp b/src/views/SettingsView.cpp index 56cf231..cf53477 100644 --- a/src/views/SettingsView.cpp +++ b/src/views/SettingsView.cpp @@ -232,5 +232,9 @@ void SettingsView::draw() { mMphKphToggle->draw(); } + { + gl::ScopedColor scGr( Color::gray(0.55) ); + tFont->drawString("SILVERSPRINT VERSION: " + std::string(SILVERSPRINT_VERSION_STR), vec2(60, 1080- 20)); + } } } diff --git a/xcode/SilverSprint.xcodeproj/project.pbxproj b/xcode/SilverSprint.xcodeproj/project.pbxproj index b4c473a..492dcbb 100644 --- a/xcode/SilverSprint.xcodeproj/project.pbxproj +++ b/xcode/SilverSprint.xcodeproj/project.pbxproj @@ -99,6 +99,7 @@ CB37B3851E297897009FC93A /* ssIcn.icns */ = {isa = PBXFileReference; lastKnownFileType = image.icns; name = ssIcn.icns; path = ../resources/ssIcn.icns; sourceTree = ""; }; CB49AA201E44F1A300820D70 /* ParticleSystem.cpp */ = {isa = PBXFileReference; fileEncoding = 4; lastKnownFileType = sourcecode.cpp.cpp; path = ParticleSystem.cpp; sourceTree = ""; }; CB49AA211E44F1A300820D70 /* ParticleSystem.h */ = {isa = PBXFileReference; fileEncoding = 4; lastKnownFileType = sourcecode.c.h; path = ParticleSystem.h; sourceTree = ""; }; + CB628DD120158AB3008FC730 /* Version.h */ = {isa = PBXFileReference; lastKnownFileType = sourcecode.c.h; name = Version.h; path = ../include/Version.h; sourceTree = ""; }; CB675B9D1FCB5A3100AF05DA /* ToggleBtn.cpp */ = {isa = PBXFileReference; fileEncoding = 4; lastKnownFileType = sourcecode.cpp.cpp; path = ToggleBtn.cpp; sourceTree = ""; }; CB675B9F1FCB5A3E00AF05DA /* ToggleBtn.h */ = {isa = PBXFileReference; lastKnownFileType = sourcecode.c.h; path = ToggleBtn.h; sourceTree = ""; }; CB675BA01FCD16D200AF05DA /* Config.h */ = {isa = PBXFileReference; lastKnownFileType = sourcecode.c.h; path = Config.h; sourceTree = ""; }; @@ -232,6 +233,7 @@ 29B97315FDCFA39411CA2CEA /* Headers */ = { isa = PBXGroup; children = ( + CB628DD120158AB3008FC730 /* Version.h */, CBF06F101C5012070064CC52 /* app */, CBF06F131C5012070064CC52 /* data */, CBF06F191C5012070064CC52 /* ui */,