Initializes Dart bindings for the Fuchsia application model.
104 {
106
112
114 std::unique_ptr<tonic::DartClassProvider> fuchsia_class_provider(
116 dart_state->class_library().add_provider("fuchsia",
117 std::move(fuchsia_class_provider));
118
119 if (directory_request) {
121 library,
ToDart(
"_outgoingServices"),
124 }
125
126 if (view_ref) {
128 library,
ToDart(
"_viewRef"),
131 }
132}
static DartState * Current()
static fml::RefPtr< Handle > Create(zx_handle_t handle)
DART_EXPORT Dart_Handle Dart_SetNativeResolver(Dart_Handle library, Dart_NativeEntryResolver resolver, Dart_NativeEntrySymbol symbol)
struct _Dart_Handle * Dart_Handle
DART_EXPORT Dart_Handle Dart_LookupLibrary(Dart_Handle url)
DART_EXPORT DART_WARN_UNUSED_RESULT Dart_Handle Dart_SetField(Dart_Handle container, Dart_Handle name, Dart_Handle value)
#define FML_CHECK(condition)
static Dart_NativeFunction NativeLookup(Dart_Handle name, int argc, bool *auto_setup_scope)
Dart_Handle ToDart(const T &object)
bool CheckAndHandleError(Dart_Handle handle)