// Copyright 2018 The Fuchsia Authors. All rights reserved.
|
// Use of this source code is governed by a BSD-style license that can be
|
// found in the LICENSE file.
|
|
library fuchsia.ui.views;
|
|
using fuchsia.ui.gfx;
|
|
union Event {
|
ChildViewAttachedEvent child_view_attached;
|
ChildViewUnavailableEvent child_view_unavailable;
|
};
|
|
// Called when a child view is attached.
|
struct ChildViewAttachedEvent {
|
uint32 view_holder_id;
|
};
|
|
// Called when a child view has become unavailable.
|
//
|
// A child may become unavailable for many reasons such being unregistered
|
// by its application, abnormal termination of its application, or
|
// cycles being introduced in the view tree.
|
//
|
// To complete removal of an unavailable child, this view component must
|
// call RemoveChild() on its view with |child_key|.
|
//
|
// The implementation should invoke the callback once the event has
|
// been handled.
|
struct ChildViewUnavailableEvent {
|
uint32 view_holder_id;
|
};
|