 |
Flutter Impeller
|
|
Go to the documentation of this file.
13 if (window ==
nullptr) {
17 if (debug_name ==
nullptr) {
18 debug_name =
"Impeller Layer";
21 GetProcTable().ASurfaceControl_createFromWindow(window, debug_name));
26 VALIDATION_LOG <<
"Surface control could not be removed from its parent. "
32 return control_.is_valid();
36 return control_.get();
44 if (!transaction.
SetParent(*
this,
nullptr)) {
47 return transaction.
Apply();
52 GetProcTable().ASurfaceControl_createFromWindow.IsAvailable();
bool SetParent(const SurfaceControl &control, const SurfaceControl *new_parent=nullptr)
Set the new parent control of the given control. If the new parent is null, it is removed from the co...
A wrapper for ASurfaceTransaction. https://developer.android.com/ndk/reference/group/native-activity#...
~SurfaceControl()
Removes the surface control from the presentation hierarchy managed by the system compositor and rele...
static bool IsAvailableOnPlatform()
bool RemoveFromParent() const
Remove the surface control from the hierarchy of nodes presented by the system compositor.
bool Apply(OnCompleteCallback callback=nullptr)
Applies the updated encoded in the transaction and invokes the callback when the updated are complete...
bool IsValid() const
If a valid proc table could be setup. This may fail in case of setup on non-Android platforms.
ASurfaceControl * GetHandle() const
const ProcTable & GetProcTable()
SurfaceControl(ANativeWindow *window, const char *debug_name=nullptr)
Creates a new surface control and adds it as a child of the given window.