Get things building on Windows ARM.

Add simple emulation of Tls* API on Windows Phone.
This commit is contained in:
Henrik Rydgard authored and Henrik Rydgård committed 2017-03-23 10:02:28 +01:00
1 parent 792dd1557c
commit 0bd43b242d
7 files changed
+38 -16

No files matched your search

+12
View File
@@ -10,7 +10,10 @@ using namespace Concurrency;
using namespace Windows::Storage;
using namespace Windows::Storage::Streams;
std::mutex initMutex;
StorageFileLoader::StorageFileLoader(Windows::Storage::StorageFile ^file) {
initMutex.lock();
file_ = file;
path_ = FromPlatformString(file_->Path);
thread_.reset(new std::thread([this]() { this->threadfunc(); }));
@@ -42,6 +45,9 @@ void StorageFileLoader::threadfunc() {
const char *what = e.what();
ILOG("%s", what);
}
catch (Platform::COMException ^e) {
}
auto sizetask = create_task(file_->GetBasicPropertiesAsync()).then([this](Windows::Storage::FileProperties::BasicProperties ^props) {
size_ = props->Size;
@@ -53,6 +59,12 @@ void StorageFileLoader::threadfunc() {
const char *what = e.what();
ILOG("%s", what);
}
catch (Platform::COMException ^e) {
std::string what = FromPlatformString(e->ToString());
ILOG("%s", what);
}
initMutex.unlock();
initMutex.unlock();