winrt_init.cpp 688 B

12345678910111213141516171819
  1. // Copyright (C) 2014 Vicente Botet
  2. //
  3. // Distributed under the Boost Software License, Version 1.0. (See accompanying
  4. // file LICENSE_1_0.txt or copy at http://www.boost.org/LICENSE_1_0.txt)
  5. #include <boost/predef/platform.h>
  6. #if BOOST_PLAT_WINDOWS_RUNTIME
  7. #include <wrl\wrappers\corewrappers.h>
  8. #pragma comment(lib, "runtimeobject.lib")
  9. // Necessary for the tests which to keep the Windows Runtime active,
  10. // when running in an actual Windows store/phone application initialization
  11. // is handled automatically by the CRT.
  12. // This is easier than calling in the main function for each test case.
  13. Microsoft::WRL::Wrappers::RoInitializeWrapper runtime(RO_INIT_MULTITHREADED);
  14. #endif