Add flutter_services package to uniformly expose services to Flutter library (flutter/engine#3046)
This adds a flutter_services package responsible for exposing the Dart interfaces exported by the engine in a uniform fashion, regardless of how and where the generated code for the interfaces are organized.
This commit is contained in:
21
engine/src/flutter/sky/dist/BUILD.gn
vendored
21
engine/src/flutter/sky/dist/BUILD.gn
vendored
@@ -3,6 +3,26 @@
|
||||
# found in the LICENSE file.
|
||||
|
||||
if (is_android) {
|
||||
action("flutter_services") {
|
||||
script = "//flutter/sky/tools/dist_dart_pkg.py"
|
||||
|
||||
source = "//flutter/sky/packages/flutter_services"
|
||||
dest = "$root_build_dir/dist/packages/flutter_services"
|
||||
|
||||
inputs = [ source ]
|
||||
outputs = [ dest ]
|
||||
|
||||
args = [
|
||||
"--source",
|
||||
rebase_path(source),
|
||||
"--dest",
|
||||
rebase_path(dest),
|
||||
]
|
||||
|
||||
deps = [
|
||||
"//flutter/sky/packages/flutter_services",
|
||||
]
|
||||
}
|
||||
action("sky_engine") {
|
||||
script = "//flutter/sky/tools/dist_dart_pkg.py"
|
||||
|
||||
@@ -49,6 +69,7 @@ if (is_android) {
|
||||
group("dist") {
|
||||
if (is_android) {
|
||||
deps = [
|
||||
":flutter_services",
|
||||
":sky_engine",
|
||||
":sky_services",
|
||||
]
|
||||
|
||||
@@ -8,5 +8,6 @@ group("packages") {
|
||||
deps = [
|
||||
"//flutter/sky/packages/sky_engine",
|
||||
"//flutter/sky/packages/sky_services",
|
||||
"//flutter/sky/packages/flutter_services",
|
||||
]
|
||||
}
|
||||
|
||||
@@ -0,0 +1,7 @@
|
||||
# Copyright 2016 The Chromium Authors. All rights reserved.
|
||||
# Use of this source code is governed by a BSD-style license that can be
|
||||
# found in the LICENSE file.
|
||||
|
||||
group("flutter_services") {
|
||||
deps = [ "//flutter/sky/packages/sky_services" ]
|
||||
}
|
||||
@@ -0,0 +1,6 @@
|
||||
/// Copyright 2014 The Chromium Authors. All rights reserved.
|
||||
/// Use of this source code is governed by a BSD-style license that can be
|
||||
/// found in the LICENSE file.
|
||||
|
||||
import 'package:sky_services/activity/activity.mojom.dart';
|
||||
export 'package:sky_services/activity/activity.mojom.dart';
|
||||
@@ -0,0 +1,6 @@
|
||||
/// Copyright 2014 The Chromium Authors. All rights reserved.
|
||||
/// Use of this source code is governed by a BSD-style license that can be
|
||||
/// found in the LICENSE file.
|
||||
|
||||
import 'package:sky_services/editing/editing.mojom.dart';
|
||||
export 'package:sky_services/editing/editing.mojom.dart';
|
||||
@@ -0,0 +1,6 @@
|
||||
/// Copyright 2014 The Chromium Authors. All rights reserved.
|
||||
/// Use of this source code is governed by a BSD-style license that can be
|
||||
/// found in the LICENSE file.
|
||||
|
||||
import 'package:sky_services/sky/input_event.mojom.dart';
|
||||
export 'package:sky_services/sky/input_event.mojom.dart';
|
||||
@@ -0,0 +1,6 @@
|
||||
/// Copyright 2014 The Chromium Authors. All rights reserved.
|
||||
/// Use of this source code is governed by a BSD-style license that can be
|
||||
/// found in the LICENSE file.
|
||||
|
||||
import 'package:mojo_services/mojo/asset_bundle/asset_bundle.mojom.dart';
|
||||
export 'package:mojo_services/mojo/asset_bundle/asset_bundle.mojom.dart';
|
||||
@@ -0,0 +1,6 @@
|
||||
/// Copyright 2014 The Chromium Authors. All rights reserved.
|
||||
/// Use of this source code is governed by a BSD-style license that can be
|
||||
/// found in the LICENSE file.
|
||||
|
||||
import 'package:mojo_services/mojo/geometry.mojom.dart';
|
||||
export 'package:mojo_services/mojo/geometry.mojom.dart';
|
||||
@@ -0,0 +1,6 @@
|
||||
/// Copyright 2014 The Chromium Authors. All rights reserved.
|
||||
/// Use of this source code is governed by a BSD-style license that can be
|
||||
/// found in the LICENSE file.
|
||||
|
||||
import 'package:mojo_services/mojo/gfx/composition/scene_token.mojom.dart';
|
||||
export 'package:mojo_services/mojo/gfx/composition/scene_token.mojom.dart';
|
||||
@@ -0,0 +1,6 @@
|
||||
/// Copyright 2014 The Chromium Authors. All rights reserved.
|
||||
/// Use of this source code is governed by a BSD-style license that can be
|
||||
/// found in the LICENSE file.
|
||||
|
||||
import 'package:mojo_services/mojo/network_service.mojom.dart';
|
||||
export 'package:mojo_services/mojo/network_service.mojom.dart';
|
||||
@@ -0,0 +1,6 @@
|
||||
/// Copyright 2014 The Chromium Authors. All rights reserved.
|
||||
/// Use of this source code is governed by a BSD-style license that can be
|
||||
/// found in the LICENSE file.
|
||||
|
||||
import 'package:mojo_services/mojo/ui/view_containers.mojom.dart';
|
||||
export 'package:mojo_services/mojo/ui/view_containers.mojom.dart';
|
||||
@@ -0,0 +1,6 @@
|
||||
/// Copyright 2014 The Chromium Authors. All rights reserved.
|
||||
/// Use of this source code is governed by a BSD-style license that can be
|
||||
/// found in the LICENSE file.
|
||||
|
||||
import 'package:mojo_services/mojo/ui/view_properties.mojom.dart';
|
||||
export 'package:mojo_services/mojo/ui/view_properties.mojom.dart';
|
||||
@@ -0,0 +1,6 @@
|
||||
/// Copyright 2014 The Chromium Authors. All rights reserved.
|
||||
/// Use of this source code is governed by a BSD-style license that can be
|
||||
/// found in the LICENSE file.
|
||||
|
||||
import 'package:mojo_services/mojo/ui/view_provider.mojom.dart';
|
||||
export 'package:mojo_services/mojo/ui/view_provider.mojom.dart';
|
||||
@@ -0,0 +1,6 @@
|
||||
/// Copyright 2014 The Chromium Authors. All rights reserved.
|
||||
/// Use of this source code is governed by a BSD-style license that can be
|
||||
/// found in the LICENSE file.
|
||||
|
||||
import 'package:mojo_services/mojo/ui/view_token.mojom.dart';
|
||||
export 'package:mojo_services/mojo/ui/view_token.mojom.dart';
|
||||
@@ -0,0 +1,6 @@
|
||||
/// Copyright 2014 The Chromium Authors. All rights reserved.
|
||||
/// Use of this source code is governed by a BSD-style license that can be
|
||||
/// found in the LICENSE file.
|
||||
|
||||
import 'package:mojo_services/mojo/ui/views.mojom.dart';
|
||||
export 'package:mojo_services/mojo/ui/views.mojom.dart';
|
||||
@@ -0,0 +1,6 @@
|
||||
/// Copyright 2014 The Chromium Authors. All rights reserved.
|
||||
/// Use of this source code is governed by a BSD-style license that can be
|
||||
/// found in the LICENSE file.
|
||||
|
||||
import 'package:mojo_services/mojo/url_loader.mojom.dart';
|
||||
export 'package:mojo_services/mojo/url_loader.mojom.dart';
|
||||
@@ -0,0 +1,6 @@
|
||||
/// Copyright 2014 The Chromium Authors. All rights reserved.
|
||||
/// Use of this source code is governed by a BSD-style license that can be
|
||||
/// found in the LICENSE file.
|
||||
|
||||
import 'package:sky_services/flutter/platform/app_messages.mojom.dart';
|
||||
export 'package:sky_services/flutter/platform/app_messages.mojom.dart';
|
||||
@@ -0,0 +1,6 @@
|
||||
/// Copyright 2014 The Chromium Authors. All rights reserved.
|
||||
/// Use of this source code is governed by a BSD-style license that can be
|
||||
/// found in the LICENSE file.
|
||||
|
||||
import 'package:sky_services/flutter/platform/haptic_feedback.mojom.dart';
|
||||
export 'package:sky_services/flutter/platform/haptic_feedback.mojom.dart';
|
||||
@@ -0,0 +1,6 @@
|
||||
/// Copyright 2014 The Chromium Authors. All rights reserved.
|
||||
/// Use of this source code is governed by a BSD-style license that can be
|
||||
/// found in the LICENSE file.
|
||||
|
||||
import 'package:sky_services/flutter/platform/path_provider.mojom.dart';
|
||||
export 'package:sky_services/flutter/platform/path_provider.mojom.dart';
|
||||
@@ -0,0 +1,6 @@
|
||||
/// Copyright 2014 The Chromium Authors. All rights reserved.
|
||||
/// Use of this source code is governed by a BSD-style license that can be
|
||||
/// found in the LICENSE file.
|
||||
|
||||
import 'package:sky_services/flutter/platform/system_chrome.mojom.dart';
|
||||
export 'package:sky_services/flutter/platform/system_chrome.mojom.dart';
|
||||
@@ -0,0 +1,6 @@
|
||||
/// Copyright 2014 The Chromium Authors. All rights reserved.
|
||||
/// Use of this source code is governed by a BSD-style license that can be
|
||||
/// found in the LICENSE file.
|
||||
|
||||
import 'package:sky_services/flutter/platform/system_sound.mojom.dart';
|
||||
export 'package:sky_services/flutter/platform/system_sound.mojom.dart';
|
||||
@@ -0,0 +1,6 @@
|
||||
/// Copyright 2014 The Chromium Authors. All rights reserved.
|
||||
/// Use of this source code is governed by a BSD-style license that can be
|
||||
/// found in the LICENSE file.
|
||||
|
||||
import 'package:sky_services/flutter/platform/url_launcher.mojom.dart';
|
||||
export 'package:sky_services/flutter/platform/url_launcher.mojom.dart';
|
||||
@@ -0,0 +1,6 @@
|
||||
/// Copyright 2014 The Chromium Authors. All rights reserved.
|
||||
/// Use of this source code is governed by a BSD-style license that can be
|
||||
/// found in the LICENSE file.
|
||||
|
||||
import 'package:sky_services/pointer/pointer.mojom.dart';
|
||||
export 'package:sky_services/pointer/pointer.mojom.dart';
|
||||
@@ -0,0 +1,6 @@
|
||||
/// Copyright 2014 The Chromium Authors. All rights reserved.
|
||||
/// Use of this source code is governed by a BSD-style license that can be
|
||||
/// found in the LICENSE file.
|
||||
|
||||
import 'package:sky_services/raw_keyboard/raw_keyboard.mojom.dart';
|
||||
export 'package:sky_services/raw_keyboard/raw_keyboard.mojom.dart';
|
||||
@@ -0,0 +1,6 @@
|
||||
/// Copyright 2014 The Chromium Authors. All rights reserved.
|
||||
/// Use of this source code is governed by a BSD-style license that can be
|
||||
/// found in the LICENSE file.
|
||||
|
||||
import 'package:sky_services/semantics/semantics.mojom.dart';
|
||||
export 'package:sky_services/semantics/semantics.mojom.dart';
|
||||
@@ -0,0 +1,11 @@
|
||||
name: flutter_services
|
||||
version: 0.0.1
|
||||
author: Flutter Authors <flutter-dev@googlegroups.com>
|
||||
description: Services exported from the Flutter engine
|
||||
homepage: http://flutter.io
|
||||
dependencies:
|
||||
sky_services:
|
||||
path:
|
||||
../sky_services
|
||||
environment:
|
||||
sdk: '>=1.8.0 <2.0.0'
|
||||
Reference in New Issue
Block a user