History

One more pass of clean up on the platform api, returning the complete description in a single call, adding the version of the OS and deprecating legacy PlatformInfo calls

Sam Gateau committed 7 years ago

Commit 53094ef1 parent 7ad097516 files · +210 −111Browse files

Showing the changes to interface/src/scripting/PlatformInfoScriptingInterface.cpp (1 of 16 files). Show all

Unified · Split

interface/src/scripting/PlatformInfoScriptingInterface.cpp+5−1
@@ -192,7 +192,7 @@ QString PlatformInfoScriptingInterface::getDisplay(int index) { · 191 unmodified lines
192}192}
193 193
194QString PlatformInfoScriptingInterface::getMemory() {194QString PlatformInfoScriptingInterface::getMemory() {
195 auto desc = platform::getMemory(0);195 auto desc = platform::getMemory();
196 return QString(desc.dump().c_str());196 return QString(desc.dump().c_str());
197}197}
198 198
@@ -201,6 +201,10 @@ QString PlatformInfoScriptingInterface::getComputer() { · 2 unmodified lines
201 return QString(desc.dump().c_str());201 return QString(desc.dump().c_str());
202}202}
203 203
204QString PlatformInfoScriptingInterface::getPlatform() {
205 auto desc = platform::getAll();
206 return QString(desc.dump().c_str());
207}
204 208
205PlatformInfoScriptingInterface::PlatformTier PlatformInfoScriptingInterface::getTierProfiled() {209PlatformInfoScriptingInterface::PlatformTier PlatformInfoScriptingInterface::getTierProfiled() {
206 return (PlatformInfoScriptingInterface::PlatformTier) platform::Profiler::profilePlatform();210 return (PlatformInfoScriptingInterface::PlatformTier) platform::Profiler::profilePlatform();