Skip to content

Commit

Permalink
Export GetBuildDate() and GetBuildId() to xrManagedApi
Browse files Browse the repository at this point in the history
And marked that xrCore.h is unmanaged
  • Loading branch information
Xottab-DUTY committed Nov 4, 2017
1 parent c8ed61f commit f975514
Show file tree
Hide file tree
Showing 2 changed files with 10 additions and 0 deletions.
7 changes: 7 additions & 0 deletions src/editors/xrManagedApi/core/Core.cpp
Original file line number Diff line number Diff line change
@@ -1,6 +1,8 @@
#include "Pch.hpp"
#include "Core.hpp"
#pragma unmanaged
#include "xrCore/xrCore.h"
#pragma managed
#include <msclr/marshal_cppstd.h>

namespace XRay
Expand Down Expand Up @@ -42,6 +44,11 @@ void Core::Initialize(String ^ appName, LogCallback ^ logCallback)

void Core::Initialize(String ^ appName) { Core::Initialize(appName, nullptr, false, nullptr); }
void Core::Destroy() { ::Core._destroy(); }

const String ^ Core::GetBuildDate() { return msclr::interop::marshal_as<String^>(::Core.GetBuildDate()); }

const UInt32 Core::GetBuildId() { return ::Core.GetBuildId(); }

}
}
}
3 changes: 3 additions & 0 deletions src/editors/xrManagedApi/core/Core.hpp
Original file line number Diff line number Diff line change
Expand Up @@ -22,6 +22,9 @@ ref class Core abstract sealed
static void Initialize(String ^ appName, LogCallback ^ logCallback);
static void Initialize(String ^ appName);
static void Destroy();

static const String ^ GetBuildDate();
static const UInt32 GetBuildId();
};
}
}
Expand Down

0 comments on commit f975514

Please sign in to comment.