Flutter Engine
The Flutter Engine
embedder_layers.h
Go to the documentation of this file.
1// Copyright 2013 The Flutter Authors. All rights reserved.
2// Use of this source code is governed by a BSD-style license that can be
3// found in the LICENSE file.
4
5#ifndef FLUTTER_SHELL_PLATFORM_EMBEDDER_EMBEDDER_LAYERS_H_
6#define FLUTTER_SHELL_PLATFORM_EMBEDDER_EMBEDDER_LAYERS_H_
7
8#include <memory>
9#include <vector>
10
11#include "flutter/flow/embedded_views.h"
12#include "flutter/fml/macros.h"
13#include "flutter/shell/platform/embedder/embedder.h"
16
17namespace flutter {
18
20 public:
21 EmbedderLayers(SkISize frame_size,
22 double device_pixel_ratio,
23 SkMatrix root_surface_transformation,
24 uint64_t presentation_time);
25
27
29 const std::vector<SkIRect>& drawn_region);
30
33
35 std::function<bool(FlutterViewId view_id,
36 const std::vector<const FlutterLayer*>& layers)>;
38 const PresentCallback& callback) const;
39
40 private:
41 const SkISize frame_size_;
42 const double device_pixel_ratio_;
43 const SkMatrix root_surface_transformation_;
44 std::vector<std::unique_ptr<FlutterPlatformView>> platform_views_referenced_;
45 std::vector<std::unique_ptr<FlutterPlatformViewMutation>>
46 mutations_referenced_;
47 std::vector<std::unique_ptr<std::vector<const FlutterPlatformViewMutation*>>>
48 mutations_arrays_referenced_;
49 std::vector<std::unique_ptr<FlutterBackingStorePresentInfo>>
50 present_info_referenced_;
51 std::vector<std::unique_ptr<FlutterRegion>> regions_referenced_;
52 std::vector<std::unique_ptr<std::vector<FlutterRect>>> rects_referenced_;
53 std::vector<FlutterLayer> presented_layers_;
54 uint64_t presentation_time_;
55
56 FML_DISALLOW_COPY_AND_ASSIGN(EmbedderLayers);
57};
58
59} // namespace flutter
60
61#endif // FLUTTER_SHELL_PLATFORM_EMBEDDER_EMBEDDER_LAYERS_H_
SI void store(P *ptr, const T &val)
void PushPlatformViewLayer(FlutterPlatformViewIdentifier identifier, const EmbeddedViewParams &params)
void PushBackingStoreLayer(const FlutterBackingStore *store, const std::vector< SkIRect > &drawn_region)
EmbedderLayers(SkISize frame_size, double device_pixel_ratio, SkMatrix root_surface_transformation, uint64_t presentation_time)
void InvokePresentCallback(FlutterViewId view_id, const PresentCallback &callback) const
std::function< bool(FlutterViewId view_id, const std::vector< const FlutterLayer * > &layers)> PresentCallback
static SkString identifier(const FontFamilyDesc &family, const FontDesc &font)
int64_t FlutterPlatformViewIdentifier
Definition: embedder.h:1188
const EmbeddedViewParams * params
FlKeyEvent uint64_t FlKeyResponderAsyncCallback callback
Dart_NativeFunction function
Definition: fuchsia.cc:51
int64_t FlutterViewId
Definition: flutter_view.h:13
Definition: SkSize.h:16