diff --git a/engine/src/flutter/build/sky_app.gni b/engine/src/flutter/build/sky_app.gni deleted file mode 100644 index 950bf82c78..0000000000 --- a/engine/src/flutter/build/sky_app.gni +++ /dev/null @@ -1,87 +0,0 @@ -# Copyright 2015 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("//sky/build/skyx.gni") - -template("sky_app") { - skyx_target_name = target_name - - if (is_android) { - skyx_target_name = "app" - } - - skyx(skyx_target_name) { - main_dart = invoker.main_dart - - if (defined(invoker.manifest)) { - manifest = invoker.manifest - } - - if (defined(invoker.sources)) { - sources = invoker.sources - } - } - - if (is_android) { - import("//build/config/android/rules.gni") - - bundle_prefix = target_name - - copy("copy_${bundle_prefix}_bundle") { - sources = [ - "$target_gen_dir/app.skyx", - ] - outputs = [ - "$target_gen_dir/${bundle_prefix}.skyx", - ] - - deps = [ - ":app", - ] - } - - copy_ex("assets") { - clear_dir = true - dest = "$target_gen_dir/assets" - - sources = [ - "$root_build_dir/icudtl.dat", - "$target_gen_dir/app.skyx", - ] - deps = [ - "//third_party/icu", - ":copy_${bundle_prefix}_bundle", - ] - - if (defined(invoker.bundles)) { - foreach(bundle, invoker.bundles) { - bundle_gen_dir = get_label_info(bundle, "target_gen_dir") - bundle_name = get_label_info(bundle, "name") - sources += [ "$bundle_gen_dir/${bundle_name}.skyx" ] - deps += [ bundle ] - } - } - } - - android_apk(target_name) { - apk_name = invoker.apk_name - android_manifest = "apk/AndroidManifest.xml" - - native_libs = [ "libsky_shell.so" ] - asset_location = "$target_gen_dir/assets" - - deps = [ - "//base:base_java", - "//sky/shell:assets", - "//sky/shell:java", - "//sky/shell:sky_shell", - ":assets", - ] - - if (defined(invoker.deps)) { - deps += invoker.deps - } - } - } -} diff --git a/engine/src/flutter/build/skyx.gni b/engine/src/flutter/build/skyx.gni deleted file mode 100644 index f0d9c235fb..0000000000 --- a/engine/src/flutter/build/skyx.gni +++ /dev/null @@ -1,98 +0,0 @@ -# Copyright 2015 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. - -package_root = "$root_gen_dir/dart-pkg/packages" - -template("skyx") { - bundle_prefix = target_name - bundle = "$target_gen_dir/${bundle_prefix}.skyx" - snapshot = "$target_gen_dir/${bundle_prefix}_snapshot.bin" - - action("gen_${bundle_prefix}_snapshot") { - main_dart = invoker.main_dart - - inputs = [ - main_dart, - ] - outputs = [ - snapshot, - ] - - if (defined(invoker.sources)) { - inputs += sources - } - - sky_packager_dir = - get_label_info("//sky/tools/packager($host_toolchain)", "root_out_dir") - - script = "//sky/tools/sky_packager.py" - - src_dir = "//" - cwd = rebase_path(src_dir, root_build_dir) - - args = [ - rebase_path("$sky_packager_dir/sky_packager", src_dir), - rebase_path(main_dart, src_dir), - "--package-root", - rebase_path(package_root, src_dir), - "--snapshot", - rebase_path(snapshot, src_dir), - "-C", - cwd, - ] - - deps = [ - "//sky/tools/packager($host_toolchain)", - "//sky/sdk", - ] - - if (defined(invoker.deps)) { - deps += invoker.deps - } - } - - action("gen_${bundle_prefix}_bundle") { - asset_base = "$package_root/sky/assets/material-design-icons" - - sources = [ - "//sky/tools/skyx/bin/skyx.dart", - snapshot, - ] - - outputs = [ - bundle, - ] - - script = "//sky/tools/skyx.py" - args = [ - "--package-root", - rebase_path(package_root, root_build_dir), - "--asset-base", - rebase_path(asset_base, root_build_dir), - "--snapshot", - rebase_path(snapshot, root_build_dir), - "-o", - rebase_path(bundle, root_build_dir), - ] - - if (defined(invoker.manifest)) { - sources += [ invoker.manifest ] - args += [ - "--manifest", - rebase_path(invoker.manifest, root_build_dir), - ] - } - - deps = [ - ":gen_${bundle_prefix}_snapshot", - "//third_party/dart-pkg", - ] - } - - group(target_name) { - deps = [ - ":gen_${bundle_prefix}_bundle", - ] - } -} diff --git a/engine/src/flutter/shell/BUILD.gn b/engine/src/flutter/shell/BUILD.gn deleted file mode 100644 index 88c9d68236..0000000000 --- a/engine/src/flutter/shell/BUILD.gn +++ /dev/null @@ -1,202 +0,0 @@ -# Copyright 2015 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. - -common_deps = [ - "//base", - "//base:i18n", - "//build/config/sanitizers:deps", - "//dart/runtime:libdart", - "//mojo/common", - "//mojo/edk/system", - "//mojo/public/cpp/application", - "//mojo/public/interfaces/application", - "//mojo/services/asset_bundle/public/interfaces", - "//mojo/services/navigation/public/interfaces", - "//mojo/services/network/public/interfaces", - "//services/asset_bundle:lib", - "//skia", - "//sky/engine", - "//sky/engine/tonic", - "//sky/engine/wtf", - "//sky/services/engine:interfaces", - "//sky/shell/dart", - "//ui/gfx/geometry", - "//ui/gl", -] - -source_set("common") { - sources = [ - "gpu/ganesh_context.cc", - "gpu/ganesh_context.h", - "gpu/ganesh_surface.cc", - "gpu/ganesh_surface.h", - "gpu/picture_serializer.cc", - "gpu/picture_serializer.h", - "gpu/rasterizer.cc", - "gpu/rasterizer.h", - "gpu_delegate.cc", - "gpu_delegate.h", - "platform_view.cc", - "platform_view.h", - "service_provider.cc", - "service_provider.h", - "shell.cc", - "shell.h", - "shell_view.cc", - "shell_view.h", - "switches.cc", - "switches.h", - "ui/animator.cc", - "ui/animator.h", - "ui/engine.cc", - "ui/engine.h", - "ui/input_event_converter.cc", - "ui/input_event_converter.h", - "ui/internals.cc", - "ui/internals.h", - "ui/platform_impl.cc", - "ui/platform_impl.h", - "ui_delegate.cc", - "ui_delegate.h", - ] - - deps = common_deps -} - -if (is_android) { - import("//build/config/android/config.gni") - import("//build/config/android/rules.gni") - - generate_jni("jni_headers") { - sources = [ - "android/org/domokit/sky/shell/PlatformServiceProvider.java", - "android/org/domokit/sky/shell/PlatformViewAndroid.java", - "android/org/domokit/sky/shell/SkyMain.java", - "android/org/domokit/sky/shell/TracingController.java", - ] - jni_package = "sky/shell" - } - - shared_library("sky_shell") { - sources = [ - "android/library_loader.cc", - "android/platform_service_provider_android.cc", - "android/platform_service_provider_android.h", - "android/platform_view_android.cc", - "android/platform_view_android.h", - "android/sky_main.cc", - "android/sky_main.h", - "android/tracing_controller.cc", - "android/tracing_controller.h", - ] - - deps = common_deps + [ - "//mojo/android:libsystem_java", - ":jni_headers", - ":common", - ] - } - - android_library("java") { - java_files = [ - "android/org/domokit/sky/shell/GestureProvider.java", - "android/org/domokit/sky/shell/PlatformServiceProvider.java", - "android/org/domokit/sky/shell/PlatformViewAndroid.java", - "android/org/domokit/sky/shell/ResourceCleaner.java", - "android/org/domokit/sky/shell/ResourceExtractor.java", - "android/org/domokit/sky/shell/ServiceFactory.java", - "android/org/domokit/sky/shell/ServiceRegistry.java", - "android/org/domokit/sky/shell/SkyActivity.java", - "android/org/domokit/sky/shell/SkyApplication.java", - "android/org/domokit/sky/shell/SkyMain.java", - "android/org/domokit/sky/shell/TracingController.java", - ] - - deps = [ - "//base:base_java", - "//mojo/android:system_java", - "//mojo/public/interfaces/application:application_java", - "//mojo/public/java:bindings", - "//mojo/public/java:system", - "//mojo/services/keyboard/public/interfaces:interfaces_java", - "//mojo/services/network/public/interfaces:interfaces_java", - "//services/keyboard", - "//sky/services/activity:activity_lib", - "//sky/services/activity:interfaces_java", - "//sky/services/engine:interfaces_java", - "//sky/services/oknet", - ] - } - - copy_ex("assets") { - clear_dir = true - dest = "$root_build_dir/sky_shell/assets" - sources = [ - "$root_build_dir/icudtl.dat", - ] - deps = [ - "//third_party/icu", - ] - } -} else if (is_ios) { - import("//build/config/ios/rules.gni") - import("//build/config/ios/ios_sdk.gni") - - ios_app("shell") { - app_name = "Sky" - info_plist = "ios/Info.plist" - scaffolding_target = "ios_scaffolding" - entitlements_path = "ios/Entitlements.xcent" - code_signing_identity = ios_code_signing_identity - - resource_copy_ios("sky_resources") { - resources = [ "//third_party/icu/android/icudtl.dat" ] - bundle_directory = "." - } - - source_set(scaffolding_target) { - sources = [ - "ios/main_ios.mm", - "ios/platform_service_provider_ios.cc", - "ios/platform_view_ios.h", - "ios/platform_view_ios.mm", - "ios/sky_app_delegate.h", - "ios/sky_app_delegate.mm", - "ios/sky_surface.h", - "ios/sky_surface.mm", - "ios/sky_view_controller.h", - "ios/sky_view_controller.mm", - ] - - deps = common_deps + [ - ":common", - "//sky/services/ns_net", - ] - } - - deps = [ - ":$scaffolding_target", - ":sky_resources", - ] - } -} else if (is_linux) { - executable("shell") { - output_name = "sky_shell" - - sources = [ - "linux/main.cc", - "linux/platform_service_provider_linux.cc", - "linux/platform_view_linux.cc", - "testing/test_runner.cc", - "testing/test_runner.h", - ] - - deps = common_deps + [ - ":common", - "//sky/services/testing:interfaces", - ] - } -} else { - assert(false, "Unsupported platform") -} diff --git a/engine/src/flutter/shell/android/library_loader.cc b/engine/src/flutter/shell/android/library_loader.cc deleted file mode 100644 index 5cb62e3e9b..0000000000 --- a/engine/src/flutter/shell/android/library_loader.cc +++ /dev/null @@ -1,51 +0,0 @@ -// Copyright 2015 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. - -#include "base/android/base_jni_onload.h" -#include "base/android/base_jni_registrar.h" -#include "base/android/jni_android.h" -#include "base/android/jni_registrar.h" -#include "base/android/library_loader/library_loader_hooks.h" -#include "base/bind.h" -#include "base/logging.h" -#include "mojo/android/system/base_run_loop.h" -#include "mojo/android/system/core_impl.h" -#include "sky/shell/android/platform_service_provider_android.h" -#include "sky/shell/android/platform_view_android.h" -#include "sky/shell/android/sky_main.h" -#include "sky/shell/android/tracing_controller.h" - -namespace { - -base::android::RegistrationMethod kSkyRegisteredMethods[] = { - {"CoreImpl", mojo::android::RegisterCoreImpl}, - {"BaseRunLoop", mojo::android::RegisterBaseRunLoop}, - {"PlatformServiceProvider", sky::shell::RegisterPlatformServiceProvider}, - {"PlatformViewAndroid", sky::shell::PlatformViewAndroid::Register}, - {"SkyMain", sky::shell::RegisterSkyMain}, - {"TracingController", sky::shell::RegisterTracingController}, -}; - -bool RegisterJNI(JNIEnv* env) { - if (!base::android::RegisterJni(env)) - return false; - - return RegisterNativeMethods(env, kSkyRegisteredMethods, - arraysize(kSkyRegisteredMethods)); -} - -} // namespace - -// This is called by the VM when the shared library is first loaded. -JNI_EXPORT jint JNI_OnLoad(JavaVM* vm, void* reserved) { - std::vector register_callbacks; - register_callbacks.push_back(base::Bind(&RegisterJNI)); - if (!base::android::OnJNIOnLoadRegisterJNI(vm, register_callbacks) || - !base::android::OnJNIOnLoadInit( - std::vector())) { - return -1; - } - - return JNI_VERSION_1_4; -} diff --git a/engine/src/flutter/shell/android/org/domokit/sky/shell/GestureProvider.java b/engine/src/flutter/shell/android/org/domokit/sky/shell/GestureProvider.java deleted file mode 100644 index f9e29e9ed9..0000000000 --- a/engine/src/flutter/shell/android/org/domokit/sky/shell/GestureProvider.java +++ /dev/null @@ -1,136 +0,0 @@ -// 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. - -package org.domokit.sky.shell; - -import android.content.Context; -import android.view.GestureDetector; -import android.view.MotionEvent; - -import org.chromium.mojom.sky.EventType; -import org.chromium.mojom.sky.GestureData; -import org.chromium.mojom.sky.InputEvent; - -/** - * Knows how to drive a GestureDetector to turn MotionEvents into Sky's - * InputEvents. Seems like this should not be needed. That there must exist - * some Android class to do most of this work for us? - */ -public class GestureProvider implements GestureDetector.OnGestureListener { - private static final String TAG = "GestureProvider"; - - /** - * Callback interface - */ - public interface OnGestureListener { - void onGestureEvent(InputEvent e); - } - - private OnGestureListener mListener; - private GestureDetector mDetector; - private boolean mScrolling; - private boolean mFlinging; - - public GestureProvider(Context context, OnGestureListener listener) { - mListener = listener; - mDetector = new GestureDetector(context, this); - } - - private InputEvent createGestureEvent(MotionEvent event) { - int pointerIndex = event.getActionIndex(); - GestureData gestureData = new GestureData(); - gestureData.primaryPointer = event.getPointerId(pointerIndex); - gestureData.x = event.getX(pointerIndex); - gestureData.y = event.getY(pointerIndex); - InputEvent inputEvent = new InputEvent(); - inputEvent.timeStamp = event.getEventTime(); - inputEvent.gestureData = gestureData; - return inputEvent; - } - - public void onTouchEvent(MotionEvent event) { - // TODO(eseidel): I am not confident that these stops are correct. - int maskedAction = event.getActionMasked(); - if (mScrolling && maskedAction == MotionEvent.ACTION_UP) { - mScrolling = false; - InputEvent inputEvent = createGestureEvent(event); - inputEvent.type = EventType.GESTURE_SCROLL_END; - mListener.onGestureEvent(inputEvent); - } - - if (mFlinging && maskedAction == MotionEvent.ACTION_DOWN) { - mFlinging = false; - InputEvent inputEvent = createGestureEvent(event); - inputEvent.type = EventType.GESTURE_FLING_CANCEL; - mListener.onGestureEvent(inputEvent); - } - - mDetector.onTouchEvent(event); - } - - @Override - public boolean onDown(MotionEvent event) { - InputEvent inputEvent = createGestureEvent(event); - inputEvent.type = EventType.GESTURE_TAP_DOWN; - mListener.onGestureEvent(inputEvent); - return true; - } - - @Override - public boolean onFling(MotionEvent e1, MotionEvent e2, - float velocityX, float velocityY) { - mFlinging = true; - - // Use the first event as a scroll start (for the target hit-test) - InputEvent inputEvent = createGestureEvent(e1); - inputEvent.gestureData.velocityX = velocityX; - inputEvent.gestureData.velocityY = velocityY; - inputEvent.type = EventType.GESTURE_FLING_START; - - mListener.onGestureEvent(inputEvent); - return true; - } - - @Override - public void onLongPress(MotionEvent event) { - InputEvent inputEvent = createGestureEvent(event); - inputEvent.type = EventType.GESTURE_LONG_PRESS; - mListener.onGestureEvent(inputEvent); - } - - @Override - public boolean onScroll(MotionEvent e1, MotionEvent e2, float distanceX, - float distanceY) { - // Use the first event as a scroll start (for the target hit-test) - InputEvent inputEvent = createGestureEvent(e1); - inputEvent.gestureData.dx = distanceX; - inputEvent.gestureData.dy = -distanceY; - - // If we haven't started scrolling, send a scroll_begin. - if (!mScrolling) { - mScrolling = true; - inputEvent.type = EventType.GESTURE_SCROLL_BEGIN; - mListener.onGestureEvent(inputEvent); - } - - inputEvent.type = EventType.GESTURE_SCROLL_UPDATE; - mListener.onGestureEvent(inputEvent); - return true; - } - - @Override - public void onShowPress(MotionEvent event) { - InputEvent inputEvent = createGestureEvent(event); - inputEvent.type = EventType.GESTURE_SHOW_PRESS; - mListener.onGestureEvent(inputEvent); - } - - @Override - public boolean onSingleTapUp(MotionEvent event) { - InputEvent inputEvent = createGestureEvent(event); - inputEvent.type = EventType.GESTURE_TAP; - mListener.onGestureEvent(inputEvent); - return true; - } -} \ No newline at end of file diff --git a/engine/src/flutter/shell/android/org/domokit/sky/shell/PlatformServiceProvider.java b/engine/src/flutter/shell/android/org/domokit/sky/shell/PlatformServiceProvider.java deleted file mode 100644 index 70b8866655..0000000000 --- a/engine/src/flutter/shell/android/org/domokit/sky/shell/PlatformServiceProvider.java +++ /dev/null @@ -1,55 +0,0 @@ -// Copyright 2015 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. - -package org.domokit.sky.shell; - -import android.content.Context; - -import org.chromium.base.CalledByNative; -import org.chromium.base.JNINamespace; -import org.chromium.mojo.system.Core; -import org.chromium.mojo.system.MessagePipeHandle; -import org.chromium.mojo.system.MojoException; -import org.chromium.mojo.system.impl.CoreImpl; -import org.chromium.mojom.mojo.ServiceProvider; - -/** - * A collection of services implemented in Java. - **/ -@JNINamespace("sky::shell") -public class PlatformServiceProvider implements ServiceProvider { - private Core mCore; - private Context mContext; - - @SuppressWarnings("unused") - @CalledByNative - public static void create(Context context, int nativeHandle) { - Core core = CoreImpl.getInstance(); - MessagePipeHandle pipe = core.acquireNativeHandle(nativeHandle).toMessagePipeHandle(); - ServiceProvider.MANAGER.bind(new PlatformServiceProvider(core, context), pipe); - } - - public PlatformServiceProvider(Core core, Context context) { - assert core != null; - assert context != null; - mCore = core; - mContext = context; - } - - @Override - public void close() {} - - @Override - public void onConnectionError(MojoException e) {} - - @Override - public void connectToService(String interfaceName, MessagePipeHandle pipe) { - ServiceFactory factory = ServiceRegistry.SHARED.get(interfaceName); - if (factory == null) { - pipe.close(); - return; - } - factory.connectToService(mContext, mCore, pipe); - } -} diff --git a/engine/src/flutter/shell/android/org/domokit/sky/shell/PlatformViewAndroid.java b/engine/src/flutter/shell/android/org/domokit/sky/shell/PlatformViewAndroid.java deleted file mode 100644 index a9e4dbb1fd..0000000000 --- a/engine/src/flutter/shell/android/org/domokit/sky/shell/PlatformViewAndroid.java +++ /dev/null @@ -1,228 +0,0 @@ -// Copyright 2013 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. - -package org.domokit.sky.shell; - -import android.content.Context; -import android.os.Build; -import android.view.MotionEvent; -import android.view.Surface; -import android.view.SurfaceHolder; -import android.view.SurfaceView; -import android.view.View; -import android.view.inputmethod.EditorInfo; -import android.view.inputmethod.InputConnection; - -import org.chromium.base.JNINamespace; -import org.chromium.mojo.bindings.InterfaceRequest; -import org.chromium.mojo.keyboard.KeyboardServiceImpl; -import org.chromium.mojo.system.Core; -import org.chromium.mojo.system.Pair; -import org.chromium.mojo.system.impl.CoreImpl; -import org.chromium.mojom.sky.EventType; -import org.chromium.mojom.sky.InputEvent; -import org.chromium.mojom.sky.PointerData; -import org.chromium.mojom.sky.PointerKind; -import org.chromium.mojom.sky.SkyEngine; -import org.chromium.mojom.sky.ViewportMetrics; - -/** - * A view containing Sky - */ -@JNINamespace("sky::shell") -public class PlatformViewAndroid extends SurfaceView - implements GestureProvider.OnGestureListener { - private static final String TAG = "PlatformViewAndroid"; - - private long mNativePlatformView; - private SkyEngine.Proxy mSkyEngine; - private final SurfaceHolder.Callback mSurfaceCallback; - private GestureProvider mGestureProvider; - private final EdgeDims mPadding; - - /** - * Dimensions in each of the four cardinal directions. - */ - public static class EdgeDims { - public double top = 0.0; - public double right = 0.0; - public double bottom = 0.0; - public double left = 0.0; - } - - public PlatformViewAndroid(Context context, EdgeDims padding) { - super(context); - mPadding = padding; - - setFocusable(true); - setFocusableInTouchMode(true); - - attach(); - assert mNativePlatformView != 0; - - final float density = context.getResources().getDisplayMetrics().density; - - mSurfaceCallback = new SurfaceHolder.Callback() { - @Override - public void surfaceChanged(SurfaceHolder holder, int format, int width, int height) { - assert mSkyEngine != null; - ViewportMetrics metrics = new ViewportMetrics(); - metrics.physicalWidth = width; - metrics.physicalHeight = height; - metrics.devicePixelRatio = density; - if (mPadding != null) { - metrics.paddingTop = mPadding.top; - metrics.paddingRight = mPadding.right; - metrics.paddingBottom = mPadding.bottom; - metrics.paddingLeft = mPadding.left; - } - mSkyEngine.onViewportMetricsChanged(metrics); - } - - @Override - public void surfaceCreated(SurfaceHolder holder) { - assert mNativePlatformView != 0; - nativeSurfaceCreated(mNativePlatformView, holder.getSurface()); - } - - @Override - public void surfaceDestroyed(SurfaceHolder holder) { - assert mNativePlatformView != 0; - nativeSurfaceDestroyed(mNativePlatformView); - } - }; - getHolder().addCallback(mSurfaceCallback); - - mGestureProvider = new GestureProvider(context, this); - KeyboardServiceImpl.setActiveView(this); - } - - SkyEngine getEngine() { - return mSkyEngine; - } - - @Override - protected void onDetachedFromWindow() { - getHolder().removeCallback(mSurfaceCallback); - nativeDetach(mNativePlatformView); - mNativePlatformView = 0; - } - - @Override - protected void onWindowVisibilityChanged(int visibility) { - super.onWindowVisibilityChanged(visibility); - if (visibility == View.VISIBLE) { - requestFocusFromTouch(); - requestFocus(); - } - } - - @Override - public boolean onCheckIsTextEditor() { - return true; - } - - @Override - public InputConnection onCreateInputConnection(EditorInfo outAttrs) { - return KeyboardServiceImpl.createInputConnection(outAttrs); - } - - private int getTypeForAction(int maskedAction) { - // Primary pointer: - if (maskedAction == MotionEvent.ACTION_DOWN) { - return EventType.POINTER_DOWN; - } - if (maskedAction == MotionEvent.ACTION_UP) { - return EventType.POINTER_UP; - } - // Secondary pointer: - if (maskedAction == MotionEvent.ACTION_POINTER_DOWN) { - return EventType.POINTER_DOWN; - } - if (maskedAction == MotionEvent.ACTION_POINTER_UP) { - return EventType.POINTER_UP; - } - // All pointers: - if (maskedAction == MotionEvent.ACTION_MOVE) { - return EventType.POINTER_MOVE; - } - if (maskedAction == MotionEvent.ACTION_CANCEL) { - return EventType.POINTER_CANCEL; - } - return EventType.UNKNOWN; - } - - private void sendInputEventForIndex(MotionEvent event, int pointerIndex) { - PointerData pointerData = new PointerData(); - pointerData.pointer = event.getPointerId(pointerIndex); - pointerData.kind = PointerKind.TOUCH; - pointerData.x = event.getX(pointerIndex); - pointerData.y = event.getY(pointerIndex); - - pointerData.pressure = event.getPressure(pointerIndex); - // TODO(eseidel): Could get the calibrated range if necessary: - // event.getDevice().getMotionRange(MotionEvent.AXIS_PRESSURE) - pointerData.pressureMin = 0.0f; - pointerData.pressureMax = 1.0f; - - InputEvent inputEvent = new InputEvent(); - inputEvent.type = getTypeForAction(event.getActionMasked()); - inputEvent.timeStamp = event.getEventTime(); - inputEvent.pointerData = pointerData; - - mSkyEngine.onInputEvent(inputEvent); - } - - @Override - public boolean onTouchEvent(MotionEvent event) { - // TODO(abarth): This version check might not be effective in some - // versions of Android that statically compile code and will be upset - // at the lack of |requestUnbufferedDispatch|. Instead, we should factor - // version-dependent code into separate classes for each supported - // version and dispatch dynamically. - if (Build.VERSION.SDK_INT >= Build.VERSION_CODES.LOLLIPOP) { - requestUnbufferedDispatch(event); - } - mGestureProvider.onTouchEvent(event); - - // TODO(abarth): Rather than unpacking these events here, we should - // probably send them in one packet to the engine. - int maskedAction = event.getActionMasked(); - // ACTION_UP, ACTION_POINTER_UP, ACTION_DOWN, and ACTION_POINTER_DOWN - // only apply to a single pointer, other events apply to all pointers. - if (maskedAction == MotionEvent.ACTION_UP - || maskedAction == MotionEvent.ACTION_POINTER_UP - || maskedAction == MotionEvent.ACTION_DOWN - || maskedAction == MotionEvent.ACTION_POINTER_DOWN) { - sendInputEventForIndex(event, event.getActionIndex()); - } else { - // ACTION_MOVE may not actually mean all pointers have moved - // but it's the responsibility of a later part of the system to - // ignore 0-deltas if desired. - for (int p = 0; p < event.getPointerCount(); p++) { - sendInputEventForIndex(event, p); - } - } - return true; - } - - @Override - public void onGestureEvent(InputEvent event) { - mSkyEngine.onInputEvent(event); - } - - private void attach() { - Core core = CoreImpl.getInstance(); - Pair> result = - SkyEngine.MANAGER.getInterfaceRequest(core); - mSkyEngine = result.first; - mNativePlatformView = nativeAttach(result.second.passHandle().releaseNativeHandle()); - } - - private static native long nativeAttach(int inputObserverHandle); - private static native void nativeDetach(long nativePlatformViewAndroid); - private static native void nativeSurfaceCreated(long nativePlatformViewAndroid, - Surface surface); - private static native void nativeSurfaceDestroyed(long nativePlatformViewAndroid); -} diff --git a/engine/src/flutter/shell/android/org/domokit/sky/shell/ResourceCleaner.java b/engine/src/flutter/shell/android/org/domokit/sky/shell/ResourceCleaner.java deleted file mode 100644 index 8aa43a9628..0000000000 --- a/engine/src/flutter/shell/android/org/domokit/sky/shell/ResourceCleaner.java +++ /dev/null @@ -1,86 +0,0 @@ -// Copyright 2015 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. - -package org.domokit.sky.shell; - -import android.content.Context; -import android.os.AsyncTask; -import android.os.Handler; -import android.util.Log; - -import java.io.File; -import java.io.FilenameFilter; - -/** - * A class to clean up orphaned resource directories after unclean shutdowns. - **/ -public class ResourceCleaner { - private static final String TAG = "ResourceCleaner"; - private static final String TEMPORARY_RESOURCE_PREFIX = ".org.chromium.Chromium."; - private static final long DELAY_MS = 5000; - - private class CleanTask extends AsyncTask { - private final File[] mFilesToDelete; - - public CleanTask(File[] filesToDelete) { - mFilesToDelete = filesToDelete; - } - - public boolean hasFilesToDelete() { - return mFilesToDelete.length > 0; - } - - @Override - protected Void doInBackground(Void... unused) { - Log.i(TAG, "Cleaning " + mFilesToDelete.length + " resources."); - for (File file : mFilesToDelete) { - if (file.exists()) { - deleteRecursively(file); - } - } - return null; - } - - private void deleteRecursively(File parent) { - if (parent.isDirectory()) { - for (File child : parent.listFiles()) { - deleteRecursively(child); - } - } - parent.delete(); - } - } - - private final Context mContext; - - public ResourceCleaner(Context context) { - mContext = context; - } - - public void start() { - File cacheDir = mContext.getCacheDir(); - if (cacheDir == null) { - return; - } - - final CleanTask task = new CleanTask(cacheDir.listFiles(new FilenameFilter() { - @Override - public boolean accept(File dir, String name) { - boolean result = name.startsWith(TEMPORARY_RESOURCE_PREFIX); - return result; - } - })); - - if (!task.hasFilesToDelete()) { - return; - } - - new Handler().postDelayed(new Runnable() { - @Override - public void run() { - task.executeOnExecutor(AsyncTask.THREAD_POOL_EXECUTOR); - } - }, DELAY_MS); - } -} diff --git a/engine/src/flutter/shell/android/org/domokit/sky/shell/ResourceExtractor.java b/engine/src/flutter/shell/android/org/domokit/sky/shell/ResourceExtractor.java deleted file mode 100644 index 3976bb9dd2..0000000000 --- a/engine/src/flutter/shell/android/org/domokit/sky/shell/ResourceExtractor.java +++ /dev/null @@ -1,186 +0,0 @@ -// Copyright 2015 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. - -package org.domokit.sky.shell; - -import android.content.Context; -import android.content.pm.PackageInfo; -import android.content.pm.PackageManager; -import android.content.res.AssetManager; -import android.os.AsyncTask; -import android.util.Log; - -import org.chromium.base.PathUtils; - -import java.io.File; -import java.io.FileOutputStream; -import java.io.FilenameFilter; -import java.io.IOException; -import java.io.InputStream; -import java.io.OutputStream; -import java.util.HashSet; -import java.util.concurrent.CancellationException; -import java.util.concurrent.ExecutionException; - -/** - * A class to intialize the native code. - **/ -public class ResourceExtractor { - private static final String TAG = "ResourceExtractor"; - private static final String TIMESTAMP_PREFIX = "res_timestamp-"; - - private class ExtractTask extends AsyncTask { - private static final int BUFFER_SIZE = 16 * 1024; - - public ExtractTask() { } - - private void extractResources() { - final File dataDir = new File(PathUtils.getDataDirectory(mContext)); - - final String timestamp = checkTimestamp(dataDir); - if (timestamp != null) { - deleteFiles(); - } - - final AssetManager manager = mContext.getResources().getAssets(); - try { - byte[] buffer = null; - final String[] assets = manager.list(""); - for (String asset : assets) { - if (!mResources.contains(asset)) - continue; - final File output = new File(dataDir, asset); - if (output.exists()) - continue; - InputStream is = null; - OutputStream os = null; - try { - is = manager.open(asset); - os = new FileOutputStream(output); - if (buffer == null) { - buffer = new byte[BUFFER_SIZE]; - } - - int count = 0; - while ((count = is.read(buffer, 0, BUFFER_SIZE)) != -1) { - os.write(buffer, 0, count); - } - os.flush(); - } finally { - try { - if (is != null) { - is.close(); - } - } finally { - if (os != null) { - os.close(); - } - } - } - } - } catch (IOException e) { - Log.w(TAG, "Exception unpacking resources: " + e.getMessage()); - deleteFiles(); - return; - } - - if (timestamp != null) { - try { - new File(dataDir, timestamp).createNewFile(); - } catch (IOException e) { - Log.w(TAG, "Failed to write resource timestamp"); - } - } - } - - private String checkTimestamp(File dataDir) { - PackageManager packageManager = mContext.getPackageManager(); - PackageInfo packageInfo = null; - - try { - packageInfo = packageManager.getPackageInfo(mContext.getPackageName(), 0); - } catch (PackageManager.NameNotFoundException e) { - return TIMESTAMP_PREFIX; - } - - if (packageInfo == null) { - return TIMESTAMP_PREFIX; - } - - String expectedTimestamp = - TIMESTAMP_PREFIX + packageInfo.versionCode + "-" + packageInfo.lastUpdateTime; - - final String[] existingTimestamps = getExistingTimestamps(dataDir); - if (existingTimestamps.length != 1 - || !expectedTimestamp.equals(existingTimestamps[0])) { - return expectedTimestamp; - } - - return null; - } - - @Override - protected Void doInBackground(Void... unused) { - extractResources(); - return null; - } - } - - private final Context mContext; - private final HashSet mResources; - private ExtractTask mExtractTask; - - public ResourceExtractor(Context context) { - mContext = context; - mResources = new HashSet(); - } - - public void addResources(String[] resources) { - for (String resource : resources) { - mResources.add(resource); - } - } - - public void start() { - assert mExtractTask == null; - mExtractTask = new ExtractTask(); - mExtractTask.executeOnExecutor(AsyncTask.THREAD_POOL_EXECUTOR); - } - - public void waitForCompletion() { - assert mExtractTask != null; - - try { - mExtractTask.get(); - } catch (CancellationException e) { - deleteFiles(); - } catch (ExecutionException e2) { - deleteFiles(); - } catch (InterruptedException e3) { - deleteFiles(); - } - } - - private String[] getExistingTimestamps(File dataDir) { - return dataDir.list(new FilenameFilter() { - @Override - public boolean accept(File dir, String name) { - return name.startsWith(TIMESTAMP_PREFIX); - } - }); - } - - private void deleteFiles() { - final File dataDir = new File(PathUtils.getDataDirectory(mContext)); - for (String resource : mResources) { - final File file = new File(dataDir, resource); - if (file.exists()) { - file.delete(); - } - } - for (String timestamp : getExistingTimestamps(dataDir)) { - new File(dataDir, timestamp).delete(); - } - } -} diff --git a/engine/src/flutter/shell/android/org/domokit/sky/shell/ServiceFactory.java b/engine/src/flutter/shell/android/org/domokit/sky/shell/ServiceFactory.java deleted file mode 100644 index a2d6cb1e66..0000000000 --- a/engine/src/flutter/shell/android/org/domokit/sky/shell/ServiceFactory.java +++ /dev/null @@ -1,19 +0,0 @@ -// Copyright 2015 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. - -package org.domokit.sky.shell; - -import android.content.Context; - -import org.chromium.mojo.system.Core; -import org.chromium.mojo.system.MessagePipeHandle; - -/** - * An interface for creating services. Instances of this interface can be - * registered with ServiceRegistry and thereby made available to non-Java - * clients. - **/ -public interface ServiceFactory { - public void connectToService(Context context, Core core, MessagePipeHandle pipe); -} diff --git a/engine/src/flutter/shell/android/org/domokit/sky/shell/ServiceRegistry.java b/engine/src/flutter/shell/android/org/domokit/sky/shell/ServiceRegistry.java deleted file mode 100644 index 73c87d77a5..0000000000 --- a/engine/src/flutter/shell/android/org/domokit/sky/shell/ServiceRegistry.java +++ /dev/null @@ -1,37 +0,0 @@ -// Copyright 2015 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. - -package org.domokit.sky.shell; - -import android.util.Log; - -import java.util.Map; -import java.util.TreeMap; - -/** - * An registry for services. - **/ -public class ServiceRegistry { - private static final String TAG = "ServiceRegistry"; - private Map mRegistrations; - - public static final ServiceRegistry SHARED = new ServiceRegistry(); - - private ServiceRegistry() { - mRegistrations = new TreeMap(); - } - - public void register(String interfaceName, ServiceFactory connector) { - assert !mRegistrations.containsKey(interfaceName); - assert connector != null; - mRegistrations.put(interfaceName, connector); - } - - public ServiceFactory get(String interfaceName) { - if (!mRegistrations.containsKey(interfaceName)) { - Log.e(TAG, "Unknown service " + interfaceName); - } - return mRegistrations.get(interfaceName); - } -} diff --git a/engine/src/flutter/shell/android/org/domokit/sky/shell/SkyActivity.java b/engine/src/flutter/shell/android/org/domokit/sky/shell/SkyActivity.java deleted file mode 100644 index 9b30b73178..0000000000 --- a/engine/src/flutter/shell/android/org/domokit/sky/shell/SkyActivity.java +++ /dev/null @@ -1,123 +0,0 @@ -// Copyright 2015 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. - -package org.domokit.sky.shell; - -import android.app.Activity; -import android.os.Build; -import android.os.Bundle; -import android.view.View; -import android.view.WindowManager; - -import org.chromium.base.PathUtils; -import org.chromium.mojom.sky.EventType; -import org.chromium.mojom.sky.InputEvent; - -import org.domokit.activity.ActivityImpl; - -import java.io.File; - -/** - * Base class for activities that use Sky. - */ -public class SkyActivity extends Activity { - private TracingController mTracingController; - private PlatformViewAndroid mView; - - /** - * @see android.app.Activity#onCreate(android.os.Bundle) - */ - @Override - protected void onCreate(Bundle savedInstanceState) { - super.onCreate(savedInstanceState); - - PlatformViewAndroid.EdgeDims edgeDims = new PlatformViewAndroid.EdgeDims(); - - if (Build.VERSION.SDK_INT >= Build.VERSION_CODES.LOLLIPOP) { - getWindow().addFlags(WindowManager.LayoutParams.FLAG_DRAWS_SYSTEM_BAR_BACKGROUNDS); - getWindow().setStatusBarColor(0x40000000); - // TODO(abarth): We should get this value from the Android framework somehow. - edgeDims.top = 25.0; - } - getWindow().getDecorView().setSystemUiVisibility( - View.SYSTEM_UI_FLAG_LAYOUT_STABLE - | View.SYSTEM_UI_FLAG_LAYOUT_FULLSCREEN); - - SkyMain.ensureInitialized(getApplicationContext()); - mView = new PlatformViewAndroid(this, edgeDims); - ActivityImpl.setCurrentActivity(this); - setContentView(mView); - mTracingController = new TracingController(this); - - onSkyReady(); - } - - /** - * @see android.app.Activity#onDestroy() - */ - @Override - protected void onDestroy() { - // Do we need to shut down Sky too? - mTracingController.stop(); - super.onDestroy(); - } - - @Override - public void onBackPressed() { - if (mView != null) { - InputEvent event = new InputEvent(); - event.type = EventType.BACK; - mView.getEngine().onInputEvent(event); - return; - } - super.onBackPressed(); - } - - @Override - protected void onPause() { - super.onPause(); - if (mView != null) { - mView.getEngine().onActivityPaused(); - } - } - - @Override - protected void onPostResume() { - super.onPostResume(); - if (mView != null) { - mView.getEngine().onActivityResumed(); - } - } - - /** - * Override this function to customize startup behavior. - */ - protected void onSkyReady() { - File dataDir = new File(PathUtils.getDataDirectory(this)); - File snapshot = new File(dataDir, SkyApplication.SNAPSHOT); - if (snapshot.exists()) { - mView.getEngine().runFromSnapshot(snapshot.getPath()); - return; - } - File appBundle = new File(dataDir, SkyApplication.APP_BUNDLE); - if (appBundle.exists()) { - mView.getEngine().runFromBundle(appBundle.getPath()); - return; - } - } - - public void loadUrl(String url) { - mView.getEngine().runFromNetwork(url); - } - - public boolean loadBundleByName(String name) { - File dataDir = new File(PathUtils.getDataDirectory(this)); - File bundle = new File(dataDir, name); - if (!bundle.exists()) { - return false; - } - mView.getEngine().runFromBundle(bundle.getPath()); - return true; - } -} diff --git a/engine/src/flutter/shell/android/org/domokit/sky/shell/SkyApplication.java b/engine/src/flutter/shell/android/org/domokit/sky/shell/SkyApplication.java deleted file mode 100644 index 7812f42880..0000000000 --- a/engine/src/flutter/shell/android/org/domokit/sky/shell/SkyApplication.java +++ /dev/null @@ -1,106 +0,0 @@ -// Copyright 2015 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. - -package org.domokit.sky.shell; - -import android.content.Context; -import android.util.Log; - -import org.chromium.base.BaseChromiumApplication; -import org.chromium.base.PathUtils; -import org.chromium.base.library_loader.LibraryLoader; -import org.chromium.base.library_loader.LibraryProcessType; -import org.chromium.base.library_loader.ProcessInitException; -import org.chromium.mojo.keyboard.KeyboardServiceImpl; -import org.chromium.mojo.system.Core; -import org.chromium.mojo.system.MessagePipeHandle; -import org.chromium.mojom.activity.Activity; -import org.chromium.mojom.keyboard.KeyboardService; -import org.chromium.mojom.mojo.NetworkService; -import org.domokit.activity.ActivityImpl; -import org.domokit.oknet.NetworkServiceImpl; - -/** - * Sky implementation of {@link android.app.Application}, managing application-level global - * state and initializations. - */ -public class SkyApplication extends BaseChromiumApplication { - static final String SNAPSHOT = "snapshot_blob.bin"; - static final String APP_BUNDLE = "app.skyx"; - - private static final String TAG = "SkyApplication"; - private static final String PRIVATE_DATA_DIRECTORY_SUFFIX = "sky_shell"; - private static final String[] SKY_RESOURCES = {"icudtl.dat", SNAPSHOT, APP_BUNDLE}; - - private ResourceExtractor mResourceExtractor; - - public ResourceExtractor getResourceExtractor() { - return mResourceExtractor; - } - - @Override - public void onCreate() { - super.onCreate(); - initJavaUtils(); - initResources(); - initNative(); - onServiceRegistryAvailable(ServiceRegistry.SHARED); - } - - /** - * Override this function to add more resources for extraction. - */ - protected void onBeforeResourceExtraction(ResourceExtractor extractor) { - extractor.addResources(SKY_RESOURCES); - } - - /** - * Override this function to register more services. - */ - protected void onServiceRegistryAvailable(ServiceRegistry registry) { - registry.register(NetworkService.MANAGER.getName(), new ServiceFactory() { - @Override - public void connectToService(Context context, Core core, MessagePipeHandle pipe) { - // TODO(eseidel): Refactor ownership to match other services. - new NetworkServiceImpl(context, core, pipe); - } - }); - - registry.register(KeyboardService.MANAGER.getName(), new ServiceFactory() { - @Override - public void connectToService(Context context, Core core, MessagePipeHandle pipe) { - KeyboardService.MANAGER.bind(new KeyboardServiceImpl(context), pipe); - } - }); - - registry.register(Activity.MANAGER.getName(), new ServiceFactory() { - @Override - public void connectToService(Context context, Core core, MessagePipeHandle pipe) { - Activity.MANAGER.bind(new ActivityImpl(), pipe); - } - }); - } - - private void initJavaUtils() { - PathUtils.setPrivateDataDirectorySuffix(PRIVATE_DATA_DIRECTORY_SUFFIX, - getApplicationContext()); - } - - private void initResources() { - Context context = getApplicationContext(); - new ResourceCleaner(context).start(); - mResourceExtractor = new ResourceExtractor(context); - onBeforeResourceExtraction(mResourceExtractor); - mResourceExtractor.start(); - } - - private void initNative() { - try { - LibraryLoader.get(LibraryProcessType.PROCESS_BROWSER).ensureInitialized(); - } catch (ProcessInitException e) { - Log.e(TAG, "Unable to load Sky Engine binary.", e); - throw new RuntimeException(e); - } - } -} diff --git a/engine/src/flutter/shell/android/org/domokit/sky/shell/SkyMain.java b/engine/src/flutter/shell/android/org/domokit/sky/shell/SkyMain.java deleted file mode 100644 index 98a1275133..0000000000 --- a/engine/src/flutter/shell/android/org/domokit/sky/shell/SkyMain.java +++ /dev/null @@ -1,46 +0,0 @@ -// Copyright 2013 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. - -package org.domokit.sky.shell; - -import android.content.Context; -import android.util.Log; - -import org.chromium.base.JNINamespace; -import org.chromium.mojo.system.impl.CoreImpl; - -/** - * A class to intialize the native code. - **/ -@JNINamespace("sky::shell") -public class SkyMain { - private static final String TAG = "SkyMain"; - - /** - * A guard flag for calling nativeInit() only once. - **/ - private static boolean sInitialized = false; - - /** - * Initializes the native system. - **/ - public static void ensureInitialized(Context applicationContext) { - if (sInitialized) { - return; - } - try { - SkyApplication app = (SkyApplication) applicationContext; - app.getResourceExtractor().waitForCompletion(); - nativeInit(applicationContext); - // Create the mojo run loop. - CoreImpl.getInstance().createDefaultRunLoop(); - sInitialized = true; - } catch (Exception e) { - Log.e(TAG, "SkyMain initialization failed.", e); - throw new RuntimeException(e); - } - } - - private static native void nativeInit(Context context); -} diff --git a/engine/src/flutter/shell/android/org/domokit/sky/shell/TracingController.java b/engine/src/flutter/shell/android/org/domokit/sky/shell/TracingController.java deleted file mode 100644 index 7c7076ee45..0000000000 --- a/engine/src/flutter/shell/android/org/domokit/sky/shell/TracingController.java +++ /dev/null @@ -1,77 +0,0 @@ -// Copyright 2015 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. - -package org.domokit.sky.shell; - -import android.content.BroadcastReceiver; -import android.content.Context; -import android.content.Intent; -import android.content.IntentFilter; -import android.util.Log; - -import org.chromium.base.JNINamespace; - -import java.io.File; -import java.text.SimpleDateFormat; -import java.util.Date; -import java.util.Locale; -import java.util.TimeZone; - -/** - * A controller for the tracing system. - */ -@JNINamespace("sky::shell") -class TracingController { - private static final String TAG = "TracingController"; - private static final String TRACING_START = ".TRACING_START"; - private static final String TRACING_STOP = ".TRACING_STOP"; - - private final Context mContext; - private final TracingBroadcastReceiver mBroadcastReceiver; - private final TracingIntentFilter mIntentFilter; - - public TracingController(Context context) { - mContext = context; - mBroadcastReceiver = new TracingBroadcastReceiver(); - mIntentFilter = new TracingIntentFilter(context); - - mContext.registerReceiver(mBroadcastReceiver, mIntentFilter); - } - - public void stop() { - mContext.unregisterReceiver(mBroadcastReceiver); - } - - private String generateTracingFilePath() { - SimpleDateFormat formatter = new SimpleDateFormat("yyyy-MM-dd-HHmmss", Locale.US); - formatter.setTimeZone(TimeZone.getTimeZone("UTC")); - File dir = mContext.getCacheDir(); - String date = formatter.format(new Date()); - File file = new File(dir, "sky-trace-" + date + ".json"); - return file.getPath(); - } - - class TracingIntentFilter extends IntentFilter { - TracingIntentFilter(Context context) { - addAction(context.getPackageName() + TRACING_START); - addAction(context.getPackageName() + TRACING_STOP); - } - } - - class TracingBroadcastReceiver extends BroadcastReceiver { - @Override - public void onReceive(Context context, Intent intent) { - if (intent.getAction().endsWith(TRACING_START)) { - nativeStartTracing(); - } else if (intent.getAction().endsWith(TRACING_STOP)) { - nativeStopTracing(generateTracingFilePath()); - } else { - Log.e(TAG, "Unexpected intent: " + intent); - } - } - } - - private static native void nativeStartTracing(); - private static native void nativeStopTracing(String path); -} diff --git a/engine/src/flutter/shell/android/platform_service_provider_android.cc b/engine/src/flutter/shell/android/platform_service_provider_android.cc deleted file mode 100644 index 5cae2e0d91..0000000000 --- a/engine/src/flutter/shell/android/platform_service_provider_android.cc +++ /dev/null @@ -1,45 +0,0 @@ -// Copyright 2015 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. - -#include "sky/shell/android/platform_service_provider_android.h" - -#include "base/android/jni_android.h" -#include "base/bind.h" -#include "base/trace_event/trace_event.h" -#include "jni/PlatformServiceProvider_jni.h" -#include "mojo/public/cpp/bindings/interface_request.h" -#include "sky/shell/service_provider.h" - -namespace sky { -namespace shell { -namespace { - -void CreatePlatformServiceProvider( - mojo::InterfaceRequest request) { - Java_PlatformServiceProvider_create( - base::android::AttachCurrentThread(), - base::android::GetApplicationContext(), - request.PassMessagePipe().release().value()); -} - -} // namespace - -bool RegisterPlatformServiceProvider(JNIEnv* env) { - return RegisterNativesImpl(env); -} - -mojo::ServiceProviderPtr CreateServiceProvider( - ServiceProviderContext* context) { - mojo::MessagePipe pipe; - context->platform_task_runner->PostTask( - FROM_HERE, - base::Bind(CreatePlatformServiceProvider, - base::Passed(mojo::MakeRequest( - pipe.handle1.Pass())))); - return mojo::MakeProxy( - mojo::InterfacePtrInfo(pipe.handle0.Pass(), 0u)); -} - -} // namespace shell -} // namespace sky diff --git a/engine/src/flutter/shell/android/platform_service_provider_android.h b/engine/src/flutter/shell/android/platform_service_provider_android.h deleted file mode 100644 index 682835646a..0000000000 --- a/engine/src/flutter/shell/android/platform_service_provider_android.h +++ /dev/null @@ -1,18 +0,0 @@ -// Copyright 2015 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. - -#ifndef SKY_SHELL_PLATFORM_SERVICE_PROVIDER_ANDROID_H_ -#define SKY_SHELL_PLATFORM_SERVICE_PROVIDER_ANDROID_H_ - -#include - -namespace sky { -namespace shell { - -bool RegisterPlatformServiceProvider(JNIEnv* env); - -} // namespace shell -} // namespace sky - -#endif // SKY_SHELL_PLATFORM_SERVICE_PROVIDER_ANDROID_H_ diff --git a/engine/src/flutter/shell/android/platform_view_android.cc b/engine/src/flutter/shell/android/platform_view_android.cc deleted file mode 100644 index af9e38c056..0000000000 --- a/engine/src/flutter/shell/android/platform_view_android.cc +++ /dev/null @@ -1,83 +0,0 @@ -// Copyright 2015 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. - -#include "sky/shell/android/platform_view_android.h" - -#include -#include - -#include "base/android/jni_android.h" -#include "base/bind.h" -#include "base/location.h" -#include "jni/PlatformViewAndroid_jni.h" -#include "sky/shell/shell.h" -#include "sky/shell/shell_view.h" - -namespace sky { -namespace shell { - -static jlong Attach(JNIEnv* env, jclass clazz, jint skyEngineHandle) { - ShellView* shell_view = new ShellView(Shell::Shared()); - auto view = static_cast(shell_view->view()); - view->SetShellView(make_scoped_ptr(shell_view)); - view->ConnectToEngine( - mojo::MakeRequest(mojo::ScopedMessagePipeHandle( - mojo::MessagePipeHandle(skyEngineHandle)))); - return reinterpret_cast(shell_view->view()); -} - -// static -bool PlatformViewAndroid::Register(JNIEnv* env) { - return RegisterNativesImpl(env); -} - -PlatformView* PlatformView::Create(const Config& config) { - return new PlatformViewAndroid(config); -} - -PlatformViewAndroid::PlatformViewAndroid(const Config& config) - : PlatformView(config) { -} - -PlatformViewAndroid::~PlatformViewAndroid() { - if (window_) - ReleaseWindow(); -} - -void PlatformViewAndroid::Detach(JNIEnv* env, jobject obj) { - DCHECK(!window_); - shell_view_.reset(); - // Note: |this| has been destroyed at this point. -} - -void PlatformViewAndroid::SurfaceCreated(JNIEnv* env, jobject obj, jobject jsurface) { - base::android::ScopedJavaLocalRef protector(env, jsurface); - // Note: This ensures that any local references used by - // ANativeWindow_fromSurface are released immediately. This is needed as a - // workaround for https://code.google.com/p/android/issues/detail?id=68174 - { - base::android::ScopedJavaLocalFrame scoped_local_reference_frame(env); - window_ = ANativeWindow_fromSurface(env, jsurface); - } - SurfaceWasCreated(); -} - -void PlatformViewAndroid::SurfaceDestroyed(JNIEnv* env, jobject obj) { - DCHECK(window_); - SurfaceWasDestroyed(); - ReleaseWindow(); -} - -void PlatformViewAndroid::SetShellView(scoped_ptr shell_view) { - DCHECK(!shell_view_); - shell_view_ = shell_view.Pass(); -} - -void PlatformViewAndroid::ReleaseWindow() { - ANativeWindow_release(window_); - window_ = nullptr; -} - -} // namespace shell -} // namespace sky diff --git a/engine/src/flutter/shell/android/platform_view_android.h b/engine/src/flutter/shell/android/platform_view_android.h deleted file mode 100644 index 4f3f908e61..0000000000 --- a/engine/src/flutter/shell/android/platform_view_android.h +++ /dev/null @@ -1,45 +0,0 @@ -// Copyright 2015 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. - -#ifndef SKY_SHELL_PLATFORM_VIEW_ANDROID_H_ -#define SKY_SHELL_PLATFORM_VIEW_ANDROID_H_ - -#include "sky/shell/platform_view.h" - -struct ANativeWindow; - -namespace sky { -namespace shell { -class ShellView; - -class PlatformViewAndroid : public PlatformView { - public: - static bool Register(JNIEnv* env); - - PlatformViewAndroid(const Config& config); - ~PlatformViewAndroid() override; - - // Called from Java - void Detach(JNIEnv* env, jobject obj); - void SurfaceCreated(JNIEnv* env, jobject obj, jobject jsurface); - void SurfaceDestroyed(JNIEnv* env, jobject obj); - - void SetShellView(scoped_ptr shell_view); - - private: - void ReleaseWindow(); - - // In principle, the ShellView should own the PlatformView, but because our - // lifetime is controlled by the Android view hierarchy, we flip around the - // ownership and have the shell_view owned by Java. We reset this pointer in - // |Detach|, which will eventually cause |~PlatformViewAndroid|. - scoped_ptr shell_view_; - - DISALLOW_COPY_AND_ASSIGN(PlatformViewAndroid); -}; - -} // namespace shell -} // namespace sky - -#endif // SKY_SHELL_PLATFORM_VIEW_ANDROID_H_ diff --git a/engine/src/flutter/shell/android/sky_main.cc b/engine/src/flutter/shell/android/sky_main.cc deleted file mode 100644 index 98118282db..0000000000 --- a/engine/src/flutter/shell/android/sky_main.cc +++ /dev/null @@ -1,70 +0,0 @@ -// Copyright 2015 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. - -#include "sky/shell/android/sky_main.h" - -#include "base/android/jni_android.h" -#include "base/android/jni_array.h" -#include "base/android/jni_string.h" -#include "base/at_exit.h" -#include "base/bind.h" -#include "base/command_line.h" -#include "base/i18n/icu_util.h" -#include "base/lazy_instance.h" -#include "base/logging.h" -#include "base/macros.h" -#include "base/message_loop/message_loop.h" -#include "base/run_loop.h" -#include "base/threading/simple_thread.h" -#include "jni/SkyMain_jni.h" -#include "sky/shell/service_provider.h" -#include "sky/shell/shell.h" -#include "ui/gl/gl_surface_egl.h" - -using base::LazyInstance; - -namespace sky { -namespace shell { - -namespace { - -LazyInstance> g_java_message_loop = - LAZY_INSTANCE_INITIALIZER; - -void InitializeLogging() { - logging::LoggingSettings settings; - settings.logging_dest = logging::LOG_TO_SYSTEM_DEBUG_LOG; - logging::InitLogging(settings); - // To view log output with IDs and timestamps use "adb logcat -v threadtime". - logging::SetLogItems(false, // Process ID - false, // Thread ID - false, // Timestamp - false); // Tick count -} - -} // namespace - -static void Init(JNIEnv* env, jclass clazz, jobject context) { - base::android::ScopedJavaLocalRef scoped_context(env, context); - base::android::InitApplicationContext(env, scoped_context); - - base::CommandLine::Init(0, nullptr); - InitializeLogging(); - - g_java_message_loop.Get().reset(new base::MessageLoopForUI); - base::MessageLoopForUI::current()->Start(); - - base::i18n::InitializeICU(); - gfx::GLSurface::InitializeOneOff(); - - Shell::Init(make_scoped_ptr(new ServiceProviderContext( - g_java_message_loop.Get()->task_runner()))); -} - -bool RegisterSkyMain(JNIEnv* env) { - return RegisterNativesImpl(env); -} - -} // namespace sky -} // namespace mojo diff --git a/engine/src/flutter/shell/android/sky_main.h b/engine/src/flutter/shell/android/sky_main.h deleted file mode 100644 index 6913690e89..0000000000 --- a/engine/src/flutter/shell/android/sky_main.h +++ /dev/null @@ -1,18 +0,0 @@ -// Copyright 2015 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. - -#ifndef SKY_SHELL_SKY_MAIN_H_ -#define SKY_SHELL_SKY_MAIN_H_ - -#include - -namespace sky { -namespace shell { - -bool RegisterSkyMain(JNIEnv* env); - -} // namespace shell -} // namespace sky - -#endif // SKY_SHELL_SKY_MAIN_H_ diff --git a/engine/src/flutter/shell/android/tracing_controller.cc b/engine/src/flutter/shell/android/tracing_controller.cc deleted file mode 100644 index d9b55c51ed..0000000000 --- a/engine/src/flutter/shell/android/tracing_controller.cc +++ /dev/null @@ -1,70 +0,0 @@ -// Copyright 2015 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. - -#include "sky/shell/android/tracing_controller.h" - -#include "base/android/jni_android.h" -#include "base/android/jni_string.h" -#include "base/files/file_util.h" -#include "base/macros.h" -#include "base/trace_event/trace_config.h" -#include "base/trace_event/trace_event.h" -#include "jni/TracingController_jni.h" - -namespace sky { -namespace shell { -namespace { - -const char kStart[] = "{\"traceEvents\":["; -const char kEnd[] = "]}"; - -static FILE* g_file = NULL; - -void Write(const std::string& data) { - ignore_result(fwrite(data.data(), data.length(), 1, g_file)); -} - -void HandleChunk(const scoped_refptr& chunk, - bool has_more_events) { - Write(chunk->data()); - if (has_more_events) - Write(","); - - if (!has_more_events) { - Write(kEnd); - base::CloseFile(g_file); - g_file = NULL; - - LOG(INFO) << "Trace complete"; - } -} - -} // namespace - -static void StartTracing(JNIEnv* env, jclass clazz) { - LOG(INFO) << "Starting trace"; - - base::trace_event::TraceLog::GetInstance()->SetEnabled( - base::trace_event::TraceConfig("*", base::trace_event::RECORD_UNTIL_FULL), - base::trace_event::TraceLog::RECORDING_MODE); -} - -static void StopTracing(JNIEnv* env, jclass clazz, jstring path) { - base::trace_event::TraceLog::GetInstance()->SetDisabled(); - - base::FilePath file_path(base::android::ConvertJavaStringToUTF8(env, path)); - g_file = base::OpenFile(file_path, "w"); - CHECK(g_file) << "Failed to open file " << file_path.LossyDisplayName(); - - LOG(INFO) << "Saving trace to " << file_path.LossyDisplayName(); - Write(kStart); - base::trace_event::TraceLog::GetInstance()->Flush(base::Bind(&HandleChunk)); -} - -bool RegisterTracingController(JNIEnv* env) { - return RegisterNativesImpl(env); -} - -} // namespace shell -} // namespace sky diff --git a/engine/src/flutter/shell/android/tracing_controller.h b/engine/src/flutter/shell/android/tracing_controller.h deleted file mode 100644 index 4a3d3d561e..0000000000 --- a/engine/src/flutter/shell/android/tracing_controller.h +++ /dev/null @@ -1,19 +0,0 @@ -// Copyright 2015 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. - -#ifndef SKY_SHELL_TRACING_CONTROLLER_H_ -#define SKY_SHELL_TRACING_CONTROLLER_H_ - -#include "base/android/jni_weak_ref.h" -#include "base/android/scoped_java_ref.h" - -namespace sky { -namespace shell { - -bool RegisterTracingController(JNIEnv* env); - -} // namespace shell -} // namespace sky - -#endif // SKY_SHELL_TRACING_CONTROLLER_H_ diff --git a/engine/src/flutter/shell/dart/BUILD.gn b/engine/src/flutter/shell/dart/BUILD.gn deleted file mode 100644 index b4a1cf528a..0000000000 --- a/engine/src/flutter/shell/dart/BUILD.gn +++ /dev/null @@ -1,24 +0,0 @@ -# Copyright 2015 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. - -source_set("dart") { - sources = [ - "dart_library_provider_files.cc", - "dart_library_provider_files.h", - "dart_library_provider_network.cc", - "dart_library_provider_network.h", - ] - - deps = [ - "//base", - "//build/config/sanitizers:deps", - "//dart/runtime:libdart", - "//mojo/common", - "//mojo/public/cpp/application", - "//mojo/services/network/public/interfaces", - "//sky/engine/tonic", - "//sky/engine/wtf", - "//url", - ] -} diff --git a/engine/src/flutter/shell/dart/dart_library_provider_files.cc b/engine/src/flutter/shell/dart/dart_library_provider_files.cc deleted file mode 100644 index 2bed8e8e9e..0000000000 --- a/engine/src/flutter/shell/dart/dart_library_provider_files.cc +++ /dev/null @@ -1,85 +0,0 @@ -// Copyright 2015 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. - -#include "sky/shell/dart/dart_library_provider_files.h" - -#include "base/bind.h" -#include "base/files/file_util.h" -#include "base/strings/string_util.h" -#include "base/threading/worker_pool.h" -#include "mojo/common/data_pipe_utils.h" -#include "sky/engine/tonic/dart_converter.h" - -namespace sky { -namespace shell { -namespace { - -void CopyComplete(base::FilePath file, bool success) { - if (!success) - LOG(ERROR) << "Failed to load " << file.AsUTF8Unsafe(); -} - -base::FilePath SimplifyPath(const base::FilePath& path) { - std::vector components; - path.GetComponents(&components); - auto it = components.begin(); - base::FilePath result(*it++); - for (; it != components.end(); it++) { - auto& component = *it; - if (component == base::FilePath::kCurrentDirectory) - continue; - if (component == base::FilePath::kParentDirectory) - result = result.DirName(); - else - result = result.Append(component); - } - return result; -} - -} // namespace - -DartLibraryProviderFiles::DartLibraryProviderFiles( - const base::FilePath& package_root) - : package_root_(package_root) { - CHECK(base::DirectoryExists(package_root_)) << "Invalid --package-root " - << "\"" << package_root_.LossyDisplayName() << "\""; -} - -DartLibraryProviderFiles::~DartLibraryProviderFiles() { -} - -void DartLibraryProviderFiles::GetLibraryAsStream( - const std::string& name, - blink::DataPipeConsumerCallback callback) { - mojo::DataPipe pipe; - callback.Run(pipe.consumer_handle.Pass()); - - base::FilePath source(name); - scoped_refptr runner = - base::WorkerPool::GetTaskRunner(true); - mojo::common::CopyFromFile(source, pipe.producer_handle.Pass(), 0, - runner.get(), base::Bind(&CopyComplete, source)); -} - -std::string DartLibraryProviderFiles::CanonicalizePackageURL(std::string url) { - DCHECK(StartsWithASCII(url, "package:", true)); - ReplaceFirstSubstringAfterOffset(&url, 0, "package:", ""); - return package_root_.Append(url).AsUTF8Unsafe(); -} - -Dart_Handle DartLibraryProviderFiles::CanonicalizeURL(Dart_Handle library, - Dart_Handle url) { - std::string string = blink::StdStringFromDart(url); - if (StartsWithASCII(string, "dart:", true)) - return url; - if (StartsWithASCII(string, "package:", true)) - return blink::StdStringToDart(CanonicalizePackageURL(string)); - base::FilePath base_path(blink::StdStringFromDart(Dart_LibraryUrl(library))); - base::FilePath resolved_path = base_path.DirName().Append(string); - base::FilePath normalized_path = SimplifyPath(resolved_path); - return blink::StdStringToDart(normalized_path.AsUTF8Unsafe()); -} - -} // namespace shell -} // namespace sky diff --git a/engine/src/flutter/shell/dart/dart_library_provider_files.h b/engine/src/flutter/shell/dart/dart_library_provider_files.h deleted file mode 100644 index b62751b9fa..0000000000 --- a/engine/src/flutter/shell/dart/dart_library_provider_files.h +++ /dev/null @@ -1,36 +0,0 @@ -// Copyright 2015 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. - -#ifndef SKY_SHELL_DART_DART_LIBRARY_PROVIDER_FILES_H_ -#define SKY_SHELL_DART_DART_LIBRARY_PROVIDER_FILES_H_ - -#include "base/files/file_path.h" -#include "sky/engine/tonic/dart_library_provider.h" - -namespace sky { -namespace shell { - -class DartLibraryProviderFiles : public blink::DartLibraryProvider { - public: - explicit DartLibraryProviderFiles(const base::FilePath& package_root); - ~DartLibraryProviderFiles() override; - - protected: - // |DartLibraryProvider| implementation: - void GetLibraryAsStream(const std::string& name, - blink::DataPipeConsumerCallback callback) override; - Dart_Handle CanonicalizeURL(Dart_Handle library, Dart_Handle url) override; - - private: - std::string CanonicalizePackageURL(std::string url); - - base::FilePath package_root_; - - DISALLOW_COPY_AND_ASSIGN(DartLibraryProviderFiles); -}; - -} // namespace shell -} // namespace sky - -#endif // SKY_SHELL_DART_DART_LIBRARY_PROVIDER_FILES_H_ diff --git a/engine/src/flutter/shell/dart/dart_library_provider_network.cc b/engine/src/flutter/shell/dart/dart_library_provider_network.cc deleted file mode 100644 index f91cac0b12..0000000000 --- a/engine/src/flutter/shell/dart/dart_library_provider_network.cc +++ /dev/null @@ -1,88 +0,0 @@ -// Copyright 2015 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. - -#include "sky/shell/dart/dart_library_provider_network.h" - -#include "base/bind.h" -#include "base/strings/string_util.h" -#include "sky/engine/tonic/dart_converter.h" -#include "url/gurl.h" - -namespace sky { -namespace shell { -namespace { - -mojo::URLLoaderPtr Fetch(mojo::NetworkService* network_service, - const std::string& url, - base::Callback callback) { - mojo::URLLoaderPtr loader; - network_service->CreateURLLoader(GetProxy(&loader)); - - mojo::URLRequestPtr request = mojo::URLRequest::New(); - request->url = url; - request->auto_follow_redirects = true; - loader->Start(request.Pass(), callback); - - return loader.Pass(); -} - -} // namespace - -class DartLibraryProviderNetwork::Job { - public: - Job(DartLibraryProviderNetwork* provider, - const std::string& name, - blink::DataPipeConsumerCallback callback) - : provider_(provider), callback_(callback), weak_factory_(this) { - url_loader_ = - Fetch(provider_->network_service(), name, - base::Bind(&Job::OnReceivedResponse, weak_factory_.GetWeakPtr())); - } - - private: - void OnReceivedResponse(mojo::URLResponsePtr response) { - mojo::ScopedDataPipeConsumerHandle data; - if (response->status_code == 200) - data = response->body.Pass(); - callback_.Run(data.Pass()); - provider_->jobs_.remove(this); - // We're deleted now. - } - - DartLibraryProviderNetwork* provider_; - blink::DataPipeConsumerCallback callback_; - mojo::URLLoaderPtr url_loader_; - - base::WeakPtrFactory weak_factory_; -}; - -DartLibraryProviderNetwork::DartLibraryProviderNetwork( - mojo::NetworkService* network_service) - : network_service_(network_service) { -} - -DartLibraryProviderNetwork::~DartLibraryProviderNetwork() { -} - -void DartLibraryProviderNetwork::GetLibraryAsStream( - const std::string& name, - blink::DataPipeConsumerCallback callback) { - jobs_.add(adoptPtr(new Job(this, name, callback))); -} - -Dart_Handle DartLibraryProviderNetwork::CanonicalizeURL(Dart_Handle library, - Dart_Handle url) { - std::string string = blink::StdStringFromDart(url); - if (StartsWithASCII(string, "dart:", true)) - return url; - // TODO(abarth): The package root should be configurable. - if (StartsWithASCII(string, "package:", true)) - ReplaceFirstSubstringAfterOffset(&string, 0, "package:", "/packages/"); - GURL library_url(blink::StdStringFromDart(Dart_LibraryUrl(library))); - GURL resolved_url = library_url.Resolve(string); - return blink::StdStringToDart(resolved_url.spec()); -} - -} // namespace shell -} // namespace sky diff --git a/engine/src/flutter/shell/dart/dart_library_provider_network.h b/engine/src/flutter/shell/dart/dart_library_provider_network.h deleted file mode 100644 index e68a259db8..0000000000 --- a/engine/src/flutter/shell/dart/dart_library_provider_network.h +++ /dev/null @@ -1,41 +0,0 @@ -// Copyright 2015 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. - -#ifndef SKY_SHELL_DART_DART_LIBRARY_PROVIDER_NETWORK_H_ -#define SKY_SHELL_DART_DART_LIBRARY_PROVIDER_NETWORK_H_ - -#include "mojo/services/network/public/interfaces/network_service.mojom.h" -#include "sky/engine/tonic/dart_library_provider.h" -#include "sky/engine/wtf/HashSet.h" -#include "sky/engine/wtf/OwnPtr.h" - -namespace sky { -namespace shell { - -class DartLibraryProviderNetwork : public blink::DartLibraryProvider { - public: - explicit DartLibraryProviderNetwork(mojo::NetworkService* network_service); - ~DartLibraryProviderNetwork() override; - - mojo::NetworkService* network_service() const { return network_service_; } - - protected: - // |DartLibraryProvider| implementation: - void GetLibraryAsStream(const std::string& name, - blink::DataPipeConsumerCallback callback) override; - Dart_Handle CanonicalizeURL(Dart_Handle library, Dart_Handle url) override; - - private: - class Job; - - mojo::NetworkService* network_service_; - HashSet> jobs_; - - DISALLOW_COPY_AND_ASSIGN(DartLibraryProviderNetwork); -}; - -} // namespace shell -} // namespace sky - -#endif // SKY_SHELL_DART_DART_LIBRARY_PROVIDER_NETWORK_H_ diff --git a/engine/src/flutter/shell/gpu/ganesh_context.cc b/engine/src/flutter/shell/gpu/ganesh_context.cc deleted file mode 100644 index bd3bac33b0..0000000000 --- a/engine/src/flutter/shell/gpu/ganesh_context.cc +++ /dev/null @@ -1,43 +0,0 @@ -// Copyright 2015 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. - -#include "sky/shell/gpu/ganesh_context.h" - -#include "base/logging.h" -#include "third_party/skia/include/gpu/gl/GrGLInterface.h" -#include "ui/gl/gl_bindings_skia_in_process.h" - -namespace sky { -namespace shell { -namespace { - -// The limit of the number of GPU resources we hold in the GrContext's -// GPU cache. -const int kMaxGaneshResourceCacheCount = 2048; - -// The limit of the bytes allocated toward GPU resources in the GrContext's -// GPU cache. -const size_t kMaxGaneshResourceCacheBytes = 96 * 1024 * 1024; - -} // namespace - -GaneshContext::GaneshContext(scoped_refptr gl_context) - : gl_context_(gl_context) { - skia::RefPtr interface = - skia::AdoptRef(gfx::CreateInProcessSkiaGLBinding()); - DCHECK(interface); - - gr_context_ = skia::AdoptRef(GrContext::Create( - kOpenGL_GrBackend, reinterpret_cast(interface.get()))); - DCHECK(gr_context_) << "Failed to create GrContext."; - gr_context_->setResourceCacheLimits(kMaxGaneshResourceCacheCount, - kMaxGaneshResourceCacheBytes); -} - -GaneshContext::~GaneshContext() { - gr_context_->abandonContext(); -} - -} // namespace shell -} // namespace sky diff --git a/engine/src/flutter/shell/gpu/ganesh_context.h b/engine/src/flutter/shell/gpu/ganesh_context.h deleted file mode 100644 index b35158ed3e..0000000000 --- a/engine/src/flutter/shell/gpu/ganesh_context.h +++ /dev/null @@ -1,37 +0,0 @@ -// Copyright 2015 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. - -#ifndef SKY_SHELL_GPU_GANESH_CONTEXT_H_ -#define SKY_SHELL_GPU_GANESH_CONTEXT_H_ - -#include "base/basictypes.h" -#include "base/memory/ref_counted.h" -#include "skia/ext/refptr.h" -#include "third_party/skia/include/gpu/GrContext.h" -#include "ui/gl/gl_context.h" - -namespace sky { -namespace shell { - -// GaneshContext holds the top-level context object for Ganesh (known as -// GrContext). We construct the GrContext using the OpenGL interface provided by -// gfx::GLContext. -class GaneshContext { - public: - explicit GaneshContext(scoped_refptr gl_context); - ~GaneshContext(); - - GrContext* gr() const { return gr_context_.get(); } - - private: - scoped_refptr gl_context_; - skia::RefPtr gr_context_; - - DISALLOW_COPY_AND_ASSIGN(GaneshContext); -}; - -} // namespace shell -} // namespace sky - -#endif // SKY_SHELL_GPU_GANESH_CONTEXT_H_ diff --git a/engine/src/flutter/shell/gpu/ganesh_surface.cc b/engine/src/flutter/shell/gpu/ganesh_surface.cc deleted file mode 100644 index bc175aeb50..0000000000 --- a/engine/src/flutter/shell/gpu/ganesh_surface.cc +++ /dev/null @@ -1,34 +0,0 @@ -// Copyright 2015 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. - -#include "sky/shell/gpu/ganesh_surface.h" - -#include "base/logging.h" -#include "third_party/skia/include/gpu/GrContext.h" - -namespace sky { -namespace shell { - -GaneshSurface::GaneshSurface(intptr_t window_fbo, - GaneshContext* context, - const gfx::Size& size) { - GrBackendRenderTargetDesc desc; - desc.fWidth = size.width(); - desc.fHeight = size.height(); - desc.fConfig = kSkia8888_GrPixelConfig; - desc.fOrigin = kBottomLeft_GrSurfaceOrigin; - desc.fRenderTargetHandle = window_fbo; - - auto target = skia::AdoptRef( - context->gr()->textureProvider()->wrapBackendRenderTarget(desc)); - DCHECK(target); - surface_ = skia::AdoptRef(SkSurface::NewRenderTargetDirect(target.get())); - DCHECK(surface_); -} - -GaneshSurface::~GaneshSurface() { -} - -} // namespace shell -} // namespace sky diff --git a/engine/src/flutter/shell/gpu/ganesh_surface.h b/engine/src/flutter/shell/gpu/ganesh_surface.h deleted file mode 100644 index bceaad55d5..0000000000 --- a/engine/src/flutter/shell/gpu/ganesh_surface.h +++ /dev/null @@ -1,41 +0,0 @@ -// Copyright 2015 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. - -#ifndef SKY_SHELL_GPU_GANESH_SURFACE_H_ -#define SKY_SHELL_GPU_GANESH_SURFACE_H_ - -#include "base/memory/scoped_ptr.h" -#include "skia/ext/refptr.h" -#include "sky/shell/gpu/ganesh_context.h" -#include "third_party/skia/include/core/SkSurface.h" -#include "ui/gfx/geometry/size.h" - -namespace sky { -namespace shell { - -// GaneshSurface holds an SkSurface configured to render with Ganesh. Using the -// provided GaneshContext, GaneshSurface wraps an SkSurface around the window -// bound FBO so that you can use |canvas()| to draw to that window bound FBO. -class GaneshSurface { - public: - GaneshSurface(intptr_t window_fbo, - GaneshContext* context, - const gfx::Size& size); - ~GaneshSurface(); - - SkCanvas* canvas() const { return surface_->getCanvas(); } - gfx::Size size() const { - return gfx::Size(surface_->width(), surface_->height()); - } - - private: - skia::RefPtr surface_; - - DISALLOW_COPY_AND_ASSIGN(GaneshSurface); -}; - -} // namespace shell -} // namespace sky - -#endif // SKY_SHELL_GPU_GANESH_SURFACE_H_ diff --git a/engine/src/flutter/shell/gpu/picture_serializer.cc b/engine/src/flutter/shell/gpu/picture_serializer.cc deleted file mode 100644 index 22ea6551da..0000000000 --- a/engine/src/flutter/shell/gpu/picture_serializer.cc +++ /dev/null @@ -1,36 +0,0 @@ -// Copyright 2015 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. - -#include "sky/shell/gpu/picture_serializer.h" - -#include "third_party/skia/include/core/SkData.h" -#include "third_party/skia/include/core/SkPixelSerializer.h" -#include "third_party/skia/include/core/SkStream.h" -#include "ui/gfx/codec/png_codec.h" - -namespace sky { - -class PngPixelSerializer : public SkPixelSerializer { - public: - bool onUseEncodedData(const void*, size_t) override { return true; } - SkData* onEncodePixels(const SkImageInfo& info, const void* pixels, - size_t row_bytes) override { - std::vector data; - - SkBitmap bm; - if (!bm.installPixels(info, const_cast(pixels), row_bytes)) - return nullptr; - if (!gfx::PNGCodec::EncodeBGRASkBitmap(bm, false, &data)) - return nullptr; - return SkData::NewWithCopy(&data.front(), data.size()); - } -}; - -void SerializePicture(const char* file_name, SkPicture* picture) { - SkFILEWStream stream(file_name); - PngPixelSerializer serializer; - picture->serialize(&stream, &serializer); -} - -} // namespace sky diff --git a/engine/src/flutter/shell/gpu/picture_serializer.h b/engine/src/flutter/shell/gpu/picture_serializer.h deleted file mode 100644 index f4300382ca..0000000000 --- a/engine/src/flutter/shell/gpu/picture_serializer.h +++ /dev/null @@ -1,16 +0,0 @@ -// Copyright 2015 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. - -#ifndef SKY_SHELL_GPU_PICTURE_SERIALIZER_H_ -#define SKY_SHELL_GPU_PICTURE_SERIALIZER_H_ - -#include "third_party/skia/include/core/SkPicture.h" - -namespace sky { - -void SerializePicture(const char* file_name, SkPicture*); - -} // namespace sky - -#endif // SKY_SHELL_GPU_PICTURE_SERIALIZER_H_ diff --git a/engine/src/flutter/shell/gpu/rasterizer.cc b/engine/src/flutter/shell/gpu/rasterizer.cc deleted file mode 100644 index f679b8f813..0000000000 --- a/engine/src/flutter/shell/gpu/rasterizer.cc +++ /dev/null @@ -1,99 +0,0 @@ -// Copyright 2015 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. - -#include "sky/shell/gpu/rasterizer.h" - -#include "base/trace_event/trace_event.h" -#include "sky/shell/gpu/ganesh_context.h" -#include "sky/shell/gpu/ganesh_surface.h" -#include "sky/shell/gpu/picture_serializer.h" -#include "third_party/skia/include/core/SkCanvas.h" -#include "third_party/skia/include/core/SkPicture.h" -#include "ui/gl/gl_bindings.h" -#include "ui/gl/gl_context.h" -#include "ui/gl/gl_share_group.h" -#include "ui/gl/gl_surface.h" - -namespace sky { -namespace shell { -namespace { - -gfx::Size GetSize(SkPicture* picture) { - const SkRect& rect = picture->cullRect(); - return gfx::Size(rect.width(), rect.height()); -} - -} // namespace - -Rasterizer::Rasterizer() - : share_group_(new gfx::GLShareGroup()), weak_factory_(this) { -} - -Rasterizer::~Rasterizer() { -} - -base::WeakPtr Rasterizer::GetWeakPtr() { - return weak_factory_.GetWeakPtr(); -} - -void Rasterizer::OnAcceleratedWidgetAvailable(gfx::AcceleratedWidget widget) { - surface_ = gfx::GLSurface::CreateViewGLSurface(widget, - gfx::SurfaceConfiguration()); - CHECK(surface_) << "GLSurface required."; -} - -void Rasterizer::Draw(skia::RefPtr picture) { - TRACE_EVENT0("sky", "Rasterizer::Draw"); - - if (!surface_) - return; - - gfx::Size size = GetSize(picture.get()); - if (size.IsEmpty()) - return; - - EnsureGLContext(); - CHECK(context_->MakeCurrent(surface_.get())); - EnsureGaneshSurface(surface_->GetBackingFrameBufferObject(), size); - - DrawPicture(picture.get()); - surface_->SwapBuffers(); - - // SerializePicture("/data/data/org.domokit.sky.demo/cache/layer0.skp", picture.get()); -} - -void Rasterizer::DrawPicture(SkPicture* picture) { - TRACE_EVENT0("sky", "Rasterizer::DrawPicture"); - SkCanvas* canvas = ganesh_surface_->canvas(); - canvas->drawPicture(picture); - canvas->flush(); -} - -void Rasterizer::OnOutputSurfaceDestroyed() { - CHECK(context_->MakeCurrent(surface_.get())); - ganesh_surface_.reset(); - ganesh_context_.reset(); - context_ = nullptr; - surface_ = nullptr; -} - -void Rasterizer::EnsureGLContext() { - if (context_) - return; - context_ = gfx::GLContext::CreateGLContext(share_group_.get(), surface_.get(), - gfx::PreferIntegratedGpu); - CHECK(context_) << "GLContext required."; - CHECK(context_->MakeCurrent(surface_.get())); - ganesh_context_.reset(new GaneshContext(context_.get())); -} - -void Rasterizer::EnsureGaneshSurface(intptr_t window_fbo, - const gfx::Size& size) { - if (!ganesh_surface_ || ganesh_surface_->size() != size) - ganesh_surface_.reset( - new GaneshSurface(window_fbo, ganesh_context_.get(), size)); -} - -} // namespace shell -} // namespace sky diff --git a/engine/src/flutter/shell/gpu/rasterizer.h b/engine/src/flutter/shell/gpu/rasterizer.h deleted file mode 100644 index a0aec6e6e4..0000000000 --- a/engine/src/flutter/shell/gpu/rasterizer.h +++ /dev/null @@ -1,59 +0,0 @@ -// Copyright 2015 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. - -#ifndef SKY_SHELL_GPU_RASTERIZER_H_ -#define SKY_SHELL_GPU_RASTERIZER_H_ - -#include "base/memory/ref_counted.h" -#include "base/memory/weak_ptr.h" -#include "skia/ext/refptr.h" -#include "sky/shell/gpu_delegate.h" -#include "ui/gfx/geometry/size.h" -#include "ui/gfx/native_widget_types.h" - -class SkPicture; - -namespace gfx { -class GLContext; -class GLShareGroup; -class GLSurface; -} - -namespace sky { -namespace shell { -class GaneshContext; -class GaneshSurface; - -class Rasterizer : public GPUDelegate { - public: - explicit Rasterizer(); - ~Rasterizer() override; - - base::WeakPtr GetWeakPtr(); - - void OnAcceleratedWidgetAvailable(gfx::AcceleratedWidget widget) override; - void OnOutputSurfaceDestroyed() override; - void Draw(skia::RefPtr picture) override; - - private: - void EnsureGLContext(); - void EnsureGaneshSurface(intptr_t window_fbo, const gfx::Size& size); - void DrawPicture(SkPicture* picture); - - scoped_refptr share_group_; - scoped_refptr surface_; - scoped_refptr context_; - - scoped_ptr ganesh_context_; - scoped_ptr ganesh_surface_; - - base::WeakPtrFactory weak_factory_; - - DISALLOW_COPY_AND_ASSIGN(Rasterizer); -}; - -} // namespace shell -} // namespace sky - -#endif // SKY_SHELL_GPU_RASTERIZER_H_ diff --git a/engine/src/flutter/shell/gpu_delegate.cc b/engine/src/flutter/shell/gpu_delegate.cc deleted file mode 100644 index 62fe84c40b..0000000000 --- a/engine/src/flutter/shell/gpu_delegate.cc +++ /dev/null @@ -1,14 +0,0 @@ -// Copyright 2015 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. - -#include "sky/shell/gpu_delegate.h" - -namespace sky { -namespace shell { - -GPUDelegate::~GPUDelegate() { -} - -} // namespace shell -} // namespace sky diff --git a/engine/src/flutter/shell/gpu_delegate.h b/engine/src/flutter/shell/gpu_delegate.h deleted file mode 100644 index 00040c5223..0000000000 --- a/engine/src/flutter/shell/gpu_delegate.h +++ /dev/null @@ -1,29 +0,0 @@ -// Copyright 2015 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. - -#ifndef SKY_SHELL_GPU_DELEGATE_H_ -#define SKY_SHELL_GPU_DELEGATE_H_ - -#include "skia/ext/refptr.h" -#include "ui/gfx/native_widget_types.h" - -class SkPicture; - -namespace sky { -namespace shell { - -class GPUDelegate { - public: - virtual void OnAcceleratedWidgetAvailable(gfx::AcceleratedWidget widget) = 0; - virtual void OnOutputSurfaceDestroyed() = 0; - virtual void Draw(skia::RefPtr picture) = 0; - - protected: - virtual ~GPUDelegate(); -}; - -} // namespace shell -} // namespace sky - -#endif // SKY_SHELL_GPU_DELEGATE_H_ diff --git a/engine/src/flutter/shell/ios/.gitignore b/engine/src/flutter/shell/ios/.gitignore deleted file mode 100644 index 01a36b1b70..0000000000 --- a/engine/src/flutter/shell/ios/.gitignore +++ /dev/null @@ -1,3 +0,0 @@ -*.pbxproj -*.xcworkspace -*.xcodeproj diff --git a/engine/src/flutter/shell/ios/Entitlements.xcent b/engine/src/flutter/shell/ios/Entitlements.xcent deleted file mode 100644 index 8030fd5136..0000000000 --- a/engine/src/flutter/shell/ios/Entitlements.xcent +++ /dev/null @@ -1,16 +0,0 @@ - - - - - application-identifier - F5T262WGN6.com.google.sky - com.apple.developer.team-identifier - F5T262WGN6 - get-task-allow - - keychain-access-groups - - F5T262WGN6.com.google.sky - - - diff --git a/engine/src/flutter/shell/ios/Info.plist b/engine/src/flutter/shell/ios/Info.plist deleted file mode 100644 index b0cf795945..0000000000 --- a/engine/src/flutter/shell/ios/Info.plist +++ /dev/null @@ -1,82 +0,0 @@ - - - - - CFBundleDevelopmentRegion - en - - - CFBundleExecutable - Sky - - CFBundleIdentifier - com.google.sky - - CFBundleInfoDictionaryVersion - 6.0 - CFBundleName - Sky - CFBundlePackageType - APPL - CFBundleShortVersionString - 1.0 - CFBundleVersion - 1 - LSRequiresIPhoneOS - - UIRequiredDeviceCapabilities - - armv7 - - - - CFBundleURLTypes - - - CFBundleTypeRole - Viewer - CFBundleURLName - com.google.mojo - CFBundleURLSchemes - - mojo - - - - - - com.google.sky.load_url - https://domokit.github.io/home.dart - - - DTPlatformName - iphonesimulator - DTSDKName - iphonesimulator8.3 - LSRequiresIPhoneOS - - MinimumOSVersion - 8.3 - UIDeviceFamily - - 1 - 2 - - CFBundleSupportedPlatforms - - iPhoneSimulator - - - diff --git a/engine/src/flutter/shell/ios/main_ios.mm b/engine/src/flutter/shell/ios/main_ios.mm deleted file mode 100644 index b0eb2042a8..0000000000 --- a/engine/src/flutter/shell/ios/main_ios.mm +++ /dev/null @@ -1,70 +0,0 @@ -// Copyright 2015 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 -#include -#import "sky_app_delegate.h" -#include "base/at_exit.h" -#include "base/logging.h" -#include "base/i18n/icu_util.h" -#include "base/command_line.h" -#include "base/mac/scoped_nsautorelease_pool.h" -#include "ui/gl/gl_surface.h" - -extern "C" { -// TODO(csg): HACK! boringssl accesses this on Android using a weak symbol -// instead of a global. Till the patch for that lands and propagates to Sky, we -// specify the same here to get workable builds on iOS. This is a hack! Will -// go away. -unsigned long getauxval(unsigned long type) { - return 0; -} -} - -static void InitializeLogging() { - logging::LoggingSettings settings; - settings.logging_dest = logging::LOG_TO_SYSTEM_DEBUG_LOG; - logging::InitLogging(settings); - logging::SetLogItems(false, // Process ID - false, // Thread ID - false, // Timestamp - false); // Tick count -} - -static void RedirectIOConnectionsToSyslog() { - asl_log_descriptor(NULL, NULL, ASL_LEVEL_INFO, STDOUT_FILENO, - ASL_LOG_DESCRIPTOR_WRITE); - asl_log_descriptor(NULL, NULL, ASL_LEVEL_NOTICE, STDERR_FILENO, - ASL_LOG_DESCRIPTOR_WRITE); -} - -#ifndef NDEBUG - -static void SkyDebuggerHookMain(void) { - // By default, LLDB breaks way too early. This is before libraries have been - // loaded and __attribute__((constructor)) methods have been called. In most - // situations, this is unnecessary. Also, breakpoint resolution is not - // immediate. So we provide this hook to break on. -} - -#endif - -int main(int argc, char* argv[]) { -#ifndef NDEBUG - SkyDebuggerHookMain(); -#endif - base::mac::ScopedNSAutoreleasePool pool; - base::AtExitManager exit_manager; - RedirectIOConnectionsToSyslog(); - auto result = false; - result = base::CommandLine::Init(0, nullptr); - DLOG_ASSERT(result); - InitializeLogging(); - result = base::i18n::InitializeICU(); - DLOG_ASSERT(result); - result = gfx::GLSurface::InitializeOneOff(); - DLOG_ASSERT(result); - return UIApplicationMain(argc, argv, nil, - NSStringFromClass([SkyAppDelegate class])); -} diff --git a/engine/src/flutter/shell/ios/platform_service_provider_ios.cc b/engine/src/flutter/shell/ios/platform_service_provider_ios.cc deleted file mode 100644 index 55b32de803..0000000000 --- a/engine/src/flutter/shell/ios/platform_service_provider_ios.cc +++ /dev/null @@ -1,44 +0,0 @@ -// Copyright 2015 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. - -#include "sky/engine/wtf/Assertions.h" -#include "sky/shell/service_provider.h" -#include "base/single_thread_task_runner.h" -#include "base/bind.h" -#include "base/bind_helpers.h" -#include "base/lazy_instance.h" -#include "base/location.h" -#include "mojo/public/cpp/application/service_provider_impl.h" -#include "sky/services/ns_net/network_service_impl.h" - -namespace sky { -namespace shell { - -// FIXME(csg): Put this in an application owned context -base::LazyInstance> g_service_provider = - LAZY_INSTANCE_INITIALIZER; -base::LazyInstance> - g_network_service_factory = LAZY_INSTANCE_INITIALIZER; - -static void CreatePlatformServiceProvider( - mojo::InterfaceRequest request) { - g_service_provider.Get().reset(new mojo::ServiceProviderImpl(request.Pass())); - g_network_service_factory.Get().reset(new mojo::NetworkServiceFactory()); - g_service_provider.Get()->AddService(g_network_service_factory.Get().get()); -} - -mojo::ServiceProviderPtr CreateServiceProvider( - ServiceProviderContext* context) { - DCHECK(context); - mojo::MessagePipe pipe; - auto request = mojo::MakeRequest(pipe.handle1.Pass()); - context->platform_task_runner->PostTask( - FROM_HERE, - base::Bind(CreatePlatformServiceProvider, base::Passed(request.Pass()))); - return mojo::MakeProxy( - mojo::InterfacePtrInfo(pipe.handle0.Pass(), 0u)); -} - -} // namespace shell -} // namespace sky diff --git a/engine/src/flutter/shell/ios/platform_view_ios.h b/engine/src/flutter/shell/ios/platform_view_ios.h deleted file mode 100644 index a9e1ef6ffc..0000000000 --- a/engine/src/flutter/shell/ios/platform_view_ios.h +++ /dev/null @@ -1,27 +0,0 @@ -// Copyright 2015 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. - -#ifndef SKY_SHELL_PLATFORM_VIEW_IOS_H_ -#define SKY_SHELL_PLATFORM_VIEW_IOS_H_ - -#include "sky/shell/platform_view.h" - -namespace sky { -namespace shell { - -class PlatformViewIOS : public PlatformView { - public: - explicit PlatformViewIOS(const Config& config); - ~PlatformViewIOS() override; - void SurfaceCreated(gfx::AcceleratedWidget widget); - void SurfaceDestroyed(void); - - private: - DISALLOW_COPY_AND_ASSIGN(PlatformViewIOS); -}; - -} // namespace shell -} // namespace sky - -#endif // SKY_SHELL_PLATFORM_VIEW_IOS_H_ diff --git a/engine/src/flutter/shell/ios/platform_view_ios.mm b/engine/src/flutter/shell/ios/platform_view_ios.mm deleted file mode 100644 index 3c5f90d160..0000000000 --- a/engine/src/flutter/shell/ios/platform_view_ios.mm +++ /dev/null @@ -1,34 +0,0 @@ -// Copyright 2015 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. - -#include "platform_view_ios.h" - -namespace sky { -namespace shell { - -PlatformView* PlatformView::Create(const Config& config) { - return new PlatformViewIOS(config); -} - -PlatformViewIOS::PlatformViewIOS(const Config& config) - : PlatformView(config) { -} - -PlatformViewIOS::~PlatformViewIOS() { -} - -void PlatformViewIOS::SurfaceCreated(gfx::AcceleratedWidget widget) { - DCHECK(window_ == 0); - window_ = widget; - SurfaceWasCreated(); -} - -void PlatformViewIOS::SurfaceDestroyed() { - DCHECK(window_); - window_ = 0; - SurfaceWasDestroyed(); -} - -} // namespace shell -} // namespace sky diff --git a/engine/src/flutter/shell/ios/sky_app_delegate.h b/engine/src/flutter/shell/ios/sky_app_delegate.h deleted file mode 100644 index 9103726971..0000000000 --- a/engine/src/flutter/shell/ios/sky_app_delegate.h +++ /dev/null @@ -1,11 +0,0 @@ -// Copyright 2015 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 - -@interface SkyAppDelegate : UIResponder - -@property(strong, nonatomic) UIWindow* window; - -@end diff --git a/engine/src/flutter/shell/ios/sky_app_delegate.mm b/engine/src/flutter/shell/ios/sky_app_delegate.mm deleted file mode 100644 index ff7449daaa..0000000000 --- a/engine/src/flutter/shell/ios/sky_app_delegate.mm +++ /dev/null @@ -1,53 +0,0 @@ -// Copyright 2015 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 "sky_app_delegate.h" -#import "sky_view_controller.h" - -#include "sky/shell/shell.h" -#include "sky/shell/service_provider.h" -#include "sky/shell/ui_delegate.h" -#include "base/lazy_instance.h" -#include "base/message_loop/message_loop.h" - -@implementation SkyAppDelegate { - base::LazyInstance> _main_message_loop; -} - -- (BOOL)application:(UIApplication*)application - didFinishLaunchingWithOptions:(NSDictionary*)launchOptions { - [self setupSkyShell]; - [self setupViewport]; - - return YES; -} - -- (void)setupSkyShell { - [self adoptPlatformRunLoop]; - - auto service_provider_context = - make_scoped_ptr(new sky::shell::ServiceProviderContext( - _main_message_loop.Get()->task_runner())); - sky::shell::Shell::Init(service_provider_context.Pass()); -} - -- (void)adoptPlatformRunLoop { - _main_message_loop.Get().reset(new base::MessageLoopForUI); - // One cannot start the message loop on the platform main thread. Instead, - // we attach to the CFRunLoop - base::MessageLoopForUI::current()->Attach(); -} - -- (void)setupViewport { - CGRect frame = [UIScreen mainScreen].bounds; - UIWindow* window = [[UIWindow alloc] initWithFrame:frame]; - SkyViewController* viewController = [[SkyViewController alloc] init]; - window.rootViewController = viewController; - [viewController release]; - self.window = window; - [window release]; - [self.window makeKeyAndVisible]; -} - -@end diff --git a/engine/src/flutter/shell/ios/sky_surface.h b/engine/src/flutter/shell/ios/sky_surface.h deleted file mode 100644 index fea4f12fca..0000000000 --- a/engine/src/flutter/shell/ios/sky_surface.h +++ /dev/null @@ -1,12 +0,0 @@ -// Copyright 2015 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 -#import "sky/shell/shell_view.h" - -@interface SkySurface : UIView - --(instancetype) initWithShellView:(sky::shell::ShellView *) shellView; - -@end diff --git a/engine/src/flutter/shell/ios/sky_surface.mm b/engine/src/flutter/shell/ios/sky_surface.mm deleted file mode 100644 index 1cb1fe0d54..0000000000 --- a/engine/src/flutter/shell/ios/sky_surface.mm +++ /dev/null @@ -1,298 +0,0 @@ -// Copyright 2015 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 "sky_surface.h" - -#import -#import -#import - -#include "base/time/time.h" -#include "mojo/public/cpp/bindings/interface_request.h" -#include "sky/services/engine/input_event.mojom.h" -#include "sky/shell/ios/platform_view_ios.h" -#include "sky/shell/shell_view.h" -#include "sky/shell/shell.h" -#include "sky/shell/ui_delegate.h" - -static inline sky::EventType EventTypeFromUITouchPhase(UITouchPhase phase) { - switch (phase) { - case UITouchPhaseBegan: - return sky::EVENT_TYPE_POINTER_DOWN; - case UITouchPhaseMoved: - case UITouchPhaseStationary: - // There is no EVENT_TYPE_POINTER_STATIONARY. So we just pass a move type - // with the same coordinates - return sky::EVENT_TYPE_POINTER_MOVE; - case UITouchPhaseEnded: - return sky::EVENT_TYPE_POINTER_UP; - case UITouchPhaseCancelled: - return sky::EVENT_TYPE_POINTER_CANCEL; - } - - return sky::EVENT_TYPE_UNKNOWN; -} - -static inline int64 InputEventTimestampFromNSTimeInterval( - NSTimeInterval interval) { - return base::TimeDelta::FromSecondsD(interval).InMilliseconds(); -} - -static sky::InputEventPtr BasicInputEventFromRecognizer( - sky::EventType type, - UIGestureRecognizer* recognizer) { - auto input = sky::InputEvent::New(); - input->type = type; - input->time_stamp = InputEventTimestampFromNSTimeInterval( - CACurrentMediaTime()); - - input->gesture_data = sky::GestureData::New(); - - CGPoint windowCoordinates = [recognizer locationInView:recognizer.view]; - const CGFloat scale = [UIScreen mainScreen].scale; - input->gesture_data->x = windowCoordinates.x * scale; - input->gesture_data->y = windowCoordinates.y * scale; - return input.Pass(); -} - -@implementation SkySurface { - BOOL _platformViewInitialized; - - sky::SkyEnginePtr _sky_engine; - scoped_ptr _shell_view; -} - --(instancetype) initWithShellView:(sky::shell::ShellView *) shellView { - self = [super init]; - if (self) { - _shell_view.reset(shellView); - [self installGestureRecognizers]; - } - return self; -} - -- (gfx::AcceleratedWidget)acceleratedWidget { - return (gfx::AcceleratedWidget)self.layer; -} - -- (void)layoutSubviews { - [super layoutSubviews]; - - [self configureLayerDefaults]; - - [self setupPlatformViewIfNecessary]; - - CGSize size = self.bounds.size; - CGFloat scale = [UIScreen mainScreen].scale; - - sky::ViewportMetricsPtr metrics = sky::ViewportMetrics::New(); - metrics->physical_width = size.width * scale; - metrics->physical_height = size.height * scale; - metrics->device_pixel_ratio = scale; - _sky_engine->OnViewportMetricsChanged(metrics.Pass()); -} - -- (void)configureLayerDefaults { - CAEAGLLayer* layer = reinterpret_cast(self.layer); - layer.allowsGroupOpacity = YES; - layer.opaque = YES; - CGFloat screenScale = [UIScreen mainScreen].scale; - layer.contentsScale = screenScale; - // Note: shouldRasterize is still NO. This is just a defensive measure - layer.rasterizationScale = screenScale; -} - -- (void)setupPlatformViewIfNecessary { - if (_platformViewInitialized) { - return; - } - - _platformViewInitialized = YES; - - [self notifySurfaceCreation]; - [self connectToEngineAndLoad]; -} - -- (sky::shell::PlatformViewIOS*)platformView { - auto view = static_cast(_shell_view->view()); - DCHECK(view); - return view; -} - -- (void)notifySurfaceCreation { - self.platformView->SurfaceCreated(self.acceleratedWidget); -} - -- (NSString*)skyInitialLoadURL { - return [NSBundle mainBundle].infoDictionary[@"com.google.sky.load_url"]; -} - -- (void)connectToEngineAndLoad { - auto interface_request = mojo::GetProxy(&_sky_engine); - self.platformView->ConnectToEngine(interface_request.Pass()); - - mojo::String string(self.skyInitialLoadURL.UTF8String); - _sky_engine->RunFromNetwork(string); -} - -- (void)notifySurfaceDestruction { - self.platformView->SurfaceDestroyed(); -} - -#pragma mark - UIResponder overrides for raw touches - -- (void)dispatchTouches:(NSSet*)touches phase:(UITouchPhase)phase { - auto eventType = EventTypeFromUITouchPhase(phase); - const CGFloat scale = [UIScreen mainScreen].scale; - - for (UITouch* touch in touches) { - auto input = sky::InputEvent::New(); - input->type = eventType; - input->time_stamp = InputEventTimestampFromNSTimeInterval(touch.timestamp); - - input->pointer_data = sky::PointerData::New(); - input->pointer_data->kind = sky::POINTER_KIND_TOUCH; - - CGPoint windowCoordinates = [touch locationInView:nil]; - - input->pointer_data->x = windowCoordinates.x * scale; - input->pointer_data->y = windowCoordinates.y * scale; - - _sky_engine->OnInputEvent(input.Pass()); - } -} - -- (void)touchesBegan:(NSSet*)touches withEvent:(UIEvent*)event { - [self dispatchTouches:touches phase:UITouchPhaseBegan]; -} - -- (void)touchesMoved:(NSSet*)touches withEvent:(UIEvent*)event { - [self dispatchTouches:touches phase:UITouchPhaseMoved]; -} - -- (void)touchesEnded:(NSSet*)touches withEvent:(UIEvent*)event { - [self dispatchTouches:touches phase:UITouchPhaseEnded]; -} - -- (void)touchesCancelled:(NSSet*)touches withEvent:(UIEvent*)event { - [self dispatchTouches:touches phase:UITouchPhaseCancelled]; -} - -#pragma mark - Gesture Recognizers - --(void) installGestureRecognizers { - // For: - // GESTURE_FLING_CANCEL - // GESTURE_FLING_START - UISwipeGestureRecognizer *swipe = [[UISwipeGestureRecognizer alloc] - initWithTarget:self action:@selector(onFling:)]; - [self addGestureRecognizer: swipe]; - [swipe release]; - - // For: - // GESTURE_LONG_PRESS - // GESTURE_SHOW_PRESS - UILongPressGestureRecognizer *longPress = - [[UILongPressGestureRecognizer alloc] - initWithTarget:self action:@selector(onLongPress:)]; - [self addGestureRecognizer: longPress]; - [longPress release]; - - // For: - // GESTURE_SCROLL_BEGIN - // GESTURE_SCROLL_END - // GESTURE_SCROLL_UPDATE - UIPanGestureRecognizer *pan = [[UIPanGestureRecognizer alloc] - initWithTarget:self action:@selector(onScroll:)]; - [self addGestureRecognizer: pan]; - [pan release]; - - // For: - // GESTURE_TAP - // GESTURE_TAP_DOWN - UITapGestureRecognizer *tap = [[UITapGestureRecognizer alloc] - initWithTarget:self action:@selector(onTap:)]; - [self addGestureRecognizer: tap]; - [tap release]; -} - --(void) onFling:(UISwipeGestureRecognizer *) recognizer { - // Swipes are discrete gestures already. So there is no equivalent to a cancel - if (recognizer.state != UIGestureRecognizerStateEnded) { - return; - } - - auto input = BasicInputEventFromRecognizer( - sky::EVENT_TYPE_GESTURE_FLING_START, recognizer); - _sky_engine->OnInputEvent(input.Pass()); -} - --(void) onLongPress:(UILongPressGestureRecognizer *) recognizer { - if (recognizer.state != UIGestureRecognizerStateEnded) { - return; - } - - auto input = BasicInputEventFromRecognizer(sky::EVENT_TYPE_GESTURE_LONG_PRESS, - recognizer); - _sky_engine->OnInputEvent(input.Pass()); -} - --(void) onScroll:(UIPanGestureRecognizer *) recognizer { - sky::EventType type = sky::EVENT_TYPE_UNKNOWN; - switch (recognizer.state) { - case UIGestureRecognizerStateBegan: - type = sky::EVENT_TYPE_GESTURE_SCROLL_BEGIN; - break; - case UIGestureRecognizerStateChanged: - type = sky::EVENT_TYPE_GESTURE_SCROLL_UPDATE; - break; - case UIGestureRecognizerStateEnded: - case UIGestureRecognizerStateCancelled: - case UIGestureRecognizerStateFailed: - type = sky::EVENT_TYPE_GESTURE_SCROLL_END; - break; - default: - break; - } - - if (type == sky::EVENT_TYPE_UNKNOWN) { - return; - } - - auto input = BasicInputEventFromRecognizer(type, recognizer); - auto scale = [UIScreen mainScreen].scale; - auto translation = [recognizer translationInView: self]; - auto velocity = [recognizer velocityInView: self]; - - input->gesture_data->dx = translation.x * scale; - input->gesture_data->dy = translation.y * scale; - input->gesture_data->velocityX = velocity.x * scale; - input->gesture_data->velocityY = velocity.y * scale; - - _sky_engine->OnInputEvent(input.Pass()); -} - --(void) onTap:(UITapGestureRecognizer *) recognizer { - - if (recognizer.state != UIGestureRecognizerStateEnded) { - return; - } - - auto input = BasicInputEventFromRecognizer(sky::EVENT_TYPE_GESTURE_TAP, - recognizer); - _sky_engine->OnInputEvent(input.Pass()); -} - -#pragma mark - Misc. - -+ (Class)layerClass { - return [CAEAGLLayer class]; -} - -- (void)dealloc { - [self notifySurfaceDestruction]; - [super dealloc]; -} - -@end diff --git a/engine/src/flutter/shell/ios/sky_view_controller.h b/engine/src/flutter/shell/ios/sky_view_controller.h deleted file mode 100644 index d82b6cd242..0000000000 --- a/engine/src/flutter/shell/ios/sky_view_controller.h +++ /dev/null @@ -1,9 +0,0 @@ -// Copyright 2015 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 - -@interface SkyViewController : UIViewController - -@end diff --git a/engine/src/flutter/shell/ios/sky_view_controller.mm b/engine/src/flutter/shell/ios/sky_view_controller.mm deleted file mode 100644 index 0cabeed32b..0000000000 --- a/engine/src/flutter/shell/ios/sky_view_controller.mm +++ /dev/null @@ -1,28 +0,0 @@ -// Copyright 2015 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 "sky_view_controller.h" -#import "sky_surface.h" - -#import -#import - -#include "sky/shell/shell.h" -#include "sky/shell/shell_view.h" - -@implementation SkyViewController - -- (void)loadView { - auto shell_view = new sky::shell::ShellView(sky::shell::Shell::Shared()); - SkySurface* surface = [[SkySurface alloc] initWithShellView: shell_view]; - - surface.autoresizingMask = - UIViewAutoresizingFlexibleWidth | UIViewAutoresizingFlexibleHeight; - - self.view = surface; - - [surface release]; -} - -@end diff --git a/engine/src/flutter/shell/linux/main.cc b/engine/src/flutter/shell/linux/main.cc deleted file mode 100644 index 06759977a7..0000000000 --- a/engine/src/flutter/shell/linux/main.cc +++ /dev/null @@ -1,89 +0,0 @@ -// Copyright 2015 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. - -#include - -#include "base/at_exit.h" -#include "base/basictypes.h" -#include "base/bind.h" -#include "base/command_line.h" -#include "base/i18n/icu_util.h" -#include "base/logging.h" -#include "base/message_loop/message_loop.h" -#include "sky/engine/public/web/WebRuntimeFeatures.h" -#include "sky/shell/platform_view.h" -#include "sky/shell/service_provider.h" -#include "sky/shell/shell.h" -#include "sky/shell/shell_view.h" -#include "sky/shell/switches.h" -#include "sky/shell/testing/test_runner.h" - -namespace sky { -namespace shell { -namespace { - -void Usage() { - std::cerr << "Usage: sky_shell" - << " --" << switches::kNonInteractive - << " --" << switches::kPackageRoot << "=PACKAGE_ROOT" - << " --" << switches::kSnapshot << "=SNAPSHOT" - << " [ MAIN_DART ]" << std::endl; -} - -void Init() { - base::CommandLine& command_line = *base::CommandLine::ForCurrentProcess(); - blink::WebRuntimeFeatures::enableObservatory( - !command_line.HasSwitch(switches::kNonInteractive)); - - Shell::Init(make_scoped_ptr(new ServiceProviderContext( - base::MessageLoop::current()->task_runner()))); - // Explicitly boot the shared test runner. - TestRunner& runner = TestRunner::Shared(); - - std::string package_root = - command_line.GetSwitchValueASCII(switches::kPackageRoot); - runner.set_package_root(package_root); - - scoped_ptr single_test; - if (command_line.HasSwitch(switches::kSnapshot)) { - single_test.reset(new TestRunner::SingleTest); - single_test->path = command_line.GetSwitchValueASCII(switches::kSnapshot); - single_test->is_snapshot = true; - } else { - auto args = command_line.GetArgs(); - if (!args.empty()) { - single_test.reset(new TestRunner::SingleTest); - single_test->path = args[0]; - } - } - - runner.Start(single_test.Pass()); -} - -} // namespace -} // namespace shell -} // namespace sky - -int main(int argc, const char* argv[]) { - base::AtExitManager exit_manager; - base::CommandLine::Init(argc, argv); - - base::CommandLine& command_line = *base::CommandLine::ForCurrentProcess(); - - if (command_line.HasSwitch(sky::shell::switches::kHelp) || - (!command_line.HasSwitch(sky::shell::switches::kPackageRoot) && - !command_line.HasSwitch(sky::shell::switches::kSnapshot))) { - sky::shell::Usage(); - return 0; - } - - base::MessageLoop message_loop; - - base::i18n::InitializeICU(); - - message_loop.PostTask(FROM_HERE, base::Bind(&sky::shell::Init)); - message_loop.Run(); - - return 0; -} diff --git a/engine/src/flutter/shell/linux/platform_service_provider_linux.cc b/engine/src/flutter/shell/linux/platform_service_provider_linux.cc deleted file mode 100644 index 8bc64cc336..0000000000 --- a/engine/src/flutter/shell/linux/platform_service_provider_linux.cc +++ /dev/null @@ -1,41 +0,0 @@ -// Copyright 2015 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. - -#include "base/bind.h" -#include "base/bind_helpers.h" -#include "base/lazy_instance.h" -#include "base/location.h" -#include "base/single_thread_task_runner.h" -#include "mojo/public/cpp/application/service_provider_impl.h" -#include "sky/shell/service_provider.h" -#include "sky/shell/testing/test_runner.h" - -namespace sky { -namespace shell { -namespace { - -base::LazyInstance> g_service_provider = - LAZY_INSTANCE_INITIALIZER; - -static void CreateServiceProviderImpl( - mojo::InterfaceRequest request) { - g_service_provider.Get().reset(new mojo::ServiceProviderImpl(request.Pass())); - g_service_provider.Get()->AddService(&TestRunner::Shared()); -} - -} // namespace - -mojo::ServiceProviderPtr CreateServiceProvider( - ServiceProviderContext* context) { - DCHECK(context); - mojo::MessagePipe pipe; - auto request = mojo::MakeRequest(pipe.handle1.Pass()); - context->platform_task_runner->PostTask( - FROM_HERE, base::Bind(CreateServiceProviderImpl, base::Passed(&request))); - return mojo::MakeProxy( - mojo::InterfacePtrInfo(pipe.handle0.Pass(), 0u)); -} - -} // namespace shell -} // namespace sky diff --git a/engine/src/flutter/shell/linux/platform_view_linux.cc b/engine/src/flutter/shell/linux/platform_view_linux.cc deleted file mode 100644 index 73fee52ab7..0000000000 --- a/engine/src/flutter/shell/linux/platform_view_linux.cc +++ /dev/null @@ -1,15 +0,0 @@ -// Copyright 2015 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. - -#include "sky/shell/platform_view.h" - -namespace sky { -namespace shell { - -PlatformView* PlatformView::Create(const Config& config) { - return new PlatformView(config); -} - -} // namespace shell -} // namespace sky diff --git a/engine/src/flutter/shell/platform_view.cc b/engine/src/flutter/shell/platform_view.cc deleted file mode 100644 index a22fc5df80..0000000000 --- a/engine/src/flutter/shell/platform_view.cc +++ /dev/null @@ -1,47 +0,0 @@ -// Copyright 2015 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. - -#include "sky/shell/platform_view.h" -#include "base/bind.h" -#include "base/location.h" -#include "sky/shell/shell.h" -#include "base/single_thread_task_runner.h" - -namespace sky { -namespace shell { - -PlatformView::Config::Config() { -} - -PlatformView::Config::~Config() { -} - -PlatformView::PlatformView(const PlatformView::Config& config) - : config_(config), window_(0) { -} - -PlatformView::~PlatformView() { -} - -void PlatformView::ConnectToEngine( - mojo::InterfaceRequest request) { - config_.ui_task_runner->PostTask( - FROM_HERE, base::Bind(&UIDelegate::ConnectToEngine, - config_.ui_delegate, base::Passed(&request))); -} - -void PlatformView::SurfaceWasCreated() { - config_.ui_task_runner->PostTask( - FROM_HERE, base::Bind(&UIDelegate::OnAcceleratedWidgetAvailable, - config_.ui_delegate, window_)); -} - -void PlatformView::SurfaceWasDestroyed() { - config_.ui_task_runner->PostTask( - FROM_HERE, - base::Bind(&UIDelegate::OnOutputSurfaceDestroyed, config_.ui_delegate)); -} - -} // namespace shell -} // namespace sky diff --git a/engine/src/flutter/shell/platform_view.h b/engine/src/flutter/shell/platform_view.h deleted file mode 100644 index 7b221af296..0000000000 --- a/engine/src/flutter/shell/platform_view.h +++ /dev/null @@ -1,47 +0,0 @@ -// Copyright 2015 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. - -#ifndef SKY_SHELL_PLATFORM_VIEW_H_ -#define SKY_SHELL_PLATFORM_VIEW_H_ - -#include "base/macros.h" -#include "base/memory/weak_ptr.h" -#include "sky/shell/ui_delegate.h" - -namespace sky { -namespace shell { - -class PlatformView { - public: - struct Config { - Config(); - ~Config(); - - base::WeakPtr ui_delegate; - scoped_refptr ui_task_runner; - }; - - static PlatformView* Create(const Config& config); - - virtual ~PlatformView(); - - void ConnectToEngine(mojo::InterfaceRequest request); - - protected: - explicit PlatformView(const Config& config); - - void SurfaceWasCreated(); - void SurfaceWasDestroyed(); - - Config config_; - gfx::AcceleratedWidget window_; - - private: - DISALLOW_COPY_AND_ASSIGN(PlatformView); -}; - -} // namespace shell -} // namespace sky - -#endif // SKY_SHELL_PLATFORM_VIEW_H_ diff --git a/engine/src/flutter/shell/service_provider.cc b/engine/src/flutter/shell/service_provider.cc deleted file mode 100644 index 3b2b9ad187..0000000000 --- a/engine/src/flutter/shell/service_provider.cc +++ /dev/null @@ -1,20 +0,0 @@ -// Copyright 2015 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. - -#include "sky/shell/service_provider.h" - -#include "base/single_thread_task_runner.h" - -namespace sky { -namespace shell { - -ServiceProviderContext::ServiceProviderContext( - scoped_refptr runner) - : platform_task_runner(runner.Pass()) {} - -ServiceProviderContext::~ServiceProviderContext() { -} - -} // namespace shell -} // namespace sky diff --git a/engine/src/flutter/shell/service_provider.h b/engine/src/flutter/shell/service_provider.h deleted file mode 100644 index cff6b6cb85..0000000000 --- a/engine/src/flutter/shell/service_provider.h +++ /dev/null @@ -1,33 +0,0 @@ -// Copyright 2015 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. - -#ifndef SKY_SHELL_SERVICE_PROVIDER_H_ -#define SKY_SHELL_SERVICE_PROVIDER_H_ - -#include "base/memory/ref_counted.h" -#include "mojo/public/cpp/system/core.h" -#include "mojo/public/interfaces/application/service_provider.mojom.h" - -namespace base { -class SingleThreadTaskRunner; -} - -namespace sky { -namespace shell { - -class ServiceProviderContext { - public: - ServiceProviderContext(scoped_refptr runner); - ~ServiceProviderContext(); - - scoped_refptr platform_task_runner; -}; - -// Implemented in platform_service_provider.cc for each platform. -mojo::ServiceProviderPtr CreateServiceProvider(ServiceProviderContext* context); - -} // namespace shell -} // namespace sky - -#endif // SKY_SHELL_SERVICE_PROVIDER_H_ diff --git a/engine/src/flutter/shell/shell.cc b/engine/src/flutter/shell/shell.cc deleted file mode 100644 index 1147b3ee14..0000000000 --- a/engine/src/flutter/shell/shell.cc +++ /dev/null @@ -1,57 +0,0 @@ -// Copyright 2015 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. - -#include "sky/shell/shell.h" - -#include "base/bind.h" -#include "base/single_thread_task_runner.h" -#include "mojo/common/message_pump_mojo.h" -#include "mojo/edk/embedder/embedder.h" -#include "mojo/edk/embedder/simple_platform_support.h" -#include "sky/shell/ui/engine.h" - -namespace sky { -namespace shell { -namespace { - -static Shell* g_shell = nullptr; - -scoped_ptr CreateMessagePumpMojo() { - return make_scoped_ptr(new mojo::common::MessagePumpMojo); -} - -} // namespace - -Shell::Shell(scoped_ptr service_provider_context) - : service_provider_context_(service_provider_context.Pass()) { - DCHECK(!g_shell); - mojo::embedder::Init(scoped_ptr( - new mojo::embedder::SimplePlatformSupport())); - - base::Thread::Options options; - options.message_pump_factory = base::Bind(&CreateMessagePumpMojo); - - gpu_thread_.reset(new base::Thread("gpu_thread")); - gpu_thread_->StartWithOptions(options); - - ui_thread_.reset(new base::Thread("ui_thread")); - ui_thread_->StartWithOptions(options); - - ui_task_runner()->PostTask(FROM_HERE, base::Bind(&Engine::Init)); -} - -Shell::~Shell() { -} - -void Shell::Init(scoped_ptr service_provider_context) { - g_shell = new Shell(service_provider_context.Pass()); -} - -Shell& Shell::Shared() { - DCHECK(g_shell); - return *g_shell; -} - -} // namespace shell -} // namespace sky diff --git a/engine/src/flutter/shell/shell.h b/engine/src/flutter/shell/shell.h deleted file mode 100644 index 36004da883..0000000000 --- a/engine/src/flutter/shell/shell.h +++ /dev/null @@ -1,55 +0,0 @@ -// Copyright 2015 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. - -#ifndef SKY_SHELL_SHELL_H_ -#define SKY_SHELL_SHELL_H_ - -#include "base/macros.h" -#include "base/memory/ref_counted.h" -#include "base/memory/scoped_ptr.h" -#include "base/message_loop/message_loop.h" -#include "base/threading/thread.h" -#include "sky/shell/service_provider.h" - -namespace sky { -namespace shell { -class ServiceProviderContext; - -class Shell { - public: - ~Shell(); - - static void Init( - scoped_ptr service_provider_context); - static Shell& Shared(); - - scoped_refptr gpu_task_runner() const { - return gpu_thread_->message_loop()->task_runner(); - } - - scoped_refptr ui_task_runner() const { - return ui_thread_->message_loop()->task_runner(); - } - - ServiceProviderContext* service_provider_context() const { - return service_provider_context_.get(); - } - - private: - explicit Shell(scoped_ptr service_provider_context); - - void InitGPU(const base::Thread::Options& options); - void InitUI(const base::Thread::Options& options); - - scoped_ptr gpu_thread_; - scoped_ptr ui_thread_; - scoped_ptr service_provider_context_; - - DISALLOW_COPY_AND_ASSIGN(Shell); -}; - -} // namespace shell -} // namespace sky - -#endif // SKY_SHELL_SHELL_H_ diff --git a/engine/src/flutter/shell/shell_view.cc b/engine/src/flutter/shell/shell_view.cc deleted file mode 100644 index bb83d422ef..0000000000 --- a/engine/src/flutter/shell/shell_view.cc +++ /dev/null @@ -1,53 +0,0 @@ -// Copyright 2015 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. - -#include "sky/shell/shell_view.h" - -#include "base/bind.h" -#include "base/single_thread_task_runner.h" -#include "sky/shell/gpu/rasterizer.h" -#include "sky/shell/platform_view.h" -#include "sky/shell/shell.h" -#include "sky/shell/ui/engine.h" - -namespace sky { -namespace shell { -namespace { - -template -void Drop(scoped_ptr ptr) { } - -} // namespace - -ShellView::ShellView(Shell& shell) - : shell_(shell) { - rasterizer_.reset(new Rasterizer()); - CreateEngine(); - CreatePlatformView(); -} - -ShellView::~ShellView() { - shell_.gpu_task_runner()->PostTask(FROM_HERE, - base::Bind(&Drop, base::Passed(&rasterizer_))); - shell_.ui_task_runner()->PostTask(FROM_HERE, - base::Bind(&Drop, base::Passed(&engine_))); -} - -void ShellView::CreateEngine() { - Engine::Config config; - config.service_provider_context = shell_.service_provider_context(); - config.gpu_task_runner = shell_.gpu_task_runner(); - config.gpu_delegate = rasterizer_->GetWeakPtr(); - engine_.reset(new Engine(config)); -} - -void ShellView::CreatePlatformView() { - PlatformView::Config config; - config.ui_task_runner = shell_.ui_task_runner(); - config.ui_delegate = engine_->GetWeakPtr(); - view_.reset(PlatformView::Create(config)); -} - -} // namespace shell -} // namespace sky diff --git a/engine/src/flutter/shell/shell_view.h b/engine/src/flutter/shell/shell_view.h deleted file mode 100644 index 221406fdd1..0000000000 --- a/engine/src/flutter/shell/shell_view.h +++ /dev/null @@ -1,40 +0,0 @@ -// Copyright 2015 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. - -#ifndef SKY_SHELL_SHELL_VIEW_H_ -#define SKY_SHELL_SHELL_VIEW_H_ - -#include "base/macros.h" -#include "base/memory/scoped_ptr.h" - -namespace sky { -namespace shell { -class Engine; -class PlatformView; -class Rasterizer; -class Shell; - -class ShellView { - public: - explicit ShellView(Shell& shell); - ~ShellView(); - - PlatformView* view() const { return view_.get(); } - - private: - void CreateEngine(); - void CreatePlatformView(); - - Shell& shell_; - scoped_ptr view_; - scoped_ptr rasterizer_; - scoped_ptr engine_; - - DISALLOW_COPY_AND_ASSIGN(ShellView); -}; - -} // namespace shell -} // namespace sky - -#endif // SKY_SHELL_SHELL_VIEW_H_ diff --git a/engine/src/flutter/shell/switches.cc b/engine/src/flutter/shell/switches.cc deleted file mode 100644 index 6548ab8ba7..0000000000 --- a/engine/src/flutter/shell/switches.cc +++ /dev/null @@ -1,18 +0,0 @@ -// Copyright 2013 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. - -#include "sky/shell/switches.h" - -namespace sky { -namespace shell { -namespace switches { - -const char kHelp[] = "help"; -const char kNonInteractive[] = "non-interactive"; -const char kPackageRoot[] = "package-root"; -const char kSnapshot[] = "snapshot"; - -} // namespace switches -} // namespace shell -} // namespace sky diff --git a/engine/src/flutter/shell/switches.h b/engine/src/flutter/shell/switches.h deleted file mode 100644 index 5338d4e09d..0000000000 --- a/engine/src/flutter/shell/switches.h +++ /dev/null @@ -1,21 +0,0 @@ -// Copyright 2013 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. - -#ifndef SKY_SHELL_SWITCHES_H_ -#define SKY_SHELL_SWITCHES_H_ - -namespace sky { -namespace shell { -namespace switches { - -extern const char kHelp[]; -extern const char kPackageRoot[]; -extern const char kNonInteractive[]; -extern const char kSnapshot[]; - -} // namespace switches -} // namespace shell -} // namespace sky - -#endif // SKY_SHELL_SWITCHES_H_ diff --git a/engine/src/flutter/shell/testing/test_runner.cc b/engine/src/flutter/shell/testing/test_runner.cc deleted file mode 100644 index c4bf2dca7e..0000000000 --- a/engine/src/flutter/shell/testing/test_runner.cc +++ /dev/null @@ -1,137 +0,0 @@ -// 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. - -#include "sky/shell/testing/test_runner.h" - -#include - -#include "base/bind.h" -#include "base/message_loop/message_loop.h" -#include "base/strings/string_util.h" -#include "sky/shell/platform_view.h" -#include "sky/shell/shell.h" -#include "sky/shell/shell_view.h" - -namespace sky { -namespace shell { -namespace { - -struct UrlData { - std::string url; - std::string expected_pixel_hash; - bool enable_pixel_dumping = false; - bool is_snapshot = false; -}; - -void WaitForURL(UrlData& data) { - // A test name is formated like file:///path/to/test'--pixel-test'pixelhash - std::cin >> data.url; - - std::string pixel_switch; - std::string::size_type separator_position = data.url.find('\''); - if (separator_position != std::string::npos) { - pixel_switch = data.url.substr(separator_position + 1); - data.url.erase(separator_position); - } - - std::string pixel_hash; - separator_position = pixel_switch.find('\''); - if (separator_position != std::string::npos) { - pixel_hash = pixel_switch.substr(separator_position + 1); - pixel_switch.erase(separator_position); - } - - data.enable_pixel_dumping = pixel_switch == "--pixel-test"; - data.expected_pixel_hash = pixel_hash; -} - -void PrintAndFlush(const std::string& value) { - std::cout << value; - std::cout.flush(); -} - -const char kFileUrlPrefix[] = "file://"; -static TestRunner* g_test_runner = nullptr; - -} // namespace - -TestRunner::TestRunner() - : shell_view_(new ShellView(Shell::Shared())), - weak_ptr_factory_(this) { - CHECK(!g_test_runner) << "Only create one TestRunner."; - - shell_view_->view()->ConnectToEngine(GetProxy(&sky_engine_)); - ViewportMetricsPtr metrics = ViewportMetrics::New(); - metrics->physical_width = 800; - metrics->physical_height = 600; - sky_engine_->OnViewportMetricsChanged(metrics.Pass()); -} - -TestRunner::~TestRunner() { -} - -TestRunner& TestRunner::Shared() { - if (!g_test_runner) - g_test_runner = new TestRunner(); - return *g_test_runner; -} - -void TestRunner::Start(scoped_ptr single_test) { - single_test_ = single_test.Pass(); - PrintAndFlush("#READY\n"); - ScheduleRun(); -} - -void TestRunner::OnTestComplete(const mojo::String& test_result, - const mojo::Array pixels) { - std::cout << "Content-Type: text/plain\n"; - std::cout << test_result << "\n"; - PrintAndFlush("#EOF\n"); // Text result complete - PrintAndFlush("#EOF\n"); // Pixel result complete - std::cerr << "#EOF\n"; - std::cerr.flush(); - bindings_.CloseAllBindings(); - - if (single_test_) - exit(0); - ScheduleRun(); -} - -void TestRunner::DispatchInputEvent(mojo::EventPtr event) { - // TODO(abarth): Not implemented. -} - -void TestRunner::Create(mojo::ApplicationConnection* app, - mojo::InterfaceRequest request) { - bindings_.AddBinding(this, request.Pass()); -} - -void TestRunner::ScheduleRun() { - base::MessageLoop::current()->PostTask(FROM_HERE, - base::Bind(&TestRunner::Run, weak_ptr_factory_.GetWeakPtr())); -} - -void TestRunner::Run() { - UrlData data; - if (single_test_) { - data.url = single_test_->path; - data.is_snapshot = single_test_->is_snapshot; - } else { - WaitForURL(data); - } - - std::cout << "#BEGIN\n"; - std::cout.flush(); - - if (StartsWithASCII(data.url, kFileUrlPrefix, true)) - ReplaceFirstSubstringAfterOffset(&data.url, 0, kFileUrlPrefix, ""); - - if (data.is_snapshot) - sky_engine_->RunFromSnapshot(data.url); - else - sky_engine_->RunFromFile(data.url, package_root_); -} - -} // namespace shell -} // namespace sky diff --git a/engine/src/flutter/shell/testing/test_runner.h b/engine/src/flutter/shell/testing/test_runner.h deleted file mode 100644 index 82d34ed46f..0000000000 --- a/engine/src/flutter/shell/testing/test_runner.h +++ /dev/null @@ -1,67 +0,0 @@ -// Copyright 2015 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. - -#ifndef SKY_SHELL_TESTING_TEST_RUNNER_H_ -#define SKY_SHELL_TESTING_TEST_RUNNER_H_ - -#include - -#include "base/macros.h" -#include "base/memory/weak_ptr.h" -#include "mojo/common/weak_binding_set.h" -#include "mojo/public/cpp/application/interface_factory_impl.h" -#include "sky/services/engine/sky_engine.mojom.h" -#include "sky/services/testing/test_harness.mojom.h" - -namespace sky { -namespace shell { -class ShellView; - -class TestRunner : public mojo::InterfaceFactory, - public TestHarness { - public: - static TestRunner& Shared(); - - void set_package_root(const std::string& package_root) { - package_root_ = package_root; - } - - struct SingleTest { - std::string path; - bool is_snapshot = false; - }; - - void Start(scoped_ptr single_test); - - private: - // mojo::InterfaceFactory implementation: - void Create(mojo::ApplicationConnection* app, - mojo::InterfaceRequest request) override; - - // TestHarness implementation: - void OnTestComplete(const mojo::String& test_result, - const mojo::Array pixels) override; - void DispatchInputEvent(mojo::EventPtr event) override; - - TestRunner(); - ~TestRunner() override; - void ScheduleRun(); - void Run(); - - std::string package_root_; - scoped_ptr shell_view_; - SkyEnginePtr sky_engine_; - - scoped_ptr single_test_; - mojo::WeakBindingSet bindings_; - - base::WeakPtrFactory weak_ptr_factory_; - - DISALLOW_COPY_AND_ASSIGN(TestRunner); -}; - -} // namespace shell -} // namespace sky - -#endif // SKY_SHELL_TESTING_TEST_RUNNER_H_ diff --git a/engine/src/flutter/shell/ui/animator.cc b/engine/src/flutter/shell/ui/animator.cc deleted file mode 100644 index ceca49942c..0000000000 --- a/engine/src/flutter/shell/ui/animator.cc +++ /dev/null @@ -1,82 +0,0 @@ -// Copyright 2015 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. - -#include "sky/shell/ui/animator.h" - -#include "base/bind.h" -#include "base/message_loop/message_loop.h" -#include "base/trace_event/trace_event.h" - -namespace sky { -namespace shell { - -Animator::Animator(const Engine::Config& config, Engine* engine) - : config_(config), - engine_(engine), - engine_requested_frame_(false), - frame_in_progress_(false), - paused_(false), - weak_factory_(this) { -} - -Animator::~Animator() { -} - -void Animator::RequestFrame() { - if (engine_requested_frame_) - return; - - TRACE_EVENT_ASYNC_BEGIN0("sky", "Frame request pending", this); - engine_requested_frame_ = true; - - if (!frame_in_progress_) { - frame_in_progress_ = true; - base::MessageLoop::current()->PostTask( - FROM_HERE, - base::Bind(&Animator::BeginFrame, weak_factory_.GetWeakPtr())); - } -} - -void Animator::Stop() { - paused_ = true; - engine_requested_frame_ = false; -} - -void Animator::Start() { - paused_ = false; - RequestFrame(); -} - -void Animator::BeginFrame() { - DCHECK(frame_in_progress_); - // There could be a request in the message loop at time of cancel. - if (!engine_requested_frame_) { - frame_in_progress_ = false; - return; - } - - engine_requested_frame_ = false; - TRACE_EVENT_ASYNC_END0("sky", "Frame request pending", this); - - engine_->BeginFrame(base::TimeTicks::Now()); - config_.gpu_task_runner->PostTaskAndReply( - FROM_HERE, - base::Bind(&GPUDelegate::Draw, config_.gpu_delegate, engine_->Paint()), - base::Bind(&Animator::OnFrameComplete, weak_factory_.GetWeakPtr())); -} - -void Animator::OnFrameComplete() { - DCHECK(frame_in_progress_); - frame_in_progress_ = false; - if (paused_) - return; - - if (engine_requested_frame_) { - frame_in_progress_ = true; - BeginFrame(); - } -} - -} // namespace shell -} // namespace sky diff --git a/engine/src/flutter/shell/ui/animator.h b/engine/src/flutter/shell/ui/animator.h deleted file mode 100644 index cef6624cc6..0000000000 --- a/engine/src/flutter/shell/ui/animator.h +++ /dev/null @@ -1,42 +0,0 @@ -// Copyright 2015 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. - -#ifndef SKY_SHELL_UI_ANIMATOR_H_ -#define SKY_SHELL_UI_ANIMATOR_H_ - -#include "base/memory/weak_ptr.h" -#include "sky/shell/ui/engine.h" - -namespace sky { -namespace shell { - -class Animator { - public: - explicit Animator(const Engine::Config& config, Engine* engine); - ~Animator(); - - void RequestFrame(); - - void Start(); - void Stop(); - - private: - void BeginFrame(); - void OnFrameComplete(); - - Engine::Config config_; - Engine* engine_; - bool engine_requested_frame_; - bool frame_in_progress_; - bool paused_; - - base::WeakPtrFactory weak_factory_; - - DISALLOW_COPY_AND_ASSIGN(Animator); -}; - -} // namespace shell -} // namespace sky - -#endif // SKY_SHELL_UI_ANIMATOR_H_ diff --git a/engine/src/flutter/shell/ui/engine.cc b/engine/src/flutter/shell/ui/engine.cc deleted file mode 100644 index aaec2987db..0000000000 --- a/engine/src/flutter/shell/ui/engine.cc +++ /dev/null @@ -1,251 +0,0 @@ -// Copyright 2015 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. - -#include "sky/shell/ui/engine.h" - -#include "base/bind.h" -#include "base/files/file_path.h" -#include "base/threading/worker_pool.h" -#include "base/trace_event/trace_event.h" -#include "mojo/common/data_pipe_utils.h" -#include "mojo/public/cpp/application/connect.h" -#include "services/asset_bundle/asset_unpacker_job.h" -#include "sky/engine/public/platform/WebInputEvent.h" -#include "sky/engine/public/platform/sky_display_metrics.h" -#include "sky/engine/public/platform/sky_display_metrics.h" -#include "sky/engine/public/web/Sky.h" -#include "sky/shell/dart/dart_library_provider_files.h" -#include "sky/shell/dart/dart_library_provider_network.h" -#include "sky/shell/service_provider.h" -#include "sky/shell/ui/animator.h" -#include "sky/shell/ui/input_event_converter.h" -#include "sky/shell/ui/internals.h" -#include "sky/shell/ui/platform_impl.h" -#include "third_party/skia/include/core/SkCanvas.h" -#include "third_party/skia/include/core/SkPictureRecorder.h" - -namespace sky { -namespace shell { - -const char kSnapshotKey[] = "snapshot_blob.bin"; - -namespace { - -void Ignored(bool) { -} - -mojo::ScopedDataPipeConsumerHandle Fetch(const base::FilePath& path) { - mojo::DataPipe pipe; - auto runner = base::WorkerPool::GetTaskRunner(true); - mojo::common::CopyFromFile(base::FilePath(path), pipe.producer_handle.Pass(), - 0, runner.get(), base::Bind(&Ignored)); - return pipe.consumer_handle.Pass(); -} - -PlatformImpl* g_platform_impl = nullptr; - -} // namespace - -using mojo::asset_bundle::AssetUnpackerJob; - -Engine::Config::Config() { -} - -Engine::Config::~Config() { -} - -Engine::Engine(const Config& config) - : config_(config), - animator_(new Animator(config, this)), - binding_(this), - activity_running_(false), - have_surface_(false), - weak_factory_(this) { - mojo::ServiceProviderPtr service_provider = - CreateServiceProvider(config.service_provider_context); - mojo::ConnectToService(service_provider.get(), &network_service_); -} - -Engine::~Engine() { -} - -base::WeakPtr Engine::GetWeakPtr() { - return weak_factory_.GetWeakPtr(); -} - -void Engine::Init() { - TRACE_EVENT0("sky", "Engine::Init"); - - DCHECK(!g_platform_impl); - g_platform_impl = new PlatformImpl(); - blink::initialize(g_platform_impl); -} - -void Engine::BeginFrame(base::TimeTicks frame_time) { - TRACE_EVENT0("sky", "Engine::BeginFrame"); - - if (sky_view_) - sky_view_->BeginFrame(frame_time); -} - -skia::RefPtr Engine::Paint() { - TRACE_EVENT0("sky", "Engine::Paint"); - - SkRTreeFactory factory; - SkPictureRecorder recorder; - auto canvas = skia::SharePtr(recorder.beginRecording( - physical_size_.width(), physical_size_.height(), &factory, - SkPictureRecorder::kComputeSaveLayerInfo_RecordFlag)); - - if (sky_view_) { - skia::RefPtr picture = sky_view_->Paint(); - canvas->clear(SK_ColorBLACK); - canvas->scale(display_metrics_.device_pixel_ratio, - display_metrics_.device_pixel_ratio); - if (picture) - canvas->drawPicture(picture.get()); - } - - return skia::AdoptRef(recorder.endRecordingAsPicture()); -} - -void Engine::ConnectToEngine(mojo::InterfaceRequest request) { - binding_.Bind(request.Pass()); -} - -void Engine::OnAcceleratedWidgetAvailable(gfx::AcceleratedWidget widget) { - config_.gpu_task_runner->PostTask( - FROM_HERE, base::Bind(&GPUDelegate::OnAcceleratedWidgetAvailable, - config_.gpu_delegate, widget)); - have_surface_ = true; - StartAnimatorIfPossible(); - if (sky_view_) - ScheduleFrame(); -} - -void Engine::OnOutputSurfaceDestroyed() { - have_surface_ = false; - StopAnimator(); - config_.gpu_task_runner->PostTask( - FROM_HERE, - base::Bind(&GPUDelegate::OnOutputSurfaceDestroyed, config_.gpu_delegate)); -} - -void Engine::OnViewportMetricsChanged(ViewportMetricsPtr metrics) { - physical_size_.SetSize(metrics->physical_width, metrics->physical_height); - - display_metrics_.physical_size = physical_size_; - display_metrics_.device_pixel_ratio = metrics->device_pixel_ratio; - display_metrics_.padding_top = metrics->padding_top; - display_metrics_.padding_right = metrics->padding_right; - display_metrics_.padding_bottom = metrics->padding_bottom; - display_metrics_.padding_left = metrics->padding_left; - - if (sky_view_) - sky_view_->SetDisplayMetrics(display_metrics_); -} - -void Engine::OnInputEvent(InputEventPtr event) { - TRACE_EVENT0("sky", "Engine::OnInputEvent"); - scoped_ptr web_event = - ConvertEvent(event, display_metrics_.device_pixel_ratio); - if (!web_event) - return; - if (sky_view_) - sky_view_->HandleInputEvent(*web_event); -} - -void Engine::RunFromLibrary(const std::string& name) { - sky_view_ = blink::SkyView::Create(this); - sky_view_->RunFromLibrary(blink::WebString::fromUTF8(name), - dart_library_provider_.get()); - sky_view_->SetDisplayMetrics(display_metrics_); -} - -void Engine::RunFromSnapshotStream( - const std::string& name, - mojo::ScopedDataPipeConsumerHandle snapshot) { - sky_view_ = blink::SkyView::Create(this); - sky_view_->RunFromSnapshot(blink::WebString::fromUTF8(name), snapshot.Pass()); - sky_view_->SetDisplayMetrics(display_metrics_); -} - -void Engine::RunFromNetwork(const mojo::String& url) { - dart_library_provider_.reset( - new DartLibraryProviderNetwork(network_service_.get())); - RunFromLibrary(url); -} - -void Engine::RunFromFile(const mojo::String& main, - const mojo::String& package_root) { - dart_library_provider_.reset( - new DartLibraryProviderFiles(base::FilePath(package_root))); - RunFromLibrary(main); -} - -void Engine::RunFromSnapshot(const mojo::String& path) { - std::string path_str = path; - RunFromSnapshotStream(path_str, Fetch(base::FilePath(path_str))); -} - -void Engine::RunFromBundle(const mojo::String& path) { - AssetUnpackerJob* unpacker = new AssetUnpackerJob( - mojo::GetProxy(&root_bundle_), base::WorkerPool::GetTaskRunner(true)); - std::string path_str = path; - unpacker->Unpack(Fetch(base::FilePath(path_str))); - root_bundle_->GetAsStream(kSnapshotKey, - base::Bind(&Engine::RunFromSnapshotStream, - weak_factory_.GetWeakPtr(), path_str)); -} - -void Engine::OnActivityPaused() { - activity_running_ = false; - StopAnimator(); -} - -void Engine::OnActivityResumed() { - activity_running_ = true; - StartAnimatorIfPossible(); -} - -void Engine::DidCreateIsolate(Dart_Isolate isolate) { - Internals::Create(isolate, - CreateServiceProvider(config_.service_provider_context), - root_bundle_.Pass()); -} - -void Engine::StopAnimator() { - animator_->Stop(); -} - -void Engine::StartAnimatorIfPossible() { - if (activity_running_ && have_surface_) - animator_->Start(); -} - -void Engine::ScheduleFrame() { - animator_->RequestFrame(); -} - -mojo::NavigatorHost* Engine::NavigatorHost() { - return this; -} - -void Engine::RequestNavigate(mojo::Target target, - mojo::URLRequestPtr request) { - // Ignoring target for now. - base::MessageLoop::current()->PostTask( - FROM_HERE, - base::Bind(&Engine::RunFromNetwork, GetWeakPtr(), request->url)); -} - -void Engine::DidNavigateLocally(const mojo::String& url) { -} - -void Engine::RequestNavigateHistory(int32_t delta) { - NOTIMPLEMENTED(); -} - -} // namespace shell -} // namespace sky diff --git a/engine/src/flutter/shell/ui/engine.h b/engine/src/flutter/shell/ui/engine.h deleted file mode 100644 index 2dc832928b..0000000000 --- a/engine/src/flutter/shell/ui/engine.h +++ /dev/null @@ -1,122 +0,0 @@ -// Copyright 2015 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. - -#ifndef SKY_SHELL_UI_ENGINE_H_ -#define SKY_SHELL_UI_ENGINE_H_ - -#include "base/macros.h" -#include "base/memory/scoped_ptr.h" -#include "base/memory/weak_ptr.h" -#include "base/single_thread_task_runner.h" -#include "mojo/public/cpp/bindings/binding.h" -#include "mojo/public/cpp/system/core.h" -#include "mojo/public/interfaces/application/service_provider.mojom.h" -#include "mojo/services/asset_bundle/public/interfaces/asset_bundle.mojom.h" -#include "mojo/services/navigation/public/interfaces/navigation.mojom.h" -#include "mojo/services/network/public/interfaces/network_service.mojom.h" -#include "skia/ext/refptr.h" -#include "sky/engine/public/platform/ServiceProvider.h" -#include "sky/engine/public/sky/sky_view.h" -#include "sky/engine/public/sky/sky_view_client.h" -#include "sky/shell/gpu_delegate.h" -#include "sky/shell/service_provider.h" -#include "sky/shell/ui_delegate.h" -#include "third_party/skia/include/core/SkPicture.h" -#include "ui/gfx/geometry/size.h" - -namespace sky { -class PlatformImpl; -namespace shell { -class Animator; - -class Engine : public UIDelegate, - public SkyEngine, - public blink::ServiceProvider, - public mojo::NavigatorHost, - public blink::SkyViewClient { - public: - struct Config { - Config(); - ~Config(); - - ServiceProviderContext* service_provider_context; - - base::WeakPtr gpu_delegate; - scoped_refptr gpu_task_runner; - }; - - explicit Engine(const Config& config); - ~Engine() override; - - base::WeakPtr GetWeakPtr(); - - static void Init(); - - void BeginFrame(base::TimeTicks frame_time); - skia::RefPtr Paint(); - - private: - // UIDelegate implementation: - void ConnectToEngine(mojo::InterfaceRequest request) override; - void OnAcceleratedWidgetAvailable(gfx::AcceleratedWidget widget) override; - void OnOutputSurfaceDestroyed() override; - - // SkyEngine implementation: - void OnViewportMetricsChanged(ViewportMetricsPtr metrics) override; - void OnInputEvent(InputEventPtr event) override; - - void RunFromNetwork(const mojo::String& url) override; - void RunFromFile(const mojo::String& main, - const mojo::String& package_root) override; - void RunFromSnapshot(const mojo::String& path) override; - void RunFromBundle(const mojo::String& path) override; - - void OnActivityPaused() override; - void OnActivityResumed() override; - - // SkyViewClient methods: - void ScheduleFrame() override; - void DidCreateIsolate(Dart_Isolate isolate) override; - - // Services methods: - mojo::NavigatorHost* NavigatorHost() override; - - // NavigatorHost methods: - void RequestNavigate(mojo::Target target, - mojo::URLRequestPtr request) override; - void DidNavigateLocally(const mojo::String& url) override; - void RequestNavigateHistory(int32_t delta) override; - - void RunFromLibrary(const std::string& name); - void RunFromSnapshotStream(const std::string& name, - mojo::ScopedDataPipeConsumerHandle snapshot); - - void StopAnimator(); - void StartAnimatorIfPossible(); - - Config config_; - scoped_ptr animator_; - - mojo::NetworkServicePtr network_service_; - mojo::asset_bundle::AssetBundlePtr root_bundle_; - scoped_ptr dart_library_provider_; - std::unique_ptr sky_view_; - - gfx::Size physical_size_; - blink::SkyDisplayMetrics display_metrics_; - mojo::Binding binding_; - - // TODO(eseidel): This should move into an AnimatorStateMachine. - bool activity_running_; - bool have_surface_; - - base::WeakPtrFactory weak_factory_; - - DISALLOW_COPY_AND_ASSIGN(Engine); -}; - -} // namespace shell -} // namespace sky - -#endif // SKY_SHELL_UI_ENGINE_H_ diff --git a/engine/src/flutter/shell/ui/input_event_converter.cc b/engine/src/flutter/shell/ui/input_event_converter.cc deleted file mode 100644 index 1e81bb1eca..0000000000 --- a/engine/src/flutter/shell/ui/input_event_converter.cc +++ /dev/null @@ -1,142 +0,0 @@ -// 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. - -#include "sky/shell/ui/input_event_converter.h" - -#include "base/logging.h" -#include "base/time/time.h" -#include "sky/engine/public/platform/WebInputEvent.h" - -namespace sky { -namespace { - -scoped_ptr BuildWebPointerEvent( - const InputEventPtr& event, float device_pixel_ratio) { - scoped_ptr web_event(new blink::WebPointerEvent); - - web_event->timeStampMS = event->time_stamp; - - switch (event->type) { - case EVENT_TYPE_POINTER_DOWN: - web_event->type = blink::WebInputEvent::PointerDown; - break; - case EVENT_TYPE_POINTER_UP: - web_event->type = blink::WebInputEvent::PointerUp; - break; - case EVENT_TYPE_POINTER_MOVE: - web_event->type = blink::WebInputEvent::PointerMove; - break; - case EVENT_TYPE_POINTER_CANCEL: - web_event->type = blink::WebInputEvent::PointerCancel; - break; - default: - NOTIMPLEMENTED() << "Received unexpected event: " << event->type; - break; - } - - if (event->pointer_data) { - if (event->pointer_data->kind == POINTER_KIND_TOUCH) - web_event->kind = blink::WebPointerEvent::Touch; - web_event->pointer = event->pointer_data->pointer; - web_event->x = event->pointer_data->x / device_pixel_ratio; - web_event->y = event->pointer_data->y / device_pixel_ratio; - web_event->pressure = event->pointer_data->pressure; - web_event->pressureMin = event->pointer_data->pressure_min; - web_event->pressureMax = event->pointer_data->pressure_max; - } - - return web_event.Pass(); -} - -scoped_ptr BuildWebGestureEvent( - const InputEventPtr& event, float device_pixel_ratio) { - scoped_ptr web_event(new blink::WebGestureEvent); - - web_event->timeStampMS = event->time_stamp; - - switch (event->type) { - case EVENT_TYPE_GESTURE_SCROLL_BEGIN: - web_event->type = blink::WebInputEvent::GestureScrollBegin; - break; - case EVENT_TYPE_GESTURE_SCROLL_END: - web_event->type = blink::WebInputEvent::GestureScrollEnd; - break; - case EVENT_TYPE_GESTURE_SCROLL_UPDATE: - web_event->type = blink::WebInputEvent::GestureScrollUpdate; - web_event->data.scrollUpdate.deltaX = - event->gesture_data->dx / device_pixel_ratio; - web_event->data.scrollUpdate.deltaY = - event->gesture_data->dy / device_pixel_ratio; - break; - case EVENT_TYPE_GESTURE_FLING_START: - web_event->type = blink::WebInputEvent::GestureFlingStart; - web_event->data.flingStart.velocityX = - event->gesture_data->velocityX / device_pixel_ratio; - web_event->data.flingStart.velocityY = - event->gesture_data->velocityY / device_pixel_ratio; - break; - case EVENT_TYPE_GESTURE_FLING_CANCEL: - web_event->type = blink::WebInputEvent::GestureFlingCancel; - break; - case EVENT_TYPE_GESTURE_LONG_PRESS: - web_event->type = blink::WebInputEvent::GestureLongPress; - break; - case EVENT_TYPE_GESTURE_SHOW_PRESS: - web_event->type = blink::WebInputEvent::GestureShowPress; - break; - case EVENT_TYPE_GESTURE_TAP: - web_event->type = blink::WebInputEvent::GestureTap; - break; - case EVENT_TYPE_GESTURE_TAP_DOWN: - web_event->type = blink::WebInputEvent::GestureTapDown; - break; - default: - break; - } - - if (event->gesture_data) { - web_event->primaryPointer = event->gesture_data->primary_pointer; - web_event->x = event->gesture_data->x / device_pixel_ratio; - web_event->y = event->gesture_data->y / device_pixel_ratio; - } - - return web_event.Pass(); -} - -scoped_ptr BuildWebBackEvent(const InputEventPtr& event) { - scoped_ptr web_event(blink::WebInputEvent::create()); - web_event->type = blink::WebInputEvent::Back; - return web_event.Pass(); -} - -} // namespace - -scoped_ptr ConvertEvent(const InputEventPtr& event, - float device_pixel_ratio) { - switch (event->type) { - case EVENT_TYPE_POINTER_DOWN: - case EVENT_TYPE_POINTER_UP: - case EVENT_TYPE_POINTER_MOVE: - case EVENT_TYPE_POINTER_CANCEL: - return BuildWebPointerEvent(event, device_pixel_ratio); - case EVENT_TYPE_GESTURE_FLING_CANCEL: - case EVENT_TYPE_GESTURE_FLING_START: - case EVENT_TYPE_GESTURE_LONG_PRESS: - case EVENT_TYPE_GESTURE_SCROLL_BEGIN: - case EVENT_TYPE_GESTURE_SCROLL_END: - case EVENT_TYPE_GESTURE_SCROLL_UPDATE: - case EVENT_TYPE_GESTURE_SHOW_PRESS: - case EVENT_TYPE_GESTURE_TAP: - case EVENT_TYPE_GESTURE_TAP_DOWN: - return BuildWebGestureEvent(event, device_pixel_ratio); - case EVENT_TYPE_BACK: - return BuildWebBackEvent(event); - case EVENT_TYPE_UNKNOWN: - NOTIMPLEMENTED() << "ConvertEvent received unexpected EVENT_TYPE_UNKNOWN"; - } - - return scoped_ptr(); -} - -} // namespace mojo diff --git a/engine/src/flutter/shell/ui/input_event_converter.h b/engine/src/flutter/shell/ui/input_event_converter.h deleted file mode 100644 index 0b66bf5a06..0000000000 --- a/engine/src/flutter/shell/ui/input_event_converter.h +++ /dev/null @@ -1,21 +0,0 @@ -// Copyright 2015 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. - -#ifndef SKY_SHELL_UI_INPUT_EVENT_CONVERTER_H_ -#define SKY_SHELL_UI_INPUT_EVENT_CONVERTER_H_ - -#include "base/memory/scoped_ptr.h" -#include "sky/services/engine/input_event.mojom.h" - -namespace blink { -class WebInputEvent; -} - -namespace sky { - -scoped_ptr ConvertEvent(const InputEventPtr& event, - float device_pixel_ratio); -} - -#endif // SKY_SHELL_UI_INPUT_EVENT_CONVERTER_H_ diff --git a/engine/src/flutter/shell/ui/internals.cc b/engine/src/flutter/shell/ui/internals.cc deleted file mode 100644 index e87b7520a0..0000000000 --- a/engine/src/flutter/shell/ui/internals.cc +++ /dev/null @@ -1,124 +0,0 @@ -// 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. - -#include "sky/shell/ui/internals.h" - -#include "base/threading/worker_pool.h" -#include "mojo/public/cpp/application/connect.h" -#include "mojo/public/cpp/bindings/array.h" -#include "services/asset_bundle/asset_unpacker_impl.h" -#include "sky/engine/tonic/dart_builtin.h" -#include "sky/engine/tonic/dart_converter.h" -#include "sky/engine/tonic/dart_error.h" -#include "sky/engine/tonic/dart_state.h" - -using namespace blink; - -namespace sky { -namespace shell { -namespace { - -int kInternalsKey = 0; - -Internals* GetInternals() { - DartState* state = DartState::Current(); - return static_cast(state->GetUserData(&kInternalsKey)); -} - -void NotifyTestComplete(Dart_NativeArguments args) { -} - -void TakeRootBundleHandle(Dart_NativeArguments args) { - Dart_SetIntegerReturnValue( - args, GetInternals()->TakeRootBundleHandle().value()); -} - -void TakeShellProxyHandle(Dart_NativeArguments args) { - Dart_SetIntegerReturnValue(args, 0); -} - -void TakeServicesProvidedByEmbedder(Dart_NativeArguments args) { - Dart_SetIntegerReturnValue( - args, GetInternals()->TakeServicesProvidedByEmbedder().value()); -} - -void TakeServicesProvidedToEmbedder(Dart_NativeArguments args) { - Dart_SetIntegerReturnValue(args, 0); -} - -void TakeServiceRegistry(Dart_NativeArguments args) { - Dart_SetIntegerReturnValue(args, 0); -} - -const DartBuiltin::Natives kNativeFunctions[] = { - {"notifyTestComplete", NotifyTestComplete, 1}, - {"takeRootBundleHandle", TakeRootBundleHandle, 0}, - {"takeServiceRegistry", TakeServiceRegistry, 0}, - {"takeServicesProvidedByEmbedder", TakeServicesProvidedByEmbedder, 0}, - {"takeServicesProvidedToEmbedder", TakeServicesProvidedToEmbedder, 0}, - {"takeShellProxyHandle", TakeShellProxyHandle, 0}, -}; - -const DartBuiltin& GetBuiltin() { - static DartBuiltin& builtin = *new DartBuiltin(kNativeFunctions, - arraysize(kNativeFunctions)); - return builtin; -} - -Dart_NativeFunction Resolver(Dart_Handle name, - int argument_count, - bool* auto_setup_scope) { - return GetBuiltin().Resolver(name, argument_count, auto_setup_scope); -} - -const uint8_t* Symbolizer(Dart_NativeFunction native_function) { - return GetBuiltin().Symbolizer(native_function); -} - -const char kLibraryName[] = "dart:sky.internals"; - -} // namespace - -void Internals::Create(Dart_Isolate isolate, - mojo::ServiceProviderPtr service_provider, - mojo::asset_bundle::AssetBundlePtr root_bundle) { - DartState* state = DartState::From(isolate); - state->SetUserData(&kInternalsKey, new Internals(service_provider.Pass(), - root_bundle.Pass())); - Dart_Handle library = - Dart_LookupLibrary(Dart_NewStringFromCString(kLibraryName)); - CHECK(!LogIfError(library)); - CHECK(!LogIfError(Dart_SetNativeResolver(library, Resolver, Symbolizer))); -} - -Internals::Internals(mojo::ServiceProviderPtr platform_service_provider, - mojo::asset_bundle::AssetBundlePtr root_bundle) - : root_bundle_(root_bundle.Pass()), - service_provider_impl_(GetProxy(&service_provider_)), - platform_service_provider_(platform_service_provider.Pass()) { - service_provider_impl_.set_fallback_service_provider( - platform_service_provider_.get()); - service_provider_impl_.AddService(this); -} - -Internals::~Internals() { -} - -void Internals::Create( - mojo::ApplicationConnection* connection, - mojo::InterfaceRequest request) { - new mojo::asset_bundle::AssetUnpackerImpl( - request.Pass(), base::WorkerPool::GetTaskRunner(true)); -} - -mojo::Handle Internals::TakeServicesProvidedByEmbedder() { - return service_provider_.PassInterface().PassHandle().release(); -} - -mojo::Handle Internals::TakeRootBundleHandle() { - return root_bundle_.PassInterface().PassHandle().release(); -} - -} // namespace shell -} // namespace sky diff --git a/engine/src/flutter/shell/ui/internals.h b/engine/src/flutter/shell/ui/internals.h deleted file mode 100644 index e2eb38cabb..0000000000 --- a/engine/src/flutter/shell/ui/internals.h +++ /dev/null @@ -1,55 +0,0 @@ -// 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. - -#ifndef SKY_SHELL_UI_INTERNALS_H_ -#define SKY_SHELL_UI_INTERNALS_H_ - -#include "base/supports_user_data.h" -#include "dart/runtime/include/dart_api.h" -#include "mojo/public/cpp/application/interface_factory.h" -#include "mojo/public/cpp/application/service_provider_impl.h" -#include "mojo/public/interfaces/application/service_provider.mojom.h" -#include "mojo/services/asset_bundle/public/interfaces/asset_bundle.mojom.h" - -namespace mojo { -class ApplicationConnection; -} - -namespace sky { -namespace shell { - -class Internals - : public base::SupportsUserData::Data, - public mojo::InterfaceFactory { - public: - ~Internals() override; - - static void Create(Dart_Isolate isolate, - mojo::ServiceProviderPtr platform_service_provider, - mojo::asset_bundle::AssetBundlePtr root_bundle); - - mojo::Handle TakeServicesProvidedByEmbedder(); - mojo::Handle TakeRootBundleHandle(); - - private: - explicit Internals(mojo::ServiceProviderPtr platform_service_provider, - mojo::asset_bundle::AssetBundlePtr root_bundle); - - // |mojo::InterfaceFactory| implementation: - void Create( - mojo::ApplicationConnection* connection, - mojo::InterfaceRequest) override; - - mojo::asset_bundle::AssetBundlePtr root_bundle_; - mojo::ServiceProviderPtr service_provider_; - mojo::ServiceProviderImpl service_provider_impl_; - mojo::ServiceProviderPtr platform_service_provider_; - - MOJO_DISALLOW_COPY_AND_ASSIGN(Internals); -}; - -} // namespace shell -} // namespace sky - -#endif // SKY_SHELL_UI_INTERNALS_H_ diff --git a/engine/src/flutter/shell/ui/platform_impl.cc b/engine/src/flutter/shell/ui/platform_impl.cc deleted file mode 100644 index dca0039fd3..0000000000 --- a/engine/src/flutter/shell/ui/platform_impl.cc +++ /dev/null @@ -1,26 +0,0 @@ -// Copyright 2015 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. - -#include "sky/shell/ui/platform_impl.h" - -namespace sky { -namespace shell { - -PlatformImpl::PlatformImpl() - : main_thread_task_runner_(base::MessageLoop::current()->task_runner()) { -} - -PlatformImpl::~PlatformImpl() { -} - -blink::WebString PlatformImpl::defaultLocale() { - return blink::WebString::fromUTF8("en-US"); -} - -base::SingleThreadTaskRunner* PlatformImpl::mainThreadTaskRunner() { - return main_thread_task_runner_.get(); -} - -} // namespace shell -} // namespace sky diff --git a/engine/src/flutter/shell/ui/platform_impl.h b/engine/src/flutter/shell/ui/platform_impl.h deleted file mode 100644 index 669e8c2b31..0000000000 --- a/engine/src/flutter/shell/ui/platform_impl.h +++ /dev/null @@ -1,32 +0,0 @@ -// 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. - -#ifndef SKY_SHELL_UI_PLATFORM_IMPL_H_ -#define SKY_SHELL_UI_PLATFORM_IMPL_H_ - -#include "base/message_loop/message_loop.h" -#include "sky/engine/public/platform/Platform.h" - -namespace sky { -namespace shell { - -class PlatformImpl : public blink::Platform { - public: - explicit PlatformImpl(); - ~PlatformImpl() override; - - // blink::Platform methods: - blink::WebString defaultLocale() override; - base::SingleThreadTaskRunner* mainThreadTaskRunner() override; - - private: - scoped_refptr main_thread_task_runner_; - - DISALLOW_COPY_AND_ASSIGN(PlatformImpl); -}; - -} // namespace shell -} // namespace sky - -#endif // SKY_SHELL_UI_PLATFORM_IMPL_H_ diff --git a/engine/src/flutter/shell/ui_delegate.cc b/engine/src/flutter/shell/ui_delegate.cc deleted file mode 100644 index e35b192432..0000000000 --- a/engine/src/flutter/shell/ui_delegate.cc +++ /dev/null @@ -1,14 +0,0 @@ -// Copyright 2015 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. - -#include "sky/shell/ui_delegate.h" - -namespace sky { -namespace shell { - -UIDelegate::~UIDelegate() { -} - -} // namespace shell -} // namespace sky diff --git a/engine/src/flutter/shell/ui_delegate.h b/engine/src/flutter/shell/ui_delegate.h deleted file mode 100644 index a32d2e4eaf..0000000000 --- a/engine/src/flutter/shell/ui_delegate.h +++ /dev/null @@ -1,29 +0,0 @@ -// Copyright 2015 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. - -#ifndef SKY_SHELL_UI_DELEGATE_H_ -#define SKY_SHELL_UI_DELEGATE_H_ - -#include "mojo/public/cpp/bindings/interface_request.h" -#include "sky/services/engine/sky_engine.mojom.h" -#include "ui/gfx/geometry/size.h" -#include "ui/gfx/native_widget_types.h" - -namespace sky { -namespace shell { - -class UIDelegate { - public: - virtual void ConnectToEngine(mojo::InterfaceRequest request) = 0; - virtual void OnAcceleratedWidgetAvailable(gfx::AcceleratedWidget widget) = 0; - virtual void OnOutputSurfaceDestroyed() = 0; - - protected: - virtual ~UIDelegate(); -}; - -} // namespace shell -} // namespace sky - -#endif // SKY_SHELL_UI_DELEGATE_H_ diff --git a/engine/src/flutter/BUILD.gn b/engine/src/flutter/sky/BUILD.gn similarity index 100% rename from engine/src/flutter/BUILD.gn rename to engine/src/flutter/sky/BUILD.gn diff --git a/engine/src/flutter/HACKING.md b/engine/src/flutter/sky/HACKING.md similarity index 100% rename from engine/src/flutter/HACKING.md rename to engine/src/flutter/sky/HACKING.md diff --git a/engine/src/flutter/README.md b/engine/src/flutter/sky/README.md similarity index 100% rename from engine/src/flutter/README.md rename to engine/src/flutter/sky/README.md diff --git a/engine/src/flutter/tools/android_library_cacher.py b/engine/src/flutter/sky/tools/android_library_cacher.py similarity index 100% rename from engine/src/flutter/tools/android_library_cacher.py rename to engine/src/flutter/sky/tools/android_library_cacher.py diff --git a/engine/src/flutter/tools/big_red_button.py b/engine/src/flutter/sky/tools/big_red_button.py similarity index 100% rename from engine/src/flutter/tools/big_red_button.py rename to engine/src/flutter/sky/tools/big_red_button.py diff --git a/engine/src/flutter/tools/deploy_sdk.py b/engine/src/flutter/sky/tools/deploy_sdk.py similarity index 100% rename from engine/src/flutter/tools/deploy_sdk.py rename to engine/src/flutter/sky/tools/deploy_sdk.py diff --git a/engine/src/flutter/tools/imagediff/BUILD.gn b/engine/src/flutter/sky/tools/imagediff/BUILD.gn similarity index 100% rename from engine/src/flutter/tools/imagediff/BUILD.gn rename to engine/src/flutter/sky/tools/imagediff/BUILD.gn diff --git a/engine/src/flutter/tools/imagediff/image_diff.cc b/engine/src/flutter/sky/tools/imagediff/image_diff.cc similarity index 100% rename from engine/src/flutter/tools/imagediff/image_diff.cc rename to engine/src/flutter/sky/tools/imagediff/image_diff.cc diff --git a/engine/src/flutter/tools/imagediff/image_diff_png.cc b/engine/src/flutter/sky/tools/imagediff/image_diff_png.cc similarity index 100% rename from engine/src/flutter/tools/imagediff/image_diff_png.cc rename to engine/src/flutter/sky/tools/imagediff/image_diff_png.cc diff --git a/engine/src/flutter/tools/imagediff/image_diff_png.h b/engine/src/flutter/sky/tools/imagediff/image_diff_png.h similarity index 100% rename from engine/src/flutter/tools/imagediff/image_diff_png.h rename to engine/src/flutter/sky/tools/imagediff/image_diff_png.h diff --git a/engine/src/flutter/tools/lint_test_expectations b/engine/src/flutter/sky/tools/lint_test_expectations similarity index 100% rename from engine/src/flutter/tools/lint_test_expectations rename to engine/src/flutter/sky/tools/lint_test_expectations diff --git a/engine/src/flutter/tools/lint_webkitpy b/engine/src/flutter/sky/tools/lint_webkitpy similarity index 100% rename from engine/src/flutter/tools/lint_webkitpy rename to engine/src/flutter/sky/tools/lint_webkitpy diff --git a/engine/src/flutter/tools/missing_from_gn b/engine/src/flutter/sky/tools/missing_from_gn similarity index 100% rename from engine/src/flutter/tools/missing_from_gn rename to engine/src/flutter/sky/tools/missing_from_gn diff --git a/engine/src/flutter/tools/mojo_cache_linker.py b/engine/src/flutter/sky/tools/mojo_cache_linker.py similarity index 100% rename from engine/src/flutter/tools/mojo_cache_linker.py rename to engine/src/flutter/sky/tools/mojo_cache_linker.py diff --git a/engine/src/flutter/tools/packager/BUILD.gn b/engine/src/flutter/sky/tools/packager/BUILD.gn similarity index 100% rename from engine/src/flutter/tools/packager/BUILD.gn rename to engine/src/flutter/sky/tools/packager/BUILD.gn diff --git a/engine/src/flutter/tools/packager/loader.cc b/engine/src/flutter/sky/tools/packager/loader.cc similarity index 100% rename from engine/src/flutter/tools/packager/loader.cc rename to engine/src/flutter/sky/tools/packager/loader.cc diff --git a/engine/src/flutter/tools/packager/loader.h b/engine/src/flutter/sky/tools/packager/loader.h similarity index 100% rename from engine/src/flutter/tools/packager/loader.h rename to engine/src/flutter/sky/tools/packager/loader.h diff --git a/engine/src/flutter/tools/packager/logging.cc b/engine/src/flutter/sky/tools/packager/logging.cc similarity index 100% rename from engine/src/flutter/tools/packager/logging.cc rename to engine/src/flutter/sky/tools/packager/logging.cc diff --git a/engine/src/flutter/tools/packager/logging.h b/engine/src/flutter/sky/tools/packager/logging.h similarity index 100% rename from engine/src/flutter/tools/packager/logging.h rename to engine/src/flutter/sky/tools/packager/logging.h diff --git a/engine/src/flutter/tools/packager/main.cc b/engine/src/flutter/sky/tools/packager/main.cc similarity index 100% rename from engine/src/flutter/tools/packager/main.cc rename to engine/src/flutter/sky/tools/packager/main.cc diff --git a/engine/src/flutter/tools/packager/scope.h b/engine/src/flutter/sky/tools/packager/scope.h similarity index 100% rename from engine/src/flutter/tools/packager/scope.h rename to engine/src/flutter/sky/tools/packager/scope.h diff --git a/engine/src/flutter/tools/packager/switches.cc b/engine/src/flutter/sky/tools/packager/switches.cc similarity index 100% rename from engine/src/flutter/tools/packager/switches.cc rename to engine/src/flutter/sky/tools/packager/switches.cc diff --git a/engine/src/flutter/tools/packager/switches.h b/engine/src/flutter/sky/tools/packager/switches.h similarity index 100% rename from engine/src/flutter/tools/packager/switches.h rename to engine/src/flutter/sky/tools/packager/switches.h diff --git a/engine/src/flutter/tools/packager/vm.cc b/engine/src/flutter/sky/tools/packager/vm.cc similarity index 100% rename from engine/src/flutter/tools/packager/vm.cc rename to engine/src/flutter/sky/tools/packager/vm.cc diff --git a/engine/src/flutter/tools/packager/vm.h b/engine/src/flutter/sky/tools/packager/vm.h similarity index 100% rename from engine/src/flutter/tools/packager/vm.h rename to engine/src/flutter/sky/tools/packager/vm.h diff --git a/engine/src/flutter/tools/pretty-diff b/engine/src/flutter/sky/tools/pretty-diff similarity index 100% rename from engine/src/flutter/tools/pretty-diff rename to engine/src/flutter/sky/tools/pretty-diff diff --git a/engine/src/flutter/tools/publish_apk.py b/engine/src/flutter/sky/tools/publish_apk.py similarity index 100% rename from engine/src/flutter/tools/publish_apk.py rename to engine/src/flutter/sky/tools/publish_apk.py diff --git a/engine/src/flutter/tools/resurrect.py b/engine/src/flutter/sky/tools/resurrect.py similarity index 100% rename from engine/src/flutter/tools/resurrect.py rename to engine/src/flutter/sky/tools/resurrect.py diff --git a/engine/src/flutter/tools/roll_versions.py b/engine/src/flutter/sky/tools/roll_versions.py similarity index 100% rename from engine/src/flutter/tools/roll_versions.py rename to engine/src/flutter/sky/tools/roll_versions.py diff --git a/engine/src/flutter/tools/setup_dart_analyzer b/engine/src/flutter/sky/tools/setup_dart_analyzer similarity index 100% rename from engine/src/flutter/tools/setup_dart_analyzer rename to engine/src/flutter/sky/tools/setup_dart_analyzer diff --git a/engine/src/flutter/tools/shelldb b/engine/src/flutter/sky/tools/shelldb similarity index 100% rename from engine/src/flutter/tools/shelldb rename to engine/src/flutter/sky/tools/shelldb diff --git a/engine/src/flutter/tools/sky_packager.py b/engine/src/flutter/sky/tools/sky_packager.py similarity index 100% rename from engine/src/flutter/tools/sky_packager.py rename to engine/src/flutter/sky/tools/sky_packager.py diff --git a/engine/src/flutter/tools/skyanalyzer b/engine/src/flutter/sky/tools/skyanalyzer similarity index 100% rename from engine/src/flutter/tools/skyanalyzer rename to engine/src/flutter/sky/tools/skyanalyzer diff --git a/engine/src/flutter/tools/skydoc.py b/engine/src/flutter/sky/tools/skydoc.py similarity index 100% rename from engine/src/flutter/tools/skydoc.py rename to engine/src/flutter/sky/tools/skydoc.py diff --git a/engine/src/flutter/tools/skygo/README.md b/engine/src/flutter/sky/tools/skygo/README.md similarity index 100% rename from engine/src/flutter/tools/skygo/README.md rename to engine/src/flutter/sky/tools/skygo/README.md diff --git a/engine/src/flutter/tools/skygo/linux64/sky_server.sha1 b/engine/src/flutter/sky/tools/skygo/linux64/sky_server.sha1 similarity index 100% rename from engine/src/flutter/tools/skygo/linux64/sky_server.sha1 rename to engine/src/flutter/sky/tools/skygo/linux64/sky_server.sha1 diff --git a/engine/src/flutter/tools/skygo/mac/sky_server.sha1 b/engine/src/flutter/sky/tools/skygo/mac/sky_server.sha1 similarity index 100% rename from engine/src/flutter/tools/skygo/mac/sky_server.sha1 rename to engine/src/flutter/sky/tools/skygo/mac/sky_server.sha1 diff --git a/engine/src/flutter/tools/skygo/sky_server.go b/engine/src/flutter/sky/tools/skygo/sky_server.go similarity index 100% rename from engine/src/flutter/tools/skygo/sky_server.go rename to engine/src/flutter/sky/tools/skygo/sky_server.go diff --git a/engine/src/flutter/tools/skypy/__init__.py b/engine/src/flutter/sky/tools/skypy/__init__.py similarity index 100% rename from engine/src/flutter/tools/skypy/__init__.py rename to engine/src/flutter/sky/tools/skypy/__init__.py diff --git a/engine/src/flutter/tools/skypy/configuration.py b/engine/src/flutter/sky/tools/skypy/configuration.py similarity index 100% rename from engine/src/flutter/tools/skypy/configuration.py rename to engine/src/flutter/sky/tools/skypy/configuration.py diff --git a/engine/src/flutter/tools/skypy/find_tests.py b/engine/src/flutter/sky/tools/skypy/find_tests.py similarity index 100% rename from engine/src/flutter/tools/skypy/find_tests.py rename to engine/src/flutter/sky/tools/skypy/find_tests.py diff --git a/engine/src/flutter/tools/skypy/paths.py b/engine/src/flutter/sky/tools/skypy/paths.py similarity index 100% rename from engine/src/flutter/tools/skypy/paths.py rename to engine/src/flutter/sky/tools/skypy/paths.py diff --git a/engine/src/flutter/tools/skypy/skyserver.py b/engine/src/flutter/sky/tools/skypy/skyserver.py similarity index 100% rename from engine/src/flutter/tools/skypy/skyserver.py rename to engine/src/flutter/sky/tools/skypy/skyserver.py diff --git a/engine/src/flutter/tools/skypy/url_mappings.py b/engine/src/flutter/sky/tools/skypy/url_mappings.py similarity index 100% rename from engine/src/flutter/tools/skypy/url_mappings.py rename to engine/src/flutter/sky/tools/skypy/url_mappings.py diff --git a/engine/src/flutter/tools/skyx.py b/engine/src/flutter/sky/tools/skyx.py similarity index 100% rename from engine/src/flutter/tools/skyx.py rename to engine/src/flutter/sky/tools/skyx.py diff --git a/engine/src/flutter/tools/skyx/.gitignore b/engine/src/flutter/sky/tools/skyx/.gitignore similarity index 100% rename from engine/src/flutter/tools/skyx/.gitignore rename to engine/src/flutter/sky/tools/skyx/.gitignore diff --git a/engine/src/flutter/tools/skyx/LICENSE b/engine/src/flutter/sky/tools/skyx/LICENSE similarity index 100% rename from engine/src/flutter/tools/skyx/LICENSE rename to engine/src/flutter/sky/tools/skyx/LICENSE diff --git a/engine/src/flutter/tools/skyx/bin/skyx.dart b/engine/src/flutter/sky/tools/skyx/bin/skyx.dart similarity index 100% rename from engine/src/flutter/tools/skyx/bin/skyx.dart rename to engine/src/flutter/sky/tools/skyx/bin/skyx.dart diff --git a/engine/src/flutter/tools/skyx/pubspec.yaml b/engine/src/flutter/sky/tools/skyx/pubspec.yaml similarity index 100% rename from engine/src/flutter/tools/skyx/pubspec.yaml rename to engine/src/flutter/sky/tools/skyx/pubspec.yaml diff --git a/engine/src/flutter/tools/staticdirindex.py b/engine/src/flutter/sky/tools/staticdirindex.py similarity index 100% rename from engine/src/flutter/tools/staticdirindex.py rename to engine/src/flutter/sky/tools/staticdirindex.py diff --git a/engine/src/flutter/tools/test_bindings b/engine/src/flutter/sky/tools/test_bindings similarity index 100% rename from engine/src/flutter/tools/test_bindings rename to engine/src/flutter/sky/tools/test_bindings diff --git a/engine/src/flutter/tools/test_perf b/engine/src/flutter/sky/tools/test_perf similarity index 100% rename from engine/src/flutter/tools/test_perf rename to engine/src/flutter/sky/tools/test_perf diff --git a/engine/src/flutter/tools/test_sky b/engine/src/flutter/sky/tools/test_sky similarity index 100% rename from engine/src/flutter/tools/test_sky rename to engine/src/flutter/sky/tools/test_sky diff --git a/engine/src/flutter/tools/test_webkitpy b/engine/src/flutter/sky/tools/test_webkitpy similarity index 100% rename from engine/src/flutter/tools/test_webkitpy rename to engine/src/flutter/sky/tools/test_webkitpy diff --git a/engine/src/flutter/tools/third_party/PrettyPatch/PrettyPatch.rb b/engine/src/flutter/sky/tools/third_party/PrettyPatch/PrettyPatch.rb similarity index 100% rename from engine/src/flutter/tools/third_party/PrettyPatch/PrettyPatch.rb rename to engine/src/flutter/sky/tools/third_party/PrettyPatch/PrettyPatch.rb diff --git a/engine/src/flutter/tools/third_party/PrettyPatch/PrettyPatch_test.rb b/engine/src/flutter/sky/tools/third_party/PrettyPatch/PrettyPatch_test.rb similarity index 100% rename from engine/src/flutter/tools/third_party/PrettyPatch/PrettyPatch_test.rb rename to engine/src/flutter/sky/tools/third_party/PrettyPatch/PrettyPatch_test.rb diff --git a/engine/src/flutter/tools/third_party/PrettyPatch/diff.rb b/engine/src/flutter/sky/tools/third_party/PrettyPatch/diff.rb similarity index 100% rename from engine/src/flutter/tools/third_party/PrettyPatch/diff.rb rename to engine/src/flutter/sky/tools/third_party/PrettyPatch/diff.rb diff --git a/engine/src/flutter/tools/third_party/PrettyPatch/prettify.rb b/engine/src/flutter/sky/tools/third_party/PrettyPatch/prettify.rb similarity index 100% rename from engine/src/flutter/tools/third_party/PrettyPatch/prettify.rb rename to engine/src/flutter/sky/tools/third_party/PrettyPatch/prettify.rb diff --git a/engine/src/flutter/tests/TestExpectations b/engine/src/flutter/tests/TestExpectations deleted file mode 100644 index efa98a5c4d..0000000000 --- a/engine/src/flutter/tests/TestExpectations +++ /dev/null @@ -1,2 +0,0 @@ -# This test depends on events.md being implemented -crbug.com/1 events/dispatcher.dart [ Skip ] diff --git a/engine/src/flutter/tests/dom/appendChild-expected.txt b/engine/src/flutter/tests/dom/appendChild-expected.txt deleted file mode 100644 index 66cd2b233e..0000000000 --- a/engine/src/flutter/tests/dom/appendChild-expected.txt +++ /dev/null @@ -1,8 +0,0 @@ -unittest-suite-wait-for-done -PASS: should throw with invalid arguments -PASS: should insert children -PASS: should insert children with a fragment - -All 3 tests passed. -unittest-suite-success -DONE diff --git a/engine/src/flutter/tests/dom/appendChild.dart b/engine/src/flutter/tests/dom/appendChild.dart deleted file mode 100644 index 5f9a2333f5..0000000000 --- a/engine/src/flutter/tests/dom/appendChild.dart +++ /dev/null @@ -1,78 +0,0 @@ -import "../resources/dom_utils.dart"; -import "../resources/third_party/unittest/unittest.dart"; -import "../resources/unit.dart"; - -import "dart:sky"; - -void main() { - initUnit(); - - Document document = new Document(); - - test("should throw with invalid arguments", () { - var parent = document.createElement("div"); - expect(() { - parent.appendChild(); - }, throws); - expect(() { - parent.appendChild(null); - }, throws); - expect(() { - parent.appendChild({tagName: "div"}); - }, throws); - }); - - test("should insert children", () { - var parent = document.createElement("div"); - var child1 = parent.appendChild(document.createElement("div")); - var child2 = parent.appendChild(document.createText(" text ")); - var child3 = parent.appendChild(document.createText(" ")); - var child4 = parent.appendChild(document.createElement("div")); - expect(child1.parentNode, equals(parent)); - expect(child2.parentNode, equals(parent)); - expect(child3.parentNode, equals(parent)); - expect(child4.parentNode, equals(parent)); - expect(childNodeCount(parent), equals(4)); - expect(childElementCount(parent), equals(2)); - }); - - test("should insert children with a fragment", () { - var fragment = document.createDocumentFragment(); - var child1 = fragment.appendChild(document.createElement("div")); - var child2 = fragment.appendChild(document.createText(" text ")); - var child3 = fragment.appendChild(document.createText(" ")); - var child4 = fragment.appendChild(document.createElement("div")); - var parent = document.createElement("div"); - parent.appendChild(fragment); - expect(child1.parentNode, equals(parent)); - expect(child2.parentNode, equals(parent)); - expect(child3.parentNode, equals(parent)); - expect(child4.parentNode, equals(parent)); - expect(childNodeCount(parent), equals(4)); - expect(childElementCount(parent), equals(2)); - }); - - // TODO(dart): These might be real bugs too. - // test("should throw when inserting a tree scope", () { - // var parent = document.createElement("div"); - // var doc = new Document(); - // var shadowRoot = document.createElement("span").ensureShadowRoot(); - // expect(() { - // parent.appendChild(doc); - // }, throws); - // expect(() { - // parent.appendChild(shadowRoot); - // }, throws); - // expect(() { - // doc.appendChild(fragment); - // }, throws); - // }); - - // TODO(dart): These might be real bugs too. - // test("should throw when appending to a text", () { - // var parent = new Text(); - // expect(() { - // parent.appendChild(document.createElement("div")); - // }, throws); - // }); -} diff --git a/engine/src/flutter/tests/dom/attribute_collection-expected.txt b/engine/src/flutter/tests/dom/attribute_collection-expected.txt deleted file mode 100644 index 4148c22b22..0000000000 --- a/engine/src/flutter/tests/dom/attribute_collection-expected.txt +++ /dev/null @@ -1,9 +0,0 @@ -unittest-suite-wait-for-done -PASS: should get by index -PASS: should set by name -PASS: should be case sensitive -PASS: should not live update - -All 4 tests passed. -unittest-suite-success -DONE diff --git a/engine/src/flutter/tests/dom/attribute_collection.dart b/engine/src/flutter/tests/dom/attribute_collection.dart deleted file mode 100644 index 87f2c3e0fc..0000000000 --- a/engine/src/flutter/tests/dom/attribute_collection.dart +++ /dev/null @@ -1,64 +0,0 @@ -import "../resources/third_party/unittest/unittest.dart"; -import "../resources/unit.dart"; - -import "dart:sky"; - -void main() { - initUnit(); - - var div; - setUp(() { - var document = new Document(); - div = document.createElement("div"); - }); - - test("should get by index", () { - div.setAttribute("attr0", "value0"); - div.setAttribute("attr1", "value1"); - var attrs = div.getAttributes(); - expect(attrs.length, equals(2)); - expect(attrs[0].name, equals("attr0")); - expect(attrs[0].value, equals("value0")); - expect(attrs[1].name, equals("attr1")); - expect(attrs[1].value, equals("value1")); - }); - test("should set by name", () { - div.setAttribute("attrName", "value0"); - expect(div.getAttribute("attrName"), equals("value0")); - expect(div.getAttributes()[0].name, equals("attrName")); - expect(div.getAttributes()[0].value, equals("value0")); - div.setAttribute("attrName", "new value"); - expect(div.getAttribute("attrName"), equals("new value")); - expect(div.getAttributes()[0].name, equals("attrName")); - expect(div.getAttributes()[0].value, equals("new value")); - }); - test("should be case sensitive", () { - div.setAttribute("attrName", "value0"); - expect(div.getAttribute("attrname"), isNull); - expect(div.getAttribute("attrName"), equals("value0")); - }); - test("should not live update", () { - div.setAttribute("attr0", "0"); - div.setAttribute("attr1", "1"); - div.setAttribute("attr2", "2"); - var oldAttributes = div.getAttributes(); - expect(oldAttributes.length, equals(3)); - div.removeAttribute("attr1"); - expect(oldAttributes.length, equals(3)); - div.setAttribute("attr0", "value0"); - div.setAttribute("attr2", "value2"); - var newAttributes = div.getAttributes(); - expect(newAttributes.length, equals(2)); - expect(newAttributes[0].name, equals("attr0")); - expect(newAttributes[0].value, equals("value0")); - expect(newAttributes[1].name, equals("attr2")); - expect(newAttributes[1].value, equals("value2")); - expect(newAttributes, isNot(equals(oldAttributes))); - expect(oldAttributes[0].name, equals("attr0")); - expect(oldAttributes[0].value, equals("0")); - expect(oldAttributes[1].name, equals("attr1")); - expect(oldAttributes[1].value, equals("1")); - expect(oldAttributes[2].name, equals("attr2")); - expect(oldAttributes[2].value, equals("2")); - }); -} diff --git a/engine/src/flutter/tests/dom/document_child_mutations-expected.txt b/engine/src/flutter/tests/dom/document_child_mutations-expected.txt deleted file mode 100644 index 31bb91109a..0000000000 --- a/engine/src/flutter/tests/dom/document_child_mutations-expected.txt +++ /dev/null @@ -1,12 +0,0 @@ -unittest-suite-wait-for-done -PASS: should allow replacing the document element -PASS: should allow replacing a text child with an element -PASS: should allow replacing the document element with text -PASS: should allow inserting text with a fragment -PASS: should allow replacing the document element with a fragment -PASS: should throw when inserting multiple elements -PASS: should throw when inserting multiple elements with a fragment - -All 7 tests passed. -unittest-suite-success -DONE diff --git a/engine/src/flutter/tests/dom/document_child_mutations.dart b/engine/src/flutter/tests/dom/document_child_mutations.dart deleted file mode 100644 index cc89c4d38f..0000000000 --- a/engine/src/flutter/tests/dom/document_child_mutations.dart +++ /dev/null @@ -1,101 +0,0 @@ -import "../resources/dom_utils.dart"; -import "../resources/third_party/unittest/unittest.dart"; -import "../resources/unit.dart"; - -import "dart:sky"; - -void main() { - initUnit(); - - var doc; - - setUp(() { - doc = new Document(); - }); - - test("should allow replacing the document element", () { - var oldChild = doc.appendChild(doc.createElement("div")); - expect(childElementCount(doc), equals(1)); - var newChild = doc.createElement("div"); - oldChild.replaceWith([newChild]); - expect(childElementCount(doc), equals(1)); - expect(newChild.parentNode, equals(doc)); - expect(oldChild.parentNode, isNull); - }); - - test("should allow replacing a text child with an element", () { - var oldChild = doc.appendChild(doc.createText("text here")); - expect(childElementCount(doc), equals(0)); - expect(childNodeCount(doc), equals(1)); - var newChild = doc.createElement("div"); - oldChild.replaceWith([newChild]); - expect(childElementCount(doc), equals(1)); - expect(childNodeCount(doc), equals(1)); - expect(newChild.parentNode, equals(doc)); - expect(oldChild.parentNode, isNull); - }); - - test("should allow replacing the document element with text", () { - var oldChild = doc.appendChild(doc.createElement("div")); - expect(childElementCount(doc), equals(1)); - var newChild = doc.createText(" text "); - oldChild.replaceWith([newChild]); - expect(childElementCount(doc), equals(0)); - expect(childNodeCount(doc), equals(1)); - expect(newChild.parentNode, equals(doc)); - expect(oldChild.parentNode, isNull); - }); - - test("should allow inserting text with a fragment", () { - var fragment = doc.createDocumentFragment(); - fragment.appendChild(doc.createText(" text ")); - fragment.appendChild(doc.createText(" text ")); - expect(childNodeCount(doc), equals(0)); - doc.appendChild(fragment); - expect(childElementCount(doc), equals(0)); - expect(childNodeCount(doc), equals(2)); - }); - - test("should allow replacing the document element with a fragment", () { - var oldChild = doc.appendChild(doc.createElement("div")); - expect(childElementCount(doc), equals(1)); - var fragment = doc.createDocumentFragment(); - fragment.appendChild(doc.createText(" text ")); - var newChild = fragment.appendChild(doc.createElement("div")); - fragment.appendChild(doc.createText(" ")); - oldChild.replaceWith([fragment]); - expect(childElementCount(doc), equals(1)); - expect(childNodeCount(doc), equals(3)); - expect(newChild.parentNode, equals(doc)); - expect(oldChild.parentNode, isNull); - }); - - test("should throw when inserting multiple elements", () { - doc.appendChild(doc.createElement("div")); - var oldChild = doc.appendChild(doc.createText(" text ")); - expect(childElementCount(doc), equals(1)); - var newChild = doc.createElement("div"); - // expect(() { - // doc.replaceChild(newChild, 0); - // }, throws); - // expect(() { - // doc.insertBefore(newChild, oldChild); - // }, throws); - }); - - test("should throw when inserting multiple elements with a fragment", () { - var oldChild = doc.appendChild(doc.createElement("div")); - expect(childElementCount(doc), equals(1)); - var fragment = doc.createDocumentFragment(); - fragment.appendChild(doc.createText(" text ")); - fragment.appendChild(doc.createElement("div")); - fragment.appendChild(doc.createElement("div")); - fragment.appendChild(doc.createText(" ")); - // expect(() { - // doc.replaceChild(fragment, 0); - // }, throws); - // expect(() { - // doc.insertBefore(fragment, oldChild); - // }, throws); - }); -} diff --git a/engine/src/flutter/tests/dom/getChildElements-expected.txt b/engine/src/flutter/tests/dom/getChildElements-expected.txt deleted file mode 100644 index fd3d56c2ac..0000000000 --- a/engine/src/flutter/tests/dom/getChildElements-expected.txt +++ /dev/null @@ -1,6 +0,0 @@ -unittest-suite-wait-for-done -PASS: getChildElements should only include immediate children - -All 1 tests passed. -unittest-suite-success -DONE diff --git a/engine/src/flutter/tests/dom/getChildElements.dart b/engine/src/flutter/tests/dom/getChildElements.dart deleted file mode 100644 index c5ce427799..0000000000 --- a/engine/src/flutter/tests/dom/getChildElements.dart +++ /dev/null @@ -1,26 +0,0 @@ -import "../resources/third_party/unittest/unittest.dart"; -import "../resources/unit.dart"; - -import "dart:sky"; - -void main() { - initUnit(); - - test("getChildElements should only include immediate children", () { - var doc = new Document(); - var parent = doc.createElement('parent'); - var child1 = doc.createElement('child1'); - var child2 = doc.createElement('child1'); - var grandchild = doc.createElement('grandchild'); - - doc.appendChild(parent); - parent.appendChild(child1); - parent.appendChild(child2); - child1.appendChild(grandchild); - - var children = parent.getChildElements(); - expect(children.length, equals(2)); - expect(children[0], equals(child1)); - expect(children[1], equals(child2)); - }); -} diff --git a/engine/src/flutter/tests/dom/ownerScope-expected.txt b/engine/src/flutter/tests/dom/ownerScope-expected.txt deleted file mode 100644 index e17fc2abd3..0000000000 --- a/engine/src/flutter/tests/dom/ownerScope-expected.txt +++ /dev/null @@ -1,10 +0,0 @@ -unittest-suite-wait-for-done -PASS: should return null for elements not a child of a scope -PASS: should return the document for elements in the document scope -PASS: should return the shadow root for elements in the shadow root scope -PASS: should return self for a shadow root or document -PASS: should dynamically update - -All 5 tests passed. -unittest-suite-success -DONE diff --git a/engine/src/flutter/tests/dom/ownerScope.dart b/engine/src/flutter/tests/dom/ownerScope.dart deleted file mode 100644 index 7f7b2c273c..0000000000 --- a/engine/src/flutter/tests/dom/ownerScope.dart +++ /dev/null @@ -1,47 +0,0 @@ -import "../resources/third_party/unittest/unittest.dart"; -import "../resources/unit.dart"; - -import "dart:sky"; - -void main() { - initUnit(); - - test("should return null for elements not a child of a scope", () { - var doc = new Document(); - var element = doc.createElement("div"); - expect(element.owner, isNull); - }); - test("should return the document for elements in the document scope", () { - var doc = new Document(); - var element = doc.createElement("div"); - doc.appendChild(element); - expect(element.owner, equals(doc)); - }); - test("should return the shadow root for elements in the shadow root scope", () { - var doc = new Document(); - var host = doc.createElement("div"); - var child = doc.createElement("div"); - var shadowRoot = host.ensureShadowRoot(); - shadowRoot.appendChild(child); - expect(child.owner, equals(shadowRoot)); - }); - test("should return self for a shadow root or document", () { - var doc = new Document(); - var host = doc.createElement("div"); - doc.appendChild(host); - var shadowRoot = host.ensureShadowRoot(); - expect(shadowRoot.owner, equals(shadowRoot)); - expect(doc.owner, equals(doc)); - }); - test("should dynamically update", () { - var doc = new Document(); - var host = doc.createElement("div"); - var child = doc.createElement("div"); - var shadowRoot = host.ensureShadowRoot(); - expect(child.owner, isNull); - shadowRoot.appendChild(child); - expect(child.owner, equals(shadowRoot)); - child.remove(); - expect(child.owner, isNull); - }); -} diff --git a/engine/src/flutter/tests/dom/replaceChild-expected.txt b/engine/src/flutter/tests/dom/replaceChild-expected.txt deleted file mode 100644 index 3d7e353309..0000000000 --- a/engine/src/flutter/tests/dom/replaceChild-expected.txt +++ /dev/null @@ -1,8 +0,0 @@ -unittest-suite-wait-for-done -PASS: should replace elements -PASS: should replace text -PASS: should replace children with a fragment - -All 3 tests passed. -unittest-suite-success -DONE diff --git a/engine/src/flutter/tests/dom/replaceChild.dart b/engine/src/flutter/tests/dom/replaceChild.dart deleted file mode 100644 index bef11f1f21..0000000000 --- a/engine/src/flutter/tests/dom/replaceChild.dart +++ /dev/null @@ -1,71 +0,0 @@ -import "../resources/dom_utils.dart"; -import "../resources/third_party/unittest/unittest.dart"; -import "../resources/unit.dart"; - -import "dart:sky"; - -void main() { - initUnit(); - - var document = new Document(); - - test("should replace elements", () { - var parent = document.createElement("div"); - var oldChild = parent.appendChild(document.createElement("div")); - var newChild = document.createElement("div"); - oldChild.replaceWith([newChild]); - expect(oldChild.parentNode, isNull); - expect(newChild.parentNode, equals(parent)); - }); - - test("should replace text", () { - var parent = document.createElement("div"); - var oldChild = parent.appendChild(document.createText(" it's a text ")); - var newChild = document.createElement("div"); - oldChild.replaceWith([newChild]); - expect(oldChild.parentNode, isNull); - expect(newChild.parentNode, equals(parent)); - }); - - test("should replace children with a fragment", () { - var fragment = document.createDocumentFragment(); - var child1 = fragment.appendChild(document.createElement("div")); - var child2 = fragment.appendChild(document.createText(" text ")); - var child3 = fragment.appendChild(document.createText(" ")); - var child4 = fragment.appendChild(document.createElement("div")); - var parent = document.createElement("div"); - var oldChild = parent.appendChild(document.createElement("div")); - var lastChild = parent.appendChild(document.createElement("div")); - oldChild.replaceWith([fragment]); - expect(child1.parentNode, equals(parent)); - expect(child2.parentNode, equals(parent)); - expect(child3.parentNode, equals(parent)); - expect(child4.parentNode, equals(parent)); - expect(oldChild.parentNode, isNull); - expect(childNodeCount(parent), equals(5)); - expect(childElementCount(parent), equals(3)); - expect(parent.lastChild, equals(lastChild)); - }); - - // test("should throw when inserting a tree scope", () { - // var parent = document.createElement("div"); - // var doc = new Document(); - // var shadowRoot = document.createElement("span").ensureShadowRoot(); - // expect(() { - // parent.replaceChild(doc); - // }, throws); - // expect(() { - // parent.replaceChild(shadowRoot); - // }, throws); - // expect(() { - // doc.replaceChild(fragment); - // }, throws); - // }); - - // test("should throw when appending to a text", () { - // var parent = new Text(); - // expect(() { - // parent.replaceChild(document.createElement("div"), null); - // }, throws); - // }); -} diff --git a/engine/src/flutter/tests/events/dispatcher-expected.txt b/engine/src/flutter/tests/events/dispatcher-expected.txt deleted file mode 100644 index bf3bb1bdd7..0000000000 --- a/engine/src/flutter/tests/events/dispatcher-expected.txt +++ /dev/null @@ -1,12 +0,0 @@ -CONSOLE: unittest-suite-wait-for-done -CONSOLE: PASS: Dispatcher simple listen -CONSOLE: PASS: Dispatcher firstWhere -CONSOLE: PASS: Dispatcher where -CONSOLE: PASS: Dispatcher where without listener -CONSOLE: PASS: Dispatcher where with listeners removed -CONSOLE: PASS: Dispatcher double listeners -CONSOLE: PASS: Dispatcher zones -CONSOLE: -CONSOLE: All 7 tests passed. -CONSOLE: unittest-suite-success -DONE diff --git a/engine/src/flutter/tests/events/dispatcher.dart b/engine/src/flutter/tests/events/dispatcher.dart deleted file mode 100644 index 29bfeefcc8..0000000000 --- a/engine/src/flutter/tests/events/dispatcher.dart +++ /dev/null @@ -1,101 +0,0 @@ -import "../resources/third_party/unittest/unittest.dart"; -import "../resources/unit.dart"; -import "dart:sky"; -import 'dart:async'; - -void send20IntegersToDispatcherController(DispatcherController d) { - for (var index = 0; index < 20; index += 1) - d.add(index); -} - -void main() { - initUnit(); - - group('Dispatcher', () { - - test('simple listen', () { - var d = new DispatcherController(); - var result = new List(); - d.dispatcher.listen((v) => result.add(v)); - send20IntegersToDispatcherController(d); - expect(result, orderedEquals([0,1,2,3,4,5,6,7,8,9,10,11,12,13,14,15,16,17,18,19])); - }); - - test('firstWhere', () { - var d = new DispatcherController(); - var result = new List(); - d.dispatcher.firstWhere((n) => n > 15).then((v) => result.add(v)); - send20IntegersToDispatcherController(d); - new Timer(new Duration(), expectAsync(() => expect(result, orderedEquals([16])))); - }); - - test('where', () { - var d = new DispatcherController(); - var result = new List(); - d.dispatcher.where((n) => n % 2 == 0).until((n) => n > 10).listen((v) => result.add(v)); - send20IntegersToDispatcherController(d); - expect(result, orderedEquals([0,2,4,6,8,10])); - }); - - test('where without listener', () { - var d = new DispatcherController(); - var result = new List(); - d.dispatcher.where((n) => result.add(n)); - send20IntegersToDispatcherController(d); - expect(result, orderedEquals([])); - }); - - test('where with listeners removed', () { - var d = new DispatcherController(); - var result = new List(); - var w = d.dispatcher.where((n) { result.add(n); return true; }); - d.add(0); - var f1 = (v) => result.add(100 + v); - w.listen(f1); - d.add(1); - var f2 = (v) => result.add(200 + v); - w.listen(f2); - d.add(2); - w.unlisten(f1); - d.add(3); - w.unlisten(f2); - d.add(4); - expect(result, orderedEquals([1, 101, 2, 102, 202, 3, 203])); - }); - - test('double listeners', () { - var d = new DispatcherController(); - var result = new List(); - d.dispatcher..listen((v) => result.add(v)) - ..where((n) => n < 3).listen((v) => result.add(v*100)); - send20IntegersToDispatcherController(d); - expect(result, orderedEquals([0,0,1,100,2,200,3,4,5,6,7,8,9,10,11,12,13,14,15,16,17,18,19])); - }); - - test('zones', () { - var d = new DispatcherController(); - var result = new List(); - runZoned(() { - var zoneA = Zone.current; - var listener; - listener = (v) { - if (Zone.current == zoneA) - result.add(v + 0.1); - if (v >= 18) - d.dispatcher.unlisten(listener); - }; - d.dispatcher.listen(listener); - }); - runZoned(() { - var zoneB = Zone.current; - d.dispatcher.until((n) => n >= 10).listen((v) { - if (Zone.current == zoneB) - result.add(v + 0.2); - }); - }); - send20IntegersToDispatcherController(d); - expect(result, orderedEquals([0.1,0.2,1.1,1.2,2.1,2.2,3.1,3.2,4.1,4.2,5.1,5.2,6.1,6.2,7.1,7.2,8.1,8.2,9.1,9.2,10.1,11.1,12.1,13.1,14.1,15.1,16.1,17.1,18.1])); - }); - - }); -} diff --git a/engine/src/flutter/tests/examples/card_collection-expected.txt b/engine/src/flutter/tests/examples/card_collection-expected.txt deleted file mode 100644 index c06d573936..0000000000 --- a/engine/src/flutter/tests/examples/card_collection-expected.txt +++ /dev/null @@ -1,281 +0,0 @@ -TestRenderView enabled - -PAINT FOR FRAME #1 ---------------------------------------------- -1 | TestPaintingCanvas() constructor: 800.0 x 600.0 ------------------------------------------------------------------------- - -PAINT FOR FRAME #2 ---------------------------------------------- -2 | TestPaintingCanvas() constructor: 800.0 x 600.0 -2 | paintChild RenderScaffold at Point(0.0, 0.0) -2 | | TestPaintingCanvas() constructor: 800.0 x 600.0 -2 | | paintChild RenderDecoratedBox at Point(0.0, 56.0) -2 | | | TestPaintingCanvas() constructor: 800.0 x 600.0 -2 | | | drawRect(Rect.fromLTRB(0.0, 56.0, 800.0, 600.0), Paint(color:Color(0xffe3f2fd))) -2 | | | paintChild RenderPadding at Point(0.0, 56.0) -2 | | | | TestPaintingCanvas() constructor: 800.0 x 600.0 -2 | | | | paintChild RenderSizeObserver at Point(8.0, 68.0) -2 | | | | | TestPaintingCanvas() constructor: 800.0 x 600.0 -2 | | | | | paintChild RenderBlockViewport at Point(8.0, 68.0) -2 | | | | | | TestPaintingCanvas() constructor: 800.0 x 600.0 -2 | | | | | | save -2 | | | | | | clipRect(Rect.fromLTRB(8.0, 68.0, 792.0, 588.0)) -2 | | | | | | paintChild RenderSizeObserver at Point(8.0, 68.0) -2 | | | | | | | TestPaintingCanvas() constructor: 800.0 x 600.0 -2 | | | | | | | paintChild RenderOpacity at Point(8.0, 68.0) -2 | | | | | | | | TestPaintingCanvas() constructor: 800.0 x 600.0 -2 | | | | | | | | paintChild RenderTransform at Point(8.0, 68.0) -2 | | | | | | | | | TestPaintingCanvas() constructor: 800.0 x 600.0 -2 | | | | | | | | | save -2 | | | | | | | | | translate(8.0, 68.0) -2 | | | | | | | | | concat([1.0, 0.0, 0.0, 0.0, 0.0, 1.0, 0.0, 0.0, 0.0, 0.0, 1.0, 0.0, 0.0, 0.0, 0.0, 1.0]) -2 | | | | | | | | | paintChild RenderPadding at Point(0.0, 0.0) -2 | | | | | | | | | | TestPaintingCanvas() constructor: 800.0 x 600.0 -2 | | | | | | | | | | paintChild RenderDecoratedBox at Point(4.0, 4.0) -2 | | | | | | | | | | | TestPaintingCanvas() constructor: 800.0 x 600.0 -2 | | | | | | | | | | | drawRRect(Instance of 'RRect', Paint(color:Color(0xfff44336), drawLooper:true)) -2 | | | | | | | | | | | paintChild RenderClipRRect at Point(4.0, 4.0) -2 | | | | | | | | | | | | TestPaintingCanvas() constructor: 800.0 x 600.0 -2 | | | | | | | | | | | | saveLayer(Rect.fromLTRB(4.0, 4.0, 780.0, 52.0), Paint(color:Color(0xff000000))) -2 | | | | | | | | | | | | clipRRect() -2 | | | | | | | | | | | | paintChild RenderConstrainedBox at Point(4.0, 4.0) -2 | | | | | | | | | | | | | TestPaintingCanvas() constructor: 800.0 x 600.0 -2 | | | | | | | | | | | | | paintChild RenderPadding at Point(4.0, 4.0) -2 | | | | | | | | | | | | | | TestPaintingCanvas() constructor: 800.0 x 600.0 -2 | | | | | | | | | | | | | | paintChild RenderPositionedBox at Point(12.0, 12.0) -2 | | | | | | | | | | | | | | | TestPaintingCanvas() constructor: 800.0 x 600.0 -2 | | | | | | | | | | | | | | | paintChild RenderParagraph at Point(359.0, 15.5) -2 | | | | | | | | | | | | | | | | TestPaintingCanvas() constructor: 800.0 x 600.0 -2 | | | | | | | | | | | | | | | | translate(359.0, 15.5) -2 | | | | | | | | | | | | | | | | translate(-359.0, -15.5) -2 | | | | | | | | | | | | restore -2 | | | | | | | | | restore -2 | | | | | | paintChild RenderSizeObserver at Point(8.0, 124.0) -2 | | | | | | | TestPaintingCanvas() constructor: 800.0 x 600.0 -2 | | | | | | | paintChild RenderOpacity at Point(8.0, 124.0) -2 | | | | | | | | TestPaintingCanvas() constructor: 800.0 x 600.0 -2 | | | | | | | | paintChild RenderTransform at Point(8.0, 124.0) -2 | | | | | | | | | TestPaintingCanvas() constructor: 800.0 x 600.0 -2 | | | | | | | | | save -2 | | | | | | | | | translate(8.0, 124.0) -2 | | | | | | | | | concat([1.0, 0.0, 0.0, 0.0, 0.0, 1.0, 0.0, 0.0, 0.0, 0.0, 1.0, 0.0, 0.0, 0.0, 0.0, 1.0]) -2 | | | | | | | | | paintChild RenderPadding at Point(0.0, 0.0) -2 | | | | | | | | | | TestPaintingCanvas() constructor: 800.0 x 600.0 -2 | | | | | | | | | | paintChild RenderDecoratedBox at Point(4.0, 4.0) -2 | | | | | | | | | | | TestPaintingCanvas() constructor: 800.0 x 600.0 -2 | | | | | | | | | | | drawRRect(Instance of 'RRect', Paint(color:Color(0xffee453b), drawLooper:true)) -2 | | | | | | | | | | | paintChild RenderClipRRect at Point(4.0, 4.0) -2 | | | | | | | | | | | | TestPaintingCanvas() constructor: 800.0 x 600.0 -2 | | | | | | | | | | | | saveLayer(Rect.fromLTRB(4.0, 4.0, 780.0, 68.0), Paint(color:Color(0xff000000))) -2 | | | | | | | | | | | | clipRRect() -2 | | | | | | | | | | | | paintChild RenderConstrainedBox at Point(4.0, 4.0) -2 | | | | | | | | | | | | | TestPaintingCanvas() constructor: 800.0 x 600.0 -2 | | | | | | | | | | | | | paintChild RenderPadding at Point(4.0, 4.0) -2 | | | | | | | | | | | | | | TestPaintingCanvas() constructor: 800.0 x 600.0 -2 | | | | | | | | | | | | | | paintChild RenderPositionedBox at Point(12.0, 12.0) -2 | | | | | | | | | | | | | | | TestPaintingCanvas() constructor: 800.0 x 600.0 -2 | | | | | | | | | | | | | | | paintChild RenderParagraph at Point(359.0, 23.5) -2 | | | | | | | | | | | | | | | | TestPaintingCanvas() constructor: 800.0 x 600.0 -2 | | | | | | | | | | | | | | | | translate(359.0, 23.5) -2 | | | | | | | | | | | | | | | | translate(-359.0, -23.5) -2 | | | | | | | | | | | | restore -2 | | | | | | | | | restore -2 | | | | | | paintChild RenderSizeObserver at Point(8.0, 196.0) -2 | | | | | | | TestPaintingCanvas() constructor: 800.0 x 600.0 -2 | | | | | | | paintChild RenderOpacity at Point(8.0, 196.0) -2 | | | | | | | | TestPaintingCanvas() constructor: 800.0 x 600.0 -2 | | | | | | | | paintChild RenderTransform at Point(8.0, 196.0) -2 | | | | | | | | | TestPaintingCanvas() constructor: 800.0 x 600.0 -2 | | | | | | | | | save -2 | | | | | | | | | translate(8.0, 196.0) -2 | | | | | | | | | concat([1.0, 0.0, 0.0, 0.0, 0.0, 1.0, 0.0, 0.0, 0.0, 0.0, 1.0, 0.0, 0.0, 0.0, 0.0, 1.0]) -2 | | | | | | | | | paintChild RenderPadding at Point(0.0, 0.0) -2 | | | | | | | | | | TestPaintingCanvas() constructor: 800.0 x 600.0 -2 | | | | | | | | | | paintChild RenderDecoratedBox at Point(4.0, 4.0) -2 | | | | | | | | | | | TestPaintingCanvas() constructor: 800.0 x 600.0 -2 | | | | | | | | | | | drawRRect(Instance of 'RRect', Paint(color:Color(0xffe84740), drawLooper:true)) -2 | | | | | | | | | | | paintChild RenderClipRRect at Point(4.0, 4.0) -2 | | | | | | | | | | | | TestPaintingCanvas() constructor: 800.0 x 600.0 -2 | | | | | | | | | | | | saveLayer(Rect.fromLTRB(4.0, 4.0, 780.0, 86.0), Paint(color:Color(0xff000000))) -2 | | | | | | | | | | | | clipRRect() -2 | | | | | | | | | | | | paintChild RenderConstrainedBox at Point(4.0, 4.0) -2 | | | | | | | | | | | | | TestPaintingCanvas() constructor: 800.0 x 600.0 -2 | | | | | | | | | | | | | paintChild RenderPadding at Point(4.0, 4.0) -2 | | | | | | | | | | | | | | TestPaintingCanvas() constructor: 800.0 x 600.0 -2 | | | | | | | | | | | | | | paintChild RenderPositionedBox at Point(12.0, 12.0) -2 | | | | | | | | | | | | | | | TestPaintingCanvas() constructor: 800.0 x 600.0 -2 | | | | | | | | | | | | | | | paintChild RenderParagraph at Point(359.0, 32.5) -2 | | | | | | | | | | | | | | | | TestPaintingCanvas() constructor: 800.0 x 600.0 -2 | | | | | | | | | | | | | | | | translate(359.0, 32.5) -2 | | | | | | | | | | | | | | | | translate(-359.0, -32.5) -2 | | | | | | | | | | | | restore -2 | | | | | | | | | restore -2 | | | | | | paintChild RenderSizeObserver at Point(8.0, 286.0) -2 | | | | | | | TestPaintingCanvas() constructor: 800.0 x 600.0 -2 | | | | | | | paintChild RenderOpacity at Point(8.0, 286.0) -2 | | | | | | | | TestPaintingCanvas() constructor: 800.0 x 600.0 -2 | | | | | | | | paintChild RenderTransform at Point(8.0, 286.0) -2 | | | | | | | | | TestPaintingCanvas() constructor: 800.0 x 600.0 -2 | | | | | | | | | save -2 | | | | | | | | | translate(8.0, 286.0) -2 | | | | | | | | | concat([1.0, 0.0, 0.0, 0.0, 0.0, 1.0, 0.0, 0.0, 0.0, 0.0, 1.0, 0.0, 0.0, 0.0, 0.0, 1.0]) -2 | | | | | | | | | paintChild RenderPadding at Point(0.0, 0.0) -2 | | | | | | | | | | TestPaintingCanvas() constructor: 800.0 x 600.0 -2 | | | | | | | | | | paintChild RenderDecoratedBox at Point(4.0, 4.0) -2 | | | | | | | | | | | TestPaintingCanvas() constructor: 800.0 x 600.0 -2 | | | | | | | | | | | drawRRect(Instance of 'RRect', Paint(color:Color(0xffe24945), drawLooper:true)) -2 | | | | | | | | | | | paintChild RenderClipRRect at Point(4.0, 4.0) -2 | | | | | | | | | | | | TestPaintingCanvas() constructor: 800.0 x 600.0 -2 | | | | | | | | | | | | saveLayer(Rect.fromLTRB(4.0, 4.0, 780.0, 50.0), Paint(color:Color(0xff000000))) -2 | | | | | | | | | | | | clipRRect() -2 | | | | | | | | | | | | paintChild RenderConstrainedBox at Point(4.0, 4.0) -2 | | | | | | | | | | | | | TestPaintingCanvas() constructor: 800.0 x 600.0 -2 | | | | | | | | | | | | | paintChild RenderPadding at Point(4.0, 4.0) -2 | | | | | | | | | | | | | | TestPaintingCanvas() constructor: 800.0 x 600.0 -2 | | | | | | | | | | | | | | paintChild RenderPositionedBox at Point(12.0, 12.0) -2 | | | | | | | | | | | | | | | TestPaintingCanvas() constructor: 800.0 x 600.0 -2 | | | | | | | | | | | | | | | paintChild RenderParagraph at Point(359.0, 14.5) -2 | | | | | | | | | | | | | | | | TestPaintingCanvas() constructor: 800.0 x 600.0 -2 | | | | | | | | | | | | | | | | translate(359.0, 14.5) -2 | | | | | | | | | | | | | | | | translate(-359.0, -14.5) -2 | | | | | | | | | | | | restore -2 | | | | | | | | | restore -2 | | | | | | paintChild RenderSizeObserver at Point(8.0, 340.0) -2 | | | | | | | TestPaintingCanvas() constructor: 800.0 x 600.0 -2 | | | | | | | paintChild RenderOpacity at Point(8.0, 340.0) -2 | | | | | | | | TestPaintingCanvas() constructor: 800.0 x 600.0 -2 | | | | | | | | paintChild RenderTransform at Point(8.0, 340.0) -2 | | | | | | | | | TestPaintingCanvas() constructor: 800.0 x 600.0 -2 | | | | | | | | | save -2 | | | | | | | | | translate(8.0, 340.0) -2 | | | | | | | | | concat([1.0, 0.0, 0.0, 0.0, 0.0, 1.0, 0.0, 0.0, 0.0, 0.0, 1.0, 0.0, 0.0, 0.0, 0.0, 1.0]) -2 | | | | | | | | | paintChild RenderPadding at Point(0.0, 0.0) -2 | | | | | | | | | | TestPaintingCanvas() constructor: 800.0 x 600.0 -2 | | | | | | | | | | paintChild RenderDecoratedBox at Point(4.0, 4.0) -2 | | | | | | | | | | | TestPaintingCanvas() constructor: 800.0 x 600.0 -2 | | | | | | | | | | | drawRRect(Instance of 'RRect', Paint(color:Color(0xffdc4c4b), drawLooper:true)) -2 | | | | | | | | | | | paintChild RenderClipRRect at Point(4.0, 4.0) -2 | | | | | | | | | | | | TestPaintingCanvas() constructor: 800.0 x 600.0 -2 | | | | | | | | | | | | saveLayer(Rect.fromLTRB(4.0, 4.0, 780.0, 64.0), Paint(color:Color(0xff000000))) -2 | | | | | | | | | | | | clipRRect() -2 | | | | | | | | | | | | paintChild RenderConstrainedBox at Point(4.0, 4.0) -2 | | | | | | | | | | | | | TestPaintingCanvas() constructor: 800.0 x 600.0 -2 | | | | | | | | | | | | | paintChild RenderPadding at Point(4.0, 4.0) -2 | | | | | | | | | | | | | | TestPaintingCanvas() constructor: 800.0 x 600.0 -2 | | | | | | | | | | | | | | paintChild RenderPositionedBox at Point(12.0, 12.0) -2 | | | | | | | | | | | | | | | TestPaintingCanvas() constructor: 800.0 x 600.0 -2 | | | | | | | | | | | | | | | paintChild RenderParagraph at Point(359.0, 21.5) -2 | | | | | | | | | | | | | | | | TestPaintingCanvas() constructor: 800.0 x 600.0 -2 | | | | | | | | | | | | | | | | translate(359.0, 21.5) -2 | | | | | | | | | | | | | | | | translate(-359.0, -21.5) -2 | | | | | | | | | | | | restore -2 | | | | | | | | | restore -2 | | | | | | paintChild RenderSizeObserver at Point(8.0, 408.0) -2 | | | | | | | TestPaintingCanvas() constructor: 800.0 x 600.0 -2 | | | | | | | paintChild RenderOpacity at Point(8.0, 408.0) -2 | | | | | | | | TestPaintingCanvas() constructor: 800.0 x 600.0 -2 | | | | | | | | paintChild RenderTransform at Point(8.0, 408.0) -2 | | | | | | | | | TestPaintingCanvas() constructor: 800.0 x 600.0 -2 | | | | | | | | | save -2 | | | | | | | | | translate(8.0, 408.0) -2 | | | | | | | | | concat([1.0, 0.0, 0.0, 0.0, 0.0, 1.0, 0.0, 0.0, 0.0, 0.0, 1.0, 0.0, 0.0, 0.0, 0.0, 1.0]) -2 | | | | | | | | | paintChild RenderPadding at Point(0.0, 0.0) -2 | | | | | | | | | | TestPaintingCanvas() constructor: 800.0 x 600.0 -2 | | | | | | | | | | paintChild RenderDecoratedBox at Point(4.0, 4.0) -2 | | | | | | | | | | | TestPaintingCanvas() constructor: 800.0 x 600.0 -2 | | | | | | | | | | | drawRRect(Instance of 'RRect', Paint(color:Color(0xffd64e50), drawLooper:true)) -2 | | | | | | | | | | | paintChild RenderClipRRect at Point(4.0, 4.0) -2 | | | | | | | | | | | | TestPaintingCanvas() constructor: 800.0 x 600.0 -2 | | | | | | | | | | | | saveLayer(Rect.fromLTRB(4.0, 4.0, 780.0, 59.0), Paint(color:Color(0xff000000))) -2 | | | | | | | | | | | | clipRRect() -2 | | | | | | | | | | | | paintChild RenderConstrainedBox at Point(4.0, 4.0) -2 | | | | | | | | | | | | | TestPaintingCanvas() constructor: 800.0 x 600.0 -2 | | | | | | | | | | | | | paintChild RenderPadding at Point(4.0, 4.0) -2 | | | | | | | | | | | | | | TestPaintingCanvas() constructor: 800.0 x 600.0 -2 | | | | | | | | | | | | | | paintChild RenderPositionedBox at Point(12.0, 12.0) -2 | | | | | | | | | | | | | | | TestPaintingCanvas() constructor: 800.0 x 600.0 -2 | | | | | | | | | | | | | | | paintChild RenderParagraph at Point(359.0, 19.0) -2 | | | | | | | | | | | | | | | | TestPaintingCanvas() constructor: 800.0 x 600.0 -2 | | | | | | | | | | | | | | | | translate(359.0, 19.0) -2 | | | | | | | | | | | | | | | | translate(-359.0, -19.0) -2 | | | | | | | | | | | | restore -2 | | | | | | | | | restore -2 | | | | | | paintChild RenderSizeObserver at Point(8.0, 471.0) -2 | | | | | | | TestPaintingCanvas() constructor: 800.0 x 600.0 -2 | | | | | | | paintChild RenderOpacity at Point(8.0, 471.0) -2 | | | | | | | | TestPaintingCanvas() constructor: 800.0 x 600.0 -2 | | | | | | | | paintChild RenderTransform at Point(8.0, 471.0) -2 | | | | | | | | | TestPaintingCanvas() constructor: 800.0 x 600.0 -2 | | | | | | | | | save -2 | | | | | | | | | translate(8.0, 471.0) -2 | | | | | | | | | concat([1.0, 0.0, 0.0, 0.0, 0.0, 1.0, 0.0, 0.0, 0.0, 0.0, 1.0, 0.0, 0.0, 0.0, 0.0, 1.0]) -2 | | | | | | | | | paintChild RenderPadding at Point(0.0, 0.0) -2 | | | | | | | | | | TestPaintingCanvas() constructor: 800.0 x 600.0 -2 | | | | | | | | | | paintChild RenderDecoratedBox at Point(4.0, 4.0) -2 | | | | | | | | | | | TestPaintingCanvas() constructor: 800.0 x 600.0 -2 | | | | | | | | | | | drawRRect(Instance of 'RRect', Paint(color:Color(0xffd05055), drawLooper:true)) -2 | | | | | | | | | | | paintChild RenderClipRRect at Point(4.0, 4.0) -2 | | | | | | | | | | | | TestPaintingCanvas() constructor: 800.0 x 600.0 -2 | | | | | | | | | | | | saveLayer(Rect.fromLTRB(4.0, 4.0, 780.0, 88.0), Paint(color:Color(0xff000000))) -2 | | | | | | | | | | | | clipRRect() -2 | | | | | | | | | | | | paintChild RenderConstrainedBox at Point(4.0, 4.0) -2 | | | | | | | | | | | | | TestPaintingCanvas() constructor: 800.0 x 600.0 -2 | | | | | | | | | | | | | paintChild RenderPadding at Point(4.0, 4.0) -2 | | | | | | | | | | | | | | TestPaintingCanvas() constructor: 800.0 x 600.0 -2 | | | | | | | | | | | | | | paintChild RenderPositionedBox at Point(12.0, 12.0) -2 | | | | | | | | | | | | | | | TestPaintingCanvas() constructor: 800.0 x 600.0 -2 | | | | | | | | | | | | | | | paintChild RenderParagraph at Point(359.0, 33.5) -2 | | | | | | | | | | | | | | | | TestPaintingCanvas() constructor: 800.0 x 600.0 -2 | | | | | | | | | | | | | | | | translate(359.0, 33.5) -2 | | | | | | | | | | | | | | | | translate(-359.0, -33.5) -2 | | | | | | | | | | | | restore -2 | | | | | | | | | restore -2 | | | | | | paintChild RenderSizeObserver at Point(8.0, 563.0) -2 | | | | | | | TestPaintingCanvas() constructor: 800.0 x 600.0 -2 | | | | | | | paintChild RenderOpacity at Point(8.0, 563.0) -2 | | | | | | | | TestPaintingCanvas() constructor: 800.0 x 600.0 -2 | | | | | | | | paintChild RenderTransform at Point(8.0, 563.0) -2 | | | | | | | | | TestPaintingCanvas() constructor: 800.0 x 600.0 -2 | | | | | | | | | save -2 | | | | | | | | | translate(8.0, 563.0) -2 | | | | | | | | | concat([1.0, 0.0, 0.0, 0.0, 0.0, 1.0, 0.0, 0.0, 0.0, 0.0, 1.0, 0.0, 0.0, 0.0, 0.0, 1.0]) -2 | | | | | | | | | paintChild RenderPadding at Point(0.0, 0.0) -2 | | | | | | | | | | TestPaintingCanvas() constructor: 800.0 x 600.0 -2 | | | | | | | | | | paintChild RenderDecoratedBox at Point(4.0, 4.0) -2 | | | | | | | | | | | TestPaintingCanvas() constructor: 800.0 x 600.0 -2 | | | | | | | | | | | drawRRect(Instance of 'RRect', Paint(color:Color(0xffca535a), drawLooper:true)) -2 | | | | | | | | | | | paintChild RenderClipRRect at Point(4.0, 4.0) -2 | | | | | | | | | | | | TestPaintingCanvas() constructor: 800.0 x 600.0 -2 | | | | | | | | | | | | saveLayer(Rect.fromLTRB(4.0, 4.0, 780.0, 100.0), Paint(color:Color(0xff000000))) -2 | | | | | | | | | | | | clipRRect() -2 | | | | | | | | | | | | paintChild RenderConstrainedBox at Point(4.0, 4.0) -2 | | | | | | | | | | | | | TestPaintingCanvas() constructor: 800.0 x 600.0 -2 | | | | | | | | | | | | | paintChild RenderPadding at Point(4.0, 4.0) -2 | | | | | | | | | | | | | | TestPaintingCanvas() constructor: 800.0 x 600.0 -2 | | | | | | | | | | | | | | paintChild RenderPositionedBox at Point(12.0, 12.0) -2 | | | | | | | | | | | | | | | TestPaintingCanvas() constructor: 800.0 x 600.0 -2 | | | | | | | | | | | | | | | paintChild RenderParagraph at Point(359.0, 39.5) -2 | | | | | | | | | | | | | | | | TestPaintingCanvas() constructor: 800.0 x 600.0 -2 | | | | | | | | | | | | | | | | translate(359.0, 39.5) -2 | | | | | | | | | | | | | | | | translate(-359.0, -39.5) -2 | | | | | | | | | | | | restore -2 | | | | | | | | | restore -2 | | | | | | restore -2 | | paintChild RenderDecoratedBox at Point(0.0, 0.0) -2 | | | TestPaintingCanvas() constructor: 800.0 x 600.0 -2 | | | drawRect(Rect.fromLTRB(0.0, 0.0, 800.0, 56.0), Paint(color:Color(0xff2196f3), drawLooper:true)) -2 | | | paintChild RenderPadding at Point(0.0, 0.0) -2 | | | | TestPaintingCanvas() constructor: 800.0 x 600.0 -2 | | | | paintChild RenderFlex at Point(8.0, 0.0) -2 | | | | | TestPaintingCanvas() constructor: 800.0 x 600.0 -2 | | | | | paintChild RenderConstrainedBox at Point(8.0, 0.0) -2 | | | | | | TestPaintingCanvas() constructor: 800.0 x 600.0 -2 | | | | | | paintChild RenderFlex at Point(8.0, 0.0) -2 | | | | | | | TestPaintingCanvas() constructor: 800.0 x 600.0 -2 | | | | | | | paintChild RenderPadding at Point(8.0, 14.0) -2 | | | | | | | | TestPaintingCanvas() constructor: 800.0 x 600.0 -2 | | | | | | | | paintChild RenderParagraph at Point(32.0, 14.0) -2 | | | | | | | | | TestPaintingCanvas() constructor: 800.0 x 600.0 -2 | | | | | | | | | translate(32.0, 14.0) -2 | | | | | | | | | translate(-32.0, -14.0) ------------------------------------------------------------------------- -PAINTED 2 FRAMES diff --git a/engine/src/flutter/tests/examples/card_collection.dart b/engine/src/flutter/tests/examples/card_collection.dart deleted file mode 100644 index 53874c6df7..0000000000 --- a/engine/src/flutter/tests/examples/card_collection.dart +++ /dev/null @@ -1,18 +0,0 @@ -// Copyright 2015 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 'dart:async'; - -import 'package:sky/widgets/widget.dart'; - -import '../../sdk/example/widgets/card_collection.dart'; -import '../resources/display_list.dart'; - -main() async { - TestRenderView testRenderView = new TestRenderView(); - CardCollectionApp app = new CardCollectionApp(); - runApp(app, renderViewOverride: testRenderView); - await testRenderView.checkFrame(); - testRenderView.endTest(); -} diff --git a/engine/src/flutter/tests/examples/sector-expected.txt b/engine/src/flutter/tests/examples/sector-expected.txt deleted file mode 100644 index f7e9dbe231..0000000000 --- a/engine/src/flutter/tests/examples/sector-expected.txt +++ /dev/null @@ -1,919 +0,0 @@ -TestRenderView enabled - -PAINT FOR FRAME #1 ---------------------------------------------- -1 | TestPaintingCanvas() constructor: 800.0 x 600.0 ------------------------------------------------------------------------- - -PAINT FOR FRAME #2 ---------------------------------------------- -2 | TestPaintingCanvas() constructor: 800.0 x 600.0 -2 | paintChild RenderScaffold at Point(0.0, 0.0) -2 | | TestPaintingCanvas() constructor: 800.0 x 600.0 -2 | | paintChild RenderDecoratedBox at Point(0.0, 56.0) -2 | | | TestPaintingCanvas() constructor: 800.0 x 600.0 -2 | | | drawRect(Rect.fromLTRB(0.0, 56.0, 800.0, 600.0), Paint(color:Color(0xfffafafa))) -2 | | | paintChild RenderFlex at Point(0.0, 56.0) -2 | | | | TestPaintingCanvas() constructor: 800.0 x 600.0 -2 | | | | paintChild RenderPadding at Point(0.0, 56.0) -2 | | | | | TestPaintingCanvas() constructor: 800.0 x 600.0 -2 | | | | | paintChild RenderFlex at Point(8.0, 81.0) -2 | | | | | | TestPaintingCanvas() constructor: 800.0 x 600.0 -2 | | | | | | paintChild RenderPadding at Point(111.25, 81.0) -2 | | | | | | | TestPaintingCanvas() constructor: 800.0 x 600.0 -2 | | | | | | | paintChild RenderConstrainedBox at Point(119.25, 89.0) -2 | | | | | | | | TestPaintingCanvas() constructor: 800.0 x 600.0 -2 | | | | | | | | paintChild RenderConstrainedBox at Point(119.25, 89.0) -2 | | | | | | | | | TestPaintingCanvas() constructor: 800.0 x 600.0 -2 | | | | | | | | | paintChild RenderDecoratedBox at Point(119.25, 89.0) -2 | | | | | | | | | | TestPaintingCanvas() constructor: 800.0 x 600.0 -2 | | | | | | | | | | drawRRect(Instance of 'RRect', Paint(color:Color(0xffe0e0e0), drawLooper:true)) -2 | | | | | | | | | | paintChild RenderInkWell at Point(119.25, 89.0) -2 | | | | | | | | | | | TestPaintingCanvas() constructor: 800.0 x 600.0 -2 | | | | | | | | | | | paintChild RenderPadding at Point(119.25, 89.0) -2 | | | | | | | | | | | | TestPaintingCanvas() constructor: 800.0 x 600.0 -2 | | | | | | | | | | | | paintChild RenderPositionedBox at Point(127.25, 89.0) -2 | | | | | | | | | | | | | TestPaintingCanvas() constructor: 800.0 x 600.0 -2 | | | | | | | | | | | | | paintChild RenderShrinkWrapWidth at Point(127.25, 89.0) -2 | | | | | | | | | | | | | | TestPaintingCanvas() constructor: 800.0 x 600.0 -2 | | | | | | | | | | | | | | paintChild RenderFlex at Point(127.25, 89.0) -2 | | | | | | | | | | | | | | | TestPaintingCanvas() constructor: 800.0 x 600.0 -2 | | | | | | | | | | | | | | | paintChild RenderPadding at Point(127.25, 89.0) -2 | | | | | | | | | | | | | | | | TestPaintingCanvas() constructor: 800.0 x 600.0 -2 | | | | | | | | | | | | | | | | paintChild RenderPadding at Point(127.25, 89.0) -2 | | | | | | | | | | | | | | | | | TestPaintingCanvas() constructor: 800.0 x 600.0 -2 | | | | | | | | | | | | | | | | | paintChild RenderBoxToRenderSectorAdapter at Point(131.25, 93.0) -2 | | | | | | | | | | | | | | | | | | TestPaintingCanvas() constructor: 800.0 x 600.0 -2 | | | | | | | | | | | | | | | | | | paintChild RenderSectorRing at Point(145.25, 107.0) -2 | | | | | | | | | | | | | | | | | | | TestPaintingCanvas() constructor: 800.0 x 600.0 -2 | | | | | | | | | | | | | | | | | | | paintChild RenderSolidColor at Point(145.25, 107.0) -2 | | | | | | | | | | | | | | | | | | | | TestPaintingCanvas() constructor: 800.0 x 600.0 -2 | | | | | | | | | | | | | | | | | | | | drawPath(Instance of 'Path', Paint(color:Color(0xff909090))) -2 | | | | | | | | | | | | | | | | | | | paintChild RenderSolidColor at Point(145.25, 107.0) -2 | | | | | | | | | | | | | | | | | | | | TestPaintingCanvas() constructor: 800.0 x 600.0 -2 | | | | | | | | | | | | | | | | | | | | drawPath(Instance of 'Path', Paint(color:Color(0xff909090))) -2 | | | | | | | | | | | | | | | | | | | paintChild RenderSolidColor at Point(145.25, 107.0) -2 | | | | | | | | | | | | | | | | | | | | TestPaintingCanvas() constructor: 800.0 x 600.0 -2 | | | | | | | | | | | | | | | | | | | | drawPath(Instance of 'Path', Paint(color:Color(0xff00dd00))) -2 | | | | | | | | | | | | | | | paintChild RenderParagraph at Point(173.25, 97.0) -2 | | | | | | | | | | | | | | | | TestPaintingCanvas() constructor: 800.0 x 600.0 -2 | | | | | | | | | | | | | | | | translate(173.25, 97.0) -2 | | | | | | | | | | | | | | | | translate(-173.25, -97.0) -2 | | | | | | paintChild RenderPadding at Point(488.75, 81.0) -2 | | | | | | | TestPaintingCanvas() constructor: 800.0 x 600.0 -2 | | | | | | | paintChild RenderConstrainedBox at Point(496.75, 89.0) -2 | | | | | | | | TestPaintingCanvas() constructor: 800.0 x 600.0 -2 | | | | | | | | paintChild RenderConstrainedBox at Point(496.75, 89.0) -2 | | | | | | | | | TestPaintingCanvas() constructor: 800.0 x 600.0 -2 | | | | | | | | | paintChild RenderDecoratedBox at Point(496.75, 89.0) -2 | | | | | | | | | | TestPaintingCanvas() constructor: 800.0 x 600.0 -2 | | | | | | | | | | drawRRect(Instance of 'RRect', Paint(color:Color(0xffd6d6d6))) -2 | | | | | | | | | | paintChild RenderPadding at Point(496.75, 89.0) -2 | | | | | | | | | | | TestPaintingCanvas() constructor: 800.0 x 600.0 -2 | | | | | | | | | | | paintChild RenderPositionedBox at Point(504.75, 89.0) -2 | | | | | | | | | | | | TestPaintingCanvas() constructor: 800.0 x 600.0 -2 | | | | | | | | | | | | paintChild RenderShrinkWrapWidth at Point(504.75, 89.0) -2 | | | | | | | | | | | | | TestPaintingCanvas() constructor: 800.0 x 600.0 -2 | | | | | | | | | | | | | paintChild RenderFlex at Point(504.75, 89.0) -2 | | | | | | | | | | | | | | TestPaintingCanvas() constructor: 800.0 x 600.0 -2 | | | | | | | | | | | | | | paintChild RenderPadding at Point(504.75, 89.0) -2 | | | | | | | | | | | | | | | TestPaintingCanvas() constructor: 800.0 x 600.0 -2 | | | | | | | | | | | | | | | paintChild RenderPadding at Point(504.75, 89.0) -2 | | | | | | | | | | | | | | | | TestPaintingCanvas() constructor: 800.0 x 600.0 -2 | | | | | | | | | | | | | | | | paintChild RenderBoxToRenderSectorAdapter at Point(508.75, 93.0) -2 | | | | | | | | | | | | | | | | | TestPaintingCanvas() constructor: 800.0 x 600.0 -2 | | | | | | | | | | | | | | | | | paintChild RenderSectorRing at Point(522.75, 107.0) -2 | | | | | | | | | | | | | | | | | | TestPaintingCanvas() constructor: 800.0 x 600.0 -2 | | | | | | | | | | | | | | | | | | paintChild RenderSolidColor at Point(522.75, 107.0) -2 | | | | | | | | | | | | | | | | | | | TestPaintingCanvas() constructor: 800.0 x 600.0 -2 | | | | | | | | | | | | | | | | | | | drawPath(Instance of 'Path', Paint(color:Color(0xff909090))) -2 | | | | | | | | | | | | | | | | | | paintChild RenderSolidColor at Point(522.75, 107.0) -2 | | | | | | | | | | | | | | | | | | | TestPaintingCanvas() constructor: 800.0 x 600.0 -2 | | | | | | | | | | | | | | | | | | | drawPath(Instance of 'Path', Paint(color:Color(0xff909090))) -2 | | | | | | | | | | | | | | | | | | paintChild RenderSolidColor at Point(522.75, 107.0) -2 | | | | | | | | | | | | | | | | | | | TestPaintingCanvas() constructor: 800.0 x 600.0 -2 | | | | | | | | | | | | | | | | | | | drawPath(Instance of 'Path', Paint(color:Color(0xffdd0000))) -2 | | | | | | | | | | | | | | paintChild RenderParagraph at Point(550.75, 97.0) -2 | | | | | | | | | | | | | | | TestPaintingCanvas() constructor: 800.0 x 600.0 -2 | | | | | | | | | | | | | | | translate(550.75, 97.0) -2 | | | | | | | | | | | | | | | translate(-550.75, -97.0) -2 | | | | paintChild RenderPadding at Point(179.0, 158.0) -2 | | | | | TestPaintingCanvas() constructor: 800.0 x 600.0 -2 | | | | | paintChild RenderDecoratedBox at Point(187.0, 166.0) -2 | | | | | | TestPaintingCanvas() constructor: 800.0 x 600.0 -2 | | | | | | drawPath(Instance of 'Path', Paint(color:Color(0xff000000))) -2 | | | | | | drawPath(Instance of 'Path', Paint(color:Color(0xff000000))) -2 | | | | | | drawPath(Instance of 'Path', Paint(color:Color(0xff000000))) -2 | | | | | | drawPath(Instance of 'Path', Paint(color:Color(0xff000000))) -2 | | | | | | paintChild RenderPadding at Point(187.0, 166.0) -2 | | | | | | | TestPaintingCanvas() constructor: 800.0 x 600.0 -2 | | | | | | | paintChild RenderBoxToRenderSectorAdapter at Point(195.0, 174.0) -2 | | | | | | | | TestPaintingCanvas() constructor: 800.0 x 600.0 -2 | | | | | | | | paintChild RenderSectorRing at Point(400.0, 379.0) -2 | | | | | | | | | TestPaintingCanvas() constructor: 800.0 x 600.0 -2 | | paintChild RenderDecoratedBox at Point(0.0, 0.0) -2 | | | TestPaintingCanvas() constructor: 800.0 x 600.0 -2 | | | drawRect(Rect.fromLTRB(0.0, 0.0, 800.0, 56.0), Paint(color:Color(0xff2196f3), drawLooper:true)) -2 | | | paintChild RenderPadding at Point(0.0, 0.0) -2 | | | | TestPaintingCanvas() constructor: 800.0 x 600.0 -2 | | | | paintChild RenderFlex at Point(8.0, 0.0) -2 | | | | | TestPaintingCanvas() constructor: 800.0 x 600.0 -2 | | | | | paintChild RenderConstrainedBox at Point(8.0, 0.0) -2 | | | | | | TestPaintingCanvas() constructor: 800.0 x 600.0 -2 | | | | | | paintChild RenderFlex at Point(8.0, 0.0) -2 | | | | | | | TestPaintingCanvas() constructor: 800.0 x 600.0 -2 | | | | | | | paintChild RenderPadding at Point(8.0, 14.0) -2 | | | | | | | | TestPaintingCanvas() constructor: 800.0 x 600.0 -2 | | | | | | | | paintChild RenderParagraph at Point(32.0, 14.0) -2 | | | | | | | | | TestPaintingCanvas() constructor: 800.0 x 600.0 -2 | | | | | | | | | translate(32.0, 14.0) -2 | | | | | | | | | translate(-32.0, -14.0) ------------------------------------------------------------------------- - -PAINT FOR FRAME #3 ---------------------------------------------- -3 | TestPaintingCanvas() constructor: 800.0 x 600.0 -3 | paintChild RenderScaffold at Point(0.0, 0.0) -3 | | TestPaintingCanvas() constructor: 800.0 x 600.0 -3 | | paintChild RenderDecoratedBox at Point(0.0, 56.0) -3 | | | TestPaintingCanvas() constructor: 800.0 x 600.0 -3 | | | drawRect(Rect.fromLTRB(0.0, 56.0, 800.0, 600.0), Paint(color:Color(0xfffafafa))) -3 | | | paintChild RenderFlex at Point(0.0, 56.0) -3 | | | | TestPaintingCanvas() constructor: 800.0 x 600.0 -3 | | | | paintChild RenderPadding at Point(0.0, 56.0) -3 | | | | | TestPaintingCanvas() constructor: 800.0 x 600.0 -3 | | | | | paintChild RenderFlex at Point(8.0, 81.0) -3 | | | | | | TestPaintingCanvas() constructor: 800.0 x 600.0 -3 | | | | | | paintChild RenderPadding at Point(111.25, 81.0) -3 | | | | | | | TestPaintingCanvas() constructor: 800.0 x 600.0 -3 | | | | | | | paintChild RenderConstrainedBox at Point(119.25, 89.0) -3 | | | | | | | | TestPaintingCanvas() constructor: 800.0 x 600.0 -3 | | | | | | | | paintChild RenderConstrainedBox at Point(119.25, 89.0) -3 | | | | | | | | | TestPaintingCanvas() constructor: 800.0 x 600.0 -3 | | | | | | | | | paintChild RenderDecoratedBox at Point(119.25, 89.0) -3 | | | | | | | | | | TestPaintingCanvas() constructor: 800.0 x 600.0 -3 | | | | | | | | | | drawRRect(Instance of 'RRect', Paint(color:Color(0xffe0e0e0), drawLooper:true)) -3 | | | | | | | | | | paintChild RenderInkWell at Point(119.25, 89.0) -3 | | | | | | | | | | | TestPaintingCanvas() constructor: 800.0 x 600.0 -3 | | | | | | | | | | | paintChild RenderPadding at Point(119.25, 89.0) -3 | | | | | | | | | | | | TestPaintingCanvas() constructor: 800.0 x 600.0 -3 | | | | | | | | | | | | paintChild RenderPositionedBox at Point(127.25, 89.0) -3 | | | | | | | | | | | | | TestPaintingCanvas() constructor: 800.0 x 600.0 -3 | | | | | | | | | | | | | paintChild RenderShrinkWrapWidth at Point(127.25, 89.0) -3 | | | | | | | | | | | | | | TestPaintingCanvas() constructor: 800.0 x 600.0 -3 | | | | | | | | | | | | | | paintChild RenderFlex at Point(127.25, 89.0) -3 | | | | | | | | | | | | | | | TestPaintingCanvas() constructor: 800.0 x 600.0 -3 | | | | | | | | | | | | | | | paintChild RenderPadding at Point(127.25, 89.0) -3 | | | | | | | | | | | | | | | | TestPaintingCanvas() constructor: 800.0 x 600.0 -3 | | | | | | | | | | | | | | | | paintChild RenderPadding at Point(127.25, 89.0) -3 | | | | | | | | | | | | | | | | | TestPaintingCanvas() constructor: 800.0 x 600.0 -3 | | | | | | | | | | | | | | | | | paintChild RenderBoxToRenderSectorAdapter at Point(131.25, 93.0) -3 | | | | | | | | | | | | | | | | | | TestPaintingCanvas() constructor: 800.0 x 600.0 -3 | | | | | | | | | | | | | | | | | | paintChild RenderSectorRing at Point(145.25, 107.0) -3 | | | | | | | | | | | | | | | | | | | TestPaintingCanvas() constructor: 800.0 x 600.0 -3 | | | | | | | | | | | | | | | | | | | paintChild RenderSolidColor at Point(145.25, 107.0) -3 | | | | | | | | | | | | | | | | | | | | TestPaintingCanvas() constructor: 800.0 x 600.0 -3 | | | | | | | | | | | | | | | | | | | | drawPath(Instance of 'Path', Paint(color:Color(0xff909090))) -3 | | | | | | | | | | | | | | | | | | | paintChild RenderSolidColor at Point(145.25, 107.0) -3 | | | | | | | | | | | | | | | | | | | | TestPaintingCanvas() constructor: 800.0 x 600.0 -3 | | | | | | | | | | | | | | | | | | | | drawPath(Instance of 'Path', Paint(color:Color(0xff909090))) -3 | | | | | | | | | | | | | | | | | | | paintChild RenderSolidColor at Point(145.25, 107.0) -3 | | | | | | | | | | | | | | | | | | | | TestPaintingCanvas() constructor: 800.0 x 600.0 -3 | | | | | | | | | | | | | | | | | | | | drawPath(Instance of 'Path', Paint(color:Color(0xff00dd00))) -3 | | | | | | | | | | | | | | | paintChild RenderParagraph at Point(173.25, 97.0) -3 | | | | | | | | | | | | | | | | TestPaintingCanvas() constructor: 800.0 x 600.0 -3 | | | | | | | | | | | | | | | | translate(173.25, 97.0) -3 | | | | | | | | | | | | | | | | translate(-173.25, -97.0) -3 | | | | | | paintChild RenderPadding at Point(488.75, 81.0) -3 | | | | | | | TestPaintingCanvas() constructor: 800.0 x 600.0 -3 | | | | | | | paintChild RenderConstrainedBox at Point(496.75, 89.0) -3 | | | | | | | | TestPaintingCanvas() constructor: 800.0 x 600.0 -3 | | | | | | | | paintChild RenderConstrainedBox at Point(496.75, 89.0) -3 | | | | | | | | | TestPaintingCanvas() constructor: 800.0 x 600.0 -3 | | | | | | | | | paintChild RenderDecoratedBox at Point(496.75, 89.0) -3 | | | | | | | | | | TestPaintingCanvas() constructor: 800.0 x 600.0 -3 | | | | | | | | | | drawRRect(Instance of 'RRect', Paint(color:Color(0xffd6d6d6))) -3 | | | | | | | | | | paintChild RenderInkWell at Point(496.75, 89.0) -3 | | | | | | | | | | | TestPaintingCanvas() constructor: 800.0 x 600.0 -3 | | | | | | | | | | | paintChild RenderPadding at Point(496.75, 89.0) -3 | | | | | | | | | | | | TestPaintingCanvas() constructor: 800.0 x 600.0 -3 | | | | | | | | | | | | paintChild RenderPositionedBox at Point(504.75, 89.0) -3 | | | | | | | | | | | | | TestPaintingCanvas() constructor: 800.0 x 600.0 -3 | | | | | | | | | | | | | paintChild RenderShrinkWrapWidth at Point(504.75, 89.0) -3 | | | | | | | | | | | | | | TestPaintingCanvas() constructor: 800.0 x 600.0 -3 | | | | | | | | | | | | | | paintChild RenderFlex at Point(504.75, 89.0) -3 | | | | | | | | | | | | | | | TestPaintingCanvas() constructor: 800.0 x 600.0 -3 | | | | | | | | | | | | | | | paintChild RenderPadding at Point(504.75, 89.0) -3 | | | | | | | | | | | | | | | | TestPaintingCanvas() constructor: 800.0 x 600.0 -3 | | | | | | | | | | | | | | | | paintChild RenderPadding at Point(504.75, 89.0) -3 | | | | | | | | | | | | | | | | | TestPaintingCanvas() constructor: 800.0 x 600.0 -3 | | | | | | | | | | | | | | | | | paintChild RenderBoxToRenderSectorAdapter at Point(508.75, 93.0) -3 | | | | | | | | | | | | | | | | | | TestPaintingCanvas() constructor: 800.0 x 600.0 -3 | | | | | | | | | | | | | | | | | | paintChild RenderSectorRing at Point(522.75, 107.0) -3 | | | | | | | | | | | | | | | | | | | TestPaintingCanvas() constructor: 800.0 x 600.0 -3 | | | | | | | | | | | | | | | | | | | paintChild RenderSolidColor at Point(522.75, 107.0) -3 | | | | | | | | | | | | | | | | | | | | TestPaintingCanvas() constructor: 800.0 x 600.0 -3 | | | | | | | | | | | | | | | | | | | | drawPath(Instance of 'Path', Paint(color:Color(0xff909090))) -3 | | | | | | | | | | | | | | | | | | | paintChild RenderSolidColor at Point(522.75, 107.0) -3 | | | | | | | | | | | | | | | | | | | | TestPaintingCanvas() constructor: 800.0 x 600.0 -3 | | | | | | | | | | | | | | | | | | | | drawPath(Instance of 'Path', Paint(color:Color(0xff909090))) -3 | | | | | | | | | | | | | | | | | | | paintChild RenderSolidColor at Point(522.75, 107.0) -3 | | | | | | | | | | | | | | | | | | | | TestPaintingCanvas() constructor: 800.0 x 600.0 -3 | | | | | | | | | | | | | | | | | | | | drawPath(Instance of 'Path', Paint(color:Color(0xffdd0000))) -3 | | | | | | | | | | | | | | | paintChild RenderParagraph at Point(550.75, 97.0) -3 | | | | | | | | | | | | | | | | TestPaintingCanvas() constructor: 800.0 x 600.0 -3 | | | | | | | | | | | | | | | | translate(550.75, 97.0) -3 | | | | | | | | | | | | | | | | translate(-550.75, -97.0) -3 | | | | paintChild RenderPadding at Point(179.0, 158.0) -3 | | | | | TestPaintingCanvas() constructor: 800.0 x 600.0 -3 | | | | | paintChild RenderDecoratedBox at Point(187.0, 166.0) -3 | | | | | | TestPaintingCanvas() constructor: 800.0 x 600.0 -3 | | | | | | drawPath(Instance of 'Path', Paint(color:Color(0xff000000))) -3 | | | | | | drawPath(Instance of 'Path', Paint(color:Color(0xff000000))) -3 | | | | | | drawPath(Instance of 'Path', Paint(color:Color(0xff000000))) -3 | | | | | | drawPath(Instance of 'Path', Paint(color:Color(0xff000000))) -3 | | | | | | paintChild RenderPadding at Point(187.0, 166.0) -3 | | | | | | | TestPaintingCanvas() constructor: 800.0 x 600.0 -3 | | | | | | | paintChild RenderBoxToRenderSectorAdapter at Point(195.0, 174.0) -3 | | | | | | | | TestPaintingCanvas() constructor: 800.0 x 600.0 -3 | | | | | | | | paintChild RenderSectorRing at Point(400.0, 379.0) -3 | | | | | | | | | TestPaintingCanvas() constructor: 800.0 x 600.0 -3 | | | | | | | | | paintChild RenderSolidColor at Point(400.0, 379.0) -3 | | | | | | | | | | TestPaintingCanvas() constructor: 800.0 x 600.0 -3 | | | | | | | | | | drawPath(Instance of 'Path', Paint(color:Color(0xff85c594))) -3 | | paintChild RenderDecoratedBox at Point(0.0, 0.0) -3 | | | TestPaintingCanvas() constructor: 800.0 x 600.0 -3 | | | drawRect(Rect.fromLTRB(0.0, 0.0, 800.0, 56.0), Paint(color:Color(0xff2196f3), drawLooper:true)) -3 | | | paintChild RenderPadding at Point(0.0, 0.0) -3 | | | | TestPaintingCanvas() constructor: 800.0 x 600.0 -3 | | | | paintChild RenderFlex at Point(8.0, 0.0) -3 | | | | | TestPaintingCanvas() constructor: 800.0 x 600.0 -3 | | | | | paintChild RenderConstrainedBox at Point(8.0, 0.0) -3 | | | | | | TestPaintingCanvas() constructor: 800.0 x 600.0 -3 | | | | | | paintChild RenderFlex at Point(8.0, 0.0) -3 | | | | | | | TestPaintingCanvas() constructor: 800.0 x 600.0 -3 | | | | | | | paintChild RenderPadding at Point(8.0, 14.0) -3 | | | | | | | | TestPaintingCanvas() constructor: 800.0 x 600.0 -3 | | | | | | | | paintChild RenderParagraph at Point(32.0, 14.0) -3 | | | | | | | | | TestPaintingCanvas() constructor: 800.0 x 600.0 -3 | | | | | | | | | translate(32.0, 14.0) -3 | | | | | | | | | translate(-32.0, -14.0) ------------------------------------------------------------------------- - -PAINT FOR FRAME #4 ---------------------------------------------- -4 | TestPaintingCanvas() constructor: 800.0 x 600.0 -4 | paintChild RenderScaffold at Point(0.0, 0.0) -4 | | TestPaintingCanvas() constructor: 800.0 x 600.0 -4 | | paintChild RenderDecoratedBox at Point(0.0, 56.0) -4 | | | TestPaintingCanvas() constructor: 800.0 x 600.0 -4 | | | drawRect(Rect.fromLTRB(0.0, 56.0, 800.0, 600.0), Paint(color:Color(0xfffafafa))) -4 | | | paintChild RenderFlex at Point(0.0, 56.0) -4 | | | | TestPaintingCanvas() constructor: 800.0 x 600.0 -4 | | | | paintChild RenderPadding at Point(0.0, 56.0) -4 | | | | | TestPaintingCanvas() constructor: 800.0 x 600.0 -4 | | | | | paintChild RenderFlex at Point(8.0, 81.0) -4 | | | | | | TestPaintingCanvas() constructor: 800.0 x 600.0 -4 | | | | | | paintChild RenderPadding at Point(111.25, 81.0) -4 | | | | | | | TestPaintingCanvas() constructor: 800.0 x 600.0 -4 | | | | | | | paintChild RenderConstrainedBox at Point(119.25, 89.0) -4 | | | | | | | | TestPaintingCanvas() constructor: 800.0 x 600.0 -4 | | | | | | | | paintChild RenderConstrainedBox at Point(119.25, 89.0) -4 | | | | | | | | | TestPaintingCanvas() constructor: 800.0 x 600.0 -4 | | | | | | | | | paintChild RenderDecoratedBox at Point(119.25, 89.0) -4 | | | | | | | | | | TestPaintingCanvas() constructor: 800.0 x 600.0 -4 | | | | | | | | | | drawRRect(Instance of 'RRect', Paint(color:Color(0xffe0e0e0), drawLooper:true)) -4 | | | | | | | | | | paintChild RenderInkWell at Point(119.25, 89.0) -4 | | | | | | | | | | | TestPaintingCanvas() constructor: 800.0 x 600.0 -4 | | | | | | | | | | | paintChild RenderPadding at Point(119.25, 89.0) -4 | | | | | | | | | | | | TestPaintingCanvas() constructor: 800.0 x 600.0 -4 | | | | | | | | | | | | paintChild RenderPositionedBox at Point(127.25, 89.0) -4 | | | | | | | | | | | | | TestPaintingCanvas() constructor: 800.0 x 600.0 -4 | | | | | | | | | | | | | paintChild RenderShrinkWrapWidth at Point(127.25, 89.0) -4 | | | | | | | | | | | | | | TestPaintingCanvas() constructor: 800.0 x 600.0 -4 | | | | | | | | | | | | | | paintChild RenderFlex at Point(127.25, 89.0) -4 | | | | | | | | | | | | | | | TestPaintingCanvas() constructor: 800.0 x 600.0 -4 | | | | | | | | | | | | | | | paintChild RenderPadding at Point(127.25, 89.0) -4 | | | | | | | | | | | | | | | | TestPaintingCanvas() constructor: 800.0 x 600.0 -4 | | | | | | | | | | | | | | | | paintChild RenderPadding at Point(127.25, 89.0) -4 | | | | | | | | | | | | | | | | | TestPaintingCanvas() constructor: 800.0 x 600.0 -4 | | | | | | | | | | | | | | | | | paintChild RenderBoxToRenderSectorAdapter at Point(131.25, 93.0) -4 | | | | | | | | | | | | | | | | | | TestPaintingCanvas() constructor: 800.0 x 600.0 -4 | | | | | | | | | | | | | | | | | | paintChild RenderSectorRing at Point(145.25, 107.0) -4 | | | | | | | | | | | | | | | | | | | TestPaintingCanvas() constructor: 800.0 x 600.0 -4 | | | | | | | | | | | | | | | | | | | paintChild RenderSolidColor at Point(145.25, 107.0) -4 | | | | | | | | | | | | | | | | | | | | TestPaintingCanvas() constructor: 800.0 x 600.0 -4 | | | | | | | | | | | | | | | | | | | | drawPath(Instance of 'Path', Paint(color:Color(0xff909090))) -4 | | | | | | | | | | | | | | | | | | | paintChild RenderSolidColor at Point(145.25, 107.0) -4 | | | | | | | | | | | | | | | | | | | | TestPaintingCanvas() constructor: 800.0 x 600.0 -4 | | | | | | | | | | | | | | | | | | | | drawPath(Instance of 'Path', Paint(color:Color(0xff909090))) -4 | | | | | | | | | | | | | | | | | | | paintChild RenderSolidColor at Point(145.25, 107.0) -4 | | | | | | | | | | | | | | | | | | | | TestPaintingCanvas() constructor: 800.0 x 600.0 -4 | | | | | | | | | | | | | | | | | | | | drawPath(Instance of 'Path', Paint(color:Color(0xff00dd00))) -4 | | | | | | | | | | | | | | | paintChild RenderParagraph at Point(173.25, 97.0) -4 | | | | | | | | | | | | | | | | TestPaintingCanvas() constructor: 800.0 x 600.0 -4 | | | | | | | | | | | | | | | | translate(173.25, 97.0) -4 | | | | | | | | | | | | | | | | translate(-173.25, -97.0) -4 | | | | | | paintChild RenderPadding at Point(488.75, 81.0) -4 | | | | | | | TestPaintingCanvas() constructor: 800.0 x 600.0 -4 | | | | | | | paintChild RenderConstrainedBox at Point(496.75, 89.0) -4 | | | | | | | | TestPaintingCanvas() constructor: 800.0 x 600.0 -4 | | | | | | | | paintChild RenderConstrainedBox at Point(496.75, 89.0) -4 | | | | | | | | | TestPaintingCanvas() constructor: 800.0 x 600.0 -4 | | | | | | | | | paintChild RenderDecoratedBox at Point(496.75, 89.0) -4 | | | | | | | | | | TestPaintingCanvas() constructor: 800.0 x 600.0 -4 | | | | | | | | | | drawRRect(Instance of 'RRect', Paint(color:Color(0xffd6d6d6))) -4 | | | | | | | | | | paintChild RenderInkWell at Point(496.75, 89.0) -4 | | | | | | | | | | | TestPaintingCanvas() constructor: 800.0 x 600.0 -4 | | | | | | | | | | | paintChild RenderPadding at Point(496.75, 89.0) -4 | | | | | | | | | | | | TestPaintingCanvas() constructor: 800.0 x 600.0 -4 | | | | | | | | | | | | paintChild RenderPositionedBox at Point(504.75, 89.0) -4 | | | | | | | | | | | | | TestPaintingCanvas() constructor: 800.0 x 600.0 -4 | | | | | | | | | | | | | paintChild RenderShrinkWrapWidth at Point(504.75, 89.0) -4 | | | | | | | | | | | | | | TestPaintingCanvas() constructor: 800.0 x 600.0 -4 | | | | | | | | | | | | | | paintChild RenderFlex at Point(504.75, 89.0) -4 | | | | | | | | | | | | | | | TestPaintingCanvas() constructor: 800.0 x 600.0 -4 | | | | | | | | | | | | | | | paintChild RenderPadding at Point(504.75, 89.0) -4 | | | | | | | | | | | | | | | | TestPaintingCanvas() constructor: 800.0 x 600.0 -4 | | | | | | | | | | | | | | | | paintChild RenderPadding at Point(504.75, 89.0) -4 | | | | | | | | | | | | | | | | | TestPaintingCanvas() constructor: 800.0 x 600.0 -4 | | | | | | | | | | | | | | | | | paintChild RenderBoxToRenderSectorAdapter at Point(508.75, 93.0) -4 | | | | | | | | | | | | | | | | | | TestPaintingCanvas() constructor: 800.0 x 600.0 -4 | | | | | | | | | | | | | | | | | | paintChild RenderSectorRing at Point(522.75, 107.0) -4 | | | | | | | | | | | | | | | | | | | TestPaintingCanvas() constructor: 800.0 x 600.0 -4 | | | | | | | | | | | | | | | | | | | paintChild RenderSolidColor at Point(522.75, 107.0) -4 | | | | | | | | | | | | | | | | | | | | TestPaintingCanvas() constructor: 800.0 x 600.0 -4 | | | | | | | | | | | | | | | | | | | | drawPath(Instance of 'Path', Paint(color:Color(0xff909090))) -4 | | | | | | | | | | | | | | | | | | | paintChild RenderSolidColor at Point(522.75, 107.0) -4 | | | | | | | | | | | | | | | | | | | | TestPaintingCanvas() constructor: 800.0 x 600.0 -4 | | | | | | | | | | | | | | | | | | | | drawPath(Instance of 'Path', Paint(color:Color(0xff909090))) -4 | | | | | | | | | | | | | | | | | | | paintChild RenderSolidColor at Point(522.75, 107.0) -4 | | | | | | | | | | | | | | | | | | | | TestPaintingCanvas() constructor: 800.0 x 600.0 -4 | | | | | | | | | | | | | | | | | | | | drawPath(Instance of 'Path', Paint(color:Color(0xffdd0000))) -4 | | | | | | | | | | | | | | | paintChild RenderParagraph at Point(550.75, 97.0) -4 | | | | | | | | | | | | | | | | TestPaintingCanvas() constructor: 800.0 x 600.0 -4 | | | | | | | | | | | | | | | | translate(550.75, 97.0) -4 | | | | | | | | | | | | | | | | translate(-550.75, -97.0) -4 | | | | paintChild RenderPadding at Point(179.0, 158.0) -4 | | | | | TestPaintingCanvas() constructor: 800.0 x 600.0 -4 | | | | | paintChild RenderDecoratedBox at Point(187.0, 166.0) -4 | | | | | | TestPaintingCanvas() constructor: 800.0 x 600.0 -4 | | | | | | drawPath(Instance of 'Path', Paint(color:Color(0xff000000))) -4 | | | | | | drawPath(Instance of 'Path', Paint(color:Color(0xff000000))) -4 | | | | | | drawPath(Instance of 'Path', Paint(color:Color(0xff000000))) -4 | | | | | | drawPath(Instance of 'Path', Paint(color:Color(0xff000000))) -4 | | | | | | paintChild RenderPadding at Point(187.0, 166.0) -4 | | | | | | | TestPaintingCanvas() constructor: 800.0 x 600.0 -4 | | | | | | | paintChild RenderBoxToRenderSectorAdapter at Point(195.0, 174.0) -4 | | | | | | | | TestPaintingCanvas() constructor: 800.0 x 600.0 -4 | | | | | | | | paintChild RenderSectorRing at Point(400.0, 379.0) -4 | | | | | | | | | TestPaintingCanvas() constructor: 800.0 x 600.0 -4 | | | | | | | | | paintChild RenderSolidColor at Point(400.0, 379.0) -4 | | | | | | | | | | TestPaintingCanvas() constructor: 800.0 x 600.0 -4 | | | | | | | | | | drawPath(Instance of 'Path', Paint(color:Color(0xff85c594))) -4 | | | | | | | | | paintChild RenderSolidColor at Point(400.0, 379.0) -4 | | | | | | | | | | TestPaintingCanvas() constructor: 800.0 x 600.0 -4 | | | | | | | | | | drawPath(Instance of 'Path', Paint(color:Color(0xffe6ade9))) -4 | | paintChild RenderDecoratedBox at Point(0.0, 0.0) -4 | | | TestPaintingCanvas() constructor: 800.0 x 600.0 -4 | | | drawRect(Rect.fromLTRB(0.0, 0.0, 800.0, 56.0), Paint(color:Color(0xff2196f3), drawLooper:true)) -4 | | | paintChild RenderPadding at Point(0.0, 0.0) -4 | | | | TestPaintingCanvas() constructor: 800.0 x 600.0 -4 | | | | paintChild RenderFlex at Point(8.0, 0.0) -4 | | | | | TestPaintingCanvas() constructor: 800.0 x 600.0 -4 | | | | | paintChild RenderConstrainedBox at Point(8.0, 0.0) -4 | | | | | | TestPaintingCanvas() constructor: 800.0 x 600.0 -4 | | | | | | paintChild RenderFlex at Point(8.0, 0.0) -4 | | | | | | | TestPaintingCanvas() constructor: 800.0 x 600.0 -4 | | | | | | | paintChild RenderPadding at Point(8.0, 14.0) -4 | | | | | | | | TestPaintingCanvas() constructor: 800.0 x 600.0 -4 | | | | | | | | paintChild RenderParagraph at Point(32.0, 14.0) -4 | | | | | | | | | TestPaintingCanvas() constructor: 800.0 x 600.0 -4 | | | | | | | | | translate(32.0, 14.0) -4 | | | | | | | | | translate(-32.0, -14.0) ------------------------------------------------------------------------- - -PAINT FOR FRAME #5 ---------------------------------------------- -5 | TestPaintingCanvas() constructor: 800.0 x 600.0 -5 | paintChild RenderScaffold at Point(0.0, 0.0) -5 | | TestPaintingCanvas() constructor: 800.0 x 600.0 -5 | | paintChild RenderDecoratedBox at Point(0.0, 56.0) -5 | | | TestPaintingCanvas() constructor: 800.0 x 600.0 -5 | | | drawRect(Rect.fromLTRB(0.0, 56.0, 800.0, 600.0), Paint(color:Color(0xfffafafa))) -5 | | | paintChild RenderFlex at Point(0.0, 56.0) -5 | | | | TestPaintingCanvas() constructor: 800.0 x 600.0 -5 | | | | paintChild RenderPadding at Point(0.0, 56.0) -5 | | | | | TestPaintingCanvas() constructor: 800.0 x 600.0 -5 | | | | | paintChild RenderFlex at Point(8.0, 81.0) -5 | | | | | | TestPaintingCanvas() constructor: 800.0 x 600.0 -5 | | | | | | paintChild RenderPadding at Point(111.25, 81.0) -5 | | | | | | | TestPaintingCanvas() constructor: 800.0 x 600.0 -5 | | | | | | | paintChild RenderConstrainedBox at Point(119.25, 89.0) -5 | | | | | | | | TestPaintingCanvas() constructor: 800.0 x 600.0 -5 | | | | | | | | paintChild RenderConstrainedBox at Point(119.25, 89.0) -5 | | | | | | | | | TestPaintingCanvas() constructor: 800.0 x 600.0 -5 | | | | | | | | | paintChild RenderDecoratedBox at Point(119.25, 89.0) -5 | | | | | | | | | | TestPaintingCanvas() constructor: 800.0 x 600.0 -5 | | | | | | | | | | drawRRect(Instance of 'RRect', Paint(color:Color(0xffe0e0e0), drawLooper:true)) -5 | | | | | | | | | | paintChild RenderInkWell at Point(119.25, 89.0) -5 | | | | | | | | | | | TestPaintingCanvas() constructor: 800.0 x 600.0 -5 | | | | | | | | | | | paintChild RenderPadding at Point(119.25, 89.0) -5 | | | | | | | | | | | | TestPaintingCanvas() constructor: 800.0 x 600.0 -5 | | | | | | | | | | | | paintChild RenderPositionedBox at Point(127.25, 89.0) -5 | | | | | | | | | | | | | TestPaintingCanvas() constructor: 800.0 x 600.0 -5 | | | | | | | | | | | | | paintChild RenderShrinkWrapWidth at Point(127.25, 89.0) -5 | | | | | | | | | | | | | | TestPaintingCanvas() constructor: 800.0 x 600.0 -5 | | | | | | | | | | | | | | paintChild RenderFlex at Point(127.25, 89.0) -5 | | | | | | | | | | | | | | | TestPaintingCanvas() constructor: 800.0 x 600.0 -5 | | | | | | | | | | | | | | | paintChild RenderPadding at Point(127.25, 89.0) -5 | | | | | | | | | | | | | | | | TestPaintingCanvas() constructor: 800.0 x 600.0 -5 | | | | | | | | | | | | | | | | paintChild RenderPadding at Point(127.25, 89.0) -5 | | | | | | | | | | | | | | | | | TestPaintingCanvas() constructor: 800.0 x 600.0 -5 | | | | | | | | | | | | | | | | | paintChild RenderBoxToRenderSectorAdapter at Point(131.25, 93.0) -5 | | | | | | | | | | | | | | | | | | TestPaintingCanvas() constructor: 800.0 x 600.0 -5 | | | | | | | | | | | | | | | | | | paintChild RenderSectorRing at Point(145.25, 107.0) -5 | | | | | | | | | | | | | | | | | | | TestPaintingCanvas() constructor: 800.0 x 600.0 -5 | | | | | | | | | | | | | | | | | | | paintChild RenderSolidColor at Point(145.25, 107.0) -5 | | | | | | | | | | | | | | | | | | | | TestPaintingCanvas() constructor: 800.0 x 600.0 -5 | | | | | | | | | | | | | | | | | | | | drawPath(Instance of 'Path', Paint(color:Color(0xff909090))) -5 | | | | | | | | | | | | | | | | | | | paintChild RenderSolidColor at Point(145.25, 107.0) -5 | | | | | | | | | | | | | | | | | | | | TestPaintingCanvas() constructor: 800.0 x 600.0 -5 | | | | | | | | | | | | | | | | | | | | drawPath(Instance of 'Path', Paint(color:Color(0xff909090))) -5 | | | | | | | | | | | | | | | | | | | paintChild RenderSolidColor at Point(145.25, 107.0) -5 | | | | | | | | | | | | | | | | | | | | TestPaintingCanvas() constructor: 800.0 x 600.0 -5 | | | | | | | | | | | | | | | | | | | | drawPath(Instance of 'Path', Paint(color:Color(0xff00dd00))) -5 | | | | | | | | | | | | | | | paintChild RenderParagraph at Point(173.25, 97.0) -5 | | | | | | | | | | | | | | | | TestPaintingCanvas() constructor: 800.0 x 600.0 -5 | | | | | | | | | | | | | | | | translate(173.25, 97.0) -5 | | | | | | | | | | | | | | | | translate(-173.25, -97.0) -5 | | | | | | paintChild RenderPadding at Point(488.75, 81.0) -5 | | | | | | | TestPaintingCanvas() constructor: 800.0 x 600.0 -5 | | | | | | | paintChild RenderConstrainedBox at Point(496.75, 89.0) -5 | | | | | | | | TestPaintingCanvas() constructor: 800.0 x 600.0 -5 | | | | | | | | paintChild RenderConstrainedBox at Point(496.75, 89.0) -5 | | | | | | | | | TestPaintingCanvas() constructor: 800.0 x 600.0 -5 | | | | | | | | | paintChild RenderDecoratedBox at Point(496.75, 89.0) -5 | | | | | | | | | | TestPaintingCanvas() constructor: 800.0 x 600.0 -5 | | | | | | | | | | drawRRect(Instance of 'RRect', Paint(color:Color(0xffd6d6d6))) -5 | | | | | | | | | | paintChild RenderInkWell at Point(496.75, 89.0) -5 | | | | | | | | | | | TestPaintingCanvas() constructor: 800.0 x 600.0 -5 | | | | | | | | | | | paintChild RenderPadding at Point(496.75, 89.0) -5 | | | | | | | | | | | | TestPaintingCanvas() constructor: 800.0 x 600.0 -5 | | | | | | | | | | | | paintChild RenderPositionedBox at Point(504.75, 89.0) -5 | | | | | | | | | | | | | TestPaintingCanvas() constructor: 800.0 x 600.0 -5 | | | | | | | | | | | | | paintChild RenderShrinkWrapWidth at Point(504.75, 89.0) -5 | | | | | | | | | | | | | | TestPaintingCanvas() constructor: 800.0 x 600.0 -5 | | | | | | | | | | | | | | paintChild RenderFlex at Point(504.75, 89.0) -5 | | | | | | | | | | | | | | | TestPaintingCanvas() constructor: 800.0 x 600.0 -5 | | | | | | | | | | | | | | | paintChild RenderPadding at Point(504.75, 89.0) -5 | | | | | | | | | | | | | | | | TestPaintingCanvas() constructor: 800.0 x 600.0 -5 | | | | | | | | | | | | | | | | paintChild RenderPadding at Point(504.75, 89.0) -5 | | | | | | | | | | | | | | | | | TestPaintingCanvas() constructor: 800.0 x 600.0 -5 | | | | | | | | | | | | | | | | | paintChild RenderBoxToRenderSectorAdapter at Point(508.75, 93.0) -5 | | | | | | | | | | | | | | | | | | TestPaintingCanvas() constructor: 800.0 x 600.0 -5 | | | | | | | | | | | | | | | | | | paintChild RenderSectorRing at Point(522.75, 107.0) -5 | | | | | | | | | | | | | | | | | | | TestPaintingCanvas() constructor: 800.0 x 600.0 -5 | | | | | | | | | | | | | | | | | | | paintChild RenderSolidColor at Point(522.75, 107.0) -5 | | | | | | | | | | | | | | | | | | | | TestPaintingCanvas() constructor: 800.0 x 600.0 -5 | | | | | | | | | | | | | | | | | | | | drawPath(Instance of 'Path', Paint(color:Color(0xff909090))) -5 | | | | | | | | | | | | | | | | | | | paintChild RenderSolidColor at Point(522.75, 107.0) -5 | | | | | | | | | | | | | | | | | | | | TestPaintingCanvas() constructor: 800.0 x 600.0 -5 | | | | | | | | | | | | | | | | | | | | drawPath(Instance of 'Path', Paint(color:Color(0xff909090))) -5 | | | | | | | | | | | | | | | | | | | paintChild RenderSolidColor at Point(522.75, 107.0) -5 | | | | | | | | | | | | | | | | | | | | TestPaintingCanvas() constructor: 800.0 x 600.0 -5 | | | | | | | | | | | | | | | | | | | | drawPath(Instance of 'Path', Paint(color:Color(0xffdd0000))) -5 | | | | | | | | | | | | | | | paintChild RenderParagraph at Point(550.75, 97.0) -5 | | | | | | | | | | | | | | | | TestPaintingCanvas() constructor: 800.0 x 600.0 -5 | | | | | | | | | | | | | | | | translate(550.75, 97.0) -5 | | | | | | | | | | | | | | | | translate(-550.75, -97.0) -5 | | | | paintChild RenderPadding at Point(179.0, 158.0) -5 | | | | | TestPaintingCanvas() constructor: 800.0 x 600.0 -5 | | | | | paintChild RenderDecoratedBox at Point(187.0, 166.0) -5 | | | | | | TestPaintingCanvas() constructor: 800.0 x 600.0 -5 | | | | | | drawPath(Instance of 'Path', Paint(color:Color(0xff000000))) -5 | | | | | | drawPath(Instance of 'Path', Paint(color:Color(0xff000000))) -5 | | | | | | drawPath(Instance of 'Path', Paint(color:Color(0xff000000))) -5 | | | | | | drawPath(Instance of 'Path', Paint(color:Color(0xff000000))) -5 | | | | | | paintChild RenderPadding at Point(187.0, 166.0) -5 | | | | | | | TestPaintingCanvas() constructor: 800.0 x 600.0 -5 | | | | | | | paintChild RenderBoxToRenderSectorAdapter at Point(195.0, 174.0) -5 | | | | | | | | TestPaintingCanvas() constructor: 800.0 x 600.0 -5 | | | | | | | | paintChild RenderSectorRing at Point(400.0, 379.0) -5 | | | | | | | | | TestPaintingCanvas() constructor: 800.0 x 600.0 -5 | | | | | | | | | paintChild RenderSolidColor at Point(400.0, 379.0) -5 | | | | | | | | | | TestPaintingCanvas() constructor: 800.0 x 600.0 -5 | | | | | | | | | | drawPath(Instance of 'Path', Paint(color:Color(0xff85c594))) -5 | | | | | | | | | paintChild RenderSolidColor at Point(400.0, 379.0) -5 | | | | | | | | | | TestPaintingCanvas() constructor: 800.0 x 600.0 -5 | | | | | | | | | | drawPath(Instance of 'Path', Paint(color:Color(0xffe6ade9))) -5 | | | | | | | | | paintChild RenderSolidColor at Point(400.0, 379.0) -5 | | | | | | | | | | TestPaintingCanvas() constructor: 800.0 x 600.0 -5 | | | | | | | | | | drawPath(Instance of 'Path', Paint(color:Color(0xffbee9dd))) -5 | | paintChild RenderDecoratedBox at Point(0.0, 0.0) -5 | | | TestPaintingCanvas() constructor: 800.0 x 600.0 -5 | | | drawRect(Rect.fromLTRB(0.0, 0.0, 800.0, 56.0), Paint(color:Color(0xff2196f3), drawLooper:true)) -5 | | | paintChild RenderPadding at Point(0.0, 0.0) -5 | | | | TestPaintingCanvas() constructor: 800.0 x 600.0 -5 | | | | paintChild RenderFlex at Point(8.0, 0.0) -5 | | | | | TestPaintingCanvas() constructor: 800.0 x 600.0 -5 | | | | | paintChild RenderConstrainedBox at Point(8.0, 0.0) -5 | | | | | | TestPaintingCanvas() constructor: 800.0 x 600.0 -5 | | | | | | paintChild RenderFlex at Point(8.0, 0.0) -5 | | | | | | | TestPaintingCanvas() constructor: 800.0 x 600.0 -5 | | | | | | | paintChild RenderPadding at Point(8.0, 14.0) -5 | | | | | | | | TestPaintingCanvas() constructor: 800.0 x 600.0 -5 | | | | | | | | paintChild RenderParagraph at Point(32.0, 14.0) -5 | | | | | | | | | TestPaintingCanvas() constructor: 800.0 x 600.0 -5 | | | | | | | | | translate(32.0, 14.0) -5 | | | | | | | | | translate(-32.0, -14.0) ------------------------------------------------------------------------- - -PAINT FOR FRAME #6 ---------------------------------------------- -6 | TestPaintingCanvas() constructor: 800.0 x 600.0 -6 | paintChild RenderScaffold at Point(0.0, 0.0) -6 | | TestPaintingCanvas() constructor: 800.0 x 600.0 -6 | | paintChild RenderDecoratedBox at Point(0.0, 56.0) -6 | | | TestPaintingCanvas() constructor: 800.0 x 600.0 -6 | | | drawRect(Rect.fromLTRB(0.0, 56.0, 800.0, 600.0), Paint(color:Color(0xfffafafa))) -6 | | | paintChild RenderFlex at Point(0.0, 56.0) -6 | | | | TestPaintingCanvas() constructor: 800.0 x 600.0 -6 | | | | paintChild RenderPadding at Point(0.0, 56.0) -6 | | | | | TestPaintingCanvas() constructor: 800.0 x 600.0 -6 | | | | | paintChild RenderFlex at Point(8.0, 81.0) -6 | | | | | | TestPaintingCanvas() constructor: 800.0 x 600.0 -6 | | | | | | paintChild RenderPadding at Point(111.25, 81.0) -6 | | | | | | | TestPaintingCanvas() constructor: 800.0 x 600.0 -6 | | | | | | | paintChild RenderConstrainedBox at Point(119.25, 89.0) -6 | | | | | | | | TestPaintingCanvas() constructor: 800.0 x 600.0 -6 | | | | | | | | paintChild RenderConstrainedBox at Point(119.25, 89.0) -6 | | | | | | | | | TestPaintingCanvas() constructor: 800.0 x 600.0 -6 | | | | | | | | | paintChild RenderDecoratedBox at Point(119.25, 89.0) -6 | | | | | | | | | | TestPaintingCanvas() constructor: 800.0 x 600.0 -6 | | | | | | | | | | drawRRect(Instance of 'RRect', Paint(color:Color(0xffe0e0e0), drawLooper:true)) -6 | | | | | | | | | | paintChild RenderInkWell at Point(119.25, 89.0) -6 | | | | | | | | | | | TestPaintingCanvas() constructor: 800.0 x 600.0 -6 | | | | | | | | | | | paintChild RenderPadding at Point(119.25, 89.0) -6 | | | | | | | | | | | | TestPaintingCanvas() constructor: 800.0 x 600.0 -6 | | | | | | | | | | | | paintChild RenderPositionedBox at Point(127.25, 89.0) -6 | | | | | | | | | | | | | TestPaintingCanvas() constructor: 800.0 x 600.0 -6 | | | | | | | | | | | | | paintChild RenderShrinkWrapWidth at Point(127.25, 89.0) -6 | | | | | | | | | | | | | | TestPaintingCanvas() constructor: 800.0 x 600.0 -6 | | | | | | | | | | | | | | paintChild RenderFlex at Point(127.25, 89.0) -6 | | | | | | | | | | | | | | | TestPaintingCanvas() constructor: 800.0 x 600.0 -6 | | | | | | | | | | | | | | | paintChild RenderPadding at Point(127.25, 89.0) -6 | | | | | | | | | | | | | | | | TestPaintingCanvas() constructor: 800.0 x 600.0 -6 | | | | | | | | | | | | | | | | paintChild RenderPadding at Point(127.25, 89.0) -6 | | | | | | | | | | | | | | | | | TestPaintingCanvas() constructor: 800.0 x 600.0 -6 | | | | | | | | | | | | | | | | | paintChild RenderBoxToRenderSectorAdapter at Point(131.25, 93.0) -6 | | | | | | | | | | | | | | | | | | TestPaintingCanvas() constructor: 800.0 x 600.0 -6 | | | | | | | | | | | | | | | | | | paintChild RenderSectorRing at Point(145.25, 107.0) -6 | | | | | | | | | | | | | | | | | | | TestPaintingCanvas() constructor: 800.0 x 600.0 -6 | | | | | | | | | | | | | | | | | | | paintChild RenderSolidColor at Point(145.25, 107.0) -6 | | | | | | | | | | | | | | | | | | | | TestPaintingCanvas() constructor: 800.0 x 600.0 -6 | | | | | | | | | | | | | | | | | | | | drawPath(Instance of 'Path', Paint(color:Color(0xff909090))) -6 | | | | | | | | | | | | | | | | | | | paintChild RenderSolidColor at Point(145.25, 107.0) -6 | | | | | | | | | | | | | | | | | | | | TestPaintingCanvas() constructor: 800.0 x 600.0 -6 | | | | | | | | | | | | | | | | | | | | drawPath(Instance of 'Path', Paint(color:Color(0xff909090))) -6 | | | | | | | | | | | | | | | | | | | paintChild RenderSolidColor at Point(145.25, 107.0) -6 | | | | | | | | | | | | | | | | | | | | TestPaintingCanvas() constructor: 800.0 x 600.0 -6 | | | | | | | | | | | | | | | | | | | | drawPath(Instance of 'Path', Paint(color:Color(0xff00dd00))) -6 | | | | | | | | | | | | | | | paintChild RenderParagraph at Point(173.25, 97.0) -6 | | | | | | | | | | | | | | | | TestPaintingCanvas() constructor: 800.0 x 600.0 -6 | | | | | | | | | | | | | | | | translate(173.25, 97.0) -6 | | | | | | | | | | | | | | | | translate(-173.25, -97.0) -6 | | | | | | paintChild RenderPadding at Point(488.75, 81.0) -6 | | | | | | | TestPaintingCanvas() constructor: 800.0 x 600.0 -6 | | | | | | | paintChild RenderConstrainedBox at Point(496.75, 89.0) -6 | | | | | | | | TestPaintingCanvas() constructor: 800.0 x 600.0 -6 | | | | | | | | paintChild RenderConstrainedBox at Point(496.75, 89.0) -6 | | | | | | | | | TestPaintingCanvas() constructor: 800.0 x 600.0 -6 | | | | | | | | | paintChild RenderDecoratedBox at Point(496.75, 89.0) -6 | | | | | | | | | | TestPaintingCanvas() constructor: 800.0 x 600.0 -6 | | | | | | | | | | drawRRect(Instance of 'RRect', Paint(color:Color(0xffd6d6d6))) -6 | | | | | | | | | | paintChild RenderInkWell at Point(496.75, 89.0) -6 | | | | | | | | | | | TestPaintingCanvas() constructor: 800.0 x 600.0 -6 | | | | | | | | | | | paintChild RenderPadding at Point(496.75, 89.0) -6 | | | | | | | | | | | | TestPaintingCanvas() constructor: 800.0 x 600.0 -6 | | | | | | | | | | | | paintChild RenderPositionedBox at Point(504.75, 89.0) -6 | | | | | | | | | | | | | TestPaintingCanvas() constructor: 800.0 x 600.0 -6 | | | | | | | | | | | | | paintChild RenderShrinkWrapWidth at Point(504.75, 89.0) -6 | | | | | | | | | | | | | | TestPaintingCanvas() constructor: 800.0 x 600.0 -6 | | | | | | | | | | | | | | paintChild RenderFlex at Point(504.75, 89.0) -6 | | | | | | | | | | | | | | | TestPaintingCanvas() constructor: 800.0 x 600.0 -6 | | | | | | | | | | | | | | | paintChild RenderPadding at Point(504.75, 89.0) -6 | | | | | | | | | | | | | | | | TestPaintingCanvas() constructor: 800.0 x 600.0 -6 | | | | | | | | | | | | | | | | paintChild RenderPadding at Point(504.75, 89.0) -6 | | | | | | | | | | | | | | | | | TestPaintingCanvas() constructor: 800.0 x 600.0 -6 | | | | | | | | | | | | | | | | | paintChild RenderBoxToRenderSectorAdapter at Point(508.75, 93.0) -6 | | | | | | | | | | | | | | | | | | TestPaintingCanvas() constructor: 800.0 x 600.0 -6 | | | | | | | | | | | | | | | | | | paintChild RenderSectorRing at Point(522.75, 107.0) -6 | | | | | | | | | | | | | | | | | | | TestPaintingCanvas() constructor: 800.0 x 600.0 -6 | | | | | | | | | | | | | | | | | | | paintChild RenderSolidColor at Point(522.75, 107.0) -6 | | | | | | | | | | | | | | | | | | | | TestPaintingCanvas() constructor: 800.0 x 600.0 -6 | | | | | | | | | | | | | | | | | | | | drawPath(Instance of 'Path', Paint(color:Color(0xff909090))) -6 | | | | | | | | | | | | | | | | | | | paintChild RenderSolidColor at Point(522.75, 107.0) -6 | | | | | | | | | | | | | | | | | | | | TestPaintingCanvas() constructor: 800.0 x 600.0 -6 | | | | | | | | | | | | | | | | | | | | drawPath(Instance of 'Path', Paint(color:Color(0xff909090))) -6 | | | | | | | | | | | | | | | | | | | paintChild RenderSolidColor at Point(522.75, 107.0) -6 | | | | | | | | | | | | | | | | | | | | TestPaintingCanvas() constructor: 800.0 x 600.0 -6 | | | | | | | | | | | | | | | | | | | | drawPath(Instance of 'Path', Paint(color:Color(0xffdd0000))) -6 | | | | | | | | | | | | | | | paintChild RenderParagraph at Point(550.75, 97.0) -6 | | | | | | | | | | | | | | | | TestPaintingCanvas() constructor: 800.0 x 600.0 -6 | | | | | | | | | | | | | | | | translate(550.75, 97.0) -6 | | | | | | | | | | | | | | | | translate(-550.75, -97.0) -6 | | | | paintChild RenderPadding at Point(179.0, 158.0) -6 | | | | | TestPaintingCanvas() constructor: 800.0 x 600.0 -6 | | | | | paintChild RenderDecoratedBox at Point(187.0, 166.0) -6 | | | | | | TestPaintingCanvas() constructor: 800.0 x 600.0 -6 | | | | | | drawPath(Instance of 'Path', Paint(color:Color(0xff000000))) -6 | | | | | | drawPath(Instance of 'Path', Paint(color:Color(0xff000000))) -6 | | | | | | drawPath(Instance of 'Path', Paint(color:Color(0xff000000))) -6 | | | | | | drawPath(Instance of 'Path', Paint(color:Color(0xff000000))) -6 | | | | | | paintChild RenderPadding at Point(187.0, 166.0) -6 | | | | | | | TestPaintingCanvas() constructor: 800.0 x 600.0 -6 | | | | | | | paintChild RenderBoxToRenderSectorAdapter at Point(195.0, 174.0) -6 | | | | | | | | TestPaintingCanvas() constructor: 800.0 x 600.0 -6 | | | | | | | | paintChild RenderSectorRing at Point(400.0, 379.0) -6 | | | | | | | | | TestPaintingCanvas() constructor: 800.0 x 600.0 -6 | | | | | | | | | paintChild RenderSolidColor at Point(400.0, 379.0) -6 | | | | | | | | | | TestPaintingCanvas() constructor: 800.0 x 600.0 -6 | | | | | | | | | | drawPath(Instance of 'Path', Paint(color:Color(0xff85c594))) -6 | | | | | | | | | paintChild RenderSolidColor at Point(400.0, 379.0) -6 | | | | | | | | | | TestPaintingCanvas() constructor: 800.0 x 600.0 -6 | | | | | | | | | | drawPath(Instance of 'Path', Paint(color:Color(0xffe6ade9))) -6 | | paintChild RenderDecoratedBox at Point(0.0, 0.0) -6 | | | TestPaintingCanvas() constructor: 800.0 x 600.0 -6 | | | drawRect(Rect.fromLTRB(0.0, 0.0, 800.0, 56.0), Paint(color:Color(0xff2196f3), drawLooper:true)) -6 | | | paintChild RenderPadding at Point(0.0, 0.0) -6 | | | | TestPaintingCanvas() constructor: 800.0 x 600.0 -6 | | | | paintChild RenderFlex at Point(8.0, 0.0) -6 | | | | | TestPaintingCanvas() constructor: 800.0 x 600.0 -6 | | | | | paintChild RenderConstrainedBox at Point(8.0, 0.0) -6 | | | | | | TestPaintingCanvas() constructor: 800.0 x 600.0 -6 | | | | | | paintChild RenderFlex at Point(8.0, 0.0) -6 | | | | | | | TestPaintingCanvas() constructor: 800.0 x 600.0 -6 | | | | | | | paintChild RenderPadding at Point(8.0, 14.0) -6 | | | | | | | | TestPaintingCanvas() constructor: 800.0 x 600.0 -6 | | | | | | | | paintChild RenderParagraph at Point(32.0, 14.0) -6 | | | | | | | | | TestPaintingCanvas() constructor: 800.0 x 600.0 -6 | | | | | | | | | translate(32.0, 14.0) -6 | | | | | | | | | translate(-32.0, -14.0) ------------------------------------------------------------------------- - -PAINT FOR FRAME #7 ---------------------------------------------- -7 | TestPaintingCanvas() constructor: 800.0 x 600.0 -7 | paintChild RenderScaffold at Point(0.0, 0.0) -7 | | TestPaintingCanvas() constructor: 800.0 x 600.0 -7 | | paintChild RenderDecoratedBox at Point(0.0, 56.0) -7 | | | TestPaintingCanvas() constructor: 800.0 x 600.0 -7 | | | drawRect(Rect.fromLTRB(0.0, 56.0, 800.0, 600.0), Paint(color:Color(0xfffafafa))) -7 | | | paintChild RenderFlex at Point(0.0, 56.0) -7 | | | | TestPaintingCanvas() constructor: 800.0 x 600.0 -7 | | | | paintChild RenderPadding at Point(0.0, 56.0) -7 | | | | | TestPaintingCanvas() constructor: 800.0 x 600.0 -7 | | | | | paintChild RenderFlex at Point(8.0, 81.0) -7 | | | | | | TestPaintingCanvas() constructor: 800.0 x 600.0 -7 | | | | | | paintChild RenderPadding at Point(111.25, 81.0) -7 | | | | | | | TestPaintingCanvas() constructor: 800.0 x 600.0 -7 | | | | | | | paintChild RenderConstrainedBox at Point(119.25, 89.0) -7 | | | | | | | | TestPaintingCanvas() constructor: 800.0 x 600.0 -7 | | | | | | | | paintChild RenderConstrainedBox at Point(119.25, 89.0) -7 | | | | | | | | | TestPaintingCanvas() constructor: 800.0 x 600.0 -7 | | | | | | | | | paintChild RenderDecoratedBox at Point(119.25, 89.0) -7 | | | | | | | | | | TestPaintingCanvas() constructor: 800.0 x 600.0 -7 | | | | | | | | | | drawRRect(Instance of 'RRect', Paint(color:Color(0xffe0e0e0), drawLooper:true)) -7 | | | | | | | | | | paintChild RenderInkWell at Point(119.25, 89.0) -7 | | | | | | | | | | | TestPaintingCanvas() constructor: 800.0 x 600.0 -7 | | | | | | | | | | | paintChild RenderPadding at Point(119.25, 89.0) -7 | | | | | | | | | | | | TestPaintingCanvas() constructor: 800.0 x 600.0 -7 | | | | | | | | | | | | paintChild RenderPositionedBox at Point(127.25, 89.0) -7 | | | | | | | | | | | | | TestPaintingCanvas() constructor: 800.0 x 600.0 -7 | | | | | | | | | | | | | paintChild RenderShrinkWrapWidth at Point(127.25, 89.0) -7 | | | | | | | | | | | | | | TestPaintingCanvas() constructor: 800.0 x 600.0 -7 | | | | | | | | | | | | | | paintChild RenderFlex at Point(127.25, 89.0) -7 | | | | | | | | | | | | | | | TestPaintingCanvas() constructor: 800.0 x 600.0 -7 | | | | | | | | | | | | | | | paintChild RenderPadding at Point(127.25, 89.0) -7 | | | | | | | | | | | | | | | | TestPaintingCanvas() constructor: 800.0 x 600.0 -7 | | | | | | | | | | | | | | | | paintChild RenderPadding at Point(127.25, 89.0) -7 | | | | | | | | | | | | | | | | | TestPaintingCanvas() constructor: 800.0 x 600.0 -7 | | | | | | | | | | | | | | | | | paintChild RenderBoxToRenderSectorAdapter at Point(131.25, 93.0) -7 | | | | | | | | | | | | | | | | | | TestPaintingCanvas() constructor: 800.0 x 600.0 -7 | | | | | | | | | | | | | | | | | | paintChild RenderSectorRing at Point(145.25, 107.0) -7 | | | | | | | | | | | | | | | | | | | TestPaintingCanvas() constructor: 800.0 x 600.0 -7 | | | | | | | | | | | | | | | | | | | paintChild RenderSolidColor at Point(145.25, 107.0) -7 | | | | | | | | | | | | | | | | | | | | TestPaintingCanvas() constructor: 800.0 x 600.0 -7 | | | | | | | | | | | | | | | | | | | | drawPath(Instance of 'Path', Paint(color:Color(0xff909090))) -7 | | | | | | | | | | | | | | | | | | | paintChild RenderSolidColor at Point(145.25, 107.0) -7 | | | | | | | | | | | | | | | | | | | | TestPaintingCanvas() constructor: 800.0 x 600.0 -7 | | | | | | | | | | | | | | | | | | | | drawPath(Instance of 'Path', Paint(color:Color(0xff909090))) -7 | | | | | | | | | | | | | | | | | | | paintChild RenderSolidColor at Point(145.25, 107.0) -7 | | | | | | | | | | | | | | | | | | | | TestPaintingCanvas() constructor: 800.0 x 600.0 -7 | | | | | | | | | | | | | | | | | | | | drawPath(Instance of 'Path', Paint(color:Color(0xff00dd00))) -7 | | | | | | | | | | | | | | | paintChild RenderParagraph at Point(173.25, 97.0) -7 | | | | | | | | | | | | | | | | TestPaintingCanvas() constructor: 800.0 x 600.0 -7 | | | | | | | | | | | | | | | | translate(173.25, 97.0) -7 | | | | | | | | | | | | | | | | translate(-173.25, -97.0) -7 | | | | | | paintChild RenderPadding at Point(488.75, 81.0) -7 | | | | | | | TestPaintingCanvas() constructor: 800.0 x 600.0 -7 | | | | | | | paintChild RenderConstrainedBox at Point(496.75, 89.0) -7 | | | | | | | | TestPaintingCanvas() constructor: 800.0 x 600.0 -7 | | | | | | | | paintChild RenderConstrainedBox at Point(496.75, 89.0) -7 | | | | | | | | | TestPaintingCanvas() constructor: 800.0 x 600.0 -7 | | | | | | | | | paintChild RenderDecoratedBox at Point(496.75, 89.0) -7 | | | | | | | | | | TestPaintingCanvas() constructor: 800.0 x 600.0 -7 | | | | | | | | | | drawRRect(Instance of 'RRect', Paint(color:Color(0xffd6d6d6))) -7 | | | | | | | | | | paintChild RenderInkWell at Point(496.75, 89.0) -7 | | | | | | | | | | | TestPaintingCanvas() constructor: 800.0 x 600.0 -7 | | | | | | | | | | | paintChild RenderPadding at Point(496.75, 89.0) -7 | | | | | | | | | | | | TestPaintingCanvas() constructor: 800.0 x 600.0 -7 | | | | | | | | | | | | paintChild RenderPositionedBox at Point(504.75, 89.0) -7 | | | | | | | | | | | | | TestPaintingCanvas() constructor: 800.0 x 600.0 -7 | | | | | | | | | | | | | paintChild RenderShrinkWrapWidth at Point(504.75, 89.0) -7 | | | | | | | | | | | | | | TestPaintingCanvas() constructor: 800.0 x 600.0 -7 | | | | | | | | | | | | | | paintChild RenderFlex at Point(504.75, 89.0) -7 | | | | | | | | | | | | | | | TestPaintingCanvas() constructor: 800.0 x 600.0 -7 | | | | | | | | | | | | | | | paintChild RenderPadding at Point(504.75, 89.0) -7 | | | | | | | | | | | | | | | | TestPaintingCanvas() constructor: 800.0 x 600.0 -7 | | | | | | | | | | | | | | | | paintChild RenderPadding at Point(504.75, 89.0) -7 | | | | | | | | | | | | | | | | | TestPaintingCanvas() constructor: 800.0 x 600.0 -7 | | | | | | | | | | | | | | | | | paintChild RenderBoxToRenderSectorAdapter at Point(508.75, 93.0) -7 | | | | | | | | | | | | | | | | | | TestPaintingCanvas() constructor: 800.0 x 600.0 -7 | | | | | | | | | | | | | | | | | | paintChild RenderSectorRing at Point(522.75, 107.0) -7 | | | | | | | | | | | | | | | | | | | TestPaintingCanvas() constructor: 800.0 x 600.0 -7 | | | | | | | | | | | | | | | | | | | paintChild RenderSolidColor at Point(522.75, 107.0) -7 | | | | | | | | | | | | | | | | | | | | TestPaintingCanvas() constructor: 800.0 x 600.0 -7 | | | | | | | | | | | | | | | | | | | | drawPath(Instance of 'Path', Paint(color:Color(0xff909090))) -7 | | | | | | | | | | | | | | | | | | | paintChild RenderSolidColor at Point(522.75, 107.0) -7 | | | | | | | | | | | | | | | | | | | | TestPaintingCanvas() constructor: 800.0 x 600.0 -7 | | | | | | | | | | | | | | | | | | | | drawPath(Instance of 'Path', Paint(color:Color(0xff909090))) -7 | | | | | | | | | | | | | | | | | | | paintChild RenderSolidColor at Point(522.75, 107.0) -7 | | | | | | | | | | | | | | | | | | | | TestPaintingCanvas() constructor: 800.0 x 600.0 -7 | | | | | | | | | | | | | | | | | | | | drawPath(Instance of 'Path', Paint(color:Color(0xffdd0000))) -7 | | | | | | | | | | | | | | | paintChild RenderParagraph at Point(550.75, 97.0) -7 | | | | | | | | | | | | | | | | TestPaintingCanvas() constructor: 800.0 x 600.0 -7 | | | | | | | | | | | | | | | | translate(550.75, 97.0) -7 | | | | | | | | | | | | | | | | translate(-550.75, -97.0) -7 | | | | paintChild RenderPadding at Point(179.0, 158.0) -7 | | | | | TestPaintingCanvas() constructor: 800.0 x 600.0 -7 | | | | | paintChild RenderDecoratedBox at Point(187.0, 166.0) -7 | | | | | | TestPaintingCanvas() constructor: 800.0 x 600.0 -7 | | | | | | drawPath(Instance of 'Path', Paint(color:Color(0xff000000))) -7 | | | | | | drawPath(Instance of 'Path', Paint(color:Color(0xff000000))) -7 | | | | | | drawPath(Instance of 'Path', Paint(color:Color(0xff000000))) -7 | | | | | | drawPath(Instance of 'Path', Paint(color:Color(0xff000000))) -7 | | | | | | paintChild RenderPadding at Point(187.0, 166.0) -7 | | | | | | | TestPaintingCanvas() constructor: 800.0 x 600.0 -7 | | | | | | | paintChild RenderBoxToRenderSectorAdapter at Point(195.0, 174.0) -7 | | | | | | | | TestPaintingCanvas() constructor: 800.0 x 600.0 -7 | | | | | | | | paintChild RenderSectorRing at Point(400.0, 379.0) -7 | | | | | | | | | TestPaintingCanvas() constructor: 800.0 x 600.0 -7 | | | | | | | | | paintChild RenderSolidColor at Point(400.0, 379.0) -7 | | | | | | | | | | TestPaintingCanvas() constructor: 800.0 x 600.0 -7 | | | | | | | | | | drawPath(Instance of 'Path', Paint(color:Color(0xff85c594))) -7 | | paintChild RenderDecoratedBox at Point(0.0, 0.0) -7 | | | TestPaintingCanvas() constructor: 800.0 x 600.0 -7 | | | drawRect(Rect.fromLTRB(0.0, 0.0, 800.0, 56.0), Paint(color:Color(0xff2196f3), drawLooper:true)) -7 | | | paintChild RenderPadding at Point(0.0, 0.0) -7 | | | | TestPaintingCanvas() constructor: 800.0 x 600.0 -7 | | | | paintChild RenderFlex at Point(8.0, 0.0) -7 | | | | | TestPaintingCanvas() constructor: 800.0 x 600.0 -7 | | | | | paintChild RenderConstrainedBox at Point(8.0, 0.0) -7 | | | | | | TestPaintingCanvas() constructor: 800.0 x 600.0 -7 | | | | | | paintChild RenderFlex at Point(8.0, 0.0) -7 | | | | | | | TestPaintingCanvas() constructor: 800.0 x 600.0 -7 | | | | | | | paintChild RenderPadding at Point(8.0, 14.0) -7 | | | | | | | | TestPaintingCanvas() constructor: 800.0 x 600.0 -7 | | | | | | | | paintChild RenderParagraph at Point(32.0, 14.0) -7 | | | | | | | | | TestPaintingCanvas() constructor: 800.0 x 600.0 -7 | | | | | | | | | translate(32.0, 14.0) -7 | | | | | | | | | translate(-32.0, -14.0) ------------------------------------------------------------------------- - -PAINT FOR FRAME #8 ---------------------------------------------- -8 | TestPaintingCanvas() constructor: 800.0 x 600.0 -8 | paintChild RenderScaffold at Point(0.0, 0.0) -8 | | TestPaintingCanvas() constructor: 800.0 x 600.0 -8 | | paintChild RenderDecoratedBox at Point(0.0, 56.0) -8 | | | TestPaintingCanvas() constructor: 800.0 x 600.0 -8 | | | drawRect(Rect.fromLTRB(0.0, 56.0, 800.0, 600.0), Paint(color:Color(0xfffafafa))) -8 | | | paintChild RenderFlex at Point(0.0, 56.0) -8 | | | | TestPaintingCanvas() constructor: 800.0 x 600.0 -8 | | | | paintChild RenderPadding at Point(0.0, 56.0) -8 | | | | | TestPaintingCanvas() constructor: 800.0 x 600.0 -8 | | | | | paintChild RenderFlex at Point(8.0, 81.0) -8 | | | | | | TestPaintingCanvas() constructor: 800.0 x 600.0 -8 | | | | | | paintChild RenderPadding at Point(111.25, 81.0) -8 | | | | | | | TestPaintingCanvas() constructor: 800.0 x 600.0 -8 | | | | | | | paintChild RenderConstrainedBox at Point(119.25, 89.0) -8 | | | | | | | | TestPaintingCanvas() constructor: 800.0 x 600.0 -8 | | | | | | | | paintChild RenderConstrainedBox at Point(119.25, 89.0) -8 | | | | | | | | | TestPaintingCanvas() constructor: 800.0 x 600.0 -8 | | | | | | | | | paintChild RenderDecoratedBox at Point(119.25, 89.0) -8 | | | | | | | | | | TestPaintingCanvas() constructor: 800.0 x 600.0 -8 | | | | | | | | | | drawRRect(Instance of 'RRect', Paint(color:Color(0xffe0e0e0), drawLooper:true)) -8 | | | | | | | | | | paintChild RenderInkWell at Point(119.25, 89.0) -8 | | | | | | | | | | | TestPaintingCanvas() constructor: 800.0 x 600.0 -8 | | | | | | | | | | | paintChild RenderPadding at Point(119.25, 89.0) -8 | | | | | | | | | | | | TestPaintingCanvas() constructor: 800.0 x 600.0 -8 | | | | | | | | | | | | paintChild RenderPositionedBox at Point(127.25, 89.0) -8 | | | | | | | | | | | | | TestPaintingCanvas() constructor: 800.0 x 600.0 -8 | | | | | | | | | | | | | paintChild RenderShrinkWrapWidth at Point(127.25, 89.0) -8 | | | | | | | | | | | | | | TestPaintingCanvas() constructor: 800.0 x 600.0 -8 | | | | | | | | | | | | | | paintChild RenderFlex at Point(127.25, 89.0) -8 | | | | | | | | | | | | | | | TestPaintingCanvas() constructor: 800.0 x 600.0 -8 | | | | | | | | | | | | | | | paintChild RenderPadding at Point(127.25, 89.0) -8 | | | | | | | | | | | | | | | | TestPaintingCanvas() constructor: 800.0 x 600.0 -8 | | | | | | | | | | | | | | | | paintChild RenderPadding at Point(127.25, 89.0) -8 | | | | | | | | | | | | | | | | | TestPaintingCanvas() constructor: 800.0 x 600.0 -8 | | | | | | | | | | | | | | | | | paintChild RenderBoxToRenderSectorAdapter at Point(131.25, 93.0) -8 | | | | | | | | | | | | | | | | | | TestPaintingCanvas() constructor: 800.0 x 600.0 -8 | | | | | | | | | | | | | | | | | | paintChild RenderSectorRing at Point(145.25, 107.0) -8 | | | | | | | | | | | | | | | | | | | TestPaintingCanvas() constructor: 800.0 x 600.0 -8 | | | | | | | | | | | | | | | | | | | paintChild RenderSolidColor at Point(145.25, 107.0) -8 | | | | | | | | | | | | | | | | | | | | TestPaintingCanvas() constructor: 800.0 x 600.0 -8 | | | | | | | | | | | | | | | | | | | | drawPath(Instance of 'Path', Paint(color:Color(0xff909090))) -8 | | | | | | | | | | | | | | | | | | | paintChild RenderSolidColor at Point(145.25, 107.0) -8 | | | | | | | | | | | | | | | | | | | | TestPaintingCanvas() constructor: 800.0 x 600.0 -8 | | | | | | | | | | | | | | | | | | | | drawPath(Instance of 'Path', Paint(color:Color(0xff909090))) -8 | | | | | | | | | | | | | | | | | | | paintChild RenderSolidColor at Point(145.25, 107.0) -8 | | | | | | | | | | | | | | | | | | | | TestPaintingCanvas() constructor: 800.0 x 600.0 -8 | | | | | | | | | | | | | | | | | | | | drawPath(Instance of 'Path', Paint(color:Color(0xff00dd00))) -8 | | | | | | | | | | | | | | | paintChild RenderParagraph at Point(173.25, 97.0) -8 | | | | | | | | | | | | | | | | TestPaintingCanvas() constructor: 800.0 x 600.0 -8 | | | | | | | | | | | | | | | | translate(173.25, 97.0) -8 | | | | | | | | | | | | | | | | translate(-173.25, -97.0) -8 | | | | | | paintChild RenderPadding at Point(488.75, 81.0) -8 | | | | | | | TestPaintingCanvas() constructor: 800.0 x 600.0 -8 | | | | | | | paintChild RenderConstrainedBox at Point(496.75, 89.0) -8 | | | | | | | | TestPaintingCanvas() constructor: 800.0 x 600.0 -8 | | | | | | | | paintChild RenderConstrainedBox at Point(496.75, 89.0) -8 | | | | | | | | | TestPaintingCanvas() constructor: 800.0 x 600.0 -8 | | | | | | | | | paintChild RenderDecoratedBox at Point(496.75, 89.0) -8 | | | | | | | | | | TestPaintingCanvas() constructor: 800.0 x 600.0 -8 | | | | | | | | | | drawRRect(Instance of 'RRect', Paint(color:Color(0xffd6d6d6))) -8 | | | | | | | | | | paintChild RenderInkWell at Point(496.75, 89.0) -8 | | | | | | | | | | | TestPaintingCanvas() constructor: 800.0 x 600.0 -8 | | | | | | | | | | | paintChild RenderPadding at Point(496.75, 89.0) -8 | | | | | | | | | | | | TestPaintingCanvas() constructor: 800.0 x 600.0 -8 | | | | | | | | | | | | paintChild RenderPositionedBox at Point(504.75, 89.0) -8 | | | | | | | | | | | | | TestPaintingCanvas() constructor: 800.0 x 600.0 -8 | | | | | | | | | | | | | paintChild RenderShrinkWrapWidth at Point(504.75, 89.0) -8 | | | | | | | | | | | | | | TestPaintingCanvas() constructor: 800.0 x 600.0 -8 | | | | | | | | | | | | | | paintChild RenderFlex at Point(504.75, 89.0) -8 | | | | | | | | | | | | | | | TestPaintingCanvas() constructor: 800.0 x 600.0 -8 | | | | | | | | | | | | | | | paintChild RenderPadding at Point(504.75, 89.0) -8 | | | | | | | | | | | | | | | | TestPaintingCanvas() constructor: 800.0 x 600.0 -8 | | | | | | | | | | | | | | | | paintChild RenderPadding at Point(504.75, 89.0) -8 | | | | | | | | | | | | | | | | | TestPaintingCanvas() constructor: 800.0 x 600.0 -8 | | | | | | | | | | | | | | | | | paintChild RenderBoxToRenderSectorAdapter at Point(508.75, 93.0) -8 | | | | | | | | | | | | | | | | | | TestPaintingCanvas() constructor: 800.0 x 600.0 -8 | | | | | | | | | | | | | | | | | | paintChild RenderSectorRing at Point(522.75, 107.0) -8 | | | | | | | | | | | | | | | | | | | TestPaintingCanvas() constructor: 800.0 x 600.0 -8 | | | | | | | | | | | | | | | | | | | paintChild RenderSolidColor at Point(522.75, 107.0) -8 | | | | | | | | | | | | | | | | | | | | TestPaintingCanvas() constructor: 800.0 x 600.0 -8 | | | | | | | | | | | | | | | | | | | | drawPath(Instance of 'Path', Paint(color:Color(0xff909090))) -8 | | | | | | | | | | | | | | | | | | | paintChild RenderSolidColor at Point(522.75, 107.0) -8 | | | | | | | | | | | | | | | | | | | | TestPaintingCanvas() constructor: 800.0 x 600.0 -8 | | | | | | | | | | | | | | | | | | | | drawPath(Instance of 'Path', Paint(color:Color(0xff909090))) -8 | | | | | | | | | | | | | | | | | | | paintChild RenderSolidColor at Point(522.75, 107.0) -8 | | | | | | | | | | | | | | | | | | | | TestPaintingCanvas() constructor: 800.0 x 600.0 -8 | | | | | | | | | | | | | | | | | | | | drawPath(Instance of 'Path', Paint(color:Color(0xffdd0000))) -8 | | | | | | | | | | | | | | | paintChild RenderParagraph at Point(550.75, 97.0) -8 | | | | | | | | | | | | | | | | TestPaintingCanvas() constructor: 800.0 x 600.0 -8 | | | | | | | | | | | | | | | | translate(550.75, 97.0) -8 | | | | | | | | | | | | | | | | translate(-550.75, -97.0) -8 | | | | paintChild RenderPadding at Point(179.0, 158.0) -8 | | | | | TestPaintingCanvas() constructor: 800.0 x 600.0 -8 | | | | | paintChild RenderDecoratedBox at Point(187.0, 166.0) -8 | | | | | | TestPaintingCanvas() constructor: 800.0 x 600.0 -8 | | | | | | drawPath(Instance of 'Path', Paint(color:Color(0xff000000))) -8 | | | | | | drawPath(Instance of 'Path', Paint(color:Color(0xff000000))) -8 | | | | | | drawPath(Instance of 'Path', Paint(color:Color(0xff000000))) -8 | | | | | | drawPath(Instance of 'Path', Paint(color:Color(0xff000000))) -8 | | | | | | paintChild RenderPadding at Point(187.0, 166.0) -8 | | | | | | | TestPaintingCanvas() constructor: 800.0 x 600.0 -8 | | | | | | | paintChild RenderBoxToRenderSectorAdapter at Point(195.0, 174.0) -8 | | | | | | | | TestPaintingCanvas() constructor: 800.0 x 600.0 -8 | | | | | | | | paintChild RenderSectorRing at Point(400.0, 379.0) -8 | | | | | | | | | TestPaintingCanvas() constructor: 800.0 x 600.0 -8 | | | | | | | | | paintChild RenderSolidColor at Point(400.0, 379.0) -8 | | | | | | | | | | TestPaintingCanvas() constructor: 800.0 x 600.0 -8 | | | | | | | | | | drawPath(Instance of 'Path', Paint(color:Color(0xff85c594))) -8 | | | | | | | | | paintChild RenderSolidColor at Point(400.0, 379.0) -8 | | | | | | | | | | TestPaintingCanvas() constructor: 800.0 x 600.0 -8 | | | | | | | | | | drawPath(Instance of 'Path', Paint(color:Color(0xff92ab8e))) -8 | | paintChild RenderDecoratedBox at Point(0.0, 0.0) -8 | | | TestPaintingCanvas() constructor: 800.0 x 600.0 -8 | | | drawRect(Rect.fromLTRB(0.0, 0.0, 800.0, 56.0), Paint(color:Color(0xff2196f3), drawLooper:true)) -8 | | | paintChild RenderPadding at Point(0.0, 0.0) -8 | | | | TestPaintingCanvas() constructor: 800.0 x 600.0 -8 | | | | paintChild RenderFlex at Point(8.0, 0.0) -8 | | | | | TestPaintingCanvas() constructor: 800.0 x 600.0 -8 | | | | | paintChild RenderConstrainedBox at Point(8.0, 0.0) -8 | | | | | | TestPaintingCanvas() constructor: 800.0 x 600.0 -8 | | | | | | paintChild RenderFlex at Point(8.0, 0.0) -8 | | | | | | | TestPaintingCanvas() constructor: 800.0 x 600.0 -8 | | | | | | | paintChild RenderPadding at Point(8.0, 14.0) -8 | | | | | | | | TestPaintingCanvas() constructor: 800.0 x 600.0 -8 | | | | | | | | paintChild RenderParagraph at Point(32.0, 14.0) -8 | | | | | | | | | TestPaintingCanvas() constructor: 800.0 x 600.0 -8 | | | | | | | | | translate(32.0, 14.0) -8 | | | | | | | | | translate(-32.0, -14.0) ------------------------------------------------------------------------- -PAINTED 8 FRAMES diff --git a/engine/src/flutter/tests/examples/sector.dart b/engine/src/flutter/tests/examples/sector.dart deleted file mode 100644 index cd3249412a..0000000000 --- a/engine/src/flutter/tests/examples/sector.dart +++ /dev/null @@ -1,30 +0,0 @@ -// Copyright 2015 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 'dart:async'; - -import 'package:sky/widgets/widget.dart'; - -import '../../sdk/example/widgets/sector.dart'; -import '../resources/display_list.dart'; - -main() async { - TestRenderView testRenderView = new TestRenderView(); - SectorApp app = new SectorApp(); - runApp(app, renderViewOverride: testRenderView); - await testRenderView.checkFrame(); - app.addSector(); - await testRenderView.checkFrame(); - app.addSector(); - await testRenderView.checkFrame(); - app.addSector(); - await testRenderView.checkFrame(); - app.removeSector(); - await testRenderView.checkFrame(); - app.removeSector(); - await testRenderView.checkFrame(); - app.addSector(); - await testRenderView.checkFrame(); - testRenderView.endTest(); -} diff --git a/engine/src/flutter/tests/examples/stocks-expected.txt b/engine/src/flutter/tests/examples/stocks-expected.txt deleted file mode 100644 index 60f8819227..0000000000 --- a/engine/src/flutter/tests/examples/stocks-expected.txt +++ /dev/null @@ -1,220 +0,0 @@ -TestRenderView enabled - -PAINT FOR FRAME #1 ---------------------------------------------- -1 | TestPaintingCanvas() constructor: 800.0 x 600.0 ------------------------------------------------------------------------- - -PAINT FOR FRAME #2 ---------------------------------------------- -2 | TestPaintingCanvas() constructor: 800.0 x 600.0 -2 | paintChild RenderStack at Point(0.0, 0.0) -2 | | TestPaintingCanvas() constructor: 800.0 x 600.0 -2 | | paintChild RenderScaffold at Point(0.0, 0.0) -2 | | | TestPaintingCanvas() constructor: 800.0 x 600.0 -2 | | | paintChild RenderFlex at Point(0.0, 56.0) -2 | | | | TestPaintingCanvas() constructor: 800.0 x 600.0 -2 | | | | paintChild RenderTransform at Point(0.0, 56.0) -2 | | | | | TestPaintingCanvas() constructor: 800.0 x 600.0 -2 | | | | | save -2 | | | | | translate(0.0, 56.0) -2 | | | | | concat([1.0, 0.0, 0.0, 0.0, 0.0, 1.0, 0.0, 0.0, 0.0, 0.0, 1.0, 0.0, 0.0, 0.0, 0.0, 1.0]) -2 | | | | | paintChild RenderTabBar at Point(0.0, 0.0) -2 | | | | | | TestPaintingCanvas() constructor: 800.0 x 600.0 -2 | | | | | | drawRect(Rect.fromLTRB(0.0, 0.0, 800.0, 48.0), Paint(color:Color(0xff9c27b0))) -2 | | | | | | paintChild RenderInkWell at Point(0.0, 0.0) -2 | | | | | | | TestPaintingCanvas() constructor: 800.0 x 600.0 -2 | | | | | | | paintChild RenderConstrainedBox at Point(0.0, 0.0) -2 | | | | | | | | TestPaintingCanvas() constructor: 800.0 x 600.0 -2 | | | | | | | | paintChild RenderPadding at Point(0.0, 0.0) -2 | | | | | | | | | TestPaintingCanvas() constructor: 800.0 x 600.0 -2 | | | | | | | | | paintChild RenderPositionedBox at Point(12.0, 0.0) -2 | | | | | | | | | | TestPaintingCanvas() constructor: 800.0 x 600.0 -2 | | | | | | | | | | paintChild RenderOpacity at Point(171.0, 14.0) -2 | | | | | | | | | | | TestPaintingCanvas() constructor: 800.0 x 600.0 -2 | | | | | | | | | | | paintChild RenderParagraph at Point(171.0, 14.0) -2 | | | | | | | | | | | | TestPaintingCanvas() constructor: 800.0 x 600.0 -2 | | | | | | | | | | | | translate(171.0, 14.0) -2 | | | | | | | | | | | | translate(-171.0, -14.0) -2 | | | | | | drawRect(Rect.fromLTRB(0.0, 46.0, 400.0, 48.0), Paint(color:Color(0xffffffff))) -2 | | | | | | paintChild RenderInkWell at Point(400.0, 0.0) -2 | | | | | | | TestPaintingCanvas() constructor: 800.0 x 600.0 -2 | | | | | | | paintChild RenderConstrainedBox at Point(400.0, 0.0) -2 | | | | | | | | TestPaintingCanvas() constructor: 800.0 x 600.0 -2 | | | | | | | | paintChild RenderPadding at Point(400.0, 0.0) -2 | | | | | | | | | TestPaintingCanvas() constructor: 800.0 x 600.0 -2 | | | | | | | | | paintChild RenderPositionedBox at Point(412.0, 0.0) -2 | | | | | | | | | | TestPaintingCanvas() constructor: 800.0 x 600.0 -2 | | | | | | | | | | paintChild RenderOpacity at Point(560.0, 14.0) -2 | | | | | | | | | | | TestPaintingCanvas() constructor: 800.0 x 600.0 -2 | | | | | | | | | | | saveLayer(null, Paint(color:Color(0xb3000000))) -2 | | | | | | | | | | | paintChild RenderParagraph at Point(560.0, 14.0) -2 | | | | | | | | | | | | TestPaintingCanvas() constructor: 800.0 x 600.0 -2 | | | | | | | | | | | | translate(560.0, 14.0) -2 | | | | | | | | | | | | translate(-560.0, -14.0) -2 | | | | | | | | | | | restore -2 | | | | | restore -2 | | | | paintChild RenderDecoratedBox at Point(0.0, 104.0) -2 | | | | | TestPaintingCanvas() constructor: 800.0 x 600.0 -2 | | | | | drawRect(Rect.fromLTRB(0.0, 104.0, 800.0, 600.0), Paint(color:Color(0xfffafafa))) -2 | | | | | paintChild RenderSizeObserver at Point(0.0, 104.0) -2 | | | | | | TestPaintingCanvas() constructor: 800.0 x 600.0 -2 | | | | | | paintChild RenderViewport at Point(0.0, 104.0) -2 | | | | | | | TestPaintingCanvas() constructor: 800.0 x 600.0 -2 | | | | | | | save -2 | | | | | | | clipRect(Rect.fromLTRB(0.0, 104.0, 800.0, 600.0)) -2 | | | | | | | paintChild RenderBlock at Point(0.0, 104.0) -2 | | | | | | | | TestPaintingCanvas() constructor: 800.0 x 600.0 -2 | | | | | | | restore -2 | | | paintChild RenderDecoratedBox at Point(0.0, 0.0) -2 | | | | TestPaintingCanvas() constructor: 800.0 x 600.0 -2 | | | | drawRect(Rect.fromLTRB(0.0, 0.0, 800.0, 56.0), Paint(color:Color(0xff9c27b0), drawLooper:true)) -2 | | | | paintChild RenderPadding at Point(0.0, 0.0) -2 | | | | | TestPaintingCanvas() constructor: 800.0 x 600.0 -2 | | | | | paintChild RenderFlex at Point(8.0, 0.0) -2 | | | | | | TestPaintingCanvas() constructor: 800.0 x 600.0 -2 | | | | | | paintChild RenderConstrainedBox at Point(8.0, 0.0) -2 | | | | | | | TestPaintingCanvas() constructor: 800.0 x 600.0 -2 | | | | | | | paintChild RenderFlex at Point(8.0, 0.0) -2 | | | | | | | | TestPaintingCanvas() constructor: 800.0 x 600.0 -2 | | | | | | | | paintChild RenderPadding at Point(8.0, 8.0) -2 | | | | | | | | | TestPaintingCanvas() constructor: 800.0 x 600.0 -2 | | | | | | | | | paintChild RenderImage at Point(16.0, 16.0) -2 | | | | | | | | | | TestPaintingCanvas() constructor: 800.0 x 600.0 -2 | | | | | | | | paintChild RenderPadding at Point(48.0, 14.0) -2 | | | | | | | | | TestPaintingCanvas() constructor: 800.0 x 600.0 -2 | | | | | | | | | paintChild RenderParagraph at Point(72.0, 14.0) -2 | | | | | | | | | | TestPaintingCanvas() constructor: 800.0 x 600.0 -2 | | | | | | | | | | translate(72.0, 14.0) -2 | | | | | | | | | | translate(-72.0, -14.0) -2 | | | | | | | | paintChild RenderPadding at Point(712.0, 8.0) -2 | | | | | | | | | TestPaintingCanvas() constructor: 800.0 x 600.0 -2 | | | | | | | | | paintChild RenderImage at Point(720.0, 16.0) -2 | | | | | | | | | | TestPaintingCanvas() constructor: 800.0 x 600.0 -2 | | | | | | | | paintChild RenderPadding at Point(752.0, 8.0) -2 | | | | | | | | | TestPaintingCanvas() constructor: 800.0 x 600.0 -2 | | | | | | | | | paintChild RenderImage at Point(760.0, 16.0) -2 | | | | | | | | | | TestPaintingCanvas() constructor: 800.0 x 600.0 -2 | | | paintChild RenderDecoratedBox at Point(728.0, 528.0) -2 | | | | TestPaintingCanvas() constructor: 800.0 x 600.0 -2 | | | | drawCircle(Point(756.0, 556.0), 28.0, Paint(color:Color(0xffff5252), drawLooper:true)) -2 | | | | paintChild RenderClipOval at Point(728.0, 528.0) -2 | | | | | TestPaintingCanvas() constructor: 800.0 x 600.0 -2 | | | | | saveLayer(Rect.fromLTRB(728.0, 528.0, 784.0, 584.0), Paint(color:Color(0xff000000))) -2 | | | | | clipPath(Instance of 'Path') -2 | | | | | paintChild RenderConstrainedBox at Point(728.0, 528.0) -2 | | | | | | TestPaintingCanvas() constructor: 800.0 x 600.0 -2 | | | | | | paintChild RenderInkWell at Point(728.0, 528.0) -2 | | | | | | | TestPaintingCanvas() constructor: 800.0 x 600.0 -2 | | | | | | | paintChild RenderPositionedBox at Point(728.0, 528.0) -2 | | | | | | | | TestPaintingCanvas() constructor: 800.0 x 600.0 -2 | | | | | | | | paintChild RenderImage at Point(744.0, 544.0) -2 | | | | | | | | | TestPaintingCanvas() constructor: 800.0 x 600.0 -2 | | | | | restore ------------------------------------------------------------------------- - -PAINT FOR FRAME #3 ---------------------------------------------- -3 | TestPaintingCanvas() constructor: 800.0 x 600.0 -3 | paintChild RenderStack at Point(0.0, 0.0) -3 | | TestPaintingCanvas() constructor: 800.0 x 600.0 -3 | | paintChild RenderScaffold at Point(0.0, 0.0) -3 | | | TestPaintingCanvas() constructor: 800.0 x 600.0 -3 | | | paintChild RenderFlex at Point(0.0, 56.0) -3 | | | | TestPaintingCanvas() constructor: 800.0 x 600.0 -3 | | | | paintChild RenderTransform at Point(0.0, 56.0) -3 | | | | | TestPaintingCanvas() constructor: 800.0 x 600.0 -3 | | | | | save -3 | | | | | translate(0.0, 56.0) -3 | | | | | concat([1.0, 0.0, 0.0, 0.0, 0.0, 1.0, 0.0, 0.0, 0.0, 0.0, 1.0, 0.0, 0.0, 0.0, 0.0, 1.0]) -3 | | | | | paintChild RenderTabBar at Point(0.0, 0.0) -3 | | | | | | TestPaintingCanvas() constructor: 800.0 x 600.0 -3 | | | | | | drawRect(Rect.fromLTRB(0.0, 0.0, 800.0, 48.0), Paint(color:Color(0xff9c27b0))) -3 | | | | | | paintChild RenderInkWell at Point(0.0, 0.0) -3 | | | | | | | TestPaintingCanvas() constructor: 800.0 x 600.0 -3 | | | | | | | paintChild RenderConstrainedBox at Point(0.0, 0.0) -3 | | | | | | | | TestPaintingCanvas() constructor: 800.0 x 600.0 -3 | | | | | | | | paintChild RenderPadding at Point(0.0, 0.0) -3 | | | | | | | | | TestPaintingCanvas() constructor: 800.0 x 600.0 -3 | | | | | | | | | paintChild RenderPositionedBox at Point(12.0, 0.0) -3 | | | | | | | | | | TestPaintingCanvas() constructor: 800.0 x 600.0 -3 | | | | | | | | | | paintChild RenderOpacity at Point(171.0, 14.0) -3 | | | | | | | | | | | TestPaintingCanvas() constructor: 800.0 x 600.0 -3 | | | | | | | | | | | paintChild RenderParagraph at Point(171.0, 14.0) -3 | | | | | | | | | | | | TestPaintingCanvas() constructor: 800.0 x 600.0 -3 | | | | | | | | | | | | translate(171.0, 14.0) -3 | | | | | | | | | | | | translate(-171.0, -14.0) -3 | | | | | | drawRect(Rect.fromLTRB(0.0, 46.0, 400.0, 48.0), Paint(color:Color(0xffffffff))) -3 | | | | | | paintChild RenderInkWell at Point(400.0, 0.0) -3 | | | | | | | TestPaintingCanvas() constructor: 800.0 x 600.0 -3 | | | | | | | paintChild RenderConstrainedBox at Point(400.0, 0.0) -3 | | | | | | | | TestPaintingCanvas() constructor: 800.0 x 600.0 -3 | | | | | | | | paintChild RenderPadding at Point(400.0, 0.0) -3 | | | | | | | | | TestPaintingCanvas() constructor: 800.0 x 600.0 -3 | | | | | | | | | paintChild RenderPositionedBox at Point(412.0, 0.0) -3 | | | | | | | | | | TestPaintingCanvas() constructor: 800.0 x 600.0 -3 | | | | | | | | | | paintChild RenderOpacity at Point(560.0, 14.0) -3 | | | | | | | | | | | TestPaintingCanvas() constructor: 800.0 x 600.0 -3 | | | | | | | | | | | saveLayer(null, Paint(color:Color(0xb3000000))) -3 | | | | | | | | | | | paintChild RenderParagraph at Point(560.0, 14.0) -3 | | | | | | | | | | | | TestPaintingCanvas() constructor: 800.0 x 600.0 -3 | | | | | | | | | | | | translate(560.0, 14.0) -3 | | | | | | | | | | | | translate(-560.0, -14.0) -3 | | | | | | | | | | | restore -3 | | | | | restore -3 | | | | paintChild RenderDecoratedBox at Point(0.0, 104.0) -3 | | | | | TestPaintingCanvas() constructor: 800.0 x 600.0 -3 | | | | | drawRect(Rect.fromLTRB(0.0, 104.0, 800.0, 600.0), Paint(color:Color(0xfffafafa))) -3 | | | | | paintChild RenderSizeObserver at Point(0.0, 104.0) -3 | | | | | | TestPaintingCanvas() constructor: 800.0 x 600.0 -3 | | | | | | paintChild RenderViewport at Point(0.0, 104.0) -3 | | | | | | | TestPaintingCanvas() constructor: 800.0 x 600.0 -3 | | | | | | | save -3 | | | | | | | clipRect(Rect.fromLTRB(0.0, 104.0, 800.0, 600.0)) -3 | | | | | | | paintChild RenderBlock at Point(0.0, 104.0) -3 | | | | | | | | TestPaintingCanvas() constructor: 800.0 x 600.0 -3 | | | | | | | restore -3 | | | paintChild RenderDecoratedBox at Point(0.0, 0.0) -3 | | | | TestPaintingCanvas() constructor: 800.0 x 600.0 -3 | | | | drawRect(Rect.fromLTRB(0.0, 0.0, 800.0, 56.0), Paint(color:Color(0xff9c27b0), drawLooper:true)) -3 | | | | paintChild RenderPadding at Point(0.0, 0.0) -3 | | | | | TestPaintingCanvas() constructor: 800.0 x 600.0 -3 | | | | | paintChild RenderFlex at Point(8.0, 0.0) -3 | | | | | | TestPaintingCanvas() constructor: 800.0 x 600.0 -3 | | | | | | paintChild RenderConstrainedBox at Point(8.0, 0.0) -3 | | | | | | | TestPaintingCanvas() constructor: 800.0 x 600.0 -3 | | | | | | | paintChild RenderFlex at Point(8.0, 0.0) -3 | | | | | | | | TestPaintingCanvas() constructor: 800.0 x 600.0 -3 | | | | | | | | paintChild RenderPadding at Point(8.0, 8.0) -3 | | | | | | | | | TestPaintingCanvas() constructor: 800.0 x 600.0 -3 | | | | | | | | | paintChild RenderImage at Point(16.0, 16.0) -3 | | | | | | | | | | TestPaintingCanvas() constructor: 800.0 x 600.0 -3 | | | | | | | | paintChild RenderPadding at Point(48.0, 14.0) -3 | | | | | | | | | TestPaintingCanvas() constructor: 800.0 x 600.0 -3 | | | | | | | | | paintChild RenderParagraph at Point(72.0, 14.0) -3 | | | | | | | | | | TestPaintingCanvas() constructor: 800.0 x 600.0 -3 | | | | | | | | | | translate(72.0, 14.0) -3 | | | | | | | | | | translate(-72.0, -14.0) -3 | | | | | | | | paintChild RenderPadding at Point(712.0, 8.0) -3 | | | | | | | | | TestPaintingCanvas() constructor: 800.0 x 600.0 -3 | | | | | | | | | paintChild RenderImage at Point(720.0, 16.0) -3 | | | | | | | | | | TestPaintingCanvas() constructor: 800.0 x 600.0 -3 | | | | | | | | paintChild RenderPadding at Point(752.0, 8.0) -3 | | | | | | | | | TestPaintingCanvas() constructor: 800.0 x 600.0 -3 | | | | | | | | | paintChild RenderImage at Point(760.0, 16.0) -3 | | | | | | | | | | TestPaintingCanvas() constructor: 800.0 x 600.0 -3 | | | paintChild RenderDecoratedBox at Point(728.0, 528.0) -3 | | | | TestPaintingCanvas() constructor: 800.0 x 600.0 -3 | | | | drawCircle(Point(756.0, 556.0), 28.0, Paint(color:Color(0xffff5252), drawLooper:true)) -3 | | | | paintChild RenderClipOval at Point(728.0, 528.0) -3 | | | | | TestPaintingCanvas() constructor: 800.0 x 600.0 -3 | | | | | saveLayer(Rect.fromLTRB(728.0, 528.0, 784.0, 584.0), Paint(color:Color(0xff000000))) -3 | | | | | clipPath(Instance of 'Path') -3 | | | | | paintChild RenderConstrainedBox at Point(728.0, 528.0) -3 | | | | | | TestPaintingCanvas() constructor: 800.0 x 600.0 -3 | | | | | | paintChild RenderInkWell at Point(728.0, 528.0) -3 | | | | | | | TestPaintingCanvas() constructor: 800.0 x 600.0 -3 | | | | | | | paintChild RenderPositionedBox at Point(728.0, 528.0) -3 | | | | | | | | TestPaintingCanvas() constructor: 800.0 x 600.0 -3 | | | | | | | | paintChild RenderImage at Point(744.0, 544.0) -3 | | | | | | | | | TestPaintingCanvas() constructor: 800.0 x 600.0 -3 | | | | | restore ------------------------------------------------------------------------- -PAINTED 3 FRAMES diff --git a/engine/src/flutter/tests/examples/stocks.dart b/engine/src/flutter/tests/examples/stocks.dart deleted file mode 100644 index 4db95d2f00..0000000000 --- a/engine/src/flutter/tests/examples/stocks.dart +++ /dev/null @@ -1,31 +0,0 @@ -// Copyright 2015 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 'dart:async'; - -import 'package:sky/widgets/widget.dart'; - -import '../../sdk/example/stocks/lib/main.dart'; -import '../resources/display_list.dart'; - -class TestStocksApp extends StocksApp { - - Completer _completer = new Completer(); - Future get isMounted => _completer.future; - - void didMount() { - super.didMount(); - _completer.complete(); - } -} - -main() async { - TestRenderView testRenderView = new TestRenderView(); - TestStocksApp app = new TestStocksApp(); - runApp(app, renderViewOverride: testRenderView); - await testRenderView.checkFrame(); - await app.isMounted; - await testRenderView.checkFrame(); - testRenderView.endTest(); -} diff --git a/engine/src/flutter/tests/examples/styled_text-expected.txt b/engine/src/flutter/tests/examples/styled_text-expected.txt deleted file mode 100644 index 7e0051405e..0000000000 --- a/engine/src/flutter/tests/examples/styled_text-expected.txt +++ /dev/null @@ -1,152 +0,0 @@ -TestRenderView enabled - -PAINT FOR FRAME #1 ---------------------------------------------- -1 | TestPaintingCanvas() constructor: 800.0 x 600.0 ------------------------------------------------------------------------- - -PAINT FOR FRAME #2 ---------------------------------------------- -2 | TestPaintingCanvas() constructor: 800.0 x 600.0 -2 | paintChild RenderScaffold at Point(0.0, 0.0) -2 | | TestPaintingCanvas() constructor: 800.0 x 600.0 -2 | | paintChild RenderDecoratedBox at Point(0.0, 56.0) -2 | | | TestPaintingCanvas() constructor: 800.0 x 600.0 -2 | | | drawRRect(Instance of 'RRect', Paint(color:Color(0xfffafafa))) -2 | | | paintChild RenderPadding at Point(0.0, 56.0) -2 | | | | TestPaintingCanvas() constructor: 800.0 x 600.0 -2 | | | | paintChild RenderFlex at Point(8.0, 56.0) -2 | | | | | TestPaintingCanvas() constructor: 800.0 x 600.0 -2 | | | | | paintChild RenderParagraph at Point(8.0, 163.5) -2 | | | | | | TestPaintingCanvas() constructor: 800.0 x 600.0 -2 | | | | | | translate(8.0, 163.5) -2 | | | | | | translate(-8.0, -163.5) -2 | | | | | paintChild RenderPadding at Point(8.0, 213.5) -2 | | | | | | TestPaintingCanvas() constructor: 800.0 x 600.0 -2 | | | | | | paintChild RenderConstrainedBox at Point(72.0, 223.5) -2 | | | | | | | TestPaintingCanvas() constructor: 800.0 x 600.0 -2 | | | | | | | paintChild RenderDecoratedBox at Point(72.0, 223.5) -2 | | | | | | | | TestPaintingCanvas() constructor: 800.0 x 600.0 -2 | | | | | | | | drawPath(Instance of 'Path', Paint(color:Color(0xff000000))) -2 | | | | | | | | drawPath(Instance of 'Path', Paint(color:Color(0xff000000))) -2 | | | | | | | | drawPath(Instance of 'Path', Paint(color:Color(0x18000000))) -2 | | | | | | | | drawPath(Instance of 'Path', Paint(color:Color(0xff000000))) -2 | | | | | | | | paintChild RenderConstrainedBox at Point(72.0, 223.5) -2 | | | | | | | | | TestPaintingCanvas() constructor: 800.0 x 600.0 -2 | | | | | paintChild RenderParagraph at Point(8.0, 233.5) -2 | | | | | | TestPaintingCanvas() constructor: 800.0 x 600.0 -2 | | | | | | translate(8.0, 233.5) -2 | | | | | | translate(-8.0, -233.5) -2 | | | | | paintChild RenderPadding at Point(8.0, 249.5) -2 | | | | | | TestPaintingCanvas() constructor: 800.0 x 600.0 -2 | | | | | | paintChild RenderConstrainedBox at Point(72.0, 259.5) -2 | | | | | | | TestPaintingCanvas() constructor: 800.0 x 600.0 -2 | | | | | | | paintChild RenderDecoratedBox at Point(72.0, 259.5) -2 | | | | | | | | TestPaintingCanvas() constructor: 800.0 x 600.0 -2 | | | | | | | | drawPath(Instance of 'Path', Paint(color:Color(0xff000000))) -2 | | | | | | | | drawPath(Instance of 'Path', Paint(color:Color(0xff000000))) -2 | | | | | | | | drawPath(Instance of 'Path', Paint(color:Color(0x18000000))) -2 | | | | | | | | drawPath(Instance of 'Path', Paint(color:Color(0xff000000))) -2 | | | | | | | | paintChild RenderConstrainedBox at Point(72.0, 259.5) -2 | | | | | | | | | TestPaintingCanvas() constructor: 800.0 x 600.0 -2 | | | | | paintChild RenderParagraph at Point(8.0, 269.5) -2 | | | | | | TestPaintingCanvas() constructor: 800.0 x 600.0 -2 | | | | | | translate(8.0, 269.5) -2 | | | | | | translate(-8.0, -269.5) -2 | | | | | paintChild RenderPadding at Point(8.0, 294.5) -2 | | | | | | TestPaintingCanvas() constructor: 800.0 x 600.0 -2 | | | | | | paintChild RenderConstrainedBox at Point(72.0, 304.5) -2 | | | | | | | TestPaintingCanvas() constructor: 800.0 x 600.0 -2 | | | | | | | paintChild RenderDecoratedBox at Point(72.0, 304.5) -2 | | | | | | | | TestPaintingCanvas() constructor: 800.0 x 600.0 -2 | | | | | | | | drawPath(Instance of 'Path', Paint(color:Color(0xff000000))) -2 | | | | | | | | drawPath(Instance of 'Path', Paint(color:Color(0xff000000))) -2 | | | | | | | | drawPath(Instance of 'Path', Paint(color:Color(0x18000000))) -2 | | | | | | | | drawPath(Instance of 'Path', Paint(color:Color(0xff000000))) -2 | | | | | | | | paintChild RenderConstrainedBox at Point(72.0, 304.5) -2 | | | | | | | | | TestPaintingCanvas() constructor: 800.0 x 600.0 -2 | | | | | paintChild RenderParagraph at Point(8.0, 314.5) -2 | | | | | | TestPaintingCanvas() constructor: 800.0 x 600.0 -2 | | | | | | translate(8.0, 314.5) -2 | | | | | | translate(-8.0, -314.5) -2 | | | | | paintChild RenderPadding at Point(8.0, 330.5) -2 | | | | | | TestPaintingCanvas() constructor: 800.0 x 600.0 -2 | | | | | | paintChild RenderConstrainedBox at Point(72.0, 340.5) -2 | | | | | | | TestPaintingCanvas() constructor: 800.0 x 600.0 -2 | | | | | | | paintChild RenderDecoratedBox at Point(72.0, 340.5) -2 | | | | | | | | TestPaintingCanvas() constructor: 800.0 x 600.0 -2 | | | | | | | | drawPath(Instance of 'Path', Paint(color:Color(0xff000000))) -2 | | | | | | | | drawPath(Instance of 'Path', Paint(color:Color(0xff000000))) -2 | | | | | | | | drawPath(Instance of 'Path', Paint(color:Color(0x18000000))) -2 | | | | | | | | drawPath(Instance of 'Path', Paint(color:Color(0xff000000))) -2 | | | | | | | | paintChild RenderConstrainedBox at Point(72.0, 340.5) -2 | | | | | | | | | TestPaintingCanvas() constructor: 800.0 x 600.0 -2 | | | | | paintChild RenderParagraph at Point(8.0, 350.5) -2 | | | | | | TestPaintingCanvas() constructor: 800.0 x 600.0 -2 | | | | | | translate(8.0, 350.5) -2 | | | | | | translate(-8.0, -350.5) -2 | | | | | paintChild RenderPadding at Point(8.0, 375.5) -2 | | | | | | TestPaintingCanvas() constructor: 800.0 x 600.0 -2 | | | | | | paintChild RenderConstrainedBox at Point(72.0, 385.5) -2 | | | | | | | TestPaintingCanvas() constructor: 800.0 x 600.0 -2 | | | | | | | paintChild RenderDecoratedBox at Point(72.0, 385.5) -2 | | | | | | | | TestPaintingCanvas() constructor: 800.0 x 600.0 -2 | | | | | | | | drawPath(Instance of 'Path', Paint(color:Color(0xff000000))) -2 | | | | | | | | drawPath(Instance of 'Path', Paint(color:Color(0xff000000))) -2 | | | | | | | | drawPath(Instance of 'Path', Paint(color:Color(0x18000000))) -2 | | | | | | | | drawPath(Instance of 'Path', Paint(color:Color(0xff000000))) -2 | | | | | | | | paintChild RenderConstrainedBox at Point(72.0, 385.5) -2 | | | | | | | | | TestPaintingCanvas() constructor: 800.0 x 600.0 -2 | | | | | paintChild RenderParagraph at Point(8.0, 395.5) -2 | | | | | | TestPaintingCanvas() constructor: 800.0 x 600.0 -2 | | | | | | translate(8.0, 395.5) -2 | | | | | | translate(-8.0, -395.5) -2 | | | | | paintChild RenderPadding at Point(8.0, 411.5) -2 | | | | | | TestPaintingCanvas() constructor: 800.0 x 600.0 -2 | | | | | | paintChild RenderConstrainedBox at Point(72.0, 421.5) -2 | | | | | | | TestPaintingCanvas() constructor: 800.0 x 600.0 -2 | | | | | | | paintChild RenderDecoratedBox at Point(72.0, 421.5) -2 | | | | | | | | TestPaintingCanvas() constructor: 800.0 x 600.0 -2 | | | | | | | | drawPath(Instance of 'Path', Paint(color:Color(0xff000000))) -2 | | | | | | | | drawPath(Instance of 'Path', Paint(color:Color(0xff000000))) -2 | | | | | | | | drawPath(Instance of 'Path', Paint(color:Color(0x18000000))) -2 | | | | | | | | drawPath(Instance of 'Path', Paint(color:Color(0xff000000))) -2 | | | | | | | | paintChild RenderConstrainedBox at Point(72.0, 421.5) -2 | | | | | | | | | TestPaintingCanvas() constructor: 800.0 x 600.0 -2 | | | | | paintChild RenderParagraph at Point(8.0, 431.5) -2 | | | | | | TestPaintingCanvas() constructor: 800.0 x 600.0 -2 | | | | | | translate(8.0, 431.5) -2 | | | | | | translate(-8.0, -431.5) -2 | | | | | paintChild RenderPadding at Point(8.0, 456.5) -2 | | | | | | TestPaintingCanvas() constructor: 800.0 x 600.0 -2 | | | | | | paintChild RenderConstrainedBox at Point(72.0, 466.5) -2 | | | | | | | TestPaintingCanvas() constructor: 800.0 x 600.0 -2 | | | | | | | paintChild RenderDecoratedBox at Point(72.0, 466.5) -2 | | | | | | | | TestPaintingCanvas() constructor: 800.0 x 600.0 -2 | | | | | | | | drawPath(Instance of 'Path', Paint(color:Color(0xff000000))) -2 | | | | | | | | drawPath(Instance of 'Path', Paint(color:Color(0xff000000))) -2 | | | | | | | | drawPath(Instance of 'Path', Paint(color:Color(0x18000000))) -2 | | | | | | | | drawPath(Instance of 'Path', Paint(color:Color(0xff000000))) -2 | | | | | | | | paintChild RenderConstrainedBox at Point(72.0, 466.5) -2 | | | | | | | | | TestPaintingCanvas() constructor: 800.0 x 600.0 -2 | | | | | paintChild RenderParagraph at Point(8.0, 476.5) -2 | | | | | | TestPaintingCanvas() constructor: 800.0 x 600.0 -2 | | | | | | translate(8.0, 476.5) -2 | | | | | | translate(-8.0, -476.5) -2 | | paintChild RenderDecoratedBox at Point(0.0, 0.0) -2 | | | TestPaintingCanvas() constructor: 800.0 x 600.0 -2 | | | drawRect(Rect.fromLTRB(0.0, 0.0, 800.0, 56.0), Paint(color:Color(0xff2196f3), drawLooper:true)) -2 | | | paintChild RenderPadding at Point(0.0, 0.0) -2 | | | | TestPaintingCanvas() constructor: 800.0 x 600.0 -2 | | | | paintChild RenderFlex at Point(8.0, 0.0) -2 | | | | | TestPaintingCanvas() constructor: 800.0 x 600.0 -2 | | | | | paintChild RenderConstrainedBox at Point(8.0, 0.0) -2 | | | | | | TestPaintingCanvas() constructor: 800.0 x 600.0 -2 | | | | | | paintChild RenderFlex at Point(8.0, 0.0) -2 | | | | | | | TestPaintingCanvas() constructor: 800.0 x 600.0 -2 | | | | | | | paintChild RenderPadding at Point(8.0, 14.0) -2 | | | | | | | | TestPaintingCanvas() constructor: 800.0 x 600.0 -2 | | | | | | | | paintChild RenderParagraph at Point(32.0, 14.0) -2 | | | | | | | | | TestPaintingCanvas() constructor: 800.0 x 600.0 -2 | | | | | | | | | translate(32.0, 14.0) -2 | | | | | | | | | translate(-32.0, -14.0) ------------------------------------------------------------------------- -PAINTED 2 FRAMES diff --git a/engine/src/flutter/tests/examples/styled_text.dart b/engine/src/flutter/tests/examples/styled_text.dart deleted file mode 100644 index 5caa936d61..0000000000 --- a/engine/src/flutter/tests/examples/styled_text.dart +++ /dev/null @@ -1,18 +0,0 @@ -// Copyright 2015 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 'dart:async'; - -import 'package:sky/widgets/widget.dart'; - -import '../../sdk/example/widgets/styled_text.dart'; -import '../resources/display_list.dart'; - -main() async { - TestRenderView testRenderView = new TestRenderView(); - StyledTextApp app = new StyledTextApp(); - runApp(app, renderViewOverride: testRenderView); - await testRenderView.checkFrame(); - testRenderView.endTest(); -} diff --git a/engine/src/flutter/tests/examples/tabs-expected.txt b/engine/src/flutter/tests/examples/tabs-expected.txt deleted file mode 100644 index 7f272d10c7..0000000000 --- a/engine/src/flutter/tests/examples/tabs-expected.txt +++ /dev/null @@ -1,200 +0,0 @@ -TestRenderView enabled - -PAINT FOR FRAME #1 ---------------------------------------------- -1 | TestPaintingCanvas() constructor: 800.0 x 600.0 ------------------------------------------------------------------------- - -PAINT FOR FRAME #2 ---------------------------------------------- -2 | TestPaintingCanvas() constructor: 800.0 x 600.0 -2 | paintChild RenderScaffold at Point(0.0, 0.0) -2 | | TestPaintingCanvas() constructor: 800.0 x 600.0 -2 | | paintChild RenderFlex at Point(0.0, 56.0) -2 | | | TestPaintingCanvas() constructor: 800.0 x 600.0 -2 | | | paintChild RenderTransform at Point(0.0, 56.0) -2 | | | | TestPaintingCanvas() constructor: 800.0 x 600.0 -2 | | | | save -2 | | | | translate(0.0, 56.0) -2 | | | | concat([1.0, 0.0, 0.0, 0.0, 0.0, 1.0, 0.0, 0.0, 0.0, 0.0, 1.0, 0.0, 0.0, 0.0, 0.0, 1.0]) -2 | | | | paintChild RenderTabBar at Point(0.0, 0.0) -2 | | | | | TestPaintingCanvas() constructor: 800.0 x 600.0 -2 | | | | | drawRect(Rect.fromLTRB(0.0, 0.0, 800.0, 48.0), Paint(color:Color(0xff2196f3))) -2 | | | | | paintChild RenderInkWell at Point(0.0, 0.0) -2 | | | | | | TestPaintingCanvas() constructor: 800.0 x 600.0 -2 | | | | | | paintChild RenderConstrainedBox at Point(0.0, 0.0) -2 | | | | | | | TestPaintingCanvas() constructor: 800.0 x 600.0 -2 | | | | | | | paintChild RenderPadding at Point(0.0, 0.0) -2 | | | | | | | | TestPaintingCanvas() constructor: 800.0 x 600.0 -2 | | | | | | | | paintChild RenderPositionedBox at Point(12.0, 0.0) -2 | | | | | | | | | TestPaintingCanvas() constructor: 800.0 x 600.0 -2 | | | | | | | | | paintChild RenderOpacity at Point(82.0, 14.0) -2 | | | | | | | | | | TestPaintingCanvas() constructor: 800.0 x 600.0 -2 | | | | | | | | | | paintChild RenderParagraph at Point(82.0, 14.0) -2 | | | | | | | | | | | TestPaintingCanvas() constructor: 800.0 x 600.0 -2 | | | | | | | | | | | translate(82.0, 14.0) -2 | | | | | | | | | | | translate(-82.0, -14.0) -2 | | | | | drawRect(Rect.fromLTRB(0.0, 46.0, 200.0, 48.0), Paint(color:Color(0xffffffff))) -2 | | | | | paintChild RenderInkWell at Point(200.0, 0.0) -2 | | | | | | TestPaintingCanvas() constructor: 800.0 x 600.0 -2 | | | | | | paintChild RenderConstrainedBox at Point(200.0, 0.0) -2 | | | | | | | TestPaintingCanvas() constructor: 800.0 x 600.0 -2 | | | | | | | paintChild RenderPadding at Point(200.0, 0.0) -2 | | | | | | | | TestPaintingCanvas() constructor: 800.0 x 600.0 -2 | | | | | | | | paintChild RenderPositionedBox at Point(212.0, 0.0) -2 | | | | | | | | | TestPaintingCanvas() constructor: 800.0 x 600.0 -2 | | | | | | | | | paintChild RenderOpacity at Point(277.5, 14.0) -2 | | | | | | | | | | TestPaintingCanvas() constructor: 800.0 x 600.0 -2 | | | | | | | | | | saveLayer(null, Paint(color:Color(0xb3000000))) -2 | | | | | | | | | | paintChild RenderParagraph at Point(277.5, 14.0) -2 | | | | | | | | | | | TestPaintingCanvas() constructor: 800.0 x 600.0 -2 | | | | | | | | | | | translate(277.5, 14.0) -2 | | | | | | | | | | | translate(-277.5, -14.0) -2 | | | | | | | | | | restore -2 | | | | | paintChild RenderInkWell at Point(400.0, 0.0) -2 | | | | | | TestPaintingCanvas() constructor: 800.0 x 600.0 -2 | | | | | | paintChild RenderConstrainedBox at Point(400.0, 0.0) -2 | | | | | | | TestPaintingCanvas() constructor: 800.0 x 600.0 -2 | | | | | | | paintChild RenderPadding at Point(400.0, 0.0) -2 | | | | | | | | TestPaintingCanvas() constructor: 800.0 x 600.0 -2 | | | | | | | | paintChild RenderPositionedBox at Point(412.0, 0.0) -2 | | | | | | | | | TestPaintingCanvas() constructor: 800.0 x 600.0 -2 | | | | | | | | | paintChild RenderOpacity at Point(480.0, 14.0) -2 | | | | | | | | | | TestPaintingCanvas() constructor: 800.0 x 600.0 -2 | | | | | | | | | | saveLayer(null, Paint(color:Color(0xb3000000))) -2 | | | | | | | | | | paintChild RenderParagraph at Point(480.0, 14.0) -2 | | | | | | | | | | | TestPaintingCanvas() constructor: 800.0 x 600.0 -2 | | | | | | | | | | | translate(480.0, 14.0) -2 | | | | | | | | | | | translate(-480.0, -14.0) -2 | | | | | | | | | | restore -2 | | | | | paintChild RenderInkWell at Point(600.0, 0.0) -2 | | | | | | TestPaintingCanvas() constructor: 800.0 x 600.0 -2 | | | | | | paintChild RenderConstrainedBox at Point(600.0, 0.0) -2 | | | | | | | TestPaintingCanvas() constructor: 800.0 x 600.0 -2 | | | | | | | paintChild RenderPadding at Point(600.0, 0.0) -2 | | | | | | | | TestPaintingCanvas() constructor: 800.0 x 600.0 -2 | | | | | | | | paintChild RenderPositionedBox at Point(612.0, 0.0) -2 | | | | | | | | | TestPaintingCanvas() constructor: 800.0 x 600.0 -2 | | | | | | | | | paintChild RenderOpacity at Point(672.0, 14.0) -2 | | | | | | | | | | TestPaintingCanvas() constructor: 800.0 x 600.0 -2 | | | | | | | | | | saveLayer(null, Paint(color:Color(0xb3000000))) -2 | | | | | | | | | | paintChild RenderParagraph at Point(672.0, 14.0) -2 | | | | | | | | | | | TestPaintingCanvas() constructor: 800.0 x 600.0 -2 | | | | | | | | | | | translate(672.0, 14.0) -2 | | | | | | | | | | | translate(-672.0, -14.0) -2 | | | | | | | | | | restore -2 | | | | restore -2 | | | paintChild RenderDecoratedBox at Point(0.0, 104.0) -2 | | | | TestPaintingCanvas() constructor: 800.0 x 600.0 -2 | | | | drawRect(Rect.fromLTRB(0.0, 104.0, 800.0, 600.0), Paint(color:Color(0xffe3f2fd))) -2 | | | | paintChild RenderPadding at Point(0.0, 104.0) -2 | | | | | TestPaintingCanvas() constructor: 800.0 x 600.0 -2 | | | | | paintChild RenderPadding at Point(12.0, 116.0) -2 | | | | | | TestPaintingCanvas() constructor: 800.0 x 600.0 -2 | | | | | | paintChild RenderDecoratedBox at Point(16.0, 120.0) -2 | | | | | | | TestPaintingCanvas() constructor: 800.0 x 600.0 -2 | | | | | | | drawRRect(Instance of 'RRect', Paint(color:Color(0xffffffff), drawLooper:true)) -2 | | | | | | | paintChild RenderClipRRect at Point(16.0, 120.0) -2 | | | | | | | | TestPaintingCanvas() constructor: 800.0 x 600.0 -2 | | | | | | | | saveLayer(Rect.fromLTRB(16.0, 120.0, 784.0, 584.0), Paint(color:Color(0xff000000))) -2 | | | | | | | | clipRRect() -2 | | | | | | | | paintChild RenderPadding at Point(16.0, 120.0) -2 | | | | | | | | | TestPaintingCanvas() constructor: 800.0 x 600.0 -2 | | | | | | | | | paintChild RenderFlex at Point(24.0, 128.0) -2 | | | | | | | | | | TestPaintingCanvas() constructor: 800.0 x 600.0 -2 | | | | | | | | | | paintChild RenderTransform at Point(24.0, 128.0) -2 | | | | | | | | | | | TestPaintingCanvas() constructor: 800.0 x 600.0 -2 | | | | | | | | | | | save -2 | | | | | | | | | | | translate(24.0, 128.0) -2 | | | | | | | | | | | concat([1.0, 0.0, 0.0, 0.0, 0.0, 1.0, 0.0, 0.0, 0.0, 0.0, 1.0, 0.0, 0.0, 0.0, 0.0, 1.0]) -2 | | | | | | | | | | | paintChild RenderTabBar at Point(0.0, 0.0) -2 | | | | | | | | | | | | TestPaintingCanvas() constructor: 800.0 x 600.0 -2 | | | | | | | | | | | | drawRect(Rect.fromLTRB(0.0, 0.0, 752.0, 48.0), Paint(color:Color(0xff2196f3))) -2 | | | | | | | | | | | | paintChild RenderInkWell at Point(0.0, 0.0) -2 | | | | | | | | | | | | | TestPaintingCanvas() constructor: 800.0 x 600.0 -2 | | | | | | | | | | | | | paintChild RenderConstrainedBox at Point(0.0, 0.0) -2 | | | | | | | | | | | | | | TestPaintingCanvas() constructor: 800.0 x 600.0 -2 | | | | | | | | | | | | | | paintChild RenderPadding at Point(0.0, 0.0) -2 | | | | | | | | | | | | | | | TestPaintingCanvas() constructor: 800.0 x 600.0 -2 | | | | | | | | | | | | | | | paintChild RenderPositionedBox at Point(12.0, 0.0) -2 | | | | | | | | | | | | | | | | TestPaintingCanvas() constructor: 800.0 x 600.0 -2 | | | | | | | | | | | | | | | | paintChild RenderOpacity at Point(78.5, 14.0) -2 | | | | | | | | | | | | | | | | | TestPaintingCanvas() constructor: 800.0 x 600.0 -2 | | | | | | | | | | | | | | | | | paintChild RenderParagraph at Point(78.5, 14.0) -2 | | | | | | | | | | | | | | | | | | TestPaintingCanvas() constructor: 800.0 x 600.0 -2 | | | | | | | | | | | | | | | | | | translate(78.5, 14.0) -2 | | | | | | | | | | | | | | | | | | translate(-78.5, -14.0) -2 | | | | | | | | | | | | drawRect(Rect.fromLTRB(0.0, 46.0, 188.0, 48.0), Paint(color:Color(0xffffffff))) -2 | | | | | | | | | | | | paintChild RenderInkWell at Point(188.0, 0.0) -2 | | | | | | | | | | | | | TestPaintingCanvas() constructor: 800.0 x 600.0 -2 | | | | | | | | | | | | | paintChild RenderConstrainedBox at Point(188.0, 0.0) -2 | | | | | | | | | | | | | | TestPaintingCanvas() constructor: 800.0 x 600.0 -2 | | | | | | | | | | | | | | paintChild RenderPadding at Point(188.0, 0.0) -2 | | | | | | | | | | | | | | | TestPaintingCanvas() constructor: 800.0 x 600.0 -2 | | | | | | | | | | | | | | | paintChild RenderPositionedBox at Point(200.0, 0.0) -2 | | | | | | | | | | | | | | | | TestPaintingCanvas() constructor: 800.0 x 600.0 -2 | | | | | | | | | | | | | | | | paintChild RenderOpacity at Point(265.0, 14.0) -2 | | | | | | | | | | | | | | | | | TestPaintingCanvas() constructor: 800.0 x 600.0 -2 | | | | | | | | | | | | | | | | | saveLayer(null, Paint(color:Color(0xb3000000))) -2 | | | | | | | | | | | | | | | | | paintChild RenderParagraph at Point(265.0, 14.0) -2 | | | | | | | | | | | | | | | | | | TestPaintingCanvas() constructor: 800.0 x 600.0 -2 | | | | | | | | | | | | | | | | | | translate(265.0, 14.0) -2 | | | | | | | | | | | | | | | | | | translate(-265.0, -14.0) -2 | | | | | | | | | | | | | | | | | restore -2 | | | | | | | | | | | | paintChild RenderInkWell at Point(376.0, 0.0) -2 | | | | | | | | | | | | | TestPaintingCanvas() constructor: 800.0 x 600.0 -2 | | | | | | | | | | | | | paintChild RenderConstrainedBox at Point(376.0, 0.0) -2 | | | | | | | | | | | | | | TestPaintingCanvas() constructor: 800.0 x 600.0 -2 | | | | | | | | | | | | | | paintChild RenderPadding at Point(376.0, 0.0) -2 | | | | | | | | | | | | | | | TestPaintingCanvas() constructor: 800.0 x 600.0 -2 | | | | | | | | | | | | | | | paintChild RenderPositionedBox at Point(388.0, 0.0) -2 | | | | | | | | | | | | | | | | TestPaintingCanvas() constructor: 800.0 x 600.0 -2 | | | | | | | | | | | | | | | | paintChild RenderOpacity at Point(452.0, 14.0) -2 | | | | | | | | | | | | | | | | | TestPaintingCanvas() constructor: 800.0 x 600.0 -2 | | | | | | | | | | | | | | | | | saveLayer(null, Paint(color:Color(0xb3000000))) -2 | | | | | | | | | | | | | | | | | paintChild RenderParagraph at Point(452.0, 14.0) -2 | | | | | | | | | | | | | | | | | | TestPaintingCanvas() constructor: 800.0 x 600.0 -2 | | | | | | | | | | | | | | | | | | translate(452.0, 14.0) -2 | | | | | | | | | | | | | | | | | | translate(-452.0, -14.0) -2 | | | | | | | | | | | | | | | | | restore -2 | | | | | | | | | | | | paintChild RenderInkWell at Point(564.0, 0.0) -2 | | | | | | | | | | | | | TestPaintingCanvas() constructor: 800.0 x 600.0 -2 | | | | | | | | | | | | | paintChild RenderConstrainedBox at Point(564.0, 0.0) -2 | | | | | | | | | | | | | | TestPaintingCanvas() constructor: 800.0 x 600.0 -2 | | | | | | | | | | | | | | paintChild RenderPadding at Point(564.0, 0.0) -2 | | | | | | | | | | | | | | | TestPaintingCanvas() constructor: 800.0 x 600.0 -2 | | | | | | | | | | | | | | | paintChild RenderPositionedBox at Point(576.0, 0.0) -2 | | | | | | | | | | | | | | | | TestPaintingCanvas() constructor: 800.0 x 600.0 -2 | | | | | | | | | | | | | | | | paintChild RenderOpacity at Point(638.0, 14.0) -2 | | | | | | | | | | | | | | | | | TestPaintingCanvas() constructor: 800.0 x 600.0 -2 | | | | | | | | | | | | | | | | | saveLayer(null, Paint(color:Color(0xb3000000))) -2 | | | | | | | | | | | | | | | | | paintChild RenderParagraph at Point(638.0, 14.0) -2 | | | | | | | | | | | | | | | | | | TestPaintingCanvas() constructor: 800.0 x 600.0 -2 | | | | | | | | | | | | | | | | | | translate(638.0, 14.0) -2 | | | | | | | | | | | | | | | | | | translate(-638.0, -14.0) -2 | | | | | | | | | | | | | | | | | restore -2 | | | | | | | | | | | restore -2 | | | | | | | | | | paintChild RenderPositionedBox at Point(343.0, 176.0) -2 | | | | | | | | | | | TestPaintingCanvas() constructor: 800.0 x 600.0 -2 | | | | | | | | | | | paintChild RenderParagraph at Point(343.0, 342.0) -2 | | | | | | | | | | | | TestPaintingCanvas() constructor: 800.0 x 600.0 -2 | | | | | | | | | | | | translate(343.0, 342.0) -2 | | | | | | | | | | | | translate(-343.0, -342.0) -2 | | | | | | | | restore -2 | | paintChild RenderDecoratedBox at Point(0.0, 0.0) -2 | | | TestPaintingCanvas() constructor: 800.0 x 600.0 -2 | | | drawRect(Rect.fromLTRB(0.0, 0.0, 800.0, 56.0), Paint(color:Color(0xff2196f3), drawLooper:true)) -2 | | | paintChild RenderPadding at Point(0.0, 0.0) -2 | | | | TestPaintingCanvas() constructor: 800.0 x 600.0 -2 | | | | paintChild RenderFlex at Point(8.0, 0.0) -2 | | | | | TestPaintingCanvas() constructor: 800.0 x 600.0 -2 | | | | | paintChild RenderConstrainedBox at Point(8.0, 0.0) -2 | | | | | | TestPaintingCanvas() constructor: 800.0 x 600.0 -2 | | | | | | paintChild RenderFlex at Point(8.0, 0.0) -2 | | | | | | | TestPaintingCanvas() constructor: 800.0 x 600.0 -2 | | | | | | | paintChild RenderPadding at Point(8.0, 14.0) -2 | | | | | | | | TestPaintingCanvas() constructor: 800.0 x 600.0 -2 | | | | | | | | paintChild RenderParagraph at Point(32.0, 14.0) -2 | | | | | | | | | TestPaintingCanvas() constructor: 800.0 x 600.0 -2 | | | | | | | | | translate(32.0, 14.0) -2 | | | | | | | | | translate(-32.0, -14.0) ------------------------------------------------------------------------- -PAINTED 2 FRAMES diff --git a/engine/src/flutter/tests/examples/tabs.dart b/engine/src/flutter/tests/examples/tabs.dart deleted file mode 100644 index cc79b2a51d..0000000000 --- a/engine/src/flutter/tests/examples/tabs.dart +++ /dev/null @@ -1,18 +0,0 @@ -// Copyright 2015 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 'dart:async'; - -import 'package:sky/widgets/widget.dart'; - -import '../../sdk/example/widgets/tabs.dart'; -import '../resources/display_list.dart'; - -main() async { - TestRenderView testRenderView = new TestRenderView(); - TabbedNavigatorApp app = new TabbedNavigatorApp(); - runApp(app, renderViewOverride: testRenderView); - await testRenderView.checkFrame(); - testRenderView.endTest(); -} diff --git a/engine/src/flutter/tests/lowlevel/resources/palatted-color-png-gamma-one-color-profile.png b/engine/src/flutter/tests/lowlevel/resources/palatted-color-png-gamma-one-color-profile.png deleted file mode 100644 index ad7c3dceb3..0000000000 Binary files a/engine/src/flutter/tests/lowlevel/resources/palatted-color-png-gamma-one-color-profile.png and /dev/null differ diff --git a/engine/src/flutter/tests/lowlevel/trivial-expected.txt b/engine/src/flutter/tests/lowlevel/trivial-expected.txt deleted file mode 100644 index 7ef22e9a43..0000000000 --- a/engine/src/flutter/tests/lowlevel/trivial-expected.txt +++ /dev/null @@ -1 +0,0 @@ -PASS diff --git a/engine/src/flutter/tests/lowlevel/trivial.dart b/engine/src/flutter/tests/lowlevel/trivial.dart deleted file mode 100644 index 484dc0f287..0000000000 --- a/engine/src/flutter/tests/lowlevel/trivial.dart +++ /dev/null @@ -1,5 +0,0 @@ -import "../resources/harness.dart"; - -void main() { - notifyTestComplete("PASS"); -} diff --git a/engine/src/flutter/tests/lowlevel/unittest-expected.txt b/engine/src/flutter/tests/lowlevel/unittest-expected.txt deleted file mode 100644 index 5ad781397d..0000000000 --- a/engine/src/flutter/tests/lowlevel/unittest-expected.txt +++ /dev/null @@ -1,6 +0,0 @@ -unittest-suite-wait-for-done -PASS: this is a test - -All 1 tests passed. -unittest-suite-success -DONE diff --git a/engine/src/flutter/tests/lowlevel/unittest.dart b/engine/src/flutter/tests/lowlevel/unittest.dart deleted file mode 100644 index 5440f7b60d..0000000000 --- a/engine/src/flutter/tests/lowlevel/unittest.dart +++ /dev/null @@ -1,11 +0,0 @@ -import "../resources/third_party/unittest/unittest.dart"; -import "../resources/unit.dart"; - -void main() { - initUnit(); - - test('this is a test', () { - int x = 2 + 3; - expect(x, equals(5)); - }); -} diff --git a/engine/src/flutter/tests/raw/bogus_import-expected.txt b/engine/src/flutter/tests/raw/bogus_import-expected.txt deleted file mode 100644 index b5be5e1d2b..0000000000 --- a/engine/src/flutter/tests/raw/bogus_import-expected.txt +++ /dev/null @@ -1,6 +0,0 @@ -unittest-suite-wait-for-done -PASS: shouldn't crash on a bogus import (see line 1) - -All 1 tests passed. -unittest-suite-success -DONE diff --git a/engine/src/flutter/tests/raw/bogus_import.dart b/engine/src/flutter/tests/raw/bogus_import.dart deleted file mode 100644 index 607598f03c..0000000000 --- a/engine/src/flutter/tests/raw/bogus_import.dart +++ /dev/null @@ -1,10 +0,0 @@ -import 'dart:bogus'; - -import '../resources/third_party/unittest/unittest.dart'; -import '../resources/unit.dart'; - -void main() { - initUnit(); - - test("shouldn't crash on a bogus import (see line 1)", () { }); -} diff --git a/engine/src/flutter/tests/raw/box_layout-expected.txt b/engine/src/flutter/tests/raw/box_layout-expected.txt deleted file mode 100644 index df690d7279..0000000000 --- a/engine/src/flutter/tests/raw/box_layout-expected.txt +++ /dev/null @@ -1,18 +0,0 @@ -TestRenderView enabled - -PAINT FOR FRAME #1 ---------------------------------------------- -1 | TestPaintingCanvas() constructor: 800.0 x 600.0 -1 | paintChild RenderDecoratedBox at Point(0.0, 0.0) -1 | | TestPaintingCanvas() constructor: 800.0 x 600.0 -1 | | drawRect(Rect.fromLTRB(0.0, 0.0, 800.0, 600.0), Paint(color:Color(0xff0000ff))) -1 | | paintChild RenderFlex at Point(0.0, 0.0) -1 | | | TestPaintingCanvas() constructor: 800.0 x 600.0 -1 | | | paintChild RenderPadding at Point(0.0, 0.0) -1 | | | | TestPaintingCanvas() constructor: 800.0 x 600.0 -1 | | | | paintChild RenderDecoratedBox at Point(50.0, 50.0) -1 | | | | | TestPaintingCanvas() constructor: 800.0 x 600.0 -1 | | | | | drawRect(Rect.fromLTRB(50.0, 50.0, 750.0, 150.0), Paint(color:Color(0xff00ff00))) -1 | | | | | paintChild RenderConstrainedBox at Point(50.0, 50.0) -1 | | | | | | TestPaintingCanvas() constructor: 800.0 x 600.0 ------------------------------------------------------------------------- -PAINTED 1 FRAMES diff --git a/engine/src/flutter/tests/raw/box_layout.dart b/engine/src/flutter/tests/raw/box_layout.dart deleted file mode 100644 index 660d5446b9..0000000000 --- a/engine/src/flutter/tests/raw/box_layout.dart +++ /dev/null @@ -1,17 +0,0 @@ -import 'dart:math' as math; -import 'dart:sky' as sky; - -import 'package:sky/rendering/box.dart'; -import 'package:sky/rendering/flex.dart'; -import 'package:sky/rendering/object.dart'; - -import '../resources/display_list.dart'; - -void main() { - RenderBox size = new RenderConstrainedBox(additionalConstraints: new BoxConstraints().applyHeight(100.0)); - RenderBox inner = new RenderDecoratedBox(decoration: new BoxDecoration(backgroundColor: const sky.Color(0xFF00FF00)), child: size); - RenderBox padding = new RenderPadding(padding: new EdgeDims.all(50.0), child: inner); - RenderBox flex = new RenderFlex(children: [padding], direction: FlexDirection.vertical, alignItems: FlexAlignItems.stretch); - RenderBox outer = new RenderDecoratedBox(decoration: new BoxDecoration(backgroundColor: const sky.Color(0xFF0000FF)), child: flex); - new TestRenderView(outer).endTest(); -} diff --git a/engine/src/flutter/tests/raw/color_bounds-expected.txt b/engine/src/flutter/tests/raw/color_bounds-expected.txt deleted file mode 100644 index 27b67a359b..0000000000 --- a/engine/src/flutter/tests/raw/color_bounds-expected.txt +++ /dev/null @@ -1,8 +0,0 @@ -unittest-suite-wait-for-done -PASS: paint set to black -PASS: color created with out of bounds value -PASS: color created with wildly out of bounds value - -All 3 tests passed. -unittest-suite-success -DONE diff --git a/engine/src/flutter/tests/raw/color_bounds.dart b/engine/src/flutter/tests/raw/color_bounds.dart deleted file mode 100644 index aa63d2b6c3..0000000000 --- a/engine/src/flutter/tests/raw/color_bounds.dart +++ /dev/null @@ -1,35 +0,0 @@ -import 'dart:sky' as sky; - -import '../resources/third_party/unittest/unittest.dart'; -import '../resources/unit.dart'; - -void main() { - initUnit(); - - test("paint set to black", () { - sky.Color c = new sky.Color(0x00000000); - sky.Paint p = new sky.Paint(); - p.color = c; - expect(c.toString(), equals('Color(0x00000000)')); - }); - - test("color created with out of bounds value", () { - try { - sky.Color c = new sky.Color(0x100 << 24); - sky.Paint p = new sky.Paint(); - p.color = c; - } catch (e) { - expect(e != null, equals(true)); - } - }); - - test("color created with wildly out of bounds value", () { - try { - sky.Color c = new sky.Color(1 << 1000000); - sky.Paint p = new sky.Paint(); - p.color = c; - } catch (e) { - expect(e != null, equals(true)); - } - }); -} diff --git a/engine/src/flutter/tests/raw/null_text_crash-expected.txt b/engine/src/flutter/tests/raw/null_text_crash-expected.txt deleted file mode 100644 index a442880287..0000000000 --- a/engine/src/flutter/tests/raw/null_text_crash-expected.txt +++ /dev/null @@ -1,6 +0,0 @@ -unittest-suite-wait-for-done -PASS: createText(null) shouldn't crash - -All 1 tests passed. -unittest-suite-success -DONE diff --git a/engine/src/flutter/tests/raw/null_text_crash.dart b/engine/src/flutter/tests/raw/null_text_crash.dart deleted file mode 100644 index 441646ab2a..0000000000 --- a/engine/src/flutter/tests/raw/null_text_crash.dart +++ /dev/null @@ -1,17 +0,0 @@ -// Copyright 2015 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 'dart:sky' as sky; - -import '../resources/third_party/unittest/unittest.dart'; -import '../resources/unit.dart'; - -void main() { - initUnit(); - - test("createText(null) shouldn't crash", () { - var doc = new sky.Document(); - doc.createText(null); - }); -} diff --git a/engine/src/flutter/tests/raw/padding_deflate-expected.txt b/engine/src/flutter/tests/raw/padding_deflate-expected.txt deleted file mode 100644 index 97bd1cbdff..0000000000 --- a/engine/src/flutter/tests/raw/padding_deflate-expected.txt +++ /dev/null @@ -1,17 +0,0 @@ -unittest-suite-wait-for-done -TestRenderView enabled - -PAINT FOR FRAME #1 ---------------------------------------------- -1 | TestPaintingCanvas() constructor: 800.0 x 600.0 -1 | paintChild RenderDecoratedBox at Point(0.0, 0.0) -1 | | TestPaintingCanvas() constructor: 800.0 x 600.0 -1 | | paintChild RenderPadding at Point(0.0, 0.0) -1 | | | TestPaintingCanvas() constructor: 800.0 x 600.0 -1 | | | paintChild RenderDecoratedBox at Point(10.0, 10.0) -1 | | | | TestPaintingCanvas() constructor: 800.0 x 600.0 ------------------------------------------------------------------------- -PASS: should not have a 0 sized colored Box - -All 1 tests passed. -unittest-suite-success -DONE diff --git a/engine/src/flutter/tests/raw/padding_deflate.dart b/engine/src/flutter/tests/raw/padding_deflate.dart deleted file mode 100644 index b102225751..0000000000 --- a/engine/src/flutter/tests/raw/padding_deflate.dart +++ /dev/null @@ -1,31 +0,0 @@ -// Copyright 2015 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 'dart:sky' as sky; - -import 'package:sky/rendering/box.dart'; -import 'package:sky/rendering/object.dart'; - -import '../resources/display_list.dart'; -import '../resources/third_party/unittest/unittest.dart'; -import '../resources/unit.dart'; - -void main() { - initUnit(); - - test("should not have a 0 sized colored Box", () { - var coloredBox = new RenderDecoratedBox( - decoration: new BoxDecoration() - ); - var paddingBox = new RenderPadding(padding: const EdgeDims.all(10.0), - child: coloredBox); - RenderBox root = new RenderDecoratedBox( - decoration: new BoxDecoration(), - child: paddingBox - ); - new TestRenderView(root); - expect(coloredBox.size.width, equals(sky.view.width - 20)); - expect(coloredBox.size.height, equals(sky.view.height - 20)); - }); -} diff --git a/engine/src/flutter/tests/raw/render_box-expected.txt b/engine/src/flutter/tests/raw/render_box-expected.txt deleted file mode 100644 index 2cc7c32a4a..0000000000 --- a/engine/src/flutter/tests/raw/render_box-expected.txt +++ /dev/null @@ -1,14 +0,0 @@ -unittest-suite-wait-for-done -TestRenderView enabled - -PAINT FOR FRAME #1 ---------------------------------------------- -1 | TestPaintingCanvas() constructor: 800.0 x 600.0 -1 | paintChild RenderDecoratedBox at Point(0.0, 0.0) -1 | | TestPaintingCanvas() constructor: 800.0 x 600.0 -1 | | drawRect(Rect.fromLTRB(0.0, 0.0, 800.0, 600.0), Paint(color:Color(0xff00ff00), shader: SkRadialGradient: (center: (0, 0) radius: 500 2 colors: FFFFEB3B, FF2196F3 clamp), drawLooper:true)) ------------------------------------------------------------------------- -PASS: should size to render view - -All 1 tests passed. -unittest-suite-success -DONE diff --git a/engine/src/flutter/tests/raw/render_box.dart b/engine/src/flutter/tests/raw/render_box.dart deleted file mode 100644 index 094f924b3c..0000000000 --- a/engine/src/flutter/tests/raw/render_box.dart +++ /dev/null @@ -1,32 +0,0 @@ -// Copyright 2015 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 'dart:sky' as sky; - -import 'package:sky/rendering/box.dart'; -import 'package:sky/rendering/object.dart'; - -import '../resources/display_list.dart'; -import '../resources/third_party/unittest/unittest.dart'; -import '../resources/unit.dart'; -import 'package:sky/theme/colors.dart'; -import 'package:sky/theme/shadows.dart'; - -void main() { - initUnit(); - - test("should size to render view", () { - RenderBox root = new RenderDecoratedBox( - decoration: new BoxDecoration( - backgroundColor: const sky.Color(0xFF00FF00), - gradient: new RadialGradient( - center: Point.origin, radius: 500.0, - colors: [Yellow[500], Blue[500]]), - boxShadow: shadows[3]) - ); - new TestRenderView(root); - expect(root.size.width, equals(sky.view.width)); - expect(root.size.height, equals(sky.view.height)); - }); -} diff --git a/engine/src/flutter/tests/raw/render_flex-expected.txt b/engine/src/flutter/tests/raw/render_flex-expected.txt deleted file mode 100644 index 0b2254e756..0000000000 --- a/engine/src/flutter/tests/raw/render_flex-expected.txt +++ /dev/null @@ -1,38 +0,0 @@ -unittest-suite-wait-for-done -TestRenderView enabled - -PAINT FOR FRAME #1 ---------------------------------------------- -1 | TestPaintingCanvas() constructor: 800.0 x 600.0 -1 | paintChild RenderDecoratedBox at Point(0.0, 0.0) -1 | | TestPaintingCanvas() constructor: 800.0 x 600.0 -1 | | drawRect(Rect.fromLTRB(0.0, 0.0, 800.0, 600.0), Paint(color:Color(0xff000000))) -1 | | paintChild RenderFlex at Point(0.0, 0.0) -1 | | | TestPaintingCanvas() constructor: 800.0 x 600.0 -1 | | | paintChild RenderSolidColor at Point(0.0, 0.0) -1 | | | | TestPaintingCanvas() constructor: 800.0 x 600.0 -1 | | | | drawRect(Rect.fromLTRB(0.0, 0.0, 800.0, 120.0), Paint(color:Color(0xffffff00))) -1 | | | paintChild RenderSolidColor at Point(350.0, 120.0) -1 | | | | TestPaintingCanvas() constructor: 800.0 x 600.0 -1 | | | | drawRect(Rect.fromLTRB(350.0, 120.0, 450.0, 220.0), Paint(color:Color(0x7700ffff))) -1 | | | paintChild RenderPadding at Point(390.0, 220.0) -1 | | | | TestPaintingCanvas() constructor: 800.0 x 600.0 -1 | | | | paintChild RenderDecoratedBox at Point(400.0, 230.0) -1 | | | | | TestPaintingCanvas() constructor: 800.0 x 600.0 -1 | | | | | drawRect(Rect.fromLTRB(400.0, 230.0, 400.0, 230.0), Paint(color:Color(0xffffffff))) -1 | | | paintChild RenderDecoratedBox at Point(0.0, 240.0) -1 | | | | TestPaintingCanvas() constructor: 800.0 x 600.0 -1 | | | | drawRect(Rect.fromLTRB(0.0, 240.0, 800.0, 600.0), Paint(color:Color(0xff333333))) -1 | | | | paintChild RenderFlex at Point(0.0, 240.0) -1 | | | | | TestPaintingCanvas() constructor: 800.0 x 600.0 -1 | | | | | paintChild RenderSolidColor at Point(0.0, 240.0) -1 | | | | | | TestPaintingCanvas() constructor: 800.0 x 600.0 -1 | | | | | | drawRect(Rect.fromLTRB(0.0, 240.0, 266.6666564941406, 600.0), Paint(color:Color(0x77ff00ff))) -1 | | | | | paintChild RenderSolidColor at Point(266.6666666666667, 240.0) -1 | | | | | | TestPaintingCanvas() constructor: 800.0 x 600.0 -1 | | | | | | drawRect(Rect.fromLTRB(266.6666564941406, 240.0, 800.0, 600.0), Paint(color:Color(0xff0000ff))) ------------------------------------------------------------------------- -PASS: should flex - -All 1 tests passed. -unittest-suite-success -DONE diff --git a/engine/src/flutter/tests/raw/render_flex.dart b/engine/src/flutter/tests/raw/render_flex.dart deleted file mode 100644 index ae92e42392..0000000000 --- a/engine/src/flutter/tests/raw/render_flex.dart +++ /dev/null @@ -1,23 +0,0 @@ -// Copyright 2015 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 'dart:sky' as sky; - -import 'package:sky/rendering/box.dart'; - -import '../../sdk/example/rendering/flex.dart'; -import '../resources/display_list.dart'; -import '../resources/third_party/unittest/unittest.dart'; -import '../resources/unit.dart'; - -void main() { - initUnit(); - - test("should flex", () { - RenderBox root = buildFlexExample(); - new TestRenderView(root); - expect(root.size.width, equals(sky.view.width)); - expect(root.size.height, equals(sky.view.height)); - }); -} diff --git a/engine/src/flutter/tests/raw/sector_layout-expected.txt b/engine/src/flutter/tests/raw/sector_layout-expected.txt deleted file mode 100644 index 5c68e26160..0000000000 --- a/engine/src/flutter/tests/raw/sector_layout-expected.txt +++ /dev/null @@ -1,27 +0,0 @@ -TestRenderView enabled - -PAINT FOR FRAME #1 ---------------------------------------------- -1 | TestPaintingCanvas() constructor: 800.0 x 600.0 -1 | paintChild RenderBoxToRenderSectorAdapter at Point(0.0, 0.0) -1 | | TestPaintingCanvas() constructor: 800.0 x 600.0 -1 | | paintChild RenderSectorRing at Point(400.0, 300.0) -1 | | | TestPaintingCanvas() constructor: 800.0 x 600.0 -1 | | | paintChild RenderSolidColor at Point(400.0, 300.0) -1 | | | | TestPaintingCanvas() constructor: 800.0 x 600.0 -1 | | | | drawPath(Instance of 'Path', Paint(color:Color(0xff00ffff))) -1 | | | paintChild RenderSolidColor at Point(400.0, 300.0) -1 | | | | TestPaintingCanvas() constructor: 800.0 x 600.0 -1 | | | | drawPath(Instance of 'Path', Paint(color:Color(0xff0000ff))) -1 | | | paintChild RenderSectorSlice at Point(400.0, 300.0) -1 | | | | TestPaintingCanvas() constructor: 800.0 x 600.0 -1 | | | | paintChild RenderSolidColor at Point(400.0, 300.0) -1 | | | | | TestPaintingCanvas() constructor: 800.0 x 600.0 -1 | | | | | drawPath(Instance of 'Path', Paint(color:Color(0xffffff00))) -1 | | | | paintChild RenderSolidColor at Point(400.0, 300.0) -1 | | | | | TestPaintingCanvas() constructor: 800.0 x 600.0 -1 | | | | | drawPath(Instance of 'Path', Paint(color:Color(0xffff9000))) -1 | | | | paintChild RenderSolidColor at Point(400.0, 300.0) -1 | | | | | TestPaintingCanvas() constructor: 800.0 x 600.0 -1 | | | | | drawPath(Instance of 'Path', Paint(color:Color(0xff00ff00))) ------------------------------------------------------------------------- -PAINTED 1 FRAMES diff --git a/engine/src/flutter/tests/raw/sector_layout.dart b/engine/src/flutter/tests/raw/sector_layout.dart deleted file mode 100644 index 5597b33f81..0000000000 --- a/engine/src/flutter/tests/raw/sector_layout.dart +++ /dev/null @@ -1,12 +0,0 @@ -// Copyright 2015 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 'dart:async'; - -import '../../sdk/example/rendering/sector_layout.dart'; -import '../resources/display_list.dart'; - -void main() { - new TestRenderView(buildSectorExample()).endTest(); -} diff --git a/engine/src/flutter/tests/styles/inline_style-expected.txt b/engine/src/flutter/tests/styles/inline_style-expected.txt deleted file mode 100644 index 0ff3690ee6..0000000000 --- a/engine/src/flutter/tests/styles/inline_style-expected.txt +++ /dev/null @@ -1,6 +0,0 @@ -unittest-suite-wait-for-done -PASS: should be settable using "style" attribute - -All 1 tests passed. -unittest-suite-success -DONE diff --git a/engine/src/flutter/tests/styles/inline_style.dart b/engine/src/flutter/tests/styles/inline_style.dart deleted file mode 100644 index cd8b6bac2d..0000000000 --- a/engine/src/flutter/tests/styles/inline_style.dart +++ /dev/null @@ -1,20 +0,0 @@ -import "../resources/third_party/unittest/unittest.dart"; -import "../resources/unit.dart"; - -import "dart:sky"; - -void main() { - initUnit(); - - test('should be settable using "style" attribute', () { - LayoutRoot layoutRoot = new LayoutRoot(); - var document = new Document(); - var foo = document.createElement('foo'); - layoutRoot.rootElement = foo; - - foo.setAttribute('style', 'color: red'); - - expect(foo.getAttribute('style'), equals('color: red')); - expect(foo.style["color"], equals('rgb(255, 0, 0)')); - }); -} diff --git a/engine/src/flutter/tests/styles/inline_style_crash-expected.txt b/engine/src/flutter/tests/styles/inline_style_crash-expected.txt deleted file mode 100644 index 614448abd4..0000000000 --- a/engine/src/flutter/tests/styles/inline_style_crash-expected.txt +++ /dev/null @@ -1,6 +0,0 @@ -unittest-suite-wait-for-done -PASS: should not crash when setting style to null - -All 1 tests passed. -unittest-suite-success -DONE diff --git a/engine/src/flutter/tests/styles/inline_style_crash.dart b/engine/src/flutter/tests/styles/inline_style_crash.dart deleted file mode 100644 index 9583f02042..0000000000 --- a/engine/src/flutter/tests/styles/inline_style_crash.dart +++ /dev/null @@ -1,29 +0,0 @@ -import "../resources/third_party/unittest/unittest.dart"; -import "../resources/unit.dart"; - -import "dart:sky"; - -void main() { - initUnit(); - - test('should not crash when setting style to null', () { - LayoutRoot layoutRoot = new LayoutRoot(); - var document = new Document(); - var foo = document.createElement('foo'); - layoutRoot.rootElement = foo; - - expect(foo.style['color'], isNull); - foo.style["color"] = null; // This used to crash. - expect(foo.style['color'], isNull); - foo.style["color"] = "blue"; - expect(foo.style['color'], equals("rgb(0, 0, 255)")); - foo.style["color"] = null; - expect(foo.style['color'], isNull); - foo.style["color"] = "blue"; - expect(foo.style['color'], equals("rgb(0, 0, 255)")); - foo.style.removeProperty("color"); - expect(foo.style['color'], isNull); - - layoutRoot.layout(); - }); -} diff --git a/engine/src/flutter/tests/widgets/buttons-expected.txt b/engine/src/flutter/tests/widgets/buttons-expected.txt deleted file mode 100644 index 653b38f5a2..0000000000 --- a/engine/src/flutter/tests/widgets/buttons-expected.txt +++ /dev/null @@ -1,79 +0,0 @@ -TestRenderView enabled - -PAINT FOR FRAME #1 ---------------------------------------------- -1 | TestPaintingCanvas() constructor: 800.0 x 600.0 ------------------------------------------------------------------------- - -PAINT FOR FRAME #2 ---------------------------------------------- -2 | TestPaintingCanvas() constructor: 800.0 x 600.0 -2 | paintChild RenderPositionedBox at Point(0.0, 0.0) -2 | | TestPaintingCanvas() constructor: 800.0 x 600.0 -2 | | paintChild RenderPadding at Point(348.0, 274.0) -2 | | | TestPaintingCanvas() constructor: 800.0 x 600.0 -2 | | | paintChild RenderConstrainedBox at Point(356.0, 282.0) -2 | | | | TestPaintingCanvas() constructor: 800.0 x 600.0 -2 | | | | paintChild RenderConstrainedBox at Point(356.0, 282.0) -2 | | | | | TestPaintingCanvas() constructor: 800.0 x 600.0 -2 | | | | | paintChild RenderDecoratedBox at Point(356.0, 282.0) -2 | | | | | | TestPaintingCanvas() constructor: 800.0 x 600.0 -2 | | | | | | drawRRect(Instance of 'RRect', Paint(color:Color(0xffe0e0e0), drawLooper:true)) -2 | | | | | | paintChild RenderInkWell at Point(356.0, 282.0) -2 | | | | | | | TestPaintingCanvas() constructor: 800.0 x 600.0 -2 | | | | | | | paintChild RenderPadding at Point(356.0, 282.0) -2 | | | | | | | | TestPaintingCanvas() constructor: 800.0 x 600.0 -2 | | | | | | | | paintChild RenderPositionedBox at Point(364.0, 282.0) -2 | | | | | | | | | TestPaintingCanvas() constructor: 800.0 x 600.0 -2 | | | | | | | | | paintChild RenderParagraph at Point(370.0, 290.0) -2 | | | | | | | | | | TestPaintingCanvas() constructor: 800.0 x 600.0 -2 | | | | | | | | | | translate(370.0, 290.0) -2 | | | | | | | | | | translate(-370.0, -290.0) ------------------------------------------------------------------------- - -PAINT FOR FRAME #3 ---------------------------------------------- -3 | TestPaintingCanvas() constructor: 800.0 x 600.0 -3 | paintChild RenderPositionedBox at Point(0.0, 0.0) -3 | | TestPaintingCanvas() constructor: 800.0 x 600.0 -3 | | paintChild RenderPadding at Point(348.0, 274.0) -3 | | | TestPaintingCanvas() constructor: 800.0 x 600.0 -3 | | | paintChild RenderConstrainedBox at Point(356.0, 282.0) -3 | | | | TestPaintingCanvas() constructor: 800.0 x 600.0 -3 | | | | paintChild RenderConstrainedBox at Point(356.0, 282.0) -3 | | | | | TestPaintingCanvas() constructor: 800.0 x 600.0 -3 | | | | | paintChild RenderDecoratedBox at Point(356.0, 282.0) -3 | | | | | | TestPaintingCanvas() constructor: 800.0 x 600.0 -3 | | | | | | paintChild RenderInkWell at Point(356.0, 282.0) -3 | | | | | | | TestPaintingCanvas() constructor: 800.0 x 600.0 -3 | | | | | | | paintChild RenderPadding at Point(356.0, 282.0) -3 | | | | | | | | TestPaintingCanvas() constructor: 800.0 x 600.0 -3 | | | | | | | | paintChild RenderPositionedBox at Point(364.0, 282.0) -3 | | | | | | | | | TestPaintingCanvas() constructor: 800.0 x 600.0 -3 | | | | | | | | | paintChild RenderParagraph at Point(370.0, 290.0) -3 | | | | | | | | | | TestPaintingCanvas() constructor: 800.0 x 600.0 -3 | | | | | | | | | | translate(370.0, 290.0) -3 | | | | | | | | | | translate(-370.0, -290.0) ------------------------------------------------------------------------- - -PAINT FOR FRAME #4 ---------------------------------------------- -4 | TestPaintingCanvas() constructor: 800.0 x 600.0 -4 | paintChild RenderPositionedBox at Point(0.0, 0.0) -4 | | TestPaintingCanvas() constructor: 800.0 x 600.0 -4 | | paintChild RenderDecoratedBox at Point(372.0, 272.0) -4 | | | TestPaintingCanvas() constructor: 800.0 x 600.0 -4 | | | drawCircle(Point(400.0, 300.0), 28.0, Paint(color:Color(0xff2196f3), drawLooper:true)) -4 | | | paintChild RenderClipOval at Point(372.0, 272.0) -4 | | | | TestPaintingCanvas() constructor: 800.0 x 600.0 -4 | | | | saveLayer(Rect.fromLTRB(372.0, 272.0, 428.0, 328.0), Paint(color:Color(0xff000000))) -4 | | | | clipPath(Instance of 'Path') -4 | | | | paintChild RenderConstrainedBox at Point(372.0, 272.0) -4 | | | | | TestPaintingCanvas() constructor: 800.0 x 600.0 -4 | | | | | paintChild RenderInkWell at Point(372.0, 272.0) -4 | | | | | | TestPaintingCanvas() constructor: 800.0 x 600.0 -4 | | | | | | paintChild RenderPositionedBox at Point(372.0, 272.0) -4 | | | | | | | TestPaintingCanvas() constructor: 800.0 x 600.0 -4 | | | | | | | paintChild RenderParagraph at Point(394.0, 290.0) -4 | | | | | | | | TestPaintingCanvas() constructor: 800.0 x 600.0 -4 | | | | | | | | translate(394.0, 290.0) -4 | | | | | | | | translate(-394.0, -290.0) -4 | | | | restore ------------------------------------------------------------------------- -PAINTED 4 FRAMES diff --git a/engine/src/flutter/tests/widgets/buttons.dart b/engine/src/flutter/tests/widgets/buttons.dart deleted file mode 100644 index 767d6c1794..0000000000 --- a/engine/src/flutter/tests/widgets/buttons.dart +++ /dev/null @@ -1,28 +0,0 @@ -// Copyright 2015 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/widgets/basic.dart'; -import 'package:sky/widgets/flat_button.dart'; -import 'package:sky/widgets/floating_action_button.dart'; -import 'package:sky/widgets/raised_button.dart'; - -import '../resources/display_list.dart'; - -main() async { - WidgetTester tester = new WidgetTester(); - - await tester.test(() { - return new Center(child: new RaisedButton(child: new Text("ENGAGE"))); - }); - - await tester.test(() { - return new Center(child: new FlatButton(child: new Text("ENGAGE"))); - }); - - await tester.test(() { - return new Center(child: new FloatingActionButton(child: new Text("+"))); - }); - - tester.endTest(); -} diff --git a/engine/src/flutter/tests/widgets/dialog-expected.txt b/engine/src/flutter/tests/widgets/dialog-expected.txt deleted file mode 100644 index 3f3e4320d2..0000000000 --- a/engine/src/flutter/tests/widgets/dialog-expected.txt +++ /dev/null @@ -1,57 +0,0 @@ -TestRenderView enabled - -PAINT FOR FRAME #1 ---------------------------------------------- -1 | TestPaintingCanvas() constructor: 800.0 x 600.0 ------------------------------------------------------------------------- - -PAINT FOR FRAME #2 ---------------------------------------------- -2 | TestPaintingCanvas() constructor: 800.0 x 600.0 -2 | paintChild RenderStack at Point(0.0, 0.0) -2 | | TestPaintingCanvas() constructor: 800.0 x 600.0 -2 | | paintChild RenderDecoratedBox at Point(0.0, 0.0) -2 | | | TestPaintingCanvas() constructor: 800.0 x 600.0 -2 | | | drawRect(Rect.fromLTRB(0.0, 0.0, 800.0, 600.0), Paint(color:Color(0x7f000000))) -2 | | | paintChild RenderConstrainedBox at Point(0.0, 0.0) -2 | | | | TestPaintingCanvas() constructor: 800.0 x 600.0 -2 | | paintChild RenderPositionedBox at Point(0.0, 0.0) -2 | | | TestPaintingCanvas() constructor: 800.0 x 600.0 -2 | | | paintChild RenderPadding at Point(220.0, 194.0) -2 | | | | TestPaintingCanvas() constructor: 800.0 x 600.0 -2 | | | | paintChild RenderConstrainedBox at Point(260.0, 218.0) -2 | | | | | TestPaintingCanvas() constructor: 800.0 x 600.0 -2 | | | | | paintChild RenderDecoratedBox at Point(260.0, 218.0) -2 | | | | | | TestPaintingCanvas() constructor: 800.0 x 600.0 -2 | | | | | | drawRRect(Instance of 'RRect', Paint(color:Color(0xffffffff), drawLooper:true)) -2 | | | | | | paintChild RenderShrinkWrapWidth at Point(260.0, 218.0) -2 | | | | | | | TestPaintingCanvas() constructor: 800.0 x 600.0 -2 | | | | | | | paintChild RenderSizeObserver at Point(260.0, 218.0) -2 | | | | | | | | TestPaintingCanvas() constructor: 800.0 x 600.0 -2 | | | | | | | | paintChild RenderViewport at Point(260.0, 218.0) -2 | | | | | | | | | TestPaintingCanvas() constructor: 800.0 x 600.0 -2 | | | | | | | | | save -2 | | | | | | | | | clipRect(Rect.fromLTRB(260.0, 218.0, 540.0, 382.0)) -2 | | | | | | | | | paintChild RenderSizeObserver at Point(260.0, 218.0) -2 | | | | | | | | | | TestPaintingCanvas() constructor: 800.0 x 600.0 -2 | | | | | | | | | | paintChild RenderBlock at Point(260.0, 218.0) -2 | | | | | | | | | | | TestPaintingCanvas() constructor: 800.0 x 600.0 -2 | | | | | | | | | | | paintChild RenderPadding at Point(260.0, 218.0) -2 | | | | | | | | | | | | TestPaintingCanvas() constructor: 800.0 x 600.0 -2 | | | | | | | | | | | | paintChild RenderParagraph at Point(284.0, 242.0) -2 | | | | | | | | | | | | | TestPaintingCanvas() constructor: 800.0 x 600.0 -2 | | | | | | | | | | | | | translate(284.0, 242.0) -2 | | | | | | | | | | | | | translate(-284.0, -242.0) -2 | | | | | | | | | | | paintChild RenderPadding at Point(260.0, 270.0) -2 | | | | | | | | | | | | TestPaintingCanvas() constructor: 800.0 x 600.0 -2 | | | | | | | | | | | | paintChild RenderParagraph at Point(284.0, 290.0) -2 | | | | | | | | | | | | | TestPaintingCanvas() constructor: 800.0 x 600.0 -2 | | | | | | | | | | | | | translate(284.0, 290.0) -2 | | | | | | | | | | | | | translate(-284.0, -290.0) -2 | | | | | | | | | | | paintChild RenderFlex at Point(260.0, 362.0) -2 | | | | | | | | | | | | TestPaintingCanvas() constructor: 800.0 x 600.0 -2 | | | | | | | | | | | | paintChild RenderParagraph at Point(411.0, 362.0) -2 | | | | | | | | | | | | | TestPaintingCanvas() constructor: 800.0 x 600.0 -2 | | | | | | | | | | | | | translate(411.0, 362.0) -2 | | | | | | | | | | | | | translate(-411.0, -362.0) -2 | | | | | | | | | restore ------------------------------------------------------------------------- -PAINTED 2 FRAMES diff --git a/engine/src/flutter/tests/widgets/dialog.dart b/engine/src/flutter/tests/widgets/dialog.dart deleted file mode 100644 index 38f4dca309..0000000000 --- a/engine/src/flutter/tests/widgets/dialog.dart +++ /dev/null @@ -1,22 +0,0 @@ -// Copyright 2015 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/widgets/basic.dart'; -import 'package:sky/widgets/dialog.dart'; - -import '../resources/display_list.dart'; - -main() async { - WidgetTester tester = new WidgetTester(); - - await tester.test(() { - return new Dialog( - title: new Text("I am a title"), - content: new Text("I am some content\nwith a line break"), - actions: [new Text("I am some actions")] - ); - }); - - tester.endTest(); -} diff --git a/engine/src/flutter/tests/widgets/syncs1-expected.txt b/engine/src/flutter/tests/widgets/syncs1-expected.txt deleted file mode 100644 index 3887abf9ed..0000000000 --- a/engine/src/flutter/tests/widgets/syncs1-expected.txt +++ /dev/null @@ -1,192 +0,0 @@ -TestRenderView enabled - -PAINT FOR FRAME #1 ---------------------------------------------- -1 | TestPaintingCanvas() constructor: 800.0 x 600.0 ------------------------------------------------------------------------- - -PAINT FOR FRAME #2 ---------------------------------------------- -2 | TestPaintingCanvas() constructor: 800.0 x 600.0 -2 | paintChild RenderFlex at Point(0.0, 0.0) -2 | | TestPaintingCanvas() constructor: 800.0 x 600.0 -2 | | paintChild RenderConstrainedBox at Point(0.0, 0.0) -2 | | | TestPaintingCanvas() constructor: 800.0 x 600.0 -2 | | | paintChild RenderFlex at Point(0.0, 0.0) -2 | | | | TestPaintingCanvas() constructor: 800.0 x 600.0 -2 | | | | paintChild RenderDecoratedBox at Point(0.0, 0.0) -2 | | | | | TestPaintingCanvas() constructor: 800.0 x 600.0 -2 | | | | | drawRect(Rect.fromLTRB(0.0, 0.0, 425.0, 250.0), Paint(color:Color(0xff00ffff))) -2 | | | | | paintChild RenderConstrainedBox at Point(0.0, 0.0) -2 | | | | | | TestPaintingCanvas() constructor: 800.0 x 600.0 -2 | | | | paintChild RenderPadding at Point(425.0, 99.0) -2 | | | | | TestPaintingCanvas() constructor: 800.0 x 600.0 -2 | | | | | paintChild RenderConstrainedBox at Point(433.0, 107.0) -2 | | | | | | TestPaintingCanvas() constructor: 800.0 x 600.0 -2 | | | | | | paintChild RenderConstrainedBox at Point(433.0, 107.0) -2 | | | | | | | TestPaintingCanvas() constructor: 800.0 x 600.0 -2 | | | | | | | paintChild RenderDecoratedBox at Point(433.0, 107.0) -2 | | | | | | | | TestPaintingCanvas() constructor: 800.0 x 600.0 -2 | | | | | | | | drawRRect(Instance of 'RRect', Paint(color:Color(0xffe0e0e0), drawLooper:true)) -2 | | | | | | | | paintChild RenderInkWell at Point(433.0, 107.0) -2 | | | | | | | | | TestPaintingCanvas() constructor: 800.0 x 600.0 -2 | | | | | | | | | paintChild RenderPadding at Point(433.0, 107.0) -2 | | | | | | | | | | TestPaintingCanvas() constructor: 800.0 x 600.0 -2 | | | | | | | | | | paintChild RenderPositionedBox at Point(441.0, 107.0) -2 | | | | | | | | | | | TestPaintingCanvas() constructor: 800.0 x 600.0 -2 | | | | | | | | | | | paintChild RenderParagraph at Point(441.0, 115.0) -2 | | | | | | | | | | | | TestPaintingCanvas() constructor: 800.0 x 600.0 -2 | | | | | | | | | | | | translate(441.0, 115.0) -2 | | | | | | | | | | | | translate(-441.0, -115.0) -2 | | paintChild RenderConstrainedBox at Point(0.0, 250.0) -2 | | | TestPaintingCanvas() constructor: 800.0 x 600.0 -2 | | | paintChild RenderStack at Point(0.0, 250.0) -2 | | | | TestPaintingCanvas() constructor: 800.0 x 600.0 -2 | | | | paintChild RenderDecoratedBox at Point(0.0, 250.0) -2 | | | | | TestPaintingCanvas() constructor: 800.0 x 600.0 -2 | | | | | drawRect(Rect.fromLTRB(0.0, 250.0, 800.0, 500.0), Paint(color:Color(0xff00ffff))) -2 | | | | | paintChild RenderConstrainedBox at Point(0.0, 250.0) -2 | | | | | | TestPaintingCanvas() constructor: 800.0 x 600.0 -2 | | | | paintChild RenderPadding at Point(0.0, 250.0) -2 | | | | | TestPaintingCanvas() constructor: 800.0 x 600.0 -2 | | | | | paintChild RenderConstrainedBox at Point(8.0, 258.0) -2 | | | | | | TestPaintingCanvas() constructor: 800.0 x 600.0 -2 | | | | | | paintChild RenderConstrainedBox at Point(8.0, 258.0) -2 | | | | | | | TestPaintingCanvas() constructor: 800.0 x 600.0 -2 | | | | | | | paintChild RenderDecoratedBox at Point(8.0, 258.0) -2 | | | | | | | | TestPaintingCanvas() constructor: 800.0 x 600.0 -2 | | | | | | | | drawRRect(Instance of 'RRect', Paint(color:Color(0xffe0e0e0), drawLooper:true)) -2 | | | | | | | | paintChild RenderInkWell at Point(8.0, 258.0) -2 | | | | | | | | | TestPaintingCanvas() constructor: 800.0 x 600.0 -2 | | | | | | | | | paintChild RenderPadding at Point(8.0, 258.0) -2 | | | | | | | | | | TestPaintingCanvas() constructor: 800.0 x 600.0 -2 | | | | | | | | | | paintChild RenderPositionedBox at Point(16.0, 258.0) -2 | | | | | | | | | | | TestPaintingCanvas() constructor: 800.0 x 600.0 -2 | | | | | | | | | | | paintChild RenderParagraph at Point(228.5, 365.0) -2 | | | | | | | | | | | | TestPaintingCanvas() constructor: 800.0 x 600.0 -2 | | | | | | | | | | | | translate(228.5, 365.0) -2 | | | | | | | | | | | | translate(-228.5, -365.0) ------------------------------------------------------------------------- - -PAINT FOR FRAME #3 ---------------------------------------------- -3 | TestPaintingCanvas() constructor: 800.0 x 600.0 -3 | paintChild RenderFlex at Point(0.0, 0.0) -3 | | TestPaintingCanvas() constructor: 800.0 x 600.0 -3 | | paintChild RenderConstrainedBox at Point(0.0, 0.0) -3 | | | TestPaintingCanvas() constructor: 800.0 x 600.0 -3 | | | paintChild RenderFlex at Point(0.0, 0.0) -3 | | | | TestPaintingCanvas() constructor: 800.0 x 600.0 -3 | | | | paintChild RenderDecoratedBox at Point(0.0, 0.0) -3 | | | | | TestPaintingCanvas() constructor: 800.0 x 600.0 -3 | | | | | drawRect(Rect.fromLTRB(0.0, 0.0, 549.0, 250.0), Paint(color:Color(0xefff9f00))) -3 | | | | | paintChild RenderConstrainedBox at Point(0.0, 0.0) -3 | | | | | | TestPaintingCanvas() constructor: 800.0 x 600.0 -3 | | | | paintChild RenderPadding at Point(549.0, 99.0) -3 | | | | | TestPaintingCanvas() constructor: 800.0 x 600.0 -3 | | | | | paintChild RenderConstrainedBox at Point(557.0, 107.0) -3 | | | | | | TestPaintingCanvas() constructor: 800.0 x 600.0 -3 | | | | | | paintChild RenderConstrainedBox at Point(557.0, 107.0) -3 | | | | | | | TestPaintingCanvas() constructor: 800.0 x 600.0 -3 | | | | | | | paintChild RenderDecoratedBox at Point(557.0, 107.0) -3 | | | | | | | | TestPaintingCanvas() constructor: 800.0 x 600.0 -3 | | | | | | | | drawRRect(Instance of 'RRect', Paint(color:Color(0xffe0e0e0), drawLooper:true)) -3 | | | | | | | | paintChild RenderInkWell at Point(557.0, 107.0) -3 | | | | | | | | | TestPaintingCanvas() constructor: 800.0 x 600.0 -3 | | | | | | | | | paintChild RenderPadding at Point(557.0, 107.0) -3 | | | | | | | | | | TestPaintingCanvas() constructor: 800.0 x 600.0 -3 | | | | | | | | | | paintChild RenderPositionedBox at Point(565.0, 107.0) -3 | | | | | | | | | | | TestPaintingCanvas() constructor: 800.0 x 600.0 -3 | | | | | | | | | | | paintChild RenderParagraph at Point(565.0, 115.0) -3 | | | | | | | | | | | | TestPaintingCanvas() constructor: 800.0 x 600.0 -3 | | | | | | | | | | | | translate(565.0, 115.0) -3 | | | | | | | | | | | | translate(-565.0, -115.0) -3 | | paintChild RenderConstrainedBox at Point(0.0, 250.0) -3 | | | TestPaintingCanvas() constructor: 800.0 x 600.0 -3 | | | paintChild RenderStack at Point(0.0, 250.0) -3 | | | | TestPaintingCanvas() constructor: 800.0 x 600.0 -3 | | | | paintChild RenderDecoratedBox at Point(0.0, 250.0) -3 | | | | | TestPaintingCanvas() constructor: 800.0 x 600.0 -3 | | | | | drawRect(Rect.fromLTRB(0.0, 250.0, 800.0, 500.0), Paint(color:Color(0xefff9f00))) -3 | | | | | paintChild RenderConstrainedBox at Point(0.0, 250.0) -3 | | | | | | TestPaintingCanvas() constructor: 800.0 x 600.0 -3 | | | | paintChild RenderPadding at Point(0.0, 250.0) -3 | | | | | TestPaintingCanvas() constructor: 800.0 x 600.0 -3 | | | | | paintChild RenderConstrainedBox at Point(8.0, 258.0) -3 | | | | | | TestPaintingCanvas() constructor: 800.0 x 600.0 -3 | | | | | | paintChild RenderConstrainedBox at Point(8.0, 258.0) -3 | | | | | | | TestPaintingCanvas() constructor: 800.0 x 600.0 -3 | | | | | | | paintChild RenderDecoratedBox at Point(8.0, 258.0) -3 | | | | | | | | TestPaintingCanvas() constructor: 800.0 x 600.0 -3 | | | | | | | | drawRRect(Instance of 'RRect', Paint(color:Color(0xffe0e0e0), drawLooper:true)) -3 | | | | | | | | paintChild RenderInkWell at Point(8.0, 258.0) -3 | | | | | | | | | TestPaintingCanvas() constructor: 800.0 x 600.0 -3 | | | | | | | | | paintChild RenderPadding at Point(8.0, 258.0) -3 | | | | | | | | | | TestPaintingCanvas() constructor: 800.0 x 600.0 -3 | | | | | | | | | | paintChild RenderPositionedBox at Point(16.0, 258.0) -3 | | | | | | | | | | | TestPaintingCanvas() constructor: 800.0 x 600.0 -3 | | | | | | | | | | | paintChild RenderParagraph at Point(290.5, 365.0) -3 | | | | | | | | | | | | TestPaintingCanvas() constructor: 800.0 x 600.0 -3 | | | | | | | | | | | | translate(290.5, 365.0) -3 | | | | | | | | | | | | translate(-290.5, -365.0) ------------------------------------------------------------------------- - -PAINT FOR FRAME #4 ---------------------------------------------- -4 | TestPaintingCanvas() constructor: 800.0 x 600.0 -4 | paintChild RenderFlex at Point(0.0, 0.0) -4 | | TestPaintingCanvas() constructor: 800.0 x 600.0 -4 | | paintChild RenderConstrainedBox at Point(0.0, 0.0) -4 | | | TestPaintingCanvas() constructor: 800.0 x 600.0 -4 | | | paintChild RenderFlex at Point(0.0, 0.0) -4 | | | | TestPaintingCanvas() constructor: 800.0 x 600.0 -4 | | | | paintChild RenderDecoratedBox at Point(0.0, 0.0) -4 | | | | | TestPaintingCanvas() constructor: 800.0 x 600.0 -4 | | | | | drawRect(Rect.fromLTRB(0.0, 0.0, 425.0, 250.0), Paint(color:Color(0xff00ffff))) -4 | | | | | paintChild RenderConstrainedBox at Point(0.0, 0.0) -4 | | | | | | TestPaintingCanvas() constructor: 800.0 x 600.0 -4 | | | | paintChild RenderPadding at Point(425.0, 99.0) -4 | | | | | TestPaintingCanvas() constructor: 800.0 x 600.0 -4 | | | | | paintChild RenderConstrainedBox at Point(433.0, 107.0) -4 | | | | | | TestPaintingCanvas() constructor: 800.0 x 600.0 -4 | | | | | | paintChild RenderConstrainedBox at Point(433.0, 107.0) -4 | | | | | | | TestPaintingCanvas() constructor: 800.0 x 600.0 -4 | | | | | | | paintChild RenderDecoratedBox at Point(433.0, 107.0) -4 | | | | | | | | TestPaintingCanvas() constructor: 800.0 x 600.0 -4 | | | | | | | | drawRRect(Instance of 'RRect', Paint(color:Color(0xffe0e0e0), drawLooper:true)) -4 | | | | | | | | paintChild RenderInkWell at Point(433.0, 107.0) -4 | | | | | | | | | TestPaintingCanvas() constructor: 800.0 x 600.0 -4 | | | | | | | | | paintChild RenderPadding at Point(433.0, 107.0) -4 | | | | | | | | | | TestPaintingCanvas() constructor: 800.0 x 600.0 -4 | | | | | | | | | | paintChild RenderPositionedBox at Point(441.0, 107.0) -4 | | | | | | | | | | | TestPaintingCanvas() constructor: 800.0 x 600.0 -4 | | | | | | | | | | | paintChild RenderParagraph at Point(441.0, 115.0) -4 | | | | | | | | | | | | TestPaintingCanvas() constructor: 800.0 x 600.0 -4 | | | | | | | | | | | | translate(441.0, 115.0) -4 | | | | | | | | | | | | translate(-441.0, -115.0) -4 | | paintChild RenderConstrainedBox at Point(0.0, 250.0) -4 | | | TestPaintingCanvas() constructor: 800.0 x 600.0 -4 | | | paintChild RenderStack at Point(0.0, 250.0) -4 | | | | TestPaintingCanvas() constructor: 800.0 x 600.0 -4 | | | | paintChild RenderDecoratedBox at Point(0.0, 250.0) -4 | | | | | TestPaintingCanvas() constructor: 800.0 x 600.0 -4 | | | | | drawRect(Rect.fromLTRB(0.0, 250.0, 800.0, 500.0), Paint(color:Color(0xff00ffff))) -4 | | | | | paintChild RenderConstrainedBox at Point(0.0, 250.0) -4 | | | | | | TestPaintingCanvas() constructor: 800.0 x 600.0 -4 | | | | paintChild RenderPadding at Point(0.0, 250.0) -4 | | | | | TestPaintingCanvas() constructor: 800.0 x 600.0 -4 | | | | | paintChild RenderConstrainedBox at Point(8.0, 258.0) -4 | | | | | | TestPaintingCanvas() constructor: 800.0 x 600.0 -4 | | | | | | paintChild RenderConstrainedBox at Point(8.0, 258.0) -4 | | | | | | | TestPaintingCanvas() constructor: 800.0 x 600.0 -4 | | | | | | | paintChild RenderDecoratedBox at Point(8.0, 258.0) -4 | | | | | | | | TestPaintingCanvas() constructor: 800.0 x 600.0 -4 | | | | | | | | drawRRect(Instance of 'RRect', Paint(color:Color(0xffe0e0e0), drawLooper:true)) -4 | | | | | | | | paintChild RenderInkWell at Point(8.0, 258.0) -4 | | | | | | | | | TestPaintingCanvas() constructor: 800.0 x 600.0 -4 | | | | | | | | | paintChild RenderPadding at Point(8.0, 258.0) -4 | | | | | | | | | | TestPaintingCanvas() constructor: 800.0 x 600.0 -4 | | | | | | | | | | paintChild RenderPositionedBox at Point(16.0, 258.0) -4 | | | | | | | | | | | TestPaintingCanvas() constructor: 800.0 x 600.0 -4 | | | | | | | | | | | paintChild RenderParagraph at Point(228.5, 365.0) -4 | | | | | | | | | | | | TestPaintingCanvas() constructor: 800.0 x 600.0 -4 | | | | | | | | | | | | translate(228.5, 365.0) -4 | | | | | | | | | | | | translate(-228.5, -365.0) ------------------------------------------------------------------------- -PAINTED 4 FRAMES diff --git a/engine/src/flutter/tests/widgets/syncs1.dart b/engine/src/flutter/tests/widgets/syncs1.dart deleted file mode 100644 index dcc20355dd..0000000000 --- a/engine/src/flutter/tests/widgets/syncs1.dart +++ /dev/null @@ -1,95 +0,0 @@ -// Copyright 2015 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/widgets/basic.dart'; -import 'package:sky/widgets/raised_button.dart'; - -import '../resources/display_list.dart'; - -class FiddleApp extends App { - - bool arbitrarySetting = true; - - void toggle() { - setState(() { - arbitrarySetting = !arbitrarySetting; - }); - } - - Widget buildFlex1() { - return new Flex([ - new Flexible(child: new Container( - decoration: new BoxDecoration( - backgroundColor: const Color(0xFF00FFFF) - ) - )), - new RaisedButton(child: new Text('TAP ME TO CHANGE THE BACKGROUND COLOUR'), onPressed: toggle) - ]); - } - - Widget buildFlex2() { - return new Flex([ - new Flexible(child: new Container( - key: 'something-else', - decoration: new BoxDecoration( - backgroundColor: const Color(0xEFFF9F00) - ) - )), - new RaisedButton(child: new Text('PRESS ME TO CHANGE IT BACK'), onPressed: toggle) - ]); - } - - Widget buildStack1() { - return new Stack([ - new Positioned(child: new Container( - decoration: new BoxDecoration( - backgroundColor: const Color(0xFF00FFFF) - ) - )), - new RaisedButton(child: new Text('TAP ME TO CHANGE THE BACKGROUND COLOUR'), onPressed: toggle) - ]); - } - - Widget buildStack2() { - return new Stack([ - new Positioned(child: new Container( - key: 'something-else', - decoration: new BoxDecoration( - backgroundColor: const Color(0xEFFF9F00) - ) - )), - new RaisedButton(child: new Text('PRESS ME TO CHANGE IT BACK'), onPressed: toggle) - ]); - } - - Widget build() { - return new Flex([ - new SizedBox( - key: 'flex-example', - height: 250.0, - child: arbitrarySetting ? buildFlex1() : buildFlex2() - ), - new SizedBox( - key: 'stack-example', - height: 250.0, - child: arbitrarySetting ? buildStack1() : buildStack2() - ) - ], - direction: FlexDirection.vertical, - alignItems: FlexAlignItems.stretch - ); - } -} - -main() async { - TestRenderView renderViewOverride = new TestRenderView(); - FiddleApp app = new FiddleApp(); - runApp(app, renderViewOverride: renderViewOverride); - await renderViewOverride.checkFrame(); - app.toggle(); - await renderViewOverride.checkFrame(); - app.toggle(); - await renderViewOverride.checkFrame(); - renderViewOverride.endTest(); -}