12#include "third_party/skia/include/gpu/ganesh/gl/GrGLInterface.h"
23 <<
"This platform does not provide a Vsync waiter implementation. A "
24 "simple timer based fallback is being used.";
29 std::unique_ptr<PlatformMessage>
message) {
34 std::unique_ptr<PointerDataPacket> packet) {
65 std::unique_ptr<Surface>
surface;
73 surface = platform_view->CreateRenderingSurface();
74 if (surface && !surface->IsValid()) {
81 FML_LOG(ERROR) <<
"Failed to create platform view rendering surface";
84 delegate_.OnPlatformViewCreated(std::move(surface));
87void PlatformView::NotifyDestroyed() {
91void PlatformView::ScheduleFrame() {
95void PlatformView::AddView(int64_t
view_id,
107 delegate_.OnPlatformViewSendViewFocusEvent(event);
110sk_sp<GrDirectContext> PlatformView::CreateResourceContext()
const {
111 FML_DLOG(WARNING) <<
"This platform does not set up the resource "
112 "context on the IO thread for async texture uploads.";
116std::shared_ptr<impeller::Context> PlatformView::GetImpellerContext()
const {
120void PlatformView::ReleaseResourceContext()
const {}
124 return std::make_unique<DefaultPointerDataDispatcher>(delegate);
129 return weak_factory_.GetWeakPtr();
132void PlatformView::UpdateSemantics(
138void PlatformView::SetApplicationLocale(
142void PlatformView::SetSemanticsTreeEnabled(
146void PlatformView::SendChannelUpdate(
const std::string&
name,
bool listening) {}
148void PlatformView::HandlePlatformMessage(
149 std::unique_ptr<PlatformMessage>
message) {
150 if (
auto response =
message->response()) {
151 response->CompleteEmpty();
155void PlatformView::OnPreEngineRestart()
const {}
157void PlatformView::RegisterTexture(std::shared_ptr<flutter::Texture>
texture) {
165void PlatformView::MarkTextureFrameAvailable(int64_t
texture_id) {
169std::unique_ptr<Surface> PlatformView::CreateRenderingSurface() {
172 FML_DCHECK(
false) <<
"This platform does not provide a rendering surface but "
173 "it was notified of surface rendering surface creation.";
177std::shared_ptr<ExternalViewEmbedder>
178PlatformView::CreateExternalViewEmbedder() {
180 <<
"This platform doesn't support embedding external views.";
189 delegate_.OnPlatformViewSetNextFrameCallback(closure);
192std::unique_ptr<std::vector<std::string>>
193PlatformView::ComputePlatformResolvedLocales(
194 const std::vector<std::string>& supported_locale_data) {
195 std::unique_ptr<std::vector<std::string>> out =
196 std::make_unique<std::vector<std::string>>();
200void PlatformView::RequestDartDeferredLibrary(intptr_t loading_unit_id) {}
202void PlatformView::LoadDartDeferredLibrary(
203 intptr_t loading_unit_id,
204 std::unique_ptr<const fml::Mapping> snapshot_data,
205 std::unique_ptr<const fml::Mapping> snapshot_instructions) {}
207void PlatformView::LoadDartDeferredLibraryError(
208 intptr_t loading_unit_id,
213void PlatformView::UpdateAssetResolverByType(
214 std::unique_ptr<AssetResolver> updated_asset_resolver,
216 delegate_.UpdateAssetResolverByType(std::move(updated_asset_resolver),
type);
219std::unique_ptr<SnapshotSurfaceProducer>
220PlatformView::CreateSnapshotSurfaceProducer() {
224std::shared_ptr<PlatformMessageHandler>
225PlatformView::GetPlatformMessageHandler()
const {
230 return delegate_.OnPlatformViewGetSettings();
233double PlatformView::GetScaledFontSize(
double unscaled_font_size,
234 int configuration_id)
const {
241void PlatformView::RequestViewFocusChange(
AssetResolverType
Identifies the type of AssetResolver an instance is.
The interface for Engine to implement.
fml::RefPtr< fml::TaskRunner > GetRasterTaskRunner() const
A Mapping like NonOwnedMapping, but uses Free as its release proc.
static void RunNowOrPostTask(const fml::RefPtr< fml::TaskRunner > &runner, const fml::closure &task)
TaskRunners task_runners_
G_BEGIN_DECLS G_MODULE_EXPORT FlValue * args
G_BEGIN_DECLS FlutterViewId view_id
FlutterDesktopBinaryReply callback
#define FML_DLOG(severity)
#define FML_LOG(severity)
#define FML_UNREACHABLE()
#define FML_DCHECK(condition)
std::unordered_map< int32_t, SemanticsNode > SemanticsNodeUpdates
std::unordered_map< int32_t, CustomAccessibilityAction > CustomAccessibilityActionUpdates
std::function< std::unique_ptr< PointerDataDispatcher >(PointerDataDispatcher::Delegate &)> PointerDataDispatcherMaker
Signature for constructing PointerDataDispatcher.
std::function< void()> closure
impeller::ShaderType type