#include "flutter/shell/platform/windows/public/flutter_windows.h"
#include <io.h>
#include <algorithm>
#include <chrono>
#include <cstdlib>
#include <filesystem>
#include <memory>
#include <vector>
#include "flutter/shell/platform/common/client_wrapper/include/flutter/plugin_registrar.h"
#include "flutter/shell/platform/common/incoming_message_dispatcher.h"
#include "flutter/shell/platform/common/path_utils.h"
#include "flutter/shell/platform/embedder/embedder.h"
#include "flutter/shell/platform/windows/dpi_utils.h"
#include "flutter/shell/platform/windows/flutter_project_bundle.h"
#include "flutter/shell/platform/windows/flutter_window.h"
#include "flutter/shell/platform/windows/flutter_windows_engine.h"
#include "flutter/shell/platform/windows/flutter_windows_view.h"
#include "flutter/shell/platform/windows/flutter_windows_view_controller.h"
#include "flutter/shell/platform/windows/window_binding_handler.h"
#include "flutter/shell/platform/windows/window_state.h"
Go to the source code of this file.
|
static |
Definition at line 79 of file flutter_windows.cc.
References flutter::FlutterWindowsEngine::CreateView(), EngineFromHandle(), HandleForViewController(), and flutter::FlutterWindowsEngine::windows_proc_table().
Referenced by FlutterDesktopEngineCreateViewController(), and FlutterDesktopViewControllerCreate().
|
static |
Definition at line 32 of file flutter_windows.cc.
Referenced by CreateViewController(), FlutterDesktopEngineDestroy(), FlutterDesktopEngineGetMessenger(), FlutterDesktopEngineGetPluginRegistrar(), FlutterDesktopEngineGetTextureRegistrar(), FlutterDesktopEngineProcessExternalWindowMessage(), FlutterDesktopEngineReloadSystemFonts(), FlutterDesktopEngineRun(), and FlutterDesktopEngineSetNextFrameCallback().
FlutterDesktopEngineRef FlutterDesktopEngineCreate | ( | const FlutterDesktopEngineProperties * | engine_properties | ) |
Definition at line 183 of file flutter_windows.cc.
References HandleForEngine().
Referenced by flutter::FlutterEngine::FlutterEngine(), and flutter::testing::TEST().
FlutterDesktopViewControllerRef FlutterDesktopEngineCreateViewController | ( | FlutterDesktopEngineRef | engine, |
const FlutterDesktopViewControllerProperties * | properties | ||
) |
Definition at line 128 of file flutter_windows.cc.
References CreateViewController(), FlutterDesktopViewControllerProperties::height, and FlutterDesktopViewControllerProperties::width.
Referenced by flutter::testing::TEST_F().
bool FlutterDesktopEngineDestroy | ( | FlutterDesktopEngineRef | engine_ref | ) |
Definition at line 190 of file flutter_windows.cc.
References EngineFromHandle(), flutter::FlutterWindowsEngine::running(), and flutter::FlutterWindowsEngine::Stop().
Referenced by flutter::FlutterEngine::ShutDown(), and flutter::testing::TEST().
FlutterDesktopMessengerRef FlutterDesktopEngineGetMessenger | ( | FlutterDesktopEngineRef | engine | ) |
Definition at line 228 of file flutter_windows.cc.
References EngineFromHandle(), and flutter::FlutterWindowsEngine::messenger().
Referenced by flutter::FlutterEngine::FlutterEngine().
FlutterDesktopPluginRegistrarRef FlutterDesktopEngineGetPluginRegistrar | ( | FlutterDesktopEngineRef | engine, |
const char * | plugin_name | ||
) |
Definition at line 218 of file flutter_windows.cc.
References EngineFromHandle(), and flutter::FlutterWindowsEngine::GetRegistrar().
Referenced by flutter::FlutterEngine::GetRegistrarForPlugin(), and flutter::testing::TEST_F().
FlutterDesktopTextureRegistrarRef FlutterDesktopEngineGetTextureRegistrar | ( | FlutterDesktopEngineRef | engine | ) |
Definition at line 233 of file flutter_windows.cc.
References EngineFromHandle(), and HandleForTextureRegistrar().
Referenced by flutter::testing::TEST().
bool FlutterDesktopEngineProcessExternalWindowMessage | ( | FlutterDesktopEngineRef | engine, |
HWND | hwnd, | ||
UINT | message, | ||
WPARAM | wparam, | ||
LPARAM | lparam, | ||
LRESULT * | result | ||
) |
Definition at line 266 of file flutter_windows.cc.
References EngineFromHandle(), message, and flutter::FlutterWindowsEngine::ProcessExternalWindowMessage().
Referenced by flutter::FlutterEngine::ProcessExternalWindowMessage().
uint64_t FlutterDesktopEngineProcessMessages | ( | FlutterDesktopEngineRef | engine | ) |
Definition at line 210 of file flutter_windows.cc.
Referenced by flutter::FlutterEngine::ProcessMessages().
void FlutterDesktopEngineRegisterPlatformViewType | ( | FlutterDesktopEngineRef | engine, |
const char * | view_type_name, | ||
FlutterPlatformViewTypeEntry | view_type | ||
) |
Definition at line 282 of file flutter_windows.cc.
void FlutterDesktopEngineReloadSystemFonts | ( | FlutterDesktopEngineRef | engine | ) |
Definition at line 214 of file flutter_windows.cc.
References EngineFromHandle(), and flutter::FlutterWindowsEngine::ReloadSystemFonts().
Referenced by flutter::FlutterEngine::ReloadSystemFonts().
bool FlutterDesktopEngineRun | ( | FlutterDesktopEngineRef | engine, |
const char * | entry_point | ||
) |
Definition at line 200 of file flutter_windows.cc.
References EngineFromHandle(), and flutter::FlutterWindowsEngine::Run().
Referenced by flutter::FlutterEngine::Run(), and flutter::testing::TEST_F().
void FlutterDesktopEngineSetNextFrameCallback | ( | FlutterDesktopEngineRef | engine, |
VoidCallback | callback, | ||
void * | user_data | ||
) |
Definition at line 239 of file flutter_windows.cc.
References callback, EngineFromHandle(), flutter::FlutterWindowsEngine::SetNextFrameCallback(), and user_data.
Referenced by flutter::FlutterEngine::SetNextFrameCallback(), and flutter::testing::TEST_F().
UINT FlutterDesktopGetDpiForHWND | ( | HWND | hwnd | ) |
Definition at line 316 of file flutter_windows.cc.
References flutter::GetDpiForHWND().
UINT FlutterDesktopGetDpiForMonitor | ( | HMONITOR | monitor | ) |
Definition at line 320 of file flutter_windows.cc.
References flutter::GetDpiForMonitor().
FlutterDesktopMessengerRef FlutterDesktopMessengerAddRef | ( | FlutterDesktopMessengerRef | messenger | ) |
Definition at line 396 of file flutter_windows.cc.
References flutter::FlutterDesktopMessenger::AddRef(), flutter::FlutterDesktopMessenger::FromRef(), and flutter::FlutterDesktopMessenger::ToRef().
bool FlutterDesktopMessengerIsAvailable | ( | FlutterDesktopMessengerRef | messenger | ) |
Definition at line 407 of file flutter_windows.cc.
References flutter::FlutterDesktopMessenger::FromRef(), and flutter::FlutterDesktopMessenger::GetEngine().
Referenced by FlutterDesktopMessengerSendResponse(), FlutterDesktopMessengerSendWithReply(), and FlutterDesktopMessengerSetCallback().
FlutterDesktopMessengerRef FlutterDesktopMessengerLock | ( | FlutterDesktopMessengerRef | messenger | ) |
Definition at line 412 of file flutter_windows.cc.
References flutter::FlutterDesktopMessenger::FromRef(), and flutter::FlutterDesktopMessenger::GetMutex().
void FlutterDesktopMessengerRelease | ( | FlutterDesktopMessengerRef | messenger | ) |
Definition at line 403 of file flutter_windows.cc.
References flutter::FlutterDesktopMessenger::FromRef(), and flutter::FlutterDesktopMessenger::Release().
bool FlutterDesktopMessengerSend | ( | FlutterDesktopMessengerRef | messenger, |
const char * | channel, | ||
const uint8_t * | message, | ||
const size_t | message_size | ||
) |
Definition at line 362 of file flutter_windows.cc.
References FlutterDesktopMessengerSendWithReply(), and message.
Referenced by flutter::BinaryMessengerImpl::Send().
void FlutterDesktopMessengerSendResponse | ( | FlutterDesktopMessengerRef | messenger, |
const FlutterDesktopMessageResponseHandle * | handle, | ||
const uint8_t * | data, | ||
size_t | data_length | ||
) |
Definition at line 370 of file flutter_windows.cc.
References FlutterDesktopMessengerIsAvailable(), flutter::FlutterDesktopMessenger::FromRef(), flutter::FlutterDesktopMessenger::GetEngine(), and flutter::FlutterWindowsEngine::SendPlatformMessageResponse().
Referenced by flutter::IncomingMessageDispatcher::HandleMessage().
bool FlutterDesktopMessengerSendWithReply | ( | FlutterDesktopMessengerRef | messenger, |
const char * | channel, | ||
const uint8_t * | message, | ||
const size_t | message_size, | ||
const FlutterDesktopBinaryReply | reply, | ||
void * | user_data | ||
) |
Definition at line 348 of file flutter_windows.cc.
References FlutterDesktopMessengerIsAvailable(), flutter::FlutterDesktopMessenger::FromRef(), flutter::FlutterDesktopMessenger::GetEngine(), message, flutter::FlutterWindowsEngine::SendPlatformMessage(), and user_data.
Referenced by FlutterDesktopMessengerSend(), and flutter::BinaryMessengerImpl::Send().
void FlutterDesktopMessengerSetCallback | ( | FlutterDesktopMessengerRef | messenger, |
const char * | channel, | ||
FlutterDesktopMessageCallback | callback, | ||
void * | user_data | ||
) |
Definition at line 383 of file flutter_windows.cc.
References callback, FlutterDesktopMessengerIsAvailable(), flutter::FlutterDesktopMessenger::FromRef(), flutter::FlutterDesktopMessenger::GetEngine(), flutter::FlutterWindowsEngine::message_dispatcher(), flutter::IncomingMessageDispatcher::SetMessageCallback(), and user_data.
Referenced by flutter::BinaryMessengerImpl::SetMessageHandler().
void FlutterDesktopMessengerUnlock | ( | FlutterDesktopMessengerRef | messenger | ) |
Definition at line 418 of file flutter_windows.cc.
References flutter::FlutterDesktopMessenger::FromRef(), and flutter::FlutterDesktopMessenger::GetMutex().
FlutterDesktopMessengerRef FlutterDesktopPluginRegistrarGetMessenger | ( | FlutterDesktopPluginRegistrarRef | registrar | ) |
Definition at line 337 of file flutter_windows.cc.
References FlutterDesktopPluginRegistrar::engine, and flutter::FlutterWindowsEngine::messenger().
FlutterDesktopViewRef FlutterDesktopPluginRegistrarGetView | ( | FlutterDesktopPluginRegistrarRef | registrar | ) |
Definition at line 290 of file flutter_windows.cc.
References FlutterDesktopPluginRegistrar::engine, HandleForView(), flutter::kImplicitViewId, and flutter::FlutterWindowsEngine::view().
Referenced by flutter::PluginRegistrarWindows::PluginRegistrarWindows(), and flutter::testing::TEST_F().
FlutterDesktopViewRef FlutterDesktopPluginRegistrarGetViewById | ( | FlutterDesktopPluginRegistrarRef | registrar, |
FlutterDesktopViewId | view_id | ||
) |
Definition at line 295 of file flutter_windows.cc.
References FlutterDesktopPluginRegistrar::engine, HandleForView(), and flutter::FlutterWindowsEngine::view().
Referenced by flutter::PluginRegistrarWindows::GetViewById(), and flutter::testing::TEST_F().
void FlutterDesktopPluginRegistrarRegisterTopLevelWindowProcDelegate | ( | FlutterDesktopPluginRegistrarRef | registrar, |
FlutterDesktopWindowProcCallback | delegate, | ||
void * | user_data | ||
) |
Definition at line 301 of file flutter_windows.cc.
References FlutterDesktopPluginRegistrar::engine, flutter::WindowProcDelegateManager::RegisterTopLevelWindowProcDelegate(), user_data, and flutter::FlutterWindowsEngine::window_proc_delegate_manager().
Referenced by flutter::PluginRegistrarWindows::RegisterTopLevelWindowProcDelegate().
void FlutterDesktopPluginRegistrarSetDestructionHandler | ( | FlutterDesktopPluginRegistrarRef | registrar, |
FlutterDesktopOnPluginRegistrarDestroyed | callback | ||
) |
Definition at line 342 of file flutter_windows.cc.
References flutter::FlutterWindowsEngine::AddPluginRegistrarDestructionCallback(), callback, and FlutterDesktopPluginRegistrar::engine.
Referenced by flutter::PluginRegistrarManager::GetRegistrar().
void FlutterDesktopPluginRegistrarUnregisterTopLevelWindowProcDelegate | ( | FlutterDesktopPluginRegistrarRef | registrar, |
FlutterDesktopWindowProcCallback | delegate | ||
) |
Definition at line 309 of file flutter_windows.cc.
References FlutterDesktopPluginRegistrar::engine, flutter::WindowProcDelegateManager::UnregisterTopLevelWindowProcDelegate(), and flutter::FlutterWindowsEngine::window_proc_delegate_manager().
Referenced by flutter::PluginRegistrarWindows::UnregisterTopLevelWindowProcDelegate().
FlutterDesktopTextureRegistrarRef FlutterDesktopRegistrarGetTextureRegistrar | ( | FlutterDesktopPluginRegistrarRef | registrar | ) |
Definition at line 422 of file flutter_windows.cc.
References FlutterDesktopPluginRegistrar::engine, HandleForTextureRegistrar(), and flutter::FlutterWindowsEngine::texture_registrar().
void FlutterDesktopResyncOutputStreams | ( | ) |
Definition at line 324 of file flutter_windows.cc.
bool FlutterDesktopTextureRegistrarMarkExternalTextureFrameAvailable | ( | FlutterDesktopTextureRegistrarRef | texture_registrar, |
int64_t | texture_id | ||
) |
Definition at line 448 of file flutter_windows.cc.
References flutter::FlutterWindowsTextureRegistrar::MarkTextureFrameAvailable(), texture_id, and TextureRegistrarFromHandle().
Referenced by flutter::TextureRegistrarImpl::MarkTextureFrameAvailable().
int64_t FlutterDesktopTextureRegistrarRegisterExternalTexture | ( | FlutterDesktopTextureRegistrarRef | texture_registrar, |
const FlutterDesktopTextureInfo * | texture_info | ||
) |
Definition at line 427 of file flutter_windows.cc.
References flutter::FlutterWindowsTextureRegistrar::RegisterTexture(), and TextureRegistrarFromHandle().
Referenced by flutter::TextureRegistrarImpl::RegisterTexture().
void FlutterDesktopTextureRegistrarUnregisterExternalTexture | ( | FlutterDesktopTextureRegistrarRef | texture_registrar, |
int64_t | texture_id, | ||
void(*)(void *user_data) | callback, | ||
void * | user_data | ||
) |
Definition at line 434 of file flutter_windows.cc.
References callback, texture_id, TextureRegistrarFromHandle(), and user_data.
Referenced by flutter::TextureRegistrarImpl::UnregisterTexture().
FlutterDesktopViewControllerRef FlutterDesktopViewControllerCreate | ( | int | width, |
int | height, | ||
FlutterDesktopEngineRef | engine | ||
) |
Definition at line 121 of file flutter_windows.cc.
References CreateViewController().
Referenced by flutter::FlutterViewController::FlutterViewController(), and flutter::testing::TEST_F().
void FlutterDesktopViewControllerDestroy | ( | FlutterDesktopViewControllerRef | ref | ) |
Definition at line 135 of file flutter_windows.cc.
References ViewControllerFromHandle().
Referenced by flutter::FlutterViewController::~FlutterViewController().
void FlutterDesktopViewControllerForceRedraw | ( | FlutterDesktopViewControllerRef | ref | ) |
Definition at line 159 of file flutter_windows.cc.
References ViewControllerFromHandle().
Referenced by flutter::FlutterViewController::ForceRedraw().
FlutterDesktopEngineRef FlutterDesktopViewControllerGetEngine | ( | FlutterDesktopViewControllerRef | ref | ) |
Definition at line 147 of file flutter_windows.cc.
References HandleForEngine(), and ViewControllerFromHandle().
Referenced by flutter::testing::TEST_F().
FlutterDesktopViewRef FlutterDesktopViewControllerGetView | ( | FlutterDesktopViewControllerRef | ref | ) |
Definition at line 153 of file flutter_windows.cc.
References HandleForView(), and ViewControllerFromHandle().
Referenced by flutter::FlutterViewController::FlutterViewController(), and flutter::testing::TEST_F().
FlutterDesktopViewId FlutterDesktopViewControllerGetViewId | ( | FlutterDesktopViewControllerRef | ref | ) |
Definition at line 141 of file flutter_windows.cc.
References ViewControllerFromHandle().
Referenced by flutter::testing::TEST_F(), and flutter::FlutterViewController::view_id().
bool FlutterDesktopViewControllerHandleTopLevelWindowProc | ( | FlutterDesktopViewControllerRef | ref, |
HWND | hwnd, | ||
UINT | message, | ||
WPARAM | wparam, | ||
LPARAM | lparam, | ||
LRESULT * | result | ||
) |
Definition at line 165 of file flutter_windows.cc.
References message, and ViewControllerFromHandle().
Referenced by flutter::FlutterViewController::HandleTopLevelWindowProc().
IDXGIAdapter* FlutterDesktopViewGetGraphicsAdapter | ( | FlutterDesktopViewRef | view | ) |
Definition at line 250 of file flutter_windows.cc.
References flutter::FlutterWindowsEngine::egl_manager(), flutter::FlutterWindowsView::GetEngine(), and ViewFromHandle().
Referenced by flutter::FlutterView::GetGraphicsAdapter(), and flutter::testing::TEST_F().
HWND FlutterDesktopViewGetHWND | ( | FlutterDesktopViewRef | view | ) |
Definition at line 246 of file flutter_windows.cc.
References flutter::FlutterWindowsView::GetWindowHandle(), and ViewFromHandle().
Referenced by flutter::FlutterView::GetNativeWindow(), and flutter::testing::TEST_F().
|
static |
Definition at line 38 of file flutter_windows.cc.
Referenced by FlutterDesktopEngineCreate(), and FlutterDesktopViewControllerGetEngine().
|
static |
Definition at line 70 of file flutter_windows.cc.
Referenced by FlutterDesktopEngineGetTextureRegistrar(), and FlutterDesktopRegistrarGetTextureRegistrar().
|
static |
Definition at line 59 of file flutter_windows.cc.
Referenced by FlutterDesktopPluginRegistrarGetView(), FlutterDesktopPluginRegistrarGetViewById(), and FlutterDesktopViewControllerGetView().
|
static |
Definition at line 48 of file flutter_windows.cc.
Referenced by CreateViewController().
|
static |
Definition at line 64 of file flutter_windows.cc.
Referenced by FlutterDesktopTextureRegistrarMarkExternalTextureFrameAvailable(), FlutterDesktopTextureRegistrarRegisterExternalTexture(), and FlutterDesktopTextureRegistrarUnregisterExternalTexture().
|
static |
Definition at line 43 of file flutter_windows.cc.
Referenced by FlutterDesktopViewControllerDestroy(), FlutterDesktopViewControllerForceRedraw(), FlutterDesktopViewControllerGetEngine(), FlutterDesktopViewControllerGetView(), FlutterDesktopViewControllerGetViewId(), and FlutterDesktopViewControllerHandleTopLevelWindowProc().
|
static |
Definition at line 54 of file flutter_windows.cc.
Referenced by FlutterDesktopViewGetGraphicsAdapter(), and FlutterDesktopViewGetHWND().