mirror of
https://gitlab.com/famedly/fluffychat.git
synced 2024-11-16 00:49:31 +01:00
31 lines
917 B
C++
31 lines
917 B
C++
|
|
||
|
#include <windows.h>
|
||
|
|
||
|
#include "winrt/Windows.ApplicationModel.Core.h"
|
||
|
#include "winrt/Windows.Foundation.h"
|
||
|
#include <winrt/Windows.Foundation.Collections.h>
|
||
|
#include <winrt/Windows.UI.ViewManagement.Core.h>
|
||
|
#include <winrt/Windows.UI.ViewManagement.h>
|
||
|
|
||
|
#include <memory>
|
||
|
|
||
|
#include "flutter_frameworkview.cpp"
|
||
|
|
||
|
struct App
|
||
|
: winrt::implements<
|
||
|
App, winrt::Windows::ApplicationModel::Core::IFrameworkViewSource> {
|
||
|
App() { view_ = winrt::make_self<FlutterFrameworkView>(); }
|
||
|
|
||
|
// |winrt::Windows::ApplicationModel::Core::IFrameworkViewSource|
|
||
|
winrt::Windows::ApplicationModel::Core::IFrameworkView CreateView() {
|
||
|
return view_.as<winrt::Windows::ApplicationModel::Core::IFrameworkView>();
|
||
|
}
|
||
|
|
||
|
winrt::com_ptr<FlutterFrameworkView> view_;
|
||
|
};
|
||
|
|
||
|
int __stdcall wWinMain(HINSTANCE, HINSTANCE, PWSTR, int) {
|
||
|
winrt::Windows::ApplicationModel::Core::CoreApplication::Run(
|
||
|
winrt::make<App>());
|
||
|
}
|