Skip to content

Commit

Permalink
Remove //flutter/glue and use FML directly. (flutter#5862)
Browse files Browse the repository at this point in the history
  • Loading branch information
chinmaygarde authored Jul 25, 2018
1 parent 7d17da7 commit 336c23f
Show file tree
Hide file tree
Showing 32 changed files with 42 additions and 131 deletions.
1 change: 0 additions & 1 deletion assets/BUILD.gn
Original file line number Diff line number Diff line change
Expand Up @@ -16,7 +16,6 @@ source_set("assets") {
deps = [
"$flutter_root/common",
"$flutter_root/fml",
"$flutter_root/glue",
"//garnet/public/lib/fxl",
]

Expand Down
2 changes: 1 addition & 1 deletion assets/asset_manager.cc
Original file line number Diff line number Diff line change
Expand Up @@ -5,7 +5,7 @@
#include "flutter/assets/asset_manager.h"

#include "flutter/assets/directory_asset_bundle.h"
#include "flutter/glue/trace_event.h"
#include "flutter/fml/trace_event.h"

#ifdef ERROR
#undef ERROR
Expand Down
2 changes: 1 addition & 1 deletion assets/zip_asset_store.cc
Original file line number Diff line number Diff line change
Expand Up @@ -14,7 +14,7 @@
#include <string>
#include <utility>

#include "flutter/glue/trace_event.h"
#include "flutter/fml/trace_event.h"

namespace blink {

Expand Down
1 change: 0 additions & 1 deletion flow/BUILD.gn
Original file line number Diff line number Diff line change
Expand Up @@ -67,7 +67,6 @@ source_set("flow") {
deps = [
"$flutter_root/common",
"$flutter_root/fml",
"$flutter_root/glue",
"$flutter_root/synchronization",
"//third_party/skia",
"//third_party/skia:gpu",
Expand Down
2 changes: 1 addition & 1 deletion flow/layers/layer.h
Original file line number Diff line number Diff line change
Expand Up @@ -11,7 +11,7 @@
#include "flutter/flow/instrumentation.h"
#include "flutter/flow/raster_cache.h"
#include "flutter/flow/texture.h"
#include "flutter/glue/trace_event.h"
#include "flutter/fml/trace_event.h"
#include "lib/fxl/build_config.h"
#include "lib/fxl/logging.h"
#include "lib/fxl/macros.h"
Expand Down
2 changes: 1 addition & 1 deletion flow/layers/layer_tree.cc
Original file line number Diff line number Diff line change
Expand Up @@ -5,7 +5,7 @@
#include "flutter/flow/layers/layer_tree.h"

#include "flutter/flow/layers/layer.h"
#include "flutter/glue/trace_event.h"
#include "flutter/fml/trace_event.h"
#include "third_party/skia/include/core/SkPictureRecorder.h"

namespace flow {
Expand Down
2 changes: 1 addition & 1 deletion flow/raster_cache.cc
Original file line number Diff line number Diff line change
Expand Up @@ -7,7 +7,7 @@
#include <vector>

#include "flutter/flow/paint_utils.h"
#include "flutter/glue/trace_event.h"
#include "flutter/fml/trace_event.h"
#include "lib/fxl/logging.h"
#include "third_party/skia/include/core/SkCanvas.h"
#include "third_party/skia/include/core/SkColorSpaceXformCanvas.h"
Expand Down
4 changes: 2 additions & 2 deletions flow/scene_update_context.cc
Original file line number Diff line number Diff line change
Expand Up @@ -7,7 +7,7 @@
#include "flutter/flow/export_node.h"
#include "flutter/flow/layers/layer.h"
#include "flutter/flow/matrix_decomposition.h"
#include "flutter/glue/trace_event.h"
#include "flutter/fml/trace_event.h"

namespace flow {

Expand Down Expand Up @@ -94,7 +94,7 @@ void SceneUpdateContext::CreateFrame(scenic::EntityNode& entity_node,
SetShapeColor(shape_node, color);

scenic::Rectangle inner_shape(session_, inner_bounds.width(),
inner_bounds.height());
inner_bounds.height());
scenic::ShapeNode inner_node(session_);
inner_node.SetShape(inner_shape);
inner_node.SetTranslation(inner_bounds.width() * 0.5f + inner_bounds.left(),
Expand Down
18 changes: 18 additions & 0 deletions fml/trace_event.h
Original file line number Diff line number Diff line change
Expand Up @@ -5,6 +5,22 @@
#ifndef FLUTTER_FML_TRACE_EVENT_H_
#define FLUTTER_FML_TRACE_EVENT_H_

#if defined(__Fuchsia__)

// Forward to the system tracing mechanism on Fuchsia.

#include <trace/event.h>

#define TRACE_EVENT0(a, b) TRACE_DURATION(a, b)
#define TRACE_EVENT1(a, b, c, d) TRACE_DURATION(a, b, c, d)
#define TRACE_EVENT2(a, b, c, d, e, f) TRACE_DURATION(a, b, c, d, e, f)
#define TRACE_EVENT_ASYNC_BEGIN0(a, b, c) TRACE_ASYNC_BEGIN(a, b, c)
#define TRACE_EVENT_ASYNC_END0(a, b, c) TRACE_ASYNC_END(a, b, c)
#define TRACE_EVENT_ASYNC_BEGIN1(a, b, c, d, e) TRACE_ASYNC_BEGIN(a, b, c, d, e)
#define TRACE_EVENT_ASYNC_END1(a, b, c, d, e) TRACE_ASYNC_END(a, b, c, d, e)

#else // defined(__Fuchsia__)

#include <cstddef>
#include <cstdint>
#include <string>
Expand Down Expand Up @@ -121,4 +137,6 @@ class ScopedInstantEnd {
} // namespace tracing
} // namespace fml

#endif // defined(__Fuchsia__)

#endif // FLUTTER_FML_TRACE_EVENT_H_
30 changes: 0 additions & 30 deletions glue/BUILD.gn

This file was deleted.

5 changes: 0 additions & 5 deletions glue/README.md

This file was deleted.

14 changes: 0 additions & 14 deletions glue/stack_trace.h

This file was deleted.

11 changes: 0 additions & 11 deletions glue/stack_trace_base.cc

This file was deleted.

11 changes: 0 additions & 11 deletions glue/stack_trace_fuchsia.cc

This file was deleted.

26 changes: 0 additions & 26 deletions glue/trace_event.h

This file was deleted.

9 changes: 5 additions & 4 deletions lib/ui/BUILD.gn
Original file line number Diff line number Diff line change
Expand Up @@ -55,14 +55,14 @@ source_set("ui") {
"painting/vertices.h",
"plugins/callback_cache.cc",
"plugins/callback_cache.h",
"semantics/custom_accessibility_action.cc",
"semantics/custom_accessibility_action.h",
"semantics/semantics_node.cc",
"semantics/semantics_node.h",
"semantics/semantics_update.cc",
"semantics/semantics_update.h",
"semantics/semantics_update_builder.cc",
"semantics/semantics_update_builder.h",
"semantics/custom_accessibility_action.cc",
"semantics/custom_accessibility_action.h",
"text/asset_manager_font_provider.cc",
"text/asset_manager_font_provider.h",
"text/font_collection.cc",
Expand Down Expand Up @@ -101,7 +101,6 @@ source_set("ui") {
"$flutter_root/common",
"$flutter_root/flow",
"$flutter_root/fml",
"$flutter_root/glue",
"$flutter_root/runtime:test_font",
"//garnet/public/lib/fxl",
"//third_party/dart/runtime/bin:embedded_dart_io",
Expand All @@ -115,5 +114,7 @@ source_set("ui") {
deps += [ "//topaz/public/dart-pkg/zircon" ]
}

public_deps = ["$flutter_root/third_party/txt"]
public_deps = [
"$flutter_root/third_party/txt",
]
}
2 changes: 1 addition & 1 deletion lib/ui/compositing/scene.cc
Original file line number Diff line number Diff line change
Expand Up @@ -4,7 +4,7 @@

#include "flutter/lib/ui/compositing/scene.h"

#include "flutter/glue/trace_event.h"
#include "flutter/fml/trace_event.h"
#include "flutter/lib/ui/painting/image.h"
#include "lib/fxl/functional/make_copyable.h"
#include "third_party/skia/include/core/SkImageInfo.h"
Expand Down
2 changes: 1 addition & 1 deletion lib/ui/painting/codec.cc
Original file line number Diff line number Diff line change
Expand Up @@ -5,7 +5,7 @@
#include "flutter/lib/ui/painting/codec.h"

#include "flutter/common/task_runners.h"
#include "flutter/glue/trace_event.h"
#include "flutter/fml/trace_event.h"
#include "flutter/lib/ui/painting/frame_info.h"
#include "lib/fxl/functional/make_copyable.h"
#include "lib/fxl/logging.h"
Expand Down
2 changes: 1 addition & 1 deletion lib/ui/painting/image_encoding.cc
Original file line number Diff line number Diff line change
Expand Up @@ -8,7 +8,7 @@
#include <utility>

#include "flutter/common/task_runners.h"
#include "flutter/glue/trace_event.h"
#include "flutter/fml/trace_event.h"
#include "flutter/lib/ui/painting/image.h"
#include "flutter/lib/ui/ui_dart_state.h"
#include "lib/fxl/build_config.h"
Expand Down
4 changes: 1 addition & 3 deletions runtime/BUILD.gn
Original file line number Diff line number Diff line change
Expand Up @@ -90,7 +90,6 @@ source_set("runtime") {
"$flutter_root/common",
"$flutter_root/flow",
"$flutter_root/fml",
"$flutter_root/glue",
"$flutter_root/lib/io",
"$flutter_root/lib/ui",
"$flutter_root/third_party/txt",
Expand All @@ -105,8 +104,7 @@ source_set("runtime") {
public_configs = [ "$flutter_root:config" ]

if (flutter_runtime_mode != "release" &&
flutter_runtime_mode != "dynamic_release" &&
!is_fuchsia) {
flutter_runtime_mode != "dynamic_release" && !is_fuchsia) {
# Only link in Observatory in non-release modes on non-Fuchsia. Fuchsia
# instead puts Observatory into the runner's package.
deps += [ "//third_party/dart/runtime/observatory:embedded_observatory_archive" ]
Expand Down
2 changes: 1 addition & 1 deletion runtime/runtime_controller.cc
Original file line number Diff line number Diff line change
Expand Up @@ -5,7 +5,7 @@
#include "flutter/runtime/runtime_controller.h"

#include "flutter/fml/message_loop.h"
#include "flutter/glue/trace_event.h"
#include "flutter/fml/trace_event.h"
#include "flutter/lib/ui/compositing/scene.h"
#include "flutter/lib/ui/ui_dart_state.h"
#include "flutter/lib/ui/window/window.h"
Expand Down
1 change: 0 additions & 1 deletion shell/common/BUILD.gn
Original file line number Diff line number Diff line change
Expand Up @@ -96,7 +96,6 @@ source_set("common") {
"$flutter_root/common",
"$flutter_root/flow",
"$flutter_root/fml",
"$flutter_root/glue",
"$flutter_root/lib/ui",
"$flutter_root/runtime",
"$flutter_root/synchronization",
Expand Down
2 changes: 1 addition & 1 deletion shell/common/animator.cc
Original file line number Diff line number Diff line change
Expand Up @@ -4,7 +4,7 @@

#include "flutter/shell/common/animator.h"

#include "flutter/glue/trace_event.h"
#include "flutter/fml/trace_event.h"
#include "lib/fxl/time/stopwatch.h"
#include "third_party/dart/runtime/include/dart_tools_api.h"

Expand Down
2 changes: 1 addition & 1 deletion shell/common/engine.cc
Original file line number Diff line number Diff line change
Expand Up @@ -8,7 +8,7 @@
#include <utility>

#include "flutter/common/settings.h"
#include "flutter/glue/trace_event.h"
#include "flutter/fml/trace_event.h"
#include "flutter/lib/snapshot/snapshot.h"
#include "flutter/lib/ui/text/font_collection.h"
#include "flutter/shell/common/animator.h"
Expand Down
2 changes: 1 addition & 1 deletion shell/common/shell.cc
Original file line number Diff line number Diff line change
Expand Up @@ -16,7 +16,7 @@
#include "flutter/fml/log_settings.h"
#include "flutter/fml/logging.h"
#include "flutter/fml/message_loop.h"
#include "flutter/glue/trace_event.h"
#include "flutter/fml/trace_event.h"
#include "flutter/runtime/dart_vm.h"
#include "flutter/runtime/start_up.h"
#include "flutter/shell/common/engine.h"
Expand Down
1 change: 0 additions & 1 deletion shell/gpu/gpu.gni
Original file line number Diff line number Diff line change
Expand Up @@ -46,7 +46,6 @@ template("shell_gpu_configuration") {
"$flutter_root/common",
"$flutter_root/flow",
"$flutter_root/fml",
"$flutter_root/glue",
"$flutter_root/shell/common",
"$flutter_root/synchronization",
"//garnet/public/lib/fxl",
Expand Down
2 changes: 1 addition & 1 deletion shell/gpu/gpu_surface_gl.cc
Original file line number Diff line number Diff line change
Expand Up @@ -4,7 +4,7 @@

#include "gpu_surface_gl.h"

#include "flutter/glue/trace_event.h"
#include "flutter/fml/trace_event.h"
#include "lib/fxl/arraysize.h"
#include "lib/fxl/logging.h"
#include "third_party/skia/include/core/SkColorFilter.h"
Expand Down
1 change: 0 additions & 1 deletion shell/platform/darwin/ios/BUILD.gn
Original file line number Diff line number Diff line change
Expand Up @@ -99,7 +99,6 @@ shared_library("create_flutter_framework_dylib") {
"$flutter_root/common",
"$flutter_root/flow",
"$flutter_root/fml",
"$flutter_root/glue",
"$flutter_root/lib/ui",
"$flutter_root/runtime",
"$flutter_root/shell/common",
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -11,7 +11,7 @@
#include <mach/mach_time.h>

#include "flutter/common/task_runners.h"
#include "flutter/glue/trace_event.h"
#include "flutter/fml/trace_event.h"
#include "lib/fxl/logging.h"

@interface VSyncClient : NSObject
Expand Down
2 changes: 1 addition & 1 deletion synchronization/BUILD.gn
Original file line number Diff line number Diff line change
Expand Up @@ -13,7 +13,7 @@ source_set("synchronization") {
public_configs = [ "$flutter_root:config" ]

public_deps = [
"$flutter_root/glue",
"$flutter_root/fml",
"//garnet/public/lib/fxl",
]
}
Expand Down
2 changes: 1 addition & 1 deletion synchronization/pipeline.h
Original file line number Diff line number Diff line change
Expand Up @@ -5,7 +5,7 @@
#ifndef SYNCHRONIZATION_PIPELINE_H_
#define SYNCHRONIZATION_PIPELINE_H_

#include "flutter/glue/trace_event.h"
#include "flutter/fml/trace_event.h"
#include "flutter/synchronization/pipeline.h"
#include "flutter/synchronization/semaphore.h"
#include "lib/fxl/functional/closure.h"
Expand Down
4 changes: 0 additions & 4 deletions travis/licenses_golden/licenses_flutter
Original file line number Diff line number Diff line change
Expand Up @@ -332,10 +332,6 @@ FILE: ../../../flutter/flow/raster_cache.cc
FILE: ../../../flutter/flow/raster_cache.h
FILE: ../../../flutter/flow/scene_update_context.cc
FILE: ../../../flutter/flow/scene_update_context.h
FILE: ../../../flutter/glue/stack_trace.h
FILE: ../../../flutter/glue/stack_trace_base.cc
FILE: ../../../flutter/glue/stack_trace_fuchsia.cc
FILE: ../../../flutter/glue/trace_event.h
FILE: ../../../flutter/lib/ui/painting/image_filter.cc
FILE: ../../../flutter/lib/ui/painting/image_filter.h
FILE: ../../../flutter/lib/ui/semantics.dart
Expand Down

0 comments on commit 336c23f

Please sign in to comment.