Get this puppy started
This commit is contained in:
@@ -26,6 +26,7 @@ private:
|
||||
std::unique_ptr<Api::CSiaApi> _siaApi;
|
||||
std::unique_ptr<Api::CSiaCurl> _siaCurl;
|
||||
std::unique_ptr<Api::CSiaDriveConfig> _siaDriveConfig;
|
||||
bool _appStarted = false;
|
||||
|
||||
public:
|
||||
// CefApp methods:
|
||||
|
@@ -1,6 +1,8 @@
|
||||
#ifndef _SIACOMMON_H
|
||||
#define _SIACOMMON_H
|
||||
|
||||
#define SIDRIVE_VERSION_STRING "0.0.1"
|
||||
|
||||
#ifdef _WIN32
|
||||
// Unicode for Win32
|
||||
#define UNICODE
|
||||
|
@@ -121,6 +121,36 @@ public:
|
||||
return std::move(SString(std::to_string(value)));
|
||||
}
|
||||
|
||||
static inline std::uint32_t ToUInt32(const SString &str)
|
||||
{
|
||||
return std::stoul(str.str());
|
||||
}
|
||||
|
||||
static inline SString FromUInt32(const std::uint32_t &value)
|
||||
{
|
||||
return std::move(SString(std::to_string(value)));
|
||||
}
|
||||
|
||||
static inline std::int64_t ToInt64(const SString &str)
|
||||
{
|
||||
return std::stoi(str.str());
|
||||
}
|
||||
|
||||
static inline SString FromInt64(const std::int64_t &value)
|
||||
{
|
||||
return std::move(SString(std::to_string(value)));
|
||||
}
|
||||
|
||||
static inline SString FromUInt64(const std::uint64_t &value)
|
||||
{
|
||||
return std::move(SString(std::to_string(value)));
|
||||
}
|
||||
|
||||
static inline std::uint64_t ToUInt64(const SString &str)
|
||||
{
|
||||
return std::stoull(str.str());
|
||||
}
|
||||
|
||||
static inline std::uint8_t ToUInt8(const SString &str)
|
||||
{
|
||||
return (std::uint8_t) std::stoi(str.str());
|
||||
|
Reference in New Issue
Block a user