diff --git a/DEPS b/DEPS index 9964aff3e..99a8dcc00 100644 --- a/DEPS +++ b/DEPS
@@ -64,6 +64,9 @@ 'checkout_traffic_annotation_tools': 'checkout_configuration == "default"', 'checkout_instrumented_libraries': 'checkout_linux and checkout_configuration == "default"', + # Define the default board to be targetted when building for CrOS. + 'cros_board': 'amd64-generic', + 'android_git': 'https://android.googlesource.com', 'aomedia_git': 'https://aomedia.googlesource.com', 'chromium_git': 'https://chromium.googlesource.com', @@ -91,7 +94,7 @@ # Three lines of non-changing comments so that # the commit queue can handle CLs rolling ANGLE # and whatever else without interference from each other. - 'angle_revision': '30b604d8d17480bd519fb97ec817db1e4ca90f0e', + 'angle_revision': '6bc264aee686a8b814e4be1f49e25f1443151c48', # Three lines of non-changing comments so that # the commit queue can handle CLs rolling build tools # and whatever else without interference from each other. @@ -103,7 +106,7 @@ # Three lines of non-changing comments so that # the commit queue can handle CLs rolling PDFium # and whatever else without interference from each other. - 'pdfium_revision': '75304f915c5c095e916d4eca0152d4ccbb2a9147', + 'pdfium_revision': '4c22dd5690cdec725389055bb7c07c300a4b6fe4', # Three lines of non-changing comments so that # the commit queue can handle CLs rolling openmax_dl # and whatever else without interference from each other. @@ -139,7 +142,7 @@ # Three lines of non-changing comments so that # the commit queue can handle CLs rolling catapult # and whatever else without interference from each other. - 'catapult_revision': '29a751ceced16f3de204feb23a5ead6d8236dddb', + 'catapult_revision': '1fcfd9b6d53d5e277666487bc2acb59faf237346', # Three lines of non-changing comments so that # the commit queue can handle CLs rolling libFuzzer # and whatever else without interference from each other. @@ -387,7 +390,7 @@ }, 'src/third_party/breakpad/breakpad': - Var('chromium_git') + '/breakpad/breakpad.git' + '@' + 'ac4a549e29fbc8fe58212380e41fa24f36e6c3ec', + Var('chromium_git') + '/breakpad/breakpad.git' + '@' + 'adcc90ddb8c9ebc13a4312116ad92d8628b691c3', 'src/third_party/byte_buddy': { 'packages': [ @@ -408,7 +411,7 @@ # Build tools for Chrome OS. Note: This depends on third_party/pyelftools. 'src/third_party/chromite': { - 'url': Var('chromium_git') + '/chromiumos/chromite.git' + '@' + '87c1c3dbea9acae74a3f98cd9b044ed395793781', + 'url': Var('chromium_git') + '/chromiumos/chromite.git' + '@' + 'ec8d7a766a7e2512c0757f10ffaf8db91fd2c91c', 'condition': 'checkout_linux', }, @@ -433,7 +436,7 @@ }, 'src/third_party/depot_tools': - Var('chromium_git') + '/chromium/tools/depot_tools.git' + '@' + 'c7d0b34084e589a895875beb9cd7ca0ba961fd4f', + Var('chromium_git') + '/chromium/tools/depot_tools.git' + '@' + '668c1d8d1f1a6c26b088b5bff1203e35c74943a0', 'src/third_party/devtools-node-modules': Var('chromium_git') + '/external/github.com/ChromeDevTools/devtools-node-modules' + '@' + Var('devtools_node_modules_revision'), @@ -907,7 +910,7 @@ Var('chromium_git') + '/v8/v8.git' + '@' + Var('v8_revision'), 'src-internal': { - 'url': 'https://chrome-internal.googlesource.com/chrome/src-internal.git@df968af499231536509b6e218abd2a76df50769e', + 'url': 'https://chrome-internal.googlesource.com/chrome/src-internal.git@5e34303e0ea17a3fd3b86e200e87b2629bbeae59', 'condition': 'checkout_src_internal', }, @@ -1629,6 +1632,26 @@ ], }, + # Download CrOS simplechrome artifacts. + { + 'name': 'cros_simplechrome_artifacts', + 'pattern': '.', + # Building for CrOS is only supported on linux currently. + 'condition': 'checkout_chromeos and host_os == "linux"', + 'action': [ + 'src/third_party/chromite/bin/cros', + 'chrome-sdk', + '--nostart-goma', + '--use-external-config', + '--nogn-gen', + '--download-vm', + '--board={cros_board}', + '--cache-dir=src/build/cros_cache/', + '--log-level=error', + 'exit', + ], + }, + # Download and initialize "vpython" VirtualEnv environment packages. { 'name': 'vpython_common',
diff --git a/android_webview/OWNERS b/android_webview/OWNERS index 925cbe6..84a80b2 100644 --- a/android_webview/OWNERS +++ b/android_webview/OWNERS
@@ -1,4 +1,5 @@ boliu@chromium.org +changwan@chromium.org michaelbai@chromium.org tobiasjs@chromium.org torne@chromium.org
diff --git a/android_webview/glue/java/src/com/android/webview/chromium/WebViewChromium.java b/android_webview/glue/java/src/com/android/webview/chromium/WebViewChromium.java index ad0e6339b..336f421 100644 --- a/android_webview/glue/java/src/com/android/webview/chromium/WebViewChromium.java +++ b/android_webview/glue/java/src/com/android/webview/chromium/WebViewChromium.java
@@ -2303,11 +2303,6 @@ } @Override - public boolean super_awakenScrollBars(int arg0, boolean arg1) { - return false; - } - - @Override public void onScrollChanged(int l, int t, int oldl, int oldt) { // Intentional no-op. // Chromium calls this directly to trigger accessibility events. That isn't needed
diff --git a/android_webview/java/src/org/chromium/android_webview/FullScreenView.java b/android_webview/java/src/org/chromium/android_webview/FullScreenView.java index 287cbad..9e4962e 100644 --- a/android_webview/java/src/org/chromium/android_webview/FullScreenView.java +++ b/android_webview/java/src/org/chromium/android_webview/FullScreenView.java
@@ -239,11 +239,6 @@ } @Override - public boolean super_awakenScrollBars(int startDelay, boolean invalidate) { - return FullScreenView.super.awakenScrollBars(startDelay, invalidate); - } - - @Override public void onScrollChanged(int lPix, int tPix, int oldlPix, int oldtPix) { FullScreenView.this.onScrollChanged(lPix, tPix, oldlPix, oldtPix); }
diff --git a/android_webview/test/shell/src/org/chromium/android_webview/shell/AwShellActivity.java b/android_webview/test/shell/src/org/chromium/android_webview/shell/AwShellActivity.java index 4203a74..0eaa5c7 100644 --- a/android_webview/test/shell/src/org/chromium/android_webview/shell/AwShellActivity.java +++ b/android_webview/test/shell/src/org/chromium/android_webview/shell/AwShellActivity.java
@@ -5,7 +5,9 @@ package org.chromium.android_webview.shell; import android.app.Activity; +import android.app.AlertDialog; import android.content.Context; +import android.content.DialogInterface; import android.content.Intent; import android.content.SharedPreferences; import android.os.Bundle; @@ -30,6 +32,7 @@ import org.chromium.android_webview.AwDevToolsServer; import org.chromium.android_webview.AwGeolocationPermissions; import org.chromium.android_webview.AwSettings; +import org.chromium.android_webview.JsResultReceiver; import org.chromium.android_webview.test.AwTestContainerView; import org.chromium.android_webview.test.NullContentsClient; import org.chromium.base.CommandLine; @@ -40,8 +43,10 @@ import org.chromium.content_public.browser.WebContents; import org.chromium.content_public.common.ContentUrlConstants; +import java.net.MalformedURLException; import java.net.URI; import java.net.URISyntaxException; +import java.net.URL; /** * This is a lightweight activity for tests that only require WebView functionality. @@ -116,6 +121,40 @@ private View mCustomView; @Override + public void handleJsConfirm(String url, String message, JsResultReceiver receiver) { + String title = "From "; + try { + URL javaUrl = new URL(url); + title += javaUrl.getProtocol() + "://" + javaUrl.getHost(); + if (javaUrl.getPort() != -1) { + title += ":" + javaUrl.getPort(); + } + } catch (MalformedURLException e) { + title += url; + } + + new AlertDialog.Builder(testContainerView.getContext()) + .setTitle(title) + .setMessage(message) + .setPositiveButton("OK", + new DialogInterface.OnClickListener() { + @Override + public void onClick(DialogInterface dialogInterface, int i) { + receiver.confirm(); + } + }) + .setNegativeButton("Cancel", + new DialogInterface.OnClickListener() { + @Override + public void onClick(DialogInterface dialogInterface, int i) { + receiver.cancel(); + } + }) + .create() + .show(); + } + + @Override public void onPageStarted(String url) { if (mUrlTextView != null) { mUrlTextView.setText(url);
diff --git a/android_webview/test/shell/src/org/chromium/android_webview/test/AwTestContainerView.java b/android_webview/test/shell/src/org/chromium/android_webview/test/AwTestContainerView.java index f31aacc..d0bf3b8c 100644 --- a/android_webview/test/shell/src/org/chromium/android_webview/test/AwTestContainerView.java +++ b/android_webview/test/shell/src/org/chromium/android_webview/test/AwTestContainerView.java
@@ -550,11 +550,6 @@ } @Override - public boolean super_awakenScrollBars(int startDelay, boolean invalidate) { - return AwTestContainerView.super.awakenScrollBars(startDelay, invalidate); - } - - @Override public void setMeasuredDimension(int measuredWidth, int measuredHeight) { AwTestContainerView.super.setMeasuredDimension(measuredWidth, measuredHeight); }
diff --git a/ash/accelerators/accelerator_controller_unittest.cc b/ash/accelerators/accelerator_controller_unittest.cc index b49e3b70..7f6b5fe0 100644 --- a/ash/accelerators/accelerator_controller_unittest.cc +++ b/ash/accelerators/accelerator_controller_unittest.cc
@@ -585,7 +585,6 @@ GetController()->RegisterAccelerators(accelerators, arraysize(accelerators)); views::Widget::InitParams params(views::Widget::InitParams::TYPE_WINDOW); - params.context = CurrentContext(); params.bounds = gfx::Rect(5, 5, 20, 20); views::Widget* widget = new views::Widget; widget->Init(params);
diff --git a/ash/app_list/app_list_view_delegate_mash.cc b/ash/app_list/app_list_view_delegate_mash.cc index a5d5d13..8ce9bc7 100644 --- a/ash/app_list/app_list_view_delegate_mash.cc +++ b/ash/app_list/app_list_view_delegate_mash.cc
@@ -59,8 +59,8 @@ UMA_HISTOGRAM_COUNTS_100(app_list::kSearchResultDistanceFromOrigin, result->distance_from_origin()); } - owner_->OpenSearchResult(result_id, event_flags); } + owner_->OpenSearchResult(result_id, event_flags); } void AppListViewDelegateMash::InvokeSearchResultAction(
diff --git a/ash/autoclick/autoclick_controller.cc b/ash/autoclick/autoclick_controller.cc index 8d01455..c7be010 100644 --- a/ash/autoclick/autoclick_controller.cc +++ b/ash/autoclick/autoclick_controller.cc
@@ -146,7 +146,6 @@ params.accept_events = false; params.activatable = views::Widget::InitParams::ACTIVATABLE_NO; params.ownership = views::Widget::InitParams::WIDGET_OWNS_NATIVE_WIDGET; - params.context = root_window; params.opacity = views::Widget::InitParams::TRANSLUCENT_WINDOW; params.parent = Shell::GetContainer(root_window, kShellWindowId_OverlayContainer);
diff --git a/ash/components/strings/ash_components_strings_pt-PT.xtb b/ash/components/strings/ash_components_strings_pt-PT.xtb index c9a665d..dda6aeede 100644 --- a/ash/components/strings/ash_components_strings_pt-PT.xtb +++ b/ash/components/strings/ash_components_strings_pt-PT.xtb
@@ -161,7 +161,7 @@ <translation id="9106898733795143799">Página e navegador de Internet</translation> <translation id="9162942292291287644">Nenhum resultado da pesquisa para <ph name="QUERY" />.</translation> <translation id="9179672198516322668">Atalhos populares</translation> -<translation id="93603345341560814">Premir <ph name="SHIFT" /> e clicar num link</translation> +<translation id="93603345341560814">Prima <ph name="SHIFT" /> e clique num link</translation> <translation id="945383118875625837">Arrastar o link para a barra de marcadores</translation> <translation id="98120814841227350">Ir para o fim do documento</translation> </translationbundle> \ No newline at end of file
diff --git a/ash/components/strings/ash_components_strings_th.xtb b/ash/components/strings/ash_components_strings_th.xtb index 58a917a..d57b776 100644 --- a/ash/components/strings/ash_components_strings_th.xtb +++ b/ash/components/strings/ash_components_strings_th.xtb
@@ -159,7 +159,7 @@ <translation id="9052808072970550123">เปลี่ยนเป็นผู้ใช้ถัดไป</translation> <translation id="906458777597946297">ขยายหน้าต่างเต็มหน้าจอ</translation> <translation id="9106898733795143799">หน้าและเว็บเบราว์เซอร์</translation> -<translation id="9162942292291287644">ไม่มีผลการค้นหา <ph name="QUERY" /></translation> +<translation id="9162942292291287644">ไม่พบผลการค้นหา <ph name="QUERY" /></translation> <translation id="9179672198516322668">แป้นพิมพ์ลัดยอดนิยม</translation> <translation id="93603345341560814">กด <ph name="SHIFT" /> แล้วคลิกลิงก์</translation> <translation id="945383118875625837">ลากลิงก์ไปยังแถบบุ๊กมาร์ก</translation>
diff --git a/ash/display/shared_display_edge_indicator.cc b/ash/display/shared_display_edge_indicator.cc index 818450d6..19c668a94 100644 --- a/ash/display/shared_display_edge_indicator.cc +++ b/ash/display/shared_display_edge_indicator.cc
@@ -47,9 +47,6 @@ views::Widget::InitParams params(views::Widget::InitParams::TYPE_POPUP); params.opacity = views::Widget::InitParams::TRANSLUCENT_WINDOW; params.keep_on_top = true; - // We set the context to the primary root window; this is OK because the ash - // stacking controller will still place us in the correct RootWindow. - params.context = Shell::GetPrimaryRootWindow(); widget->set_focus_on_creation(false); widget->Init(params); widget->SetVisibilityChangedAnimationsEnabled(false);
diff --git a/ash/drag_drop/drag_drop_interactive_uitest.cc b/ash/drag_drop/drag_drop_interactive_uitest.cc index 64d6c5a..7c06da7 100644 --- a/ash/drag_drop/drag_drop_interactive_uitest.cc +++ b/ash/drag_drop/drag_drop_interactive_uitest.cc
@@ -72,7 +72,6 @@ views::Widget::InitParams params; params.type = views::Widget::InitParams::TYPE_WINDOW_FRAMELESS; params.accept_events = true; - params.context = Shell::GetPrimaryRootWindow(); params.bounds = bounds; widget->Init(params);
diff --git a/ash/extended_desktop_unittest.cc b/ash/extended_desktop_unittest.cc index 5a8b7bb..faa3207 100644 --- a/ash/extended_desktop_unittest.cc +++ b/ash/extended_desktop_unittest.cc
@@ -146,21 +146,10 @@ Shell::Get()->cursor_manager()->ShowCursor(); } + // TODO(jamescook): Switch to AshTestBase::CreateTestWidget(). views::Widget* CreateTestWidget(const gfx::Rect& bounds) { - return CreateTestWidgetWithParentAndContext(nullptr, CurrentContext(), - bounds, false); - } - - views::Widget* CreateTestWidgetWithParentAndContext(views::Widget* parent, - gfx::NativeView context, - const gfx::Rect& bounds, - bool child) { views::Widget::InitParams params(views::Widget::InitParams::TYPE_WINDOW); - if (parent) - params.parent = parent->GetNativeView(); - params.context = context; params.bounds = bounds; - params.child = child; views::Widget* widget = new views::Widget; widget->Init(params); widget->Show();
diff --git a/ash/focus_cycler_unittest.cc b/ash/focus_cycler_unittest.cc index edebce41..bf2d86e 100644 --- a/ash/focus_cycler_unittest.cc +++ b/ash/focus_cycler_unittest.cc
@@ -277,7 +277,6 @@ test_widget_delegate.reset(new PanedWidgetDelegate(browser_widget.get())); views::Widget::InitParams widget_params( views::Widget::InitParams::TYPE_WINDOW); - widget_params.context = CurrentContext(); widget_params.delegate = test_widget_delegate.get(); widget_params.ownership = views::Widget::InitParams::WIDGET_OWNS_NATIVE_WIDGET;
diff --git a/ash/frame/caption_buttons/frame_caption_button_container_view.cc b/ash/frame/caption_buttons/frame_caption_button_container_view.cc index 65d18ca..da15deb 100644 --- a/ash/frame/caption_buttons/frame_caption_button_container_view.cc +++ b/ash/frame/caption_buttons/frame_caption_button_container_view.cc
@@ -14,10 +14,12 @@ #include "ash/touch/touch_uma.h" #include "ash/wm/tablet_mode/tablet_mode_controller.h" #include "base/metrics/user_metrics.h" +#include "ui/aura/window_tree_host.h" #include "ui/base/hit_test.h" #include "ui/base/l10n/l10n_util.h" #include "ui/base/material_design/material_design_controller.h" #include "ui/compositor/scoped_animation_duration_scale_mode.h" +#include "ui/events/event_sink.h" #include "ui/gfx/animation/slide_animation.h" #include "ui/gfx/animation/tween.h" #include "ui/gfx/canvas.h" @@ -423,6 +425,19 @@ } else { RecordAction(UserMetricsAction("CloseButton_Clk")); } + } else if (sender == menu_button_) { + // Send up event as well as down event as ARC++ clients expect this + // sequence. + aura::Window* root_window = GetWidget()->GetNativeWindow()->GetRootWindow(); + ui::KeyEvent press_key_event(ui::ET_KEY_PRESSED, ui::VKEY_APPS, + ui::EF_NONE); + ignore_result(root_window->GetHost()->event_sink()->OnEventFromSource( + &press_key_event)); + ui::KeyEvent release_key_event(ui::ET_KEY_RELEASED, ui::VKEY_APPS, + ui::EF_NONE); + ignore_result(root_window->GetHost()->event_sink()->OnEventFromSource( + &release_key_event)); + // TODO(oshima): Add metrics } }
diff --git a/ash/frame/caption_buttons/frame_caption_button_container_view_unittest.cc b/ash/frame/caption_buttons/frame_caption_button_container_view_unittest.cc index 5b45cff..44c7c40 100644 --- a/ash/frame/caption_buttons/frame_caption_button_container_view_unittest.cc +++ b/ash/frame/caption_buttons/frame_caption_button_container_view_unittest.cc
@@ -58,7 +58,6 @@ new TestWidgetDelegate(maximize_allowed == MAXIMIZE_ALLOWED, minimize_allowed == MINIMIZE_ALLOWED); params.ownership = views::Widget::InitParams::WIDGET_OWNS_NATIVE_WIDGET; - params.context = CurrentContext(); widget->Init(params); return widget; }
diff --git a/ash/frame/caption_buttons/frame_size_button_unittest.cc b/ash/frame/caption_buttons/frame_size_button_unittest.cc index 19f092b..ad9e0e8a 100644 --- a/ash/frame/caption_buttons/frame_size_button_unittest.cc +++ b/ash/frame/caption_buttons/frame_size_button_unittest.cc
@@ -105,7 +105,6 @@ views::Widget* widget = new views::Widget; views::Widget::InitParams params( views::Widget::InitParams::TYPE_WINDOW_FRAMELESS); - params.context = CurrentContext(); params.delegate = delegate; params.bounds = gfx::Rect(10, 10, 100, 100); widget->Init(params);
diff --git a/ash/frame/custom_frame_view_ash_unittest.cc b/ash/frame/custom_frame_view_ash_unittest.cc index dfb1765..2d86625 100644 --- a/ash/frame/custom_frame_view_ash_unittest.cc +++ b/ash/frame/custom_frame_view_ash_unittest.cc
@@ -109,33 +109,12 @@ DISALLOW_COPY_AND_ASSIGN(TestWidgetConstraintsDelegate); }; -class CustomFrameViewAshTest : public AshTestBase { - public: - CustomFrameViewAshTest() = default; - ~CustomFrameViewAshTest() override = default; - - protected: - std::unique_ptr<views::Widget> CreateWidget( - CustomFrameTestWidgetDelegate* delegate) { - std::unique_ptr<views::Widget> widget(new views::Widget); - views::Widget::InitParams params; - params.delegate = delegate; - params.ownership = views::Widget::InitParams::WIDGET_OWNS_NATIVE_WIDGET; - params.bounds = gfx::Rect(0, 0, 100, 100); - params.context = CurrentContext(); - widget->Init(params); - return widget; - } - - private: - DISALLOW_COPY_AND_ASSIGN(CustomFrameViewAshTest); -}; +using CustomFrameViewAshTest = AshTestBase; // Verifies the client view is not placed at a y location of 0. TEST_F(CustomFrameViewAshTest, ClientViewCorrectlyPlaced) { - std::unique_ptr<views::Widget> widget( - CreateWidget(new CustomFrameTestWidgetDelegate)); - widget->Show(); + std::unique_ptr<views::Widget> widget = + CreateTestWidget(new CustomFrameTestWidgetDelegate); EXPECT_NE(0, widget->client_view()->bounds().y()); } @@ -144,8 +123,7 @@ TEST_F(CustomFrameViewAshTest, HeaderHeight) { CustomFrameTestWidgetDelegate* delegate = new CustomFrameTestWidgetDelegate; - std::unique_ptr<views::Widget> widget(CreateWidget(delegate)); - widget->Show(); + std::unique_ptr<views::Widget> widget = CreateTestWidget(delegate); // The header should have enough room for the window controls. The // header/content separator line overlays the window controls. @@ -157,7 +135,7 @@ // sizes when the client view does not specify any size constraints. TEST_F(CustomFrameViewAshTest, NoSizeConstraints) { TestWidgetConstraintsDelegate* delegate = new TestWidgetConstraintsDelegate; - std::unique_ptr<views::Widget> widget(CreateWidget(delegate)); + std::unique_ptr<views::Widget> widget = CreateTestWidget(delegate); CustomFrameViewAsh* custom_frame_view = delegate->custom_frame_view(); gfx::Size min_frame_size = custom_frame_view->GetMinimumSize(); @@ -178,7 +156,7 @@ TestWidgetConstraintsDelegate* delegate = new TestWidgetConstraintsDelegate; delegate->set_minimum_size(min_client_size); delegate->set_maximum_size(max_client_size); - std::unique_ptr<views::Widget> widget(CreateWidget(delegate)); + std::unique_ptr<views::Widget> widget = CreateTestWidget(delegate); CustomFrameViewAsh* custom_frame_view = delegate->custom_frame_view(); gfx::Size min_frame_size = custom_frame_view->GetMinimumSize(); @@ -198,7 +176,7 @@ const gfx::Size min_client_size(500, 500); TestWidgetConstraintsDelegate* delegate = new TestWidgetConstraintsDelegate; delegate->set_minimum_size(min_client_size); - std::unique_ptr<views::Widget> widget(CreateWidget(delegate)); + std::unique_ptr<views::Widget> widget = CreateTestWidget(delegate); // Update the native window's minimum size property. const gfx::Size min_window_size(600, 700); @@ -215,7 +193,7 @@ // avatar icon window property. TEST_F(CustomFrameViewAshTest, AvatarIcon) { TestWidgetConstraintsDelegate* delegate = new TestWidgetConstraintsDelegate; - std::unique_ptr<views::Widget> widget(CreateWidget(delegate)); + std::unique_ptr<views::Widget> widget = CreateTestWidget(delegate); CustomFrameViewAsh* custom_frame_view = delegate->custom_frame_view(); EXPECT_FALSE(custom_frame_view->GetAvatarIconViewForTest()); @@ -237,7 +215,7 @@ // new visibility. TEST_F(CustomFrameViewAshTest, HeaderViewNotifiedOfChildSizeChange) { TestWidgetConstraintsDelegate* delegate = new TestWidgetConstraintsDelegate; - std::unique_ptr<views::Widget> widget(CreateWidget(delegate)); + std::unique_ptr<views::Widget> widget = CreateTestWidget(delegate); const gfx::Rect initial = delegate->GetFrameCaptionButtonContainerViewBounds(); @@ -257,7 +235,7 @@ // header is zero. TEST_F(CustomFrameViewAshTest, FrameHiddenInTabletModeForMaximizedWindows) { CustomFrameTestWidgetDelegate* delegate = new CustomFrameTestWidgetDelegate; - std::unique_ptr<views::Widget> widget(CreateWidget(delegate)); + std::unique_ptr<views::Widget> widget = CreateTestWidget(delegate); widget->Maximize(); Shell::Get()->tablet_mode_controller()->EnableTabletModeWindowManager(true); @@ -268,7 +246,7 @@ // the header is non zero. TEST_F(CustomFrameViewAshTest, FrameShownInTabletModeForNonMaximizedWindows) { auto* delegate = new CustomFrameTestWidgetDelegate(); - std::unique_ptr<views::Widget> widget(CreateWidget(delegate)); + std::unique_ptr<views::Widget> widget = CreateTestWidget(delegate); Shell::Get()->tablet_mode_controller()->EnableTabletModeWindowManager(true); EXPECT_EQ(GetAshLayoutSize(AshLayoutSize::kNonBrowserCaption).height(), @@ -280,7 +258,7 @@ TEST_F(CustomFrameViewAshTest, FrameRemainsHiddenInTabletModeWhenTogglingFullscreen) { CustomFrameTestWidgetDelegate* delegate = new CustomFrameTestWidgetDelegate; - std::unique_ptr<views::Widget> widget(CreateWidget(delegate)); + std::unique_ptr<views::Widget> widget = CreateTestWidget(delegate); widget->SetFullscreen(true); EXPECT_EQ(0, delegate->GetCustomFrameViewTopBorderHeight()); @@ -292,8 +270,7 @@ TEST_F(CustomFrameViewAshTest, OpeningAppsInTabletMode) { auto* delegate = new CustomFrameTestWidgetDelegate(); - std::unique_ptr<views::Widget> widget(CreateWidget(delegate)); - widget->Show(); + std::unique_ptr<views::Widget> widget = CreateTestWidget(delegate); widget->Maximize(); Shell::Get()->tablet_mode_controller()->EnableTabletModeWindowManager(true); @@ -321,11 +298,10 @@ // Verify windows that are minimized and then entered into tablet mode will have // no header when unminimized in tablet mode. TEST_F(CustomFrameViewAshTest, MinimizedWindowsInTabletMode) { - std::unique_ptr<views::Widget> widget( - CreateWidget(new CustomFrameTestWidgetDelegate)); + std::unique_ptr<views::Widget> widget = + CreateTestWidget(new CustomFrameTestWidgetDelegate); widget->GetNativeWindow()->SetProperty(aura::client::kResizeBehaviorKey, ui::mojom::kResizeBehaviorCanMaximize); - widget->Show(); widget->Maximize(); widget->Minimize(); Shell::Get()->tablet_mode_controller()->EnableTabletModeWindowManager(true); @@ -337,8 +313,7 @@ TEST_F(CustomFrameViewAshTest, HeaderVisibilityInOverviewMode) { auto* delegate = new CustomFrameTestWidgetDelegate(); - std::unique_ptr<views::Widget> widget(CreateWidget(delegate)); - widget->Show(); + std::unique_ptr<views::Widget> widget = CreateTestWidget(delegate); // Verify the header is not painted in overview mode and painted when not in // overview mode. @@ -351,8 +326,7 @@ TEST_F(CustomFrameViewAshTest, HeaderVisibilityInSplitview) { auto create_widget = [this](CustomFrameTestWidgetDelegate* delegate) { - std::unique_ptr<views::Widget> widget(CreateWidget(delegate)); - widget->Show(); + std::unique_ptr<views::Widget> widget = CreateTestWidget(delegate); // Windows need to be resizable and maximizable to be used in splitview. widget->GetNativeWindow()->SetProperty( aura::client::kResizeBehaviorKey, @@ -468,8 +442,7 @@ TestButtonModel* model_ptr = model.get(); auto* delegate = new CustomFrameTestWidgetDelegate(); - std::unique_ptr<views::Widget> widget(CreateWidget(delegate)); - widget->Show(); + std::unique_ptr<views::Widget> widget = CreateTestWidget(delegate); ui::Accelerator accelerator_back_press(ui::VKEY_BROWSER_BACK, ui::EF_NONE); accelerator_back_press.set_key_state(ui::Accelerator::KeyState::PRESSED); @@ -526,14 +499,9 @@ // frame is hidden. TEST_F(CustomFrameViewAshTest, FrameVisibility) { CustomFrameTestWidgetDelegate* delegate = new CustomFrameTestWidgetDelegate; - views::Widget* widget = new views::Widget(); gfx::Rect window_bounds(10, 10, 200, 100); - views::Widget::InitParams params; - params.bounds = window_bounds; - params.context = CurrentContext(); - params.delegate = delegate; - widget->Init(params); - widget->Show(); + std::unique_ptr<views::Widget> widget = CreateTestWidget( + delegate, kShellWindowId_DefaultContainer, window_bounds); // The height is smaller by the top border height. gfx::Size client_bounds(200, 67); @@ -562,8 +530,7 @@ TestButtonModel* model_ptr = model.get(); auto* delegate = new CustomFrameTestWidgetDelegate(); - std::unique_ptr<views::Widget> widget(CreateWidget(delegate)); - widget->Show(); + std::unique_ptr<views::Widget> widget = CreateTestWidget(delegate); CustomFrameViewAsh* custom_frame_view = delegate->custom_frame_view(); custom_frame_view->SetCaptionButtonModel(std::move(model)); @@ -640,7 +607,7 @@ TEST_F(CustomFrameViewAshTest, ZeroTopBorderHeightOverride) { CustomFrameTestWidgetDelegate* delegate = new CustomFrameTestWidgetDelegate; - std::unique_ptr<views::Widget> widget(CreateWidget(delegate)); + std::unique_ptr<views::Widget> widget(CreateTestWidget(delegate)); CustomFrameViewAsh* custom_frame_view = delegate->custom_frame_view(); custom_frame_view->set_zero_top_border_height(true); EXPECT_EQ(0, delegate->GetCustomFrameViewTopBorderHeight()); @@ -689,7 +656,7 @@ // ash::kFrameActiveColorKey window property. TEST_P(CustomFrameViewAshFrameColorTest, kFrameActiveColorKey) { TestWidgetDelegate* delegate = new TestWidgetDelegate(GetParam()); - std::unique_ptr<views::Widget> widget(CreateWidget(delegate)); + std::unique_ptr<views::Widget> widget = CreateTestWidget(delegate); SkColor active_color = widget->GetNativeWindow()->GetProperty(ash::kFrameActiveColorKey); @@ -708,7 +675,7 @@ // ash::kFrameInactiveColorKey window property. TEST_P(CustomFrameViewAshFrameColorTest, KFrameInactiveColor) { TestWidgetDelegate* delegate = new TestWidgetDelegate(GetParam()); - std::unique_ptr<views::Widget> widget(CreateWidget(delegate)); + std::unique_ptr<views::Widget> widget = CreateTestWidget(delegate); SkColor active_color = widget->GetNativeWindow()->GetProperty(ash::kFrameInactiveColorKey);
diff --git a/ash/login/ui/login_test_base.cc b/ash/login/ui/login_test_base.cc index c99f41d..4ea2a1a9 100644 --- a/ash/login/ui/login_test_base.cc +++ b/ash/login/ui/login_test_base.cc
@@ -53,7 +53,6 @@ views::Widget::InitParams params( views::Widget::InitParams::TYPE_WINDOW_FRAMELESS); params.ownership = views::Widget::InitParams::WIDGET_OWNS_NATIVE_WIDGET; - params.context = CurrentContext(); params.bounds = gfx::Rect(0, 0, 800, 800); params.delegate = new WidgetDelegate(content);
diff --git a/ash/public/cpp/ash_switches.cc b/ash/public/cpp/ash_switches.cc index 22d224c..a5537b0 100644 --- a/ash/public/cpp/ash_switches.cc +++ b/ash/public/cpp/ash_switches.cc
@@ -25,9 +25,6 @@ const char kAshDisableSmoothScreenRotation[] = "ash-disable-smooth-screen-rotation"; -// Disables the split view on tablet mode. -const char kAshDisableTabletSplitView[] = "disable-tablet-splitview"; - // Disable the Touch Exploration Mode. Touch Exploration Mode will no longer be // turned on automatically when spoken feedback is enabled when this flag is // set. @@ -61,6 +58,9 @@ // is used to enable tablet mode on convertible devices. const char kAshEnableTabletMode[] = "enable-touchview"; +// Enables the split view on tablet mode. +const char kAshEnableTabletSplitView[] = "enable-tablet-splitview"; + // Enable the wayland server. const char kAshEnableWaylandServer[] = "ash-enable-wayland-server";
diff --git a/ash/public/cpp/ash_switches.h b/ash/public/cpp/ash_switches.h index 5807fe2..3ba712b 100644 --- a/ash/public/cpp/ash_switches.h +++ b/ash/public/cpp/ash_switches.h
@@ -21,7 +21,6 @@ ASH_PUBLIC_EXPORT extern const char kAshDeveloperShortcuts[]; ASH_PUBLIC_EXPORT extern const char kAshDisableLoginDimAndBlur[]; ASH_PUBLIC_EXPORT extern const char kAshDisableSmoothScreenRotation[]; -ASH_PUBLIC_EXPORT extern const char kAshDisableTabletSplitView[]; ASH_PUBLIC_EXPORT extern const char kAshDisableTouchExplorationMode[]; ASH_PUBLIC_EXPORT extern const char kAshEnableCursorMotionBlur[]; ASH_PUBLIC_EXPORT extern const char kAshEnableV1AppBackButton[]; @@ -30,6 +29,7 @@ ASH_PUBLIC_EXPORT extern const char kAshEnablePaletteOnAllDisplays[]; ASH_PUBLIC_EXPORT extern const char kAshEnableScaleSettingsTray[]; ASH_PUBLIC_EXPORT extern const char kAshEnableTabletMode[]; +ASH_PUBLIC_EXPORT extern const char kAshEnableTabletSplitView[]; ASH_PUBLIC_EXPORT extern const char kAshEnableWaylandServer[]; ASH_PUBLIC_EXPORT extern const char kAshEnableMirroredScreen[]; ASH_PUBLIC_EXPORT extern const char kAshForceEnableStylusTools[];
diff --git a/ash/public/interfaces/wallpaper.mojom b/ash/public/interfaces/wallpaper.mojom index 7021d5f..dbfa041 100644 --- a/ash/public/interfaces/wallpaper.mojom +++ b/ash/public/interfaces/wallpaper.mojom
@@ -217,6 +217,11 @@ // returns false. IsActiveUserWallpaperControlledByPolicy() => (bool controlled); + // Returns the location of the active user's wallpaper (either a url or a file + // path, corresponding to |WallpaperInfo.location|). Returns an empty string + // if there's no active user. + GetActiveUserWallpaperLocation() => (string loaction); + // Returns true if the wallpaper setting (used to open the wallpaper picker) // should be visible. ShouldShowWallpaperSetting() => (bool show);
diff --git a/ash/root_window_controller_unittest.cc b/ash/root_window_controller_unittest.cc index 53b1ad1..4c76e4c6 100644 --- a/ash/root_window_controller_unittest.cc +++ b/ash/root_window_controller_unittest.cc
@@ -168,7 +168,6 @@ views::Widget* unparented_control = new Widget; Widget::InitParams params; params.bounds = gfx::Rect(650, 10, 100, 100); - params.context = CurrentContext(); params.type = Widget::InitParams::TYPE_CONTROL; unparented_control->Init(params); EXPECT_EQ(root_windows[1],
diff --git a/ash/shelf/shelf_layout_manager_unittest.cc b/ash/shelf/shelf_layout_manager_unittest.cc index 21e1844..a7ae59e 100644 --- a/ash/shelf/shelf_layout_manager_unittest.cc +++ b/ash/shelf/shelf_layout_manager_unittest.cc
@@ -292,7 +292,6 @@ views::Widget* CreateTestWidget() { views::Widget::InitParams params(views::Widget::InitParams::TYPE_WINDOW); params.bounds = gfx::Rect(0, 0, 200, 200); - params.context = CurrentContext(); return CreateTestWidgetWithParams(params); }
diff --git a/ash/shelf/shelf_tooltip_manager_unittest.cc b/ash/shelf/shelf_tooltip_manager_unittest.cc index 3d80ac5a..6ab4909 100644 --- a/ash/shelf/shelf_tooltip_manager_unittest.cc +++ b/ash/shelf/shelf_tooltip_manager_unittest.cc
@@ -36,16 +36,6 @@ bool IsTimerRunning() { return tooltip_manager_->timer_.IsRunning(); } views::Widget* GetTooltip() { return tooltip_manager_->bubble_->GetWidget(); } - std::unique_ptr<views::Widget> CreateTestWidget() { - std::unique_ptr<views::Widget> widget = std::make_unique<views::Widget>(); - views::Widget::InitParams params; - params.ownership = views::Widget::InitParams::WIDGET_OWNS_NATIVE_WIDGET; - params.context = CurrentContext(); - widget->Init(params); - widget->Show(); - return widget; - } - protected: ShelfView* shelf_view_; ShelfTooltipManager* tooltip_manager_;
diff --git a/ash/shelf/shelf_widget_unittest.cc b/ash/shelf/shelf_widget_unittest.cc index 37dde22..91d6275 100644 --- a/ash/shelf/shelf_widget_unittest.cc +++ b/ash/shelf/shelf_widget_unittest.cc
@@ -140,7 +140,6 @@ views::Widget* widget = new views::Widget; views::Widget::InitParams params(views::Widget::InitParams::TYPE_WINDOW); params.bounds = gfx::Rect(0, 0, 200, 200); - params.context = CurrentContext(); // Widget is now owned by the parent window. widget->Init(params); widget->SetFullscreen(true); @@ -206,7 +205,6 @@ params.bounds = gfx::Rect(shelf_bounds.height() - kOverlapSize, shelf_bounds.y() - kWindowHeight + kOverlapSize, kWindowWidth, kWindowHeight); - params.context = CurrentContext(); // Widget is now owned by the parent window. widget->Init(params); widget->Show(); @@ -285,7 +283,6 @@ views::Widget* widget = new views::Widget; views::Widget::InitParams params(views::Widget::InitParams::TYPE_WINDOW); params.bounds = gfx::Rect(0, 0, 200, 200); - params.context = CurrentContext(); // Widget is now owned by the parent window. widget->Init(params); widget->Show();
diff --git a/ash/shell/window_type_launcher.cc b/ash/shell/window_type_launcher.cc index 61b71dc2..e162cb14 100644 --- a/ash/shell/window_type_launcher.cc +++ b/ash/shell/window_type_launcher.cc
@@ -285,7 +285,7 @@ ModalWindow::OpenModalWindow(GetWidget()->GetNativeView(), ui::MODAL_TYPE_WINDOW); } else if (sender == child_modal_button_) { - TestChildModalParent::Create(GetWidget()->GetNativeView()->GetRootWindow()); + TestChildModalParent::Create(); } else if (sender == transient_button_) { NonModalTransient::OpenNonModalTransient(GetWidget()->GetNativeView()); } else if (sender == show_hide_window_button_) {
diff --git a/ash/shell_unittest.cc b/ash/shell_unittest.cc index 0f41623..0fee05e 100644 --- a/ash/shell_unittest.cc +++ b/ash/shell_unittest.cc
@@ -160,9 +160,9 @@ class ShellTest : public AshTestBase { public: + // TODO(jamescook): Convert to AshTestBase::CreateTestWidget(). views::Widget* CreateTestWindow(views::Widget::InitParams params) { views::Widget* widget = new views::Widget; - params.context = CurrentContext(); widget->Init(params); return widget; }
diff --git a/ash/system/power/power_button_controller.cc b/ash/system/power/power_button_controller.cc index 2914daf4..757eb23 100644 --- a/ash/system/power/power_button_controller.cc +++ b/ash/system/power/power_button_controller.cc
@@ -17,7 +17,9 @@ #include "ash/shell_port.h" #include "ash/shutdown_reason.h" #include "ash/system/power/power_button_display_controller.h" +#include "ash/system/power/power_button_menu_item_view.h" #include "ash/system/power/power_button_menu_screen_view.h" +#include "ash/system/power/power_button_menu_view.h" #include "ash/system/power/power_button_screenshot_controller.h" #include "ash/wm/lock_state_controller.h" #include "ash/wm/session_state_animator.h" @@ -43,9 +45,10 @@ constexpr base::TimeDelta kShowMenuWhenScreenOffTimeout = base::TimeDelta::FromMilliseconds(2000); -// Time that power button should be pressed before starting to shutdown. -constexpr base::TimeDelta kStartShutdownTimeout = - base::TimeDelta::FromSeconds(3); +// Time that power button should be pressed after power menu is shown before +// starting the cancellable pre-shutdown animation. +constexpr base::TimeDelta kStartShutdownAnimationTimeout = + base::TimeDelta::FromMilliseconds(650); // Creates a fullscreen widget responsible for showing the power button menu. std::unique_ptr<views::Widget> CreateMenuWidget() { @@ -234,16 +237,16 @@ FROM_HERE, timeout, this, &PowerButtonController::StartPowerMenuAnimation); } - - shutdown_timer_.Start(FROM_HERE, kStartShutdownTimeout, this, - &PowerButtonController::OnShutdownTimeout); } else { + if (lock_state_controller_->CanCancelShutdownAnimation()) + lock_state_controller_->CancelShutdownAnimation(); + const base::TimeTicks previous_up_time = last_button_up_time_; last_button_up_time_ = timestamp; const bool menu_timer_was_running = power_button_menu_timer_.IsRunning(); power_button_menu_timer_.Stop(); - shutdown_timer_.Stop(); + pre_shutdown_timer_.Stop(); // Ignore the event if it comes too soon after the last one. if (timestamp - previous_up_time <= kIgnoreRepeatedButtonUpDelay) @@ -257,7 +260,8 @@ // Cancel the menu animation if it's still ongoing when the button is // released on a clamshell device. - if (!ShouldTurnScreenOffForTap() && !show_menu_animation_done_) { + if (!ShouldTurnScreenOffForTap() && IsMenuOpened() && + !show_menu_animation_done_) { static_cast<PowerButtonMenuScreenView*>(menu_widget_->GetContentsView()) ->ScheduleShowHideAnimation(false); } @@ -416,7 +420,7 @@ } void PowerButtonController::StopTimersAndDismissMenu() { - shutdown_timer_.Stop(); + pre_shutdown_timer_.Stop(); power_button_menu_timer_.Stop(); DismissMenu(); } @@ -446,11 +450,6 @@ ->ScheduleShowHideAnimation(true); } -void PowerButtonController::OnShutdownTimeout() { - display_controller_->SetBacklightsForcedOff(true); - lock_state_controller_->RequestShutdown(ShutdownReason::POWER_BUTTON); -} - void PowerButtonController::ProcessCommandLine() { const base::CommandLine* cl = base::CommandLine::ForCurrentProcess(); button_type_ = cl->HasSwitch(switches::kAuraLegacyPowerButton) @@ -486,6 +485,21 @@ void PowerButtonController::SetShowMenuAnimationDone() { show_menu_animation_done_ = true; + + DCHECK(menu_widget_->GetContentsView()); + // Focus on 'Power off' when menu is shown. + static_cast<PowerButtonMenuScreenView*>(menu_widget_->GetContentsView()) + ->power_button_menu_view() + ->power_off_item() + ->RequestFocus(); + + pre_shutdown_timer_.Start( + FROM_HERE, kStartShutdownAnimationTimeout, + base::BindRepeating( + [](LockStateController* controller) { + controller->StartShutdownAnimation(ShutdownReason::POWER_BUTTON); + }, + lock_state_controller_)); } void PowerButtonController::ParsePowerButtonPositionSwitch() {
diff --git a/ash/system/power/power_button_controller.h b/ash/system/power/power_button_controller.h index 46c65b5..ca15f22 100644 --- a/ash/system/power/power_button_controller.h +++ b/ash/system/power/power_button_controller.h
@@ -159,9 +159,6 @@ // button is pressed or when |power_button_menu_timer_| fires. void StartPowerMenuAnimation(); - // Called by |shutdown_timer_| to turn the screen off and request shutdown. - void OnShutdownTimeout(); - // Updates |button_type_| and |force_clamshell_power_button_| based on the // current command line. void ProcessCommandLine(); @@ -245,9 +242,10 @@ // Saves the most recent timestamp that power button was released. base::TimeTicks last_button_up_time_; - // Started when the power button is pressed and stopped when it's released. - // Runs OnShutdownTimeout() to start shutdown. - base::OneShotTimer shutdown_timer_; + // Started when |show_menu_animation_done_| is set to true and stopped when + // power button is released. Runs OnPreShutdownTimeout() to start the + // cancellable pre-shutdown animation. + base::OneShotTimer pre_shutdown_timer_; // Started when the power button of convertible/slate/detachable devices is // pressed and stopped when it's released. Runs StartPowerMenuAnimation() to
diff --git a/ash/system/power/power_button_controller_test_api.cc b/ash/system/power/power_button_controller_test_api.cc index c619aa4..b69f4ca 100644 --- a/ash/system/power/power_button_controller_test_api.cc +++ b/ash/system/power/power_button_controller_test_api.cc
@@ -20,16 +20,16 @@ PowerButtonControllerTestApi::~PowerButtonControllerTestApi() = default; -bool PowerButtonControllerTestApi::ShutdownTimerIsRunning() const { - return controller_->shutdown_timer_.IsRunning(); +bool PowerButtonControllerTestApi::PreShutdownTimerIsRunning() const { + return controller_->pre_shutdown_timer_.IsRunning(); } -bool PowerButtonControllerTestApi::TriggerShutdownTimeout() { - if (!controller_->shutdown_timer_.IsRunning()) +bool PowerButtonControllerTestApi::TriggerPreShutdownTimeout() { + if (!controller_->pre_shutdown_timer_.IsRunning()) return false; - base::Closure task = controller_->shutdown_timer_.user_task(); - controller_->shutdown_timer_.Stop(); + base::Closure task = controller_->pre_shutdown_timer_.user_task(); + controller_->pre_shutdown_timer_.Stop(); task.Run(); return true; }
diff --git a/ash/system/power/power_button_controller_test_api.h b/ash/system/power/power_button_controller_test_api.h index 2d0942be..4d4c14f 100644 --- a/ash/system/power/power_button_controller_test_api.h +++ b/ash/system/power/power_button_controller_test_api.h
@@ -31,12 +31,12 @@ explicit PowerButtonControllerTestApi(PowerButtonController* controller); ~PowerButtonControllerTestApi(); - // Returns true when |controller_->shutdown_timer_| is running. - bool ShutdownTimerIsRunning() const; + // Returns true when |controller_->pre_shutdown_timer_| is running. + bool PreShutdownTimerIsRunning() const; - // If |controller_->shutdown_timer_| is running, stops it, runs its task, and - // returns true. Otherwise, returns false. - bool TriggerShutdownTimeout() WARN_UNUSED_RESULT; + // If |controller_->pre_shutdown_timer_| is running, stops it, runs its task, + // and returns true. Otherwise, returns false. + bool TriggerPreShutdownTimeout() WARN_UNUSED_RESULT; // Returns true when |power_button_menu_timer_| is running. bool PowerButtonMenuTimerIsRunning() const;
diff --git a/ash/system/power/power_button_controller_unittest.cc b/ash/system/power/power_button_controller_unittest.cc index 66f2843..f8e50a6 100644 --- a/ash/system/power/power_button_controller_unittest.cc +++ b/ash/system/power/power_button_controller_unittest.cc
@@ -15,6 +15,7 @@ #include "ash/session/session_controller.h" #include "ash/shell.h" #include "ash/system/power/power_button_controller_test_api.h" +#include "ash/system/power/power_button_menu_item_view.h" #include "ash/system/power/power_button_menu_view.h" #include "ash/system/power/power_button_test_base.h" #include "ash/test_media_client.h" @@ -129,6 +130,10 @@ ASSERT_TRUE(power_button_test_api_->TriggerPowerButtonMenuTimeout()); ReleasePowerButton(); ASSERT_TRUE(power_button_test_api_->IsMenuOpened()); + // "Power off" item has focus after menu is opened. + EXPECT_TRUE(power_button_test_api_->GetPowerButtonMenuView() + ->power_off_item() + ->HasFocus()); } // Tap outside of the menu view to dismiss the menu. @@ -290,48 +295,20 @@ // Tests that release power button after menu is opened but before trigger // shutdown will not turn screen off. -TEST_F(PowerButtonControllerTest, ReleasePowerButtonAfterShowPowerButtonMenu) { +TEST_F(PowerButtonControllerTest, ReleasePowerButtonBeforeTriggerShutdown) { PressPowerButton(); EXPECT_TRUE(power_button_test_api_->PowerButtonMenuTimerIsRunning()); - EXPECT_TRUE(power_button_test_api_->ShutdownTimerIsRunning()); EXPECT_FALSE(power_manager_client_->backlights_forced_off()); - EXPECT_TRUE(power_button_test_api_->TriggerPowerButtonMenuTimeout()); + ASSERT_TRUE(power_button_test_api_->TriggerPowerButtonMenuTimeout()); + ASSERT_TRUE(power_button_test_api_->TriggerPreShutdownTimeout()); + EXPECT_TRUE(lock_state_test_api_->shutdown_timer_is_running()); ReleasePowerButton(); EXPECT_TRUE(power_button_test_api_->IsMenuOpened()); - EXPECT_FALSE(power_button_test_api_->ShutdownTimerIsRunning()); + EXPECT_FALSE(lock_state_test_api_->shutdown_timer_is_running()); + EXPECT_FALSE(power_button_test_api_->PowerButtonMenuTimerIsRunning()); EXPECT_FALSE(power_manager_client_->backlights_forced_off()); } -// Tests that the real shutdown is started if the power button is released -// after the timer fires when screen is on. -TEST_F(PowerButtonControllerTest, RealShutdownIfScreenIsOn) { - PressPowerButton(); - EXPECT_TRUE(power_button_test_api_->TriggerShutdownTimeout()); - ShutdownSoundPlayed(); - EXPECT_TRUE(lock_state_test_api_->real_shutdown_timer_is_running()); - ReleasePowerButton(); - EXPECT_TRUE(power_manager_client_->backlights_forced_off()); - // Release power button if real shutdown started will not cancel the shutdown. - EXPECT_TRUE(lock_state_test_api_->real_shutdown_timer_is_running()); -} - -// Tests that the real shutdown is started if the power button is released -// after the timer fires when screen is off. -TEST_F(PowerButtonControllerTest, RealShutdownIfScreenIsOff) { - // Press power button to turn screen off. - PressPowerButton(); - ReleaseLockButton(); - - PressPowerButton(); - EXPECT_TRUE(power_button_test_api_->TriggerShutdownTimeout()); - ShutdownSoundPlayed(); - EXPECT_TRUE(lock_state_test_api_->real_shutdown_timer_is_running()); - ReleasePowerButton(); - EXPECT_TRUE(power_manager_client_->backlights_forced_off()); - // Release power button if real shutdown started will not cancel the shutdown. - EXPECT_TRUE(lock_state_test_api_->real_shutdown_timer_is_running()); -} - // Should dismiss the menu if locking screen when menu is opened. TEST_F(PowerButtonControllerTest, LockScreenIfMenuIsOpened) { Initialize(ButtonType::NORMAL, LoginStatus::USER); @@ -407,19 +384,19 @@ // are not forced off. tick_clock_.Advance(base::TimeDelta::FromMilliseconds(500)); PressPowerButton(); - EXPECT_TRUE(power_button_test_api_->ShutdownTimerIsRunning()); + EXPECT_TRUE(power_button_test_api_->PowerButtonMenuTimerIsRunning()); ReleasePowerButton(); - EXPECT_FALSE(power_button_test_api_->ShutdownTimerIsRunning()); + EXPECT_FALSE(power_button_test_api_->PowerButtonMenuTimerIsRunning()); EXPECT_FALSE(power_manager_client_->backlights_forced_off()); // Send the power button event after a longer delay and check that backlights // are forced off. tick_clock_.Advance(base::TimeDelta::FromMilliseconds(1600)); PressPowerButton(); - EXPECT_TRUE(power_button_test_api_->ShutdownTimerIsRunning()); + EXPECT_TRUE(power_button_test_api_->PowerButtonMenuTimerIsRunning()); ReleasePowerButton(); SendBrightnessChange(0, kUserCause); - EXPECT_FALSE(power_button_test_api_->ShutdownTimerIsRunning()); + EXPECT_FALSE(power_button_test_api_->PowerButtonMenuTimerIsRunning()); EXPECT_TRUE(power_manager_client_->backlights_forced_off()); } @@ -443,19 +420,19 @@ tick_clock_.Advance(base::TimeDelta::FromMilliseconds(500)); PressPowerButton(); SendBrightnessChange(kNonZeroBrightness, kUserCause); - EXPECT_TRUE(power_button_test_api_->ShutdownTimerIsRunning()); + EXPECT_TRUE(power_button_test_api_->PowerButtonMenuTimerIsRunning()); ReleasePowerButton(); - EXPECT_FALSE(power_button_test_api_->ShutdownTimerIsRunning()); + EXPECT_FALSE(power_button_test_api_->PowerButtonMenuTimerIsRunning()); EXPECT_FALSE(power_manager_client_->backlights_forced_off()); // Send the power button event after a longer delay and check that backlights // are forced off. tick_clock_.Advance(base::TimeDelta::FromMilliseconds(1600)); PressPowerButton(); - EXPECT_TRUE(power_button_test_api_->ShutdownTimerIsRunning()); + EXPECT_TRUE(power_button_test_api_->PowerButtonMenuTimerIsRunning()); ReleasePowerButton(); SendBrightnessChange(0, kUserCause); - EXPECT_FALSE(power_button_test_api_->ShutdownTimerIsRunning()); + EXPECT_FALSE(power_button_test_api_->PowerButtonMenuTimerIsRunning()); EXPECT_TRUE(power_manager_client_->backlights_forced_off()); } @@ -598,10 +575,8 @@ TEST_F(PowerButtonControllerTest, EnterOrLeaveTabletModeWhilePressingPowerButton) { PressPowerButton(); - EXPECT_TRUE(power_button_test_api_->ShutdownTimerIsRunning()); EXPECT_TRUE(power_button_test_api_->PowerButtonMenuTimerIsRunning()); power_button_controller_->OnTabletModeStarted(); - EXPECT_FALSE(power_button_test_api_->ShutdownTimerIsRunning()); EXPECT_FALSE(power_button_test_api_->PowerButtonMenuTimerIsRunning()); tick_clock_.Advance(base::TimeDelta::FromMilliseconds(1500)); ReleasePowerButton(); @@ -609,10 +584,8 @@ EXPECT_FALSE(power_button_test_api_->IsMenuOpened()); PressPowerButton(); - EXPECT_TRUE(power_button_test_api_->ShutdownTimerIsRunning()); EXPECT_TRUE(power_button_test_api_->PowerButtonMenuTimerIsRunning()); power_button_controller_->OnTabletModeEnded(); - EXPECT_FALSE(power_button_test_api_->ShutdownTimerIsRunning()); EXPECT_FALSE(power_button_test_api_->PowerButtonMenuTimerIsRunning()); tick_clock_.Advance(base::TimeDelta::FromMilliseconds(2500)); ReleasePowerButton();
diff --git a/ash/system/power/power_button_menu_item_view.cc b/ash/system/power/power_button_menu_item_view.cc index 62c9ad8..e95bfe3 100644 --- a/ash/system/power/power_button_menu_item_view.cc +++ b/ash/system/power/power_button_menu_item_view.cc
@@ -9,6 +9,7 @@ #include "ui/gfx/color_palette.h" #include "ui/gfx/font.h" #include "ui/gfx/paint_vector_icon.h" +#include "ui/views/border.h" #include "ui/views/controls/image_view.h" #include "ui/views/controls/label.h" @@ -16,6 +17,9 @@ namespace { +// Color of the image icon. +constexpr SkColor kItemIconColor = SkColorSetARGBMacro(0xFF, 0x20, 0x21, 0x24); + // Color of the title of the label. constexpr SkColor kItemTitleColor = SkColorSetARGBMacro(0xFF, 0x5F, 0x63, 0x68); @@ -27,10 +31,21 @@ constexpr int kIconSize = 24; // Top padding of the image icon to the top of the item view. -constexpr int kIconTopPadding = 24; +constexpr int kIconTopPadding = 16; // Top padding of the label of title to the top of the item view. -constexpr int kTitleTopPadding = 50; +constexpr int kTitleTopPadding = 53; + +// The amount of rounding applied to the corners of the focused menu item. +constexpr int kFocusedItemRoundRectRadiusDp = 8; + +// Color of the focused menu item's border. +constexpr SkColor kFocusedItemBorderColor = + SkColorSetARGBMacro(0x66, 0x1A, 0x73, 0xE8); + +// Color of the focused menu item. +constexpr SkColor kFocusedItemColor = + SkColorSetARGBMacro(0x0A, 0x1A, 0x73, 0xE8); } // namespace @@ -41,8 +56,10 @@ : views::ImageButton(listener), icon_view_(new views::ImageView), title_(new views::Label) { + SetFocusBehavior(FocusBehavior::ALWAYS); + SetFocusPainter(nullptr); SetPaintToLayer(); - icon_view_->SetImage(gfx::CreateVectorIcon(icon, gfx::kChromeIconGrey)); + icon_view_->SetImage(gfx::CreateVectorIcon(icon, kItemIconColor)); AddChildView(icon_view_); title_->SetBackgroundColor(SK_ColorTRANSPARENT); @@ -54,6 +71,10 @@ title_->SetEnabledColor(kItemTitleColor); title_->SetText(title_text); AddChildView(title_); + + SetBorder(views::CreateEmptyBorder(kItemBorderThickness, kItemBorderThickness, + kItemBorderThickness, + kItemBorderThickness)); } PowerButtonMenuItemView::~PowerButtonMenuItemView() = default; @@ -74,12 +95,29 @@ } gfx::Size PowerButtonMenuItemView::CalculatePreferredSize() const { - return gfx::Size(kMenuItemWidth, kMenuItemHeight); + return gfx::Size(kMenuItemWidth + 2 * kItemBorderThickness, + kMenuItemHeight + 2 * kItemBorderThickness); +} + +void PowerButtonMenuItemView::OnFocus() { + SchedulePaint(); +} + +void PowerButtonMenuItemView::OnBlur() { + SchedulePaint(); } void PowerButtonMenuItemView::PaintButtonContents(gfx::Canvas* canvas) { views::View::OnPaint(canvas); canvas->DrawColor(SK_ColorWHITE); + if (!HasFocus() || GetContentsBounds().IsEmpty()) + return; + + SetBorder(views::CreateRoundedRectBorder(kItemBorderThickness, + kFocusedItemRoundRectRadiusDp, + kFocusedItemBorderColor)); + canvas->FillRect(GetContentsBounds(), kFocusedItemColor); + views::View::OnPaintBorder(canvas); } } // namespace ash
diff --git a/ash/system/power/power_button_menu_item_view.h b/ash/system/power/power_button_menu_item_view.h index ed348e34..22e9277 100644 --- a/ash/system/power/power_button_menu_item_view.h +++ b/ash/system/power/power_button_menu_item_view.h
@@ -26,9 +26,12 @@ class ASH_EXPORT PowerButtonMenuItemView : public views::ImageButton { public: // Height of the menu item in pixels. - static constexpr int kMenuItemHeight = 96; + static constexpr int kMenuItemHeight = 84; // Width of the menu item in pixels. - static constexpr int kMenuItemWidth = 96; + static constexpr int kMenuItemWidth = 84; + + // Thickness of the menu item's border in pixels. + static constexpr int kItemBorderThickness = 2; PowerButtonMenuItemView(views::ButtonListener* listener, const gfx::VectorIcon& icon, @@ -39,6 +42,8 @@ // views::View: void Layout() override; gfx::Size CalculatePreferredSize() const override; + void OnFocus() override; + void OnBlur() override; // views::ImageButton: void PaintButtonContents(gfx::Canvas* canvas) override;
diff --git a/ash/system/power/power_button_menu_view.cc b/ash/system/power/power_button_menu_view.cc index d3babfe..fb4a3c2 100644 --- a/ash/system/power/power_button_menu_view.cc +++ b/ash/system/power/power_button_menu_view.cc
@@ -28,6 +28,9 @@ // The amount of rounding applied to the corners of the menu view. constexpr int kMenuViewRoundRectRadiusDp = 16; +// Horizontal padding between two menu items. +constexpr int kPaddingBetweenMenuItmes = 8; + } // namespace using PowerButtonPosition = PowerButtonController::PowerButtonPosition; @@ -142,8 +145,10 @@ const gfx::Rect rect(GetContentsBounds()); gfx::Rect power_off_rect(rect); power_off_rect.set_size(power_off_item_->GetPreferredSize()); - power_off_rect.Offset( - gfx::Vector2d(kMenuItemVerticalPadding, kMenuItemHorizontalPadding)); + power_off_rect.Offset(gfx::Vector2d( + kMenuItemVerticalPadding - PowerButtonMenuItemView::kItemBorderThickness, + kMenuItemHorizontalPadding - + PowerButtonMenuItemView::kItemBorderThickness)); power_off_item_->SetBoundsRect(power_off_rect); if (sign_out_item_) { @@ -151,8 +156,11 @@ sign_out_rect.set_size(sign_out_item_->GetPreferredSize()); sign_out_rect.Offset( gfx::Vector2d(kMenuItemHorizontalPadding + - power_off_item_->GetPreferredSize().width(), - kMenuItemVerticalPadding)); + power_off_item_->GetPreferredSize().width() + + kPaddingBetweenMenuItmes - + PowerButtonMenuItemView::kItemBorderThickness, + kMenuItemVerticalPadding - + PowerButtonMenuItemView::kItemBorderThickness)); sign_out_item_->SetBoundsRect(sign_out_rect); } } @@ -177,7 +185,8 @@ 2 * kMenuItemVerticalPadding); menu_size.set_width(sign_out_item_ ? 2 * PowerButtonMenuItemView::kMenuItemWidth + - 2 * kMenuItemHorizontalPadding + 2 * kMenuItemHorizontalPadding + + kPaddingBetweenMenuItmes : PowerButtonMenuItemView::kMenuItemWidth + 2 * kMenuItemHorizontalPadding); return menu_size;
diff --git a/ash/system/power/power_button_menu_view.h b/ash/system/power/power_button_menu_view.h index c7a7c014..6566d09 100644 --- a/ash/system/power/power_button_menu_view.h +++ b/ash/system/power/power_button_menu_view.h
@@ -44,6 +44,8 @@ bool sign_out_item_for_testing() const { return sign_out_item_; } + PowerButtonMenuItemView* power_off_item() const { return power_off_item_; } + // Schedules an animation to show or hide the view. void ScheduleShowHideAnimation(bool show);
diff --git a/ash/system/power/power_button_screenshot_controller_unittest.cc b/ash/system/power/power_button_screenshot_controller_unittest.cc index 3042e724..fe03c2c 100644 --- a/ash/system/power/power_button_screenshot_controller_unittest.cc +++ b/ash/system/power/power_button_screenshot_controller_unittest.cc
@@ -187,10 +187,8 @@ // Tests volume down key can stop power button's shutdown timer and power // button menu timer. PressPowerButton(); - EXPECT_TRUE(power_button_test_api_->ShutdownTimerIsRunning()); EXPECT_TRUE(power_button_test_api_->PowerButtonMenuTimerIsRunning()); PressKey(ui::VKEY_VOLUME_DOWN); - EXPECT_FALSE(power_button_test_api_->ShutdownTimerIsRunning()); EXPECT_FALSE(power_button_test_api_->PowerButtonMenuTimerIsRunning()); ReleasePowerButton(); ReleaseKey(ui::VKEY_VOLUME_DOWN); @@ -199,11 +197,9 @@ // Tests volume up key can stop power button's shutdown timer and power button // menu timer. Also tests that volume up key is not consumed. PressPowerButton(); - EXPECT_TRUE(power_button_test_api_->ShutdownTimerIsRunning()); EXPECT_TRUE(power_button_test_api_->PowerButtonMenuTimerIsRunning()); PressKey(ui::VKEY_VOLUME_UP); EXPECT_FALSE(LastKeyConsumed()); - EXPECT_FALSE(power_button_test_api_->ShutdownTimerIsRunning()); EXPECT_FALSE(power_button_test_api_->PowerButtonMenuTimerIsRunning()); ReleasePowerButton(); ReleaseKey(ui::VKEY_VOLUME_UP); @@ -211,20 +207,19 @@ EXPECT_FALSE(LastKeyConsumed()); } -// Tests volume key pressed can not cancel the started real shutdown. +// Tests volume key pressed can not cancel the started pre-shutdown animation. TEST_F(PowerButtonScreenshotControllerTest, PowerButtonPressedFirst_VolumeKeyNotCancelPowerButton) { - // Power button shutdown behavior will turn screen off and then start the real - // shutdown. PressPowerButton(); - EXPECT_TRUE(power_button_test_api_->TriggerShutdownTimeout()); - ShutdownSoundPlayed(); - EXPECT_TRUE(lock_state_test_api_->real_shutdown_timer_is_running()); + ASSERT_TRUE(power_button_test_api_->TriggerPowerButtonMenuTimeout()); + EXPECT_TRUE(power_button_test_api_->PreShutdownTimerIsRunning()); + EXPECT_TRUE(power_button_test_api_->TriggerPreShutdownTimeout()); + EXPECT_TRUE(lock_state_test_api_->shutdown_timer_is_running()); PressKey(ui::VKEY_VOLUME_DOWN); - ReleasePowerButton(); ReleaseKey(ui::VKEY_VOLUME_DOWN); - EXPECT_TRUE(power_manager_client_->backlights_forced_off()); - EXPECT_TRUE(lock_state_test_api_->real_shutdown_timer_is_running()); + EXPECT_TRUE(lock_state_test_api_->shutdown_timer_is_running()); + ReleasePowerButton(); + EXPECT_FALSE(lock_state_test_api_->shutdown_timer_is_running()); } // Tests volume down key pressed first and meets screenshot chord condition. @@ -300,7 +295,6 @@ // Tests volume down key invalidates the power button behavior. PressKey(ui::VKEY_VOLUME_DOWN); PressPowerButton(); - EXPECT_FALSE(power_button_test_api_->ShutdownTimerIsRunning()); EXPECT_FALSE(power_button_test_api_->PowerButtonMenuTimerIsRunning()); ReleasePowerButton(); ReleaseKey(ui::VKEY_VOLUME_DOWN); @@ -311,7 +305,6 @@ PressKey(ui::VKEY_VOLUME_UP); PressPowerButton(); EXPECT_FALSE(LastKeyConsumed()); - EXPECT_FALSE(power_button_test_api_->ShutdownTimerIsRunning()); EXPECT_FALSE(power_button_test_api_->PowerButtonMenuTimerIsRunning()); ReleasePowerButton(); ReleaseKey(ui::VKEY_VOLUME_UP);
diff --git a/ash/system/power/power_button_test_base.cc b/ash/system/power/power_button_test_base.cc index adc2802..352110f39 100644 --- a/ash/system/power/power_button_test_base.cc +++ b/ash/system/power/power_button_test_base.cc
@@ -4,7 +4,6 @@ #include "ash/system/power/power_button_test_base.h" -#include "ash/accessibility/accessibility_controller.h" #include "ash/public/cpp/ash_switches.h" #include "ash/session/session_controller.h" #include "ash/session/test_session_controller_client.h" @@ -44,9 +43,6 @@ lock_state_controller_ = Shell::Get()->lock_state_controller(); lock_state_test_api_ = std::make_unique<LockStateControllerTestApi>(lock_state_controller_); - - a11y_controller_ = Shell::Get()->accessibility_controller(); - a11y_controller_->SetClient(a11y_client_.CreateInterfacePtrAndBind()); } void PowerButtonTestBase::TearDown() { @@ -148,8 +144,4 @@ base::TimeDelta::FromMilliseconds(1)); } -void PowerButtonTestBase::ShutdownSoundPlayed() { - a11y_controller_->FlushMojoForTest(); -} - } // namespace ash
diff --git a/ash/system/power/power_button_test_base.h b/ash/system/power/power_button_test_base.h index 0f80968..f96c3fe 100644 --- a/ash/system/power/power_button_test_base.h +++ b/ash/system/power/power_button_test_base.h
@@ -7,7 +7,6 @@ #include <memory> -#include "ash/accessibility/test_accessibility_controller_client.h" #include "ash/system/power/power_button_controller.h" #include "ash/test/ash_test_base.h" #include "base/test/simple_test_tick_clock.h" @@ -20,7 +19,6 @@ namespace ash { -class AccessibilityController; class LockStateController; class LockStateControllerTestApi; class PowerButtonControllerTestApi; @@ -93,9 +91,6 @@ // they come too close. void AdvanceClockToAvoidIgnoring(); - // Simulate that shutdown sound duration callback is done. - void ShutdownSoundPlayed(); - // Ownership is passed on to chromeos::DBusThreadManager. chromeos::FakePowerManagerClient* power_manager_client_ = nullptr; chromeos::FakeSessionManagerClient* session_manager_client_ = nullptr; @@ -107,8 +102,6 @@ std::unique_ptr<LockStateControllerTestApi> lock_state_test_api_; std::unique_ptr<PowerButtonControllerTestApi> power_button_test_api_; base::SimpleTestTickClock tick_clock_; - AccessibilityController* a11y_controller_; - TestAccessibilityControllerClient a11y_client_; DISALLOW_COPY_AND_ASSIGN(PowerButtonTestBase); };
diff --git a/ash/test/ash_test_helper_unittest.cc b/ash/test/ash_test_helper_unittest.cc index 056a4766..cbc4826 100644 --- a/ash/test/ash_test_helper_unittest.cc +++ b/ash/test/ash_test_helper_unittest.cc
@@ -52,7 +52,6 @@ std::unique_ptr<Widget> w1(new Widget); Widget::InitParams params; params.ownership = Widget::InitParams::WIDGET_OWNS_NATIVE_WIDGET; - params.context = ash_test_helper()->CurrentContext(); w1->Init(params); w1->Show(); EXPECT_TRUE(w1->IsActive());
diff --git a/ash/test/ash_test_views_delegate.cc b/ash/test/ash_test_views_delegate.cc index f17edbe..3cc2fe9 100644 --- a/ash/test/ash_test_views_delegate.cc +++ b/ash/test/ash_test_views_delegate.cc
@@ -2,10 +2,10 @@ // Use of this source code is governed by a BSD-style license that can be // found in the LICENSE file. -#include "ash/test/ash_test_helper.h" #include "ash/test/ash_test_views_delegate.h" #include "ash/shell.h" +#include "ash/test/ash_test_helper.h" namespace ash { @@ -18,10 +18,8 @@ views::internal::NativeWidgetDelegate* delegate) { TestViewsDelegate::OnBeforeWidgetInit(params, delegate); - if (!params->parent && !params->context && ash::Shell::HasInstance()) { - // If the window has neither a parent nor a context add to the root. - params->parent = ash::Shell::Get()->GetPrimaryRootWindow(); - } + if (!params->parent && !params->context && ash::Shell::HasInstance()) + params->context = Shell::GetRootWindowForNewWindows(); } void AshTestViewsDelegate::NotifyAccessibilityEvent(
diff --git a/ash/tooltips/tooltip_controller_unittest.cc b/ash/tooltips/tooltip_controller_unittest.cc index 2e4c7670..9b84bc08 100644 --- a/ash/tooltips/tooltip_controller_unittest.cc +++ b/ash/tooltips/tooltip_controller_unittest.cc
@@ -5,6 +5,7 @@ #include "ui/views/corewm/tooltip_controller.h" #include "ash/public/cpp/config.h" +#include "ash/public/cpp/shell_window_ids.h" #include "ash/shell.h" #include "ash/test/ash_test_base.h" #include "base/strings/utf_string_conversions.h" @@ -38,7 +39,8 @@ params.type = views::Widget::InitParams::TYPE_WINDOW_FRAMELESS; params.accept_events = true; params.ownership = views::Widget::InitParams::WIDGET_OWNS_NATIVE_WIDGET; - params.context = Shell::GetAllRootWindows().at(display); + params.parent = Shell::Get()->GetContainer( + Shell::GetAllRootWindows().at(display), kShellWindowId_DefaultContainer); params.bounds = bounds; widget->Init(params); widget->Show();
diff --git a/ash/wallpaper/wallpaper_controller.cc b/ash/wallpaper/wallpaper_controller.cc index 1b9a70c0..1491cf6 100644 --- a/ash/wallpaper/wallpaper_controller.cc +++ b/ash/wallpaper/wallpaper_controller.cc
@@ -754,21 +754,6 @@ } } -std::string WallpaperController::GetActiveUserWallpaperLocation() { - // The currently active user has index 0. - const mojom::UserSession* const active_user_session = - Shell::Get()->session_controller()->GetUserSession(0 /*user index=*/); - if (!active_user_session) - return std::string(); - - WallpaperInfo info; - if (!GetUserWallpaperInfo(active_user_session->user_info->account_id, &info, - active_user_session->user_info->is_ephemeral)) { - return std::string(); - } - return info.location; -} - void WallpaperController::OnDisplayConfigurationChanged() { gfx::Size max_display_size = GetMaxDisplaySizeInNative(); if (current_max_display_size_ != max_display_size) { @@ -1369,6 +1354,11 @@ std::move(callback).Run(IsActiveUserWallpaperControlledByPolicyImpl()); } +void WallpaperController::GetActiveUserWallpaperLocation( + GetActiveUserWallpaperLocationCallback callback) { + std::move(callback).Run(GetActiveUserWallpaperLocationImpl()); +} + void WallpaperController::ShouldShowWallpaperSetting( ShouldShowWallpaperSettingCallback callback) { std::move(callback).Run(ShouldShowWallpaperSettingImpl()); @@ -1882,7 +1872,7 @@ } } -bool WallpaperController::IsActiveUserWallpaperControlledByPolicyImpl() { +bool WallpaperController::IsActiveUserWallpaperControlledByPolicyImpl() const { // The currently active user has index 0. const mojom::UserSession* const active_user_session = Shell::Get()->session_controller()->GetUserSession(0 /*user index=*/); @@ -1892,7 +1882,22 @@ active_user_session->user_info->is_ephemeral); } -bool WallpaperController::ShouldShowWallpaperSettingImpl() { +std::string WallpaperController::GetActiveUserWallpaperLocationImpl() const { + // The currently active user has index 0. + const mojom::UserSession* const active_user_session = + Shell::Get()->session_controller()->GetUserSession(0 /*user index=*/); + if (!active_user_session) + return std::string(); + + WallpaperInfo info; + if (!GetUserWallpaperInfo(active_user_session->user_info->account_id, &info, + active_user_session->user_info->is_ephemeral)) { + return std::string(); + } + return info.location; +} + +bool WallpaperController::ShouldShowWallpaperSettingImpl() const { // The currently active user has index 0. const mojom::UserSession* const active_user_session = Shell::Get()->session_controller()->GetUserSession(0 /*user index=*/);
diff --git a/ash/wallpaper/wallpaper_controller.h b/ash/wallpaper/wallpaper_controller.h index 01dbbe7..bd13fcc 100644 --- a/ash/wallpaper/wallpaper_controller.h +++ b/ash/wallpaper/wallpaper_controller.h
@@ -235,11 +235,6 @@ // |locking| is true and remove it otherwise. void PrepareWallpaperForLockScreenChange(bool locking); - // Returns the location of the active user's wallpaper (either an URL or a - // file path). Returns an empty string if there's no active user, or the - // active user has not set a user wallpaper. - std::string GetActiveUserWallpaperLocation(); - // WindowTreeHostManager::Observer: void OnDisplayConfigurationChanged() override; @@ -357,6 +352,8 @@ void GetWallpaperColors(GetWallpaperColorsCallback callback) override; void IsActiveUserWallpaperControlledByPolicy( IsActiveUserWallpaperControlledByPolicyCallback callback) override; + void GetActiveUserWallpaperLocation( + GetActiveUserWallpaperLocationCallback callback) override; void ShouldShowWallpaperSetting( ShouldShowWallpaperSettingCallback callback) override; @@ -525,10 +522,13 @@ void OnDevicePolicyWallpaperDecoded(const gfx::ImageSkia& image); // Implementation of |IsActiveUserWallpaperControlledByPolicy|. - bool IsActiveUserWallpaperControlledByPolicyImpl(); + bool IsActiveUserWallpaperControlledByPolicyImpl() const; + + // Implementation of |GetActiveUserWallpaperLocation|. + std::string GetActiveUserWallpaperLocationImpl() const; // Implementation of |ShouldShowWallpaperSetting|. - bool ShouldShowWallpaperSettingImpl(); + bool ShouldShowWallpaperSettingImpl() const; // When wallpaper resizes, we can check which displays will be affected. For // simplicity, we only lock the compositor for the internal display.
diff --git a/ash/wm/immersive_fullscreen_controller_unittest.cc b/ash/wm/immersive_fullscreen_controller_unittest.cc index 15eac02..b659f1d5 100644 --- a/ash/wm/immersive_fullscreen_controller_unittest.cc +++ b/ash/wm/immersive_fullscreen_controller_unittest.cc
@@ -143,7 +143,6 @@ widget_ = new views::Widget(); views::Widget::InitParams params; - params.context = CurrentContext(); widget_->Init(params); widget_->Show(); @@ -865,7 +864,6 @@ views::Widget::InitParams non_transient_params; non_transient_params.ownership = views::Widget::InitParams::WIDGET_OWNS_NATIVE_WIDGET; - non_transient_params.context = top_container_widget->GetNativeView(); non_transient_params.bounds = gfx::Rect(0, 100, 100, 100); std::unique_ptr<views::Widget> non_transient_widget(new views::Widget()); non_transient_widget->Init(non_transient_params);
diff --git a/ash/wm/lock_state_controller_unittest.cc b/ash/wm/lock_state_controller_unittest.cc index 9c5b8c1..f63842f 100644 --- a/ash/wm/lock_state_controller_unittest.cc +++ b/ash/wm/lock_state_controller_unittest.cc
@@ -7,6 +7,8 @@ #include <memory> #include <utility> +#include "ash/accessibility/accessibility_controller.h" +#include "ash/accessibility/test_accessibility_controller_client.h" #include "ash/public/cpp/ash_switches.h" #include "ash/public/cpp/config.h" #include "ash/session/session_controller.h" @@ -14,6 +16,7 @@ #include "ash/shutdown_controller.h" #include "ash/shutdown_reason.h" #include "ash/system/power/power_button_controller.h" +#include "ash/system/power/power_button_controller_test_api.h" #include "ash/system/power/power_button_test_base.h" #include "ash/touch/touch_devices_controller.h" #include "ash/wm/lock_state_controller_test_api.h" @@ -80,6 +83,9 @@ test_animator_ = new TestSessionStateAnimator; lock_state_controller_->set_animator_for_test(test_animator_); lock_state_test_api_->set_shutdown_controller(&test_shutdown_controller_); + + a11y_controller_ = Shell::Get()->accessibility_controller(); + a11y_controller_->SetClient(a11y_client_.CreateInterfacePtrAndBind()); } protected: @@ -212,6 +218,22 @@ SessionStateAnimator::ANIMATION_GRAYSCALE_BRIGHTNESS)); } + void ExpectShutdownAnimationFinished() { + SCOPED_TRACE("Failure in ExpectShutdownAnimationFinished"); + EXPECT_EQ(0u, test_animator_->GetAnimationCount()); + EXPECT_FALSE(test_animator_->AreContainersAnimated( + SessionStateAnimator::ROOT_CONTAINER, + SessionStateAnimator::ANIMATION_GRAYSCALE_BRIGHTNESS)); + } + + void ExpectShutdownAnimationCancel() { + SCOPED_TRACE("Failure in ExpectShutdownAnimationCancel"); + EXPECT_LT(0u, test_animator_->GetAnimationCount()); + EXPECT_TRUE(test_animator_->AreContainersAnimated( + SessionStateAnimator::ROOT_CONTAINER, + SessionStateAnimator::ANIMATION_UNDO_GRAYSCALE_BRIGHTNESS)); + } + void ExpectWallpaperIsShowing() { SCOPED_TRACE("Failure in ExpectWallpaperIsShowing"); EXPECT_LT(0u, test_animator_->GetAnimationCount()); @@ -263,8 +285,13 @@ lock_state_controller_->OnLockScreenHide(closure); } + // Simulate that shutdown sound duration callback is done. + void ShutdownSoundPlayed() { a11y_controller_->FlushMojoForTest(); } + TestShutdownController test_shutdown_controller_; TestSessionStateAnimator* test_animator_ = nullptr; // not owned + AccessibilityController* a11y_controller_ = nullptr; // not owned + TestAccessibilityControllerClient a11y_client_; private: DISALLOW_COPY_AND_ASSIGN(LockStateControllerTest); @@ -679,4 +706,42 @@ TouchDeviceEnabledSource::GLOBAL)); } +// Tests that continue pressing the power button for a while after power menu is +// shown should trigger the cancellable pre-shutdown animation. +TEST_F(LockStateControllerTest, ShutDownAfterShowPowerMenu) { + Initialize(ButtonType::NORMAL, LoginStatus::USER); + PressPowerButton(); + EXPECT_TRUE(power_button_test_api_->IsMenuOpened()); + ASSERT_TRUE(power_button_test_api_->TriggerPreShutdownTimeout()); + EXPECT_TRUE(lock_state_test_api_->shutdown_timer_is_running()); + + ExpectShutdownAnimationStarted(); + AdvancePartially(SessionStateAnimator::ANIMATION_SPEED_SHUTDOWN, 0.5f); + // Release the power button before the shutdown timer fires. + ReleasePowerButton(); + EXPECT_FALSE(lock_state_test_api_->shutdown_timer_is_running()); + ExpectShutdownAnimationCancel(); + + power_button_controller_->DismissMenu(); + EXPECT_FALSE(power_button_test_api_->IsMenuOpened()); + + // Press the button again and make the shutdown timeout fire this time. + // Check that we start the timer for actually requesting the shutdown. + PressPowerButton(); + ASSERT_TRUE(power_button_test_api_->TriggerPreShutdownTimeout()); + EXPECT_TRUE(lock_state_test_api_->shutdown_timer_is_running()); + + Advance(SessionStateAnimator::ANIMATION_SPEED_SHUTDOWN); + ExpectShutdownAnimationFinished(); + lock_state_test_api_->trigger_shutdown_timeout(); + + ShutdownSoundPlayed(); + EXPECT_TRUE(lock_state_test_api_->real_shutdown_timer_is_running()); + EXPECT_EQ(0, NumShutdownRequests()); + + // When the timeout fires, we should request a shutdown. + lock_state_test_api_->trigger_real_shutdown_timeout(); + EXPECT_EQ(1, NumShutdownRequests()); +} + } // namespace ash
diff --git a/ash/wm/overview/cleanup_animation_observer_unittest.cc b/ash/wm/overview/cleanup_animation_observer_unittest.cc index e74e1bba..a4f2d05 100644 --- a/ash/wm/overview/cleanup_animation_observer_unittest.cc +++ b/ash/wm/overview/cleanup_animation_observer_unittest.cc
@@ -85,7 +85,6 @@ params.ownership = views::Widget::InitParams::WIDGET_OWNS_NATIVE_WIDGET; widget->Init(params); widget->Show(); - ParentWindowInPrimaryRootWindow(widget->GetNativeWindow()); widget->AddObserver(this); widget_ = widget.get(); return widget;
diff --git a/ash/wm/overview/window_selector_unittest.cc b/ash/wm/overview/window_selector_unittest.cc index 0554d4bf..06ad709 100644 --- a/ash/wm/overview/window_selector_unittest.cc +++ b/ash/wm/overview/window_selector_unittest.cc
@@ -148,7 +148,6 @@ widget->Show(); aura::Window* window = widget->GetNativeWindow(); window->SetProperty(aura::client::kTopViewInset, kHeaderHeight); - ParentWindowInPrimaryRootWindow(window); return widget; }
diff --git a/ash/wm/splitview/split_view_controller.cc b/ash/wm/splitview/split_view_controller.cc index 71cb86c..bd43cbc 100644 --- a/ash/wm/splitview/split_view_controller.cc +++ b/ash/wm/splitview/split_view_controller.cc
@@ -34,6 +34,7 @@ #include "base/metrics/user_metrics.h" #include "base/optional.h" #include "base/stl_util.h" +#include "base/sys_info.h" #include "ui/aura/client/aura_constants.h" #include "ui/aura/window.h" #include "ui/aura/window_delegate.h" @@ -153,10 +154,21 @@ // static bool SplitViewController::ShouldAllowSplitView() { - if (base::CommandLine::ForCurrentProcess()->HasSwitch( - switches::kAshDisableTabletSplitView)) { +#if defined(GOOGLE_CHROME_BUILD) + // Disable splitscreen on M66 stable channel unless it is explicity enabled by + // the user, and keep it enabled by default for all other channels on M66. + // It will be reverted later on M67. + constexpr char kChromeOSReleaseTrack[] = "CHROMEOS_RELEASE_TRACK"; + constexpr char kChromeOSStableChannelString[] = "stable-channel"; + std::string channel; + if (base::SysInfo::GetLsbReleaseValue(kChromeOSReleaseTrack, &channel) && + channel == kChromeOSStableChannelString && + !base::CommandLine::ForCurrentProcess()->HasSwitch( + switches::kAshEnableTabletSplitView)) { return false; } +#endif + if (!Shell::Get() ->tablet_mode_controller() ->IsTabletModeWindowManagerEnabled()) {
diff --git a/ash/wm/tablet_mode/tablet_mode_window_manager_unittest.cc b/ash/wm/tablet_mode/tablet_mode_window_manager_unittest.cc index ccad40a..1bc7631a 100644 --- a/ash/wm/tablet_mode/tablet_mode_window_manager_unittest.cc +++ b/ash/wm/tablet_mode/tablet_mode_window_manager_unittest.cc
@@ -109,7 +109,6 @@ aura::Window* CreateWindowWithWidget(const gfx::Rect& bounds) { views::Widget* widget = new views::Widget(); views::Widget::InitParams params; - params.context = CurrentContext(); // Note: The widget will get deleted with the window. widget->Init(params); widget->Show();
diff --git a/ash/wm/test_child_modal_parent.cc b/ash/wm/test_child_modal_parent.cc index dd1334b..b45efe1 100644 --- a/ash/wm/test_child_modal_parent.cc +++ b/ash/wm/test_child_modal_parent.cc
@@ -96,14 +96,14 @@ } // static -void TestChildModalParent::Create(aura::Window* context) { +void TestChildModalParent::Create() { Widget::CreateWindowWithContextAndBounds( - new TestChildModalParent(context), context, + new TestChildModalParent(), /*context=*/nullptr, gfx::Rect(kWindowLeft, kWindowTop, kWindowWidth, kWindowHeight)) ->Show(); } -TestChildModalParent::TestChildModalParent(aura::Window* context) +TestChildModalParent::TestChildModalParent() : widget_(std::make_unique<Widget>()), button_(new views::LabelButton( this, @@ -113,7 +113,6 @@ child_(nullptr) { Widget::InitParams params(Widget::InitParams::TYPE_CONTROL); params.ownership = Widget::InitParams::WIDGET_OWNS_NATIVE_WIDGET; - params.context = context; widget_->Init(params); widget_->GetRootView()->SetBackground( views::CreateSolidBackground(kModalParentColor));
diff --git a/ash/wm/test_child_modal_parent.h b/ash/wm/test_child_modal_parent.h index d6f3d55..843299b 100644 --- a/ash/wm/test_child_modal_parent.h +++ b/ash/wm/test_child_modal_parent.h
@@ -28,9 +28,9 @@ public views::WidgetObserver { public: // Creates the test window. - static void Create(aura::Window* context); + static void Create(); - explicit TestChildModalParent(aura::Window* context); + TestChildModalParent(); ~TestChildModalParent() override; void ShowChild();
diff --git a/ash/wm/window_modality_controller_unittest.cc b/ash/wm/window_modality_controller_unittest.cc index baeb0ec..940c9d1f 100644 --- a/ash/wm/window_modality_controller_unittest.cc +++ b/ash/wm/window_modality_controller_unittest.cc
@@ -463,9 +463,9 @@ // |child| window. // - Focus should follow the active window. TEST_F(WindowModalityControllerTest, ChildModal) { - TestChildModalParent* delegate = new TestChildModalParent(CurrentContext()); + TestChildModalParent* delegate = new TestChildModalParent(); views::Widget* widget = views::Widget::CreateWindowWithContextAndBounds( - delegate, CurrentContext(), gfx::Rect(0, 0, 400, 400)); + delegate, nullptr /* context */, gfx::Rect(0, 0, 400, 400)); widget->Show(); aura::Window* parent = widget->GetNativeView(); @@ -522,9 +522,9 @@ // Same as |ChildModal| test, but using |EventGenerator| rather than bypassing // it by calling |ActivateWindow|. TEST_F(WindowModalityControllerTest, ChildModalEventGenerator) { - TestChildModalParent* delegate = new TestChildModalParent(CurrentContext()); + TestChildModalParent* delegate = new TestChildModalParent(); views::Widget* widget = views::Widget::CreateWindowWithContextAndBounds( - delegate, CurrentContext(), gfx::Rect(0, 0, 400, 400)); + delegate, nullptr /* context */, gfx::Rect(0, 0, 400, 400)); widget->Show(); aura::Window* parent = widget->GetNativeView();
diff --git a/ash/wm/window_positioner_unittest.cc b/ash/wm/window_positioner_unittest.cc index 4539a2f..6f6fed39 100644 --- a/ash/wm/window_positioner_unittest.cc +++ b/ash/wm/window_positioner_unittest.cc
@@ -114,7 +114,6 @@ views::Widget* widget = new views::Widget(); views::Widget::InitParams params(views::Widget::InitParams::TYPE_WINDOW); params.delegate = new OutOfDisplayDelegate(widget); - params.context = Shell::GetPrimaryRootWindow(); widget->Init(params); widget->SetBounds(gfx::Rect(450, 10, 100, 100)); wm::GetWindowState(widget->GetNativeView())->set_minimum_visibility(true);
diff --git a/ash/wm/workspace/workspace_layout_manager_unittest.cc b/ash/wm/workspace/workspace_layout_manager_unittest.cc index 804db01f..5efa2ab 100644 --- a/ash/wm/workspace/workspace_layout_manager_unittest.cc +++ b/ash/wm/workspace/workspace_layout_manager_unittest.cc
@@ -295,7 +295,6 @@ views::Widget::InitParams params; params.ownership = views::Widget::InitParams::WIDGET_OWNS_NATIVE_WIDGET; params.delegate = new MaximizeDelegateView(gfx::Rect(400, 0, 30, 40)); - params.context = root_windows[0]; w1->Init(params); EXPECT_EQ(root_windows[0], w1->GetNativeWindow()->GetRootWindow()); w1->Show();
diff --git a/base/trace_event/cfi_backtrace_android.cc b/base/trace_event/cfi_backtrace_android.cc index 835a8c5d..04faf13361 100644 --- a/base/trace_event/cfi_backtrace_android.cc +++ b/base/trace_event/cfi_backtrace_android.cc
@@ -33,11 +33,13 @@ UNW_DATA table. The second table contains one or more rows for the function unwind information. -The output file starts with 4 bytes counting the size of UNW_INDEX in bytes. -Then UNW_INDEX table and UNW_DATA table. -UNW_INDEX contains one row for each function. Each row is 6 bytes long: - 4 bytes: Function start address. - 2 bytes: offset (in count of 2 bytes) of function data from start of UNW_DATA. +UNW_INDEX contains two columns of N rows each, where N is the number of +functions. + 1. First column 4 byte rows of all the function start address as offset from + start of the binary, in sorted order. + 2. For each function addr, the second column contains 2 byte indices in order. + The indices are offsets (in count of 2 bytes) of the CFI data from start of + UNW_DATA. The last entry in the table always contains CANT_UNWIND index to specify the end address of the last function. @@ -83,30 +85,6 @@ static_assert(sizeof(uintptr_t) == 4, "The unwind table format is only valid for 32 bit builds."); -// The struct that corresponds to each row in the UNW_INDEX table. The first 4 -// bytes in the row represents the address of the function w.r.t. to the start -// of the binary and the next 2 bytes have the index. The members of this struct -// is in order of the input format. We cast the memory map of the unwind table -// as an array of CFIUnwindIndexRow and use it to read data and search. So, the -// size of this struct should be 6 bytes and the order of the members is fixed -// according to the given format. -struct CFIUnwindIndexRow { - // Declare all the members of the function with size 2 bytes to make sure the - // alignment is 2 bytes and the struct is not padded to 8 bytes. The |addr_l| - // and |addr_r| represent the lower and higher 2 bytes of the function - // address. - uint16_t addr_l; - uint16_t addr_r; - - // The |index| is count in terms of 2 byte address into the UNW_DATA table, - // where the CFI data of the function exists. - uint16_t index; - - // Returns the address of the function as offset from the start of the binary, - // to which the index row corresponds to. - uintptr_t addr() const { return (addr_r << 16) | addr_l; } -}; - // The CFI data in UNW_DATA table starts with number of rows (N) and then // followed by N rows of 4 bytes long. The CFIUnwindDataRow represents a single // row of CFI data of a function in the table. Since we cast the memory at the @@ -131,10 +109,6 @@ }; static_assert( - sizeof(CFIUnwindIndexRow) == 6, - "The CFIUnwindIndexRow struct must be exactly 6 bytes for searching."); - -static_assert( sizeof(CFIUnwindDataRow) == 4, "The CFIUnwindDataRow struct must be exactly 4 bytes for searching."); @@ -173,22 +147,28 @@ if (!cfi_mmap_->Initialize(base::File(fd), cfi_region)) return; - // The first 4 bytes in the file is the size of UNW_INDEX table. The UNW_INDEX - // table contains rows of 6 bytes each. + ParseCFITables(); + can_unwind_stack_frames_ = true; +} + +void CFIBacktraceAndroid::ParseCFITables() { + // The first 4 bytes in the file is the size of UNW_INDEX table. + static constexpr size_t kUnwIndexRowSize = + sizeof(*unw_index_function_col_) + sizeof(*unw_index_indices_col_); size_t unw_index_size = 0; memcpy(&unw_index_size, cfi_mmap_->data(), sizeof(unw_index_size)); - DCHECK_EQ(0u, unw_index_size % sizeof(CFIUnwindIndexRow)); - DCHECK_GT(cfi_region.size, unw_index_size); - unw_index_start_addr_ = - reinterpret_cast<const size_t*>(cfi_mmap_->data()) + 1; - unw_index_row_count_ = unw_index_size / sizeof(CFIUnwindIndexRow); + DCHECK_EQ(0u, unw_index_size % kUnwIndexRowSize); + // UNW_INDEX table starts after 4 bytes. + unw_index_function_col_ = + reinterpret_cast<const uintptr_t*>(cfi_mmap_->data()) + 1; + unw_index_row_count_ = unw_index_size / kUnwIndexRowSize; + unw_index_indices_col_ = reinterpret_cast<const uint16_t*>( + unw_index_function_col_ + unw_index_row_count_); // The UNW_DATA table data is right after the end of UNW_INDEX table. // Interpret the UNW_DATA table as an array of 2 byte numbers since the // indexes we have from the UNW_INDEX table are in terms of 2 bytes. - unw_data_start_addr_ = reinterpret_cast<const uint16_t*>( - reinterpret_cast<uintptr_t>(unw_index_start_addr_) + unw_index_size); - can_unwind_stack_frames_ = true; + unw_data_start_addr_ = unw_index_indices_col_ + unw_index_row_count_; } size_t CFIBacktraceAndroid::Unwind(const void** out_trace, @@ -232,39 +212,37 @@ bool CFIBacktraceAndroid::FindCFIRowForPC( uintptr_t func_addr, CFIBacktraceAndroid::CFIRow* cfi) const { - // Consider the UNW_TABLE as an array of CFIUnwindIndexRow since each row - // is 6 bytes long and it contains |unw_index_size_| / 6 rows. We define - // start and end iterator on this array and use std::lower_bound() to binary - // search on this array. std::lower_bound() returns the row that corresponds - // to the first row that has address greater than the current value, since - // address is used in compartor. - const CFIUnwindIndexRow* start = - static_cast<const CFIUnwindIndexRow*>(unw_index_start_addr_); - const CFIUnwindIndexRow* end = start + unw_index_row_count_; - const CFIUnwindIndexRow to_find = {func_addr & 0xffff, func_addr >> 16, 0}; - const CFIUnwindIndexRow* found = std::lower_bound( - start, end, to_find, - [](const auto& a, const auto& b) { return a.addr() < b.addr(); }); + // Consider each column of UNW_INDEX table as arrays of uintptr_t (function + // addresses) and uint16_t (indices). Define start and end iterator on the + // first column array (addresses) and use std::lower_bound() to binary search + // on this array to find the required function address. + static const uintptr_t* const unw_index_fn_end = + unw_index_function_col_ + unw_index_row_count_; + const uintptr_t* found = + std::lower_bound(unw_index_function_col_, unw_index_fn_end, func_addr); *cfi = {0}; // If found is start, then the given function is not in the table. If the // given pc is start of a function then we cannot unwind. - if (found == start || found->addr() == func_addr) + if (found == unw_index_function_col_ || *found == func_addr) return false; - // The required row is always one less than the value returned by - // std::lower_bound(). - found--; - uintptr_t func_start_addr = found->addr(); + // std::lower_bound() returns the iter that corresponds to the first address + // that is greater than the given address. So, the required iter is always one + // less than the value returned by std::lower_bound(). + --found; + uintptr_t func_start_addr = *found; + size_t row_num = found - unw_index_function_col_; + uint16_t index = unw_index_indices_col_[row_num]; DCHECK_LE(func_start_addr, func_addr); // If the index is CANT_UNWIND then we do not have unwind infomation for the // function. - if (found->index == kCantUnwind) + if (index == kCantUnwind) return false; // The unwind data for the current function is at an offsset of the index // found in UNW_INDEX table. - const uint16_t* unwind_data = unw_data_start_addr_ + found->index; + const uint16_t* unwind_data = unw_data_start_addr_ + index; // The value of first 2 bytes is the CFI data row count for the function. uint16_t row_count = 0; memcpy(&row_count, unwind_data, sizeof(row_count));
diff --git a/base/trace_event/cfi_backtrace_android.h b/base/trace_event/cfi_backtrace_android.h index 72fcf7c..1b7369df 100644 --- a/base/trace_event/cfi_backtrace_android.h +++ b/base/trace_event/cfi_backtrace_android.h
@@ -81,6 +81,9 @@ // still reduce the total amount of address space available in process. void Initialize(); + // Finds the UNW_INDEX and UNW_DATA tables in from the CFI file memory map. + void ParseCFITables(); + // Finds the CFI row for the given |func_addr| in terms of offset from // the start of the current binary. bool FindCFIRowForPC(uintptr_t func_addr, CFIRow* out) const; @@ -94,8 +97,13 @@ // because it is replaced in tests. std::unique_ptr<MemoryMappedFile> cfi_mmap_; - // The start address of UNW_IDX table. - const void* unw_index_start_addr_ = nullptr; + // The UNW_INDEX table: Start address of the function address column. The + // memory segment corresponding to this column is treated as an array of + // uintptr_t. + const uintptr_t* unw_index_function_col_ = nullptr; + // The UNW_INDEX table: Start address of the index column. The memory segment + // corresponding to this column is treated as an array of uint16_t. + const uint16_t* unw_index_indices_col_ = nullptr; // The number of rows in UNW_INDEX table. size_t unw_index_row_count_ = 0;
diff --git a/base/trace_event/cfi_backtrace_android_unittest.cc b/base/trace_event/cfi_backtrace_android_unittest.cc index 4f84223..05e0ac2 100644 --- a/base/trace_event/cfi_backtrace_android_unittest.cc +++ b/base/trace_event/cfi_backtrace_android_unittest.cc
@@ -66,13 +66,20 @@ STACK CFI INIT 2200 10 STACK CFI 2204 .cfa: sp 44 + .ra: .cfa -8 + ^ r4: .cfa -16 + ^ */ - uint16_t input[] = {0x2A, 0x0, 0x1000, 0x0, 0x0, 0x1502, 0x0, - 0xffff, 0x2000, 0x0, 0xb, 0x2024, 0x0, 0x10, - 0x2126, 0x0, 0xffff, 0x2200, 0x0, 0x15, 0x2212, - 0x0, 0xffff, 0x5, 0x2, 0x111, 0x8, 0x220, - 0x40, 0x330, 0x50, 0x332, 0x80, 0x220, 0x2, - 0x4, 0x13, 0x8, 0x13, 0x2, 0xc, 0x33, - 0xdc, 0x40, 0x1, 0x4, 0x2e}; + uint16_t input[] = {// UNW_INDEX size + 0x2A, + + // UNW_INDEX address column (4 byte rows). + 0x0, 0x1000, 0x0, 0x1502, 0x0, 0x2000, 0x0, 0x2024, 0x0, + 0x2126, 0x0, 0x2200, 0x0, 0x2212, 0x0, + + // UNW_INDEX index column (2 byte rows). + 0x0, 0xffff, 0xb, 0x10, 0xffff, 0x15, 0xffff, + + // UNW_DATA table. + 0x5, 0x2, 0x111, 0x8, 0x220, 0x40, 0x330, 0x50, 0x332, + 0x80, 0x220, 0x2, 0x4, 0x13, 0x8, 0x13, 0x2, 0xc, 0x33, + 0xdc, 0x40, 0x1, 0x4, 0x2e}; FilePath temp_path; CreateTemporaryFile(&temp_path); EXPECT_EQ( @@ -81,11 +88,7 @@ unwinder->cfi_mmap_.reset(new MemoryMappedFile()); unwinder->cfi_mmap_->Initialize(temp_path); - unwinder->unw_index_start_addr_ = - reinterpret_cast<const size_t*>(unwinder->cfi_mmap_->data()) + 1; - unwinder->unw_index_row_count_ = input[0] / 6; - unwinder->unw_data_start_addr_ = reinterpret_cast<const uint16_t*>( - reinterpret_cast<uintptr_t>(unwinder->unw_index_start_addr_) + input[0]); + unwinder->ParseCFITables(); CFIBacktraceAndroid::CFIRow cfi_row = {0}; EXPECT_FALSE(unwinder->FindCFIRowForPC(0x00, &cfi_row));
diff --git a/build/.gitignore b/build/.gitignore index 7f487fe..bd3703c 100644 --- a/build/.gitignore +++ b/build/.gitignore
@@ -4,6 +4,7 @@ /android/bin /android/binary_size/apks/**/*.apk /config/gclient_args.gni +/cros_cache/ /Debug /Debug_x64 /goma
diff --git a/build/android/gyp/extract_unwind_tables.py b/build/android/gyp/extract_unwind_tables.py index 4f8d28ad..37a8421 100755 --- a/build/android/gyp/extract_unwind_tables.py +++ b/build/android/gyp/extract_unwind_tables.py
@@ -22,9 +22,14 @@ The output file starts with 4 bytes counting the size of UNW_INDEX in bytes. Then UNW_INDEX table and UNW_DATA table. -UNW_INDEX contains one row for each function. Each row is 6 bytes long: - 4 bytes: Function start address. - 2 bytes: offset (in count of 2 bytes) of function data from start of UNW_DATA. + +UNW_INDEX contains two columns of N rows each, where N is the number of +functions. + 1. First column 4 byte rows of all the function start address as offset from + start of the binary, in sorted order. + 2. For each function addr, the second column contains 2 byte indices in order. + The indices are offsets (in count of 2 bytes) of the CFI data from start of + UNW_DATA. The last entry in the table always contains CANT_UNWIND index to specify the end address of the last function. @@ -237,9 +242,11 @@ # Write the size of UNW_INDEX file in bytes. _Write4Bytes(out_file, len(func_addr_to_index) * 6) - # Write the UNW_INDEX table. - for addr, index in sorted(func_addr_to_index.iteritems()): + # Write the UNW_INDEX table. First list of addresses and then indices. + sorted_unw_index = sorted(func_addr_to_index.iteritems()) + for addr, index in sorted_unw_index: _Write4Bytes(out_file, addr) + for addr, index in sorted_unw_index: _Write2Bytes(out_file, index) # Write the UNW_DATA table.
diff --git a/build/android/gyp/extract_unwind_tables_tests.py b/build/android/gyp/extract_unwind_tables_tests.py index b490249..02c70eb 100755 --- a/build/android/gyp/extract_unwind_tables_tests.py +++ b/build/android/gyp/extract_unwind_tables_tests.py
@@ -92,16 +92,18 @@ # |actual_output| is in blocks of 2 bytes. Skip first 4 bytes representing # size. unw_index_start = 2 - unw_index_end = unw_index_start + unw_index_size / 2 - unw_index = actual_output[unw_index_start: unw_index_end] + unw_index_addr_end = unw_index_start + expected_function_count * 2 + unw_index_end = unw_index_addr_end + expected_function_count + unw_index_addr_col = actual_output[unw_index_start : unw_index_addr_end] + unw_index_index_col = actual_output[unw_index_addr_end : unw_index_end] unw_data_start = unw_index_end unw_data = actual_output[unw_data_start:] for func_iter in range(0, expected_function_count): - func_addr = (unw_index[func_iter * 3 + 1] << 16 | - unw_index[func_iter * 3]) - index = unw_index[func_iter * 3 + 2] + func_addr = (unw_index_addr_col[func_iter * 2 + 1] << 16 | + unw_index_addr_col[func_iter * 2]) + index = unw_index_index_col[func_iter] # If index is CANT_UNWIND then invalid function. if index == 0xFFFF: self.assertEqual(expected_cfi_data[func_addr], [])
diff --git a/build/config/android/internal_rules.gni b/build/config/android/internal_rules.gni index ea1c51f4..ad368581 100644 --- a/build/config/android/internal_rules.gni +++ b/build/config/android/internal_rules.gni
@@ -1387,6 +1387,7 @@ # possibly broken symlinks to them) get copied into the output # directory. copy_ex(_output_jar_target) { + forward_variables_from(invoker, [ "inputs" ]) deps = _deps if (defined(invoker.deps)) { deps += invoker.deps @@ -2496,6 +2497,7 @@ "main_class cannot be used for target of type ${invoker.type}") } + # The only target that might have no prebuilt and no sources is a java_binary. if (_is_prebuilt || _has_sources) { if (defined(invoker.output_name)) { _output_name = invoker.output_name @@ -2771,6 +2773,14 @@ } output_jar_path = _final_jar_path deps = _accumulated_deps + + # Although these will be listed as deps in the depfile, they must also + # appear here so that "gn analyze" knows about them. + # https://crbug.com/827197 + if (defined(invoker.proguard_configs)) { + inputs = invoker.proguard_configs + deps += _srcjar_deps # For the aapt-generated proguard rules. + } } _accumulated_deps += [ ":$_process_prebuilt_target_name" ]
diff --git a/build/config/android/rules.gni b/build/config/android/rules.gni index 5de06ce..4ff5dea 100644 --- a/build/config/android/rules.gni +++ b/build/config/android/rules.gni
@@ -1414,6 +1414,13 @@ _build_config, ] + # Although these will be listed as deps in the depfile, they must also + # appear here so that "gn analyze" knows about them. + # https://crbug.com/827197 + if (defined(invoker.proguard_configs)) { + inputs += invoker.proguard_configs + } + output_jar_path = invoker.output args = [ "--proguard-configs=@FileArg($_rebased_build_config:deps_info:proguard_all_configs)", @@ -1543,6 +1550,13 @@ _build_config, ] + # Although these will be listed as deps in the depfile, they must also + # appear here so that "gn analyze" knows about them. + # https://crbug.com/827197 + if (defined(invoker.proguard_configs)) { + inputs += invoker.proguard_configs + } + outputs = [ invoker.output, ] @@ -3254,6 +3268,9 @@ "testonly", "visibility", ]) + public_deps = [ + ":$_unpack_target_name", + ] deps = [] if (defined(_jar_target_name)) { deps += [ ":$_jar_target_name" ]
diff --git a/build/toolchain/win/setup_toolchain.py b/build/toolchain/win/setup_toolchain.py index a5f4013..00ae570 100644 --- a/build/toolchain/win/setup_toolchain.py +++ b/build/toolchain/win/setup_toolchain.py
@@ -254,6 +254,7 @@ print 'vc_lib_atlmfc_path = ' + gn_helpers.ToGNString(vc_lib_atlmfc_path) assert vc_lib_um_path print 'vc_lib_um_path = ' + gn_helpers.ToGNString(vc_lib_um_path) + print 'paths = ' + gn_helpers.ToGNString(env['PATH']) if __name__ == '__main__': main()
diff --git a/cc/paint/paint_flags.cc b/cc/paint/paint_flags.cc index e194750..d6298749 100644 --- a/cc/paint/paint_flags.cc +++ b/cc/paint/paint_flags.cc
@@ -36,7 +36,21 @@ PaintFlags::PaintFlags(PaintFlags&& other) = default; -PaintFlags::~PaintFlags() = default; +PaintFlags::~PaintFlags() { + // TODO(enne): non-default dtor to investigate http://crbug.com/790915 + + // Sanity check accessing this object doesn't crash. + CHECK_NE(blend_mode_, static_cast<uint32_t>(SkBlendMode::kLastMode) + 100); + + // Free refcounted objects one by one. + typeface_.reset(); + path_effect_.reset(); + shader_.reset(); + mask_filter_.reset(); + color_filter_.reset(); + draw_looper_.reset(); + image_filter_.reset(); +} PaintFlags& PaintFlags::operator=(const PaintFlags& other) = default;
diff --git a/cc/raster/zero_copy_raster_buffer_provider.cc b/cc/raster/zero_copy_raster_buffer_provider.cc index c17f9753..9cefe8af 100644 --- a/cc/raster/zero_copy_raster_buffer_provider.cc +++ b/cc/raster/zero_copy_raster_buffer_provider.cc
@@ -168,6 +168,7 @@ // GpuMemoryBuffer allocation can fail (https://crbug.com/554541). if (!gpu_memory_buffer_) return; + gpu_memory_buffer_->SetColorSpace(resource_color_space_); } DCHECK_EQ(1u, gfx::NumberOfPlanesForBufferFormat(
diff --git a/cc/tiles/tile_manager.cc b/cc/tiles/tile_manager.cc index 217a6ff5..57e6f13 100644 --- a/cc/tiles/tile_manager.cc +++ b/cc/tiles/tile_manager.cc
@@ -442,7 +442,7 @@ ScheduledTasksStateAsValue()); // TODO(vmpstr): Temporary check to debug crbug.com/642927. CHECK(tile_task_manager_); - signals_.ready_to_activate = true; + signals_.activate_tile_tasks_completed = true; signals_check_notifier_.Schedule(); } @@ -452,7 +452,7 @@ ScheduledTasksStateAsValue()); // TODO(vmpstr): Temporary check to debug crbug.com/642927. CHECK(tile_task_manager_); - signals_.ready_to_draw = true; + signals_.draw_tile_tasks_completed = true; signals_check_notifier_.Schedule(); } @@ -492,7 +492,7 @@ return false; } - signals_.reset(); + signals_ = Signals(); global_state_ = state; // Ensure that we don't schedule any decode work for checkered images until @@ -536,7 +536,7 @@ tile_task_manager_->CheckForCompletedTasks(); did_check_for_completed_tasks_since_last_schedule_tasks_ = true; - CheckPendingGpuWorkTiles(true /* issue_signals */, false /* flush */); + CheckPendingGpuWorkTiles(true /* issue_signals */); TRACE_EVENT_INSTANT1( "cc", "TileManager::CheckForCompletedTasksFinished", @@ -1212,7 +1212,7 @@ } void TileManager::ResetSignalsForTesting() { - signals_.reset(); + signals_ = Signals(); } void TileManager::OnRasterTaskCompleted( @@ -1357,11 +1357,13 @@ tile_task_manager_->CheckForCompletedTasks(); did_check_for_completed_tasks_since_last_schedule_tasks_ = true; - CheckPendingGpuWorkTiles(false /* issue_signals */, true /* flush */); + raster_buffer_provider_->Flush(); + CheckPendingGpuWorkTiles(false /* issue_signals */); // Ready to activate. - if (signals_.ready_to_activate && !signals_.did_notify_ready_to_activate) { - signals_.ready_to_activate = false; + if (signals_.activate_tile_tasks_completed && + signals_.activate_gpu_work_completed && + !signals_.did_notify_ready_to_activate) { if (IsReadyToActivate()) { TRACE_EVENT0(TRACE_DISABLED_BY_DEFAULT("cc.debug"), "TileManager::CheckAndIssueSignals - ready to activate"); @@ -1371,8 +1373,8 @@ } // Ready to draw. - if (signals_.ready_to_draw && !signals_.did_notify_ready_to_draw) { - signals_.ready_to_draw = false; + if (signals_.draw_tile_tasks_completed && signals_.draw_gpu_work_completed && + !signals_.did_notify_ready_to_draw) { if (IsReadyToDraw()) { TRACE_EVENT0(TRACE_DISABLED_BY_DEFAULT("cc.debug"), "TileManager::CheckAndIssueSignals - ready to draw"); @@ -1384,7 +1386,6 @@ // All tile tasks completed. if (signals_.all_tile_tasks_completed && !signals_.did_notify_all_tile_tasks_completed) { - signals_.all_tile_tasks_completed = false; if (!has_scheduled_tile_tasks_) { TRACE_EVENT0( TRACE_DISABLED_BY_DEFAULT("cc.debug"), @@ -1444,8 +1445,8 @@ CHECK(tile_task_manager_); // Schedule all checks in case we're left with solid color tiles only. - signals_.ready_to_activate = true; - signals_.ready_to_draw = true; + signals_.activate_tile_tasks_completed = true; + signals_.draw_tile_tasks_completed = true; signals_.all_tile_tasks_completed = true; signals_check_notifier_.Schedule(); @@ -1526,8 +1527,10 @@ std::unique_ptr<base::trace_event::TracedValue> state( new base::trace_event::TracedValue()); state->BeginDictionary("tasks_pending"); - state->SetBoolean("ready_to_activate", signals_.ready_to_activate); - state->SetBoolean("ready_to_draw", signals_.ready_to_draw); + state->SetBoolean("activate_tile_tasks_completed", + signals_.activate_tile_tasks_completed); + state->SetBoolean("draw_tile_tasks_completed", + signals_.draw_tile_tasks_completed); state->SetBoolean("all_tile_tasks_completed", signals_.all_tile_tasks_completed); state->EndDictionary(); @@ -1539,15 +1542,12 @@ raster_buffer_provider_->CanPartialRasterIntoProvidedResource(); } -void TileManager::CheckPendingGpuWorkTiles(bool issue_signals, bool flush) { +void TileManager::CheckPendingGpuWorkTiles(bool issue_signals) { TRACE_EVENT2("cc", "TileManager::CheckPendingGpuWorkTiles", "pending_gpu_work_tiles", pending_gpu_work_tiles_.size(), "tree_priority", TreePriorityToString(global_state_.tree_priority)); - if (flush) - raster_buffer_provider_->Flush(); - std::vector<const ResourcePool::InUsePoolResource*> required_for_activation; std::vector<const ResourcePool::InUsePoolResource*> required_for_draw; @@ -1587,7 +1587,7 @@ required_for_activation, base::Bind(&TileManager::CheckPendingGpuWorkTiles, ready_to_draw_callback_weak_ptr_factory_.GetWeakPtr(), - true /* issue_signals */, false /* flush */), + true /* issue_signals */), pending_required_for_activation_callback_id_); } @@ -1599,20 +1599,28 @@ required_for_draw, base::Bind(&TileManager::CheckPendingGpuWorkTiles, ready_to_draw_callback_weak_ptr_factory_.GetWeakPtr(), - true /* issue_signals */, false /* flush */), + true /* issue_signals */), pending_required_for_draw_callback_id_); } // Update our signals now that we know whether we have pending resources. - signals_.ready_to_activate = + signals_.activate_gpu_work_completed = (pending_required_for_activation_callback_id_ == 0); - signals_.ready_to_draw = (pending_required_for_draw_callback_id_ == 0); - - if (issue_signals && (signals_.ready_to_activate || signals_.ready_to_draw)) - signals_check_notifier_.Schedule(); + signals_.draw_gpu_work_completed = + (pending_required_for_draw_callback_id_ == 0); // We've just updated all pending tile requirements if necessary. pending_tile_requirements_dirty_ = false; + + if (!issue_signals) + return; + + bool can_activate = signals_.activate_gpu_work_completed && + signals_.activate_tile_tasks_completed; + bool can_draw = + signals_.draw_gpu_work_completed && signals_.draw_tile_tasks_completed; + if (can_activate || can_draw) + signals_check_notifier_.Schedule(); } // Utility function that can be used to create a "Task set finished" task that @@ -1753,19 +1761,6 @@ resource_count_ > limit.resource_count_; } -TileManager::Signals::Signals() { - reset(); -} - -void TileManager::Signals::reset() { - ready_to_activate = false; - did_notify_ready_to_activate = false; - ready_to_draw = false; - did_notify_ready_to_draw = false; - all_tile_tasks_completed = false; - did_notify_all_tile_tasks_completed = false; -} - TileManager::PrioritizedWorkToSchedule::PrioritizedWorkToSchedule() = default; TileManager::PrioritizedWorkToSchedule::PrioritizedWorkToSchedule( PrioritizedWorkToSchedule&& other) = default;
diff --git a/cc/tiles/tile_manager.h b/cc/tiles/tile_manager.h index 38bcea6..bb930e6c 100644 --- a/cc/tiles/tile_manager.h +++ b/cc/tiles/tile_manager.h
@@ -312,16 +312,16 @@ }; struct Signals { - Signals(); + bool activate_tile_tasks_completed = false; + bool draw_tile_tasks_completed = false; + bool all_tile_tasks_completed = false; - void reset(); + bool activate_gpu_work_completed = false; + bool draw_gpu_work_completed = false; - bool ready_to_activate; - bool did_notify_ready_to_activate; - bool ready_to_draw; - bool did_notify_ready_to_draw; - bool all_tile_tasks_completed; - bool did_notify_all_tile_tasks_completed; + bool did_notify_ready_to_activate = false; + bool did_notify_ready_to_draw = false; + bool did_notify_all_tile_tasks_completed = false; }; struct PrioritizedWorkToSchedule { @@ -391,7 +391,7 @@ bool UsePartialRaster() const; - void CheckPendingGpuWorkTiles(bool issue_signals, bool flush); + void CheckPendingGpuWorkTiles(bool issue_signals); TileManagerClient* client_; base::SequencedTaskRunner* task_runner_;
diff --git a/cc/trees/layer_tree_host_impl.cc b/cc/trees/layer_tree_host_impl.cc index 46dd9e1..fada4d0 100644 --- a/cc/trees/layer_tree_host_impl.cc +++ b/cc/trees/layer_tree_host_impl.cc
@@ -1850,6 +1850,9 @@ gfx::ScrollOffsetToVector2dF(active_tree_->TotalScrollOffset()); metadata.root_background_color = active_tree_->background_color(); metadata.is_scroll_offset_at_top = active_tree_->TotalScrollOffset().y() == 0; + + active_tree_->GetViewportSelection(&metadata.selection); + return metadata; }
diff --git a/cc/trees/layer_tree_host_impl_unittest.cc b/cc/trees/layer_tree_host_impl_unittest.cc index 7593ae0..11fac4f5 100644 --- a/cc/trees/layer_tree_host_impl_unittest.cc +++ b/cc/trees/layer_tree_host_impl_unittest.cc
@@ -14,6 +14,7 @@ #include "base/command_line.h" #include "base/location.h" #include "base/memory/ptr_util.h" +#include "base/optional.h" #include "base/run_loop.h" #include "base/test/histogram_tester.h" #include "base/threading/thread_task_runner_handle.h" @@ -13979,11 +13980,18 @@ void OnRenderFrameSubmission(RenderFrameMetadata metadata) override { if (increment_counter_) frame_token_allocator_->GetOrAllocateFrameToken(); + last_metadata_ = metadata; + } + + const base::Optional<RenderFrameMetadata>& last_metadata() const { + return last_metadata_; } private: FrameTokenAllocator* frame_token_allocator_; bool increment_counter_; + base::Optional<RenderFrameMetadata> last_metadata_; + DISALLOW_COPY_AND_ASSIGN(TestRenderFrameMetadataObserver); }; @@ -14080,5 +14088,70 @@ } } +TEST_F(LayerTreeHostImplTest, SelectionBoundsPassedToRenderFrameMetadata) { + const int root_layer_id = 1; + std::unique_ptr<SolidColorLayerImpl> root = + SolidColorLayerImpl::Create(host_impl_->active_tree(), root_layer_id); + root->SetPosition(gfx::PointF()); + root->SetBounds(gfx::Size(10, 10)); + root->SetDrawsContent(true); + root->test_properties()->force_render_surface = true; + + host_impl_->active_tree()->SetRootLayerForTesting(std::move(root)); + host_impl_->active_tree()->BuildPropertyTreesForTesting(); + + auto observer = std::make_unique<TestRenderFrameMetadataObserver>(false); + auto* observer_ptr = observer.get(); + host_impl_->SetRenderFrameObserver(std::move(observer)); + EXPECT_FALSE(observer_ptr->last_metadata()); + + // Trigger a draw-swap sequence. + host_impl_->SetNeedsRedraw(); + TestFrameData frame; + EXPECT_EQ(DRAW_SUCCESS, host_impl_->PrepareToDraw(&frame)); + EXPECT_TRUE(host_impl_->DrawLayers(&frame)); + host_impl_->DidDrawAllLayers(frame); + + // Ensure the selection bounds propagated to the render frame metadata + // represent an empty selection. + ASSERT_TRUE(observer_ptr->last_metadata()); + const viz::Selection<gfx::SelectionBound>& selection_1 = + observer_ptr->last_metadata()->selection; + EXPECT_EQ(gfx::SelectionBound::EMPTY, selection_1.start.type()); + EXPECT_EQ(gfx::SelectionBound::EMPTY, selection_1.end.type()); + EXPECT_EQ(gfx::PointF(), selection_1.start.edge_bottom()); + EXPECT_EQ(gfx::PointF(), selection_1.start.edge_top()); + EXPECT_FALSE(selection_1.start.visible()); + EXPECT_FALSE(selection_1.end.visible()); + + // Plumb the layer-local selection bounds. + gfx::Point selection_top(5, 0); + gfx::Point selection_bottom(5, 5); + LayerSelection selection; + selection.start.type = gfx::SelectionBound::CENTER; + selection.start.layer_id = root_layer_id; + selection.start.edge_bottom = selection_bottom; + selection.start.edge_top = selection_top; + selection.end = selection.start; + host_impl_->active_tree()->RegisterSelection(selection); + + // Trigger a draw-swap sequence. + host_impl_->SetNeedsRedraw(); + EXPECT_EQ(DRAW_SUCCESS, host_impl_->PrepareToDraw(&frame)); + EXPECT_TRUE(host_impl_->DrawLayers(&frame)); + host_impl_->DidDrawAllLayers(frame); + + // Ensure the selection bounds have propagated to the render frame metadata. + ASSERT_TRUE(observer_ptr->last_metadata()); + const viz::Selection<gfx::SelectionBound>& selection_2 = + observer_ptr->last_metadata()->selection; + EXPECT_EQ(selection.start.type, selection_2.start.type()); + EXPECT_EQ(selection.end.type, selection_2.end.type()); + EXPECT_EQ(gfx::PointF(selection_bottom), selection_2.start.edge_bottom()); + EXPECT_EQ(gfx::PointF(selection_top), selection_2.start.edge_top()); + EXPECT_TRUE(selection_2.start.visible()); + EXPECT_TRUE(selection_2.end.visible()); +} + } // namespace } // namespace cc
diff --git a/cc/trees/render_frame_metadata.cc b/cc/trees/render_frame_metadata.cc index def5aff1..4466cb92 100644 --- a/cc/trees/render_frame_metadata.cc +++ b/cc/trees/render_frame_metadata.cc
@@ -20,7 +20,8 @@ const RenderFrameMetadata& rfm1, const RenderFrameMetadata& rfm2) { return rfm1.root_background_color != rfm2.root_background_color || - rfm1.is_scroll_offset_at_top != rfm2.is_scroll_offset_at_top; + rfm1.is_scroll_offset_at_top != rfm2.is_scroll_offset_at_top || + rfm1.selection != rfm2.selection; } RenderFrameMetadata& RenderFrameMetadata::operator=( @@ -32,7 +33,8 @@ bool RenderFrameMetadata::operator==(const RenderFrameMetadata& other) { return root_scroll_offset == other.root_scroll_offset && root_background_color == other.root_background_color && - is_scroll_offset_at_top == other.is_scroll_offset_at_top; + is_scroll_offset_at_top == other.is_scroll_offset_at_top && + selection == other.selection; } bool RenderFrameMetadata::operator!=(const RenderFrameMetadata& other) {
diff --git a/cc/trees/render_frame_metadata.h b/cc/trees/render_frame_metadata.h index 0a6cb93..0a20fa8d 100644 --- a/cc/trees/render_frame_metadata.h +++ b/cc/trees/render_frame_metadata.h
@@ -7,8 +7,10 @@ #include "base/optional.h" #include "cc/cc_export.h" +#include "components/viz/common/quads/selection.h" #include "third_party/skia/include/core/SkColor.h" #include "ui/gfx/geometry/vector2d_f.h" +#include "ui/gfx/selection_bound.h" namespace cc { @@ -42,6 +44,10 @@ // Scroll offset of the root layer. This optional parameter is only valid // during tests. base::Optional<gfx::Vector2dF> root_scroll_offset; + + // Selection region relative to the current viewport. If the selection is + // empty or otherwise unused, the bound types will indicate such. + viz::Selection<gfx::SelectionBound> selection; }; } // namespace cc
diff --git a/chrome/android/BUILD.gn b/chrome/android/BUILD.gn index 6fe4f600..da38538a 100644 --- a/chrome/android/BUILD.gn +++ b/chrome/android/BUILD.gn
@@ -608,6 +608,7 @@ "//chrome/test/data/media/", "//chrome/test/data/navigation_interception/", "//chrome/test/data/notifications/", + "//chrome/test/data/offline_pages/", "//chrome/test/data/popup_blocker/", "//chrome/test/data/push_messaging/", "//chrome/test/data/translate/",
diff --git a/chrome/android/java/src/org/chromium/chrome/browser/ChromeTabbedActivity.java b/chrome/android/java/src/org/chromium/chrome/browser/ChromeTabbedActivity.java index e0bb19b5..7643ea50 100644 --- a/chrome/android/java/src/org/chromium/chrome/browser/ChromeTabbedActivity.java +++ b/chrome/android/java/src/org/chromium/chrome/browser/ChromeTabbedActivity.java
@@ -29,6 +29,7 @@ import android.view.Menu; import android.view.View; import android.view.View.OnClickListener; +import android.view.ViewConfiguration; import android.view.ViewGroup; import android.view.Window; import android.view.WindowManager; @@ -278,6 +279,8 @@ private AppIndexingUtil mAppIndexingUtil; + private Runnable mShowHistoryRunnable; + /** * Whether an initial tab needs to be created during UI initialization. */ @@ -2031,6 +2034,13 @@ @Override public boolean onKeyDown(int keyCode, KeyEvent event) { + // Detecting a long press of the back button via onLongPress is broken in Android N. + // To work around this, use a postDelayed, which is supported in all versions. + if (keyCode == KeyEvent.KEYCODE_BACK && !isTablet()) { + if (mShowHistoryRunnable == null) mShowHistoryRunnable = this ::showFullHistoryForTab; + mHandler.postDelayed(mShowHistoryRunnable, ViewConfiguration.getLongPressTimeout()); + return super.onKeyDown(keyCode, event); + } if (!mUIInitialized) { return super.onKeyDown(keyCode, event); } @@ -2041,6 +2051,16 @@ } @Override + public boolean onKeyUp(int keyCode, KeyEvent event) { + if (keyCode == KeyEvent.KEYCODE_BACK && !isTablet()) { + mHandler.removeCallbacks(mShowHistoryRunnable); + } + return super.onKeyUp(keyCode, event); + } + + private void showFullHistoryForTab() {} + + @Override public void onProvideKeyboardShortcuts(List<KeyboardShortcutGroup> data, Menu menu, int deviceId) { data.addAll(KeyboardShortcuts.createShortcutGroup(this));
diff --git a/chrome/android/java/src/org/chromium/chrome/browser/download/DownloadUtils.java b/chrome/android/java/src/org/chromium/chrome/browser/download/DownloadUtils.java index 82af7f71..3ea2fed4 100644 --- a/chrome/android/java/src/org/chromium/chrome/browser/download/DownloadUtils.java +++ b/chrome/android/java/src/org/chromium/chrome/browser/download/DownloadUtils.java
@@ -137,14 +137,19 @@ @Nullable Activity activity, @Nullable Tab tab, boolean showPrefetchedContent) { // Figure out what tab was last being viewed by the user. if (activity == null) activity = ApplicationStatus.getLastTrackedFocusedActivity(); + Context appContext = ContextUtils.getApplicationContext(); + boolean isTablet; if (tab == null && activity instanceof ChromeTabbedActivity) { - tab = ((ChromeTabbedActivity) activity).getActivityTab(); + ChromeTabbedActivity chromeActivity = ((ChromeTabbedActivity) activity); + tab = chromeActivity.getActivityTab(); + isTablet = chromeActivity.isTablet(); + } else { + Context displayContext = activity != null ? activity : appContext; + isTablet = DeviceFormFactor.isNonMultiDisplayContextOnTablet(displayContext); } - Context appContext = ContextUtils.getApplicationContext(); - - if (DeviceFormFactor.isNonMultiDisplayContextOnTablet(activity)) { + if (isTablet) { // Download Home shows up as a tab on tablets. LoadUrlParams params = new LoadUrlParams(UrlConstants.DOWNLOADS_URL); if (tab == null || !tab.isInitialized()) {
diff --git a/chrome/android/java/src/org/chromium/chrome/browser/infobar/AppBannerInfoBarDelegateAndroid.java b/chrome/android/java/src/org/chromium/chrome/browser/infobar/AppBannerInfoBarDelegateAndroid.java index dcda63c..b52f740f 100644 --- a/chrome/android/java/src/org/chromium/chrome/browser/infobar/AppBannerInfoBarDelegateAndroid.java +++ b/chrome/android/java/src/org/chromium/chrome/browser/infobar/AppBannerInfoBarDelegateAndroid.java
@@ -23,17 +23,17 @@ @Override public void onInstallIntentCompleted(InstallerDelegate delegate, boolean isInstalling) { - nativeOnInstallIntentReturned(mNativePointer, isInstalling); + if (mNativePointer != 0) nativeOnInstallIntentReturned(mNativePointer, isInstalling); } @Override public void onInstallFinished(InstallerDelegate delegate, boolean success) { - nativeOnInstallFinished(mNativePointer, success); + if (mNativePointer != 0) nativeOnInstallFinished(mNativePointer, success); } @Override public void onApplicationStateChanged(InstallerDelegate delegate, int newState) { - nativeUpdateInstallState(mNativePointer); + if (mNativePointer != 0) nativeUpdateInstallState(mNativePointer); } @CalledByNative
diff --git a/chrome/android/java/src/org/chromium/chrome/browser/offlinepages/OfflinePageBridge.java b/chrome/android/java/src/org/chromium/chrome/browser/offlinepages/OfflinePageBridge.java index bd5a5599..374cb55 100644 --- a/chrome/android/java/src/org/chromium/chrome/browser/offlinepages/OfflinePageBridge.java +++ b/chrome/android/java/src/org/chromium/chrome/browser/offlinepages/OfflinePageBridge.java
@@ -568,10 +568,11 @@ * @param url Url of the offline page. * @param filePath Path to the file for the offline page. * @param size Length of the offline page file. - * @param publishedCallback Function to call when publishing is done. + * @param publishedCallback Function to call when publishing is done. This will be called + * with the new path of the file. */ public void publishInternalPage(Profile profile, long offlineId, String title, String url, - String filePath, long size, Callback<OfflinePageItem> publishedCallback) { + String filePath, long size, Callback<String> publishedCallback) { nativePublishInternalPage(mNativeOfflinePageBridge, profile, offlineId, title, url, filePath, size, publishedCallback); } @@ -858,7 +859,7 @@ @VisibleForTesting private native void nativePublishInternalPage(long nativeOfflinePageBridge, Profile profile, long offlineId, String title, String url, String filePath, long size, - Callback<OfflinePageItem> publishedCallback); + Callback<String> publishedCallback); private native void nativeSelectPageForOnlineUrl( long nativeOfflinePageBridge, String onlineUrl, int tabId,
diff --git a/chrome/android/java/src/org/chromium/chrome/browser/offlinepages/OfflinePageUtils.java b/chrome/android/java/src/org/chromium/chrome/browser/offlinepages/OfflinePageUtils.java index ef043fd..c2ec827 100644 --- a/chrome/android/java/src/org/chromium/chrome/browser/offlinepages/OfflinePageUtils.java +++ b/chrome/android/java/src/org/chromium/chrome/browser/offlinepages/OfflinePageUtils.java
@@ -430,9 +430,6 @@ return false; } - // If the page is not in a public location, we cannot share it. - if (offlinePageBridge.isInPrivateDirectory(offlinePath)) return false; - return true; } @@ -453,8 +450,8 @@ public static void publishThenShareInternalPage(final Activity activity, Profile profile, OfflinePageBridge offlinePageBridge, OfflinePageItem offlinePage, final Callback<ShareParams> shareCallback) { - Callback<OfflinePageItem> publishPageCallback = - new PublishPageCallback(activity, shareCallback); + Callback<String> publishPageCallback = + new PublishPageCallback(activity, offlinePage, shareCallback); offlinePageBridge.publishInternalPage(profile, offlinePage.getOfflineId(), offlinePage.getTitle(), offlinePage.getUrl(), offlinePage.getFilePath(), offlinePage.getFileSize(), publishPageCallback);
diff --git a/chrome/android/java/src/org/chromium/chrome/browser/offlinepages/PublishPageCallback.java b/chrome/android/java/src/org/chromium/chrome/browser/offlinepages/PublishPageCallback.java index 8e5f0e9..d2569b3a 100644 --- a/chrome/android/java/src/org/chromium/chrome/browser/offlinepages/PublishPageCallback.java +++ b/chrome/android/java/src/org/chromium/chrome/browser/offlinepages/PublishPageCallback.java
@@ -14,21 +14,37 @@ * This callback will save the state we need when the JNI call is done, and start the next stage of * processing for sharing. */ -public class PublishPageCallback implements Callback<OfflinePageItem> { +public class PublishPageCallback implements Callback<String> { private Callback<ShareParams> mShareCallback; + OfflinePageItem mPage; private Activity mActivity; private static final String TAG = "PublishPageCallback"; /** Create a callback for use when page publishing is completed. */ - public PublishPageCallback(Activity activity, Callback<ShareParams> shareCallback) { + public PublishPageCallback( + Activity activity, OfflinePageItem page, Callback<ShareParams> shareCallback) { mActivity = activity; + mPage = page; mShareCallback = shareCallback; } @Override @CalledByNative /** Report results of publishing. */ - public void onResult(OfflinePageItem page) { + public void onResult(String newFilePath) { + OfflinePageItem page = null; + // If the sharing failed, the file path will be empty. We'll call the share callback + // with a null page to indicate failure. + if (!newFilePath.isEmpty()) { + // Make a new OfflinePageItem with the new path. + page = new OfflinePageItem(mPage.getUrl(), mPage.getOfflineId(), + mPage.getClientId().getNamespace(), mPage.getClientId().getId(), + mPage.getTitle(), newFilePath, mPage.getFileSize(), mPage.getCreationTimeMs(), + mPage.getAccessCount(), mPage.getLastAccessTimeMs(), mPage.getRequestOrigin()); + } + + // TODO(petewil): Sharing seems out of place here. Move the call to sharing + // back to OfflinePageUtils. OfflinePageUtils.sharePublishedPage(page, mActivity, mShareCallback); } }
diff --git a/chrome/android/java/src/org/chromium/chrome/browser/payments/PaymentRequestFactory.java b/chrome/android/java/src/org/chromium/chrome/browser/payments/PaymentRequestFactory.java index 95d25467..491b33f 100644 --- a/chrome/android/java/src/org/chromium/chrome/browser/payments/PaymentRequestFactory.java +++ b/chrome/android/java/src/org/chromium/chrome/browser/payments/PaymentRequestFactory.java
@@ -36,7 +36,7 @@ } @Override - public void show() { + public void show(boolean isUserGesture) { if (mClient != null) { mClient.onError(PaymentErrorReason.USER_CANCEL); mClient.close();
diff --git a/chrome/android/java/src/org/chromium/chrome/browser/payments/PaymentRequestImpl.java b/chrome/android/java/src/org/chromium/chrome/browser/payments/PaymentRequestImpl.java index d28e8a9..766eb13 100644 --- a/chrome/android/java/src/org/chromium/chrome/browser/payments/PaymentRequestImpl.java +++ b/chrome/android/java/src/org/chromium/chrome/browser/payments/PaymentRequestImpl.java
@@ -619,7 +619,7 @@ * Called by the merchant website to show the payment request to the user. */ @Override - public void show() { + public void show(boolean isUserGesture) { if (mClient == null) return; if (mUI != null) { @@ -660,6 +660,7 @@ mObservedTabModel.addObserver(mTabModelObserver); buildUI(chromeActivity); + if (!isUserGesture) mShouldSkipShowingPaymentRequestUi = false; if (!mShouldSkipShowingPaymentRequestUi) mUI.show(); triggerPaymentAppUiSkipIfApplicable();
diff --git a/chrome/android/java/src/org/chromium/chrome/browser/suggestions/README.md b/chrome/android/java/src/org/chromium/chrome/browser/suggestions/README.md index 55ff128..73de8e464 100644 --- a/chrome/android/java/src/org/chromium/chrome/browser/suggestions/README.md +++ b/chrome/android/java/src/org/chromium/chrome/browser/suggestions/README.md
@@ -18,8 +18,8 @@ - **Allow for radical UI changes.** The core architecture of the package should be structured to allow for flexibility and experimentation in the UI. This means it generally shouldn't be tied to any particular UI surface, and - specifically that it is flexible enough to accomodate both the NTP and Chrome - Home. + specifically that it is flexible enough to accomodate both the current NTP and + its evolutions. ## Principles @@ -145,17 +145,6 @@ - [`ContextMenuManager.Delegate`](../ntp/ContextMenuManager.java) -### BottomSheet vs NewTabPage - -The suggestions were initially only displayed on New Tab pages. They had a -fairly standard lifecycle, like other Native Pages, as an independent page -created and rendered when the user opens it. When ChromeHome is enabled, the -suggestions move to the bottom sheet and become part of the Chrome UI. - -Lifecycle differences are discussed in a -[separate document (internal)](https://docs.google.com/document/d/1roFf_B9rNj49PzaEnzh0AljKj63M7m30RlvLZ-oAt08/preview) - - ## Appendix ### Sample operations
diff --git a/chrome/android/java/src/org/chromium/chrome/browser/toolbar/CustomTabToolbar.java b/chrome/android/java/src/org/chromium/chrome/browser/toolbar/CustomTabToolbar.java index 21b0760..2e5011e9d 100644 --- a/chrome/android/java/src/org/chromium/chrome/browser/toolbar/CustomTabToolbar.java +++ b/chrome/android/java/src/org/chromium/chrome/browser/toolbar/CustomTabToolbar.java
@@ -180,18 +180,13 @@ @Override public void onNativeLibraryReady() { super.onNativeLibraryReady(); - mSecurityButton.setOnClickListener(new OnClickListener() { - @Override - public void onClick(View v) { - Tab currentTab = getToolbarDataProvider().getTab(); - if (currentTab == null || currentTab.getWebContents() == null) return; - Activity activity = currentTab.getWindowAndroid().getActivity().get(); - if (activity == null) return; - String publisherName = mState == STATE_TITLE_ONLY - ? parsePublisherNameFromUrl(currentTab.getUrl()) : null; - PageInfoPopup.show( - activity, currentTab, publisherName, PageInfoPopup.OPENED_FROM_TOOLBAR); - } + mSecurityButton.setOnClickListener(v -> { + Tab currentTab = getToolbarDataProvider().getTab(); + if (currentTab == null || currentTab.getWebContents() == null) return; + Activity activity = currentTab.getWindowAndroid().getActivity().get(); + if (activity == null) return; + PageInfoPopup.show( + activity, currentTab, getContentPublisher(), PageInfoPopup.OPENED_FROM_TOOLBAR); }); } @@ -334,10 +329,15 @@ @Override public String getContentPublisher() { - if (mState == STATE_TITLE_ONLY) { - if (getToolbarDataProvider().getTab() == null) return null; - return parsePublisherNameFromUrl(getToolbarDataProvider().getTab().getUrl()); - } + Tab tab = getToolbarDataProvider().getTab(); + if (tab == null) return null; + + String publisherUrl = tab.getTrustedCdnPublisherUrl(); + if (publisherUrl != null) return extractPublisherFromPublisherUrl(publisherUrl); + + // TODO(bauerb): Remove this once trusted CDN publisher URLs have rolled out completely. + if (mState == STATE_TITLE_ONLY) return parsePublisherNameFromUrl(tab.getUrl()); + return null; } @@ -377,6 +377,11 @@ updateSecurityIcon(); } + private static String extractPublisherFromPublisherUrl(String publisherUrl) { + return BidiFormatter.getInstance().unicodeWrap( + UrlFormatter.formatUrlForDisplayOmitScheme(GURLUtils.getOrigin(publisherUrl))); + } + @Override public void setUrlToPageUrl() { if (getCurrentTab() == null) { @@ -400,10 +405,8 @@ } CharSequence displayText; if (publisherUrl != null) { - String publisherOrigin = - UrlFormatter.formatUrlForDisplayOmitScheme(GURLUtils.getOrigin(publisherUrl)); String plainDisplayText = getContext().getString(R.string.custom_tab_amp_publisher_url, - BidiFormatter.getInstance().unicodeWrap(publisherOrigin)); + extractPublisherFromPublisherUrl(publisherUrl)); ColorStateList tint = mUseDarkColors ? mDarkModeTint : mLightModeTint; displayText = SpanApplier.applySpans(plainDisplayText, new SpanInfo("<bg>", "</bg>", new ForegroundColorSpan(tint.getDefaultColor())));
diff --git a/chrome/android/java/strings/translations/android_chrome_strings_da.xtb b/chrome/android/java/strings/translations/android_chrome_strings_da.xtb index 02ad64d..bb234f8 100644 --- a/chrome/android/java/strings/translations/android_chrome_strings_da.xtb +++ b/chrome/android/java/strings/translations/android_chrome_strings_da.xtb
@@ -724,7 +724,7 @@ <translation id="7658239707568436148">Annuller</translation> <translation id="7665369617277396874">Tilføj konto</translation> <translation id="7682724950699840886">Prøv følgende tips: Sørg for, at der er nok ledig plads på din enhed, og prøv at eksportere igen.</translation> -<translation id="7698359219371678927">Opret e-mail i <ph name="APP_NAME" /></translation> +<translation id="7698359219371678927">Opret mail i <ph name="APP_NAME" /></translation> <translation id="773466115871691567">Oversæt altid sider på <ph name="SOURCE_LANGUAGE" /></translation> <translation id="7735672056998735387"><ph name="SPACE_FREE" /> (<ph name="SPACE_OTHER" />)</translation> <translation id="7754704193130578113">Spørg, hvor hver enkelt fil skal gemmes, inden download begynder</translation> @@ -742,7 +742,7 @@ <translation id="7846076177841592234">Annuller valg</translation> <translation id="784934925303690534">Tidsinterval</translation> <translation id="7851858861565204677">Andre enheder</translation> -<translation id="7875915731392087153">Opret e-mail</translation> +<translation id="7875915731392087153">Opret mail</translation> <translation id="7876243839304621966">Fjern alt</translation> <translation id="7882131421121961860">Der blev ikke fundet nogen historik</translation> <translation id="7882806643839505685">Tillad, at et bestemt website afspiller lyd.</translation>
diff --git a/chrome/android/javatests/src/org/chromium/chrome/browser/customtabs/TrustedCdnPublisherUrlTest.java b/chrome/android/javatests/src/org/chromium/chrome/browser/customtabs/TrustedCdnPublisherUrlTest.java index 8689ce5..d6aa5325 100644 --- a/chrome/android/javatests/src/org/chromium/chrome/browser/customtabs/TrustedCdnPublisherUrlTest.java +++ b/chrome/android/javatests/src/org/chromium/chrome/browser/customtabs/TrustedCdnPublisherUrlTest.java
@@ -1,4 +1,4 @@ -// Copyright 2015 The Chromium Authors. All rights reserved. +// Copyright 2018 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. @@ -36,6 +36,7 @@ import org.chromium.base.test.util.AnnotationRule; import org.chromium.base.test.util.CommandLineFlags; import org.chromium.base.test.util.Feature; +import org.chromium.chrome.R; import org.chromium.chrome.browser.ChromeFeatureList; import org.chromium.chrome.browser.ChromeSwitches; import org.chromium.chrome.browser.firstrun.FirstRunStatus; @@ -44,6 +45,7 @@ import org.chromium.chrome.test.ChromeJUnit4ClassRunner; import org.chromium.chrome.test.util.browser.Features; import org.chromium.components.url_formatter.UrlFormatter; +import org.chromium.content.browser.test.util.TestTouchUtils; import org.chromium.net.test.util.TestWebServer; import org.chromium.ui.base.DeviceFormFactor; @@ -210,6 +212,21 @@ runTrustedCdnPublisherUrlTest( "https://example.com/test", "com.example.test", null, getDefaultSecurityIcon()); } + + @Test + @SmallTest + @Feature({"UiCatalogue"}) + @Features.EnableFeatures(ChromeFeatureList.SHOW_TRUSTED_PUBLISHER_URL) + @OverrideTrustedCdn + public void testPageInfo() throws Exception { + runTrustedCdnPublisherUrlTest("https://example.com/test", "com.example.test", "example.com", + R.drawable.omnibox_https_valid); + TestTouchUtils.performClickOnMainSync(InstrumentationRegistry.getInstrumentation(), + mCustomTabActivityTestRule.getActivity().findViewById(R.id.security_button)); + InstrumentationRegistry.getInstrumentation().waitForIdleSync(); + mScreenShooter.shoot("Page Info"); + } + // TODO(bauerb): Test an insecure HTTPS connection. private void runTrustedCdnPublisherUrlTest(@Nullable String publisherUrl, String clientPackage,
diff --git a/chrome/android/javatests/src/org/chromium/chrome/browser/offlinepages/OfflinePageUtilsTest.java b/chrome/android/javatests/src/org/chromium/chrome/browser/offlinepages/OfflinePageUtilsTest.java index 415b652..78acbc60 100644 --- a/chrome/android/javatests/src/org/chromium/chrome/browser/offlinepages/OfflinePageUtilsTest.java +++ b/chrome/android/javatests/src/org/chromium/chrome/browser/offlinepages/OfflinePageUtilsTest.java
@@ -22,6 +22,7 @@ import org.chromium.base.ThreadUtils; import org.chromium.base.test.util.CommandLineFlags; import org.chromium.base.test.util.DisabledTest; +import org.chromium.base.test.util.UrlUtils; import org.chromium.chrome.browser.ChromeActivity; import org.chromium.chrome.browser.ChromeSwitches; import org.chromium.chrome.browser.offlinepages.OfflinePageBridge.OfflinePageModelObserver; @@ -41,6 +42,7 @@ import java.util.concurrent.Semaphore; import java.util.concurrent.TimeUnit; +import java.util.concurrent.atomic.AtomicReference; /** Instrumentation tests for {@link OfflinePageUtils}. */ @RunWith(ChromeJUnit4ClassRunner.class) @@ -320,10 +322,18 @@ boolean shared = OfflinePageUtils.maybeShareOfflinePage(mActivityTestRule.getActivity(), mActivityTestRule.getActivity().getActivityTab(), shareCallback); - // The attempt to share a page from our private internal directory should fail. - Assert.assertFalse(shared); + // The attempt to share a page from our private internal directory should succeed. + Assert.assertTrue(shared); } }); + + // Wait for share callback to get called. + Assert.assertTrue(semaphore.tryAcquire(TIMEOUT_MS, TimeUnit.MILLISECONDS)); + // Assert that URI is what we expected. + String foundUri = shareCallback.getSharedUri(); + Uri uri = Uri.parse(foundUri); + String uriPath = uri.getPath(); + Assert.assertEquals(TEST_PAGE, uriPath); } // Checks on the UI thread if an offline path corresponds to a sharable file. @@ -353,9 +363,10 @@ final String privatePath = activity().getApplicationContext().getCacheDir().getPath(); final String publicPath = Environment.getExternalStorageDirectory().getPath(); - // Check that an offline page item in the private directory is not sharable. + // Check that an offline page item in the private directory is sharable, since we can + // upgrade it. final String fullPrivatePath = privatePath + CACHE_SUBDIR + NEW_FILE; - checkIfOfflinePageIsSharable(fullPrivatePath, SHARED_URI, false); + checkIfOfflinePageIsSharable(fullPrivatePath, SHARED_URI, true); // Check that an offline page item with no file path is not sharable. checkIfOfflinePageIsSharable(EMPTY_PATH, SHARED_URI, false); @@ -377,6 +388,23 @@ checkIfOfflinePageIsSharable(fullPublicPath, EMPTY_URI, false); } + @Test + @SmallTest + public void testMhtmlPropertiesFromRenderer() throws Exception { + // This gets a file:// URL which should result in an untrusted offline page. + String testUrl = UrlUtils.getTestFileUrl("offline_pages/hello.mhtml"); + mActivityTestRule.loadUrl(testUrl); + + final AtomicReference<OfflinePageItem> offlinePageItem = new AtomicReference<>(); + ThreadUtils.runOnUiThreadBlocking(() -> { + offlinePageItem.set(OfflinePageUtils.getOfflinePage( + mActivityTestRule.getActivity().getActivityTab())); + }); + + Assert.assertEquals("http://www.example.com/", offlinePageItem.get().getUrl()); + Assert.assertEquals(1321901946000L, offlinePageItem.get().getCreationTimeMs()); + } + private void loadPageAndSave(ClientId clientId) throws Exception { mTestPage = mTestServer.getURL(TEST_PAGE); mActivityTestRule.loadUrl(mTestPage);
diff --git a/chrome/android/shared_preference_files/OWNERS b/chrome/android/shared_preference_files/OWNERS new file mode 100644 index 0000000..1516dad --- /dev/null +++ b/chrome/android/shared_preference_files/OWNERS
@@ -0,0 +1,3 @@ +bsheedy@chromium.org + +per-file *.json=* \ No newline at end of file
diff --git a/chrome/app/resources/chromium_strings_da.xtb b/chrome/app/resources/chromium_strings_da.xtb index 9debac7..27a65cf 100644 --- a/chrome/app/resources/chromium_strings_da.xtb +++ b/chrome/app/resources/chromium_strings_da.xtb
@@ -205,7 +205,7 @@ Du kan forhindre <ph name="NEW_PROFILE_NAME" /> i at få adgang til din konto ved at låse din profil, når du ikke bruger Chromium. Du gør dette ved at klikke på dit profilnavn øverst til højre i browseren og vælge "Afslut, og aktivér børnesikring". <ph name="BEGIN_LINK_2" />Få flere oplysninger<ph name="END_LINK_2" /> -Gå til din e-mail på <ph name="ACCOUNT_EMAIL" /> for at få yderligere vejledning.</translation> +Gå til din mail på <ph name="ACCOUNT_EMAIL" /> for at få yderligere vejledning.</translation> <translation id="7449453770951226939"><ph name="PAGE_TITLE" /> – Chromium for udviklere</translation> <translation id="7451052299415159299">Chromium skal have tilladelse til at bruge dit kamera på dette website</translation> <translation id="7483335560992089831">Kan ikke installere den samme version af Chromium som den, der kører i øjeblikket. Luk Chromium, og prøv igen.</translation>
diff --git a/chrome/app/resources/generated_resources_am.xtb b/chrome/app/resources/generated_resources_am.xtb index bc3a6c8..a6afadaf 100644 --- a/chrome/app/resources/generated_resources_am.xtb +++ b/chrome/app/resources/generated_resources_am.xtb
@@ -51,7 +51,6 @@ <ph name="EXTENSION_NAME" /></translation> <translation id="1071917609930274619">የውሂብ ሚስጥራዊነት</translation> -<translation id="1074944608454986967">ይዘትን ጮክ ብሎ ለማንበብ ፍለጋን ተጭነው ይያዙ፣ ከዚያ ይዘትን ለመምረጥ ጠቅ ያድርጉ ወይም ይጎትቱ። አንድ ክልል ይምረጡና ፍለጋ + S ይጠቀሙ።</translation> <translation id="1076698951459398590">ገጽታን አንቃ</translation> <translation id="1076818208934827215">Microsoft Internet Explorer</translation> <translation id="1077946062898560804">ለሁሉም ተጠቃሚዎች አውቶማቲክ ዝምኖችን አዋቅር</translation> @@ -3789,7 +3788,6 @@ <translation id="6979737339423435258">የምንጊዜም</translation> <translation id="6980462514016882061">Google ፍለጋን፣ ማስታወቂያዎችን እና ሌሎች የGoogle አገልግሎቶችን ግላዊነት ለማላበስ ሲል የአሰሳ ታሪክዎን ሊጠቀም ይችላል።</translation> <translation id="6981982820502123353">ተደራሽነት</translation> -<translation id="6983201004195852174">ፍለጋን ይጫኑ እና ይያዙ፣ በመቀጠል ጮኽ ተብሎ እንዲነበብ ይዘትን ለመምረጥ ጠቅ ያድርጉ ወይም ይጎትቱ</translation> <translation id="6983783921975806247">የተመዘገበ OID</translation> <translation id="6983991971286645866">ሁሉም አርትዖቶች ወደ $1 ይቀመጣሉ።</translation> <translation id="6984299437918708277">በመግቢያ ገጹ ላይ ለመለያዎ የሚታየውን ሥዕል ይምረጡ</translation>
diff --git a/chrome/app/resources/generated_resources_ar.xtb b/chrome/app/resources/generated_resources_ar.xtb index 5cb39fe..a640f51 100644 --- a/chrome/app/resources/generated_resources_ar.xtb +++ b/chrome/app/resources/generated_resources_ar.xtb
@@ -51,7 +51,6 @@ <ph name="EXTENSION_NAME" /></translation> <translation id="1071917609930274619">تشفير البيانات</translation> -<translation id="1074944608454986967">لقراءة المحتوى جهرًا، اضغط مع الاستمرار على "بحث" ثم انقر أو اسحب لتحديد المحتوى، أو حدّد منطقة واستخدم "بحث" + S.</translation> <translation id="1076698951459398590">تمكين المظهر</translation> <translation id="1076818208934827215">Microsoft Internet Explorer</translation> <translation id="1077946062898560804">إعداد التحديثات التلقائية لجميع المستخدمين</translation> @@ -3788,7 +3787,6 @@ <translation id="6979737339423435258">جميع الأوقات</translation> <translation id="6980462514016882061">قد تستخدم Google سجل التصفح لتخصيص البحث، والإعلانات، وخدمات Google الأخرى</translation> <translation id="6981982820502123353">إمكانية الدخول</translation> -<translation id="6983201004195852174">الضغط باستمرار على البحث، ثم النقر أو السحب لتحديد المحتوى المراد قراءته بصوت عالٍ</translation> <translation id="6983783921975806247">معرّف الكائنات (OID) المسجل</translation> <translation id="6983991971286645866">سيتم حفظ جميع التعديلات مقابل 1 دولار.</translation> <translation id="6984299437918708277">اختر صورة لعرضها لحسابك في شاشة تسجيل الدخول</translation>
diff --git a/chrome/app/resources/generated_resources_bg.xtb b/chrome/app/resources/generated_resources_bg.xtb index 6c53e065..9c1eb6b 100644 --- a/chrome/app/resources/generated_resources_bg.xtb +++ b/chrome/app/resources/generated_resources_bg.xtb
@@ -51,7 +51,6 @@ <ph name="EXTENSION_NAME" /></translation> <translation id="1071917609930274619">Шифроване на данни</translation> -<translation id="1074944608454986967">За да се прочете на глас дадено съдържание, натиснете и задръжте клавиша „търсене“, след което кликнете или преместете с плъзгане, за да изберете съдържанието. Можете също да откроите определена област и да използвате „търсене“ + S.</translation> <translation id="1076698951459398590">Активиране на темата</translation> <translation id="1076818208934827215">Microsoft Internet Explorer</translation> <translation id="1077946062898560804">Настройка за автоматични актуализации за всички потребители</translation> @@ -3791,7 +3790,6 @@ <translation id="6979737339423435258">За цялото време</translation> <translation id="6980462514016882061">Възможно е да използваме историята ви на сърфиране, за да персонализираме търсенето, рекламите и други услуги на Google</translation> <translation id="6981982820502123353">Достъпност</translation> -<translation id="6983201004195852174">Натиснете и задръжте клавиша „търсене“ и кликнете или преместете с плъзгане, за да изберете съдържание, което да бъде прочетено на глас</translation> <translation id="6983783921975806247">Регистриран ИДО</translation> <translation id="6983991971286645866">Всички редакции ще се запазят в/ъв „$1“.</translation> <translation id="6984299437918708277">Изберете снимка, която да се показва за профила ви на екрана за вход</translation>
diff --git a/chrome/app/resources/generated_resources_bn.xtb b/chrome/app/resources/generated_resources_bn.xtb index bc06074..8f638bc 100644 --- a/chrome/app/resources/generated_resources_bn.xtb +++ b/chrome/app/resources/generated_resources_bn.xtb
@@ -51,7 +51,6 @@ <ph name="EXTENSION_NAME" /></translation> <translation id="1071917609930274619">ডেটা চিহ্নকরণ</translation> -<translation id="1074944608454986967">স্ক্রিনে যা দেখা যাচ্ছে তা শোনার জন্য সার্চ বোতামটি টিপে ধরে রাখুন, তারপরে কন্টেন্ট বেছে নিতে ক্লিক করুন অথবা ক্লিক করে টেনে আনুন। অথবা, একটি জায়গা হাইলাইট করে সার্চ + S টিপুন।</translation> <translation id="1076698951459398590">থিম সক্ষম করুন</translation> <translation id="1076818208934827215">Microsoft Internet Explorer</translation> <translation id="1077946062898560804">সকল ব্যবহারকারীর জন্য স্বয়ংক্রিয় আপডেটগুলো সেটআপ করুন</translation> @@ -3788,7 +3787,6 @@ <translation id="6979737339423435258">শুরু থেকে</translation> <translation id="6980462514016882061">অনুসন্ধান, বিজ্ঞাপন এবং অন্যান্য Google পরিষেবা ব্যক্তিগতকৃত করতে Google আপনার ব্রাউজিং ইতিহাস ব্যবহার করতে পারে</translation> <translation id="6981982820502123353">অ্যাক্সেযোগ্যতা</translation> -<translation id="6983201004195852174">অনুসন্ধান বোতামটি টিপে ধরে রাখুন, তারপরে যে কন্টেন্টের বিষয়ে শুনতে চান সেটিতে ক্লিক করুন বা টেনে আনুন</translation> <translation id="6983783921975806247">নিবন্ধীকৃত OID</translation> <translation id="6983991971286645866">সকল সম্পাদনা $1 এ সংরক্ষণ করা হবে।</translation> <translation id="6984299437918708277">সাইন-ইন স্ক্রীনে আপনার অ্যাকাউন্টের জন্য প্রদর্শন করাতে একটি ছবি বেছে নিন</translation>
diff --git a/chrome/app/resources/generated_resources_ca.xtb b/chrome/app/resources/generated_resources_ca.xtb index 319f327..5f61e1d 100644 --- a/chrome/app/resources/generated_resources_ca.xtb +++ b/chrome/app/resources/generated_resources_ca.xtb
@@ -51,7 +51,6 @@ <ph name="EXTENSION_NAME" /></translation> <translation id="1071917609930274619">Encriptació de dades</translation> -<translation id="1074944608454986967">Per escoltar contingut en veu alta, mantén premuda la tecla Cerca i, a continuació, fes clic al quadre o arrossega'l per seleccionar el contingut. També pots destacar una regió i prémer Cerca+S.</translation> <translation id="1076698951459398590">Activa el tema</translation> <translation id="1076818208934827215">Microsoft Internet Explorer</translation> <translation id="1077946062898560804">Configura actualitzacions automàtiques per a tots els usuaris</translation> @@ -630,7 +629,7 @@ <translation id="1956390763342388273">Es penjaran tots els fitxers que hi ha a <ph name="FOLDER_PATH" />. Fes-ho només si confies en el lloc web.</translation> <translation id="1962233722219655970">Aquesta pàgina fa servir una aplicació de Native Client que no funciona al vostre ordinador.</translation> <translation id="1962969542251276847">Bloqueja la pantalla</translation> -<translation id="1963227389609234879">Elimina-ho tot</translation> +<translation id="1963227389609234879">Esborra-ho tot</translation> <translation id="1965624977906726414">No té permisos especials.</translation> <translation id="1970368523891847084">S'ha activat el mode de vídeo</translation> <translation id="197288927597451399">Conserva</translation> @@ -3791,7 +3790,6 @@ <translation id="6979737339423435258">Sempre</translation> <translation id="6980462514016882061">És possible que Google utilitzi el vostre historial de navegació per personalitzar la Cerca, els anuncis i altres serveis de Google</translation> <translation id="6981982820502123353">Accessibilitat</translation> -<translation id="6983201004195852174">Mantén premuda la tecla Cerca i, a continuació, fes clic al quadre o arrossega'l per seleccionar el contingut que s'hagi de llegir en veu alta</translation> <translation id="6983783921975806247">OID registrat</translation> <translation id="6983991971286645866">Tots els canvis es desaran a $1.</translation> <translation id="6984299437918708277">Tria una imatge per al teu compte perquè es mostri a la pantalla d'inici de sessió</translation>
diff --git a/chrome/app/resources/generated_resources_cs.xtb b/chrome/app/resources/generated_resources_cs.xtb index 630b0a0..5b1ba44 100644 --- a/chrome/app/resources/generated_resources_cs.xtb +++ b/chrome/app/resources/generated_resources_cs.xtb
@@ -51,7 +51,6 @@ <ph name="EXTENSION_NAME" /></translation> <translation id="1071917609930274619">Šifrování dat</translation> -<translation id="1074944608454986967">Chcete-li obsah nahlas přečíst, podržte tlačítko Hledat a poté kliknutím nebo přetažením vyberte požadovaný obsah. Můžete také zvýraznit oblast a stisknout klávesy Hledat + S.</translation> <translation id="1076698951459398590">Zapnout motiv</translation> <translation id="1076818208934827215">Microsoft Internet Explorer</translation> <translation id="1077946062898560804">Nastavit automatické aktualizace pro všechny uživatele</translation> @@ -3789,7 +3788,6 @@ <translation id="6979737339423435258">Od počátku věků</translation> <translation id="6980462514016882061">Google vaši historii procházení může používat k personalizaci Vyhledávání, reklam a dalších služeb Google</translation> <translation id="6981982820502123353">Usnadnění</translation> -<translation id="6983201004195852174">Podržte tlačítko Hledat a poté kliknutím nebo přetažením vyberte obsah, který chcete nahlas přečíst</translation> <translation id="6983783921975806247">Registrovaný OID</translation> <translation id="6983991971286645866">Všechny úpravy budou uloženy do souboru $1.</translation> <translation id="6984299437918708277">Vyberte obrázek, který se pro váš účet bude zobrazovat na přihlašovací stránce</translation>
diff --git a/chrome/app/resources/generated_resources_da.xtb b/chrome/app/resources/generated_resources_da.xtb index ad27d9d7..c0a68d9 100644 --- a/chrome/app/resources/generated_resources_da.xtb +++ b/chrome/app/resources/generated_resources_da.xtb
@@ -51,7 +51,6 @@ <ph name="EXTENSION_NAME" /></translation> <translation id="1071917609930274619">Omsætning af data til kode</translation> -<translation id="1074944608454986967">Hold søgeknappen nede, og klik eller træk derefter for at vælge det indhold, der skal læses op. Du kan også fremhæve et område, og brug søgeknappen + S.</translation> <translation id="1076698951459398590">Aktivér tema</translation> <translation id="1076818208934827215">Microsoft Internet Explorer</translation> <translation id="1077946062898560804">Konfigurer automatiske opdateringer for alle brugere</translation> @@ -2159,7 +2158,7 @@ <translation id="4364567974334641491"><ph name="APP_NAME" /> deler et vindue.</translation> <translation id="4364830672918311045">Vis underretninger</translation> <translation id="4365673000813822030">Ups, synkroniseringen fungerer ikke.</translation> -<translation id="4370975561335139969">Den e-mail og adgangskode, du indtastede, stemmer ikke overens</translation> +<translation id="4370975561335139969">Den mail og adgangskode, du indtastede, stemmer ikke overens</translation> <translation id="437184764829821926">Avancerede indstillinger for skrifttype</translation> <translation id="4372884569765913867">1 x 1</translation> <translation id="4375035964737468845">Åbne downloadede filer</translation> @@ -2352,7 +2351,7 @@ <translation id="4699357559218762027">(automatisk opstart)</translation> <translation id="4707302005824653064">Forbrug og historik kan gennemgås af administratoren (<ph name="CUSTODIAN_EMAIL" />) på chrome.com.</translation> <translation id="4707579418881001319">L2TP/IPSec + brugercertifikat</translation> -<translation id="4707934200082538898">Tjek din e-mail på <ph name="BEGIN_BOLD" /><ph name="MANAGER_EMAIL" /><ph name="END_BOLD" /> for at få yderligere vejledning.</translation> +<translation id="4707934200082538898">Tjek din mail på <ph name="BEGIN_BOLD" /><ph name="MANAGER_EMAIL" /><ph name="END_BOLD" /> for at få yderligere vejledning.</translation> <translation id="4708794300267213770">Vis låseskærmen, når enheden vågner fra dvale</translation> <translation id="4708849949179781599">Afslut <ph name="PRODUCT_NAME" /></translation> <translation id="4711638718396952945">Gendan indstillinger</translation> @@ -2701,7 +2700,7 @@ <translation id="5254368820972107711">Vis de filer, der skal slettes</translation> <translation id="52550593576409946">Terminalapplikationen kunne ikke startes.</translation> <translation id="5255315797444241226">Den angivne adgangssætning er forkert.</translation> -<translation id="5260508466980570042">Din e-mail eller adgangskode blev ikke bekræftet. Prøv igen.</translation> +<translation id="5260508466980570042">Din mail eller adgangskode blev ikke bekræftet. Prøv igen.</translation> <translation id="5261683757250193089">Åbn i Webshop</translation> <translation id="5262311848634918433"><ph name="MARKUP_1" />Få adgang til filer overalt, også offline.<ph name="MARKUP_2" /> Filer i Google Drev er opdaterede og tilgængelige på alle enheder.<ph name="MARKUP_3" /> @@ -2883,7 +2882,7 @@ <translation id="5516183516694518900">Log ind på Chrome med din Google-konto for at få dine bogmærker, din historik og dine indstillinger på alle dine enheder.</translation> <translation id="551752069230578406">Føjer printer til din konto – dette kan tage et øjeblik...</translation> <translation id="5518219166343146486">Spørg om tilladelse, når et website vil se tekst og billeder, der er kopieret til udklipsholderen</translation> -<translation id="5518584115117143805">Certifikat til kryptering af e-mail</translation> +<translation id="5518584115117143805">Certifikat til kryptering af mail</translation> <translation id="5521078259930077036">Var det den startside, du forventede?</translation> <translation id="5521348028713515143">Tilføj skrivebordsgenvej</translation> <translation id="5522156646677899028">Denne udvidelse indeholder en alvorlig sikkerhedsbrist.</translation> @@ -3793,7 +3792,6 @@ <translation id="6979737339423435258">Alle browserdata</translation> <translation id="6980462514016882061">Google kan bruge din browserhistorik til at personliggøre Søgning, annoncer og andre Google-tjenester.</translation> <translation id="6981982820502123353">Hjælpefunktioner</translation> -<translation id="6983201004195852174">Hold søgeknappen nede, og klik eller træk derefter for at vælge det indhold, der skal læses op</translation> <translation id="6983783921975806247">Registreret OID</translation> <translation id="6983991971286645866">Alle ændringer gemmes i $1.</translation> <translation id="6984299437918708277">Vælg et billede, som skal vises på loginskærmen for din konto</translation> @@ -5062,7 +5060,7 @@ <translation id="9011178328451474963">Sidste fane</translation> <translation id="901440679911238150">Dine kontooplysninger er forældede. <ph name="BEGIN_LINK" />Log ind igen<ph name="END_LINK" />.</translation> <translation id="9014987600015527693">Vis en anden telefon</translation> -<translation id="901834265349196618">e-mail</translation> +<translation id="901834265349196618">mail</translation> <translation id="9019062154811256702">Læse og redigere indstillinger for autofyld</translation> <translation id="9020362265352758658">4x</translation> <translation id="9021662811137657072">Der er fundet en virus</translation> @@ -5111,7 +5109,7 @@ <translation id="9073281213608662541">PAP</translation> <translation id="9074739597929991885">Bluetooth</translation> <translation id="9074836595010225693">USB-mus er tilsluttet</translation> -<translation id="9076523132036239772">Din e-mail eller adgangskode blev ikke bekræftet. Prøv at oprette forbindelse til et netværk først.</translation> +<translation id="9076523132036239772">Din mail eller adgangskode blev ikke bekræftet. Prøv at oprette forbindelse til et netværk først.</translation> <translation id="9084064520949870008">Åbn som vindue</translation> <translation id="9088234649737575428"><ph name="PLUGIN_NAME" /> er blokeret af en virksomhedspolitik</translation> <translation id="9088917181875854783">Bekræft, at denne adgangsnøgle vises på "<ph name="DEVICE_NAME" />":</translation>
diff --git a/chrome/app/resources/generated_resources_de.xtb b/chrome/app/resources/generated_resources_de.xtb index ae0553f..0da4d5e 100644 --- a/chrome/app/resources/generated_resources_de.xtb +++ b/chrome/app/resources/generated_resources_de.xtb
@@ -51,7 +51,6 @@ <ph name="EXTENSION_NAME" /></translation> <translation id="1071917609930274619">Datenverschlüsselung</translation> -<translation id="1074944608454986967">Um sich Inhalte laut vorlesen zu lassen, halten Sie die Suchtaste gedrückt. Klicken oder ziehen Sie anschließend, um Inhalte auszuwählen. Sie können auch einen Bereich markieren und "Suchtaste" + "S" verwenden.</translation> <translation id="1076698951459398590">Design aktivieren</translation> <translation id="1076818208934827215">Internet Explorer</translation> <translation id="1077946062898560804">Automatische Updates für alle Nutzer einrichten</translation> @@ -3788,7 +3787,6 @@ <translation id="6979737339423435258">Gesamte Zeit</translation> <translation id="6980462514016882061">Mithilfe Ihres Browserverlaufs kann Google die Suche, Werbung und andere Google-Dienste personalisieren</translation> <translation id="6981982820502123353">Bedienungshilfen</translation> -<translation id="6983201004195852174">Suchtaste gedrückt halten und anschließend klicken oder ziehen, um den vorzulesenden Inhalt auszuwählen</translation> <translation id="6983783921975806247">Registrierte OID</translation> <translation id="6983991971286645866">Alle Änderungen werden in $1 gespeichert.</translation> <translation id="6984299437918708277">Wählen Sie ein Bild aus, das auf der Anmeldeseite für Ihr Konto zu sehen sein soll</translation>
diff --git a/chrome/app/resources/generated_resources_el.xtb b/chrome/app/resources/generated_resources_el.xtb index 27f16b9..7d66000 100644 --- a/chrome/app/resources/generated_resources_el.xtb +++ b/chrome/app/resources/generated_resources_el.xtb
@@ -51,7 +51,6 @@ <ph name="EXTENSION_NAME" /></translation> <translation id="1071917609930274619">Κρυπτογράφηση δεδομένων</translation> -<translation id="1074944608454986967">Για να γίνει ανάγνωση του περιεχόμενου δυνατά, πιέστε παρατεταμένα την Αναζήτηση και, έπειτα, κάντε κλικ ή σύρετε, για να επιλέξετε το περιεχόμενο. Εναλλακτικά επισημάνετε μια περιοχή και χρησιμοποιήστε τα πλήκτρα Αναζήτηση + S.</translation> <translation id="1076698951459398590">Ενεργοποίηση θέματος</translation> <translation id="1076818208934827215">Microsoft Internet Explorer</translation> <translation id="1077946062898560804">Ρύθμιση αυτόματων ενημερώσεων για όλους τους χρήστες</translation> @@ -3794,7 +3793,6 @@ <translation id="6979737339423435258">Από την αρχή</translation> <translation id="6980462514016882061">Η Google μπορεί να χρησιμοποιεί το ιστορικό περιήγησής σας για την εξατομίκευση της Αναζήτησης, των διαφημίσεων και άλλων υπηρεσιών Google</translation> <translation id="6981982820502123353">Προσβασιμότητα</translation> -<translation id="6983201004195852174">Πιέστε παρατεταμένα την Αναζήτηση και, έπειτα, κάντε κλικ ή σύρετε, για να επιλέξετε το περιεχόμενο που θα εκφωνηθεί</translation> <translation id="6983783921975806247">Εγγεγραμμένο OID</translation> <translation id="6983991971286645866">Όλες οι τροποποιήσεις θα αποθηκευτούν στο $1.</translation> <translation id="6984299437918708277">Επιλέξτε μια εικόνα που θα εμφανίζεται για τον λογαριασμό σας στην οθόνη σύνδεσης</translation>
diff --git a/chrome/app/resources/generated_resources_en-GB.xtb b/chrome/app/resources/generated_resources_en-GB.xtb index d827612..d85c19d 100644 --- a/chrome/app/resources/generated_resources_en-GB.xtb +++ b/chrome/app/resources/generated_resources_en-GB.xtb
@@ -51,7 +51,6 @@ <ph name="EXTENSION_NAME" /></translation> <translation id="1071917609930274619">Data Encipherment</translation> -<translation id="1074944608454986967">To read content aloud, press and hold Search, then click or drag to select content; or highlight a region and use Search + S.</translation> <translation id="1076698951459398590">Enable Theme</translation> <translation id="1076818208934827215">Microsoft Internet Explorer</translation> <translation id="1077946062898560804">Set Up Automatic Updates for All Users</translation> @@ -3792,7 +3791,6 @@ <translation id="6979737339423435258">All time</translation> <translation id="6980462514016882061">Google may use your browsing history to personalise Search, ads and other Google services</translation> <translation id="6981982820502123353">Accessibility</translation> -<translation id="6983201004195852174">Press and hold Search, then click or drag to select content to be read aloud</translation> <translation id="6983783921975806247">Registered OID</translation> <translation id="6983991971286645866">All edits will be saved to $1.</translation> <translation id="6984299437918708277">Choose a picture to display for your account on the sign-in screen</translation>
diff --git a/chrome/app/resources/generated_resources_es-419.xtb b/chrome/app/resources/generated_resources_es-419.xtb index 3234fd8..01694c1 100644 --- a/chrome/app/resources/generated_resources_es-419.xtb +++ b/chrome/app/resources/generated_resources_es-419.xtb
@@ -51,7 +51,6 @@ <ph name="EXTENSION_NAME" /></translation> <translation id="1071917609930274619">Cifrado de datos</translation> -<translation id="1074944608454986967">Para leer el contenido en voz alta, mantén presionado el botón de búsqueda y, luego, haz clic en el contenido o arrastra el cursor para seleccionarlo. O bien, destaca una parte y presiona Búsqueda + S.</translation> <translation id="1076698951459398590">Habilitar tema</translation> <translation id="1076818208934827215">Microsoft Internet Explorer</translation> <translation id="1077946062898560804">Configurar actualizaciones automáticas para todos los usuarios</translation> @@ -3789,7 +3788,6 @@ <translation id="6979737339423435258">Todos</translation> <translation id="6980462514016882061">Es posible que Google use tu historial de navegación para personalizar Búsqueda, Ads y otros servicios de Google</translation> <translation id="6981982820502123353">Accesibilidad</translation> -<translation id="6983201004195852174">Mantén presionado el botón de búsqueda, luego, haz clic en el contenido o arrástralo para seleccionarlo y que se lea en voz alta</translation> <translation id="6983783921975806247">OID registrado</translation> <translation id="6983991971286645866">Todas las modificaciones se guardarán en $1.</translation> <translation id="6984299437918708277">Selecciona una imagen para mostrar en tu cuenta, en la pantalla de inicio</translation>
diff --git a/chrome/app/resources/generated_resources_es.xtb b/chrome/app/resources/generated_resources_es.xtb index 73cfb7e..3f698f29 100644 --- a/chrome/app/resources/generated_resources_es.xtb +++ b/chrome/app/resources/generated_resources_es.xtb
@@ -51,7 +51,6 @@ <ph name="EXTENSION_NAME" /></translation> <translation id="1071917609930274619">Cifrado de datos</translation> -<translation id="1074944608454986967">Para leer el contenido en voz alta, mantén pulsada la tecla de búsqueda y haz clic o arrastra el cursor para seleccionar contenido. También puedes resaltar una zona y pulsar la tecla de búsqueda + S.</translation> <translation id="1076698951459398590">Habilitar tema</translation> <translation id="1076818208934827215">Microsoft Internet Explorer</translation> <translation id="1077946062898560804">Configurar actualizaciones automáticas para todos los usuarios</translation> @@ -3789,7 +3788,6 @@ <translation id="6979737339423435258">Desde siempre</translation> <translation id="6980462514016882061">Google puede utilizar tu historial de navegación para personalizar la Búsqueda, los anuncios y otros servicios de Google</translation> <translation id="6981982820502123353">Accesibilidad</translation> -<translation id="6983201004195852174">Mantén pulsada la tecla de búsqueda y haz clic en el contenido o arrastra el cursor para que se lea en voz alta.</translation> <translation id="6983783921975806247">OID registrado</translation> <translation id="6983991971286645866">Todos los cambios se guardarán en $1.</translation> <translation id="6984299437918708277">Selecciona la imagen de tu cuenta que quieres mostrar en la pantalla de inicio de sesión</translation>
diff --git a/chrome/app/resources/generated_resources_et.xtb b/chrome/app/resources/generated_resources_et.xtb index 19e314b..72543bc 100644 --- a/chrome/app/resources/generated_resources_et.xtb +++ b/chrome/app/resources/generated_resources_et.xtb
@@ -51,7 +51,6 @@ <ph name="EXTENSION_NAME" /></translation> <translation id="1071917609930274619">Andmete šifreerimine</translation> -<translation id="1074944608454986967">Sisu ettelugemiseks vajutage pikalt otsinguklahvi ja klõpsake või lohistage sisu valimiseks. Võite ka piirkonna esile tõsta ja kasutada klahvikombinatsiooni Otsing + S.</translation> <translation id="1076698951459398590">Luba teema</translation> <translation id="1076818208934827215">Microsoft Internet Explorer</translation> <translation id="1077946062898560804">Automaatsete värskenduste seadistamine kõikidele kasutajatele</translation> @@ -3792,7 +3791,6 @@ <translation id="6979737339423435258">Algusest</translation> <translation id="6980462514016882061">Google võib kasutada teie sirvimisajalugu otsingu, reklaamide ja muude Google'i teenuste isikupärastamiseks</translation> <translation id="6981982820502123353">Juurdepääsetavus</translation> -<translation id="6983201004195852174">Vajutage pikalt otsinguklahvi ja klõpsake sisu valimiseks või lohistage sellele, et see ette lugeda</translation> <translation id="6983783921975806247">Registreeritud OID</translation> <translation id="6983991971286645866">Kõik muudatused salvestatakse koopiasse $1.</translation> <translation id="6984299437918708277">Valige pilt, mis konto sisselogimisekraanil kuvada</translation>
diff --git a/chrome/app/resources/generated_resources_fa.xtb b/chrome/app/resources/generated_resources_fa.xtb index 6fb135b5..2d4c719 100644 --- a/chrome/app/resources/generated_resources_fa.xtb +++ b/chrome/app/resources/generated_resources_fa.xtb
@@ -51,7 +51,6 @@ <ph name="EXTENSION_NAME" /></translation> <translation id="1071917609930274619">به رمز درآوردن داده</translation> -<translation id="1074944608454986967">برای اینکه محتوا بلند خوانده شود، «جستجو» را فشار دهید و نگهدارید. سپس برای انتخاب محتوای موردنظر کلیک کنید یا بکشید. یا قسمتی را برجسته کنید و از «جستجو» + S استفاده کنید.</translation> <translation id="1076698951459398590">فعال کردن طرح زمینه</translation> <translation id="1076818208934827215">Microsoft Internet Explorer</translation> <translation id="1077946062898560804">راهاندازی بهروزرسانیهای خودکار برای همه کاربرها</translation> @@ -3788,7 +3787,6 @@ <translation id="6979737339423435258">همه زمانها</translation> <translation id="6980462514016882061">Google ممکن است از سابقه مرور شما برای شخصیسازی جستجو، آگهیها و سایر سرویسهای Google استفاده کند</translation> <translation id="6981982820502123353">قابلیت دسترسی</translation> -<translation id="6983201004195852174">«جستجو» را فشار دهید و نگهدارید، سپس برای اینکه محتوایی را انتخاب کنید تا بلند خوانده شود، کلیک کنید یا بکشید</translation> <translation id="6983783921975806247">OID ثبت شده</translation> <translation id="6983991971286645866">همه ویرایشها در $1 ذخیره میشوند.</translation> <translation id="6984299437918708277">تصویری انتخاب کنید تا برای حساب شما در صفحه ورود به سیستم نشان داده شود</translation>
diff --git a/chrome/app/resources/generated_resources_fi.xtb b/chrome/app/resources/generated_resources_fi.xtb index 460d217d..3606d3f6 100644 --- a/chrome/app/resources/generated_resources_fi.xtb +++ b/chrome/app/resources/generated_resources_fi.xtb
@@ -51,7 +51,6 @@ <ph name="EXTENSION_NAME" /></translation> <translation id="1071917609930274619">Tiedon salakoodaus</translation> -<translation id="1074944608454986967">Jos haluat lukea sisältöä ääneen, pidä hakupainiketta painettuna ja valitse ääneen luettava sisältö klikkaamalla tai vetämällä. Voit myös korostaa alueen ja valita Haku + S.</translation> <translation id="1076698951459398590">Ota teema käyttöön</translation> <translation id="1076818208934827215">Microsoft Internet Explorer</translation> <translation id="1077946062898560804">Ota käyttöön automaattiset päivitykset kaikille käyttäjille</translation> @@ -3792,7 +3791,6 @@ <translation id="6979737339423435258">Kaikki</translation> <translation id="6980462514016882061">Google voi muokata hakua, mainoksia ja muita Googlen palveluita selaushistoriasi perusteella.</translation> <translation id="6981982820502123353">Esteettömyys</translation> -<translation id="6983201004195852174">Pidä hakupainiketta painettuna, ja valitse ääneen luettava sisältö klikkaamalla tai vetämällä.</translation> <translation id="6983783921975806247">Rekisteröity OID</translation> <translation id="6983991971286645866">Kaikki muokkaukset tallennetaan kohteeseen $1.</translation> <translation id="6984299437918708277">Valitse kirjautumisnäytöllä näytettävä tilisi kuvake.</translation>
diff --git a/chrome/app/resources/generated_resources_fil.xtb b/chrome/app/resources/generated_resources_fil.xtb index 1744fd2..bbd19751 100644 --- a/chrome/app/resources/generated_resources_fil.xtb +++ b/chrome/app/resources/generated_resources_fil.xtb
@@ -51,7 +51,6 @@ <ph name="EXTENSION_NAME" /></translation> <translation id="1071917609930274619">Pag-encipher ng Data</translation> -<translation id="1074944608454986967">Upang basahin ang content nang malakas, i-press nang matagal ang Maghanap, pagkatapos ay i-click o i-drag upang pumili ng content. O kaya, mag-highlight ng rehiyon at gamitin ang Maghanap + S.</translation> <translation id="1076698951459398590">I-enable ang Tema</translation> <translation id="1076818208934827215">Microsoft Internet Explorer</translation> <translation id="1077946062898560804">Mag-Set up ng Mga Awtomatikong Update para sa Lahat ng Mga User</translation> @@ -3792,7 +3791,6 @@ <translation id="6979737339423435258">Lahat ng oras</translation> <translation id="6980462514016882061">Maaaring gamitin ng Google ang iyong history ng pagba-browse upang i-personalize ang Search, mga ad at iba pang mga serbisyo ng Google</translation> <translation id="6981982820502123353">Pagiging Maa-access</translation> -<translation id="6983201004195852174">Pindutin nang matagal ang Paghahanap, pagkatapos ay mag-click o mag-drag upang pumili ng content na babasahin nang malakas</translation> <translation id="6983783921975806247">Nakarehistrong OID</translation> <translation id="6983991971286645866">Ise-save ang lahat ng pag-edit sa $1.</translation> <translation id="6984299437918708277">Pumili ng larawang ipapakita para sa iyong account sa screen ng pag-sign in</translation>
diff --git a/chrome/app/resources/generated_resources_fr.xtb b/chrome/app/resources/generated_resources_fr.xtb index c54655c..3ae3824 100644 --- a/chrome/app/resources/generated_resources_fr.xtb +++ b/chrome/app/resources/generated_resources_fr.xtb
@@ -51,7 +51,6 @@ <ph name="EXTENSION_NAME" /></translation> <translation id="1071917609930274619">Chiffrement des données</translation> -<translation id="1074944608454986967">Appuyez de manière prolongée sur la touche de recherche, puis cliquez sur le contenu de votre choix ou faites-le glisser pour entendre ce qui est écrit. Vous pouvez aussi mettre en surbrillance une zone, puis appuyer sur la touche de recherche+S.</translation> <translation id="1076698951459398590">Activer le thème</translation> <translation id="1076818208934827215">Microsoft Internet Explorer</translation> <translation id="1077946062898560804">Configurer les mises à jour automatiques pour tous les utilisateurs</translation> @@ -3793,7 +3792,6 @@ <translation id="6979737339423435258">Toutes les périodes</translation> <translation id="6980462514016882061">Google peut utiliser votre historique de navigation pour personnaliser la recherche, les annonces et d'autres services Google.</translation> <translation id="6981982820502123353">Accessibilité</translation> -<translation id="6983201004195852174">Appuyez de manière prolongée sur Rechercher, puis cliquez sur le contenu de votre choix ou faites-le glisser pour entendre ce qui est écrit</translation> <translation id="6983783921975806247">OID enregistré</translation> <translation id="6983991971286645866">Toutes les modifications seront enregistrées dans le fichier $1.</translation> <translation id="6984299437918708277">Choisissez une image à associer à votre compte, laquelle s'affichera sur l'écran de connexion</translation>
diff --git a/chrome/app/resources/generated_resources_gu.xtb b/chrome/app/resources/generated_resources_gu.xtb index d4848df..3dc340c2 100644 --- a/chrome/app/resources/generated_resources_gu.xtb +++ b/chrome/app/resources/generated_resources_gu.xtb
@@ -51,7 +51,6 @@ <ph name="EXTENSION_NAME" /></translation> <translation id="1071917609930274619">ડેટા ચિહ્નિકરણ</translation> -<translation id="1074944608454986967">કન્ટેન્ટને મોટેથી વાંચવા માટે, શોધોને દબાવી રાખો, પછી કન્ટેન્ટ પસંદ કરવા માટે ક્લિક કરો અથવા ખેંચો. અથવા ક્ષેત્રને હાઇલાઇટ કરો અને શોધો + S નો ઉપયોગ કરો.</translation> <translation id="1076698951459398590">થીમ સક્ષમ કરો</translation> <translation id="1076818208934827215">Microsoft Internet Explorer</translation> <translation id="1077946062898560804">બધા વપરાશકર્તા માટે સ્વચાલિત અપડેટ્સ સેટ કરો</translation> @@ -3778,7 +3777,6 @@ <translation id="6979737339423435258">હંમેશાં</translation> <translation id="6980462514016882061">શોધ, જાહેરાતો અને અન્ય Google સેવાઓને વ્યક્તિગત કરવા માટે Google, તમારા બ્રાઉઝિંગ ઇતિહાસનો ઉપયોગ કરી શકે છે</translation> <translation id="6981982820502123353">ઍક્સેસિબિલિટી</translation> -<translation id="6983201004195852174">શોધો દબાવો અને પકડી રાખો, પછી મોટેથી વાંચવાનું કન્ટેન્ટ પસંદ કરવા માટે ક્લિક કરો અથવા ખેંચો</translation> <translation id="6983783921975806247">નોંધાયેલ OID</translation> <translation id="6983991971286645866">બધા સંપાદનો $1 પર સાચવવામાં આવશે.</translation> <translation id="6984299437918708277">સાઇન-ઇન સ્ક્રીન પર તમારા એકાઉન્ટ માટે પ્રદર્શિત કરવા માટેનું ચિત્ર પસંદ કરો</translation>
diff --git a/chrome/app/resources/generated_resources_hi.xtb b/chrome/app/resources/generated_resources_hi.xtb index af8aff9..f52c2476 100644 --- a/chrome/app/resources/generated_resources_hi.xtb +++ b/chrome/app/resources/generated_resources_hi.xtb
@@ -51,7 +51,6 @@ <ph name="EXTENSION_NAME" /></translation> <translation id="1071917609930274619">डेटा कूटलेखन</translation> -<translation id="1074944608454986967">सामग्री को ज़ोर से पढ़ने के लिए, खोजें को दबाकर रखें, उसके बाद सामग्री चुनने के लिए उस पर क्लिक करें या खींचें और छोड़ें. या किसी क्षेत्र को हाइलाइट करें और Search + S का इस्तेमाल करें.</translation> <translation id="1076698951459398590">थीम सक्षम करें</translation> <translation id="1076818208934827215">Microsoft Internet Explorer</translation> <translation id="1077946062898560804">सभी उपयोगकर्ताओं के लिए स्वचालित अपडेट सेट करें</translation> @@ -3791,7 +3790,6 @@ <translation id="6979737339423435258">हमेशा</translation> <translation id="6980462514016882061">खोज, विज्ञापन और अन्य Google सेवाओं को वैयक्तिकृत करने के लिए Google आपके ब्राउज़िंग इतिहास का उपयोग कर सकता है</translation> <translation id="6981982820502123353">पहुंच क्षमता</translation> -<translation id="6983201004195852174">खोजें को दबाकर रखें, उसके बाद ज़ोर से पढ़ी जाने वाली सामग्री चुनने के लिए क्लिक करें या खींचें</translation> <translation id="6983783921975806247">पंजीकृत OID</translation> <translation id="6983991971286645866">सभी संपादन $1 पर सहेजे जाएंगे.</translation> <translation id="6984299437918708277">प्रवेश स्क्रीन पर अपने खाते के लिए प्रदर्शित किया जाने वाला चित्र चुनें</translation>
diff --git a/chrome/app/resources/generated_resources_hr.xtb b/chrome/app/resources/generated_resources_hr.xtb index 67f28533..7ea886a 100644 --- a/chrome/app/resources/generated_resources_hr.xtb +++ b/chrome/app/resources/generated_resources_hr.xtb
@@ -51,7 +51,6 @@ <ph name="EXTENSION_NAME" /></translation> <translation id="1071917609930274619">Šifriranje podataka</translation> -<translation id="1074944608454986967">Za čitanje sadržaja naglas pritisnite i zadržite tipku za pretraživanje, a zatim kliknite ili povucite sadržaj. Možete i istaknuti područje i pritisnuti tipku za pretraživanje i S.</translation> <translation id="1076698951459398590">Omogući temu</translation> <translation id="1076818208934827215">Microsoft Internet Explorer</translation> <translation id="1077946062898560804">Postavi automatsko ažuriranje za sve korisnike</translation> @@ -3792,7 +3791,6 @@ <translation id="6979737339423435258">Cijelo vrijeme</translation> <translation id="6980462514016882061">Google može upotrebljavati vašu povijest pregledavanja za prilagodbu Pretraživanja, oglasa i drugih Googleovih usluga</translation> <translation id="6981982820502123353">Pristupačnost</translation> -<translation id="6983201004195852174">Pritisnite i zadržite Pretraživanje, a zatim kliknite ili povucite da biste odabrali sadržaj za čitanje naglas</translation> <translation id="6983783921975806247">Registrirani OID</translation> <translation id="6983991971286645866">Sva uređivanja spremit će se u $1.</translation> <translation id="6984299437918708277">Odaberite sliku za prikaz za svoj račun na zaslonu za prijavu</translation>
diff --git a/chrome/app/resources/generated_resources_hu.xtb b/chrome/app/resources/generated_resources_hu.xtb index 1b4c23f..a8350c1b 100644 --- a/chrome/app/resources/generated_resources_hu.xtb +++ b/chrome/app/resources/generated_resources_hu.xtb
@@ -51,7 +51,6 @@ <ph name="EXTENSION_NAME" /></translation> <translation id="1071917609930274619">Adattitkosítás</translation> -<translation id="1074944608454986967">Tartsa lenyomva a Keresés gombot, majd kattintással vagy húzással jelölje ki a felolvastatni kívánt tartalmat. További lehetőség: jelölje ki a kívánt szakaszt, és használja a Keresés+s billentyűkombinációt.</translation> <translation id="1076698951459398590">Téma engedélyezése</translation> <translation id="1076818208934827215">Microsoft Internet Explorer</translation> <translation id="1077946062898560804">Automatikus frissítések beállítása az összes felhasználó számára</translation> @@ -3794,7 +3793,6 @@ <translation id="6979737339423435258">Mindenkori</translation> <translation id="6980462514016882061">A Google felhasználhatja az Ön böngészési előzményeit a Keresés, a hirdetések és más Google-szolgáltatások személyre szabására</translation> <translation id="6981982820502123353">Kisegítő lehetőségek</translation> -<translation id="6983201004195852174">Tartsa lenyomva a Keresést, majd kattintással vagy húzással jelölje ki a felolvastatni kívánt tartalmat</translation> <translation id="6983783921975806247">Regisztrált OID</translation> <translation id="6983991971286645866">A módosításokat a rendszer a következő fájlba menti: $1.</translation> <translation id="6984299437918708277">Válassza ki a bejelentkezési képernyőn a fiókja mellett megjeleníteni kívánt képet</translation>
diff --git a/chrome/app/resources/generated_resources_id.xtb b/chrome/app/resources/generated_resources_id.xtb index 37fb16a..39bef7f 100644 --- a/chrome/app/resources/generated_resources_id.xtb +++ b/chrome/app/resources/generated_resources_id.xtb
@@ -51,7 +51,6 @@ <ph name="EXTENSION_NAME" /></translation> <translation id="1071917609930274619">Penyandian Data</translation> -<translation id="1074944608454986967">Untuk membaca konten dengan keras, tekan dan tahan tombol Penelusuran, lalu klik atau tarik untuk memilih konten. Atau, tandai wilayah dan gunakan tombol Penelusuran + S.</translation> <translation id="1076698951459398590">Aktifkan Tema</translation> <translation id="1076818208934827215">Microsoft Internet Explorer</translation> <translation id="1077946062898560804">Menyiapkan Pembaruan Otomatis untuk Semua Pengguna</translation> @@ -3792,7 +3791,6 @@ <translation id="6979737339423435258">Semua</translation> <translation id="6980462514016882061">Google dapat menggunakan histori penjelajahan Anda untuk mempersonalisasi Penelusuran, iklan, dan layanan Google lainnya</translation> <translation id="6981982820502123353">Aksesibilitas</translation> -<translation id="6983201004195852174">Tekan dan tahan tombol Penelusuran, lalu klik atau tarik untuk memilih konten yang akan dibaca dengan lantang</translation> <translation id="6983783921975806247">OID terdaftar</translation> <translation id="6983991971286645866">Semua pengeditan akan disimpan ke $1.</translation> <translation id="6984299437918708277">Pilih gambar yang akan ditampilkan untuk akun Anda di layar login</translation>
diff --git a/chrome/app/resources/generated_resources_it.xtb b/chrome/app/resources/generated_resources_it.xtb index a8be615..c188fbb 100644 --- a/chrome/app/resources/generated_resources_it.xtb +++ b/chrome/app/resources/generated_resources_it.xtb
@@ -51,7 +51,6 @@ <ph name="EXTENSION_NAME" /></translation> <translation id="1071917609930274619">Crittografia dati</translation> -<translation id="1074944608454986967">Per leggere il contenuto ad alta voce, tieni premuto il tasto per la ricerca, quindi fai clic o trascina per selezionare il contenuto. Oppure evidenzia una regione e utilizza il tasto per la ricerca + S.</translation> <translation id="1076698951459398590">Attiva tema</translation> <translation id="1076818208934827215">Microsoft Internet Explorer</translation> <translation id="1077946062898560804">Imposta aggiornamenti automatici per tutti gli utenti</translation> @@ -3788,7 +3787,6 @@ <translation id="6979737339423435258">Tutto</translation> <translation id="6980462514016882061">Google può utilizzare la tua cronologia di navigazione per personalizzare la Ricerca, gli annunci e altri servizi Google.</translation> <translation id="6981982820502123353">Accessibilità</translation> -<translation id="6983201004195852174">Tieni premuto il tasto per la ricerca, poi fai clic o trascina per selezionare i contenuti da farti leggere ad alta voce</translation> <translation id="6983783921975806247">OID registrato</translation> <translation id="6983991971286645866">Tutte le modifiche verranno salvate in $1.</translation> <translation id="6984299437918708277">Scegli un'immagine da visualizzare per il tuo account nella schermata di accesso</translation>
diff --git a/chrome/app/resources/generated_resources_iw.xtb b/chrome/app/resources/generated_resources_iw.xtb index d4b5216..943f359 100644 --- a/chrome/app/resources/generated_resources_iw.xtb +++ b/chrome/app/resources/generated_resources_iw.xtb
@@ -51,7 +51,6 @@ <ph name="EXTENSION_NAME" /></translation> <translation id="1071917609930274619">קידוד נתונים</translation> -<translation id="1074944608454986967">כדי שהתוכן יוקרא בקול, יש להקיש על מקש החיפוש ולהחזיק אותו, ולאחר מכן ללחוץ או לגרור כדי לבחור תוכן. לחלופין אפשר להדגיש אזור ולהקיש על מקש החיפוש + S.</translation> <translation id="1076698951459398590">הפעל עיצוב</translation> <translation id="1076818208934827215">Microsoft Internet Explorer</translation> <translation id="1077946062898560804">הגדר עדכונים אוטומטיים לכל המשתמשים</translation> @@ -3789,7 +3788,6 @@ <translation id="6979737339423435258">משחר ההיסטוריה</translation> <translation id="6980462514016882061">חברת Google עשויה להשתמש בהיסטוריית הגלישה שלך לצורך התאמה אישית של חיפוש Google, מודעות Google ושירותי Google אחרים</translation> <translation id="6981982820502123353">נגישות</translation> -<translation id="6983201004195852174">הקש והחזק את מקש החיפוש ולאחר מכן לחץ או גרור כדי לבחור תוכן להקראה בקול</translation> <translation id="6983783921975806247">OID רשום</translation> <translation id="6983991971286645866">כל העריכות יישמרו ב-$1.</translation> <translation id="6984299437918708277">בחר לחשבונך תמונה שתוצג במסך הכניסה</translation>
diff --git a/chrome/app/resources/generated_resources_ja.xtb b/chrome/app/resources/generated_resources_ja.xtb index 0e584bf1..a0b631e 100644 --- a/chrome/app/resources/generated_resources_ja.xtb +++ b/chrome/app/resources/generated_resources_ja.xtb
@@ -51,7 +51,6 @@ <ph name="EXTENSION_NAME" /></translation> <translation id="1071917609930274619">データの暗号化</translation> -<translation id="1074944608454986967">コンテンツを読み上げるには、検索キーを押したままクリックまたはドラッグしてコンテンツを選択するか、読み上げる部分をハイライト表示して検索+S キーを押します。</translation> <translation id="1076698951459398590">テーマを有効にする</translation> <translation id="1076818208934827215">Microsoft Internet Explorer</translation> <translation id="1077946062898560804">すべてのユーザーの自動更新を設定</translation> @@ -3793,7 +3792,6 @@ <translation id="6979737339423435258">全期間</translation> <translation id="6980462514016882061">検索、広告、その他の Google サービスをカスタマイズする目的で、Google が閲覧履歴を使用することがあります</translation> <translation id="6981982820502123353">ユーザー補助機能</translation> -<translation id="6983201004195852174">検索キーを押したままクリックまたはドラッグして、読み上げるコンテンツを選択します</translation> <translation id="6983783921975806247">登録されている OID</translation> <translation id="6983991971286645866">編集内容はすべて $1 に保存されます。</translation> <translation id="6984299437918708277">ログイン画面で自分のアカウントに表示する画像を選択します</translation>
diff --git a/chrome/app/resources/generated_resources_kn.xtb b/chrome/app/resources/generated_resources_kn.xtb index ed9d053..728d24d 100644 --- a/chrome/app/resources/generated_resources_kn.xtb +++ b/chrome/app/resources/generated_resources_kn.xtb
@@ -51,7 +51,6 @@ <ph name="EXTENSION_NAME" /></translation> <translation id="1071917609930274619">ಡೇಟಾ ಎನ್ಸಿಫರ್ಮೆಂಟ್</translation> -<translation id="1074944608454986967">ವಿಷಯವನ್ನು ಗಟ್ಟಿಯಾಗಿ ಓದಲು, ಹುಡುಕಾಟ ಎಂಬುದನ್ನು ಒತ್ತಿ ಹಿಡಿದುಕೊಳ್ಳಿ. ನಂತರ, ವಿಷಯವನ್ನು ಆಯ್ಕೆ ಮಾಡಲು ಕ್ಲಿಕ್ ಮಾಡಿ ಅಥವಾ ಡ್ರ್ಯಾಗ್ ಮಾಡಿ. ಅಥವಾ ಒಂದು ಪ್ರದೇಶವನ್ನು ಹೈಲೈಟ್ ಮಾಡಿ, ಹುಡುಕಾಟ + S ಬಳಸಿ.</translation> <translation id="1076698951459398590">ಥೀಮ್ ಸಕ್ರಿಯಗೊಳಿಸಿ</translation> <translation id="1076818208934827215">Microsoft Internet Explorer</translation> <translation id="1077946062898560804">ಎಲ್ಲ ಬಳಕೆದಾರರಿಗೆ ಸ್ವಯಂಚಾಲಿತ ನವೀಕರಣಗಳನ್ನು ಹೊಂದಿಸಿ </translation> @@ -3790,7 +3789,6 @@ <translation id="6979737339423435258">ಎಲ್ಲ ಸಮಯ</translation> <translation id="6980462514016882061">ಹುಡುಕಾಟ, ಜಾಹೀರಾತುಗಳು ಮತ್ತು ಇತರ Google ಸೇವೆಗಳನ್ನು ವೈಯಕ್ತೀಕರಿಸಲು ನಿಮ್ಮ ಬ್ರೌಸಿಂಗ್ ಇತಿಹಾಸವನ್ನು Google ಬಳಸಬಹುದು</translation> <translation id="6981982820502123353">ಪ್ರವೇಶ</translation> -<translation id="6983201004195852174">ಹುಡುಕಾಟವನ್ನು ಒತ್ತಿ ಹಿಡಿಯಿರಿ, ನಂತರ ಜೋರಾಗಿ ಓದಬೇಕಾದ ವಿಷಯವನ್ನು ಆಯ್ಕೆ ಮಾಡಲು ಕ್ಲಿಕ್ ಮಾಡಿ ಅಥವಾ ಡ್ರ್ಯಾಗ್ ಮಾಡಿ.</translation> <translation id="6983783921975806247">ನೋಂದಾಯಿತ OID</translation> <translation id="6983991971286645866">ಎಲ್ಲಾ ಸಂಪಾದನೆಗಳನ್ನು $1 ಗೆ ಉಳಿಸಲಾಗುವುದು.</translation> <translation id="6984299437918708277">ಸೈನ್-ಇನ್ ಪರದೆಯಲ್ಲಿ ನಿಮ್ಮ ಖಾತೆಯನ್ನು ಪ್ರದರ್ಶಿಸಲು ಚಿತ್ರವನ್ನು ಆಯ್ಕೆಮಾಡಿ</translation>
diff --git a/chrome/app/resources/generated_resources_ko.xtb b/chrome/app/resources/generated_resources_ko.xtb index 3edb166..4f710fa 100644 --- a/chrome/app/resources/generated_resources_ko.xtb +++ b/chrome/app/resources/generated_resources_ko.xtb
@@ -51,7 +51,6 @@ <ph name="EXTENSION_NAME" /></translation> <translation id="1071917609930274619">데이터 암호화</translation> -<translation id="1074944608454986967">콘텐츠를 소리 내어 읽으려면 검색 키를 길게 누른 다음 콘텐츠를 클릭하거나 드래그하여 선택합니다. 또는 영역을 강조표시하고 검색 키+ S를 사용하세요.</translation> <translation id="1076698951459398590">테마 사용</translation> <translation id="1076818208934827215">Microsoft Internet Explorer</translation> <translation id="1077946062898560804">모든 사용자에 대해 자동 업데이트 설정</translation> @@ -3792,7 +3791,6 @@ <translation id="6979737339423435258">전체 기간</translation> <translation id="6980462514016882061">Google에서 검색, 광고 및 다른 Google 서비스를 맞춤설정하기 위하여 내 인터넷 사용 기록을 사용할 수 있습니다.</translation> <translation id="6981982820502123353">접근성</translation> -<translation id="6983201004195852174">검색 키를 길게 누른 다음 소리 내어 읽을 콘텐츠를 클릭하거나 드래그하여 선택합니다.</translation> <translation id="6983783921975806247">등록된 OID</translation> <translation id="6983991971286645866">모든 수정사항이 $1에 저장됩니다.</translation> <translation id="6984299437918708277">로그인 화면에 표시할 내 계정 사진을 선택하세요.</translation>
diff --git a/chrome/app/resources/generated_resources_lt.xtb b/chrome/app/resources/generated_resources_lt.xtb index 0009781..1479490d 100644 --- a/chrome/app/resources/generated_resources_lt.xtb +++ b/chrome/app/resources/generated_resources_lt.xtb
@@ -51,7 +51,6 @@ <ph name="EXTENSION_NAME" /></translation> <translation id="1071917609930274619">Duomenų kodavimas</translation> -<translation id="1074944608454986967">Jei norite, kad turinys būtų skaitomas garsiai, paspauskite ir palaikykite parinktį „Ieškoti“, tada spustelėkite pasirinktą turinį arba nuvilkite ant jo laukelį. Arba paryškinkite sritį ir naudokite „Ieškoti“ + S.</translation> <translation id="1076698951459398590">Įgalinti temą</translation> <translation id="1076818208934827215">„Microsoft Internet Explorer“</translation> <translation id="1077946062898560804">Nustatyti automatinius naujinius visiems naudotojams</translation> @@ -3793,7 +3792,6 @@ <translation id="6979737339423435258">Visas laikotarpis</translation> <translation id="6980462514016882061">„Google“ gali naudoti jūsų naršymo istoriją, kad suasmenintų Paiešką, skelbimus ir kitas „Google“ paslaugas</translation> <translation id="6981982820502123353">Pritaikymas neįgaliesiems</translation> -<translation id="6983201004195852174">Paspauskite ir palaikykite parinktį „Ieškoti“, tada spustelėkite pasirinktą turinį arba nuvilkite ant jo laukelį, kad jis būtų perskaitytas garsiai</translation> <translation id="6983783921975806247">Registruotas OID</translation> <translation id="6983991971286645866">Visi redagavimo veiksmai bus išsaugoti kaip $1.</translation> <translation id="6984299437918708277">Pasirinkite paskyros paveikslėlį, kurį norite pateikti prisijungimo ekrane</translation>
diff --git a/chrome/app/resources/generated_resources_lv.xtb b/chrome/app/resources/generated_resources_lv.xtb index 9826375..b4abf42 100644 --- a/chrome/app/resources/generated_resources_lv.xtb +++ b/chrome/app/resources/generated_resources_lv.xtb
@@ -51,7 +51,6 @@ <ph name="EXTENSION_NAME" /></translation> <translation id="1071917609930274619">Datu šifrēšana</translation> -<translation id="1074944608454986967">Lai saturs tiktu skaļi nolasīts, turiet nospiestu meklēšanas taustiņu, pēc tam atlasiet saturu, noklikšķinot uz satura vai to velkot. Varat arī iezīmēt satura daļu un vienlaicīgi nospiest meklēšanas taustiņu un taustiņu S.</translation> <translation id="1076698951459398590">Iespējot motīvu</translation> <translation id="1076818208934827215">Microsoft Internet Explorer</translation> <translation id="1077946062898560804">Iestatīt visiem lietotājiem pieejamus automātiskos atjauninājumus</translation> @@ -3792,7 +3791,6 @@ <translation id="6979737339423435258">Visā periodā</translation> <translation id="6980462514016882061">Google var izmantot jūsu pārlūkošanas vēsturi, lai personalizētu Meklēšanu, reklāmas un citus Google pakalpojumus.</translation> <translation id="6981982820502123353">Pieejamība</translation> -<translation id="6983201004195852174">Turiet nospiestu meklēšanas taustiņu; pēc tam noklikšķiniet vai velciet, lai atlasītu izrunājamo saturu.</translation> <translation id="6983783921975806247">Reģistrētais OID</translation> <translation id="6983991971286645866">Visi labojumi tiks saglabāti šeit: $1.</translation> <translation id="6984299437918708277">Izvēlieties attēlu, ko rādīt savā kontā pierakstīšanās ekrānā.</translation>
diff --git a/chrome/app/resources/generated_resources_ml.xtb b/chrome/app/resources/generated_resources_ml.xtb index b8d6d50..c2731c47 100644 --- a/chrome/app/resources/generated_resources_ml.xtb +++ b/chrome/app/resources/generated_resources_ml.xtb
@@ -51,7 +51,6 @@ <ph name="EXTENSION_NAME" /></translation> <translation id="1071917609930274619">ഡാറ്റ എന്സിഫെര്മെന്റ്</translation> -<translation id="1074944608454986967">ഉള്ളടക്കം ഉറക്കെ വായിക്കാൻ, തിരയൽ അമർത്തിപ്പിടിക്കുക, എന്നിട്ട് ഉള്ളടക്കം തിരഞ്ഞെടുക്കാൻ ക്ലിക്ക് ചെയ്യുകയോ വലിച്ചിടുകയോ ചെയ്യുക. അല്ലെങ്കിൽ ഒരു മേഖല തിരഞ്ഞെടുക്കുക, 'തിരയുക + S' ഉപയോഗിക്കുക.</translation> <translation id="1076698951459398590">തീം പ്രവർത്തനക്ഷമമാക്കുക</translation> <translation id="1076818208934827215">Microsoft Internet Explorer</translation> <translation id="1077946062898560804">എല്ലാ ഉപയോക്താക്കള്ക്കും ഓട്ടോമാറ്റിക്ക് അപ്ഡേറ്റുകള് ക്രമീകരിക്കുക</translation> @@ -3790,7 +3789,6 @@ <translation id="6979737339423435258">എല്ലാ സമയത്തും</translation> <translation id="6980462514016882061">തിരയലും പരസ്യങ്ങളും മറ്റ് Google സേവനങ്ങളും വ്യക്തിപരമാക്കാൻ, Google നിങ്ങളുടെ ബ്രൗസിംഗ് ചരിത്രം ഉപയോഗിച്ചേക്കാം</translation> <translation id="6981982820502123353">ഉപയോഗസഹായി</translation> -<translation id="6983201004195852174">തിരയൽ അമർത്തിപ്പിടിക്കുക, തുടർന്ന് ഉറക്കെ വായിക്കാനുള്ള ഉള്ളടക്കം തിരഞ്ഞെടുക്കാൻ ക്ലിക്കുചെയ്യുക അല്ലെങ്കിൽ വലിച്ചിടുക</translation> <translation id="6983783921975806247">രജിസ്ട്രേഡ് OID</translation> <translation id="6983991971286645866">എല്ലാ എഡിറ്റുകളും $1 എന്നതിൽ സംരക്ഷിക്കും.</translation> <translation id="6984299437918708277">സൈൻ ഇൻ സ്ക്രീനിലുള്ള നിങ്ങളുടെ അക്കൗണ്ടിൽ പ്രദര്ശിപ്പിക്കുന്നതിന് ഒരു ചിത്രം തിരഞ്ഞെടുക്കുക</translation>
diff --git a/chrome/app/resources/generated_resources_mr.xtb b/chrome/app/resources/generated_resources_mr.xtb index 067abbf..bedb14c8 100644 --- a/chrome/app/resources/generated_resources_mr.xtb +++ b/chrome/app/resources/generated_resources_mr.xtb
@@ -51,7 +51,6 @@ <ph name="EXTENSION_NAME" /></translation> <translation id="1071917609930274619">डेटा एनसिफरमेन्ट</translation> -<translation id="1074944608454986967">आशय मोठ्याने वाचण्यासाठी, शोधा दाबा आणि धरून ठेवा, नंतर आशय निवडण्यासाठी क्लिक करा किंवा ड्रॅग करा किंवा तो भाग ठळक करा आणि शोधा + S वापरा.</translation> <translation id="1076698951459398590">थीम सक्षम करा</translation> <translation id="1076818208934827215">Microsoft Internet Explorer</translation> <translation id="1077946062898560804">सर्व वापरकर्त्यांसाठी स्वयंचलित अपडेट सेट करा</translation> @@ -3789,7 +3788,6 @@ <translation id="6979737339423435258">पूर्णवेळ</translation> <translation id="6980462514016882061">शोध, जाहिरात आणि इतर Google सेवा वैयक्तीकृत करण्यासाठी Google आपल्या ब्राउझिंग इतिहासाचा वापर करू शकते</translation> <translation id="6981982820502123353">प्रवेशयोग्यता</translation> -<translation id="6983201004195852174">शोध दाबा आणि धरून ठेवा, त्यानंतर मोठयाने वाचण्याचा आशय निवडण्यासाठी क्लिक करा किंवा ड्रॅग करा</translation> <translation id="6983783921975806247">नोंदणीकृत OID</translation> <translation id="6983991971286645866">सर्व संपादने $1 वर जतन केली जातील.</translation> <translation id="6984299437918708277">साइन-इन स्क्रीनवर आपल्या खात्यासाठी प्रदर्शित करण्याकरिता एक चित्र निवडा</translation>
diff --git a/chrome/app/resources/generated_resources_ms.xtb b/chrome/app/resources/generated_resources_ms.xtb index 1d33422..65e11af 100644 --- a/chrome/app/resources/generated_resources_ms.xtb +++ b/chrome/app/resources/generated_resources_ms.xtb
@@ -51,7 +51,6 @@ <ph name="EXTENSION_NAME" /></translation> <translation id="1071917609930274619">Data Encipherment</translation> -<translation id="1074944608454986967">Untuk membaca kandungan dengan kuat, tekan dan tahan Cari, kemudian klik atau seret untuk memilih kandungan. Selain itu, serlahkan kawasan dan gunakan Cari + S.</translation> <translation id="1076698951459398590">Dayakan Tema</translation> <translation id="1076818208934827215">Microsoft Internet Explorer</translation> <translation id="1077946062898560804">Sediakan Kemas Kini Automatik untuk Semua Pengguna</translation> @@ -3793,7 +3792,6 @@ <translation id="6979737339423435258">Sepanjang masa</translation> <translation id="6980462514016882061">Google boleh menggunakan sejarah penyemakan imbas anda untuk memperibadikan Carian, iklan dan perkhidmatan Google yang lain.</translation> <translation id="6981982820502123353">Kebolehcapaian</translation> -<translation id="6983201004195852174">Tekan dan tahan Cari, kemudian klik atau seret untuk memilih kandungan yang akan dibaca</translation> <translation id="6983783921975806247">OID berdaftar</translation> <translation id="6983991971286645866">Semua suntingan akan disimpan ke $1.</translation> <translation id="6984299437918708277">Pilih gambar yang hendak dipaparkan untuk akaun anda pada skrin log masuk</translation>
diff --git a/chrome/app/resources/generated_resources_nl.xtb b/chrome/app/resources/generated_resources_nl.xtb index 8c4b7ee..c74ccea6 100644 --- a/chrome/app/resources/generated_resources_nl.xtb +++ b/chrome/app/resources/generated_resources_nl.xtb
@@ -51,7 +51,6 @@ <ph name="EXTENSION_NAME" /></translation> <translation id="1071917609930274619">Gegevenscodering</translation> -<translation id="1074944608454986967">Houd Zoeken ingedrukt en klik of sleep om content te selecteren die moet worden voorgelezen. Je kunt ook een gedeelte markeren en Zoeken + S gebruiken.</translation> <translation id="1076698951459398590">Thema inschakelen</translation> <translation id="1076818208934827215">Microsoft Internet Explorer</translation> <translation id="1077946062898560804">Automatische updates instellen voor alle gebruikers</translation> @@ -3793,7 +3792,6 @@ <translation id="6979737339423435258">Altijd</translation> <translation id="6980462514016882061">Google kan je browsegeschiedenis gebruiken om Google Zoeken, advertenties en andere Google-services te personaliseren</translation> <translation id="6981982820502123353">Toegankelijkheid</translation> -<translation id="6983201004195852174">Houd Zoeken ingedrukt en klik of sleep om content te selecteren die moet worden voorgelezen</translation> <translation id="6983783921975806247">Geregistreerde OID</translation> <translation id="6983991971286645866">Alle bewerkingen worden opgeslagen in $1.</translation> <translation id="6984299437918708277">Selecteer een foto als weergave van je account op het inlogscherm</translation>
diff --git a/chrome/app/resources/generated_resources_no.xtb b/chrome/app/resources/generated_resources_no.xtb index 2f2c480..59d69fb5 100644 --- a/chrome/app/resources/generated_resources_no.xtb +++ b/chrome/app/resources/generated_resources_no.xtb
@@ -51,7 +51,6 @@ <ph name="EXTENSION_NAME" /></translation> <translation id="1071917609930274619">Datachiffrering</translation> -<translation id="1074944608454986967">For å få innholdet lest opp, trykk og hold på Søk, og klikk eller dra for å velge innholdet. Eller fremhev et område og bruk Søk + S.</translation> <translation id="1076698951459398590">Slå på temaet</translation> <translation id="1076818208934827215">Microsoft Internet Explorer</translation> <translation id="1077946062898560804">Velg automatiske oppdateringer for alle brukere</translation> @@ -3772,7 +3771,6 @@ <translation id="6979737339423435258">Alle datoer</translation> <translation id="6980462514016882061">Google kan bruke nettlesingsloggen din for å gi Søk, annonser og andre Google-tjenester et personlig preg</translation> <translation id="6981982820502123353">Tilgjengelighet</translation> -<translation id="6983201004195852174">Trykk og hold på Søk, og klikk eller dra for å velge innhold og få det lest opp</translation> <translation id="6983783921975806247">Registrert OID</translation> <translation id="6983991971286645866">Alle endringer blir lagret som $1.</translation> <translation id="6984299437918708277">Velg et bilde som skal vises på påloggingsskjermen for kontoen din</translation>
diff --git a/chrome/app/resources/generated_resources_pl.xtb b/chrome/app/resources/generated_resources_pl.xtb index e0f848d6..b1931b77 100644 --- a/chrome/app/resources/generated_resources_pl.xtb +++ b/chrome/app/resources/generated_resources_pl.xtb
@@ -51,7 +51,6 @@ <ph name="EXTENSION_NAME" /></translation> <translation id="1071917609930274619">Szyfrowanie danych</translation> -<translation id="1074944608454986967">Aby usłyszeć treść czytaną na głos, naciśnij i przytrzymaj Wyszukaj, a potem kliknij lub przeciągnij, by ją zaznaczyć. Możesz też zaznaczyć region i kliknąć Wyszukaj + S.</translation> <translation id="1076698951459398590">Włącz motyw</translation> <translation id="1076818208934827215">Microsoft Internet Explorer</translation> <translation id="1077946062898560804">Skonfiguruj automatyczne aktualizacje dla wszystkich użytkowników</translation> @@ -3792,7 +3791,6 @@ <translation id="6979737339423435258">Od początku</translation> <translation id="6980462514016882061">Google może korzystać z Twojej historii przeglądania, by dostosowywać wyniki wyszukiwania, reklamy i działanie innych usług.</translation> <translation id="6981982820502123353">Ułatwienia dostępu</translation> -<translation id="6983201004195852174">Naciśnij i przytrzymaj klawisz wyszukiwania, a następnie kliknij lub przeciągnij, by zaznaczyć treść, którą chcesz usłyszeć</translation> <translation id="6983783921975806247">Zarejestrowany identyfikator OID</translation> <translation id="6983991971286645866">Wszystkie zmiany zostaną zapisane w pliku $1.</translation> <translation id="6984299437918708277">Wybierz do Twojego konta zdjęcie, które pojawi się na ekranie logowania</translation>
diff --git a/chrome/app/resources/generated_resources_pt-BR.xtb b/chrome/app/resources/generated_resources_pt-BR.xtb index 23a9b7b..00923ee 100644 --- a/chrome/app/resources/generated_resources_pt-BR.xtb +++ b/chrome/app/resources/generated_resources_pt-BR.xtb
@@ -51,7 +51,6 @@ <ph name="EXTENSION_NAME" /></translation> <translation id="1071917609930274619">Codificação de dados</translation> -<translation id="1074944608454986967">Para ler conteúdo em voz alta, toque na tecla Pesquisar e mantenha-a pressionada. Depois, clique ou arraste para selecionar o conteúdo. Você também pode destacar uma região e usar as teclas Pesquisar + S.</translation> <translation id="1076698951459398590">Ativar tema</translation> <translation id="1076818208934827215">Microsoft Internet Explorer</translation> <translation id="1077946062898560804">Configurar atualizações automáticas para todos os usuários</translation> @@ -3794,7 +3793,6 @@ <translation id="6979737339423435258">Todo o período</translation> <translation id="6980462514016882061">O Google pode usar seu histórico de navegação para personalizar a Pesquisa Google, os anúncios e outros serviços nossos</translation> <translation id="6981982820502123353">Acessibilidade</translation> -<translation id="6983201004195852174">Toque na tecla Pesquisar e a mantenha pressionada; depois clique ou arraste para selecionar o conteúdo que deverá ser lido em voz alta</translation> <translation id="6983783921975806247">OID registrado</translation> <translation id="6983991971286645866">Todas as edições serão salvas em $1.</translation> <translation id="6984299437918708277">Escolha uma imagem de exibição para sua conta na tela de login</translation>
diff --git a/chrome/app/resources/generated_resources_pt-PT.xtb b/chrome/app/resources/generated_resources_pt-PT.xtb index 1546d949..90766cc 100644 --- a/chrome/app/resources/generated_resources_pt-PT.xtb +++ b/chrome/app/resources/generated_resources_pt-PT.xtb
@@ -51,7 +51,6 @@ <ph name="EXTENSION_NAME" /></translation> <translation id="1071917609930274619">Cifragem de dados</translation> -<translation id="1074944608454986967">Para ler conteúdos em voz alta, prima sem soltar Pesquisar e, de seguida, clique ou arraste para selecionar o conteúdo. Em alternativa, realce uma região e utilize Pesquisar + S.</translation> <translation id="1076698951459398590">Ativar tema</translation> <translation id="1076818208934827215">Microsoft Internet Explorer</translation> <translation id="1077946062898560804">Configurar actualizações automáticas para todos os utilizadores</translation> @@ -3795,7 +3794,6 @@ <translation id="6979737339423435258">Sempre</translation> <translation id="6980462514016882061">A Google pode utilizar o seu histórico de navegação para personalizar a Pesquisa Google, os anúncios e outros serviços Google</translation> <translation id="6981982820502123353">Acessibilidade</translation> -<translation id="6983201004195852174">Prima sem soltar Pesquisar e, de seguida, clique ou arraste para selecionar o conteúdo a ler em voz alta</translation> <translation id="6983783921975806247">OID registado</translation> <translation id="6983991971286645866">Todas as alterações são guardadas em $1.</translation> <translation id="6984299437918708277">Selecione uma imagem para apresentar no ecrã de início de sessão da sua conta</translation>
diff --git a/chrome/app/resources/generated_resources_ro.xtb b/chrome/app/resources/generated_resources_ro.xtb index 7b85d79..3827e0a 100644 --- a/chrome/app/resources/generated_resources_ro.xtb +++ b/chrome/app/resources/generated_resources_ro.xtb
@@ -51,7 +51,6 @@ <ph name="EXTENSION_NAME" /></translation> <translation id="1071917609930274619">Cifrare de date</translation> -<translation id="1074944608454986967">Pentru a se rosti conținutul, apasă lung tasta de căutare, apoi dă clic sau trage pentru a selecta conținutul sau evidențiază o regiune și folosește tasta de căutare + S.</translation> <translation id="1076698951459398590">Activează tema</translation> <translation id="1076818208934827215">Microsoft Internet Explorer</translation> <translation id="1077946062898560804">Configurează actualizările automate pentru toți utilizatorii</translation> @@ -3792,7 +3791,6 @@ <translation id="6979737339423435258">Dintotdeauna</translation> <translation id="6980462514016882061">Google poate folosi istoricul de navigare pentru a personaliza Căutarea, anunțurile și alte servicii Google</translation> <translation id="6981982820502123353">Accesibilitate</translation> -<translation id="6983201004195852174">Apasă lung tasta de căutare, apoi dă clic sau trage pentru a selecta conținutul care trebuie citit cu voce tare</translation> <translation id="6983783921975806247">OID înregistrat</translation> <translation id="6983991971286645866">Toate modificările vor fi salvate în $1.</translation> <translation id="6984299437918708277">Alege o imagine de afișat pentru contul tău pe ecranul de conectare</translation>
diff --git a/chrome/app/resources/generated_resources_ru.xtb b/chrome/app/resources/generated_resources_ru.xtb index ce15ce6..a5c2cbb 100644 --- a/chrome/app/resources/generated_resources_ru.xtb +++ b/chrome/app/resources/generated_resources_ru.xtb
@@ -51,7 +51,6 @@ <ph name="EXTENSION_NAME" /></translation> <translation id="1071917609930274619">Шифрование данных</translation> -<translation id="1074944608454986967">Чтобы прослушать текст на экране, нажмите и удерживайте кнопку Поиск, а затем выберите контент, удерживая левую кнопку мыши. Также можно выделить область и нажать Поиск + S.</translation> <translation id="1076698951459398590">Включить тему</translation> <translation id="1076818208934827215">Microsoft Internet Explorer</translation> <translation id="1077946062898560804">Настройка автообновлений для всех пользователей</translation> @@ -3793,7 +3792,6 @@ <translation id="6979737339423435258">Все время</translation> <translation id="6980462514016882061">Google может использовать историю просмотров для персонализации Поиска, Рекламы и других сервисов.</translation> <translation id="6981982820502123353">Специальные возможности</translation> -<translation id="6983201004195852174">Если вы хотите озвучить текст, нажмите и удерживайте кнопку поиска, а затем выберите поле или перетащите его, чтобы выделить контент.</translation> <translation id="6983783921975806247">Зарегистрированный OID</translation> <translation id="6983991971286645866">Все изменения будут сохранены в файле $1.</translation> <translation id="6984299437918708277">Выберите картинку, которая будет видна на экране входа в аккаунт</translation>
diff --git a/chrome/app/resources/generated_resources_sk.xtb b/chrome/app/resources/generated_resources_sk.xtb index 77d6ec1..837007f 100644 --- a/chrome/app/resources/generated_resources_sk.xtb +++ b/chrome/app/resources/generated_resources_sk.xtb
@@ -51,7 +51,6 @@ <ph name="EXTENSION_NAME" /></translation> <translation id="1071917609930274619">Zašifrovanie údajov</translation> -<translation id="1074944608454986967">Ak chcete obsah nahlas prečítať, pridržte tlačidlo Hľadať a potom kliknutím alebo presunutím vyberte požadovaný obsah. Môžete tiež zvýrazniť oblasť a stlačiť klávesy Hľadať + S.</translation> <translation id="1076698951459398590">Povoliť motív</translation> <translation id="1076818208934827215">Microsoft Internet Explorer</translation> <translation id="1077946062898560804">Nastaviť automatické aktualizácie pre všetkých používateľov</translation> @@ -3790,7 +3789,6 @@ <translation id="6979737339423435258">Celé obdobie</translation> <translation id="6980462514016882061">Google môže používať vašu históriu prehliadania na prispôsobenie Vyhľadávania, reklám a ďalších služieb Google</translation> <translation id="6981982820502123353">Dostupnosť</translation> -<translation id="6983201004195852174">Stlačte a podržte tlačidlo Hľadať, potom kliknite alebo presunutím myšou vyberte obsah, ktorý sa má nahlas prečítať</translation> <translation id="6983783921975806247">Registrovaný identifikátor OID</translation> <translation id="6983991971286645866">Všetky úpravy budu uložené do súboru $1.</translation> <translation id="6984299437918708277">Vyberte obrázok pre svoj účet, ktorý sa objaví na obrazovke prihlásenia</translation>
diff --git a/chrome/app/resources/generated_resources_sl.xtb b/chrome/app/resources/generated_resources_sl.xtb index d0d899c..cc4fb30 100644 --- a/chrome/app/resources/generated_resources_sl.xtb +++ b/chrome/app/resources/generated_resources_sl.xtb
@@ -51,7 +51,6 @@ <ph name="EXTENSION_NAME" /></translation> <translation id="1071917609930274619">Šifriranje podatkov</translation> -<translation id="1074944608454986967">Če želite brati vsebino na glas, pridržite tipko za iskanje in nato kliknite ali povlecite, če želite izbrati vsebino. Prav tako lahko označite območje in uporabite tipko za iskanje in S.</translation> <translation id="1076698951459398590">Omogoči temo</translation> <translation id="1076818208934827215">Microsoft Internet Explorer</translation> <translation id="1077946062898560804">Nastavitev samodejnih posodobitev za vse uporabnike</translation> @@ -3793,7 +3792,6 @@ <translation id="6979737339423435258">Od začetka</translation> <translation id="6980462514016882061">Google lahko vašo zgodovino brskanja uporabi za prilagajanje Iskanja Google, oglasov in drugih Googlovih storitev.</translation> <translation id="6981982820502123353">Dostopnost</translation> -<translation id="6983201004195852174">Pridržite tipko za iskanje in nato kliknite ali povlecite, če želite izbrati vsebino, ki naj se izgovori</translation> <translation id="6983783921975806247">Registriran OID</translation> <translation id="6983991971286645866">Vsa urejanja bodo shranjena v $1.</translation> <translation id="6984299437918708277">Izberite sliko za vaš račun na zaslonu za prijavo</translation>
diff --git a/chrome/app/resources/generated_resources_sr.xtb b/chrome/app/resources/generated_resources_sr.xtb index 8d4532d..39d38df 100644 --- a/chrome/app/resources/generated_resources_sr.xtb +++ b/chrome/app/resources/generated_resources_sr.xtb
@@ -51,7 +51,6 @@ <ph name="EXTENSION_NAME" /></translation> <translation id="1071917609930274619">Шифровање података</translation> -<translation id="1074944608454986967">За читање садржаја наглас притисните и задржите тастер за претрагу, па кликните или превуците да бисте изабрали садржај. Можете и да означите област и притиснете тастер за претрагу + S.</translation> <translation id="1076698951459398590">Омогући тему</translation> <translation id="1076818208934827215">Microsoft Internet Explorer</translation> <translation id="1077946062898560804">Подеси аутоматска ажурирања за све кориснике</translation> @@ -3789,7 +3788,6 @@ <translation id="6979737339423435258">Одувек</translation> <translation id="6980462514016882061">Google може да користи историју прегледања за персонализацију Претраге, огласа и других Google услуга</translation> <translation id="6981982820502123353">Приступачност</translation> -<translation id="6983201004195852174">Притисните и задржите тастер за претрагу, па кликните или превуците да бисте изабрали садржај који ће се читати наглас</translation> <translation id="6983783921975806247">Регистровани OID</translation> <translation id="6983991971286645866">Све измене ће се сачувати у $1.</translation> <translation id="6984299437918708277">Изаберите слику која ће се приказивати за налог на екрану за пријављивање</translation>
diff --git a/chrome/app/resources/generated_resources_sv.xtb b/chrome/app/resources/generated_resources_sv.xtb index 74e7c39..a7e747c 100644 --- a/chrome/app/resources/generated_resources_sv.xtb +++ b/chrome/app/resources/generated_resources_sv.xtb
@@ -51,7 +51,6 @@ <ph name="EXTENSION_NAME" /></translation> <translation id="1071917609930274619">Datachiffrering</translation> -<translation id="1074944608454986967">Om du vill få text uppläst håller du ned söktangenten och markerar det som ska läsas upp genom att klicka eller dra. Du kan också markera ett avsnitt och trycka på söktangenten + S.</translation> <translation id="1076698951459398590">Aktivera temat</translation> <translation id="1076818208934827215">Microsoft Internet Explorer</translation> <translation id="1077946062898560804">Konfigurera automatiska uppdateringar för alla användare</translation> @@ -3791,7 +3790,6 @@ <translation id="6979737339423435258">Genom tiderna</translation> <translation id="6980462514016882061">Google kan anpassa Sök, annonser och andra Google-tjänster utifrån webbhistoriken.</translation> <translation id="6981982820502123353">Tillgänglighet</translation> -<translation id="6983201004195852174">Håll söktangenten nedtryckt och markera sedan texten som ska läsas upp genom att klicka och dra</translation> <translation id="6983783921975806247">Registrerat OID</translation> <translation id="6983991971286645866">Alla ändringar sparas i $1.</translation> <translation id="6984299437918708277">Välj en bild som ska visas för ditt konto på inloggningsskärmen</translation>
diff --git a/chrome/app/resources/generated_resources_sw.xtb b/chrome/app/resources/generated_resources_sw.xtb index f54f908..90046ace 100644 --- a/chrome/app/resources/generated_resources_sw.xtb +++ b/chrome/app/resources/generated_resources_sw.xtb
@@ -51,7 +51,6 @@ <ph name="EXTENSION_NAME" /></translation> <translation id="1071917609930274619">Usimbaji wa Data</translation> -<translation id="1074944608454986967">Ili kusoma maudhui kwa sauti, bonyeza na ushikilie kitufe cha Tafuta, kisha bofya au uburute ili uchague maudhui. Au angazia sehemu na utumie Tafuta + S.</translation> <translation id="1076698951459398590">Washa Mandhari</translation> <translation id="1076818208934827215">Microsoft Internet Explorer</translation> <translation id="1077946062898560804">Weka Masasisho ya Kiotomatiki kwa Watumiaji Wote</translation> @@ -3784,7 +3783,6 @@ <translation id="6979737339423435258">Wakati wote</translation> <translation id="6980462514016882061">Google inaweza kutumia historia ya jinsi unavyovinjari ili kuweka mapendeleo kwenye huduma ya Tafuta na Google, matangazo na huduma nyingine za Google</translation> <translation id="6981982820502123353">Upatikanaji</translation> -<translation id="6983201004195852174">Bonyeza na ushikilie kitufe cha Kutafuta, kisha ubofye au uburute ili uchague maudhui yatakayosomwa kwa sauti</translation> <translation id="6983783921975806247">OID Iliyosajiliwa</translation> <translation id="6983991971286645866">Mabadiliko yote yatahifadhiwa kwenye $1.</translation> <translation id="6984299437918708277">Chagua picha ya kuonyesha ya akaunti yako kwenye skrini ya kuingia katika akaunti</translation>
diff --git a/chrome/app/resources/generated_resources_ta.xtb b/chrome/app/resources/generated_resources_ta.xtb index 3cb5745..86a547302 100644 --- a/chrome/app/resources/generated_resources_ta.xtb +++ b/chrome/app/resources/generated_resources_ta.xtb
@@ -51,7 +51,6 @@ <ph name="EXTENSION_NAME" /></translation> <translation id="1071917609930274619">தரவு மாற்றம்</translation> -<translation id="1074944608454986967">உள்ளடக்கத்தைச் சத்தமாகப் படிக்க, தேடல் விசையை அழுத்திப் பிடிக்கவும், பின்னர் உள்ளடக்கத்தைத் தேர்ந்தெடுக்க, கிளிக் செய்யவும் அல்லது இழுக்கவும். அல்லது படிக்க வேண்டிய பகுதியைத் தனிப்படுத்தி, தேடல் + Sஐப் பயன்படுத்தவும்.</translation> <translation id="1076698951459398590">தீமினை இயக்கு</translation> <translation id="1076818208934827215">Microsoft Internet Explorer</translation> <translation id="1077946062898560804">எல்லா பயனர்களுக்கும் தானாக புதுப்பித்தலை அமைக்கவும்</translation> @@ -3793,7 +3792,6 @@ <translation id="6979737339423435258">எல்லா நேரமும்</translation> <translation id="6980462514016882061">தேடல், விளம்பரங்கள் மற்றும் பிற Google சேவைகளைத் தனிப்பயனாக்க, உங்கள் உலாவல் வரலாற்றை Google பயன்படுத்தக்கூடும்</translation> <translation id="6981982820502123353">அணுகல் தன்மை</translation> -<translation id="6983201004195852174">தேடலை அழுத்திப் பிடித்து, பின்னர் சத்தமாகப் படிக்க வேண்டிய உள்ளடக்கத்தைத் தேர்ந்தெடுக்க, கிளிக் செய்யவும் அல்லது இழுக்கவும்</translation> <translation id="6983783921975806247">பதிவுசெய்யப்பட்ட OID</translation> <translation id="6983991971286645866">அனைத்து மாற்றங்களும் $1 இல் சேமிக்கப்படும்.</translation> <translation id="6984299437918708277">உள்நுழைவுத் திரையில் உங்கள் கணக்கிற்குக் காட்ட வேண்டிய படத்தைத் தேர்வு செய்யவும்</translation>
diff --git a/chrome/app/resources/generated_resources_te.xtb b/chrome/app/resources/generated_resources_te.xtb index ace1fbf..56f77d3 100644 --- a/chrome/app/resources/generated_resources_te.xtb +++ b/chrome/app/resources/generated_resources_te.xtb
@@ -51,7 +51,6 @@ <ph name="EXTENSION_NAME" /></translation> <translation id="1071917609930274619">డేటా గుప్తీకరణ</translation> -<translation id="1074944608454986967">కంటెంట్ గట్టిగా చదివి వినిపించడానికి, శోధన కీ నొక్కి, ఉంచి, ఆపై ఎంపిక చేసుకునే కంటెంట్పై క్లిక్ చేయండి లేదా అక్కడి వరకు లాగండి. లేదంటే, నిర్దిష్ట స్థలాన్ని హైలైట్ చేసి, శోధన + S కీలు ఉపయోగించండి.</translation> <translation id="1076698951459398590">థీమ్ను ప్రారంభించు</translation> <translation id="1076818208934827215">Microsoft Internet Explorer</translation> <translation id="1077946062898560804">అందరు వినియోగదారులకి ఆటోమేటిక్ అప్డేట్లను సెట్ చెయ్యి</translation> @@ -454,7 +453,7 @@ <translation id="1665611772925418501">ఫైల్ను సవరించడం సాధ్యపడదు.</translation> <translation id="1670399744444387456">ప్రాథమికం</translation> <translation id="1673103856845176271">భద్రతా కారణాల దృష్ట్యా ఫైల్ను ప్రాప్యత చేయడం సాధ్యపడదు.</translation> -<translation id="1673137583248014546"><ph name="URL" /> మీ భద్రతా కీ యొక్క తయారీ మరియు మోడల్ని చూడాలనుకుంటోంది</translation> +<translation id="1673137583248014546"><ph name="URL" /> మీ భద్రతా కీ యొక్క తయారీదారు బ్రాండ్ పేరు మరియు మోడల్ని చూడాలనుకుంటోంది</translation> <translation id="167832068858235403">వాల్యూ. తగ్గించు</translation> <translation id="1679068421605151609">డెవలపర్ సాధనాలు</translation> <translation id="16815041330799488">క్లిప్బోర్డ్కు కాపీ చేసిన వచనం మరియు చిత్రాలను చూడటానికి సైట్లను అనుమతించవద్దు</translation> @@ -1387,7 +1386,7 @@ <translation id="3090871774332213558">"<ph name="DEVICE_NAME" />" జత చేయబడింది</translation> <translation id="3100609564180505575">మాడ్యూళ్ళు (<ph name="TOTAL_COUNT" />) - తెలిసిన వైరుధ్యాలు: <ph name="BAD_COUNT" />, అనుమానించినవి: <ph name="SUSPICIOUS_COUNT" /></translation> <translation id="3101709781009526431">తేదీ మరియు సమయం</translation> -<translation id="310671807099593501">బ్లూటూత్ని సైట్ ఉపయోగిస్తోంది</translation> +<translation id="310671807099593501">సైట్ బ్లూటూత్ని ఉపయోగిస్తోంది</translation> <translation id="3108967419958202225">ఎంచుకోండి...</translation> <translation id="3115128645424181617">మీ ఫోన్ను కనుగొనలేము. అది చేతికి అందేంత దగ్గర్లో ఉందని మరియు బ్లూటూత్ ఆన్ చేసి ఉన్నట్లు నిర్ధారించుకోండి.</translation> <translation id="3115147772012638511">కాష్ కోసం వేచి ఉంది...</translation> @@ -3638,7 +3637,7 @@ <translation id="6718273304615422081">జిప్ చేస్తోంది...</translation> <translation id="671928215901716392">స్క్రీన్ను లాక్ చేయి</translation> <translation id="67211069045302358">ఈ సైట్ కోసం సెట్టింగ్లను రీసెట్ చేయాలా?</translation> -<translation id="6721678857435001674">మీ భద్రతా కీ తయారీ మరియు మోడల్ని చూడండి</translation> +<translation id="6721678857435001674">మీ భద్రతా కీ యొక్క తయారీదారు బ్రాండ్ పేరు మరియు మోడల్ని చూడండి</translation> <translation id="6721972322305477112">&ఫైల్</translation> <translation id="672213144943476270">దయచేసి అతిథి వలె బ్రౌజ్ చేయబోయే ముందు మీ ప్రొఫైల్ను అన్లాక్ చేయండి.</translation> <translation id="6723354935081862304">Google డాక్స్కు మరియు ఇతర మేఘ గమ్యస్థానాలకు ముద్రించండి. Google మేఘ ముద్రణకు ముద్రించడానికి <ph name="BEGIN_LINK" />సైన్ ఇన్ చేయండి<ph name="END_LINK" />.</translation> @@ -3792,7 +3791,6 @@ <translation id="6979737339423435258">మొత్తం సమయం</translation> <translation id="6980462514016882061">శోధన, ప్రకటనలు మరియు ఇతర Google సేవలను వ్యక్తిగతీకరించడం కోసం Google మీ బ్రౌజింగ్ చరిత్రను ఉపయోగించవచ్చు</translation> <translation id="6981982820502123353">ప్రాప్యత</translation> -<translation id="6983201004195852174">శోధించుని నొక్కి, పట్టుకుని, గట్టిగా చదవాల్సిన కంటెంట్ని క్లిక్ చేయండి లేదా లాగడం ద్వారా ఎంచుకోండి</translation> <translation id="6983783921975806247">రిజిస్టర్ చేసిన OID</translation> <translation id="6983991971286645866">అన్ని సవరణలు $1కి సేవ్ చేయబడతాయి.</translation> <translation id="6984299437918708277">సైన్-ఇన్ స్క్రీన్లో మీ ఖాతా కోసం ప్రదర్శించడానికి చిత్రాన్ని ఎంచుకోండి</translation> @@ -4224,7 +4222,7 @@ <translation id="7665369617277396874">ఖాతాను జోడించండి</translation> <translation id="7671130400130574146">సిస్టమ్ శీర్షిక బార్ మరియు హద్దులను ఉపయోగించు</translation> <translation id="7672520070349703697"><ph name="HUNG_IFRAME_URL" />, <ph name="PAGE_TITLE" />లో.</translation> -<translation id="7681095912841365527">బ్లూటూత్ని సైట్ ఉపయోగించవచ్చు</translation> +<translation id="7681095912841365527">సైట్ బ్లూటూత్ని ఉపయోగించవచ్చు</translation> <translation id="7683373461016844951">కొనసాగించాలంటే, సరే క్లిక్ చేసి, ఆపై మీ <ph name="DOMAIN" /> ఇమెయిల్ చిరునామా కోసం కొత్త ప్రొఫైల్ను సృష్టించడానికి వ్యక్తిని జోడించు క్లిక్ చేయండి.</translation> <translation id="7684212569183643648">మీ నిర్వాహకుడు ఇన్స్టాల్ చేసారు</translation> <translation id="7684559058815332124">క్యాప్టివ్ పోర్టల్ లాగిన్ పేజీని సందర్శించండి</translation>
diff --git a/chrome/app/resources/generated_resources_th.xtb b/chrome/app/resources/generated_resources_th.xtb index cb7aeb4a..9e3b7ad3 100644 --- a/chrome/app/resources/generated_resources_th.xtb +++ b/chrome/app/resources/generated_resources_th.xtb
@@ -51,7 +51,6 @@ <ph name="EXTENSION_NAME" /></translation> <translation id="1071917609930274619">การเข้ารหัสข้อมูล</translation> -<translation id="1074944608454986967">หากต้องการให้อ่านออกเสียงเนื้อหา ให้กดแป้น Search ค้างไว้ จากนั้นคลิกหรือลากเพื่อเลือกเนื้อหา หรือไฮไลต์บริเวณที่ต้องการแล้วใช้แป้น Search + S</translation> <translation id="1076698951459398590">เปิดใช้ธีม</translation> <translation id="1076818208934827215">Microsoft Internet Explorer</translation> <translation id="1077946062898560804">ติดตั้งการอัปเดตอัตโนมัติสำหรับผู้ใช้ทั้งหมด</translation> @@ -685,7 +684,7 @@ <translation id="2071393345806050157">ไม่มีไฟล์บันทึกในเครื่อง</translation> <translation id="2074527029802029717">ยกเลิกการตรึงแท็บ</translation> <translation id="2075474481720804517">แบตเตอรี่ <ph name="BATTERY_PERCENTAGE" />%</translation> -<translation id="2075959085554270910">ให้คุณเปิด/ปิดใช้การแตะเพื่อคลิกและการแตะแล้วลาก</translation> +<translation id="2075959085554270910">ช่วยให้คุณเปิด/ปิดใช้การแตะเพื่อคลิกและการแตะแล้วลากได้</translation> <translation id="2076269580855484719">ซ่อนปลั๊กอินนี้</translation> <translation id="2076672359661571384">กลาง (แนะนำ)</translation> <translation id="2077129598763517140">ใช้การเร่งฮาร์ดแวร์เมื่อสามารถใช้ได้</translation> @@ -3792,7 +3791,6 @@ <translation id="6979737339423435258">ตั้งแต่ต้น</translation> <translation id="6980462514016882061">Google อาจใช้ประวัติการท่องเว็บของคุณเพื่อปรับเปลี่ยนการค้นหา โฆษณา และบริการอื่นๆ ของ Google ในแบบของคุณ</translation> <translation id="6981982820502123353">การเข้าถึง</translation> -<translation id="6983201004195852174">กดแป้น Search ค้างไว้แล้วคลิกหรือลากเพื่อเลือกเนื้อหาที่จะให้อ่านออกเสียง</translation> <translation id="6983783921975806247">OID ที่ลงทะเบียนแล้ว</translation> <translation id="6983991971286645866">การแก้ไขทั้งหมดจะบันทึกเป็น $1</translation> <translation id="6984299437918708277">เลือกรูปภาพสำหรับบัญชีของคุณเพื่อแสดงในหน้าลงชื่อเข้าใช้</translation>
diff --git a/chrome/app/resources/generated_resources_tr.xtb b/chrome/app/resources/generated_resources_tr.xtb index 0d0f5ea..f99e8a1 100644 --- a/chrome/app/resources/generated_resources_tr.xtb +++ b/chrome/app/resources/generated_resources_tr.xtb
@@ -51,7 +51,6 @@ <ph name="EXTENSION_NAME" /></translation> <translation id="1071917609930274619">Veri Şifreleme</translation> -<translation id="1074944608454986967">İçeriği yüksek sesle okumak için Ara'yı basılı tutun, ardından tıklayarak veya tıklayıp sürükleyerek içeriği seçin. İsterseniz bir bölgeyi vurgulayıp Ara + S tuşlarını kullanabilirsiniz.</translation> <translation id="1076698951459398590">Temayı Etkinleştir</translation> <translation id="1076818208934827215">Microsoft Internet Explorer</translation> <translation id="1077946062898560804">Tüm Kullanıcılar İçin Otomatik Güncellemeleri Ayarla</translation> @@ -3793,7 +3792,6 @@ <translation id="6979737339423435258">Tüm zamanlar</translation> <translation id="6980462514016882061">Google; Arama, reklamlar ve diğer Google hizmetlerini kişiselleştirmek için tarama geçmişinizi kullanabilir</translation> <translation id="6981982820502123353">Erişilebilirlik</translation> -<translation id="6983201004195852174">Ara'ya basın ve basılı tutun, ardından sesli olarak okunacak içeriği seçmek üzere tıklayın veya sürükleyin</translation> <translation id="6983783921975806247">Kayıtlı OID</translation> <translation id="6983991971286645866">Tüm düzenlemeler $1 dosyasına kaydedilecektir.</translation> <translation id="6984299437918708277">Oturum açma ekranında hesabınız için görüntülenecek bir resim seçin</translation>
diff --git a/chrome/app/resources/generated_resources_uk.xtb b/chrome/app/resources/generated_resources_uk.xtb index 645a72d..8c92e4d2 100644 --- a/chrome/app/resources/generated_resources_uk.xtb +++ b/chrome/app/resources/generated_resources_uk.xtb
@@ -51,7 +51,6 @@ <ph name="EXTENSION_NAME" /></translation> <translation id="1071917609930274619">Шифрування даних</translation> -<translation id="1074944608454986967">Щоб озвучити вміст, утримуйте клавішу "Пошук", а потім натисніть чи потягніть рамку, щоб виділити вміст. Або виділіть область і натисніть "Пошук" + S.</translation> <translation id="1076698951459398590">Увімкнути тему</translation> <translation id="1076818208934827215">Microsoft Internet Explorer</translation> <translation id="1077946062898560804">Налаштувати автоматичні оновлення для всіх користувачів</translation> @@ -3792,7 +3791,6 @@ <translation id="6979737339423435258">Весь час</translation> <translation id="6980462514016882061">Google може використовувати вашу історію веб-перегляду, щоб персоналізувати Пошук, оголошення й інші служби Google</translation> <translation id="6981982820502123353">Доступність</translation> -<translation id="6983201004195852174">Натисніть і утримуйте клавішу "Пошук", а потім натисніть або потягніть курсор, щоб вибрати вміст для читання вголос</translation> <translation id="6983783921975806247">Зареєстрований ідентифікатор об'єкта (OID)</translation> <translation id="6983991971286645866">Усі зміни буде збережено у файлі "$1".</translation> <translation id="6984299437918708277">Виберіть зображення облікового запису, яке відображатиметься на екрані входу</translation>
diff --git a/chrome/app/resources/generated_resources_vi.xtb b/chrome/app/resources/generated_resources_vi.xtb index 361d778..9faceb19 100644 --- a/chrome/app/resources/generated_resources_vi.xtb +++ b/chrome/app/resources/generated_resources_vi.xtb
@@ -51,7 +51,6 @@ <ph name="EXTENSION_NAME" /></translation> <translation id="1071917609930274619">Mã hóa Dữ liệu</translation> -<translation id="1074944608454986967">Để đọc to nội dung, hãy nhấn và giữ phím Tìm kiếm, sau đó nhấp hoặc kéo để chọn nội dung. Hoặc đánh dấu một vùng và sử dụng tổ hợp phím Tìm kiếm + S.</translation> <translation id="1076698951459398590">Bật chủ đề</translation> <translation id="1076818208934827215">Microsoft Internet Explorer</translation> <translation id="1077946062898560804">Thiết lập Cập nhật Tự động cho Tất cả Người dùng</translation> @@ -3793,7 +3792,6 @@ <translation id="6979737339423435258">Từ trước đến nay</translation> <translation id="6980462514016882061">Google có thể sử dụng lịch sử duyệt web của bạn để cá nhân hóa Tìm kiếm, quảng cáo và các dịch vụ khác của Google</translation> <translation id="6981982820502123353">Truy cập</translation> -<translation id="6983201004195852174">Nhấn và giữ Tìm kiếm, sau đó nhấp hoặc kéo để chọn nội dung cần đọc to</translation> <translation id="6983783921975806247">OID đã Đăng ký</translation> <translation id="6983991971286645866">Tất cả các chỉnh sửa sẽ được lưu vào $1.</translation> <translation id="6984299437918708277">Chọn hình ảnh để hiển thị cho tài khoản của bạn trên màn hình đăng nhập</translation>
diff --git a/chrome/app/resources/generated_resources_zh-CN.xtb b/chrome/app/resources/generated_resources_zh-CN.xtb index cb22664..c8ff9584 100644 --- a/chrome/app/resources/generated_resources_zh-CN.xtb +++ b/chrome/app/resources/generated_resources_zh-CN.xtb
@@ -51,7 +51,6 @@ <ph name="EXTENSION_NAME" /></translation> <translation id="1071917609930274619">数据加密</translation> -<translation id="1074944608454986967">您可通过以下方法让系统读出屏幕上显示的内容:按住搜索键,然后通过点击或拖动鼠标来选择所需内容;或者,突出显示相应区域,然后使用“搜索键 + S”组合键。</translation> <translation id="1076698951459398590">启用主题背景</translation> <translation id="1076818208934827215">Microsoft Internet Explorer</translation> <translation id="1077946062898560804">为所有用户设置自动更新</translation> @@ -3778,7 +3777,6 @@ <translation id="6979737339423435258">时间不限</translation> <translation id="6980462514016882061">Google 可能会利用您的浏览记录为您提供个性化的 Google 搜索、广告和其他 Google 服务</translation> <translation id="6981982820502123353">无障碍</translation> -<translation id="6983201004195852174">按住搜索键,然后点击或拖动以选择要让系统大声朗读的内容</translation> <translation id="6983783921975806247">已注册的 OID</translation> <translation id="6983991971286645866">所有修改都会被保存到 $1。</translation> <translation id="6984299437918708277">选择您的帐号在登录屏幕上的显示图片</translation>
diff --git a/chrome/app/resources/generated_resources_zh-TW.xtb b/chrome/app/resources/generated_resources_zh-TW.xtb index ce8e117..082c2fe 100644 --- a/chrome/app/resources/generated_resources_zh-TW.xtb +++ b/chrome/app/resources/generated_resources_zh-TW.xtb
@@ -51,7 +51,6 @@ <ph name="EXTENSION_NAME" /></translation> <translation id="1071917609930274619">資料編密</translation> -<translation id="1074944608454986967">如要朗讀內容,請按住搜尋鍵,然後以點選或拖曳方式選取內容。或者先讓特定區域醒目顯示,再按下搜尋鍵 + S 鍵。</translation> <translation id="1076698951459398590">啟用主題</translation> <translation id="1076818208934827215">Microsoft Internet Explorer</translation> <translation id="1077946062898560804">為所有使用者設定自動更新</translation> @@ -3789,7 +3788,6 @@ <translation id="6979737339423435258">不限時間</translation> <translation id="6980462514016882061">Google 可能會使用您的瀏覽紀錄,為您提供個人化的搜尋服務、廣告內容和其他各項 Google 服務</translation> <translation id="6981982820502123353">協助工具</translation> -<translation id="6983201004195852174">按住搜尋鍵,然後以點選或拖曳方式選取要朗讀的內容</translation> <translation id="6983783921975806247">已註冊的 OID</translation> <translation id="6983991971286645866">所有編輯內容都會儲存到「$1」。</translation> <translation id="6984299437918708277">請選擇登入畫面上的個人帳戶圖片</translation>
diff --git a/chrome/app/resources/google_chrome_strings_da.xtb b/chrome/app/resources/google_chrome_strings_da.xtb index f595b15..f03dee8 100644 --- a/chrome/app/resources/google_chrome_strings_da.xtb +++ b/chrome/app/resources/google_chrome_strings_da.xtb
@@ -91,7 +91,7 @@ Du kan forhindre <ph name="NEW_PROFILE_NAME" /> i at få adgang til din konto ved at låse din profil, når du ikke bruger Chrome. Du gør dette ved at klikke på dit profilnavn øverst til højre i browseren og vælge "Afslut, og aktivér børnesikring". <ph name="BEGIN_LINK_2" />Få flere oplysninger<ph name="END_LINK_2" /> -Gå til din e-mail på <ph name="ACCOUNT_EMAIL" /> for at få yderligere vejledning.</translation> +Gå til din mail på <ph name="ACCOUNT_EMAIL" /> for at få yderligere vejledning.</translation> <translation id="3282568296779691940">Log ind i Chrome</translation> <translation id="3360895254066713204">Hjælp til Chrome</translation> <translation id="3395323229510056640">Få hjælp til Chrome OS</translation>
diff --git a/chrome/browser/BUILD.gn b/chrome/browser/BUILD.gn index 918255a1..b991cae 100644 --- a/chrome/browser/BUILD.gn +++ b/chrome/browser/BUILD.gn
@@ -2610,8 +2610,6 @@ "resource_coordinator/background_tab_navigation_throttle.h", "resource_coordinator/discard_metrics_lifecycle_unit_observer.cc", "resource_coordinator/discard_metrics_lifecycle_unit_observer.h", - "resource_coordinator/discard_metrics_util.cc", - "resource_coordinator/discard_metrics_util.h", "resource_coordinator/discard_reason.h", "resource_coordinator/lifecycle_unit.cc", "resource_coordinator/lifecycle_unit.h", @@ -2646,8 +2644,6 @@ "resource_coordinator/tab_manager_web_contents_data.h", "resource_coordinator/tab_metrics_logger.cc", "resource_coordinator/tab_metrics_logger.h", - "resource_coordinator/tab_stats.cc", - "resource_coordinator/tab_stats.h", "resource_coordinator/time.cc", "resource_coordinator/time.h", "search/iframe_source.cc",
diff --git a/chrome/browser/about_flags.cc b/chrome/browser/about_flags.cc index 60af9d1..9c9f598 100644 --- a/chrome/browser/about_flags.cc +++ b/chrome/browser/about_flags.cc
@@ -3485,9 +3485,9 @@ FEATURE_VALUE_TYPE(features::kEnablePixelCanvasRecording)}, #if defined(OS_CHROMEOS) - {"disable-tablet-splitview", flag_descriptions::kDisableTabletSplitViewName, - flag_descriptions::kDisableTabletSplitViewDescription, kOsCrOS, - SINGLE_VALUE_TYPE(ash::switches::kAshDisableTabletSplitView)}, + {"enable-tablet-splitview", flag_descriptions::kEnableTabletSplitViewName, + flag_descriptions::kEnableTabletSplitViewDescription, kOsCrOS, + SINGLE_VALUE_TYPE(ash::switches::kAshEnableTabletSplitView)}, #endif // defined(OS_CHROMEOS) {"enable-parallel-downloading", flag_descriptions::kParallelDownloadingName,
diff --git a/chrome/browser/android/vr/vr_shell_gl.cc b/chrome/browser/android/vr/vr_shell_gl.cc index 04ac70ad..4e2ebdb 100644 --- a/chrome/browser/android/vr/vr_shell_gl.cc +++ b/chrome/browser/android/vr/vr_shell_gl.cc
@@ -336,18 +336,18 @@ OnVSync(base::TimeTicks::Now()); } -bool VrShellGl::WebVrCanSubmitFrame() { +bool VrShellGl::WebVrCanProcessFrame() { return mailbox_bridge_ready_ && !webvr_frame_processing_; } -void VrShellGl::WebVrTryDeferredSubmit() { - if (!webvr_deferred_mojo_submit_ || !WebVrCanSubmitFrame()) +void VrShellGl::WebVrTryDeferredProcessing() { + if (!webvr_deferred_start_processing_ || !WebVrCanProcessFrame()) return; DVLOG(2) << "Running deferred SubmitFrame"; // Run synchronously, not via PostTask, to ensure we don't // get a new SendVSync scheduling in between. - base::ResetAndReturn(&webvr_deferred_mojo_submit_).Run(); + base::ResetAndReturn(&webvr_deferred_start_processing_).Run(); } void VrShellGl::OnGpuProcessConnectionReady() { @@ -355,7 +355,7 @@ mailbox_bridge_ready_ = true; // We might have a deferred submit that was waiting for // mailbox_bridge_ready_. - WebVrTryDeferredSubmit(); + WebVrTryDeferredProcessing(); } void VrShellGl::CreateOrResizeWebVRSurface(const gfx::Size& size) { @@ -402,26 +402,13 @@ if (!submit_client_.get()) return; - if (!WebVrCanSubmitFrame()) { - DVLOG(2) << "Deferring SubmitFrame, not ready"; - DCHECK(!webvr_deferred_mojo_submit_); - webvr_deferred_mojo_submit_ = - base::BindOnce(&VrShellGl::SubmitFrame, weak_ptr_factory_.GetWeakPtr(), - frame_index, mailbox, time_waited); - return; - } - if (frame_index < 0 || !webvr_frame_oustanding_[frame_index % kPoseRingBufferSize]) { mojo::ReportBadMessage("SubmitFrame called with an invalid frame_index"); binding_.Close(); return; } - webvr_frame_processing_ = true; - OnNewWebVRFrame(); - webvr_time_js_submit_[frame_index % kPoseRingBufferSize] = - base::TimeTicks::Now(); // The JavaScript wait time is supplied externally and not trustworthy. Clamp // to a reasonable range to avoid math errors. @@ -433,6 +420,27 @@ TRACE_COUNTER1("gpu", "WebVR JS wait (ms)", webvr_js_wait_time_.GetAverage().InMilliseconds()); + webvr_time_js_submit_[frame_index % kPoseRingBufferSize] = + base::TimeTicks::Now(); + + if (WebVrCanProcessFrame()) { + ProcessWebVrFrame(frame_index, mailbox); + } else { + DVLOG(2) << "Deferring processing frame, not ready"; + DCHECK(!webvr_deferred_start_processing_); + webvr_deferred_start_processing_ = + base::BindOnce(&VrShellGl::ProcessWebVrFrame, + weak_ptr_factory_.GetWeakPtr(), frame_index, mailbox); + } +} + +void VrShellGl::ProcessWebVrFrame(int16_t frame_index, + const gpu::MailboxHolder& mailbox) { + TRACE_EVENT0("gpu", __FUNCTION__); + // Transition frame from "animating" to "processing" state. + webvr_frame_processing_ = true; + OnNewWebVRFrame(); + // Swapping twice on a Surface without calling updateTexImage in // between can lose frames, so don't draw+swap if we already have // a pending frame we haven't consumed yet. @@ -454,6 +462,10 @@ // OnWebVRFrameAvailable where we'd normally report that. submit_client_->OnSubmitFrameRendered(); } + + // Unblock the next animating frame in case it was waiting for this + // one to start processing. + WebVrTryStartAnimatingFrame(false); } void VrShellGl::SubmitFrameWithTextureHandle( @@ -1357,9 +1369,6 @@ // but the logic is a bit complicated. if (frame_index >= 0) { webvr_frame_processing_ = false; - // If we have a waiting submit that arrived while processing this one, - // handle it now. - WebVrTryDeferredSubmit(); } } @@ -1368,6 +1377,13 @@ vr_ui_fps_meter_.AddFrame(base::TimeTicks::Now()); DVLOG(1) << "fps: " << vr_ui_fps_meter_.GetFPS(); TRACE_COUNTER1("gpu", "VR UI FPS", vr_ui_fps_meter_.GetFPS()); + + if (ShouldDrawWebVr()) { + // We finished processing a frame, this may make pending WebVR + // work eligible to proceed. + WebVrTryDeferredProcessing(); + WebVrTryStartAnimatingFrame(false); + } } bool VrShellGl::ShouldDrawWebVr() { @@ -1434,8 +1450,10 @@ ClosePresentationBindings(); // Ensure that re-entering VR later gets a fresh start by clearing out the // current session's animating and processing frame state. - webvr_deferred_mojo_submit_.Reset(); + webvr_frame_oustanding_.assign(kPoseRingBufferSize, false); + webvr_deferred_start_processing_.Reset(); webvr_frame_processing_ = false; + last_ui_allows_sending_webvr_vsync_ = false; } } @@ -1457,6 +1475,78 @@ return ui_->GetBrowserUiWeakPtr(); } +bool VrShellGl::WebVrCanAnimateFrame(bool is_from_onvsync) { + // This check needs to be first to ensure that we start the WebVR + // first-frame timeout on presentation start. + bool can_send_webvr_vsync = ui_->CanSendWebVrVSync(); + if (!last_ui_allows_sending_webvr_vsync_ && can_send_webvr_vsync) { + // We will start sending vsync to the WebVR page, so schedule the incoming + // frame timeout. + ScheduleOrCancelWebVrFrameTimeout(); + } + last_ui_allows_sending_webvr_vsync_ = can_send_webvr_vsync; + if (!can_send_webvr_vsync) { + DVLOG(2) << __FUNCTION__ << ": waiting for can_send_webvr_vsync"; + return false; + } + + // If we want to send vsync-aligned frames, we only allow animation to start + // when called from OnVSync, so if we're called from somewhere else we can + // skip all the other checks. Legacy Cardboard mode (not surfaceless) doesn't + // use vsync aligned frames, and there's a flag to disable it for surfaceless + // mode. + if (surfaceless_rendering_ && webvr_vsync_align_ && !is_from_onvsync) { + DVLOG(3) << __FUNCTION__ << ": waiting for onvsync (vsync aligned)"; + return false; + } + + if (get_vsync_callback_.is_null()) { + DVLOG(2) << __FUNCTION__ << ": waiting for get_vsync_callback_"; + return false; + } + + if (!pending_vsync_) { + DVLOG(2) << __FUNCTION__ << ": waiting for pending_vsync (too fast)"; + return false; + } + + // If the previous frame deferred starting processing, that frame is still + // considered the current animating frame, so we must wait for that to + // transition to processing before sending the next VSync. Don't check + // WebVrCanProcessFrame() here - we intentionally want to allow the first + // VSync to go out before mailbox_bridge_ready_ becomes true. The first + // SubmitFrame will be deferred if needed. + if (webvr_deferred_start_processing_) { + DVLOG(2) << __FUNCTION__ + << ": waiting for previous frame to start processing"; + return false; + } + + // Keep the heuristic tests last since they update a trace counter, they + // should only be run if the remaining criteria are already met. There's no + // corresponding WebVrTryStartAnimating call for this, the retries happen + // via OnVSync. + bool still_rendering = WebVrHasSlowRenderingFrame(); + bool overstuffed = WebVrHasOverstuffedBuffers(); + TRACE_COUNTER2("gpu", "WebVR frame skip", "still rendering", still_rendering, + "overstuffed", overstuffed); + if (still_rendering || overstuffed) { + DVLOG(2) << __FUNCTION__ << ": waiting for backlogged frames," + << " still_rendering=" << still_rendering + << " overstuffed=" << overstuffed; + return false; + } + + DVLOG(2) << __FUNCTION__ << ": ready to animate frame"; + return true; +} + +void VrShellGl::WebVrTryStartAnimatingFrame(bool is_from_onvsync) { + if (WebVrCanAnimateFrame(is_from_onvsync)) { + SendVSync(); + } +} + void VrShellGl::OnVSync(base::TimeTicks frame_time) { TRACE_EVENT0("gpu", "VrShellGl::OnVSync"); // Create a synthetic VSync trace event for the reported last-VSync time. Use @@ -1476,25 +1566,10 @@ vsync_helper_.RequestVSync( base::BindRepeating(&VrShellGl::OnVSync, base::Unretained(this))); - bool can_send_webvr_vsync = ui_->CanSendWebVrVSync(); - if (!last_should_send_webvr_vsync_ && can_send_webvr_vsync) { - // We will start sending vsync to the WebVR page, so schedule the first - // frame timeout. - ScheduleOrCancelWebVrFrameTimeout(); - } - last_should_send_webvr_vsync_ = can_send_webvr_vsync; + pending_vsync_ = true; + pending_time_ = frame_time; + WebVrTryStartAnimatingFrame(true); - // Process WebVR presenting VSync (VRDisplay rAF). - if (!callback_.is_null() && can_send_webvr_vsync) { - // A callback was stored by GetVSync. Use it now for sending a VSync. - SendVSync(frame_time, base::ResetAndReturn(&callback_)); - } else { - // We don't have a callback yet. Mark that there's a pending VSync - // to indicate that the next GetVSync is allowed to call SendVSync - // immediately. - pending_vsync_ = true; - pending_time_ = frame_time; - } if (ShouldDrawWebVr()) { // When drawing WebVR, controller input doesn't need to be synchronized with // rendering as WebVR uses the gamepad api. To ensure we always handle input @@ -1509,22 +1584,15 @@ } void VrShellGl::GetVSync(GetVSyncCallback callback) { - // In surfaceless (reprojecting) rendering, stay locked - // to vsync intervals. Otherwise, for legacy Cardboard mode, - // run requested animation frames now if it missed a vsync. - if ((surfaceless_rendering_ && webvr_vsync_align_) || !pending_vsync_ || - !ui_->CanSendWebVrVSync()) { - if (!callback_.is_null()) { - mojo::ReportBadMessage( - "Requested VSync before waiting for response to previous request."); - ClosePresentationBindings(); - return; - } - callback_ = std::move(callback); + TRACE_EVENT0("gpu", __FUNCTION__); + if (!get_vsync_callback_.is_null()) { + mojo::ReportBadMessage( + "Requested VSync before waiting for response to previous request."); + ClosePresentationBindings(); return; } - pending_vsync_ = false; - SendVSync(pending_time_, std::move(callback)); + get_vsync_callback_ = std::move(callback); + WebVrTryStartAnimatingFrame(false); } void VrShellGl::ForceExitVr() { @@ -1597,15 +1665,7 @@ return expected_frame_time; } -bool VrShellGl::ShouldSkipVSync() { - // If we appear to be backlogged, don't send additional VSyncs. Don't check - // WebVrCanSubmit() here - we intentionally want to allow the first VSync to - // go out before mailbox_bridge_ready_ becomes true. The first SubmitFrame - // will be deferred if needed, and we'll throttle here to avoid requesting - // more frames until that's done. - if (webvr_deferred_mojo_submit_) - return true; - +bool VrShellGl::WebVrHasSlowRenderingFrame() { // Disable heuristic for traditional render path where we submit completed // frames. if (!webvr_use_gpu_fence_) @@ -1621,7 +1681,6 @@ // Also, AddWebVrRenderTimeEstimate zeroes the submit time once the rendered // frame is complete. In all of those cases, we don't need to wait for render // completion. - bool still_rendering = false; int16_t prev_idx = (next_frame_index_ + kPoseRingBufferSize - 2) % kPoseRingBufferSize; base::TimeTicks prev_js_submit = webvr_time_js_submit_[prev_idx]; @@ -1641,34 +1700,38 @@ // this VSync if we'd arrive a full VSync interval early. if (mean_js_time - mean_js_wait + frame_interval < prev_render_time_left + frame_interval * 3 / 4) { - still_rendering = true; + return true; } } + return false; +} - bool overstuffed = false; +bool VrShellGl::WebVrHasOverstuffedBuffers() { + base::TimeDelta frame_interval = vsync_helper_.DisplayVSyncInterval(); + base::TimeDelta mean_render_time = + webvr_render_time_.GetAverageOrDefault(frame_interval); + if (webvr_unstuff_ratelimit_frames_ > 0) { --webvr_unstuff_ratelimit_frames_; } else if (webvr_acquire_time_.GetAverage() >= kWebVrSlowAcquireThreshold && mean_render_time < frame_interval) { - overstuffed = true; + // This is a fast app with average render time less than the frame + // interval. If GVR acquire is slow, that means its internal swap chain was + // already full when we tried to give it the next frame. We can skip a + // SendVSync to drain one frame from the GVR queue. That should reduce + // latency by one frame. webvr_unstuff_ratelimit_frames_ = kWebVrUnstuffMaxDropRate; + return true; } - TRACE_COUNTER2("gpu", "WebVR frame skip", "still rendering", still_rendering, - "overstuffed", overstuffed); - - return still_rendering | overstuffed; + return false; } -void VrShellGl::SendVSync(base::TimeTicks time, GetVSyncCallback callback) { - // There must not be a stored callback at this point, callers should use - // ResetAndReturn to clear it before calling this method. - DCHECK(!callback_); +void VrShellGl::SendVSync() { + DCHECK(!get_vsync_callback_.is_null()); + DCHECK(pending_vsync_); - if (ShouldSkipVSync()) { - callback_ = std::move(callback); - DVLOG(2) << __FUNCTION__ << ": ShouldSkipVSync()=true"; - return; - } + // Mark the VSync as consumed. + pending_vsync_ = false; // next_frame_index_ is an uint8_t that generates a wrapping 0.255 frame // number. We store it in an int16_t to match mojo APIs, and to avoid it @@ -1706,19 +1769,19 @@ // frame. webvr_time_js_submit_[frame_index % kPoseRingBufferSize] = base::TimeTicks(); - std::move(callback).Run( - std::move(pose), time - base::TimeTicks(), frame_index, - device::mojom::VRPresentationProvider::VSyncStatus::SUCCESS); + base::ResetAndReturn(&get_vsync_callback_) + .Run(std::move(pose), pending_time_ - base::TimeTicks(), frame_index, + device::mojom::VRPresentationProvider::VSyncStatus::SUCCESS); } void VrShellGl::ClosePresentationBindings() { webvr_frame_timeout_.Cancel(); submit_client_.reset(); - if (!callback_.is_null()) { + if (!get_vsync_callback_.is_null()) { // When this Presentation provider is going away we have to respond to // pending callbacks, so instead of providing a VSync, tell the requester // the connection is closing. - base::ResetAndReturn(&callback_) + base::ResetAndReturn(&get_vsync_callback_) .Run(nullptr, base::TimeDelta(), -1, device::mojom::VRPresentationProvider::VSyncStatus::CLOSING); }
diff --git a/chrome/browser/android/vr/vr_shell_gl.h b/chrome/browser/android/vr/vr_shell_gl.h index 23da9bc4..93b15049 100644 --- a/chrome/browser/android/vr/vr_shell_gl.h +++ b/chrome/browser/android/vr/vr_shell_gl.h
@@ -189,16 +189,32 @@ void ForceExitVr(); - bool ShouldSkipVSync(); - void SendVSync(base::TimeTicks time, GetVSyncCallback callback); + // Sends a GetVSync response to the presentation client. + void SendVSync(); - // Checks if we're in a valid state for submitting a frame. Invalid states - // include mailbox_bridge_ready_ being false, or overlapping processing - // frames. - bool WebVrCanSubmitFrame(); - // Call this after state changes that could result in WebVrCanSubmitFrame + // Heuristics to avoid excessive backlogged frames. + bool WebVrHasSlowRenderingFrame(); + bool WebVrHasOverstuffedBuffers(); + + // Checks if we're in a valid state for starting animation of a new frame. + // Invalid states include a previous animating frame that's not complete + // yet (including deferred processing not having started yet), or timing + // heuristics indicating that it should be retried later. + bool WebVrCanAnimateFrame(bool is_from_onvsync); + // Call this after state changes that could result in WebVrCanAnimateFrame // becoming true. - void WebVrTryDeferredSubmit(); + void WebVrTryStartAnimatingFrame(bool is_from_onvsync); + + // Checks if we're in a valid state for processing the current animating + // frame. Invalid states include mailbox_bridge_ready_ being false, or an + // already existing processing frame that's not done yet. + bool WebVrCanProcessFrame(); + // Call this after state changes that could result in WebVrCanProcessFrame + // becoming true. + void WebVrTryDeferredProcessing(); + // Transition a frame from animating to processing. + void ProcessWebVrFrame(int16_t frame_index, + const gpu::MailboxHolder& mailbox); void ClosePresentationBindings(); @@ -280,16 +296,16 @@ scoped_refptr<base::SingleThreadTaskRunner> task_runner_; // Attributes tracking WebVR rAF/VSync animation loop state. Blink schedules - // a callback using the GetVSync mojo call, and the callback is either passed - // to SendVSync immediately, or deferred until the next OnVSync call. + // a callback using the GetVSync mojo call which is stored in + // get_vsync_callback_. The callback is executed by SendVSync once + // WebVrCanAnimateFrame returns true. // - // pending_vsync_ is set to true in OnVSync if there is no current - // outstanding callback, and this means that a future GetVSync is permitted - // to execute SendVSync immediately. If it is false, GetVSync must store the - // pending callback in callback_ for later execution. + // pending_vsync_ is set to true in OnVSync and false in SendVSync. It + // throttles animation to no faster than the VSync rate. The pending_time_ is + // updated in OnVSync and used as the rAF animation timer in SendVSync. base::TimeTicks pending_time_; bool pending_vsync_ = false; - GetVSyncCallback callback_; + GetVSyncCallback get_vsync_callback_; mojo::Binding<device::mojom::VRPresentationProvider> binding_; device::mojom::VRSubmitFrameClientPtr submit_client_; @@ -349,9 +365,9 @@ // for that timespan. bool webvr_frame_processing_ = false; - // If we receive a new SubmitFrame when we're not ready, save it for - // later execution. - base::OnceClosure webvr_deferred_mojo_submit_; + // If we receive a new SubmitFrame when we're not ready, defer start of + // processing for later. + base::OnceClosure webvr_deferred_start_processing_; std::vector<gvr::BufferSpec> specs_; @@ -363,7 +379,10 @@ std::unique_ptr<VrDialog> vr_dialog_; bool showing_vr_dialog_ = false; - bool last_should_send_webvr_vsync_ = false; + // Used by WebVrCanAnimateFrame() to detect when ui_->CanSendWebVrVSync() + // transitions from false to true, as part of starting the incoming frame + // timeout. + bool last_ui_allows_sending_webvr_vsync_ = false; base::WeakPtrFactory<VrShellGl> weak_ptr_factory_;
diff --git a/chrome/browser/apps/guest_view/web_view_interactive_browsertest.cc b/chrome/browser/apps/guest_view/web_view_interactive_browsertest.cc index 592db553..6b529c3 100644 --- a/chrome/browser/apps/guest_view/web_view_interactive_browsertest.cc +++ b/chrome/browser/apps/guest_view/web_view_interactive_browsertest.cc
@@ -1558,9 +1558,14 @@ ASSERT_TRUE(embedder_web_contents()); ASSERT_TRUE(ui_test_utils::ShowAndFocusNativeWindow(GetPlatformAppWindow())); + blink::WebInputEvent::Type context_menu_gesture_event_type = + blink::WebInputEvent::kGestureLongPress; +#if defined(OS_WIN) + context_menu_gesture_event_type = blink::WebInputEvent::kGestureLongTap; +#endif auto filter = std::make_unique<content::InputMsgWatcher>( guest_web_contents()->GetRenderWidgetHostView()->GetRenderWidgetHost(), - blink::WebInputEvent::kGestureLongPress); + context_menu_gesture_event_type); // Wait for guest to load (without this the events never reach the guest). scoped_refptr<content::MessageLoopRunner> message_loop_runner = @@ -1580,8 +1585,7 @@ blink::WebMouseEvent::Button::kLeft, guest_rect.CenterPoint()); - content::SimulateLongPressAt(embedder_web_contents(), - guest_rect.CenterPoint()); + content::SimulateLongTapAt(embedder_web_contents(), guest_rect.CenterPoint()); EXPECT_EQ(content::INPUT_EVENT_ACK_STATE_CONSUMED, filter->GetAckStateWaitIfNecessary());
diff --git a/chrome/browser/autofill/autofill_interactive_uitest.cc b/chrome/browser/autofill/autofill_interactive_uitest.cc index 36c9bf12..a7dbaa89 100644 --- a/chrome/browser/autofill/autofill_interactive_uitest.cc +++ b/chrome/browser/autofill/autofill_interactive_uitest.cc
@@ -1960,7 +1960,14 @@ }; // Test that we can Autofill dynamically generated forms. -IN_PROC_BROWSER_TEST_F(DynamicFormInteractiveTest, DynamicChangingFormFill) { +// Flakily times out on ChromeOS http://crbug.com/827797 +#if defined(OS_CHROMEOS) +#define MAYBE_DynamicChangingFormFill DISABLED_DynamicChangingFormFill +#else +#define MAYBE_DynamicChangingFormFill DynamicChangingFormFill +#endif +IN_PROC_BROWSER_TEST_F(DynamicFormInteractiveTest, + MAYBE_DynamicChangingFormFill) { // Setup that the test expects a re-fill to happen. test_delegate()->SetIsExpectingDynamicRefill(true);
diff --git a/chrome/browser/browser_process_impl.cc b/chrome/browser/browser_process_impl.cc index 6609cd1..b447597 100644 --- a/chrome/browser/browser_process_impl.cc +++ b/chrome/browser/browser_process_impl.cc
@@ -70,6 +70,7 @@ #include "chrome/browser/printing/print_job_manager.h" #include "chrome/browser/printing/print_preview_dialog_controller.h" #include "chrome/browser/profiles/profile_manager.h" +#include "chrome/browser/resource_coordinator/tab_lifecycle_unit_source.h" #include "chrome/browser/safe_browsing/safe_browsing_service.h" #include "chrome/browser/shell_integration.h" #include "chrome/browser/status_icons/status_tray.h" @@ -849,8 +850,12 @@ resource_coordinator::TabManager* BrowserProcessImpl::GetTabManager() { DCHECK_CALLED_ON_VALID_SEQUENCE(sequence_checker_); #if defined(OS_WIN) || defined(OS_MACOSX) || defined(OS_LINUX) - if (!tab_manager_) + if (!tab_manager_) { tab_manager_ = std::make_unique<resource_coordinator::TabManager>(); + tab_lifecycle_unit_source_ = + std::make_unique<resource_coordinator::TabLifecycleUnitSource>(); + tab_lifecycle_unit_source_->AddObserver(tab_manager_.get()); + } return tab_manager_.get(); #else return nullptr;
diff --git a/chrome/browser/browser_process_impl.h b/chrome/browser/browser_process_impl.h index 3e4e388..7db524b 100644 --- a/chrome/browser/browser_process_impl.h +++ b/chrome/browser/browser_process_impl.h
@@ -70,6 +70,10 @@ class PolicyService; } // namespace policy +namespace resource_coordinator { +class TabLifecycleUnitSource; +} + // Real implementation of BrowserProcess that creates and returns the services. class BrowserProcessImpl : public BrowserProcess, public KeepAliveStateObserver { @@ -368,6 +372,8 @@ // Any change to this #ifdef must be reflected as well in // chrome/browser/resource_coordinator/tab_manager_browsertest.cc std::unique_ptr<resource_coordinator::TabManager> tab_manager_; + std::unique_ptr<resource_coordinator::TabLifecycleUnitSource> + tab_lifecycle_unit_source_; #endif shell_integration::DefaultWebClientState cached_default_web_client_state_ =
diff --git a/chrome/browser/chromeos/BUILD.gn b/chrome/browser/chromeos/BUILD.gn index e33ca4d..4ba51bd 100644 --- a/chrome/browser/chromeos/BUILD.gn +++ b/chrome/browser/chromeos/BUILD.gn
@@ -304,8 +304,12 @@ "app_mode/startup_app_launcher_update_checker.h", "apps/intent_helper/apps_navigation_throttle.cc", "apps/intent_helper/apps_navigation_throttle.h", + "apps/intent_helper/apps_navigation_types.cc", + "apps/intent_helper/apps_navigation_types.h", "arc/accessibility/arc_accessibility_helper_bridge.cc", "arc/accessibility/arc_accessibility_helper_bridge.h", + "arc/accessibility/arc_accessibility_util.cc", + "arc/accessibility/arc_accessibility_util.h", "arc/accessibility/ax_tree_source_arc.cc", "arc/accessibility/ax_tree_source_arc.h", "arc/arc_migration_constants.h", @@ -505,6 +509,8 @@ "cryptauth/chrome_cryptauth_service_factory.h", "cryptauth/cryptauth_device_id_provider_impl.cc", "cryptauth/cryptauth_device_id_provider_impl.h", + "cryptauth/gcm_device_info_provider_impl.cc", + "cryptauth/gcm_device_info_provider_impl.h", "customization/customization_document.cc", "customization/customization_document.h", "customization/customization_wallpaper_downloader.cc", @@ -962,6 +968,8 @@ "login/oobe_screen.h", "login/profile_auth_data.cc", "login/profile_auth_data.h", + "login/quick_unlock/auth_token.cc", + "login/quick_unlock/auth_token.h", "login/quick_unlock/fingerprint_storage.cc", "login/quick_unlock/fingerprint_storage.h", "login/quick_unlock/pin_storage.cc", @@ -1817,6 +1825,7 @@ "accessibility/select_to_speak_event_handler_unittest.cc", "accessibility/spoken_feedback_event_rewriter_unittest.cc", "app_mode/startup_app_launcher_unittest.cc", + "apps/intent_helper/apps_navigation_throttle_unittest.cc", "arc/accessibility/arc_accessibility_helper_bridge_unittest.cc", "arc/accessibility/ax_tree_source_arc_unittest.cc", "arc/arc_play_store_enabled_preference_handler_unittest.cc",
diff --git a/chrome/browser/chromeos/accessibility/select_to_speak_event_handler.cc b/chrome/browser/chromeos/accessibility/select_to_speak_event_handler.cc index f73d7e30..815e4c5 100644 --- a/chrome/browser/chromeos/accessibility/select_to_speak_event_handler.cc +++ b/chrome/browser/chromeos/accessibility/select_to_speak_event_handler.cc
@@ -59,8 +59,7 @@ SelectToSpeakEventHandler::~SelectToSpeakEventHandler() { if (aura::Env::GetInstanceDontCreate()) - aura::Env::GetInstanceDontCreate()->AddPreTargetHandler( - this, ui::EventTarget::Priority::kAccessibility); + aura::Env::GetInstanceDontCreate()->RemovePreTargetHandler(this); } void SelectToSpeakEventHandler::CaptureForwardedEventsForTesting(
diff --git a/chrome/browser/chromeos/apps/intent_helper/apps_navigation_throttle.cc b/chrome/browser/chromeos/apps/intent_helper/apps_navigation_throttle.cc index 767e434..c04d33c 100644 --- a/chrome/browser/chromeos/apps/intent_helper/apps_navigation_throttle.cc +++ b/chrome/browser/chromeos/apps/intent_helper/apps_navigation_throttle.cc
@@ -4,15 +4,90 @@ #include "chrome/browser/chromeos/apps/intent_helper/apps_navigation_throttle.h" +#include "base/bind.h" +#include "chrome/browser/chromeos/apps/intent_helper/apps_navigation_types.h" #include "chrome/browser/chromeos/arc/arc_util.h" #include "chrome/browser/chromeos/arc/intent_helper/arc_navigation_throttle.h" #include "chrome/browser/prerender/prerender_contents.h" #include "chrome/browser/profiles/profile.h" +#include "chrome/browser/ui/browser.h" +#include "chrome/browser/ui/browser_commands.h" +#include "chrome/browser/ui/browser_finder.h" +#include "components/arc/intent_helper/page_transition_util.h" #include "content/public/browser/browser_context.h" +#include "content/public/browser/browser_thread.h" #include "content/public/browser/navigation_handle.h" -#include "content/public/browser/navigation_throttle.h" +#include "content/public/browser/site_instance.h" #include "content/public/browser/web_contents.h" +namespace { + +constexpr char kGoogleCom[] = "google.com"; + +// Compares the host name of the referrer and target URL to decide whether +// the navigation needs to be overriden. +bool ShouldOverrideUrlLoading(const GURL& previous_url, + const GURL& current_url) { + // When the navigation is initiated in a web page where sending a referrer + // is disabled, |previous_url| can be empty. In this case, we should open + // it in the desktop browser. + if (!previous_url.is_valid() || previous_url.is_empty()) + return false; + + // Also check |current_url| just in case. + if (!current_url.is_valid() || current_url.is_empty()) { + DVLOG(1) << "Unexpected URL: " << current_url << ", opening it in Chrome."; + return false; + } + + // Check the scheme for both |previous_url| and |current_url| since an + // extension could have referred us (e.g. Google Docs). + if (!current_url.SchemeIsHTTPOrHTTPS() || + !previous_url.SchemeIsHTTPOrHTTPS()) { + return false; + } + + // TODO(dominickn): this was added as a special case for ARC. Reconsider if + // it's necessary for all app platforms. + if (net::registry_controlled_domains::SameDomainOrHost( + current_url, previous_url, + net::registry_controlled_domains::INCLUDE_PRIVATE_REGISTRIES)) { + if (net::registry_controlled_domains::GetDomainAndRegistry( + current_url, + net::registry_controlled_domains::INCLUDE_PRIVATE_REGISTRIES) == + kGoogleCom) { + // Navigation within the google.com domain are good candidates for this + // throttle (and consecuently the picker UI) only if they have different + // hosts, this is because multiple services are hosted within the same + // domain e.g. play.google.com, mail.google.com and so on. + return current_url.host_piece() != previous_url.host_piece(); + } + + return false; + } + return true; +} + +GURL GetStartingGURL(content::NavigationHandle* navigation_handle) { + // This helps us determine a reference GURL for the current NavigationHandle. + // This is the order or preferrence: Referrer > LastCommittedURL > SiteURL, + // GetSiteURL *should* only be used on very rare cases, e.g. when the + // navigation goes from https: to http: on a new tab, thus losing the other + // potential referrers. + const GURL referrer_url = navigation_handle->GetReferrer().url; + if (referrer_url.is_valid() && !referrer_url.is_empty()) + return referrer_url; + + const GURL last_committed_url = + navigation_handle->GetWebContents()->GetLastCommittedURL(); + if (last_committed_url.is_valid() && !last_committed_url.is_empty()) + return last_committed_url; + + return navigation_handle->GetStartingSiteInstance()->GetSiteURL(); +} + +} // namespace + namespace chromeos { // static @@ -24,10 +99,152 @@ prerender::PrerenderContents* prerender_contents = prerender::PrerenderContents::FromWebContents(handle->GetWebContents()); if (!prerender_contents) - return std::make_unique<arc::ArcNavigationThrottle>(handle); + return std::make_unique<AppsNavigationThrottle>(handle); } return nullptr; } +// static +void AppsNavigationThrottle::ShowIntentPickerBubble(const Browser* browser, + const GURL& url) { + // TODO(crbug.com/824598): ensure that |browser| is still alive when the + // callback is run. + arc::ArcNavigationThrottle::QueryArcApps( + browser, url, + base::BindOnce(&AppsNavigationThrottle::ShowIntentPickerBubbleForApps, + browser, url)); +} + +// static +bool AppsNavigationThrottle::ShouldOverrideUrlLoadingForTesting( + const GURL& previous_url, + const GURL& current_url) { + return ShouldOverrideUrlLoading(previous_url, current_url); +} + +AppsNavigationThrottle::AppsNavigationThrottle( + content::NavigationHandle* navigation_handle) + : content::NavigationThrottle(navigation_handle), + arc_throttle_(std::make_unique<arc::ArcNavigationThrottle>()), + ui_displayed_(false), + weak_factory_(this) {} + +AppsNavigationThrottle::~AppsNavigationThrottle() = default; + +const char* AppsNavigationThrottle::GetNameForLogging() { + return "AppsNavigationThrottle"; +} + +content::NavigationThrottle::ThrottleCheckResult +AppsNavigationThrottle::WillStartRequest() { + DCHECK_CURRENTLY_ON(content::BrowserThread::UI); + starting_url_ = GetStartingGURL(navigation_handle()); + Browser* browser = + chrome::FindBrowserWithWebContents(navigation_handle()->GetWebContents()); + if (browser) + chrome::SetIntentPickerViewVisibility(browser, false); + return HandleRequest(); +} + +content::NavigationThrottle::ThrottleCheckResult +AppsNavigationThrottle::WillRedirectRequest() { + DCHECK_CURRENTLY_ON(content::BrowserThread::UI); + + // TODO(dominickn): Consider what to do when there is another URL during the + // same navigation that could be handled by apps. Two ideas are: + // 1) update the bubble with a mix of both app candidates (if different) + // 2) show a bubble based on the last url, thus closing all the previous ones + if (ui_displayed_) + return content::NavigationThrottle::PROCEED; + + return HandleRequest(); +} + +// static +void AppsNavigationThrottle::ShowIntentPickerBubbleForApps( + const Browser* browser, + const GURL& url, + const std::vector<IntentPickerAppInfo>& apps) { + if (apps.empty()) + return; + + // TODO(crbug.com/824598): move the IntentPickerResponse callback and + // CloseReason enum/UMA to be in this class. + chrome::QueryAndDisplayArcApps( + browser, apps, + base::Bind(&arc::ArcNavigationThrottle::OnIntentPickerClosed, url)); +} + +void AppsNavigationThrottle::CancelNavigation() { + content::WebContents* tab = navigation_handle()->GetWebContents(); + if (tab && tab->GetController().IsInitialNavigation()) + tab->Close(); + else + CancelDeferredNavigation(content::NavigationThrottle::CANCEL_AND_IGNORE); +} + +void AppsNavigationThrottle::OnDeferredRequestProcessed( + AppsNavigationAction action, + const std::vector<IntentPickerAppInfo>& apps) { + if (action == AppsNavigationAction::CANCEL) { + // We found a preferred ARC app to open; cancel the navigation and don't do + // anything else. + CancelNavigation(); + return; + } + + content::NavigationHandle* handle = navigation_handle(); + ShowIntentPickerBubbleForApps( + chrome::FindBrowserWithWebContents(handle->GetWebContents()), + handle->GetURL(), apps); + + // We are about to resume the navigation, which will destroy this object. + ui_displayed_ = false; + Resume(); +} + +content::NavigationThrottle::ThrottleCheckResult +AppsNavigationThrottle::HandleRequest() { + DCHECK(!ui_displayed_); + content::NavigationHandle* handle = navigation_handle(); + + // Always handle http(s) <form> submissions in Chrome for two reasons: 1) we + // don't have a way to send POST data to ARC, and 2) intercepting http(s) form + // submissions is not very important because such submissions are usually + // done within the same domain. ShouldOverrideUrlLoading() below filters out + // such submissions anyway. + constexpr bool kAllowFormSubmit = false; + + // Ignore navigations with the CLIENT_REDIRECT qualifier on. + constexpr bool kAllowClientRedirect = false; + + // We must never handle navigations started within a context menu. + if (handle->WasStartedFromContextMenu()) + return content::NavigationThrottle::PROCEED; + + if (arc::ShouldIgnoreNavigation(handle->GetPageTransition(), kAllowFormSubmit, + kAllowClientRedirect)) { + return content::NavigationThrottle::PROCEED; + } + + if (!ShouldOverrideUrlLoading(starting_url_, handle->GetURL())) + return content::NavigationThrottle::PROCEED; + + if (arc_throttle_->ShouldDeferRequest( + handle, + base::BindOnce(&AppsNavigationThrottle::OnDeferredRequestProcessed, + weak_factory_.GetWeakPtr()))) { + // Handling is now deferred to |arc_throttle_|, which asynchronously queries + // ARC for apps, and runs OnDeferredRequestProcessed() with an action based + // on whether an acceptable app was found and user consent to open received. + // We assume the UI is shown or a preferred app was found; reset to false if + // we resume the navigation. + ui_displayed_ = true; + return content::NavigationThrottle::DEFER; + } + + return content::NavigationThrottle::PROCEED; +} + } // namespace chromeos
diff --git a/chrome/browser/chromeos/apps/intent_helper/apps_navigation_throttle.h b/chrome/browser/chromeos/apps/intent_helper/apps_navigation_throttle.h index 183960c..b466b39 100644 --- a/chrome/browser/chromeos/apps/intent_helper/apps_navigation_throttle.h +++ b/chrome/browser/chromeos/apps/intent_helper/apps_navigation_throttle.h
@@ -7,23 +7,87 @@ #include <memory> +#include "base/callback_forward.h" +#include "base/macros.h" +#include "base/memory/weak_ptr.h" +#include "chrome/browser/chromeos/apps/intent_helper/apps_navigation_types.h" +#include "content/public/browser/navigation_throttle.h" +#include "url/gurl.h" + +class Browser; + +namespace arc { +class ArcNavigationThrottle; +} + namespace content { class NavigationHandle; -class NavigationThrottle; } // namespace content namespace chromeos { -// TODO(crbug.com/824598): make this class inherit from -// content::NavigationThrottle, and move the throttle functionality from -// ArcNavigationThrottle into here. -class AppsNavigationThrottle { +// Allows navigation to be routed to an installed app on Chrome OS, and provides +// a static method for showing an intent picker for the current URL to display +// any handling apps. +class AppsNavigationThrottle : public content::NavigationThrottle { public: - // Possibly creates a navigation throttle that checks if any installed ARC++ + // Restricts the amount of apps displayed to the user without the need of a + // ScrollView. + enum { kMaxAppResults = 3 }; + + // Possibly creates a navigation throttle that checks if any installed ARC // apps can handle the URL being navigated to. The user is prompted if they // wish to open the app or remain in the browser. static std::unique_ptr<content::NavigationThrottle> MaybeCreate( content::NavigationHandle* handle); + + // Queries for ARC apps which can handle |url|, and displays the intent picker + // bubble in |browser|. + static void ShowIntentPickerBubble(const Browser* browser, const GURL& url); + + static bool ShouldOverrideUrlLoadingForTesting(const GURL& previous_url, + const GURL& current_url); + + explicit AppsNavigationThrottle(content::NavigationHandle* navigation_handle); + ~AppsNavigationThrottle() override; + + // content::NavigationHandle overrides + const char* GetNameForLogging() override; + content::NavigationThrottle::ThrottleCheckResult WillStartRequest() override; + content::NavigationThrottle::ThrottleCheckResult WillRedirectRequest() + override; + + private: + static void ShowIntentPickerBubbleForApps( + const Browser* browser, + const GURL& url, + const std::vector<IntentPickerAppInfo>& apps); + void CancelNavigation(); + + content::NavigationThrottle::ThrottleCheckResult HandleRequest(); + + // Passed as a callback to allow app-platform-specific code to asychronously + // inform this object of the apps which can handle this URL, and optionally + // request that the navigation be completely cancelled (e.g. if a preferred + // app has been opened). + void OnDeferredRequestProcessed(AppsNavigationAction action, + const std::vector<IntentPickerAppInfo>& apps); + + // A reference to the starting GURL. + GURL starting_url_; + + std::unique_ptr<arc::ArcNavigationThrottle> arc_throttle_; + + // Keeps track of whether we already shown the UI or preferred app. Since + // AppsNavigationThrottle cannot wait for the user (due to the non-blocking + // nature of the feature) the best we can do is check if we launched a + // preferred app or asked the UI to be shown, this flag ensures we never + // trigger the UI twice for the same throttle. + bool ui_displayed_; + + base::WeakPtrFactory<AppsNavigationThrottle> weak_factory_; + + DISALLOW_COPY_AND_ASSIGN(AppsNavigationThrottle); }; } // namespace chromeos
diff --git a/chrome/browser/chromeos/apps/intent_helper/apps_navigation_throttle_unittest.cc b/chrome/browser/chromeos/apps/intent_helper/apps_navigation_throttle_unittest.cc new file mode 100644 index 0000000..8380a78f --- /dev/null +++ b/chrome/browser/chromeos/apps/intent_helper/apps_navigation_throttle_unittest.cc
@@ -0,0 +1,85 @@ +// Copyright 2018 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 "chrome/browser/chromeos/apps/intent_helper/apps_navigation_throttle.h" +#include "testing/gtest/include/gtest/gtest.h" +#include "url/gurl.h" + +namespace chromeos { + +TEST(AppsNavigationThrottleTest, TestShouldOverrideUrlLoading) { + // A navigation within the same domain shouldn't be overridden except if the + // domain is google.com. + EXPECT_FALSE(AppsNavigationThrottle::ShouldOverrideUrlLoadingForTesting( + GURL("http://google.com"), GURL("http://google.com/"))); + EXPECT_TRUE(AppsNavigationThrottle::ShouldOverrideUrlLoadingForTesting( + GURL("http://google.com"), GURL("http://a.google.com/"))); + EXPECT_TRUE(AppsNavigationThrottle::ShouldOverrideUrlLoadingForTesting( + GURL("http://a.google.com"), GURL("http://google.com/"))); + EXPECT_TRUE(AppsNavigationThrottle::ShouldOverrideUrlLoadingForTesting( + GURL("http://a.google.com"), GURL("http://b.google.com/"))); + EXPECT_TRUE(AppsNavigationThrottle::ShouldOverrideUrlLoadingForTesting( + GURL("http://a.google.com"), GURL("http://b.c.google.com/"))); + EXPECT_TRUE(AppsNavigationThrottle::ShouldOverrideUrlLoadingForTesting( + GURL("http://a.b.google.com"), GURL("http://c.google.com/"))); + EXPECT_TRUE(AppsNavigationThrottle::ShouldOverrideUrlLoadingForTesting( + GURL("http://a.b.google.com"), GURL("http://b.google.com"))); + EXPECT_TRUE(AppsNavigationThrottle::ShouldOverrideUrlLoadingForTesting( + GURL("http://b.google.com"), GURL("http://a.b.google.com"))); + EXPECT_FALSE(AppsNavigationThrottle::ShouldOverrideUrlLoadingForTesting( + GURL("http://notg.com"), GURL("http://notg.com"))); + EXPECT_FALSE(AppsNavigationThrottle::ShouldOverrideUrlLoadingForTesting( + GURL("http://a.notg.com"), GURL("http://notg.com"))); + EXPECT_FALSE(AppsNavigationThrottle::ShouldOverrideUrlLoadingForTesting( + GURL("http://notg.com"), GURL("http://a.notg.com"))); + EXPECT_FALSE(AppsNavigationThrottle::ShouldOverrideUrlLoadingForTesting( + GURL("http://a.notg.com"), GURL("http://b.notg.com"))); + EXPECT_FALSE(AppsNavigationThrottle::ShouldOverrideUrlLoadingForTesting( + GURL("http://a.notg.com"), GURL("http://a.b.notg.com"))); + EXPECT_FALSE(AppsNavigationThrottle::ShouldOverrideUrlLoadingForTesting( + GURL("http://a.b.notg.com"), GURL("http://c.notg.com"))); + + // Same as last tests, except for "play.google.com". + EXPECT_TRUE(AppsNavigationThrottle::ShouldOverrideUrlLoadingForTesting( + GURL("http://google.com"), GURL("http://play.google.com/fake_app"))); + EXPECT_TRUE(AppsNavigationThrottle::ShouldOverrideUrlLoadingForTesting( + GURL("https://www.google.com.mx"), + GURL("https://play.google.com/fake_app"))); + EXPECT_TRUE(AppsNavigationThrottle::ShouldOverrideUrlLoadingForTesting( + GURL("https://mail.google.com"), + GURL("https://play.google.com/fake_app"))); + EXPECT_FALSE(AppsNavigationThrottle::ShouldOverrideUrlLoadingForTesting( + GURL("https://play.google.com/search"), + GURL("https://play.google.com/fake_app"))); + EXPECT_TRUE(AppsNavigationThrottle::ShouldOverrideUrlLoadingForTesting( + GURL("http://not_google.com"), GURL("http://play.google.com/fake_app"))); + + // If either of two paramters is empty, the function should return false. + EXPECT_FALSE(AppsNavigationThrottle::ShouldOverrideUrlLoadingForTesting( + GURL(), GURL("http://a.google.com/"))); + EXPECT_FALSE(AppsNavigationThrottle::ShouldOverrideUrlLoadingForTesting( + GURL("http://a.google.com/"), GURL())); + EXPECT_FALSE(AppsNavigationThrottle::ShouldOverrideUrlLoadingForTesting( + GURL(), GURL())); + + // A navigation not within the same domain can be overridden. + EXPECT_TRUE(AppsNavigationThrottle::ShouldOverrideUrlLoadingForTesting( + GURL("http://www.google.com"), GURL("http://www.not-google.com/"))); + EXPECT_TRUE(AppsNavigationThrottle::ShouldOverrideUrlLoadingForTesting( + GURL("http://www.not-google.com"), GURL("http://www.google.com/"))); + + // A navigation with neither an http nor https scheme cannot be overriden. + EXPECT_FALSE(AppsNavigationThrottle::ShouldOverrideUrlLoadingForTesting( + GURL("chrome-extension://fake_document"), GURL("http://www.a.com"))); + EXPECT_FALSE(AppsNavigationThrottle::ShouldOverrideUrlLoadingForTesting( + GURL("http://www.a.com"), GURL("chrome-extension://fake_document"))); + EXPECT_FALSE(AppsNavigationThrottle::ShouldOverrideUrlLoadingForTesting( + GURL("chrome-extension://fake_document"), GURL("https://www.a.com"))); + EXPECT_FALSE(AppsNavigationThrottle::ShouldOverrideUrlLoadingForTesting( + GURL("https://www.a.com"), GURL("chrome-extension://fake_document"))); + EXPECT_FALSE(AppsNavigationThrottle::ShouldOverrideUrlLoadingForTesting( + GURL("chrome-extension://fake_a"), GURL("chrome-extension://fake_b"))); +} + +} // namespace chromeos
diff --git a/chrome/browser/chromeos/apps/intent_helper/apps_navigation_types.cc b/chrome/browser/chromeos/apps/intent_helper/apps_navigation_types.cc new file mode 100644 index 0000000..b65b9cd --- /dev/null +++ b/chrome/browser/chromeos/apps/intent_helper/apps_navigation_types.cc
@@ -0,0 +1,18 @@ +// Copyright 2018 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 "chrome/browser/chromeos/apps/intent_helper/apps_navigation_types.h" + +namespace chromeos { + +IntentPickerAppInfo::IntentPickerAppInfo(AppType app_type, + const gfx::Image& img, + const std::string& launch, + const std::string& name) + : type(app_type), icon(img), launch_name(launch), display_name(name) {} + +IntentPickerAppInfo::IntentPickerAppInfo(const IntentPickerAppInfo& app_info) = + default; + +} // namespace chromeos
diff --git a/chrome/browser/chromeos/apps/intent_helper/apps_navigation_types.h b/chrome/browser/chromeos/apps/intent_helper/apps_navigation_types.h new file mode 100644 index 0000000..f005dc3 --- /dev/null +++ b/chrome/browser/chromeos/apps/intent_helper/apps_navigation_types.h
@@ -0,0 +1,67 @@ +// Copyright 2018 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 CHROME_BROWSER_CHROMEOS_APPS_INTENT_HELPER_APPS_NAVIGATION_TYPES_H_ +#define CHROME_BROWSER_CHROMEOS_APPS_INTENT_HELPER_APPS_NAVIGATION_TYPES_H_ + +#include <string> + +#include "base/callback_forward.h" +#include "ui/gfx/image/image.h" + +namespace chromeos { + +enum class AppType { + // An Android app. + ARC, +}; + +enum class AppsNavigationAction { + // The current navigation should be cancelled. + CANCEL, + + // The current navigation should resume. + RESUME, +}; + +// Represents the data required to display an app in a picker to the user. +struct IntentPickerAppInfo { + IntentPickerAppInfo(AppType app_type, + const gfx::Image& img, + const std::string& launch, + const std::string& name); + + // TODO(crbug.com/824598): make this type move-only to avoid unnecessary + // copies. + IntentPickerAppInfo(const IntentPickerAppInfo& app_info); + + // The type of app that this object represents. + AppType type; + + // The icon to be displayed for this app in the picker. + gfx::Image icon; + + // The string used to launch this app. Represents an Android package name + // when type is ARC. + std::string launch_name; + + // The string shown to the user to identify this app in the intent picker. + std::string display_name; +}; + +// Callback to allow app-platform-specific code to asynchronously signal what +// action should be taken for the current navigation, and provide a list of apps +// which can handle the navigation. +using AppsNavigationCallback = + base::OnceCallback<void(AppsNavigationAction action, + const std::vector<IntentPickerAppInfo>& apps)>; + +// Callback to allow app-platform-specific code to asynchronously provide a list +// of apps which can handle the navigation. +using QueryAppsCallback = + base::OnceCallback<void(const std::vector<IntentPickerAppInfo>& apps)>; + +} // namespace chromeos + +#endif // CHROME_BROWSER_CHROMEOS_APPS_INTENT_HELPER_APPS_NAVIGATION_TYPES_H_
diff --git a/chrome/browser/chromeos/arc/accessibility/OWNERS b/chrome/browser/chromeos/arc/accessibility/OWNERS index f3097ed..81077236 100644 --- a/chrome/browser/chromeos/arc/accessibility/OWNERS +++ b/chrome/browser/chromeos/arc/accessibility/OWNERS
@@ -1,2 +1,7 @@ dtseng@chromium.org yawano@chromium.org + +file://ui/accessibility/OWNERS + +# TEAM: chromium-accessibility@chromium.org +# COMPONENT: UI>Accessibility
diff --git a/chrome/browser/chromeos/arc/accessibility/arc_accessibility_util.cc b/chrome/browser/chromeos/arc/accessibility/arc_accessibility_util.cc new file mode 100644 index 0000000..a1dcc750 --- /dev/null +++ b/chrome/browser/chromeos/arc/accessibility/arc_accessibility_util.cc
@@ -0,0 +1,85 @@ +// Copyright 2018 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 "chrome/browser/chromeos/arc/accessibility/arc_accessibility_util.h" + +#include "components/arc/common/accessibility_helper.mojom.h" + +namespace arc { + +bool GetProperty(mojom::AccessibilityNodeInfoData* node, + mojom::AccessibilityBooleanProperty prop) { + if (!node->boolean_properties) + return false; + + auto it = node->boolean_properties->find(prop); + if (it == node->boolean_properties->end()) + return false; + + return it->second; +} + +bool GetProperty(mojom::AccessibilityNodeInfoData* node, + mojom::AccessibilityIntProperty prop, + int32_t* out_value) { + if (!node->int_properties) + return false; + + auto it = node->int_properties->find(prop); + if (it == node->int_properties->end()) + return false; + + *out_value = it->second; + return true; +} + +bool HasProperty(mojom::AccessibilityNodeInfoData* node, + mojom::AccessibilityStringProperty prop) { + if (!node->string_properties) + return false; + + auto it = node->string_properties->find(prop); + return it != node->string_properties->end(); +} + +bool GetProperty(mojom::AccessibilityNodeInfoData* node, + mojom::AccessibilityStringProperty prop, + std::string* out_value) { + if (!HasProperty(node, prop)) + return false; + + auto it = node->string_properties->find(prop); + *out_value = it->second; + return true; +} + +bool GetProperty(mojom::AccessibilityNodeInfoData* node, + mojom::AccessibilityIntListProperty prop, + std::vector<int32_t>* out_value) { + if (!node->int_list_properties) + return false; + + auto it = node->int_list_properties->find(prop); + if (it == node->int_list_properties->end()) + return false; + + *out_value = it->second; + return true; +} + +bool GetProperty(mojom::AccessibilityNodeInfoData* node, + mojom::AccessibilityStringListProperty prop, + std::vector<std::string>* out_value) { + if (!node->string_list_properties) + return false; + + auto it = node->string_list_properties->find(prop); + if (it == node->string_list_properties->end()) + return false; + + *out_value = it->second; + return true; +} + +} // namespace arc
diff --git a/chrome/browser/chromeos/arc/accessibility/arc_accessibility_util.h b/chrome/browser/chromeos/arc/accessibility/arc_accessibility_util.h new file mode 100644 index 0000000..855afc6 --- /dev/null +++ b/chrome/browser/chromeos/arc/accessibility/arc_accessibility_util.h
@@ -0,0 +1,42 @@ +// Copyright 2018 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 CHROME_BROWSER_CHROMEOS_ARC_ACCESSIBILITY_ARC_ACCESSIBILITY_UTIL_H_ +#define CHROME_BROWSER_CHROMEOS_ARC_ACCESSIBILITY_ARC_ACCESSIBILITY_UTIL_H_ + +#include <stdint.h> + +#include <string> +#include <vector> + +namespace arc { +namespace mojom { +class AccessibilityNodeInfoData; +enum class AccessibilityBooleanProperty; +enum class AccessibilityIntProperty; +enum class AccessibilityStringProperty; +enum class AccessibilityIntListProperty; +enum class AccessibilityStringListProperty; +} // namespace mojom + +bool GetProperty(mojom::AccessibilityNodeInfoData* node, + mojom::AccessibilityBooleanProperty prop); +bool GetProperty(mojom::AccessibilityNodeInfoData* node, + mojom::AccessibilityIntProperty prop, + int32_t* out_value); +bool HasProperty(mojom::AccessibilityNodeInfoData* node, + mojom::AccessibilityStringProperty prop); +bool GetProperty(mojom::AccessibilityNodeInfoData* node, + mojom::AccessibilityStringProperty prop, + std::string* out_value); +bool GetProperty(mojom::AccessibilityNodeInfoData* node, + mojom::AccessibilityIntListProperty prop, + std::vector<int32_t>* out_value); +bool GetProperty(mojom::AccessibilityNodeInfoData* node, + mojom::AccessibilityStringListProperty prop, + std::vector<std::string>* out_value); + +} // namespace arc + +#endif // CHROME_BROWSER_CHROMEOS_ARC_ACCESSIBILITY_ARC_ACCESSIBILITY_UTIL_H_
diff --git a/chrome/browser/chromeos/arc/accessibility/ax_tree_source_arc.cc b/chrome/browser/chromeos/arc/accessibility/ax_tree_source_arc.cc index 92ef992b..0239533 100644 --- a/chrome/browser/chromeos/arc/accessibility/ax_tree_source_arc.cc +++ b/chrome/browser/chromeos/arc/accessibility/ax_tree_source_arc.cc
@@ -7,6 +7,7 @@ #include <string> #include "base/strings/stringprintf.h" +#include "chrome/browser/chromeos/arc/accessibility/arc_accessibility_util.h" #include "chrome/browser/extensions/api/automation_internal/automation_event_router.h" #include "chrome/browser/ui/aura/accessibility/automation_manager_aura.h" #include "chrome/common/extensions/chrome_extension_messages.h" @@ -18,43 +19,54 @@ #include "ui/views/view.h" #include "ui/views/widget/widget.h" -namespace { +namespace arc { -ax::mojom::Event ToAXEvent(arc::mojom::AccessibilityEventType arc_event_type) { +using AXBooleanProperty = mojom::AccessibilityBooleanProperty; +using AXCollectionInfoData = mojom::AccessibilityCollectionInfoData; +using AXCollectionItemInfoData = mojom::AccessibilityCollectionItemInfoData; +using AXEventData = mojom::AccessibilityEventData; +using AXEventType = mojom::AccessibilityEventType; +using AXIntListProperty = mojom::AccessibilityIntListProperty; +using AXIntProperty = mojom::AccessibilityIntProperty; +using AXNodeInfoData = mojom::AccessibilityNodeInfoData; +using AXRangeInfoData = mojom::AccessibilityRangeInfoData; +using AXStringListProperty = mojom::AccessibilityStringListProperty; +using AXStringProperty = mojom::AccessibilityStringProperty; + +ax::mojom::Event ToAXEvent(AXEventType arc_event_type) { switch (arc_event_type) { - case arc::mojom::AccessibilityEventType::VIEW_FOCUSED: - case arc::mojom::AccessibilityEventType::VIEW_ACCESSIBILITY_FOCUSED: + case AXEventType::VIEW_FOCUSED: + case AXEventType::VIEW_ACCESSIBILITY_FOCUSED: return ax::mojom::Event::kFocus; - case arc::mojom::AccessibilityEventType::VIEW_CLICKED: - case arc::mojom::AccessibilityEventType::VIEW_LONG_CLICKED: + case AXEventType::VIEW_CLICKED: + case AXEventType::VIEW_LONG_CLICKED: return ax::mojom::Event::kClicked; - case arc::mojom::AccessibilityEventType::VIEW_TEXT_CHANGED: + case AXEventType::VIEW_TEXT_CHANGED: return ax::mojom::Event::kTextChanged; - case arc::mojom::AccessibilityEventType::VIEW_TEXT_SELECTION_CHANGED: + case AXEventType::VIEW_TEXT_SELECTION_CHANGED: return ax::mojom::Event::kTextSelectionChanged; - case arc::mojom::AccessibilityEventType::WINDOW_STATE_CHANGED: - case arc::mojom::AccessibilityEventType::NOTIFICATION_STATE_CHANGED: - case arc::mojom::AccessibilityEventType::WINDOW_CONTENT_CHANGED: - case arc::mojom::AccessibilityEventType::WINDOWS_CHANGED: + case AXEventType::WINDOW_STATE_CHANGED: + case AXEventType::NOTIFICATION_STATE_CHANGED: + case AXEventType::WINDOW_CONTENT_CHANGED: + case AXEventType::WINDOWS_CHANGED: return ax::mojom::Event::kLayoutComplete; - case arc::mojom::AccessibilityEventType::VIEW_HOVER_ENTER: + case AXEventType::VIEW_HOVER_ENTER: return ax::mojom::Event::kHover; - case arc::mojom::AccessibilityEventType::ANNOUNCEMENT: + case AXEventType::ANNOUNCEMENT: return ax::mojom::Event::kAlert; - case arc::mojom::AccessibilityEventType::VIEW_SCROLLED: + case AXEventType::VIEW_SCROLLED: return ax::mojom::Event::kScrollPositionChanged; - case arc::mojom::AccessibilityEventType::VIEW_SELECTED: - case arc::mojom::AccessibilityEventType::VIEW_HOVER_EXIT: - case arc::mojom::AccessibilityEventType::TOUCH_EXPLORATION_GESTURE_START: - case arc::mojom::AccessibilityEventType::TOUCH_EXPLORATION_GESTURE_END: - case arc::mojom::AccessibilityEventType:: - VIEW_TEXT_TRAVERSED_AT_MOVEMENT_GRANULARITY: - case arc::mojom::AccessibilityEventType::GESTURE_DETECTION_START: - case arc::mojom::AccessibilityEventType::GESTURE_DETECTION_END: - case arc::mojom::AccessibilityEventType::TOUCH_INTERACTION_START: - case arc::mojom::AccessibilityEventType::TOUCH_INTERACTION_END: - case arc::mojom::AccessibilityEventType::VIEW_CONTEXT_CLICKED: - case arc::mojom::AccessibilityEventType::ASSIST_READING_CONTEXT: + case AXEventType::VIEW_SELECTED: + case AXEventType::VIEW_HOVER_EXIT: + case AXEventType::TOUCH_EXPLORATION_GESTURE_START: + case AXEventType::TOUCH_EXPLORATION_GESTURE_END: + case AXEventType::VIEW_TEXT_TRAVERSED_AT_MOVEMENT_GRANULARITY: + case AXEventType::GESTURE_DETECTION_START: + case AXEventType::GESTURE_DETECTION_END: + case AXEventType::TOUCH_INTERACTION_START: + case AXEventType::TOUCH_INTERACTION_END: + case AXEventType::VIEW_CONTEXT_CLICKED: + case AXEventType::ASSIST_READING_CONTEXT: return ax::mojom::Event::kChildrenChanged; default: return ax::mojom::Event::kChildrenChanged; @@ -62,82 +74,14 @@ return ax::mojom::Event::kChildrenChanged; } -bool GetBooleanProperty(arc::mojom::AccessibilityNodeInfoData* node, - arc::mojom::AccessibilityBooleanProperty prop) { - if (!node->boolean_properties) - return false; - - auto it = node->boolean_properties->find(prop); - if (it == node->boolean_properties->end()) - return false; - - return it->second; -} - -bool GetIntProperty(arc::mojom::AccessibilityNodeInfoData* node, - arc::mojom::AccessibilityIntProperty prop, - int32_t* out_value) { - if (!node->int_properties) - return false; - - auto it = node->int_properties->find(prop); - if (it == node->int_properties->end()) - return false; - - *out_value = it->second; - return true; -} - -bool GetStringProperty(arc::mojom::AccessibilityNodeInfoData* node, - arc::mojom::AccessibilityStringProperty prop, - std::string* out_value) { - if (!node->string_properties) - return false; - - auto it = node->string_properties->find(prop); - if (it == node->string_properties->end()) - return false; - - *out_value = it->second; - return true; -} - -bool GetIntListProperty(arc::mojom::AccessibilityNodeInfoData* node, - arc::mojom::AccessibilityIntListProperty prop, - std::vector<int32_t>* out_value) { - if (!node->int_list_properties) - return false; - - auto it = node->int_list_properties->find(prop); - if (it == node->int_list_properties->end()) - return false; - - *out_value = it->second; - return true; -} - -bool GetStringListProperty(arc::mojom::AccessibilityNodeInfoData* node, - arc::mojom::AccessibilityStringListProperty prop, - std::vector<std::string>* out_value) { - if (!node->string_list_properties) - return false; - - auto it = node->string_list_properties->find(prop); - if (it == node->string_list_properties->end()) - return false; - - *out_value = it->second; - return true; -} - -bool HasCoveringSpan(arc::mojom::AccessibilityNodeInfoData* data, - arc::mojom::AccessibilityStringProperty prop, - arc::mojom::SpanType span_type) { +bool HasCoveringSpan(AXNodeInfoData* data, + AXStringProperty prop, + mojom::SpanType span_type) { if (!data->spannable_string_properties) return false; std::string text; - GetStringProperty(data, prop, &text); + GetProperty(data, prop, &text); if (text.empty()) return false; @@ -157,32 +101,26 @@ return false; } -void PopulateAXRole(arc::mojom::AccessibilityNodeInfoData* node, - ui::AXNodeData* out_data) { +void PopulateAXRole(AXNodeInfoData* node, ui::AXNodeData* out_data) { std::string class_name; - if (GetStringProperty(node, - arc::mojom::AccessibilityStringProperty::CLASS_NAME, - &class_name)) { + if (GetProperty(node, AXStringProperty::CLASS_NAME, &class_name)) { out_data->AddStringAttribute(ax::mojom::StringAttribute::kClassName, class_name); } - if (GetBooleanProperty(node, - arc::mojom::AccessibilityBooleanProperty::EDITABLE)) { + if (GetProperty(node, AXBooleanProperty::EDITABLE)) { out_data->role = ax::mojom::Role::kTextField; return; } - if (HasCoveringSpan(node, arc::mojom::AccessibilityStringProperty::TEXT, - arc::mojom::SpanType::URL) || - HasCoveringSpan( - node, arc::mojom::AccessibilityStringProperty::CONTENT_DESCRIPTION, - arc::mojom::SpanType::URL)) { + if (HasCoveringSpan(node, AXStringProperty::TEXT, mojom::SpanType::URL) || + HasCoveringSpan(node, AXStringProperty::CONTENT_DESCRIPTION, + mojom::SpanType::URL)) { out_data->role = ax::mojom::Role::kLink; return; } - arc::mojom::AccessibilityCollectionItemInfoData* collection_item_info = + AXCollectionItemInfoData* collection_item_info = node->collection_item_info.get(); if (collection_item_info) { if (collection_item_info->is_heading) { @@ -196,9 +134,7 @@ } std::string chrome_role; - if (GetStringProperty(node, - arc::mojom::AccessibilityStringProperty::CHROME_ROLE, - &chrome_role)) { + if (GetProperty(node, AXStringProperty::CHROME_ROLE, &chrome_role)) { ax::mojom::Role role_value = ui::ParseRole(chrome_role.c_str()); if (role_value != ax::mojom::Role::kNone) { // The webView and rootWebArea roles differ between Android and Chrome. In @@ -231,8 +167,7 @@ MAP_ROLE(ui::kAXGridViewClassname, ax::mojom::Role::kTable); MAP_ROLE(ui::kAXImageClassname, ax::mojom::Role::kImage); MAP_ROLE(ui::kAXImageButtonClassname, ax::mojom::Role::kButton); - if (GetBooleanProperty(node, - arc::mojom::AccessibilityBooleanProperty::CLICKABLE)) { + if (GetProperty(node, AXBooleanProperty::CLICKABLE)) { MAP_ROLE(ui::kAXImageViewClassname, ax::mojom::Role::kButton); } else { MAP_ROLE(ui::kAXImageViewClassname, ax::mojom::Role::kImage); @@ -253,21 +188,18 @@ #undef MAP_ROLE std::string text; - GetStringProperty(node, arc::mojom::AccessibilityStringProperty::TEXT, &text); + GetProperty(node, AXStringProperty::TEXT, &text); if (!text.empty()) out_data->role = ax::mojom::Role::kStaticText; else out_data->role = ax::mojom::Role::kGenericContainer; } -void PopulateAXState(arc::mojom::AccessibilityNodeInfoData* node, - ui::AXNodeData* out_data) { +void PopulateAXState(AXNodeInfoData* node, ui::AXNodeData* out_data) { #define MAP_STATE(android_boolean_property, chrome_state) \ - if (GetBooleanProperty(node, android_boolean_property)) \ + if (GetProperty(node, android_boolean_property)) \ out_data->AddState(chrome_state); - using AXBooleanProperty = arc::mojom::AccessibilityBooleanProperty; - // These mappings were taken from accessibility utils (Android -> Chrome) and // BrowserAccessibilityAndroid. They do not completely match the above two // sources. @@ -279,26 +211,21 @@ #undef MAP_STATE - if (GetBooleanProperty(node, AXBooleanProperty::CHECKABLE)) { - const bool is_checked = - GetBooleanProperty(node, AXBooleanProperty::CHECKED); + if (GetProperty(node, AXBooleanProperty::CHECKABLE)) { + const bool is_checked = GetProperty(node, AXBooleanProperty::CHECKED); out_data->SetCheckedState(is_checked ? ax::mojom::CheckedState::kTrue : ax::mojom::CheckedState::kFalse); } - if (!GetBooleanProperty(node, AXBooleanProperty::ENABLED)) { + if (!GetProperty(node, AXBooleanProperty::ENABLED)) { out_data->SetRestriction(ax::mojom::Restriction::kDisabled); } - if (!GetBooleanProperty(node, AXBooleanProperty::VISIBLE_TO_USER)) { + if (!GetProperty(node, AXBooleanProperty::VISIBLE_TO_USER)) { out_data->AddState(ax::mojom::State::kInvisible); } } -} // namespace - -namespace arc { - // This class keeps focus on a |ShellSurface| without interfering with default // focus management in |ShellSurface|. For example, touch causes the // |ShellSurface| to lose focus to its ancestor containing View. @@ -335,8 +262,7 @@ Reset(); } -void AXTreeSourceArc::NotifyAccessibilityEvent( - mojom::AccessibilityEventData* event_data) { +void AXTreeSourceArc::NotifyAccessibilityEvent(AXEventData* event_data) { tree_map_.clear(); parent_map_.clear(); cached_computed_bounds_.clear(); @@ -355,7 +281,7 @@ if (!event_data->node_data[i]->int_list_properties) continue; auto it = event_data->node_data[i]->int_list_properties->find( - arc::mojom::AccessibilityIntListProperty::CHILD_NODE_IDS); + AXIntListProperty::CHILD_NODE_IDS); if (it != event_data->node_data[i]->int_list_properties->end()) { for (size_t j = 0; j < it->second.size(); ++j) parent_map_[it->second[j]] = event_data->node_data[i]->id; @@ -364,15 +290,14 @@ for (size_t i = 0; i < event_data->node_data.size(); ++i) { int32_t id = event_data->node_data[i]->id; - mojom::AccessibilityNodeInfoData* node = event_data->node_data[i].get(); + AXNodeInfoData* node = event_data->node_data[i].get(); tree_map_[id] = node; if (parent_map_.find(id) == parent_map_.end()) { CHECK_EQ(-1, root_id_) << "Duplicated root"; root_id_ = id; } - if (GetBooleanProperty(node, - arc::mojom::AccessibilityBooleanProperty::FOCUSED)) { + if (GetProperty(node, AXBooleanProperty::FOCUSED)) { focused_node_id_ = id; } } @@ -381,7 +306,7 @@ // avoid an O(n^2) amount of work as the computed bounds uses descendant // bounds. for (int i = event_data->node_data.size() - 1; i >= 0; --i) { - mojom::AccessibilityNodeInfoData* node = event_data->node_data[i].get(); + AXNodeInfoData* node = event_data->node_data[i].get(); cached_computed_bounds_[node] = ComputeEnclosingBounds(node); } @@ -395,8 +320,7 @@ ui::AXTreeUpdate update; - if (event_data->event_type == - arc::mojom::AccessibilityEventType::WINDOW_CONTENT_CHANGED) { + if (event_data->event_type == AXEventType::WINDOW_CONTENT_CHANGED) { current_tree_serializer_->DeleteClientSubtree( GetFromId(event_data->source_id)); } @@ -438,45 +362,51 @@ return true; } -mojom::AccessibilityNodeInfoData* AXTreeSourceArc::GetRoot() const { - mojom::AccessibilityNodeInfoData* root = GetFromId(root_id_); +AXNodeInfoData* AXTreeSourceArc::GetRoot() const { + AXNodeInfoData* root = GetFromId(root_id_); return root; } -mojom::AccessibilityNodeInfoData* AXTreeSourceArc::GetFromId(int32_t id) const { +AXNodeInfoData* AXTreeSourceArc::GetFromId(int32_t id) const { auto it = tree_map_.find(id); if (it == tree_map_.end()) return nullptr; return it->second; } -int32_t AXTreeSourceArc::GetId(mojom::AccessibilityNodeInfoData* node) const { +int32_t AXTreeSourceArc::GetId(AXNodeInfoData* node) const { if (!node) return -1; return node->id; } void AXTreeSourceArc::GetChildren( - mojom::AccessibilityNodeInfoData* node, - std::vector<mojom::AccessibilityNodeInfoData*>* out_children) const { + AXNodeInfoData* node, + std::vector<AXNodeInfoData*>* out_children) const { if (!node || !node->int_list_properties) return; - auto it = node->int_list_properties->find( - arc::mojom::AccessibilityIntListProperty::CHILD_NODE_IDS); + auto it = node->int_list_properties->find(AXIntListProperty::CHILD_NODE_IDS); if (it == node->int_list_properties->end()) return; - for (size_t i = 0; i < it->second.size(); ++i) - out_children->push_back(GetFromId(it->second[i])); + std::map<int32_t, size_t> id_to_index; + for (size_t i = 0; i < it->second.size(); ++i) { + AXNodeInfoData* child = GetFromId(it->second[i]); + out_children->push_back(child); + id_to_index[child->id] = i; + } // Sort children based on their enclosing bounding rectangles, based on their // descendants. std::sort(out_children->begin(), out_children->end(), - [this](auto left, auto right) { + [this, id_to_index](auto left, auto right) { auto left_bounds = ComputeEnclosingBounds(left); auto right_bounds = ComputeEnclosingBounds(right); + if (left_bounds.IsEmpty() || right_bounds.IsEmpty()) + return id_to_index.at(left->id) < id_to_index.at(right->id); + // Top to bottom sort (non-overlapping). if (!left_bounds.Intersects(right_bounds)) return left_bounds.y() < right_bounds.y(); @@ -503,12 +433,11 @@ return width_difference > 0; // The rects are equal. - return false; + return id_to_index.at(left->id) < id_to_index.at(right->id); }); } -mojom::AccessibilityNodeInfoData* AXTreeSourceArc::GetParent( - mojom::AccessibilityNodeInfoData* node) const { +AXNodeInfoData* AXTreeSourceArc::GetParent(AXNodeInfoData* node) const { if (!node) return nullptr; auto it = parent_map_.find(node->id); @@ -517,22 +446,22 @@ return nullptr; } -bool AXTreeSourceArc::IsValid(mojom::AccessibilityNodeInfoData* node) const { +bool AXTreeSourceArc::IsValid(AXNodeInfoData* node) const { return node; } -bool AXTreeSourceArc::IsEqual(mojom::AccessibilityNodeInfoData* node1, - mojom::AccessibilityNodeInfoData* node2) const { +bool AXTreeSourceArc::IsEqual(AXNodeInfoData* node1, + AXNodeInfoData* node2) const { if (!node1 || !node2) return false; return node1->id == node2->id; } -mojom::AccessibilityNodeInfoData* AXTreeSourceArc::GetNull() const { +AXNodeInfoData* AXTreeSourceArc::GetNull() const { return nullptr; } -void AXTreeSourceArc::SerializeNode(mojom::AccessibilityNodeInfoData* node, +void AXTreeSourceArc::SerializeNode(AXNodeInfoData* node, ui::AXNodeData* out_data) const { if (!node) return; @@ -544,10 +473,10 @@ else PopulateAXRole(node, out_data); - using AXIntListProperty = arc::mojom::AccessibilityIntListProperty; - using AXIntProperty = arc::mojom::AccessibilityIntProperty; - using AXStringListProperty = arc::mojom::AccessibilityStringListProperty; - using AXStringProperty = arc::mojom::AccessibilityStringProperty; + using AXIntListProperty = AXIntListProperty; + using AXIntProperty = AXIntProperty; + using AXStringListProperty = AXStringListProperty; + using AXStringProperty = AXStringProperty; // String properties. int labelled_by = -1; @@ -556,13 +485,12 @@ // description, text, or labelled by text. std::string name; bool has_name = - GetStringProperty(node, AXStringProperty::CONTENT_DESCRIPTION, &name); + GetProperty(node, AXStringProperty::CONTENT_DESCRIPTION, &name); if (name.empty()) - has_name |= GetStringProperty(node, AXStringProperty::TEXT, &name); + has_name |= GetProperty(node, AXStringProperty::TEXT, &name); if (name.empty() && - GetIntProperty(node, arc::mojom::AccessibilityIntProperty::LABELED_BY, - &labelled_by)) { - mojom::AccessibilityNodeInfoData* labelled_by_node = GetFromId(labelled_by); + GetProperty(node, AXIntProperty::LABELED_BY, &labelled_by)) { + AXNodeInfoData* labelled_by_node = GetFromId(labelled_by); if (labelled_by_node) { ui::AXNodeData labelled_by_data; SerializeNode(labelled_by_node, &labelled_by_data); @@ -579,16 +507,15 @@ } std::string role_description; - if (GetStringProperty(node, AXStringProperty::ROLE_DESCRIPTION, - &role_description)) { + if (GetProperty(node, AXStringProperty::ROLE_DESCRIPTION, + &role_description)) { out_data->AddStringAttribute(ax::mojom::StringAttribute::kRoleDescription, role_description); } if (out_data->role == ax::mojom::Role::kRootWebArea) { std::string package_name; - if (GetStringProperty(node, AXStringProperty::PACKAGE_NAME, - &package_name)) { + if (GetProperty(node, AXStringProperty::PACKAGE_NAME, &package_name)) { const std::string& url = base::StringPrintf("%s/%d", package_name.c_str(), tree_id()); out_data->AddStringAttribute(ax::mojom::StringAttribute::kUrl, url); @@ -597,33 +524,27 @@ // Int properties. int traversal_before = -1, traversal_after = -1; - if (GetIntProperty(node, - arc::mojom::AccessibilityIntProperty::TRAVERSAL_BEFORE, - &traversal_before)) { + if (GetProperty(node, AXIntProperty::TRAVERSAL_BEFORE, &traversal_before)) { out_data->AddIntAttribute(ax::mojom::IntAttribute::kPreviousFocusId, traversal_before); } - if (GetIntProperty(node, - arc::mojom::AccessibilityIntProperty::TRAVERSAL_AFTER, - &traversal_after)) { + if (GetProperty(node, AXIntProperty::TRAVERSAL_AFTER, &traversal_after)) { out_data->AddIntAttribute(ax::mojom::IntAttribute::kNextFocusId, traversal_after); } // Boolean properties. PopulateAXState(node, out_data); - if (GetBooleanProperty( - node, arc::mojom::AccessibilityBooleanProperty::SCROLLABLE)) { + if (GetProperty(node, AXBooleanProperty::SCROLLABLE)) { out_data->AddBoolAttribute(ax::mojom::BoolAttribute::kScrollable, true); } - if (GetBooleanProperty(node, - arc::mojom::AccessibilityBooleanProperty::CLICKABLE)) { + if (GetProperty(node, AXBooleanProperty::CLICKABLE)) { out_data->AddBoolAttribute(ax::mojom::BoolAttribute::kClickable, true); } // Range info. - arc::mojom::AccessibilityRangeInfoData* range_info = node->range_info.get(); + AXRangeInfoData* range_info = node->range_info.get(); if (range_info) { out_data->AddFloatAttribute(ax::mojom::FloatAttribute::kValueForRange, range_info->current); @@ -649,22 +570,20 @@ // Integer properties. int32_t val; - if (GetIntProperty(node, AXIntProperty::TEXT_SELECTION_START, &val) && - val >= 0) + if (GetProperty(node, AXIntProperty::TEXT_SELECTION_START, &val) && val >= 0) out_data->AddIntAttribute(ax::mojom::IntAttribute::kTextSelStart, val); - if (GetIntProperty(node, AXIntProperty::TEXT_SELECTION_END, &val) && val >= 0) + if (GetProperty(node, AXIntProperty::TEXT_SELECTION_END, &val) && val >= 0) out_data->AddIntAttribute(ax::mojom::IntAttribute::kTextSelEnd, val); // Custom actions. std::vector<int32_t> custom_action_ids; - if (GetIntListProperty(node, AXIntListProperty::CUSTOM_ACTION_IDS, - &custom_action_ids)) { + if (GetProperty(node, AXIntListProperty::CUSTOM_ACTION_IDS, + &custom_action_ids)) { std::vector<std::string> custom_action_descriptions; - CHECK(GetStringListProperty( - node, AXStringListProperty::CUSTOM_ACTION_DESCRIPTIONS, - &custom_action_descriptions)); + CHECK(GetProperty(node, AXStringListProperty::CUSTOM_ACTION_DESCRIPTIONS, + &custom_action_descriptions)); CHECK(!custom_action_ids.empty()); CHECK_EQ(custom_action_ids.size(), custom_action_descriptions.size()); @@ -677,9 +596,8 @@ } } -const gfx::Rect AXTreeSourceArc::GetBounds( - mojom::AccessibilityNodeInfoData* node, - aura::Window* focused_window) const { +const gfx::Rect AXTreeSourceArc::GetBounds(AXNodeInfoData* node, + aura::Window* focused_window) const { DCHECK_NE(root_id_, -1); gfx::Rect node_bounds = node->bounds_in_screen; @@ -705,15 +623,19 @@ return node_bounds; } -gfx::Rect AXTreeSourceArc::ComputeEnclosingBounds( - mojom::AccessibilityNodeInfoData* node) const { +gfx::Rect AXTreeSourceArc::ComputeEnclosingBounds(AXNodeInfoData* node) const { gfx::Rect computed_bounds; + + // Exit early if |node| is invisible. + if (!GetProperty(node, AXBooleanProperty::VISIBLE_TO_USER)) + return computed_bounds; + ComputeEnclosingBoundsInternal(node, computed_bounds); - return computed_bounds.IsEmpty() ? node->bounds_in_screen : computed_bounds; + return computed_bounds; } void AXTreeSourceArc::ComputeEnclosingBoundsInternal( - mojom::AccessibilityNodeInfoData* node, + AXNodeInfoData* node, gfx::Rect& computed_bounds) const { auto cached_bounds = cached_computed_bounds_.find(node); if (cached_bounds != cached_computed_bounds_.end()) { @@ -721,24 +643,32 @@ return; } + if (!GetProperty(node, AXBooleanProperty::VISIBLE_TO_USER)) + return; + // Only consider nodes that can possibly be accessibility focused. In Chrome, - // this amounts to nodes with a non-generic container role. + // this means: + // a node with a non-generic role and + // actionable nodes, or + // top level scrollables with a name ui::AXNodeData data; PopulateAXRole(node, &data); - const gfx::Rect& bounds = node->bounds_in_screen; - if (data.role != ax::mojom::Role::kGenericContainer && - data.role != ax::mojom::Role::kGroup && !bounds.IsEmpty() && - GetBooleanProperty( - node, arc::mojom::AccessibilityBooleanProperty::VISIBLE_TO_USER)) { - computed_bounds.Union(bounds); + if ((data.role != ax::mojom::Role::kGenericContainer && + data.role != ax::mojom::Role::kGroup) && + (GetProperty(node, AXBooleanProperty::FOCUSABLE) || + GetProperty(node, AXBooleanProperty::CLICKABLE) || + GetProperty(node, AXBooleanProperty::FOCUSABLE) || + GetProperty(node, AXBooleanProperty::CHECKABLE) || + (HasProperty(node, AXStringProperty::TEXT) && + GetProperty(node, AXBooleanProperty::SCROLLABLE)))) { + computed_bounds.Union(node->bounds_in_screen); return; } if (!node->int_list_properties) return; - auto it = node->int_list_properties->find( - arc::mojom::AccessibilityIntListProperty::CHILD_NODE_IDS); + auto it = node->int_list_properties->find(AXIntListProperty::CHILD_NODE_IDS); if (it == node->int_list_properties->end()) return;
diff --git a/chrome/browser/chromeos/arc/accessibility/ax_tree_source_arc_unittest.cc b/chrome/browser/chromeos/arc/accessibility/ax_tree_source_arc_unittest.cc index 2a4a39c..a3b1d24 100644 --- a/chrome/browser/chromeos/arc/accessibility/ax_tree_source_arc_unittest.cc +++ b/chrome/browser/chromeos/arc/accessibility/ax_tree_source_arc_unittest.cc
@@ -10,23 +10,68 @@ namespace arc { +using AXBooleanProperty = mojom::AccessibilityBooleanProperty; +using AXCollectionInfoData = mojom::AccessibilityCollectionInfoData; +using AXCollectionItemInfoData = mojom::AccessibilityCollectionItemInfoData; +using AXEventData = mojom::AccessibilityEventData; +using AXEventType = mojom::AccessibilityEventType; +using AXIntListProperty = mojom::AccessibilityIntListProperty; +using AXIntProperty = mojom::AccessibilityIntProperty; +using AXNodeInfoData = mojom::AccessibilityNodeInfoData; +using AXRangeInfoData = mojom::AccessibilityRangeInfoData; +using AXStringListProperty = mojom::AccessibilityStringListProperty; +using AXStringProperty = mojom::AccessibilityStringProperty; + +void SetProperty(AXNodeInfoData* node, AXBooleanProperty prop, bool value) { + if (!node->boolean_properties) { + node->boolean_properties = std::unordered_map<AXBooleanProperty, bool>(); + } + node->boolean_properties.value().insert(std::make_pair(prop, value)); +} + +void SetProperty(AXNodeInfoData* node, + AXStringProperty prop, + const std::string& value) { + if (!node->string_properties) { + node->string_properties = + std::unordered_map<AXStringProperty, std::string>(); + } + node->string_properties.value().insert(std::make_pair(prop, value)); +} + +void SetProperty(AXNodeInfoData* node, AXIntProperty prop, int32_t value) { + if (!node->int_properties) { + node->int_properties = std::unordered_map<AXIntProperty, int>(); + } + node->int_properties.value().insert(std::make_pair(prop, value)); +} + +void SetProperty(AXNodeInfoData* node, + AXIntListProperty prop, + const std::vector<int>& value) { + if (!node->int_list_properties) { + node->int_list_properties = + std::unordered_map<AXIntListProperty, std::vector<int>>(); + } + node->int_list_properties.value().insert(std::make_pair(prop, value)); +} + class AXTreeSourceArcTest : public testing::Test, public AXTreeSourceArc::Delegate { public: AXTreeSourceArcTest() : tree_(new AXTreeSourceArc(this)) {} protected: - void CallNotifyAccessibilityEvent(mojom::AccessibilityEventData* event_data) { + void CallNotifyAccessibilityEvent(AXEventData* event_data) { tree_->NotifyAccessibilityEvent(event_data); } - void CallGetChildren( - mojom::AccessibilityNodeInfoData* node, - std::vector<mojom::AccessibilityNodeInfoData*>* out_children) const { + void CallGetChildren(AXNodeInfoData* node, + std::vector<AXNodeInfoData*>* out_children) const { tree_->GetChildren(node, out_children); } - void CallSerializeNode(mojom::AccessibilityNodeInfoData* node, + void CallSerializeNode(AXNodeInfoData* node, std::unique_ptr<ui::AXNodeData>* out_data) const { ASSERT_TRUE(out_data); *out_data = std::make_unique<ui::AXNodeData>(); @@ -42,152 +87,143 @@ }; TEST_F(AXTreeSourceArcTest, ReorderChildrenByLayout) { + auto event = AXEventData::New(); + event->source_id = 0; + event->task_id = 1; + event->event_type = AXEventType::VIEW_FOCUSED; - auto event1 = arc::mojom::AccessibilityEventData::New(); - event1->source_id = 0; - event1->task_id = 1; - event1->event_type = arc::mojom::AccessibilityEventType::VIEW_FOCUSED; - event1->node_data.push_back(arc::mojom::AccessibilityNodeInfoData::New()); - event1->node_data[0]->id = 0; - event1->node_data[0]->int_list_properties = - std::unordered_map<arc::mojom::AccessibilityIntListProperty, - std::vector<int>>(); - event1->node_data[0]->int_list_properties.value().insert( - std::make_pair(arc::mojom::AccessibilityIntListProperty::CHILD_NODE_IDS, - std::vector<int>({1, 2}))); + event->node_data.push_back(AXNodeInfoData::New()); + AXNodeInfoData* root = event->node_data.back().get(); + root->id = 0; + SetProperty(root, AXIntListProperty::CHILD_NODE_IDS, + std::vector<int>({1, 2})); // Child button. - event1->node_data.push_back(arc::mojom::AccessibilityNodeInfoData::New()); - event1->node_data[1]->id = 1; - event1->node_data[1]->string_properties = - std::unordered_map<arc::mojom::AccessibilityStringProperty, - std::string>(); - event1->node_data[1]->string_properties.value().insert( - std::make_pair(arc::mojom::AccessibilityStringProperty::CLASS_NAME, - ui::kAXButtonClassname)); - event1->node_data[1]->boolean_properties = - std::unordered_map<arc::mojom::AccessibilityBooleanProperty, bool>(); - event1->node_data[1]->boolean_properties.value().insert(std::make_pair( - arc::mojom::AccessibilityBooleanProperty::VISIBLE_TO_USER, true)); + event->node_data.push_back(AXNodeInfoData::New()); + AXNodeInfoData* button1 = event->node_data.back().get(); + button1->id = 1; + SetProperty(button1, AXStringProperty::CLASS_NAME, ui::kAXButtonClassname); + SetProperty(button1, AXBooleanProperty::VISIBLE_TO_USER, true); + SetProperty(button1, AXBooleanProperty::FOCUSABLE, true); // Another child button. - event1->node_data.push_back(arc::mojom::AccessibilityNodeInfoData::New()); - event1->node_data[2]->id = 2; - event1->node_data[2]->string_properties = - std::unordered_map<arc::mojom::AccessibilityStringProperty, - std::string>(); - event1->node_data[2]->string_properties.value().insert( - std::make_pair(arc::mojom::AccessibilityStringProperty::CLASS_NAME, - ui::kAXButtonClassname)); - event1->node_data[2]->boolean_properties = - std::unordered_map<arc::mojom::AccessibilityBooleanProperty, bool>(); - event1->node_data[2]->boolean_properties.value().insert(std::make_pair( - arc::mojom::AccessibilityBooleanProperty::VISIBLE_TO_USER, true)); - - // Populate the tree source with the data. - CallNotifyAccessibilityEvent(event1.get()); - - // Live edit the data sources to exercise each layout. + event->node_data.push_back(AXNodeInfoData::New()); + AXNodeInfoData* button2 = event->node_data.back().get(); + button2->id = 2; + SetProperty(button2, AXStringProperty::CLASS_NAME, ui::kAXButtonClassname); + SetProperty(button2, AXBooleanProperty::VISIBLE_TO_USER, true); + SetProperty(button2, AXBooleanProperty::FOCUSABLE, true); // Non-overlapping, bottom to top. - event1->node_data[1]->bounds_in_screen = gfx::Rect(100, 100, 100, 100); - event1->node_data[2]->bounds_in_screen = gfx::Rect(0, 0, 50, 50); - std::vector<mojom::AccessibilityNodeInfoData*> top_to_bottom; - CallGetChildren(event1->node_data[0].get(), &top_to_bottom); + button1->bounds_in_screen = gfx::Rect(100, 100, 100, 100); + button2->bounds_in_screen = gfx::Rect(0, 0, 50, 50); + + // Trigger an update which refreshes the computed bounds used for reordering. + CallNotifyAccessibilityEvent(event.get()); + std::vector<AXNodeInfoData*> top_to_bottom; + CallGetChildren(root, &top_to_bottom); ASSERT_EQ(2U, top_to_bottom.size()); ASSERT_EQ(2, top_to_bottom[0]->id); ASSERT_EQ(1, top_to_bottom[1]->id); // Non-overlapping, top to bottom. - event1->node_data[1]->bounds_in_screen = gfx::Rect(0, 0, 50, 50); - event1->node_data[2]->bounds_in_screen = gfx::Rect(100, 100, 100, 100); + button1->bounds_in_screen = gfx::Rect(0, 0, 50, 50); + button2->bounds_in_screen = gfx::Rect(100, 100, 100, 100); + CallNotifyAccessibilityEvent(event.get()); top_to_bottom.clear(); - CallGetChildren(event1->node_data[0].get(), &top_to_bottom); + CallGetChildren(event->node_data[0].get(), &top_to_bottom); ASSERT_EQ(2U, top_to_bottom.size()); ASSERT_EQ(1, top_to_bottom[0]->id); ASSERT_EQ(2, top_to_bottom[1]->id); // Overlapping; right to left. - event1->node_data[1]->bounds_in_screen = gfx::Rect(101, 100, 99, 100); - event1->node_data[2]->bounds_in_screen = gfx::Rect(100, 100, 100, 100); - std::vector<mojom::AccessibilityNodeInfoData*> left_to_right; - CallGetChildren(event1->node_data[0].get(), &left_to_right); + button1->bounds_in_screen = gfx::Rect(101, 100, 99, 100); + button2->bounds_in_screen = gfx::Rect(100, 100, 100, 100); + CallNotifyAccessibilityEvent(event.get()); + std::vector<AXNodeInfoData*> left_to_right; + CallGetChildren(root, &left_to_right); ASSERT_EQ(2U, left_to_right.size()); ASSERT_EQ(2, left_to_right[0]->id); ASSERT_EQ(1, left_to_right[1]->id); // Overlapping; left to right. - event1->node_data[1]->bounds_in_screen = gfx::Rect(100, 100, 100, 100); - event1->node_data[2]->bounds_in_screen = gfx::Rect(101, 100, 99, 100); + button1->bounds_in_screen = gfx::Rect(100, 100, 100, 100); + button2->bounds_in_screen = gfx::Rect(101, 100, 99, 100); + CallNotifyAccessibilityEvent(event.get()); left_to_right.clear(); - CallGetChildren(event1->node_data[0].get(), &left_to_right); + CallGetChildren(event->node_data[0].get(), &left_to_right); ASSERT_EQ(2U, left_to_right.size()); ASSERT_EQ(1, left_to_right[0]->id); ASSERT_EQ(2, left_to_right[1]->id); // Overlapping, bottom to top. - event1->node_data[1]->bounds_in_screen = gfx::Rect(100, 100, 100, 100); - event1->node_data[2]->bounds_in_screen = gfx::Rect(100, 99, 100, 100); + button1->bounds_in_screen = gfx::Rect(100, 100, 100, 100); + button2->bounds_in_screen = gfx::Rect(100, 99, 100, 100); + CallNotifyAccessibilityEvent(event.get()); top_to_bottom.clear(); - CallGetChildren(event1->node_data[0].get(), &top_to_bottom); + CallGetChildren(event->node_data[0].get(), &top_to_bottom); ASSERT_EQ(2U, top_to_bottom.size()); ASSERT_EQ(2, top_to_bottom[0]->id); ASSERT_EQ(1, top_to_bottom[1]->id); // Overlapping, top to bottom. - event1->node_data[1]->bounds_in_screen = gfx::Rect(100, 99, 100, 100); - event1->node_data[2]->bounds_in_screen = gfx::Rect(100, 100, 100, 100); + button1->bounds_in_screen = gfx::Rect(100, 99, 100, 100); + button2->bounds_in_screen = gfx::Rect(100, 100, 100, 100); + CallNotifyAccessibilityEvent(event.get()); top_to_bottom.clear(); - CallGetChildren(event1->node_data[0].get(), &top_to_bottom); + CallGetChildren(event->node_data[0].get(), &top_to_bottom); ASSERT_EQ(2U, top_to_bottom.size()); ASSERT_EQ(1, top_to_bottom[0]->id); ASSERT_EQ(2, top_to_bottom[1]->id); // Identical. smaller to larger. - event1->node_data[1]->bounds_in_screen = gfx::Rect(100, 100, 100, 10); - event1->node_data[2]->bounds_in_screen = gfx::Rect(100, 100, 100, 100); - std::vector<mojom::AccessibilityNodeInfoData*> dimension; - CallGetChildren(event1->node_data[0].get(), &dimension); + button1->bounds_in_screen = gfx::Rect(100, 100, 100, 10); + button2->bounds_in_screen = gfx::Rect(100, 100, 100, 100); + CallNotifyAccessibilityEvent(event.get()); + std::vector<AXNodeInfoData*> dimension; + CallGetChildren(event->node_data[0].get(), &dimension); ASSERT_EQ(2U, dimension.size()); ASSERT_EQ(2, dimension[0]->id); ASSERT_EQ(1, dimension[1]->id); - event1->node_data[1]->bounds_in_screen = gfx::Rect(100, 100, 10, 100); - event1->node_data[2]->bounds_in_screen = gfx::Rect(100, 100, 100, 100); + button1->bounds_in_screen = gfx::Rect(100, 100, 10, 100); + button2->bounds_in_screen = gfx::Rect(100, 100, 100, 100); + CallNotifyAccessibilityEvent(event.get()); dimension.clear(); - CallGetChildren(event1->node_data[0].get(), &dimension); + CallGetChildren(event->node_data[0].get(), &dimension); ASSERT_EQ(2U, dimension.size()); ASSERT_EQ(2, dimension[0]->id); ASSERT_EQ(1, dimension[1]->id); // Identical. Larger to smaller. - event1->node_data[1]->bounds_in_screen = gfx::Rect(100, 100, 100, 100); - event1->node_data[2]->bounds_in_screen = gfx::Rect(100, 100, 100, 10); + button1->bounds_in_screen = gfx::Rect(100, 100, 100, 100); + button2->bounds_in_screen = gfx::Rect(100, 100, 100, 10); + CallNotifyAccessibilityEvent(event.get()); dimension.clear(); - CallGetChildren(event1->node_data[0].get(), &dimension); + CallGetChildren(event->node_data[0].get(), &dimension); ASSERT_EQ(2U, dimension.size()); ASSERT_EQ(1, dimension[0]->id); ASSERT_EQ(2, dimension[1]->id); - event1->node_data[1]->bounds_in_screen = gfx::Rect(100, 100, 100, 100); - event1->node_data[2]->bounds_in_screen = gfx::Rect(100, 100, 10, 100); + button1->bounds_in_screen = gfx::Rect(100, 100, 100, 100); + button2->bounds_in_screen = gfx::Rect(100, 100, 10, 100); + CallNotifyAccessibilityEvent(event.get()); dimension.clear(); - CallGetChildren(event1->node_data[0].get(), &dimension); + CallGetChildren(event->node_data[0].get(), &dimension); ASSERT_EQ(2U, dimension.size()); ASSERT_EQ(1, dimension[0]->id); ASSERT_EQ(2, dimension[1]->id); } TEST_F(AXTreeSourceArcTest, AccessibleNameComputation) { - auto event = arc::mojom::AccessibilityEventData::New(); + auto event = AXEventData::New(); event->source_id = 0; event->task_id = 1; - event->event_type = arc::mojom::AccessibilityEventType::VIEW_FOCUSED; - event->node_data.push_back(arc::mojom::AccessibilityNodeInfoData::New()); - event->node_data[0]->id = 0; - event->node_data[0]->string_properties = - std::unordered_map<arc::mojom::AccessibilityStringProperty, - std::string>(); + event->event_type = AXEventType::VIEW_FOCUSED; + event->node_data.push_back(AXNodeInfoData::New()); + AXNodeInfoData* root = event->node_data.back().get(); + root->id = 0; + SetProperty(root, AXStringProperty::CLASS_NAME, ""); // Populate the tree source with the data. CallNotifyAccessibilityEvent(event.get()); @@ -196,46 +232,41 @@ // No attributes. std::unique_ptr<ui::AXNodeData> data; - CallSerializeNode(event->node_data[0].get(), &data); + CallSerializeNode(root, &data); std::string name; ASSERT_FALSE( data->GetStringAttribute(ax::mojom::StringAttribute::kName, &name)); // Text (empty). - event->node_data[0]->string_properties.value().insert( - std::make_pair(arc::mojom::AccessibilityStringProperty::TEXT, "")); + SetProperty(root, AXStringProperty::TEXT, ""); - CallSerializeNode(event->node_data[0].get(), &data); + CallSerializeNode(root, &data); ASSERT_TRUE( data->GetStringAttribute(ax::mojom::StringAttribute::kName, &name)); ASSERT_EQ("", name); // Text (non-empty). - event->node_data[0]->string_properties->clear(); - event->node_data[0]->string_properties.value().insert(std::make_pair( - arc::mojom::AccessibilityStringProperty::TEXT, "label text")); + root->string_properties->clear(); + SetProperty(root, AXStringProperty::TEXT, "label text"); - CallSerializeNode(event->node_data[0].get(), &data); + CallSerializeNode(root, &data); ASSERT_TRUE( data->GetStringAttribute(ax::mojom::StringAttribute::kName, &name)); ASSERT_EQ("label text", name); // Content description (empty), text (non-empty). - event->node_data[0]->string_properties.value().insert(std::make_pair( - arc::mojom::AccessibilityStringProperty::CONTENT_DESCRIPTION, "")); + SetProperty(root, AXStringProperty::CONTENT_DESCRIPTION, ""); - CallSerializeNode(event->node_data[0].get(), &data); + CallSerializeNode(root, &data); ASSERT_TRUE( data->GetStringAttribute(ax::mojom::StringAttribute::kName, &name)); ASSERT_EQ("label text", name); // Content description (non-empty), text (non-empty). - event->node_data[0] - ->string_properties - .value()[arc::mojom::AccessibilityStringProperty::CONTENT_DESCRIPTION] = + root->string_properties.value()[AXStringProperty::CONTENT_DESCRIPTION] = "label content description"; - CallSerializeNode(event->node_data[0].get(), &data); + CallSerializeNode(root, &data); ASSERT_TRUE( data->GetStringAttribute(ax::mojom::StringAttribute::kName, &name)); ASSERT_EQ("label content description", name);
diff --git a/chrome/browser/chromeos/arc/intent_helper/arc_external_protocol_dialog.cc b/chrome/browser/chromeos/arc/intent_helper/arc_external_protocol_dialog.cc index 08ba5da..d82dcbb1 100644 --- a/chrome/browser/chromeos/arc/intent_helper/arc_external_protocol_dialog.cc +++ b/chrome/browser/chromeos/arc/intent_helper/arc_external_protocol_dialog.cc
@@ -9,6 +9,7 @@ #include "base/bind.h" #include "base/lazy_instance.h" #include "base/memory/ref_counted.h" +#include "chrome/browser/chromeos/apps/intent_helper/apps_navigation_types.h" #include "chrome/browser/chromeos/arc/intent_helper/arc_navigation_throttle.h" #include "chrome/browser/chromeos/external_protocol_dialog.h" #include "chrome/browser/tab_contents/tab_util.h" @@ -350,16 +351,16 @@ std::unique_ptr<ArcIntentHelperBridge::ActivityToIconsMap> icons) { DCHECK_CURRENTLY_ON(content::BrowserThread::UI); - using AppInfo = ArcNavigationThrottle::AppInfo; + using AppInfo = chromeos::IntentPickerAppInfo; std::vector<AppInfo> app_info; for (const auto& handler : handlers) { const ArcIntentHelperBridge::ActivityName activity(handler->package_name, handler->activity_name); const auto it = icons->find(activity); - app_info.emplace_back( - AppInfo(it != icons->end() ? it->second.icon16 : gfx::Image(), - handler->package_name, handler->name)); + app_info.emplace_back(chromeos::AppType::ARC, + it != icons->end() ? it->second.icon16 : gfx::Image(), + handler->package_name, handler->name); } auto show_bubble_cb = base::Bind(ShowIntentPickerBubble());
diff --git a/chrome/browser/chromeos/arc/intent_helper/arc_navigation_throttle.cc b/chrome/browser/chromeos/arc/intent_helper/arc_navigation_throttle.cc index 3b1beed..bf41f9d 100644 --- a/chrome/browser/chromeos/arc/intent_helper/arc_navigation_throttle.cc +++ b/chrome/browser/chromeos/arc/intent_helper/arc_navigation_throttle.cc
@@ -4,11 +4,10 @@ #include "chrome/browser/chromeos/arc/intent_helper/arc_navigation_throttle.h" -#include <algorithm> +#include <utility> #include "base/bind.h" -#include "base/logging.h" -#include "base/memory/ref_counted.h" +#include "base/callback.h" #include "base/metrics/histogram_macros.h" #include "chrome/browser/ui/browser.h" #include "chrome/browser/ui/browser_commands.h" @@ -17,74 +16,26 @@ #include "components/arc/arc_bridge_service.h" #include "components/arc/arc_service_manager.h" #include "components/arc/intent_helper/arc_intent_helper_bridge.h" -#include "components/arc/intent_helper/page_transition_util.h" #include "content/public/browser/browser_thread.h" #include "content/public/browser/navigation_controller.h" #include "content/public/browser/navigation_handle.h" -#include "content/public/browser/site_instance.h" #include "content/public/browser/web_contents.h" #include "net/base/registry_controlled_domains/registry_controlled_domain.h" -#include "ui/base/page_transition_types.h" -#include "ui/gfx/image/image.h" namespace arc { namespace { -constexpr char kGoogleCom[] = "google.com"; - -// Compares the host name of the referrer and target URL to decide whether -// the navigation needs to be overriden. -bool ShouldOverrideUrlLoading(const GURL& previous_url, - const GURL& current_url) { - // When the navigation is initiated in a web page where sending a referrer - // is disabled, |previous_url| can be empty. In this case, we should open - // it in the desktop browser. - if (!previous_url.is_valid() || previous_url.is_empty()) - return false; - - // Also check |current_url| just in case. - if (!current_url.is_valid() || current_url.is_empty()) { - DVLOG(1) << "Unexpected URL: " << current_url << ", opening it in Chrome."; - return false; - } - - // Check the scheme for both |previous_url| and |current_url| since an - // extension could have referred us (e.g. Google Docs). - if (!current_url.SchemeIsHTTPOrHTTPS() || - !previous_url.SchemeIsHTTPOrHTTPS()) { - return false; - } - - if (net::registry_controlled_domains::SameDomainOrHost( - current_url, previous_url, - net::registry_controlled_domains::INCLUDE_PRIVATE_REGISTRIES)) { - if (net::registry_controlled_domains::GetDomainAndRegistry( - current_url, - net::registry_controlled_domains::INCLUDE_PRIVATE_REGISTRIES) == - kGoogleCom) { - // Navigation within the google.com domain are good candidates for this - // throttle (and consecuently the picker UI) only if they have different - // hosts, this is because multiple services are hosted within the same - // domain e.g. play.google.com, mail.google.com and so on. - return current_url.host_piece() != previous_url.host_piece(); - } - - return false; - } - return true; -} - -// Searches for a preferred app in |handlers| and returns its index. If not -// found, returns |handlers.size()|. +// Searches for a preferred app in |app_candidates| and returns its index. If +// not found, returns |app_candidates.size()|. size_t FindPreferredApp( - const std::vector<mojom::IntentHandlerInfoPtr>& handlers, + const std::vector<mojom::IntentHandlerInfoPtr>& app_candidates, const GURL& url_for_logging) { - for (size_t i = 0; i < handlers.size(); ++i) { - if (!handlers[i]->is_preferred) + for (size_t i = 0; i < app_candidates.size(); ++i) { + if (!app_candidates[i]->is_preferred) continue; if (ArcIntentHelperBridge::IsIntentHelperPackage( - handlers[i]->package_name)) { + app_candidates[i]->package_name)) { // If Chrome browser was selected as the preferred app, we shouldn't // create a throttle. DVLOG(1) @@ -93,163 +44,92 @@ } return i; } - return handlers.size(); // not found + return app_candidates.size(); // not found } } // namespace -ArcNavigationThrottle::ArcNavigationThrottle( - content::NavigationHandle* navigation_handle) - : content::NavigationThrottle(navigation_handle), - ui_displayed_(false), - weak_ptr_factory_(this) {} +ArcNavigationThrottle::ArcNavigationThrottle() : weak_ptr_factory_(this) {} ArcNavigationThrottle::~ArcNavigationThrottle() = default; -const char* ArcNavigationThrottle::GetNameForLogging() { - return "ArcNavigationThrottle"; -} - -content::NavigationThrottle::ThrottleCheckResult -ArcNavigationThrottle::WillStartRequest() { - DCHECK_CURRENTLY_ON(content::BrowserThread::UI); - starting_gurl_ = GetStartingGURL(); - Browser* browser = - chrome::FindBrowserWithWebContents(navigation_handle()->GetWebContents()); - if (browser) - chrome::SetIntentPickerViewVisibility(browser, false); - return HandleRequest(); -} - -content::NavigationThrottle::ThrottleCheckResult -ArcNavigationThrottle::WillRedirectRequest() { - DCHECK_CURRENTLY_ON(content::BrowserThread::UI); - - // TODO(djacobo): Consider what to do when there is another url during the - // same navigation that could be handled by ARC apps, two ideas are: 1) update - // the bubble with a mix of both app candidates (if different) 2) show a - // bubble based on the last url, thus closing all the previous ones. - if (ui_displayed_) - return content::NavigationThrottle::PROCEED; - - return HandleRequest(); -} - -content::NavigationThrottle::ThrottleCheckResult -ArcNavigationThrottle::HandleRequest() { - DCHECK(!ui_displayed_); - content::NavigationHandle* handle = navigation_handle(); - const GURL& url = handle->GetURL(); - - // Always handle http(s) <form> submissions in Chrome for two reasons: 1) we - // don't have a way to send POST data to ARC, and 2) intercepting http(s) form - // submissions is not very important because such submissions are usually - // done within the same domain. ShouldOverrideUrlLoading() below filters out - // such submissions anyway. - constexpr bool kAllowFormSubmit = false; - - // Ignore navigations with the CLIENT_REDIRECT qualifier on. - constexpr bool kAllowClientRedirect = false; - - // We must never handle navigations started within a context menu. - if (handle->WasStartedFromContextMenu()) - return content::NavigationThrottle::PROCEED; - - if (ShouldIgnoreNavigation(handle->GetPageTransition(), kAllowFormSubmit, - kAllowClientRedirect)) - return content::NavigationThrottle::PROCEED; - - if (!ShouldOverrideUrlLoading(starting_gurl_, url)) - return content::NavigationThrottle::PROCEED; - +bool ArcNavigationThrottle::ShouldDeferRequest( + content::NavigationHandle* handle, + chromeos::AppsNavigationCallback callback) { ArcServiceManager* arc_service_manager = ArcServiceManager::Get(); if (!arc_service_manager) - return content::NavigationThrottle::PROCEED; + return false; auto* intent_helper_bridge = ArcIntentHelperBridge::GetForBrowserContext( handle->GetWebContents()->GetBrowserContext()); if (!intent_helper_bridge) - return content::NavigationThrottle::PROCEED; + return false; + const GURL& url = handle->GetURL(); if (intent_helper_bridge->ShouldChromeHandleUrl(url)) { // Allow navigation to proceed if there isn't an android app that handles // the given URL. - return content::NavigationThrottle::PROCEED; + return false; } auto* instance = ARC_GET_INSTANCE_FOR_METHOD( arc_service_manager->arc_bridge_service()->intent_helper(), RequestUrlHandlerList); if (!instance) - return content::NavigationThrottle::PROCEED; + return false; - // Assume the UI or a preferred app was found, reset to false only if we don't - // find a valid app candidate. - ui_displayed_ = true; + // Return true to defer the navigation until we asynchronously hear back from + // ARC whether a preferred app should be launched. This makes it safe to bind + // |handle| as a raw pointer argument. We will either resume or cancel the + // navigation as soon as the callback is run. instance->RequestUrlHandlerList( url.spec(), base::BindOnce(&ArcNavigationThrottle::OnAppCandidatesReceived, - weak_ptr_factory_.GetWeakPtr())); - // We don't want to block the navigation, the only exception is here since we - // need to know if we really need to launch the UI or not, navigation is - // resumed right after we receive an answer from ARC's side (no user - // interaction needed). - return content::NavigationThrottle::DEFER; -} - -GURL ArcNavigationThrottle::GetStartingGURL() const { - // This helps us determine a reference GURL for the current NavigationHandle. - // This is the order or preferrence: Referrer > LastCommittedURL > SiteURL, - // GetSiteURL *should* only be used on very rare cases, e.g. when the - // navigation goes from https: to http: on a new tab, thus losing the other - // potential referrers. - const GURL referrer_url = navigation_handle()->GetReferrer().url; - if (referrer_url.is_valid() && !referrer_url.is_empty()) - return referrer_url; - - const GURL last_committed_url = - navigation_handle()->GetWebContents()->GetLastCommittedURL(); - if (last_committed_url.is_valid() && !last_committed_url.is_empty()) - return last_committed_url; - - return navigation_handle()->GetStartingSiteInstance()->GetSiteURL(); + weak_ptr_factory_.GetWeakPtr(), handle, + std::move(callback))); + return true; } void ArcNavigationThrottle::OnAppCandidatesReceived( - std::vector<mojom::IntentHandlerInfoPtr> handlers) { - if (FoundPreferredOrVerifiedArcApp(std::move(handlers))) { - content::WebContents* tab = navigation_handle()->GetWebContents(); - if (tab && tab->GetController().IsInitialNavigation()) - tab->Close(); - else - CancelDeferredNavigation(content::NavigationThrottle::CANCEL_AND_IGNORE); - } else { - Resume(); - } -} - -bool ArcNavigationThrottle::FoundPreferredOrVerifiedArcApp( - std::vector<mojom::IntentHandlerInfoPtr> handlers) { - DCHECK_CURRENTLY_ON(content::BrowserThread::UI); - content::NavigationHandle* handle = navigation_handle(); + content::NavigationHandle* handle, + chromeos::AppsNavigationCallback callback, + std::vector<mojom::IntentHandlerInfoPtr> app_candidates) { const GURL& url = handle->GetURL(); - - bool cancel_navigation = false; - if (!IsAppAvailable(handlers)) { + if (!IsAppAvailable(app_candidates)) { // This scenario shouldn't be accessed as ArcNavigationThrottle is created // iff there are ARC apps which can actually handle the given URL. DVLOG(1) << "There are no app candidates for this URL: " << url; - ui_displayed_ = false; RecordUma(CloseReason::ERROR, Platform::CHROME); - return cancel_navigation; + std::move(callback).Run(chromeos::AppsNavigationAction::RESUME, {}); + return; } - // If one of the apps is marked as preferred, use it right away without - // showing the UI. - const size_t index = FindPreferredApp(handlers, url); - if (index != handlers.size()) { + content::WebContents* web_contents = handle->GetWebContents(); + // If one of the apps is marked as preferred, launch it immediately. + if (DidLaunchPreferredArcApp(url, web_contents, app_candidates)) { + std::move(callback).Run(chromeos::AppsNavigationAction::CANCEL, {}); + return; + } + + // We are always going to resume navigation at this point, and possibly show + // the intent picker bubble to prompt the user to choose if they would like to + // use an ARC app to open the URL. + ArcAppIconQuery(url, web_contents, std::move(app_candidates), + base::BindOnce(std::move(callback), + chromeos::AppsNavigationAction::RESUME)); +} + +bool ArcNavigationThrottle::DidLaunchPreferredArcApp( + const GURL& url, + content::WebContents* web_contents, + const std::vector<mojom::IntentHandlerInfoPtr>& app_candidates) { + DCHECK_CURRENTLY_ON(content::BrowserThread::UI); + + bool cancel_navigation = false; + const size_t index = FindPreferredApp(app_candidates, url); + if (index != app_candidates.size()) { CloseReason close_reason = CloseReason::PREFERRED_ACTIVITY_FOUND; - const std::string package_name = handlers[index]->package_name; + const std::string package_name = app_candidates[index]->package_name; // Make sure that the instance at least supports HandleUrl. auto* arc_service_manager = ArcServiceManager::Get(); @@ -264,7 +144,7 @@ close_reason = CloseReason::ERROR; } else if (ArcIntentHelperBridge::IsIntentHelperPackage(package_name)) { chrome::SetIntentPickerViewVisibility( - chrome::FindBrowserWithWebContents(handle->GetWebContents()), true); + chrome::FindBrowserWithWebContents(web_contents), true); } else { instance->HandleUrl(url.spec(), package_name); cancel_navigation = true; @@ -272,54 +152,61 @@ Platform platform = GetDestinationPlatform(package_name, close_reason); RecordUma(close_reason, platform); - } else { - auto* intent_helper_bridge = ArcIntentHelperBridge::GetForBrowserContext( - handle->GetWebContents()->GetBrowserContext()); - if (!intent_helper_bridge) { - LOG(ERROR) << "Cannot get an instance of ArcIntentHelperBridge"; - RecordUma(CloseReason::ERROR, Platform::CHROME); - return cancel_navigation; - } - std::vector<ArcIntentHelperBridge::ActivityName> activities; - for (const auto& handler : handlers) - activities.emplace_back(handler->package_name, handler->activity_name); - - intent_helper_bridge->GetActivityIcons( - activities, - base::BindOnce( - &ArcNavigationThrottle::AsyncOnAppIconsReceived, - chrome::FindBrowserWithWebContents(handle->GetWebContents()), - std::move(handlers), url)); } - return cancel_navigation; } -// static -void ArcNavigationThrottle::AsyncOnAppIconsReceived( - const Browser* browser, - std::vector<arc::mojom::IntentHandlerInfoPtr> handlers, +void ArcNavigationThrottle::ArcAppIconQuery( const GURL& url, - std::unique_ptr<arc::ArcIntentHelperBridge::ActivityToIconsMap> icons) { - std::vector<AppInfo> app_info; + content::WebContents* web_contents, + std::vector<mojom::IntentHandlerInfoPtr> app_candidates, + chromeos::QueryAppsCallback callback) { + DCHECK_CURRENTLY_ON(content::BrowserThread::UI); - for (const auto& handler : handlers) { - gfx::Image icon; - const arc::ArcIntentHelperBridge::ActivityName activity( - handler->package_name, handler->activity_name); - const auto it = icons->find(activity); - - app_info.emplace_back(it != icons->end() ? it->second.icon16 : gfx::Image(), - handler->package_name, handler->name); + auto* intent_helper_bridge = ArcIntentHelperBridge::GetForBrowserContext( + web_contents->GetBrowserContext()); + if (!intent_helper_bridge) { + LOG(ERROR) << "Cannot get an instance of ArcIntentHelperBridge"; + RecordUma(CloseReason::ERROR, Platform::CHROME); + std::move(callback).Run({}); + return; } + std::vector<ArcIntentHelperBridge::ActivityName> activities; + for (const auto& candidate : app_candidates) + activities.emplace_back(candidate->package_name, candidate->activity_name); - chrome::QueryAndDisplayArcApps( - browser, app_info, - base::Bind(&ArcNavigationThrottle::AsyncOnIntentPickerClosed, url)); + intent_helper_bridge->GetActivityIcons( + activities, + base::BindOnce(&ArcNavigationThrottle::OnAppIconsReceived, + chrome::FindBrowserWithWebContents(web_contents), + std::move(app_candidates), url, std::move(callback))); } // static -void ArcNavigationThrottle::AsyncOnIntentPickerClosed( +void ArcNavigationThrottle::OnAppIconsReceived( + const Browser* browser, + std::vector<arc::mojom::IntentHandlerInfoPtr> app_candidates, + const GURL& url, + chromeos::QueryAppsCallback callback, + std::unique_ptr<arc::ArcIntentHelperBridge::ActivityToIconsMap> icons) { + std::vector<chromeos::IntentPickerAppInfo> app_info; + + for (const auto& candidate : app_candidates) { + gfx::Image icon; + const arc::ArcIntentHelperBridge::ActivityName activity( + candidate->package_name, candidate->activity_name); + const auto it = icons->find(activity); + + app_info.emplace_back(chromeos::AppType::ARC, + it != icons->end() ? it->second.icon16 : gfx::Image(), + candidate->package_name, candidate->name); + } + + std::move(callback).Run(app_info); +} + +// static +void ArcNavigationThrottle::OnIntentPickerClosed( const GURL& url, const std::string& pkg, arc::ArcNavigationThrottle::CloseReason close_reason) { @@ -381,13 +268,13 @@ // static size_t ArcNavigationThrottle::GetAppIndex( - const std::vector<mojom::IntentHandlerInfoPtr>& handlers, + const std::vector<mojom::IntentHandlerInfoPtr>& app_candidates, const std::string& selected_app_package) { - for (size_t i = 0; i < handlers.size(); ++i) { - if (handlers[i]->package_name == selected_app_package) + for (size_t i = 0; i < app_candidates.size(); ++i) { + if (app_candidates[i]->package_name == selected_app_package) return i; } - return handlers.size(); + return app_candidates.size(); } // static @@ -415,37 +302,33 @@ // static bool ArcNavigationThrottle::IsAppAvailable( - const std::vector<mojom::IntentHandlerInfoPtr>& handlers) { - return handlers.size() > 1 || - (handlers.size() == 1 && !ArcIntentHelperBridge::IsIntentHelperPackage( - handlers[0]->package_name)); -} - -// static -bool ArcNavigationThrottle::ShouldOverrideUrlLoadingForTesting( - const GURL& previous_url, - const GURL& current_url) { - return ShouldOverrideUrlLoading(previous_url, current_url); + const std::vector<mojom::IntentHandlerInfoPtr>& app_candidates) { + return app_candidates.size() > 1 || + (app_candidates.size() == 1 && + !ArcIntentHelperBridge::IsIntentHelperPackage( + app_candidates[0]->package_name)); } // static bool ArcNavigationThrottle::IsAppAvailableForTesting( - const std::vector<mojom::IntentHandlerInfoPtr>& handlers) { - return IsAppAvailable(handlers); + const std::vector<mojom::IntentHandlerInfoPtr>& app_candidates) { + return IsAppAvailable(app_candidates); } // static size_t ArcNavigationThrottle::FindPreferredAppForTesting( - const std::vector<mojom::IntentHandlerInfoPtr>& handlers) { - return FindPreferredApp(handlers, GURL()); + const std::vector<mojom::IntentHandlerInfoPtr>& app_candidates) { + return FindPreferredApp(app_candidates, GURL()); } // static -void ArcNavigationThrottle::AsyncShowIntentPickerBubble(const Browser* browser, - const GURL& url) { +void ArcNavigationThrottle::QueryArcApps(const Browser* browser, + const GURL& url, + chromeos::QueryAppsCallback callback) { arc::ArcServiceManager* arc_service_manager = arc::ArcServiceManager::Get(); if (!arc_service_manager) { DVLOG(1) << "Cannot get an instance of ArcServiceManager"; + std::move(callback).Run({}); return; } @@ -454,22 +337,25 @@ RequestUrlHandlerList); if (!instance) { DVLOG(1) << "Cannot get access to RequestUrlHandlerList"; + std::move(callback).Run({}); return; } instance->RequestUrlHandlerList( url.spec(), base::BindOnce(&ArcNavigationThrottle::AsyncOnAppCandidatesReceived, - browser, url)); + browser, url, std::move(callback))); } // static void ArcNavigationThrottle::AsyncOnAppCandidatesReceived( const Browser* browser, const GURL& url, - std::vector<arc::mojom::IntentHandlerInfoPtr> handlers) { - if (!IsAppAvailable(handlers)) { + chromeos::QueryAppsCallback callback, + std::vector<arc::mojom::IntentHandlerInfoPtr> app_candidates) { + if (!IsAppAvailable(app_candidates)) { DVLOG(1) << "There are no app candidates for this URL"; + std::move(callback).Run({}); return; } @@ -477,17 +363,18 @@ browser->tab_strip_model()->GetActiveWebContents()->GetBrowserContext()); if (!intent_helper_bridge) { DVLOG(1) << "Cannot get an instance of ArcIntentHelperBridge"; + std::move(callback).Run({}); return; } std::vector<arc::ArcIntentHelperBridge::ActivityName> activities; - for (const auto& handler : handlers) - activities.emplace_back(handler->package_name, handler->activity_name); + for (const auto& candidate : app_candidates) + activities.emplace_back(candidate->package_name, candidate->activity_name); intent_helper_bridge->GetActivityIcons( activities, - base::BindOnce(&ArcNavigationThrottle::AsyncOnAppIconsReceived, browser, - std::move(handlers), url)); + base::BindOnce(&ArcNavigationThrottle::OnAppIconsReceived, browser, + std::move(app_candidates), url, std::move(callback))); } } // namespace arc
diff --git a/chrome/browser/chromeos/arc/intent_helper/arc_navigation_throttle.h b/chrome/browser/chromeos/arc/intent_helper/arc_navigation_throttle.h index b1baa366..5bb0f77 100644 --- a/chrome/browser/chromeos/arc/intent_helper/arc_navigation_throttle.h +++ b/chrome/browser/chromeos/arc/intent_helper/arc_navigation_throttle.h
@@ -7,28 +7,26 @@ #include <memory> #include <string> -#include <utility> #include <vector> -#include "base/callback.h" #include "base/macros.h" #include "base/memory/weak_ptr.h" +#include "chrome/browser/chromeos/apps/intent_helper/apps_navigation_types.h" #include "components/arc/intent_helper/arc_intent_helper_bridge.h" -#include "content/public/browser/navigation_throttle.h" -#include "ui/gfx/image/image.h" #include "url/gurl.h" class Browser; namespace content { class NavigationHandle; +class WebContents; } // namespace content namespace arc { // A class that allow us to retrieve ARC app's information and handle URL // traffic initiated on Chrome browser, either on Chrome or an ARC's app. -class ArcNavigationThrottle : public content::NavigationThrottle { +class ArcNavigationThrottle { public: // These enums are used to define the buckets for an enumerated UMA histogram // and need to be synced with histograms.xml. This enum class should also be @@ -66,32 +64,20 @@ SIZE, }; - // Restricts the amount of apps displayed to the user without the need of a - // ScrollView. - enum { kMaxAppResults = 3 }; + ArcNavigationThrottle(); + ~ArcNavigationThrottle(); - struct AppInfo { - AppInfo(gfx::Image img, std::string package, std::string activity) - : icon(img), package_name(package), activity_name(activity) {} - gfx::Image icon; - std::string package_name; - std::string activity_name; - }; + // Returns true if the navigation request represented by |handle| should be + // deferred while ARC is queried for apps, and if so, |callback| will be run + // asynchronously with the action for the navigation. |callback| will not be + // run if false is returned. + bool ShouldDeferRequest(content::NavigationHandle* handle, + chromeos::AppsNavigationCallback callback); - using QueryAndDisplayArcAppsCallback = base::Callback<void( - const Browser* browser, - const std::vector<AppInfo>& app_info, - const base::Callback<void(const std::string&, CloseReason)>& cb)>; - explicit ArcNavigationThrottle(content::NavigationHandle* navigation_handle); - ~ArcNavigationThrottle() override; - - static bool ShouldOverrideUrlLoadingForTesting(const GURL& previous_url, - const GURL& current_url); - - // Finds |selected_app_package| from the |handlers| array and returns the - // index. If the app is not found, returns |handlers.size()|. + // Finds |selected_app_package| from the |app_candidates| array and returns + // the index. If the app is not found, returns |app_candidates.size()|. static size_t GetAppIndex( - const std::vector<mojom::IntentHandlerInfoPtr>& handlers, + const std::vector<mojom::IntentHandlerInfoPtr>& app_candidates, const std::string& selected_app_package); // Determines the destination of the current navigation. We know that if the // |close_reason| is either ERROR or DIALOG_DEACTIVATED the navigation MUST @@ -105,65 +91,62 @@ static void RecordUma(CloseReason close_reason, Platform platform); // TODO(djacobo): Remove this function and instead stop ARC from returning // Chrome as a valid app candidate. - // Records true if |handlers| contain one or more apps. When this function is - // called from OnAppCandidatesReceived, |handlers| always contain Chrome (aka - // intent helper), but the same function doesn't treat this as an app. + // Records true if |app_candidates| contain one or more apps. When this + // function is called from OnAppCandidatesReceived, |app_candidates| always + // contains Chrome (aka intent helper), but the same function doesn't treat + // this as an app. static bool IsAppAvailable( - const std::vector<mojom::IntentHandlerInfoPtr>& handlers); + const std::vector<mojom::IntentHandlerInfoPtr>& app_candidates); static bool IsAppAvailableForTesting( - const std::vector<mojom::IntentHandlerInfoPtr>& handlers); + const std::vector<mojom::IntentHandlerInfoPtr>& app_candidates); static size_t FindPreferredAppForTesting( - const std::vector<mojom::IntentHandlerInfoPtr>& handlers); - static void AsyncShowIntentPickerBubble(const Browser* browser, - const GURL& url); - // content::Navigation implementation: - const char* GetNameForLogging() override; - - private: - // content::Navigation implementation: - NavigationThrottle::ThrottleCheckResult WillStartRequest() override; - NavigationThrottle::ThrottleCheckResult WillRedirectRequest() override; - - NavigationThrottle::ThrottleCheckResult HandleRequest(); - // Resume/Cancel the current navigation which was put in DEFER. Close the - // current tab only if we continue the navigation on ARC and the current tab - // was explicitly generated for this navigation. - void OnAppCandidatesReceived( - std::vector<mojom::IntentHandlerInfoPtr> handlers); - // Receives the array of app candidates to handle this URL and decides whether - // a preferred app should be triggered right away or ask the browser to - // display the intent picker. - bool FoundPreferredOrVerifiedArcApp( - std::vector<mojom::IntentHandlerInfoPtr> handlers); - void OnAppIconsReceived( - std::vector<mojom::IntentHandlerInfoPtr> handlers, - std::unique_ptr<ArcIntentHelperBridge::ActivityToIconsMap> icons); - void DisplayArcApps() const; - GURL GetStartingGURL() const; - static void AsyncOnAppCandidatesReceived( - const Browser* browser, - const GURL& url, - std::vector<arc::mojom::IntentHandlerInfoPtr> handlers); - static void AsyncOnAppIconsReceived( - const Browser* browser, - std::vector<arc::mojom::IntentHandlerInfoPtr> handlers, - const GURL& url, - std::unique_ptr<arc::ArcIntentHelperBridge::ActivityToIconsMap> icons); - static void AsyncOnIntentPickerClosed( + const std::vector<mojom::IntentHandlerInfoPtr>& app_candidates); + static void QueryArcApps(const Browser* browser, + const GURL& url, + chromeos::QueryAppsCallback callback); + static void OnIntentPickerClosed( const GURL& url, const std::string& package_name, arc::ArcNavigationThrottle::CloseReason close_reason); - // Keeps a referrence to the starting GURL. - GURL starting_gurl_; + private: + // Determines whether we should open a preferred app or show the intent + // picker. Resume/Cancel the navigation which was put in DEFER. Close the + // current tab only if we continue the navigation on ARC and the current tab + // was explicitly generated for this navigation. + void OnAppCandidatesReceived( + content::NavigationHandle* handle, + chromeos::AppsNavigationCallback callback, + std::vector<mojom::IntentHandlerInfoPtr> app_candidates); - // Keeps track of whether we already shown the UI or preferred app. Since - // ArcNavigationThrottle cannot wait for the user (due to the non-blocking - // nature of the feature) the best we can do is check if we launched a - // preferred app or asked the UI to be shown, this flag ensures we never - // trigger the UI twice for the same throttle. - bool ui_displayed_; + // Returns true if an app in |app_candidates| is preferred for handling the + // navigation represented by |handle|, and we are successfully able to launch + // it. + bool DidLaunchPreferredArcApp( + const GURL& url, + content::WebContents* web_contents, + const std::vector<mojom::IntentHandlerInfoPtr>& app_candidates); + + // Queries the ArcIntentHelperBridge for ARC app icons for the apps in + // |app_candidates|. Calls OnAppIconsReceived() when finished. + void ArcAppIconQuery(const GURL& url, + content::WebContents* web_contents, + std::vector<mojom::IntentHandlerInfoPtr> app_candidates, + chromeos::QueryAppsCallback callback); + + static void AsyncOnAppCandidatesReceived( + const Browser* browser, + const GURL& url, + chromeos::QueryAppsCallback callback, + std::vector<arc::mojom::IntentHandlerInfoPtr> app_candidates); + + static void OnAppIconsReceived( + const Browser* browser, + std::vector<arc::mojom::IntentHandlerInfoPtr> app_candidates, + const GURL& url, + chromeos::QueryAppsCallback callback, + std::unique_ptr<arc::ArcIntentHelperBridge::ActivityToIconsMap> icons); // This has to be the last member of the class. base::WeakPtrFactory<ArcNavigationThrottle> weak_ptr_factory_;
diff --git a/chrome/browser/chromeos/arc/intent_helper/arc_navigation_throttle_unittest.cc b/chrome/browser/chromeos/arc/intent_helper/arc_navigation_throttle_unittest.cc index f216b058..5c2d503f 100644 --- a/chrome/browser/chromeos/arc/intent_helper/arc_navigation_throttle_unittest.cc +++ b/chrome/browser/chromeos/arc/intent_helper/arc_navigation_throttle_unittest.cc
@@ -2,12 +2,11 @@ // Use of this source code is governed by a BSD-style license that can be // found in the LICENSE file. -#include <algorithm> +#include <utility> #include "chrome/browser/chromeos/arc/intent_helper/arc_navigation_throttle.h" #include "components/arc/intent_helper/arc_intent_helper_bridge.h" #include "testing/gtest/include/gtest/gtest.h" -#include "url/gurl.h" namespace arc { @@ -35,80 +34,6 @@ } // namespace -TEST(ArcNavigationThrottleTest, TestShouldOverrideUrlLoading) { - // A navigation within the same domain shouldn't be overridden except if the - // domain is google.com. - EXPECT_FALSE(ArcNavigationThrottle::ShouldOverrideUrlLoadingForTesting( - GURL("http://google.com"), GURL("http://google.com/"))); - EXPECT_TRUE(ArcNavigationThrottle::ShouldOverrideUrlLoadingForTesting( - GURL("http://google.com"), GURL("http://a.google.com/"))); - EXPECT_TRUE(ArcNavigationThrottle::ShouldOverrideUrlLoadingForTesting( - GURL("http://a.google.com"), GURL("http://google.com/"))); - EXPECT_TRUE(ArcNavigationThrottle::ShouldOverrideUrlLoadingForTesting( - GURL("http://a.google.com"), GURL("http://b.google.com/"))); - EXPECT_TRUE(ArcNavigationThrottle::ShouldOverrideUrlLoadingForTesting( - GURL("http://a.google.com"), GURL("http://b.c.google.com/"))); - EXPECT_TRUE(ArcNavigationThrottle::ShouldOverrideUrlLoadingForTesting( - GURL("http://a.b.google.com"), GURL("http://c.google.com/"))); - EXPECT_TRUE(ArcNavigationThrottle::ShouldOverrideUrlLoadingForTesting( - GURL("http://a.b.google.com"), GURL("http://b.google.com"))); - EXPECT_TRUE(ArcNavigationThrottle::ShouldOverrideUrlLoadingForTesting( - GURL("http://b.google.com"), GURL("http://a.b.google.com"))); - EXPECT_FALSE(ArcNavigationThrottle::ShouldOverrideUrlLoadingForTesting( - GURL("http://notg.com"), GURL("http://notg.com"))); - EXPECT_FALSE(ArcNavigationThrottle::ShouldOverrideUrlLoadingForTesting( - GURL("http://a.notg.com"), GURL("http://notg.com"))); - EXPECT_FALSE(ArcNavigationThrottle::ShouldOverrideUrlLoadingForTesting( - GURL("http://notg.com"), GURL("http://a.notg.com"))); - EXPECT_FALSE(ArcNavigationThrottle::ShouldOverrideUrlLoadingForTesting( - GURL("http://a.notg.com"), GURL("http://b.notg.com"))); - EXPECT_FALSE(ArcNavigationThrottle::ShouldOverrideUrlLoadingForTesting( - GURL("http://a.notg.com"), GURL("http://a.b.notg.com"))); - EXPECT_FALSE(ArcNavigationThrottle::ShouldOverrideUrlLoadingForTesting( - GURL("http://a.b.notg.com"), GURL("http://c.notg.com"))); - - // Same as last tests, except for "play.google.com". - EXPECT_TRUE(ArcNavigationThrottle::ShouldOverrideUrlLoadingForTesting( - GURL("http://google.com"), GURL("http://play.google.com/fake_app"))); - EXPECT_TRUE(ArcNavigationThrottle::ShouldOverrideUrlLoadingForTesting( - GURL("https://www.google.com.mx"), - GURL("https://play.google.com/fake_app"))); - EXPECT_TRUE(ArcNavigationThrottle::ShouldOverrideUrlLoadingForTesting( - GURL("https://mail.google.com"), - GURL("https://play.google.com/fake_app"))); - EXPECT_FALSE(ArcNavigationThrottle::ShouldOverrideUrlLoadingForTesting( - GURL("https://play.google.com/search"), - GURL("https://play.google.com/fake_app"))); - EXPECT_TRUE(ArcNavigationThrottle::ShouldOverrideUrlLoadingForTesting( - GURL("http://not_google.com"), GURL("http://play.google.com/fake_app"))); - - // If either of two paramters is empty, the function should return false. - EXPECT_FALSE(ArcNavigationThrottle::ShouldOverrideUrlLoadingForTesting( - GURL(), GURL("http://a.google.com/"))); - EXPECT_FALSE(ArcNavigationThrottle::ShouldOverrideUrlLoadingForTesting( - GURL("http://a.google.com/"), GURL())); - EXPECT_FALSE(ArcNavigationThrottle::ShouldOverrideUrlLoadingForTesting( - GURL(), GURL())); - - // A navigation not within the same domain can be overridden. - EXPECT_TRUE(ArcNavigationThrottle::ShouldOverrideUrlLoadingForTesting( - GURL("http://www.google.com"), GURL("http://www.not-google.com/"))); - EXPECT_TRUE(ArcNavigationThrottle::ShouldOverrideUrlLoadingForTesting( - GURL("http://www.not-google.com"), GURL("http://www.google.com/"))); - - // A navigation with neither an http nor https scheme cannot be overriden. - EXPECT_FALSE(ArcNavigationThrottle::ShouldOverrideUrlLoadingForTesting( - GURL("chrome-extension://fake_document"), GURL("http://www.a.com"))); - EXPECT_FALSE(ArcNavigationThrottle::ShouldOverrideUrlLoadingForTesting( - GURL("http://www.a.com"), GURL("chrome-extension://fake_document"))); - EXPECT_FALSE(ArcNavigationThrottle::ShouldOverrideUrlLoadingForTesting( - GURL("chrome-extension://fake_document"), GURL("https://www.a.com"))); - EXPECT_FALSE(ArcNavigationThrottle::ShouldOverrideUrlLoadingForTesting( - GURL("https://www.a.com"), GURL("chrome-extension://fake_document"))); - EXPECT_FALSE(ArcNavigationThrottle::ShouldOverrideUrlLoadingForTesting( - GURL("chrome-extension://fake_a"), GURL("chrome-extension://fake_b"))); -} - TEST(ArcNavigationThrottleTest, TestIsAppAvailable) { // Test an empty array. EXPECT_FALSE(
diff --git a/chrome/browser/chromeos/cryptauth/chrome_cryptauth_service.cc b/chrome/browser/chromeos/cryptauth/chrome_cryptauth_service.cc index cfdf3f5..53de9d7 100644 --- a/chrome/browser/chromeos/cryptauth/chrome_cryptauth_service.cc +++ b/chrome/browser/chromeos/cryptauth/chrome_cryptauth_service.cc
@@ -13,6 +13,7 @@ #include "chrome/browser/browser_process.h" #include "chrome/browser/chrome_content_browser_client.h" #include "chrome/browser/chromeos/cryptauth/cryptauth_device_id_provider_impl.h" +#include "chrome/browser/chromeos/cryptauth/gcm_device_info_provider_impl.h" #include "chrome/browser/chromeos/login/easy_unlock/secure_message_delegate_chromeos.h" #include "chrome/browser/gcm/gcm_profile_service_factory.h" #include "chrome/browser/profiles/profile.h" @@ -45,29 +46,6 @@ namespace { -cryptauth::GcmDeviceInfo GetGcmDeviceInfo() { - cryptauth::GcmDeviceInfo device_info; - device_info.set_long_device_id( - cryptauth::CryptAuthDeviceIdProviderImpl::GetInstance()->GetDeviceId()); - device_info.set_device_type(cryptauth::CHROME); - device_info.set_device_software_version(version_info::GetVersionNumber()); - google::protobuf::int64 software_version_code = - cryptauth::HashStringToInt64(version_info::GetLastChange()); - device_info.set_device_software_version_code(software_version_code); - ChromeContentBrowserClient chrome_content_browser_client; - device_info.set_locale(chrome_content_browser_client.GetApplicationLocale()); - device_info.set_device_model(base::SysInfo::GetLsbReleaseBoard()); - device_info.set_device_os_version(base::GetLinuxDistro()); - // The Chrome OS version tracks the Chrome version, so fill in the same value - // as |device_software_version_code|. - device_info.set_device_os_version_code(software_version_code); - // |device_display_diagonal_mils| is unused because it only applies to - // phones/tablets, but it must be set due to server API verification. - device_info.set_device_display_diagonal_mils(0); - - return device_info; -} - std::unique_ptr<cryptauth::CryptAuthClientFactory> CreateCryptAuthClientFactoryImpl(Profile* profile) { return std::make_unique<cryptauth::CryptAuthClientFactoryImpl>( @@ -117,7 +95,8 @@ cryptauth::CryptAuthEnrollmentManagerImpl::Factory::NewInstance( base::DefaultClock::GetInstance(), std::make_unique<CryptAuthEnrollerFactoryImpl>(profile), - CreateSecureMessageDelegateImpl(), GetGcmDeviceInfo(), + CreateSecureMessageDelegateImpl(), + GcmDeviceInfoProviderImpl::GetInstance()->GetGcmDeviceInfo(), gcm_manager.get(), profile->GetPrefs()); // Note: ChromeCryptAuthServiceFactory DependsOn(OAuth2TokenServiceFactory),
diff --git a/chrome/browser/chromeos/cryptauth/gcm_device_info_provider_impl.cc b/chrome/browser/chromeos/cryptauth/gcm_device_info_provider_impl.cc new file mode 100644 index 0000000..97f89b1 --- /dev/null +++ b/chrome/browser/chromeos/cryptauth/gcm_device_info_provider_impl.cc
@@ -0,0 +1,57 @@ +// Copyright 2018 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 "chrome/browser/chromeos/cryptauth/gcm_device_info_provider_impl.h" + +#include "base/linux_util.h" +#include "base/no_destructor.h" +#include "base/sys_info.h" +#include "base/version.h" +#include "chrome/browser/chrome_content_browser_client.h" +#include "chrome/browser/chromeos/cryptauth/cryptauth_device_id_provider_impl.h" +#include "components/cryptauth/cryptauth_enrollment_utils.h" +#include "components/version_info/version_info.h" + +namespace chromeos { + +// static +const GcmDeviceInfoProviderImpl* GcmDeviceInfoProviderImpl::GetInstance() { + static const base::NoDestructor<GcmDeviceInfoProviderImpl> provider; + return provider.get(); +} + +const cryptauth::GcmDeviceInfo& GcmDeviceInfoProviderImpl::GetGcmDeviceInfo() + const { + static const base::NoDestructor<cryptauth::GcmDeviceInfo> gcm_device_info([] { + static const google::protobuf::int64 kSoftwareVersionCode = + cryptauth::HashStringToInt64(version_info::GetLastChange()); + + cryptauth::GcmDeviceInfo gcm_device_info; + + gcm_device_info.set_long_device_id( + cryptauth::CryptAuthDeviceIdProviderImpl::GetInstance()->GetDeviceId()); + gcm_device_info.set_device_type(cryptauth::CHROME); + gcm_device_info.set_device_software_version( + version_info::GetVersionNumber()); + gcm_device_info.set_device_software_version_code(kSoftwareVersionCode); + gcm_device_info.set_locale( + ChromeContentBrowserClient().GetApplicationLocale()); + gcm_device_info.set_device_model(base::SysInfo::GetLsbReleaseBoard()); + gcm_device_info.set_device_os_version(base::GetLinuxDistro()); + // The Chrome OS version tracks the Chrome version, so fill in the same + // value as |device_kSoftwareVersionCode|. + gcm_device_info.set_device_os_version_code(kSoftwareVersionCode); + // |device_display_diagonal_mils| is unused because it only applies to + // phones/tablets, but it must be set due to server API verification. + gcm_device_info.set_device_display_diagonal_mils(0); + + return gcm_device_info; + }()); + + return *gcm_device_info; +} + +GcmDeviceInfoProviderImpl::GcmDeviceInfoProviderImpl() = default; + +} // namespace chromeos
diff --git a/chrome/browser/chromeos/cryptauth/gcm_device_info_provider_impl.h b/chrome/browser/chromeos/cryptauth/gcm_device_info_provider_impl.h new file mode 100644 index 0000000..7168743 --- /dev/null +++ b/chrome/browser/chromeos/cryptauth/gcm_device_info_provider_impl.h
@@ -0,0 +1,33 @@ +// Copyright 2018 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 CHROME_BROWSER_CHROMEOS_CRYPTAUTH_GCM_DEVICE_INFO_PROVIDER_IMPL_H_ +#define CHROME_BROWSER_CHROMEOS_CRYPTAUTH_GCM_DEVICE_INFO_PROVIDER_IMPL_H_ + +#include "base/macros.h" +#include "base/no_destructor.h" +#include "components/cryptauth/gcm_device_info_provider.h" +#include "components/cryptauth/proto/cryptauth_api.pb.h" + +namespace chromeos { + +// Concrete GcmDeviceInfoProvider implementation. +class GcmDeviceInfoProviderImpl : public cryptauth::GcmDeviceInfoProvider { + public: + static const GcmDeviceInfoProviderImpl* GetInstance(); + + // cryptauth::GcmDeviceInfoProvider: + const cryptauth::GcmDeviceInfo& GetGcmDeviceInfo() const override; + + private: + friend class base::NoDestructor<GcmDeviceInfoProviderImpl>; + + GcmDeviceInfoProviderImpl(); + + DISALLOW_COPY_AND_ASSIGN(GcmDeviceInfoProviderImpl); +}; + +} // namespace chromeos + +#endif // CHROME_BROWSER_CHROMEOS_CRYPTAUTH_GCM_DEVICE_INFO_PROVIDER_IMPL_H_
diff --git a/chrome/browser/chromeos/extensions/quick_unlock_private/quick_unlock_private_api.cc b/chrome/browser/chromeos/extensions/quick_unlock_private/quick_unlock_private_api.cc index 526b42b..0b98270 100644 --- a/chrome/browser/chromeos/extensions/quick_unlock_private/quick_unlock_private_api.cc +++ b/chrome/browser/chromeos/extensions/quick_unlock_private/quick_unlock_private_api.cc
@@ -10,6 +10,7 @@ #include "base/stl_util.h" #include "chrome/browser/chromeos/login/easy_unlock/easy_unlock_service.h" +#include "chrome/browser/chromeos/login/quick_unlock/auth_token.h" #include "chrome/browser/chromeos/login/quick_unlock/quick_unlock_factory.h" #include "chrome/browser/chromeos/login/quick_unlock/quick_unlock_storage.h" #include "chrome/browser/chromeos/login/supervised/supervised_user_authentication.h" @@ -40,6 +41,7 @@ using CredentialRequirements = quick_unlock_private::CredentialRequirements; using QuickUnlockMode = quick_unlock_private::QuickUnlockMode; +using AuthToken = chromeos::quick_unlock::AuthToken; using QuickUnlockModeList = std::vector<QuickUnlockMode>; using QuickUnlockStorage = chromeos::quick_unlock::QuickUnlockStorage; @@ -253,8 +255,8 @@ Profile* profile = Profile::FromBrowserContext(browser_context()); QuickUnlockStorage* quick_unlock_storage = chromeos::quick_unlock::QuickUnlockFactory::GetForProfile(profile); - result->token = quick_unlock_storage->CreateAuthToken(); - result->lifetime_seconds = QuickUnlockStorage::kTokenExpirationSeconds; + result->token = quick_unlock_storage->CreateAuthToken(user_context); + result->lifetime_seconds = AuthToken::kTokenExpirationSeconds; Respond(ArgumentList( quick_unlock_private::GetAuthToken::Results::Create(*result))); @@ -395,8 +397,8 @@ QuickUnlockPrivateSetModesFunction::QuickUnlockPrivateSetModesFunction() : chrome_details_(this) {} -QuickUnlockPrivateSetModesFunction::~QuickUnlockPrivateSetModesFunction() { -} +QuickUnlockPrivateSetModesFunction::~QuickUnlockPrivateSetModesFunction() = + default; void QuickUnlockPrivateSetModesFunction::SetModesChangedEventHandlerForTesting( const ModesChangedEventHandler& handler) {
diff --git a/chrome/browser/chromeos/extensions/quick_unlock_private/quick_unlock_private_api_unittest.cc b/chrome/browser/chromeos/extensions/quick_unlock_private/quick_unlock_private_api_unittest.cc index 9c83fc6..6a82acc 100644 --- a/chrome/browser/chromeos/extensions/quick_unlock_private/quick_unlock_private_api_unittest.cc +++ b/chrome/browser/chromeos/extensions/quick_unlock_private/quick_unlock_private_api_unittest.cc
@@ -120,7 +120,7 @@ // Generate an auth token. token_ = quick_unlock::QuickUnlockFactory::GetForProfile(profile()) - ->CreateAuthToken(); + ->CreateAuthToken(auth_token_user_context_); // Ensure that quick unlock is turned off. RunSetModes(QuickUnlockModeList{}, CredentialList{}); @@ -395,6 +395,7 @@ QuickUnlockPrivateSetModesFunction::ModesChangedEventHandler modes_changed_handler_; bool expect_modes_changed_ = false; + chromeos::UserContext auth_token_user_context_; std::string token_; DISALLOW_COPY_AND_ASSIGN(QuickUnlockPrivateUnitTest); @@ -409,7 +410,7 @@ quick_unlock::QuickUnlockFactory::GetForProfile(profile()); EXPECT_EQ(token_info->token, quick_unlock_storage->GetAuthToken()); EXPECT_EQ(token_info->lifetime_seconds, - quick_unlock::QuickUnlockStorage::kTokenExpirationSeconds); + quick_unlock::AuthToken::kTokenExpirationSeconds); } // Verifies that GetAuthTokenValid fails when an invalid password is provided.
diff --git a/chrome/browser/chromeos/extensions/wallpaper_private_api.cc b/chrome/browser/chromeos/extensions/wallpaper_private_api.cc index bf9ff03..785c03f 100644 --- a/chrome/browser/chromeos/extensions/wallpaper_private_api.cc +++ b/chrome/browser/chromeos/extensions/wallpaper_private_api.cc
@@ -245,15 +245,6 @@ const std::string& app_locale = g_browser_process->GetApplicationLocale(); webui::SetLoadTimeDataDefaults(app_locale, dict.get()); - // TODO(crbug.com/777293, 776464): Make it work under mash (most likely by - // creating a mojo callback). - dict->SetString("currentWallpaper", - ash::Shell::HasInstance() - ? ash::Shell::Get() - ->wallpaper_controller() - ->GetActiveUserWallpaperLocation() - : std::string()); - #if defined(GOOGLE_CHROME_BUILD) dict->SetString("manifestBaseURL", kWallpaperManifestBaseURL); #endif @@ -266,7 +257,18 @@ ? GetBackdropWallpaperSuffix() : kHighResolutionSuffix); - return RespondNow(OneArgument(std::move(dict))); + WallpaperControllerClient::Get()->GetActiveUserWallpaperLocation( + base::BindOnce( + &WallpaperPrivateGetStringsFunction::OnWallpaperLocationReturned, + this, std::move(dict))); + return RespondLater(); +} + +void WallpaperPrivateGetStringsFunction::OnWallpaperLocationReturned( + std::unique_ptr<base::DictionaryValue> dict, + const std::string& location) { + dict->SetString("currentWallpaper", location); + Respond(OneArgument(std::move(dict))); } ExtensionFunction::ResponseAction
diff --git a/chrome/browser/chromeos/extensions/wallpaper_private_api.h b/chrome/browser/chromeos/extensions/wallpaper_private_api.h index 980fd7c..c3f0f30a 100644 --- a/chrome/browser/chromeos/extensions/wallpaper_private_api.h +++ b/chrome/browser/chromeos/extensions/wallpaper_private_api.h
@@ -30,6 +30,11 @@ // ExtensionFunction: ResponseAction Run() override; + + private: + // Responds with the dictionary after getting the wallpaper location. + void OnWallpaperLocationReturned(std::unique_ptr<base::DictionaryValue> dict, + const std::string& location); }; // Check if sync themes setting is enabled.
diff --git a/chrome/browser/chromeos/login/easy_unlock/easy_unlock_tpm_key_manager_unittest.cc b/chrome/browser/chromeos/login/easy_unlock/easy_unlock_tpm_key_manager_unittest.cc index f13e8928..cf00e89 100644 --- a/chrome/browser/chromeos/login/easy_unlock/easy_unlock_tpm_key_manager_unittest.cc +++ b/chrome/browser/chromeos/login/easy_unlock/easy_unlock_tpm_key_manager_unittest.cc
@@ -196,7 +196,7 @@ class EasyUnlockTpmKeyManagerTest : public testing::Test { public: EasyUnlockTpmKeyManagerTest() - : thread_bundle_(content::TestBrowserThreadBundle::REAL_IO_THREAD), + : thread_bundle_(content::TestBrowserThreadBundle::IO_MAINLOOP), user_manager_(new FakeChromeUserManager()), user_manager_enabler_(base::WrapUnique(user_manager_)), profile_manager_(TestingBrowserProcess::GetGlobal()) {}
diff --git a/chrome/browser/chromeos/login/quick_unlock/auth_token.cc b/chrome/browser/chromeos/login/quick_unlock/auth_token.cc new file mode 100644 index 0000000..37834d8d --- /dev/null +++ b/chrome/browser/chromeos/login/quick_unlock/auth_token.cc
@@ -0,0 +1,44 @@ +// Copyright 2018 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 "chrome/browser/chromeos/login/quick_unlock/auth_token.h" + +#include "base/single_thread_task_runner.h" +#include "base/threading/thread_task_runner_handle.h" +#include "chromeos/login/auth/user_context.h" + +namespace chromeos { +namespace quick_unlock { + +const int AuthToken::kTokenExpirationSeconds = 5 * 60; + +AuthToken::AuthToken(const chromeos::UserContext& user_context) + : identifier_(base::UnguessableToken::Create()), + user_context_(std::make_unique<chromeos::UserContext>(user_context)), + weak_factory_(this) { + base::ThreadTaskRunnerHandle::Get()->PostDelayedTask( + FROM_HERE, base::BindOnce(&AuthToken::Reset, weak_factory_.GetWeakPtr()), + base::TimeDelta::FromSeconds(kTokenExpirationSeconds)); +} + +AuthToken::~AuthToken() = default; + +base::Optional<std::string> AuthToken::Identifier() { + if (!user_context_) + return base::nullopt; + return identifier_.ToString(); +} + +void AuthToken::ResetForTest() { + Reset(); +} + +void AuthToken::Reset() { + if (user_context_) + user_context_->ClearSecrets(); + user_context_.reset(); +} + +} // namespace quick_unlock +} // namespace chromeos
diff --git a/chrome/browser/chromeos/login/quick_unlock/auth_token.h b/chrome/browser/chromeos/login/quick_unlock/auth_token.h new file mode 100644 index 0000000..c029fda --- /dev/null +++ b/chrome/browser/chromeos/login/quick_unlock/auth_token.h
@@ -0,0 +1,53 @@ +// Copyright 2018 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 CHROME_BROWSER_CHROMEOS_LOGIN_QUICK_UNLOCK_AUTH_TOKEN_H_ +#define CHROME_BROWSER_CHROMEOS_LOGIN_QUICK_UNLOCK_AUTH_TOKEN_H_ + +#include <memory> + +#include "base/macros.h" +#include "base/memory/weak_ptr.h" +#include "base/optional.h" +#include "base/unguessable_token.h" + +namespace chromeos { +class UserContext; + +namespace quick_unlock { + +class AuthToken { + public: + // How long the token lives. + static const int kTokenExpirationSeconds; + + explicit AuthToken(const chromeos::UserContext& user_context); + ~AuthToken(); + + // An unguessable identifier that can be passed to webui to verify the token + // instance has not changed. Returns nullopt if the token is expired. + base::Optional<std::string> Identifier(); + + // The UserContext returned here can be null if its time-to-live has expired. + chromeos::UserContext* user_context() { return user_context_.get(); } + + // Time the token out - should be used only by tests. + void ResetForTest(); + + private: + // Times the token out. + void Reset(); + + base::UnguessableToken identifier_; + std::unique_ptr<chromeos::UserContext> user_context_; + + base::WeakPtrFactory<AuthToken> weak_factory_; + + DISALLOW_COPY_AND_ASSIGN(AuthToken); +}; + +} // namespace quick_unlock +} // namespace chromeos + +#endif // CHROME_BROWSER_CHROMEOS_LOGIN_QUICK_UNLOCK_AUTH_TOKEN_H_
diff --git a/chrome/browser/chromeos/login/quick_unlock/quick_unlock_storage.cc b/chrome/browser/chromeos/login/quick_unlock/quick_unlock_storage.cc index 401ec8b..15a9ef9a 100644 --- a/chrome/browser/chromeos/login/quick_unlock/quick_unlock_storage.cc +++ b/chrome/browser/chromeos/login/quick_unlock/quick_unlock_storage.cc
@@ -14,8 +14,6 @@ namespace chromeos { namespace quick_unlock { -const int QuickUnlockStorage::kTokenExpirationSeconds = 5 * 60; - QuickUnlockStorage::QuickUnlockStorage(PrefService* pref_service) : pref_service_(pref_service) { fingerprint_storage_ = std::make_unique<FingerprintStorage>(pref_service); @@ -63,24 +61,21 @@ return HasStrongAuth() && pin_storage()->TryAuthenticatePin(pin, key_type); } -std::string QuickUnlockStorage::CreateAuthToken() { - auth_token_ = base::UnguessableToken::Create(); - auth_token_issue_time_ = base::TimeTicks::Now(); - return auth_token_.ToString(); +std::string QuickUnlockStorage::CreateAuthToken( + const chromeos::UserContext& user_context) { + auth_token_ = std::make_unique<AuthToken>(user_context); + DCHECK(auth_token_->Identifier().has_value()); + return *auth_token_->Identifier(); } bool QuickUnlockStorage::GetAuthTokenExpired() { - return base::TimeTicks::Now() >= - auth_token_issue_time_ + - base::TimeDelta::FromSeconds(kTokenExpirationSeconds); + return !auth_token_ || !auth_token_->Identifier().has_value(); } std::string QuickUnlockStorage::GetAuthToken() { - if (GetAuthTokenExpired()) { - auth_token_ = base::UnguessableToken(); - return std::string(); - } - return auth_token_.is_empty() ? std::string() : auth_token_.ToString(); + if (GetAuthTokenExpired()) + return ""; + return *auth_token_->Identifier(); } void QuickUnlockStorage::Shutdown() {
diff --git a/chrome/browser/chromeos/login/quick_unlock/quick_unlock_storage.h b/chrome/browser/chromeos/login/quick_unlock/quick_unlock_storage.h index 1b097b8..6b16a02d4 100644 --- a/chrome/browser/chromeos/login/quick_unlock/quick_unlock_storage.h +++ b/chrome/browser/chromeos/login/quick_unlock/quick_unlock_storage.h
@@ -6,9 +6,10 @@ #define CHROME_BROWSER_CHROMEOS_LOGIN_QUICK_UNLOCK_QUICK_UNLOCK_STORAGE_H_ #include "base/memory/ptr_util.h" -#include "base/unguessable_token.h" +#include "chrome/browser/chromeos/login/quick_unlock/auth_token.h" #include "chrome/browser/chromeos/login/quick_unlock/fingerprint_storage.h" #include "chrome/browser/chromeos/login/quick_unlock/pin_storage.h" +#include "chromeos/login/auth/user_context.h" #include "components/keyed_service/core/keyed_service.h" class PrefService; @@ -57,7 +58,7 @@ // Creates a new authentication token to be used by the quickSettingsPrivate // API for authenticating requests. Resets the expiration timer and // invalidates any previously issued tokens. - std::string CreateAuthToken(); + std::string CreateAuthToken(const chromeos::UserContext& user_context); // Returns true if the current authentication token has expired. bool GetAuthTokenExpired(); @@ -71,8 +72,6 @@ } PinStorage* pin_storage() { return pin_storage_.get(); } - static const int kTokenExpirationSeconds; - private: friend class chromeos::QuickUnlockStorageTestApi; friend class chromeos::QuickUnlockStorageUnitTest; @@ -84,8 +83,7 @@ base::TimeTicks last_strong_auth_; std::unique_ptr<FingerprintStorage> fingerprint_storage_; std::unique_ptr<PinStorage> pin_storage_; - base::UnguessableToken auth_token_; - base::TimeTicks auth_token_issue_time_; + std::unique_ptr<AuthToken> auth_token_; DISALLOW_COPY_AND_ASSIGN(QuickUnlockStorage); };
diff --git a/chrome/browser/chromeos/login/quick_unlock/quick_unlock_storage_unittest.cc b/chrome/browser/chromeos/login/quick_unlock/quick_unlock_storage_unittest.cc index 39b98d8..6a31b32 100644 --- a/chrome/browser/chromeos/login/quick_unlock/quick_unlock_storage_unittest.cc +++ b/chrome/browser/chromeos/login/quick_unlock/quick_unlock_storage_unittest.cc
@@ -17,6 +17,7 @@ namespace chromeos { +using AuthToken = quick_unlock::AuthToken; using QuickUnlockStorage = quick_unlock::QuickUnlockStorage; namespace { @@ -48,10 +49,7 @@ void ExpireAuthToken() { quick_unlock::QuickUnlockFactory::GetForProfile(profile_.get()) - ->auth_token_issue_time_ = - base::TimeTicks::Now() - - base::TimeDelta::FromSeconds( - QuickUnlockStorage::kTokenExpirationSeconds); + ->auth_token_->ResetForTest(); } content::TestBrowserThreadBundle thread_bundle_; @@ -169,7 +167,8 @@ quick_unlock::QuickUnlockFactory::GetForProfile(profile_.get()); EXPECT_EQ(std::string(), quick_unlock_storage->GetAuthToken()); - std::string auth_token = quick_unlock_storage->CreateAuthToken(); + chromeos::UserContext context; + std::string auth_token = quick_unlock_storage->CreateAuthToken(context); EXPECT_NE(std::string(), auth_token); EXPECT_EQ(auth_token, quick_unlock_storage->GetAuthToken()); EXPECT_FALSE(quick_unlock_storage->GetAuthTokenExpired());
diff --git a/chrome/browser/custom_handlers/register_protocol_handler_permission_request.cc b/chrome/browser/custom_handlers/register_protocol_handler_permission_request.cc index dd21cf8..b79eb6c 100644 --- a/chrome/browser/custom_handlers/register_protocol_handler_permission_request.cc +++ b/chrome/browser/custom_handlers/register_protocol_handler_permission_request.cc
@@ -12,19 +12,6 @@ #include "components/vector_icons/vector_icons.h" #include "ui/base/l10n/l10n_util.h" -namespace { - -base::string16 GetProtocolName( - const ProtocolHandler& handler) { - if (handler.protocol() == "mailto") - return l10n_util::GetStringUTF16(IDS_REGISTER_PROTOCOL_HANDLER_MAILTO_NAME); - if (handler.protocol() == "webcal") - return l10n_util::GetStringUTF16(IDS_REGISTER_PROTOCOL_HANDLER_WEBCAL_NAME); - return base::UTF8ToUTF16(handler.protocol()); -} - -} // namespace - RegisterProtocolHandlerPermissionRequest ::RegisterProtocolHandlerPermissionRequest( ProtocolHandlerRegistry* registry, @@ -46,14 +33,14 @@ base::string16 RegisterProtocolHandlerPermissionRequest::GetMessageTextFragment() const { ProtocolHandler old_handler = registry_->GetHandlerFor(handler_.protocol()); - return old_handler.IsEmpty() ? - l10n_util::GetStringFUTF16( - IDS_REGISTER_PROTOCOL_HANDLER_CONFIRM_FRAGMENT, - GetProtocolName(handler_)) : - l10n_util::GetStringFUTF16( - IDS_REGISTER_PROTOCOL_HANDLER_CONFIRM_REPLACE_FRAGMENT, - GetProtocolName(handler_), - base::UTF8ToUTF16(old_handler.url().host_piece())); + return old_handler.IsEmpty() + ? l10n_util::GetStringFUTF16( + IDS_REGISTER_PROTOCOL_HANDLER_CONFIRM_FRAGMENT, + handler_.GetProtocolDisplayName()) + : l10n_util::GetStringFUTF16( + IDS_REGISTER_PROTOCOL_HANDLER_CONFIRM_REPLACE_FRAGMENT, + handler_.GetProtocolDisplayName(), + base::UTF8ToUTF16(old_handler.url().host_piece())); } GURL RegisterProtocolHandlerPermissionRequest::GetOrigin() const {
diff --git a/chrome/browser/devtools/devtools_ui_bindings.cc b/chrome/browser/devtools/devtools_ui_bindings.cc index 356657e..576edfd2 100644 --- a/chrome/browser/devtools/devtools_ui_bindings.cc +++ b/chrome/browser/devtools/devtools_ui_bindings.cc
@@ -91,7 +91,7 @@ static const char kFrontendHostId[] = "id"; static const char kFrontendHostMethod[] = "method"; static const char kFrontendHostParams[] = "params"; -static const char kTitleFormat[] = "Developer Tools - %s"; +static const char kTitleFormat[] = "DevTools - %s"; static const char kDevToolsActionTakenHistogram[] = "DevTools.ActionTaken"; static const char kDevToolsPanelShownHistogram[] = "DevTools.PanelShown"; @@ -573,8 +573,8 @@ it != instances->end(); ++it) { if ((*it)->web_contents() == web_contents) return *it; - } - return NULL; + } + return NULL; } DevToolsUIBindings::DevToolsUIBindings(content::WebContents* web_contents) @@ -728,9 +728,19 @@ void DevToolsUIBindings::InspectedURLChanged(const std::string& url) { content::NavigationController& controller = web_contents()->GetController(); content::NavigationEntry* entry = controller.GetActiveEntry(); + + const std::string kHttpPrefix = "http://"; + const std::string kHttpsPrefix = "https://"; + const std::string simplified_url = + base::StartsWith(url, kHttpsPrefix, base::CompareCase::SENSITIVE) + ? url.substr(kHttpsPrefix.length()) + : base::StartsWith(url, kHttpPrefix, base::CompareCase::SENSITIVE) + ? url.substr(kHttpPrefix.length()) + : url; // DevTools UI is not localized. web_contents()->UpdateTitleForEntry( - entry, base::UTF8ToUTF16(base::StringPrintf(kTitleFormat, url.c_str()))); + entry, base::UTF8ToUTF16( + base::StringPrintf(kTitleFormat, simplified_url.c_str()))); } void DevToolsUIBindings::LoadNetworkResource(const DispatchCallback& callback,
diff --git a/chrome/browser/extensions/api/developer_private/DEPS b/chrome/browser/extensions/api/developer_private/DEPS new file mode 100644 index 0000000..5ad83b6 --- /dev/null +++ b/chrome/browser/extensions/api/developer_private/DEPS
@@ -0,0 +1,6 @@ +specific_include_rules = { + "developer_private_api_unittest.cc": [ + # Allow the unittest to create a data_decoder service. + "+services/data_decoder" + ], +}
diff --git a/chrome/browser/extensions/api/developer_private/developer_private_api.cc b/chrome/browser/extensions/api/developer_private/developer_private_api.cc index a395be0d..c7f44caf 100644 --- a/chrome/browser/extensions/api/developer_private/developer_private_api.cc +++ b/chrome/browser/extensions/api/developer_private/developer_private_api.cc
@@ -24,6 +24,8 @@ #include "chrome/browser/extensions/api/developer_private/entry_picker.h" #include "chrome/browser/extensions/api/developer_private/extension_info_generator.h" #include "chrome/browser/extensions/api/developer_private/show_permissions_dialog_helper.h" +#include "chrome/browser/extensions/chrome_zipfile_installer.h" +#include "chrome/browser/extensions/crx_installer.h" #include "chrome/browser/extensions/devtools_util.h" #include "chrome/browser/extensions/extension_commands_global_registry.h" #include "chrome/browser/extensions/extension_service.h" @@ -58,6 +60,7 @@ #include "content/public/browser/storage_partition.h" #include "content/public/browser/web_contents.h" #include "content/public/common/drop_data.h" +#include "content/public/common/service_manager_connection.h" #include "extensions/browser/api/file_handlers/app_file_handler_util.h" #include "extensions/browser/app_window/app_window.h" #include "extensions/browser/app_window/app_window_registry.h" @@ -73,6 +76,7 @@ #include "extensions/browser/notification_types.h" #include "extensions/browser/path_util.h" #include "extensions/browser/warning_service.h" +#include "extensions/browser/zipfile_installer.h" #include "extensions/common/extension_set.h" #include "extensions/common/feature_switch.h" #include "extensions/common/install_warning.h" @@ -80,6 +84,7 @@ #include "extensions/common/manifest_handlers/options_page_info.h" #include "extensions/common/manifest_url_handlers.h" #include "extensions/common/permissions/permissions_data.h" +#include "net/base/filename_util.h" #include "storage/browser/blob/shareable_file_reference.h" #include "storage/browser/fileapi/external_mount_points.h" #include "storage/browser/fileapi/file_system_context.h" @@ -1089,6 +1094,52 @@ .ToValue())); } +DeveloperPrivateInstallDroppedFileFunction:: + DeveloperPrivateInstallDroppedFileFunction() = default; +DeveloperPrivateInstallDroppedFileFunction:: + ~DeveloperPrivateInstallDroppedFileFunction() = default; + +ExtensionFunction::ResponseAction +DeveloperPrivateInstallDroppedFileFunction::Run() { + content::WebContents* web_contents = GetSenderWebContents(); + if (!web_contents) + return RespondNow(Error(kCouldNotFindWebContentsError)); + + DeveloperPrivateAPI* api = DeveloperPrivateAPI::Get(browser_context()); + base::FilePath path = api->GetDraggedPath(web_contents); + if (path.empty()) + return RespondNow(Error("No dragged path")); + + ExtensionService* service = GetExtensionService(browser_context()); + if (path.MatchesExtension(FILE_PATH_LITERAL(".zip"))) { + ZipFileInstaller::Create( + content::ServiceManagerConnection::GetForProcess()->GetConnector(), + MakeRegisterInExtensionServiceCallback(service)) + ->LoadFromZipFile(path); + } else { + auto prompt = std::make_unique<ExtensionInstallPrompt>(web_contents); + scoped_refptr<CrxInstaller> crx_installer = + CrxInstaller::Create(service, std::move(prompt)); + crx_installer->set_error_on_unsupported_requirements(true); + crx_installer->set_off_store_install_allow_reason( + CrxInstaller::OffStoreInstallAllowedFromSettingsPage); + crx_installer->set_install_immediately(true); + + if (path.MatchesExtension(FILE_PATH_LITERAL(".user.js"))) { + crx_installer->InstallUserScript(path, net::FilePathToFileURL(path)); + } else if (path.MatchesExtension(FILE_PATH_LITERAL(".crx"))) { + crx_installer->InstallCrx(path); + } else { + EXTENSION_FUNCTION_VALIDATE(false); + } + } + + // TODO(devlin): We could optionally wait to return until we validate whether + // the load succeeded or failed. For now, that's unnecessary, and just adds + // complexity. + return RespondNow(NoArguments()); +} + DeveloperPrivateNotifyDragInstallInProgressFunction:: DeveloperPrivateNotifyDragInstallInProgressFunction() = default; DeveloperPrivateNotifyDragInstallInProgressFunction::
diff --git a/chrome/browser/extensions/api/developer_private/developer_private_api.h b/chrome/browser/extensions/api/developer_private/developer_private_api.h index 6a82e8f..11767ee 100644 --- a/chrome/browser/extensions/api/developer_private/developer_private_api.h +++ b/chrome/browser/extensions/api/developer_private/developer_private_api.h
@@ -512,6 +512,22 @@ DeveloperPrivateAPI::UnpackedRetryId retry_guid_; }; +class DeveloperPrivateInstallDroppedFileFunction + : public DeveloperPrivateAPIFunction { + public: + DECLARE_EXTENSION_FUNCTION("developerPrivate.installDroppedFile", + DEVELOPERPRIVATE_INSTALLDROPPEDFILE); + DeveloperPrivateInstallDroppedFileFunction(); + + private: + ~DeveloperPrivateInstallDroppedFileFunction() override; + + // ExtensionFunction: + ResponseAction Run() override; + + DISALLOW_COPY_AND_ASSIGN(DeveloperPrivateInstallDroppedFileFunction); +}; + class DeveloperPrivateNotifyDragInstallInProgressFunction : public DeveloperPrivateAPIFunction { public:
diff --git a/chrome/browser/extensions/api/developer_private/developer_private_api_unittest.cc b/chrome/browser/extensions/api/developer_private/developer_private_api_unittest.cc index 0cdd232..5fcb562c 100644 --- a/chrome/browser/extensions/api/developer_private/developer_private_api_unittest.cc +++ b/chrome/browser/extensions/api/developer_private/developer_private_api_unittest.cc
@@ -35,17 +35,20 @@ #include "components/policy/core/common/policy_service_impl.h" #include "components/policy/core/common/policy_types.h" #include "components/policy/policy_constants.h" +#include "components/services/unzip/unzip_service.h" #include "components/sync_preferences/testing_pref_service_syncable.h" #include "content/public/browser/notification_service.h" #include "content/public/test/web_contents_tester.h" #include "extensions/browser/api_test_utils.h" #include "extensions/browser/event_router_factory.h" +#include "extensions/browser/extension_dialog_auto_confirm.h" #include "extensions/browser/extension_error_test_util.h" #include "extensions/browser/extension_prefs.h" #include "extensions/browser/extension_registry.h" #include "extensions/browser/extension_registry_observer.h" #include "extensions/browser/extension_system.h" #include "extensions/browser/extension_util.h" +#include "extensions/browser/install/extension_install_ui.h" #include "extensions/browser/mock_external_provider.h" #include "extensions/browser/test_extension_registry_observer.h" #include "extensions/common/extension.h" @@ -55,6 +58,9 @@ #include "extensions/common/manifest_constants.h" #include "extensions/common/value_builder.h" #include "extensions/test/test_extension_dir.h" +#include "services/data_decoder/data_decoder_service.h" +#include "services/service_manager/public/cpp/connector.h" +#include "services/service_manager/public/cpp/test/test_connector_factory.h" using testing::Return; using testing::_; @@ -1220,6 +1226,120 @@ EXPECT_THAT(error, testing::HasSubstr("policy")); } +TEST_F(DeveloperPrivateApiUnitTest, InstallDroppedFileNoDraggedPath) { + extensions::ExtensionInstallUI::set_disable_ui_for_tests(); + ScopedTestDialogAutoConfirm auto_confirm(ScopedTestDialogAutoConfirm::ACCEPT); + + std::unique_ptr<content::WebContents> web_contents( + content::WebContentsTester::CreateTestWebContents(profile(), nullptr)); + + scoped_refptr<UIThreadExtensionFunction> function = + base::MakeRefCounted<api::DeveloperPrivateInstallDroppedFileFunction>(); + function->SetRenderFrameHost(web_contents->GetMainFrame()); + + TestExtensionRegistryObserver observer(registry()); + EXPECT_EQ("No dragged path", api_test_utils::RunFunctionAndReturnError( + function.get(), "[]", profile())); +} + +TEST_F(DeveloperPrivateApiUnitTest, InstallDroppedFileCrx) { + TestExtensionDir test_dir; + test_dir.WriteManifest( + R"({ + "name": "foo", + "version": "1.0", + "manifest_version": 2 + })"); + base::FilePath crx_path = test_dir.Pack(); + extensions::ExtensionInstallUI::set_disable_ui_for_tests(); + ScopedTestDialogAutoConfirm auto_confirm(ScopedTestDialogAutoConfirm::ACCEPT); + + std::unique_ptr<content::WebContents> web_contents( + content::WebContentsTester::CreateTestWebContents(profile(), nullptr)); + DeveloperPrivateAPI::Get(profile())->SetDraggedPath(web_contents.get(), + crx_path); + + scoped_refptr<UIThreadExtensionFunction> function = + base::MakeRefCounted<api::DeveloperPrivateInstallDroppedFileFunction>(); + function->SetRenderFrameHost(web_contents->GetMainFrame()); + + TestExtensionRegistryObserver observer(registry()); + ASSERT_TRUE(api_test_utils::RunFunction(function.get(), "[]", profile())) + << function->GetError(); + const Extension* extension = observer.WaitForExtensionInstalled(); + ASSERT_TRUE(extension); + EXPECT_EQ("foo", extension->name()); +} + +TEST_F(DeveloperPrivateApiUnitTest, InstallDroppedFileUserScript) { + base::FilePath script_path = + data_dir().AppendASCII("user_script_basic.user.js"); + extensions::ExtensionInstallUI::set_disable_ui_for_tests(); + ScopedTestDialogAutoConfirm auto_confirm(ScopedTestDialogAutoConfirm::ACCEPT); + + std::unique_ptr<content::WebContents> web_contents( + content::WebContentsTester::CreateTestWebContents(profile(), nullptr)); + DeveloperPrivateAPI::Get(profile())->SetDraggedPath(web_contents.get(), + script_path); + + scoped_refptr<UIThreadExtensionFunction> function = + base::MakeRefCounted<api::DeveloperPrivateInstallDroppedFileFunction>(); + function->SetRenderFrameHost(web_contents->GetMainFrame()); + + TestExtensionRegistryObserver observer(registry()); + ASSERT_TRUE(api_test_utils::RunFunction(function.get(), "[]", profile())) + << function->GetError(); + const Extension* extension = observer.WaitForExtensionInstalled(); + ASSERT_TRUE(extension); + EXPECT_EQ("My user script", extension->name()); +} + +class DeveloperPrivateZipInstallerUnitTest + : public DeveloperPrivateApiUnitTest { + public: + DeveloperPrivateZipInstallerUnitTest() { + service_manager::TestConnectorFactory::NameToServiceMap services; + services.insert(std::make_pair("data_decoder", + data_decoder::DataDecoderService::Create())); + services.insert( + std::make_pair("unzip_service", unzip::UnzipService::CreateService())); + test_connector_factory_ = + service_manager::TestConnectorFactory::CreateForServices( + std::move(services)); + connector_ = test_connector_factory_->CreateConnector(); + } + ~DeveloperPrivateZipInstallerUnitTest() override {} + + private: + std::unique_ptr<service_manager::TestConnectorFactory> + test_connector_factory_; + std::unique_ptr<service_manager::Connector> connector_; + + DISALLOW_COPY_AND_ASSIGN(DeveloperPrivateZipInstallerUnitTest); +}; + +TEST_F(DeveloperPrivateZipInstallerUnitTest, InstallDroppedFileZip) { + base::FilePath zip_path = data_dir().AppendASCII("simple_empty.zip"); + extensions::ExtensionInstallUI::set_disable_ui_for_tests(); + ScopedTestDialogAutoConfirm auto_confirm(ScopedTestDialogAutoConfirm::ACCEPT); + + std::unique_ptr<content::WebContents> web_contents( + content::WebContentsTester::CreateTestWebContents(profile(), nullptr)); + DeveloperPrivateAPI::Get(profile())->SetDraggedPath(web_contents.get(), + zip_path); + + scoped_refptr<UIThreadExtensionFunction> function = + base::MakeRefCounted<api::DeveloperPrivateInstallDroppedFileFunction>(); + function->SetRenderFrameHost(web_contents->GetMainFrame()); + + TestExtensionRegistryObserver observer(registry()); + ASSERT_TRUE(api_test_utils::RunFunction(function.get(), "[]", profile())) + << function->GetError(); + const Extension* extension = observer.WaitForExtensionInstalled(); + ASSERT_TRUE(extension); + EXPECT_EQ("Simple Empty Extension", extension->name()); +} + class DeveloperPrivateApiSupervisedUserUnitTest : public DeveloperPrivateApiUnitTest { public:
diff --git a/chrome/browser/extensions/api/tabs/tabs_test.cc b/chrome/browser/extensions/api/tabs/tabs_test.cc index 82fa8cf..abb1c3a 100644 --- a/chrome/browser/extensions/api/tabs/tabs_test.cc +++ b/chrome/browser/extensions/api/tabs/tabs_test.cc
@@ -77,7 +77,10 @@ class ExtensionTabsTest : public PlatformAppBrowserTest { public: - ExtensionTabsTest() : scoped_set_tick_clock_for_testing_(&test_clock_) {} + ExtensionTabsTest() : scoped_set_tick_clock_for_testing_(&test_clock_) { + // Start with a non-null time. + test_clock_.Advance(base::TimeDelta::FromSeconds(1)); + } // Fast-forward time until no tab is protected from being discarded for having // recently been used.
diff --git a/chrome/browser/extensions/api/webstore_private/webstore_private_apitest.cc b/chrome/browser/extensions/api/webstore_private/webstore_private_apitest.cc index 620a8b9..f33655ac 100644 --- a/chrome/browser/extensions/api/webstore_private/webstore_private_apitest.cc +++ b/chrome/browser/extensions/api/webstore_private/webstore_private_apitest.cc
@@ -123,7 +123,7 @@ // API functions. host_resolver()->AddRule("www.example.com", "127.0.0.1"); ASSERT_TRUE(StartEmbeddedTestServer()); - extensions::ExtensionInstallUI::set_disable_failure_ui_for_tests(); + extensions::ExtensionInstallUI::set_disable_ui_for_tests(); auto_confirm_install_.reset( new ScopedTestDialogAutoConfirm(ScopedTestDialogAutoConfirm::ACCEPT));
diff --git a/chrome/browser/extensions/chrome_zipfile_installer.cc b/chrome/browser/extensions/chrome_zipfile_installer.cc index 56578742..d8cc5659 100644 --- a/chrome/browser/extensions/chrome_zipfile_installer.cc +++ b/chrome/browser/extensions/chrome_zipfile_installer.cc
@@ -38,4 +38,4 @@ service->AsWeakPtr()); } -} // namespace extensions \ No newline at end of file +} // namespace extensions
diff --git a/chrome/browser/extensions/webstore_startup_installer_browsertest.cc b/chrome/browser/extensions/webstore_startup_installer_browsertest.cc index 263f77e..2c902f6 100644 --- a/chrome/browser/extensions/webstore_startup_installer_browsertest.cc +++ b/chrome/browser/extensions/webstore_startup_installer_browsertest.cc
@@ -215,7 +215,7 @@ void SetUpInProcessBrowserTestFixture() override { WebstoreStartupInstallerTest::SetUpInProcessBrowserTestFixture(); - extensions::ExtensionInstallUI::set_disable_failure_ui_for_tests(); + extensions::ExtensionInstallUI::set_disable_ui_for_tests(); } };
diff --git a/chrome/browser/flag_descriptions.cc b/chrome/browser/flag_descriptions.cc index 5f6578f..20dab80 100644 --- a/chrome/browser/flag_descriptions.cc +++ b/chrome/browser/flag_descriptions.cc
@@ -2622,10 +2622,6 @@ "Disable tablet mode autohide titlebars functionality. The user will be " "able to see the titlebar in tablet mode."; -const char kDisableTabletSplitViewName[] = "Disable split view in Tablet mode"; -const char kDisableTabletSplitViewDescription[] = - "Disable split view for Chrome OS tablet mode."; - const char kEnablePerUserTimezoneName[] = "Per-user time zone preferences."; const char kEnablePerUserTimezoneDescription[] = "Chrome OS system timezone preference is stored and handled for each user " @@ -2681,6 +2677,10 @@ "If enabled, the handwriting virtual keyboard will allow user to write " "anywhere on the screen"; +const char kEnableTabletSplitViewName[] = "Split view in Tablet mode"; +const char kEnableTabletSplitViewDescription[] = + "Enable split view for Chrome OS tablet mode."; + const char kEnableUnifiedMultiDeviceSettingsName[] = "Enable unified MultiDevice settings"; const char kEnableUnifiedMultiDeviceSettingsDescription[] =
diff --git a/chrome/browser/flag_descriptions.h b/chrome/browser/flag_descriptions.h index 3d6f2bc..c5b65ea 100644 --- a/chrome/browser/flag_descriptions.h +++ b/chrome/browser/flag_descriptions.h
@@ -1615,9 +1615,6 @@ extern const char kDisableTabletAutohideTitlebarsName[]; extern const char kDisableTabletAutohideTitlebarsDescription[]; -extern const char kDisableTabletSplitViewName[]; -extern const char kDisableTabletSplitViewDescription[]; - extern const char kEnablePerUserTimezoneName[]; extern const char kEnablePerUserTimezoneDescription[]; @@ -1651,6 +1648,9 @@ extern const char kEnableFullscreenHandwritingVirtualKeyboardName[]; extern const char kEnableFullscreenHandwritingVirtualKeyboardDescription[]; +extern const char kEnableTabletSplitViewName[]; +extern const char kEnableTabletSplitViewDescription[]; + extern const char kEnableUnifiedMultiDeviceSettingsName[]; extern const char kEnableUnifiedMultiDeviceSettingsDescription[];
diff --git a/chrome/browser/guest_view/web_view/chrome_web_view_guest_delegate.cc b/chrome/browser/guest_view/web_view/chrome_web_view_guest_delegate.cc index b666311..fdaadf6 100644 --- a/chrome/browser/guest_view/web_view/chrome_web_view_guest_delegate.cc +++ b/chrome/browser/guest_view/web_view/chrome_web_view_guest_delegate.cc
@@ -40,6 +40,7 @@ bool ChromeWebViewGuestDelegate::HandleContextMenu( const content::ContextMenuParams& params) { if ((params.source_type == ui::MENU_SOURCE_LONG_PRESS || + params.source_type == ui::MENU_SOURCE_LONG_TAP || params.source_type == ui::MENU_SOURCE_TOUCH) && !params.selection_text.empty() && (guest_web_contents()->GetRenderWidgetHostView() &&
diff --git a/chrome/browser/media/webrtc/OWNERS b/chrome/browser/media/webrtc/OWNERS index dfc87da..587d8770 100644 --- a/chrome/browser/media/webrtc/OWNERS +++ b/chrome/browser/media/webrtc/OWNERS
@@ -15,6 +15,9 @@ # For WebRTC desktop capturer related changes only per-file native_desktop_media_list*=zijiehe@chromium.org +# For WebRTC event logging code. +per-file webrtc_event_log_*=eladalon@chromium.org + per-file *permission_context*=file://chrome/browser/permissions/PERMISSIONS_OWNERS # COMPONENT: Blink>WebRTC
diff --git a/chrome/browser/offline_pages/android/offline_page_bridge.cc b/chrome/browser/offline_pages/android/offline_page_bridge.cc index 4ac9c8c..d95e63eb 100644 --- a/chrome/browser/offline_pages/android/offline_page_bridge.cc +++ b/chrome/browser/offline_pages/android/offline_page_bridge.cc
@@ -294,22 +294,18 @@ void PublishPageDone( const ScopedJavaGlobalRef<jobject>& j_published_callback_obj, - const OfflinePageItem& offline_page) { + const base::FilePath& file_path, + bool success) { // Create a java side OfflinePageItem for this offline_page. JNIEnv* env = base::android::AttachCurrentThread(); - ScopedJavaLocalRef<jobject> j_page = - Java_OfflinePageBridge_createOfflinePageItem( - env, ConvertUTF8ToJavaString(env, offline_page.url.spec()), - offline_page.offline_id, - ConvertUTF8ToJavaString(env, offline_page.client_id.name_space), - ConvertUTF8ToJavaString(env, offline_page.client_id.id), - ConvertUTF16ToJavaString(env, offline_page.title), - ConvertUTF8ToJavaString(env, offline_page.file_path.value()), - offline_page.file_size, offline_page.creation_time.ToJavaTime(), - offline_page.access_count, offline_page.last_access_time.ToJavaTime(), - ConvertUTF8ToJavaString(env, offline_page.request_origin)); - base::android::RunCallbackAndroid(j_published_callback_obj, j_page); + base::FilePath file_path_or_empty; + if (success) + file_path_or_empty = file_path; + + base::android::RunCallbackAndroid( + j_published_callback_obj, + ConvertUTF8ToJavaString(env, file_path.value())); } } // namespace
diff --git a/chrome/browser/offline_pages/offline_page_mhtml_archiver_unittest.cc b/chrome/browser/offline_pages/offline_page_mhtml_archiver_unittest.cc index 7943f554..4c7f0fd 100644 --- a/chrome/browser/offline_pages/offline_page_mhtml_archiver_unittest.cc +++ b/chrome/browser/offline_pages/offline_page_mhtml_archiver_unittest.cc
@@ -29,12 +29,12 @@ const char kTestURL[] = "http://example.com/hello.mhtml"; const char kNonExistentURL[] = "http://example.com/non_existent.mhtml"; // Size of chrome/test/data/offline_pages/hello.mhtml -const int64_t kTestFileSize = 450LL; +const int64_t kTestFileSize = 471LL; const base::string16 kTestTitle = base::UTF8ToUTF16("a title"); // SHA256 Hash of chrome/test/data/offline_pages/hello.mhtml const std::string kTestDigest( - "\x90\x64\xF9\x7C\x94\xE5\x9E\x91\x83\x3D\x41\xB0\x36\x90\x0A\xDF\xB3\xB1" - "\x5C\x13\xBE\xB8\x35\x8C\xF6\x5B\xC4\xB5\x5A\xFC\x3A\xCC", + "\x43\x60\x62\x02\x06\x15\x0f\x3e\x77\x99\x3d\xed\xdc\xd4\xe2\x0d\xbe\xbd" + "\x77\x1a\xfb\x32\x00\x51\x7e\x63\x7d\x3b\x2e\x46\x63\xf6", 32); class TestMHTMLArchiver : public OfflinePageMHTMLArchiver {
diff --git a/chrome/browser/offline_pages/offline_page_request_job_unittest.cc b/chrome/browser/offline_pages/offline_page_request_job_unittest.cc index aa54c67c..1079a2ef 100644 --- a/chrome/browser/offline_pages/offline_page_request_job_unittest.cc +++ b/chrome/browser/offline_pages/offline_page_request_job_unittest.cc
@@ -67,12 +67,12 @@ const base::FilePath kFilename2(FILE_PATH_LITERAL("test.mhtml")); const base::FilePath kNonexistentFilename( FILE_PATH_LITERAL("nonexistent.mhtml")); -const int kFileSize1 = 450; // Real size of hello.mhtml. +const int kFileSize1 = 471; // Real size of hello.mhtml. const int kFileSize2 = 444; // Real size of test.mhtml. const int kMismatchedFileSize = 99999; const std::string kDigest1( - "\x90\x64\xF9\x7C\x94\xE5\x9E\x91\x83\x3D\x41\xB0\x36\x90\x0A\xDF\xB3\xB1" - "\x5C\x13\xBE\xB8\x35\x8C\xF6\x5B\xC4\xB5\x5A\xFC\x3A\xCC", + "\x43\x60\x62\x02\x06\x15\x0f\x3e\x77\x99\x3d\xed\xdc\xd4\xe2\x0d\xbe\xbd" + "\x77\x1a\xfb\x32\x00\x51\x7e\x63\x7d\x3b\x2e\x46\x63\xf6", 32); // SHA256 Hash of hello.mhtml. const std::string kDigest2( "\xBD\xD3\x37\x79\xDA\x7F\x4E\x6A\x16\x66\xED\x49\x67\x18\x54\x48\xC6\x8E"
diff --git a/chrome/browser/offline_pages/offline_page_tab_helper.cc b/chrome/browser/offline_pages/offline_page_tab_helper.cc index 932596a7..8f43d2c 100644 --- a/chrome/browser/offline_pages/offline_page_tab_helper.cc +++ b/chrome/browser/offline_pages/offline_page_tab_helper.cc
@@ -29,6 +29,7 @@ #include "content/public/browser/navigation_handle.h" #include "content/public/browser/render_frame_host.h" #include "content/public/browser/web_contents.h" +#include "mojo/public/cpp/bindings/strong_binding.h" #include "ui/base/page_transition_types.h" DEFINE_WEB_CONTENTS_USER_DATA_KEY(offline_pages::OfflinePageTabHelper); @@ -49,7 +50,24 @@ : trusted_state(OfflinePageTrustedState::UNTRUSTED), is_showing_offline_preview(false) {} -OfflinePageTabHelper::LoadedOfflinePageInfo::~LoadedOfflinePageInfo() {} +OfflinePageTabHelper::LoadedOfflinePageInfo::LoadedOfflinePageInfo( + OfflinePageTabHelper::LoadedOfflinePageInfo&& other) = default; + +OfflinePageTabHelper::LoadedOfflinePageInfo::~LoadedOfflinePageInfo() = default; + +OfflinePageTabHelper::LoadedOfflinePageInfo& +OfflinePageTabHelper::LoadedOfflinePageInfo::operator=( + OfflinePageTabHelper::LoadedOfflinePageInfo&& other) = default; + +// static +OfflinePageTabHelper::LoadedOfflinePageInfo +OfflinePageTabHelper::LoadedOfflinePageInfo::MakeUntrusted() { + LoadedOfflinePageInfo untrusted_info; + untrusted_info.offline_page = std::make_unique<OfflinePageItem>(); + untrusted_info.offline_page->offline_id = store_utils::GenerateOfflineId(); + + return untrusted_info; +} void OfflinePageTabHelper::LoadedOfflinePageInfo::Clear() { offline_page.reset(); @@ -58,8 +76,13 @@ is_showing_offline_preview = false; } +bool OfflinePageTabHelper::LoadedOfflinePageInfo::IsValid() const { + return offline_page != nullptr; +} + OfflinePageTabHelper::OfflinePageTabHelper(content::WebContents* web_contents) : content::WebContentsObserver(web_contents), + mhtml_page_notifier_bindings_(web_contents, this), weak_ptr_factory_(this) { DCHECK(content::BrowserThread::CurrentlyOn(content::BrowserThread::UI)); prefetch_service_ = PrefetchServiceFactory::GetForBrowserContext( @@ -68,6 +91,33 @@ OfflinePageTabHelper::~OfflinePageTabHelper() {} +void OfflinePageTabHelper::NotifyIsMhtmlPage(const GURL& main_frame_url, + base::Time creation_time) { + if (mhtml_page_notifier_bindings_.GetCurrentTargetFrame() != + web_contents()->GetMainFrame()) { + return; + } + + // Sanity checking the input URL. + if (!main_frame_url.is_valid() || !main_frame_url.SchemeIsHTTPOrHTTPS()) + return; + + // The renderer's info should only be used if the offline page is not trusted, + // so ignore this information if we have a trusted page already. + if (provisional_offline_info_.IsValid() && + provisional_offline_info_.trusted_state != + OfflinePageTrustedState::UNTRUSTED) { + return; + } + + if (!provisional_offline_info_.IsValid()) + provisional_offline_info_ = LoadedOfflinePageInfo::MakeUntrusted(); + provisional_offline_info_.offline_page->url = main_frame_url; + + if (!creation_time.is_null()) + provisional_offline_info_.offline_page->creation_time = creation_time; +} + void OfflinePageTabHelper::DidStartNavigation( content::NavigationHandle* navigation_handle) { // Skips non-main frame. @@ -125,61 +175,31 @@ GURL navigated_url = navigation_handle->GetURL(); - // If a MHTML archive is being loaded for file: or content: URL, create an - // untrusted offline page. content::WebContents* web_contents = navigation_handle->GetWebContents(); - if (SchemeIsForUntrustedOfflinePages(navigated_url) && - web_contents->GetContentsMimeType() == "multipart/related") { - offline_info_.offline_page = std::make_unique<OfflinePageItem>(); - offline_info_.offline_page->offline_id = store_utils::GenerateOfflineId(); - offline_info_.trusted_state = OfflinePageTrustedState::UNTRUSTED; - // TODO(jianli): Extract the url where the MHTML acrhive claims from the - // MHTML headers and set it in OfflinePageItem::original_url. + if (web_contents->GetContentsMimeType() != "multipart/related") + return; - // If the file: or content: URL is launched due to opening an item from - // Downloads home, a custom offline header containing the offline ID should - // be present. If so, find and use the corresponding offline page. - content::NavigationEntry* entry = - web_contents->GetController().GetLastCommittedEntry(); - DCHECK(entry); - std::string header_value = - OfflinePageUtils::ExtractOfflineHeaderValueFromNavigationEntry(*entry); - if (!header_value.empty()) { - OfflinePageHeader header(header_value); - if (header.reason == OfflinePageHeader::Reason::DOWNLOAD && - !header.id.empty()) { - int64_t offline_id; - if (base::StringToInt64(header.id, &offline_id)) { - offline_info_.offline_page->offline_id = offline_id; - OfflinePageModel* model = - OfflinePageModelFactory::GetForBrowserContext( - web_contents->GetBrowserContext()); - DCHECK(model); - model->GetPageByOfflineId( - offline_id, - base::Bind(&OfflinePageTabHelper::GetPageByOfflineIdDone, - weak_ptr_factory_.GetWeakPtr())); - } - } + if (SchemeIsForUntrustedOfflinePages(navigated_url)) { + // If a MHTML archive is being loaded for file: or content: URL, and we did + // get a message from the renderer describing the contents, the results of + // that message will be stored in |provisional_offline_info_|. + if (provisional_offline_info_.IsValid()) { + offline_info_ = std::move(provisional_offline_info_); + provisional_offline_info_.Clear(); + } else { + // Otherwise, just use an empty untrusted page. + offline_info_ = LoadedOfflinePageInfo::MakeUntrusted(); + offline_info_.offline_page->url = navigated_url; } - - return; + } else if (navigated_url.SchemeIsHTTPOrHTTPS()) { + // For http/https URL, commit the provisional offline info if any. + if (provisional_offline_info_.IsValid()) { + DCHECK(OfflinePageUtils::EqualsIgnoringFragment( + navigated_url, provisional_offline_info_.offline_page->url)); + offline_info_ = std::move(provisional_offline_info_); + provisional_offline_info_.Clear(); + } } - - // For http/https URL,commit the provisional offline info if any. - if (!navigated_url.SchemeIsHTTPOrHTTPS() || - !provisional_offline_info_.offline_page) { - return; - } - - DCHECK(OfflinePageUtils::EqualsIgnoringFragment( - navigated_url, provisional_offline_info_.offline_page->url)); - offline_info_.offline_page = - std::move(provisional_offline_info_.offline_page); - offline_info_.offline_header = provisional_offline_info_.offline_header; - offline_info_.trusted_state = provisional_offline_info_.trusted_state; - offline_info_.is_showing_offline_preview = - provisional_offline_info_.is_showing_offline_preview; } void OfflinePageTabHelper::ReportOfflinePageMetrics() { @@ -290,23 +310,6 @@ web_contents()->GetController().LoadURLWithParams(load_params); } -void OfflinePageTabHelper::GetPageByOfflineIdDone( - const OfflinePageItem* offline_page) { - if (!offline_page) - return; - - // Update the temporary offline page which only contains the offline ID with - // the one retrieved from the metadata database. Do this only when the stored - // offline info is not changed since last time the asynchronous query is - // issued. - if (offline_info_.offline_page && - offline_info_.trusted_state == OfflinePageTrustedState::UNTRUSTED && - offline_info_.offline_page->offline_id == offline_page->offline_id) { - offline_info_.offline_page = - std::make_unique<OfflinePageItem>(*offline_page); - } -} - // This is a callback from network request interceptor. It happens between // DidStartNavigation and DidFinishNavigation calls on this tab helper. void OfflinePageTabHelper::SetOfflinePage( @@ -339,6 +342,12 @@ return provisional_offline_info_.trusted_state; } +void OfflinePageTabHelper::SetCurrentTargetFrameForTest( + content::RenderFrameHost* render_frame_host) { + mhtml_page_notifier_bindings_.SetCurrentTargetFrameForTesting( + render_frame_host); +} + const OfflinePageItem* OfflinePageTabHelper::GetOfflinePreviewItem() const { if (provisional_offline_info_.is_showing_offline_preview) return provisional_offline_info_.offline_page.get();
diff --git a/chrome/browser/offline_pages/offline_page_tab_helper.h b/chrome/browser/offline_pages/offline_page_tab_helper.h index f413be4..d328de5 100644 --- a/chrome/browser/offline_pages/offline_page_tab_helper.h +++ b/chrome/browser/offline_pages/offline_page_tab_helper.h
@@ -9,9 +9,12 @@ #include "base/memory/weak_ptr.h" #include "base/time/time.h" #include "chrome/browser/offline_pages/offline_page_utils.h" +#include "chrome/common/mhtml_page_notifier.mojom.h" #include "components/offline_pages/core/request_header/offline_page_header.h" +#include "content/public/browser/web_contents_binding_set.h" #include "content/public/browser/web_contents_observer.h" #include "content/public/browser/web_contents_user_data.h" +#include "services/service_manager/public/cpp/binder_registry.h" #include "url/gurl.h" namespace content { @@ -43,12 +46,20 @@ // Per-tab class that monitors the navigations and stores the necessary info // to facilitate the synchronous access to offline information. -class OfflinePageTabHelper : - public content::WebContentsObserver, - public content::WebContentsUserData<OfflinePageTabHelper> { +class OfflinePageTabHelper + : public content::WebContentsObserver, + public content::WebContentsUserData<OfflinePageTabHelper>, + public mojom::MhtmlPageNotifier { public: ~OfflinePageTabHelper() override; + // Creates the Mojo service that can listen to the renderer's archive events. + void CreateMhtmlPageNotifier(mojom::MhtmlPageNotifierRequest request); + + // MhtmlPageNotifier overrides. + void NotifyIsMhtmlPage(const GURL& main_frame_url, + base::Time date_header_time) override; + void SetOfflinePage(const OfflinePageItem& offline_page, const OfflinePageHeader& offline_header, OfflinePageTrustedState trusted_state, @@ -82,6 +93,11 @@ // Returns trusted state of provisional offline page. OfflinePageTrustedState GetTrustedStateForTest() const; + // Sets the target frame, useful for unit testing the MhtmlPageNotifier + // interface. + void SetCurrentTargetFrameForTest( + content::RenderFrameHost* render_frame_host); + // Helper function which normally should only be called by // OfflinePageUtils::ScheduleDownload to do the work. This is because we need // to ensure |web_contents| is still valid after returning from the @@ -103,7 +119,16 @@ LoadedOfflinePageInfo(); ~LoadedOfflinePageInfo(); - // The cached copy of OfflinePageItem. + // Constructs a valid but untrusted LoadedOfflinePageInfo with |url| as the + // online URL. + static LoadedOfflinePageInfo MakeUntrusted(); + + LoadedOfflinePageInfo& operator=(LoadedOfflinePageInfo&& other); + LoadedOfflinePageInfo(LoadedOfflinePageInfo&& other); + + // The cached copy of OfflinePageItem. Note that if |is_trusted| is false, + // offline_page may contain information derived from the MHTML itself and + // should be exposed to the user as untrusted. std::unique_ptr<OfflinePageItem> offline_page; // The offline header that is provided when offline page is loaded. @@ -114,7 +139,12 @@ // Whether the page is an offline preview. Offline page previews are shown // when a user's effective connection type is prohibitively slow. - bool is_showing_offline_preview; + bool is_showing_offline_preview = false; + + // Returns true if this contains an offline page. When constructed, + // LoadedOfflinePageInfo objects are invalid until filled with an offline + // page. + bool IsValid() const; void Clear(); }; @@ -139,9 +169,10 @@ void TryLoadingOfflinePageOnNetError( content::NavigationHandle* navigation_handle); - void SelectPagesForURLDone(const std::vector<OfflinePageItem>& offline_pages); + // Creates an offline info with an invalid offline ID and the given URL. + LoadedOfflinePageInfo MakeUntrustedOfflineInfo(const GURL& url); - void GetPageByOfflineIdDone(const OfflinePageItem* offline_page); + void SelectPagesForURLDone(const std::vector<OfflinePageItem>& offline_pages); void DuplicateCheckDoneForScheduleDownload( content::WebContents* web_contents, @@ -177,6 +208,11 @@ // replace this instance with access to a shared one. ClientPolicyController policy_controller_; + // TODO(crbug.com/827215): We only really want interface messages for the main + // frame but this is not easily done with the current helper classes. + content::WebContentsFrameBindingSet<mojom::MhtmlPageNotifier> + mhtml_page_notifier_bindings_; + base::WeakPtrFactory<OfflinePageTabHelper> weak_ptr_factory_; DISALLOW_COPY_AND_ASSIGN(OfflinePageTabHelper);
diff --git a/chrome/browser/offline_pages/offline_page_tab_helper_unittest.cc b/chrome/browser/offline_pages/offline_page_tab_helper_unittest.cc index 1200b4c..ca67f79 100644 --- a/chrome/browser/offline_pages/offline_page_tab_helper_unittest.cc +++ b/chrome/browser/offline_pages/offline_page_tab_helper_unittest.cc
@@ -173,6 +173,7 @@ tab_helper()->SetOfflinePage( offlinePage, offlineHeader, OfflinePageTrustedState::TRUSTED_AS_IN_INTERNAL_DIR, false); + navigation_simulator()->SetContentsMimeType("multipart/related"); navigation_simulator()->Commit(); @@ -192,7 +193,7 @@ tab_helper()->SetOfflinePage( offlinePage, offlineHeader, OfflinePageTrustedState::TRUSTED_AS_IN_INTERNAL_DIR, false); - + navigation_simulator()->SetContentsMimeType("multipart/related"); navigation_simulator()->Commit(); ASSERT_NE(nullptr, tab_helper()->offline_page()); @@ -213,7 +214,7 @@ tab_helper()->SetOfflinePage( offlinePage, offlineHeader, OfflinePageTrustedState::TRUSTED_AS_UNMODIFIED_AND_IN_PUBLIC_DIR, false); - + navigation_simulator()->SetContentsMimeType("multipart/related"); navigation_simulator()->Commit(); ASSERT_NE(nullptr, tab_helper()->offline_page()); @@ -253,4 +254,47 @@ } #endif +TEST_F(OfflinePageTabHelperTest, TestNotifyIsMhtmlPage) { + GURL mhtml_url("https://www.example.com"); + base::Time mhtml_creation_time = base::Time::FromJsTime(1522339419011L); + tab_helper()->SetCurrentTargetFrameForTest(web_contents()->GetMainFrame()); + + CreateNavigationSimulator(kTestFileUrl); + navigation_simulator()->Start(); + navigation_simulator()->SetContentsMimeType("multipart/related"); + tab_helper()->NotifyIsMhtmlPage(mhtml_url, mhtml_creation_time); + navigation_simulator()->Commit(); + + EXPECT_EQ(OfflinePageTrustedState::UNTRUSTED, tab_helper()->trusted_state()); + EXPECT_FALSE(tab_helper()->IsShowingTrustedOfflinePage()); + EXPECT_EQ(OfflinePageHeader::Reason::NONE, + tab_helper()->offline_header().reason); + + const OfflinePageItem* offline_page = tab_helper()->offline_page(); + ASSERT_NE(nullptr, offline_page); + EXPECT_EQ(mhtml_url, offline_page->url); + EXPECT_EQ(mhtml_creation_time, offline_page->creation_time); +} + +TEST_F(OfflinePageTabHelperTest, TestNotifyIsMhtmlPage_BadUrl) { + GURL mhtml_url("sftp://www.example.com"); + base::Time mhtml_creation_time = base::Time::FromJsTime(1522339419011L); + tab_helper()->SetCurrentTargetFrameForTest(web_contents()->GetMainFrame()); + + CreateNavigationSimulator(kTestFileUrl); + navigation_simulator()->Start(); + navigation_simulator()->SetContentsMimeType("multipart/related"); + tab_helper()->NotifyIsMhtmlPage(mhtml_url, mhtml_creation_time); + navigation_simulator()->Commit(); + + EXPECT_EQ(OfflinePageTrustedState::UNTRUSTED, tab_helper()->trusted_state()); + EXPECT_FALSE(tab_helper()->IsShowingTrustedOfflinePage()); + EXPECT_EQ(OfflinePageHeader::Reason::NONE, + tab_helper()->offline_header().reason); + + const OfflinePageItem* offline_page = tab_helper()->offline_page(); + EXPECT_EQ(kTestFileUrl, offline_page->url); + EXPECT_EQ(base::Time(), offline_page->creation_time); +} + } // namespace offline_pages
diff --git a/chrome/browser/previews/previews_infobar_tab_helper_unittest.cc b/chrome/browser/previews/previews_infobar_tab_helper_unittest.cc index 95d1411..7e32674 100644 --- a/chrome/browser/previews/previews_infobar_tab_helper_unittest.cc +++ b/chrome/browser/previews/previews_infobar_tab_helper_unittest.cc
@@ -233,6 +233,9 @@ PreviewsInfoBarTabHelper::FromWebContents(web_contents()); EXPECT_FALSE(infobar_tab_helper->displayed_preview_infobar()); + content::WebContentsTester::For(web_contents()) + ->SetMainFrameMimeType("multipart/related"); + SimulateCommit(); offline_pages::OfflinePageItem item; item.url = GURL(kTestUrl);
diff --git a/chrome/browser/printing/pdf_to_emf_converter_browsertest.cc b/chrome/browser/printing/pdf_to_emf_converter_browsertest.cc index 99ff1ef..c050f0ff 100644 --- a/chrome/browser/printing/pdf_to_emf_converter_browsertest.cc +++ b/chrome/browser/printing/pdf_to_emf_converter_browsertest.cc
@@ -296,4 +296,36 @@ } } +IN_PROC_BROWSER_TEST_F(PdfToEmfConverterBrowserTest, + PostScriptLevel2WithZeroSizedText) { + const PdfRenderSettings pdf_settings( + kLetter200DpiRect, gfx::Point(0, 0), k200DpiSize, + /*autorotate=*/false, PdfRenderSettings::Mode::POSTSCRIPT_LEVEL2); + constexpr int kNumberOfPages = 1; + + ASSERT_TRUE(GetTestInput("bug_767343.pdf")); + ASSERT_TRUE(StartPdfConverter(pdf_settings, kNumberOfPages)); + ASSERT_TRUE(GetPage(0)); + // The output is PS encapsulated in EMF. + ASSERT_TRUE(GetPageExpectedEmfData("bug_767343.emf")); + ComparePageEmfHeader(); + ComparePageEmfPayload(); +} + +IN_PROC_BROWSER_TEST_F(PdfToEmfConverterBrowserTest, + PostScriptLevel3WithZeroSizedText) { + const PdfRenderSettings pdf_settings( + kLetter200DpiRect, gfx::Point(0, 0), k200DpiSize, + /*autorotate=*/false, PdfRenderSettings::Mode::POSTSCRIPT_LEVEL3); + constexpr int kNumberOfPages = 1; + + ASSERT_TRUE(GetTestInput("bug_767343.pdf")); + ASSERT_TRUE(StartPdfConverter(pdf_settings, kNumberOfPages)); + ASSERT_TRUE(GetPage(0)); + // The output is PS encapsulated in EMF. + ASSERT_TRUE(GetPageExpectedEmfData("bug_767343.emf")); + ComparePageEmfHeader(); + ComparePageEmfPayload(); +} + } // namespace printing
diff --git a/chrome/browser/profiles/profile_destroyer.cc b/chrome/browser/profiles/profile_destroyer.cc index d863aa0..371d48fd 100644 --- a/chrome/browser/profiles/profile_destroyer.cc +++ b/chrome/browser/profiles/profile_destroyer.cc
@@ -36,39 +36,66 @@ DCHECK(profile); profile->MaybeSendDestroyedNotification(); - HostSet hosts; // Testing profiles can simply be deleted directly. Some tests don't setup // RenderProcessHost correctly and don't necessary run on the UI thread - // anyway, so we can't use the AllHostIterator. - if (profile->AsTestingProfile() == NULL) { - GetHostsForProfile(profile, &hosts); - if (!profile->IsOffTheRecord() && profile->HasOffTheRecordProfile()) - GetHostsForProfile(profile->GetOffTheRecordProfile(), &hosts); - } - // Generally, !hosts.empty() means that there is a leak in a render process - // host that MUST BE FIXED!!! - // - // However, off-the-record profiles are destroyed before their - // RenderProcessHosts in order to erase private data quickly, and - // RenderProcessHostImpl::Release() avoids destroying RenderProcessHosts in - // --single-process mode to avoid race conditions. - DCHECK(hosts.empty() || profile->IsOffTheRecord() || - profile->HasOffTheRecordProfile() || - content::RenderProcessHost::run_renderer_in_process()) - << "Profile still has " << hosts.size() << " hosts"; - // Note that we still test for !profile->IsOffTheRecord here even though we - // DCHECK'd above because we want to protect Release builds against this even - // we need to identify if there are leaks when we run Debug builds. - if (hosts.empty() || !profile->IsOffTheRecord()) { + // anyway, so we can't iterate them via AllHostsIterator anyway. + if (profile->AsTestingProfile()) { if (profile->IsOffTheRecord()) profile->GetOriginalProfile()->DestroyOffTheRecordProfile(); else delete profile; - } else { - // The instance will destroy itself once all render process hosts referring - // to it are properly terminated. - new ProfileDestroyer(profile, &hosts); + return; } + + HostSet profile_hosts = GetHostsForProfile(profile); + const bool profile_is_off_the_record = profile->IsOffTheRecord(); + base::debug::Alias(&profile_is_off_the_record); + const bool profile_has_off_the_record = + !profile_is_off_the_record && profile->HasOffTheRecordProfile(); + base::debug::Alias(&profile_has_off_the_record); + + // Off-the-record profiles have DestroyProfileWhenAppropriate() called before + // their RenderProcessHosts are destroyed, to ensure private data is erased + // promptly. In this case, defer deletion until all the hosts are gone. + const size_t profile_hosts_count = profile_hosts.size(); + base::debug::Alias(&profile_hosts_count); + if (profile_is_off_the_record) { + DCHECK(!profile_has_off_the_record); + if (profile_hosts_count) { + // The instance will destroy itself once all render process hosts + // referring to it are properly terminated. + new ProfileDestroyer(profile, &profile_hosts); + } else { + profile->GetOriginalProfile()->DestroyOffTheRecordProfile(); + } + return; + } + + // If |profile| has an off-the-record profile then count its hosts so crashes + // and DCHECKs will contain that detail. + HostSet off_the_record_hosts; + if (profile_has_off_the_record) { + off_the_record_hosts = + GetHostsForProfile(profile->GetOffTheRecordProfile()); + } + const size_t off_the_record_hosts_count = off_the_record_hosts.size(); + base::debug::Alias(&off_the_record_hosts_count); + + // |profile| is not off-the-record, so if |profile_hosts| is not empty then + // something has leaked a RenderProcessHost, and needs fixing. + // + // The exception is that RenderProcessHostImpl::Release() avoids destroying + // RenderProcessHosts in --single-process mode, to avoid race conditions. + if (!content::RenderProcessHost::run_renderer_in_process()) { + DCHECK_EQ(profile_hosts_count, 0u); +#if !defined(OS_CHROMEOS) + // ChromeOS' system profile can be outlived by its off-the-record profile + // (see https://crbug.com/828479). + DCHECK_EQ(off_the_record_hosts_count, 0u); +#endif + } + + delete profile; } // This can be called to cancel any pending destruction and destroy the profile @@ -173,16 +200,17 @@ } // static -bool ProfileDestroyer::GetHostsForProfile( - Profile* const profile, HostSet* hosts) { +ProfileDestroyer::HostSet ProfileDestroyer::GetHostsForProfile( + Profile* const profile) { + HostSet hosts; for (content::RenderProcessHost::iterator iter( content::RenderProcessHost::AllHostsIterator()); !iter.IsAtEnd(); iter.Advance()) { content::RenderProcessHost* render_process_host = iter.GetCurrentValue(); if (render_process_host && render_process_host->GetBrowserContext() == profile) { - hosts->insert(render_process_host); + hosts.insert(render_process_host); } } - return !hosts->empty(); + return hosts; }
diff --git a/chrome/browser/profiles/profile_destroyer.h b/chrome/browser/profiles/profile_destroyer.h index 48f088b..be90e62 100644 --- a/chrome/browser/profiles/profile_destroyer.h +++ b/chrome/browser/profiles/profile_destroyer.h
@@ -43,8 +43,7 @@ void DestroyProfile(); // Fetch the list of render process hosts that still refer to the profile. - // Return true if we found at least one, false otherwise. - static bool GetHostsForProfile(Profile* const profile, HostSet* hosts); + static HostSet GetHostsForProfile(Profile* const profile); // We need access to all pending destroyers so we can cancel them. static DestroyerSet* pending_destroyers_;
diff --git a/chrome/browser/resource_coordinator/discard_metrics_lifecycle_unit_observer.cc b/chrome/browser/resource_coordinator/discard_metrics_lifecycle_unit_observer.cc index a3aa787..b93d2bb 100644 --- a/chrome/browser/resource_coordinator/discard_metrics_lifecycle_unit_observer.cc +++ b/chrome/browser/resource_coordinator/discard_metrics_lifecycle_unit_observer.cc
@@ -29,7 +29,7 @@ LifecycleUnit* lifecycle_unit) { // If the browser is not shutting down and the tab is in a LOADED state after // being discarded, record TabManager.Discarding.ReloadToCloseTime. - if (!g_browser_process->IsShuttingDown() && + if (g_browser_process && !g_browser_process->IsShuttingDown() && lifecycle_unit->GetState() == LifecycleUnit::State::LOADED && !reload_time_.is_null()) { auto reload_to_close_time = NowTicks() - reload_time_;
diff --git a/chrome/browser/resource_coordinator/discard_metrics_lifecycle_unit_observer_unittest.cc b/chrome/browser/resource_coordinator/discard_metrics_lifecycle_unit_observer_unittest.cc index ae4a513..7843604 100644 --- a/chrome/browser/resource_coordinator/discard_metrics_lifecycle_unit_observer_unittest.cc +++ b/chrome/browser/resource_coordinator/discard_metrics_lifecycle_unit_observer_unittest.cc
@@ -46,9 +46,13 @@ } base::string16 GetTitle() const override { return base::string16(); } std::string GetIconURL() const override { return std::string(); } + base::ProcessHandle GetProcessHandle() const override { + return base::ProcessHandle(); + } SortKey GetSortKey() const override { return SortKey(last_focused_time_); } bool Freeze() override { return false; } int GetEstimatedMemoryFreedOnDiscardKB() const override { return 0; } + bool CanPurge() const override { return false; } bool CanDiscard(DiscardReason reason) const override { return false; } bool Discard(DiscardReason discard_reason) override { return false; }
diff --git a/chrome/browser/resource_coordinator/discard_metrics_util.cc b/chrome/browser/resource_coordinator/discard_metrics_util.cc deleted file mode 100644 index b8766dd4..0000000 --- a/chrome/browser/resource_coordinator/discard_metrics_util.cc +++ /dev/null
@@ -1,35 +0,0 @@ -// Copyright 2017 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 "chrome/browser/resource_coordinator/discard_metrics_util.h" - -#include "base/metrics/histogram_macros.h" - -namespace resource_coordinator { - -void RecordTabDiscarded() { - static int discard_count = 0; - UMA_HISTOGRAM_CUSTOM_COUNTS("TabManager.Discarding.DiscardCount", - ++discard_count, 1, 1000, 50); -} - -void RecordTabReloaded(base::TimeTicks last_active_time, - base::TimeTicks discard_time, - base::TimeTicks reload_time) { - static int reload_count = 0; - UMA_HISTOGRAM_CUSTOM_COUNTS("TabManager.Discarding.ReloadCount", - ++reload_count, 1, 1000, 50); - auto discard_to_reload_time = reload_time - discard_time; - UMA_HISTOGRAM_CUSTOM_TIMES( - "TabManager.Discarding.DiscardToReloadTime", discard_to_reload_time, - base::TimeDelta::FromSeconds(1), base::TimeDelta::FromDays(1), 100); - if (!last_active_time.is_null()) { - auto inactive_to_reload_time = reload_time - last_active_time; - UMA_HISTOGRAM_CUSTOM_TIMES( - "TabManager.Discarding.InactiveToReloadTime", inactive_to_reload_time, - base::TimeDelta::FromSeconds(1), base::TimeDelta::FromDays(1), 100); - } -} - -} // namespace resource_coordinator
diff --git a/chrome/browser/resource_coordinator/discard_metrics_util.h b/chrome/browser/resource_coordinator/discard_metrics_util.h deleted file mode 100644 index 913cc21..0000000 --- a/chrome/browser/resource_coordinator/discard_metrics_util.h +++ /dev/null
@@ -1,25 +0,0 @@ -// Copyright 2017 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 CHROME_BROWSER_RESOURCE_COORDINATOR_DISCARD_METRICS_UTIL_H_ -#define CHROME_BROWSER_RESOURCE_COORDINATOR_DISCARD_METRICS_UTIL_H_ - -#include "base/time/time.h" - -namespace resource_coordinator { - -// Records histograms when a tab is discarded. -void RecordTabDiscarded(); - -// Records histograms when a discarded tab is reloaded. |last_active_time| is -// the last time at which the tab was active. |discard_time| is the time at -// which the tab was discarded. |reload_time| is the time at which the tab was -// reloaded. -void RecordTabReloaded(base::TimeTicks last_active_time, - base::TimeTicks discard_time, - base::TimeTicks reload_time); - -} // namespace resource_coordinator - -#endif // CHROME_BROWSER_RESOURCE_COORDINATOR_DISCARD_METRICS_UTIL_H_
diff --git a/chrome/browser/resource_coordinator/lifecycle_unit.h b/chrome/browser/resource_coordinator/lifecycle_unit.h index bfca348..ff7c7c25 100644 --- a/chrome/browser/resource_coordinator/lifecycle_unit.h +++ b/chrome/browser/resource_coordinator/lifecycle_unit.h
@@ -7,8 +7,10 @@ #include <stdint.h> #include <string> +#include <vector> #include "base/containers/flat_set.h" +#include "base/process/process_handle.h" #include "base/strings/string16.h" #include "base/time/time.h" #include "chrome/browser/resource_coordinator/discard_reason.h" @@ -62,6 +64,13 @@ // icon is available. virtual std::string GetIconURL() const = 0; + // Returns the process hosting this LifecycleUnit. Used to distribute OOM + // scores. + // + // TODO(fdoray): Change this to take into account the fact that a + // LifecycleUnit can be hosted in multiple processes. https://crbug.com/775644 + virtual base::ProcessHandle GetProcessHandle() const = 0; + // Returns a key that can be used to evaluate the relative importance of this // LifecycleUnit. // @@ -91,6 +100,12 @@ // than for individual LifecycleUnits. https://crbug.com/775644 virtual int GetEstimatedMemoryFreedOnDiscardKB() const = 0; + // Whether memory can be purged in the process hosting this LifecycleUnit. + // + // TODO(fdoray): This method should be on a class that represents a process, + // not on a LifecycleUnit. https://crbug.com/775644 + virtual bool CanPurge() const = 0; + // Returns true if this LifecycleUnit can be discared. virtual bool CanDiscard(DiscardReason reason) const = 0; @@ -109,6 +124,7 @@ }; using LifecycleUnitSet = base::flat_set<LifecycleUnit*>; +using LifecycleUnitVector = std::vector<LifecycleUnit*>; } // namespace resource_coordinator
diff --git a/chrome/browser/resource_coordinator/lifecycle_unit_base_unittest.cc b/chrome/browser/resource_coordinator/lifecycle_unit_base_unittest.cc index 0f7887b..0951356e 100644 --- a/chrome/browser/resource_coordinator/lifecycle_unit_base_unittest.cc +++ b/chrome/browser/resource_coordinator/lifecycle_unit_base_unittest.cc
@@ -43,10 +43,14 @@ } base::string16 GetTitle() const override { return base::string16(); } std::string GetIconURL() const override { return std::string(); } + base::ProcessHandle GetProcessHandle() const override { + return base::ProcessHandle(); + } SortKey GetSortKey() const override { return SortKey(); } State GetState() const override { return State::LOADED; } bool Freeze() override { return false; } int GetEstimatedMemoryFreedOnDiscardKB() const override { return 0; } + bool CanPurge() const override { return false; } bool CanDiscard(DiscardReason reason) const override { return false; } bool Discard(DiscardReason discard_reason) override { return false; }
diff --git a/chrome/browser/resource_coordinator/tab_lifecycle_observer_browsertest.cc b/chrome/browser/resource_coordinator/tab_lifecycle_observer_browsertest.cc deleted file mode 100644 index f22849b..0000000 --- a/chrome/browser/resource_coordinator/tab_lifecycle_observer_browsertest.cc +++ /dev/null
@@ -1,196 +0,0 @@ -// Copyright (c) 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. - -#include "base/macros.h" -#include "build/build_config.h" -#include "chrome/browser/browser_process.h" -#include "chrome/browser/resource_coordinator/tab_lifecycle_observer.h" -#include "chrome/browser/resource_coordinator/tab_manager.h" -#include "chrome/browser/resource_coordinator/tab_manager_web_contents_data.h" -#include "chrome/browser/ui/browser.h" -#include "chrome/browser/ui/tabs/tab_strip_model.h" -#include "chrome/common/url_constants.h" -#include "chrome/test/base/in_process_browser_test.h" -#include "content/public/test/test_utils.h" -#include "url/gurl.h" - -using content::OpenURLParams; -using content::WebContents; - -#if defined(OS_WIN) || defined(OS_MACOSX) || defined(OS_LINUX) || \ - defined(OS_CHROMEOS) - -namespace resource_coordinator { - -class TabLifecycleObserverTest : public InProcessBrowserTest { - public: - TabLifecycleObserverTest() {} - - // Helper functions. - void set_tab_strip_model(TabStripModel* tsm) { tab_strip_model_ = tsm; } - - int GetIndex(WebContents* contents) { - return tab_strip_model_->GetIndexOfWebContents(contents); - } - - WebContents* GetContents(int index) { - return tab_strip_model_->GetWebContentsAt(index); - } - - int64_t ContentsId(WebContents* contents) { - return TabManager::IdFromWebContents(contents); - } - - private: - TabStripModel* tab_strip_model_; -}; - -class MockTabLifecycleObserver : public TabLifecycleObserver { - public: - MockTabLifecycleObserver() - : nb_events_(0), - contents_(nullptr), - is_discarded_(false), - is_auto_discardable_(true) {} - - // TabLifecycleObserver implementation: - void OnDiscardedStateChange(content::WebContents* contents, - bool is_discarded) override { - nb_events_++; - contents_ = contents; - is_discarded_ = is_discarded; - } - - void OnAutoDiscardableStateChange(content::WebContents* contents, - bool is_auto_discardable) override { - nb_events_++; - contents_ = contents; - is_auto_discardable_ = is_auto_discardable; - } - - int nb_events() const { return nb_events_; } - WebContents* content() const { return contents_; } - bool is_discarded() const { return is_discarded_; } - bool is_auto_discardable() const { return is_auto_discardable_; } - - private: - int nb_events_; - WebContents* contents_; - bool is_discarded_; - bool is_auto_discardable_; - - DISALLOW_COPY_AND_ASSIGN(MockTabLifecycleObserver); -}; - -IN_PROC_BROWSER_TEST_F(TabLifecycleObserverTest, OnDiscardStateChange) { - TabManager* tab_manager = g_browser_process->GetTabManager(); - auto* tsm = browser()->tab_strip_model(); - set_tab_strip_model(tsm); - - // Open two tabs. - OpenURLParams open1(GURL(chrome::kChromeUIAboutURL), content::Referrer(), - WindowOpenDisposition::NEW_BACKGROUND_TAB, - ui::PAGE_TRANSITION_TYPED, false); - int index_1 = GetIndex(browser()->OpenURL(open1)); - - OpenURLParams open2(GURL(chrome::kChromeUICreditsURL), content::Referrer(), - WindowOpenDisposition::NEW_BACKGROUND_TAB, - ui::PAGE_TRANSITION_TYPED, false); - int index_2 = GetIndex(browser()->OpenURL(open2)); - - // Subscribe observer to TabManager's observer list. - MockTabLifecycleObserver tabmanager_observer; - tab_manager->AddObserver(&tabmanager_observer); - - // Discards both tabs and make sure the events were observed properly. - EXPECT_TRUE(tab_manager->DiscardTabById(ContentsId(GetContents(index_1)), - DiscardReason::kProactive)); - EXPECT_EQ(1, tabmanager_observer.nb_events()); - EXPECT_EQ(ContentsId(GetContents(index_1)), - ContentsId(tabmanager_observer.content())); - EXPECT_TRUE(tabmanager_observer.is_discarded()); - - EXPECT_TRUE(tab_manager->DiscardTabById(ContentsId(GetContents(index_2)), - DiscardReason::kProactive)); - EXPECT_EQ(2, tabmanager_observer.nb_events()); - EXPECT_EQ(ContentsId(GetContents(index_2)), - ContentsId(tabmanager_observer.content())); - EXPECT_TRUE(tabmanager_observer.is_discarded()); - - // Discarding an already discarded tab shouldn't fire the observers. - EXPECT_FALSE(tab_manager->DiscardTabById(ContentsId(GetContents(index_1)), - DiscardReason::kProactive)); - EXPECT_EQ(2, tabmanager_observer.nb_events()); - - // Reload tab 1. - tsm->ActivateTabAt(index_1, false); - EXPECT_EQ(index_1, tsm->active_index()); - EXPECT_EQ(3, tabmanager_observer.nb_events()); - EXPECT_EQ(ContentsId(GetContents(index_1)), - ContentsId(tabmanager_observer.content())); - EXPECT_FALSE(tabmanager_observer.is_discarded()); - - // Reloading a tab that's not discarded shouldn't fire the observers. - tsm->ActivateTabAt(index_1, false); - EXPECT_EQ(3, tabmanager_observer.nb_events()); - - // Reload tab 2. - tsm->ActivateTabAt(index_2, false); - EXPECT_EQ(index_2, tsm->active_index()); - EXPECT_EQ(4, tabmanager_observer.nb_events()); - EXPECT_EQ(ContentsId(GetContents(index_2)), - ContentsId(tabmanager_observer.content())); - EXPECT_FALSE(tabmanager_observer.is_discarded()); - - // After removing the observer from the TabManager's list, it shouldn't - // receive events anymore. - tab_manager->RemoveObserver(&tabmanager_observer); - EXPECT_TRUE(tab_manager->DiscardTabById(ContentsId(GetContents(index_1)), - DiscardReason::kProactive)); - EXPECT_EQ(4, tabmanager_observer.nb_events()); -} - -IN_PROC_BROWSER_TEST_F(TabLifecycleObserverTest, OnAutoDiscardableStateChange) { - TabManager* tab_manager = g_browser_process->GetTabManager(); - auto* tsm = browser()->tab_strip_model(); - set_tab_strip_model(tsm); - - // Open two tabs. - OpenURLParams open(GURL(chrome::kChromeUIAboutURL), content::Referrer(), - WindowOpenDisposition::NEW_BACKGROUND_TAB, - ui::PAGE_TRANSITION_TYPED, false); - WebContents* contents = browser()->OpenURL(open); - - // Subscribe observer to TabManager's observer list. - MockTabLifecycleObserver observer; - tab_manager->AddObserver(&observer); - - // No events initially. - EXPECT_EQ(0, observer.nb_events()); - - // Should maintain at zero since the default value of the state is true. - tab_manager->SetTabAutoDiscardableState(contents, true); - EXPECT_EQ(0, observer.nb_events()); - - // Now it has to change. - tab_manager->SetTabAutoDiscardableState(contents, false); - EXPECT_EQ(1, observer.nb_events()); - EXPECT_FALSE(observer.is_auto_discardable()); - EXPECT_EQ(ContentsId(contents), ContentsId(observer.content())); - - // No changes since it's not a new state. - tab_manager->SetTabAutoDiscardableState(contents, false); - EXPECT_EQ(1, observer.nb_events()); - - // Change it back and we should have another event. - tab_manager->SetTabAutoDiscardableState(contents, true); - EXPECT_EQ(2, observer.nb_events()); - EXPECT_TRUE(observer.is_auto_discardable()); - EXPECT_EQ(ContentsId(contents), ContentsId(observer.content())); -} - -} // namespace resource_coordinator - -#endif // defined(OS_WIN) || defined(OS_MACOSX) || defined(OS_LINUX) || - // defined(OS_CHROMEOS)
diff --git a/chrome/browser/resource_coordinator/tab_lifecycle_unit.cc b/chrome/browser/resource_coordinator/tab_lifecycle_unit.cc index 5b88900..ff1abefd 100644 --- a/chrome/browser/resource_coordinator/tab_lifecycle_unit.cc +++ b/chrome/browser/resource_coordinator/tab_lifecycle_unit.cc
@@ -94,6 +94,17 @@ return favicon.valid ? favicon.url.spec() : std::string(); } +base::ProcessHandle TabLifecycleUnitSource::TabLifecycleUnit::GetProcessHandle() + const { + content::RenderFrameHost* main_frame = GetWebContents()->GetMainFrame(); + if (!main_frame) + return base::ProcessHandle(); + content::RenderProcessHost* process = main_frame->GetProcess(); + if (!process) + return base::ProcessHandle(); + return process->GetHandle(); +} + LifecycleUnit::SortKey TabLifecycleUnitSource::TabLifecycleUnit::GetSortKey() const { return SortKey(last_focused_time_); @@ -115,6 +126,11 @@ return 0; } +bool TabLifecycleUnitSource::TabLifecycleUnit::CanPurge() const { + // A renderer can be purged if it's not playing media. + return !IsMediaTab(); +} + bool TabLifecycleUnitSource::TabLifecycleUnit::CanDiscard( DiscardReason reason) const { // Can't discard a tab that isn't in a TabStripModel.
diff --git a/chrome/browser/resource_coordinator/tab_lifecycle_unit.h b/chrome/browser/resource_coordinator/tab_lifecycle_unit.h index dc9fac88..65af855 100644 --- a/chrome/browser/resource_coordinator/tab_lifecycle_unit.h +++ b/chrome/browser/resource_coordinator/tab_lifecycle_unit.h
@@ -74,9 +74,11 @@ TabLifecycleUnitExternal* AsTabLifecycleUnitExternal() override; base::string16 GetTitle() const override; std::string GetIconURL() const override; + base::ProcessHandle GetProcessHandle() const override; SortKey GetSortKey() const override; bool Freeze() override; int GetEstimatedMemoryFreedOnDiscardKB() const override; + bool CanPurge() const override; bool CanDiscard(DiscardReason reason) const override; bool Discard(DiscardReason discard_reason) override;
diff --git a/chrome/browser/resource_coordinator/tab_lifecycle_unit_external.cc b/chrome/browser/resource_coordinator/tab_lifecycle_unit_external.cc index 7992ea3..fa777285 100644 --- a/chrome/browser/resource_coordinator/tab_lifecycle_unit_external.cc +++ b/chrome/browser/resource_coordinator/tab_lifecycle_unit_external.cc
@@ -4,6 +4,7 @@ #include "chrome/browser/resource_coordinator/tab_lifecycle_unit_external.h" +#include "base/logging.h" #include "chrome/browser/resource_coordinator/tab_lifecycle_unit_source.h" namespace resource_coordinator { @@ -12,9 +13,24 @@ TabLifecycleUnitExternal* TabLifecycleUnitExternal::FromWebContents( content::WebContents* web_contents) { TabLifecycleUnitSource* source = TabLifecycleUnitSource::GetInstance(); - if (!source) - return nullptr; + DCHECK(source); return source->GetTabLifecycleUnitExternal(web_contents); } +// static +void TabLifecycleUnitExternal::AddTabLifecycleObserver( + TabLifecycleObserver* observer) { + TabLifecycleUnitSource* source = TabLifecycleUnitSource::GetInstance(); + DCHECK(source); + source->AddTabLifecycleObserver(observer); +} + +// static +void TabLifecycleUnitExternal::RemoveTabLifecycleObserver( + TabLifecycleObserver* observer) { + TabLifecycleUnitSource* source = TabLifecycleUnitSource::GetInstance(); + DCHECK(source); + source->RemoveTabLifecycleObserver(observer); +} + } // namespace resource_coordinator
diff --git a/chrome/browser/resource_coordinator/tab_lifecycle_unit_external.h b/chrome/browser/resource_coordinator/tab_lifecycle_unit_external.h index f15cf42..a824c5d 100644 --- a/chrome/browser/resource_coordinator/tab_lifecycle_unit_external.h +++ b/chrome/browser/resource_coordinator/tab_lifecycle_unit_external.h
@@ -11,6 +11,8 @@ namespace resource_coordinator { +class TabLifecycleObserver; + // Interface to control the lifecycle of a tab exposed outside of // chrome/browser/resource_coordinator/. class TabLifecycleUnitExternal { @@ -20,6 +22,11 @@ static TabLifecycleUnitExternal* FromWebContents( content::WebContents* web_contents); + // Adds / removes an observer that is notified when the discarded or auto- + // discardable state of a tab changes. + static void AddTabLifecycleObserver(TabLifecycleObserver* observer); + static void RemoveTabLifecycleObserver(TabLifecycleObserver* observer); + virtual ~TabLifecycleUnitExternal() = default; // Returns the WebContents associated with this tab.
diff --git a/chrome/browser/resource_coordinator/tab_lifecycle_unit_source.cc b/chrome/browser/resource_coordinator/tab_lifecycle_unit_source.cc index 170c6620..057479e 100644 --- a/chrome/browser/resource_coordinator/tab_lifecycle_unit_source.cc +++ b/chrome/browser/resource_coordinator/tab_lifecycle_unit_source.cc
@@ -98,7 +98,9 @@ TabStripModel* TabLifecycleUnitSource::GetFocusedTabStripModel() const { if (focused_tab_strip_model_for_testing_) return focused_tab_strip_model_for_testing_; - Browser* const focused_browser = chrome::FindBrowserWithActiveWindow(); + // Use FindLastActive() rather than FindBrowserWithActiveWindow() to avoid + // flakiness when focus changes during browser tests. + Browser* const focused_browser = chrome::FindLastActive(); if (!focused_browser) return nullptr; return focused_browser->tab_strip_model();
diff --git a/chrome/browser/resource_coordinator/tab_lifecycle_unit_source_unittest.cc b/chrome/browser/resource_coordinator/tab_lifecycle_unit_source_unittest.cc index 82482cf..c1525d1f 100644 --- a/chrome/browser/resource_coordinator/tab_lifecycle_unit_source_unittest.cc +++ b/chrome/browser/resource_coordinator/tab_lifecycle_unit_source_unittest.cc
@@ -89,15 +89,18 @@ protected: TabLifecycleUnitSourceTest() : scoped_set_tick_clock_for_testing_(&test_clock_) { - source_.AddObserver(&source_observer_); - source_.AddTabLifecycleObserver(&tab_observer_); } void SetUp() override { ChromeRenderViewHostTestHarness::SetUp(); + + source_ = TabLifecycleUnitSource::GetInstance(); + source_->AddObserver(&source_observer_); + source_->AddTabLifecycleObserver(&tab_observer_); + tab_strip_model_ = std::make_unique<TabStripModel>(&tab_strip_model_delegate_, profile()); - tab_strip_model_->AddObserver(&source_); + tab_strip_model_->AddObserver(source_); } void TearDown() override { @@ -114,7 +117,7 @@ LifecycleUnit** first_lifecycle_unit, LifecycleUnit** second_lifecycle_unit) { if (focus_tab_strip) - source_.SetFocusedTabStripModelForTesting(tab_strip_model_.get()); + source_->SetFocusedTabStripModelForTesting(tab_strip_model_.get()); // Add a foreground tab to the tab strip. test_clock_.Advance(kShortDelay); @@ -133,7 +136,7 @@ content::WebContents* first_web_contents = CreateAndNavigateWebContents(); tab_strip_model_->AppendWebContents(first_web_contents, true); testing::Mock::VerifyAndClear(&source_observer_); - EXPECT_TRUE(source_.GetTabLifecycleUnitExternal(first_web_contents)); + EXPECT_TRUE(source_->GetTabLifecycleUnitExternal(first_web_contents)); // Add another foreground tab to the focused tab strip. test_clock_.Advance(kShortDelay); @@ -156,7 +159,7 @@ content::WebContents* second_web_contents = CreateAndNavigateWebContents(); tab_strip_model_->AppendWebContents(second_web_contents, true); testing::Mock::VerifyAndClear(&source_observer_); - EXPECT_TRUE(source_.GetTabLifecycleUnitExternal(second_web_contents)); + EXPECT_TRUE(source_->GetTabLifecycleUnitExternal(second_web_contents)); // TabStripModel doesn't update the visibility of its WebContents by itself. first_web_contents->WasHidden(); @@ -196,7 +199,7 @@ content::WebContents* third_web_contents = CreateAndNavigateWebContents(); tab_strip_model_->AppendWebContents(third_web_contents, false); testing::Mock::VerifyAndClear(&source_observer_); - EXPECT_TRUE(source_.GetTabLifecycleUnitExternal(third_web_contents)); + EXPECT_TRUE(source_->GetTabLifecycleUnitExternal(third_web_contents)); // Expect notifications when tabs are closed. CloseTabsAndExpectNotifications( @@ -219,7 +222,7 @@ tab_strip_model->CloseAllTabs(); } - TabLifecycleUnitSource source_; + TabLifecycleUnitSource* source_ = nullptr; testing::StrictMock<MockLifecycleUnitSourceObserver> source_observer_; testing::StrictMock<MockTabLifecycleObserver> tab_observer_; std::unique_ptr<TabStripModel> tab_strip_model_; @@ -308,13 +311,13 @@ content::WebContents* original_web_contents = tab_strip_model_->GetWebContentsAt(1); TabLifecycleUnitExternal* tab_lifecycle_unit_external = - source_.GetTabLifecycleUnitExternal(original_web_contents); + source_->GetTabLifecycleUnitExternal(original_web_contents); content::WebContents* new_web_contents = CreateTestWebContents(); EXPECT_EQ(original_web_contents, tab_strip_model_->ReplaceWebContentsAt(1, new_web_contents)); - EXPECT_FALSE(source_.GetTabLifecycleUnitExternal(original_web_contents)); + EXPECT_FALSE(source_->GetTabLifecycleUnitExternal(original_web_contents)); EXPECT_EQ(tab_lifecycle_unit_external, - source_.GetTabLifecycleUnitExternal(new_web_contents)); + source_->GetTabLifecycleUnitExternal(new_web_contents)); delete original_web_contents; @@ -339,7 +342,7 @@ NoUnloadListenerTabStripModelDelegate other_tab_strip_model_delegate; TabStripModel other_tab_strip_model(&other_tab_strip_model_delegate, profile()); - other_tab_strip_model.AddObserver(&source_); + other_tab_strip_model.AddObserver(source_); // Insert the tab into the second tab strip without focusing it. Verify that // it can be discarded. @@ -410,7 +413,7 @@ EXPECT_EQ(kDummyLastActiveTime, tab_strip_model_->GetWebContentsAt(0)->GetLastActiveTime()); - source_.SetFocusedTabStripModelForTesting(nullptr); + source_->SetFocusedTabStripModelForTesting(nullptr); } TEST_F(TabLifecycleUnitSourceTest, DiscardAndActivate) {
diff --git a/chrome/browser/resource_coordinator/tab_manager.cc b/chrome/browser/resource_coordinator/tab_manager.cc index 266b911..0bed292 100644 --- a/chrome/browser/resource_coordinator/tab_manager.cc +++ b/chrome/browser/resource_coordinator/tab_manager.cc
@@ -11,12 +11,10 @@ #include "base/bind.h" #include "base/bind_helpers.h" -#include "base/containers/flat_set.h" #include "base/feature_list.h" #include "base/memory/memory_pressure_monitor.h" #include "base/metrics/field_trial.h" #include "base/metrics/histogram_macros.h" -#include "base/observer_list.h" #include "base/process/process.h" #include "base/rand_util.h" #include "base/strings/string16.h" @@ -33,7 +31,7 @@ #include "chrome/browser/profiles/profile.h" #include "chrome/browser/resource_coordinator/background_tab_navigation_throttle.h" #include "chrome/browser/resource_coordinator/resource_coordinator_web_contents_observer.h" -#include "chrome/browser/resource_coordinator/tab_lifecycle_observer.h" +#include "chrome/browser/resource_coordinator/tab_lifecycle_unit_external.h" #include "chrome/browser/resource_coordinator/tab_manager_features.h" #include "chrome/browser/resource_coordinator/tab_manager_resource_coordinator_signal_observer.h" #include "chrome/browser/resource_coordinator/tab_manager_stats_collector.h" @@ -63,7 +61,6 @@ #include "content/public/common/content_features.h" #include "content/public/common/page_importance_signals.h" #include "third_party/WebKit/public/platform/WebSuddenTerminationDisablerType.h" -#include "ui/gfx/geometry/rect.h" #if defined(OS_CHROMEOS) #include "chrome/browser/resource_coordinator/tab_manager_delegate_chromeos.h" @@ -90,85 +87,21 @@ // value. const int kAdjustmentIntervalSeconds = 10; -// The time during which a tab is protected from discarding after it stops being -// audible. -const int kAudioProtectionTimeSeconds = 60; +struct LifecycleUnitAndSortKey { + explicit LifecycleUnitAndSortKey(LifecycleUnit* lifecycle_unit) + : lifecycle_unit(lifecycle_unit), + sort_key(lifecycle_unit->GetSortKey()) {} -int FindWebContentsById(const TabStripModel* model, int32_t tab_id) { - for (int idx = 0; idx < model->count(); idx++) { - WebContents* web_contents = model->GetWebContentsAt(idx); - auto* data = TabManager::WebContentsData::FromWebContents(web_contents); - if (data && tab_id == data->id()) - return idx; + bool operator<(const LifecycleUnitAndSortKey& other) const { + return sort_key < other.sort_key; + } + bool operator>(const LifecycleUnitAndSortKey& other) const { + return sort_key > other.sort_key; } - return -1; -} - -void ReloadWebContentsIfDiscarded(WebContents* contents, - TabManager::WebContentsData* contents_data) { - if (contents_data->IsDiscarded()) { - contents->GetController().SetNeedsReload(); - contents->GetController().LoadIfNecessary(); - contents_data->SetDiscardState(false); - } -} - -// Returns a set with browsers in |browser_info_list| that are completely -// covered by another browser in |browser_info_list| (some browsers that match -// this description might not be included in the set if insufficient z-order -// information is provided). Non-browser windows are not taken into -// consideration when computing window occlusion, because there is no simple way -// to know whether they opaquely fill their bounds. -// -// TODO(fdoray): Handle the case where a browser window is completely covered by -// the union of other browser windows but not by a single browser window. -base::flat_set<const BrowserInfo*> GetOccludedBrowsers( - const std::vector<BrowserInfo>& browser_info_list, - const std::vector<gfx::NativeWindow>& windows_sorted_by_z_index) { - base::flat_set<const BrowserInfo*> occluded_browsers; - std::vector<gfx::Rect> bounds_of_previous_browsers; - - // Traverse windows from topmost to bottommost. - for (gfx::NativeWindow native_window : windows_sorted_by_z_index) { - // Find the BrowserInfo corresponding to the current NativeWindow. - auto browser_info_it = std::find_if( - browser_info_list.begin(), browser_info_list.end(), - [&native_window](const BrowserInfo& browser_info) { - return browser_info.browser->window()->GetNativeWindow() == - native_window; - }); - - // Skip the current NativeWindow if no browser is associated with it or if - // the associated browser is minimized. - if (browser_info_it == browser_info_list.end() || - browser_info_it->browser->window()->IsMinimized()) { - continue; - } - - // Determine if the browser window is occluded by looking for a previously - // traversed browser window that completely covers it.] - bool browser_is_occluded = false; - const gfx::Rect bounds = browser_info_it->browser->window()->GetBounds(); - for (const gfx::Rect other_bounds : bounds_of_previous_browsers) { - if (other_bounds.Contains(bounds)) { - browser_is_occluded = true; - break; - } - } - - // Add the current browser to the list of occluded browsers if - // |browser_is_occluded| is true. Otherwise, add the current window bounds - // to |bounds_of_previous_browsers| for use in future window occlusion - // computations. - if (browser_is_occluded) - occluded_browsers.insert(&*browser_info_it); - else - bounds_of_previous_browsers.push_back(bounds); - } - - return occluded_browsers; -} + LifecycleUnit* lifecycle_unit; + LifecycleUnit::SortKey sort_key; +}; std::unique_ptr<base::trace_event::ConvertableToTraceFormat> DataAsTraceValue( TabManager::BackgroundTabLoadingMode mode, @@ -219,12 +152,10 @@ constexpr base::TimeDelta TabManager::kDefaultMinTimeToPurge; TabManager::TabManager() - : discard_count_(0), - browser_tab_strip_tracker_(this, nullptr, this), + : browser_tab_strip_tracker_(this, nullptr, nullptr), is_session_restore_loading_tabs_(false), restored_tab_count_(0u), background_tab_loading_mode_(BackgroundTabLoadingMode::kStaggered), - force_load_timer_(std::make_unique<base::OneShotTimer>(GetTickClock())), loading_slots_(kNumOfLoadingSlots), weak_ptr_factory_(this) { #if defined(OS_CHROMEOS) @@ -307,106 +238,31 @@ void TabManager::Stop() { update_timer_.Stop(); - force_load_timer_->Stop(); + force_load_timer_.reset(); memory_pressure_listener_.reset(); } -int TabManager::FindTabStripModelById(int32_t tab_id, - TabStripModel** model) const { - DCHECK(model); +LifecycleUnitVector TabManager::GetSortedLifecycleUnits() { + std::vector<LifecycleUnitAndSortKey> lifecycle_units_and_sort_keys; + lifecycle_units_and_sort_keys.reserve(lifecycle_units_.size()); + for (auto* lifecycle_unit : lifecycle_units_) + lifecycle_units_and_sort_keys.emplace_back(lifecycle_unit); + std::sort(lifecycle_units_and_sort_keys.begin(), + lifecycle_units_and_sort_keys.end()); - for (const auto& browser_info : GetBrowserInfoList()) { - TabStripModel* local_model = browser_info.tab_strip_model; - int idx = FindWebContentsById(local_model, tab_id); - if (idx != -1) { - *model = local_model; - return idx; - } + LifecycleUnitVector sorted_lifecycle_units; + sorted_lifecycle_units.reserve(lifecycle_units_.size()); + for (auto& lifecycle_unit_and_sort_key : lifecycle_units_and_sort_keys) { + sorted_lifecycle_units.push_back( + lifecycle_unit_and_sort_key.lifecycle_unit); } - return -1; -} - -TabStatsList TabManager::GetTabStats() const { - TabStatsList stats_list(GetUnsortedTabStats()); - - // Sort the collected data so that least desirable to be killed is first, most - // desirable is last. - std::sort(stats_list.begin(), stats_list.end(), CompareTabStats); - - return stats_list; + return sorted_lifecycle_units; } bool TabManager::IsTabDiscarded(content::WebContents* contents) const { - return GetWebContentsData(contents)->IsDiscarded(); -} - -bool TabManager::CanDiscardTab(const TabStats& tab_stats, - DiscardReason reason) const { -#if defined(OS_CHROMEOS) - if (tab_stats.is_active && tab_stats.is_in_visible_window) - return false; -#else - if (tab_stats.is_active) - return false; -#endif // defined(OS_CHROMEOS) - - TabStripModel* model; - const int idx = FindTabStripModelById(tab_stats.id, &model); - - if (idx == -1) - return false; - - WebContents* web_contents = model->GetWebContentsAt(idx); - - // Do not discard tabs that don't have a valid URL (most probably they have - // just been opened and dicarding them would lose the URL). - // TODO(georgesak): Look into a workaround to be able to kill the tab without - // losing the pending navigation. - if (!web_contents->GetLastCommittedURL().is_valid() || - web_contents->GetLastCommittedURL().is_empty()) { - return false; - } - - // Do not discard tabs in which the user has entered text in a form, lest that - // state gets lost. - if (web_contents->GetPageImportanceSignals().had_form_interaction) - return false; - - // Do not discard tabs that are playing either playing audio or accessing the - // microphone or camera as it's too distruptive to the user experience. Note - // that tabs that have recently stopped playing audio by at least - // |kAudioProtectionTimeSeconds| seconds are protected as well. - if (IsMediaTab(web_contents)) - return false; - - // Do not discard PDFs as they might contain entry that is not saved and they - // don't remember their scrolling positions. See https://crbug.com/547286 and - // https://crbug.com/65244. - // TODO(georgesak): Remove this workaround when the bugs are fixed. - if (web_contents->GetContentsMimeType() == "application/pdf") - return false; - - // Do not discard a tab that was explicitly disallowed to. - if (!IsTabAutoDiscardable(web_contents)) - return false; - -#if defined(OS_CHROMEOS) - // The following protections are ignored on ChromeOS during urgent discard, - // because running out of memory would lead to a kernel panic. - if (reason == DiscardReason::kUrgent) - return true; -#endif // defined(OS_CHROMEOS) - - if (GetWebContentsData(web_contents)->DiscardCount() > 0) - return false; - - auto delta = - NowTicks() - GetWebContentsData(web_contents)->LastInactiveTime(); - if (delta < kDiscardProtectionTime) - return false; - - return true; + auto* lifecycle_unit = TabLifecycleUnitExternal::FromWebContents(contents); + return lifecycle_unit && lifecycle_unit->IsDiscarded(); } void TabManager::DiscardTab(DiscardReason reason) { @@ -423,34 +279,32 @@ DiscardTabImpl(reason); } -WebContents* TabManager::DiscardTabById(int32_t tab_id, DiscardReason reason) { - TabStripModel* model; - int index = FindTabStripModelById(tab_id, &model); - - if (index == -1) - return nullptr; - - DVLOG(1) << "Discarding tab " << index << " id " << tab_id; - - return DiscardWebContentsAt(index, model, reason); +void TabManager::DiscardTabById(int32_t tab_id, DiscardReason reason) { + for (LifecycleUnit* lifecycle_unit : lifecycle_units_) { + if (lifecycle_unit->GetID() == tab_id) { + lifecycle_unit->Discard(reason); + return; + } + } } void TabManager::FreezeTabById(int32_t tab_id) { - TabStripModel* model = nullptr; - int index = FindTabStripModelById(tab_id, &model); - - if (index == -1) - return; - - DVLOG(1) << "Freezing tab " << index << " id " << tab_id; - - FreezeWebContentsAt(index, model); + for (LifecycleUnit* lifecycle_unit : lifecycle_units_) { + if (lifecycle_unit->GetID() == tab_id) { + lifecycle_unit->Freeze(); + return; + } + } } WebContents* TabManager::DiscardTabByExtension(content::WebContents* contents) { if (contents) { - return DiscardTabById(IdFromWebContents(contents), - DiscardReason::kExternal); + TabLifecycleUnitExternal* tab_lifecycle_unit_external = + TabLifecycleUnitExternal::FromWebContents(contents); + DCHECK(tab_lifecycle_unit_external); + if (tab_lifecycle_unit_external->DiscardTab()) + return tab_lifecycle_unit_external->GetWebContents(); + return nullptr; } return DiscardTabImpl(DiscardReason::kExternal); @@ -467,118 +321,58 @@ memory::OomMemoryDetails::Log(title, callback); } -TabStatsList TabManager::GetUnsortedTabStats( - const std::vector<gfx::NativeWindow>& windows_sorted_by_z_index) const { - DCHECK_CURRENTLY_ON(BrowserThread::UI); - - const auto browser_info_list = GetBrowserInfoList(); - const base::flat_set<const BrowserInfo*> occluded_browsers = - GetOccludedBrowsers(browser_info_list, windows_sorted_by_z_index); - - TabStatsList stats_list; - stats_list.reserve(32); // 99% of users have < 30 tabs open. - for (const BrowserInfo& browser_info : browser_info_list) { - const bool window_is_active = stats_list.empty(); - const bool window_is_visible = - !browser_info.window_is_minimized && - !base::ContainsKey(occluded_browsers, &browser_info); - AddTabStats(browser_info, window_is_active, window_is_visible, &stats_list); - } - - return stats_list; -} - void TabManager::AddObserver(TabLifecycleObserver* observer) { - observers_.AddObserver(observer); + TabLifecycleUnitExternal::AddTabLifecycleObserver(observer); } void TabManager::RemoveObserver(TabLifecycleObserver* observer) { - observers_.RemoveObserver(observer); + TabLifecycleUnitExternal::RemoveTabLifecycleObserver(observer); } bool TabManager::IsTabAutoDiscardable(content::WebContents* contents) const { - return GetWebContentsData(contents)->IsAutoDiscardable(); + auto* lifecycle_unit = TabLifecycleUnitExternal::FromWebContents(contents); + return !lifecycle_unit || lifecycle_unit->IsAutoDiscardable(); } void TabManager::SetTabAutoDiscardableState(int32_t tab_id, bool state) { - auto* web_contents = GetWebContentsById(tab_id); - if (web_contents) - SetTabAutoDiscardableState(web_contents, state); + for (LifecycleUnit* lifecycle_unit : lifecycle_units_) { + if (lifecycle_unit->GetID() == tab_id) { + TabLifecycleUnitExternal* tab_lifecycle_unit_external = + lifecycle_unit->AsTabLifecycleUnitExternal(); + // For now, all LifecycleUnits are TabLifecycleUnitExternals. + DCHECK(tab_lifecycle_unit_external); + tab_lifecycle_unit_external->SetAutoDiscardable(state); + return; + } + } } void TabManager::SetTabAutoDiscardableState(content::WebContents* contents, bool state) { - GetWebContentsData(contents)->SetAutoDiscardableState(state); -} - -content::WebContents* TabManager::GetWebContentsById(int32_t tab_id) const { - TabStripModel* model = nullptr; - int index = FindTabStripModelById(tab_id, &model); - if (index == -1) - return nullptr; - return model->GetWebContentsAt(index); + TabLifecycleUnitExternal::FromWebContents(contents)->SetAutoDiscardable( + state); } bool TabManager::CanPurgeBackgroundedRenderer(int render_process_id) const { - // A renderer can be purged if it's not playing media. - auto tab_stats = GetUnsortedTabStats(); - for (auto& tab : tab_stats) { - if (tab.child_process_host_id != render_process_id) + for (LifecycleUnit* lifecycle_unit : lifecycle_units_) { + TabLifecycleUnitExternal* tab_lifecycle_unit_external = + lifecycle_unit->AsTabLifecycleUnitExternal(); + // For now, all LifecycleUnits are TabLifecycleUnitExternals. + DCHECK(tab_lifecycle_unit_external); + content::WebContents* content = + tab_lifecycle_unit_external->GetWebContents(); + DCHECK(content); + + if (content->IsCrashed()) continue; - WebContents* web_contents = GetWebContentsById(tab.id); - if (!web_contents) - return false; - if (IsMediaTab(web_contents)) + if (content->GetMainFrame()->GetProcess()->GetID() != render_process_id) + continue; + if (!lifecycle_unit->CanPurge()) return false; } return true; } -// static -bool TabManager::CompareTabStats(const TabStats& first, - const TabStats& second) { - // Protect non auto-discardable tabs. - if (first.is_auto_discardable != second.is_auto_discardable) - return !first.is_auto_discardable; - - // Protect tabs with pending form entries. - if (first.has_form_entry != second.has_form_entry) - return first.has_form_entry; - - // Protect streaming audio and video conferencing tabs as these are similar to - // active tabs. - if (first.is_media != second.is_media) - return first.is_media; - - // Tab with internal web UI like NTP or Settings are good choices to discard, - // so protect non-Web UI and let the other conditionals finish the sort. - if (first.is_internal_page != second.is_internal_page) - return !first.is_internal_page; - - // Being pinned is important to protect. - if (first.is_pinned != second.is_pinned) - return first.is_pinned; - - // Being an app is important too, as it's the only visible surface in the - // window and should not be discarded. - if (first.is_app != second.is_app) - return first.is_app; - - // A tab with a beforeunload handler usually indicates that the tab has - // unsaved user state. - if (first.has_beforeunload_handler != second.has_beforeunload_handler) - return first.has_beforeunload_handler; - - // Being more recently active is more important. - return first.last_active > second.last_active; -} - -// static -int32_t TabManager::IdFromWebContents(WebContents* web_contents) { - auto* data = GetWebContentsData(web_contents); - return data->id(); -} - bool TabManager::IsTabInSessionRestore(WebContents* web_contents) const { return GetWebContentsData(web_contents)->is_in_session_restore(); } @@ -615,18 +409,6 @@ /////////////////////////////////////////////////////////////////////////////// // TabManager, private: -void TabManager::OnDiscardedStateChange(content::WebContents* contents, - bool is_discarded) { - for (TabLifecycleObserver& observer : observers_) - observer.OnDiscardedStateChange(contents, is_discarded); -} - -void TabManager::OnAutoDiscardableStateChange(content::WebContents* contents, - bool is_auto_discardable) { - for (TabLifecycleObserver& observer : observers_) - observer.OnAutoDiscardableStateChange(contents, is_auto_discardable); -} - // static void TabManager::PurgeMemoryAndDiscardTab(DiscardReason reason) { TabManager* manager = g_browser_process->GetTabManager(); @@ -665,56 +447,6 @@ } } -void TabManager::AddTabStats(const BrowserInfo& browser_info, - bool window_is_active, - bool window_is_visible, - TabStatsList* stats_list) const { - TabStripModel* tab_strip_model = browser_info.tab_strip_model; - for (int i = 0; i < tab_strip_model->count(); i++) { - WebContents* contents = tab_strip_model->GetWebContentsAt(i); - if (!contents->IsCrashed()) { - TabStats stats; - stats.is_app = browser_info.browser_is_app; - stats.is_internal_page = IsInternalPage(contents->GetLastCommittedURL()); - stats.is_media = IsMediaTab(contents); - stats.is_pinned = tab_strip_model->IsTabPinned(i); - stats.is_active = tab_strip_model->active_index() == i; - stats.is_in_active_window = window_is_active; - stats.is_in_visible_window = window_is_visible; - stats.is_discarded = GetWebContentsData(contents)->IsDiscarded(); - stats.has_form_entry = - contents->GetPageImportanceSignals().had_form_interaction; - stats.discard_count = GetWebContentsData(contents)->DiscardCount(); - stats.last_active = contents->GetLastActiveTime(); - stats.render_process_host = contents->GetMainFrame()->GetProcess(); - stats.renderer_handle = - contents->GetMainFrame()->GetProcess()->GetHandle(); - stats.child_process_host_id = - contents->GetMainFrame()->GetProcess()->GetID(); -#if defined(OS_CHROMEOS) - stats.oom_score = delegate_->GetCachedOomScore(stats.renderer_handle); -#endif - stats.tab_url = contents->GetLastCommittedURL().spec(); - auto* commit = contents->GetController().GetLastCommittedEntry(); - if (commit) { - const auto& favicon = commit->GetFavicon(); - if (favicon.valid) - stats.favicon_url = favicon.url.spec(); - } - stats.title = contents->GetTitle(); - stats.id = IdFromWebContents(contents); - content::RenderFrameHost* render_frame = contents->GetMainFrame(); - DCHECK(render_frame); - stats.has_beforeunload_handler = - render_frame->GetSuddenTerminationDisablerState( - blink::kBeforeUnloadHandler); - stats.is_auto_discardable = - GetWebContentsData(contents)->IsAutoDiscardable(); - stats_list->push_back(stats); - } - } -} - // This function is called when |update_timer_| fires. It will adjust the clock // if needed (if it detects that the machine was asleep) and will fire the stats // updating on ChromeOS via the delegate. This function also tries to purge @@ -728,9 +460,8 @@ return; #if defined(OS_CHROMEOS) - TabStatsList stats_list = GetTabStats(); // This starts the CrOS specific OOM adjustments in /proc/<pid>/oom_score_adj. - delegate_->AdjustOomPriorities(stats_list); + delegate_->AdjustOomPriorities(); #endif PurgeBackgroundedTabsIfNeeded(); @@ -746,6 +477,8 @@ bool TabManager::ShouldPurgeNow(content::WebContents* content) const { if (GetWebContentsData(content)->is_purged()) return false; + if (IsTabDiscarded(content)) + return false; base::TimeDelta time_passed = NowTicks() - GetWebContentsData(content)->LastInactiveTime(); @@ -753,15 +486,25 @@ } void TabManager::PurgeBackgroundedTabsIfNeeded() { - auto tab_stats = GetUnsortedTabStats(); - for (auto& tab : tab_stats) { - if (!tab.render_process_host->IsProcessBackgrounded()) - continue; - if (!CanPurgeBackgroundedRenderer(tab.child_process_host_id)) + for (LifecycleUnit* lifecycle_unit : lifecycle_units_) { + TabLifecycleUnitExternal* tab_lifecycle_unit_external = + lifecycle_unit->AsTabLifecycleUnitExternal(); + // For now, all LifecycleUnits are TabLifecycleUnitExternals. + DCHECK(tab_lifecycle_unit_external); + content::WebContents* content = + tab_lifecycle_unit_external->GetWebContents(); + DCHECK(content); + + if (content->IsCrashed()) continue; - WebContents* content = GetWebContentsById(tab.id); - if (!content) + content::RenderProcessHost* render_process_host = + content->GetMainFrame()->GetProcess(); + int render_process_id = render_process_host->GetID(); + + if (!render_process_host->IsProcessBackgrounded()) + continue; + if (!CanPurgeBackgroundedRenderer(render_process_id)) continue; bool purge_now = ShouldPurgeNow(content); @@ -773,105 +516,10 @@ GetWebContentsData(content)->set_is_purged(true); // TODO(tasak): rename PurgeAndSuspend with a better name, e.g. // RequestPurgeCache, because we don't suspend any renderers. - tab.render_process_host->PurgeAndSuspend(); + render_process_host->PurgeAndSuspend(); } } -WebContents* TabManager::DiscardWebContentsAt(int index, - TabStripModel* model, - DiscardReason reason) { - WebContents* old_contents = model->GetWebContentsAt(index); - - // Can't discard tabs that are already discarded. - if (GetWebContentsData(old_contents)->IsDiscarded()) - return nullptr; - - ++discard_count_; - - UMA_HISTOGRAM_BOOLEAN( - "TabManager.Discarding.DiscardedTabHasBeforeUnloadHandler", - old_contents->NeedToFireBeforeUnload()); - - WebContents* null_contents = - WebContents::Create(WebContents::CreateParams(model->profile())); - // Copy over the state from the navigation controller to preserve the - // back/forward history and to continue to display the correct title/favicon. - // - // Set |needs_reload| to false so that the tab is not automatically reloaded - // when activated (otherwise, there would be an immediate reload when the - // active tab in a non-visible window is discarded). TabManager will - // explicitly reload the tab when it becomes the active tab in an active - // window (ReloadWebContentsIfDiscarded). - // - // Note: It is important that |needs_reload| is false even when the discarded - // tab is not active. Otherwise, it would get reloaded by - // WebContentsImpl::WasShown() and by ReloadWebContentsIfDiscarded() when - // activated. - null_contents->GetController().CopyStateFrom(old_contents->GetController(), - /* needs_reload */ false); - - // Make sure to persist the last active time property. - null_contents->SetLastActiveTime(old_contents->GetLastActiveTime()); - // Copy over the discard count. - WebContentsData::CopyState(old_contents, null_contents); - - // First try to fast-kill the process, if it's just running a single tab. - bool fast_shutdown_success = - old_contents->GetMainFrame()->GetProcess()->FastShutdownIfPossible(1u, - false); - -#ifdef OS_CHROMEOS - if (!fast_shutdown_success && reason == DiscardReason::kUrgent) { - content::RenderFrameHost* main_frame = old_contents->GetMainFrame(); - // We avoid fast shutdown on tabs with beforeunload handlers on the main - // frame, as that is often an indication of unsaved user state. - DCHECK(main_frame); - if (!main_frame->GetSuddenTerminationDisablerState( - blink::kBeforeUnloadHandler)) { - fast_shutdown_success = - old_contents->GetMainFrame()->GetProcess()->FastShutdownIfPossible( - 1u, /* skip_unload_handlers */ true); - } - UMA_HISTOGRAM_BOOLEAN( - "TabManager.Discarding.DiscardedTabCouldUnsafeFastShutdown", - fast_shutdown_success); - } -#endif - UMA_HISTOGRAM_BOOLEAN("TabManager.Discarding.DiscardedTabCouldFastShutdown", - fast_shutdown_success); - - // Replace the discarded tab with the null version. - model->ReplaceWebContentsAt(index, null_contents); - // Mark the tab so it will reload when clicked on. - GetWebContentsData(null_contents)->SetDiscardState(true); - GetWebContentsData(null_contents)->IncrementDiscardCount(); - - // Make the tab PURGED to avoid purging null_contents. - GetWebContentsData(null_contents)->set_is_purged(true); - - // Discard the old tab's renderer. - // TODO(jamescook): This breaks script connections with other tabs. - // Find a different approach that doesn't do that, perhaps based on - // RenderFrameProxyHosts. - delete old_contents; - - // This ensures that on reload after discard, the document has - // "wasDiscarded" set to true. - null_contents->SetWasDiscarded(true); - return null_contents; -} - -void TabManager::FreezeWebContentsAt(int index, TabStripModel* model) { - WebContents* content = model->GetWebContentsAt(index); - - // Can't freeze tabs that are already discarded or frozen. - // TODO(fmeawad): Only freeze non-frozen tabs. - if (!content || GetWebContentsData(content)->IsDiscarded()) - return; - - content->FreezePage(); -} - void TabManager::PauseBackgroundTabOpeningIfNeeded() { TRACE_EVENT_INSTANT0("navigation", "TabManager::PauseBackgroundTabOpeningIfNeeded", @@ -918,20 +566,6 @@ // calling PurgeBrowserMemory() before CRITICAL is reached. } -void TabManager::TabChangedAt(content::WebContents* contents, - int index, - TabChangeType change_type) { - if (change_type != TabChangeType::kAll) - return; - auto* data = GetWebContentsData(contents); - bool old_state = data->IsRecentlyAudible(); - bool current_state = contents->WasRecentlyAudible(); - if (old_state != current_state) { - data->SetRecentlyAudible(current_state); - data->SetLastAudioChangeTime(NowTicks()); - } -} - void TabManager::ActiveTabChanged(content::WebContents* old_contents, content::WebContents* new_contents, int index, @@ -954,12 +588,6 @@ stats_collector_->RecordSwitchToTab(old_contents, new_contents); } - // Reload |web_contents| if it is in an active browser and discarded. - if (IsActiveWebContentsInActiveBrowser(new_contents)) { - ReloadWebContentsIfDiscarded(new_contents, - GetWebContentsData(new_contents)); - } - ResumeTabNavigationIfNeeded(new_contents); } @@ -980,36 +608,11 @@ GetTimeToPurge(min_time_to_purge_, max_time_to_purge_)); } -void TabManager::OnBrowserSetLastActive(Browser* browser) { - // Reload the active tab in |browser| if it is discarded. - content::WebContents* contents = - browser->tab_strip_model()->GetActiveWebContents(); - if (contents) - ReloadWebContentsIfDiscarded(contents, GetWebContentsData(contents)); -} - -bool TabManager::IsMediaTab(WebContents* contents) const { - if (contents->WasRecentlyAudible()) - return true; - - scoped_refptr<MediaStreamCaptureIndicator> media_indicator = - MediaCaptureDevicesDispatcher::GetInstance() - ->GetMediaStreamCaptureIndicator(); - if (media_indicator->IsCapturingUserMedia(contents) || - media_indicator->IsBeingMirrored(contents)) { - return true; - } - - auto last_audio_change_time = - GetWebContentsData(contents)->LastAudioChangeTime(); - - if (last_audio_change_time.is_null()) { - // The tab was never audible. - return false; - } - - auto delta = NowTicks() - last_audio_change_time; - return delta < TimeDelta::FromSeconds(kAudioProtectionTimeSeconds); +void TabManager::TabReplacedAt(TabStripModel* tab_strip_model, + content::WebContents* old_contents, + content::WebContents* new_contents, + int index) { + WebContentsData::CopyState(old_contents, new_contents); } // static @@ -1024,54 +627,21 @@ // discarding the entire set together, or use that in the priority computation. content::WebContents* TabManager::DiscardTabImpl(DiscardReason reason) { DCHECK_CURRENTLY_ON(BrowserThread::UI); - TabStatsList stats = GetTabStats(); - if (stats.empty()) - return nullptr; - // Loop until a non-discarded tab to kill is found. - for (TabStatsList::const_reverse_iterator stats_rit = stats.rbegin(); - stats_rit != stats.rend(); ++stats_rit) { - if (CanDiscardTab(*stats_rit, reason)) { - WebContents* new_contents = DiscardTabById(stats_rit->id, reason); - if (new_contents) - return new_contents; + for (LifecycleUnit* lifecycle_unit : GetSortedLifecycleUnits()) { + if (lifecycle_unit->CanDiscard(reason) && lifecycle_unit->Discard(reason)) { + TabLifecycleUnitExternal* tab_lifecycle_unit_external = + lifecycle_unit->AsTabLifecycleUnitExternal(); + // For now, all LifecycleUnits are TabLifecycleUnitExternals. + DCHECK(tab_lifecycle_unit_external); + + return tab_lifecycle_unit_external->GetWebContents(); } } + return nullptr; } -bool TabManager::IsActiveWebContentsInActiveBrowser( - content::WebContents* contents) const { - auto browser_info_list = GetBrowserInfoList(); - if (browser_info_list.empty()) - return false; - return browser_info_list.front().tab_strip_model->GetActiveWebContents() == - contents; -} - -std::vector<BrowserInfo> TabManager::GetBrowserInfoList() const { - if (!test_browser_info_list_.empty()) - return test_browser_info_list_; - - std::vector<BrowserInfo> browser_info_list; - - BrowserList* browser_list = BrowserList::GetInstance(); - for (auto browser_iterator = browser_list->begin_last_active(); - browser_iterator != browser_list->end_last_active(); - ++browser_iterator) { - Browser* browser = *browser_iterator; - - BrowserInfo browser_info; - browser_info.browser = browser; - browser_info.tab_strip_model = browser->tab_strip_model(); - browser_info.window_is_minimized = browser->window()->IsMinimized(); - browser_info.browser_is_app = browser->is_app(); - browser_info_list.push_back(browser_info); - } - - return browser_info_list; -} - void TabManager::OnSessionRestoreStartedLoadingTabs() { DCHECK(!is_session_restore_loading_tabs_); is_session_restore_loading_tabs_ = true; @@ -1217,7 +787,11 @@ DataAsTraceValue(background_tab_loading_mode_, pending_navigations_.size(), loading_contents_.size())); - force_load_timer_->Stop(); + if (force_load_timer_) + force_load_timer_->Stop(); + else + force_load_timer_ = std::make_unique<base::OneShotTimer>(GetTickClock()); + force_load_timer_->Start(FROM_HERE, GetTabLoadTimeout(kDefaultBackgroundTabLoadTimeout), this, &TabManager::LoadNextBackgroundTabIfNeeded); @@ -1227,7 +801,7 @@ TRACE_EVENT_INSTANT2( "navigation", "TabManager::LoadNextBackgroundTabIfNeeded", TRACE_EVENT_SCOPE_THREAD, "is_force_load_timer_running", - force_load_timer_->IsRunning(), "data", + IsForceLoadTimerRunning(), "data", DataAsTraceValue(background_tab_loading_mode_, pending_navigations_.size(), loading_contents_.size())); @@ -1237,14 +811,13 @@ // Do not load more background tabs until TabManager can load the next tab. // Ignore this constraint if the timer fires to force loading the next // background tab. - if (force_load_timer_->IsRunning() && !CanLoadNextTab()) + if (IsForceLoadTimerRunning() && !CanLoadNextTab()) return; if (pending_navigations_.empty()) return; - stats_collector_->OnWillLoadNextBackgroundTab( - !force_load_timer_->IsRunning()); + stats_collector_->OnWillLoadNextBackgroundTab(!IsForceLoadTimerRunning()); BackgroundTabNavigationThrottle* throttle = pending_navigations_.front(); pending_navigations_.erase(pending_navigations_.begin()); ResumeNavigation(throttle); @@ -1338,4 +911,19 @@ return false; } +bool TabManager::IsForceLoadTimerRunning() const { + return force_load_timer_ && force_load_timer_->IsRunning(); +} + +void TabManager::OnLifecycleUnitDestroyed(LifecycleUnit* lifecycle_unit) { + lifecycle_units_.erase(lifecycle_unit); +} + +void TabManager::OnLifecycleUnitCreated(LifecycleUnit* lifecycle_unit) { + lifecycle_units_.insert(lifecycle_unit); + + // Add an observer to be notified of destruction. + lifecycle_unit->AddObserver(this); +} + } // namespace resource_coordinator
diff --git a/chrome/browser/resource_coordinator/tab_manager.h b/chrome/browser/resource_coordinator/tab_manager.h index 7c50341..323a31e 100644 --- a/chrome/browser/resource_coordinator/tab_manager.h +++ b/chrome/browser/resource_coordinator/tab_manager.h
@@ -17,21 +17,20 @@ #include "base/macros.h" #include "base/memory/memory_pressure_listener.h" #include "base/memory/weak_ptr.h" -#include "base/observer_list.h" #include "base/strings/string16.h" #include "base/timer/timer.h" #include "build/build_config.h" #include "chrome/browser/resource_coordinator/discard_reason.h" +#include "chrome/browser/resource_coordinator/lifecycle_unit.h" +#include "chrome/browser/resource_coordinator/lifecycle_unit_observer.h" +#include "chrome/browser/resource_coordinator/lifecycle_unit_source_observer.h" #include "chrome/browser/resource_coordinator/tab_lifecycle_observer.h" -#include "chrome/browser/resource_coordinator/tab_stats.h" #include "chrome/browser/sessions/session_restore_observer.h" -#include "chrome/browser/ui/browser_list_observer.h" #include "chrome/browser/ui/browser_tab_strip_tracker.h" #include "chrome/browser/ui/tabs/tab_strip_model_observer.h" #include "content/public/browser/navigation_throttle.h" #include "ui/gfx/native_widget_types.h" -class BrowserList; class GURL; class TabStripModel; @@ -49,14 +48,6 @@ #endif class TabManagerStatsCollector; -// Information about a Browser. -struct BrowserInfo { - Browser* browser = nullptr; // Can be nullptr in tests. - TabStripModel* tab_strip_model = nullptr; - bool window_is_minimized = false; - bool browser_is_app = false; -}; - // The TabManager periodically updates (see // |kAdjustmentIntervalSeconds| in the source) the status of renderers // which are then used by the algorithm embedded here for priority in being @@ -82,7 +73,11 @@ // Tabs are identified by a unique ID vended by this component. These IDs are // not reused in a session. They are stable for a given conceptual tab, and will // follow it through discards, reloads, tab strip operations, etc. -class TabManager : public TabStripModelObserver, public BrowserListObserver { +// +// TODO(fdoray): Rename to LifecycleManager. https://crbug.com/775644 +class TabManager : public LifecycleUnitObserver, + public LifecycleUnitSourceObserver, + public TabStripModelObserver { public: // Forward declaration of resource coordinator signal observer. class ResourceCoordinatorSignalObserver; @@ -93,25 +88,18 @@ TabManager(); ~TabManager() override; - // Number of discard events since Chrome started. - int discard_count() const { return discard_count_; } - // Start/Stop the Tab Manager. void Start(); void Stop(); - // Returns the list of the stats for all renderers. Must be called on the UI - // thread. The returned list is sorted by reversed importance. - TabStatsList GetTabStats() const; + // Returns the LifecycleUnits managed by this, sorted from less to most + // important to the user. It is unsafe to access a pointer in the returned + // vector after a LifecycleUnit has been destroyed. + LifecycleUnitVector GetSortedLifecycleUnits(); // Returns true if |contents| is currently discarded. bool IsTabDiscarded(content::WebContents* contents) const; - // Goes through a list of checks to see if a tab is allowed to be discarded - // for |reason|. Note that this is not used when discarding a particular tab - // from about:discards or from an extension. - bool CanDiscardTab(const TabStats& tab_stats, DiscardReason reason) const; - // Discards a tab to free the memory occupied by its renderer. The tab still // exists in the tab-strip; clicking on it will reload it. If the |reason| is // urgent, an aggressive fast-kill will be attempted if the sudden termination @@ -123,7 +111,7 @@ // tab-strip; clicking on it will reload it. Returns null if the tab cannot // be found or cannot be discarded. Otherwise returns the new web_contents // of the discarded tab. - content::WebContents* DiscardTabById(int32_t tab_id, DiscardReason reason); + void DiscardTabById(int32_t tab_id, DiscardReason reason); // Freezes a tab with the given unique ID. Unlike discarding, freezing does // not kill or change the tab other than stopping its task queues. Revisiting @@ -144,16 +132,8 @@ // Log memory statistics for the running processes, then call the callback. void LogMemory(const std::string& title, const base::Closure& callback); - // Returns TabStats for all tabs in the current Chrome instance. The tabs are - // sorted first by most recently used to least recently used Browser and - // second by index in the Browser. |windows_sorted_by_z_index| is a list of - // Browser windows sorted by z-index, from topmost to bottommost. If left - // empty, no window occlusion checks will be performed. Must be called on the - // UI thread. - TabStatsList GetUnsortedTabStats( - const std::vector<gfx::NativeWindow>& windows_sorted_by_z_index = - std::vector<gfx::NativeWindow>()) const; - + // TODO(fdoray): Remove these methods. TabManager shouldn't know about tabs. + // https://crbug.com/775644 void AddObserver(TabLifecycleObserver* observer); void RemoveObserver(TabLifecycleObserver* observer); @@ -197,14 +177,6 @@ // needs to clean up data related to that tab. void OnWebContentsDestroyed(content::WebContents* contents); - // Returns true if |first| is considered less desirable to be killed than - // |second|. - static bool CompareTabStats(const TabStats& first, const TabStats& second); - - // Returns the unique ID associated with a tab given the |web_contents| - // currently backing that tab. - static int32_t IdFromWebContents(content::WebContents* web_contents); - // Return whether tabs are being loaded during session restore. bool IsSessionRestoreLoadingTabs() const { return is_session_restore_loading_tabs_; @@ -248,23 +220,16 @@ FRIEND_TEST_ALL_PREFIXES(TabManagerTest, AutoDiscardable); FRIEND_TEST_ALL_PREFIXES(TabManagerTest, CanOnlyDiscardOnce); FRIEND_TEST_ALL_PREFIXES(TabManagerTest, ChildProcessNotifications); - FRIEND_TEST_ALL_PREFIXES(TabManagerTest, Comparator); - FRIEND_TEST_ALL_PREFIXES(TabManagerTest, DiscardedTabKeepsLastActiveTime); - FRIEND_TEST_ALL_PREFIXES(TabManagerTest, DiscardWebContentsAt); FRIEND_TEST_ALL_PREFIXES(TabManagerTest, InvalidOrEmptyURL); FRIEND_TEST_ALL_PREFIXES(TabManagerTest, IsInternalPage); FRIEND_TEST_ALL_PREFIXES(TabManagerTest, OomPressureListener); FRIEND_TEST_ALL_PREFIXES(TabManagerTest, ProtectPDFPages); FRIEND_TEST_ALL_PREFIXES(TabManagerTest, ProtectRecentlyUsedTabs); FRIEND_TEST_ALL_PREFIXES(TabManagerTest, ProtectVideoTabs); - FRIEND_TEST_ALL_PREFIXES(TabManagerTest, ReloadDiscardedTabContextMenu); FRIEND_TEST_ALL_PREFIXES(TabManagerTest, TabManagerBasics); FRIEND_TEST_ALL_PREFIXES(TabManagerTest, TabManagerWasDiscarded); FRIEND_TEST_ALL_PREFIXES(TabManagerTest, TabManagerWasDiscardedCrossSiteSubFrame); - FRIEND_TEST_ALL_PREFIXES(TabManagerTest, - GetUnsortedTabStatsIsInVisibleWindow); - FRIEND_TEST_ALL_PREFIXES(TabManagerTest, DiscardTabWithNonVisibleTabs); FRIEND_TEST_ALL_PREFIXES(TabManagerTest, MaybeThrottleNavigation); FRIEND_TEST_ALL_PREFIXES(TabManagerTest, OnDidFinishNavigation); FRIEND_TEST_ALL_PREFIXES(TabManagerTest, OnTabIsLoaded); @@ -309,20 +274,6 @@ // min time to purge times this value. const int kDefaultMinMaxTimeToPurgeRatio = 4; - // Finds TabStripModel which has a WebContents whose id is the given - // |tab_id|, and returns the WebContents index and the TabStripModel. - int FindTabStripModelById(int32_t tab_id, TabStripModel** model) const; - - // Called by WebContentsData whenever the discard state of a WebContents - // changes, so that observers can be informed. - void OnDiscardedStateChange(content::WebContents* contents, - bool is_discarded); - - // Called by WebContentsData whenever the auto-discardable state of a - // WebContents changes, so that observers can be informed. - void OnAutoDiscardableStateChange(content::WebContents* contents, - bool is_auto_discardable); - static void PurgeMemoryAndDiscardTab(DiscardReason reason); // Returns true if the |url| represents an internal Chrome web UI page that @@ -332,22 +283,10 @@ // Purges data structures in the browser that can be easily recomputed. void PurgeBrowserMemory(); - // Adds all the stats of the tabs in |browser_info| into |stats_list|. - // |window_is_active| indicates whether |browser_info|'s window is active. - // |window_is_visible| indicates whether |browser_info|'s window might be - // visible (true when window visibility is unknown). - void AddTabStats(const BrowserInfo& browser_info, - bool window_is_active, - bool window_is_visible, - TabStatsList* stats_list) const; - // Callback for when |update_timer_| fires. Takes care of executing the tasks // that need to be run periodically (see comment in implementation). void UpdateTimerCallback(); - // Returns WebContents whose contents id matches the given |tab_id|. - content::WebContents* GetWebContentsById(int32_t tab_id) const; - // Returns a random time-to-purge whose min value is min_time_to_purge and max // value is max_time_to_purge. base::TimeDelta GetTimeToPurge(base::TimeDelta min_time_to_purge, @@ -368,13 +307,6 @@ // (=ActiveTabChanged is invoked). void PurgeBackgroundedTabsIfNeeded(); - // Does the actual discard by destroying the WebContents in |model| at |index| - // and replacing it by an empty one. Returns the new WebContents or NULL if - // the operation fails (return value used only in testing). - content::WebContents* DiscardWebContentsAt(int index, - TabStripModel* model, - DiscardReason reason); - // Makes a request to the WebContents at the specified index to freeze its // page. void FreezeWebContentsAt(int index, TabStripModel* model); @@ -389,9 +321,6 @@ base::MemoryPressureListener::MemoryPressureLevel memory_pressure_level); // TabStripModelObserver overrides. - void TabChangedAt(content::WebContents* contents, - int index, - TabChangeType change_type) override; void ActiveTabChanged(content::WebContents* old_contents, content::WebContents* new_contents, int index, @@ -400,32 +329,19 @@ content::WebContents* contents, int index, bool foreground) override; - - // BrowserListObserver overrides. - void OnBrowserSetLastActive(Browser* browser) override; - - // Returns true if the tab is currently playing audio or has played audio - // recently, or if the tab is currently accessing the camera, microphone or - // mirroring the display. - bool IsMediaTab(content::WebContents* contents) const; + void TabReplacedAt(TabStripModel* tab_strip_model, + content::WebContents* old_contents, + content::WebContents* new_contents, + int index) override; // Returns the WebContentsData associated with |contents|. Also takes care of // creating one if needed. static WebContentsData* GetWebContentsData(content::WebContents* contents); - // Implementation of DiscardTab. Returns null if no tab was discarded. - // Otherwise returns the new web_contents of the discarded tab. + // Discards the less important LifecycleUnit that supports discarding under + // |reason|. content::WebContents* DiscardTabImpl(DiscardReason reason); - // Returns true if |web_contents| is the active WebContents in the last active - // Browser. - bool IsActiveWebContentsInActiveBrowser(content::WebContents* contents) const; - - // Returns a list of BrowserInfo constructed from either - // |test_browser_info_list_| or BrowserList. The first BrowserInfo in the list - // corresponds to the last active Browser. - std::vector<BrowserInfo> GetBrowserInfoList() const; - void OnSessionRestoreStartedLoadingTabs(); void OnSessionRestoreFinishedLoadingTabs(); void OnWillRestoreTab(content::WebContents* contents); @@ -492,15 +408,24 @@ TabManagerStatsCollector* stats_collector() { return stats_collector_.get(); } + // Returns true if the background tab force load timer is running. + bool IsForceLoadTimerRunning() const; + + // LifecycleUnitObserver: + void OnLifecycleUnitDestroyed(LifecycleUnit* lifecycle_unit) override; + + // LifecycleUnitSourceObserver: + void OnLifecycleUnitCreated(LifecycleUnit* lifecycle_unit) override; + + // LifecycleUnits managed by this. + LifecycleUnitSet lifecycle_units_; + // Timer to periodically update the stats of the renderers. base::RepeatingTimer update_timer_; // A listener to global memory pressure events. std::unique_ptr<base::MemoryPressureListener> memory_pressure_listener_; - // Number of times a tab has been discarded, for statistics. - int discard_count_; - // A backgrounded renderer will be purged between min_time_to_purge_ and // max_time_to_purge_. base::TimeDelta min_time_to_purge_; @@ -514,18 +439,6 @@ // TabStripModels. Automatically tracks browsers as they come and go. BrowserTabStripTracker browser_tab_strip_tracker_; - // Injected BrowserInfo list. Allows this to be tested end-to-end without - // requiring a full browser environment. If specified these BrowserInfo will - // be crawled as the authoritative source of tabs, otherwise the BrowserList - // and associated Browser objects are crawled. The first BrowserInfo in the - // list corresponds to the last active Browser. - // TODO(chrisha): Factor out tab-strip model enumeration to a helper class, - // and make a delegate that centralizes all testing seams. - std::vector<BrowserInfo> test_browser_info_list_; - - // List of observers that will receive notifications on state changes. - base::ObserverList<TabLifecycleObserver> observers_; - bool is_session_restore_loading_tabs_; size_t restored_tab_count_;
diff --git a/chrome/browser/resource_coordinator/tab_manager_browsertest.cc b/chrome/browser/resource_coordinator/tab_manager_browsertest.cc index 2adf65a..960fd945 100644 --- a/chrome/browser/resource_coordinator/tab_manager_browsertest.cc +++ b/chrome/browser/resource_coordinator/tab_manager_browsertest.cc
@@ -12,6 +12,7 @@ #include "chrome/browser/browser_process.h" #include "chrome/browser/media/webrtc/media_capture_devices_dispatcher.h" #include "chrome/browser/media/webrtc/media_stream_capture_indicator.h" +#include "chrome/browser/resource_coordinator/tab_lifecycle_unit_external.h" #include "chrome/browser/resource_coordinator/tab_manager.h" #include "chrome/browser/resource_coordinator/tab_manager_web_contents_data.h" #include "chrome/browser/resource_coordinator/time.h" @@ -48,11 +49,16 @@ namespace { -static constexpr char kBlinkPageLifecycleFeature[] = "PageLifecycle"; +constexpr char kBlinkPageLifecycleFeature[] = "PageLifecycle"; +constexpr base::TimeDelta kShortDelay = base::TimeDelta::FromSeconds(1); class TabManagerTest : public InProcessBrowserTest { public: - TabManagerTest() : scoped_set_tick_clock_for_testing_(&test_clock_) {} + TabManagerTest() : scoped_set_tick_clock_for_testing_(&test_clock_) { + // Start with a non-null TimeTicks, as there is no discard protection for + // a tab with a null focused timestamp. + test_clock_.Advance(kShortDelay); + } void SetUpCommandLine(base::CommandLine* command_line) override { command_line->AppendSwitchASCII(switches::kEnableBlinkFeatures, @@ -111,6 +117,8 @@ TabManager* tab_manager = g_browser_process->GetTabManager(); // Get three tabs open. + + test_clock_.Advance(kShortDelay); WindowedNotificationObserver load1( content::NOTIFICATION_NAV_ENTRY_COMMITTED, content::NotificationService::AllSources()); @@ -120,6 +128,7 @@ browser()->OpenURL(open1); load1.Wait(); + test_clock_.Advance(kShortDelay); WindowedNotificationObserver load2( content::NOTIFICATION_NAV_ENTRY_COMMITTED, content::NotificationService::AllSources()); @@ -129,6 +138,7 @@ browser()->OpenURL(open2); load2.Wait(); + test_clock_.Advance(kShortDelay); WindowedNotificationObserver load3( content::NOTIFICATION_NAV_ENTRY_COMMITTED, content::NotificationService::AllSources()); @@ -190,9 +200,11 @@ // Kill the third tab after making second tab active. tsm->ActivateTabAt(1, true); + EXPECT_EQ(1, tsm->active_index()); EXPECT_FALSE(tab_manager->IsTabDiscarded(tsm->GetWebContentsAt(1))); - tab_manager->DiscardWebContentsAt(2, tsm, DiscardReason::kProactive); + FastForwardAfterDiscardProtectionTime(); + tab_manager->DiscardTabImpl(DiscardReason::kProactive); EXPECT_TRUE(tab_manager->IsTabDiscarded(tsm->GetWebContentsAt(2))); // Force creation of the FindBarController. @@ -797,6 +809,8 @@ "TabManager.Discarding.DiscardedTabCouldFastShutdown", false, 1); } +// TODO(fdoray): Move this test to |tab_lifecyle_unit_unittest.cc|. +// https://crbug.com/775644 IN_PROC_BROWSER_TEST_F(TabManagerTest, FreezeTab) { const char kMainFrameFrozenStateJS[] = "window.domAutomationController.send(mainFrameFreezeCount);"; @@ -862,8 +876,7 @@ EXPECT_EQ(0, freeze_count_result); // Freeze the tab. If it fails then we might be freezing a visible tab. - g_browser_process->GetTabManager()->FreezeWebContentsAt( - freezing_index, browser()->tab_strip_model()); + TabLifecycleUnitExternal::FromWebContents(content)->FreezeTab(); // freeze_count_result should be exactly 1 for both frames. The valus is // incremented in the onfreeze callback. If it is >1, then the callback was @@ -893,8 +906,9 @@ EXPECT_FALSE(not_discarded_result); // Discard the tab. This simulates a tab discard. - g_browser_process->GetTabManager()->DiscardWebContentsAt( - 0, browser()->tab_strip_model(), DiscardReason::kProactive); + TabLifecycleUnitExternal::FromWebContents( + browser()->tab_strip_model()->GetActiveWebContents()) + ->DiscardTab(); // Here we simulate re-focussing the tab causing reload with navigation, // the navigation will reload the tab. @@ -950,8 +964,7 @@ EXPECT_FALSE(before_discard_childframe_result); // Discard the tab. This simulates a tab discard. - g_browser_process->GetTabManager()->DiscardWebContentsAt( - 0, browser()->tab_strip_model(), DiscardReason::kProactive); + TabLifecycleUnitExternal::FromWebContents(contents)->DiscardTab(); // Here we simulate re-focussing the tab causing reload with navigation, // the navigation will reload the tab.
diff --git a/chrome/browser/resource_coordinator/tab_manager_delegate_chromeos.cc b/chrome/browser/resource_coordinator/tab_manager_delegate_chromeos.cc index 5ee78b6..827dfcc 100644 --- a/chrome/browser/resource_coordinator/tab_manager_delegate_chromeos.cc +++ b/chrome/browser/resource_coordinator/tab_manager_delegate_chromeos.cc
@@ -12,7 +12,6 @@ #include <vector> #include "ash/shell.h" -#include "base/barrier_closure.h" #include "base/bind.h" #include "base/command_line.h" #include "base/files/file_path.h" @@ -29,11 +28,10 @@ #include "chrome/browser/chromeos/arc/process/arc_process.h" #include "chrome/browser/chromeos/arc/process/arc_process_service.h" #include "chrome/browser/memory/memory_kills_monitor.h" -#include "chrome/browser/resource_coordinator/tab_stats.h" +#include "chrome/browser/resource_coordinator/tab_lifecycle_unit_external.h" #include "chrome/browser/ui/browser.h" #include "chrome/browser/ui/browser_list.h" #include "chrome/browser/ui/browser_window.h" -#include "chrome/browser/ui/sort_windows_by_z_index.h" #include "chrome/browser/ui/tabs/tab_strip_model.h" #include "chrome/common/chrome_constants.h" #include "chrome/common/chrome_features.h" @@ -49,7 +47,6 @@ #include "content/public/browser/render_process_host.h" #include "content/public/browser/render_widget_host.h" #include "content/public/browser/zygote_host_linux.h" -#include "ui/gfx/native_widget_types.h" #include "ui/wm/public/activation_client.h" using base::ProcessHandle; @@ -84,81 +81,6 @@ LOG(WARNING) << "Set OOM score: " << output; } -using LoadTabListAndArcProcessesCallback = - base::OnceCallback<void(const TabStatsList&, - const std::vector<arc::ArcProcess>&)>; - -// Loads TabStatsList and a list of ARC processes. Invokes |callback| with the -// result. -void LoadTabListAndArcProcesses(base::WeakPtr<TabManager> tab_manager, - LoadTabListAndArcProcessesCallback callback) { - std::unique_ptr<TabStatsList> tab_stats_list = - std::make_unique<TabStatsList>(); - TabStatsList* const tab_stats_list_raw = tab_stats_list.get(); - - std::unique_ptr<std::vector<arc::ArcProcess>> arc_processes = - std::make_unique<std::vector<arc::ArcProcess>>(); - std::vector<arc::ArcProcess>* const arc_processes_raw = arc_processes.get(); - - // Invoked when the TabStatsList is loaded and when the list of ARC processes - // is loaded. Invokes |callback| the second time it's called (i.e. when both - // the lists have been loaded). - auto barrier = base::BarrierClosure( - 2, base::BindOnce( - [](std::unique_ptr<TabStatsList> tab_stats_list, - std::unique_ptr<std::vector<arc::ArcProcess>> arc_processes, - LoadTabListAndArcProcessesCallback callback) { - std::move(callback).Run(*tab_stats_list.get(), - *arc_processes.get()); - }, - std::move(tab_stats_list), std::move(arc_processes), - std::move(callback))); - - // Invoked when the list of browser windows sorted by z-index is loaded. - auto sort_windows_by_z_index_callback = base::BindOnce( - [](TabStatsList* tab_stats_list, base::WeakPtr<TabManager> tab_manager, - base::RepeatingClosure barrier, - std::vector<gfx::NativeWindow> windows_sorted_by_z_index) { - if (tab_manager) { - *tab_stats_list = - tab_manager->GetUnsortedTabStats(windows_sorted_by_z_index); - } - barrier.Run(); - }, - base::Unretained(tab_stats_list_raw), tab_manager, barrier); - - // Start loading the list of browser windows sorted by z-index. - std::vector<gfx::NativeWindow> browser_windows; - for (Browser* browser : *BrowserList::GetInstance()) - browser_windows.push_back(browser->window()->GetNativeWindow()); - // In unit tests, windows can't be sorted because the Shell is not available. - if (ash::Shell::HasInstance()) { - ui::SortWindowsByZIndex(browser_windows, - std::move(sort_windows_by_z_index_callback)); - } else { - std::move(sort_windows_by_z_index_callback) - .Run(std::vector<gfx::NativeWindow>()); - } - - // Invoked when the list of ARC processes is loaded. - auto request_app_process_list_callback = base::BindRepeating( - [](std::vector<arc::ArcProcess>* arc_processes_dest, - base::RepeatingClosure barrier, - std::vector<arc::ArcProcess> arc_processes_src) { - *arc_processes_dest = std::move(arc_processes_src); - barrier.Run(); - }, - base::Unretained(arc_processes_raw), barrier); - - // Start loading the list of ARC processes. - arc::ArcProcessService* arc_process_service = arc::ArcProcessService::Get(); - - if (!arc_process_service || !arc_process_service->RequestAppProcessList( - request_app_process_list_callback)) { - request_app_process_list_callback.Run(std::vector<arc::ArcProcess>()); - } -} - } // namespace // static @@ -172,10 +94,12 @@ return os << "FOCUSED_APP"; case ProcessType::IMPORTANT_APP: return os << "IMPORTANT_APP"; - case ProcessType::BACKGROUND_TAB: - return os << "BACKGROUND_TAB"; case ProcessType::BACKGROUND_APP: return os << "BACKGROUND_APP"; + case ProcessType::BACKGROUND_TAB: + return os << "BACKGROUND_TAB"; + case ProcessType::PROTECTED_BACKGROUND_TAB: + return os << "PROTECTED_BACKGROUND_TAB"; case ProcessType::UNKNOWN_TYPE: return os << "UNKNOWN_TYPE"; default: @@ -187,27 +111,16 @@ // TabManagerDelegate::Candidate implementation. std::ostream& operator<<(std::ostream& out, const TabManagerDelegate::Candidate& candidate) { - if (candidate.app()) { + if (candidate.app()) out << "app " << *candidate.app(); - } else if (candidate.tab()) { - const TabStats* const& tab = candidate.tab(); - out << "tab " << tab->title << ", renderer_handle: " << tab->renderer_handle - << ", oom_score: " << tab->oom_score - << ", is_discarded: " << tab->is_discarded - << ", discard_count: " << tab->discard_count - << ", last_active: " << tab->last_active; - } + else if (candidate.lifecycle_unit()) + out << "tab " << candidate.lifecycle_unit()->GetTitle(); out << ", process_type " << candidate.process_type(); return out; } TabManagerDelegate::Candidate& TabManagerDelegate::Candidate::operator=( - TabManagerDelegate::Candidate&& other) { - tab_ = other.tab_; - app_ = other.app_; - process_type_ = other.process_type_; - return *this; -} + TabManagerDelegate::Candidate&& other) = default; bool TabManagerDelegate::Candidate::operator<( const TabManagerDelegate::Candidate& rhs) const { @@ -215,8 +128,8 @@ return process_type() < rhs.process_type(); if (app() && rhs.app()) return *app() < *rhs.app(); - if (tab() && rhs.tab()) - return TabManager::CompareTabStats(*tab(), *rhs.tab()); + if (lifecycle_unit() && rhs.lifecycle_unit()) + return lifecycle_unit_sort_key_ > rhs.lifecycle_unit_sort_key_; // Impossible case. If app and tab are mixed in one process type, favor // apps. NOTREACHED() << "Undefined comparison between apps and tabs: process_type=" @@ -232,9 +145,11 @@ return ProcessType::IMPORTANT_APP; return ProcessType::BACKGROUND_APP; } - if (tab()) { - if (tab()->is_active && tab()->is_in_active_window) + if (lifecycle_unit()) { + if (lifecycle_unit_sort_key_.last_focused_time == base::TimeTicks::Max()) return ProcessType::FOCUSED_TAB; + if (!lifecycle_unit()->CanDiscard(DiscardReason::kProactive)) + return ProcessType::PROTECTED_BACKGROUND_TAB; return ProcessType::BACKGROUND_TAB; } NOTREACHED() << "Unexpected process type"; @@ -416,17 +331,21 @@ void TabManagerDelegate::ScheduleEarlyOomPrioritiesAdjustment() { DCHECK_CURRENTLY_ON(BrowserThread::UI); - if (tab_manager_) { - AdjustOomPriorities(tab_manager_->GetUnsortedTabStats()); - } + AdjustOomPriorities(); } // If able to get the list of ARC procsses, prioritize tabs and apps as a whole. // Otherwise try to kill tabs only. void TabManagerDelegate::LowMemoryKill(DiscardReason reason) { - LoadTabListAndArcProcesses( - tab_manager_, base::BindOnce(&TabManagerDelegate::LowMemoryKillImpl, - weak_ptr_factory_.GetWeakPtr(), reason)); + arc::ArcProcessService* arc_process_service = arc::ArcProcessService::Get(); + if (arc_process_service && + arc_process_service->RequestAppProcessList( + base::BindRepeating(&TabManagerDelegate::LowMemoryKillImpl, + weak_ptr_factory_.GetWeakPtr(), reason))) { + return; + } + + LowMemoryKillImpl(reason, std::vector<arc::ArcProcess>()); } int TabManagerDelegate::GetCachedOomScore(ProcessHandle process_handle) { @@ -439,6 +358,12 @@ return -1001; } +LifecycleUnitVector TabManagerDelegate::GetLifecycleUnits() { + if (tab_manager_) + return tab_manager_->GetSortedLifecycleUnits(); + return LifecycleUnitVector(); +} + void TabManagerDelegate::OnFocusTabScoreAdjustmentTimeout() { DCHECK_CURRENTLY_ON(BrowserThread::UI); base::ProcessHandle pid = focused_process_->GetTabPid(); @@ -545,18 +470,18 @@ // 1) whether or not a tab is pinned // 2) last time a tab was selected // 3) is the tab currently selected -void TabManagerDelegate::AdjustOomPriorities(const TabStatsList& tab_list) { +void TabManagerDelegate::AdjustOomPriorities() { if (IsArcMemoryManagementEnabled()) { arc::ArcProcessService* arc_process_service = arc::ArcProcessService::Get(); if (arc_process_service && arc_process_service->RequestAppProcessList( base::Bind(&TabManagerDelegate::AdjustOomPrioritiesImpl, - weak_ptr_factory_.GetWeakPtr(), tab_list))) { + weak_ptr_factory_.GetWeakPtr()))) { return; } } // Pass in a dummy list if unable to get ARC processes. - AdjustOomPrioritiesImpl(tab_list, std::vector<arc::ArcProcess>()); + AdjustOomPrioritiesImpl(std::vector<arc::ArcProcess>()); } // Excludes persistent ARC apps, but still preserves active chrome tabs and @@ -565,13 +490,13 @@ // static std::vector<TabManagerDelegate::Candidate> TabManagerDelegate::GetSortedCandidates( - const TabStatsList& tab_list, + const LifecycleUnitVector& lifecycle_units, const std::vector<arc::ArcProcess>& arc_processes) { std::vector<Candidate> candidates; - candidates.reserve(tab_list.size() + arc_processes.size()); + candidates.reserve(lifecycle_units.size() + arc_processes.size()); - for (const auto& tab : tab_list) { - candidates.emplace_back(&tab); + for (LifecycleUnit* lifecycle_unit : lifecycle_units) { + candidates.emplace_back(lifecycle_unit); } for (const auto& app : arc_processes) { @@ -607,11 +532,9 @@ return true; } -bool TabManagerDelegate::KillTab(const TabStats& tab_stats, +bool TabManagerDelegate::KillTab(LifecycleUnit* lifecycle_unit, DiscardReason reason) { - // Check |tab_manager_| is alive before taking tabs into consideration. - return tab_manager_ && tab_manager_->CanDiscardTab(tab_stats, reason) && - tab_manager_->DiscardTabById(tab_stats.id, reason); + return lifecycle_unit->CanDiscard(reason) && lifecycle_unit->Discard(reason); } chromeos::DebugDaemonClient* TabManagerDelegate::GetDebugDaemonClient() { @@ -620,13 +543,12 @@ void TabManagerDelegate::LowMemoryKillImpl( DiscardReason reason, - const TabStatsList& tab_list, - const std::vector<arc::ArcProcess>& arc_processes) { + std::vector<arc::ArcProcess> arc_processes) { DCHECK_CURRENTLY_ON(content::BrowserThread::UI); VLOG(2) << "LowMemoryKillImpl"; - const std::vector<TabManagerDelegate::Candidate> candidates = - GetSortedCandidates(tab_list, arc_processes); + std::vector<TabManagerDelegate::Candidate> candidates = + GetSortedCandidates(GetLifecycleUnits(), arc_processes); // TODO(semenzato): decide if TargetMemoryToFreeKB is doing real // I/O and if it is, move to I/O thread (crbug.com/778703). @@ -659,9 +581,9 @@ if (process_type <= ProcessType::IMPORTANT_APP) { if (it->app()) { MEMORY_LOG(ERROR) << "Skipped killing " << it->app()->process_name(); - } else if (it->tab()) { - MEMORY_LOG(ERROR) << "Skipped killing " << it->tab()->title << " (" - << it->tab()->renderer_handle << ")"; + } else if (it->lifecycle_unit()) { + MEMORY_LOG(ERROR) << "Skipped killing " + << it->lifecycle_unit()->GetTitle(); } continue; } @@ -685,19 +607,19 @@ } else { MEMORY_LOG(ERROR) << "Failed to kill " << it->app()->process_name(); } - } else if (it->tab()) { + } else if (it->lifecycle_unit()) { // The estimation is problematic since multiple tabs may share the same // process, while the calculation counts memory used by the whole process. // So |estimated_memory_freed_kb| is an over-estimation. int estimated_memory_freed_kb = - mem_stat_->EstimatedMemoryFreedKB(it->tab()->renderer_handle); - if (KillTab(*it->tab(), reason)) { + it->lifecycle_unit()->GetEstimatedMemoryFreedOnDiscardKB(); + if (KillTab(it->lifecycle_unit(), reason)) { target_memory_to_free_kb -= estimated_memory_freed_kb; memory::MemoryKillsMonitor::LogLowMemoryKill("TAB", estimated_memory_freed_kb); - MEMORY_LOG(ERROR) << "Killed tab " << it->tab()->title << " (" - << it->tab()->renderer_handle << "), estimated " - << estimated_memory_freed_kb << " KB freed"; + MEMORY_LOG(ERROR) << "Killed tab " << it->lifecycle_unit()->GetTitle() + << ", estimated " << estimated_memory_freed_kb + << " KB freed"; } } } @@ -708,13 +630,14 @@ } void TabManagerDelegate::AdjustOomPrioritiesImpl( - const TabStatsList& tab_list, std::vector<arc::ArcProcess> arc_processes) { std::vector<TabManagerDelegate::Candidate> candidates; std::vector<TabManagerDelegate::Candidate> apps_non_killable; // Least important first. - auto all_candidates = GetSortedCandidates(tab_list, arc_processes); + LifecycleUnitVector lifecycle_units = GetLifecycleUnits(); + auto all_candidates = + GetSortedCandidates(std::move(lifecycle_units), arc_processes); for (auto& candidate : all_candidates) { // TODO(cylee|yusukes): Consider using IsImportant() instead of // IsKernelKillable() for simplicity. @@ -757,8 +680,8 @@ ProcessScoreMap new_map; // Make the apps non-killable. - if (!apps_non_killable.empty()) - SetOomScore(apps_non_killable, kLowestOomScore, &new_map); + DistributeOomScoreInRange(apps_non_killable.begin(), apps_non_killable.end(), + kLowestOomScore, kLowestOomScore, &new_map); // Higher priority part. DistributeOomScoreInRange(candidates.begin(), lower_priority_part, @@ -771,17 +694,9 @@ oom_score_map_.swap(new_map); } -void TabManagerDelegate::SetOomScore( - const std::vector<TabManagerDelegate::Candidate>& candidates, - int score, - ProcessScoreMap* new_map) { - DistributeOomScoreInRange(candidates.begin(), candidates.end(), score, score, - new_map); -} - void TabManagerDelegate::DistributeOomScoreInRange( - std::vector<TabManagerDelegate::Candidate>::const_iterator begin, - std::vector<TabManagerDelegate::Candidate>::const_iterator end, + std::vector<TabManagerDelegate::Candidate>::iterator begin, + std::vector<TabManagerDelegate::Candidate>::iterator end, int range_begin, int range_end, ProcessScoreMap* new_map) { @@ -804,7 +719,7 @@ if (cur->app()) { pid = cur->app()->pid(); } else { - pid = cur->tab()->renderer_handle; + pid = cur->lifecycle_unit()->GetProcessHandle(); // 1. tab_list contains entries for already-discarded tabs. If the PID // (renderer_handle) is zero, we don't need to adjust the oom_score. // 2. Only add unseen process handle so if there's multiple tab maps to
diff --git a/chrome/browser/resource_coordinator/tab_manager_delegate_chromeos.h b/chrome/browser/resource_coordinator/tab_manager_delegate_chromeos.h index b2bd5c16..be0836f 100644 --- a/chrome/browser/resource_coordinator/tab_manager_delegate_chromeos.h +++ b/chrome/browser/resource_coordinator/tab_manager_delegate_chromeos.h
@@ -18,8 +18,8 @@ #include "base/process/process.h" #include "base/timer/timer.h" #include "chrome/browser/chromeos/arc/process/arc_process.h" +#include "chrome/browser/resource_coordinator/lifecycle_unit.h" #include "chrome/browser/resource_coordinator/tab_manager.h" -#include "chrome/browser/resource_coordinator/tab_stats.h" #include "chrome/browser/ui/browser_list_observer.h" #include "chromeos/dbus/debug_daemon_client.h" #include "components/arc/common/process.mojom.h" @@ -46,8 +46,9 @@ IMPORTANT_APP = 3, BACKGROUND_APP = 4, - BACKGROUND_TAB = 5, - UNKNOWN_TYPE = 6, + PROTECTED_BACKGROUND_TAB = 5, + BACKGROUND_TAB = 6, + UNKNOWN_TYPE = 7, }; // The Chrome OS TabManagerDelegate is responsible for keeping the @@ -81,7 +82,7 @@ int GetCachedOomScore(base::ProcessHandle process_handle); // Called when the timer fires, sets oom_adjust_score for all renderers. - void AdjustOomPriorities(const TabStatsList& tab_list); + void AdjustOomPriorities(); // Returns true if the process has recently been killed. // Virtual for unit testing. @@ -95,7 +96,7 @@ // Kills a tab. Returns true if the tab is killed successfully. // Virtual for unit testing. - virtual bool KillTab(const TabStats& tab_stats, DiscardReason reason); + virtual bool KillTab(LifecycleUnit* lifecycle_unit, DiscardReason reason); // Get debugd client instance. Virtual for unit testing. virtual chromeos::DebugDaemonClient* GetDebugDaemonClient(); @@ -132,44 +133,35 @@ // Get the list of candidates to kill, sorted by descending importance. static std::vector<Candidate> GetSortedCandidates( - const TabStatsList& tab_list, + const LifecycleUnitVector& lifecycle_units, const std::vector<arc::ArcProcess>& arc_processes); + // Returns the LifecycleUnits in TabManager. Virtual for unit tests. + virtual LifecycleUnitVector GetLifecycleUnits(); + // Sets OOM score for the focused tab. void OnFocusTabScoreAdjustmentTimeout(); // Kills a process after getting all info of tabs and apps. void LowMemoryKillImpl(DiscardReason reason, - const TabStatsList& tab_list, - const std::vector<arc::ArcProcess>& arc_processes); - - // Public interface to adjust OOM scores. - void AdjustOomPriorities(const TabStatsList& tab_list, - const std::vector<arc::ArcProcess>& arc_processes); + std::vector<arc::ArcProcess> arc_processes); // Sets a newly focused tab the highest priority process if it wasn't. void AdjustFocusedTabScore(base::ProcessHandle pid); // Called by AdjustOomPriorities. Runs on the main thread. - void AdjustOomPrioritiesImpl(const TabStatsList& tab_list, - std::vector<arc::ArcProcess> arc_processes); + void AdjustOomPrioritiesImpl(std::vector<arc::ArcProcess> arc_processes); // Sets OOM score for processes in the range [|rbegin|, |rend|) to integers // distributed evenly in [|range_begin|, |range_end|). // The new score is set in |new_map|. void DistributeOomScoreInRange( - std::vector<TabManagerDelegate::Candidate>::const_iterator begin, - std::vector<TabManagerDelegate::Candidate>::const_iterator end, + std::vector<TabManagerDelegate::Candidate>::iterator begin, + std::vector<TabManagerDelegate::Candidate>::iterator end, int range_begin, int range_end, ProcessScoreMap* new_map); - // Changes |candidates|' OOM scores to |score|. The new scores are set in - // |new_map|. - void SetOomScore(const std::vector<TabManagerDelegate::Candidate>& candidates, - int score, - ProcessScoreMap* new_map); - // Initiates an oom priority adjustment. void ScheduleEarlyOomPrioritiesAdjustment(); @@ -218,14 +210,12 @@ // victims. class TabManagerDelegate::Candidate { public: - explicit Candidate(const TabStats* tab) - : tab_(tab), app_(nullptr), process_type_(GetProcessTypeInternal()) { - DCHECK(tab_); + explicit Candidate(LifecycleUnit* lifecycle_unit) + : lifecycle_unit_(lifecycle_unit), + lifecycle_unit_sort_key_(lifecycle_unit_->GetSortKey()) { + DCHECK(lifecycle_unit_); } - explicit Candidate(const arc::ArcProcess* app) - : tab_(nullptr), app_(app), process_type_(GetProcessTypeInternal()) { - DCHECK(app_); - } + explicit Candidate(const arc::ArcProcess* app) : app_(app) { DCHECK(app_); } // Move-only class. Candidate(Candidate&&) = default; @@ -234,7 +224,8 @@ // Higher priority first. bool operator<(const Candidate& rhs) const; - const TabStats* tab() const { return tab_; } + LifecycleUnit* lifecycle_unit() { return lifecycle_unit_; } + const LifecycleUnit* lifecycle_unit() const { return lifecycle_unit_; } const arc::ArcProcess* app() const { return app_; } ProcessType process_type() const { return process_type_; } @@ -242,9 +233,10 @@ // Derive process type for this candidate. Used to initialize |process_type_|. ProcessType GetProcessTypeInternal() const; - const TabStats* tab_; - const arc::ArcProcess* app_; - ProcessType process_type_; + LifecycleUnit* lifecycle_unit_ = nullptr; + LifecycleUnit::SortKey lifecycle_unit_sort_key_; + const arc::ArcProcess* app_ = nullptr; + ProcessType process_type_ = GetProcessTypeInternal(); DISALLOW_COPY_AND_ASSIGN(Candidate); };
diff --git a/chrome/browser/resource_coordinator/tab_manager_delegate_chromeos_unittest.cc b/chrome/browser/resource_coordinator/tab_manager_delegate_chromeos_unittest.cc index d764a3b5..efa9ade 100644 --- a/chrome/browser/resource_coordinator/tab_manager_delegate_chromeos_unittest.cc +++ b/chrome/browser/resource_coordinator/tab_manager_delegate_chromeos_unittest.cc
@@ -9,13 +9,16 @@ #include <utility> #include <vector> +#include "base/macros.h" #include "base/process/process_handle.h" +#include "chrome/browser/resource_coordinator/lifecycle_unit_base.h" #include "chrome/browser/resource_coordinator/time.h" #include "chromeos/dbus/fake_debug_daemon_client.h" #include "content/public/test/test_browser_thread_bundle.h" #include "testing/gtest/include/gtest/gtest.h" namespace resource_coordinator { +namespace { class TabManagerDelegateTest : public testing::Test { public: @@ -26,9 +29,44 @@ content::TestBrowserThreadBundle thread_bundle_; }; -namespace { +class DummyLifecycleUnit : public LifecycleUnitBase { + public: + explicit DummyLifecycleUnit( + base::TimeTicks last_focused_time, + base::ProcessHandle process_handle = base::ProcessHandle(), + bool can_discard = true) + : last_focused_time_(last_focused_time), + process_handle_(process_handle), + can_discard_(can_discard) {} + + // LifecycleUnit: + base::string16 GetTitle() const override { return base::string16(); } + std::string GetIconURL() const override { return std::string(); } + base::ProcessHandle GetProcessHandle() const override { + return process_handle_; + } + TabLifecycleUnitExternal* AsTabLifecycleUnitExternal() override { + return nullptr; + } + SortKey GetSortKey() const override { return SortKey(last_focused_time_); } + State GetState() const override { return State::LOADED; } + bool Freeze() override { return false; } + int GetEstimatedMemoryFreedOnDiscardKB() const override { return 0; } + bool CanPurge() const override { return false; } + bool CanDiscard(DiscardReason reason) const override { return can_discard_; } + bool Discard(DiscardReason discard_reason) override { return false; } + + private: + base::TimeTicks last_focused_time_; + base::ProcessHandle process_handle_; + bool can_discard_; + + DISALLOW_COPY_AND_ASSIGN(DummyLifecycleUnit); +}; + constexpr bool kIsFocused = true; constexpr bool kNotFocused = false; + } // namespace TEST_F(TabManagerDelegateTest, CandidatesSorted) { @@ -42,56 +80,42 @@ arc_processes.emplace_back(4, 40, "visible2", arc::mojom::ProcessState::TOP, kNotFocused, 150); - TabStats tab1, tab2, tab3, tab4, tab5; - tab1.id = 100; - tab1.is_pinned = true; - - tab2.id = 200; - tab2.is_internal_page = true; - - tab3.id = 300; - tab3.is_pinned = true; - tab3.is_media = true; - - tab4.id = 400; - tab4.is_media = true; - - tab5.id = 500; - tab5.is_app = true; - TabStatsList tab_list = {tab1, tab2, tab3, tab4, tab5}; + DummyLifecycleUnit focused_lifecycle_unit(base::TimeTicks::Max()); + DummyLifecycleUnit protected_lifecycle_unit( + base::TimeTicks() + base::TimeDelta::FromSeconds(5), 0, false); + DummyLifecycleUnit non_focused_lifecycle_unit( + base::TimeTicks() + base::TimeDelta::FromSeconds(1)); + DummyLifecycleUnit other_non_focused_lifecycle_unit( + base::TimeTicks() + base::TimeDelta::FromSeconds(2)); + LifecycleUnitVector lifecycle_units{ + &focused_lifecycle_unit, &protected_lifecycle_unit, + &non_focused_lifecycle_unit, &other_non_focused_lifecycle_unit}; std::vector<TabManagerDelegate::Candidate> candidates; - candidates = TabManagerDelegate::GetSortedCandidates(tab_list, arc_processes); - ASSERT_EQ(9U, candidates.size()); + candidates = + TabManagerDelegate::GetSortedCandidates(lifecycle_units, arc_processes); + ASSERT_EQ(8U, candidates.size()); + // focused LifecycleUnit + EXPECT_EQ(candidates[0].lifecycle_unit(), &focused_lifecycle_unit); // focused app. - ASSERT_TRUE(candidates[0].app()); - EXPECT_EQ("focused", candidates[0].app()->process_name()); - // visible app 1, last_activity_time larger than visible app 2. ASSERT_TRUE(candidates[1].app()); - EXPECT_EQ("visible1", candidates[1].app()->process_name()); - // visible app 2, last_activity_time less than visible app 1. + EXPECT_EQ("focused", candidates[1].app()->process_name()); + // visible app 1, last_activity_time larger than visible app 2. ASSERT_TRUE(candidates[2].app()); - EXPECT_EQ("visible2", candidates[2].app()->process_name()); - // background service. + EXPECT_EQ("visible1", candidates[2].app()->process_name()); + // visible app 2, last_activity_time less than visible app 1. ASSERT_TRUE(candidates[3].app()); - EXPECT_EQ("service", candidates[3].app()->process_name()); - // pinned and media. - ASSERT_TRUE(candidates[4].tab()); - EXPECT_EQ(300, candidates[4].tab()->id); - // media. - ASSERT_TRUE(candidates[5].tab()); - EXPECT_EQ(400, candidates[5].tab()->id); - // pinned. - ASSERT_TRUE(candidates[6].tab()); - EXPECT_EQ(100, candidates[6].tab()->id); - // chrome app. - ASSERT_TRUE(candidates[7].tab()); - EXPECT_EQ(500, candidates[7].tab()->id); - // internal page. - ASSERT_TRUE(candidates[8].tab()); - EXPECT_EQ(200, candidates[8].tab()->id); + EXPECT_EQ("visible2", candidates[3].app()->process_name()); + // background service. + ASSERT_TRUE(candidates[4].app()); + EXPECT_EQ("service", candidates[4].app()->process_name()); + // protected LifecycleUnit + EXPECT_EQ(candidates[5].lifecycle_unit(), &protected_lifecycle_unit); + // non-focused LifecycleUnits, sorted by last focused time. + EXPECT_EQ(candidates[6].lifecycle_unit(), &other_non_focused_lifecycle_unit); + EXPECT_EQ(candidates[7].lifecycle_unit(), &non_focused_lifecycle_unit); } // Occasionally, Chrome sees both FOCUSED_TAB and FOCUSED_APP at the same time. @@ -100,19 +124,15 @@ std::vector<arc::ArcProcess> arc_processes; arc_processes.emplace_back(1, 10, "focused", arc::mojom::ProcessState::TOP, kIsFocused, 100); - TabStats tab1; - tab1.id = 100; - tab1.is_pinned = true; - tab1.is_in_active_window = true; - tab1.is_active = true; - const TabStatsList tab_list = {tab1}; + + DummyLifecycleUnit focused_lifecycle_unit(base::TimeTicks::Max()); + LifecycleUnitVector lifecycle_units{&focused_lifecycle_unit}; const std::vector<TabManagerDelegate::Candidate> candidates = - TabManagerDelegate::GetSortedCandidates(tab_list, arc_processes); + TabManagerDelegate::GetSortedCandidates(lifecycle_units, arc_processes); ASSERT_EQ(2U, candidates.size()); // FOCUSED_TAB should be the first one. - ASSERT_TRUE(candidates[0].tab()); - EXPECT_EQ(100, candidates[0].tab()->id); + EXPECT_EQ(&focused_lifecycle_unit, candidates[0].lifecycle_unit()); ASSERT_TRUE(candidates[1].app()); EXPECT_EQ("focused", candidates[1].app()->process_name()); } @@ -131,7 +151,7 @@ std::vector<int> GetKilledArcProcesses() { return killed_arc_processes_; } // unit test. - std::vector<int64_t> GetKilledTabs() { return killed_tabs_; } + LifecycleUnitVector GetKilledTabs() { return killed_tabs_; } // unit test. void Clear() { @@ -146,6 +166,10 @@ always_return_true_from_is_recently_killed; } + void AddLifecycleUnit(LifecycleUnit* lifecycle_unit) { + lifecycle_units_.push_back(lifecycle_unit); + } + bool IsRecentlyKilledArcProcess(const std::string& process_name, const base::TimeTicks& now) override { if (always_return_true_from_is_recently_killed_) @@ -159,19 +183,22 @@ return true; } - bool KillTab(const TabStats& tab_stats, DiscardReason reason) override { - killed_tabs_.push_back(tab_stats.id); + bool KillTab(LifecycleUnit* lifecycle_unit, DiscardReason reason) override { + killed_tabs_.push_back(lifecycle_unit); return true; } + LifecycleUnitVector GetLifecycleUnits() override { return lifecycle_units_; } + chromeos::DebugDaemonClient* GetDebugDaemonClient() override { return &debugd_client_; } private: + LifecycleUnitVector lifecycle_units_; chromeos::FakeDebugDaemonClient debugd_client_; std::vector<int> killed_arc_processes_; - std::vector<int64_t> killed_tabs_; + LifecycleUnitVector killed_tabs_; bool always_return_true_from_is_recently_killed_; }; @@ -220,23 +247,21 @@ arc::mojom::ProcessState::PERSISTENT_UI, kNotFocused, 700); - TabStats tab1, tab2, tab3, tab4, tab5; - tab1.is_pinned = true; - tab1.renderer_handle = 11; - - tab2.is_internal_page = true; - tab2.renderer_handle = 11; - - tab3.is_pinned = true; - tab3.is_media = true; - tab3.renderer_handle = 12; - - tab4.is_media = true; - tab4.renderer_handle = 12; - - tab5.is_app = true; - tab5.renderer_handle = 12; - TabStatsList tab_list = {tab1, tab2, tab3, tab4, tab5}; + DummyLifecycleUnit tab1(base::TimeTicks() + base::TimeDelta::FromSeconds(3), + 11); + tab_manager_delegate.AddLifecycleUnit(&tab1); + DummyLifecycleUnit tab2(base::TimeTicks() + base::TimeDelta::FromSeconds(1), + 11); + tab_manager_delegate.AddLifecycleUnit(&tab2); + DummyLifecycleUnit tab3(base::TimeTicks() + base::TimeDelta::FromSeconds(5), + 12); + tab_manager_delegate.AddLifecycleUnit(&tab3); + DummyLifecycleUnit tab4(base::TimeTicks() + base::TimeDelta::FromSeconds(4), + 12); + tab_manager_delegate.AddLifecycleUnit(&tab4); + DummyLifecycleUnit tab5(base::TimeTicks() + base::TimeDelta::FromSeconds(2), + 12); + tab_manager_delegate.AddLifecycleUnit(&tab5); // Sorted order (by GetSortedCandidates): // app "focused" pid: 10 @@ -250,8 +275,7 @@ // tab1 pid: 11 // tab5 pid: 12 // tab2 pid: 11 - tab_manager_delegate.AdjustOomPrioritiesImpl(tab_list, - std::move(arc_processes)); + tab_manager_delegate.AdjustOomPrioritiesImpl(std::move(arc_processes)); auto& oom_score_map = tab_manager_delegate.oom_score_map_; // 6 PIDs for apps + 2 PIDs for tabs. @@ -337,9 +361,8 @@ memory_stat->SetTargetMemoryToFreeKB(250000); memory_stat->SetProcessPss(30, 10000); - TabStatsList tab_list; - tab_manager_delegate.LowMemoryKillImpl(DiscardReason::kUrgent, tab_list, - arc_processes); + tab_manager_delegate.LowMemoryKillImpl(DiscardReason::kUrgent, + std::move(arc_processes)); auto killed_arc_processes = tab_manager_delegate.GetKilledArcProcesses(); EXPECT_EQ(0U, killed_arc_processes.size()); @@ -369,28 +392,21 @@ arc::mojom::ProcessState::PERSISTENT, kNotFocused, 400); - TabStats tab1, tab2, tab3, tab4, tab5; - tab1.is_pinned = true; - tab1.renderer_handle = 11; - tab1.id = 1; - - tab2.is_internal_page = true; - tab2.renderer_handle = 11; - tab2.id = 2; - - tab3.is_pinned = true; - tab3.is_media = true; - tab3.renderer_handle = 12; - tab3.id = 3; - - tab4.is_media = true; - tab4.renderer_handle = 12; - tab4.id = 4; - - tab5.is_app = true; - tab5.renderer_handle = 12; - tab5.id = 5; - TabStatsList tab_list = {tab1, tab2, tab3, tab4, tab5}; + DummyLifecycleUnit tab1(base::TimeTicks() + base::TimeDelta::FromSeconds(3), + 11); + tab_manager_delegate.AddLifecycleUnit(&tab1); + DummyLifecycleUnit tab2(base::TimeTicks() + base::TimeDelta::FromSeconds(1), + 11); + tab_manager_delegate.AddLifecycleUnit(&tab2); + DummyLifecycleUnit tab3(base::TimeTicks() + base::TimeDelta::FromSeconds(5), + 12); + tab_manager_delegate.AddLifecycleUnit(&tab3); + DummyLifecycleUnit tab4(base::TimeTicks() + base::TimeDelta::FromSeconds(4), + 12); + tab_manager_delegate.AddLifecycleUnit(&tab4); + DummyLifecycleUnit tab5(base::TimeTicks() + base::TimeDelta::FromSeconds(2), + 12); + tab_manager_delegate.AddLifecycleUnit(&tab5); // Sorted order (by GetSortedCandidates): // app "focused" pid: 10 nspid 1 @@ -416,8 +432,8 @@ memory_stat->SetProcessPss(20, 30000); memory_stat->SetProcessPss(10, 100000); - tab_manager_delegate.LowMemoryKillImpl(DiscardReason::kProactive, tab_list, - arc_processes); + tab_manager_delegate.LowMemoryKillImpl(DiscardReason::kProactive, + std::move(arc_processes)); auto killed_arc_processes = tab_manager_delegate.GetKilledArcProcesses(); auto killed_tabs = tab_manager_delegate.GetKilledTabs(); @@ -431,11 +447,11 @@ // times. But so far I don't have a good way to estimate the memory freed // if multiple tabs share one process. ASSERT_EQ(5U, killed_tabs.size()); - EXPECT_EQ(2, killed_tabs[0]); - EXPECT_EQ(5, killed_tabs[1]); - EXPECT_EQ(1, killed_tabs[2]); - EXPECT_EQ(4, killed_tabs[3]); - EXPECT_EQ(3, killed_tabs[4]); + EXPECT_EQ(&tab2, killed_tabs[0]); + EXPECT_EQ(&tab5, killed_tabs[1]); + EXPECT_EQ(&tab1, killed_tabs[2]); + EXPECT_EQ(&tab4, killed_tabs[3]); + EXPECT_EQ(&tab3, killed_tabs[4]); // Check that killed apps are in the map. const TabManagerDelegate::KilledArcProcessesMap& processes_map =
diff --git a/chrome/browser/resource_coordinator/tab_manager_unittest.cc b/chrome/browser/resource_coordinator/tab_manager_unittest.cc index 0210b78..fcecd96 100644 --- a/chrome/browser/resource_coordinator/tab_manager_unittest.cc +++ b/chrome/browser/resource_coordinator/tab_manager_unittest.cc
@@ -29,14 +29,15 @@ #include "chrome/browser/resource_coordinator/tab_manager_resource_coordinator_signal_observer.h" #include "chrome/browser/resource_coordinator/tab_manager_stats_collector.h" #include "chrome/browser/resource_coordinator/tab_manager_web_contents_data.h" -#include "chrome/browser/resource_coordinator/tab_stats.h" #include "chrome/browser/resource_coordinator/time.h" #include "chrome/browser/sessions/tab_loader.h" +#include "chrome/browser/ui/browser.h" #include "chrome/browser/ui/tab_ui_helper.h" #include "chrome/browser/ui/tabs/tab_strip_model.h" #include "chrome/browser/ui/tabs/test_tab_strip_model_delegate.h" #include "chrome/common/url_constants.h" #include "chrome/test/base/chrome_render_view_host_test_harness.h" +#include "chrome/test/base/test_browser_window.h" #include "chrome/test/base/testing_profile.h" #include "components/variations/variations_associated_data.h" #include "content/public/browser/render_frame_host.h" @@ -288,107 +289,6 @@ // TODO(georgesak): Add tests for protection to tabs with form input and // playing audio; -// Tests the sorting comparator to make sure it's producing the desired order. -TEST_F(TabManagerTest, Comparator) { - TabStatsList test_list; - const base::TimeTicks now = NowTicks(); - - // Add kAutoDiscardable last to verify that the array is being sorted. - - { - TabStats stats; - stats.last_active = now; - stats.is_pinned = true; - stats.child_process_host_id = kPinned; - test_list.push_back(stats); - } - - { - TabStats stats; - stats.last_active = now; - stats.is_app = true; - stats.child_process_host_id = kApp; - test_list.push_back(stats); - } - - { - TabStats stats; - stats.last_active = now; - stats.is_media = true; - stats.child_process_host_id = kPlayingAudio; - test_list.push_back(stats); - } - - { - TabStats stats; - stats.last_active = now; - stats.has_form_entry = true; - stats.child_process_host_id = kFormEntry; - test_list.push_back(stats); - } - - { - TabStats stats; - stats.last_active = now - base::TimeDelta::FromSeconds(10); - stats.child_process_host_id = kRecent; - test_list.push_back(stats); - } - - { - TabStats stats; - stats.last_active = now - base::TimeDelta::FromMinutes(15); - stats.child_process_host_id = kOld; - test_list.push_back(stats); - } - - { - TabStats stats; - stats.last_active = now - base::TimeDelta::FromDays(365); - stats.child_process_host_id = kReallyOld; - test_list.push_back(stats); - } - - { - TabStats stats; - stats.is_pinned = true; - stats.last_active = now - base::TimeDelta::FromDays(365); - stats.child_process_host_id = kOldButPinned; - test_list.push_back(stats); - } - - { - TabStats stats; - stats.last_active = now; - stats.is_internal_page = true; - stats.child_process_host_id = kInternalPage; - test_list.push_back(stats); - } - - // This entry sorts to the front, so by adding it last, it verifies that the - // array is being sorted. - { - TabStats stats; - stats.last_active = now; - stats.is_auto_discardable = false; - stats.child_process_host_id = kAutoDiscardable; - test_list.push_back(stats); - } - - std::sort(test_list.begin(), test_list.end(), TabManager::CompareTabStats); - - int index = 0; - EXPECT_EQ(kAutoDiscardable, test_list[index++].child_process_host_id); - EXPECT_EQ(kFormEntry, test_list[index++].child_process_host_id); - EXPECT_EQ(kPlayingAudio, test_list[index++].child_process_host_id); - EXPECT_EQ(kPinned, test_list[index++].child_process_host_id); - EXPECT_EQ(kOldButPinned, test_list[index++].child_process_host_id); - EXPECT_EQ(kApp, test_list[index++].child_process_host_id); - EXPECT_EQ(kRecent, test_list[index++].child_process_host_id); - EXPECT_EQ(kOld, test_list[index++].child_process_host_id); - EXPECT_EQ(kReallyOld, test_list[index++].child_process_host_id); - EXPECT_EQ(kInternalPage, test_list[index++].child_process_host_id); -} - TEST_F(TabManagerTest, IsInternalPage) { EXPECT_TRUE(TabManager::IsInternalPage(GURL(chrome::kChromeUIDownloadsURL))); EXPECT_TRUE(TabManager::IsInternalPage(GURL(chrome::kChromeUIHistoryURL))); @@ -407,124 +307,6 @@ TabManager::IsInternalPage(GURL("chrome://settings/fakeSetting"))); } -// Ensures discarding tabs leaves TabStripModel in a good state. -TEST_F(TabManagerTest, DiscardWebContentsAt) { - // Create a tab strip in a visible and active window. - TabStripDummyDelegate delegate; - TabStripModel tabstrip(&delegate, profile()); - tabstrip.AddObserver(tab_manager_); - - BrowserInfo browser_info; - browser_info.tab_strip_model = &tabstrip; - browser_info.window_is_minimized = false; - browser_info.browser_is_app = false; - tab_manager_->test_browser_info_list_.push_back(browser_info); - - // Fill it with some tabs. - WebContents* contents1 = CreateWebContents(); - tabstrip.AppendWebContents(contents1, true); - WebContents* contents2 = CreateWebContents(); - tabstrip.AppendWebContents(contents2, true); - - // Start watching for events after the appends to avoid observing state - // transitions that aren't relevant to this test. - MockTabStripModelObserver tabstrip_observer; - tabstrip.AddObserver(&tabstrip_observer); - - // Discard one of the tabs. - WebContents* null_contents1 = tab_manager_->DiscardWebContentsAt( - 0, &tabstrip, DiscardReason::kProactive); - ASSERT_EQ(2, tabstrip.count()); - EXPECT_TRUE(tab_manager_->IsTabDiscarded(tabstrip.GetWebContentsAt(0))); - EXPECT_FALSE(tab_manager_->IsTabDiscarded(tabstrip.GetWebContentsAt(1))); - ASSERT_EQ(null_contents1, tabstrip.GetWebContentsAt(0)); - ASSERT_EQ(contents2, tabstrip.GetWebContentsAt(1)); - ASSERT_EQ(1, tabstrip_observer.NbEvents()); - EXPECT_EQ(contents1, tabstrip_observer.OldContents()); - EXPECT_EQ(null_contents1, tabstrip_observer.NewContents()); - tabstrip_observer.Reset(); - - // Discard the same tab again, after resetting its discard state. - tab_manager_->GetWebContentsData(tabstrip.GetWebContentsAt(0)) - ->SetDiscardState(false); - WebContents* null_contents2 = tab_manager_->DiscardWebContentsAt( - 0, &tabstrip, DiscardReason::kProactive); - ASSERT_EQ(2, tabstrip.count()); - EXPECT_TRUE(tab_manager_->IsTabDiscarded(tabstrip.GetWebContentsAt(0))); - EXPECT_FALSE(tab_manager_->IsTabDiscarded(tabstrip.GetWebContentsAt(1))); - ASSERT_EQ(null_contents2, tabstrip.GetWebContentsAt(0)); - ASSERT_EQ(contents2, tabstrip.GetWebContentsAt(1)); - ASSERT_EQ(1, tabstrip_observer.NbEvents()); - EXPECT_EQ(null_contents1, tabstrip_observer.OldContents()); - EXPECT_EQ(null_contents2, tabstrip_observer.NewContents()); - - // Activating the tab should clear its discard state. - tabstrip.ActivateTabAt(0, true /* user_gesture */); - ASSERT_EQ(2, tabstrip.count()); - EXPECT_FALSE(tab_manager_->IsTabDiscarded(tabstrip.GetWebContentsAt(0))); - EXPECT_FALSE(tab_manager_->IsTabDiscarded(tabstrip.GetWebContentsAt(1))); - - tabstrip.CloseAllTabs(); - EXPECT_TRUE(tabstrip.empty()); -} - -// Makes sure that reloading a discarded tab without activating it unmarks the -// tab as discarded so it won't reload on activation. -TEST_F(TabManagerTest, ReloadDiscardedTabContextMenu) { - // Note that we do not add |tab_manager| as an observer to |tabstrip| here as - // the event we are trying to test for is not related to the tab strip, but - // the web content instead and therefore should be handled by WebContentsData - // (which observes the web content). - TabStripDummyDelegate delegate; - TabStripModel tabstrip(&delegate, profile()); - - // Create 2 tabs because the active tab cannot be discarded. - tabstrip.AppendWebContents(CreateWebContents(), true); - content::WebContents* test_contents = - WebContentsTester::CreateTestWebContents(browser_context(), nullptr); - tabstrip.AppendWebContents(test_contents, false); // Opened in background. - - // Navigate to a web page. This is necessary to set a current entry in memory - // so the reload can happen. - WebContentsTester::For(test_contents) - ->NavigateAndCommit(GURL("chrome://newtab")); - EXPECT_FALSE(tab_manager_->IsTabDiscarded(tabstrip.GetWebContentsAt(1))); - - tab_manager_->DiscardWebContentsAt(1, &tabstrip, DiscardReason::kProactive); - EXPECT_TRUE(tab_manager_->IsTabDiscarded(tabstrip.GetWebContentsAt(1))); - - tabstrip.GetWebContentsAt(1)->GetController().Reload( - content::ReloadType::NORMAL, false); - EXPECT_FALSE(tab_manager_->IsTabDiscarded(tabstrip.GetWebContentsAt(1))); - tabstrip.CloseAllTabs(); - EXPECT_TRUE(tabstrip.empty()); -} - -// Makes sure that the last active time property is saved even though the tab is -// discarded. -TEST_F(TabManagerTest, DiscardedTabKeepsLastActiveTime) { - TabStripDummyDelegate delegate; - TabStripModel tabstrip(&delegate, profile()); - tabstrip.AddObserver(tab_manager_); - - tabstrip.AppendWebContents(CreateWebContents(), true); - WebContents* test_contents = CreateWebContents(); - tabstrip.AppendWebContents(test_contents, false); - - // Simulate an old inactive tab about to get discarded. - base::TimeTicks new_last_active_time = - NowTicks() - base::TimeDelta::FromMinutes(35); - test_contents->SetLastActiveTime(new_last_active_time); - EXPECT_EQ(new_last_active_time, test_contents->GetLastActiveTime()); - - WebContents* null_contents = tab_manager_->DiscardWebContentsAt( - 1, &tabstrip, DiscardReason::kProactive); - EXPECT_EQ(new_last_active_time, null_contents->GetLastActiveTime()); - - tabstrip.CloseAllTabs(); - EXPECT_TRUE(tabstrip.empty()); -} - TEST_F(TabManagerTest, DefaultTimeToPurgeInCorrectRange) { base::TimeDelta time_to_purge = tab_manager_->GetTimeToPurge(TabManager::kDefaultMinTimeToPurge, @@ -534,12 +316,15 @@ } TEST_F(TabManagerTest, ShouldPurgeAtDefaultTime) { - TabStripDummyDelegate delegate; - TabStripModel tabstrip(&delegate, profile()); - tabstrip.AddObserver(tab_manager_); + auto window = std::make_unique<TestBrowserWindow>(); + Browser::CreateParams params(profile(), true); + params.type = Browser::TYPE_TABBED; + params.window = window.get(); + auto browser = std::make_unique<Browser>(params); + TabStripModel* tab_strip = browser->tab_strip_model(); WebContents* test_contents = CreateWebContents(); - tabstrip.AppendWebContents(test_contents, false); + tab_strip->AppendWebContents(test_contents, false); tab_manager_->GetWebContentsData(test_contents)->set_is_purged(false); tab_manager_->GetWebContentsData(test_contents) @@ -564,24 +349,21 @@ EXPECT_FALSE(tab_manager_->ShouldPurgeNow(test_contents)); // Tabs with a committed URL must be closed explicitly to avoid DCHECK errors. - tabstrip.CloseAllTabs(); + tab_strip->CloseAllTabs(); } TEST_F(TabManagerTest, ActivateTabResetPurgeState) { - TabStripDummyDelegate delegate; - TabStripModel tabstrip(&delegate, profile()); - tabstrip.AddObserver(tab_manager_); - - BrowserInfo browser_info; - browser_info.tab_strip_model = &tabstrip; - browser_info.window_is_minimized = false; - browser_info.browser_is_app = false; - tab_manager_->test_browser_info_list_.push_back(browser_info); + auto window = std::make_unique<TestBrowserWindow>(); + Browser::CreateParams params(profile(), true); + params.type = Browser::TYPE_TABBED; + params.window = window.get(); + auto browser = std::make_unique<Browser>(params); + TabStripModel* tabstrip = browser->tab_strip_model(); WebContents* tab1 = CreateWebContents(); WebContents* tab2 = CreateWebContents(); - tabstrip.AppendWebContents(tab1, true); - tabstrip.AppendWebContents(tab2, false); + tabstrip->AppendWebContents(tab1, true); + tabstrip->AppendWebContents(tab2, false); tab_manager_->GetWebContentsData(tab2)->SetLastInactiveTime(NowTicks()); static_cast<content::MockRenderProcessHost*>( @@ -600,66 +382,11 @@ EXPECT_TRUE(tab_manager_->GetWebContentsData(tab2)->is_purged()); // Activate tab2. Tab2's PurgeAndSuspend state should be NOT_PURGED. - tabstrip.ActivateTabAt(1, true /* user_gesture */); + tabstrip->ActivateTabAt(1, true /* user_gesture */); EXPECT_FALSE(tab_manager_->GetWebContentsData(tab2)->is_purged()); // Tabs with a committed URL must be closed explicitly to avoid DCHECK errors. - tabstrip.CloseAllTabs(); -} - -// Verify that the |is_in_visible_window| field of TabStats returned by -// GetUnsortedTabStats() is set correctly. -TEST_F(TabManagerTest, GetUnsortedTabStatsIsInVisibleWindow) { - TabStripDummyDelegate delegate; - - WebContents* web_contents1a = CreateWebContents(); - WebContents* web_contents1b = CreateWebContents(); - WebContents* web_contents2a = CreateWebContents(); - WebContents* web_contents2b = CreateWebContents(); - - // Create 2 TabStripModels. - TabStripModel tab_strip1(&delegate, profile()); - tab_strip1.AppendWebContents(web_contents1a, true); - tab_strip1.AppendWebContents(web_contents1b, false); - - TabStripModel tab_strip2(&delegate, profile()); - tab_strip2.AppendWebContents(web_contents2a, true); - tab_strip2.AppendWebContents(web_contents2b, false); - - // Add the 2 TabStripModels to the TabManager. - // The window for |tab_strip1| is visible while the window for |tab_strip2| is - // minimized. - BrowserInfo browser_info1; - browser_info1.tab_strip_model = &tab_strip1; - browser_info1.window_is_minimized = false; - browser_info1.browser_is_app = false; - tab_manager_->test_browser_info_list_.push_back(browser_info1); - - BrowserInfo browser_info2; - browser_info2.tab_strip_model = &tab_strip2; - browser_info2.window_is_minimized = true; - browser_info2.browser_is_app = false; - tab_manager_->test_browser_info_list_.push_back(browser_info2); - - // Get TabStats and verify the the |is_in_visible_window| field of each - // TabStats is set correctly. - auto tab_stats = tab_manager_->GetUnsortedTabStats(); - - ASSERT_EQ(4U, tab_stats.size()); - - EXPECT_EQ(tab_stats[0].id, tab_manager_->IdFromWebContents(web_contents1a)); - EXPECT_EQ(tab_stats[1].id, tab_manager_->IdFromWebContents(web_contents1b)); - EXPECT_EQ(tab_stats[2].id, tab_manager_->IdFromWebContents(web_contents2a)); - EXPECT_EQ(tab_stats[3].id, tab_manager_->IdFromWebContents(web_contents2b)); - - EXPECT_TRUE(tab_stats[0].is_in_visible_window); - EXPECT_TRUE(tab_stats[1].is_in_visible_window); - EXPECT_FALSE(tab_stats[2].is_in_visible_window); - EXPECT_FALSE(tab_stats[3].is_in_visible_window); - - // Tabs with a committed URL must be closed explicitly to avoid DCHECK errors. - tab_strip1.CloseAllTabs(); - tab_strip2.CloseAllTabs(); + tabstrip->CloseAllTabs(); } // Data race on Linux. http://crbug.com/787842 @@ -670,35 +397,34 @@ #endif // Verify that: -// - On ChromeOS, DiscardTab can discard every tab in a non-visible window, but -// cannot discard the active tab in a visible window. -// - On other platforms, DiscardTab can discard every non-active tab. +// - On ChromeOS, DiscardTab can discard every non-visible tab, but cannot +// discard a visible tab. +// - On other platforms, DiscardTab can discard every tab that is not active in +// its tab strip. TEST_F(TabManagerTest, MAYBE_DiscardTabWithNonVisibleTabs) { - TabStripDummyDelegate delegate; + // Create 2 tab strips. Simulate the second tab strip being hidden by hiding + // its active tab. + auto window1 = std::make_unique<TestBrowserWindow>(); + Browser::CreateParams params1(profile(), true); + params1.type = Browser::TYPE_TABBED; + params1.window = window1.get(); + auto browser1 = std::make_unique<Browser>(params1); + TabStripModel* tab_strip1 = browser1->tab_strip_model(); + tab_strip1->AppendWebContents(CreateWebContents(), true); + tab_strip1->AppendWebContents(CreateWebContents(), false); + tab_strip1->GetWebContentsAt(0)->WasShown(); + tab_strip1->GetWebContentsAt(1)->WasHidden(); - // Create 2 TabStripModels. - TabStripModel tab_strip1(&delegate, profile()); - tab_strip1.AppendWebContents(CreateWebContents(), true); - tab_strip1.AppendWebContents(CreateWebContents(), false); - - TabStripModel tab_strip2(&delegate, profile()); - tab_strip2.AppendWebContents(CreateWebContents(), true); - tab_strip2.AppendWebContents(CreateWebContents(), false); - - // Add the 2 TabStripModels to the TabManager. - // The window for |tab_strip1| is visible while the window for |tab_strip2| - // is minimized. - BrowserInfo browser_info1; - browser_info1.tab_strip_model = &tab_strip1; - browser_info1.window_is_minimized = false; - browser_info1.browser_is_app = false; - tab_manager_->test_browser_info_list_.push_back(browser_info1); - - BrowserInfo browser_info2; - browser_info2.tab_strip_model = &tab_strip2; - browser_info2.window_is_minimized = true; - browser_info2.browser_is_app = false; - tab_manager_->test_browser_info_list_.push_back(browser_info2); + auto window2 = std::make_unique<TestBrowserWindow>(); + Browser::CreateParams params2(profile(), true); + params2.type = Browser::TYPE_TABBED; + params2.window = window2.get(); + auto browser2 = std::make_unique<Browser>(params1); + TabStripModel* tab_strip2 = browser2->tab_strip_model(); + tab_strip2->AppendWebContents(CreateWebContents(), true); + tab_strip2->AppendWebContents(CreateWebContents(), false); + tab_strip2->GetWebContentsAt(0)->WasHidden(); + tab_strip2->GetWebContentsAt(1)->WasHidden(); // Fast-forward time until no tab is protected from being discarded for having // recently been used. @@ -708,24 +434,25 @@ tab_manager_->DiscardTab(DiscardReason::kProactive); // Active tab in a visible window should not be discarded. - EXPECT_FALSE(tab_manager_->IsTabDiscarded(tab_strip1.GetWebContentsAt(0))); + EXPECT_FALSE(tab_manager_->IsTabDiscarded(tab_strip1->GetWebContentsAt(0))); // Non-active tabs should be discarded. - EXPECT_TRUE(tab_manager_->IsTabDiscarded(tab_strip1.GetWebContentsAt(1))); - EXPECT_TRUE(tab_manager_->IsTabDiscarded(tab_strip2.GetWebContentsAt(1))); + EXPECT_TRUE(tab_manager_->IsTabDiscarded(tab_strip1->GetWebContentsAt(1))); + EXPECT_TRUE(tab_manager_->IsTabDiscarded(tab_strip2->GetWebContentsAt(1))); #if defined(OS_CHROMEOS) - // On ChromeOS, active tab in a minimized window should be discarded. - EXPECT_TRUE(tab_manager_->IsTabDiscarded(tab_strip2.GetWebContentsAt(0))); + // On ChromeOS, a non-visible tab should be discarded even if it's active in + // its tab strip. + EXPECT_TRUE(tab_manager_->IsTabDiscarded(tab_strip2->GetWebContentsAt(0))); #else - // On other platforms, an active tab is never discarded, even if its window is - // minimized. - EXPECT_FALSE(tab_manager_->IsTabDiscarded(tab_strip2.GetWebContentsAt(0))); + // On other platforms, an active tab is never discarded, even if it's not + // visible. + EXPECT_FALSE(tab_manager_->IsTabDiscarded(tab_strip2->GetWebContentsAt(0))); #endif // defined(OS_CHROMEOS) // Tabs with a committed URL must be closed explicitly to avoid DCHECK errors. - tab_strip1.CloseAllTabs(); - tab_strip2.CloseAllTabs(); + tab_strip1->CloseAllTabs(); + tab_strip2->CloseAllTabs(); } TEST_F(TabManagerTest, MaybeThrottleNavigation) {
diff --git a/chrome/browser/resource_coordinator/tab_manager_web_contents_data.cc b/chrome/browser/resource_coordinator/tab_manager_web_contents_data.cc index 059cfc86..64deba0 100644 --- a/chrome/browser/resource_coordinator/tab_manager_web_contents_data.cc +++ b/chrome/browser/resource_coordinator/tab_manager_web_contents_data.cc
@@ -5,9 +5,7 @@ #include "chrome/browser/resource_coordinator/tab_manager_web_contents_data.h" #include "base/metrics/histogram_macros.h" -#include "base/time/tick_clock.h" #include "chrome/browser/browser_process.h" -#include "chrome/browser/resource_coordinator/discard_metrics_util.h" #include "chrome/browser/resource_coordinator/tab_manager.h" #include "chrome/browser/resource_coordinator/tab_manager_stats_collector.h" #include "chrome/browser/resource_coordinator/time.h" @@ -27,19 +25,10 @@ TabManager::WebContentsData::WebContentsData(content::WebContents* web_contents) : WebContentsObserver(web_contents), time_to_purge_(base::TimeDelta::FromMinutes(30)), - is_purged_(false) { - tab_data_.is_hidden = - web_contents->GetVisibility() == content::Visibility::HIDDEN; -} + is_purged_(false) {} TabManager::WebContentsData::~WebContentsData() {} -void TabManager::WebContentsData::DidStartLoading() { - // Marks the tab as no longer discarded if it has been reloaded from another - // source (ie: context menu). - SetDiscardState(false); -} - void TabManager::WebContentsData::DidStopLoading() { if (IsPageAlmostIdleSignalEnabled()) return; @@ -73,17 +62,6 @@ if (g_browser_process->IsShuttingDown()) return; - // If the tab has been previously discarded but is not currently discarded - // (ie. it has been reloaded), we want to record the time it took between the - // reload event and the closing of the tab. - if (tab_data_.discard_count > 0 && !tab_data_.is_discarded) { - auto delta = NowTicks() - tab_data_.last_reload_time; - // Capped to one day for now, will adjust if necessary. - UMA_HISTOGRAM_CUSTOM_TIMES("TabManager.Discarding.ReloadToCloseTime", delta, - base::TimeDelta::FromSeconds(1), - base::TimeDelta::FromDays(1), 100); - } - SetTabLoadingState(TAB_IS_NOT_LOADING); SetIsInSessionRestore(false); g_browser_process->GetTabManager()->OnWebContentsDestroyed(web_contents()); @@ -98,52 +76,6 @@ } } -bool TabManager::WebContentsData::IsDiscarded() { - return tab_data_.is_discarded; -} - -void TabManager::WebContentsData::SetDiscardState(bool is_discarded) { - if (tab_data_.is_discarded == is_discarded) - return; - - if (is_discarded) { - tab_data_.last_discard_time = NowTicks(); - RecordTabDiscarded(); - } else { - tab_data_.last_reload_time = NowTicks(); - RecordTabReloaded(tab_data_.last_inactive_time, tab_data_.last_discard_time, - tab_data_.last_reload_time); - } - - tab_data_.is_discarded = is_discarded; - g_browser_process->GetTabManager()->OnDiscardedStateChange(web_contents(), - is_discarded); -} - -int TabManager::WebContentsData::DiscardCount() { - return tab_data_.discard_count; -} - -void TabManager::WebContentsData::IncrementDiscardCount() { - tab_data_.discard_count++; -} - -bool TabManager::WebContentsData::IsRecentlyAudible() { - return tab_data_.is_recently_audible; -} - -void TabManager::WebContentsData::SetRecentlyAudible(bool state) { - tab_data_.is_recently_audible = state; -} - -TimeTicks TabManager::WebContentsData::LastAudioChangeTime() { - return tab_data_.last_audio_change_time; -} - -void TabManager::WebContentsData::SetLastAudioChangeTime(TimeTicks timestamp) { - tab_data_.last_audio_change_time = timestamp; -} - TimeTicks TabManager::WebContentsData::LastInactiveTime() { return tab_data_.last_inactive_time; } @@ -165,27 +97,12 @@ } TabManager::WebContentsData::Data::Data() - : id(0), - is_discarded(false), - discard_count(0), - is_hidden(true), - is_recently_audible(false), - is_auto_discardable(true), - tab_loading_state(TAB_IS_NOT_LOADING), + : tab_loading_state(TAB_IS_NOT_LOADING), is_in_session_restore(false), - is_restored_in_foreground(false) { - static int32_t next_id = 0; - id = ++next_id; -} + is_restored_in_foreground(false) {} bool TabManager::WebContentsData::Data::operator==(const Data& right) const { - return id == right.id && is_discarded == right.is_discarded && - is_hidden == right.is_hidden && - is_recently_audible == right.is_recently_audible && - last_audio_change_time == right.last_audio_change_time && - last_discard_time == right.last_discard_time && - last_reload_time == right.last_reload_time && - last_inactive_time == right.last_inactive_time && + return last_inactive_time == right.last_inactive_time && tab_loading_state == right.tab_loading_state && is_in_session_restore == right.is_in_session_restore && is_restored_in_foreground == right.is_restored_in_foreground; @@ -195,17 +112,4 @@ return !(*this == right); } -void TabManager::WebContentsData::SetAutoDiscardableState(bool state) { - if (tab_data_.is_auto_discardable == state) - return; - - tab_data_.is_auto_discardable = state; - g_browser_process->GetTabManager()->OnAutoDiscardableStateChange( - web_contents(), state); -} - -bool TabManager::WebContentsData::IsAutoDiscardable() { - return tab_data_.is_auto_discardable; -} - } // namespace resource_coordinator
diff --git a/chrome/browser/resource_coordinator/tab_manager_web_contents_data.h b/chrome/browser/resource_coordinator/tab_manager_web_contents_data.h index d200715..e7012cc 100644 --- a/chrome/browser/resource_coordinator/tab_manager_web_contents_data.h +++ b/chrome/browser/resource_coordinator/tab_manager_web_contents_data.h
@@ -51,7 +51,6 @@ ~WebContentsData() override; // WebContentsObserver implementation: - void DidStartLoading() override; void DidStopLoading() override; void DidStartNavigation( content::NavigationHandle* navigation_handle) override; @@ -63,30 +62,6 @@ // tab is considered loaded. void NotifyTabIsLoaded(); - // Returns true if the tab has been discarded to save memory. - bool IsDiscarded(); - - // Sets/clears the discard state of the tab. - void SetDiscardState(bool is_discarded); - - // Returns the number of times the tab has been discarded. - int DiscardCount(); - - // Increments the number of times the tab has been discarded. - void IncrementDiscardCount(); - - // Returns true if audio has recently been audible. - bool IsRecentlyAudible(); - - // Set/clears the state of whether audio has recently been audible. - void SetRecentlyAudible(bool state); - - // Returns the timestamp of the last time the tab changed its audio state. - base::TimeTicks LastAudioChangeTime(); - - // Sets the timestamp of the last time the tab changed its audio state. - void SetLastAudioChangeTime(base::TimeTicks timestamp); - // Returns the timestamp of the last time the tab changed became inactive. base::TimeTicks LastInactiveTime(); @@ -97,13 +72,6 @@ static void CopyState(content::WebContents* old_contents, content::WebContents* new_contents); - // Returns the auto-discardable state of the tab. - // See tab_manager.h for more information. - bool IsAutoDiscardable(); - - // Sets/clears the auto-discardable state of the tab. - void SetAutoDiscardableState(bool state); - // Sets the current purge state. // TODO(tasak): remove this after the logic is moved into // MemoryCoordinator. @@ -146,8 +114,6 @@ return tab_data_.is_restored_in_foreground; } - int32_t id() const { return tab_data_.id; } - private: // Needed to access tab_data_. FRIEND_TEST_ALL_PREFIXES(TabManagerWebContentsDataTest, CopyState); @@ -158,29 +124,8 @@ bool operator==(const Data& right) const; bool operator!=(const Data& right) const; - // Unique ID associated with this tab. This stays constant through discards - // and reloads, and is independent of the underlying WebContents and - // TabStripModel index, both of which may change. - int32_t id; - // Is the tab currently discarded? - bool is_discarded; - // Number of times the tab has been discarded. - int discard_count; - // Is the tab hidden? - bool is_hidden; - // Is the tab playing audio? - bool is_recently_audible; - // Last time the tab started or stopped playing audio (we record the - // transition time). - base::TimeTicks last_audio_change_time; - // The last time the tab was discarded. - base::TimeTicks last_discard_time; - // The last time the tab was reloaded after being discarded. - base::TimeTicks last_reload_time; // The last time the tab switched from being active to inactive. base::TimeTicks last_inactive_time; - // Is tab eligible for auto discarding? Defaults to true. - bool is_auto_discardable; // Current loading state of this tab. TabLoadingState tab_loading_state; // True if the tab was created by session restore. Remains true until the
diff --git a/chrome/browser/resource_coordinator/tab_manager_web_contents_data_unittest.cc b/chrome/browser/resource_coordinator/tab_manager_web_contents_data_unittest.cc index 05a60fee..a48f671 100644 --- a/chrome/browser/resource_coordinator/tab_manager_web_contents_data_unittest.cc +++ b/chrome/browser/resource_coordinator/tab_manager_web_contents_data_unittest.cc
@@ -62,37 +62,6 @@ } // namespace -TEST_F(TabManagerWebContentsDataTest, DiscardState) { - EXPECT_FALSE(tab_data()->IsDiscarded()); - tab_data()->SetDiscardState(true); - EXPECT_TRUE(tab_data()->IsDiscarded()); - tab_data()->SetDiscardState(false); - EXPECT_FALSE(tab_data()->IsDiscarded()); -} - -TEST_F(TabManagerWebContentsDataTest, DiscardCount) { - EXPECT_EQ(0, tab_data()->DiscardCount()); - tab_data()->IncrementDiscardCount(); - EXPECT_EQ(1, tab_data()->DiscardCount()); - tab_data()->IncrementDiscardCount(); - EXPECT_EQ(2, tab_data()->DiscardCount()); -} - -TEST_F(TabManagerWebContentsDataTest, RecentlyAudible) { - EXPECT_FALSE(tab_data()->IsRecentlyAudible()); - tab_data()->SetRecentlyAudible(true); - EXPECT_TRUE(tab_data()->IsRecentlyAudible()); - tab_data()->SetRecentlyAudible(false); - EXPECT_FALSE(tab_data()->IsRecentlyAudible()); -} - -TEST_F(TabManagerWebContentsDataTest, LastAudioChangeTime) { - EXPECT_TRUE(tab_data()->LastAudioChangeTime().is_null()); - auto now = NowTicks(); - tab_data()->SetLastAudioChangeTime(now); - EXPECT_EQ(now, tab_data()->LastAudioChangeTime()); -} - TEST_F(TabManagerWebContentsDataTest, LastInactiveTime) { EXPECT_TRUE(tab_data()->LastInactiveTime().is_null()); auto now = NowTicks(); @@ -109,116 +78,21 @@ } TEST_F(TabManagerWebContentsDataTest, CopyState) { + tab_data()->SetLastInactiveTime(base::TimeTicks() + + base::TimeDelta::FromSeconds(42)); + tab_data()->SetTabLoadingState(TAB_IS_LOADED); + tab_data()->SetIsInSessionRestore(true); + tab_data()->SetIsRestoredInForeground(true); + std::unique_ptr<WebContents> web_contents2; auto* tab_data2 = CreateWebContentsAndTabData(&web_contents2); - // TabManagerWebContentsData are initially distinct as they each have unique - // IDs assigned to them at construction time. - EXPECT_NE(tab_data()->tab_data_, tab_data2->tab_data_); - // Copying the state should bring the ID along with it, so they should have - // identical content afterwards. + EXPECT_NE(tab_data()->tab_data_, tab_data2->tab_data_); TabManager::WebContentsData::CopyState(tab_data()->web_contents(), tab_data2->web_contents()); EXPECT_EQ(tab_data()->tab_data_, tab_data2->tab_data_); } -TEST_F(TabManagerWebContentsDataTest, HistogramDiscardCount) { - const char kHistogramName[] = "TabManager.Discarding.DiscardCount"; - - base::HistogramTester histograms; - - EXPECT_TRUE(histograms.GetTotalCountsForPrefix(kHistogramName).empty()); - tab_data()->SetDiscardState(true); - EXPECT_EQ(1, - histograms.GetTotalCountsForPrefix(kHistogramName).begin()->second); - tab_data()->SetDiscardState(false); - EXPECT_EQ(1, - histograms.GetTotalCountsForPrefix(kHistogramName).begin()->second); - tab_data()->SetDiscardState(true); - EXPECT_EQ(2, - histograms.GetTotalCountsForPrefix(kHistogramName).begin()->second); - tab_data()->SetDiscardState(false); - EXPECT_EQ(2, - histograms.GetTotalCountsForPrefix(kHistogramName).begin()->second); -} - -TEST_F(TabManagerWebContentsDataTest, HistogramReloadCount) { - const char kHistogramName[] = "TabManager.Discarding.ReloadCount"; - - base::HistogramTester histograms; - - EXPECT_TRUE(histograms.GetTotalCountsForPrefix(kHistogramName).empty()); - tab_data()->SetDiscardState(true); - EXPECT_TRUE(histograms.GetTotalCountsForPrefix(kHistogramName).empty()); - tab_data()->SetDiscardState(false); - EXPECT_EQ(1, - histograms.GetTotalCountsForPrefix(kHistogramName).begin()->second); - tab_data()->SetDiscardState(true); - EXPECT_EQ(1, - histograms.GetTotalCountsForPrefix(kHistogramName).begin()->second); - tab_data()->SetDiscardState(false); - EXPECT_EQ(2, - histograms.GetTotalCountsForPrefix(kHistogramName).begin()->second); -} - -TEST_F(TabManagerWebContentsDataTest, HistogramsDiscardToReloadTime) { - const char kHistogramName[] = "TabManager.Discarding.DiscardToReloadTime"; - - base::HistogramTester histograms; - - EXPECT_TRUE(histograms.GetTotalCountsForPrefix(kHistogramName).empty()); - - tab_data()->SetDiscardState(true); - test_clock().Advance(base::TimeDelta::FromSeconds(24)); - tab_data()->SetDiscardState(false); - - EXPECT_EQ(1, - histograms.GetTotalCountsForPrefix(kHistogramName).begin()->second); - - histograms.ExpectBucketCount(kHistogramName, 24000, 1); -} - -TEST_F(TabManagerWebContentsDataTest, HistogramsReloadToCloseTime) { - const char kHistogramName[] = "TabManager.Discarding.ReloadToCloseTime"; - - base::HistogramTester histograms; - - EXPECT_TRUE(histograms.GetTotalCountsForPrefix(kHistogramName).empty()); - - tab_data()->SetDiscardState(true); - tab_data()->IncrementDiscardCount(); - test_clock().Advance(base::TimeDelta::FromSeconds(5)); - tab_data()->SetDiscardState(false); - test_clock().Advance(base::TimeDelta::FromSeconds(13)); - - tab_data()->WebContentsDestroyed(); - - EXPECT_EQ(1, - histograms.GetTotalCountsForPrefix(kHistogramName).begin()->second); - - histograms.ExpectBucketCount(kHistogramName, 13000, 1); -} - -TEST_F(TabManagerWebContentsDataTest, HistogramsInactiveToReloadTime) { - const char kHistogramName[] = "TabManager.Discarding.InactiveToReloadTime"; - - base::HistogramTester histograms; - - EXPECT_TRUE(histograms.GetTotalCountsForPrefix(kHistogramName).empty()); - - tab_data()->SetLastInactiveTime(NowTicks()); - test_clock().Advance(base::TimeDelta::FromSeconds(5)); - tab_data()->SetDiscardState(true); - tab_data()->IncrementDiscardCount(); - test_clock().Advance(base::TimeDelta::FromSeconds(7)); - tab_data()->SetDiscardState(false); - - EXPECT_EQ(1, - histograms.GetTotalCountsForPrefix(kHistogramName).begin()->second); - - histograms.ExpectBucketCount(kHistogramName, 12000, 1); -} - TEST_F(TabManagerWebContentsDataTest, IsInSessionRestoreWithTabLoading) { EXPECT_FALSE(tab_data()->is_in_session_restore()); tab_data()->SetIsInSessionRestore(true);
diff --git a/chrome/browser/resource_coordinator/tab_stats.cc b/chrome/browser/resource_coordinator/tab_stats.cc deleted file mode 100644 index 9a9f5376..0000000 --- a/chrome/browser/resource_coordinator/tab_stats.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 "chrome/browser/resource_coordinator/tab_stats.h" -#include "build/build_config.h" - -namespace resource_coordinator { - -TabStats::TabStats() = default; - -TabStats::TabStats(const TabStats& other) = default; - -TabStats::TabStats(TabStats&& other) noexcept = default; - -TabStats::~TabStats() {} - -TabStats& TabStats::operator=(const TabStats& other) = default; - -} // namespace resource_coordinator
diff --git a/chrome/browser/resource_coordinator/tab_stats.h b/chrome/browser/resource_coordinator/tab_stats.h deleted file mode 100644 index 7dd270d..0000000 --- a/chrome/browser/resource_coordinator/tab_stats.h +++ /dev/null
@@ -1,65 +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 CHROME_BROWSER_RESOURCE_COORDINATOR_TAB_STATS_H_ -#define CHROME_BROWSER_RESOURCE_COORDINATOR_TAB_STATS_H_ - -#include <stdint.h> - -#include <vector> - -#include "base/process/process.h" -#include "base/strings/string16.h" -#include "base/time/time.h" -#include "build/build_config.h" - -namespace content { -class RenderProcessHost; -} // namespace content - -namespace resource_coordinator { - -struct TabStats { - TabStats(); - TabStats(const TabStats& other); - TabStats(TabStats&& other) noexcept; - ~TabStats(); - - TabStats& operator=(const TabStats& other); - - bool is_app = false; // Browser window is an app. - bool is_internal_page = false; // Internal page, such as NTP or Settings. - // Playing audio, accessing cam/mic or mirroring display. - bool is_media = false; - bool is_pinned = false; - bool is_in_visible_window = false; - bool is_in_active_window = false; - // Whether this is the active tab in a browser window. - bool is_active = false; - bool is_discarded = false; - // User has entered text in a form. - bool has_form_entry = false; - int discard_count = 0; - bool has_beforeunload_handler = false; - base::TimeTicks last_active; - content::RenderProcessHost* render_process_host = nullptr; - base::ProcessHandle renderer_handle = 0; - int child_process_host_id = 0; - std::string tab_url; - std::string favicon_url; - base::string16 title; -#if defined(OS_CHROMEOS) - int oom_score = 0; -#endif - // Unique ID for the tab. This is constant across discards/reloads and - // tab strip model manipulations. - int32_t id = 0; - bool is_auto_discardable = true; -}; - -typedef std::vector<TabStats> TabStatsList; - -} // namespace resource_coordinator - -#endif // CHROME_BROWSER_RESOURCE_COORDINATOR_TAB_STATS_H_
diff --git a/chrome/browser/resources/chromeos/emulator/audio_settings.html b/chrome/browser/resources/chromeos/emulator/audio_settings.html index 688da48..966f6bd0 100644 --- a/chrome/browser/resources/chromeos/emulator/audio_settings.html +++ b/chrome/browser/resources/chromeos/emulator/audio_settings.html
@@ -18,7 +18,7 @@ See https://github.com/Polymer/polymer/pull/3668. --> <style include="device-emulator-shared-styles cr-shared-style iron-flex iron-flex-alignment iron-positioning"> </style> - <dialog is="cr-dialog" id="editDialog"> + <cr-dialog id="editDialog"> <div slot="title">[[currentEditableObject.deviceName]]</div> <div slot="body"> <form> @@ -59,7 +59,7 @@ Done </paper-button> </div> - </dialog> + </cr-dialog> <div class="layout vertical"> <div class="element-label">
diff --git a/chrome/browser/resources/chromeos/emulator/bluetooth_settings.html b/chrome/browser/resources/chromeos/emulator/bluetooth_settings.html index 5389e24..e804c7b 100644 --- a/chrome/browser/resources/chromeos/emulator/bluetooth_settings.html +++ b/chrome/browser/resources/chromeos/emulator/bluetooth_settings.html
@@ -18,7 +18,7 @@ See https://github.com/Polymer/polymer/pull/3668. --> <style include="device-emulator-shared-styles cr-shared-style iron-flex iron-flex-alignment iron-positioning"> </style> - <dialog is="cr-dialog" id="editDialog"> + <cr-dialog id="editDialog"> <div slot="title">[[currentEditableObject.alias]]</div> <div slot="body"> <form> @@ -99,7 +99,7 @@ Close </paper-button> </div> - </dialog> + </cr-dialog> <div class="layout vertical"> <div class="element-label">
diff --git a/chrome/browser/resources/chromeos/internet_config_dialog/internet_config_dialog.html b/chrome/browser/resources/chromeos/internet_config_dialog/internet_config_dialog.html index af490f28..068a4b3 100644 --- a/chrome/browser/resources/chromeos/internet_config_dialog/internet_config_dialog.html +++ b/chrome/browser/resources/chromeos/internet_config_dialog/internet_config_dialog.html
@@ -27,13 +27,15 @@ <dom-module id="internet-config-dialog"> <template> <style include="network-shared iron-flex"> - dialog { - border-radius: 0; - height: 100%; - width: 100%; + cr-dialog { + --cr-dialog-native: { + border-radius: 0; + height: 100%; + width: 100%; + } } - dialog [slot=body] { + cr-dialog [slot=body] { /* This should match or exceed SystemWebDialogDelegate::kDialogHeight to ensure the content is stretched to fit. */ height: 480px; @@ -45,7 +47,7 @@ } </style> - <dialog is="cr-dialog" id="dialog" no-cancel> + <cr-dialog id="dialog" no-cancel> <div slot="title">[[getDialogTitle_(networkProperties_)]]</div> <div slot="body"> <network-config id="networkConfig" class="flex" @@ -72,7 +74,7 @@ $i18n{networkButtonConnect} </paper-button> </div> - </dialog> + </cr-dialog> </template> <script src="internet_config_dialog.js"></script> </dom-module>
diff --git a/chrome/browser/resources/chromeos/login/offline_ad_login.html b/chrome/browser/resources/chromeos/login/offline_ad_login.html index 9127f20a..936d518b 100644 --- a/chrome/browser/resources/chromeos/login/offline_ad_login.html +++ b/chrome/browser/resources/chromeos/login/offline_ad_login.html
@@ -71,7 +71,7 @@ </div> </gaia-card> - <dialog is="cr-dialog" id="moreOptionsDlg" on-close="onMoreOptionsClosed_"> + <cr-dialog id="moreOptionsDlg" on-close="onMoreOptionsClosed_"> <div slot="title"> $i18n{adJoinMoreOptions} </div> @@ -108,6 +108,6 @@ $i18n{adJoinConfirm} </paper-button> </div> - </dialog> + </cr-dialog> </template> </dom-module>
diff --git a/chrome/browser/resources/chromeos/login/offline_gaia.css b/chrome/browser/resources/chromeos/login/offline_gaia.css index 1033709..7e65290 100644 --- a/chrome/browser/resources/chromeos/login/offline_gaia.css +++ b/chrome/browser/resources/chromeos/login/offline_gaia.css
@@ -11,9 +11,11 @@ } #forgotPasswordDlg { - color: var(--primary-text-color); - font-size: 15px; - width: 384px; + --cr-dialog-native: { + color: var(--primary-text-color); + font-size: 15px; + width: 384px; + } } /*
diff --git a/chrome/browser/resources/chromeos/login/offline_gaia.html b/chrome/browser/resources/chromeos/login/offline_gaia.html index 351cd9a..8a3cade 100644 --- a/chrome/browser/resources/chromeos/login/offline_gaia.html +++ b/chrome/browser/resources/chromeos/login/offline_gaia.html
@@ -160,7 +160,7 @@ </neon-animated-pages> </template> - <dialog is="cr-dialog" id="forgotPasswordDlg" + <cr-dialog id="forgotPasswordDlg" on-close="onDialogOverlayClosed_"> <div slot="body" i18n-content="offlineLoginForgotPasswordDlg"></div> @@ -169,6 +169,6 @@ i18n-content="offlineLoginCloseBtn" class="action-button"> </paper-button> </div> - </dialog> + </cr-dialog> </template> </dom-module>
diff --git a/chrome/browser/resources/chromeos/login/saml_confirm_password.css b/chrome/browser/resources/chromeos/login/saml_confirm_password.css index d30b2ff6..7de5aba 100644 --- a/chrome/browser/resources/chromeos/login/saml_confirm_password.css +++ b/chrome/browser/resources/chromeos/login/saml_confirm_password.css
@@ -17,7 +17,9 @@ } #cancelConfirmDlg { - color: var(--primary-text-color); - font-size: 15px; - width: 384px; + --cr-dialog-native: { + color: var(--primary-text-color); + font-size: 15px; + width: 384px; + }; }
diff --git a/chrome/browser/resources/chromeos/login/saml_confirm_password.html b/chrome/browser/resources/chromeos/login/saml_confirm_password.html index 480cfa5..f4e948a 100644 --- a/chrome/browser/resources/chromeos/login/saml_confirm_password.html +++ b/chrome/browser/resources/chromeos/login/saml_confirm_password.html
@@ -79,7 +79,7 @@ disabled="[[disabled]]"> </navigation-bar> - <dialog is="cr-dialog" id="cancelConfirmDlg" + <cr-dialog id="cancelConfirmDlg" on-close="onDialogOverlayClosed_"> <div slot="body" i18n-content="accountSetupCancelDialogTitle"></div> @@ -91,7 +91,7 @@ i18n-content="accountSetupCancelDialogYes" on-tap="onCancelYes_"> </paper-button> </div> - </dialog> + </cr-dialog> </template> </dom-module>
diff --git a/chrome/browser/resources/chromeos/login/screen_arc_terms_of_service.css b/chrome/browser/resources/chromeos/login/screen_arc_terms_of_service.css index 021e65e0..851070bf 100644 --- a/chrome/browser/resources/chromeos/login/screen_arc_terms_of_service.css +++ b/chrome/browser/resources/chromeos/login/screen_arc_terms_of_service.css
@@ -90,6 +90,10 @@ margin: 0; } +#arc-tos-legacy .oobe-icon { + -webkit-margin-start: -36px; +} + #arc-tos-loading, #arc-tos-error { -webkit-align-items: center;
diff --git a/chrome/browser/resources/chromeos/login/screen_arc_terms_of_service.html b/chrome/browser/resources/chromeos/login/screen_arc_terms_of_service.html index d3b688e..bce9d5f 100644 --- a/chrome/browser/resources/chromeos/login/screen_arc_terms_of_service.html +++ b/chrome/browser/resources/chromeos/login/screen_arc_terms_of_service.html
@@ -1,12 +1,13 @@ <link rel="stylesheet" href="chrome://resources/css/overlay.css"> +<link rel="import" href="chrome://resources/polymer/v1_0/iron-icon/iron-icon.html"> <div class="step right hidden arc-tos-loading no-logo" id="arc-tos" role="group" hidden> <arc-tos-md id="arc-tos-md" hidden></arc-tos-md> <div id="arc-tos-legacy"> <div class="step-contents"> - <img id="arc-tos-logo" - src="https://play.google.com/about/images/play_logo.png" alt> + <iron-icon src="chrome://oobe/playstore.svg" class="oobe-icon"> + </iron-icon> <h1 i18n-content="arcTermsOfServiceScreenHeading"></h1> <h2 i18n-content="arcTermsOfServiceScreenDescription"></h2> <div id="arc-tos-container"> @@ -14,21 +15,39 @@ <div id="arc-tos-view-container"> <webview id="arc-tos-view"></webview> </div> - <label> - <a id="arc-policy-link" href="#" i18n-content="arcPolicyLink"> - </a> - </label> - <label> - <p id="arc-text-metrics"></p> - </label> - <label> - <input type="checkbox" id="arc-enable-backup-restore"> - <p i18n-values=".innerHTML:arcTextBackupRestore"></p> - </label> - <label> - <input type="checkbox" id="arc-enable-location-service"> - <p i18n-values=".innerHTML:arcTextLocationService"></p> - </label> + <div> + <label> + <a id="arc-policy-link" href="#" i18n-content="arcPolicyLink"> + </a> + </label> + </div> + <div> + <label> + <p id="arc-text-metrics"></p> + </label> + </div> + <div> + <label> + <input type="checkbox" id="arc-enable-backup-restore"> + <p i18n-values=".innerHTML:arcTextBackupRestore"></p> + </label> + </div> + <div> + <label id = "arc-location-service"> + <input type="checkbox" id="arc-enable-location-service"> + <p i18n-values=".innerHTML:arcTextLocationService"></p> + </label> + </div> + <div> + <label id="arc-pai-service"> + <p i18n-values=".innerHTML:arcTextPaiService"></p> + </label> + </div> + <div> + <label id="arc-google-service-confirmation"> + <p i18n-values=".innerHTML:arcTextGoogleServiceConfirmation"></p> + </label> + </div> </div> <div id="arc-tos-loading"> <p i18n-content="arcTermsOfServiceLoading"></p>
diff --git a/chrome/browser/resources/chromeos/login/screen_arc_terms_of_service.js b/chrome/browser/resources/chromeos/login/screen_arc_terms_of_service.js index 49491ac..855a58ff 100644 --- a/chrome/browser/resources/chromeos/login/screen_arc_terms_of_service.js +++ b/chrome/browser/resources/chromeos/login/screen_arc_terms_of_service.js
@@ -330,6 +330,7 @@ enableButtons_: function(enable) { $('arc-tos-skip-button').disabled = !enable; $('arc-tos-accept-button').disabled = !enable; + $('arc-tos-next-button').disabled = !enable; $('arc-tos-retry-button').disabled = !enable; $('arc-tos-md').arcTosButtonsDisabled = !enable; }, @@ -504,11 +505,6 @@ Oobe.getInstance().headerHidden = true; - // Reload caption image in case it was not loaded during the - // initialization phase. - $('arc-tos-logo').src = - 'https://play.google.com/about/images/play_logo.png'; - this.hideOverlay(); // ToS content may be loaded before the page is shown. In that case, // height of ToS webview is not correctly caculated. Recaculate the
diff --git a/chrome/browser/resources/md_bookmarks/command_manager.html b/chrome/browser/resources/md_bookmarks/command_manager.html index c5e38f8..12447ac7 100644 --- a/chrome/browser/resources/md_bookmarks/command_manager.html +++ b/chrome/browser/resources/md_bookmarks/command_manager.html
@@ -57,7 +57,7 @@ </cr-lazy-render> <cr-lazy-render id="openDialog"> <template> - <dialog is="cr-dialog"> + <cr-dialog> <div slot="title">$i18n{openDialogTitle}</div> <div slot="body"></div> <div slot="button-container"> @@ -68,7 +68,7 @@ $i18n{openDialogConfirm} </paper-button> </div> - </dialog> + </cr-dialog> </template> </cr-lazy-render> </template>
diff --git a/chrome/browser/resources/md_bookmarks/edit_dialog.html b/chrome/browser/resources/md_bookmarks/edit_dialog.html index 2be1feb..1fc0ecd 100644 --- a/chrome/browser/resources/md_bookmarks/edit_dialog.html +++ b/chrome/browser/resources/md_bookmarks/edit_dialog.html
@@ -11,7 +11,7 @@ <dom-module id="bookmarks-edit-dialog"> <template> <style include="cr-shared-style paper-button-style"></style> - <dialog is="cr-dialog" id="dialog"> + <cr-dialog id="dialog"> <div slot="title"> [[getDialogTitle_(isFolder_, isEdit_)]] </div> @@ -39,7 +39,7 @@ $i18n{saveEdit} </paper-button> </div> - </dialog> + </cr-dialog> </template> <script src="chrome://bookmarks/edit_dialog.js"></script> </dom-module>
diff --git a/chrome/browser/resources/md_extensions/compiled_resources2.gyp b/chrome/browser/resources/md_extensions/compiled_resources2.gyp index 39b6a26..dec283f 100644 --- a/chrome/browser/resources/md_extensions/compiled_resources2.gyp +++ b/chrome/browser/resources/md_extensions/compiled_resources2.gyp
@@ -147,6 +147,7 @@ { 'target_name': 'load_error', 'dependencies': [ + '<(DEPTH)/ui/webui/resources/cr_elements/cr_dialog/compiled_resources2.gyp:cr_dialog', '<(DEPTH)/ui/webui/resources/js/compiled_resources2.gyp:assert', '<(DEPTH)/ui/webui/resources/js/compiled_resources2.gyp:cr', '<(EXTERNS_GYP):developer_private', @@ -187,6 +188,7 @@ { 'target_name': 'options_dialog', 'dependencies': [ + '<(DEPTH)/ui/webui/resources/cr_elements/cr_dialog/compiled_resources2.gyp:cr_dialog', '<(DEPTH)/ui/webui/resources/js/compiled_resources2.gyp:assert', '<(DEPTH)/ui/webui/resources/js/compiled_resources2.gyp:cr', '<(EXTERNS_GYP):developer_private', @@ -204,6 +206,16 @@ 'includes': ['../../../../third_party/closure_compiler/compile_js2.gypi'], }, { + 'target_name': 'pack_dialog_alert', + 'dependencies': [ + '<(DEPTH)/ui/webui/resources/cr_elements/cr_dialog/compiled_resources2.gyp:cr_dialog', + '<(DEPTH)/ui/webui/resources/js/compiled_resources2.gyp:cr', + '<(DEPTH)/ui/webui/resources/js/compiled_resources2.gyp:load_time_data', + '<(EXTERNS_GYP):developer_private', + ], + 'includes': ['../../../../third_party/closure_compiler/compile_js2.gypi'], + }, + { 'target_name': 'service', 'dependencies': [ '<(DEPTH)/ui/webui/resources/js/compiled_resources2.gyp:assert',
diff --git a/chrome/browser/resources/md_extensions/install_warnings_dialog.html b/chrome/browser/resources/md_extensions/install_warnings_dialog.html index 286b25e5..b65e209 100644 --- a/chrome/browser/resources/md_extensions/install_warnings_dialog.html +++ b/chrome/browser/resources/md_extensions/install_warnings_dialog.html
@@ -20,7 +20,7 @@ padding-top: 10px; } </style> - <dialog is="cr-dialog" id="dialog" close-text="$i18n{close}"> + <cr-dialog id="dialog" close-text="$i18n{close}"> <div slot="title">$i18n{installWarnings}</div> <div slot="body"> <ul> @@ -34,7 +34,7 @@ $i18n{ok} </paper-button> </div> - </dialog> + </cr-dialog> </template> <script src="install_warnings_dialog.js"></script> </dom-module>
diff --git a/chrome/browser/resources/md_extensions/kiosk_dialog.html b/chrome/browser/resources/md_extensions/kiosk_dialog.html index e85ab696..5fe53138 100644 --- a/chrome/browser/resources/md_extensions/kiosk_dialog.html +++ b/chrome/browser/resources/md_extensions/kiosk_dialog.html
@@ -75,7 +75,7 @@ visibility: visible; } </style> - <dialog is="cr-dialog" id="dialog" close-text="$i18n{close}" + <cr-dialog id="dialog" close-text="$i18n{close}" ignore-enter-key> <div slot="title">$i18n{manageKioskApp}</div> <div slot="body"> @@ -131,8 +131,8 @@ $i18n{done} </paper-button> </div> - </dialog> - <dialog is="cr-dialog" id="confirm-dialog" close-text="$i18n{close}" + </cr-dialog> + <cr-dialog id="confirm-dialog" close-text="$i18n{close}" ignore-enter-key on-close="stopPropagation_"> <div slot="title">$i18n{kioskDisableBailoutWarningTitle}</div> <div slot="body">$i18n{kioskDisableBailoutWarningBody}</div> @@ -146,7 +146,7 @@ $i18n{confirm} </paper-button> </div> - </dialog> + </cr-dialog> </template> <script src="kiosk_dialog.js"></script> </dom-module>
diff --git a/chrome/browser/resources/md_extensions/load_error.html b/chrome/browser/resources/md_extensions/load_error.html index 10080e15..32693f9 100644 --- a/chrome/browser/resources/md_extensions/load_error.html +++ b/chrome/browser/resources/md_extensions/load_error.html
@@ -21,7 +21,7 @@ width: 104px; /* Magic number from the specs. */ } </style> - <dialog is="cr-dialog" id="dialog" close-text="$i18n{close}"> + <cr-dialog id="dialog" close-text="$i18n{close}"> <div slot="title">$i18n{loadErrorHeading}</div> <div slot="body"> <div id="info"> @@ -48,7 +48,7 @@ $i18n{loadErrorRetry} </paper-button> </div> - </dialog> + </cr-dialog> </template> <script src="load_error.js"></script> </dom-module>
diff --git a/chrome/browser/resources/md_extensions/load_error.js b/chrome/browser/resources/md_extensions/load_error.js index 8c22a6b..be8d902 100644 --- a/chrome/browser/resources/md_extensions/load_error.js +++ b/chrome/browser/resources/md_extensions/load_error.js
@@ -33,11 +33,11 @@ ], show: function() { - this.$$('dialog').showModal(); + /** @type {!CrDialogElement} */ (this.$.dialog).showModal(); }, close: function() { - this.$$('dialog').close(); + /** @type {!CrDialogElement} */ (this.$.dialog).close(); }, /** @private */
diff --git a/chrome/browser/resources/md_extensions/options_dialog.html b/chrome/browser/resources/md_extensions/options_dialog.html index 524b35a..76b427a 100644 --- a/chrome/browser/resources/md_extensions/options_dialog.html +++ b/chrome/browser/resources/md_extensions/options_dialog.html
@@ -26,7 +26,7 @@ overflow: hidden; } - dialog { + cr-dialog { --scroll-border: 0; --cr-dialog-body: { height: 100%; @@ -47,7 +47,7 @@ } </style> - <dialog is="cr-dialog" id="dialog" close-text="$i18n{close}" + <cr-dialog id="dialog" close-text="$i18n{close}" on-close="onClose_"> <div slot="title"> <div id="icon-and-name-wrapper"> @@ -61,7 +61,7 @@ </div> <div slot="body" id="body"> </div> - </dialog> + </cr-dialog> </template> <script src="options_dialog.js"></script> </dom-module>
diff --git a/chrome/browser/resources/md_extensions/options_dialog.js b/chrome/browser/resources/md_extensions/options_dialog.js index e5dbb639..20237db8 100644 --- a/chrome/browser/resources/md_extensions/options_dialog.js +++ b/chrome/browser/resources/md_extensions/options_dialog.js
@@ -41,7 +41,7 @@ boundResizeListener_: null, get open() { - return this.$$('dialog').open; + return /** @type {!CrDialogElement} */ (this.$.dialog).open; }, /** @@ -54,8 +54,12 @@ updateDialogSize_: function(width, height) { const effectiveHeight = Math.min(window.innerHeight, height); const effectiveWidth = Math.min(window.innerWidth, width); - this.$.dialog.style.height = effectiveHeight + 'px'; - this.$.dialog.style.width = effectiveWidth + 'px'; + + // Get a reference to the inner native <dialog>. + const nativeDialog = + /** @type {!CrDialogElement} */ (this.$.dialog).getNative(); + nativeDialog.style.height = effectiveHeight + 'px'; + nativeDialog.style.width = effectiveWidth + 'px'; }, /** @param {chrome.developerPrivate.ExtensionInfo} data */ @@ -71,7 +75,7 @@ const onSizeChanged = e => { preferredSize = e; this.updateDialogSize_(preferredSize.width, preferredSize.height); - this.$$('dialog').showModal(); + this.$.dialog.showModal(); this.extensionOptions_.onpreferredsizechanged = null; }; @@ -91,7 +95,7 @@ }, close: function() { - this.$$('dialog').close(); + /** @type {!CrDialogElement} */ (this.$.dialog).close(); this.extensionOptions_.onpreferredsizechanged = null; },
diff --git a/chrome/browser/resources/md_extensions/pack_dialog.html b/chrome/browser/resources/md_extensions/pack_dialog.html index e984b8565..ce51758 100644 --- a/chrome/browser/resources/md_extensions/pack_dialog.html +++ b/chrome/browser/resources/md_extensions/pack_dialog.html
@@ -28,7 +28,7 @@ color: var(--google-blue-500); } </style> - <dialog is="cr-dialog" id="dialog" close-text="$i18n{close}"> + <cr-dialog id="dialog" close-text="$i18n{close}"> <div slot="title">$i18n{packDialogTitle}</div> <div slot="body"> <div>$i18n{packDialogContent}</div> @@ -58,7 +58,7 @@ $i18n{packDialogConfirm} </paper-button> </div> - </dialog> + </cr-dialog> <template is="dom-if" if="[[lastResponse_]]" restamp> <extensions-pack-dialog-alert model="[[lastResponse_]]" on-close="onAlertClose_">
diff --git a/chrome/browser/resources/md_extensions/pack_dialog_alert.html b/chrome/browser/resources/md_extensions/pack_dialog_alert.html index ebf69a9..79fa1a74 100644 --- a/chrome/browser/resources/md_extensions/pack_dialog_alert.html +++ b/chrome/browser/resources/md_extensions/pack_dialog_alert.html
@@ -16,7 +16,7 @@ } </style> - <dialog is="cr-dialog" id="dialog" close-text="$i18n{close}"> + <cr-dialog id="dialog" close-text="$i18n{close}"> <div class="title" slot="title">[[title_]]</div> <!-- No whitespace or new-lines allowed within the div.body tag. --> <div class="body" slot="body">[[model.message]]</div> @@ -30,7 +30,7 @@ [[confirmLabel_]] </paper-button> </div> - </dialog> + </cr-dialog> </template> <script src="pack_dialog_alert.js"></script> </dom-module>
diff --git a/chrome/browser/resources/md_extensions/pack_dialog_alert.js b/chrome/browser/resources/md_extensions/pack_dialog_alert.js index 7c3e475..9b33668 100644 --- a/chrome/browser/resources/md_extensions/pack_dialog_alert.js +++ b/chrome/browser/resources/md_extensions/pack_dialog_alert.js
@@ -17,12 +17,12 @@ /** @private */ message_: String, - /** @private */ + /** @private {?string} */ cancelLabel_: String, /** * This needs to be initialized to trigger data-binding. - * @private + * @private {?string} */ confirmLabel_: { type: String, @@ -32,7 +32,9 @@ /** @return {string} */ get returnValue() { - return this.$.dialog.returnValue; + return /** @type {!CrDialogElement} */ (this.$.dialog) + .getNative() + .returnValue; }, /** @override */
diff --git a/chrome/browser/resources/md_history/history_list.html b/chrome/browser/resources/md_history/history_list.html index 5a86619..dae8f5e 100644 --- a/chrome/browser/resources/md_history/history_list.html +++ b/chrome/browser/resources/md_history/history_list.html
@@ -60,7 +60,7 @@ <cr-lazy-render id="dialog"> <template> - <dialog is="cr-dialog"> + <cr-dialog> <div slot="title">$i18n{removeSelected}</div> <div slot="body">$i18n{deleteWarning}</div> <div slot="button-container"> @@ -71,7 +71,7 @@ $i18n{deleteConfirm} </paper-button> </div> - </dialog> + </cr-dialog> </template> </cr-lazy-render>
diff --git a/chrome/browser/resources/md_user_manager/error_dialog.html b/chrome/browser/resources/md_user_manager/error_dialog.html index a55ec1bf..9cae3a5 100644 --- a/chrome/browser/resources/md_user_manager/error_dialog.html +++ b/chrome/browser/resources/md_user_manager/error_dialog.html
@@ -16,11 +16,11 @@ word-wrap: break-word; } </style> - <dialog is="cr-dialog" id="dialog"> + <cr-dialog id="dialog"> <div slot="body"> <div id="message">[[message_]]</div> </div> - </dialog> + </cr-dialog> </template> <script src="error_dialog.js"></script> </dom-module>
diff --git a/chrome/browser/resources/md_user_manager/import_supervised_user.html b/chrome/browser/resources/md_user_manager/import_supervised_user.html index b308c93..73b108c 100644 --- a/chrome/browser/resources/md_user_manager/import_supervised_user.html +++ b/chrome/browser/resources/md_user_manager/import_supervised_user.html
@@ -62,7 +62,7 @@ flex-shrink: 0; } </style> - <dialog is="cr-dialog" id="dialog"> + <cr-dialog id="dialog"> <div slot="title">$i18n{supervisedUserImportTitle}</div> <div slot="body"> <div id="message">$i18n{supervisedUserImportText}</div> @@ -88,7 +88,7 @@ $i18n{supervisedUserImportOk} </paper-button> </div> - </dialog> + </cr-dialog> </template> <script src="import_supervised_user.js"></script> </dom-module>
diff --git a/chrome/browser/resources/pdf/elements/viewer-error-screen/viewer-error-screen.html b/chrome/browser/resources/pdf/elements/viewer-error-screen/viewer-error-screen.html index 6844a00..b5032db 100644 --- a/chrome/browser/resources/pdf/elements/viewer-error-screen/viewer-error-screen.html +++ b/chrome/browser/resources/pdf/elements/viewer-error-screen/viewer-error-screen.html
@@ -6,7 +6,7 @@ <dom-module id="viewer-error-screen"> <template> <style include="cr-shared-style"></style> - <dialog is="cr-dialog" id="dialog" no-cancel> + <cr-dialog id="dialog" no-cancel> <div slot="title"> [[strings.errorDialogTitle]] </div> @@ -18,7 +18,7 @@ [[strings.pageReload]] </paper-button> </div> - </dialog> + </cr-dialog> </template> <script src="viewer-error-screen.js"></script> </dom-module>
diff --git a/chrome/browser/resources/pdf/elements/viewer-password-screen/viewer-password-screen.html b/chrome/browser/resources/pdf/elements/viewer-password-screen/viewer-password-screen.html index 485a061..8259dac 100644 --- a/chrome/browser/resources/pdf/elements/viewer-password-screen/viewer-password-screen.html +++ b/chrome/browser/resources/pdf/elements/viewer-password-screen/viewer-password-screen.html
@@ -15,7 +15,7 @@ }; } </style> - <dialog is="cr-dialog" id="dialog" no-cancel> + <cr-dialog id="dialog" no-cancel> <div slot="title">[[strings.passwordDialogTitle]]</div> <div slot="body"> <div id="message">[[strings.passwordPrompt]]</div> @@ -32,7 +32,7 @@ [[strings.passwordSubmit]] </paper-button> </div> - </dialog> + </cr-dialog> </template> <script src="viewer-password-screen.js"></script> </dom-module>
diff --git a/chrome/browser/resources/print_preview/new/advanced_settings_dialog.html b/chrome/browser/resources/print_preview/new/advanced_settings_dialog.html index 91e920b53..bc4b5856 100644 --- a/chrome/browser/resources/print_preview/new/advanced_settings_dialog.html +++ b/chrome/browser/resources/print_preview/new/advanced_settings_dialog.html
@@ -14,7 +14,7 @@ <style include="print-preview-shared search-dialog button cr-hidden-style"> </style> <template> - <dialog is="cr-dialog" id="dialog" on-close="onCloseOrCancel_"> + <cr-dialog id="dialog" on-close="onCloseOrCancel_"> <div slot="title"> <div>[[i18n('advancedSettingsDialogTitle', destination.displayName)]] </div> @@ -41,7 +41,7 @@ $i18n{advancedSettingsDialogConfirm} </button> </div> - </dialog> + </cr-dialog> </template> <script src="advanced_settings_dialog.js"></script> </dom-module>
diff --git a/chrome/browser/resources/print_preview/new/destination_dialog.html b/chrome/browser/resources/print_preview/new/destination_dialog.html index 380dc64..e740071 100644 --- a/chrome/browser/resources/print_preview/new/destination_dialog.html +++ b/chrome/browser/resources/print_preview/new/destination_dialog.html
@@ -20,7 +20,11 @@ <template> <style include="print-preview-shared button action-link select cr-hidden-style search-dialog throbber"> :host #dialog { - width: 640px; + --cr-dialog-native: { + box-shadow: 0 4px 23px 5px rgba(0, 0, 0, 0.2), + 0 2px 6px rgba(0, 0, 0, 0.15); + width: 640px; + } } :host .user-info { @@ -95,7 +99,7 @@ -webkit-margin-start: 10px; } </style> - <dialog is="cr-dialog" id="dialog" on-close="onCloseOrCancel_"> + <cr-dialog id="dialog" on-close="onCloseOrCancel_"> <div slot="title"> <div>$i18n{destinationSearchTitle}</div> <div class="user-info" hidden$="[[!userInfo.loggedIn]]"> @@ -160,7 +164,7 @@ </div> </div> </div> - </dialog> + </cr-dialog> </template> <script src="destination_dialog.js"></script> </dom-module>
diff --git a/chrome/browser/resources/print_preview/new/search_dialog_css.html b/chrome/browser/resources/print_preview/new/search_dialog_css.html index 6ec2597..90db69a 100644 --- a/chrome/browser/resources/print_preview/new/search_dialog_css.html +++ b/chrome/browser/resources/print_preview/new/search_dialog_css.html
@@ -8,31 +8,32 @@ <dom-module id="search-dialog"> <template> <style include="print-preview-shared button"> - #dialog::backdrop { - background-color: rgba(255, 255, 255, 0.75); - } - #dialog { + /* TODO(dpapad): Figure out how to specify + background-color: rgba(255, 255, 255, 0.75) for the inner dialog's + backdrop. See context at crbug.com/827397 */ --cr-dialog-close-image: { background-image: url(chrome://theme/IDR_CLOSE_DIALOG); - } + }; --cr-dialog-close-image-active: { background-image: url(chrome://theme/IDR_CLOSE_DIALOG_P); - } + }; --cr-dialog-close-image-hover: { background-image: url(chrome://theme/IDR_CLOSE_DIALOG_H); - } + }; + --cr-dialog-native: { + box-shadow: 0 4px 23px 5px rgba(0, 0, 0, 0.2), + 0 2px 6px rgba(0, 0, 0, 0.15); + }; --cr-icon-ripple-size: 0; --cr-icon-size: 14px; --cr-dialog-body: { box-sizing: border-box; padding-top: 0; - } + }; --cr-dialog-wrapper: { max-height: calc(100vh - 40px); - } - box-shadow: 0 4px 23px 5px rgba(0, 0, 0, 0.2), - 0 2px 6px rgba(0, 0, 0, 0.15); + }; } #searchBox {
diff --git a/chrome/browser/resources/settings/about_page/channel_switcher_dialog.html b/chrome/browser/resources/settings/about_page/channel_switcher_dialog.html index 70cbc55e..32ef3ea 100644 --- a/chrome/browser/resources/settings/about_page/channel_switcher_dialog.html +++ b/chrome/browser/resources/settings/about_page/channel_switcher_dialog.html
@@ -15,7 +15,7 @@ display: none; } </style> - <dialog is="cr-dialog" id="dialog" close-text="$i18n{close}"> + <cr-dialog id="dialog" close-text="$i18n{close}"> <div slot="title">$i18n{aboutChangeChannel}</div> <div slot="body"> <!-- TODO(dbeam): this can be policy-controlled. Show this in the UI. @@ -66,7 +66,7 @@ $i18n{aboutChangeChannelAndPowerwash} </paper-button> </div> - </dialog> + </cr-dialog> </template> <script src="channel_switcher_dialog.js"></script> </dom-module>
diff --git a/chrome/browser/resources/settings/about_page/update_warning_dialog.html b/chrome/browser/resources/settings/about_page/update_warning_dialog.html index e6dd4ab..73621cfe 100644 --- a/chrome/browser/resources/settings/about_page/update_warning_dialog.html +++ b/chrome/browser/resources/settings/about_page/update_warning_dialog.html
@@ -9,7 +9,7 @@ <dom-module id="settings-update-warning-dialog"> <template> <style include="settings-shared"></style> - <dialog is="cr-dialog" id="dialog" close-text="$i18n{close}"> + <cr-dialog id="dialog" close-text="$i18n{close}"> <div slot="title">$i18n{aboutUpdateWarningTitle}</div> <div slot="body"> <div id="update-warning-message"></div> @@ -22,7 +22,7 @@ $i18n{aboutUpdateWarningContinue} </paper-button> </div> - </dialog> + </cr-dialog> </template> <script src="update_warning_dialog.js"></script> </dom-module>
diff --git a/chrome/browser/resources/settings/android_apps_page/android_apps_subpage.html b/chrome/browser/resources/settings/android_apps_page/android_apps_subpage.html index 8f2d54ad..11164e29 100644 --- a/chrome/browser/resources/settings/android_apps_page/android_apps_subpage.html +++ b/chrome/browser/resources/settings/android_apps_page/android_apps_subpage.html
@@ -30,7 +30,7 @@ </template> <!-- Confirm disable android apps dialog --> - <dialog is="cr-dialog" id="confirmDisableDialog" close-text="$i18n{close}" + <cr-dialog id="confirmDisableDialog" close-text="$i18n{close}" on-cancel="onConfirmDisableDialogCancel_" on-close="onConfirmDisableDialogClose_"> <div slot="title">$i18n{androidAppsDisableDialogTitle}</div> @@ -45,7 +45,7 @@ $i18n{androidAppsDisableDialogRemove} </paper-button> </div> - </dialog> + </cr-dialog> </template> <script src="android_apps_subpage.js"></script>
diff --git a/chrome/browser/resources/settings/clear_browsing_data_dialog/clear_browsing_data_dialog.html b/chrome/browser/resources/settings/clear_browsing_data_dialog/clear_browsing_data_dialog.html index dbbc94a3..40e0062a 100644 --- a/chrome/browser/resources/settings/clear_browsing_data_dialog/clear_browsing_data_dialog.html +++ b/chrome/browser/resources/settings/clear_browsing_data_dialog/clear_browsing_data_dialog.html
@@ -114,7 +114,7 @@ } </style> - <dialog is="cr-dialog" id="clearBrowsingDataDialog" + <cr-dialog id="clearBrowsingDataDialog" on-close="onClearBrowsingDataDialogClose_" close-text="$i18n{close}" ignore-popstate has-tabs> <div slot="title"> @@ -259,10 +259,10 @@ $i18n{clearData} </paper-button> </div> - </dialog> + </cr-dialog> <template is="dom-if" if="[[showImportantSitesDialog_]]"> - <dialog is="cr-dialog" id="importantSitesDialog" close-text="$i18n{close}" + <cr-dialog id="importantSitesDialog" close-text="$i18n{close}" show-scroll-borders ignore-popstate> <div slot="title"> $i18n{clearBrowsingData} @@ -296,7 +296,7 @@ $i18n{importantSitesConfirm} </paper-button> </div> - </dialog> + </cr-dialog> </template> <template is="dom-if" if="[[showHistoryDeletionDialog_]]" restamp>
diff --git a/chrome/browser/resources/settings/clear_browsing_data_dialog/history_deletion_dialog.html b/chrome/browser/resources/settings/clear_browsing_data_dialog/history_deletion_dialog.html index 52429899..5ca1761 100644 --- a/chrome/browser/resources/settings/clear_browsing_data_dialog/history_deletion_dialog.html +++ b/chrome/browser/resources/settings/clear_browsing_data_dialog/history_deletion_dialog.html
@@ -7,7 +7,7 @@ <template> <style include="settings-shared"></style> - <dialog is="cr-dialog" id="dialog" close-text="$i18n{close}"> + <cr-dialog id="dialog" close-text="$i18n{close}"> <div slot="title">$i18n{historyDeletionDialogTitle}</div> <div slot="body">$i18nRaw{historyDeletionDialogBody}</div> <div slot="button-container"> @@ -15,7 +15,7 @@ $i18n{historyDeletionDialogOK} </paper-button> </div> - </dialog> + </cr-dialog> </template> <script src="history_deletion_dialog.js"></script> </dom-module>
diff --git a/chrome/browser/resources/settings/device_page/display_overscan_dialog.html b/chrome/browser/resources/settings/device_page/display_overscan_dialog.html index 5c90de1c..c5b2d74 100644 --- a/chrome/browser/resources/settings/device_page/display_overscan_dialog.html +++ b/chrome/browser/resources/settings/device_page/display_overscan_dialog.html
@@ -43,7 +43,7 @@ padding: 4px 8px 0; } </style> - <dialog is="cr-dialog" id="dialog" on-close="close" + <cr-dialog id="dialog" on-close="close" close-text="$i18n{close}"> <div slot="title">$i18n{displayOverscanPageTitle}</div> <div slot="body"> @@ -81,7 +81,7 @@ $i18n{ok} </paper-button> </div> - </dialog> + </cr-dialog> </template> <script src="display_overscan_dialog.js"></script> </dom-module>
diff --git a/chrome/browser/resources/settings/device_page/drive_cache_dialog.html b/chrome/browser/resources/settings/device_page/drive_cache_dialog.html index d111fcf..c493176b 100644 --- a/chrome/browser/resources/settings/device_page/drive_cache_dialog.html +++ b/chrome/browser/resources/settings/device_page/drive_cache_dialog.html
@@ -8,7 +8,7 @@ <dom-module id="settings-drive-cache-dialog"> <template> <style include="settings-shared"></style> - <dialog is="cr-dialog" id="dialog" close-text="$i18n{close}"> + <cr-dialog id="dialog" close-text="$i18n{close}"> <div slot="title"> $i18n{storageClearDriveCacheDialogTitle} </div> @@ -25,7 +25,7 @@ $i18n{storageDeleteAllButtonTitle} </paper-button> </div> - </dialog> + </cr-dialog> </template> <script src="drive_cache_dialog.js"></script> </dom-module>
diff --git a/chrome/browser/resources/settings/internet_page/internet_config.html b/chrome/browser/resources/settings/internet_page/internet_config.html index fce0c7e..8e2b173 100644 --- a/chrome/browser/resources/settings/internet_page/internet_config.html +++ b/chrome/browser/resources/settings/internet_page/internet_config.html
@@ -11,8 +11,10 @@ <dom-module id="internet-config"> <template> <style include="internet-shared iron-flex"> - dialog { - width: 460px; + cr-dialog { + --cr-dialog-native: { + width: 460px; + }; } .error { @@ -21,7 +23,7 @@ } </style> - <dialog is="cr-dialog" id="dialog" close-text="$i18n{close}"> + <cr-dialog id="dialog" close-text="$i18n{close}"> <div slot="title">[[getDialogTitle_(networkProperties_)]]</div> <div slot="body"> <network-config id="networkConfig" class="flex" @@ -57,7 +59,7 @@ </template> </div> - </dialog> + </cr-dialog> </template> <script src="internet_config.js"></script> </dom-module>
diff --git a/chrome/browser/resources/settings/internet_page/network_proxy_section.html b/chrome/browser/resources/settings/internet_page/network_proxy_section.html index 7aa2e64..146da4c1 100644 --- a/chrome/browser/resources/settings/internet_page/network_proxy_section.html +++ b/chrome/browser/resources/settings/internet_page/network_proxy_section.html
@@ -77,7 +77,7 @@ </div> <!-- Confirm Allow shared proxies dialog --> - <dialog is="cr-dialog" id="confirmAllowSharedDialog" + <cr-dialog id="confirmAllowSharedDialog" close-text="$i18n{close}" on-cancel="onAllowSharedDialogCancel_" on-close="onAllowSharedDialogClose_"> <div slot="title"> @@ -98,7 +98,7 @@ $i18n{confirm} </paper-button> </div> - </dialog> + </cr-dialog> </template> <script src="network_proxy_section.js"></script> </dom-module>
diff --git a/chrome/browser/resources/settings/internet_page/tether_connection_dialog.html b/chrome/browser/resources/settings/internet_page/tether_connection_dialog.html index c54c5c1..2a305ca 100644 --- a/chrome/browser/resources/settings/internet_page/tether_connection_dialog.html +++ b/chrome/browser/resources/settings/internet_page/tether_connection_dialog.html
@@ -66,7 +66,7 @@ font-weight: 500; } </style> - <dialog is="cr-dialog" id="dialog" close-text="$i18n{close}"> + <cr-dialog id="dialog" close-text="$i18n{close}"> <div slot="title">$i18n{tetherConnectionDialogTitle}</div> <div slot="body"> <span id="availability-title"> @@ -116,7 +116,7 @@ $i18n{tetherConnectionConnectButton} </paper-button> </div> - </dialog> + </cr-dialog> </template> <script src="tether_connection_dialog.js"></script> </dom-module>
diff --git a/chrome/browser/resources/settings/languages_page/add_languages_dialog.html b/chrome/browser/resources/settings/languages_page/add_languages_dialog.html index a3f6edd..e143de5 100644 --- a/chrome/browser/resources/settings/languages_page/add_languages_dialog.html +++ b/chrome/browser/resources/settings/languages_page/add_languages_dialog.html
@@ -39,7 +39,7 @@ } } </style> - <dialog is="cr-dialog" id="dialog" close-text="$i18n{close}"> + <cr-dialog id="dialog" close-text="$i18n{close}"> <div slot="title">$i18n{addLanguagesDialogTitle}</div> <div slot="body" scrollable> <settings-subpage-search label="[[searchLabel]]" @@ -67,7 +67,7 @@ $i18n{add} </paper-button> </div> - </dialog> + </cr-dialog> </template> <script src="add_languages_dialog.js"></script> </dom-module>
diff --git a/chrome/browser/resources/settings/on_startup_page/startup_url_dialog.html b/chrome/browser/resources/settings/on_startup_page/startup_url_dialog.html index 313bdf7a..fb74c039 100644 --- a/chrome/browser/resources/settings/on_startup_page/startup_url_dialog.html +++ b/chrome/browser/resources/settings/on_startup_page/startup_url_dialog.html
@@ -9,7 +9,7 @@ <dom-module id="settings-startup-url-dialog"> <template> <style include="settings-shared"></style> - <dialog is="cr-dialog" id="dialog" close-text="$i18n{close}"> + <cr-dialog id="dialog" close-text="$i18n{close}"> <div slot="title">[[dialogTitle_]]</div> <div slot="body"> <paper-input always-float-label id="url" label="$i18n{onStartupSiteUrl}" @@ -26,7 +26,7 @@ <paper-button id="actionButton" class="action-button" on-click="onActionButtonTap_">[[actionButtonText_]]</paper-button> </div> - </dialog> + </cr-dialog> </template> <script src="startup_url_dialog.js"></script> </dom-module>
diff --git a/chrome/browser/resources/settings/passwords_and_forms_page/address_edit_dialog.html b/chrome/browser/resources/settings/passwords_and_forms_page/address_edit_dialog.html index 8d6515df..539781b 100644 --- a/chrome/browser/resources/settings/passwords_and_forms_page/address_edit_dialog.html +++ b/chrome/browser/resources/settings/passwords_and_forms_page/address_edit_dialog.html
@@ -92,7 +92,7 @@ transform: translate3d(0, 0, 0); } </style> - <dialog is="cr-dialog" id="dialog" close-text="$i18n{close}"> + <cr-dialog id="dialog" close-text="$i18n{close}"> <div slot="title">[[title_]]</div> <div slot="body"> <template is="dom-repeat" items="[[addressWrapper_]]"> @@ -152,7 +152,7 @@ $i18n{save} </paper-button> </div> - </dialog> + </cr-dialog> </template> <script src="address_edit_dialog.js"></script> </dom-module>
diff --git a/chrome/browser/resources/settings/passwords_and_forms_page/credit_card_edit_dialog.html b/chrome/browser/resources/settings/passwords_and_forms_page/credit_card_edit_dialog.html index 6465c600..9a522be 100644 --- a/chrome/browser/resources/settings/passwords_and_forms_page/credit_card_edit_dialog.html +++ b/chrome/browser/resources/settings/passwords_and_forms_page/credit_card_edit_dialog.html
@@ -49,7 +49,7 @@ padding-top: 8px; } </style> - <dialog is="cr-dialog" id="dialog" close-text="$i18n{close}"> + <cr-dialog id="dialog" close-text="$i18n{close}"> <div slot="title">[[title_]]</div> <div slot="body"> <paper-input id="nameInput" label="$i18n{creditCardName}" @@ -93,7 +93,7 @@ <paper-button id="saveButton" class="action-button" on-click="onSaveButtonTap_" disabled>$i18n{save}</paper-button> </div> - </dialog> + </cr-dialog> </template> <script src="credit_card_edit_dialog.js"></script> </dom-module>
diff --git a/chrome/browser/resources/settings/passwords_and_forms_page/password_edit_dialog.html b/chrome/browser/resources/settings/passwords_and_forms_page/password_edit_dialog.html index 89ad315..05d713e 100644 --- a/chrome/browser/resources/settings/passwords_and_forms_page/password_edit_dialog.html +++ b/chrome/browser/resources/settings/passwords_and_forms_page/password_edit_dialog.html
@@ -40,7 +40,7 @@ background-size: 24px; /* Other buttons are sized by --cr-icon-size. */ } </style> - <dialog is="cr-dialog" id="dialog" close-text="$i18n{close}"> + <cr-dialog id="dialog" close-text="$i18n{close}"> <div slot="title">$i18n{passwordDetailsTitle}</div> <div slot="body"> <paper-input id="websiteInput" label="$i18n{editPasswordWebsiteLabel}" @@ -75,7 +75,7 @@ $i18n{done} </paper-button> </div> - </dialog> + </cr-dialog> </template> <script src="password_edit_dialog.js"></script> </dom-module>
diff --git a/chrome/browser/resources/settings/passwords_and_forms_page/passwords_export_dialog.html b/chrome/browser/resources/settings/passwords_and_forms_page/passwords_export_dialog.html index 2cfe136..33e3643 100644 --- a/chrome/browser/resources/settings/passwords_and_forms_page/passwords_export_dialog.html +++ b/chrome/browser/resources/settings/passwords_and_forms_page/passwords_export_dialog.html
@@ -16,7 +16,7 @@ -webkit-margin-start: 8px; } </style> - <dialog is="cr-dialog" id="dialog_start" close-text="$i18n{close}"> + <cr-dialog id="dialog_start" close-text="$i18n{close}"> <div slot="title">$i18n{exportPasswordsTitle}</div> <div slot="body"> <div class="layout horizontal center"> @@ -33,9 +33,9 @@ $i18n{exportPasswords} </paper-button> </div> - </dialog> + </cr-dialog> - <dialog is="cr-dialog" id="dialog_progress" no-cancel="true"> + <cr-dialog id="dialog_progress" no-cancel="true"> <div slot="title">$i18n{exportingPasswordsTitle}</div> <div slot="body"> <paper-progress indeterminate class="blue"></paper-progress> @@ -47,9 +47,9 @@ $i18n{cancel} </paper-button> </div> - </dialog> + </cr-dialog> - <dialog is="cr-dialog" id="dialog_error" close-text="$i18n{close}"> + <cr-dialog id="dialog_error" close-text="$i18n{close}"> <div slot="title">[[exportErrorMessage]]</div> <div slot="body"> $i18n{exportPasswordsFailTips} @@ -68,7 +68,7 @@ $i18n{exportPasswordsTryAgain} </paper-button> </div> - </dialog> + </cr-dialog> </template> <script src="passwords_export_dialog.js"></script>
diff --git a/chrome/browser/resources/settings/people_page/easy_unlock_turn_off_dialog.html b/chrome/browser/resources/settings/people_page/easy_unlock_turn_off_dialog.html index dd65510..df78b847 100644 --- a/chrome/browser/resources/settings/people_page/easy_unlock_turn_off_dialog.html +++ b/chrome/browser/resources/settings/people_page/easy_unlock_turn_off_dialog.html
@@ -12,7 +12,7 @@ <dom-module id="easy-unlock-turn-off-dialog"> <template> <style include="settings-shared"></style> - <dialog is="cr-dialog" id="dialog" close-text="$i18n{close}"> + <cr-dialog id="dialog" close-text="$i18n{close}"> <div slot="title">[[getTitleText_(status_)]]</div> <div slot="body"> [[getDescriptionText_(status_)]] @@ -31,7 +31,7 @@ [[getTurnOffButtonText_(status_)]] </paper-button> </div> - </dialog> + </cr-dialog> </template> <script src="easy_unlock_turn_off_dialog.js"></script> </dom-module>
diff --git a/chrome/browser/resources/settings/people_page/import_data_dialog.html b/chrome/browser/resources/settings/people_page/import_data_dialog.html index cb07d33..395da90 100644 --- a/chrome/browser/resources/settings/people_page/import_data_dialog.html +++ b/chrome/browser/resources/settings/people_page/import_data_dialog.html
@@ -35,7 +35,7 @@ width: 100%; } </style> - <dialog is="cr-dialog" id="dialog" close-text="$i18n{close}" + <cr-dialog id="dialog" close-text="$i18n{close}" ignore-popstate> <div slot="title">$i18n{importTitle}</div> <div slot="body"> @@ -121,7 +121,7 @@ importStatusEnum_.SUCCEEDED, importStatus_)]]" on-click="closeDialog_">$i18n{done}</paper-button> </div> - </dialog> + </cr-dialog> </template> <script src="import_data_dialog.js"></script> :</dom-module>
diff --git a/chrome/browser/resources/settings/people_page/password_prompt_dialog.html b/chrome/browser/resources/settings/people_page/password_prompt_dialog.html index 3a5e4b6..0aafe38 100644 --- a/chrome/browser/resources/settings/people_page/password_prompt_dialog.html +++ b/chrome/browser/resources/settings/people_page/password_prompt_dialog.html
@@ -18,7 +18,7 @@ } </style> - <dialog is="cr-dialog" id="dialog" close-text="$i18n{close}"> + <cr-dialog id="dialog" close-text="$i18n{close}"> <div slot="title">$i18n{passwordPromptTitle}</div> <div slot="body"> @@ -42,7 +42,7 @@ $i18n{confirm} </paper-button> </div> - </dialog> + </cr-dialog> </template> <script src="password_prompt_dialog.js"></script> </dom-module>
diff --git a/chrome/browser/resources/settings/people_page/people_page.html b/chrome/browser/resources/settings/people_page/people_page.html index ee0dead..0c1c393 100644 --- a/chrome/browser/resources/settings/people_page/people_page.html +++ b/chrome/browser/resources/settings/people_page/people_page.html
@@ -355,7 +355,7 @@ </settings-animated-pages> <template is="dom-if" if="[[showDisconnectDialog_]]" restamp> - <dialog is="cr-dialog" id="disconnectDialog" + <cr-dialog id="disconnectDialog" ignore-popstate ignore-enter-key on-close="onDisconnectClosed_" close-text="$i18n{close}"> <div slot="title">$i18n{syncDisconnectTitle}</div> @@ -398,7 +398,7 @@ </div> </template> </if> - </dialog> + </cr-dialog> </template> <template is="dom-if" if="[[showImportDataDialog_]]" restamp>
diff --git a/chrome/browser/resources/settings/people_page/setup_fingerprint_dialog.html b/chrome/browser/resources/settings/people_page/setup_fingerprint_dialog.html index 7e005111..8c0f581c 100644 --- a/chrome/browser/resources/settings/people_page/setup_fingerprint_dialog.html +++ b/chrome/browser/resources/settings/people_page/setup_fingerprint_dialog.html
@@ -20,8 +20,10 @@ } #dialog { - min-width: 500px; - width: 500px; + --cr-dialog-native: { + min-width: 500px; + width: 500px; + }; } #image { @@ -52,7 +54,7 @@ } </style> - <dialog is="cr-dialog" id="dialog" on-close="close" + <cr-dialog id="dialog" on-close="close" close-text="$i18n{close}"> <div slot="title">$i18n{configureFingerprintTitle}</div> <div slot="body"> @@ -82,7 +84,7 @@ [[getCloseButtonText_(step_)]] </paper-button> </div> - </dialog> + </cr-dialog> </template> <script src="setup_fingerprint_dialog.js"></script>
diff --git a/chrome/browser/resources/settings/people_page/setup_pin_dialog.html b/chrome/browser/resources/settings/people_page/setup_pin_dialog.html index 7cffa7ec..61c3c8e7 100644 --- a/chrome/browser/resources/settings/people_page/setup_pin_dialog.html +++ b/chrome/browser/resources/settings/people_page/setup_pin_dialog.html
@@ -2,6 +2,7 @@ <link rel="import" href="chrome://resources/cr_elements/icons.html"> <link rel="import" href="chrome://resources/html/polymer.html"> +<link rel="import" href="chrome://resources/cr_elements/cr_dialog/cr_dialog.html"> <link rel="import" href="chrome://resources/html/assert.html"> <link rel="import" href="chrome://resources/html/i18n_behavior.html"> <link rel="import" href="chrome://resources/polymer/v1_0/paper-button/paper-button.html"> @@ -50,7 +51,7 @@ } </style> - <dialog is="cr-dialog" id="dialog" on-close="close" + <cr-dialog id="dialog" on-close="close" close-text="$i18n{close}"> <div slot="title">[[getTitleMessage_(isConfirmStep_)]]</div> <div slot="body"> @@ -78,7 +79,7 @@ <span>[[getContinueMessage_(isConfirmStep_)]]</span> </paper-button> </div> - </dialog> + </cr-dialog> </template> <script src="setup_pin_dialog.js"></script>
diff --git a/chrome/browser/resources/settings/people_page/users_add_user_dialog.html b/chrome/browser/resources/settings/people_page/users_add_user_dialog.html index fe8cd9c..97358beb 100644 --- a/chrome/browser/resources/settings/people_page/users_add_user_dialog.html +++ b/chrome/browser/resources/settings/people_page/users_add_user_dialog.html
@@ -17,7 +17,7 @@ }; } </style> - <dialog is="cr-dialog" id="dialog" close-text="$i18n{close}"> + <cr-dialog id="dialog" close-text="$i18n{close}"> <div slot="title">$i18n{addUsers}</div> <div slot="body"> <paper-input id="addUserInput" label="$i18n{addUsersEmail}" autofocus @@ -33,7 +33,7 @@ $i18n{add} </paper-button> </div> - </dialog> + </cr-dialog> </template> <script src="users_add_user_dialog.js"></script> </dom-module>
diff --git a/chrome/browser/resources/settings/printing_page/cups_add_printer_dialog_util.html b/chrome/browser/resources/settings/printing_page/cups_add_printer_dialog_util.html index 2c7ba3387..70ae6da0 100644 --- a/chrome/browser/resources/settings/printing_page/cups_add_printer_dialog_util.html +++ b/chrome/browser/resources/settings/printing_page/cups_add_printer_dialog_util.html
@@ -100,7 +100,7 @@ } </style> - <dialog is="cr-dialog" id="dialog" close-text="$i18n{close}"> + <cr-dialog id="dialog" close-text="$i18n{close}"> <div slot="title"> <slot name="dialog-title"></slot> </div> @@ -110,7 +110,7 @@ <div slot="button-container"> <slot name="dialog-buttons"></slot> </div> - </dialog> + </cr-dialog> </template> <script src="cups_add_printer_dialog_util.js"></script> </dom-module>
diff --git a/chrome/browser/resources/settings/privacy_page/privacy_page.html b/chrome/browser/resources/settings/privacy_page/privacy_page.html index ec6446f..3607db3 100644 --- a/chrome/browser/resources/settings/privacy_page/privacy_page.html +++ b/chrome/browser/resources/settings/privacy_page/privacy_page.html
@@ -45,7 +45,7 @@ </template> <template id="doNotTrackDialogIf" is="dom-if" if="[[showDoNotTrackDialog_]]" notify-dom-change> - <dialog is="cr-dialog" id="confirmDoNotTrackDialog" + <cr-dialog id="confirmDoNotTrackDialog" close-text="$i18n{close}" on-cancel="onDoNotTrackDialogCancel_" on-close="onDoNotTrackDialogClosed_"> <div slot="title">$i18n{doNotTrackDialogTitle}</div> @@ -60,7 +60,7 @@ $i18n{confirm} </paper-button> </div> - </dialog> + </cr-dialog> </template> <settings-animated-pages id="pages" section="privacy" focus-config="[[focusConfig_]]">
diff --git a/chrome/browser/resources/settings/reset_page/powerwash_dialog.html b/chrome/browser/resources/settings/reset_page/powerwash_dialog.html index 98a82fd..90e2a12 100644 --- a/chrome/browser/resources/settings/reset_page/powerwash_dialog.html +++ b/chrome/browser/resources/settings/reset_page/powerwash_dialog.html
@@ -10,7 +10,7 @@ <template> <style include="settings-shared"> </style> - <dialog is="cr-dialog" id="dialog" close-text="$i18n{close}" + <cr-dialog id="dialog" close-text="$i18n{close}" ignore-enter-key> <div slot="title">$i18n{powerwashDialogTitle}</div> <div slot="body"> @@ -27,7 +27,7 @@ <paper-button class="action-button" id="powerwash" on-click="onRestartTap_">$i18n{powerwashDialogButton}</paper-button> </div> - </dialog> + </cr-dialog> </template> <script src="powerwash_dialog.js"></script> </dom-module>
diff --git a/chrome/browser/resources/settings/reset_page/reset_profile_banner.html b/chrome/browser/resources/settings/reset_page/reset_profile_banner.html index aed186e6..3eaaf42 100644 --- a/chrome/browser/resources/settings/reset_page/reset_profile_banner.html +++ b/chrome/browser/resources/settings/reset_page/reset_profile_banner.html
@@ -8,7 +8,7 @@ <dom-module id="settings-reset-profile-banner"> <template> <style include="settings-shared"></style> - <dialog is="cr-dialog" id="dialog" close-text="$i18n{close}" ignore-popstate> + <cr-dialog id="dialog" close-text="$i18n{close}" ignore-popstate> <div slot="title">$i18n{resetAutomatedDialogTitle}</div> <div slot="body"> <span id="description"> @@ -26,7 +26,7 @@ $i18n{resetProfileBannerButton} </paper-button> </div> - </dialog> + </cr-dialog> </template> <script src="reset_profile_banner.js"></script> </dom-module>
diff --git a/chrome/browser/resources/settings/reset_page/reset_profile_dialog.html b/chrome/browser/resources/settings/reset_page/reset_profile_dialog.html index be6154e2..30b25d1 100644 --- a/chrome/browser/resources/settings/reset_page/reset_profile_dialog.html +++ b/chrome/browser/resources/settings/reset_page/reset_profile_dialog.html
@@ -19,7 +19,7 @@ margin: 0 8px; } </style> - <dialog is="cr-dialog" id="dialog" close-text="$i18n{close}" + <cr-dialog id="dialog" close-text="$i18n{close}" ignore-popstate ignore-enter-key> <div slot="title"> [[getPageTitle_(isTriggered_, triggeredResetToolName_)]] @@ -48,7 +48,7 @@ <paper-checkbox id="sendSettings" checked> $i18nRaw{resetPageFeedback}</paper-checkbox> </div> - </dialog> + </cr-dialog> </template> <script src="reset_profile_dialog.js"></script> </dom-module>
diff --git a/chrome/browser/resources/settings/search_engines_page/search_engine_dialog.html b/chrome/browser/resources/settings/search_engines_page/search_engine_dialog.html index a8e0591..ce40163 100644 --- a/chrome/browser/resources/settings/search_engines_page/search_engine_dialog.html +++ b/chrome/browser/resources/settings/search_engines_page/search_engine_dialog.html
@@ -22,7 +22,7 @@ }; } </style> - <dialog is="cr-dialog" id="dialog" close-text="$i18n{close}"> + <cr-dialog id="dialog" close-text="$i18n{close}"> <div slot="title">[[dialogTitle_]]</div> <div slot="body" spellcheck="false"> <paper-input always-float-label id="searchEngine" @@ -51,7 +51,7 @@ [[actionButtonText_]] </paper-button> </div> - </dialog> + </cr-dialog> </template> <script src="search_engine_dialog.js"></script> </dom-module>
diff --git a/chrome/browser/resources/settings/site_settings/add_site_dialog.html b/chrome/browser/resources/settings/site_settings/add_site_dialog.html index 3aad9d1..9d78be71 100644 --- a/chrome/browser/resources/settings/site_settings/add_site_dialog.html +++ b/chrome/browser/resources/settings/site_settings/add_site_dialog.html
@@ -21,7 +21,7 @@ visibility: hidden; } </style> - <dialog is="cr-dialog" id="dialog" close-text="$i18n{close}"> + <cr-dialog id="dialog" close-text="$i18n{close}"> <div slot="title">$i18n{addSiteTitle}</div> <div slot="body"> <paper-input id="site" always-float-label label="$i18n{addSite}" @@ -43,7 +43,7 @@ $i18n{add} </paper-button> </div> - </dialog> + </cr-dialog> </template> <script src="add_site_dialog.js"></script> </dom-module>
diff --git a/chrome/browser/resources/settings/site_settings/edit_exception_dialog.html b/chrome/browser/resources/settings/site_settings/edit_exception_dialog.html index 25da836..97de40c 100644 --- a/chrome/browser/resources/settings/site_settings/edit_exception_dialog.html +++ b/chrome/browser/resources/settings/site_settings/edit_exception_dialog.html
@@ -9,7 +9,7 @@ <dom-module id="settings-edit-exception-dialog"> <template> <style include="settings-shared"></style> - <dialog is="cr-dialog" id="dialog"> + <cr-dialog id="dialog"> <div slot="title">$i18n{editSiteTitle}</div> <div slot="body"> <paper-input always-float-label label="$i18n{addSite}" @@ -26,7 +26,7 @@ $i18n{edit} </paper-button> </div> - </dialog> + </cr-dialog> </template> <script src="edit_exception_dialog.js"></script> </dom-module>
diff --git a/chrome/browser/resources/settings/site_settings/protocol_handlers.html b/chrome/browser/resources/settings/site_settings/protocol_handlers.html index 49c6f51..d513605 100644 --- a/chrome/browser/resources/settings/site_settings/protocol_handlers.html +++ b/chrome/browser/resources/settings/site_settings/protocol_handlers.html
@@ -33,7 +33,7 @@ </div> <template is="dom-repeat" items="[[protocols]]" as="protocol"> - <div class="column-header">[[protocol.protocol]]</div> + <div class="column-header">[[protocol.protocol_display_name]]</div> <div class="list-frame menu-content vertical-list"> <template is="dom-repeat" items="[[protocol.handlers]]"> @@ -77,7 +77,9 @@ </div> <div class="middle" > <div class="protocol-host">[[item.host]]</div> - <div class="secondary protocol-protocol">[[item.protocol]]</div> + <div class="secondary protocol-protocol"> + [[item.protocol_display_name]] + </div> </div> <paper-icon-button-light class="icon-clear"> <button id="removeIgnoredButton" on-click="onRemoveIgnored_"
diff --git a/chrome/browser/resources/settings/site_settings/protocol_handlers.js b/chrome/browser/resources/settings/site_settings/protocol_handlers.js index 6192d9f1..904fc75 100644 --- a/chrome/browser/resources/settings/site_settings/protocol_handlers.js +++ b/chrome/browser/resources/settings/site_settings/protocol_handlers.js
@@ -21,13 +21,15 @@ * @typedef {{host: string, * is_default: boolean, * protocol: string, + * protocol_display_name: string, * spec: string}} */ let HandlerEntry; /** * @typedef {{handlers: !Array<!HandlerEntry>, - * protocol: string}} + * protocol: string, + * protocol_display_name: string}} */ let ProtocolEntry;
diff --git a/chrome/browser/resources/settings/site_settings/site_data.html b/chrome/browser/resources/settings/site_settings/site_data.html index af0aad9..8779e1c 100644 --- a/chrome/browser/resources/settings/site_settings/site_data.html +++ b/chrome/browser/resources/settings/site_settings/site_data.html
@@ -76,7 +76,7 @@ </iron-list> <!-- Confirm Delete dialog --> - <dialog is="cr-dialog" id="confirmDeleteDialog" close-text="$i18n{close}" + <cr-dialog id="confirmDeleteDialog" close-text="$i18n{close}" on-close="onConfirmDeleteDialogClosed_"> <div slot="title"> $i18n{siteSettingsCookieRemoveDialogTitle} @@ -90,7 +90,7 @@ $i18n{siteSettingsCookiesClearAll} </paper-button> </div> - </dialog> + </cr-dialog> </template> <script src="site_data.js"></script> </dom-module>
diff --git a/chrome/browser/resources/settings/site_settings/site_details.html b/chrome/browser/resources/settings/site_settings/site_details.html index b177b18..c5431ba6 100644 --- a/chrome/browser/resources/settings/site_settings/site_details.html +++ b/chrome/browser/resources/settings/site_settings/site_details.html
@@ -36,7 +36,7 @@ } </style> <!-- Confirm Delete dialog --> - <dialog is="cr-dialog" id="confirmDeleteDialog" close-text="$i18n{close}"> + <cr-dialog id="confirmDeleteDialog" close-text="$i18n{close}"> <div slot="title"> $i18n{siteSettingsSiteResetDialogTitle} </div> @@ -51,7 +51,7 @@ $i18n{siteSettingsSiteResetAll} </paper-button> </div> - </dialog> + </cr-dialog> <template is="dom-if" if="[[enableSiteSettings_]]"> <div id="usage">
diff --git a/chrome/browser/safe_browsing/download_protection/DEPS b/chrome/browser/safe_browsing/download_protection/DEPS new file mode 100644 index 0000000..504a3d3 --- /dev/null +++ b/chrome/browser/safe_browsing/download_protection/DEPS
@@ -0,0 +1,5 @@ +specific_include_rules = { + ".*test\.cc": [ + "+services/network/network_context.h", + ] +}
diff --git a/chrome/browser/safe_browsing/download_protection/check_client_download_request.cc b/chrome/browser/safe_browsing/download_protection/check_client_download_request.cc index 1f3e6d3..d142a71 100644 --- a/chrome/browser/safe_browsing/download_protection/check_client_download_request.cc +++ b/chrome/browser/safe_browsing/download_protection/check_client_download_request.cc
@@ -28,6 +28,8 @@ #include "content/public/common/service_manager_connection.h" #include "net/http/http_cache.h" #include "net/http/http_status_code.h" +#include "services/network/public/cpp/shared_url_loader_factory.h" +#include "services/network/public/cpp/simple_url_loader.h" namespace safe_browsing { @@ -163,13 +165,13 @@ void CheckClientDownloadRequest::Cancel() { DCHECK_CURRENTLY_ON(BrowserThread::UI); cancelable_task_tracker_.TryCancelAll(); - if (fetcher_.get()) { + if (loader_.get()) { // The DownloadProtectionService is going to release its reference, so we - // might be destroyed before the URLFetcher completes. Cancel the - // fetcher so it does not try to invoke OnURLFetchComplete. - fetcher_.reset(); + // might be destroyed before the URLLoader completes. Cancel the + // loader so it does not try to invoke OnURLFetchComplete. + loader_.reset(); } - // Note: If there is no fetcher, then some callback is still holding a + // Note: If there is no loader, then some callback is still holding a // reference to this object. We'll eventually wind up in some method on // the UI thread that will call FinishRequest() again. If FinishRequest() // is called a second time, it will be a no-op. @@ -186,31 +188,28 @@ } // TODO: this method puts "DownloadProtectionService::" in front of a lot of -// stuff to avoid referencing the enums i copied to this .h file. From the -// net::URLFetcherDelegate interface. -void CheckClientDownloadRequest::OnURLFetchComplete( - const net::URLFetcher* source) { +// stuff to avoid referencing the enums i copied to this .h file. +void CheckClientDownloadRequest::OnURLLoaderComplete( + std::unique_ptr<std::string> response_body) { DCHECK_CURRENTLY_ON(BrowserThread::UI); - DCHECK_EQ(source, fetcher_.get()); + bool success = loader_->NetError() == net::OK; + int response_code = 0; + if (loader_->ResponseInfo() && loader_->ResponseInfo()->headers) + response_code = loader_->ResponseInfo()->headers->response_code(); DVLOG(2) << "Received a response for URL: " << item_->GetUrlChain().back() - << ": success=" << source->GetStatus().is_success() - << " response_code=" << source->GetResponseCode(); - if (source->GetStatus().is_success()) { + << ": success=" << success << " response_code=" << response_code; + if (success) { base::UmaHistogramSparse("SBClientDownload.DownloadRequestResponseCode", - source->GetResponseCode()); + response_code); } base::UmaHistogramSparse("SBClientDownload.DownloadRequestNetError", - -source->GetStatus().error()); + -loader_->NetError()); DownloadCheckResultReason reason = REASON_SERVER_PING_FAILED; DownloadCheckResult result = DownloadCheckResult::UNKNOWN; std::string token; - if (source->GetStatus().is_success() && - net::HTTP_OK == source->GetResponseCode()) { + if (success && net::HTTP_OK == response_code) { ClientDownloadResponse response; - std::string data; - bool got_data = source->GetResponseAsString(&data); - DCHECK(got_data); - if (!response.ParseFromString(data)) { + if (!response.ParseFromString(*response_body.get())) { reason = REASON_INVALID_RESPONSE_PROTO; result = DownloadCheckResult::UNKNOWN; } else if (type_ == ClientDownloadRequest::SAMPLED_UNSUPPORTED_FILE) { @@ -260,10 +259,11 @@ bool upload_requested = response.upload(); DownloadFeedbackService::MaybeStorePingsForDownload( - result, upload_requested, item_, client_download_request_data_, data); + result, upload_requested, item_, client_download_request_data_, + *response_body.get()); } - // We don't need the fetcher anymore. - fetcher_.reset(); + // We don't need the loader anymore. + loader_.reset(); UMA_HISTOGRAM_TIMES("SBClientDownload.DownloadRequestDuration", base::TimeTicks::Now() - start_time_); UMA_HISTOGRAM_TIMES("SBClientDownload.DownloadRequestNetworkDuration", @@ -772,7 +772,7 @@ return; } - // The URLFetcher is owned by the UI thread, so post a message to + // The URLLoader is owned by the UI thread, so post a message to // start the pingback. BrowserThread::PostTask( BrowserThread::UI, FROM_HERE, @@ -1004,20 +1004,21 @@ } } })"); - fetcher_ = - net::URLFetcher::Create(0, PPAPIDownloadRequest::GetDownloadRequestUrl(), - net::URLFetcher::POST, this, traffic_annotation); - data_use_measurement::DataUseUserData::AttachToFetcher( - fetcher_.get(), data_use_measurement::DataUseUserData::SAFE_BROWSING); - fetcher_->SetLoadFlags(net::LOAD_DISABLE_CACHE); - fetcher_->SetAutomaticallyRetryOn5xx(false); // Don't retry on error. - fetcher_->SetRequestContext(service_->request_context_getter_.get()); - fetcher_->SetUploadData("application/octet-stream", - client_download_request_data_); + auto resource_request = std::make_unique<network::ResourceRequest>(); + resource_request->url = PPAPIDownloadRequest::GetDownloadRequestUrl(); + resource_request->method = "POST"; + resource_request->load_flags = net::LOAD_DISABLE_CACHE; + loader_ = network::SimpleURLLoader::Create(std::move(resource_request), + traffic_annotation); + loader_->AttachStringForUpload(client_download_request_data_, + "application/octet-stream"); + loader_->DownloadToStringOfUnboundedSizeUntilCrashAndDie( + service_->url_loader_factory_.get(), + base::BindOnce(&CheckClientDownloadRequest::OnURLLoaderComplete, + base::Unretained(this))); request_start_time_ = base::TimeTicks::Now(); UMA_HISTOGRAM_COUNTS("SBClientDownload.DownloadRequestPayloadSize", client_download_request_data_.size()); - fetcher_->Start(); } void CheckClientDownloadRequest::PostFinishTask(
diff --git a/chrome/browser/safe_browsing/download_protection/check_client_download_request.h b/chrome/browser/safe_browsing/download_protection/check_client_download_request.h index 3a0d410..b98642e 100644 --- a/chrome/browser/safe_browsing/download_protection/check_client_download_request.h +++ b/chrome/browser/safe_browsing/download_protection/check_client_download_request.h
@@ -28,9 +28,6 @@ #include "components/history/core/browser/history_service.h" #include "components/safe_browsing/db/database_manager.h" #include "content/public/browser/browser_thread.h" -#include "net/url_request/url_fetcher.h" -#include "net/url_request/url_fetcher_delegate.h" -#include "net/url_request/url_request_context_getter.h" #include "url/gurl.h" #if defined(OS_MACOSX) @@ -40,12 +37,15 @@ using content::BrowserThread; +namespace network { +class SimpleURLLoader; +} + namespace safe_browsing { class CheckClientDownloadRequest : public base::RefCountedThreadSafe<CheckClientDownloadRequest, BrowserThread::DeleteOnUIThread>, - public net::URLFetcherDelegate, public download::DownloadItem::Observer { public: CheckClientDownloadRequest( @@ -59,7 +59,7 @@ void StartTimeout(); void Cancel(); void OnDownloadDestroyed(download::DownloadItem* download) override; - void OnURLFetchComplete(const net::URLFetcher* source) override; + void OnURLLoaderComplete(std::unique_ptr<std::string> response_body); static bool IsSupportedDownload(const download::DownloadItem& item, const base::FilePath& target_path, DownloadCheckResultReason* reason, @@ -141,7 +141,7 @@ scoped_refptr<BinaryFeatureExtractor> binary_feature_extractor_; scoped_refptr<SafeBrowsingDatabaseManager> database_manager_; const bool pingback_enabled_; - std::unique_ptr<net::URLFetcher> fetcher_; + std::unique_ptr<network::SimpleURLLoader> loader_; scoped_refptr<SandboxedRarAnalyzer> rar_analyzer_; scoped_refptr<SandboxedZipAnalyzer> zip_analyzer_; base::TimeTicks rar_analysis_start_time_;
diff --git a/chrome/browser/safe_browsing/download_protection/download_feedback.cc b/chrome/browser/safe_browsing/download_protection/download_feedback.cc index d6e1b2e2..3db44bb 100644 --- a/chrome/browser/safe_browsing/download_protection/download_feedback.cc +++ b/chrome/browser/safe_browsing/download_protection/download_feedback.cc
@@ -13,6 +13,7 @@ #include "components/safe_browsing/proto/csd.pb.h" #include "content/public/browser/browser_thread.h" #include "net/base/net_errors.h" +#include "services/network/public/cpp/shared_url_loader_factory.h" namespace safe_browsing { @@ -36,11 +37,12 @@ // download feedback service. class DownloadFeedbackImpl : public DownloadFeedback { public: - DownloadFeedbackImpl(net::URLRequestContextGetter* request_context_getter, - base::TaskRunner* file_task_runner, - const base::FilePath& file_path, - const std::string& ping_request, - const std::string& ping_response); + DownloadFeedbackImpl( + scoped_refptr<network::SharedURLLoaderFactory> url_loader_factory, + base::TaskRunner* file_task_runner, + const base::FilePath& file_path, + const std::string& ping_request, + const std::string& ping_response); ~DownloadFeedbackImpl() override; void Start(const base::Closure& finish_callback) override; @@ -64,7 +66,7 @@ void RecordUploadResult(UploadResultType result); - scoped_refptr<net::URLRequestContextGetter> request_context_getter_; + scoped_refptr<network::SharedURLLoaderFactory> url_loader_factory_; scoped_refptr<base::TaskRunner> file_task_runner_; const base::FilePath file_path_; int64_t file_size_; @@ -80,12 +82,12 @@ }; DownloadFeedbackImpl::DownloadFeedbackImpl( - net::URLRequestContextGetter* request_context_getter, + scoped_refptr<network::SharedURLLoaderFactory> url_loader_factory, base::TaskRunner* file_task_runner, const base::FilePath& file_path, const std::string& ping_request, const std::string& ping_response) - : request_context_getter_(request_context_getter), + : url_loader_factory_(url_loader_factory), file_task_runner_(file_task_runner), file_path_(file_path), file_size_(-1), @@ -164,9 +166,8 @@ })"); uploader_ = TwoPhaseUploader::Create( - request_context_getter_.get(), file_task_runner_.get(), - GURL(kSbFeedbackURL), metadata_string, file_path_, - TwoPhaseUploader::ProgressCallback(), + url_loader_factory_, file_task_runner_.get(), GURL(kSbFeedbackURL), + metadata_string, file_path_, base::Bind(&DownloadFeedbackImpl::FinishedUpload, base::Unretained(this), finish_callback), traffic_annotation); @@ -237,18 +238,18 @@ // static std::unique_ptr<DownloadFeedback> DownloadFeedback::Create( - net::URLRequestContextGetter* request_context_getter, + scoped_refptr<network::SharedURLLoaderFactory> url_loader_factory, base::TaskRunner* file_task_runner, const base::FilePath& file_path, const std::string& ping_request, const std::string& ping_response) { if (!factory_) { return base::WrapUnique( - new DownloadFeedbackImpl(request_context_getter, file_task_runner, + new DownloadFeedbackImpl(url_loader_factory, file_task_runner, file_path, ping_request, ping_response)); } return DownloadFeedback::factory_->CreateDownloadFeedback( - request_context_getter, file_task_runner, file_path, ping_request, + url_loader_factory, file_task_runner, file_path, ping_request, ping_response); }
diff --git a/chrome/browser/safe_browsing/download_protection/download_feedback.h b/chrome/browser/safe_browsing/download_protection/download_feedback.h index 1c532bd..b9b5e68f9 100644 --- a/chrome/browser/safe_browsing/download_protection/download_feedback.h +++ b/chrome/browser/safe_browsing/download_protection/download_feedback.h
@@ -24,7 +24,7 @@ // Takes ownership of the file pointed to be |file_path|, it will be deleted // when the DownloadFeedback is destructed. static std::unique_ptr<DownloadFeedback> Create( - net::URLRequestContextGetter* request_context_getter, + scoped_refptr<network::SharedURLLoaderFactory> url_loader_factory, base::TaskRunner* file_task_runner, const base::FilePath& file_path, const std::string& ping_request, @@ -66,7 +66,7 @@ virtual ~DownloadFeedbackFactory() {} virtual std::unique_ptr<DownloadFeedback> CreateDownloadFeedback( - net::URLRequestContextGetter* request_context_getter, + scoped_refptr<network::SharedURLLoaderFactory> url_loader_factory, base::TaskRunner* file_task_runner, const base::FilePath& file_path, const std::string& ping_request,
diff --git a/chrome/browser/safe_browsing/download_protection/download_feedback_service.cc b/chrome/browser/safe_browsing/download_protection/download_feedback_service.cc index 44b3963..d03a6582 100644 --- a/chrome/browser/safe_browsing/download_protection/download_feedback_service.cc +++ b/chrome/browser/safe_browsing/download_protection/download_feedback_service.cc
@@ -15,6 +15,7 @@ #include "chrome/browser/safe_browsing/download_protection/download_feedback.h" #include "components/download/public/common/download_item.h" #include "content/public/browser/browser_thread.h" +#include "services/network/public/cpp/shared_url_loader_factory.h" namespace safe_browsing { @@ -68,9 +69,9 @@ } // namespace DownloadFeedbackService::DownloadFeedbackService( - net::URLRequestContextGetter* request_context_getter, + scoped_refptr<network::SharedURLLoaderFactory> url_loader_factory, base::TaskRunner* file_task_runner) - : request_context_getter_(request_context_getter), + : url_loader_factory_(url_loader_factory), file_task_runner_(file_task_runner), weak_ptr_factory_(this) { DCHECK_CURRENTLY_ON(content::BrowserThread::UI); @@ -182,9 +183,9 @@ const std::string& ping_response, const base::FilePath& path) { DCHECK_CURRENTLY_ON(content::BrowserThread::UI); - std::unique_ptr<DownloadFeedback> feedback(DownloadFeedback::Create( - request_context_getter_.get(), file_task_runner_.get(), path, - ping_request, ping_response)); + std::unique_ptr<DownloadFeedback> feedback( + DownloadFeedback::Create(url_loader_factory_, file_task_runner_.get(), + path, ping_request, ping_response)); active_feedback_.push(std::move(feedback)); UMA_HISTOGRAM_COUNTS_100("SBDownloadFeedback.ActiveFeedbacks", active_feedback_.size());
diff --git a/chrome/browser/safe_browsing/download_protection/download_feedback_service.h b/chrome/browser/safe_browsing/download_protection/download_feedback_service.h index 25ceed28..10bf60d 100644 --- a/chrome/browser/safe_browsing/download_protection/download_feedback_service.h +++ b/chrome/browser/safe_browsing/download_protection/download_feedback_service.h
@@ -24,8 +24,8 @@ class DownloadItem; } -namespace net { -class URLRequestContextGetter; +namespace network { +class SharedURLLoaderFactory; } namespace safe_browsing { @@ -37,8 +37,9 @@ // Lives on the UI thread. class DownloadFeedbackService { public: - DownloadFeedbackService(net::URLRequestContextGetter* request_context_getter, - base::TaskRunner* file_task_runner); + DownloadFeedbackService( + scoped_refptr<network::SharedURLLoaderFactory> url_loader_factory, + base::TaskRunner* file_task_runner); ~DownloadFeedbackService(); // Stores the request and response ping data from the download check, if the @@ -86,7 +87,7 @@ const base::FilePath& path); void FeedbackComplete(); - scoped_refptr<net::URLRequestContextGetter> request_context_getter_; + scoped_refptr<network::SharedURLLoaderFactory> url_loader_factory_; scoped_refptr<base::TaskRunner> file_task_runner_; // Currently active & pending uploads. The first item is active, remaining
diff --git a/chrome/browser/safe_browsing/download_protection/download_feedback_service_unittest.cc b/chrome/browser/safe_browsing/download_protection/download_feedback_service_unittest.cc index 384e7c0c..30282b6 100644 --- a/chrome/browser/safe_browsing/download_protection/download_feedback_service_unittest.cc +++ b/chrome/browser/safe_browsing/download_protection/download_feedback_service_unittest.cc
@@ -22,6 +22,7 @@ #include "content/public/test/test_browser_thread_bundle.h" #include "content/public/test/test_utils.h" #include "net/url_request/url_request_test_util.h" +#include "services/network/public/cpp/shared_url_loader_factory.h" #include "testing/gmock/include/gmock/gmock.h" #include "testing/gtest/include/gtest/gtest.h" @@ -36,8 +37,7 @@ class FakeDownloadFeedback : public DownloadFeedback { public: - FakeDownloadFeedback(net::URLRequestContextGetter* request_context_getter, - base::TaskRunner* file_task_runner, + FakeDownloadFeedback(base::TaskRunner* file_task_runner, const base::FilePath& file_path, const std::string& ping_request, const std::string& ping_response, @@ -67,7 +67,6 @@ bool start_called() const { return start_called_; } private: - scoped_refptr<net::URLRequestContextGetter> request_context_getter_; scoped_refptr<base::TaskRunner> file_task_runner_; base::FilePath file_path_; std::string ping_request_; @@ -83,14 +82,13 @@ ~FakeDownloadFeedbackFactory() override {} std::unique_ptr<DownloadFeedback> CreateDownloadFeedback( - net::URLRequestContextGetter* request_context_getter, + scoped_refptr<network::SharedURLLoaderFactory> url_loader_factory, base::TaskRunner* file_task_runner, const base::FilePath& file_path, const std::string& ping_request, const std::string& ping_response) override { FakeDownloadFeedback* feedback = new FakeDownloadFeedback( - request_context_getter, file_task_runner, file_path, ping_request, - ping_response, + file_task_runner, file_path, ping_request, ping_response, base::Bind(&FakeDownloadFeedbackFactory::DownloadFeedbackSent, base::Unretained(this), feedbacks_.size())); feedbacks_.push_back(feedback); @@ -125,11 +123,7 @@ public: DownloadFeedbackServiceTest() : file_task_runner_(base::CreateSequencedTaskRunnerWithTraits( - {base::MayBlock(), base::TaskPriority::BACKGROUND})), - io_task_runner_(content::BrowserThread::GetTaskRunnerForThread( - content::BrowserThread::IO)), - request_context_getter_( - new net::TestURLRequestContextGetter(io_task_runner_)) {} + {base::MayBlock(), base::TaskPriority::BACKGROUND})) {} void SetUp() override { ASSERT_TRUE(temp_dir_.CreateUniqueTempDir()); @@ -160,8 +154,6 @@ base::ScopedTempDir temp_dir_; content::TestBrowserThreadBundle thread_bundle_; scoped_refptr<base::SequencedTaskRunner> file_task_runner_; - scoped_refptr<base::SingleThreadTaskRunner> io_task_runner_; - scoped_refptr<net::TestURLRequestContextGetter> request_context_getter_; FakeDownloadFeedbackFactory download_feedback_factory_; }; @@ -219,8 +211,7 @@ StealDangerousDownload(true /*delete_file_after_feedback*/, _)) .WillOnce(SaveArg<1>(&download_discarded_callback)); - DownloadFeedbackService service(request_context_getter_.get(), - file_task_runner_.get()); + DownloadFeedbackService service(nullptr, file_task_runner_.get()); service.MaybeStorePingsForDownload(DownloadCheckResult::UNCOMMON, true /* upload_requested */, &item, ping_request, ping_response); @@ -261,8 +252,7 @@ GURL empty_url; EXPECT_CALL(item, GetURL()).WillOnce(ReturnRef(empty_url)); - DownloadFeedbackService service(request_context_getter_.get(), - file_task_runner_.get()); + DownloadFeedbackService service(nullptr, file_task_runner_.get()); service.MaybeStorePingsForDownload(DownloadCheckResult::UNCOMMON, true /* upload_requested */, &item, ping_request, ping_response); @@ -310,8 +300,7 @@ } { - DownloadFeedbackService service(request_context_getter_.get(), - file_task_runner_.get()); + DownloadFeedbackService service(nullptr, file_task_runner_.get()); for (size_t i = 0; i < kNumDownloads; ++i) { SCOPED_TRACE(i); service.BeginFeedbackForDownload(&item[i], DownloadCommands::DISCARD); @@ -380,8 +369,7 @@ } { - DownloadFeedbackService service(request_context_getter_.get(), - file_task_runner_.get()); + DownloadFeedbackService service(nullptr, file_task_runner_.get()); for (size_t i = 0; i < kNumDownloads; ++i) { SCOPED_TRACE(i); service.BeginFeedbackForDownload(&item[i], DownloadCommands::DISCARD);
diff --git a/chrome/browser/safe_browsing/download_protection/download_feedback_unittest.cc b/chrome/browser/safe_browsing/download_protection/download_feedback_unittest.cc index 78a87ff..3388021d 100644 --- a/chrome/browser/safe_browsing/download_protection/download_feedback_unittest.cc +++ b/chrome/browser/safe_browsing/download_protection/download_feedback_unittest.cc
@@ -18,6 +18,8 @@ #include "content/public/test/test_utils.h" #include "net/traffic_annotation/network_traffic_annotation_test_helper.h" #include "net/url_request/url_request_test_util.h" +#include "services/network/network_context.h" +#include "services/network/public/cpp/shared_url_loader_factory.h" #include "testing/gtest/include/gtest/gtest.h" namespace safe_browsing { @@ -26,42 +28,33 @@ class FakeUploader : public TwoPhaseUploader { public: - FakeUploader(net::URLRequestContextGetter* url_request_context_getter, - base::TaskRunner* file_task_runner, + FakeUploader(base::TaskRunner* file_task_runner, const GURL& base_url, const std::string& metadata, const base::FilePath& file_path, - const ProgressCallback& progress_callback, const FinishCallback& finish_callback); ~FakeUploader() override {} void Start() override { start_called_ = true; } - scoped_refptr<net::URLRequestContextGetter> url_request_context_getter_; scoped_refptr<base::TaskRunner> file_task_runner_; GURL base_url_; std::string metadata_; base::FilePath file_path_; - ProgressCallback progress_callback_; FinishCallback finish_callback_; bool start_called_; }; -FakeUploader::FakeUploader( - net::URLRequestContextGetter* url_request_context_getter, - base::TaskRunner* file_task_runner, - const GURL& base_url, - const std::string& metadata, - const base::FilePath& file_path, - const ProgressCallback& progress_callback, - const FinishCallback& finish_callback) - : url_request_context_getter_(url_request_context_getter), - file_task_runner_(file_task_runner), +FakeUploader::FakeUploader(base::TaskRunner* file_task_runner, + const GURL& base_url, + const std::string& metadata, + const base::FilePath& file_path, + const FinishCallback& finish_callback) + : file_task_runner_(file_task_runner), base_url_(base_url), metadata_(metadata), file_path_(file_path), - progress_callback_(progress_callback), finish_callback_(finish_callback), start_called_(false) {} @@ -71,12 +64,11 @@ ~FakeUploaderFactory() override {} std::unique_ptr<TwoPhaseUploader> CreateTwoPhaseUploader( - net::URLRequestContextGetter* url_request_context_getter, + scoped_refptr<network::SharedURLLoaderFactory> url_loader_factory, base::TaskRunner* file_task_runner, const GURL& base_url, const std::string& metadata, const base::FilePath& file_path, - const TwoPhaseUploader::ProgressCallback& progress_callback, const TwoPhaseUploader::FinishCallback& finish_callback, const net::NetworkTrafficAnnotationTag& traffic_annotation) override; @@ -84,22 +76,52 @@ }; std::unique_ptr<TwoPhaseUploader> FakeUploaderFactory::CreateTwoPhaseUploader( - net::URLRequestContextGetter* url_request_context_getter, + scoped_refptr<network::SharedURLLoaderFactory> url_loader_factory, base::TaskRunner* file_task_runner, const GURL& base_url, const std::string& metadata, const base::FilePath& file_path, - const TwoPhaseUploader::ProgressCallback& progress_callback, const TwoPhaseUploader::FinishCallback& finish_callback, const net::NetworkTrafficAnnotationTag& traffic_annotation) { EXPECT_FALSE(uploader_); - uploader_ = - new FakeUploader(url_request_context_getter, file_task_runner, base_url, - metadata, file_path, progress_callback, finish_callback); + uploader_ = new FakeUploader(file_task_runner, base_url, metadata, file_path, + finish_callback); return base::WrapUnique(uploader_); } +class SharedURLLoaderFactory : public network::SharedURLLoaderFactory { + public: + explicit SharedURLLoaderFactory( + network::mojom::URLLoaderFactory* url_loader_factory) + : url_loader_factory_(url_loader_factory) {} + + std::unique_ptr<network::SharedURLLoaderFactoryInfo> Clone() override { + NOTREACHED(); + return nullptr; + } + + // network::URLLoaderFactory implementation: + void CreateLoaderAndStart(network::mojom::URLLoaderRequest loader, + int32_t routing_id, + int32_t request_id, + uint32_t options, + const network::ResourceRequest& request, + network::mojom::URLLoaderClientPtr client, + const net::MutableNetworkTrafficAnnotationTag& + traffic_annotation) override { + url_loader_factory_->CreateLoaderAndStart( + std::move(loader), routing_id, request_id, options, std::move(request), + std::move(client), traffic_annotation); + } + + private: + friend class base::RefCounted<SharedURLLoaderFactory>; + ~SharedURLLoaderFactory() override = default; + + network::mojom::URLLoaderFactory* url_loader_factory_; +}; + } // namespace class DownloadFeedbackTest : public testing::Test { @@ -113,6 +135,14 @@ new net::TestURLRequestContextGetter(io_task_runner_)), feedback_finish_called_(false) { EXPECT_NE(io_task_runner_, file_task_runner_); + network::mojom::NetworkContextPtr network_context; + network_context_ = std::make_unique<network::NetworkContext>( + nullptr, mojo::MakeRequest(&network_context), + url_request_context_getter_); + network_context_->CreateURLLoaderFactory( + mojo::MakeRequest(&url_loader_factory_), 0); + shared_url_loader_factory_ = + base::MakeRefCounted<SharedURLLoaderFactory>(url_loader_factory_.get()); } void SetUp() override { @@ -145,6 +175,9 @@ scoped_refptr<base::SingleThreadTaskRunner> io_task_runner_; FakeUploaderFactory two_phase_uploader_factory_; scoped_refptr<net::TestURLRequestContextGetter> url_request_context_getter_; + std::unique_ptr<network::NetworkContext> network_context_; + network::mojom::URLLoaderFactoryPtr url_loader_factory_; + scoped_refptr<SharedURLLoaderFactory> shared_url_loader_factory_; bool feedback_finish_called_; }; @@ -163,8 +196,8 @@ expected_report_metadata.download_response().SerializeAsString()); std::unique_ptr<DownloadFeedback> feedback = DownloadFeedback::Create( - url_request_context_getter_.get(), file_task_runner_.get(), - upload_file_path_, ping_request, ping_response); + shared_url_loader_factory_, file_task_runner_.get(), upload_file_path_, + ping_request, ping_response); EXPECT_FALSE(uploader()); feedback->Start(base::Bind(&DownloadFeedbackTest::FinishCallback, @@ -173,8 +206,6 @@ EXPECT_FALSE(feedback_finish_called_); EXPECT_TRUE(uploader()->start_called_); - EXPECT_EQ(url_request_context_getter_, - uploader()->url_request_context_getter_); EXPECT_EQ(file_task_runner_, uploader()->file_task_runner_); EXPECT_EQ(upload_file_path_, uploader()->file_path_); EXPECT_EQ(expected_report_metadata.SerializeAsString(), @@ -206,8 +237,8 @@ expected_report_metadata.download_response().SerializeAsString()); std::unique_ptr<DownloadFeedback> feedback = DownloadFeedback::Create( - url_request_context_getter_.get(), file_task_runner_.get(), - upload_file_path_, ping_request, ping_response); + shared_url_loader_factory_, file_task_runner_.get(), upload_file_path_, + ping_request, ping_response); EXPECT_FALSE(uploader()); feedback->Start(base::Bind(&DownloadFeedbackTest::FinishCallback,
diff --git a/chrome/browser/safe_browsing/download_protection/download_protection_service.cc b/chrome/browser/safe_browsing/download_protection/download_protection_service.cc index 4b08146f4..59ab62af 100644 --- a/chrome/browser/safe_browsing/download_protection/download_protection_service.cc +++ b/chrome/browser/safe_browsing/download_protection/download_protection_service.cc
@@ -26,6 +26,7 @@ #include "content/public/browser/web_contents.h" #include "net/base/url_util.h" #include "net/cert/x509_util.h" +#include "services/network/public/cpp/shared_url_loader_factory.h" using content::BrowserThread; namespace safe_browsing { @@ -64,13 +65,13 @@ SafeBrowsingService* sb_service) : sb_service_(sb_service), navigation_observer_manager_(nullptr), - request_context_getter_(sb_service ? sb_service->url_request_context() - : nullptr), + url_loader_factory_(sb_service ? sb_service->GetURLLoaderFactory() + : nullptr), enabled_(false), binary_feature_extractor_(new BinaryFeatureExtractor()), download_request_timeout_ms_(kDownloadRequestTimeoutMs), feedback_service_(new DownloadFeedbackService( - request_context_getter_.get(), + url_loader_factory_, base::CreateSequencedTaskRunnerWithTraits( {base::MayBlock(), base::TaskPriority::BACKGROUND}) .get())),
diff --git a/chrome/browser/safe_browsing/download_protection/download_protection_service.h b/chrome/browser/safe_browsing/download_protection/download_protection_service.h index cb8de19..f0e7d07 100644 --- a/chrome/browser/safe_browsing/download_protection/download_protection_service.h +++ b/chrome/browser/safe_browsing/download_protection/download_protection_service.h
@@ -27,7 +27,6 @@ #include "chrome/browser/safe_browsing/safe_browsing_navigation_observer_manager.h" #include "chrome/browser/safe_browsing/ui_manager.h" #include "components/safe_browsing/db/database_manager.h" -#include "net/url_request/url_request_context_getter.h" #include "url/gurl.h" namespace content { @@ -42,6 +41,10 @@ class X509Certificate; } // namespace net +namespace network { +class SharedURLLoaderFactory; +} + class Profile; namespace safe_browsing { @@ -250,8 +253,8 @@ scoped_refptr<SafeBrowsingNavigationObserverManager> navigation_observer_manager_; - // The context we use to issue network requests. - scoped_refptr<net::URLRequestContextGetter> request_context_getter_; + // The loader factory we use to issue network requests. + scoped_refptr<network::SharedURLLoaderFactory> url_loader_factory_; // Set of pending server requests for DownloadManager mediated downloads. std::set<scoped_refptr<CheckClientDownloadRequest>> download_requests_;
diff --git a/chrome/browser/safe_browsing/download_protection/download_protection_service_unittest.cc b/chrome/browser/safe_browsing/download_protection/download_protection_service_unittest.cc index 006d232..179c3f4 100644 --- a/chrome/browser/safe_browsing/download_protection/download_protection_service_unittest.cc +++ b/chrome/browser/safe_browsing/download_protection/download_protection_service_unittest.cc
@@ -27,6 +27,7 @@ #include "base/single_thread_task_runner.h" #include "base/strings/string_number_conversions.h" #include "base/task_scheduler/task_scheduler.h" +#include "base/test/bind_test_util.h" #include "base/threading/thread_task_runner_handle.h" #include "build/build_config.h" #include "chrome/browser/history/history_service_factory.h" @@ -52,6 +53,7 @@ #include "components/safe_browsing/proto/csd.pb.h" #include "content/public/browser/download_item_utils.h" #include "content/public/browser/page_navigator.h" +#include "content/public/common/weak_wrapper_shared_url_loader_factory.h" #include "content/public/test/test_browser_thread_bundle.h" #include "content/public/test/test_utils.h" #include "content/public/test/web_contents_tester.h" @@ -59,10 +61,7 @@ #include "net/cert/x509_certificate.h" #include "net/cert/x509_util.h" #include "net/http/http_status_code.h" -#include "net/url_request/test_url_fetcher_factory.h" -#include "net/url_request/url_fetcher_delegate.h" -#include "net/url_request/url_fetcher_impl.h" -#include "net/url_request/url_request_status.h" +#include "services/network/test/test_url_loader_factory.h" #include "testing/gmock/include/gmock/gmock.h" #include "testing/gtest/include/gtest/gtest.h" #include "third_party/zlib/google/zip.h" @@ -108,7 +107,11 @@ class FakeSafeBrowsingService : public SafeBrowsingService, public ServicesDelegate::ServicesCreator { public: - FakeSafeBrowsingService() : download_report_count_(0) { + FakeSafeBrowsingService() + : test_shared_loader_factory_( + base::MakeRefCounted<content::WeakWrapperSharedURLLoaderFactory>( + &test_url_loader_factory_)), + download_report_count_(0) { services_delegate_ = ServicesDelegate::CreateForTest(this, this); } @@ -118,10 +121,19 @@ return mock_database_manager_; } + scoped_refptr<network::SharedURLLoaderFactory> GetURLLoaderFactory() + override { + return test_shared_loader_factory_; + } + void SendSerializedDownloadReport(const std::string& unused_report) override { download_report_count_++; } + network::TestURLLoaderFactory* test_url_loader_factory() { + return &test_url_loader_factory_; + } + int download_report_count() { return download_report_count_; } protected: @@ -156,6 +168,8 @@ return nullptr; } + network::TestURLLoaderFactory test_url_loader_factory_; + scoped_refptr<network::SharedURLLoaderFactory> test_shared_loader_factory_; MockSafeBrowsingDatabaseManager* mock_database_manager_; int download_report_count_; @@ -181,35 +195,19 @@ DISALLOW_COPY_AND_ASSIGN(MockBinaryFeatureExtractor); }; -class TestURLFetcherWatcher : public net::TestURLFetcherDelegateForTests { - public: - explicit TestURLFetcherWatcher(net::TestURLFetcherFactory* factory) - : factory_(factory), fetcher_id_(-1) { - factory_->SetDelegateForTests(this); - } - ~TestURLFetcherWatcher() { factory_->SetDelegateForTests(NULL); } - - // TestURLFetcherDelegateForTests impl: - void OnRequestStart(int fetcher_id) override { - fetcher_id_ = fetcher_id; - run_loop_.Quit(); - } - void OnChunkUpload(int fetcher_id) override {} - void OnRequestEnd(int fetcher_id) override {} - - int WaitForRequest() { - run_loop_.Run(); - return fetcher_id_; - } - - private: - net::TestURLFetcherFactory* factory_; - int fetcher_id_; - RunLoop run_loop_; -}; - using NiceMockDownloadItem = NiceMock<download::MockDownloadItem>; +std::string GetBodyFromRequest(const network::ResourceRequest& request) { + auto body = request.request_body; + if (!body) + return std::string(); + + CHECK_EQ(1u, body->elements()->size()); + auto& element = body->elements()->at(0); + CHECK_EQ(network::DataElement::TYPE_BYTES, element.type()); + return std::string(element.bytes(), element.length()); +} + } // namespace ACTION_P(SetCertificateContents, contents) { @@ -404,17 +402,24 @@ void ClearClientDownloadRequest() { last_client_download_request_.reset(); } - void PrepareResponse(net::FakeURLFetcherFactory* factory, - ClientDownloadResponse::Verdict verdict, + void PrepareResponse(ClientDownloadResponse::Verdict verdict, net::HttpStatusCode response_code, - net::URLRequestStatus::Status status, + int net_error, bool upload_requested = false) { + if (net_error != net::OK) { + network::URLLoaderCompletionStatus status; + sb_service_->test_url_loader_factory()->AddResponse( + PPAPIDownloadRequest::GetDownloadRequestUrl(), + network::ResourceResponseHead(), std::string(), + network::URLLoaderCompletionStatus(net_error)); + return; + } ClientDownloadResponse response; response.set_verdict(verdict); response.set_upload(upload_requested); - factory->SetFakeResponse(PPAPIDownloadRequest::GetDownloadRequestUrl(), - response.SerializeAsString(), response_code, - status); + sb_service_->test_url_loader_factory()->AddResponse( + PPAPIDownloadRequest::GetDownloadRequestUrl().spec(), + response.SerializeAsString()); } void PrepareBasicDownloadItem( @@ -515,10 +520,6 @@ has_result_ = true; } - void SendURLFetchComplete(net::TestURLFetcher* fetcher) { - fetcher->delegate()->OnURLFetchComplete(fetcher); - } - testing::AssertionResult IsResult(DownloadCheckResult expected) { if (!has_result_) return testing::AssertionFailure() << "No result"; @@ -567,8 +568,7 @@ void DownloadProtectionServiceTest::CheckClientDownloadReportCorruptArchive( ArchiveType type) { - net::FakeURLFetcherFactory factory(NULL); - PrepareResponse(&factory, ClientDownloadResponse::SAFE, net::HTTP_OK, + PrepareResponse(ClientDownloadResponse::SAFE, net::HTTP_OK, net::URLRequestStatus::SUCCESS); NiceMockDownloadItem item; @@ -663,8 +663,7 @@ TEST_F(DownloadProtectionServiceTest, CheckClientDownloadWhitelistedUrlWithoutSampling) { // Response to any requests will be DANGEROUS. - net::FakeURLFetcherFactory factory(NULL); - PrepareResponse(&factory, ClientDownloadResponse::DANGEROUS, net::HTTP_OK, + PrepareResponse(ClientDownloadResponse::DANGEROUS, net::HTTP_OK, net::URLRequestStatus::SUCCESS); NiceMockDownloadItem item; @@ -758,8 +757,7 @@ CheckClientDownloadWhitelistedUrlWithSampling) { // Server responses "SAFE" to every requests coming from whitelisted // download. - net::FakeURLFetcherFactory factory(NULL); - PrepareResponse(&factory, ClientDownloadResponse::SAFE, net::HTTP_OK, + PrepareResponse(ClientDownloadResponse::SAFE, net::HTTP_OK, net::URLRequestStatus::SUCCESS); NiceMockDownloadItem item; @@ -902,8 +900,7 @@ TEST_F(DownloadProtectionServiceTest, CheckClientDownloadSampledFile) { // Server response will be discarded. - net::FakeURLFetcherFactory factory(NULL); - PrepareResponse(&factory, ClientDownloadResponse::DANGEROUS, net::HTTP_OK, + PrepareResponse(ClientDownloadResponse::DANGEROUS, net::HTTP_OK, net::URLRequestStatus::SUCCESS); NiceMockDownloadItem item; @@ -994,9 +991,7 @@ TEST_F(DownloadProtectionServiceTest, CheckClientDownloadFetchFailed) { // HTTP request will fail. - net::FakeURLFetcherFactory factory(NULL); - PrepareResponse(&factory, ClientDownloadResponse::SAFE, - net::HTTP_INTERNAL_SERVER_ERROR, + PrepareResponse(ClientDownloadResponse::SAFE, net::HTTP_INTERNAL_SERVER_ERROR, net::URLRequestStatus::FAILED); NiceMockDownloadItem item; @@ -1021,8 +1016,7 @@ } TEST_F(DownloadProtectionServiceTest, CheckClientDownloadSuccess) { - net::FakeURLFetcherFactory factory(NULL); - PrepareResponse(&factory, ClientDownloadResponse::SAFE, net::HTTP_OK, + PrepareResponse(ClientDownloadResponse::SAFE, net::HTTP_OK, net::URLRequestStatus::SUCCESS); NiceMockDownloadItem item; @@ -1057,9 +1051,9 @@ { // Invalid response should result in SAFE (default value in proto). ClientDownloadResponse invalid_response; - factory.SetFakeResponse(PPAPIDownloadRequest::GetDownloadRequestUrl(), - invalid_response.SerializePartialAsString(), - net::HTTP_OK, net::URLRequestStatus::SUCCESS); + sb_service_->test_url_loader_factory()->AddResponse( + PPAPIDownloadRequest::GetDownloadRequestUrl().spec(), + invalid_response.SerializePartialAsString()); RunLoop run_loop; download_service_->CheckClientDownload( &item, base::Bind(&DownloadProtectionServiceTest::CheckDoneCallback, @@ -1074,7 +1068,7 @@ { // If the response is dangerous the result should also be marked as // dangerous, and should not upload if not requested. - PrepareResponse(&factory, ClientDownloadResponse::DANGEROUS, net::HTTP_OK, + PrepareResponse(ClientDownloadResponse::DANGEROUS, net::HTTP_OK, net::URLRequestStatus::SUCCESS, false /* upload_requested */); RunLoop run_loop; @@ -1091,7 +1085,7 @@ { // If the response is dangerous and the server requests an upload, // we should upload. - PrepareResponse(&factory, ClientDownloadResponse::DANGEROUS, net::HTTP_OK, + PrepareResponse(ClientDownloadResponse::DANGEROUS, net::HTTP_OK, net::URLRequestStatus::SUCCESS, true /* upload_requested */); RunLoop run_loop; @@ -1107,7 +1101,7 @@ } { // If the response is uncommon the result should also be marked as uncommon. - PrepareResponse(&factory, ClientDownloadResponse::UNCOMMON, net::HTTP_OK, + PrepareResponse(ClientDownloadResponse::UNCOMMON, net::HTTP_OK, net::URLRequestStatus::SUCCESS, true /* upload_requested */); RunLoop run_loop; @@ -1130,8 +1124,8 @@ { // If the response is dangerous_host the result should also be marked as // dangerous_host. - PrepareResponse(&factory, ClientDownloadResponse::DANGEROUS_HOST, - net::HTTP_OK, net::URLRequestStatus::SUCCESS, + PrepareResponse(ClientDownloadResponse::DANGEROUS_HOST, net::HTTP_OK, + net::URLRequestStatus::SUCCESS, true /* upload_requested */); RunLoop run_loop; download_service_->CheckClientDownload( @@ -1150,8 +1144,8 @@ { // If the response is POTENTIALLY_UNWANTED the result should also be marked // as POTENTIALLY_UNWANTED. - PrepareResponse(&factory, ClientDownloadResponse::POTENTIALLY_UNWANTED, - net::HTTP_OK, net::URLRequestStatus::SUCCESS); + PrepareResponse(ClientDownloadResponse::POTENTIALLY_UNWANTED, net::HTTP_OK, + net::URLRequestStatus::SUCCESS); RunLoop run_loop; download_service_->CheckClientDownload( &item, base::Bind(&DownloadProtectionServiceTest::CheckDoneCallback, @@ -1164,7 +1158,7 @@ { // If the response is UNKNOWN the result should also be marked as // UNKNOWN. And if the server requests an upload, we should upload. - PrepareResponse(&factory, ClientDownloadResponse::UNKNOWN, net::HTTP_OK, + PrepareResponse(ClientDownloadResponse::UNKNOWN, net::HTTP_OK, net::URLRequestStatus::SUCCESS, true /* upload_requested */); RunLoop run_loop; @@ -1181,8 +1175,7 @@ } TEST_F(DownloadProtectionServiceTest, CheckClientDownloadHTTPS) { - net::FakeURLFetcherFactory factory(NULL); - PrepareResponse(&factory, ClientDownloadResponse::DANGEROUS, net::HTTP_OK, + PrepareResponse(ClientDownloadResponse::DANGEROUS, net::HTTP_OK, net::URLRequestStatus::SUCCESS); NiceMockDownloadItem item; @@ -1212,8 +1205,7 @@ } TEST_F(DownloadProtectionServiceTest, CheckClientDownloadBlob) { - net::FakeURLFetcherFactory factory(NULL); - PrepareResponse(&factory, ClientDownloadResponse::DANGEROUS, net::HTTP_OK, + PrepareResponse(ClientDownloadResponse::DANGEROUS, net::HTTP_OK, net::URLRequestStatus::SUCCESS); NiceMockDownloadItem item; @@ -1245,8 +1237,7 @@ } TEST_F(DownloadProtectionServiceTest, CheckClientDownloadData) { - net::FakeURLFetcherFactory factory(NULL); - PrepareResponse(&factory, ClientDownloadResponse::DANGEROUS, net::HTTP_OK, + PrepareResponse(ClientDownloadResponse::DANGEROUS, net::HTTP_OK, net::URLRequestStatus::SUCCESS); NiceMockDownloadItem item; @@ -1303,8 +1294,7 @@ } TEST_F(DownloadProtectionServiceTest, CheckClientDownloadZip) { - net::FakeURLFetcherFactory factory(NULL); - PrepareResponse(&factory, ClientDownloadResponse::SAFE, net::HTTP_OK, + PrepareResponse(ClientDownloadResponse::SAFE, net::HTTP_OK, net::URLRequestStatus::SUCCESS); NiceMockDownloadItem item; @@ -1369,7 +1359,7 @@ { // If the response is dangerous the result should also be marked as // dangerous. - PrepareResponse(&factory, ClientDownloadResponse::DANGEROUS, net::HTTP_OK, + PrepareResponse(ClientDownloadResponse::DANGEROUS, net::HTTP_OK, net::URLRequestStatus::SUCCESS); RunLoop run_loop; download_service_->CheckClientDownload( @@ -1434,8 +1424,7 @@ // Tests that signatures get recorded and uploaded for signed DMGs. TEST_F(DownloadProtectionServiceTest, CheckClientDownloadReportDmgWithSignature) { - net::FakeURLFetcherFactory factory(NULL); - PrepareResponse(&factory, ClientDownloadResponse::SAFE, net::HTTP_OK, + PrepareResponse(ClientDownloadResponse::SAFE, net::HTTP_OK, net::URLRequestStatus::SUCCESS); base::FilePath signed_dmg; @@ -1481,8 +1470,7 @@ // Tests that no signature gets recorded and uploaded for unsigned DMGs. TEST_F(DownloadProtectionServiceTest, CheckClientDownloadReportDmgWithoutSignature) { - net::FakeURLFetcherFactory factory(NULL); - PrepareResponse(&factory, ClientDownloadResponse::SAFE, net::HTTP_OK, + PrepareResponse(ClientDownloadResponse::SAFE, net::HTTP_OK, net::URLRequestStatus::SUCCESS); base::FilePath unsigned_dmg; @@ -1518,8 +1506,7 @@ // trailer are treated as disk images and processed accordingly. TEST_F(DownloadProtectionServiceTest, CheckClientDownloadReportDmgWithoutExtension) { - net::FakeURLFetcherFactory factory(NULL); - PrepareResponse(&factory, ClientDownloadResponse::SAFE, net::HTTP_OK, + PrepareResponse(ClientDownloadResponse::SAFE, net::HTTP_OK, net::URLRequestStatus::SUCCESS); base::FilePath test_data; @@ -1552,8 +1539,7 @@ // Demonstrate that a .dmg file whose a) extension has been changed to .txt and // b) 'koly' signature has been removed is not processed as a disk image. TEST_F(DownloadProtectionServiceTest, CheckClientDownloadReportDmgWithoutKoly) { - net::FakeURLFetcherFactory factory(NULL); - PrepareResponse(&factory, ClientDownloadResponse::SAFE, net::HTTP_OK, + PrepareResponse(ClientDownloadResponse::SAFE, net::HTTP_OK, net::URLRequestStatus::SUCCESS); base::FilePath test_data; @@ -1586,8 +1572,7 @@ // Test that a large DMG (size equals max value of 64 bit signed int) is not // unpacked for binary feature analysis. TEST_F(DownloadProtectionServiceTest, CheckClientDownloadReportLargeDmg) { - net::FakeURLFetcherFactory factory(NULL); - PrepareResponse(&factory, ClientDownloadResponse::SAFE, net::HTTP_OK, + PrepareResponse(ClientDownloadResponse::SAFE, net::HTTP_OK, net::URLRequestStatus::SUCCESS); base::FilePath unsigned_dmg; @@ -1625,8 +1610,6 @@ #endif // OS_MACOSX TEST_F(DownloadProtectionServiceTest, CheckClientDownloadValidateRequest) { - net::TestURLFetcherFactory factory; - #if defined(OS_MACOSX) std::string download_file_path("ftp://www.google.com/bla.dmg"); #else @@ -1697,14 +1680,11 @@ EXPECT_TRUE(headers.pe_headers().has_dos_header()); EXPECT_EQ("dummy dos header", headers.pe_headers().dos_header()); #endif // OS_MACOSX - } // Similar to above, but with an unsigned binary. TEST_F(DownloadProtectionServiceTest, CheckClientDownloadValidateRequestNoSignature) { - net::TestURLFetcherFactory factory; - #if defined(OS_MACOSX) std::string download_file_path("ftp://www.google.com/bla.dmg"); #else @@ -1767,8 +1747,6 @@ // Similar to above, but with tab history. TEST_F(DownloadProtectionServiceTest, CheckClientDownloadValidateRequestTabHistory) { - net::TestURLFetcherFactory factory; - NiceMockDownloadItem item; PrepareBasicDownloadItem( &item, @@ -1797,19 +1775,29 @@ // First test with no history match for the tab URL. { - TestURLFetcherWatcher fetcher_watcher(&factory); + RunLoop interceptor_run_loop; + + std::string upload_data; + sb_service_->test_url_loader_factory()->SetInterceptor( + base::BindLambdaForTesting( + [&](const network::ResourceRequest& request) { + upload_data = GetBodyFromRequest(request); + if (!upload_data.empty()) + interceptor_run_loop.Quit(); + })); + RunLoop run_loop; download_service_->CheckClientDownload( &item, base::Bind(&DownloadProtectionServiceTest::CheckDoneCallback, base::Unretained(this), run_loop.QuitClosure())); - EXPECT_EQ(0, fetcher_watcher.WaitForRequest()); + interceptor_run_loop.Run(); + EXPECT_TRUE(HasClientDownloadRequest()); ClearClientDownloadRequest(); - net::TestURLFetcher* fetcher = factory.GetFetcherByID(0); - ASSERT_TRUE(fetcher); + ClientDownloadRequest request; - EXPECT_TRUE(request.ParseFromString(fetcher->upload_data())); + EXPECT_TRUE(request.ParseFromString(upload_data)); EXPECT_EQ("http://www.google.com/bla.exe", request.url()); EXPECT_EQ(hash_, request.digests().sha256()); EXPECT_EQ(item.GetReceivedBytes(), request.length()); @@ -1836,16 +1824,26 @@ EXPECT_TRUE(headers.pe_headers().has_dos_header()); EXPECT_EQ("dummy dos header", headers.pe_headers().dos_header()); + sb_service_->test_url_loader_factory()->SetInterceptor( + network::TestURLLoaderFactory::Interceptor()); + // Simulate the request finishing. - base::ThreadTaskRunnerHandle::Get()->PostTask( - FROM_HERE, - base::BindOnce(&DownloadProtectionServiceTest::SendURLFetchComplete, - base::Unretained(this), fetcher)); run_loop.Run(); } // Now try with a history match. { + RunLoop interceptor_run_loop; + + std::string upload_data; + sb_service_->test_url_loader_factory()->SetInterceptor( + base::BindLambdaForTesting( + [&](const network::ResourceRequest& request) { + upload_data = GetBodyFromRequest(request); + if (!upload_data.empty()) + interceptor_run_loop.Quit(); + })); + history::RedirectList redirects; redirects.push_back(GURL("http://tab.com/ref1")); redirects.push_back(GURL("http://tab.com/ref2")); @@ -1856,18 +1854,17 @@ reinterpret_cast<history::ContextID>(1), 0, GURL(), redirects, ui::PAGE_TRANSITION_TYPED, history::SOURCE_BROWSED, false); - TestURLFetcherWatcher fetcher_watcher(&factory); RunLoop run_loop; download_service_->CheckClientDownload( &item, base::Bind(&DownloadProtectionServiceTest::CheckDoneCallback, base::Unretained(this), run_loop.QuitClosure())); - EXPECT_EQ(0, fetcher_watcher.WaitForRequest()); + + interceptor_run_loop.Run(); + EXPECT_TRUE(HasClientDownloadRequest()); ClearClientDownloadRequest(); - net::TestURLFetcher* fetcher = factory.GetFetcherByID(0); - ASSERT_TRUE(fetcher); ClientDownloadRequest request; - EXPECT_TRUE(request.ParseFromString(fetcher->upload_data())); + EXPECT_TRUE(request.ParseFromString(upload_data)); EXPECT_EQ("http://www.google.com/bla.exe", request.url()); EXPECT_EQ(hash_, request.digests().sha256()); EXPECT_EQ(item.GetReceivedBytes(), request.length()); @@ -1896,17 +1893,11 @@ EXPECT_EQ("dummy cert data", chain.element(0).certificate()); // Simulate the request finishing. - base::ThreadTaskRunnerHandle::Get()->PostTask( - FROM_HERE, - base::BindOnce(&DownloadProtectionServiceTest::SendURLFetchComplete, - base::Unretained(this), fetcher)); run_loop.Run(); } } TEST_F(DownloadProtectionServiceTest, TestCheckDownloadUrl) { - net::TestURLFetcherFactory factory; - std::vector<GURL> url_chain; url_chain.push_back(GURL("http://www.google.com/")); url_chain.push_back(GURL("http://www.google.com/bla.exe")); @@ -1975,8 +1966,6 @@ } TEST_F(DownloadProtectionServiceTest, TestDownloadRequestTimeout) { - net::TestURLFetcherFactory factory; - NiceMockDownloadItem item; PrepareBasicDownloadItem(&item, {"http://www.evil.com/bla.exe"}, // url_chain "http://www.google.com/", // referrer @@ -2043,7 +2032,6 @@ TEST_F(DownloadProtectionServiceTest, TestDownloadItemDestroyedDuringWhitelistCheck) { - net::TestURLFetcherFactory factory; std::unique_ptr<NiceMockDownloadItem> item(new NiceMockDownloadItem); PrepareBasicDownloadItem(item.get(), {"http://www.evil.com/bla.exe"}, // url_chain @@ -2213,7 +2201,6 @@ } TEST_F(DownloadProtectionServiceTest, PPAPIDownloadRequest_SupportedDefault) { - net::FakeURLFetcherFactory factory(nullptr); base::FilePath default_file_path(FILE_PATH_LITERAL("/foo/bar/test.crx")); std::vector<base::FilePath::StringType> alternate_extensions; EXPECT_CALL(*sb_service_->mock_database_manager(), @@ -2234,8 +2221,8 @@ }; for (const auto& test_case : kExpectedResults) { - factory.ClearFakeResponses(); - PrepareResponse(&factory, test_case.verdict, net::HTTP_OK, + sb_service_->test_url_loader_factory()->ClearResponses(); + PrepareResponse(test_case.verdict, net::HTTP_OK, net::URLRequestStatus::SUCCESS); SetExtendedReportingPreference(true); RunLoop run_loop; @@ -2252,11 +2239,10 @@ } TEST_F(DownloadProtectionServiceTest, PPAPIDownloadRequest_SupportedAlternate) { - net::FakeURLFetcherFactory factory(nullptr); base::FilePath default_file_path(FILE_PATH_LITERAL("/foo/bar/test.txt")); std::vector<base::FilePath::StringType> alternate_extensions{ FILE_PATH_LITERAL(".tmp"), FILE_PATH_LITERAL(".crx")}; - PrepareResponse(&factory, ClientDownloadResponse::DANGEROUS, net::HTTP_OK, + PrepareResponse(ClientDownloadResponse::DANGEROUS, net::HTTP_OK, net::URLRequestStatus::SUCCESS); EXPECT_CALL(*sb_service_->mock_database_manager(), MatchDownloadWhitelistUrl(_)) @@ -2276,7 +2262,6 @@ } TEST_F(DownloadProtectionServiceTest, PPAPIDownloadRequest_WhitelistedURL) { - net::FakeURLFetcherFactory factory(nullptr); base::FilePath default_file_path(FILE_PATH_LITERAL("/foo/bar/test.crx")); std::vector<base::FilePath::StringType> alternate_extensions; EXPECT_CALL(*sb_service_->mock_database_manager(), @@ -2295,10 +2280,9 @@ } TEST_F(DownloadProtectionServiceTest, PPAPIDownloadRequest_FetchFailed) { - net::FakeURLFetcherFactory factory(nullptr); base::FilePath default_file_path(FILE_PATH_LITERAL("/foo/bar/test.crx")); std::vector<base::FilePath::StringType> alternate_extensions; - PrepareResponse(&factory, ClientDownloadResponse::DANGEROUS, net::HTTP_OK, + PrepareResponse(ClientDownloadResponse::DANGEROUS, net::HTTP_OK, net::URLRequestStatus::FAILED); EXPECT_CALL(*sb_service_->mock_database_manager(), MatchDownloadWhitelistUrl(_)) @@ -2315,12 +2299,10 @@ } TEST_F(DownloadProtectionServiceTest, PPAPIDownloadRequest_InvalidResponse) { - net::FakeURLFetcherFactory factory(nullptr); base::FilePath default_file_path(FILE_PATH_LITERAL("/foo/bar/test.crx")); std::vector<base::FilePath::StringType> alternate_extensions; - factory.SetFakeResponse(PPAPIDownloadRequest::GetDownloadRequestUrl(), - "Hello world!", net::HTTP_OK, - net::URLRequestStatus::SUCCESS); + sb_service_->test_url_loader_factory()->AddResponse( + PPAPIDownloadRequest::GetDownloadRequestUrl().spec(), "Hello world!"); EXPECT_CALL(*sb_service_->mock_database_manager(), MatchDownloadWhitelistUrl(_)) .WillRepeatedly(Return(false)); @@ -2336,13 +2318,12 @@ } TEST_F(DownloadProtectionServiceTest, PPAPIDownloadRequest_Timeout) { - net::FakeURLFetcherFactory factory(nullptr); base::FilePath default_file_path(FILE_PATH_LITERAL("/foo/bar/test.crx")); std::vector<base::FilePath::StringType> alternate_extensions; EXPECT_CALL(*sb_service_->mock_database_manager(), MatchDownloadWhitelistUrl(_)) .WillRepeatedly(Return(false)); - PrepareResponse(&factory, ClientDownloadResponse::SAFE, net::HTTP_OK, + PrepareResponse(ClientDownloadResponse::SAFE, net::HTTP_OK, net::URLRequestStatus::SUCCESS); download_service_->download_request_timeout_ms_ = 0; RunLoop run_loop; @@ -2356,47 +2337,15 @@ ASSERT_TRUE(IsResult(DownloadCheckResult::UNKNOWN)); } -namespace { - -std::unique_ptr<net::FakeURLFetcher> FakeURLFetcherCreatorFunc( - std::string* upload_data_receiver, - const GURL& url, - net::URLFetcherDelegate* delegate, - const std::string& response_body, - net::HttpStatusCode response_code, - net::URLRequestStatus::Status status) { - class URLFetcher : public net::FakeURLFetcher { - public: - URLFetcher(std::string* upload_data_receiver, - const GURL& url, - net::URLFetcherDelegate* delegate, - const std::string& response_body, - net::HttpStatusCode response_code, - net::URLRequestStatus::Status status) - : FakeURLFetcher(url, delegate, response_body, response_code, status), - upload_data_receiver_(upload_data_receiver) {} - - void SetUploadData(const std::string& upload_content_type, - const std::string& upload_content) override { - *upload_data_receiver_ = upload_content; - FakeURLFetcher::SetUploadData(upload_content_type, upload_content); - } - - private: - std::string* upload_data_receiver_; - }; - - return std::unique_ptr<net::FakeURLFetcher>( - new URLFetcher(upload_data_receiver, url, delegate, response_body, - response_code, status)); -} - -} // namespace - TEST_F(DownloadProtectionServiceTest, PPAPIDownloadRequest_Payload) { + RunLoop interceptor_run_loop; + std::string upload_data; - net::FakeURLFetcherFactory factory( - nullptr, base::Bind(&FakeURLFetcherCreatorFunc, &upload_data)); + sb_service_->test_url_loader_factory()->SetInterceptor( + base::BindLambdaForTesting([&](const network::ResourceRequest& request) { + upload_data = GetBodyFromRequest(request); + })); + base::FilePath default_file_path(FILE_PATH_LITERAL("/foo/bar/test.crx")); std::vector<base::FilePath::StringType> alternate_extensions{ FILE_PATH_LITERAL(".txt"), FILE_PATH_LITERAL(".abc"), @@ -2404,7 +2353,7 @@ EXPECT_CALL(*sb_service_->mock_database_manager(), MatchDownloadWhitelistUrl(_)) .WillRepeatedly(Return(false)); - PrepareResponse(&factory, ClientDownloadResponse::SAFE, net::HTTP_OK, + PrepareResponse(ClientDownloadResponse::SAFE, net::HTTP_OK, net::URLRequestStatus::SUCCESS); const GURL kRequestorUrl("http://example.com/foo"); RunLoop run_loop;
diff --git a/chrome/browser/safe_browsing/download_protection/ppapi_download_request.cc b/chrome/browser/safe_browsing/download_protection/ppapi_download_request.cc index 5e87d3be..dab8f8b 100644 --- a/chrome/browser/safe_browsing/download_protection/ppapi_download_request.cc +++ b/chrome/browser/safe_browsing/download_protection/ppapi_download_request.cc
@@ -20,6 +20,8 @@ #include "net/http/http_cache.h" #include "net/http/http_status_code.h" #include "net/url_request/url_fetcher.h" +#include "services/network/public/cpp/shared_url_loader_factory.h" +#include "services/network/public/cpp/simple_url_loader.h" using content::BrowserThread; @@ -66,7 +68,7 @@ } PPAPIDownloadRequest::~PPAPIDownloadRequest() { - if (fetcher_ && !callback_.is_null()) + if (loader_ && !callback_.is_null()) Finish(RequestOutcome::REQUEST_DESTROYED, DownloadCheckResult::UNKNOWN); } @@ -236,35 +238,35 @@ } } })"); - fetcher_ = - net::URLFetcher::Create(0, GetDownloadRequestUrl(), net::URLFetcher::POST, - this, traffic_annotation); - data_use_measurement::DataUseUserData::AttachToFetcher( - fetcher_.get(), data_use_measurement::DataUseUserData::SAFE_BROWSING); - fetcher_->SetLoadFlags(net::LOAD_DISABLE_CACHE); - fetcher_->SetAutomaticallyRetryOn5xx(false); - fetcher_->SetRequestContext(service_->request_context_getter_.get()); - fetcher_->SetUploadData("application/octet-stream", - client_download_request_data_); - fetcher_->Start(); + auto resource_request = std::make_unique<network::ResourceRequest>(); + resource_request->url = GetDownloadRequestUrl(); + resource_request->method = "POST"; + resource_request->load_flags = net::LOAD_DISABLE_CACHE; + loader_ = network::SimpleURLLoader::Create(std::move(resource_request), + traffic_annotation); + loader_->AttachStringForUpload(client_download_request_data_, + "application/octet-stream"); + loader_->DownloadToStringOfUnboundedSizeUntilCrashAndDie( + service_->url_loader_factory_.get(), + base::BindOnce(&PPAPIDownloadRequest::OnURLLoaderComplete, + base::Unretained(this))); } -// net::URLFetcherDelegate -void PPAPIDownloadRequest::OnURLFetchComplete(const net::URLFetcher* source) { +void PPAPIDownloadRequest::OnURLLoaderComplete( + std::unique_ptr<std::string> response_body) { DCHECK_CURRENTLY_ON(BrowserThread::UI); - if (!source->GetStatus().is_success() || - net::HTTP_OK != source->GetResponseCode()) { + int response_code = 0; + if (loader_->ResponseInfo() && loader_->ResponseInfo()->headers) + response_code = loader_->ResponseInfo()->headers->response_code(); + if (loader_->NetError() != net::OK || net::HTTP_OK != response_code) { Finish(RequestOutcome::FETCH_FAILED, DownloadCheckResult::UNKNOWN); return; } ClientDownloadResponse response; - std::string response_body; - bool got_data = source->GetResponseAsString(&response_body); - DCHECK(got_data); - if (response.ParseFromString(response_body)) { + if (response.ParseFromString(*response_body.get())) { Finish(RequestOutcome::SUCCEEDED, DownloadCheckResultFromClientDownloadResponse(response.verdict())); } else { @@ -291,7 +293,7 @@ base::TimeTicks::Now() - start_time_); if (!callback_.is_null()) base::ResetAndReturn(&callback_).Run(response); - fetcher_.reset(); + loader_.reset(); weakptr_factory_.InvalidateWeakPtrs(); // If the request is being destroyed, don't notify the service_. It already
diff --git a/chrome/browser/safe_browsing/download_protection/ppapi_download_request.h b/chrome/browser/safe_browsing/download_protection/ppapi_download_request.h index daf2d515..afdd6345 100644 --- a/chrome/browser/safe_browsing/download_protection/ppapi_download_request.h +++ b/chrome/browser/safe_browsing/download_protection/ppapi_download_request.h
@@ -11,13 +11,16 @@ #include "base/files/file_path.h" #include "base/memory/weak_ptr.h" #include "chrome/browser/safe_browsing/download_protection/download_protection_util.h" -#include "net/url_request/url_fetcher_delegate.h" #include "url/gurl.h" namespace content { class WebContents; } // namespace content +namespace network { +class SimpleURLLoader; +} + class Profile; namespace safe_browsing { @@ -39,7 +42,7 @@ // // PPAPIDownloadRequest objects are owned by the DownloadProtectionService // indicated by |service|. -class PPAPIDownloadRequest : public net::URLFetcherDelegate { +class PPAPIDownloadRequest { public: // The outcome of the request. These values are used for UMA. New values // should only be added at the end. @@ -66,7 +69,7 @@ DownloadProtectionService* service, scoped_refptr<SafeBrowsingDatabaseManager> database_manager); - ~PPAPIDownloadRequest() override; + ~PPAPIDownloadRequest(); // Start the process of checking the download request. The callback passed as // the |callback| parameter to the constructor will be invoked with the result @@ -100,8 +103,7 @@ void SendRequest(); - // net::URLFetcherDelegate - void OnURLFetchComplete(const net::URLFetcher* source) override; + void OnURLLoaderComplete(std::unique_ptr<std::string> response_body); void OnRequestTimedOut(); @@ -118,7 +120,7 @@ const base::FilePath& default_file_path, const std::vector<base::FilePath::StringType>& alternate_extensions); - std::unique_ptr<net::URLFetcher> fetcher_; + std::unique_ptr<network::SimpleURLLoader> loader_; std::string client_download_request_data_; // URL of document that requested the PPAPI download.
diff --git a/chrome/browser/safe_browsing/download_protection/two_phase_uploader.cc b/chrome/browser/safe_browsing/download_protection/two_phase_uploader.cc index 217ae00..e8bd31b8fb 100644 --- a/chrome/browser/safe_browsing/download_protection/two_phase_uploader.cc +++ b/chrome/browser/safe_browsing/download_protection/two_phase_uploader.cc
@@ -12,13 +12,14 @@ #include "base/macros.h" #include "base/memory/ptr_util.h" #include "base/task_runner.h" -#include "components/data_use_measurement/core/data_use_user_data.h" #include "content/public/browser/browser_thread.h" #include "net/base/net_errors.h" #include "net/http/http_response_headers.h" #include "net/url_request/url_fetcher.h" #include "net/url_request/url_fetcher_delegate.h" #include "net/url_request/url_request_status.h" +#include "services/network/public/cpp/shared_url_loader_factory.h" +#include "services/network/public/cpp/simple_url_loader.h" namespace { @@ -30,16 +31,14 @@ const char kUploadContentType[] = "application/octet-stream"; -class TwoPhaseUploaderImpl : public net::URLFetcherDelegate, - public TwoPhaseUploader { +class TwoPhaseUploaderImpl : public TwoPhaseUploader { public: TwoPhaseUploaderImpl( - net::URLRequestContextGetter* url_request_context_getter, + scoped_refptr<network::SharedURLLoaderFactory> url_loader_factory, base::TaskRunner* file_task_runner, const GURL& base_url, const std::string& metadata, const base::FilePath& file_path, - const ProgressCallback& progress_callback, const FinishCallback& finish_callback, const net::NetworkTrafficAnnotationTag& traffic_annotation); ~TwoPhaseUploaderImpl() override; @@ -47,11 +46,7 @@ // Begins the upload process. void Start() override; - // net::URLFetcherDelegate implementation: - void OnURLFetchComplete(const net::URLFetcher* source) override; - void OnURLFetchUploadProgress(const net::URLFetcher* source, - int64_t current, - int64_t total) override; + void OnURLLoaderComplete(std::unique_ptr<std::string> response_body); private: void UploadMetadata(); @@ -59,37 +54,34 @@ void Finish(int net_error, int response_code, const std::string& response); State state_; - scoped_refptr<net::URLRequestContextGetter> url_request_context_getter_; + scoped_refptr<network::SharedURLLoaderFactory> url_loader_factory_; scoped_refptr<base::TaskRunner> file_task_runner_; GURL base_url_; GURL upload_url_; std::string metadata_; const base::FilePath file_path_; - ProgressCallback progress_callback_; FinishCallback finish_callback_; net::NetworkTrafficAnnotationTag traffic_annotation_; - std::unique_ptr<net::URLFetcher> url_fetcher_; + std::unique_ptr<network::SimpleURLLoader> url_loader_; DISALLOW_COPY_AND_ASSIGN(TwoPhaseUploaderImpl); }; TwoPhaseUploaderImpl::TwoPhaseUploaderImpl( - net::URLRequestContextGetter* url_request_context_getter, + scoped_refptr<network::SharedURLLoaderFactory> url_loader_factory, base::TaskRunner* file_task_runner, const GURL& base_url, const std::string& metadata, const base::FilePath& file_path, - const ProgressCallback& progress_callback, const FinishCallback& finish_callback, const net::NetworkTrafficAnnotationTag& traffic_annotation) : state_(STATE_NONE), - url_request_context_getter_(url_request_context_getter), + url_loader_factory_(url_loader_factory), file_task_runner_(file_task_runner), base_url_(base_url), metadata_(metadata), file_path_(file_path), - progress_callback_(progress_callback), finish_callback_(finish_callback), traffic_annotation_(traffic_annotation) { DCHECK_CURRENTLY_ON(content::BrowserThread::UI); @@ -106,33 +98,33 @@ UploadMetadata(); } -void TwoPhaseUploaderImpl::OnURLFetchComplete(const net::URLFetcher* source) { +void TwoPhaseUploaderImpl::OnURLLoaderComplete( + std::unique_ptr<std::string> response_body) { DCHECK_CURRENTLY_ON(content::BrowserThread::UI); - net::URLRequestStatus status = source->GetStatus(); - int response_code = source->GetResponseCode(); + int response_code = 0; + if (url_loader_->ResponseInfo() && url_loader_->ResponseInfo()->headers) + response_code = url_loader_->ResponseInfo()->headers->response_code(); - DVLOG(1) << __func__ << " " << source->GetURL().spec() << " " - << status.status() << " " << response_code; + DVLOG(1) << __func__ << " " << url_loader_->GetFinalURL().spec() << " " + << url_loader_->NetError() << " " << response_code; - if (!status.is_success()) { - LOG(ERROR) << "URLFetcher failed, status=" << status.status() - << " err=" << status.error(); - Finish(status.error(), response_code, std::string()); + if (url_loader_->NetError() != net::OK) { + LOG(ERROR) << "URLFetcher failed, err=" << url_loader_->NetError(); + Finish(url_loader_->NetError(), response_code, std::string()); return; } - std::string response; - source->GetResponseAsString(&response); - switch (state_) { case UPLOAD_METADATA: { if (response_code != 201) { LOG(ERROR) << "Invalid response to initial request: " << response_code; - Finish(net::OK, response_code, response); + Finish(net::OK, response_code, *response_body.get()); return; } std::string location; - if (!source->GetResponseHeaders()->EnumerateHeader( + if (!url_loader_->ResponseInfo() || + !url_loader_->ResponseInfo()->headers || + !url_loader_->ResponseInfo()->headers->EnumerateHeader( nullptr, kLocationHeader, &location)) { LOG(ERROR) << "no location header"; Finish(net::OK, response_code, std::string()); @@ -149,51 +141,45 @@ } else { state_ = STATE_SUCCESS; } - Finish(net::OK, response_code, response); + Finish(net::OK, response_code, *response_body.get()); return; default: NOTREACHED(); } } -void TwoPhaseUploaderImpl::OnURLFetchUploadProgress( - const net::URLFetcher* source, - int64_t current, - int64_t total) { - DCHECK_CURRENTLY_ON(content::BrowserThread::UI); - DVLOG(3) << __func__ << " " << source->GetURL().spec() << " " << current - << "/" << total; - if (state_ == UPLOAD_FILE && !progress_callback_.is_null()) - progress_callback_.Run(current, total); -} - void TwoPhaseUploaderImpl::UploadMetadata() { DCHECK_CURRENTLY_ON(content::BrowserThread::UI); state_ = UPLOAD_METADATA; - url_fetcher_ = net::URLFetcher::Create(base_url_, net::URLFetcher::POST, this, - traffic_annotation_); - - data_use_measurement::DataUseUserData::AttachToFetcher( - url_fetcher_.get(), data_use_measurement::DataUseUserData::SAFE_BROWSING); - url_fetcher_->SetRequestContext(url_request_context_getter_.get()); - url_fetcher_->SetExtraRequestHeaders(kStartHeader); - url_fetcher_->SetUploadData(kUploadContentType, metadata_); - url_fetcher_->Start(); + auto resource_request = std::make_unique<network::ResourceRequest>(); + resource_request->url = base_url_; + resource_request->method = "POST"; + resource_request->headers.AddHeadersFromString(kStartHeader); + url_loader_ = network::SimpleURLLoader::Create(std::move(resource_request), + traffic_annotation_); + url_loader_->SetAllowHttpErrorResults(true); + url_loader_->AttachStringForUpload(metadata_, kUploadContentType); + url_loader_->DownloadToStringOfUnboundedSizeUntilCrashAndDie( + url_loader_factory_.get(), + base::BindOnce(&TwoPhaseUploaderImpl::OnURLLoaderComplete, + base::Unretained(this))); } void TwoPhaseUploaderImpl::UploadFile() { DCHECK_CURRENTLY_ON(content::BrowserThread::UI); state_ = UPLOAD_FILE; - url_fetcher_ = net::URLFetcher::Create(upload_url_, net::URLFetcher::PUT, - this, traffic_annotation_); - data_use_measurement::DataUseUserData::AttachToFetcher( - url_fetcher_.get(), data_use_measurement::DataUseUserData::SAFE_BROWSING); - url_fetcher_->SetRequestContext(url_request_context_getter_.get()); - url_fetcher_->SetUploadFilePath(kUploadContentType, file_path_, 0, - std::numeric_limits<uint64_t>::max(), - file_task_runner_); - url_fetcher_->Start(); + auto resource_request = std::make_unique<network::ResourceRequest>(); + resource_request->url = upload_url_; + resource_request->method = "PUT"; + url_loader_ = network::SimpleURLLoader::Create(std::move(resource_request), + traffic_annotation_); + url_loader_->SetAllowHttpErrorResults(true); + url_loader_->AttachFileForUpload(file_path_, kUploadContentType); + url_loader_->DownloadToStringOfUnboundedSizeUntilCrashAndDie( + url_loader_factory_.get(), + base::BindOnce(&TwoPhaseUploaderImpl::OnURLLoaderComplete, + base::Unretained(this))); } void TwoPhaseUploaderImpl::Finish(int net_error, @@ -210,20 +196,19 @@ // static std::unique_ptr<TwoPhaseUploader> TwoPhaseUploader::Create( - net::URLRequestContextGetter* url_request_context_getter, + scoped_refptr<network::SharedURLLoaderFactory> url_loader_factory, base::TaskRunner* file_task_runner, const GURL& base_url, const std::string& metadata, const base::FilePath& file_path, - const ProgressCallback& progress_callback, const FinishCallback& finish_callback, const net::NetworkTrafficAnnotationTag& traffic_annotation) { if (!factory_) { return base::WrapUnique(new TwoPhaseUploaderImpl( - url_request_context_getter, file_task_runner, base_url, metadata, - file_path, progress_callback, finish_callback, traffic_annotation)); + url_loader_factory, file_task_runner, base_url, metadata, file_path, + finish_callback, traffic_annotation)); } return TwoPhaseUploader::factory_->CreateTwoPhaseUploader( - url_request_context_getter, file_task_runner, base_url, metadata, - file_path, progress_callback, finish_callback, traffic_annotation); + url_loader_factory, file_task_runner, base_url, metadata, file_path, + finish_callback, traffic_annotation); }
diff --git a/chrome/browser/safe_browsing/download_protection/two_phase_uploader.h b/chrome/browser/safe_browsing/download_protection/two_phase_uploader.h index 5703e71..52e7b32 100644 --- a/chrome/browser/safe_browsing/download_protection/two_phase_uploader.h +++ b/chrome/browser/safe_browsing/download_protection/two_phase_uploader.h
@@ -13,14 +13,13 @@ #include "base/callback.h" #include "base/files/file_path.h" #include "net/traffic_annotation/network_traffic_annotation.h" -#include "net/url_request/url_request_context_getter.h" #include "url/gurl.h" namespace base { class TaskRunner; } -namespace net { -class URLRequestContextGetter; +namespace network { +class SharedURLLoaderFactory; } class TwoPhaseUploaderFactory; @@ -42,7 +41,6 @@ UPLOAD_FILE, STATE_SUCCESS, }; - using ProgressCallback = base::Callback<void(int64_t sent, int64_t total)>; using FinishCallback = base::Callback<void(State state, int net_error, int response_code, @@ -55,8 +53,6 @@ // The uploaded |file_path| will be read on |file_task_runner|. // The first phase request will be sent to |base_url|, with |metadata| // included. - // |progress_callback| will be called periodically as the second phase - // progresses, if it is non-null. // On success |finish_callback| will be called with state = STATE_SUCCESS and // the server response in response_data. On failure, state will specify // which step the failure occurred in, and net_error, response_code, and @@ -64,12 +60,11 @@ // will not be called if the upload is cancelled by destructing the // TwoPhaseUploader object before completion. static std::unique_ptr<TwoPhaseUploader> Create( - net::URLRequestContextGetter* url_request_context_getter, + scoped_refptr<network::SharedURLLoaderFactory> url_loader_factory, base::TaskRunner* file_task_runner, const GURL& base_url, const std::string& metadata, const base::FilePath& file_path, - const ProgressCallback& progress_callback, const FinishCallback& finish_callback, const net::NetworkTrafficAnnotationTag& traffic_annotation); @@ -93,12 +88,11 @@ virtual ~TwoPhaseUploaderFactory() {} virtual std::unique_ptr<TwoPhaseUploader> CreateTwoPhaseUploader( - net::URLRequestContextGetter* url_request_context_getter, + scoped_refptr<network::SharedURLLoaderFactory> url_loader_factory, base::TaskRunner* file_task_runner, const GURL& base_url, const std::string& metadata, const base::FilePath& file_path, - const TwoPhaseUploader::ProgressCallback& progress_callback, const TwoPhaseUploader::FinishCallback& finish_callback, const net::NetworkTrafficAnnotationTag& traffic_annotation) = 0; };
diff --git a/chrome/browser/safe_browsing/download_protection/two_phase_uploader_unittest.cc b/chrome/browser/safe_browsing/download_protection/two_phase_uploader_unittest.cc index 8bd23a9..3a9ebd9 100644 --- a/chrome/browser/safe_browsing/download_protection/two_phase_uploader_unittest.cc +++ b/chrome/browser/safe_browsing/download_protection/two_phase_uploader_unittest.cc
@@ -17,6 +17,8 @@ #include "net/traffic_annotation/network_traffic_annotation_test_helper.h" #include "net/url_request/url_fetcher.h" #include "net/url_request/url_request_test_util.h" +#include "services/network/network_context.h" +#include "services/network/public/cpp/shared_url_loader_factory.h" #include "testing/gtest/include/gtest/gtest.h" using content::BrowserThread; @@ -30,8 +32,6 @@ public: Delegate() : state_(TwoPhaseUploader::STATE_NONE) {} - void ProgressCallback(int64_t current, int64_t total) {} - void FinishCallback(scoped_refptr<MessageLoopRunner> runner, TwoPhaseUploader::State state, int net_error, @@ -60,6 +60,38 @@ return file_path; } +class SharedURLLoaderFactory : public network::SharedURLLoaderFactory { + public: + explicit SharedURLLoaderFactory( + network::mojom::URLLoaderFactory* url_loader_factory) + : url_loader_factory_(url_loader_factory) {} + + std::unique_ptr<network::SharedURLLoaderFactoryInfo> Clone() override { + NOTREACHED(); + return nullptr; + } + + // network::URLLoaderFactory implementation: + void CreateLoaderAndStart(network::mojom::URLLoaderRequest loader, + int32_t routing_id, + int32_t request_id, + uint32_t options, + const network::ResourceRequest& request, + network::mojom::URLLoaderClientPtr client, + const net::MutableNetworkTrafficAnnotationTag& + traffic_annotation) override { + url_loader_factory_->CreateLoaderAndStart( + std::move(loader), routing_id, request_id, options, std::move(request), + std::move(client), traffic_annotation); + } + + private: + friend class base::RefCounted<SharedURLLoaderFactory>; + ~SharedURLLoaderFactory() override = default; + + network::mojom::URLLoaderFactory* url_loader_factory_; +}; + } // namespace class TwoPhaseUploaderTest : public testing::Test { @@ -67,7 +99,16 @@ TwoPhaseUploaderTest() : thread_bundle_(content::TestBrowserThreadBundle::IO_MAINLOOP), url_request_context_getter_(new net::TestURLRequestContextGetter( - BrowserThread::GetTaskRunnerForThread(BrowserThread::IO))) {} + BrowserThread::GetTaskRunnerForThread(BrowserThread::IO))) { + network::mojom::NetworkContextPtr network_context; + network_context_ = std::make_unique<network::NetworkContext>( + nullptr, mojo::MakeRequest(&network_context), + url_request_context_getter_); + network_context_->CreateURLLoaderFactory( + mojo::MakeRequest(&url_loader_factory_), 0); + shared_url_loader_factory_ = + base::MakeRefCounted<SharedURLLoaderFactory>(url_loader_factory_.get()); + } protected: content::TestBrowserThreadBundle thread_bundle_; @@ -76,6 +117,9 @@ const scoped_refptr<base::SequencedTaskRunner> task_runner_ = base::CreateSequencedTaskRunnerWithTraits( {base::MayBlock(), base::TaskPriority::BACKGROUND}); + std::unique_ptr<network::NetworkContext> network_context_; + network::mojom::URLLoaderFactoryPtr url_loader_factory_; + scoped_refptr<SharedURLLoaderFactory> shared_url_loader_factory_; }; TEST_F(TwoPhaseUploaderTest, UploadFile) { @@ -84,9 +128,8 @@ ASSERT_TRUE(test_server.Start()); Delegate delegate; std::unique_ptr<TwoPhaseUploader> uploader(TwoPhaseUploader::Create( - url_request_context_getter_.get(), task_runner_.get(), + shared_url_loader_factory_, task_runner_.get(), test_server.GetURL("start"), "metadata", GetTestFilePath(), - base::Bind(&Delegate::ProgressCallback, base::Unretained(&delegate)), base::Bind(&Delegate::FinishCallback, base::Unretained(&delegate), runner), TRAFFIC_ANNOTATION_FOR_TESTS)); @@ -108,9 +151,8 @@ ASSERT_TRUE(test_server.Start()); Delegate delegate; std::unique_ptr<TwoPhaseUploader> uploader(TwoPhaseUploader::Create( - url_request_context_getter_.get(), task_runner_.get(), + shared_url_loader_factory_, task_runner_.get(), test_server.GetURL("start?p1code=500"), "metadata", GetTestFilePath(), - base::Bind(&Delegate::ProgressCallback, base::Unretained(&delegate)), base::Bind(&Delegate::FinishCallback, base::Unretained(&delegate), runner), TRAFFIC_ANNOTATION_FOR_TESTS)); @@ -128,9 +170,8 @@ ASSERT_TRUE(test_server.Start()); Delegate delegate; std::unique_ptr<TwoPhaseUploader> uploader(TwoPhaseUploader::Create( - url_request_context_getter_.get(), task_runner_.get(), + shared_url_loader_factory_, task_runner_.get(), test_server.GetURL("start?p2code=500"), "metadata", GetTestFilePath(), - base::Bind(&Delegate::ProgressCallback, base::Unretained(&delegate)), base::Bind(&Delegate::FinishCallback, base::Unretained(&delegate), runner), TRAFFIC_ANNOTATION_FOR_TESTS)); @@ -152,9 +193,8 @@ ASSERT_TRUE(test_server.Start()); Delegate delegate; std::unique_ptr<TwoPhaseUploader> uploader(TwoPhaseUploader::Create( - url_request_context_getter_.get(), task_runner_.get(), + shared_url_loader_factory_, task_runner_.get(), test_server.GetURL("start?p1close=1"), "metadata", GetTestFilePath(), - base::Bind(&Delegate::ProgressCallback, base::Unretained(&delegate)), base::Bind(&Delegate::FinishCallback, base::Unretained(&delegate), runner), TRAFFIC_ANNOTATION_FOR_TESTS)); @@ -162,7 +202,6 @@ runner->Run(); EXPECT_EQ(TwoPhaseUploader::UPLOAD_METADATA, delegate.state_); EXPECT_EQ(net::ERR_EMPTY_RESPONSE, delegate.net_error_); - EXPECT_EQ(net::URLFetcher::RESPONSE_CODE_INVALID, delegate.response_code_); EXPECT_EQ("", delegate.response_); } @@ -172,9 +211,8 @@ ASSERT_TRUE(test_server.Start()); Delegate delegate; std::unique_ptr<TwoPhaseUploader> uploader(TwoPhaseUploader::Create( - url_request_context_getter_.get(), task_runner_.get(), + shared_url_loader_factory_, task_runner_.get(), test_server.GetURL("start?p2close=1"), "metadata", GetTestFilePath(), - base::Bind(&Delegate::ProgressCallback, base::Unretained(&delegate)), base::Bind(&Delegate::FinishCallback, base::Unretained(&delegate), runner), TRAFFIC_ANNOTATION_FOR_TESTS)); @@ -182,7 +220,6 @@ runner->Run(); EXPECT_EQ(TwoPhaseUploader::UPLOAD_FILE, delegate.state_); EXPECT_EQ(net::ERR_EMPTY_RESPONSE, delegate.net_error_); - EXPECT_EQ(net::URLFetcher::RESPONSE_CODE_INVALID, delegate.response_code_); EXPECT_EQ("", delegate.response_); }
diff --git a/chrome/browser/safe_browsing/safe_browsing_service.h b/chrome/browser/safe_browsing/safe_browsing_service.h index 1299f11..ddc20fc 100644 --- a/chrome/browser/safe_browsing/safe_browsing_service.h +++ b/chrome/browser/safe_browsing/safe_browsing_service.h
@@ -152,7 +152,7 @@ // NetworkContext and URLLoaderFactory used for safe browsing requests. network::mojom::NetworkContext* GetNetworkContext(); - scoped_refptr<network::SharedURLLoaderFactory> GetURLLoaderFactory(); + virtual scoped_refptr<network::SharedURLLoaderFactory> GetURLLoaderFactory(); // Called on IO thread thread when QUIC should be disabled (e.g. because of // policy). This should not be necessary anymore when http://crbug.com/678653
diff --git a/chrome/browser/signin/mutable_profile_oauth2_token_service_delegate.cc b/chrome/browser/signin/mutable_profile_oauth2_token_service_delegate.cc index 04b15b6..ce676c97 100644 --- a/chrome/browser/signin/mutable_profile_oauth2_token_service_delegate.cc +++ b/chrome/browser/signin/mutable_profile_oauth2_token_service_delegate.cc
@@ -96,7 +96,7 @@ (new_token == MutableProfileOAuth2TokenServiceDelegate::kInvalidRefreshToken) ? TokenStateTransition::kRegularToInvalid - : transition = TokenStateTransition::kRegularToRegular; + : TokenStateTransition::kRegularToRegular; } DCHECK_NE(TokenStateTransition::kCount, transition); RecordTokenStateTransition(transition);
diff --git a/chrome/browser/ui/app_list/crostini/crostini_util.cc b/chrome/browser/ui/app_list/crostini/crostini_util.cc index 108b202..aa09b96 100644 --- a/chrome/browser/ui/app_list/crostini/crostini_util.cc +++ b/chrome/browser/ui/app_list/crostini/crostini_util.cc
@@ -16,7 +16,7 @@ } // namespace bool IsCrostiniAllowed() { - return base::FeatureList::IsEnabled(features::kCrostini) && + return virtual_machines::AreVirtualMachinesAllowedByVersionAndChannel() && virtual_machines::AreVirtualMachinesAllowedByPolicy(); }
diff --git a/chrome/browser/ui/ash/accessibility/ax_tree_source_aura_unittest.cc b/chrome/browser/ui/ash/accessibility/ax_tree_source_aura_unittest.cc index 843587a..f461198 100644 --- a/chrome/browser/ui/ash/accessibility/ax_tree_source_aura_unittest.cc +++ b/chrome/browser/ui/ash/accessibility/ax_tree_source_aura_unittest.cc
@@ -56,7 +56,6 @@ widget_ = new Widget(); Widget::InitParams init_params(Widget::InitParams::TYPE_WINDOW_FRAMELESS); - init_params.context = CurrentContext(); widget_->Init(init_params); content_ = new View();
diff --git a/chrome/browser/ui/ash/launcher/chrome_launcher_controller_unittest.cc b/chrome/browser/ui/ash/launcher/chrome_launcher_controller_unittest.cc index 55623883..91f6c5a 100644 --- a/chrome/browser/ui/ash/launcher/chrome_launcher_controller_unittest.cc +++ b/chrome/browser/ui/ash/launcher/chrome_launcher_controller_unittest.cc
@@ -940,7 +940,6 @@ views::Widget* CreateArcWindow(const std::string& window_app_id) { views::Widget::InitParams params(views::Widget::InitParams::TYPE_WINDOW); params.bounds = gfx::Rect(5, 5, 20, 20); - params.context = GetContext(); views::Widget* widget = new views::Widget(); widget->Init(params); // Set ARC id before showing the window to be recognized in
diff --git a/chrome/browser/ui/ash/test_wallpaper_controller.cc b/chrome/browser/ui/ash/test_wallpaper_controller.cc index 7af434a..c44fa01 100644 --- a/chrome/browser/ui/ash/test_wallpaper_controller.cc +++ b/chrome/browser/ui/ash/test_wallpaper_controller.cc
@@ -159,6 +159,12 @@ NOTIMPLEMENTED(); } +void TestWallpaperController::GetActiveUserWallpaperLocation( + ash::mojom::WallpaperController::GetActiveUserWallpaperLocationCallback + callback) { + NOTIMPLEMENTED(); +} + void TestWallpaperController::ShouldShowWallpaperSetting( ash::mojom::WallpaperController::ShouldShowWallpaperSettingCallback callback) {
diff --git a/chrome/browser/ui/ash/test_wallpaper_controller.h b/chrome/browser/ui/ash/test_wallpaper_controller.h index cbf93b6c..60fd580 100644 --- a/chrome/browser/ui/ash/test_wallpaper_controller.h +++ b/chrome/browser/ui/ash/test_wallpaper_controller.h
@@ -95,6 +95,9 @@ void IsActiveUserWallpaperControlledByPolicy( ash::mojom::WallpaperController:: IsActiveUserWallpaperControlledByPolicyCallback callback) override; + void GetActiveUserWallpaperLocation( + ash::mojom::WallpaperController::GetActiveUserWallpaperLocationCallback + callback) override; void ShouldShowWallpaperSetting( ash::mojom::WallpaperController::ShouldShowWallpaperSettingCallback callback) override;
diff --git a/chrome/browser/ui/ash/wallpaper_controller_client.cc b/chrome/browser/ui/ash/wallpaper_controller_client.cc index 9ab5e6e..f23df58 100644 --- a/chrome/browser/ui/ash/wallpaper_controller_client.cc +++ b/chrome/browser/ui/ash/wallpaper_controller_client.cc
@@ -381,6 +381,12 @@ std::move(callback)); } +void WallpaperControllerClient::GetActiveUserWallpaperLocation( + ash::mojom::WallpaperController::GetActiveUserWallpaperLocationCallback + callback) { + wallpaper_controller_->GetActiveUserWallpaperLocation(std::move(callback)); +} + void WallpaperControllerClient::ShouldShowWallpaperSetting( ash::mojom::WallpaperController::ShouldShowWallpaperSettingCallback callback) {
diff --git a/chrome/browser/ui/ash/wallpaper_controller_client.h b/chrome/browser/ui/ash/wallpaper_controller_client.h index cb70751..97b3108 100644 --- a/chrome/browser/ui/ash/wallpaper_controller_client.h +++ b/chrome/browser/ui/ash/wallpaper_controller_client.h
@@ -73,6 +73,9 @@ void IsActiveUserWallpaperControlledByPolicy( ash::mojom::WallpaperController:: IsActiveUserWallpaperControlledByPolicyCallback callback); + void GetActiveUserWallpaperLocation( + ash::mojom::WallpaperController::GetActiveUserWallpaperLocationCallback + callback); void ShouldShowWallpaperSetting( ash::mojom::WallpaperController::ShouldShowWallpaperSettingCallback callback);
diff --git a/chrome/browser/ui/browser_commands.cc b/chrome/browser/ui/browser_commands.cc index 7ba65a2a..89f43a10 100644 --- a/chrome/browser/ui/browser_commands.cc +++ b/chrome/browser/ui/browser_commands.cc
@@ -1232,7 +1232,7 @@ #if defined(OS_CHROMEOS) void QueryAndDisplayArcApps( const Browser* browser, - const std::vector<arc::ArcNavigationThrottle::AppInfo>& app_info, + const std::vector<chromeos::IntentPickerAppInfo>& app_info, IntentPickerResponse callback) { browser->window()->ShowIntentPickerBubble(app_info, callback); }
diff --git a/chrome/browser/ui/browser_commands.h b/chrome/browser/ui/browser_commands.h index e97666b..6fd5018 100644 --- a/chrome/browser/ui/browser_commands.h +++ b/chrome/browser/ui/browser_commands.h
@@ -17,7 +17,7 @@ #include "ui/base/window_open_disposition.h" #if defined(OS_CHROMEOS) -#include "chrome/browser/chromeos/arc/intent_helper/arc_navigation_throttle.h" +#include "chrome/browser/chromeos/apps/intent_helper/apps_navigation_types.h" #include "chrome/browser/ui/browser_dialogs.h" #endif @@ -154,7 +154,7 @@ #if defined(OS_CHROMEOS) void QueryAndDisplayArcApps( const Browser* browser, - const std::vector<arc::ArcNavigationThrottle::AppInfo>& app_info, + const std::vector<chromeos::IntentPickerAppInfo>& app_info, IntentPickerResponse callback); void SetIntentPickerViewVisibility(Browser* browser, bool visible); #endif // defined(OS_CHROMEOS)
diff --git a/chrome/browser/ui/browser_dialogs.h b/chrome/browser/ui/browser_dialogs.h index 0bacf38..01548fb 100644 --- a/chrome/browser/ui/browser_dialogs.h +++ b/chrome/browser/ui/browser_dialogs.h
@@ -20,6 +20,7 @@ #include "ui/gfx/native_widget_types.h" #if defined(OS_CHROMEOS) +#include "chrome/browser/chromeos/apps/intent_helper/apps_navigation_types.h" #include "chrome/browser/chromeos/arc/intent_helper/arc_navigation_throttle.h" #include "url/gurl.h" #endif // OS_CHROMEOS @@ -329,7 +330,7 @@ using BubbleShowPtr = views::Widget* (*)(views::View*, content::WebContents*, - const std::vector<arc::ArcNavigationThrottle::AppInfo>&, + const std::vector<chromeos::IntentPickerAppInfo>&, bool disable_display_in_chrome, const IntentPickerResponse&);
diff --git a/chrome/browser/ui/browser_window.h b/chrome/browser/ui/browser_window.h index 4e580586..1826b12 100644 --- a/chrome/browser/ui/browser_window.h +++ b/chrome/browser/ui/browser_window.h
@@ -27,7 +27,7 @@ #include "ui/gfx/native_widget_types.h" #if defined(OS_CHROMEOS) -#include "chrome/browser/chromeos/arc/intent_helper/arc_navigation_throttle.h" +#include "chrome/browser/chromeos/apps/intent_helper/apps_navigation_types.h" #endif // defined(OS_CHROMEOS) class Browser; @@ -234,7 +234,7 @@ // display and |callback| gives access so we can redirect the user (if needed) // and store UMA metrics. virtual void ShowIntentPickerBubble( - std::vector<arc::ArcNavigationThrottle::AppInfo> app_info, + const std::vector<chromeos::IntentPickerAppInfo>& app_info, IntentPickerResponse callback) = 0; virtual void SetIntentPickerViewVisibility(bool visible) = 0; #endif // defined(OS_CHROMEOS)
diff --git a/chrome/browser/ui/content_settings/content_setting_bubble_model.cc b/chrome/browser/ui/content_settings/content_setting_bubble_model.cc index 9fd9436..91affd3 100644 --- a/chrome/browser/ui/content_settings/content_setting_bubble_model.cc +++ b/chrome/browser/ui/content_settings/content_setting_bubble_model.cc
@@ -333,16 +333,7 @@ pending_handler_ = content_settings->pending_protocol_handler(); previous_handler_ = content_settings->previous_protocol_handler(); - base::string16 protocol; - if (pending_handler_.protocol() == "mailto") { - protocol = - l10n_util::GetStringUTF16(IDS_REGISTER_PROTOCOL_HANDLER_MAILTO_NAME); - } else if (pending_handler_.protocol() == "webcal") { - protocol = - l10n_util::GetStringUTF16(IDS_REGISTER_PROTOCOL_HANDLER_WEBCAL_NAME); - } else { - protocol = base::UTF8ToUTF16(pending_handler_.protocol()); - } + base::string16 protocol = pending_handler_.GetProtocolDisplayName(); // Note that we ignore the |title| parameter. if (previous_handler_.IsEmpty()) {
diff --git a/chrome/browser/ui/exclusive_access/fullscreen_controller_test.h b/chrome/browser/ui/exclusive_access/fullscreen_controller_test.h index da6e87e..376464d0 100644 --- a/chrome/browser/ui/exclusive_access/fullscreen_controller_test.h +++ b/chrome/browser/ui/exclusive_access/fullscreen_controller_test.h
@@ -7,6 +7,7 @@ #include "base/macros.h" #include "base/memory/weak_ptr.h" +#include "build/build_config.h" #include "chrome/browser/chrome_notification_types.h" #include "chrome/browser/ui/exclusive_access/exclusive_access_bubble_hide_callback.h" #include "chrome/browser/ui/exclusive_access/exclusive_access_bubble_type.h" @@ -15,6 +16,10 @@ #include "content/public/browser/notification_service.h" #include "content/public/test/test_utils.h" +#if defined(OS_MACOSX) +#include "ui/base/test/scoped_fake_nswindow_fullscreen.h" +#endif + // Observer for NOTIFICATION_FULLSCREEN_CHANGED notifications. class FullscreenNotificationObserver : public content::WindowedNotificationObserver { @@ -75,6 +80,13 @@ void ToggleTabFullscreen_Internal(bool enter_fullscreen, bool retry_until_success); +#if defined(OS_MACOSX) + // On Mac, entering into the system fullscreen mode can tickle crashes in + // the WindowServer (c.f. https://crbug.com/828031), so provide a fake for + // testing. + ui::test::ScopedFakeNSWindowFullscreen fake_fullscreen_window_; +#endif + base::WeakPtrFactory<FullscreenControllerTest> weak_ptr_factory_; DISALLOW_COPY_AND_ASSIGN(FullscreenControllerTest);
diff --git a/chrome/browser/ui/extensions/extension_install_ui_default.cc b/chrome/browser/ui/extensions/extension_install_ui_default.cc index 4ac3979..f24f7d2c 100644 --- a/chrome/browser/ui/extensions/extension_install_ui_default.cc +++ b/chrome/browser/ui/extensions/extension_install_ui_default.cc
@@ -76,7 +76,7 @@ void ExtensionInstallUIDefault::OnInstallSuccess(const Extension* extension, const SkBitmap* icon) { - if (skip_post_install_ui_ || extension->is_theme()) + if (disable_ui_for_tests() || skip_post_install_ui_ || extension->is_theme()) return; if (!profile_) { @@ -115,7 +115,7 @@ void ExtensionInstallUIDefault::OnInstallFailure( const extensions::CrxInstallError& error) { DCHECK_CURRENTLY_ON(BrowserThread::UI); - if (disable_failure_ui_for_tests() || skip_post_install_ui_) + if (disable_ui_for_tests() || skip_post_install_ui_) return; Browser* browser = chrome::FindLastActiveWithProfile(profile_);
diff --git a/chrome/browser/ui/views/frame/browser_view.cc b/chrome/browser/ui/views/frame/browser_view.cc index 5b19cfa..45da0b4 100644 --- a/chrome/browser/ui/views/frame/browser_view.cc +++ b/chrome/browser/ui/views/frame/browser_view.cc
@@ -1184,7 +1184,7 @@ #if defined(OS_CHROMEOS) void BrowserView::ShowIntentPickerBubble( - std::vector<IntentPickerBubbleView::AppInfo> app_info, + const std::vector<IntentPickerBubbleView::AppInfo>& app_info, IntentPickerResponse callback) { toolbar_->ShowIntentPickerBubble(app_info, callback); }
diff --git a/chrome/browser/ui/views/frame/browser_view.h b/chrome/browser/ui/views/frame/browser_view.h index 422c701..ce69278 100644 --- a/chrome/browser/ui/views/frame/browser_view.h +++ b/chrome/browser/ui/views/frame/browser_view.h
@@ -333,7 +333,7 @@ void ShowUpdateChromeDialog() override; #if defined(OS_CHROMEOS) void ShowIntentPickerBubble( - std::vector<IntentPickerBubbleView::AppInfo> app_info, + const std::vector<IntentPickerBubbleView::AppInfo>& app_info, IntentPickerResponse callback) override; void SetIntentPickerViewVisibility(bool visible) override; #endif // defined(OS_CHROMEOS)
diff --git a/chrome/browser/ui/views/intent_picker_bubble_view.cc b/chrome/browser/ui/views/intent_picker_bubble_view.cc index 2d34bcce..151353fd 100644 --- a/chrome/browser/ui/views/intent_picker_bubble_view.cc +++ b/chrome/browser/ui/views/intent_picker_bubble_view.cc
@@ -9,6 +9,7 @@ #include "base/logging.h" #include "base/strings/string_piece.h" #include "base/strings/utf_string_conversions.h" +#include "chrome/browser/chromeos/apps/intent_helper/apps_navigation_throttle.h" #include "chrome/browser/ui/browser_dialogs.h" #include "chrome/browser/ui/browser_finder.h" #include "chrome/browser/ui/views/frame/browser_view.h" @@ -35,7 +36,8 @@ // TODO(djacobo): Replace this limit to correctly reflect the UI mocks, which // now instead of limiting the results to 3.5 will allow whatever fits in 256pt. // Using |kMaxAppResults| as a measure of how many apps we want to show. -constexpr size_t kMaxAppResults = arc::ArcNavigationThrottle::kMaxAppResults; +constexpr size_t kMaxAppResults = + chromeos::AppsNavigationThrottle::kMaxAppResults; // Main components sizes constexpr int kTitlePadding = 16; constexpr int kRowHeight = 32; @@ -46,7 +48,7 @@ // UI position wrt the Top Container constexpr int kTopContainerMerge = 3; -constexpr char kInvalidPackageName[] = ""; +constexpr char kInvalidLaunchName[] = ""; bool IsKeyboardCodeArrow(ui::KeyboardCode key_code) { return key_code == ui::VKEY_UP || key_code == ui::VKEY_DOWN || @@ -69,11 +71,11 @@ public: IntentPickerLabelButton(views::ButtonListener* listener, gfx::Image* icon, - const std::string& package_name, - const std::string& activity_name) + const std::string& launch_name, + const std::string& display_name) : LabelButton(listener, - base::UTF8ToUTF16(base::StringPiece(activity_name))), - package_name_(package_name) { + base::UTF8ToUTF16(base::StringPiece(display_name))), + launch_name_(launch_name) { SetHorizontalAlignment(gfx::ALIGN_LEFT); SetMinSize(gfx::Size(kMaxWidth, kRowHeight)); SetInkDropMode(InkDropMode::ON); @@ -99,7 +101,7 @@ } private: - std::string package_name_; + std::string launch_name_; DISALLOW_COPY_AND_ASSIGN(IntentPickerLabelButton); }; @@ -122,7 +124,7 @@ } Browser* browser = chrome::FindBrowserWithWebContents(web_contents); if (!browser || !BrowserView::GetBrowserViewForBrowser(browser)) { - intent_picker_cb.Run(kInvalidPackageName, + intent_picker_cb.Run(kInvalidLaunchName, arc::ArcNavigationThrottle::CloseReason::ERROR); return nullptr; } @@ -184,7 +186,7 @@ bool IntentPickerBubbleView::Accept() { RunCallback( - app_info_[selected_app_tag_].package_name, + app_info_[selected_app_tag_].launch_name, remember_selection_checkbox_->checked() ? arc::ArcNavigationThrottle::CloseReason::ARC_APP_PREFERRED_PRESSED : arc::ArcNavigationThrottle::CloseReason::ARC_APP_PRESSED); @@ -203,7 +205,7 @@ bool IntentPickerBubbleView::Close() { // Whenever closing the bubble without pressing |Just once| or |Always| we // need to report back that the user didn't select anything. - RunCallback(kInvalidPackageName, + RunCallback(kInvalidLaunchName, arc::ArcNavigationThrottle::CloseReason::DIALOG_DEACTIVATED); return true; } @@ -225,12 +227,12 @@ size_t to_erase = app_info_.size(); for (AppInfo app_info : app_info_) { if (arc::ArcIntentHelperBridge::IsIntentHelperPackage( - app_info.package_name)) { + app_info.launch_name)) { to_erase = i; continue; } IntentPickerLabelButton* app_button = new IntentPickerLabelButton( - this, &app_info.icon, app_info.package_name, app_info.activity_name); + this, &app_info.icon, app_info.launch_name, app_info.display_name); app_button->set_tag(i); scrollable_view->AddChildViewAt(app_button, i++); } @@ -324,7 +326,7 @@ // If the widget gets closed without an app being selected we still need to use // the callback so the caller can Resume the navigation. void IntentPickerBubbleView::OnWidgetDestroying(views::Widget* widget) { - RunCallback(kInvalidPackageName, + RunCallback(kInvalidLaunchName, arc::ArcNavigationThrottle::CloseReason::DIALOG_DEACTIVATED); } @@ -374,7 +376,7 @@ } void IntentPickerBubbleView::RunCallback( - std::string package, + const std::string& launch_name, arc::ArcNavigationThrottle::CloseReason close_reason) { if (!intent_picker_cb_.is_null()) { // We must ensure |intent_picker_cb_| is only Run() once, this is why we @@ -382,7 +384,7 @@ // to null and still report back to whoever started the UI. auto callback = intent_picker_cb_; intent_picker_cb_.Reset(); - callback.Run(package, close_reason); + callback.Run(launch_name, close_reason); } intent_picker_bubble_ = nullptr;
diff --git a/chrome/browser/ui/views/intent_picker_bubble_view.h b/chrome/browser/ui/views/intent_picker_bubble_view.h index 099487de..80e999c8 100644 --- a/chrome/browser/ui/views/intent_picker_bubble_view.h +++ b/chrome/browser/ui/views/intent_picker_bubble_view.h
@@ -11,7 +11,7 @@ #include "base/callback.h" #include "base/macros.h" -#include "chrome/browser/chromeos/arc/intent_helper/arc_navigation_throttle.h" +#include "chrome/browser/chromeos/apps/intent_helper/apps_navigation_types.h" #include "chrome/browser/ui/browser_dialogs.h" #include "chrome/browser/ui/views/location_bar/location_bar_bubble_delegate_view.h" #include "content/public/browser/web_contents_observer.h" @@ -59,7 +59,7 @@ class IntentPickerBubbleView : public LocationBarBubbleDelegateView, public views::ButtonListener { public: - using AppInfo = arc::ArcNavigationThrottle::AppInfo; + using AppInfo = chromeos::IntentPickerAppInfo; ~IntentPickerBubbleView() override; static views::Widget* ShowBubble( @@ -124,7 +124,7 @@ // Retrieves the IntentPickerLabelButton* contained at position |index| from // the internal ScrollView. IntentPickerLabelButton* GetIntentPickerLabelButtonAt(size_t index); - void RunCallback(std::string package, + void RunCallback(const std::string& launch_name, arc::ArcNavigationThrottle::CloseReason close_reason); // Accessory for |scroll_view_|'s contents size.
diff --git a/chrome/browser/ui/views/intent_picker_bubble_view_unittest.cc b/chrome/browser/ui/views/intent_picker_bubble_view_unittest.cc index bd4269c..298ae21 100644 --- a/chrome/browser/ui/views/intent_picker_bubble_view_unittest.cc +++ b/chrome/browser/ui/views/intent_picker_bubble_view_unittest.cc
@@ -10,6 +10,7 @@ #include "base/bind_helpers.h" #include "base/callback.h" #include "base/macros.h" +#include "chrome/browser/chromeos/apps/intent_helper/apps_navigation_types.h" #include "chrome/browser/chromeos/arc/intent_helper/arc_navigation_throttle.h" #include "chrome/test/base/browser_with_test_window_test.h" #include "components/arc/intent_helper/arc_intent_helper_bridge.h" @@ -22,7 +23,7 @@ #include "ui/views/resources/grit/views_resources.h" #include "url/gurl.h" -using AppInfo = arc::ArcNavigationThrottle::AppInfo; +using AppInfo = chromeos::IntentPickerAppInfo; using content::WebContents; using content::OpenURLParams; using content::Referrer; @@ -41,12 +42,15 @@ protected: void CreateBubbleView(bool use_icons, bool disable_stay_in_chrome) { // Pushing a couple of fake apps just to check they are created on the UI. - app_info_.emplace_back(gfx::Image(), "package_1", "dank app 1"); - app_info_.emplace_back(gfx::Image(), "package_2", "dank_app_2"); + app_info_.emplace_back(chromeos::AppType::ARC, gfx::Image(), "package_1", + "dank app 1"); + app_info_.emplace_back(chromeos::AppType::ARC, gfx::Image(), "package_2", + "dank_app_2"); // Also adding the corresponding Chrome's package name on ARC, even if this // is given to the picker UI as input it should be ignored. app_info_.emplace_back( - gfx::Image(), arc::ArcIntentHelperBridge::kArcIntentHelperPackageName, + chromeos::AppType::ARC, gfx::Image(), + arc::ArcIntentHelperBridge::kArcIntentHelperPackageName, "legit_chrome"); if (use_icons) @@ -113,8 +117,7 @@ size_t size = app_info_.size(); size_t chrome_package_repetitions = 0; for (AppInfo app_info : app_info_) { - if (arc::ArcIntentHelperBridge::IsIntentHelperPackage( - app_info.package_name)) + if (arc::ArcIntentHelperBridge::IsIntentHelperPackage(app_info.launch_name)) ++chrome_package_repetitions; } @@ -169,7 +172,7 @@ size_t size = bubble_->GetScrollViewSize(); for (size_t i = 0; i < size; ++i) { EXPECT_FALSE(arc::ArcIntentHelperBridge::IsIntentHelperPackage( - bubble_->app_info_[i].package_name)); + bubble_->app_info_[i].launch_name)); } }
diff --git a/chrome/browser/ui/views/location_bar/intent_picker_view.cc b/chrome/browser/ui/views/location_bar/intent_picker_view.cc index 636e220..2d104c0 100644 --- a/chrome/browser/ui/views/location_bar/intent_picker_view.cc +++ b/chrome/browser/ui/views/location_bar/intent_picker_view.cc
@@ -4,6 +4,7 @@ #include "chrome/browser/ui/views/location_bar/intent_picker_view.h" +#include "chrome/browser/chromeos/apps/intent_helper/apps_navigation_throttle.h" #include "chrome/browser/chromeos/arc/intent_helper/intent_picker_controller.h" #include "chrome/browser/profiles/profile.h" #include "chrome/browser/ui/bookmarks/bookmark_utils.h" @@ -39,7 +40,7 @@ const GURL url = chrome::GetURLToBookmark( browser_->tab_strip_model()->GetActiveWebContents()); - arc::ArcNavigationThrottle::AsyncShowIntentPickerBubble(browser_, url); + chromeos::AppsNavigationThrottle::ShowIntentPickerBubble(browser_, url); } else { SetVisible(false); }
diff --git a/chrome/browser/ui/views/omnibox/omnibox_result_view.cc b/chrome/browser/ui/views/omnibox/omnibox_result_view.cc index 4e19cec..4290000d 100644 --- a/chrome/browser/ui/views/omnibox/omnibox_result_view.cc +++ b/chrome/browser/ui/views/omnibox/omnibox_result_view.cc
@@ -96,30 +96,64 @@ } // namespace //////////////////////////////////////////////////////////////////////////////// +// OmniboxImageView: + +class OmniboxImageView : public views::ImageView { + public: + bool CanProcessEventsWithinSubtree() const override { return false; } +}; + +//////////////////////////////////////////////////////////////////////////////// // OmniboxSeparatedLineView: class OmniboxSeparatedLineView : public views::View { public: - explicit OmniboxSeparatedLineView(OmniboxResultView* result_view); + explicit OmniboxSeparatedLineView(OmniboxResultView* result_view, + const gfx::FontList& font_list); ~OmniboxSeparatedLineView() override; + void OnMatchUpdate(const AutocompleteMatch& match); + void OnHighlightUpdate(const AutocompleteMatch& match); + protected: // views::View: void Layout() override; const char* GetClassName() const override; + // Weak pointers for easy reference. OmniboxResultView* result_view_; + views::ImageView* icon_view_; // An icon resembling a '>'. + views::ImageView* image_view_; // For rich suggestions. + OmniboxTextView* content_view_; + OmniboxTextView* description_view_; + OmniboxTextView* separator_view_; private: DISALLOW_COPY_AND_ASSIGN(OmniboxSeparatedLineView); }; OmniboxSeparatedLineView::OmniboxSeparatedLineView( - OmniboxResultView* result_view) - : result_view_(result_view) {} + OmniboxResultView* result_view, + const gfx::FontList& font_list) + : result_view_(result_view) { + AddChildView(icon_view_ = new OmniboxImageView()); + AddChildView(image_view_ = new OmniboxImageView()); + AddChildView(content_view_ = new OmniboxTextView(result_view, font_list)); + AddChildView(description_view_ = new OmniboxTextView(result_view, font_list)); + AddChildView(separator_view_ = new OmniboxTextView(result_view, font_list)); +} OmniboxSeparatedLineView::~OmniboxSeparatedLineView() = default; +void OmniboxSeparatedLineView::OnMatchUpdate(const AutocompleteMatch& match) { + // TODO(dschuyler): Fill this in. +} + +void OmniboxSeparatedLineView::OnHighlightUpdate( + const AutocompleteMatch& match) { + // TODO(dschuyler): Fill this in. +} + const char* OmniboxSeparatedLineView::GetClassName() const { return "OmniboxSeparatedLineView"; } @@ -133,7 +167,8 @@ class OmniboxSuggestionView : public OmniboxSeparatedLineView { public: - explicit OmniboxSuggestionView(OmniboxResultView* result_view); + explicit OmniboxSuggestionView(OmniboxResultView* result_view, + const gfx::FontList& font_list); ~OmniboxSuggestionView() override; private: @@ -144,8 +179,10 @@ DISALLOW_COPY_AND_ASSIGN(OmniboxSuggestionView); }; -OmniboxSuggestionView::OmniboxSuggestionView(OmniboxResultView* result_view) - : OmniboxSeparatedLineView::OmniboxSeparatedLineView(result_view) {} +OmniboxSuggestionView::OmniboxSuggestionView(OmniboxResultView* result_view, + const gfx::FontList& font_list) + : OmniboxSeparatedLineView::OmniboxSeparatedLineView(result_view, + font_list) {} OmniboxSuggestionView::~OmniboxSuggestionView() = default; @@ -158,14 +195,6 @@ } //////////////////////////////////////////////////////////////////////////////// -// OmniboxImageView: - -class OmniboxImageView : public views::ImageView { - public: - bool CanProcessEventsWithinSubtree() const override { return false; } -}; - -//////////////////////////////////////////////////////////////////////////////// // OmniboxResultView, public: OmniboxResultView::OmniboxResultView(OmniboxPopupContentsView* model, @@ -189,20 +218,14 @@ keyword_separator_view_(AddOmniboxTextView(font_list)) { CHECK_GE(model_index, 0); - AddChildView(suggestion_view_ = new OmniboxSuggestionView(this)); - AddChildView(keyword_view_ = new OmniboxSeparatedLineView(this)); + AddChildView(suggestion_view_ = new OmniboxSuggestionView(this, font_list)); + AddChildView(keyword_view_ = new OmniboxSeparatedLineView(this, font_list)); keyword_icon_view_->EnableCanvasFlippingForRTLUI(true); keyword_icon_view_->SetImage(gfx::CreateVectorIcon( omnibox::kKeywordSearchIcon, GetLayoutConstant(LOCATION_BAR_ICON_SIZE), GetColor(OmniboxPart::RESULTS_ICON))); keyword_icon_view_->SizeToPreferredSize(); - - if (OmniboxFieldTrial::InTabSwitchSuggestionWithButtonTrial()) { - suggestion_tab_switch_button_ = - std::make_unique<OmniboxTabSwitchButton>(this, GetTextHeight()); - suggestion_tab_switch_button_->set_owned_by_client(); - } } OmniboxResultView::~OmniboxResultView() {} @@ -215,19 +238,22 @@ match_ = match.GetMatchWithContentsAndDescriptionPossiblySwapped(); animation_->Reset(); is_hovered_ = false; + suggestion_view_->OnMatchUpdate(match_); + keyword_view_->OnMatchUpdate(match_); + suggestion_image_view_->SetVisible(false); // Until SetAnswerImage is called. keyword_icon_view_->SetVisible(match_.associated_keyword.get()); - if (suggestion_tab_switch_button_) { - if (match.type == AutocompleteMatchType::TAB_SEARCH && - !keyword_icon_view_->visible()) { - if (!suggestion_tab_switch_button_->parent()) { - AddChildView(suggestion_tab_switch_button_.get()); - } - } else if (suggestion_tab_switch_button_->parent()) { - RemoveChildView(suggestion_tab_switch_button_.get()); - } - } + if (OmniboxFieldTrial::InTabSwitchSuggestionWithButtonTrial() && + match.type == AutocompleteMatchType::TAB_SEARCH && + !keyword_icon_view_->visible()) { + suggestion_tab_switch_button_ = + std::make_unique<OmniboxTabSwitchButton>(this, GetTextHeight()); + suggestion_tab_switch_button_->set_owned_by_client(); + AddChildView(suggestion_tab_switch_button_.get()); + } else { + suggestion_tab_switch_button_.reset(); + } Invalidate(); if (GetWidget()) Layout(); @@ -250,6 +276,9 @@ SetBackground(CreateBackgroundWithColor(color)); } + suggestion_view_->OnHighlightUpdate(match_); + keyword_view_->OnHighlightUpdate(match_); + // Recreate the icons in case the color needs to change. // Note: if this is an extension icon or favicon then this can be done in // SetMatch() once (rather than repeatedly, as happens here). There may @@ -345,8 +374,7 @@ if (event.IsOnlyLeftMouseButton()) { if (!IsSelected()) model_->SetSelectedLine(model_index_); - if (suggestion_tab_switch_button_ && - suggestion_tab_switch_button_->parent()) { + if (suggestion_tab_switch_button_) { gfx::Point point_in_child_coords(event.location()); View::ConvertPointToTarget(this, suggestion_tab_switch_button_.get(), &point_in_child_coords); @@ -560,8 +588,7 @@ suggestion_icon_view_->SetBounds( start_x, icon_y, std::min(end_x, icon.Width()), icon.Height()); - if (suggestion_tab_switch_button_ && - match_.type == AutocompleteMatchType::TAB_SEARCH) { + if (suggestion_tab_switch_button_) { const gfx::Size ts_button_size = suggestion_tab_switch_button_->GetPreferredSize(); suggestion_tab_switch_button_->SetSize(ts_button_size);
diff --git a/chrome/browser/ui/views/omnibox/omnibox_tab_switch_button.cc b/chrome/browser/ui/views/omnibox/omnibox_tab_switch_button.cc index e59eafd8b..4975847 100644 --- a/chrome/browser/ui/views/omnibox/omnibox_tab_switch_button.cc +++ b/chrome/browser/ui/views/omnibox/omnibox_tab_switch_button.cc
@@ -56,7 +56,7 @@ } if (state() == STATE_PRESSED) SetPressed(); - LabelButton::StateChanged(old_state); + MdTextButton::StateChanged(old_state); } SkColor OmniboxTabSwitchButton::GetBackgroundColor() const {
diff --git a/chrome/browser/ui/webui/discards/discards_ui.cc b/chrome/browser/ui/webui/discards/discards_ui.cc index 5b52a26..d7b7532b1 100644 --- a/chrome/browser/ui/webui/discards/discards_ui.cc +++ b/chrome/browser/ui/webui/discards/discards_ui.cc
@@ -11,8 +11,9 @@ #include "chrome/browser/browser_process.h" #include "chrome/browser/profiles/profile.h" #include "chrome/browser/resource_coordinator/discard_reason.h" +#include "chrome/browser/resource_coordinator/lifecycle_unit.h" +#include "chrome/browser/resource_coordinator/tab_lifecycle_unit_external.h" #include "chrome/browser/resource_coordinator/tab_manager.h" -#include "chrome/browser/resource_coordinator/tab_stats.h" #include "chrome/browser/resource_coordinator/time.h" #include "chrome/browser/ui/webui/discards/discards.mojom.h" #include "chrome/common/webui_url_constants.h" @@ -44,31 +45,44 @@ void GetTabDiscardsInfo(GetTabDiscardsInfoCallback callback) override { resource_coordinator::TabManager* tab_manager = g_browser_process->GetTabManager(); - resource_coordinator::TabStatsList stats = tab_manager->GetTabStats(); + const resource_coordinator::LifecycleUnitVector lifecycle_units = + tab_manager->GetSortedLifecycleUnits(); std::vector<mojom::TabDiscardsInfoPtr> infos; - infos.reserve(stats.size()); + infos.reserve(lifecycle_units.size()); - base::TimeTicks now = resource_coordinator::NowTicks(); + const base::TimeTicks now = resource_coordinator::NowTicks(); - // Convert the TabStatsList to a vector of TabDiscardsInfos. + // Convert the LifecycleUnits to a vector of TabDiscardsInfos. size_t rank = 1; - for (const auto& tab : stats) { + for (auto* lifecycle_unit : lifecycle_units) { mojom::TabDiscardsInfoPtr info(mojom::TabDiscardsInfo::New()); - info->tab_url = tab.tab_url; + resource_coordinator::TabLifecycleUnitExternal* + tab_lifecycle_unit_external = + lifecycle_unit->AsTabLifecycleUnitExternal(); + content::WebContents* contents = + tab_lifecycle_unit_external->GetWebContents(); + + info->tab_url = contents->GetLastCommittedURL().spec(); // This can be empty for pages without a favicon. The WebUI takes care of // showing the chrome://favicon default in that case. - info->favicon_url = tab.favicon_url; - info->title = base::UTF16ToUTF8(tab.title); - info->is_media = tab.is_media; - info->is_discarded = tab.is_discarded; - info->discard_count = tab.discard_count; + info->favicon_url = lifecycle_unit->GetIconURL(); + info->title = base::UTF16ToUTF8(lifecycle_unit->GetTitle()); + info->is_media = tab_lifecycle_unit_external->IsMediaTab(); + info->is_discarded = tab_lifecycle_unit_external->IsDiscarded(); + info->discard_count = tab_lifecycle_unit_external->GetDiscardCount(); info->utility_rank = rank++; - auto elapsed = now - tab.last_active; + const base::TimeTicks last_focused_time = + lifecycle_unit->GetSortKey().last_focused_time; + const base::TimeDelta elapsed = + (last_focused_time == base::TimeTicks::Max()) + ? base::TimeDelta() + : (now - last_focused_time); info->last_active_seconds = static_cast<int32_t>(elapsed.InSeconds()); - info->is_auto_discardable = tab.is_auto_discardable; - info->id = tab.id; + info->is_auto_discardable = + tab_lifecycle_unit_external->IsAutoDiscardable(); + info->id = lifecycle_unit->GetID(); infos.push_back(std::move(info)); }
diff --git a/chrome/browser/ui/webui/settings/protocol_handlers_handler.cc b/chrome/browser/ui/webui/settings/protocol_handlers_handler.cc index 57d7ceca..1f486d9 100644 --- a/chrome/browser/ui/webui/settings/protocol_handlers_handler.cc +++ b/chrome/browser/ui/webui/settings/protocol_handlers_handler.cc
@@ -77,6 +77,8 @@ for (handler = handlers.begin(); handler != handlers.end(); ++handler) { std::unique_ptr<base::DictionaryValue> handler_value( new base::DictionaryValue()); + handler_value->SetString("protocol_display_name", + handler->GetProtocolDisplayName()); handler_value->SetString("protocol", handler->protocol()); handler_value->SetString("spec", handler->url().spec()); handler_value->SetString("host", handler->url().host()); @@ -89,6 +91,8 @@ const std::string& protocol, base::DictionaryValue* handlers_value) { ProtocolHandlerRegistry* registry = GetProtocolHandlerRegistry(); + handlers_value->SetString("protocol_display_name", + ProtocolHandler::GetProtocolDisplayName(protocol)); handlers_value->SetString("protocol", protocol); auto handlers_list = std::make_unique<base::ListValue>();
diff --git a/chrome/browser/vr/elements/omnibox_formatting.cc b/chrome/browser/vr/elements/omnibox_formatting.cc index c82920c..77884f1 100644 --- a/chrome/browser/vr/elements/omnibox_formatting.cc +++ b/chrome/browser/vr/elements/omnibox_formatting.cc
@@ -63,8 +63,7 @@ gfx::RenderText* render_text, int min_path_pixels) { // In situations where there is no host, do not attempt to position the TLD. - bool allow_offset = - gurl.IsStandard() && !gurl.SchemeIsFile() && parsed.host.is_nonempty(); + bool allow_offset = gurl.IsStandard() && parsed.host.is_nonempty(); int total_width = render_text->GetContentWidth(); ElisionParameters result;
diff --git a/chrome/browser/vr/elements/omnibox_formatting_unittest.cc b/chrome/browser/vr/elements/omnibox_formatting_unittest.cc index 3ce5e46..4a0d384 100644 --- a/chrome/browser/vr/elements/omnibox_formatting_unittest.cc +++ b/chrome/browser/vr/elements/omnibox_formatting_unittest.cc
@@ -129,9 +129,12 @@ // A long domain and path should see fading at both ends. {"http://aaaaaaaaaaaaaaaaaaaaaaaa.abc.com/aaaaaaaaaaaaaaaaaaaaaaaaaaaa", "abc.com/aaa", kHasOffset, true, true}, - // A file URL should always fade to the right. - {"file://filer/aaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaa", "file://filer/aaa", + // A file URL with no hostname should fade to the right. + {"file:///path/aaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaa", "file://path/aaa", kNoOffset, false, true}, + // A file URL with a hostname should treat the hostname like https. + {"file://very-long-file-hostname/aaaaaaaaaaaaaa", "file://hostname/aaa", + kHasOffset, true, true}, {"data:text/plain;charset=UTF-8;aaaaaaaaaaaaaaaaaaa", "data:text/plain", kNoOffset, false, true}, };
diff --git a/chrome/browser/vr/testapp/vr_test_context.cc b/chrome/browser/vr/testapp/vr_test_context.cc index b1a9021..e32a502 100644 --- a/chrome/browser/vr/testapp/vr_test_context.cc +++ b/chrome/browser/vr/testapp/vr_test_context.cc
@@ -636,10 +636,10 @@ // Do not show URL {GURL(), security_state::SecurityLevel::HTTP_SHOW_WARNING, &toolbar::kHttpIcon, base::string16(), false, false}, - {GURL("file:///C:/path/filename"), + {GURL("file://very-very-very-long-file-hostname/path/path/path/path"), security_state::SecurityLevel::HTTP_SHOW_WARNING, &toolbar::kHttpIcon, base::string16(), true, false}, - {GURL("file:///C:/path/path/path/path/path/path/path/path"), + {GURL("file:///path/path/path/path/path/path/path/path/path"), security_state::SecurityLevel::HTTP_SHOW_WARNING, &toolbar::kHttpIcon, base::string16(), true, false}, // Elision-related cases.
diff --git a/chrome/common/BUILD.gn b/chrome/common/BUILD.gn index b6bfb46ec..5b88838d 100644 --- a/chrome/common/BUILD.gn +++ b/chrome/common/BUILD.gn
@@ -7,6 +7,7 @@ import("//chrome/common/features.gni") import("//chrome/process_version_rc_template.gni") # For branding_file_path. import("//components/nacl/features.gni") +import("//components/offline_pages/buildflags/features.gni") import("//device/vr/buildflags/buildflags.gni") import("//extensions/buildflags/buildflags.gni") import("//media/media_options.gni") @@ -682,6 +683,10 @@ sources += [ "conflicts/module_event_sink_win.mojom" ] } + if (enable_offline_pages) { + sources += [ "mhtml_page_notifier.mojom" ] + } + public_deps = [ "//components/content_settings/core/common:mojo_bindings", "//content/public/common:interfaces",
diff --git a/chrome/common/custom_handlers/protocol_handler.cc b/chrome/common/custom_handlers/protocol_handler.cc index 686b70ec..f284c1b 100644 --- a/chrome/common/custom_handlers/protocol_handler.cc +++ b/chrome/common/custom_handlers/protocol_handler.cc
@@ -7,8 +7,9 @@ #include "base/memory/ptr_util.h" #include "base/strings/string_util.h" #include "base/strings/utf_string_conversions.h" +#include "chrome/grit/generated_resources.h" #include "net/base/escape.h" - +#include "ui/base/l10n/l10n_util.h" ProtocolHandler::ProtocolHandler(const std::string& protocol, const GURL& url) @@ -67,6 +68,19 @@ return d; } +base::string16 ProtocolHandler::GetProtocolDisplayName( + const std::string& protocol) { + if (protocol == "mailto") + return l10n_util::GetStringUTF16(IDS_REGISTER_PROTOCOL_HANDLER_MAILTO_NAME); + if (protocol == "webcal") + return l10n_util::GetStringUTF16(IDS_REGISTER_PROTOCOL_HANDLER_WEBCAL_NAME); + return base::UTF8ToUTF16(protocol); +} + +base::string16 ProtocolHandler::GetProtocolDisplayName() const { + return GetProtocolDisplayName(protocol_); +} + #if !defined(NDEBUG) std::string ProtocolHandler::ToString() const { return "{ protocol=" + protocol_ +
diff --git a/chrome/common/custom_handlers/protocol_handler.h b/chrome/common/custom_handlers/protocol_handler.h index 69c195c..ea9a0c06 100644 --- a/chrome/common/custom_handlers/protocol_handler.h +++ b/chrome/common/custom_handlers/protocol_handler.h
@@ -45,6 +45,14 @@ // Encodes this protocol handler as a DictionaryValue. std::unique_ptr<base::DictionaryValue> Encode() const; + // Returns a friendly name for |protocol| if one is available, otherwise + // this function returns |protocol|. + static base::string16 GetProtocolDisplayName(const std::string& protocol); + + // Returns a friendly name for |this.protocol_| if one is available, otherwise + // this function returns |this.protocol_|. + base::string16 GetProtocolDisplayName() const; + const std::string& protocol() const { return protocol_; } const GURL& url() const { return url_;}
diff --git a/chrome/common/extensions/api/developer_private.idl b/chrome/common/extensions/api/developer_private.idl index 173c4348..0e56d217 100644 --- a/chrome/common/extensions/api/developer_private.idl +++ b/chrome/common/extensions/api/developer_private.idl
@@ -562,6 +562,10 @@ static void loadUnpacked(optional LoadUnpackedOptions options, optional LoadErrorCallback callback); + // Installs the file that was dragged and dropped onto the associated + // page. + static void installDroppedFile(optional VoidCallback callback); + // Notifies the browser that a user began a drag in order to install an // extension. static void notifyDragInstallInProgress();
diff --git a/chrome/common/mhtml_page_notifier.mojom b/chrome/common/mhtml_page_notifier.mojom new file mode 100644 index 0000000..c0436e01 --- /dev/null +++ b/chrome/common/mhtml_page_notifier.mojom
@@ -0,0 +1,15 @@ +// Copyright 2018 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. + +module offline_pages.mojom; + +import "mojo/public/mojom/base/time.mojom"; +import "url/mojom/url.mojom"; + +// This interface is implemented in the browser process by OfflinePageTabHelper, +// and is notified when the renderer installs an archive (MHTML) document into +// the main frame. +interface MhtmlPageNotifier { + NotifyIsMhtmlPage(url.mojom.Url main_frame_url, mojo_base.mojom.Time date); +};
diff --git a/chrome/common/offline_pages/BUILD.gn b/chrome/common/offline_pages/BUILD.gn new file mode 100644 index 0000000..1760cda --- /dev/null +++ b/chrome/common/offline_pages/BUILD.gn
@@ -0,0 +1,16 @@ +# Copyright 2018 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("//mojo/public/tools/bindings/mojom.gni") + +mojom("mojo_bindings") { + sources = [ + "mhtml_page_notifier.mojom", + ] + + public_deps = [ + "//mojo/public/mojom/base", + "//url/mojom:url_mojom_gurl", + ] +}
diff --git a/chrome/common/offline_pages/OWNERS b/chrome/common/offline_pages/OWNERS new file mode 100644 index 0000000..08850f4 --- /dev/null +++ b/chrome/common/offline_pages/OWNERS
@@ -0,0 +1,2 @@ +per-file *.mojom=set noparent +per-file *.mojom=file://ipc/SECURITY_OWNERS
diff --git a/chrome/renderer/BUILD.gn b/chrome/renderer/BUILD.gn index 838bf82..6db84a3 100644 --- a/chrome/renderer/BUILD.gn +++ b/chrome/renderer/BUILD.gn
@@ -5,6 +5,7 @@ import("//build/config/features.gni") import("//chrome/common/features.gni") import("//components/nacl/features.gni") +import("//components/offline_pages/buildflags/features.gni") import("//components/spellcheck/spellcheck_build_features.gni") import("//extensions/buildflags/buildflags.gni") import("//media/media_options.gni")
diff --git a/chrome/renderer/DEPS b/chrome/renderer/DEPS index 91082f2f..735ff01 100644 --- a/chrome/renderer/DEPS +++ b/chrome/renderer/DEPS
@@ -20,6 +20,7 @@ "+components/nacl/renderer", "+components/network_hints/renderer", "+components/network_session_configurator/common", + "+components/offline_pages/buildflags", "+components/password_manager/content/renderer", "+components/password_manager/core/common", "+components/pdf/renderer",
diff --git a/chrome/renderer/chrome_render_frame_observer.cc b/chrome/renderer/chrome_render_frame_observer.cc index 6338e83..073be72 100644 --- a/chrome/renderer/chrome_render_frame_observer.cc +++ b/chrome/renderer/chrome_render_frame_observer.cc
@@ -26,6 +26,7 @@ #include "chrome/renderer/prerender/prerender_helper.h" #include "chrome/renderer/web_apps.h" #include "components/crash/core/common/crash_key.h" +#include "components/offline_pages/buildflags/buildflags.h" #include "components/translate/content/renderer/translate_helper.h" #include "content/public/common/bindings_policy.h" #include "content/public/renderer/render_frame.h" @@ -61,6 +62,10 @@ #include "chrome/renderer/safe_browsing/phishing_classifier_delegate.h" #endif +#if BUILDFLAG(ENABLE_OFFLINE_PAGES) +#include "chrome/common/mhtml_page_notifier.mojom.h" +#endif + #if BUILDFLAG(ENABLE_PRINTING) #include "components/printing/common/print_messages.h" #include "components/printing/renderer/print_render_frame_helper.h" @@ -339,6 +344,31 @@ } } +void ChromeRenderFrameObserver::DidCreateNewDocument() { +#if BUILDFLAG(ENABLE_OFFLINE_PAGES) + DCHECK(render_frame()); + if (!render_frame()->IsMainFrame()) + return; + + DCHECK(render_frame()->GetWebFrame()); + blink::WebDocumentLoader* doc_loader = + render_frame()->GetWebFrame()->GetDocumentLoader(); + DCHECK(doc_loader); + if (!doc_loader->IsArchive()) + return; + + // Connect to Mojo service on browser to notify it of the page's archive + // properties. + offline_pages::mojom::MhtmlPageNotifierAssociatedPtr mhtml_notifier; + render_frame()->GetRemoteAssociatedInterfaces()->GetInterface( + &mhtml_notifier); + DCHECK(mhtml_notifier); + blink::WebArchiveInfo info = doc_loader->GetArchiveInfo(); + + mhtml_notifier->NotifyIsMhtmlPage(info.url, info.date); +#endif +} + void ChromeRenderFrameObserver::DidStartProvisionalLoad( WebDocumentLoader* document_loader) { // Let translate_helper do any preparatory work for loading a URL.
diff --git a/chrome/renderer/chrome_render_frame_observer.h b/chrome/renderer/chrome_render_frame_observer.h index 648e3d1..25666cc 100644 --- a/chrome/renderer/chrome_render_frame_observer.h +++ b/chrome/renderer/chrome_render_frame_observer.h
@@ -47,6 +47,7 @@ bool OnMessageReceived(const IPC::Message& message) override; void DidStartProvisionalLoad(blink::WebDocumentLoader* loader) override; void DidFinishLoad() override; + void DidCreateNewDocument() override; void DidCommitProvisionalLoad(bool is_new_navigation, bool is_same_document_navigation) override; void DidClearWindowObject() override;
diff --git a/chrome/test/BUILD.gn b/chrome/test/BUILD.gn index 6f0e8229..0ed02c5 100644 --- a/chrome/test/BUILD.gn +++ b/chrome/test/BUILD.gn
@@ -693,7 +693,6 @@ "../browser/repost_form_warning_browsertest.cc", "../browser/resource_coordinator/resource_coordinator_render_process_probe_browsertest.cc", "../browser/resource_coordinator/tab_activity_watcher_browsertest.cc", - "../browser/resource_coordinator/tab_lifecycle_observer_browsertest.cc", "../browser/resource_coordinator/tab_manager_browsertest.cc", "../browser/safe_browsing/chrome_cleaner/reporter_runner_browsertest_win.cc", "../browser/safe_browsing/test_safe_browsing_database_helper.cc",
diff --git a/chrome/test/base/chrome_unit_test_suite.cc b/chrome/test/base/chrome_unit_test_suite.cc index f772598..1585856c 100644 --- a/chrome/test/base/chrome_unit_test_suite.cc +++ b/chrome/test/base/chrome_unit_test_suite.cc
@@ -10,6 +10,7 @@ #include "base/path_service.h" #include "base/process/process_handle.h" #include "build/build_config.h" +#include "chrome/browser/browser_process.h" #include "chrome/browser/chrome_content_browser_client.h" #include "chrome/browser/profiles/profile_shortcut_manager.h" #include "chrome/browser/ui/webui/chrome_web_ui_controller_factory.h" @@ -65,6 +66,10 @@ content::SetUtilityClientForTesting(utility_content_client_.get()); TestingBrowserProcess::CreateInstance(); + + // Force TabManager creation before the first tab is created. In production, + // that happens in ChromeBrowserMainParts::PreBrowserStart(). + g_browser_process->GetTabManager(); } void OnTestEnd(const testing::TestInfo& test_info) override {
diff --git a/chrome/test/base/test_browser_window.h b/chrome/test/base/test_browser_window.h index 9bb12aa..76ead40b 100644 --- a/chrome/test/base/test_browser_window.h +++ b/chrome/test/base/test_browser_window.h
@@ -16,7 +16,7 @@ #include "chrome/common/buildflags.h" #if defined(OS_CHROMEOS) -#include "chrome/browser/chromeos/arc/intent_helper/arc_navigation_throttle.h" +#include "chrome/browser/chromeos/apps/intent_helper/apps_navigation_types.h" #endif // defined(OS_CHROMEOS) class LocationBarTesting; @@ -99,7 +99,7 @@ void ShowBookmarkBubble(const GURL& url, bool already_bookmarked) override {} #if defined(OS_CHROMEOS) void ShowIntentPickerBubble( - std::vector<arc::ArcNavigationThrottle::AppInfo> app_info, + const std::vector<chromeos::IntentPickerAppInfo>& app_info, IntentPickerResponse callback) override {} void SetIntentPickerViewVisibility(bool visible) override {} #endif // defined(OS_CHROMEOS)
diff --git a/chrome/test/base/testing_browser_process.cc b/chrome/test/base/testing_browser_process.cc index b098fb4c..f8fb04f 100644 --- a/chrome/test/base/testing_browser_process.cc +++ b/chrome/test/base/testing_browser_process.cc
@@ -17,6 +17,7 @@ #include "chrome/browser/policy/chrome_browser_policy_connector.h" #include "chrome/browser/printing/print_job_manager.h" #include "chrome/browser/profiles/profile_manager.h" +#include "chrome/browser/resource_coordinator/tab_lifecycle_unit_source.h" #include "chrome/browser/resource_coordinator/tab_manager.h" #include "chrome/browser/safe_browsing/safe_browsing_service.h" #include "chrome/common/buildflags.h" @@ -420,8 +421,12 @@ resource_coordinator::TabManager* TestingBrowserProcess::GetTabManager() { #if defined(OS_WIN) || defined(OS_MACOSX) || defined(OS_LINUX) - if (!tab_manager_.get()) - tab_manager_.reset(new resource_coordinator::TabManager()); + if (!tab_manager_) { + tab_manager_ = std::make_unique<resource_coordinator::TabManager>(); + tab_lifecycle_unit_source_ = + std::make_unique<resource_coordinator::TabLifecycleUnitSource>(); + tab_lifecycle_unit_source_->AddObserver(tab_manager_.get()); + } return tab_manager_.get(); #else return nullptr;
diff --git a/chrome/test/base/testing_browser_process.h b/chrome/test/base/testing_browser_process.h index c3a4bf4..1799a236 100644 --- a/chrome/test/base/testing_browser_process.h +++ b/chrome/test/base/testing_browser_process.h
@@ -47,6 +47,10 @@ class PolicyService; } +namespace resource_coordinator { +class TabLifecycleUnitSource; +} + class TestingBrowserProcess : public BrowserProcess { public: // Initializes |g_browser_process| with a new TestingBrowserProcess. @@ -194,6 +198,8 @@ // GetTabManager() is invoked on supported platforms. #if defined(OS_WIN) || defined(OS_MACOSX) || defined(OS_LINUX) std::unique_ptr<resource_coordinator::TabManager> tab_manager_; + std::unique_ptr<resource_coordinator::TabLifecycleUnitSource> + tab_lifecycle_unit_source_; #endif // The following objects are not owned by TestingBrowserProcess:
diff --git a/chrome/test/data/extensions/simple_empty.zip b/chrome/test/data/extensions/simple_empty.zip new file mode 100644 index 0000000..6ba97330 --- /dev/null +++ b/chrome/test/data/extensions/simple_empty.zip Binary files differ
diff --git a/chrome/test/data/offline_pages/.gitattributes b/chrome/test/data/offline_pages/.gitattributes new file mode 100644 index 0000000..06cf9fa --- /dev/null +++ b/chrome/test/data/offline_pages/.gitattributes
@@ -0,0 +1,9 @@ +# While the overall structure of MHTML always uses CRLF, the MHTML parts +# that use binary encoding will preserve their original line endings +# (i.e. LF in case of the file below). We tell git to treat these files +# as "binary" to preserve this weird mixture of CRLF and LF line endings. +*.mhtml binary + +# Test.mhtml is quoted-printable so all the line endings can be crlf. +test.mhtml text eol=crlf +
diff --git a/chrome/test/data/offline_pages/hello.mhtml b/chrome/test/data/offline_pages/hello.mhtml index 1ac5223..646c5a0 100644 --- a/chrome/test/data/offline_pages/hello.mhtml +++ b/chrome/test/data/offline_pages/hello.mhtml
@@ -1,17 +1,20 @@ -From: <Saved by UnMHT> -Subject: Hello -Date: Mon, Nov 21 2011 10:59:06 GMT-0800 -MIME-Version: 1.0 -Content-Type: multipart/related; - boundary="----=_NextPart_000_0000_0324C3DC.A3C79392"; - type="text/html" - -------=_NextPart_000_0000_0324C3DC.A3C79392 -Content-Type: text/html; charset="UTF-8" -Content-Transfer-Encoding: quoted-printable -Content-Location: http://www.example.com - +From: <Saved by UnMHT> +Subject: Hello +Date: Mon, Nov 21 2011 10:59:06 GMT-0800 +MIME-Version: 1.0 +Content-Type: multipart/related; + boundary="----=_NextPart_000_0000_0324C3DC.A3C79392"; + type="text/html" + + +------=_NextPart_000_0000_0324C3DC.A3C79392 +Content-Type: text/html; charset="UTF-8" +Content-Transfer-Encoding: binary +Content-Location: http://www.example.com + <html> +<body> Hello, World! +</body> </html> -------=_NextPart_000_0000_0324C3DC.A3C79392-- +------=_NextPart_000_0000_0324C3DC.A3C79392--
diff --git a/chrome/test/data/printing/bug_767343.emf b/chrome/test/data/printing/bug_767343.emf new file mode 100644 index 0000000..1681f56 --- /dev/null +++ b/chrome/test/data/printing/bug_767343.emf Binary files differ
diff --git a/chrome/test/data/printing/bug_767343.pdf b/chrome/test/data/printing/bug_767343.pdf new file mode 100644 index 0000000..0f722509 --- /dev/null +++ b/chrome/test/data/printing/bug_767343.pdf Binary files differ
diff --git a/chrome/test/data/webui/cr_elements/cr_dialog_test.js b/chrome/test/data/webui/cr_elements/cr_dialog_test.js index ab33a4c0..08c31d9 100644 --- a/chrome/test/data/webui/cr_elements/cr_dialog_test.js +++ b/chrome/test/data/webui/cr_elements/cr_dialog_test.js
@@ -13,12 +13,12 @@ test('focuses title on show', function() { document.body.innerHTML = ` - <dialog is="cr-dialog"> + <cr-dialog> <div slot="title">title</div> <div slot="body"><button>button</button></div> - </dialog>`; + </cr-dialog>`; - const dialog = document.body.querySelector('dialog'); + const dialog = document.body.querySelector('cr-dialog'); const button = document.body.querySelector('button'); assertNotEquals(dialog, document.activeElement); @@ -32,15 +32,15 @@ test('enter keys should trigger action buttons once', function() { document.body.innerHTML = ` - <dialog is="cr-dialog"> + <cr-dialog> <div slot="title">title</div> <div slot="body"> <button class="action-button">button</button> <button id="other-button">other button</button> </div> - </dialog>`; + </cr-dialog>`; - const dialog = document.body.querySelector('dialog'); + const dialog = document.body.querySelector('cr-dialog'); const actionButton = document.body.querySelector('.action-button'); dialog.showModal(); @@ -69,7 +69,7 @@ test('enter keys find the first non-hidden non-disabled button', function() { document.body.innerHTML = ` - <dialog is="cr-dialog"> + <cr-dialog> <div slot="title">title</div> <div slot="body"> <button id="hidden" class="action-button" hidden>hidden</button> @@ -77,9 +77,9 @@ <button class="action-button" disabled hidden>disabled hidden</button> <button id="active" class="action-button">active</button> </div> - </dialog>`; + </cr-dialog>`; - const dialog = document.body.querySelector('dialog'); + const dialog = document.body.querySelector('cr-dialog'); const hiddenButton = document.body.querySelector('#hidden'); const actionButton = document.body.querySelector('#active'); dialog.showModal(); @@ -99,16 +99,16 @@ test('enter keys from paper-inputs (only) are processed', function() { document.body.innerHTML = ` - <dialog is="cr-dialog"> + <cr-dialog> <div slot="title">title</div> <div slot="body"> <paper-input></paper-input> <foobar></foobar> <button class="action-button">active</button> </div> - </dialog>`; + </cr-dialog>`; - const dialog = document.body.querySelector('dialog'); + const dialog = document.body.querySelector('cr-dialog'); const inputElement = document.body.querySelector('paper-input'); const otherElement = document.body.querySelector('foobar'); @@ -132,12 +132,12 @@ test('focuses [autofocus] instead of title when present', function() { document.body.innerHTML = ` - <dialog is="cr-dialog"> + <cr-dialog> <div slot="title">title</div> <div slot="body"><button autofocus>button</button></div> - </dialog>`; + </cr-dialog>`; - const dialog = document.body.querySelector('dialog'); + const dialog = document.body.querySelector('cr-dialog'); const button = document.body.querySelector('button'); assertNotEquals(dialog, document.activeElement); @@ -153,12 +153,12 @@ // dialog has been opened. test('body scrollable border not added before modal shown', function(done) { document.body.innerHTML = ` - <dialog is="cr-dialog"> + <cr-dialog> <div slot="title">title</div> <div slot="body">body</div> - </dialog>`; + </cr-dialog>`; - const dialog = document.body.querySelector('dialog'); + const dialog = document.body.querySelector('cr-dialog'); assertFalse(dialog.open); const bodyContainer = dialog.$$('.body-container'); assertTrue(!!bodyContainer); @@ -174,14 +174,14 @@ test('dialog body scrollable border when appropriate', function(done) { document.body.innerHTML = ` - <dialog is="cr-dialog"> + <cr-dialog> <div slot="title">title</div> <div slot="body"> <div style="height: 100px">tall content</div> </div> - </dialog>`; + </cr-dialog>`; - const dialog = document.body.querySelector('dialog'); + const dialog = document.body.querySelector('cr-dialog'); const bodyContainer = dialog.$$('.body-container'); assertTrue(!!bodyContainer); @@ -225,11 +225,11 @@ test('dialog cannot be cancelled when `no-cancel` is set', function() { document.body.innerHTML = ` - <dialog is="cr-dialog" no-cancel> + <cr-dialog no-cancel> <div slot="title">title</div> - </dialog>`; + </cr-dialog>`; - const dialog = document.body.querySelector('dialog'); + const dialog = document.body.querySelector('cr-dialog'); dialog.showModal(); // The paper-icon-button-light is the hidden element which is the
diff --git a/chrome/test/data/webui/extensions/extension_load_error_test.js b/chrome/test/data/webui/extensions/extension_load_error_test.js index edb3ad8..32d3b984 100644 --- a/chrome/test/data/webui/extensions/extension_load_error_test.js +++ b/chrome/test/data/webui/extensions/extension_load_error_test.js
@@ -38,7 +38,7 @@ }); test(assert(TestNames.RetryError), function() { - var dialogElement = loadError.$$('dialog'); + var dialogElement = loadError.$$('cr-dialog').getNative(); expectFalse(extension_test_util.isElementVisible(dialogElement)); loadError.show(); expectTrue(extension_test_util.isElementVisible(dialogElement)); @@ -54,7 +54,7 @@ }); test(assert(TestNames.RetrySuccess), function() { - var dialogElement = loadError.$$('dialog'); + var dialogElement = loadError.$$('cr-dialog').getNative(); expectFalse(extension_test_util.isElementVisible(dialogElement)); loadError.show(); expectTrue(extension_test_util.isElementVisible(dialogElement));
diff --git a/chrome/test/data/webui/extensions/extension_options_dialog_test.js b/chrome/test/data/webui/extensions/extension_options_dialog_test.js index 6433c686..1e81760 100644 --- a/chrome/test/data/webui/extensions/extension_options_dialog_test.js +++ b/chrome/test/data/webui/extensions/extension_options_dialog_test.js
@@ -31,7 +31,7 @@ }); function isDialogVisible() { - var dialogElement = optionsDialog.$$('dialog'); + var dialogElement = optionsDialog.$.dialog.getNative(); var rect = dialogElement.getBoundingClientRect(); return rect.width * rect.height > 0; }
diff --git a/chrome/test/data/webui/extensions/extension_pack_dialog_test.js b/chrome/test/data/webui/extensions/extension_pack_dialog_test.js index b2da000..b5cf222 100644 --- a/chrome/test/data/webui/extensions/extension_pack_dialog_test.js +++ b/chrome/test/data/webui/extensions/extension_pack_dialog_test.js
@@ -65,7 +65,7 @@ }); test(assert(TestNames.Interaction), function() { - var dialogElement = packDialog.$$('dialog'); + var dialogElement = packDialog.$$('cr-dialog').getNative(); expectFalse(extension_test_util.isElementVisible(dialogElement)); packDialog.show(); @@ -104,7 +104,7 @@ }); test(assert(TestNames.PackSuccess), function() { - var dialogElement = packDialog.$$('dialog'); + var dialogElement = packDialog.$$('cr-dialog').getNative(); var packDialogAlert; var alertElement; @@ -128,7 +128,7 @@ }) .then(() => { packDialogAlert = packDialog.$$('extensions-pack-dialog-alert'); - alertElement = packDialogAlert.$.dialog; + alertElement = packDialogAlert.$.dialog.getNative(); expectTrue(extension_test_util.isElementVisible(alertElement)); expectTrue(extension_test_util.isElementVisible(dialogElement)); expectTrue(!!packDialogAlert.$$('.action-button')); @@ -144,7 +144,7 @@ }); test(assert(TestNames.PackError), function() { - var dialogElement = packDialog.$$('dialog'); + var dialogElement = packDialog.$$('cr-dialog').getNative(); var packDialogAlert; var alertElement; @@ -166,7 +166,7 @@ // Make sure new alert and the appropriate buttons are visible. packDialogAlert = packDialog.$$('extensions-pack-dialog-alert'); - alertElement = packDialogAlert.$.dialog; + alertElement = packDialogAlert.$.dialog.getNative(); expectTrue(extension_test_util.isElementVisible(alertElement)); expectTrue(extension_test_util.isElementVisible(dialogElement)); expectTrue(!!packDialogAlert.$$('.action-button')); @@ -181,7 +181,7 @@ }); test(assert(TestNames.PackWarning), function() { - var dialogElement = packDialog.$$('dialog'); + var dialogElement = packDialog.$$('cr-dialog').getNative(); var packDialogAlert; var alertElement; @@ -207,7 +207,7 @@ // Make sure new alert and the appropriate buttons are visible. packDialogAlert = packDialog.$$('extensions-pack-dialog-alert'); - alertElement = packDialogAlert.$.dialog; + alertElement = packDialogAlert.$.dialog.getNative(); expectTrue(extension_test_util.isElementVisible(alertElement)); expectTrue(extension_test_util.isElementVisible(dialogElement)); expectFalse(packDialogAlert.$$('.cancel-button').hidden);
diff --git a/chrome/test/data/webui/settings/protocol_handlers_tests.js b/chrome/test/data/webui/settings/protocol_handlers_tests.js index 864b937..0f69f2e 100644 --- a/chrome/test/data/webui/settings/protocol_handlers_tests.js +++ b/chrome/test/data/webui/settings/protocol_handlers_tests.js
@@ -19,6 +19,7 @@ handlers: [{ host: 'www.google.com', protocol: 'mailto', + protocol_name: 'email', spec: 'http://www.google.com/%s', is_default: true }], @@ -29,12 +30,14 @@ { host: 'www.google1.com', protocol: 'webcal', + protocol_name: 'web calendar', spec: 'http://www.google1.com/%s', is_default: true }, { host: 'www.google2.com', protocol: 'webcal', + protocol_name: 'web calendar', spec: 'http://www.google2.com/%s', is_default: false } @@ -50,6 +53,7 @@ const ignoredProtocols = [{ host: 'www.google.com', protocol: 'web+ignored', + protocol_name: 'web+ignored', spec: 'https://www.google.com/search?q=ignored+%s', is_default: false }];
diff --git a/chrome/test/data/webui/settings/quick_unlock_authenticate_browsertest_chromeos.js b/chrome/test/data/webui/settings/quick_unlock_authenticate_browsertest_chromeos.js index 634e7e23..eecd1e5c 100644 --- a/chrome/test/data/webui/settings/quick_unlock_authenticate_browsertest_chromeos.js +++ b/chrome/test/data/webui/settings/quick_unlock_authenticate_browsertest_chromeos.js
@@ -21,6 +21,11 @@ } element = element.parentElement; + + // cr-dialog itself will always be 0x0. It's the inner native <dialog> + // that has actual dimensions. + if (element && element.tagName == 'CR-DIALOG') + element = element.getNative(); } return true;
diff --git a/chromecast/browser/cast_content_browser_client.cc b/chromecast/browser/cast_content_browser_client.cc index 3efe61a4..cb55a80 100644 --- a/chromecast/browser/cast_content_browser_client.cc +++ b/chromecast/browser/cast_content_browser_client.cc
@@ -166,46 +166,6 @@ url_request_context_factory_.release()); } -void CastContentBrowserClient::AppendExtraCommandLineSwitches( - base::CommandLine* command_line) { -#if defined(USE_AURA) - std::string process_type = - command_line->GetSwitchValueNative(switches::kProcessType); - if (process_type == switches::kGpuProcess) { - static const char* const kForwardSwitches[] = { - switches::kCastInitialScreenHeight, switches::kCastInitialScreenWidth, - switches::kVSyncInterval, - }; - base::CommandLine* browser_command_line = - base::CommandLine::ForCurrentProcess(); - command_line->CopySwitchesFrom(*browser_command_line, kForwardSwitches, - arraysize(kForwardSwitches)); - - auto display = display::Screen::GetScreen()->GetPrimaryDisplay(); - gfx::Size res = display.GetSizeInPixel(); - if (display.rotation() == display::Display::ROTATE_90 || - display.rotation() == display::Display::ROTATE_270) { - res = gfx::Size(res.height(), res.width()); - } - - if (!command_line->HasSwitch(switches::kCastInitialScreenWidth)) { - command_line->AppendSwitchASCII(switches::kCastInitialScreenWidth, - base::IntToString(res.width())); - } - if (!command_line->HasSwitch(switches::kCastInitialScreenHeight)) { - command_line->AppendSwitchASCII(switches::kCastInitialScreenHeight, - base::IntToString(res.height())); - } - - if (base::FeatureList::IsEnabled(kSingleBuffer)) { - command_line->AppendSwitchASCII(switches::kGraphicsBufferCount, "1"); - } else if (base::FeatureList::IsEnabled(chromecast::kTripleBuffer720)) { - command_line->AppendSwitchASCII(switches::kGraphicsBufferCount, "3"); - } - } -#endif // defined(USE_AURA) -} - std::unique_ptr<CastService> CastContentBrowserClient::CreateCastService( content::BrowserContext* browser_context, PrefService* pref_service, @@ -447,18 +407,45 @@ browser_command_line->GetSwitchValueASCII( switches::kAudioOutputChannels)); } - } - + } else if (process_type == switches::kGpuProcess) { #if defined(OS_LINUX) // Necessary for accelerated 2d canvas. By default on Linux, Chromium assumes // GLES2 contexts can be lost to a power-save mode, which breaks GPU canvas // apps. - if (process_type == switches::kGpuProcess) { command_line->AppendSwitch(switches::kGpuNoContextLost); - } #endif - AppendExtraCommandLineSwitches(command_line); +#if defined(USE_AURA) + static const char* const kForwardSwitches[] = { + switches::kCastInitialScreenHeight, switches::kCastInitialScreenWidth, + switches::kVSyncInterval, + }; + command_line->CopySwitchesFrom(*browser_command_line, kForwardSwitches, + arraysize(kForwardSwitches)); + + auto display = display::Screen::GetScreen()->GetPrimaryDisplay(); + gfx::Size res = display.GetSizeInPixel(); + if (display.rotation() == display::Display::ROTATE_90 || + display.rotation() == display::Display::ROTATE_270) { + res = gfx::Size(res.height(), res.width()); + } + + if (!command_line->HasSwitch(switches::kCastInitialScreenWidth)) { + command_line->AppendSwitchASCII(switches::kCastInitialScreenWidth, + base::IntToString(res.width())); + } + if (!command_line->HasSwitch(switches::kCastInitialScreenHeight)) { + command_line->AppendSwitchASCII(switches::kCastInitialScreenHeight, + base::IntToString(res.height())); + } + + if (base::FeatureList::IsEnabled(kSingleBuffer)) { + command_line->AppendSwitchASCII(switches::kGraphicsBufferCount, "1"); + } else if (base::FeatureList::IsEnabled(chromecast::kTripleBuffer720)) { + command_line->AppendSwitchASCII(switches::kGraphicsBufferCount, "3"); + } +#endif // defined(USE_AURA) + } } void CastContentBrowserClient::OverrideWebkitPrefs(
diff --git a/chromecast/browser/cast_content_browser_client.h b/chromecast/browser/cast_content_browser_client.h index 4f5bdbc8..390d4a75 100644 --- a/chromecast/browser/cast_content_browser_client.h +++ b/chromecast/browser/cast_content_browser_client.h
@@ -64,9 +64,6 @@ ~CastContentBrowserClient() override; - // Appends extra command line arguments before launching a new process. - virtual void AppendExtraCommandLineSwitches(base::CommandLine* command_line); - // Creates and returns the CastService instance for the current process. // Note: |request_context_getter| might be different than the main request // getter accessible via CastBrowserProcess.
diff --git a/components/content_view/java/src/org/chromium/components/content_view/ContentView.java b/components/content_view/java/src/org/chromium/components/content_view/ContentView.java index 920cfcf..7c5c713 100644 --- a/components/content_view/java/src/org/chromium/components/content_view/ContentView.java +++ b/components/content_view/java/src/org/chromium/components/content_view/ContentView.java
@@ -303,9 +303,11 @@ @Override public boolean awakenScrollBars(int startDelay, boolean invalidate) { - ContentViewCore cvc = getContentViewCore(); - assert cvc != null; - return cvc.awakenScrollBars(startDelay, invalidate); + // For the default implementation of ContentView which draws the scrollBars on the native + // side, calling this function may get us into a bad state where we keep drawing the + // scrollBars, so disable it by always returning false. + if (getScrollBarStyle() == View.SCROLLBARS_INSIDE_OVERLAY) return false; + return super.awakenScrollBars(startDelay, invalidate); } @Override @@ -358,11 +360,6 @@ super.onConfigurationChanged(newConfig); } - @Override - public boolean super_awakenScrollBars(int startDelay, boolean invalidate) { - return super.awakenScrollBars(startDelay, invalidate); - } - /////////////////////////////////////////////////////////////////////////////////////////////// // End Implementation of ContentViewCore.InternalAccessDelegate // ///////////////////////////////////////////////////////////////////////////////////////////////
diff --git a/components/cryptauth/BUILD.gn b/components/cryptauth/BUILD.gn index 8b9e7dd..3dbc56b 100644 --- a/components/cryptauth/BUILD.gn +++ b/components/cryptauth/BUILD.gn
@@ -58,6 +58,7 @@ "device_to_device_secure_context.h", "foreground_eid_generator.cc", "foreground_eid_generator.h", + "gcm_device_info_provider.h", "local_device_data_provider.cc", "local_device_data_provider.h", "pref_names.cc", @@ -139,6 +140,8 @@ "fake_cryptauth_service.h", "fake_device_capability_manager.cc", "fake_device_capability_manager.h", + "fake_gcm_device_info_provider.cc", + "fake_gcm_device_info_provider.h", "fake_remote_device_provider.cc", "fake_remote_device_provider.h", "fake_secure_channel.cc",
diff --git a/components/cryptauth/fake_gcm_device_info_provider.cc b/components/cryptauth/fake_gcm_device_info_provider.cc new file mode 100644 index 0000000..63fcc2d --- /dev/null +++ b/components/cryptauth/fake_gcm_device_info_provider.cc
@@ -0,0 +1,19 @@ +// Copyright 2018 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 "components/cryptauth/fake_gcm_device_info_provider.h" + +namespace cryptauth { + +FakeGcmDeviceInfoProvider::FakeGcmDeviceInfoProvider( + const GcmDeviceInfo& gcm_device_info) + : gcm_device_info_(gcm_device_info) {} + +FakeGcmDeviceInfoProvider::~FakeGcmDeviceInfoProvider() = default; + +const GcmDeviceInfo& FakeGcmDeviceInfoProvider::GetGcmDeviceInfo() const { + return gcm_device_info_; +} + +} // namespace cryptauth
diff --git a/components/cryptauth/fake_gcm_device_info_provider.h b/components/cryptauth/fake_gcm_device_info_provider.h new file mode 100644 index 0000000..324532ad --- /dev/null +++ b/components/cryptauth/fake_gcm_device_info_provider.h
@@ -0,0 +1,31 @@ +// Copyright 2018 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 COMPONENTS_CRYPTAUTH_FAKE_GCM_DEVICE_INFO_PROVIDER_H_ +#define COMPONENTS_CRYPTAUTH_FAKE_GCM_DEVICE_INFO_PROVIDER_H_ + +#include "base/macros.h" +#include "components/cryptauth/gcm_device_info_provider.h" +#include "components/cryptauth/proto/cryptauth_api.pb.h" + +namespace cryptauth { + +// Test GcmDeviceInfoProvider implementation. +class FakeGcmDeviceInfoProvider : public GcmDeviceInfoProvider { + public: + FakeGcmDeviceInfoProvider(const GcmDeviceInfo& gcm_device_info); + ~FakeGcmDeviceInfoProvider() override; + + // GcmDeviceInfoProvider: + const GcmDeviceInfo& GetGcmDeviceInfo() const override; + + private: + const GcmDeviceInfo gcm_device_info_; + + DISALLOW_COPY_AND_ASSIGN(FakeGcmDeviceInfoProvider); +}; + +} // namespace cryptauth + +#endif // COMPONENTS_CRYPTAUTH_FAKE_GCM_DEVICE_INFO_PROVIDER_H_
diff --git a/components/cryptauth/gcm_device_info_provider.h b/components/cryptauth/gcm_device_info_provider.h new file mode 100644 index 0000000..f508a62 --- /dev/null +++ b/components/cryptauth/gcm_device_info_provider.h
@@ -0,0 +1,29 @@ +// Copyright 2018 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 COMPONENTS_CRYPTAUTH_GCM_DEVICE_INFO_PROVIDER_H_ +#define COMPONENTS_CRYPTAUTH_GCM_DEVICE_INFO_PROVIDER_H_ + +#include "base/macros.h" +#include "components/cryptauth/proto/cryptauth_api.pb.h" + +namespace cryptauth { + +// Provides the GcmDeviceInfo object associated with the current device. +// GcmDeviceInfo describes properties of this Chromebook and is not expected to +// change except when the OS version is updated. +class GcmDeviceInfoProvider { + public: + GcmDeviceInfoProvider() = default; + virtual ~GcmDeviceInfoProvider() = default; + + virtual const GcmDeviceInfo& GetGcmDeviceInfo() const = 0; + + private: + DISALLOW_COPY_AND_ASSIGN(GcmDeviceInfoProvider); +}; + +} // namespace cryptauth + +#endif // COMPONENTS_CRYPTAUTH_GCM_DEVICE_INFO_PROVIDER_H_
diff --git a/components/data_reduction_proxy/content/browser/content_lofi_decider.cc b/components/data_reduction_proxy/content/browser/content_lofi_decider.cc index e2df7c2..511767beb 100644 --- a/components/data_reduction_proxy/content/browser/content_lofi_decider.cc +++ b/components/data_reduction_proxy/content/browser/content_lofi_decider.cc
@@ -59,15 +59,6 @@ return updated_state; } -bool ContentLoFiDecider::IsUsingLoFi(const net::URLRequest& request) const { - const content::ResourceRequestInfo* request_info = - content::ResourceRequestInfo::ForRequest(&request); - if (!request_info) - return false; - - return (request_info->GetPreviewsState() & content::SERVER_LOFI_ON); -} - void ContentLoFiDecider::MaybeSetAcceptTransformHeader( const net::URLRequest& request, net::HttpRequestHeaders* headers) const {
diff --git a/components/data_reduction_proxy/content/browser/content_lofi_decider.h b/components/data_reduction_proxy/content/browser/content_lofi_decider.h index edc55ba..db0d3a2 100644 --- a/components/data_reduction_proxy/content/browser/content_lofi_decider.h +++ b/components/data_reduction_proxy/content/browser/content_lofi_decider.h
@@ -44,7 +44,6 @@ content::PreviewsState initial_state); // LoFiDecider implementation: - bool IsUsingLoFi(const net::URLRequest& request) const override; void MaybeSetAcceptTransformHeader( const net::URLRequest& request, net::HttpRequestHeaders* headers) const override;
diff --git a/components/data_reduction_proxy/core/browser/data_reduction_proxy_network_delegate.cc b/components/data_reduction_proxy/core/browser/data_reduction_proxy_network_delegate.cc index 19b6230..ed775857 100644 --- a/components/data_reduction_proxy/core/browser/data_reduction_proxy_network_delegate.cc +++ b/components/data_reduction_proxy/core/browser/data_reduction_proxy_network_delegate.cc
@@ -112,14 +112,11 @@ } } -// |lofi_low_header_added| is set to true iff Lo-Fi request header -// can be added to the Chrome proxy header. |received_content_length| is -// the number of prefilter bytes received. |original_content_length| is the -// length of resource if accessed directly without data saver proxy. -// |freshness_lifetime| specifies how long the resource will -// be fresh for. -void RecordContentLengthHistograms(bool lofi_low_header_added, - bool is_https, +// |received_content_length| is the number of prefilter bytes received. +// |original_content_length| is the length of resource if accessed directly +// without data saver proxy. |freshness_lifetime| specifies how long the +// resource will be fresh for. +void RecordContentLengthHistograms(bool is_https, bool is_video, int64_t received_content_length, int64_t original_content_length, @@ -134,19 +131,6 @@ original_content_length); UMA_HISTOGRAM_COUNTS_1M("Net.HttpContentLengthDifferenceWithValidOCL", original_content_length - received_content_length); - - // Populate Lo-Fi content length histograms. - if (lofi_low_header_added) { - UMA_HISTOGRAM_COUNTS_1M("Net.HttpContentLengthWithValidOCL.LoFiOn", - received_content_length); - UMA_HISTOGRAM_COUNTS_1M( - "Net.HttpOriginalContentLengthWithValidOCL.LoFiOn", - original_content_length); - UMA_HISTOGRAM_COUNTS_1M( - "Net.HttpContentLengthDifferenceWithValidOCL.LoFiOn", - original_content_length - received_content_length); - } - } else { // Presume the original content length is the same as the received content // length. @@ -640,11 +624,6 @@ } RecordContentLengthHistograms( - // |data_reduction_proxy_io_data_| can be NULL for Webview. - data_reduction_proxy_io_data_ && - data_reduction_proxy_io_data_->IsEnabled() && - data_reduction_proxy_io_data_->lofi_decider() && - data_reduction_proxy_io_data_->lofi_decider()->IsUsingLoFi(request), is_https, is_video, request.received_response_content_length(), original_content_length, freshness_lifetime, request_type);
diff --git a/components/data_reduction_proxy/core/browser/data_reduction_proxy_network_delegate_unittest.cc b/components/data_reduction_proxy/core/browser/data_reduction_proxy_network_delegate_unittest.cc index 2a32471..fb1b4f38 100644 --- a/components/data_reduction_proxy/core/browser/data_reduction_proxy_network_delegate_unittest.cc +++ b/components/data_reduction_proxy/core/browser/data_reduction_proxy_network_delegate_unittest.cc
@@ -127,14 +127,6 @@ const char kOriginalVideoSecureOtherHistogramName[] = "Net.HttpOriginalContentLengthV2.Https.Other.Video"; -// Lo-Fi histograms. -const char kReceivedValidOCLLoFiOnHistogramName[] = - "Net.HttpContentLengthWithValidOCL.LoFiOn"; -const char kOriginalValidOCLLoFiOnHistogramName[] = - "Net.HttpOriginalContentLengthWithValidOCL.LoFiOn"; -const char kDifferenceValidOCLLoFiOnHistogramName[] = - "Net.HttpContentLengthDifferenceWithValidOCL.LoFiOn"; - const char kReceivedHistogramName[] = "Net.HttpContentLength"; const char kReceivedInsecureDirectHistogramName[] = "Net.HttpContentLengthV2.Http.Direct"; @@ -213,10 +205,6 @@ ignore_is_using_data_reduction_proxy_check_(false) {} ~TestLoFiDecider() override {} - bool IsUsingLoFi(const net::URLRequest& request) const override { - return should_request_lofi_resource_; - } - void SetIsUsingLoFi(bool should_request_lofi_resource) { should_request_lofi_resource_ = should_request_lofi_resource; } @@ -1285,67 +1273,6 @@ kResponseContentLength, 1); histogram_tester.ExpectUniqueSample(kCacheable24HoursHistogramName, kResponseContentLength, 1); - - // Check Lo-Fi histograms. - const struct { - bool lofi_enabled; - int expected_count; - } tests[] = { - { - // Lo-Fi disabled. - false, 0, - }, - { - // Lo-Fi enabled so should populate Lo-Fi content length histogram. - true, 1, - }, - }; - - for (size_t i = 0; i < arraysize(tests); ++i) { - - base::test::ScopedFeatureList scoped_feature_list; - if (tests[i].lofi_enabled) { - scoped_feature_list.InitAndEnableFeature( - features::kDataReductionProxyDecidesTransform); - } else { - scoped_feature_list.InitAndDisableFeature( - features::kDataReductionProxyDecidesTransform); - } - - // Needed as a parameter, but functionality is not tested. - previews::TestPreviewsDecider test_previews_decider(true); - lofi_decider()->SetIsUsingLoFi(config()->ShouldAcceptServerPreview( - *fake_request.get(), test_previews_decider)); - - fake_request = (FetchURLRequest(GURL(kTestURL), nullptr, response_headers, - kResponseContentLength, 0)); - fake_request->SetLoadFlags(fake_request->load_flags() | - net::LOAD_MAIN_FRAME_DEPRECATED); - - // Histograms are accumulative, so get the sum of all the tests so far. - int expected_count = 0; - for (size_t j = 0; j <= i; ++j) - expected_count += tests[j].expected_count; - - if (expected_count == 0) { - histogram_tester.ExpectTotalCount(kReceivedValidOCLLoFiOnHistogramName, - expected_count); - histogram_tester.ExpectTotalCount(kOriginalValidOCLLoFiOnHistogramName, - expected_count); - histogram_tester.ExpectTotalCount(kDifferenceValidOCLLoFiOnHistogramName, - expected_count); - } else { - histogram_tester.ExpectUniqueSample(kReceivedValidOCLLoFiOnHistogramName, - kResponseContentLength, - expected_count); - histogram_tester.ExpectUniqueSample(kOriginalValidOCLLoFiOnHistogramName, - kOriginalContentLength, - expected_count); - histogram_tester.ExpectUniqueSample( - kDifferenceValidOCLLoFiOnHistogramName, - kOriginalContentLength - kResponseContentLength, expected_count); - } - } } TEST_F(DataReductionProxyNetworkDelegateTest, NetVideoHistograms) {
diff --git a/components/data_reduction_proxy/core/browser/warmup_url_fetcher.cc b/components/data_reduction_proxy/core/browser/warmup_url_fetcher.cc index a5832ab6..28464c9 100644 --- a/components/data_reduction_proxy/core/browser/warmup_url_fetcher.cc +++ b/components/data_reduction_proxy/core/browser/warmup_url_fetcher.cc
@@ -171,7 +171,7 @@ if (!GetFieldTrialParamByFeatureAsBool( features::kDataReductionProxyRobustConnection, - "warmup_fetch_callback_enabled", false)) { + params::GetWarmupCallbackParamName(), false)) { CleanupAfterFetch(); return; } @@ -257,7 +257,7 @@ if (!GetFieldTrialParamByFeatureAsBool( features::kDataReductionProxyRobustConnection, - "warmup_fetch_callback_enabled", false)) { + params::GetWarmupCallbackParamName(), false)) { // Running the callback is not enabled. CleanupAfterFetch(); return;
diff --git a/components/data_reduction_proxy/core/browser/warmup_url_fetcher_unittest.cc b/components/data_reduction_proxy/core/browser/warmup_url_fetcher_unittest.cc index 494665a..daa46742 100644 --- a/components/data_reduction_proxy/core/browser/warmup_url_fetcher_unittest.cc +++ b/components/data_reduction_proxy/core/browser/warmup_url_fetcher_unittest.cc
@@ -18,6 +18,7 @@ #include "base/threading/platform_thread.h" #include "components/data_reduction_proxy/core/browser/data_reduction_proxy_util.h" #include "components/data_reduction_proxy/core/common/data_reduction_proxy_features.h" +#include "components/data_reduction_proxy/core/common/data_reduction_proxy_params.h" #include "net/base/proxy_server.h" #include "net/http/http_status_code.h" #include "net/nqe/network_quality_estimator_test_util.h" @@ -52,7 +53,7 @@ static void InitExperiment( base::test::ScopedFeatureList* scoped_feature_list) { std::map<std::string, std::string> params; - params["warmup_fetch_callback_enabled"] = "true"; + params[params::GetWarmupCallbackParamName()] = "true"; scoped_feature_list->InitAndEnableFeatureWithParameters( features::kDataReductionProxyRobustConnection, params); }
diff --git a/components/data_reduction_proxy/core/common/data_reduction_proxy_headers.cc b/components/data_reduction_proxy/core/common/data_reduction_proxy_headers.cc index ef2d3122..03bd90a 100644 --- a/components/data_reduction_proxy/core/common/data_reduction_proxy_headers.cc +++ b/components/data_reduction_proxy/core/common/data_reduction_proxy_headers.cc
@@ -11,12 +11,14 @@ #include <utility> #include <vector> +#include "base/metrics/field_trial_params.h" #include "base/rand_util.h" #include "base/strings/string_number_conversions.h" #include "base/strings/string_split.h" #include "base/strings/string_util.h" #include "base/time/time.h" #include "components/data_reduction_proxy/core/common/data_reduction_proxy_event_creator.h" +#include "components/data_reduction_proxy/core/common/data_reduction_proxy_features.h" #include "components/data_reduction_proxy/core/common/data_reduction_proxy_params.h" #include "net/http/http_response_headers.h" #include "net/http/http_status_code.h" @@ -423,7 +425,17 @@ !headers.HasHeader("Proxy-Authenticate")) { return BYPASS_EVENT_TYPE_MALFORMED_407; } - if (!has_via_header && (headers.response_code() != net::HTTP_NOT_MODIFIED)) { + + bool disable_bypass_on_missing_via_header = + GetFieldTrialParamByFeatureAsBool( + features::kDataReductionProxyRobustConnection, + params::GetWarmupCallbackParamName(), false) && + GetFieldTrialParamByFeatureAsBool( + features::kDataReductionProxyRobustConnection, + params::GetMissingViaBypassParamName(), false); + + if (!has_via_header && !disable_bypass_on_missing_via_header && + (headers.response_code() != net::HTTP_NOT_MODIFIED)) { // A Via header might not be present in a 304. Since the goal of a 304 // response is to minimize information transfer, a sender in general // should not generate representation metadata other than Cache-Control,
diff --git a/components/data_reduction_proxy/core/common/data_reduction_proxy_headers_unittest.cc b/components/data_reduction_proxy/core/common/data_reduction_proxy_headers_unittest.cc index 2fac76306..71031e8cff 100644 --- a/components/data_reduction_proxy/core/common/data_reduction_proxy_headers_unittest.cc +++ b/components/data_reduction_proxy/core/common/data_reduction_proxy_headers_unittest.cc
@@ -18,6 +18,7 @@ #include "components/data_reduction_proxy/core/common/data_reduction_proxy_event_storage_delegate_test_utils.h" #include "components/data_reduction_proxy/core/common/data_reduction_proxy_features.h" #include "components/data_reduction_proxy/core/common/data_reduction_proxy_headers_test_utils.h" +#include "components/data_reduction_proxy/core/common/data_reduction_proxy_params.h" #include "net/http/http_response_headers.h" #include "net/proxy_resolution/proxy_resolution_service.h" #include "testing/gtest/include/gtest/gtest.h" @@ -665,6 +666,56 @@ } } +TEST_F(DataReductionProxyHeadersTest, BypassMissingViaIfExperiment) { + const struct { + const char* headers; + std::map<std::string, std::string> feature_parameters; + DataReductionProxyBypassType expected_result; + } tests[] = { + { + "HTTP/1.1 200 OK\n", + { + {params::GetWarmupCallbackParamName(), "true"}, + {params::GetMissingViaBypassParamName(), "true"}, + }, + BYPASS_EVENT_TYPE_MAX, + }, + { + "HTTP/1.1 200 OK\n", + { + {params::GetWarmupCallbackParamName(), "true"}, + {params::GetMissingViaBypassParamName(), "false"}, + }, + BYPASS_EVENT_TYPE_MISSING_VIA_HEADER_OTHER, + }, + { + "HTTP/1.1 200 OK\n", + { + {params::GetWarmupCallbackParamName(), "false"}, + {params::GetMissingViaBypassParamName(), "false"}, + }, + BYPASS_EVENT_TYPE_MISSING_VIA_HEADER_OTHER, + }, + }; + for (auto test : tests) { + std::string headers(test.headers); + HeadersToRaw(&headers); + scoped_refptr<net::HttpResponseHeaders> parsed( + new net::HttpResponseHeaders(headers)); + DataReductionProxyInfo proxy_info; + + base::test::ScopedFeatureList scoped_feature_list; + scoped_feature_list.InitAndEnableFeatureWithParameters( + features::kDataReductionProxyRobustConnection, test.feature_parameters); + + EXPECT_EQ(test.expected_result, + GetDataReductionProxyBypassType(std::vector<GURL>(), *parsed, + &proxy_info)); + if (test.expected_result != BYPASS_EVENT_TYPE_MAX) + EXPECT_TRUE(proxy_info.mark_proxies_as_bad); + } +} + TEST_F(DataReductionProxyHeadersTest, GetDataReductionProxyBypassEventType) { const struct { const char* headers;
diff --git a/components/data_reduction_proxy/core/common/data_reduction_proxy_params.cc b/components/data_reduction_proxy/core/common/data_reduction_proxy_params.cc index 0232a102..be112f8 100644 --- a/components/data_reduction_proxy/core/common/data_reduction_proxy_params.cc +++ b/components/data_reduction_proxy/core/common/data_reduction_proxy_params.cc
@@ -53,6 +53,9 @@ // LitePage black list version. const char kLitePageBlackListVersion[] = "lite-page-blacklist-version"; +const char kWarmupFetchCallbackEnabledParam[] = "warmup_fetch_callback_enabled"; +const char kMissingViaBypassDisabledParam[] = "bypass_missing_via_disabled"; + bool IsIncludedInFieldTrial(const std::string& name) { return base::StartsWith(base::FieldTrialList::FindFullName(name), kEnabled, base::CompareCase::SENSITIVE); @@ -115,6 +118,14 @@ return kLoFiFlagFieldTrial; } +const char* GetWarmupCallbackParamName() { + return kWarmupFetchCallbackEnabledParam; +} + +const char* GetMissingViaBypassParamName() { + return kMissingViaBypassDisabledParam; +} + bool IsIncludedInServerExperimentsFieldTrial() { return !base::CommandLine::ForCurrentProcess()->HasSwitch( data_reduction_proxy::switches::
diff --git a/components/data_reduction_proxy/core/common/data_reduction_proxy_params.h b/components/data_reduction_proxy/core/common/data_reduction_proxy_params.h index b77b74e..e177fd34 100644 --- a/components/data_reduction_proxy/core/common/data_reduction_proxy_params.h +++ b/components/data_reduction_proxy/core/common/data_reduction_proxy_params.h
@@ -133,6 +133,12 @@ // Returns the warmup URL. GURL GetWarmupURL(); +// Returns the experiment parameter name to enable the warmup fetch callback. +const char* GetWarmupCallbackParamName(); + +// Returns the experiment parameter name to disable missing via header bypasses. +const char* GetMissingViaBypassParamName(); + } // namespace params // Contains information about a given proxy server. |proxies_for_http| contains
diff --git a/components/data_reduction_proxy/core/common/lofi_decider.h b/components/data_reduction_proxy/core/common/lofi_decider.h index 57f90a8..a898c0b 100644 --- a/components/data_reduction_proxy/core/common/lofi_decider.h +++ b/components/data_reduction_proxy/core/common/lofi_decider.h
@@ -26,10 +26,6 @@ public: virtual ~LoFiDecider() {} - // Returns true when Lo-Fi Previews are on for the given |request|. This means - // the Lo-Fi header should be added to the given request. - virtual bool IsUsingLoFi(const net::URLRequest& request) const = 0; - // Adds a previews-specific directive to the Chrome-Proxy-Accept-Transform // header if needed. virtual void MaybeSetAcceptTransformHeader(
diff --git a/components/download/downloader/in_progress/BUILD.gn b/components/download/downloader/in_progress/BUILD.gn index 30abd02..bd728e0 100644 --- a/components/download/downloader/in_progress/BUILD.gn +++ b/components/download/downloader/in_progress/BUILD.gn
@@ -7,7 +7,7 @@ import("//build/config/android/rules.gni") } -static_library("in_progress") { +source_set("in_progress") { sources = [ "download_entry.cc", "download_entry.h", @@ -21,7 +21,6 @@ deps = [ "//base", "//components/download/downloader/in_progress/proto", - "//components/download/public/common:public", "//net", "//services/metrics/public/cpp:metrics_cpp", ]
diff --git a/components/download/internal/common/BUILD.gn b/components/download/internal/common/BUILD.gn index a48fcdf..2e0d0b2 100644 --- a/components/download/internal/common/BUILD.gn +++ b/components/download/internal/common/BUILD.gn
@@ -18,6 +18,8 @@ "download_file_impl.cc", "download_interrupt_reasons_impl.cc", "download_interrupt_reasons_utils.cc", + "download_item_impl.cc", + "download_item_impl_delegate.cc", "download_job.cc", "download_job_factory.cc", "download_job_impl.cc", @@ -42,6 +44,7 @@ deps = [ "//base", + "//components/download/downloader/in_progress", "//components/download/public/common:interfaces", "//components/download/quarantine", "//mojo/public/c/system",
diff --git a/components/download/internal/common/DEPS b/components/download/internal/common/DEPS index 9d81a1a..65c7005 100644 --- a/components/download/internal/common/DEPS +++ b/components/download/internal/common/DEPS
@@ -1,5 +1,6 @@ include_rules = [ "-content", + "+components/download/downloader/in_progress", "+components/download/public/common", "+components/download/quarantine", "+components/ukm/test_ukm_recorder.h",
diff --git a/content/browser/download/download_item_impl.cc b/components/download/internal/common/download_item_impl.cc similarity index 81% rename from content/browser/download/download_item_impl.cc rename to components/download/internal/common/download_item_impl.cc index 89584422..5ea5be9f 100644 --- a/content/browser/download/download_item_impl.cc +++ b/components/download/internal/common/download_item_impl.cc
@@ -5,11 +5,11 @@ // File method ordering: Methods in this file are in the same order as // in download_item_impl.h, with the following exception: The public // interface Start is placed in chronological order with the other -// (private) routines that together define a download::DownloadItem's state +// (private) routines that together define a DownloadItem's state // transitions as the download progresses. See "Download progression // cascade" later in this file. -// A regular download::DownloadItem (created for a download in this session of +// A regular DownloadItem (created for a download in this session of // the browser) normally goes through the following states: // * Created (when download starts) // * Destination filename determined @@ -21,7 +21,7 @@ // * Download file is renamed to its final name, and possibly // auto-opened. -#include "content/browser/download/download_item_impl.h" +#include "components/download/public/common/download_item_impl.h" #include <memory> #include <utility> @@ -39,10 +39,11 @@ #include "base/strings/stringprintf.h" #include "base/strings/utf_string_conversions.h" #include "base/task_runner_util.h" -#include "components/download/downloader/in_progress/in_progress_cache.h" +#include "components/download/downloader/in_progress/download_entry.h" #include "components/download/public/common/download_danger_type.h" #include "components/download/public/common/download_file.h" #include "components/download/public/common/download_interrupt_reasons.h" +#include "components/download/public/common/download_item_impl_delegate.h" #include "components/download/public/common/download_job_factory.h" #include "components/download/public/common/download_job_impl.h" #include "components/download/public/common/download_stats.h" @@ -50,20 +51,16 @@ #include "components/download/public/common/download_ukm_helper.h" #include "components/download/public/common/download_url_parameters.h" #include "components/download/public/common/parallel_download_utils.h" -#include "content/browser/download/download_item_impl_delegate.h" -#include "content/browser/download/download_request_handle.h" -#include "content/browser/download/download_utils.h" -#include "content/public/browser/download_item_utils.h" #include "net/http/http_response_headers.h" #include "net/http/http_status_code.h" #include "net/traffic_annotation/network_traffic_annotation.h" -namespace content { +namespace download { namespace { bool DeleteDownloadedFile(const base::FilePath& path) { - DCHECK(download::GetDownloadTaskRunner()->RunsTasksInCurrentSequence()); + DCHECK(GetDownloadTaskRunner()->RunsTasksInCurrentSequence()); // Make sure we only delete files. if (base::DirectoryExists(path)) @@ -71,10 +68,9 @@ return base::DeleteFile(path, false); } -void DeleteDownloadedFileDone( - base::WeakPtr<DownloadItemImpl> item, - const base::Callback<void(bool)>& callback, - bool success) { +void DeleteDownloadedFileDone(base::WeakPtr<DownloadItemImpl> item, + const base::Callback<void(bool)>& callback, + bool success) { if (success && item.get()) item->OnDownloadedFileRemoved(); callback.Run(success); @@ -83,16 +79,15 @@ // Wrapper around DownloadFile::Detach and DownloadFile::Cancel that // takes ownership of the DownloadFile and hence implicitly destroys it // at the end of the function. -base::FilePath DownloadFileDetach( - std::unique_ptr<download::DownloadFile> download_file) { - DCHECK(download::GetDownloadTaskRunner()->RunsTasksInCurrentSequence()); +base::FilePath DownloadFileDetach(std::unique_ptr<DownloadFile> download_file) { + DCHECK(GetDownloadTaskRunner()->RunsTasksInCurrentSequence()); base::FilePath full_path = download_file->FullPath(); download_file->Detach(); return full_path; } -base::FilePath MakeCopyOfDownloadFile(download::DownloadFile* download_file) { - DCHECK(download::GetDownloadTaskRunner()->RunsTasksInCurrentSequence()); +base::FilePath MakeCopyOfDownloadFile(DownloadFile* download_file) { + DCHECK(GetDownloadTaskRunner()->RunsTasksInCurrentSequence()); base::FilePath temp_file_path; if (!base::CreateTemporaryFile(&temp_file_path)) return base::FilePath(); @@ -105,26 +100,26 @@ return temp_file_path; } -void DownloadFileCancel(std::unique_ptr<download::DownloadFile> download_file) { - DCHECK(download::GetDownloadTaskRunner()->RunsTasksInCurrentSequence()); +void DownloadFileCancel(std::unique_ptr<DownloadFile> download_file) { + DCHECK(GetDownloadTaskRunner()->RunsTasksInCurrentSequence()); download_file->Cancel(); } // Most of the cancellation pathways behave the same whether the cancellation // was initiated by ther user (CANCELED) or initiated due to browser context // shutdown (SHUTDOWN). -bool IsCancellation(download::DownloadInterruptReason reason) { - return reason == download::DOWNLOAD_INTERRUPT_REASON_USER_SHUTDOWN || - reason == download::DOWNLOAD_INTERRUPT_REASON_USER_CANCELED; +bool IsCancellation(DownloadInterruptReason reason) { + return reason == DOWNLOAD_INTERRUPT_REASON_USER_SHUTDOWN || + reason == DOWNLOAD_INTERRUPT_REASON_USER_CANCELED; } -std::string GetDownloadTypeNames(download::DownloadItem::DownloadType type) { +std::string GetDownloadTypeNames(DownloadItem::DownloadType type) { switch (type) { - case download::DownloadItem::TYPE_ACTIVE_DOWNLOAD: + case DownloadItem::TYPE_ACTIVE_DOWNLOAD: return "NEW_DOWNLOAD"; - case download::DownloadItem::TYPE_HISTORY_IMPORT: + case DownloadItem::TYPE_HISTORY_IMPORT: return "HISTORY_IMPORT"; - case download::DownloadItem::TYPE_SAVE_PAGE_AS: + case DownloadItem::TYPE_SAVE_PAGE_AS: return "SAVE_PAGE_AS"; default: NOTREACHED(); @@ -132,25 +127,25 @@ } } -std::string GetDownloadDangerNames(download::DownloadDangerType type) { +std::string GetDownloadDangerNames(DownloadDangerType type) { switch (type) { - case download::DOWNLOAD_DANGER_TYPE_NOT_DANGEROUS: + case DOWNLOAD_DANGER_TYPE_NOT_DANGEROUS: return "NOT_DANGEROUS"; - case download::DOWNLOAD_DANGER_TYPE_DANGEROUS_FILE: + case DOWNLOAD_DANGER_TYPE_DANGEROUS_FILE: return "DANGEROUS_FILE"; - case download::DOWNLOAD_DANGER_TYPE_DANGEROUS_URL: + case DOWNLOAD_DANGER_TYPE_DANGEROUS_URL: return "DANGEROUS_URL"; - case download::DOWNLOAD_DANGER_TYPE_DANGEROUS_CONTENT: + case DOWNLOAD_DANGER_TYPE_DANGEROUS_CONTENT: return "DANGEROUS_CONTENT"; - case download::DOWNLOAD_DANGER_TYPE_MAYBE_DANGEROUS_CONTENT: + case DOWNLOAD_DANGER_TYPE_MAYBE_DANGEROUS_CONTENT: return "MAYBE_DANGEROUS_CONTENT"; - case download::DOWNLOAD_DANGER_TYPE_UNCOMMON_CONTENT: + case DOWNLOAD_DANGER_TYPE_UNCOMMON_CONTENT: return "UNCOMMON_CONTENT"; - case download::DOWNLOAD_DANGER_TYPE_USER_VALIDATED: + case DOWNLOAD_DANGER_TYPE_USER_VALIDATED: return "USER_VALIDATED"; - case download::DOWNLOAD_DANGER_TYPE_DANGEROUS_HOST: + case DOWNLOAD_DANGER_TYPE_DANGEROUS_HOST: return "DANGEROUS_HOST"; - case download::DOWNLOAD_DANGER_TYPE_POTENTIALLY_UNWANTED: + case DOWNLOAD_DANGER_TYPE_POTENTIALLY_UNWANTED: return "POTENTIALLY_UNWANTED"; default: NOTREACHED(); @@ -161,12 +156,12 @@ class DownloadItemActivatedData : public base::trace_event::ConvertableToTraceFormat { public: - DownloadItemActivatedData(download::DownloadItem::DownloadType download_type, + DownloadItemActivatedData(DownloadItem::DownloadType download_type, uint32_t download_id, std::string original_url, std::string final_url, std::string file_name, - download::DownloadDangerType danger_type, + DownloadDangerType danger_type, int64_t start_offset, bool has_user_gesture) : download_type_(download_type), @@ -202,12 +197,12 @@ } private: - download::DownloadItem::DownloadType download_type_; + DownloadItem::DownloadType download_type_; uint32_t download_id_; std::string original_url_; std::string final_url_; std::string file_name_; - download::DownloadDangerType danger_type_; + DownloadDangerType danger_type_; int64_t start_offset_; bool has_user_gesture_; DISALLOW_COPY_AND_ASSIGN(DownloadItemActivatedData); @@ -298,13 +293,13 @@ int64_t received_bytes, int64_t total_bytes, const std::string& hash, - download::DownloadItem::DownloadState state, - download::DownloadDangerType danger_type, - download::DownloadInterruptReason interrupt_reason, + DownloadItem::DownloadState state, + DownloadDangerType danger_type, + DownloadInterruptReason interrupt_reason, bool opened, base::Time last_access_time, bool transient, - const std::vector<download::DownloadItem::ReceivedSlice>& received_slices) + const std::vector<DownloadItem::ReceivedSlice>& received_slices) : request_info_(url_chain, referrer_url, site_url, @@ -350,7 +345,7 @@ // Constructing for a regular download: DownloadItemImpl::DownloadItemImpl(DownloadItemImplDelegate* delegate, uint32_t download_id, - const download::DownloadCreateInfo& info) + const DownloadCreateInfo& info) : request_info_(info.url_chain, info.referrer_url, info.site_url, @@ -399,7 +394,7 @@ const base::FilePath& path, const GURL& url, const std::string& mime_type, - std::unique_ptr<download::DownloadRequestHandleInterface> request_handle) + std::unique_ptr<DownloadRequestHandleInterface> request_handle) : request_info_(url), guid_(base::GenerateGUID()), download_id_(download_id), @@ -411,9 +406,9 @@ destination_info_(path, path, 0, false, std::string(), base::Time()), is_updating_observers_(false), weak_ptr_factory_(this) { - job_ = download::DownloadJobFactory::CreateJob( - this, std::move(request_handle), download::DownloadCreateInfo(), true, - nullptr, nullptr); + job_ = DownloadJobFactory::CreateJob(this, std::move(request_handle), + DownloadCreateInfo(), true, nullptr, + nullptr); delegate_->Attach(); Init(true /* actively downloading */, TYPE_SAVE_PAGE_AS); } @@ -467,9 +462,9 @@ if (IsDone() || !IsDangerous()) return; - download::RecordDangerousDownloadAccept(GetDangerType(), GetTargetFilePath()); + RecordDangerousDownloadAccept(GetDangerType(), GetTargetFilePath()); - danger_type_ = download::DOWNLOAD_DANGER_TYPE_USER_VALIDATED; + danger_type_ = DOWNLOAD_DANGER_TYPE_USER_VALIDATED; TRACE_EVENT_INSTANT1("download", "DownloadItemSaftyStateUpdated", TRACE_EVENT_SCOPE_THREAD, "danger_type", @@ -493,7 +488,7 @@ if (delete_file_afterward) { if (download_file_) { base::PostTaskAndReplyWithResult( - download::GetDownloadTaskRunner().get(), FROM_HERE, + GetDownloadTaskRunner().get(), FROM_HERE, base::Bind(&DownloadFileDetach, base::Passed(&download_file_)), callback); } else { @@ -504,7 +499,7 @@ // Download item has now been deleted. } else if (download_file_) { base::PostTaskAndReplyWithResult( - download::GetDownloadTaskRunner().get(), FROM_HERE, + GetDownloadTaskRunner().get(), FROM_HERE, base::Bind(&MakeCopyOfDownloadFile, download_file_.get()), callback); } else { callback.Run(GetFullPath()); @@ -555,7 +550,7 @@ case COMPLETING_INTERNAL: case INITIAL_INTERNAL: case INTERRUPTED_TARGET_PENDING_INTERNAL: - case RESUMING_INTERNAL: // Resumption in progress. + case RESUMING_INTERNAL: // Resumption in progress. return; case TARGET_PENDING_INTERNAL: @@ -583,19 +578,18 @@ DCHECK_CALLED_ON_VALID_THREAD(thread_checker_); DVLOG(20) << __func__ << "() download = " << DebugString(true); InterruptAndDiscardPartialState( - user_cancel ? download::DOWNLOAD_INTERRUPT_REASON_USER_CANCELED - : download::DOWNLOAD_INTERRUPT_REASON_USER_SHUTDOWN); + user_cancel ? DOWNLOAD_INTERRUPT_REASON_USER_CANCELED + : DOWNLOAD_INTERRUPT_REASON_USER_SHUTDOWN); UpdateObservers(); } void DownloadItemImpl::Remove() { DVLOG(20) << __func__ << "() download = " << DebugString(true); DCHECK_CALLED_ON_VALID_THREAD(thread_checker_); - download::RecordDownloadDeletion(GetEndTime(), GetMimeType()); + RecordDownloadDeletion(GetEndTime(), GetMimeType()); delegate_->AssertStateConsistent(this); - InterruptAndDiscardPartialState( - download::DOWNLOAD_INTERRUPT_REASON_USER_CANCELED); + InterruptAndDiscardPartialState(DOWNLOAD_INTERRUPT_REASON_USER_CANCELED); UpdateObservers(); delegate_->AssertStateConsistent(this); @@ -623,7 +617,7 @@ // program that opens the file. So instead we spawn a check to update // the UI if the file has been deleted in parallel with the open. delegate_->CheckForFileRemoval(this); - download::RecordOpen(GetEndTime(), !GetOpened()); + RecordOpen(GetEndTime(), !GetOpened()); opened_ = true; last_access_time_ = base::Time::Now(); for (auto& observer : observers_) @@ -645,11 +639,11 @@ return guid_; } -download::DownloadItem::DownloadState DownloadItemImpl::GetState() const { +DownloadItem::DownloadState DownloadItemImpl::GetState() const { return InternalToExternalState(state_); } -download::DownloadInterruptReason DownloadItemImpl::GetLastReason() const { +DownloadInterruptReason DownloadItemImpl::GetLastReason() const { return last_reason_; } @@ -678,11 +672,11 @@ return IsPaused(); case INTERRUPTED_INTERNAL: { - download::ResumeMode resume_mode = GetResumeMode(); + ResumeMode resume_mode = GetResumeMode(); // Only allow Resume() calls if the resumption mode requires a user // action. - return resume_mode == download::ResumeMode::USER_RESTART || - resume_mode == download::ResumeMode::USER_CONTINUE; + return resume_mode == ResumeMode::USER_RESTART || + resume_mode == ResumeMode::USER_CONTINUE; } case MAX_DOWNLOAD_INTERNAL_STATE: @@ -816,8 +810,7 @@ return GetTargetFilePath().BaseName(); } -download::DownloadItem::TargetDisposition -DownloadItemImpl::GetTargetDisposition() const { +DownloadItem::TargetDisposition DownloadItemImpl::GetTargetDisposition() const { return destination_info_.target_disposition; } @@ -831,7 +824,7 @@ void DownloadItemImpl::DeleteFile(const base::Callback<void(bool)>& callback) { DCHECK_CALLED_ON_VALID_THREAD(thread_checker_); - if (GetState() != download::DownloadItem::COMPLETE) { + if (GetState() != DownloadItem::COMPLETE) { // Pass a null WeakPtr so it doesn't call OnDownloadedFileRemoved. base::SequencedTaskRunnerHandle::Get()->PostTask( FROM_HERE, @@ -848,26 +841,26 @@ return; } base::PostTaskAndReplyWithResult( - download::GetDownloadTaskRunner().get(), FROM_HERE, + GetDownloadTaskRunner().get(), FROM_HERE, base::Bind(&DeleteDownloadedFile, GetFullPath()), base::Bind(&DeleteDownloadedFileDone, weak_ptr_factory_.GetWeakPtr(), callback)); } -download::DownloadFile* DownloadItemImpl::GetDownloadFile() { +DownloadFile* DownloadItemImpl::GetDownloadFile() { return download_file_.get(); } bool DownloadItemImpl::IsDangerous() const { - return (danger_type_ == download::DOWNLOAD_DANGER_TYPE_DANGEROUS_FILE || - danger_type_ == download::DOWNLOAD_DANGER_TYPE_DANGEROUS_URL || - danger_type_ == download::DOWNLOAD_DANGER_TYPE_DANGEROUS_CONTENT || - danger_type_ == download::DOWNLOAD_DANGER_TYPE_UNCOMMON_CONTENT || - danger_type_ == download::DOWNLOAD_DANGER_TYPE_DANGEROUS_HOST || - danger_type_ == download::DOWNLOAD_DANGER_TYPE_POTENTIALLY_UNWANTED); + return (danger_type_ == DOWNLOAD_DANGER_TYPE_DANGEROUS_FILE || + danger_type_ == DOWNLOAD_DANGER_TYPE_DANGEROUS_URL || + danger_type_ == DOWNLOAD_DANGER_TYPE_DANGEROUS_CONTENT || + danger_type_ == DOWNLOAD_DANGER_TYPE_UNCOMMON_CONTENT || + danger_type_ == DOWNLOAD_DANGER_TYPE_DANGEROUS_HOST || + danger_type_ == DOWNLOAD_DANGER_TYPE_POTENTIALLY_UNWANTED); } -download::DownloadDangerType DownloadItemImpl::GetDangerType() const { +DownloadDangerType DownloadItemImpl::GetDangerType() const { return danger_type_; } @@ -911,7 +904,7 @@ return destination_info_.received_bytes; } -const std::vector<download::DownloadItem::ReceivedSlice>& +const std::vector<DownloadItem::ReceivedSlice>& DownloadItemImpl::GetReceivedSlices() const { return received_slices_; } @@ -934,7 +927,7 @@ // We can open the file or mark it for opening on completion if the download // is expected to complete successfully. Exclude temporary downloads, since // they aren't owned by the download system. - const bool is_complete = GetState() == download::DownloadItem::COMPLETE; + const bool is_complete = GetState() == DownloadItem::COMPLETE; return (!IsDone() || is_complete) && !IsTemporary() && !file_externally_removed_ && delegate_->IsMostRecentDownloadItemAtFilePath(this); @@ -964,9 +957,8 @@ return transient_; } -void DownloadItemImpl::OnContentCheckCompleted( - download::DownloadDangerType danger_type, - download::DownloadInterruptReason reason) { +void DownloadItemImpl::OnContentCheckCompleted(DownloadDangerType danger_type, + DownloadInterruptReason reason) { DCHECK_CALLED_ON_VALID_THREAD(thread_checker_); DCHECK(AllDataSaved()); @@ -980,9 +972,9 @@ DVLOG(20) << __func__ << "() danger_type=" << danger_type << " download=" << DebugString(true); SetDangerType(danger_type); - if (reason != download::DOWNLOAD_INTERRUPT_REASON_NONE) { + if (reason != DOWNLOAD_INTERRUPT_REASON_NONE) { InterruptAndDiscardPartialState(reason); - DCHECK_EQ(download::ResumeMode::INVALID, GetResumeMode()); + DCHECK_EQ(ResumeMode::INVALID, GetResumeMode()); } UpdateObservers(); } @@ -1005,11 +997,10 @@ } std::string DownloadItemImpl::DebugString(bool verbose) const { - std::string description = - base::StringPrintf("{ id = %d" - " state = %s", - download_id_, - DebugDownloadStateString(state_)); + std::string description = base::StringPrintf( + "{ id = %d" + " state = %s", + download_id_, DebugDownloadStateString(state_)); // Construct a string of the URL chain. std::string url_list("<none>"); @@ -1018,7 +1009,7 @@ std::vector<GURL>::const_iterator last = request_info_.url_chain.end(); url_list = (*iter).is_valid() ? (*iter).spec() : "<invalid>"; ++iter; - for ( ; verbose && (iter != last); ++iter) { + for (; verbose && (iter != last); ++iter) { url_list += " ->\n\t"; const GURL& next_url = *iter; url_list += next_url.is_valid() ? next_url.spec() : "<invalid>"; @@ -1061,20 +1052,19 @@ return description; } -void DownloadItemImpl::SimulateErrorForTesting( - download::DownloadInterruptReason reason) { +void DownloadItemImpl::SimulateErrorForTesting(DownloadInterruptReason reason) { DCHECK_CALLED_ON_VALID_THREAD(thread_checker_); InterruptWithPartialState(GetReceivedBytes(), nullptr, reason); UpdateObservers(); } -download::ResumeMode DownloadItemImpl::GetResumeMode() const { +ResumeMode DownloadItemImpl::GetResumeMode() const { DCHECK_CALLED_ON_VALID_THREAD(thread_checker_); // Only support resumption for HTTP(S). if (!GetURL().SchemeIsHTTPOrHTTPS()) - return download::ResumeMode::INVALID; + return ResumeMode::INVALID; // We can't continue without a handle on the intermediate file. // We also can't continue if we don't have some verifier to make sure @@ -1088,19 +1078,19 @@ (auto_resume_count_ >= kMaxAutoResumeAttempts || IsPaused()); switch (last_reason_) { - case download::DOWNLOAD_INTERRUPT_REASON_FILE_TRANSIENT_ERROR: - case download::DOWNLOAD_INTERRUPT_REASON_NETWORK_TIMEOUT: - case download::DOWNLOAD_INTERRUPT_REASON_SERVER_CONTENT_LENGTH_MISMATCH: + case DOWNLOAD_INTERRUPT_REASON_FILE_TRANSIENT_ERROR: + case DOWNLOAD_INTERRUPT_REASON_NETWORK_TIMEOUT: + case DOWNLOAD_INTERRUPT_REASON_SERVER_CONTENT_LENGTH_MISMATCH: break; - case download::DOWNLOAD_INTERRUPT_REASON_SERVER_NO_RANGE: + case DOWNLOAD_INTERRUPT_REASON_SERVER_NO_RANGE: // The server disagreed with the file offset that we sent. - case download::DOWNLOAD_INTERRUPT_REASON_FILE_HASH_MISMATCH: + case DOWNLOAD_INTERRUPT_REASON_FILE_HASH_MISMATCH: // The file on disk was found to not match the expected hash. Discard and // start from beginning. - case download::DOWNLOAD_INTERRUPT_REASON_FILE_TOO_SHORT: + case DOWNLOAD_INTERRUPT_REASON_FILE_TOO_SHORT: // The [possibly persisted] file offset disagreed with the file on disk. // The intermediate stub is not usable and the server is responding. Hence @@ -1108,20 +1098,20 @@ restart_required = true; break; - case download::DOWNLOAD_INTERRUPT_REASON_NETWORK_FAILED: - case download::DOWNLOAD_INTERRUPT_REASON_NETWORK_DISCONNECTED: - case download::DOWNLOAD_INTERRUPT_REASON_NETWORK_SERVER_DOWN: - case download::DOWNLOAD_INTERRUPT_REASON_SERVER_FAILED: - case download::DOWNLOAD_INTERRUPT_REASON_SERVER_UNREACHABLE: - case download::DOWNLOAD_INTERRUPT_REASON_USER_SHUTDOWN: - case download::DOWNLOAD_INTERRUPT_REASON_CRASH: + case DOWNLOAD_INTERRUPT_REASON_NETWORK_FAILED: + case DOWNLOAD_INTERRUPT_REASON_NETWORK_DISCONNECTED: + case DOWNLOAD_INTERRUPT_REASON_NETWORK_SERVER_DOWN: + case DOWNLOAD_INTERRUPT_REASON_SERVER_FAILED: + case DOWNLOAD_INTERRUPT_REASON_SERVER_UNREACHABLE: + case DOWNLOAD_INTERRUPT_REASON_USER_SHUTDOWN: + case DOWNLOAD_INTERRUPT_REASON_CRASH: // It is not clear whether attempting a resumption is acceptable at this // time or whether it would work at all. Hence allow the user to retry the // download manually. user_action_required = true; break; - case download::DOWNLOAD_INTERRUPT_REASON_FILE_NO_SPACE: + case DOWNLOAD_INTERRUPT_REASON_FILE_NO_SPACE: // There was no space. Require user interaction so that the user may, for // example, choose a different location to store the file. Or they may // free up some space on the targret device and retry. But try to reuse @@ -1129,44 +1119,44 @@ user_action_required = true; break; - case download::DOWNLOAD_INTERRUPT_REASON_FILE_FAILED: - case download::DOWNLOAD_INTERRUPT_REASON_FILE_ACCESS_DENIED: - case download::DOWNLOAD_INTERRUPT_REASON_FILE_NAME_TOO_LONG: - case download::DOWNLOAD_INTERRUPT_REASON_FILE_TOO_LARGE: + case DOWNLOAD_INTERRUPT_REASON_FILE_FAILED: + case DOWNLOAD_INTERRUPT_REASON_FILE_ACCESS_DENIED: + case DOWNLOAD_INTERRUPT_REASON_FILE_NAME_TOO_LONG: + case DOWNLOAD_INTERRUPT_REASON_FILE_TOO_LARGE: // Assume the partial stub is unusable. Also it may not be possible to // restart immediately. user_action_required = true; restart_required = true; break; - case download::DOWNLOAD_INTERRUPT_REASON_NONE: - case download::DOWNLOAD_INTERRUPT_REASON_NETWORK_INVALID_REQUEST: - case download::DOWNLOAD_INTERRUPT_REASON_FILE_VIRUS_INFECTED: - case download::DOWNLOAD_INTERRUPT_REASON_SERVER_BAD_CONTENT: - case download::DOWNLOAD_INTERRUPT_REASON_USER_CANCELED: - case download::DOWNLOAD_INTERRUPT_REASON_FILE_BLOCKED: - case download::DOWNLOAD_INTERRUPT_REASON_FILE_SECURITY_CHECK_FAILED: - case download::DOWNLOAD_INTERRUPT_REASON_SERVER_UNAUTHORIZED: - case download::DOWNLOAD_INTERRUPT_REASON_SERVER_CERT_PROBLEM: - case download::DOWNLOAD_INTERRUPT_REASON_SERVER_FORBIDDEN: - case download::DOWNLOAD_INTERRUPT_REASON_FILE_SAME_AS_SOURCE: - return download::ResumeMode::INVALID; + case DOWNLOAD_INTERRUPT_REASON_NONE: + case DOWNLOAD_INTERRUPT_REASON_NETWORK_INVALID_REQUEST: + case DOWNLOAD_INTERRUPT_REASON_FILE_VIRUS_INFECTED: + case DOWNLOAD_INTERRUPT_REASON_SERVER_BAD_CONTENT: + case DOWNLOAD_INTERRUPT_REASON_USER_CANCELED: + case DOWNLOAD_INTERRUPT_REASON_FILE_BLOCKED: + case DOWNLOAD_INTERRUPT_REASON_FILE_SECURITY_CHECK_FAILED: + case DOWNLOAD_INTERRUPT_REASON_SERVER_UNAUTHORIZED: + case DOWNLOAD_INTERRUPT_REASON_SERVER_CERT_PROBLEM: + case DOWNLOAD_INTERRUPT_REASON_SERVER_FORBIDDEN: + case DOWNLOAD_INTERRUPT_REASON_FILE_SAME_AS_SOURCE: + return ResumeMode::INVALID; } if (user_action_required && restart_required) - return download::ResumeMode::USER_RESTART; + return ResumeMode::USER_RESTART; if (restart_required) - return download::ResumeMode::IMMEDIATE_RESTART; + return ResumeMode::IMMEDIATE_RESTART; if (user_action_required) - return download::ResumeMode::USER_CONTINUE; + return ResumeMode::USER_CONTINUE; - return download::ResumeMode::IMMEDIATE_CONTINUE; + return ResumeMode::IMMEDIATE_CONTINUE; } void DownloadItemImpl::UpdateValidatorsOnResumption( - const download::DownloadCreateInfo& new_create_info) { + const DownloadCreateInfo& new_create_info) { DCHECK_CALLED_ON_VALID_THREAD(thread_checker_); DCHECK_EQ(RESUMING_INTERNAL, state_); DCHECK(!new_create_info.url_chain.empty()); @@ -1190,18 +1180,17 @@ int origin_state = 0; bool is_partial = GetReceivedBytes() > 0; if (chain_iter != new_create_info.url_chain.end()) - origin_state |= download::ORIGIN_STATE_ON_RESUMPTION_ADDITIONAL_REDIRECTS; + origin_state |= ORIGIN_STATE_ON_RESUMPTION_ADDITIONAL_REDIRECTS; if (etag_ != new_create_info.etag || last_modified_time_ != new_create_info.last_modified) { received_slices_.clear(); destination_info_.received_bytes = 0; - origin_state |= download::ORIGIN_STATE_ON_RESUMPTION_VALIDATORS_CHANGED; + origin_state |= ORIGIN_STATE_ON_RESUMPTION_VALIDATORS_CHANGED; } if (content_disposition_ != new_create_info.content_disposition) - origin_state |= - download::ORIGIN_STATE_ON_RESUMPTION_CONTENT_DISPOSITION_CHANGED; - download::RecordOriginStateOnResumption( - is_partial, static_cast<download::OriginStateOnResumption>(origin_state)); + origin_state |= ORIGIN_STATE_ON_RESUMPTION_CONTENT_DISPOSITION_CHANGED; + RecordOriginStateOnResumption( + is_partial, static_cast<OriginStateOnResumption>(origin_state)); request_info_.url_chain.insert(request_info_.url_chain.end(), chain_iter, new_create_info.url_chain.end()); @@ -1229,7 +1218,7 @@ UpdateObservers(); } -base::WeakPtr<download::DownloadDestinationObserver> +base::WeakPtr<DownloadDestinationObserver> DownloadItemImpl::DestinationObserverAsWeakPtr() { return weak_ptr_factory_.GetWeakPtr(); } @@ -1254,12 +1243,12 @@ if (received_bytes_at_length_mismatch_ > 0) { if (total_bytes > received_bytes_at_length_mismatch_) { - download::RecordDownloadCountWithSource( - download::MORE_BYTES_RECEIVED_AFTER_CONTENT_LENGTH_MISMATCH_COUNT, + RecordDownloadCountWithSource( + MORE_BYTES_RECEIVED_AFTER_CONTENT_LENGTH_MISMATCH_COUNT, download_source_); } else if (total_bytes == received_bytes_at_length_mismatch_) { - download::RecordDownloadCountWithSource( - download::NO_BYTES_RECEIVED_AFTER_CONTENT_LENGTH_MISMATCH_COUNT, + RecordDownloadCountWithSource( + NO_BYTES_RECEIVED_AFTER_CONTENT_LENGTH_MISMATCH_COUNT, download_source_); } else { // This could happen if the content changes on the server. @@ -1281,7 +1270,7 @@ void DownloadItemImpl::DestinationUpdate( int64_t bytes_so_far, int64_t bytes_per_sec, - const std::vector<download::DownloadItem::ReceivedSlice>& received_slices) { + const std::vector<DownloadItem::ReceivedSlice>& received_slices) { DCHECK_CALLED_ON_VALID_THREAD(thread_checker_); // If the download is in any other state we don't expect any // DownloadDestinationObserver callbacks. An interruption or a cancellation @@ -1292,8 +1281,7 @@ state_ == INTERRUPTED_TARGET_PENDING_INTERNAL); // There must be no pending deferred_interrupt_reason_. - DCHECK(deferred_interrupt_reason_ == - download::DOWNLOAD_INTERRUPT_REASON_NONE || + DCHECK(deferred_interrupt_reason_ == DOWNLOAD_INTERRUPT_REASON_NONE || state_ == INTERRUPTED_TARGET_PENDING_INTERNAL); DVLOG(20) << __func__ << "() so_far=" << bytes_so_far @@ -1310,7 +1298,7 @@ } void DownloadItemImpl::DestinationError( - download::DownloadInterruptReason reason, + DownloadInterruptReason reason, int64_t bytes_so_far, std::unique_ptr<crypto::SecureHash> secure_hash) { DCHECK_CALLED_ON_VALID_THREAD(thread_checker_); @@ -1347,9 +1335,8 @@ // **** Download progression cascade -void DownloadItemImpl::Init( - bool active, - download::DownloadItem::DownloadType download_type) { +void DownloadItemImpl::Init(bool active, + DownloadItem::DownloadType download_type) { DCHECK_CALLED_ON_VALID_THREAD(thread_checker_); std::string file_name; @@ -1393,27 +1380,25 @@ // We're starting the download. void DownloadItemImpl::Start( - std::unique_ptr<download::DownloadFile> file, - std::unique_ptr<download::DownloadRequestHandleInterface> req_handle, - const download::DownloadCreateInfo& new_create_info, + std::unique_ptr<DownloadFile> file, + std::unique_ptr<DownloadRequestHandleInterface> req_handle, + const DownloadCreateInfo& new_create_info, scoped_refptr<network::SharedURLLoaderFactory> shared_url_loader_factory, net::URLRequestContextGetter* url_request_context_getter) { DCHECK_CALLED_ON_VALID_THREAD(thread_checker_); DCHECK(!download_file_.get()); DVLOG(20) << __func__ << "() this=" << DebugString(true); - download::RecordDownloadCountWithSource(download::START_COUNT, - download_source_); + RecordDownloadCountWithSource(START_COUNT, download_source_); download_file_ = std::move(file); - job_ = download::DownloadJobFactory::CreateJob( + job_ = DownloadJobFactory::CreateJob( this, std::move(req_handle), new_create_info, false, std::move(shared_url_loader_factory), url_request_context_getter); if (job_->IsParallelizable()) { - download::RecordParallelizableDownloadCount( - download::START_COUNT, download::IsParallelDownloadEnabled()); + RecordParallelizableDownloadCount(START_COUNT, IsParallelDownloadEnabled()); } - deferred_interrupt_reason_ = download::DOWNLOAD_INTERRUPT_REASON_NONE; + deferred_interrupt_reason_ = DOWNLOAD_INTERRUPT_REASON_NONE; if (state_ == CANCELLED_INTERNAL) { // The download was in the process of resuming when it was cancelled. Don't @@ -1436,7 +1421,7 @@ // If a resumption attempted failed, or if the download was DOA, then the // download should go back to being interrupted. - if (new_create_info.result != download::DOWNLOAD_INTERRUPT_REASON_NONE) { + if (new_create_info.result != DOWNLOAD_INTERRUPT_REASON_NONE) { DCHECK(!download_file_.get()); // Download requests that are interrupted by Start() should result in a @@ -1460,26 +1445,24 @@ } if (state_ == INITIAL_INTERNAL) { - download::RecordDownloadCountWithSource(download::NEW_DOWNLOAD_COUNT, - download_source_); + RecordDownloadCountWithSource(NEW_DOWNLOAD_COUNT, download_source_); if (job_->IsParallelizable()) { - download::RecordParallelizableDownloadCount( - download::NEW_DOWNLOAD_COUNT, download::IsParallelDownloadEnabled()); + RecordParallelizableDownloadCount(NEW_DOWNLOAD_COUNT, + IsParallelDownloadEnabled()); } - download::RecordDownloadMimeType(mime_type_); - download::DownloadContent file_type = - download::DownloadContentFromMimeType(mime_type_, false); + RecordDownloadMimeType(mime_type_); + DownloadContent file_type = DownloadContentFromMimeType(mime_type_, false); auto in_progress_entry = delegate_->GetInProgressEntry(this); if (in_progress_entry) { - download::DownloadUkmHelper::RecordDownloadStarted( + DownloadUkmHelper::RecordDownloadStarted( in_progress_entry->ukm_download_id, new_create_info.ukm_source_id, file_type, download_source_); } if (!delegate_->IsOffTheRecord()) { - download::RecordDownloadCountWithSource( - download::NEW_DOWNLOAD_COUNT_NORMAL_PROFILE, download_source_); - download::RecordDownloadMimeTypeForNormalProfile(mime_type_); + RecordDownloadCountWithSource(NEW_DOWNLOAD_COUNT_NORMAL_PROFILE, + download_source_); + RecordDownloadMimeTypeForNormalProfile(mime_type_); } } @@ -1506,9 +1489,8 @@ GetReceivedSlices()); } -void DownloadItemImpl::OnDownloadFileInitialized( - download::DownloadInterruptReason result, - int64_t bytes_wasted) { +void DownloadItemImpl::OnDownloadFileInitialized(DownloadInterruptReason result, + int64_t bytes_wasted) { DCHECK_CALLED_ON_VALID_THREAD(thread_checker_); DCHECK(state_ == TARGET_PENDING_INTERNAL || state_ == INTERRUPTED_TARGET_PENDING_INTERNAL) @@ -1521,14 +1503,14 @@ bytes_wasted_ = bytes_wasted; auto in_progress_entry = delegate_->GetInProgressEntry(this); if (in_progress_entry.has_value()) { - download::DownloadEntry entry = in_progress_entry.value(); + DownloadEntry entry = in_progress_entry.value(); bytes_wasted_ = entry.bytes_wasted + bytes_wasted; delegate_->ReportBytesWasted(this); } } // Handle download interrupt reason. - if (result != download::DOWNLOAD_INTERRUPT_REASON_NONE) { + if (result != DOWNLOAD_INTERRUPT_REASON_NONE) { ReleaseDownloadFile(true); InterruptAndDiscardPartialState(result); } @@ -1540,8 +1522,8 @@ DCHECK_CALLED_ON_VALID_THREAD(thread_checker_); DVLOG(20) << __func__ << "() " << DebugString(true); - download::RecordDownloadCountWithSource( - download::DETERMINE_DOWNLOAD_TARGET_COUNT, download_source_); + RecordDownloadCountWithSource(DETERMINE_DOWNLOAD_TARGET_COUNT, + download_source_); delegate_->DetermineDownloadTarget( this, base::Bind(&DownloadItemImpl::OnDownloadTargetDetermined, weak_ptr_factory_.GetWeakPtr())); @@ -1551,9 +1533,9 @@ void DownloadItemImpl::OnDownloadTargetDetermined( const base::FilePath& target_path, TargetDisposition disposition, - download::DownloadDangerType danger_type, + DownloadDangerType danger_type, const base::FilePath& intermediate_path, - download::DownloadInterruptReason interrupt_reason) { + DownloadInterruptReason interrupt_reason) { DCHECK_CALLED_ON_VALID_THREAD(thread_checker_); if (state_ == CANCELLED_INTERNAL) return; @@ -1567,8 +1549,8 @@ << DownloadInterruptReasonToString(interrupt_reason) << " this:" << DebugString(true); - download::RecordDownloadCountWithSource( - download::DOWNLOAD_TARGET_DETERMINED_COUNT, download_source_); + RecordDownloadCountWithSource(DOWNLOAD_TARGET_DETERMINED_COUNT, + download_source_); if (IsCancellation(interrupt_reason) || target_path.empty()) { Cancel(true); @@ -1581,7 +1563,7 @@ // intermediate rename. In the case of a new download, we'll lose the partial // data that may have been downloaded, but that should be a small loss. if (state_ == TARGET_PENDING_INTERNAL && - interrupt_reason != download::DOWNLOAD_INTERRUPT_REASON_NONE) { + interrupt_reason != DOWNLOAD_INTERRUPT_REASON_NONE) { deferred_interrupt_reason_ = interrupt_reason; TransitionTo(INTERRUPTED_TARGET_PENDING_INTERNAL); OnTargetResolved(); @@ -1614,8 +1596,8 @@ // determination on resumption, for example if the reason for the interruption // was the download target running out space, resulting in a user prompt. if (intermediate_path == GetFullPath()) { - OnDownloadRenamedToIntermediateName( - download::DOWNLOAD_INTERRUPT_REASON_NONE, intermediate_path); + OnDownloadRenamedToIntermediateName(DOWNLOAD_INTERRUPT_REASON_NONE, + intermediate_path); return; } @@ -1625,19 +1607,19 @@ // filename. Unnecessary renames may cause bugs like // http://crbug.com/74187. DCHECK(!IsSavePackageDownload()); - download::DownloadFile::RenameCompletionCallback callback = + DownloadFile::RenameCompletionCallback callback = base::Bind(&DownloadItemImpl::OnDownloadRenamedToIntermediateName, weak_ptr_factory_.GetWeakPtr()); - download::GetDownloadTaskRunner()->PostTask( + GetDownloadTaskRunner()->PostTask( FROM_HERE, - base::BindOnce(&download::DownloadFile::RenameAndUniquify, + base::BindOnce(&DownloadFile::RenameAndUniquify, // Safe because we control download file lifetime. base::Unretained(download_file_.get()), intermediate_path, std::move(callback))); } void DownloadItemImpl::OnDownloadRenamedToIntermediateName( - download::DownloadInterruptReason reason, + DownloadInterruptReason reason, const base::FilePath& full_path) { DCHECK_CALLED_ON_VALID_THREAD(thread_checker_); DCHECK(state_ == TARGET_PENDING_INTERNAL || @@ -1645,7 +1627,7 @@ DCHECK(download_file_); DVLOG(20) << __func__ << "() download=" << DebugString(true); - if (download::DOWNLOAD_INTERRUPT_REASON_NONE == reason) { + if (DOWNLOAD_INTERRUPT_REASON_NONE == reason) { SetFullPath(full_path); } else { // TODO(asanka): Even though the rename failed, it may still be possible to @@ -1659,12 +1641,10 @@ void DownloadItemImpl::OnTargetResolved() { DCHECK_CALLED_ON_VALID_THREAD(thread_checker_); DVLOG(20) << __func__ << "() download=" << DebugString(true); - DCHECK( - (state_ == TARGET_PENDING_INTERNAL && - deferred_interrupt_reason_ == - download::DOWNLOAD_INTERRUPT_REASON_NONE) || - (state_ == INTERRUPTED_TARGET_PENDING_INTERNAL && - deferred_interrupt_reason_ != download::DOWNLOAD_INTERRUPT_REASON_NONE)) + DCHECK((state_ == TARGET_PENDING_INTERNAL && + deferred_interrupt_reason_ == DOWNLOAD_INTERRUPT_REASON_NONE) || + (state_ == INTERRUPTED_TARGET_PENDING_INTERNAL && + deferred_interrupt_reason_ != DOWNLOAD_INTERRUPT_REASON_NONE)) << " deferred_interrupt_reason_:" << DownloadInterruptReasonToString(deferred_interrupt_reason_) << " this:" << DebugString(true); @@ -1675,16 +1655,16 @@ // OnTargetResolved() can result in an externally visible state where the // download is interrupted but doesn't have a target path associated with it. // - // While not terrible, this complicates the download::DownloadItem<->Observer + // While not terrible, this complicates the DownloadItem<->Observer // relationship since an observer that needs a target path in order to respond // properly to an interruption will need to wait for another OnDownloadUpdated // notification. This requirement currently affects all of our UIs. TransitionTo(TARGET_RESOLVED_INTERNAL); - if (download::DOWNLOAD_INTERRUPT_REASON_NONE != deferred_interrupt_reason_) { + if (DOWNLOAD_INTERRUPT_REASON_NONE != deferred_interrupt_reason_) { InterruptWithPartialState(GetReceivedBytes(), std::move(hash_state_), deferred_interrupt_reason_); - deferred_interrupt_reason_ = download::DOWNLOAD_INTERRUPT_REASON_NONE; + deferred_interrupt_reason_ = DOWNLOAD_INTERRUPT_REASON_NONE; UpdateObservers(); return; } @@ -1701,7 +1681,7 @@ // SavePackageFilePickerChromeOS), GData calls MaybeCompleteDownload() like it // does for non-SavePackage downloads, but SavePackage downloads never satisfy // IsDownloadReadyForCompletion(). GDataDownloadObserver manually calls -// download::DownloadItem::UpdateObservers() when the upload completes so that +// DownloadItem::UpdateObservers() when the upload completes so that // SavePackage notices that the upload has completed and runs its normal // Finish() pathway. MaybeCompleteDownload() is never the mechanism by which // SavePackage completes downloads. SavePackage always uses its own Finish() to @@ -1738,12 +1718,12 @@ DCHECK(download_file_.get()); // Unilaterally rename; even if it already has the right name, // we need theannotation. - download::DownloadFile::RenameCompletionCallback callback = + DownloadFile::RenameCompletionCallback callback = base::Bind(&DownloadItemImpl::OnDownloadRenamedToFinalName, weak_ptr_factory_.GetWeakPtr()); - download::GetDownloadTaskRunner()->PostTask( + GetDownloadTaskRunner()->PostTask( FROM_HERE, - base::BindOnce(&download::DownloadFile::RenameAndAnnotate, + base::BindOnce(&DownloadFile::RenameAndAnnotate, base::Unretained(download_file_.get()), GetTargetFilePath(), delegate_->GetApplicationClientIdForFileScanning(), @@ -1751,7 +1731,7 @@ } void DownloadItemImpl::OnDownloadRenamedToFinalName( - download::DownloadInterruptReason reason, + DownloadInterruptReason reason, const base::FilePath& full_path) { DCHECK_CALLED_ON_VALID_THREAD(thread_checker_); DCHECK(!IsSavePackageDownload()); @@ -1765,7 +1745,7 @@ DVLOG(20) << __func__ << "() full_path = \"" << full_path.value() << "\" " << DebugString(false); - if (download::DOWNLOAD_INTERRUPT_REASON_NONE != reason) { + if (DOWNLOAD_INTERRUPT_REASON_NONE != reason) { // Failure to perform the final rename is considered fatal. TODO(asanka): It // may not be, in which case we should figure out whether we can recover the // state. @@ -1819,15 +1799,15 @@ TransitionTo(COMPLETE_INTERNAL); bool is_parallelizable = job_ && job_->IsParallelizable(); - download::RecordDownloadCompleted(start_tick_, GetReceivedBytes(), - is_parallelizable, download_source_); + RecordDownloadCompleted(start_tick_, GetReceivedBytes(), is_parallelizable, + download_source_); if (!delegate_->IsOffTheRecord()) { - download::RecordDownloadCountWithSource( - download::COMPLETED_COUNT_NORMAL_PROFILE, download_source_); + RecordDownloadCountWithSource(COMPLETED_COUNT_NORMAL_PROFILE, + download_source_); } if (is_parallelizable) { - download::RecordParallelizableDownloadCount( - download::COMPLETED_COUNT, download::IsParallelDownloadEnabled()); + RecordParallelizableDownloadCount(COMPLETED_COUNT, + IsParallelDownloadEnabled()); int64_t content_length = -1; if (response_headers_->response_code() != net::HTTP_PARTIAL_CONTENT) { content_length = response_headers_->GetContentLength(); @@ -1838,13 +1818,12 @@ &content_length); } if (content_length > 0) - download::RecordParallelizableContentLength(content_length); + RecordParallelizableContentLength(content_length); } if (auto_opened_) { // If it was already handled by the delegate, do nothing. - } else if (GetOpenWhenComplete() || - ShouldOpenFileBasedOnExtension() || + } else if (GetOpenWhenComplete() || ShouldOpenFileBasedOnExtension() || IsTemporary()) { // If the download is temporary, like in drag-and-drop, do not open it but // we still need to set it auto-opened so that it can be removed from the @@ -1862,7 +1841,7 @@ auto in_progress_entry = delegate_->GetInProgressEntry(this); if (in_progress_entry) { - download::DownloadUkmHelper::RecordDownloadCompleted( + DownloadUkmHelper::RecordDownloadCompleted( in_progress_entry->ukm_download_id, resulting_file_size, time_since_start, in_progress_entry->bytes_wasted); } @@ -1874,16 +1853,16 @@ // **** End of Download progression cascade void DownloadItemImpl::InterruptAndDiscardPartialState( - download::DownloadInterruptReason reason) { - InterruptWithPartialState(0, std::unique_ptr<crypto::SecureHash>(), reason); + DownloadInterruptReason reason) { + InterruptWithPartialState(0, nullptr, reason); } void DownloadItemImpl::InterruptWithPartialState( int64_t bytes_so_far, std::unique_ptr<crypto::SecureHash> hash_state, - download::DownloadInterruptReason reason) { + DownloadInterruptReason reason) { DCHECK_CALLED_ON_VALID_THREAD(thread_checker_); - DCHECK_NE(download::DOWNLOAD_INTERRUPT_REASON_NONE, reason); + DCHECK_NE(DOWNLOAD_INTERRUPT_REASON_NONE, reason); DVLOG(20) << __func__ << "() reason:" << DownloadInterruptReasonToString(reason) << " bytes_so_far:" << bytes_so_far @@ -1921,7 +1900,7 @@ // completes. // // current_path_ may be empty because it is possible for - // download::DownloadItem to receive a DestinationError prior to the + // DownloadItem to receive a DestinationError prior to the // download file initialization complete callback. if (!IsCancellation(reason)) { UpdateProgress(bytes_so_far, 0); @@ -1940,10 +1919,9 @@ last_reason_ = reason; if (download_file_) { - download::ResumeMode resume_mode = GetResumeMode(); - ReleaseDownloadFile(resume_mode != - download::ResumeMode::IMMEDIATE_CONTINUE && - resume_mode != download::ResumeMode::USER_CONTINUE); + ResumeMode resume_mode = GetResumeMode(); + ReleaseDownloadFile(resume_mode != ResumeMode::IMMEDIATE_CONTINUE && + resume_mode != ResumeMode::USER_CONTINUE); } break; @@ -1960,7 +1938,7 @@ // There is no download file and this is transitioning from INTERRUPTED // to CANCELLED. The intermediate file is no longer usable, and should // be deleted. - download::GetDownloadTaskRunner()->PostTask( + GetDownloadTaskRunner()->PostTask( FROM_HERE, base::BindOnce(base::IgnoreResult(&DeleteDownloadedFile), GetFullPath())); destination_info_.current_path.clear(); @@ -1994,28 +1972,26 @@ if (IsCancellation(reason)) { if (IsDangerous()) { - download::RecordDangerousDownloadDiscard( - reason == download::DOWNLOAD_INTERRUPT_REASON_USER_CANCELED - ? download::DOWNLOAD_DISCARD_DUE_TO_USER_ACTION - : download::DOWNLOAD_DISCARD_DUE_TO_SHUTDOWN, + RecordDangerousDownloadDiscard( + reason == DOWNLOAD_INTERRUPT_REASON_USER_CANCELED + ? DOWNLOAD_DISCARD_DUE_TO_USER_ACTION + : DOWNLOAD_DISCARD_DUE_TO_SHUTDOWN, GetDangerType(), GetTargetFilePath()); } - download::RecordDownloadCountWithSource(download::CANCELLED_COUNT, - download_source_); + RecordDownloadCountWithSource(CANCELLED_COUNT, download_source_); if (job_ && job_->IsParallelizable()) { - download::RecordParallelizableDownloadCount( - download::CANCELLED_COUNT, download::IsParallelDownloadEnabled()); + RecordParallelizableDownloadCount(CANCELLED_COUNT, + IsParallelDownloadEnabled()); } DCHECK_EQ(last_reason_, reason); TransitionTo(CANCELLED_INTERNAL); return; } - download::RecordDownloadInterrupted(reason, GetReceivedBytes(), total_bytes_, - job_ && job_->IsParallelizable(), - download::IsParallelDownloadEnabled(), - download_source_); + RecordDownloadInterrupted(reason, GetReceivedBytes(), total_bytes_, + job_ && job_->IsParallelizable(), + IsParallelDownloadEnabled(), download_source_); base::TimeDelta time_since_start = base::Time::Now() - GetStartTime(); int resulting_file_size = GetReceivedBytes(); @@ -2026,12 +2002,11 @@ change_in_file_size = total_bytes_ - resulting_file_size; } - download::DownloadUkmHelper::RecordDownloadInterrupted( + DownloadUkmHelper::RecordDownloadInterrupted( in_progress_entry->ukm_download_id, change_in_file_size, reason, resulting_file_size, time_since_start, in_progress_entry->bytes_wasted); } - if (reason == - download::DOWNLOAD_INTERRUPT_REASON_SERVER_CONTENT_LENGTH_MISMATCH) { + if (reason == DOWNLOAD_INTERRUPT_REASON_SERVER_CONTENT_LENGTH_MISMATCH) { received_bytes_at_length_mismatch_ = GetReceivedBytes(); } @@ -2044,9 +2019,8 @@ AutoResumeIfValid(); } -void DownloadItemImpl::UpdateProgress( - int64_t bytes_so_far, - int64_t bytes_per_sec) { +void DownloadItemImpl::UpdateProgress(int64_t bytes_so_far, + int64_t bytes_per_sec) { destination_info_.received_bytes = bytes_so_far; bytes_per_sec_ = bytes_per_sec; @@ -2075,7 +2049,7 @@ DVLOG(20) << __func__ << "() destroy_file:" << destroy_file; if (destroy_file) { - download::GetDownloadTaskRunner()->PostTask( + GetDownloadTaskRunner()->PostTask( FROM_HERE, // Will be deleted at end of task execution. base::BindOnce(&DownloadFileCancel, std::move(download_file_))); @@ -2084,7 +2058,7 @@ destination_info_.current_path.clear(); received_slices_.clear(); } else { - download::GetDownloadTaskRunner()->PostTask( + GetDownloadTaskRunner()->PostTask( FROM_HERE, base::BindOnce(base::IgnoreResult(&DownloadFileDetach), // Will be deleted at end of task execution. std::move(download_file_))); @@ -2153,8 +2127,7 @@ break; case INTERRUPTED_TARGET_PENDING_INTERNAL: - DCHECK_NE(download::DOWNLOAD_INTERRUPT_REASON_NONE, - deferred_interrupt_reason_) + DCHECK_NE(DOWNLOAD_INTERRUPT_REASON_NONE, deferred_interrupt_reason_) << "Interrupt reason must be set prior to transitioning into " "TARGET_PENDING"; break; @@ -2194,7 +2167,7 @@ case INTERRUPTED_INTERNAL: DCHECK(!download_file_) << "Download file must be released prior to interruption."; - DCHECK_NE(last_reason_, download::DOWNLOAD_INTERRUPT_REASON_NONE); + DCHECK_NE(last_reason_, DOWNLOAD_INTERRUPT_REASON_NONE); TRACE_EVENT_INSTANT2("download", "DownloadItemInterrupted", TRACE_EVENT_SCOPE_THREAD, "interrupt_reason", DownloadInterruptReasonToString(last_reason_), @@ -2245,7 +2218,7 @@ } } -void DownloadItemImpl::SetDangerType(download::DownloadDangerType danger_type) { +void DownloadItemImpl::SetDangerType(DownloadDangerType danger_type) { if (danger_type != danger_type_) { TRACE_EVENT_INSTANT1("download", "DownloadItemSaftyStateUpdated", TRACE_EVENT_SCOPE_THREAD, "danger_type", @@ -2253,16 +2226,15 @@ } // Only record the Malicious UMA stat if it's going from {not malicious} -> // {malicious}. - if ((danger_type_ == download::DOWNLOAD_DANGER_TYPE_NOT_DANGEROUS || - danger_type_ == download::DOWNLOAD_DANGER_TYPE_DANGEROUS_FILE || - danger_type_ == download::DOWNLOAD_DANGER_TYPE_UNCOMMON_CONTENT || - danger_type_ == - download::DOWNLOAD_DANGER_TYPE_MAYBE_DANGEROUS_CONTENT) && - (danger_type == download::DOWNLOAD_DANGER_TYPE_DANGEROUS_HOST || - danger_type == download::DOWNLOAD_DANGER_TYPE_DANGEROUS_URL || - danger_type == download::DOWNLOAD_DANGER_TYPE_DANGEROUS_CONTENT || - danger_type == download::DOWNLOAD_DANGER_TYPE_POTENTIALLY_UNWANTED)) { - download::RecordMaliciousDownloadClassified(danger_type); + if ((danger_type_ == DOWNLOAD_DANGER_TYPE_NOT_DANGEROUS || + danger_type_ == DOWNLOAD_DANGER_TYPE_DANGEROUS_FILE || + danger_type_ == DOWNLOAD_DANGER_TYPE_UNCOMMON_CONTENT || + danger_type_ == DOWNLOAD_DANGER_TYPE_MAYBE_DANGEROUS_CONTENT) && + (danger_type == DOWNLOAD_DANGER_TYPE_DANGEROUS_HOST || + danger_type == DOWNLOAD_DANGER_TYPE_DANGEROUS_URL || + danger_type == DOWNLOAD_DANGER_TYPE_DANGEROUS_CONTENT || + danger_type == DOWNLOAD_DANGER_TYPE_POTENTIALLY_UNWANTED)) { + RecordMaliciousDownloadClassified(danger_type); } danger_type_ = danger_type; } @@ -2284,10 +2256,10 @@ void DownloadItemImpl::AutoResumeIfValid() { DVLOG(20) << __func__ << "() " << DebugString(true); DCHECK_CALLED_ON_VALID_THREAD(thread_checker_); - download::ResumeMode mode = GetResumeMode(); + ResumeMode mode = GetResumeMode(); - if (mode != download::ResumeMode::IMMEDIATE_RESTART && - mode != download::ResumeMode::IMMEDIATE_CONTINUE) { + if (mode != ResumeMode::IMMEDIATE_RESTART && + mode != ResumeMode::IMMEDIATE_CONTINUE) { return; } @@ -2308,9 +2280,9 @@ weak_ptr_factory_.InvalidateWeakPtrs(); // Reset the appropriate state if restarting. - download::ResumeMode mode = GetResumeMode(); - if (mode == download::ResumeMode::IMMEDIATE_RESTART || - mode == download::ResumeMode::USER_RESTART) { + ResumeMode mode = GetResumeMode(); + if (mode == ResumeMode::IMMEDIATE_RESTART || + mode == ResumeMode::USER_RESTART) { DCHECK(GetFullPath().empty()); destination_info_.received_bytes = 0; last_modified_time_.clear(); @@ -2348,13 +2320,12 @@ // are consistently routed through the no-renderer code paths so that the // request will not be dropped if the WebContents (and by extension, the // associated renderer) goes away before a response is received. - std::unique_ptr<download::DownloadUrlParameters> download_params( - new download::DownloadUrlParameters(GetURL(), nullptr, - traffic_annotation)); + std::unique_ptr<DownloadUrlParameters> download_params( + new DownloadUrlParameters(GetURL(), nullptr, traffic_annotation)); download_params->set_file_path(GetFullPath()); if (received_slices_.size() > 0) { - std::vector<download::DownloadItem::ReceivedSlice> slices_to_download = - download::FindSlicesToDownload(received_slices_); + std::vector<DownloadItem::ReceivedSlice> slices_to_download = + FindSlicesToDownload(received_slices_); download_params->set_offset(slices_to_download[0].offset); } else { download_params->set_offset(GetReceivedBytes()); @@ -2382,17 +2353,16 @@ download_params->set_referrer_policy(net::URLRequest::NEVER_CLEAR_REFERRER); TransitionTo(RESUMING_INTERNAL); - download::RecordDownloadCountWithSource( - source == ResumptionRequestSource::USER - ? download::MANUAL_RESUMPTION_COUNT - : download::AUTO_RESUMPTION_COUNT, - download_source_); + RecordDownloadCountWithSource(source == ResumptionRequestSource::USER + ? MANUAL_RESUMPTION_COUNT + : AUTO_RESUMPTION_COUNT, + download_source_); base::TimeDelta time_since_start = base::Time::Now() - GetStartTime(); auto in_progress_entry = delegate_->GetInProgressEntry(this); if (in_progress_entry) { - download::DownloadUkmHelper::RecordDownloadResumed( - in_progress_entry->ukm_download_id, GetResumeMode(), time_since_start); + DownloadUkmHelper::RecordDownloadResumed(in_progress_entry->ukm_download_id, + GetResumeMode(), time_since_start); } delegate_->ResumeInterruptedDownload(std::move(download_params), GetId(), @@ -2403,7 +2373,7 @@ } // static -download::DownloadItem::DownloadState DownloadItemImpl::InternalToExternalState( +DownloadItem::DownloadState DownloadItemImpl::InternalToExternalState( DownloadInternalState internal_state) { switch (internal_state) { case INITIAL_INTERNAL: @@ -2435,8 +2405,7 @@ // static DownloadItemImpl::DownloadInternalState -DownloadItemImpl::ExternalToInternalState( - DownloadState external_state) { +DownloadItemImpl::ExternalToInternalState(DownloadState external_state) { switch (external_state) { case IN_PROGRESS: return IN_PROGRESS_INTERNAL; @@ -2561,21 +2530,21 @@ return "unknown"; } -const char* DownloadItemImpl::DebugResumeModeString(download::ResumeMode mode) { +const char* DownloadItemImpl::DebugResumeModeString(ResumeMode mode) { switch (mode) { - case download::ResumeMode::INVALID: + case ResumeMode::INVALID: return "INVALID"; - case download::ResumeMode::IMMEDIATE_CONTINUE: + case ResumeMode::IMMEDIATE_CONTINUE: return "IMMEDIATE_CONTINUE"; - case download::ResumeMode::IMMEDIATE_RESTART: + case ResumeMode::IMMEDIATE_RESTART: return "IMMEDIATE_RESTART"; - case download::ResumeMode::USER_CONTINUE: + case ResumeMode::USER_CONTINUE: return "USER_CONTINUE"; - case download::ResumeMode::USER_RESTART: + case ResumeMode::USER_RESTART: return "USER_RESTART"; } NOTREACHED() << "Unknown resume mode " << static_cast<int>(mode); return "unknown"; } -} // namespace content +} // namespace download
diff --git a/content/browser/download/download_item_impl_delegate.cc b/components/download/internal/common/download_item_impl_delegate.cc similarity index 73% rename from content/browser/download/download_item_impl_delegate.cc rename to components/download/internal/common/download_item_impl_delegate.cc index 9de4ddc..363d564 100644 --- a/content/browser/download/download_item_impl_delegate.cc +++ b/components/download/internal/common/download_item_impl_delegate.cc
@@ -2,19 +2,18 @@ // Use of this source code is governed by a BSD-style license that can be // found in the LICENSE file. -#include "content/browser/download/download_item_impl_delegate.h" +#include "components/download/public/common/download_item_impl_delegate.h" #include "base/logging.h" #include "components/download/downloader/in_progress/download_entry.h" #include "components/download/public/common/download_danger_type.h" -#include "content/browser/download/download_item_impl.h" +#include "components/download/public/common/download_item_impl.h" -namespace content { +namespace download { // Infrastructure in DownloadItemImplDelegate to assert invariant that // delegate always outlives all attached DownloadItemImpls. -DownloadItemImplDelegate::DownloadItemImplDelegate() - : count_(0) {} +DownloadItemImplDelegate::DownloadItemImplDelegate() : count_(0) {} DownloadItemImplDelegate::~DownloadItemImplDelegate() { DCHECK_EQ(0, count_); @@ -30,13 +29,13 @@ } void DownloadItemImplDelegate::DetermineDownloadTarget( - DownloadItemImpl* download, const DownloadTargetCallback& callback) { + DownloadItemImpl* download, + const DownloadTargetCallback& callback) { // TODO(rdsmith/asanka): Do something useful if forced file path is null. base::FilePath target_path(download->GetForcedFilePath()); - callback.Run(target_path, - download::DownloadItem::TARGET_DISPOSITION_OVERWRITE, - download::DOWNLOAD_DANGER_TYPE_NOT_DANGEROUS, target_path, - download::DOWNLOAD_INTERRUPT_REASON_NONE); + callback.Run(target_path, DownloadItem::TARGET_DISPOSITION_OVERWRITE, + DOWNLOAD_DANGER_TYPE_NOT_DANGEROUS, target_path, + DOWNLOAD_INTERRUPT_REASON_NONE); } bool DownloadItemImplDelegate::ShouldCompleteDownload( @@ -46,7 +45,8 @@ } bool DownloadItemImplDelegate::ShouldOpenDownload( - DownloadItemImpl* download, const ShouldOpenDownloadCallback& callback) { + DownloadItemImpl* download, + const ShouldOpenDownloadCallback& callback) { return false; } @@ -64,7 +64,7 @@ } void DownloadItemImplDelegate::ResumeInterruptedDownload( - std::unique_ptr<download::DownloadUrlParameters> params, + std::unique_ptr<DownloadUrlParameters> params, uint32_t id, const GURL& site_url) {} @@ -88,9 +88,9 @@ void DownloadItemImplDelegate::DownloadInterrupted(DownloadItemImpl* download) { } -base::Optional<download::DownloadEntry> -DownloadItemImplDelegate::GetInProgressEntry(DownloadItemImpl* download) { - return base::Optional<download::DownloadEntry>(); +base::Optional<DownloadEntry> DownloadItemImplDelegate::GetInProgressEntry( + DownloadItemImpl* download) { + return base::Optional<DownloadEntry>(); } bool DownloadItemImplDelegate::IsOffTheRecord() const { @@ -99,4 +99,4 @@ void DownloadItemImplDelegate::ReportBytesWasted(DownloadItemImpl* download) {} -} // namespace content +} // namespace download
diff --git a/components/download/public/common/BUILD.gn b/components/download/public/common/BUILD.gn index 57efaf2..8dd829e 100644 --- a/components/download/public/common/BUILD.gn +++ b/components/download/public/common/BUILD.gn
@@ -30,6 +30,8 @@ "download_interrupt_reasons.h", "download_interrupt_reasons_utils.h", "download_item.h", + "download_item_impl.h", + "download_item_impl_delegate.h", "download_job.h", "download_job_factory.h", "download_job_impl.h", @@ -65,6 +67,7 @@ deps = [ "//base", + "//components/download/downloader/in_progress", "//components/download/internal/common:internal", "//crypto", "//net", @@ -74,8 +77,10 @@ "//ui/base", ] - allow_circular_includes_from = - [ "//components/download/internal/common:internal" ] + allow_circular_includes_from = [ + "//components/download/internal/common:internal", + "//components/download/downloader/in_progress", + ] } if (is_android) {
diff --git a/content/browser/download/download_item_impl.h b/components/download/public/common/download_item_impl.h similarity index 84% rename from content/browser/download/download_item_impl.h rename to components/download/public/common/download_item_impl.h index 96fc6f2..a92093e 100644 --- a/content/browser/download/download_item_impl.h +++ b/components/download/public/common/download_item_impl.h
@@ -2,8 +2,8 @@ // Use of this source code is governed by a BSD-style license that can be // found in the LICENSE file. -#ifndef CONTENT_BROWSER_DOWNLOAD_DOWNLOAD_ITEM_IMPL_H_ -#define CONTENT_BROWSER_DOWNLOAD_DOWNLOAD_ITEM_IMPL_H_ +#ifndef COMPONENTS_DOWNLOAD_PUBLIC_COMMON_DOWNLOAD_ITEM_IMPL_H_ +#define COMPONENTS_DOWNLOAD_PUBLIC_COMMON_DOWNLOAD_ITEM_IMPL_H_ #include <stdint.h> @@ -25,33 +25,30 @@ #include "components/download/public/common/download_request_handle_interface.h" #include "components/download/public/common/download_url_parameters.h" #include "components/download/public/common/resume_mode.h" -#include "content/common/content_export.h" #include "services/network/public/cpp/shared_url_loader_factory.h" #include "url/gurl.h" -namespace download { -class DownloadFile; -class DownloadJob; -} // namespace download - namespace net { class URLRequestContextGetter; } -namespace content { +namespace download { + +class DownloadFile; class DownloadItemImplDelegate; +class DownloadJob; // See download_item.h for usage. -class CONTENT_EXPORT DownloadItemImpl - : public download::DownloadItem, - public download::DownloadDestinationObserver { +class COMPONENTS_DOWNLOAD_EXPORT DownloadItemImpl + : public DownloadItem, + public DownloadDestinationObserver { public: // Information about the initial request that triggers the download. Most of - // the fields are immutable after the download::DownloadItem is successfully + // the fields are immutable after the DownloadItem is successfully // created. However, it is possible that the url chain is changed when // resuming an interrupted download. In that case, the download will restart // from the beginning. - struct CONTENT_EXPORT RequestInfo { + struct COMPONENTS_DOWNLOAD_EXPORT RequestInfo { RequestInfo(const std::vector<GURL>& url_chain, const GURL& referrer_url, const GURL& site_url, @@ -106,7 +103,7 @@ }; // Information about the current state of the download destination. - struct CONTENT_EXPORT DestinationInfo { + struct COMPONENTS_DOWNLOAD_EXPORT DestinationInfo { DestinationInfo(const base::FilePath& target_path, const base::FilePath& current_path, int64_t received_bytes, @@ -162,39 +159,39 @@ // Constructing from persistent store: // |net_log| is constructed externally for our use. - DownloadItemImpl(DownloadItemImplDelegate* delegate, - const std::string& guid, - uint32_t id, - const base::FilePath& current_path, - const base::FilePath& target_path, - const std::vector<GURL>& url_chain, - const GURL& referrer_url, - const GURL& site_url, - const GURL& tab_url, - const GURL& tab_referrer_url, - const std::string& mime_type, - const std::string& original_mime_type, - base::Time start_time, - base::Time end_time, - const std::string& etag, - const std::string& last_modified, - int64_t received_bytes, - int64_t total_bytes, - const std::string& hash, - download::DownloadItem::DownloadState state, - download::DownloadDangerType danger_type, - download::DownloadInterruptReason interrupt_reason, - bool opened, - base::Time last_access_time, - bool transient, - const std::vector<download::DownloadItem::ReceivedSlice>& - received_slices); + DownloadItemImpl( + DownloadItemImplDelegate* delegate, + const std::string& guid, + uint32_t id, + const base::FilePath& current_path, + const base::FilePath& target_path, + const std::vector<GURL>& url_chain, + const GURL& referrer_url, + const GURL& site_url, + const GURL& tab_url, + const GURL& tab_referrer_url, + const std::string& mime_type, + const std::string& original_mime_type, + base::Time start_time, + base::Time end_time, + const std::string& etag, + const std::string& last_modified, + int64_t received_bytes, + int64_t total_bytes, + const std::string& hash, + DownloadItem::DownloadState state, + DownloadDangerType danger_type, + DownloadInterruptReason interrupt_reason, + bool opened, + base::Time last_access_time, + bool transient, + const std::vector<DownloadItem::ReceivedSlice>& received_slices); // Constructing for a regular download. // |net_log| is constructed externally for our use. DownloadItemImpl(DownloadItemImplDelegate* delegate, uint32_t id, - const download::DownloadCreateInfo& info); + const DownloadCreateInfo& info); // Constructing for the "Save Page As..." feature: // |net_log| is constructed externally for our use. @@ -204,13 +201,13 @@ const base::FilePath& path, const GURL& url, const std::string& mime_type, - std::unique_ptr<download::DownloadRequestHandleInterface> request_handle); + std::unique_ptr<DownloadRequestHandleInterface> request_handle); ~DownloadItemImpl() override; - // download::DownloadItem - void AddObserver(download::DownloadItem::Observer* observer) override; - void RemoveObserver(download::DownloadItem::Observer* observer) override; + // DownloadItem + void AddObserver(DownloadItem::Observer* observer) override; + void RemoveObserver(DownloadItem::Observer* observer) override; void UpdateObservers() override; void ValidateDangerousDownload() override; void StealDangerousDownload(bool need_removal, @@ -224,7 +221,7 @@ uint32_t GetId() const override; const std::string& GetGuid() const override; DownloadState GetState() const override; - download::DownloadInterruptReason GetLastReason() const override; + DownloadInterruptReason GetLastReason() const override; bool IsPaused() const override; bool IsTemporary() const override; bool CanResume() const override; @@ -257,16 +254,16 @@ const std::string& GetHash() const override; bool GetFileExternallyRemoved() const override; void DeleteFile(const base::Callback<void(bool)>& callback) override; - download::DownloadFile* GetDownloadFile() override; + DownloadFile* GetDownloadFile() override; bool IsDangerous() const override; - download::DownloadDangerType GetDangerType() const override; + DownloadDangerType GetDangerType() const override; bool TimeRemaining(base::TimeDelta* remaining) const override; int64_t CurrentSpeed() const override; int PercentComplete() const override; bool AllDataSaved() const override; int64_t GetTotalBytes() const override; int64_t GetReceivedBytes() const override; - const std::vector<download::DownloadItem::ReceivedSlice>& GetReceivedSlices() + const std::vector<DownloadItem::ReceivedSlice>& GetReceivedSlices() const override; base::Time GetStartTime() const override; base::Time GetEndTime() const override; @@ -278,16 +275,14 @@ bool GetOpened() const override; base::Time GetLastAccessTime() const override; bool IsTransient() const override; - void OnContentCheckCompleted( - download::DownloadDangerType danger_type, - download::DownloadInterruptReason reason) override; + void OnContentCheckCompleted(DownloadDangerType danger_type, + DownloadInterruptReason reason) override; void SetOpenWhenComplete(bool open) override; void SetOpened(bool opened) override; void SetLastAccessTime(base::Time last_access_time) override; void SetDisplayName(const base::FilePath& name) override; std::string DebugString(bool verbose) const override; - void SimulateErrorForTesting( - download::DownloadInterruptReason reason) override; + void SimulateErrorForTesting(DownloadInterruptReason reason) override; // All remaining public interfaces virtual to allow for DownloadItemImpl // mocks. @@ -299,14 +294,14 @@ // |req_handle| is the new request handle associated with the download. // |new_create_info| is a DownloadCreateInfo containing the new response // parameters. It may be different from the DownloadCreateInfo used to create - // the download::DownloadItem if Start() is being called in response for a + // the DownloadItem if Start() is being called in response for a // download resumption request. // TODO(qinmin): Remove |url_request_context_getter| once network service is // enabled. virtual void Start( - std::unique_ptr<download::DownloadFile> download_file, - std::unique_ptr<download::DownloadRequestHandleInterface> req_handle, - const download::DownloadCreateInfo& new_create_info, + std::unique_ptr<DownloadFile> download_file, + std::unique_ptr<DownloadRequestHandleInterface> req_handle, + const DownloadCreateInfo& new_create_info, scoped_refptr<network::SharedURLLoaderFactory> shared_url_loader_factory, net::URLRequestContextGetter* url_request_context_getter); @@ -319,7 +314,7 @@ // Provide a weak pointer reference to a DownloadDestinationObserver // for use by download destinations. - virtual base::WeakPtr<download::DownloadDestinationObserver> + virtual base::WeakPtr<DownloadDestinationObserver> DestinationObserverAsWeakPtr(); // DownloadItemImpl routines only needed by SavePackage ---------------------- @@ -330,20 +325,19 @@ virtual void OnAllDataSaved(int64_t total_bytes, std::unique_ptr<crypto::SecureHash> hash_state); - // Called by SavePackage to display progress when the download::DownloadItem + // Called by SavePackage to display progress when the DownloadItem // should be considered complete. virtual void MarkAsComplete(); - download::DownloadSource download_source() const { return download_source_; } + DownloadSource download_source() const { return download_source_; } - // download::DownloadDestinationObserver + // DownloadDestinationObserver void DestinationUpdate( int64_t bytes_so_far, int64_t bytes_per_sec, - const std::vector<download::DownloadItem::ReceivedSlice>& received_slices) - override; + const std::vector<DownloadItem::ReceivedSlice>& received_slices) override; void DestinationError( - download::DownloadInterruptReason reason, + DownloadInterruptReason reason, int64_t bytes_so_far, std::unique_ptr<crypto::SecureHash> hash_state) override; void DestinationCompleted( @@ -511,10 +505,10 @@ // Construction common to all constructors. |active| should be true for new // downloads and false for downloads from the history. // |download_type| indicates to the trace event what kind of download this is. - void Init(bool active, download::DownloadItem::DownloadType download_type); + void Init(bool active, DownloadItem::DownloadType download_type); // Callback from file thread when we initialize the DownloadFile. - void OnDownloadFileInitialized(download::DownloadInterruptReason result, + void OnDownloadFileInitialized(DownloadInterruptReason result, int64_t bytes_wasted); // Called to determine the target path. Will cause OnDownloadTargetDetermined @@ -529,13 +523,12 @@ virtual void OnDownloadTargetDetermined( const base::FilePath& target_path, TargetDisposition disposition, - download::DownloadDangerType danger_type, + DownloadDangerType danger_type, const base::FilePath& intermediate_path, - download::DownloadInterruptReason interrupt_reason); + DownloadInterruptReason interrupt_reason); - void OnDownloadRenamedToIntermediateName( - download::DownloadInterruptReason reason, - const base::FilePath& full_path); + void OnDownloadRenamedToIntermediateName(DownloadInterruptReason reason, + const base::FilePath& full_path); void OnTargetResolved(); @@ -546,10 +539,10 @@ // Called when the download is ready to complete. // This may perform final rename if necessary and will eventually call - // download::DownloadItem::Completed(). + // DownloadItem::Completed(). void OnDownloadCompleting(); - void OnDownloadRenamedToFinalName(download::DownloadInterruptReason reason, + void OnDownloadRenamedToFinalName(DownloadInterruptReason reason, const base::FilePath& full_path); // Called if the embedder took over opening a download, to indicate that @@ -565,8 +558,7 @@ // Indicate that an error has occurred on the download. Discards partial // state. The interrupted download will not be considered continuable, but may // be restarted. - void InterruptAndDiscardPartialState( - download::DownloadInterruptReason reason); + void InterruptAndDiscardPartialState(DownloadInterruptReason reason); // Indiates that an error has occurred on the download. The |bytes_so_far| and // |hash_state| should correspond to the state of the DownloadFile. If the @@ -574,7 +566,7 @@ // interrupted download upon resumption. void InterruptWithPartialState(int64_t bytes_so_far, std::unique_ptr<crypto::SecureHash> hash_state, - download::DownloadInterruptReason reason); + DownloadInterruptReason reason); void UpdateProgress(int64_t bytes_so_far, int64_t bytes_per_sec); @@ -598,7 +590,7 @@ void TransitionTo(DownloadInternalState new_state); // Set the |danger_type_| and invoke observers if necessary. - void SetDangerType(download::DownloadDangerType danger_type); + void SetDangerType(DownloadDangerType danger_type); void SetFullPath(const base::FilePath& new_path); @@ -610,7 +602,7 @@ // Update origin information based on the response to a download resumption // request. Should only be called if the resumption request was successful. virtual void UpdateValidatorsOnResumption( - const download::DownloadCreateInfo& new_create_info); + const DownloadCreateInfo& new_create_info); // Notify observers that this item is being removed by the user. void NotifyRemoved(); @@ -618,7 +610,7 @@ // Determines the resume mode for an interrupted download. Requires // last_reason_ to be set, but doesn't require the download to be in // INTERRUPTED state. - download::ResumeMode GetResumeMode() const; + ResumeMode GetResumeMode() const; static DownloadState InternalToExternalState( DownloadInternalState internal_state); @@ -627,7 +619,7 @@ // Debugging routines -------------------------------------------------------- static const char* DebugDownloadStateString(DownloadInternalState state); - static const char* DebugResumeModeString(download::ResumeMode mode); + static const char* DebugResumeModeString(ResumeMode mode); static bool IsValidSavePackageStateTransition(DownloadInternalState from, DownloadInternalState to); static bool IsValidStateTransition(DownloadInternalState from, @@ -636,7 +628,7 @@ RequestInfo request_info_; // GUID to identify the download, generated by |base::GenerateGUID| in - // download item, or provided by |download::DownloadUrlParameters|. + // download item, or provided by |DownloadUrlParameters|. // The format should follow UUID version 4 in RFC 4122. // The string representation is case sensitive. Legacy download GUID hex // digits may be upper case ASCII characters, and new GUID will be in lower @@ -673,8 +665,7 @@ int64_t total_bytes_ = 0; // Last reason. - download::DownloadInterruptReason last_reason_ = - download::DOWNLOAD_INTERRUPT_REASON_NONE; + DownloadInterruptReason last_reason_ = DOWNLOAD_INTERRUPT_REASON_NONE; // Start time for recording statistics. base::TimeTicks start_tick_; @@ -683,8 +674,7 @@ DownloadInternalState state_ = INITIAL_INTERNAL; // Current danger type for the download. - download::DownloadDangerType danger_type_ = - download::DOWNLOAD_DANGER_TYPE_NOT_DANGEROUS; + DownloadDangerType danger_type_ = DOWNLOAD_DANGER_TYPE_NOT_DANGEROUS; // The views of this item in the download shelf and download contents. base::ObserverList<Observer> observers_; @@ -724,16 +714,16 @@ // Error return from DestinationError or received at Start(). Stored // separately from last_reason_ so that we can avoid handling destination // errors until after file name determination has occurred. - download::DownloadInterruptReason deferred_interrupt_reason_ = - download::DOWNLOAD_INTERRUPT_REASON_NONE; + DownloadInterruptReason deferred_interrupt_reason_ = + DOWNLOAD_INTERRUPT_REASON_NONE; // The following fields describe the current state of the download file. // DownloadFile associated with this download. Note that this // pointer may only be used or destroyed on the download sequence. - // This pointer will be non-null only while the download::DownloadItem is in + // This pointer will be non-null only while the DownloadItem is in // the IN_PROGRESS state. - std::unique_ptr<download::DownloadFile> download_file_; + std::unique_ptr<DownloadFile> download_file_; // Information about |download_file_|. DestinationInfo destination_info_; @@ -757,9 +747,9 @@ std::string etag_; // The data slices that have been received so far. - std::vector<download::DownloadItem::ReceivedSlice> received_slices_; + std::vector<DownloadItem::ReceivedSlice> received_slices_; - std::unique_ptr<download::DownloadJob> job_; + std::unique_ptr<DownloadJob> job_; // Value of |received_bytes_| at the time the download was interrupted with // CONTENT_LENGTH_MISMATCH. @@ -774,10 +764,10 @@ // Request header key/value pairs that will be added to the download HTTP // request. - download::DownloadUrlParameters::RequestHeadersType request_headers_; + DownloadUrlParameters::RequestHeadersType request_headers_; // Source of the download, used in metrics. - download::DownloadSource download_source_ = download::DownloadSource::UNKNOWN; + DownloadSource download_source_ = DownloadSource::UNKNOWN; THREAD_CHECKER(thread_checker_); @@ -786,6 +776,6 @@ DISALLOW_COPY_AND_ASSIGN(DownloadItemImpl); }; -} // namespace content +} // namespace download -#endif // CONTENT_BROWSER_DOWNLOAD_DOWNLOAD_ITEM_IMPL_H_ +#endif // COMPONENTS_DOWNLOAD_PUBLIC_COMMON_DOWNLOAD_ITEM_IMPL_H_
diff --git a/content/browser/download/download_item_impl_delegate.h b/components/download/public/common/download_item_impl_delegate.h similarity index 75% rename from content/browser/download/download_item_impl_delegate.h rename to components/download/public/common/download_item_impl_delegate.h index 8ce4ecd1..863786a 100644 --- a/content/browser/download/download_item_impl_delegate.h +++ b/components/download/public/common/download_item_impl_delegate.h
@@ -2,8 +2,8 @@ // Use of this source code is governed by a BSD-style license that can be // found in the LICENSE file. -#ifndef CONTENT_BROWSER_DOWNLOAD_DOWNLOAD_ITEM_IMPL_DELEGATE_H_ -#define CONTENT_BROWSER_DOWNLOAD_DOWNLOAD_ITEM_IMPL_DELEGATE_H_ +#ifndef COMPONENTS_DOWNLOAD_PUBLIC_COMMON_DOWNLOAD_ITEM_IMPL_DELEGATE_H_ +#define COMPONENTS_DOWNLOAD_PUBLIC_COMMON_DOWNLOAD_ITEM_IMPL_DELEGATE_H_ #include <stdint.h> @@ -11,23 +11,19 @@ #include "base/files/file_path.h" #include "base/macros.h" #include "base/optional.h" +#include "components/download/public/common/download_export.h" #include "components/download/public/common/download_item.h" #include "components/download/public/common/download_url_parameters.h" -#include "content/common/content_export.h" -#include "content/public/browser/download_manager_delegate.h" namespace download { struct DownloadEntry; -} - -namespace content { class DownloadItemImpl; // Delegate for operations that a DownloadItemImpl can't do for itself. // The base implementation of this class does nothing (returning false // on predicates) so interfaces not of interest to a derived class may // be left unimplemented. -class CONTENT_EXPORT DownloadItemImplDelegate { +class COMPONENTS_DOWNLOAD_EXPORT DownloadItemImplDelegate { public: // The boolean argument indicates whether or not the download was // actually opened. @@ -40,22 +36,27 @@ void Attach(); void Detach(); + using DownloadTargetCallback = + base::Callback<void(const base::FilePath& target_path, + DownloadItem::TargetDisposition disposition, + DownloadDangerType danger_type, + const base::FilePath& intermediate_path, + DownloadInterruptReason interrupt_reason)>; // Request determination of the download target from the delegate. - virtual void DetermineDownloadTarget( - DownloadItemImpl* download, const DownloadTargetCallback& callback); + virtual void DetermineDownloadTarget(DownloadItemImpl* download, + const DownloadTargetCallback& callback); // Allows the delegate to delay completion of the download. This function // will either return true (if the download may complete now) or will return // false and call the provided callback at some future point. This function // may be called repeatedly. - virtual bool ShouldCompleteDownload( - DownloadItemImpl* download, - const base::Closure& complete_callback); + virtual bool ShouldCompleteDownload(DownloadItemImpl* download, + const base::Closure& complete_callback); // Allows the delegate to override the opening of a download. If it returns // true then it's reponsible for opening the item. - virtual bool ShouldOpenDownload( - DownloadItemImpl* download, const ShouldOpenDownloadCallback& callback); + virtual bool ShouldOpenDownload(DownloadItemImpl* download, + const ShouldOpenDownloadCallback& callback); // Tests if a file type should be opened automatically. virtual bool ShouldOpenFileBasedOnExtension(const base::FilePath& path); @@ -76,7 +77,7 @@ // Called when an interrupted download is resumed. virtual void ResumeInterruptedDownload( - std::unique_ptr<download::DownloadUrlParameters> params, + std::unique_ptr<DownloadUrlParameters> params, uint32_t id, const GURL& site_url); @@ -94,7 +95,7 @@ virtual void ShowDownloadInShell(DownloadItemImpl* download); // Handle any delegate portions of a state change operation on the - // download::DownloadItem. + // DownloadItem. virtual void DownloadRemoved(DownloadItemImpl* download); // Assert consistent state for delgate object at various transitions. @@ -104,7 +105,7 @@ virtual void DownloadInterrupted(DownloadItemImpl* download); // Get the in progress entry for the download item. - virtual base::Optional<download::DownloadEntry> GetInProgressEntry( + virtual base::Optional<DownloadEntry> GetInProgressEntry( DownloadItemImpl* download); // Whether the download is off the record. @@ -120,6 +121,6 @@ DISALLOW_COPY_AND_ASSIGN(DownloadItemImplDelegate); }; -} // namespace content +} // namespace download -#endif // CONTENT_BROWSER_DOWNLOAD_DOWNLOAD_ITEM_IMPL_DELEGATE_H_ +#endif // COMPONENTS_DOWNLOAD_PUBLIC_COMMON_DOWNLOAD_ITEM_IMPL_DELEGATE_H_
diff --git a/components/ntp_snippets/contextual/contextual_content_suggestions_service.cc b/components/ntp_snippets/contextual/contextual_content_suggestions_service.cc index 1d8a09b6..e06e5e6 100644 --- a/components/ntp_snippets/contextual/contextual_content_suggestions_service.cc +++ b/components/ntp_snippets/contextual/contextual_content_suggestions_service.cc
@@ -20,6 +20,9 @@ ContextualContentSuggestionsService::Cluster::Cluster() = default; +ContextualContentSuggestionsService::Cluster::Cluster(Cluster&& other) = + default; + ContextualContentSuggestionsService::Cluster::~Cluster() = default; ContextualContentSuggestionsService::ContextualContentSuggestionsService( @@ -49,7 +52,11 @@ void ContextualContentSuggestionsService::FetchContextualSuggestionClusters( const GURL& url, FetchContextualSuggestionClustersCallback callback) { - // Fetch suggestions using the updated fetcher. + // TODO(pnoland): Fetch suggestions using the new fetcher. + contextual_suggestions_fetcher_->FetchContextualSuggestions( + url, base::BindOnce(&ContextualContentSuggestionsService:: + DidFetchContextualSuggestionsClusterWrapper, + base::Unretained(this), std::move(callback))); } void ContextualContentSuggestionsService::FetchContextualSuggestionImage( @@ -92,4 +99,24 @@ std::move(callback).Run(status, url, std::move(suggestions)); } +void ContextualContentSuggestionsService:: + DidFetchContextualSuggestionsClusterWrapper( + FetchContextualSuggestionClustersCallback callback, + Status status, + ContextualSuggestionsFetcher::OptionalSuggestions fetched_suggestions) { + std::vector<Cluster> clusters; + if (fetched_suggestions.has_value()) { + clusters.emplace_back(); + Cluster& cluster = clusters.back(); + for (const std::unique_ptr<ContextualSuggestion>& suggestion : + fetched_suggestions.value()) { + cluster.suggestions.emplace_back(suggestion->ToContentSuggestion()); + ContentSuggestion::ID id = cluster.suggestions.back().id(); + GURL image_url = suggestion->salient_image_url(); + image_url_by_id_[id.id_within_category()] = image_url; + } + } + std::move(callback).Run(std::move(clusters)); +} + } // namespace ntp_snippets
diff --git a/components/ntp_snippets/contextual/contextual_content_suggestions_service.h b/components/ntp_snippets/contextual/contextual_content_suggestions_service.h index dccd787..9639964 100644 --- a/components/ntp_snippets/contextual/contextual_content_suggestions_service.h +++ b/components/ntp_snippets/contextual/contextual_content_suggestions_service.h
@@ -30,12 +30,15 @@ public: // A structure representing a suggestion cluster. struct Cluster { + public: Cluster(); + Cluster(Cluster&& other); ~Cluster(); std::string title; std::vector<ContentSuggestion> suggestions; + private: DISALLOW_COPY_AND_ASSIGN(Cluster); }; @@ -81,8 +84,10 @@ Status status, ContextualSuggestionsFetcher::OptionalSuggestions fetched_suggestions); - void DidFetchContextualSuggestionsCluster( + // Temporary function to wire new bridge to the old prototype. + void DidFetchContextualSuggestionsClusterWrapper( FetchContextualSuggestionClustersCallback callback, + Status status, ContextualSuggestionsFetcher::OptionalSuggestions fetched_suggestions); // Cache for images of contextual suggestions, needed by CachedImageFetcher.
diff --git a/components/offline_pages/core/BUILD.gn b/components/offline_pages/core/BUILD.gn index 1266fcc0..6be9f5b 100644 --- a/components/offline_pages/core/BUILD.gn +++ b/components/offline_pages/core/BUILD.gn
@@ -50,6 +50,8 @@ "model/startup_maintenance_task.h", "model/store_thumbnail_task.cc", "model/store_thumbnail_task.h", + "model/update_file_path_task.cc", + "model/update_file_path_task.h", "offline_event_logger.cc", "offline_event_logger.h", "offline_page_archiver.cc",
diff --git a/components/offline_pages/core/model/offline_page_model_taskified.cc b/components/offline_pages/core/model/offline_page_model_taskified.cc index 296307d2..6627e0c 100644 --- a/components/offline_pages/core/model/offline_page_model_taskified.cc +++ b/components/offline_pages/core/model/offline_page_model_taskified.cc
@@ -27,6 +27,7 @@ #include "components/offline_pages/core/model/mark_page_accessed_task.h" #include "components/offline_pages/core/model/offline_page_model_utils.h" #include "components/offline_pages/core/model/startup_maintenance_task.h" +#include "components/offline_pages/core/model/update_file_path_task.h" #include "components/offline_pages/core/offline_page_feature.h" #include "components/offline_pages/core/offline_page_metadata_store_sql.h" #include "components/offline_pages/core/offline_page_model.h" @@ -542,21 +543,21 @@ PublishPageCallback publish_done_callback, const OfflinePageItem& offline_page, PublishArchiveResult* publish_results) { - // Return an empty OfflinePageItem if we were unable to move the page. The - // offline_id will be 0, which marks it as invalid. + // Call the callback with success == false if we failed to move the page. if (publish_results->move_result != SavePageResult::SUCCESS) { - OfflinePageItem empty_offline_page; - std::move(publish_done_callback).Run(empty_offline_page); + std::move(publish_done_callback).Run(publish_results->new_file_path, false); return; } - // TODO(petewil): Update the OfflinePageModel with the new location for the - // page, which is found in move_results.new_file_path, and with the download - // ID found at move_results.download_id. Return the updated offline_page to - // the callback. + // Update the OfflinePageModel with the new location for the page, which is + // found in move_results.new_file_path, and with the download ID found at + // move_results.download_id. Return the updated offline_page to the callback. + auto task = std::make_unique<UpdateFilePathTask>( + store_.get(), offline_page.offline_id, publish_results->new_file_path, + base::BindOnce(std::move(publish_done_callback), + publish_results->new_file_path)); - // Return to the OfflinePageBridge callback passed in. - std::move(publish_done_callback).Run(offline_page); + task_queue_.AddTask(std::move(task)); } void OfflinePageModelTaskified::OnAddPageForSavePageDone(
diff --git a/components/offline_pages/core/model/offline_page_model_taskified.h b/components/offline_pages/core/model/offline_page_model_taskified.h index 4c42c6e..489d5af 100644 --- a/components/offline_pages/core/model/offline_page_model_taskified.h +++ b/components/offline_pages/core/model/offline_page_model_taskified.h
@@ -216,7 +216,7 @@ // Callback for when publishing an internal archive has completed. void PublishInternalArchiveDone(PublishPageCallback publish_done_callback, const OfflinePageItem& offline_page, - PublishArchiveResult* move_results); + PublishArchiveResult* publish_results); // Method for unpublishing the page from the system download manager. static void RemoveFromDownloadManager(
diff --git a/components/offline_pages/core/model/offline_page_model_taskified_unittest.cc b/components/offline_pages/core/model/offline_page_model_taskified_unittest.cc index abe9800..71ce6da 100644 --- a/components/offline_pages/core/model/offline_page_model_taskified_unittest.cc +++ b/components/offline_pages/core/model/offline_page_model_taskified_unittest.cc
@@ -29,6 +29,7 @@ #include "components/offline_pages/core/offline_page_model.h" #include "components/offline_pages/core/offline_page_test_archiver.h" #include "components/offline_pages/core/offline_page_types.h" +#include "components/offline_pages/core/offline_store_utils.h" #include "components/offline_pages/core/system_download_manager_stub.h" #include "testing/gmock/include/gmock/gmock.h" #include "testing/gtest/include/gtest/gtest.h" @@ -67,6 +68,34 @@ const std::string kTestDigest("test digest"); const int64_t kDownloadId = 42LL; +// Class to receive the callback for page publish completion. +// TODO(romax): Convert this to a mock callback like the other tests use. +class PublishPageTestCallback { + public: + PublishPageTestCallback() + : callback_called_(false), weak_ptr_factory_(this) {} + + void Run(const base::FilePath& file_path, bool success) { + callback_called_ = true; + success_ = false; + file_path_ = file_path; + success_ = success; + } + + bool callback_called() const { return callback_called_; } + bool success() const { return success_; }; + const base::FilePath file_path() const { return file_path_; }; + base::WeakPtr<PublishPageTestCallback> GetWeakPtr() { + return weak_ptr_factory_.GetWeakPtr(); + } + + private: + bool callback_called_; + bool success_; + base::FilePath file_path_; + base::WeakPtrFactory<PublishPageTestCallback> weak_ptr_factory_; +}; + } // namespace class OfflinePageModelTaskifiedTest : public testing::Test, @@ -1221,9 +1250,6 @@ #endif TEST_F(OfflinePageModelTaskifiedTest, MAYBE_CheckPagesSavedInSeparateDirsPublic) { - auto feature_list = std::make_unique<base::test::ScopedFeatureList>(); - feature_list->InitAndEnableFeature( - offline_pages::kOfflinePagesSharingFeature); // Save a temporary page. auto archiver = BuildArchiver(kTestUrl, ArchiverResult::SUCCESSFULLY_CREATED); int64_t temporary_id = SavePageWithExpectedResult( @@ -1254,6 +1280,51 @@ EXPECT_NE(temporary_page_path.DirName(), persistent_page_path.DirName()); } +// This test is affected by https://crbug.com/725685, which only affects windows +// platform. +#if defined(OS_WIN) +#define MAYBE_CheckPublishInternalArchive DISABLED_CheckPublishInternalArchive +#else +#define MAYBE_CheckPublishInternalArchive CheckPublishInternalArchive +#endif +TEST_F(OfflinePageModelTaskifiedTest, MAYBE_CheckPublishInternalArchive) { + // Save a persistent page into our internal directory that will not be + // published. We use a "browser actions" page for this purpose. + std::unique_ptr<OfflinePageTestArchiver> test_archiver = + BuildArchiver(kTestUrl2, ArchiverResult::SUCCESSFULLY_CREATED); + int64_t persistent_id = SavePageWithExpectedResult( + kTestUrl2, kTestBrowserActionsClientId, GURL(), kEmptyRequestOrigin, + std::move(test_archiver), SavePageResult::SUCCESS); + + std::unique_ptr<OfflinePageItem> persistent_page = + store_test_util()->GetPageByOfflineId(persistent_id); + + ASSERT_TRUE(persistent_page); + + base::FilePath persistent_page_path = persistent_page->file_path; + + // For a page in the browser actions namespace, it gets moved to the + // a private internal directory inside chromium. + EXPECT_TRUE(private_archive_dir_path().IsParent(persistent_page_path)); + + // Make another archiver, since SavePageWithExpectedResult deleted the first + // one. + test_archiver = + BuildArchiver(kTestUrl2, ArchiverResult::SUCCESSFULLY_CREATED); + + // Publish the page from our internal store. + PublishPageTestCallback test_callback; + PublishPageCallback publish_done_callback = + base::BindOnce(&PublishPageTestCallback::Run, test_callback.GetWeakPtr()); + + model()->PublishInternalArchive(*persistent_page, std::move(test_archiver), + std::move(publish_done_callback)); + PumpLoop(); + + // Check that the page was published as expected. + ASSERT_TRUE(test_callback.callback_called()); +} + // This test is disabled since it's lacking the ability of mocking store failure // in store_test_utils. https://crbug.com/781023 // TODO(romax): reenable the test once the above issue is resolved.
diff --git a/components/offline_pages/core/model/update_file_path_task.cc b/components/offline_pages/core/model/update_file_path_task.cc new file mode 100644 index 0000000..6ff0dfd3 --- /dev/null +++ b/components/offline_pages/core/model/update_file_path_task.cc
@@ -0,0 +1,78 @@ +// Copyright 2018 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 "components/offline_pages/core/model/update_file_path_task.h" + +#include "base/bind.h" +#include "components/offline_pages/core/client_namespace_constants.h" +#include "components/offline_pages/core/model/offline_page_model_utils.h" +#include "components/offline_pages/core/offline_page_metadata_store_sql.h" +#include "components/offline_pages/core/offline_store_utils.h" +#include "sql/connection.h" +#include "sql/statement.h" +#include "sql/transaction.h" + +namespace offline_pages { + +namespace { + +bool UpdateFilePathSync(const base::FilePath& new_file_path, + int64_t offline_id, + sql::Connection* db) { + if (!db) + return false; + + sql::Transaction transaction(db); + if (!transaction.Begin()) + return false; + + // Update the file_path to point to the new path. + const char kSqlUpdate[] = + "UPDATE OR IGNORE offlinepages_v1" + " SET file_path = ?" + " WHERE offline_id = ?"; + sql::Statement update_statement( + db->GetCachedStatement(SQL_FROM_HERE, kSqlUpdate)); + update_statement.BindString( + 0, offline_pages::store_utils::ToDatabaseFilePath(new_file_path)); + update_statement.BindInt64(1, offline_id); + + if (!update_statement.Run()) + return false; + + if (!transaction.Commit()) + return false; + + return true; +} + +} // namespace + +UpdateFilePathTask::UpdateFilePathTask(OfflinePageMetadataStoreSQL* store, + int64_t offline_id, + const base::FilePath& file_path, + UpdateFilePathDoneCallback callback) + : store_(store), + offline_id_(offline_id), + file_path_(file_path), + callback_(std::move(callback)), + weak_ptr_factory_(this) { + DCHECK(store_); +} + +UpdateFilePathTask::~UpdateFilePathTask(){}; + +void UpdateFilePathTask::Run() { + store_->Execute(base::BindOnce(&UpdateFilePathSync, file_path_, offline_id_), + base::BindOnce(&UpdateFilePathTask::OnUpdateFilePathDone, + weak_ptr_factory_.GetWeakPtr())); +} + +void UpdateFilePathTask::OnUpdateFilePathDone(bool result) { + // Forward the updated offline page to the callback + std::move(callback_).Run(result); + TaskComplete(); +} + +} // namespace offline_pages
diff --git a/components/offline_pages/core/model/update_file_path_task.h b/components/offline_pages/core/model/update_file_path_task.h new file mode 100644 index 0000000..da61bf6 --- /dev/null +++ b/components/offline_pages/core/model/update_file_path_task.h
@@ -0,0 +1,50 @@ +// Copyright 2018 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 COMPONENTS_OFFLINE_PAGES_CORE_MODEL_UPDATE_FILE_PATH_TASK_H_ +#define COMPONENTS_OFFLINE_PAGES_CORE_MODEL_UPDATE_FILE_PATH_TASK_H_ + +#include "base/files/file_path.h" +#include "base/macros.h" +#include "base/memory/weak_ptr.h" +#include "components/offline_pages/core/model/get_pages_task.h" +#include "components/offline_pages/core/offline_page_model.h" +#include "components/offline_pages/core/task.h" + +namespace offline_pages { + +using ReadResult = GetPagesTask::ReadResult; + +class OfflinePageMetadataStoreSQL; + +// Task that updates the file path in the metadata store. It takes the offline +// ID of the page accessed, the new file path, and the completion callback. +class UpdateFilePathTask : public Task { + public: + UpdateFilePathTask(OfflinePageMetadataStoreSQL* store, + int64_t offline_id, + const base::FilePath& file_path, + UpdateFilePathDoneCallback callback); + ~UpdateFilePathTask() override; + + // Task implementation. + void Run() override; + + private: + void OnUpdateFilePathDone(bool result); + + // The metadata store used to update the page. Not owned. + OfflinePageMetadataStoreSQL* store_; + + int64_t offline_id_; + base::FilePath file_path_; + UpdateFilePathDoneCallback callback_; + + base::WeakPtrFactory<UpdateFilePathTask> weak_ptr_factory_; + DISALLOW_COPY_AND_ASSIGN(UpdateFilePathTask); +}; + +} // namespace offline_pages + +#endif // COMPONENTS_OFFLINE_PAGES_CORE_MODEL_UPDATE_FILE_PATH_TASK_H_
diff --git a/components/offline_pages/core/offline_page_test_archiver.cc b/components/offline_pages/core/offline_page_test_archiver.cc index 14bad88f..656f452d 100644 --- a/components/offline_pages/core/offline_page_test_archiver.cc +++ b/components/offline_pages/core/offline_page_test_archiver.cc
@@ -25,13 +25,14 @@ result_(result), size_to_report_(size_to_report), create_archive_called_(false), + publish_archive_called_(false), delayed_(false), result_title_(result_title), digest_to_report_(digest_to_report), task_runner_(task_runner) {} OfflinePageTestArchiver::~OfflinePageTestArchiver() { - EXPECT_TRUE(create_archive_called_); + EXPECT_TRUE(create_archive_called_ || publish_archive_called_); } void OfflinePageTestArchiver::CreateArchive( @@ -53,6 +54,7 @@ const base::FilePath& new_file_path, SystemDownloadManager* download_manager, PublishArchiveDoneCallback publish_done_callback) { + publish_archive_called_ = true; publish_archive_result_.move_result = SavePageResult::SUCCESS; publish_archive_result_.new_file_path = offline_page.file_path; publish_archive_result_.download_id = 0;
diff --git a/components/offline_pages/core/offline_page_test_archiver.h b/components/offline_pages/core/offline_page_test_archiver.h index 609fff76..03f88921d 100644 --- a/components/offline_pages/core/offline_page_test_archiver.h +++ b/components/offline_pages/core/offline_page_test_archiver.h
@@ -85,6 +85,7 @@ ArchiverResult result_; int64_t size_to_report_; bool create_archive_called_; + bool publish_archive_called_; bool delayed_; base::string16 result_title_; std::string digest_to_report_;
diff --git a/components/offline_pages/core/offline_page_types.h b/components/offline_pages/core/offline_page_types.h index 6f3f030..047d6035 100644 --- a/components/offline_pages/core/offline_page_types.h +++ b/components/offline_pages/core/offline_page_types.h
@@ -108,8 +108,10 @@ GetThumbnailCallback; typedef base::OnceCallback<void(bool)> CleanupThumbnailsCallback; -// Callback used for publishing an offline page. -using PublishPageCallback = base::OnceCallback<void(const OfflinePageItem&)>; +// Callbacks used for publishing an offline page. +using PublishPageCallback = + base::OnceCallback<void(const base::FilePath&, bool)>; +using UpdateFilePathDoneCallback = base::OnceCallback<void(bool)>; } // namespace offline_pages #endif // COMPONENTS_OFFLINE_PAGES_CORE_OFFLINE_PAGE_TYPES_H_
diff --git a/components/omnibox/browser/search_provider.cc b/components/omnibox/browser/search_provider.cc index b86cb21d..731b8925 100644 --- a/components/omnibox/browser/search_provider.cc +++ b/components/omnibox/browser/search_provider.cc
@@ -996,10 +996,17 @@ } SearchSuggestionParser::SuggestResult verbatim( - trimmed_verbatim, AutocompleteMatchType::SEARCH_WHAT_YOU_TYPED, 0, - trimmed_verbatim, base::string16(), base::string16(), answer_contents, - answer_type, std::move(answer), std::string(), std::string(), false, - verbatim_relevance, relevance_from_server, false, trimmed_verbatim); + /*suggestion=*/trimmed_verbatim, + AutocompleteMatchType::SEARCH_WHAT_YOU_TYPED, + /*subtype_identifier=*/0, + /*match_contents=*/trimmed_verbatim, + /*match_contents_prefix=*/base::string16(), + /*annotation=*/base::string16(), answer_contents, answer_type, + std::move(answer), /*suggest_query_params=*/std::string(), + /*deletion_url=*/std::string(), + /*from_keyword_provider=*/false, verbatim_relevance, + relevance_from_server, /*should_prefetch=*/false, + /*input_text=*/trimmed_verbatim); AddMatchToMap(verbatim, std::string(), did_not_accept_default_suggestion, false, keyword_url != nullptr, &map); } @@ -1019,11 +1026,21 @@ const base::string16& trimmed_verbatim = base::CollapseWhitespace(keyword_input_.text(), false); SearchSuggestionParser::SuggestResult verbatim( - trimmed_verbatim, AutocompleteMatchType::SEARCH_OTHER_ENGINE, 0, - trimmed_verbatim, base::string16(), base::string16(), - base::string16(), base::string16(), nullptr, std::string(), - std::string(), true, keyword_verbatim_relevance, - keyword_relevance_from_server, false, trimmed_verbatim); + /*suggestion=*/trimmed_verbatim, + AutocompleteMatchType::SEARCH_OTHER_ENGINE, + /*subtype_identifier=*/0, + /*match_contents=*/trimmed_verbatim, + /*match_contents_prefix=*/base::string16(), + /*annotation=*/base::string16(), + /*answer_contents=*/base::string16(), + /*answer_type=*/base::string16(), + /*answer=*/nullptr, + /*suggest_query_params=*/std::string(), + /*deletion_url=*/std::string(), + /*from_keyword_provider=*/true, keyword_verbatim_relevance, + keyword_relevance_from_server, + /*should_prefetch=*/false, + /*input_text=*/trimmed_verbatim); AddMatchToMap(verbatim, std::string(), did_not_accept_keyword_suggestion, false, true, &map); } @@ -1205,10 +1222,19 @@ insertion_position = scored_results.begin(); } SearchSuggestionParser::SuggestResult history_suggestion( - trimmed_suggestion, AutocompleteMatchType::SEARCH_HISTORY, 0, - trimmed_suggestion, base::string16(), base::string16(), - base::string16(), base::string16(), nullptr, std::string(), - std::string(), is_keyword, relevance, false, false, trimmed_input); + /*suggestion=*/trimmed_suggestion, + AutocompleteMatchType::SEARCH_HISTORY, + /*subtype_identifier=*/0, + /*match_contents=*/trimmed_suggestion, + /*match_contents_prefix=*/base::string16(), + /*annotation=*/base::string16(), + /*answer_contents=*/base::string16(), + /*answer_type=*/base::string16(), + /*answer=*/nullptr, + /*suggest_query_params=*/std::string(), + /*deletion_url=*/std::string(), is_keyword, relevance, + /*relevance_from_server=*/false, + /*should_prefetch=*/false, /*input_text=*/trimmed_input); // History results are synchronous; they are received on the last keystroke. history_suggestion.set_received_after_last_keystroke(false); scored_results.insert(insertion_position, history_suggestion);
diff --git a/components/password_manager/core/browser/android_affiliation/affiliation_utils.cc b/components/password_manager/core/browser/android_affiliation/affiliation_utils.cc index ce491749..f206c88 100644 --- a/components/password_manager/core/browser/android_affiliation/affiliation_utils.cc +++ b/components/password_manager/core/browser/android_affiliation/affiliation_utils.cc
@@ -53,7 +53,8 @@ url::StdStringCanonOutput canonical_output(canonical_uri); bool canonicalization_succeeded = url::CanonicalizeStandardURL( - input_uri.c_str(), input_uri.size(), input_parsed, nullptr, + input_uri.c_str(), input_uri.size(), input_parsed, + url::SCHEME_WITH_HOST_PORT_AND_USER_INFORMATION, nullptr, &canonical_output, &canonical_parsed); canonical_output.Complete();
diff --git a/components/payments/content/payment_request.cc b/components/payments/content/payment_request.cc index 687ee54..2eef35d3 100644 --- a/components/payments/content/payment_request.cc +++ b/components/payments/content/payment_request.cc
@@ -151,7 +151,7 @@ spec_->url_payment_method_identifiers().end()); } -void PaymentRequest::Show() { +void PaymentRequest::Show(bool is_user_gesture) { if (!client_.is_bound() || !binding_.is_bound()) { LOG(ERROR) << "Attempted Show(), but binding(s) missing."; OnConnectionTerminated(); @@ -177,6 +177,8 @@ return; } + is_show_user_gesture_ = is_user_gesture; + // TODO(crbug.com/783811): Display a spinner when checking whether // the methods are supported asynchronously for better user experience. state_->AreRequestedMethodsSupported( @@ -356,7 +358,7 @@ bool PaymentRequest::SatisfiesSkipUIConstraints() const { return base::FeatureList::IsEnabled(features::kWebPaymentsSingleAppUiSkip) && base::FeatureList::IsEnabled(::features::kServiceWorkerPaymentApps) && - state()->is_get_all_instruments_finished() && + is_show_user_gesture_ && state()->is_get_all_instruments_finished() && state()->available_instruments().size() == 1 && spec()->stringified_method_data().size() == 1 && !spec()->request_shipping() && !spec()->request_payer_name() &&
diff --git a/components/payments/content/payment_request.h b/components/payments/content/payment_request.h index 400ae351..3d7fe46 100644 --- a/components/payments/content/payment_request.h +++ b/components/payments/content/payment_request.h
@@ -65,7 +65,7 @@ std::vector<mojom::PaymentMethodDataPtr> method_data, mojom::PaymentDetailsPtr details, mojom::PaymentOptionsPtr options) override; - void Show() override; + void Show(bool is_user_gesture) override; void UpdateWith(mojom::PaymentDetailsPtr details) override; void NoUpdatedPaymentDetails() override; void Abort() override; @@ -165,6 +165,9 @@ // Whether a completion was already recorded for this Payment Request. bool has_recorded_completion_ = false; + // Whether PaymentRequest.show() was invoked with a user gesture. + bool is_show_user_gesture_ = false; + base::WeakPtrFactory<PaymentRequest> weak_ptr_factory_; DISALLOW_COPY_AND_ASSIGN(PaymentRequest);
diff --git a/components/safe_browsing/browser/safe_browsing_network_context.cc b/components/safe_browsing/browser/safe_browsing_network_context.cc index dc55afe..de77882 100644 --- a/components/safe_browsing/browser/safe_browsing_network_context.cc +++ b/components/safe_browsing/browser/safe_browsing_network_context.cc
@@ -33,8 +33,9 @@ network::mojom::NetworkContext* GetNetworkContext() { DCHECK(content::BrowserThread::CurrentlyOn(content::BrowserThread::UI)); if (!network_context_) { - internal_state_ = base::MakeRefCounted<InternalState>( - request_context_getter_, MakeRequest(&network_context_)); + internal_state_ = base::MakeRefCounted<InternalState>(); + internal_state_->Initialize(request_context_getter_, + MakeRequest(&network_context_)); } return network_context_.get(); } @@ -74,7 +75,9 @@ // This class holds on to the network::NetworkContext object on the IO thread. class InternalState : public base::RefCountedThreadSafe<InternalState> { public: - InternalState( + InternalState() = default; + + void Initialize( scoped_refptr<net::URLRequestContextGetter> request_context_getter, network::mojom::NetworkContextRequest network_context_request) { content::BrowserThread::PostTask(
diff --git a/components/security_interstitials_strings_grdp/IDS_CAPTIVE_PORTAL_HEADING_WIRED.png.sha1 b/components/security_interstitials_strings_grdp/IDS_CAPTIVE_PORTAL_HEADING_WIRED.png.sha1 new file mode 100644 index 0000000..827b2a0 --- /dev/null +++ b/components/security_interstitials_strings_grdp/IDS_CAPTIVE_PORTAL_HEADING_WIRED.png.sha1
@@ -0,0 +1 @@ +378650e81625e476126a1a3d4b6ff559df54ef7c \ No newline at end of file
diff --git a/components/security_interstitials_strings_grdp/OWNERS b/components/security_interstitials_strings_grdp/OWNERS new file mode 100644 index 0000000..d94897a8 --- /dev/null +++ b/components/security_interstitials_strings_grdp/OWNERS
@@ -0,0 +1 @@ +file://components/security_interstitials/OWNERS
diff --git a/components/strings/components_strings_da.xtb b/components/strings/components_strings_da.xtb index 1f9c415..6e79739 100644 --- a/components/strings/components_strings_da.xtb +++ b/components/strings/components_strings_da.xtb
@@ -409,7 +409,7 @@ <translation id="3884278016824448484">Modstridende enheds-id</translation> <translation id="3885155851504623709">Sogn</translation> <translation id="3886446263141354045">Din anmodning om adgang til dette website er blevet sendt til <ph name="NAME" />.</translation> -<translation id="3890664840433101773">Tilføj e-mail</translation> +<translation id="3890664840433101773">Tilføj mail</translation> <translation id="3901925938762663762">Kortet er udløbet</translation> <translation id="3909695131102177774"><ph name="LABEL" /> <ph name="ERROR" /></translation> <translation id="3945915738023014686">Uploadet nedbruds-id <ph name="CRASH_ID" /> (lokalt nedbruds-id: <ph name="CRASH_LOCAL_ID" />)</translation>
diff --git a/components/strings/components_strings_sv.xtb b/components/strings/components_strings_sv.xtb index 3aef58875..b0c9be1 100644 --- a/components/strings/components_strings_sv.xtb +++ b/components/strings/components_strings_sv.xtb
@@ -728,7 +728,7 @@ <translation id="647261751007945333">Enhetspolicyer</translation> <translation id="6477321094435799029">Chrome har identifierat ovanlig kod på sidan och blockerat den för att skydda dina personliga uppgifter (som lösenord, telefonnummer och kreditkortsuppgifter).</translation> <translation id="6489534406876378309">Börja överföra information om krascher</translation> -<translation id="6499038740797743453">Vill du återställ lösenordet?</translation> +<translation id="6499038740797743453">Vill du återställa lösenordet?</translation> <translation id="6507833130742554667">Kreditkort och betalkort får användas.</translation> <translation id="6508722015517270189">Starta om Chrome</translation> <translation id="6529602333819889595">&Gör om Ta bort</translation>
diff --git a/components/strings/components_strings_te.xtb b/components/strings/components_strings_te.xtb index f356749..fdc47d5 100644 --- a/components/strings/components_strings_te.xtb +++ b/components/strings/components_strings_te.xtb
@@ -149,7 +149,7 @@ <translation id="2064691555167957331">{COUNT,plural, =1{1 సూచన}other{# సూచనలు}}</translation> <translation id="2079545284768500474">చర్య రద్దు</translation> <translation id="20817612488360358">సిస్టమ్ ప్రాక్సీ సెట్టింగ్లు ఉపయోగించడానికి సెట్ చేయబడ్డాయి కానీ స్పష్టమైన ప్రాక్సీ కాన్ఫిగరేషన్ కూడా పేర్కొనబడింది.</translation> -<translation id="2084558088529668945"><ph name="ORG_NAME" /> నిర్వహించని ఒక సైట్లో మీరు మీ పాస్వర్డ్ని నమోదు చేసారు. మీ ఖాతాని రక్షించాలంటే, ఇతర యాప్లు మరియు సైట్లలో మీ పాస్వర్డ్ని ఉపయోగించవద్దు.</translation> +<translation id="2084558088529668945"><ph name="ORG_NAME" /> నిర్వహించని ఒక సైట్లో మీరు మీ పాస్వర్డ్ని నమోదు చేసారు. మీ ఖాతాని రక్షించాలంటే, ఇతర యాప్లు మరియు సైట్లలో మీ పాస్వర్డ్ని తిరిగి ఉపయోగించవద్దు.</translation> <translation id="2091887806945687916">ధ్వని</translation> <translation id="2094505752054353250">డొమైన్ సరిపోలలేదు</translation> <translation id="2096368010154057602">శాఖ</translation>
diff --git a/components/strings/components_strings_th.xtb b/components/strings/components_strings_th.xtb index 10122f6e..8eb3cc5 100644 --- a/components/strings/components_strings_th.xtb +++ b/components/strings/components_strings_th.xtb
@@ -149,7 +149,7 @@ <translation id="2064691555167957331">{COUNT,plural, =1{1 คำแนะนำ}other{# คำแนะนำ}}</translation> <translation id="2079545284768500474">เลิกทำ</translation> <translation id="20817612488360358">มีการกำหนดให้ใช้การตั้งค่าพร็อกซีระบบ แต่ก็มีการระบุการกำหนดค่าพร็อกซีอย่างชัดเจนไว้ด้วยเช่นกัน</translation> -<translation id="2084558088529668945">คุณป้อนรหัสผ่านในเว็บไซต์ที่ <ph name="ORG_NAME" /> ไม่ได้จัดการ เพื่อปกป้องบัญชีของคุณ โปรดอย่าใช้รหัสผ่านซ้ำในแอปและเว็บไซต์อื่นๆ</translation> +<translation id="2084558088529668945">คุณป้อนรหัสผ่านในเว็บไซต์ที่ <ph name="ORG_NAME" /> ไม่ได้จัดการ เพื่อปกป้องบัญชี โปรดอย่าใช้รหัสผ่านซ้ำในแอปและเว็บไซต์อื่นๆ</translation> <translation id="2091887806945687916">เสียง</translation> <translation id="2094505752054353250">โดเมนไม่ตรง</translation> <translation id="2096368010154057602">จังหวัด</translation>
diff --git a/components/url_formatter/url_fixer_unittest.cc b/components/url_formatter/url_fixer_unittest.cc index 79d641d..e946f23 100644 --- a/components/url_formatter/url_fixer_unittest.cc +++ b/components/url_formatter/url_fixer_unittest.cc
@@ -248,64 +248,64 @@ const std::string input; const std::string output; } fixup_cases[] = { - {"www.google.com", "http://www.google.com/"}, - {" www.google.com ", "http://www.google.com/"}, - {" foo.com/asdf bar", "http://foo.com/asdf%20%20bar"}, - {"..www.google.com..", "http://www.google.com./"}, - {"http://......", "http://....../"}, - {"http://host.com:ninety-two/", "http://host.com:ninety-two/"}, - {"http://host.com:ninety-two?foo", "http://host.com:ninety-two/?foo"}, - {"google.com:123", "http://google.com:123/"}, - {"about:", "chrome://version/"}, - {"about:foo", "chrome://foo/"}, - {"about:version", "chrome://version/"}, - {"about:blank", "about:blank"}, - {"about:usr:pwd@hst/pth?qry#ref", "chrome://usr:pwd@hst/pth?qry#ref"}, - {"about://usr:pwd@hst/pth?qry#ref", "chrome://usr:pwd@hst/pth?qry#ref"}, - {"chrome:usr:pwd@hst/pth?qry#ref", "chrome://usr:pwd@hst/pth?qry#ref"}, - {"chrome://usr:pwd@hst/pth?qry#ref", "chrome://usr:pwd@hst/pth?qry#ref"}, - {"www:123", "http://www:123/"}, - {" www:123", "http://www:123/"}, - {"www.google.com?foo", "http://www.google.com/?foo"}, - {"www.google.com#foo", "http://www.google.com/#foo"}, - {"www.google.com?", "http://www.google.com/?"}, - {"www.google.com#", "http://www.google.com/#"}, - {"www.google.com:123?foo#bar", "http://www.google.com:123/?foo#bar"}, - {"user@www.google.com", "http://user@www.google.com/"}, - {"\xE6\xB0\xB4.com", "http://xn--1rw.com/"}, - // It would be better if this next case got treated as http, but I don't see - // a clean way to guess this isn't the new-and-exciting "user" scheme. - {"user:passwd@www.google.com:8080/", "user:passwd@www.google.com:8080/"}, - // {"file:///c:/foo/bar%20baz.txt", "file:///C:/foo/bar%20baz.txt"}, - // URLs which end with 0x85 (NEL in ISO-8859). - {"http://foo.com/s?q=\xd0\x85", "http://foo.com/s?q=%D0%85"}, - {"http://foo.com/s?q=\xec\x97\x85", "http://foo.com/s?q=%EC%97%85"}, - {"http://foo.com/s?q=\xf0\x90\x80\x85", "http://foo.com/s?q=%F0%90%80%85"}, - // URLs which end with 0xA0 (non-break space in ISO-8859). - {"http://foo.com/s?q=\xd0\xa0", "http://foo.com/s?q=%D0%A0"}, - {"http://foo.com/s?q=\xec\x97\xa0", "http://foo.com/s?q=%EC%97%A0"}, - {"http://foo.com/s?q=\xf0\x90\x80\xa0", "http://foo.com/s?q=%F0%90%80%A0"}, - // URLs containing IPv6 literals. - {"[2001:db8::2]", "http://[2001:db8::2]/"}, - {"[::]:80", "http://[::]/"}, - {"[::]:80/path", "http://[::]/path"}, - {"[::]:180/path", "http://[::]:180/path"}, - // TODO(pmarks): Maybe we should parse bare IPv6 literals someday. Currently - // the first colon is treated as a scheme separator, and we default - // unspecified schemes to "http". - {"::1", "http://:1/"}, - // Semicolon as scheme separator for standard schemes. - {"http;//www.google.com/", "http://www.google.com/"}, - {"about;chrome", "chrome://chrome/"}, - // Semicolon in non-standard schemes is not replaced by colon. - {"whatsup;//fool", "http://whatsup%3B//fool"}, - // Semicolon left as-is in URL itself. - {"http://host/port?query;moar", "http://host/port?query;moar"}, - // Fewer slashes than expected. - {"http;www.google.com/", "http://www.google.com/"}, - {"http;/www.google.com/", "http://www.google.com/"}, - // Semicolon at start. - {";http://www.google.com/", "http://%3Bhttp//www.google.com/"}, + {"www.google.com", "http://www.google.com/"}, + {" www.google.com ", "http://www.google.com/"}, + {" foo.com/asdf bar", "http://foo.com/asdf%20%20bar"}, + {"..www.google.com..", "http://www.google.com./"}, + {"http://......", "http://....../"}, + {"http://host.com:ninety-two/", "http://host.com:ninety-two/"}, + {"http://host.com:ninety-two?foo", "http://host.com:ninety-two/?foo"}, + {"google.com:123", "http://google.com:123/"}, + {"about:", "chrome://version/"}, + {"about:foo", "chrome://foo/"}, + {"about:version", "chrome://version/"}, + {"about:blank", "about:blank"}, + {"about:usr:pwd@hst:20/pth?qry#ref", "chrome://hst/pth?qry#ref"}, + {"about://usr:pwd@hst/pth?qry#ref", "chrome://hst/pth?qry#ref"}, + {"chrome:usr:pwd@hst/pth?qry#ref", "chrome://hst/pth?qry#ref"}, + {"chrome://usr:pwd@hst/pth?qry#ref", "chrome://hst/pth?qry#ref"}, + {"www:123", "http://www:123/"}, + {" www:123", "http://www:123/"}, + {"www.google.com?foo", "http://www.google.com/?foo"}, + {"www.google.com#foo", "http://www.google.com/#foo"}, + {"www.google.com?", "http://www.google.com/?"}, + {"www.google.com#", "http://www.google.com/#"}, + {"www.google.com:123?foo#bar", "http://www.google.com:123/?foo#bar"}, + {"user@www.google.com", "http://user@www.google.com/"}, + {"\xE6\xB0\xB4.com", "http://xn--1rw.com/"}, + // It would be better if this next case got treated as http, but I don't see + // a clean way to guess this isn't the new-and-exciting "user" scheme. + {"user:passwd@www.google.com:8080/", "user:passwd@www.google.com:8080/"}, + // {"file:///c:/foo/bar%20baz.txt", "file:///C:/foo/bar%20baz.txt"}, + // URLs which end with 0x85 (NEL in ISO-8859). + {"http://foo.com/s?q=\xd0\x85", "http://foo.com/s?q=%D0%85"}, + {"http://foo.com/s?q=\xec\x97\x85", "http://foo.com/s?q=%EC%97%85"}, + {"http://foo.com/s?q=\xf0\x90\x80\x85", "http://foo.com/s?q=%F0%90%80%85"}, + // URLs which end with 0xA0 (non-break space in ISO-8859). + {"http://foo.com/s?q=\xd0\xa0", "http://foo.com/s?q=%D0%A0"}, + {"http://foo.com/s?q=\xec\x97\xa0", "http://foo.com/s?q=%EC%97%A0"}, + {"http://foo.com/s?q=\xf0\x90\x80\xa0", "http://foo.com/s?q=%F0%90%80%A0"}, + // URLs containing IPv6 literals. + {"[2001:db8::2]", "http://[2001:db8::2]/"}, + {"[::]:80", "http://[::]/"}, + {"[::]:80/path", "http://[::]/path"}, + {"[::]:180/path", "http://[::]:180/path"}, + // TODO(pmarks): Maybe we should parse bare IPv6 literals someday. Currently + // the first colon is treated as a scheme separator, and we default + // unspecified schemes to "http". + {"::1", "http://:1/"}, + // Semicolon as scheme separator for standard schemes. + {"http;//www.google.com/", "http://www.google.com/"}, + {"about;chrome", "chrome://chrome/"}, + // Semicolon in non-standard schemes is not replaced by colon. + {"whatsup;//fool", "http://whatsup%3B//fool"}, + // Semicolon left as-is in URL itself. + {"http://host/port?query;moar", "http://host/port?query;moar"}, + // Fewer slashes than expected. + {"http;www.google.com/", "http://www.google.com/"}, + {"http;/www.google.com/", "http://www.google.com/"}, + // Semicolon at start. + {";http://www.google.com/", "http://%3Bhttp//www.google.com/"}, }; TEST(URLFixerTest, FixupURL) {
diff --git a/components/viz/host/host_frame_sink_manager.cc b/components/viz/host/host_frame_sink_manager.cc index 8a9377f..2fc6141 100644 --- a/components/viz/host/host_frame_sink_manager.cc +++ b/components/viz/host/host_frame_sink_manager.cc
@@ -249,9 +249,9 @@ } void HostFrameSinkManager::RequestCopyOfOutput( - const FrameSinkId& frame_sink_id, + const SurfaceId& surface_id, std::unique_ptr<CopyOutputRequest> request) { - frame_sink_manager_->RequestCopyOfOutput(frame_sink_id, std::move(request)); + frame_sink_manager_->RequestCopyOfOutput(surface_id, std::move(request)); } std::unique_ptr<CompositorFrameSinkSupport>
diff --git a/components/viz/host/host_frame_sink_manager.h b/components/viz/host/host_frame_sink_manager.h index 86184f0a..43257ce4d 100644 --- a/components/viz/host/host_frame_sink_manager.h +++ b/components/viz/host/host_frame_sink_manager.h
@@ -137,10 +137,13 @@ // Marks the given SurfaceIds for destruction. void EvictSurfaces(const std::vector<SurfaceId>& surface_ids); - // Takes a snapshot of |frame_sink_id|. Next time a display frame is - // generated, the snapshot will be taken from the Surface belonging to - // |frame_sink_id| that is reachable from the root Surface. - void RequestCopyOfOutput(const FrameSinkId& frame_sink_id, + // Takes snapshot of a |surface_id| or a newer surface with the same + // FrameSinkId. The FrameSinkId is used to identify which frame we're + // interested in. The snapshot will only be taken if the LocalSurfaceId is at + // least the given LocalSurfaceId (|surface_id.local_frame_id()|). If the + // LocalSurfaceId is lower than the given id, then the request is queued up to + // be executed later. + void RequestCopyOfOutput(const SurfaceId& surface_id, std::unique_ptr<CopyOutputRequest> request); // CompositorFrameSinkSupportManager:
diff --git a/components/viz/service/display/display.cc b/components/viz/service/display/display.cc index 8082d08f..7394bb8 100644 --- a/components/viz/service/display/display.cc +++ b/components/viz/service/display/display.cc
@@ -595,7 +595,7 @@ if (!pass->filters.IsEmpty() || !pass->background_filters.IsEmpty()) { for (auto* const quad : pass->quad_list) { total_quad_area_shown_wo_occlusion_px += - quad->visible_rect.height() * quad->visible_rect.width(); + quad->visible_rect.size().GetCheckedArea(); } continue; } @@ -605,7 +605,7 @@ if (pass != frame->render_pass_list.back()) { for (auto* const quad : pass->quad_list) { total_quad_area_shown_wo_occlusion_px += - quad->visible_rect.height() * quad->visible_rect.width(); + quad->visible_rect.size().GetCheckedArea(); } continue; } @@ -614,7 +614,7 @@ gfx::Rect occlusion_in_quad_content_space; for (auto quad = pass->quad_list.begin(); quad != quad_list_end;) { total_quad_area_shown_wo_occlusion_px += - quad->visible_rect.height() * quad->visible_rect.width(); + quad->visible_rect.size().GetCheckedArea(); // Skip quad if it is a RenderPassDrawQuad because RenderPassDrawQuad is a // special type of DrawQuad where the visible_rect of shared quad state is @@ -693,8 +693,7 @@ // Case 1: for simple transforms (scale or translation), define the // occlusion region in the quad content space. If the |quad| is not // shown on the screen, then remove |quad| from the compositor frame. - total_area_saved_in_px += - quad->visible_rect.height() * quad->visible_rect.width(); + total_area_saved_in_px += quad->visible_rect.size().GetCheckedArea(); quad = pass->quad_list.EraseAndInvalidateAllPointers(quad); } else if (occlusion_in_quad_content_space.Intersects( @@ -706,7 +705,7 @@ quad->visible_rect.Subtract(occlusion_in_quad_content_space); if (origin_rect != quad->visible_rect) { origin_rect.Subtract(quad->visible_rect); - total_area_saved_in_px += origin_rect.height() * origin_rect.width(); + total_area_saved_in_px += origin_rect.size().GetCheckedArea(); } ++quad; } else if (occlusion_in_quad_content_space.IsEmpty() && @@ -716,14 +715,14 @@ // Case 3: for non simple transforms, define the occlusion region in // target space. If the |quad| is not shown on the screen, then remove // |quad| from the compositor frame. - total_area_saved_in_px += - quad->visible_rect.height() * quad->visible_rect.width(); + total_area_saved_in_px += quad->visible_rect.size().GetCheckedArea(); quad = pass->quad_list.EraseAndInvalidateAllPointers(quad); } else { ++quad; } } } + UMA_HISTOGRAM_PERCENTAGE( "Compositing.Display.Draw.Occlusion.Percentage.Saved", total_quad_area_shown_wo_occlusion_px.ValueOrDefault(0) == 0
diff --git a/components/viz/service/display/display_unittest.cc b/components/viz/service/display/display_unittest.cc index 3ddc03a..37ebe45c 100644 --- a/components/viz/service/display/display_unittest.cc +++ b/components/viz/service/display/display_unittest.cc
@@ -3101,9 +3101,9 @@ display_->Initialize(&client, manager_.surface_manager()); CompositorFrame frame = MakeDefaultCompositorFrame(); - // The size of this DrawQuad will be 19770x97790 > 2^32 (uint32_t.max()) + // The size of this DrawQuad will be 237790x237790 > 2^32 (uint32_t.max()) // which caused the integer overflow in the bug. - gfx::Rect rect1(197790, 97790); + gfx::Rect rect1(237790, 237790); bool is_clipped = false; bool are_contents_opaque = true;
diff --git a/components/viz/service/display/gl_renderer.cc b/components/viz/service/display/gl_renderer.cc index 386aa365..babb3a72 100644 --- a/components/viz/service/display/gl_renderer.cc +++ b/components/viz/service/display/gl_renderer.cc
@@ -1949,15 +1949,18 @@ !quad->IsRightEdge() || texture_size.width() == tex_coord_rect.right(); bool fills_bottom_edge = !quad->IsBottomEdge() || texture_size.height() == tex_coord_rect.bottom(); - bool has_tex_clamp_rect = - filter == GL_LINEAR && (!fills_right_edge || !fills_bottom_edge); + bool has_tex_clamp_rect = true; gfx::SizeF tex_clamp_size(texture_size); // Clamp from the original tex coord rect, instead of the one that has - // been adjusted by the visible rect. - if (!fills_right_edge) - tex_clamp_size.set_width(quad->tex_coord_rect.right() - 0.5f); - if (!fills_bottom_edge) - tex_clamp_size.set_height(quad->tex_coord_rect.bottom() - 0.5f); + // been adjusted by the visible rect. Nearest neighbor should never be + // clamped. However, still specify a tex clamp rect so that we don't + // thrash shaders. + if (filter == GL_LINEAR) { + if (!fills_right_edge) + tex_clamp_size.set_width(quad->tex_coord_rect.right() - 0.5f); + if (!fills_bottom_edge) + tex_clamp_size.set_height(quad->tex_coord_rect.bottom() - 0.5f); + } // Map to normalized texture coordinates. if (sampler != SAMPLER_TYPE_2D_RECT) {
diff --git a/components/viz/service/display/surface_aggregator_unittest.cc b/components/viz/service/display/surface_aggregator_unittest.cc index a5f477a..d25d511 100644 --- a/components/viz/service/display/surface_aggregator_unittest.cc +++ b/components/viz/service/display/surface_aggregator_unittest.cc
@@ -1187,7 +1187,8 @@ device_scale_factor); auto copy_request = CopyOutputRequest::CreateStubForTesting(); auto* copy_request_ptr = copy_request.get(); - embedded_support->RequestCopyOfOutput(std::move(copy_request)); + embedded_support->RequestCopyOfOutput(embedded_local_surface_id, + std::move(copy_request)); Quad root_quads[] = { Quad::SolidColorQuad(SK_ColorWHITE, gfx::Rect(5, 5)), @@ -1333,7 +1334,8 @@ device_scale_factor); auto copy_request(CopyOutputRequest::CreateStubForTesting()); auto* copy_request_ptr = copy_request.get(); - embedded_support->RequestCopyOfOutput(std::move(copy_request)); + embedded_support->RequestCopyOfOutput(embedded_local_surface_id, + std::move(copy_request)); LocalSurfaceId parent_local_surface_id = allocator_.GenerateId(); SurfaceId parent_surface_id(parent_support->frame_sink_id(),
diff --git a/components/viz/service/frame_sinks/compositor_frame_sink_support.cc b/components/viz/service/frame_sinks/compositor_frame_sink_support.cc index 906ffbe..f7d539a3 100644 --- a/components/viz/service/frame_sinks/compositor_frame_sink_support.cc +++ b/components/viz/service/frame_sinks/compositor_frame_sink_support.cc
@@ -160,13 +160,22 @@ surface_resource_holder_.ReceiveFromChild(resources); } -bool CompositorFrameSinkSupport::HasCopyOutputRequests() { - return !copy_output_requests_.empty(); -} - std::vector<std::unique_ptr<CopyOutputRequest>> -CompositorFrameSinkSupport::TakeCopyOutputRequests() { - return std::move(copy_output_requests_); +CompositorFrameSinkSupport::TakeCopyOutputRequests( + const LocalSurfaceId& latest_local_id) { + std::vector<std::unique_ptr<CopyOutputRequest>> results; + for (auto it = copy_output_requests_.begin(); + it != copy_output_requests_.end();) { + // Requests with a non-valid local id should be satisfied as soon as + // possible. + if (!it->first.is_valid() || it->first <= latest_local_id) { + results.push_back(std::move(it->second)); + it = copy_output_requests_.erase(it); + } else { + ++it; + } + } + return results; } void CompositorFrameSinkSupport::EvictLastActivatedSurface() { @@ -500,13 +509,15 @@ } void CompositorFrameSinkSupport::RequestCopyOfOutput( + const LocalSurfaceId& local_surface_id, std::unique_ptr<CopyOutputRequest> copy_request) { - if (!last_activated_surface_id_.is_valid()) - return; - copy_output_requests_.push_back(std::move(copy_request)); - BeginFrameAck ack; - ack.has_damage = true; - surface_manager_->SurfaceModified(last_activated_surface_id_, ack); + copy_output_requests_.push_back( + std::make_pair(local_surface_id, std::move(copy_request))); + if (last_activated_surface_id_.is_valid()) { + BeginFrameAck ack; + ack.has_damage = true; + surface_manager_->SurfaceModified(last_activated_surface_id_, ack); + } } HitTestAggregator* CompositorFrameSinkSupport::GetHitTestAggregator() {
diff --git a/components/viz/service/frame_sinks/compositor_frame_sink_support.h b/components/viz/service/frame_sinks/compositor_frame_sink_support.h index ff35305..b65e0e7 100644 --- a/components/viz/service/frame_sinks/compositor_frame_sink_support.h +++ b/components/viz/service/frame_sinks/compositor_frame_sink_support.h
@@ -97,9 +97,10 @@ void ReturnResources(const std::vector<ReturnedResource>& resources) override; void ReceiveFromChild( const std::vector<TransferableResource>& resources) override; - bool HasCopyOutputRequests() override; - std::vector<std::unique_ptr<CopyOutputRequest>> TakeCopyOutputRequests() - override; + // Takes the CopyOutputRequests that were requested for a surface with at + // most |local_surface_id|. + std::vector<std::unique_ptr<CopyOutputRequest>> TakeCopyOutputRequests( + const LocalSurfaceId& local_surface_id) override; // mojom::CompositorFrameSink helpers. void SetNeedsBeginFrame(bool needs_begin_frame); @@ -134,7 +135,8 @@ void AttachCaptureClient(CapturableFrameSink::Client* client) override; void DetachCaptureClient(CapturableFrameSink::Client* client) override; gfx::Size GetActiveFrameSize() override; - void RequestCopyOfOutput(std::unique_ptr<CopyOutputRequest> request) override; + void RequestCopyOfOutput(const LocalSurfaceId& local_surface_id, + std::unique_ptr<CopyOutputRequest> request) override; HitTestAggregator* GetHitTestAggregator(); @@ -251,8 +253,14 @@ // These are the CopyOutputRequests made on the frame sink (as opposed to // being included as a part of a CompositorFrame). They stay here until a - // Surface takes them. - std::vector<std::unique_ptr<CopyOutputRequest>> copy_output_requests_; + // Surface with a LocalSurfaceId which is at least the stored LocalSurfaceId + // takes them. For example, if we store a pair of LocalSurfaceId stored_id and + // a CopyOutputRequest, then a surface with LocalSurfaceId >= stored_id will + // take it, but a surface with LocalSurfaceId < stored_id will not. Note that + // if stored_id is default initialized, then the next surface will take it + // regardless of its LocalSurfaceId. + std::vector<std::pair<LocalSurfaceId, std::unique_ptr<CopyOutputRequest>>> + copy_output_requests_; base::WeakPtrFactory<CompositorFrameSinkSupport> weak_factory_;
diff --git a/components/viz/service/frame_sinks/compositor_frame_sink_support_unittest.cc b/components/viz/service/frame_sinks/compositor_frame_sink_support_unittest.cc index 361e524..59ce707 100644 --- a/components/viz/service/frame_sinks/compositor_frame_sink_support_unittest.cc +++ b/components/viz/service/frame_sinks/compositor_frame_sink_support_unittest.cc
@@ -713,7 +713,7 @@ base::BindOnce(&CopyRequestTestCallback, &called1)); request->set_source(kArbitrarySourceId1); - support_->RequestCopyOfOutput(std::move(request)); + support_->RequestCopyOfOutput(local_surface_id_, std::move(request)); GetSurfaceForId(surface_id)->TakeCopyOutputRequestsFromClient(); EXPECT_FALSE(called1); @@ -723,7 +723,7 @@ base::BindOnce(&CopyRequestTestCallback, &called2)); request->set_source(kArbitrarySourceId2); - support_->RequestCopyOfOutput(std::move(request)); + support_->RequestCopyOfOutput(local_surface_id_, std::move(request)); GetSurfaceForId(surface_id)->TakeCopyOutputRequestsFromClient(); // Callbacks have different sources so neither should be called. EXPECT_FALSE(called1); @@ -735,7 +735,7 @@ base::BindOnce(&CopyRequestTestCallback, &called3)); request->set_source(kArbitrarySourceId1); - support_->RequestCopyOfOutput(std::move(request)); + support_->RequestCopyOfOutput(local_surface_id_, std::move(request)); GetSurfaceForId(surface_id)->TakeCopyOutputRequestsFromClient(); // Two callbacks are from source1, so the first should be called. EXPECT_TRUE(called1); @@ -906,11 +906,7 @@ auto request = std::make_unique<CopyOutputRequest>( CopyOutputRequest::ResultFormat::RGBA_BITMAP, base::BindOnce(StubResultCallback)); - support_->RequestCopyOfOutput(std::move(request)); - - // Both surfaces should report that they have a CopyOutputRequest. - EXPECT_TRUE(GetSurfaceForId(id1)->HasCopyOutputRequests()); - EXPECT_TRUE(GetSurfaceForId(id2)->HasCopyOutputRequests()); + support_->RequestCopyOfOutput(local_surface_id1, std::move(request)); // First surface takes CopyOutputRequests from its client. Now only the first // surface should report having CopyOutputRequests. @@ -933,6 +929,47 @@ EXPECT_FALSE(requests_map.empty()); } +TEST_F(CompositorFrameSinkSupportTest, + OldSurfaceDoesNotTakeCopyOutputRequestsFromNewLocalId) { + LocalSurfaceId local_surface_id1(1, kArbitraryToken); + LocalSurfaceId local_surface_id2(2, kArbitraryToken); + SurfaceId id1(support_->frame_sink_id(), local_surface_id1); + SurfaceId id2(support_->frame_sink_id(), local_surface_id2); + + // Create the first surface. + support_->SubmitCompositorFrame(local_surface_id1, + MakeDefaultCompositorFrame()); + + // Create the second surface. + support_->SubmitCompositorFrame(local_surface_id2, + MakeDefaultCompositorFrame()); + + // Send a CopyOutputRequest. + auto request = std::make_unique<CopyOutputRequest>( + CopyOutputRequest::ResultFormat::RGBA_BITMAP, + base::BindOnce(StubResultCallback)); + support_->RequestCopyOfOutput(local_surface_id2, std::move(request)); + + // The first surface doesn't have copy output requests, because it can't + // satisfy the request that the client has. + GetSurfaceForId(id1)->TakeCopyOutputRequestsFromClient(); + EXPECT_FALSE(GetSurfaceForId(id1)->HasCopyOutputRequests()); + EXPECT_FALSE(GetSurfaceForId(id2)->HasCopyOutputRequests()); + + // Second surface should succeed at taking the requests. + GetSurfaceForId(id2)->TakeCopyOutputRequestsFromClient(); + EXPECT_FALSE(GetSurfaceForId(id1)->HasCopyOutputRequests()); + EXPECT_TRUE(GetSurfaceForId(id2)->HasCopyOutputRequests()); + + // Do TakeCopyOutputRequests, to see if its output is consistent with + // HasCopyOutputRequests. + Surface::CopyRequestsMap requests_map; + GetSurfaceForId(id1)->TakeCopyOutputRequests(&requests_map); + EXPECT_TRUE(requests_map.empty()); + GetSurfaceForId(id2)->TakeCopyOutputRequests(&requests_map); + EXPECT_FALSE(requests_map.empty()); +} + // Verifies that CopyOutputRequests made at frame sink level are sent to the // surface that takes them first. In this test this surface is the last // activated surface. @@ -952,16 +989,12 @@ auto request = std::make_unique<CopyOutputRequest>( CopyOutputRequest::ResultFormat::RGBA_BITMAP, base::BindOnce(StubResultCallback)); - support_->RequestCopyOfOutput(std::move(request)); + support_->RequestCopyOfOutput(local_surface_id1, std::move(request)); // Create the second surface. support_->SubmitCompositorFrame(local_surface_id2, MakeDefaultCompositorFrame()); - // Both surfaces should report that they have a CopyOutputRequest. - EXPECT_TRUE(GetSurfaceForId(id1)->HasCopyOutputRequests()); - EXPECT_TRUE(GetSurfaceForId(id2)->HasCopyOutputRequests()); - // Second surface takes CopyOutputRequests from its client. Now only the // second surface should report having CopyOutputRequests. GetSurfaceForId(id2)->TakeCopyOutputRequestsFromClient();
diff --git a/components/viz/service/frame_sinks/frame_sink_manager_impl.cc b/components/viz/service/frame_sinks/frame_sink_manager_impl.cc index 3732616..fb74b41 100644 --- a/components/viz/service/frame_sinks/frame_sink_manager_impl.cc +++ b/components/viz/service/frame_sinks/frame_sink_manager_impl.cc
@@ -287,14 +287,15 @@ } void FrameSinkManagerImpl::RequestCopyOfOutput( - const FrameSinkId& frame_sink_id, + const SurfaceId& surface_id, std::unique_ptr<CopyOutputRequest> request) { - auto it = support_map_.find(frame_sink_id); + auto it = support_map_.find(surface_id.frame_sink_id()); if (it == support_map_.end()) { // |request| will send an empty result when it goes out of scope. return; } - it->second->RequestCopyOfOutput(std::move(request)); + it->second->RequestCopyOfOutput(surface_id.local_surface_id(), + std::move(request)); } void FrameSinkManagerImpl::OnSurfaceCreated(const SurfaceId& surface_id) {
diff --git a/components/viz/service/frame_sinks/frame_sink_manager_impl.h b/components/viz/service/frame_sinks/frame_sink_manager_impl.h index f721bdc..4c086c7d 100644 --- a/components/viz/service/frame_sinks/frame_sink_manager_impl.h +++ b/components/viz/service/frame_sinks/frame_sink_manager_impl.h
@@ -94,7 +94,7 @@ void CreateVideoCapturer( mojom::FrameSinkVideoCapturerRequest request) override; void EvictSurfaces(const std::vector<SurfaceId>& surface_ids) override; - void RequestCopyOfOutput(const FrameSinkId& frame_sink_id, + void RequestCopyOfOutput(const SurfaceId& surface_id, std::unique_ptr<CopyOutputRequest> request) override; // SurfaceObserver implementation.
diff --git a/components/viz/service/frame_sinks/video_capture/capturable_frame_sink.h b/components/viz/service/frame_sinks/video_capture/capturable_frame_sink.h index 806133f8..908d275 100644 --- a/components/viz/service/frame_sinks/video_capture/capturable_frame_sink.h +++ b/components/viz/service/frame_sinks/video_capture/capturable_frame_sink.h
@@ -17,6 +17,7 @@ namespace viz { class CopyOutputRequest; +class LocalSurfaceId; // Interface for CompositorFrameSink implementations that support frame sink // video capture. @@ -51,8 +52,12 @@ // active frame. virtual gfx::Size GetActiveFrameSize() = 0; - // Issues a request for a copy of the next composited frame. + // Issues a request for a copy of the next composited frame whose + // LocalSurfaceId is at least |local_surface_id|. Note that if this id is + // default constructed, then the next surface will provide the copy output + // regardless of its LocalSurfaceId. virtual void RequestCopyOfOutput( + const LocalSurfaceId& local_surface_id, std::unique_ptr<CopyOutputRequest> request) = 0; };
diff --git a/components/viz/service/frame_sinks/video_capture/frame_sink_video_capturer_impl.cc b/components/viz/service/frame_sinks/video_capture/frame_sink_video_capturer_impl.cc index 1aaac05b..dadd464 100644 --- a/components/viz/service/frame_sinks/video_capture/frame_sink_video_capturer_impl.cc +++ b/components/viz/service/frame_sinks/video_capture/frame_sink_video_capturer_impl.cc
@@ -14,6 +14,7 @@ #include "base/trace_event/trace_event.h" #include "components/viz/common/frame_sinks/copy_output_request.h" #include "components/viz/common/frame_sinks/copy_output_result.h" +#include "components/viz/common/surfaces/local_surface_id.h" #include "components/viz/service/frame_sinks/video_capture/frame_sink_video_capturer_manager.h" #include "media/base/limits.h" #include "media/base/video_util.h" @@ -492,7 +493,7 @@ // damage over all the frames that weren't captured. request->set_result_selection(gfx::Rect(content_rect.size())); dirty_rect_ = gfx::Rect(); - resolved_target_->RequestCopyOfOutput(std::move(request)); + resolved_target_->RequestCopyOfOutput(LocalSurfaceId(), std::move(request)); } void FrameSinkVideoCapturerImpl::DidCopyFrame(
diff --git a/components/viz/service/frame_sinks/video_capture/frame_sink_video_capturer_impl_unittest.cc b/components/viz/service/frame_sinks/video_capture/frame_sink_video_capturer_impl_unittest.cc index 27bd0aa5..98529e7 100644 --- a/components/viz/service/frame_sinks/video_capture/frame_sink_video_capturer_impl_unittest.cc +++ b/components/viz/service/frame_sinks/video_capture/frame_sink_video_capturer_impl_unittest.cc
@@ -199,6 +199,7 @@ gfx::Size GetActiveFrameSize() override { return kSourceSize; } void RequestCopyOfOutput( + const LocalSurfaceId& local_surface_id, std::unique_ptr<CopyOutputRequest> request) override { EXPECT_EQ(CopyOutputResult::Format::I420_PLANES, request->result_format()); EXPECT_NE(base::UnguessableToken(), request->source());
diff --git a/components/viz/service/surfaces/surface.cc b/components/viz/service/surfaces/surface.cc index ecf8cd2..20355b4 100644 --- a/components/viz/service/surfaces/surface.cc +++ b/components/viz/service/surfaces/surface.cc
@@ -426,9 +426,6 @@ if (!active_frame_data_) return; - // TakeCopyOutputRequestsFromClient() has to be called before this method. - DCHECK(!surface_client_ || !surface_client_->HasCopyOutputRequests()); - for (const auto& render_pass : active_frame_data_->frame.render_pass_list) { for (auto& request : render_pass->copy_requests) { copy_requests->insert( @@ -442,7 +439,8 @@ if (!surface_client_) return; for (std::unique_ptr<CopyOutputRequest>& request : - surface_client_->TakeCopyOutputRequests()) { + surface_client_->TakeCopyOutputRequests( + surface_id().local_surface_id())) { RequestCopyOfOutput(std::move(request)); } } @@ -450,8 +448,6 @@ bool Surface::HasCopyOutputRequests() { if (!active_frame_data_) return false; - if (surface_client_ && surface_client_->HasCopyOutputRequests()) - return true; for (const auto& render_pass : active_frame_data_->frame.render_pass_list) { if (!render_pass->copy_requests.empty()) return true;
diff --git a/components/viz/service/surfaces/surface_client.h b/components/viz/service/surfaces/surface_client.h index 8d26045..445f860 100644 --- a/components/viz/service/surfaces/surface_client.h +++ b/components/viz/service/surfaces/surface_client.h
@@ -46,12 +46,10 @@ virtual void ReceiveFromChild( const std::vector<TransferableResource>& resources) = 0; - // Returns whether there are any CopyOutputRequests at the client level. - virtual bool HasCopyOutputRequests() = 0; - - // Takes all the CopyOutputRequests made at the client level. + // Takes all the CopyOutputRequests made at the client level that happened for + // a LocalSurfaceId preceeding the given one. virtual std::vector<std::unique_ptr<CopyOutputRequest>> - TakeCopyOutputRequests() = 0; + TakeCopyOutputRequests(const LocalSurfaceId& latest_surface_id) = 0; private: DISALLOW_COPY_AND_ASSIGN(SurfaceClient);
diff --git a/components/viz/service/surfaces/surface_unittest.cc b/components/viz/service/surfaces/surface_unittest.cc index 2cdc3b5..819039b6 100644 --- a/components/viz/service/surfaces/surface_unittest.cc +++ b/components/viz/service/surfaces/surface_unittest.cc
@@ -91,9 +91,11 @@ ASSERT_TRUE(!!surface); bool copy_called = false; - support->RequestCopyOfOutput(std::make_unique<CopyOutputRequest>( - CopyOutputRequest::ResultFormat::RGBA_BITMAP, - base::BindOnce(&TestCopyResultCallback, ©_called))); + support->RequestCopyOfOutput( + local_surface_id, + std::make_unique<CopyOutputRequest>( + CopyOutputRequest::ResultFormat::RGBA_BITMAP, + base::BindOnce(&TestCopyResultCallback, ©_called))); surface->TakeCopyOutputRequestsFromClient(); EXPECT_TRUE(surface_manager->GetSurfaceForId(surface_id)); EXPECT_FALSE(copy_called);
diff --git a/components/viz/test/test_frame_sink_manager.h b/components/viz/test/test_frame_sink_manager.h index 2c646eb5..422bebb 100644 --- a/components/viz/test/test_frame_sink_manager.h +++ b/components/viz/test/test_frame_sink_manager.h
@@ -52,7 +52,7 @@ mojom::FrameSinkVideoCapturerRequest request) override {} void EvictSurfaces(const std::vector<SurfaceId>& surface_ids) override {} void RequestCopyOfOutput( - const FrameSinkId& frame_sink_id, + const SurfaceId& surface_id, std::unique_ptr<CopyOutputRequest> request) override {} mojo::Binding<mojom::FrameSinkManager> binding_;
diff --git a/components/viz/test/test_layer_tree_frame_sink.cc b/components/viz/test/test_layer_tree_frame_sink.cc index 5035854e..7442b9f 100644 --- a/components/viz/test/test_layer_tree_frame_sink.cc +++ b/components/viz/test/test_layer_tree_frame_sink.cc
@@ -174,8 +174,20 @@ support_->SubmitCompositorFrame(local_surface_id_, std::move(frame)); - for (auto& copy_request : copy_requests_) - support_->RequestCopyOfOutput(std::move(copy_request)); + // TODO(vmpstr): In layout tests, we request this call. However, with site + // isolation we don't get an activation yet. Previously the call to the + // support would delete the request resulting in an empty bitmap being + // returned to the caller. However, with recent changes in preparation for + // properly capturing pixel dumps from site isolation layout tests, it now + // stashes the request in the pending queue and waits for an activation. Since + // this never happens, the tests time out instead of failing. It's important + // for us to not mark some of these tests as timing out, since we need to + // ensure that they don't time out for reasons unrelated to pixel dumps. + // https://crbug.com/667551 tracks the progress of fixing this. + if (support_->last_activated_surface_id().is_valid()) { + for (auto& copy_request : copy_requests_) + support_->RequestCopyOfOutput(local_surface_id_, std::move(copy_request)); + } copy_requests_.clear(); if (!display_->has_scheduler()) {
diff --git a/content/browser/BUILD.gn b/content/browser/BUILD.gn index e63b8dda..efe7dff 100644 --- a/content/browser/BUILD.gn +++ b/content/browser/BUILD.gn
@@ -695,10 +695,6 @@ "download/byte_stream_input_stream.cc", "download/byte_stream_input_stream.h", "download/download_item_factory.h", - "download/download_item_impl.cc", - "download/download_item_impl.h", - "download/download_item_impl_delegate.cc", - "download/download_item_impl_delegate.h", "download/download_item_utils.cc", "download/download_manager_impl.cc", "download/download_manager_impl.h",
diff --git a/content/browser/blob_storage/chrome_blob_storage_context.cc b/content/browser/blob_storage/chrome_blob_storage_context.cc index 387ea1e..0b5780d 100644 --- a/content/browser/blob_storage/chrome_blob_storage_context.cc +++ b/content/browser/blob_storage/chrome_blob_storage_context.cc
@@ -19,6 +19,7 @@ #include "base/task_runner.h" #include "base/task_scheduler/post_task.h" #include "content/browser/resource_context_impl.h" +#include "content/common/wrapper_shared_url_loader_factory.h" #include "content/public/browser/blob_handle.h" #include "content/public/browser/browser_context.h" #include "content/public/browser/browser_thread.h" @@ -28,6 +29,7 @@ #include "storage/browser/blob/blob_impl.h" #include "storage/browser/blob/blob_memory_controller.h" #include "storage/browser/blob/blob_storage_context.h" +#include "storage/browser/blob/blob_url_loader_factory.h" using base::FilePath; using base::UserDataAdapter; @@ -193,6 +195,29 @@ return blob_handle; } +// static +scoped_refptr<network::SharedURLLoaderFactory> +ChromeBlobStorageContext::URLLoaderFactoryForToken( + BrowserContext* browser_context, + blink::mojom::BlobURLTokenPtr token) { + DCHECK_CURRENTLY_ON(BrowserThread::UI); + network::mojom::URLLoaderFactoryPtr blob_url_loader_factory_ptr; + BrowserThread::PostTask( + BrowserThread::IO, FROM_HERE, + base::BindOnce( + [](scoped_refptr<ChromeBlobStorageContext> context, + network::mojom::URLLoaderFactoryRequest request, + blink::mojom::BlobURLTokenPtrInfo token) { + storage::BlobURLLoaderFactory::Create( + blink::mojom::BlobURLTokenPtr(std::move(token)), + context->context()->AsWeakPtr(), std::move(request)); + }, + base::WrapRefCounted(GetFor(browser_context)), + MakeRequest(&blob_url_loader_factory_ptr), token.PassInterface())); + return base::MakeRefCounted<WrapperSharedURLLoaderFactory>( + std::move(blob_url_loader_factory_ptr)); +} + ChromeBlobStorageContext::~ChromeBlobStorageContext() {} void ChromeBlobStorageContext::DeleteOnCorrectThread() const {
diff --git a/content/browser/blob_storage/chrome_blob_storage_context.h b/content/browser/blob_storage/chrome_blob_storage_context.h index 8c5b031e..4871fbe 100644 --- a/content/browser/blob_storage/chrome_blob_storage_context.h +++ b/content/browser/blob_storage/chrome_blob_storage_context.h
@@ -15,7 +15,9 @@ #include "base/memory/ref_counted.h" #include "base/sequenced_task_runner_helpers.h" #include "content/common/content_export.h" +#include "services/network/public/cpp/shared_url_loader_factory.h" #include "storage/browser/blob/blob_data_handle.h" +#include "third_party/WebKit/public/mojom/blob/blob_url_store.mojom.h" namespace base { class FilePath; @@ -72,6 +74,11 @@ int64_t size, const base::Time& expected_modification_time); + // Must be called on the UI thread. + static scoped_refptr<network::SharedURLLoaderFactory> + URLLoaderFactoryForToken(BrowserContext* browser_context, + blink::mojom::BlobURLTokenPtr token); + protected: virtual ~ChromeBlobStorageContext();
diff --git a/content/browser/browser_side_navigation_browsertest.cc b/content/browser/browser_side_navigation_browsertest.cc index e303622..5f10f348 100644 --- a/content/browser/browser_side_navigation_browsertest.cc +++ b/content/browser/browser_side_navigation_browsertest.cc
@@ -497,7 +497,7 @@ // termination. RenderProcessHostKillWaiter process_kill_waiter(rfh->GetProcess()); rfh->frame_host_binding_for_testing().impl()->BeginNavigation( - common_params, std::move(begin_params)); + common_params, std::move(begin_params), nullptr); EXPECT_EQ(bad_message::RFH_BASE_URL_FOR_DATA_URL_SPECIFIED, process_kill_waiter.Wait());
diff --git a/content/browser/device_sensors/device_sensor_browsertest.cc b/content/browser/device_sensors/device_sensor_browsertest.cc index 9fe346b5..f4dc655d 100644 --- a/content/browser/device_sensors/device_sensor_browsertest.cc +++ b/content/browser/device_sensors/device_sensor_browsertest.cc
@@ -32,6 +32,7 @@ #include "net/dns/mock_host_resolver.h" #include "services/device/public/cpp/generic_sensor/platform_sensor_configuration.h" #include "services/device/public/cpp/generic_sensor/sensor_reading.h" +#include "services/device/public/cpp/test/fake_sensor_and_provider.h" #include "services/device/public/mojom/constants.mojom.h" #include "services/device/public/mojom/sensor.mojom.h" #include "services/device/public/mojom/sensor_provider.mojom.h" @@ -41,232 +42,7 @@ namespace { -class FakeSensor : public device::mojom::Sensor { - public: - FakeSensor(device::mojom::SensorType sensor_type) - : sensor_type_(sensor_type) { - shared_buffer_handle_ = mojo::SharedBufferHandle::Create( - sizeof(device::SensorReadingSharedBuffer) * - static_cast<uint64_t>(device::mojom::SensorType::LAST)); - - if (!shared_buffer_handle_.is_valid()) - return; - - // Create read/write mapping now, to ensure it is kept writable - // after the region is sealed read-only on Android. - shared_buffer_mapping_ = shared_buffer_handle_->MapAtOffset( - device::mojom::SensorInitParams::kReadBufferSizeForTests, - GetBufferOffset()); - } - - ~FakeSensor() override = default; - - // device::mojom::Sensor: - void AddConfiguration( - const device::PlatformSensorConfiguration& configuration, - AddConfigurationCallback callback) override { - std::move(callback).Run(true); - SensorReadingChanged(); - } - - // device::mojom::Sensor: - void GetDefaultConfiguration( - GetDefaultConfigurationCallback callback) override { - std::move(callback).Run(GetDefaultConfiguration()); - } - - // device::mojom::Sensor: - void RemoveConfiguration( - const device::PlatformSensorConfiguration& configuration) override {} - - // device::mojom::Sensor: - void Suspend() override {} - void Resume() override {} - void ConfigureReadingChangeNotifications(bool enabled) override { - reading_notification_enabled_ = enabled; - } - - device::PlatformSensorConfiguration GetDefaultConfiguration() { - return device::PlatformSensorConfiguration(60 /* frequency */); - } - - device::mojom::ReportingMode GetReportingMode() { - return device::mojom::ReportingMode::ON_CHANGE; - } - - double GetMaximumSupportedFrequency() { return 60.0; } - double GetMinimumSupportedFrequency() { return 1.0; } - - device::mojom::SensorClientRequest GetClient() { - return mojo::MakeRequest(&client_); - } - - mojo::ScopedSharedBufferHandle GetSharedBufferHandle() { - return shared_buffer_handle_->Clone( - mojo::SharedBufferHandle::AccessMode::READ_ONLY); - } - - uint64_t GetBufferOffset() { - return device::SensorReadingSharedBuffer::GetOffset(sensor_type_); - } - - void set_reading(device::SensorReading reading) { reading_ = reading; } - - void SensorReadingChanged() { - if (!shared_buffer_mapping_.get()) - return; - - device::SensorReadingSharedBuffer* buffer = - static_cast<device::SensorReadingSharedBuffer*>( - shared_buffer_mapping_.get()); - - auto& seqlock = buffer->seqlock.value(); - seqlock.WriteBegin(); - buffer->reading = reading_; - seqlock.WriteEnd(); - - if (client_ && reading_notification_enabled_) - client_->SensorReadingChanged(); - } - - private: - device::mojom::SensorType sensor_type_; - bool reading_notification_enabled_ = true; - mojo::ScopedSharedBufferHandle shared_buffer_handle_; - mojo::ScopedSharedBufferMapping shared_buffer_mapping_; - device::mojom::SensorClientPtr client_; - device::SensorReading reading_; - - DISALLOW_COPY_AND_ASSIGN(FakeSensor); -}; - -class FakeSensorProvider : public device::mojom::SensorProvider { - public: - FakeSensorProvider() : binding_(this) {} - ~FakeSensorProvider() override = default; - - void Bind(const std::string& interface_name, - mojo::ScopedMessagePipeHandle handle, - const service_manager::BindSourceInfo& source_info) { - DCHECK(!binding_.is_bound()); - binding_.Bind(device::mojom::SensorProviderRequest(std::move(handle))); - } - - void set_accelerometer_is_available(bool accelerometer_is_available) { - accelerometer_is_available_ = accelerometer_is_available; - } - - void set_linear_acceleration_sensor_is_available( - bool linear_acceleration_sensor_is_available) { - linear_acceleration_sensor_is_available_ = - linear_acceleration_sensor_is_available; - } - - void set_gyroscope_is_available(bool gyroscope_is_available) { - gyroscope_is_available_ = gyroscope_is_available; - } - - void set_relative_orientation_sensor_is_available( - bool relative_orientation_sensor_is_available) { - relative_orientation_sensor_is_available_ = - relative_orientation_sensor_is_available; - } - - void set_absolute_orientation_sensor_is_available( - bool absolute_orientation_sensor_is_available) { - absolute_orientation_sensor_is_available_ = - absolute_orientation_sensor_is_available; - } - - // device::mojom::sensorProvider: - void GetSensor(device::mojom::SensorType type, - GetSensorCallback callback) override { - std::unique_ptr<FakeSensor> sensor; - device::SensorReading reading; - reading.raw.timestamp = - (base::TimeTicks::Now() - base::TimeTicks()).InSecondsF(); - - switch (type) { - case device::mojom::SensorType::ACCELEROMETER: - if (accelerometer_is_available_) { - sensor = std::make_unique<FakeSensor>( - device::mojom::SensorType::ACCELEROMETER); - reading.accel.x = 4; - reading.accel.y = 5; - reading.accel.z = 6; - } - break; - case device::mojom::SensorType::LINEAR_ACCELERATION: - if (linear_acceleration_sensor_is_available_) { - sensor = std::make_unique<FakeSensor>( - device::mojom::SensorType::LINEAR_ACCELERATION); - reading.accel.x = 1; - reading.accel.y = 2; - reading.accel.z = 3; - } - break; - case device::mojom::SensorType::GYROSCOPE: - if (gyroscope_is_available_) { - sensor = std::make_unique<FakeSensor>( - device::mojom::SensorType::GYROSCOPE); - reading.gyro.x = 7; - reading.gyro.y = 8; - reading.gyro.z = 9; - } - break; - case device::mojom::SensorType::RELATIVE_ORIENTATION_EULER_ANGLES: - if (relative_orientation_sensor_is_available_) { - sensor = std::make_unique<FakeSensor>( - device::mojom::SensorType::RELATIVE_ORIENTATION_EULER_ANGLES); - reading.orientation_euler.x = 2; // beta - reading.orientation_euler.y = 3; // gamma - reading.orientation_euler.z = 1; // alpha - } - break; - case device::mojom::SensorType::ABSOLUTE_ORIENTATION_EULER_ANGLES: - if (absolute_orientation_sensor_is_available_) { - sensor = std::make_unique<FakeSensor>( - device::mojom::SensorType::ABSOLUTE_ORIENTATION_EULER_ANGLES); - reading.orientation_euler.x = 5; // beta - reading.orientation_euler.y = 6; // gamma - reading.orientation_euler.z = 4; // alpha - } - break; - default: - NOTIMPLEMENTED(); - } - - if (sensor) { - sensor->set_reading(reading); - - auto init_params = device::mojom::SensorInitParams::New(); - init_params->client_request = sensor->GetClient(); - init_params->memory = sensor->GetSharedBufferHandle(); - init_params->buffer_offset = sensor->GetBufferOffset(); - init_params->default_configuration = sensor->GetDefaultConfiguration(); - init_params->maximum_frequency = sensor->GetMaximumSupportedFrequency(); - init_params->minimum_frequency = sensor->GetMinimumSupportedFrequency(); - - mojo::MakeStrongBinding(std::move(sensor), - mojo::MakeRequest(&init_params->sensor)); - std::move(callback).Run(device::mojom::SensorCreationResult::SUCCESS, - std::move(init_params)); - } else { - std::move(callback).Run( - device::mojom::SensorCreationResult::ERROR_NOT_AVAILABLE, nullptr); - } - } - - private: - mojo::Binding<device::mojom::SensorProvider> binding_; - bool accelerometer_is_available_ = true; - bool linear_acceleration_sensor_is_available_ = true; - bool gyroscope_is_available_ = true; - bool relative_orientation_sensor_is_available_ = true; - bool absolute_orientation_sensor_is_available_ = true; - - DISALLOW_COPY_AND_ASSIGN(FakeSensorProvider); -}; +using device::FakeSensorProvider; class DeviceSensorBrowserTest : public ContentBrowserTest { public: @@ -287,6 +63,11 @@ https_embedded_test_server_->StartAcceptingConnections(); sensor_provider_ = std::make_unique<FakeSensorProvider>(); + sensor_provider_->SetAccelerometerData(4, 5, 6); + sensor_provider_->SetLinearAccelerationSensorData(1, 2, 3); + sensor_provider_->SetGyroscopeData(7, 8, 9); + sensor_provider_->SetRelativeOrientationSensorData(1, 2, 3); + sensor_provider_->SetAbsoluteOrientationSensorData(4, 5, 6); BrowserThread::PostTask( BrowserThread::IO, FROM_HERE, base::BindOnce(&DeviceSensorBrowserTest::SetUpOnIOThread, @@ -306,8 +87,7 @@ // it. service_manager::ServiceContext::SetGlobalBinderForTesting( device::mojom::kServiceName, device::mojom::SensorProvider::Name_, - base::Bind(&FakeSensorProvider::Bind, - base::Unretained(sensor_provider_.get()))); + base::Bind(&DeviceSensorBrowserTest::Bind, base::Unretained(this))); io_loop_finished_event_.Signal(); } @@ -333,6 +113,13 @@ std::unique_ptr<net::EmbeddedTestServer> https_embedded_test_server_; private: + void Bind(const std::string& interface_name, + mojo::ScopedMessagePipeHandle handle, + const service_manager::BindSourceInfo& source_info) { + sensor_provider_->Bind( + device::mojom::SensorProviderRequest(std::move(handle))); + } + base::WaitableEvent io_loop_finished_event_; };
diff --git a/content/browser/download/download_browsertest.cc b/content/browser/download/download_browsertest.cc index 699306b..a0eabb72 100644 --- a/content/browser/download/download_browsertest.cc +++ b/content/browser/download/download_browsertest.cc
@@ -37,7 +37,6 @@ #include "components/download/public/common/download_file_impl.h" #include "components/download/public/common/download_task_runner.h" #include "components/download/public/common/parallel_download_utils.h" -#include "content/browser/download/download_item_impl.h" #include "content/browser/download/download_manager_impl.h" #include "content/browser/download/download_resource_handler.h" #include "content/browser/web_contents/web_contents_impl.h"
diff --git a/content/browser/download/download_item_factory.h b/content/browser/download/download_item_factory.h index 7d6ef5ee..c088755 100644 --- a/content/browser/download/download_item_factory.h +++ b/content/browser/download/download_item_factory.h
@@ -25,20 +25,19 @@ namespace download { struct DownloadCreateInfo; +class DownloadItemImpl; +class DownloadItemImplDelegate; class DownloadRequestHandleInterface; } // namespace download namespace content { -class DownloadItemImpl; -class DownloadItemImplDelegate; - class DownloadItemFactory { public: virtual ~DownloadItemFactory() {} - virtual DownloadItemImpl* CreatePersistedItem( - DownloadItemImplDelegate* delegate, + virtual download::DownloadItemImpl* CreatePersistedItem( + download::DownloadItemImplDelegate* delegate, const std::string& guid, uint32_t download_id, const base::FilePath& current_path, @@ -66,13 +65,13 @@ const std::vector<download::DownloadItem::ReceivedSlice>& received_slices) = 0; - virtual DownloadItemImpl* CreateActiveItem( - DownloadItemImplDelegate* delegate, + virtual download::DownloadItemImpl* CreateActiveItem( + download::DownloadItemImplDelegate* delegate, uint32_t download_id, const download::DownloadCreateInfo& info) = 0; - virtual DownloadItemImpl* CreateSavePageItem( - DownloadItemImplDelegate* delegate, + virtual download::DownloadItemImpl* CreateSavePageItem( + download::DownloadItemImplDelegate* delegate, uint32_t download_id, const base::FilePath& path, const GURL& url,
diff --git a/content/browser/download/download_item_impl_unittest.cc b/content/browser/download/download_item_impl_unittest.cc index 35ef769..eee3143 100644 --- a/content/browser/download/download_item_impl_unittest.cc +++ b/content/browser/download/download_item_impl_unittest.cc
@@ -2,7 +2,7 @@ // Use of this source code is governed by a BSD-style license that can be // found in the LICENSE file. -#include "content/browser/download/download_item_impl.h" +#include "components/download/public/common/download_item_impl.h" #include <stdint.h> @@ -27,18 +27,17 @@ #include "components/download/public/common/download_destination_observer.h" #include "components/download/public/common/download_file_factory.h" #include "components/download/public/common/download_interrupt_reasons.h" +#include "components/download/public/common/download_item_impl_delegate.h" #include "components/download/public/common/download_request_handle_interface.h" #include "components/download/public/common/download_url_parameters.h" #include "components/download/public/common/mock_download_file.h" #include "components/download/public/common/mock_download_item.h" #include "content/browser/byte_stream.h" -#include "content/browser/download/download_item_impl_delegate.h" #include "content/public/browser/browser_thread.h" #include "content/public/common/content_features.h" #include "content/public/test/test_browser_context.h" #include "content/public/test/test_browser_thread_bundle.h" #include "content/public/test/test_utils.h" -#include "content/public/test/web_contents_tester.h" #include "crypto/secure_hash.h" #include "net/http/http_response_headers.h" #include "testing/gmock/include/gmock/gmock.h" @@ -72,21 +71,24 @@ return static_cast<base::HistogramBase::Sample>(t); } -class MockDelegate : public DownloadItemImplDelegate { +class MockDelegate : public download::DownloadItemImplDelegate { public: - MockDelegate() : DownloadItemImplDelegate() { + MockDelegate() : download::DownloadItemImplDelegate() { browser_context_.reset(new TestBrowserContext); SetDefaultExpectations(); } - MOCK_METHOD2(DetermineDownloadTarget, void( - DownloadItemImpl*, const DownloadTargetCallback&)); + MOCK_METHOD2( + DetermineDownloadTarget, + void(download::DownloadItemImpl*, + const download::DownloadItemImplDelegate::DownloadTargetCallback&)); MOCK_METHOD2(ShouldCompleteDownload, - bool(DownloadItemImpl*, const base::Closure&)); + bool(download::DownloadItemImpl*, const base::Closure&)); MOCK_METHOD2(ShouldOpenDownload, - bool(DownloadItemImpl*, const ShouldOpenDownloadCallback&)); + bool(download::DownloadItemImpl*, + const ShouldOpenDownloadCallback&)); MOCK_METHOD1(ShouldOpenFileBasedOnExtension, bool(const base::FilePath&)); - MOCK_METHOD1(CheckForFileRemoval, void(DownloadItemImpl*)); + MOCK_METHOD1(CheckForFileRemoval, void(download::DownloadItemImpl*)); void ResumeInterruptedDownload( std::unique_ptr<download::DownloadUrlParameters> params, @@ -97,9 +99,9 @@ MOCK_METHOD2(MockResumeInterruptedDownload, void(download::DownloadUrlParameters* params, uint32_t id)); - MOCK_METHOD1(DownloadOpened, void(DownloadItemImpl*)); - MOCK_METHOD1(DownloadRemoved, void(DownloadItemImpl*)); - MOCK_CONST_METHOD1(AssertStateConsistent, void(DownloadItemImpl*)); + MOCK_METHOD1(DownloadOpened, void(download::DownloadItemImpl*)); + MOCK_METHOD1(DownloadRemoved, void(download::DownloadItemImpl*)); + MOCK_CONST_METHOD1(AssertStateConsistent, void(download::DownloadItemImpl*)); void VerifyAndClearExpectations() { ::testing::Mock::VerifyAndClearExpectations(this); @@ -271,9 +273,9 @@ create_info_->etag = "SomethingToSatisfyResumption"; } - DownloadItemImpl* CreateDownloadItemWithCreateInfo( + download::DownloadItemImpl* CreateDownloadItemWithCreateInfo( std::unique_ptr<download::DownloadCreateInfo> info) { - DownloadItemImpl* download = new DownloadItemImpl( + download::DownloadItemImpl* download = new download::DownloadItemImpl( mock_delegate(), next_download_id_++, *(info.get())); allocated_downloads_[download] = base::WrapUnique(download); return download; @@ -289,9 +291,9 @@ // This class keeps ownership of the created download item; it will // be torn down at the end of the test unless DestroyDownloadItem is // called. - DownloadItemImpl* CreateDownloadItem() { + download::DownloadItemImpl* CreateDownloadItem() { create_info_->download_id = ++next_download_id_; - DownloadItemImpl* download = new DownloadItemImpl( + download::DownloadItemImpl* download = new download::DownloadItemImpl( mock_delegate(), create_info_->download_id, *create_info_); allocated_downloads_[download] = base::WrapUnique(download); return download; @@ -299,8 +301,8 @@ // Add DownloadFile to download::DownloadItem. download::MockDownloadFile* CallDownloadItemStart( - DownloadItemImpl* item, - DownloadTargetCallback* callback) { + download::DownloadItemImpl* item, + download::DownloadItemImplDelegate::DownloadTargetCallback* callback) { download::MockDownloadFile* mock_download_file = nullptr; std::unique_ptr<download::DownloadFile> download_file; EXPECT_CALL(*mock_delegate(), DetermineDownloadTarget(item, _)) @@ -340,11 +342,11 @@ // download will be set to kDummyTargetPath. Returns the MockDownloadFile* // that was added to the download::DownloadItem. download::MockDownloadFile* DoIntermediateRename( - DownloadItemImpl* item, + download::DownloadItemImpl* item, download::DownloadDangerType danger_type) { EXPECT_EQ(download::DownloadItem::IN_PROGRESS, item->GetState()); EXPECT_TRUE(item->GetTargetFilePath().empty()); - DownloadTargetCallback callback; + download::DownloadItemImplDelegate::DownloadTargetCallback callback; download::MockDownloadFile* download_file = CallDownloadItemStart(item, &callback); base::FilePath target_path(kDummyTargetPath); @@ -360,7 +362,7 @@ return download_file; } - void DoDestinationComplete(DownloadItemImpl* item, + void DoDestinationComplete(download::DownloadItemImpl* item, download::MockDownloadFile* download_file) { EXPECT_CALL(*mock_delegate(), ShouldCompleteDownload(_, _)) .WillOnce(Return(true)); @@ -379,7 +381,7 @@ // Cleanup a download item (specifically get rid of the DownloadFile on it). // The item must be in the expected state. - void CleanupItem(DownloadItemImpl* item, + void CleanupItem(download::DownloadItemImpl* item, download::MockDownloadFile* download_file, download::DownloadItem::DownloadState expected_state) { EXPECT_EQ(expected_state, item->GetState()); @@ -428,7 +430,7 @@ // set_* mutators TEST_F(DownloadItemTest, NotificationAfterUpdate) { - DownloadItemImpl* item = CreateDownloadItem(); + download::DownloadItemImpl* item = CreateDownloadItem(); download::MockDownloadFile* file = DoIntermediateRename(item, download::DOWNLOAD_DANGER_TYPE_NOT_DANGEROUS); ASSERT_EQ(download::DownloadItem::IN_PROGRESS, item->GetState()); @@ -442,8 +444,8 @@ } TEST_F(DownloadItemTest, NotificationAfterCancel) { - DownloadItemImpl* user_cancel = CreateDownloadItem(); - DownloadTargetCallback target_callback; + download::DownloadItemImpl* user_cancel = CreateDownloadItem(); + download::DownloadItemImplDelegate::DownloadTargetCallback target_callback; download::MockDownloadFile* download_file = CallDownloadItemStart(user_cancel, &target_callback); EXPECT_CALL(*download_file, Cancel()); @@ -452,7 +454,7 @@ user_cancel->Cancel(true); ASSERT_TRUE(observer1.CheckAndResetDownloadUpdated()); - DownloadItemImpl* system_cancel = CreateDownloadItem(); + download::DownloadItemImpl* system_cancel = CreateDownloadItem(); download_file = CallDownloadItemStart(system_cancel, &target_callback); EXPECT_CALL(*download_file, Cancel()); @@ -462,7 +464,7 @@ } TEST_F(DownloadItemTest, NotificationAfterComplete) { - DownloadItemImpl* item = CreateDownloadItem(); + download::DownloadItemImpl* item = CreateDownloadItem(); TestDownloadItemObserver observer(item); download::MockDownloadFile* download_file = DoIntermediateRename(item, download::DOWNLOAD_DANGER_TYPE_NOT_DANGEROUS); @@ -472,7 +474,7 @@ } TEST_F(DownloadItemTest, NotificationAfterDownloadedFileRemoved) { - DownloadItemImpl* item = CreateDownloadItem(); + download::DownloadItemImpl* item = CreateDownloadItem(); TestDownloadItemObserver observer(item); item->OnDownloadedFileRemoved(); @@ -480,7 +482,7 @@ } TEST_F(DownloadItemTest, NotificationAfterInterrupted) { - DownloadItemImpl* item = CreateDownloadItem(); + download::DownloadItemImpl* item = CreateDownloadItem(); download::MockDownloadFile* download_file = DoIntermediateRename(item, download::DOWNLOAD_DANGER_TYPE_NOT_DANGEROUS); EXPECT_CALL(*download_file, Cancel()); @@ -495,7 +497,7 @@ } TEST_F(DownloadItemTest, NotificationAfterDestroyed) { - DownloadItemImpl* item = CreateDownloadItem(); + download::DownloadItemImpl* item = CreateDownloadItem(); TestDownloadItemObserver observer(item); DestroyDownloadItem(item); @@ -503,8 +505,8 @@ } TEST_F(DownloadItemTest, NotificationAfterRemove) { - DownloadItemImpl* item = CreateDownloadItem(); - DownloadTargetCallback target_callback; + download::DownloadItemImpl* item = CreateDownloadItem(); + download::DownloadItemImplDelegate::DownloadTargetCallback target_callback; download::MockDownloadFile* download_file = CallDownloadItemStart(item, &target_callback); EXPECT_CALL(*download_file, Cancel()); @@ -518,7 +520,7 @@ TEST_F(DownloadItemTest, NotificationAfterOnContentCheckCompleted) { // Setting to NOT_DANGEROUS does not trigger a notification. - DownloadItemImpl* safe_item = CreateDownloadItem(); + download::DownloadItemImpl* safe_item = CreateDownloadItem(); download::MockDownloadFile* download_file = DoIntermediateRename( safe_item, download::DOWNLOAD_DANGER_TYPE_NOT_DANGEROUS); TestDownloadItemObserver safe_observer(safe_item); @@ -532,7 +534,7 @@ CleanupItem(safe_item, download_file, download::DownloadItem::IN_PROGRESS); // Setting to unsafe url or unsafe file should trigger a notification. - DownloadItemImpl* unsafeurl_item = CreateDownloadItem(); + download::DownloadItemImpl* unsafeurl_item = CreateDownloadItem(); download_file = DoIntermediateRename( unsafeurl_item, download::DOWNLOAD_DANGER_TYPE_NOT_DANGEROUS); TestDownloadItemObserver unsafeurl_observer(unsafeurl_item); @@ -552,7 +554,7 @@ CleanupItem(unsafeurl_item, download_file, download::DownloadItem::IN_PROGRESS); - DownloadItemImpl* unsafefile_item = CreateDownloadItem(); + download::DownloadItemImpl* unsafefile_item = CreateDownloadItem(); download_file = DoIntermediateRename( unsafefile_item, download::DOWNLOAD_DANGER_TYPE_NOT_DANGEROUS); TestDownloadItemObserver unsafefile_observer(unsafefile_item); @@ -579,8 +581,8 @@ // name. Check that observers are updated when the new filename is available and // not before. TEST_F(DownloadItemTest, NotificationAfterOnDownloadTargetDetermined) { - DownloadItemImpl* item = CreateDownloadItem(); - DownloadTargetCallback callback; + download::DownloadItemImpl* item = CreateDownloadItem(); + download::DownloadItemImplDelegate::DownloadTargetCallback callback; download::MockDownloadFile* download_file = CallDownloadItemStart(item, &callback); TestDownloadItemObserver observer(item); @@ -607,7 +609,7 @@ } TEST_F(DownloadItemTest, NotificationAfterTogglePause) { - DownloadItemImpl* item = CreateDownloadItem(); + download::DownloadItemImpl* item = CreateDownloadItem(); TestDownloadItemObserver observer(item); download::MockDownloadFile* mock_download_file( new download::MockDownloadFile); @@ -635,7 +637,7 @@ // Test that a download is resumed automatically after a continuable interrupt. TEST_F(DownloadItemTest, AutomaticResumption_Continue) { - DownloadItemImpl* item = CreateDownloadItem(); + download::DownloadItemImpl* item = CreateDownloadItem(); TestDownloadItemObserver observer(item); download::MockDownloadFile* download_file = DoIntermediateRename(item, download::DOWNLOAD_DANGER_TYPE_NOT_DANGEROUS); @@ -690,7 +692,7 @@ // Automatic resumption should restart and discard the intermediate file if the // interrupt reason requires it. TEST_F(DownloadItemTest, AutomaticResumption_Restart) { - DownloadItemImpl* item = CreateDownloadItem(); + download::DownloadItemImpl* item = CreateDownloadItem(); TestDownloadItemObserver observer(item); download::MockDownloadFile* download_file = DoIntermediateRename(item, download::DOWNLOAD_DANGER_TYPE_NOT_DANGEROUS); @@ -730,7 +732,7 @@ // Test that automatic resumption doesn't happen after an interrupt that // requires user action to resolve. TEST_F(DownloadItemTest, AutomaticResumption_NeedsUserAction) { - DownloadItemImpl* item = CreateDownloadItem(); + download::DownloadItemImpl* item = CreateDownloadItem(); TestDownloadItemObserver observer(item); download::MockDownloadFile* download_file = DoIntermediateRename(item, download::DOWNLOAD_DANGER_TYPE_NOT_DANGEROUS); @@ -758,7 +760,7 @@ // Test that a download is resumed automatically after a content length mismatch // error. TEST_F(DownloadItemTest, AutomaticResumption_ContentLengthMismatch) { - DownloadItemImpl* item = CreateDownloadItem(); + download::DownloadItemImpl* item = CreateDownloadItem(); TestDownloadItemObserver observer(item); download::MockDownloadFile* download_file = DoIntermediateRename(item, download::DOWNLOAD_DANGER_TYPE_NOT_DANGEROUS); @@ -801,7 +803,7 @@ // Check we do correct cleanup for RESUME_MODE_INVALID interrupts. TEST_F(DownloadItemTest, UnresumableInterrupt) { - DownloadItemImpl* item = CreateDownloadItem(); + download::DownloadItemImpl* item = CreateDownloadItem(); TestDownloadItemObserver observer(item); download::MockDownloadFile* download_file = DoIntermediateRename(item, download::DOWNLOAD_DANGER_TYPE_NOT_DANGEROUS); @@ -836,14 +838,14 @@ TEST_F(DownloadItemTest, AutomaticResumption_AttemptLimit) { base::HistogramTester histogram_tester; - DownloadItemImpl* item = CreateDownloadItem(); + download::DownloadItemImpl* item = CreateDownloadItem(); base::WeakPtr<download::DownloadDestinationObserver> as_observer( item->DestinationObserverAsWeakPtr()); TestDownloadItemObserver observer(item); download::MockDownloadFile* mock_download_file_ref = nullptr; std::unique_ptr<download::MockDownloadFile> mock_download_file; std::unique_ptr<MockRequestHandle> mock_request_handle; - DownloadTargetCallback callback; + download::DownloadItemImplDelegate::DownloadTargetCallback callback; EXPECT_CALL(*mock_delegate(), DetermineDownloadTarget(item, _)) .WillRepeatedly(SaveArg<1>(&callback)); @@ -856,8 +858,9 @@ kDummyIntermediatePath)), Property(&download::DownloadUrlParameters::offset, 1)), _)) - .Times(DownloadItemImpl::kMaxAutoResumeAttempts); - for (int i = 0; i < (DownloadItemImpl::kMaxAutoResumeAttempts + 1); ++i) { + .Times(download::DownloadItemImpl::kMaxAutoResumeAttempts); + for (int i = 0; i < (download::DownloadItemImpl::kMaxAutoResumeAttempts + 1); + ++i) { SCOPED_TRACE(::testing::Message() << "Iteration " << i); mock_download_file = @@ -908,7 +911,7 @@ "Download.InterruptedReason", ToHistogramSample<download::DownloadInterruptReason>( download::DOWNLOAD_INTERRUPT_REASON_FILE_TRANSIENT_ERROR), - DownloadItemImpl::kMaxAutoResumeAttempts + 1); + download::DownloadItemImpl::kMaxAutoResumeAttempts + 1); EXPECT_EQ(download::DownloadItem::INTERRUPTED, item->GetState()); EXPECT_EQ(1, observer.interrupt_count()); CleanupItem(item, nullptr, download::DownloadItem::INTERRUPTED); @@ -931,7 +934,7 @@ create_info()->url_chain.push_back(GURL(kFirstURL)); create_info()->mime_type = kMimeType; - DownloadItemImpl* item = CreateDownloadItem(); + download::DownloadItemImpl* item = CreateDownloadItem(); download::MockDownloadFile* download_file = DoIntermediateRename(item, download::DOWNLOAD_DANGER_TYPE_NOT_DANGEROUS); ASSERT_TRUE(item->GetResponseHeaders()); @@ -977,7 +980,7 @@ // Calling Start() with a response indicating failure shouldn't cause a target // update, nor should it result in discarding the intermediate file. - DownloadTargetCallback target_callback; + download::DownloadItemImplDelegate::DownloadTargetCallback target_callback; download_file = CallDownloadItemStart(item, &target_callback); ASSERT_FALSE(target_callback.is_null()); target_callback.Run(base::FilePath(kDummyTargetPath), @@ -1017,7 +1020,7 @@ create_info()->url_chain.push_back(GURL(kFirstURL)); create_info()->mime_type = kMimeType; - DownloadItemImpl* item = CreateDownloadItem(); + download::DownloadItemImpl* item = CreateDownloadItem(); download::MockDownloadFile* download_file = DoIntermediateRename(item, download::DOWNLOAD_DANGER_TYPE_NOT_DANGEROUS); EXPECT_CALL(*mock_delegate(), MockResumeInterruptedDownload(_, _)); @@ -1044,7 +1047,7 @@ create_info()->url_chain.push_back(GURL(kSecondURL)); create_info()->mime_type = kSecondMimeType; - DownloadTargetCallback target_callback; + download::DownloadItemImplDelegate::DownloadTargetCallback target_callback; download_file = CallDownloadItemStart(item, &target_callback); ASSERT_TRUE(item->GetResponseHeaders()); @@ -1067,7 +1070,7 @@ download::DownloadItem::ReceivedSlice(0, 10)}; create_info()->etag = kFirstETag; - DownloadItemImpl* item = CreateDownloadItem(); + download::DownloadItemImpl* item = CreateDownloadItem(); download::MockDownloadFile* download_file = DoIntermediateRename(item, download::DOWNLOAD_DANGER_TYPE_NOT_DANGEROUS); @@ -1089,7 +1092,7 @@ // Change the strong validator and resume the download, the received slices // should be cleared. create_info()->etag = kSecondETag; - DownloadTargetCallback target_callback; + download::DownloadItemImplDelegate::DownloadTargetCallback target_callback; download_file = CallDownloadItemStart(item, &target_callback); EXPECT_TRUE(item->GetReceivedSlices().empty()); EXPECT_EQ(0, item->GetReceivedBytes()); @@ -1105,7 +1108,7 @@ create_info()->url_chain.push_back(GURL("http://example.com/b")); create_info()->url_chain.push_back(GURL("http://example.com/c")); - DownloadItemImpl* item = CreateDownloadItem(); + download::DownloadItemImpl* item = CreateDownloadItem(); TestDownloadItemObserver observer(item); download::MockDownloadFile* download_file = DoIntermediateRename(item, download::DOWNLOAD_DANGER_TYPE_NOT_DANGEROUS); @@ -1136,8 +1139,8 @@ } TEST_F(DownloadItemTest, DisplayName) { - DownloadItemImpl* item = CreateDownloadItem(); - DownloadTargetCallback callback; + download::DownloadItemImpl* item = CreateDownloadItem(); + download::DownloadItemImplDelegate::DownloadTargetCallback callback; download::MockDownloadFile* download_file = CallDownloadItemStart(item, &callback); base::FilePath target_path( @@ -1166,7 +1169,7 @@ download::MockDownloadFile* mock_download_file( new download::MockDownloadFile); std::unique_ptr<download::DownloadFile> download_file(mock_download_file); - DownloadItemImpl* item = CreateDownloadItem(); + download::DownloadItemImpl* item = CreateDownloadItem(); EXPECT_CALL(*mock_download_file, Initialize(_, _, _, _)); std::unique_ptr<download::DownloadRequestHandleInterface> request_handle( new NiceMock<MockRequestHandle>); @@ -1181,7 +1184,7 @@ // Download file and the request should be cancelled as a result of download // file initialization failing. TEST_F(DownloadItemTest, InitDownloadFileFails) { - DownloadItemImpl* item = CreateDownloadItem(); + download::DownloadItemImpl* item = CreateDownloadItem(); std::unique_ptr<download::MockDownloadFile> file = std::make_unique<download::MockDownloadFile>(); std::unique_ptr<MockRequestHandle> request_handle = @@ -1194,7 +1197,8 @@ .WillOnce(ScheduleCallbackWithParams( download::DOWNLOAD_INTERRUPT_REASON_FILE_ACCESS_DENIED, 0)); - DownloadTargetCallback download_target_callback; + download::DownloadItemImplDelegate::DownloadTargetCallback + download_target_callback; EXPECT_CALL(*mock_delegate(), DetermineDownloadTarget(item, _)) .WillOnce(SaveArg<1>(&download_target_callback)); @@ -1227,13 +1231,14 @@ TEST_F(DownloadItemTest, StartFailedDownload) { base::HistogramTester histogram_tester; create_info()->result = download::DOWNLOAD_INTERRUPT_REASON_NETWORK_FAILED; - DownloadItemImpl* item = CreateDownloadItem(); + download::DownloadItemImpl* item = CreateDownloadItem(); // DownloadFile and DownloadRequestHandleInterface objects aren't created for // failed downloads. std::unique_ptr<download::DownloadFile> null_download_file; std::unique_ptr<download::DownloadRequestHandleInterface> null_request_handle; - DownloadTargetCallback download_target_callback; + download::DownloadItemImplDelegate::DownloadTargetCallback + download_target_callback; EXPECT_CALL(*mock_delegate(), DetermineDownloadTarget(item, _)) .WillOnce(SaveArg<1>(&download_target_callback)); item->Start(std::move(null_download_file), std::move(null_request_handle), @@ -1264,8 +1269,8 @@ // Test that the delegate is invoked after the download file is renamed. TEST_F(DownloadItemTest, CallbackAfterRename) { - DownloadItemImpl* item = CreateDownloadItem(); - DownloadTargetCallback callback; + download::DownloadItemImpl* item = CreateDownloadItem(); + download::DownloadItemImplDelegate::DownloadTargetCallback callback; download::MockDownloadFile* download_file = CallDownloadItemStart(item, &callback); base::FilePath final_path( @@ -1303,8 +1308,8 @@ // Test that the delegate is invoked after the download file is renamed and the // download item is in an interrupted state. TEST_F(DownloadItemTest, CallbackAfterInterruptedRename) { - DownloadItemImpl* item = CreateDownloadItem(); - DownloadTargetCallback callback; + download::DownloadItemImpl* item = CreateDownloadItem(); + download::DownloadItemImplDelegate::DownloadTargetCallback callback; base::HistogramTester histogram_tester; download::MockDownloadFile* download_file = CallDownloadItemStart(item, &callback); @@ -1336,7 +1341,7 @@ TEST_F(DownloadItemTest, Interrupted) { base::HistogramTester histogram_tester; - DownloadItemImpl* item = CreateDownloadItem(); + download::DownloadItemImpl* item = CreateDownloadItem(); download::MockDownloadFile* download_file = DoIntermediateRename(item, download::DOWNLOAD_DANGER_TYPE_NOT_DANGEROUS); @@ -1366,8 +1371,8 @@ // the download to be marked as interrupted until after the intermediate rename. TEST_F(DownloadItemTest, InterruptedBeforeIntermediateRename_Restart) { base::HistogramTester histogram_tester; - DownloadItemImpl* item = CreateDownloadItem(); - DownloadTargetCallback callback; + download::DownloadItemImpl* item = CreateDownloadItem(); + download::DownloadItemImplDelegate::DownloadTargetCallback callback; download::MockDownloadFile* download_file = CallDownloadItemStart(item, &callback); item->DestinationObserverAsWeakPtr()->DestinationError( @@ -1408,8 +1413,8 @@ // the intermediate rename succeeds. TEST_F(DownloadItemTest, InterruptedBeforeIntermediateRename_Continue) { base::HistogramTester histogram_tester; - DownloadItemImpl* item = CreateDownloadItem(); - DownloadTargetCallback callback; + download::DownloadItemImpl* item = CreateDownloadItem(); + download::DownloadItemImplDelegate::DownloadTargetCallback callback; download::MockDownloadFile* download_file = CallDownloadItemStart(item, &callback); @@ -1453,8 +1458,8 @@ // be set to the file error and the intermediate path should be empty. TEST_F(DownloadItemTest, InterruptedBeforeIntermediateRename_Failed) { base::HistogramTester histogram_tester; - DownloadItemImpl* item = CreateDownloadItem(); - DownloadTargetCallback callback; + download::DownloadItemImpl* item = CreateDownloadItem(); + download::DownloadItemImplDelegate::DownloadTargetCallback callback; download::MockDownloadFile* download_file = CallDownloadItemStart(item, &callback); item->DestinationObserverAsWeakPtr()->DestinationError( @@ -1499,8 +1504,8 @@ } TEST_F(DownloadItemTest, Canceled) { - DownloadItemImpl* item = CreateDownloadItem(); - DownloadTargetCallback target_callback; + download::DownloadItemImpl* item = CreateDownloadItem(); + download::DownloadItemImplDelegate::DownloadTargetCallback target_callback; download::MockDownloadFile* download_file = CallDownloadItemStart(item, &target_callback); @@ -1511,8 +1516,8 @@ } TEST_F(DownloadItemTest, DownloadTargetDetermined_Cancel) { - DownloadItemImpl* item = CreateDownloadItem(); - DownloadTargetCallback callback; + download::DownloadItemImpl* item = CreateDownloadItem(); + download::DownloadItemImplDelegate::DownloadTargetCallback callback; download::MockDownloadFile* download_file = CallDownloadItemStart(item, &callback); @@ -1526,8 +1531,8 @@ } TEST_F(DownloadItemTest, DownloadTargetDetermined_CancelWithEmptyName) { - DownloadItemImpl* item = CreateDownloadItem(); - DownloadTargetCallback callback; + download::DownloadItemImpl* item = CreateDownloadItem(); + download::DownloadItemImplDelegate::DownloadTargetCallback callback; download::MockDownloadFile* download_file = CallDownloadItemStart(item, &callback); @@ -1540,8 +1545,8 @@ } TEST_F(DownloadItemTest, DownloadTargetDetermined_Conflict) { - DownloadItemImpl* item = CreateDownloadItem(); - DownloadTargetCallback callback; + download::DownloadItemImpl* item = CreateDownloadItem(); + download::DownloadItemImplDelegate::DownloadTargetCallback callback; download::MockDownloadFile* download_file = CallDownloadItemStart(item, &callback); base::FilePath target_path(FILE_PATH_LITERAL("/foo/bar")); @@ -1557,7 +1562,7 @@ } TEST_F(DownloadItemTest, FileRemoved) { - DownloadItemImpl* item = CreateDownloadItem(); + download::DownloadItemImpl* item = CreateDownloadItem(); EXPECT_FALSE(item->GetFileExternallyRemoved()); item->OnDownloadedFileRemoved(); @@ -1565,7 +1570,7 @@ } TEST_F(DownloadItemTest, DestinationUpdate) { - DownloadItemImpl* item = CreateDownloadItem(); + download::DownloadItemImpl* item = CreateDownloadItem(); download::MockDownloadFile* file = DoIntermediateRename(item, download::DOWNLOAD_DANGER_TYPE_NOT_DANGEROUS); base::WeakPtr<download::DownloadDestinationObserver> as_observer( @@ -1601,7 +1606,7 @@ TEST_F(DownloadItemTest, DestinationError_NoRestartRequired) { base::HistogramTester histogram_tester; - DownloadItemImpl* item = CreateDownloadItem(); + download::DownloadItemImpl* item = CreateDownloadItem(); download::MockDownloadFile* download_file = DoIntermediateRename(item, download::DOWNLOAD_DANGER_TYPE_NOT_DANGEROUS); base::WeakPtr<download::DownloadDestinationObserver> as_observer( @@ -1636,7 +1641,7 @@ TEST_F(DownloadItemTest, DestinationError_RestartRequired) { base::HistogramTester histogram_tester; - DownloadItemImpl* item = CreateDownloadItem(); + download::DownloadItemImpl* item = CreateDownloadItem(); download::MockDownloadFile* download_file = DoIntermediateRename(item, download::DOWNLOAD_DANGER_TYPE_NOT_DANGEROUS); base::WeakPtr<download::DownloadDestinationObserver> as_observer( @@ -1669,7 +1674,7 @@ TEST_F(DownloadItemTest, DestinationCompleted) { base::HistogramTester histogram_tester; - DownloadItemImpl* item = CreateDownloadItem(); + download::DownloadItemImpl* item = CreateDownloadItem(); download::MockDownloadFile* download_file = DoIntermediateRename(item, download::DOWNLOAD_DANGER_TYPE_NOT_DANGEROUS); base::WeakPtr<download::DownloadDestinationObserver> as_observer( @@ -1712,7 +1717,7 @@ } TEST_F(DownloadItemTest, EnabledActionsForNormalDownload) { - DownloadItemImpl* item = CreateDownloadItem(); + download::DownloadItemImpl* item = CreateDownloadItem(); download::MockDownloadFile* download_file = DoIntermediateRename(item, download::DOWNLOAD_DANGER_TYPE_NOT_DANGEROUS); @@ -1745,7 +1750,7 @@ // A download created with a non-empty FilePath is considered a temporary // download. create_info()->save_info->file_path = base::FilePath(kDummyTargetPath); - DownloadItemImpl* item = CreateDownloadItem(); + download::DownloadItemImpl* item = CreateDownloadItem(); download::MockDownloadFile* download_file = DoIntermediateRename(item, download::DOWNLOAD_DANGER_TYPE_NOT_DANGEROUS); @@ -1776,7 +1781,7 @@ } TEST_F(DownloadItemTest, EnabledActionsForInterruptedDownload) { - DownloadItemImpl* item = CreateDownloadItem(); + download::DownloadItemImpl* item = CreateDownloadItem(); download::MockDownloadFile* download_file = DoIntermediateRename(item, download::DOWNLOAD_DANGER_TYPE_NOT_DANGEROUS); @@ -1793,7 +1798,7 @@ } TEST_F(DownloadItemTest, EnabledActionsForCancelledDownload) { - DownloadItemImpl* item = CreateDownloadItem(); + download::DownloadItemImpl* item = CreateDownloadItem(); download::MockDownloadFile* download_file = DoIntermediateRename(item, download::DOWNLOAD_DANGER_TYPE_NOT_DANGEROUS); @@ -1812,7 +1817,7 @@ TEST_F(DownloadItemTest, CompleteDelegate_ReturnTrue) { // Test to confirm that if we have a callback that returns true, // we complete immediately. - DownloadItemImpl* item = CreateDownloadItem(); + download::DownloadItemImpl* item = CreateDownloadItem(); download::MockDownloadFile* download_file = DoIntermediateRename(item, download::DOWNLOAD_DANGER_TYPE_NOT_DANGEROUS); @@ -1844,7 +1849,7 @@ // Test to confirm that if we have a callback that returns true, // we complete immediately. - DownloadItemImpl* item = CreateDownloadItem(); + download::DownloadItemImpl* item = CreateDownloadItem(); download::MockDownloadFile* download_file = DoIntermediateRename(item, download::DOWNLOAD_DANGER_TYPE_NOT_DANGEROUS); @@ -1884,7 +1889,7 @@ TEST_F(DownloadItemTest, CompleteDelegate_SetDanger) { // Test to confirm that if we have a callback that returns true, // we complete immediately. - DownloadItemImpl* item = CreateDownloadItem(); + download::DownloadItemImpl* item = CreateDownloadItem(); download::MockDownloadFile* download_file = DoIntermediateRename(item, download::DOWNLOAD_DANGER_TYPE_NOT_DANGEROUS); @@ -1935,7 +1940,7 @@ TEST_F(DownloadItemTest, CompleteDelegate_BlockTwice) { // Test to confirm that if we have a callback that returns true, // we complete immediately. - DownloadItemImpl* item = CreateDownloadItem(); + download::DownloadItemImpl* item = CreateDownloadItem(); download::MockDownloadFile* download_file = DoIntermediateRename(item, download::DOWNLOAD_DANGER_TYPE_NOT_DANGEROUS); @@ -1980,7 +1985,7 @@ } TEST_F(DownloadItemTest, StealDangerousDownloadAndDiscard) { - DownloadItemImpl* item = CreateDownloadItem(); + download::DownloadItemImpl* item = CreateDownloadItem(); download::MockDownloadFile* download_file = DoIntermediateRename(item, download::DOWNLOAD_DANGER_TYPE_DANGEROUS_FILE); ASSERT_TRUE(item->IsDangerous()); @@ -2002,7 +2007,7 @@ } TEST_F(DownloadItemTest, StealDangerousDownloadAndKeep) { - DownloadItemImpl* item = CreateDownloadItem(); + download::DownloadItemImpl* item = CreateDownloadItem(); download::MockDownloadFile* download_file = DoIntermediateRename(item, download::DOWNLOAD_DANGER_TYPE_DANGEROUS_FILE); ASSERT_TRUE(item->IsDangerous()); @@ -2023,7 +2028,7 @@ TEST_F(DownloadItemTest, StealInterruptedContinuableDangerousDownload) { base::FilePath returned_path; - DownloadItemImpl* item = CreateDownloadItem(); + download::DownloadItemImpl* item = CreateDownloadItem(); download::MockDownloadFile* download_file = DoIntermediateRename(item, download::DOWNLOAD_DANGER_TYPE_DANGEROUS_FILE); base::FilePath full_path = item->GetFullPath(); @@ -2048,7 +2053,7 @@ TEST_F(DownloadItemTest, StealInterruptedNonContinuableDangerousDownload) { base::FilePath returned_path; - DownloadItemImpl* item = CreateDownloadItem(); + download::DownloadItemImpl* item = CreateDownloadItem(); download::MockDownloadFile* download_file = DoIntermediateRename(item, download::DOWNLOAD_DANGER_TYPE_DANGEROUS_FILE); EXPECT_CALL(*download_file, Cancel()); @@ -2283,7 +2288,7 @@ base::BindOnce(action, observer)); } - DownloadItemImpl* item_; + download::DownloadItemImpl* item_; std::unique_ptr<download::MockDownloadFile> file_; std::unique_ptr<MockRequestHandle> request_handle_; @@ -2322,7 +2327,7 @@ ScheduleObservations(PreInitializeFileObservations(), destination_observer); task_environment_.RunUntilIdle(); - DownloadTargetCallback target_callback; + download::DownloadItemImplDelegate::DownloadTargetCallback target_callback; EXPECT_CALL(*mock_delegate(), DetermineDownloadTarget(_, _)) .WillOnce(SaveArg<1>(&target_callback)); ScheduleObservations(PostInitializeFileObservations(), destination_observer); @@ -2370,7 +2375,7 @@ ScheduleObservations(PreInitializeFileObservations(), destination_observer); task_environment_.RunUntilIdle(); - DownloadTargetCallback target_callback; + download::DownloadItemImplDelegate::DownloadTargetCallback target_callback; EXPECT_CALL(*mock_delegate(), DetermineDownloadTarget(_, _)) .WillOnce(SaveArg<1>(&target_callback)); ScheduleObservations(PostInitializeFileObservations(), destination_observer); @@ -2435,7 +2440,7 @@ ScheduleObservations(PreInitializeFileObservations(), destination_observer); task_environment_.RunUntilIdle(); - DownloadTargetCallback target_callback; + download::DownloadItemImplDelegate::DownloadTargetCallback target_callback; EXPECT_CALL(*mock_delegate(), DetermineDownloadTarget(_, _)) .WillOnce(SaveArg<1>(&target_callback)); ScheduleObservations(PostInitializeFileObservations(), destination_observer);
diff --git a/content/browser/download/download_manager_impl.cc b/content/browser/download/download_manager_impl.cc index 77ebc5fe..c788efe 100644 --- a/content/browser/download/download_manager_impl.cc +++ b/content/browser/download/download_manager_impl.cc
@@ -29,6 +29,7 @@ #include "components/download/public/common/download_file.h" #include "components/download/public/common/download_file_factory.h" #include "components/download/public/common/download_interrupt_reasons.h" +#include "components/download/public/common/download_item_impl.h" #include "components/download/public/common/download_request_handle_interface.h" #include "components/download/public/common/download_stats.h" #include "components/download/public/common/download_task_runner.h" @@ -40,7 +41,6 @@ #include "content/browser/child_process_security_policy_impl.h" #include "content/browser/download/byte_stream_input_stream.h" #include "content/browser/download/download_item_factory.h" -#include "content/browser/download/download_item_impl.h" #include "content/browser/download/download_resource_handler.h" #include "content/browser/download/download_utils.h" #include "content/browser/download/url_downloader.h" @@ -260,8 +260,8 @@ DownloadItemFactoryImpl() {} ~DownloadItemFactoryImpl() override {} - DownloadItemImpl* CreatePersistedItem( - DownloadItemImplDelegate* delegate, + download::DownloadItemImpl* CreatePersistedItem( + download::DownloadItemImplDelegate* delegate, const std::string& guid, uint32_t download_id, const base::FilePath& current_path, @@ -288,7 +288,7 @@ bool transient, const std::vector<download::DownloadItem::ReceivedSlice>& received_slices) override { - return new DownloadItemImpl( + return new download::DownloadItemImpl( delegate, guid, download_id, current_path, target_path, url_chain, referrer_url, site_url, tab_url, tab_refererr_url, mime_type, original_mime_type, start_time, end_time, etag, last_modified, @@ -296,23 +296,23 @@ opened, last_access_time, transient, received_slices); } - DownloadItemImpl* CreateActiveItem( - DownloadItemImplDelegate* delegate, + download::DownloadItemImpl* CreateActiveItem( + download::DownloadItemImplDelegate* delegate, uint32_t download_id, const download::DownloadCreateInfo& info) override { - return new DownloadItemImpl(delegate, download_id, info); + return new download::DownloadItemImpl(delegate, download_id, info); } - DownloadItemImpl* CreateSavePageItem( - DownloadItemImplDelegate* delegate, + download::DownloadItemImpl* CreateSavePageItem( + download::DownloadItemImplDelegate* delegate, uint32_t download_id, const base::FilePath& path, const GURL& url, const std::string& mime_type, std::unique_ptr<download::DownloadRequestHandleInterface> request_handle) override { - return new DownloadItemImpl(delegate, download_id, path, url, mime_type, - std::move(request_handle)); + return new download::DownloadItemImpl(delegate, download_id, path, url, + mime_type, std::move(request_handle)); } }; @@ -419,12 +419,13 @@ download::SetIOTaskRunner(nullptr); } -DownloadItemImpl* DownloadManagerImpl::CreateActiveItem( +download::DownloadItemImpl* DownloadManagerImpl::CreateActiveItem( uint32_t id, const download::DownloadCreateInfo& info) { DCHECK_CURRENTLY_ON(BrowserThread::UI); DCHECK(!base::ContainsKey(downloads_, id)); - DownloadItemImpl* download = item_factory_->CreateActiveItem(this, id, info); + download::DownloadItemImpl* download = + item_factory_->CreateActiveItem(this, id, info); downloads_[id] = base::WrapUnique(download); downloads_by_guid_[download->GetGuid()] = download; @@ -442,7 +443,8 @@ } void DownloadManagerImpl::DetermineDownloadTarget( - DownloadItemImpl* item, const DownloadTargetCallback& callback) { + download::DownloadItemImpl* item, + const DownloadTargetCallback& callback) { // Note that this next call relies on // DownloadItemImplDelegate::DownloadTargetCallback and // DownloadManagerDelegate::DownloadTargetCallback having the same @@ -459,7 +461,8 @@ } bool DownloadManagerImpl::ShouldCompleteDownload( - DownloadItemImpl* item, const base::Closure& complete_callback) { + download::DownloadItemImpl* item, + const base::Closure& complete_callback) { if (!delegate_ || delegate_->ShouldCompleteDownload(item, complete_callback)) { return true; @@ -478,7 +481,8 @@ } bool DownloadManagerImpl::ShouldOpenDownload( - DownloadItemImpl* item, const ShouldOpenDownloadCallback& callback) { + download::DownloadItemImpl* item, + const ShouldOpenDownloadCallback& callback) { if (!delegate_) return true; @@ -533,7 +537,7 @@ // accepted or discarded. Canceling will remove the intermediate download // file. for (const auto& it : downloads_) { - DownloadItemImpl* download = it.second.get(); + download::DownloadItemImpl* download = it.second.get(); if (download->GetState() == download::DownloadItem::IN_PROGRESS) download->Cancel(false); } @@ -609,7 +613,7 @@ uint32_t id) { DCHECK_CURRENTLY_ON(BrowserThread::UI); DCHECK_NE(download::DownloadItem::kInvalidId, id); - DownloadItemImpl* download = nullptr; + download::DownloadItemImpl* download = nullptr; if (new_download) { download = CreateActiveItem(id, *info); } else { @@ -720,12 +724,13 @@ void DownloadManagerImpl::CheckForHistoryFilesRemoval() { DCHECK_CURRENTLY_ON(BrowserThread::UI); for (const auto& it : downloads_) { - DownloadItemImpl* item = it.second.get(); + download::DownloadItemImpl* item = it.second.get(); CheckForFileRemoval(item); } } -void DownloadManagerImpl::CheckForFileRemoval(DownloadItemImpl* download_item) { +void DownloadManagerImpl::CheckForFileRemoval( + download::DownloadItemImpl* download_item) { DCHECK_CURRENTLY_ON(BrowserThread::UI); if ((download_item->GetState() == download::DownloadItem::COMPLETE) && !download_item->GetFileExternallyRemoved() && delegate_) { @@ -785,7 +790,7 @@ DCHECK_CURRENTLY_ON(BrowserThread::UI); DCHECK_NE(download::DownloadItem::kInvalidId, id); DCHECK(!base::ContainsKey(downloads_, id)); - DownloadItemImpl* download_item = item_factory_->CreateSavePageItem( + download::DownloadItemImpl* download_item = item_factory_->CreateSavePageItem( this, id, main_file_path, page_url, mime_type, std::move(request_handle)); DownloadItemUtils::AttachInfo(download_item, GetBrowserContext(), WebContentsImpl::FromRenderFrameHostID( @@ -846,7 +851,8 @@ return file_factory_.get(); } -void DownloadManagerImpl::DownloadRemoved(DownloadItemImpl* download) { +void DownloadManagerImpl::DownloadRemoved( + download::DownloadItemImpl* download) { if (!download) return; @@ -854,7 +860,8 @@ downloads_.erase(download->GetId()); } -void DownloadManagerImpl::DownloadInterrupted(DownloadItemImpl* download) { +void DownloadManagerImpl::DownloadInterrupted( + download::DownloadItemImpl* download) { WebContents* web_contents = DownloadItemUtils::GetWebContents(download); if (!web_contents) { download::RecordDownloadCountWithSource( @@ -863,7 +870,7 @@ } base::Optional<download::DownloadEntry> DownloadManagerImpl::GetInProgressEntry( - DownloadItemImpl* download) { + download::DownloadItemImpl* download) { if (!download || !delegate_) return base::Optional<download::DownloadEntry>(); @@ -878,7 +885,8 @@ return browser_context_->IsOffTheRecord(); } -void DownloadManagerImpl::ReportBytesWasted(DownloadItemImpl* download) { +void DownloadManagerImpl::ReportBytesWasted( + download::DownloadItemImpl* download) { if (!delegate_) return; auto entry_opt = GetInProgressEntry(download); @@ -995,7 +1003,7 @@ int count = 0; auto it = downloads_.begin(); while (it != downloads_.end()) { - DownloadItemImpl* download = it->second.get(); + download::DownloadItemImpl* download = it->second.get(); // Increment done here to protect against invalidation below. ++it; @@ -1074,7 +1082,7 @@ return nullptr; } DCHECK(!base::ContainsKey(downloads_by_guid_, guid)); - DownloadItemImpl* item = item_factory_->CreatePersistedItem( + download::DownloadItemImpl* item = item_factory_->CreatePersistedItem( this, guid, id, current_path, target_path, url_chain, referrer_url, site_url, tab_url, tab_refererr_url, mime_type, original_mime_type, start_time, end_time, etag, last_modified, received_bytes, total_bytes, @@ -1187,10 +1195,10 @@ } } -void DownloadManagerImpl::OpenDownload(DownloadItemImpl* download) { +void DownloadManagerImpl::OpenDownload(download::DownloadItemImpl* download) { int num_unopened = 0; for (const auto& it : downloads_) { - DownloadItemImpl* item = it.second.get(); + download::DownloadItemImpl* item = it.second.get(); if ((item->GetState() == download::DownloadItem::COMPLETE) && !item->GetOpened()) ++num_unopened; @@ -1202,12 +1210,13 @@ } bool DownloadManagerImpl::IsMostRecentDownloadItemAtFilePath( - DownloadItemImpl* download) { + download::DownloadItemImpl* download) { return delegate_ ? delegate_->IsMostRecentDownloadItemAtFilePath(download) : false; } -void DownloadManagerImpl::ShowDownloadInShell(DownloadItemImpl* download) { +void DownloadManagerImpl::ShowDownloadInShell( + download::DownloadItemImpl* download) { if (delegate_) delegate_->ShowDownloadInShell(download); }
diff --git a/content/browser/download/download_manager_impl.h b/content/browser/download/download_manager_impl.h index c0db4a6..b97db191 100644 --- a/content/browser/download/download_manager_impl.h +++ b/content/browser/download/download_manager_impl.h
@@ -20,9 +20,9 @@ #include "base/observer_list.h" #include "base/sequenced_task_runner_helpers.h" #include "base/synchronization/lock.h" +#include "components/download/public/common/download_item_impl_delegate.h" #include "components/download/public/common/download_url_parameters.h" #include "components/download/public/common/url_download_handler.h" -#include "content/browser/download/download_item_impl_delegate.h" #include "content/browser/loader/navigation_url_loader.h" #include "content/common/content_export.h" #include "content/public/browser/browser_thread.h" @@ -34,12 +34,12 @@ namespace download { class DownloadFileFactory; +class DownloadItemImpl; class DownloadRequestHandleInterface; } namespace content { class DownloadItemFactory; -class DownloadItemImpl; class ResourceContext; class StoragePartitionImpl; class URLLoaderFactoryGetter; @@ -47,9 +47,10 @@ class CONTENT_EXPORT DownloadManagerImpl : public DownloadManager, public download::UrlDownloadHandler::Delegate, - private DownloadItemImplDelegate { + private download::DownloadItemImplDelegate { public: - using DownloadItemImplCreated = base::Callback<void(DownloadItemImpl*)>; + using DownloadItemImplCreated = + base::Callback<void(download::DownloadItemImpl*)>; // Caller guarantees that |net_log| will remain valid // for the lifetime of DownloadManagerImpl (until Shutdown() is called). @@ -172,8 +173,9 @@ private: using DownloadSet = std::set<download::DownloadItem*>; - using DownloadGuidMap = std::unordered_map<std::string, DownloadItemImpl*>; - using DownloadItemImplVector = std::vector<DownloadItemImpl*>; + using DownloadGuidMap = + std::unordered_map<std::string, download::DownloadItemImpl*>; + using DownloadItemImplVector = std::vector<download::DownloadItemImpl*>; // For testing. friend class DownloadManagerTest; @@ -204,8 +206,9 @@ // Create a new active item based on the info. Separate from // StartDownload() for testing. - DownloadItemImpl* CreateActiveItem(uint32_t id, - const download::DownloadCreateInfo& info); + download::DownloadItemImpl* CreateActiveItem( + uint32_t id, + const download::DownloadCreateInfo& info); // Get next download id. |callback| is called on the UI thread and may // be called synchronously. @@ -218,28 +221,29 @@ // Overridden from DownloadItemImplDelegate // (Note that |GetBrowserContext| are present in both interfaces.) - void DetermineDownloadTarget(DownloadItemImpl* item, + void DetermineDownloadTarget(download::DownloadItemImpl* item, const DownloadTargetCallback& callback) override; - bool ShouldCompleteDownload(DownloadItemImpl* item, + bool ShouldCompleteDownload(download::DownloadItemImpl* item, const base::Closure& complete_callback) override; bool ShouldOpenFileBasedOnExtension(const base::FilePath& path) override; - bool ShouldOpenDownload(DownloadItemImpl* item, + bool ShouldOpenDownload(download::DownloadItemImpl* item, const ShouldOpenDownloadCallback& callback) override; - void CheckForFileRemoval(DownloadItemImpl* download_item) override; + void CheckForFileRemoval(download::DownloadItemImpl* download_item) override; std::string GetApplicationClientIdForFileScanning() const override; void ResumeInterruptedDownload( std::unique_ptr<download::DownloadUrlParameters> params, uint32_t id, const GURL& site_url) override; - void OpenDownload(DownloadItemImpl* download) override; - bool IsMostRecentDownloadItemAtFilePath(DownloadItemImpl* download) override; - void ShowDownloadInShell(DownloadItemImpl* download) override; - void DownloadRemoved(DownloadItemImpl* download) override; - void DownloadInterrupted(DownloadItemImpl* download) override; + void OpenDownload(download::DownloadItemImpl* download) override; + bool IsMostRecentDownloadItemAtFilePath( + download::DownloadItemImpl* download) override; + void ShowDownloadInShell(download::DownloadItemImpl* download) override; + void DownloadRemoved(download::DownloadItemImpl* download) override; + void DownloadInterrupted(download::DownloadItemImpl* download) override; base::Optional<download::DownloadEntry> GetInProgressEntry( - DownloadItemImpl* download) override; + download::DownloadItemImpl* download) override; bool IsOffTheRecord() const override; - void ReportBytesWasted(DownloadItemImpl* download) override; + void ReportBytesWasted(download::DownloadItemImpl* download) override; // Helper method to start or resume a download. void BeginDownloadInternal( @@ -289,7 +293,8 @@ // "save page as" downloads. // TODO(asanka): Remove this container in favor of downloads_by_guid_ as a // part of http://crbug.com/593020. - std::unordered_map<uint32_t, std::unique_ptr<DownloadItemImpl>> downloads_; + std::unordered_map<uint32_t, std::unique_ptr<download::DownloadItemImpl>> + downloads_; // Same as the above, but maps from GUID to download item. Note that the // container is case sensitive. Hence the key needs to be normalized to
diff --git a/content/browser/download/download_manager_impl_unittest.cc b/content/browser/download/download_manager_impl_unittest.cc index dd88e88..59340f3 100644 --- a/content/browser/download/download_manager_impl_unittest.cc +++ b/content/browser/download/download_manager_impl_unittest.cc
@@ -28,13 +28,13 @@ #include "components/download/public/common/download_file_factory.h" #include "components/download/public/common/download_interrupt_reasons.h" #include "components/download/public/common/download_item.h" +#include "components/download/public/common/download_item_impl.h" +#include "components/download/public/common/download_item_impl_delegate.h" #include "components/download/public/common/download_request_handle_interface.h" #include "components/download/public/common/mock_download_file.h" #include "content/browser/byte_stream.h" #include "content/browser/download/byte_stream_input_stream.h" #include "content/browser/download/download_item_factory.h" -#include "content/browser/download/download_item_impl.h" -#include "content/browser/download/download_item_impl_delegate.h" #include "content/browser/download/mock_download_item_impl.h" #include "content/public/browser/browser_context.h" #include "content/public/browser/download_manager_delegate.h" @@ -123,8 +123,8 @@ void SetHasObserverCalls(bool observer_calls); // Overridden methods from DownloadItemFactory. - DownloadItemImpl* CreatePersistedItem( - DownloadItemImplDelegate* delegate, + download::DownloadItemImpl* CreatePersistedItem( + download::DownloadItemImplDelegate* delegate, const std::string& guid, uint32_t download_id, const base::FilePath& current_path, @@ -151,12 +151,12 @@ bool transient, const std::vector<download::DownloadItem::ReceivedSlice>& received_slices) override; - DownloadItemImpl* CreateActiveItem( - DownloadItemImplDelegate* delegate, + download::DownloadItemImpl* CreateActiveItem( + download::DownloadItemImplDelegate* delegate, uint32_t download_id, const download::DownloadCreateInfo& info) override; - DownloadItemImpl* CreateSavePageItem( - DownloadItemImplDelegate* delegate, + download::DownloadItemImpl* CreateSavePageItem( + download::DownloadItemImplDelegate* delegate, uint32_t download_id, const base::FilePath& path, const GURL& url, @@ -166,7 +166,7 @@ private: std::map<uint32_t, MockDownloadItemImpl*> items_; - DownloadItemImplDelegate item_delegate_; + download::DownloadItemImplDelegate item_delegate_; bool has_observer_calls_; DISALLOW_COPY_AND_ASSIGN(MockDownloadItemFactory); @@ -203,8 +203,8 @@ has_observer_calls_ = has_observer_calls; } -DownloadItemImpl* MockDownloadItemFactory::CreatePersistedItem( - DownloadItemImplDelegate* delegate, +download::DownloadItemImpl* MockDownloadItemFactory::CreatePersistedItem( + download::DownloadItemImplDelegate* delegate, const std::string& guid, uint32_t download_id, const base::FilePath& current_path, @@ -240,8 +240,8 @@ return result; } -DownloadItemImpl* MockDownloadItemFactory::CreateActiveItem( - DownloadItemImplDelegate* delegate, +download::DownloadItemImpl* MockDownloadItemFactory::CreateActiveItem( + download::DownloadItemImplDelegate* delegate, uint32_t download_id, const download::DownloadCreateInfo& info) { DCHECK(items_.find(download_id) == items_.end()); @@ -267,8 +267,8 @@ return result; } -DownloadItemImpl* MockDownloadItemFactory::CreateSavePageItem( - DownloadItemImplDelegate* delegate, +download::DownloadItemImpl* MockDownloadItemFactory::CreateSavePageItem( + download::DownloadItemImplDelegate* delegate, uint32_t download_id, const base::FilePath& path, const GURL& url, @@ -446,7 +446,7 @@ interrupt_reason_ = interrupt_reason; } - void DetermineDownloadTarget(DownloadItemImpl* item) { + void DetermineDownloadTarget(download::DownloadItemImpl* item) { download_manager_->DetermineDownloadTarget( item, base::Bind( &DownloadManagerTest::DownloadTargetDeterminedCallback,
diff --git a/content/browser/download/download_request_core_unittest.cc b/content/browser/download/download_request_core_unittest.cc index 020b4d2..9daa2e9 100644 --- a/content/browser/download/download_request_core_unittest.cc +++ b/content/browser/download/download_request_core_unittest.cc
@@ -6,8 +6,8 @@ #include "base/memory/ptr_util.h" #include "base/run_loop.h" +#include "components/download/public/common/download_item.h" #include "components/download/public/common/download_url_parameters.h" -#include "content/browser/download/download_item_impl.h" #include "content/browser/download/download_request_core.h" #include "content/public/browser/browser_thread.h" #include "content/public/test/test_browser_thread_bundle.h"
diff --git a/content/browser/download/download_utils.cc b/content/browser/download/download_utils.cc index 1c93efb..1da3d7f 100644 --- a/content/browser/download/download_utils.cc +++ b/content/browser/download/download_utils.cc
@@ -99,21 +99,4 @@ return request; } -base::Optional<download::DownloadEntry> GetInProgressEntry( - const std::string& guid, - BrowserContext* browser_context) { - base::Optional<download::DownloadEntry> entry; - if (!browser_context || guid.empty()) - return entry; - - auto* manager_delegate = browser_context->GetDownloadManagerDelegate(); - if (manager_delegate) { - download::InProgressCache* in_progress_cache = - manager_delegate->GetInProgressCache(); - if (in_progress_cache) - entry = in_progress_cache->RetrieveEntry(guid); - } - return entry; -} - } // namespace content
diff --git a/content/browser/download/download_utils.h b/content/browser/download/download_utils.h index 1b52010..df86cad 100644 --- a/content/browser/download/download_utils.h +++ b/content/browser/download/download_utils.h
@@ -11,7 +11,6 @@ #include "content/common/content_export.h" namespace download { -struct DownloadEntry; class DownloadUrlParameters; } // namespace download @@ -25,18 +24,12 @@ namespace content { -class BrowserContext; class ResourceContext; // Create a URLRequest from |params|. std::unique_ptr<net::URLRequest> CONTENT_EXPORT CreateURLRequestOnIOThread(download::DownloadUrlParameters* params); -// Get the entry based on |guid| from in progress cache. -CONTENT_EXPORT base::Optional<download::DownloadEntry> GetInProgressEntry( - const std::string& guid, - BrowserContext* browser_context); - storage::BlobStorageContext* BlobStorageContextGetter( ResourceContext* resource_context);
diff --git a/content/browser/download/drag_download_file_browsertest.cc b/content/browser/download/drag_download_file_browsertest.cc index 0dcadaf..f080504 100644 --- a/content/browser/download/drag_download_file_browsertest.cc +++ b/content/browser/download/drag_download_file_browsertest.cc
@@ -8,7 +8,6 @@ #include "base/memory/ref_counted.h" #include "base/message_loop/message_loop.h" #include "base/path_service.h" -#include "content/browser/download/download_item_impl.h" #include "content/browser/download/download_manager_impl.h" #include "content/browser/download/drag_download_file.h" #include "content/browser/download/drag_download_util.h"
diff --git a/content/browser/download/mock_download_item_impl.cc b/content/browser/download/mock_download_item_impl.cc index 674f2521..bb18fc7 100644 --- a/content/browser/download/mock_download_item_impl.cc +++ b/content/browser/download/mock_download_item_impl.cc
@@ -6,33 +6,35 @@ namespace content { -MockDownloadItemImpl::MockDownloadItemImpl(DownloadItemImplDelegate* delegate) - : DownloadItemImpl(delegate, - std::string("7d122682-55b5-4a47-a253-36cadc3e5bee"), - download::DownloadItem::kInvalidId, - base::FilePath(), - base::FilePath(), - std::vector<GURL>(), - GURL(), - GURL(), - GURL(), - GURL(), - "application/octet-stream", - "application/octet-stream", - base::Time(), - base::Time(), - std::string(), - std::string(), - 0, - 0, - std::string(), - download::DownloadItem::COMPLETE, - download::DOWNLOAD_DANGER_TYPE_NOT_DANGEROUS, - download::DOWNLOAD_INTERRUPT_REASON_NONE, - false, - base::Time(), - true, - download::DownloadItem::ReceivedSlices()) {} +MockDownloadItemImpl::MockDownloadItemImpl( + download::DownloadItemImplDelegate* delegate) + : download::DownloadItemImpl( + delegate, + std::string("7d122682-55b5-4a47-a253-36cadc3e5bee"), + download::DownloadItem::kInvalidId, + base::FilePath(), + base::FilePath(), + std::vector<GURL>(), + GURL(), + GURL(), + GURL(), + GURL(), + "application/octet-stream", + "application/octet-stream", + base::Time(), + base::Time(), + std::string(), + std::string(), + 0, + 0, + std::string(), + download::DownloadItem::COMPLETE, + download::DOWNLOAD_DANGER_TYPE_NOT_DANGEROUS, + download::DOWNLOAD_INTERRUPT_REASON_NONE, + false, + base::Time(), + true, + download::DownloadItem::ReceivedSlices()) {} MockDownloadItemImpl::~MockDownloadItemImpl() = default;
diff --git a/content/browser/download/mock_download_item_impl.h b/content/browser/download/mock_download_item_impl.h index 9854dacd..d0eb549 100644 --- a/content/browser/download/mock_download_item_impl.h +++ b/content/browser/download/mock_download_item_impl.h
@@ -12,18 +12,18 @@ #include "base/macros.h" #include "components/download/public/common/download_create_info.h" #include "components/download/public/common/download_file.h" +#include "components/download/public/common/download_item_impl.h" #include "components/download/public/common/download_request_handle_interface.h" -#include "content/browser/download/download_item_impl.h" #include "testing/gmock/include/gmock/gmock.h" namespace content { class DownloadManager; -class MockDownloadItemImpl : public DownloadItemImpl { +class MockDownloadItemImpl : public download::DownloadItemImpl { public: // Use history constructor for minimal base object. - explicit MockDownloadItemImpl(DownloadItemImplDelegate* delegate); + explicit MockDownloadItemImpl(download::DownloadItemImplDelegate* delegate); ~MockDownloadItemImpl() override; MOCK_METHOD5(OnDownloadTargetDetermined,
diff --git a/content/browser/download/save_package.cc b/content/browser/download/save_package.cc index 3c82319..ce081e9 100644 --- a/content/browser/download/save_package.cc +++ b/content/browser/download/save_package.cc
@@ -24,6 +24,7 @@ #include "base/threading/thread.h" #include "base/threading/thread_restrictions.h" #include "build/build_config.h" +#include "components/download/public/common/download_item_impl.h" #include "components/download/public/common/download_request_handle_interface.h" #include "components/download/public/common/download_stats.h" #include "components/download/public/common/download_task_runner.h" @@ -31,7 +32,6 @@ #include "components/filename_generation/filename_generation.h" #include "components/url_formatter/url_formatter.h" #include "content/browser/bad_message.h" -#include "content/browser/download/download_item_impl.h" #include "content/browser/download/download_manager_impl.h" #include "content/browser/download/save_file.h" #include "content/browser/download/save_file_manager.h" @@ -297,7 +297,7 @@ void SavePackage::InitWithDownloadItem( const SavePackageDownloadCreatedCallback& download_created_callback, - DownloadItemImpl* item) { + download::DownloadItemImpl* item) { DCHECK_CURRENTLY_ON(BrowserThread::UI); DCHECK(item); download_ = item;
diff --git a/content/browser/download/save_package.h b/content/browser/download/save_package.h index f09df9c..d4ad79aec 100644 --- a/content/browser/download/save_package.h +++ b/content/browser/download/save_package.h
@@ -34,8 +34,11 @@ class GURL; -namespace content { +namespace download { class DownloadItemImpl; +} + +namespace content { class DownloadManagerImpl; class FrameTreeNode; class RenderFrameHostImpl; @@ -156,7 +159,7 @@ void InitWithDownloadItem( const SavePackageDownloadCreatedCallback& download_created_callback, - DownloadItemImpl* item); + download::DownloadItemImpl* item); // Callback for WebContents::GenerateMHTML(). void OnMHTMLGenerated(int64_t size); @@ -369,7 +372,7 @@ // DownloadManager owns the download::DownloadItem and handles history and UI. DownloadManagerImpl* download_manager_ = nullptr; - DownloadItemImpl* download_ = nullptr; + download::DownloadItemImpl* download_ = nullptr; // The URL of the page the user wants to save. const GURL page_url_;
diff --git a/content/browser/frame_host/navigation_request.cc b/content/browser/frame_host/navigation_request.cc index d8fcc7a4..439754d 100644 --- a/content/browser/frame_host/navigation_request.cc +++ b/content/browser/frame_host/navigation_request.cc
@@ -313,7 +313,8 @@ mojom::BeginNavigationParamsPtr begin_params, int current_history_list_offset, int current_history_list_length, - bool override_user_agent) { + bool override_user_agent, + scoped_refptr<network::SharedURLLoaderFactory> blob_url_loader_factory) { // Only normal navigations to a different document or reloads are expected. // - Renderer-initiated fragment-navigations never take place in the browser, // even with PlzNavigate. @@ -348,6 +349,8 @@ true, // from_begin_navigation nullptr, entry, nullptr)); // navigation_ui_data + navigation_request->blob_url_loader_factory_ = + std::move(blob_url_loader_factory); return navigation_request; } @@ -1216,7 +1219,9 @@ frame_tree_node_->frame_tree_node_id(), is_for_guests_only, report_raw_headers, navigating_frame_host->GetVisibilityState() == - blink::mojom::PageVisibilityState::kPrerender), + blink::mojom::PageVisibilityState::kPrerender, + blob_url_loader_factory_ ? blob_url_loader_factory_->Clone() + : nullptr), std::move(navigation_ui_data), navigation_handle_->service_worker_handle(), navigation_handle_->appcache_handle(), this);
diff --git a/content/browser/frame_host/navigation_request.h b/content/browser/frame_host/navigation_request.h index 75975ca4..7582a5e3 100644 --- a/content/browser/frame_host/navigation_request.h +++ b/content/browser/frame_host/navigation_request.h
@@ -107,7 +107,8 @@ mojom::BeginNavigationParamsPtr begin_params, int current_history_list_offset, int current_history_list_length, - bool override_user_agent); + bool override_user_agent, + scoped_refptr<network::SharedURLLoaderFactory> blob_url_loader_factory); ~NavigationRequest() override; @@ -335,6 +336,9 @@ // NavigationUIData at the beginning of the navigation. std::unique_ptr<NavigationUIData> navigation_ui_data_; + // URLLoaderFactory to facilitate loading blob URLs. + scoped_refptr<network::SharedURLLoaderFactory> blob_url_loader_factory_; + NavigationState state_; std::unique_ptr<NavigationURLLoader> loader_;
diff --git a/content/browser/frame_host/navigation_request_info.cc b/content/browser/frame_host/navigation_request_info.cc index 5909229f..4e918bf 100644 --- a/content/browser/frame_host/navigation_request_info.cc +++ b/content/browser/frame_host/navigation_request_info.cc
@@ -18,7 +18,9 @@ int frame_tree_node_id, bool is_for_guests_only, bool report_raw_headers, - bool is_prerendering) + bool is_prerendering, + std::unique_ptr<network::SharedURLLoaderFactoryInfo> + blob_url_loader_factory) : common_params(common_params), begin_params(std::move(begin_params)), site_for_cookies(site_for_cookies), @@ -28,7 +30,8 @@ frame_tree_node_id(frame_tree_node_id), is_for_guests_only(is_for_guests_only), report_raw_headers(report_raw_headers), - is_prerendering(is_prerendering) {} + is_prerendering(is_prerendering), + blob_url_loader_factory(std::move(blob_url_loader_factory)) {} NavigationRequestInfo::NavigationRequestInfo(const NavigationRequestInfo& other) : common_params(other.common_params),
diff --git a/content/browser/frame_host/navigation_request_info.h b/content/browser/frame_host/navigation_request_info.h index dc2aba1..47dbca1 100644 --- a/content/browser/frame_host/navigation_request_info.h +++ b/content/browser/frame_host/navigation_request_info.h
@@ -12,6 +12,7 @@ #include "content/common/navigation_params.h" #include "content/common/navigation_params.mojom.h" #include "content/public/common/referrer.h" +#include "services/network/public/cpp/shared_url_loader_factory.h" #include "url/gurl.h" #include "url/origin.h" @@ -30,7 +31,9 @@ int frame_tree_node_id, bool is_for_guests_only, bool report_raw_headers, - bool is_prerendering); + bool is_prerendering, + std::unique_ptr<network::SharedURLLoaderFactoryInfo> + blob_url_loader_factory); NavigationRequestInfo(const NavigationRequestInfo& other); ~NavigationRequestInfo(); @@ -55,6 +58,9 @@ const bool report_raw_headers; const bool is_prerendering; + + // URLLoaderFactory to facilitate loading blob URLs. + std::unique_ptr<network::SharedURLLoaderFactoryInfo> blob_url_loader_factory; }; } // namespace content
diff --git a/content/browser/frame_host/navigator.cc b/content/browser/frame_host/navigator.cc index a945fbc..ff6457f3 100644 --- a/content/browser/frame_host/navigator.cc +++ b/content/browser/frame_host/navigator.cc
@@ -38,6 +38,7 @@ void Navigator::OnBeginNavigation( FrameTreeNode* frame_tree_node, const CommonNavigationParams& common_params, - mojom::BeginNavigationParamsPtr begin_params) {} + mojom::BeginNavigationParamsPtr begin_params, + scoped_refptr<network::SharedURLLoaderFactory> blob_url_loader_factory) {} } // namespace content
diff --git a/content/browser/frame_host/navigator.h b/content/browser/frame_host/navigator.h index e93b664..ec12c59 100644 --- a/content/browser/frame_host/navigator.h +++ b/content/browser/frame_host/navigator.h
@@ -159,9 +159,11 @@ // Used to start a new renderer-initiated navigation, following a // BeginNavigation IPC from the renderer. - virtual void OnBeginNavigation(FrameTreeNode* frame_tree_node, - const CommonNavigationParams& common_params, - mojom::BeginNavigationParamsPtr begin_params); + virtual void OnBeginNavigation( + FrameTreeNode* frame_tree_node, + const CommonNavigationParams& common_params, + mojom::BeginNavigationParamsPtr begin_params, + scoped_refptr<network::SharedURLLoaderFactory> blob_url_loader_factory); // Used to restart a navigation that was thought to be same-document in // cross-document mode.
diff --git a/content/browser/frame_host/navigator_impl.cc b/content/browser/frame_host/navigator_impl.cc index 4d23d40..bb33fd3 100644 --- a/content/browser/frame_host/navigator_impl.cc +++ b/content/browser/frame_host/navigator_impl.cc
@@ -849,7 +849,8 @@ void NavigatorImpl::OnBeginNavigation( FrameTreeNode* frame_tree_node, const CommonNavigationParams& common_params, - mojom::BeginNavigationParamsPtr begin_params) { + mojom::BeginNavigationParamsPtr begin_params, + scoped_refptr<network::SharedURLLoaderFactory> blob_url_loader_factory) { // TODO(clamy): the url sent by the renderer should be validated with // FilterURL. // This is a renderer-initiated navigation. @@ -909,7 +910,8 @@ NavigationRequest::CreateRendererInitiated( frame_tree_node, pending_entry, common_params, std::move(begin_params), controller_->GetLastCommittedEntryIndex(), - controller_->GetEntryCount(), override_user_agent)); + controller_->GetEntryCount(), override_user_agent, + std::move(blob_url_loader_factory))); NavigationRequest* navigation_request = frame_tree_node->navigation_request(); // For main frames, NavigationHandle will be created after the call to
diff --git a/content/browser/frame_host/navigator_impl.h b/content/browser/frame_host/navigator_impl.h index 07a1a12..b1bb76b 100644 --- a/content/browser/frame_host/navigator_impl.h +++ b/content/browser/frame_host/navigator_impl.h
@@ -95,7 +95,9 @@ const base::TimeTicks& proceed_time) override; void OnBeginNavigation(FrameTreeNode* frame_tree_node, const CommonNavigationParams& common_params, - mojom::BeginNavigationParamsPtr begin_params) override; + mojom::BeginNavigationParamsPtr begin_params, + scoped_refptr<network::SharedURLLoaderFactory> + blob_url_loader_factory) override; void RestartNavigationAsCrossDocument( std::unique_ptr<NavigationRequest> navigation_request) override; void OnAbortNavigation(FrameTreeNode* frame_tree_node) override;
diff --git a/content/browser/frame_host/render_frame_host_impl.cc b/content/browser/frame_host/render_frame_host_impl.cc index 36cb381..737b1871 100644 --- a/content/browser/frame_host/render_frame_host_impl.cc +++ b/content/browser/frame_host/render_frame_host_impl.cc
@@ -105,6 +105,7 @@ #include "content/common/swapped_out_messages.h" #include "content/common/url_loader_factory_bundle.mojom.h" #include "content/common/widget.mojom.h" +#include "content/common/wrapper_shared_url_loader_factory.h" #include "content/public/browser/ax_event_notification_details.h" #include "content/public/browser/browser_accessibility_state.h" #include "content/public/browser/browser_context.h" @@ -151,6 +152,8 @@ #include "services/resource_coordinator/public/cpp/resource_coordinator_features.h" #include "services/service_manager/public/cpp/connector.h" #include "services/service_manager/public/cpp/interface_provider.h" +#include "storage/browser/blob/blob_storage_context.h" +#include "storage/browser/blob/blob_url_loader_factory.h" #include "third_party/WebKit/public/common/feature_policy/feature_policy.h" #include "third_party/WebKit/public/common/frame/frame_policy.h" #include "third_party/WebKit/public/mojom/page/page_visibility_state.mojom.h" @@ -376,6 +379,16 @@ } // namespace +RenderFrameHostImpl::PendingNavigation::PendingNavigation( + const CommonNavigationParams& common_params, + mojom::BeginNavigationParamsPtr begin_params, + scoped_refptr<network::SharedURLLoaderFactory> blob_url_loader_factory) + : common_params(common_params), + begin_params(std::move(begin_params)), + blob_url_loader_factory(std::move(blob_url_loader_factory)) {} + +RenderFrameHostImpl::PendingNavigation::~PendingNavigation() = default; + class RenderFrameHostImpl::DroppedInterfaceRequestLogger : public service_manager::mojom::InterfaceProvider { public: @@ -1285,6 +1298,8 @@ render_widget_host_->SetWidgetInputHandler(std::move(widget_handler), std::move(host_request)); } + render_widget_host_->input_router()->SetFrameTreeNodeId( + frame_tree_node_->frame_tree_node_id()); viz::mojom::InputTargetClientPtr input_target_client; remote_interfaces_->GetInterface(&input_target_client); input_target_client_ = input_target_client.get(); @@ -1307,8 +1322,9 @@ waiting_for_init_ = false; if (pending_navigate_) { frame_tree_node()->navigator()->OnBeginNavigation( - frame_tree_node(), pending_navigate_->first, - std::move(pending_navigate_->second)); + frame_tree_node(), pending_navigate_->common_params, + std::move(pending_navigate_->begin_params), + std::move(pending_navigate_->blob_url_loader_factory)); pending_navigate_.reset(); } } @@ -3014,7 +3030,8 @@ // otherwise mojo bad message reporting. void RenderFrameHostImpl::BeginNavigation( const CommonNavigationParams& common_params, - mojom::BeginNavigationParamsPtr begin_params) { + mojom::BeginNavigationParamsPtr begin_params, + blink::mojom::BlobURLTokenPtr blob_url_token) { if (!is_active()) return; @@ -3045,14 +3062,27 @@ return; } + if (blob_url_token && !validated_params.url.SchemeIsBlob()) { + mojo::ReportBadMessage("Blob URL Token, but not a blob: URL"); + return; + } + scoped_refptr<network::SharedURLLoaderFactory> blob_url_loader_factory; + if (blob_url_token) { + blob_url_loader_factory = + ChromeBlobStorageContext::URLLoaderFactoryForToken( + GetSiteInstance()->GetBrowserContext(), std::move(blob_url_token)); + } + if (waiting_for_init_) { pending_navigate_ = std::make_unique<PendingNavigation>( - validated_params, std::move(begin_params)); + validated_params, std::move(begin_params), + std::move(blob_url_loader_factory)); return; } frame_tree_node()->navigator()->OnBeginNavigation( - frame_tree_node(), validated_params, std::move(begin_params)); + frame_tree_node(), validated_params, std::move(begin_params), + std::move(blob_url_loader_factory)); } void RenderFrameHostImpl::SubresourceResponseStarted(
diff --git a/content/browser/frame_host/render_frame_host_impl.h b/content/browser/frame_host/render_frame_host_impl.h index 8f095954..8d156df 100644 --- a/content/browser/frame_host/render_frame_host_impl.h +++ b/content/browser/frame_host/render_frame_host_impl.h
@@ -897,7 +897,8 @@ std::unique_ptr<FrameHostMsg_DidCommitProvisionalLoad_Params> validated_params) override; void BeginNavigation(const CommonNavigationParams& common_params, - mojom::BeginNavigationParamsPtr begin_params) override; + mojom::BeginNavigationParamsPtr begin_params, + blink::mojom::BlobURLTokenPtr blob_url_token) override; void SubresourceResponseStarted(const GURL& url, net::CertStatus cert_status) override; void ResourceLoadComplete( @@ -1381,8 +1382,16 @@ // If true then this frame's document has a focused element which is editable. bool has_focused_editable_element_; - typedef std::pair<CommonNavigationParams, mojom::BeginNavigationParamsPtr> - PendingNavigation; + struct PendingNavigation { + PendingNavigation( + const CommonNavigationParams& common_params, + mojom::BeginNavigationParamsPtr begin_params, + scoped_refptr<network::SharedURLLoaderFactory> blob_url_loader_factory); + ~PendingNavigation(); + CommonNavigationParams common_params; + mojom::BeginNavigationParamsPtr begin_params; + scoped_refptr<network::SharedURLLoaderFactory> blob_url_loader_factory; + }; std::unique_ptr<PendingNavigation> pending_navigate_; // A collection of non-network URLLoaderFactory implementations which are used
diff --git a/content/browser/generic_sensor/generic_sensor_browsertest.cc b/content/browser/generic_sensor/generic_sensor_browsertest.cc index 7d2bbda..ec3dff1a5 100644 --- a/content/browser/generic_sensor/generic_sensor_browsertest.cc +++ b/content/browser/generic_sensor/generic_sensor_browsertest.cc
@@ -28,6 +28,7 @@ #include "services/device/public/cpp/generic_sensor/platform_sensor_configuration.h" #include "services/device/public/cpp/generic_sensor/sensor_reading.h" #include "services/device/public/cpp/generic_sensor/sensor_traits.h" +#include "services/device/public/cpp/test/fake_sensor_and_provider.h" #include "services/device/public/mojom/constants.mojom.h" #include "services/device/public/mojom/sensor.mojom.h" #include "services/device/public/mojom/sensor_provider.mojom.h" @@ -37,138 +38,7 @@ namespace { -class FakeAmbientLightSensor : public device::mojom::Sensor { - public: - FakeAmbientLightSensor() { - shared_buffer_handle_ = mojo::SharedBufferHandle::Create( - sizeof(device::SensorReadingSharedBuffer) * - static_cast<uint64_t>(device::mojom::SensorType::LAST)); - - if (!shared_buffer_handle_.is_valid()) - return; - - // Create read/write mapping now, to ensure it is kept writable - // after the region is sealed read-only on Android. - shared_buffer_mapping_ = shared_buffer_handle_->MapAtOffset( - device::mojom::SensorInitParams::kReadBufferSizeForTests, - GetBufferOffset()); - } - - ~FakeAmbientLightSensor() override = default; - - // device::mojom::Sensor implemenation: - void AddConfiguration( - const device::PlatformSensorConfiguration& configuration, - AddConfigurationCallback callback) override { - std::move(callback).Run(true); - SensorReadingChanged(); - } - - void GetDefaultConfiguration( - GetDefaultConfigurationCallback callback) override { - std::move(callback).Run(GetDefaultConfiguration()); - } - - void RemoveConfiguration( - const device::PlatformSensorConfiguration& configuration) override {} - - void Suspend() override {} - void Resume() override {} - void ConfigureReadingChangeNotifications(bool enabled) override {} - - device::PlatformSensorConfiguration GetDefaultConfiguration() { - return device::PlatformSensorConfiguration( - device::SensorTraits< - device::mojom::SensorType::AMBIENT_LIGHT>::kDefaultFrequency); - } - - device::mojom::ReportingMode GetReportingMode() { - return device::mojom::ReportingMode::ON_CHANGE; - } - - double GetMaximumSupportedFrequency() { - return device::SensorTraits< - device::mojom::SensorType::AMBIENT_LIGHT>::kMaxAllowedFrequency; - } - double GetMinimumSupportedFrequency() { return 1.0; } - - device::mojom::SensorClientRequest GetClient() { - return mojo::MakeRequest(&client_); - } - - mojo::ScopedSharedBufferHandle GetSharedBufferHandle() { - return shared_buffer_handle_->Clone( - mojo::SharedBufferHandle::AccessMode::READ_ONLY); - } - - uint64_t GetBufferOffset() { - return device::SensorReadingSharedBuffer::GetOffset( - device::mojom::SensorType::AMBIENT_LIGHT); - } - - void SensorReadingChanged() { - if (!shared_buffer_mapping_.get()) - return; - - device::SensorReading reading; - reading.als.timestamp = - (base::TimeTicks::Now() - base::TimeTicks()).InSecondsF(); - reading.als.value = 50; - - device::SensorReadingSharedBuffer* buffer = - static_cast<device::SensorReadingSharedBuffer*>( - shared_buffer_mapping_.get()); - auto& seqlock = buffer->seqlock.value(); - seqlock.WriteBegin(); - buffer->reading = reading; - seqlock.WriteEnd(); - - if (client_) - client_->SensorReadingChanged(); - } - - private: - mojo::ScopedSharedBufferHandle shared_buffer_handle_; - mojo::ScopedSharedBufferMapping shared_buffer_mapping_; - device::mojom::SensorClientPtr client_; - - DISALLOW_COPY_AND_ASSIGN(FakeAmbientLightSensor); -}; - -class FakeSensorProvider : public device::mojom::SensorProvider { - public: - FakeSensorProvider() = default; - ~FakeSensorProvider() override = default; - - // device::mojom::sensorProvider implementation. - void GetSensor(device::mojom::SensorType type, - GetSensorCallback callback) override { - switch (type) { - case device::mojom::SensorType::AMBIENT_LIGHT: { - auto sensor = std::make_unique<FakeAmbientLightSensor>(); - - auto init_params = device::mojom::SensorInitParams::New(); - init_params->client_request = sensor->GetClient(); - init_params->memory = sensor->GetSharedBufferHandle(); - init_params->buffer_offset = sensor->GetBufferOffset(); - init_params->default_configuration = sensor->GetDefaultConfiguration(); - init_params->maximum_frequency = sensor->GetMaximumSupportedFrequency(); - init_params->minimum_frequency = sensor->GetMinimumSupportedFrequency(); - - mojo::MakeStrongBinding(std::move(sensor), - mojo::MakeRequest(&init_params->sensor)); - std::move(callback).Run(device::mojom::SensorCreationResult::SUCCESS, - std::move(init_params)); - break; - } - default: - NOTIMPLEMENTED(); - } - } - - private: - DISALLOW_COPY_AND_ASSIGN(FakeSensorProvider); -}; +using device::FakeSensorProvider; class GenericSensorBrowserTest : public ContentBrowserTest { public: @@ -227,11 +97,12 @@ if (!sensor_provider_available_) return; - if (!fake_sensor_provider_) + if (!fake_sensor_provider_) { fake_sensor_provider_ = std::make_unique<FakeSensorProvider>(); + fake_sensor_provider_->SetAmbientLightSensorData(50); + } - sensor_provider_bindings_.AddBinding( - fake_sensor_provider_.get(), + fake_sensor_provider_->Bind( device::mojom::SensorProviderRequest(std::move(handle))); } @@ -247,7 +118,6 @@ base::WaitableEvent io_loop_finished_event_; bool sensor_provider_available_ = true; std::unique_ptr<FakeSensorProvider> fake_sensor_provider_; - mojo::BindingSet<device::mojom::SensorProvider> sensor_provider_bindings_; DISALLOW_COPY_AND_ASSIGN(GenericSensorBrowserTest); };
diff --git a/content/browser/loader/merkle_integrity_source_stream.cc b/content/browser/loader/merkle_integrity_source_stream.cc index 5dc5b7f..4643113 100644 --- a/content/browser/loader/merkle_integrity_source_stream.cc +++ b/content/browser/loader/merkle_integrity_source_stream.cc
@@ -4,9 +4,11 @@ #include "content/browser/loader/merkle_integrity_source_stream.h" +#include <string.h> + #include "base/base64url.h" #include "base/big_endian.h" -#include "crypto/sha2.h" +#include "base/numerics/safe_conversions.h" #include "net/base/io_buffer.h" namespace content { @@ -20,23 +22,32 @@ constexpr char kMiSha256Header[] = "mi-sha256="; constexpr size_t kMiSha256HeaderLength = sizeof(kMiSha256Header) - 1; +// Copies as many bytes from |input| as will fit in |output| and advances both. +size_t CopyClamped(base::span<const char>* input, base::span<char>* output) { + size_t size = std::min(output->size(), input->size()); + memcpy(output->data(), input->data(), size); + *output = output->subspan(size); + *input = input->subspan(size); + return size; +} + } // namespace MerkleIntegritySourceStream::MerkleIntegritySourceStream( base::StringPiece mi_header_value, std::unique_ptr<SourceStream> upstream) // TODO(ksakamoto): Use appropriate SourceType. - : net::FilterSourceStream(SourceStream::TYPE_NONE, std::move(upstream)), - record_size_(0), - failed_(false) { + : net::FilterSourceStream(SourceStream::TYPE_NONE, std::move(upstream)) { // TODO(ksakamoto): Support quoted parameter value. - if (mi_header_value.size() < kMiSha256HeaderLength || - mi_header_value.substr(0, kMiSha256HeaderLength) != kMiSha256Header || + std::string next_proof; + if (!mi_header_value.starts_with(kMiSha256Header) || !base::Base64UrlDecode(mi_header_value.substr(kMiSha256HeaderLength), base::Base64UrlDecodePolicy::DISALLOW_PADDING, - &next_proof_) || - next_proof_.size() != crypto::kSHA256Length) { + &next_proof) || + next_proof.size() != SHA256_DIGEST_LENGTH) { failed_ = true; + } else { + memcpy(next_proof_, next_proof.data(), SHA256_DIGEST_LENGTH); } } @@ -48,76 +59,180 @@ int input_buffer_size, int* consumed_bytes, bool upstream_eof_reached) { - if (failed_) - return net::ERR_CONTENT_DECODING_FAILED; - - // TODO(ksakamoto): Avoid unnecessary buffer copying. - input_.append(input_buffer->data(), input_buffer_size); - *consumed_bytes = input_buffer_size; - - if (!ProcessInput(upstream_eof_reached)) { - failed_ = true; + if (failed_) { return net::ERR_CONTENT_DECODING_FAILED; } - int bytes_out = - std::min(output_.size(), static_cast<size_t>(output_buffer_size)); - output_.copy(output_buffer->data(), bytes_out); - output_.erase(0, bytes_out); - return bytes_out; + base::span<const char> remaining_input = base::make_span( + input_buffer->data(), base::checked_cast<size_t>(input_buffer_size)); + base::span<char> remaining_output = base::make_span( + output_buffer->data(), base::checked_cast<size_t>(output_buffer_size)); + bool ok = + FilterDataImpl(&remaining_output, &remaining_input, upstream_eof_reached); + *consumed_bytes = + input_buffer_size - base::checked_cast<int>(remaining_input.size()); + if (!ok) { + failed_ = true; + return net::ERR_CONTENT_DECODING_FAILED; + } + return output_buffer_size - base::checked_cast<int>(remaining_output.size()); } -bool MerkleIntegritySourceStream::ProcessInput(bool upstream_eof_reached) { - // TODO(ksakamoto): Use shift iterator or StringPiece instead of substr/erase. +std::string MerkleIntegritySourceStream::GetTypeAsString() const { + return "MI-SHA256"; +} - // Read the record size (the first 8 octets of the stream). - if (!record_size_) { - if (input_.size() < 8) +bool MerkleIntegritySourceStream::FilterDataImpl(base::span<char>* output, + base::span<const char>* input, + bool upstream_eof_reached) { + std::string storage; + + // Process the record size in front, if we haven't yet. + if (record_size_ == 0) { + base::span<const char> bytes; + if (!ConsumeBytes(input, 8, &bytes, &storage)) { return !upstream_eof_reached; - - base::ReadBigEndian(input_.data(), &record_size_); - input_.erase(0, 8); - if (record_size_ == 0) + } + uint64_t record_size; + base::ReadBigEndian(bytes.data(), &record_size); + if (record_size == 0) { return false; - if (record_size_ > kMaxRecordSize) { + } + if (record_size > kMaxRecordSize) { DVLOG(1) << "Rejecting MI content encoding because record size is too big: " - << record_size_; + << record_size; + return false; + } + record_size_ = base::checked_cast<size_t>(record_size); + } + + // Clear any previous output before continuing. + if (!CopyPartialOutput(output)) { + DCHECK(output->empty()); + return true; + } + + // Process records until we're done or there's no more room in |output|. + while (!output->empty() && !final_record_done_) { + base::span<const char> record; + if (!ConsumeBytes(input, record_size_ + SHA256_DIGEST_LENGTH, &record, + &storage)) { + DCHECK(input->empty()); + if (!upstream_eof_reached) { + return true; // Wait for more data later. + } + + // The final record is shorter and does not contain a hash. Process all + // remaining input the final record. + // + // TODO(davidben): This matches the previous implementation in that it + // allows empty final records, but this does not match the specification + // and means some inputs have two valid encodings. However, the + // specification's version cannot represent the empty string. Update this + // when https://github.com/martinthomson/http-mice/issues/3 is resolved. + if (partial_input_.size() > record_size_) { + return false; + } + record = partial_input_; + final_record_done_ = true; + } + if (!ProcessRecord(record, final_record_done_, output)) { return false; } } - // Process records other than the last. - while (input_.size() >= record_size_ + crypto::kSHA256Length) { - std::string chunk = input_.substr(0, record_size_ + crypto::kSHA256Length); - input_.erase(0, record_size_ + crypto::kSHA256Length); - chunk.push_back('\x01'); - std::string hash = crypto::SHA256HashString(chunk); - if (next_proof_ != hash) - return false; - output_.append(chunk.substr(0, record_size_)); - next_proof_ = chunk.substr(record_size_, crypto::kSHA256Length); - } - - // Process the last record. - if (upstream_eof_reached && !next_proof_.empty()) { - if (input_.size() > record_size_) - return false; - - input_.push_back('\0'); - std::string hash = crypto::SHA256HashString(input_); - if (next_proof_ != hash) - return false; - - output_.append(input_.substr(0, input_.size() - 1)); - input_.clear(); - next_proof_.clear(); + if (final_record_done_) { + DCHECK(upstream_eof_reached); + DCHECK(input->empty()); } return true; } -std::string MerkleIntegritySourceStream::GetTypeAsString() const { - return "MI-256"; +bool MerkleIntegritySourceStream::CopyPartialOutput(base::span<char>* output) { + if (partial_output_offset_ == partial_output_.size()) { + return true; + } + base::span<const char> partial = + base::make_span(partial_output_).subspan(partial_output_offset_); + partial_output_offset_ += CopyClamped(&partial, output); + if (partial_output_offset_ < partial_output_.size()) { + return false; + } + partial_output_.clear(); + partial_output_offset_ = 0; + return true; +} + +bool MerkleIntegritySourceStream::ConsumeBytes(base::span<const char>* input, + size_t len, + base::span<const char>* result, + std::string* storage) { + // This comes from the requirement that, when ConsumeBytes returns false, the + // next call must use the same |len|. + DCHECK_LT(partial_input_.size(), len); + + // Return data directly from |input| if possible. + if (partial_input_.empty() && input->size() >= len) { + *result = input->subspan(0, len); + *input = input->subspan(len); + return true; + } + + // Reassemble |len| bytes from |partial_input_| and |input|. + size_t to_copy = std::min(len - partial_input_.size(), input->size()); + partial_input_.append(input->data(), to_copy); + *input = input->subspan(to_copy); + + if (partial_input_.size() < len) { + return false; + } + *storage = std::move(partial_input_); + partial_input_.clear(); + *result = *storage; + return true; +} + +bool MerkleIntegritySourceStream::ProcessRecord(base::span<const char> record, + bool is_final, + base::span<char>* output) { + DCHECK(partial_output_.empty()); + + // Check the hash. + SHA256_CTX ctx; + SHA256_Init(&ctx); + SHA256_Update(&ctx, reinterpret_cast<const uint8_t*>(record.data()), + record.size()); + uint8_t type = is_final ? 0 : 1; + SHA256_Update(&ctx, &type, 1); + uint8_t sha256[SHA256_DIGEST_LENGTH]; + SHA256_Final(sha256, &ctx); +#ifdef FUZZING_BUILD_MODE_UNSAFE_FOR_PRODUCTION + // The fuzzer will have a hard time fixing up chains of hashes, so, if + // building in fuzzer mode, everything hashes to the same garbage value. + memset(sha256, 0x42, SHA256_DIGEST_LENGTH); +#endif + if (memcmp(sha256, next_proof_, SHA256_DIGEST_LENGTH) != 0) { + return false; + } + + if (!is_final) { + // Split into data and a hash. + base::span<const char> hash = record.subspan(record_size_); + record = record.subspan(0, record_size_); + + // Save the next proof. + CHECK_EQ(static_cast<size_t>(SHA256_DIGEST_LENGTH), hash.size()); + memcpy(next_proof_, hash.data(), SHA256_DIGEST_LENGTH); + } + + // Copy whatever output there is room for. + CopyClamped(&record, output); + + // If it didn't all fit, save the remaining in |partial_output_|. + DCHECK(record.empty() || output->empty()); + partial_output_.append(record.data(), record.size()); + return true; } } // namespace content
diff --git a/content/browser/loader/merkle_integrity_source_stream.h b/content/browser/loader/merkle_integrity_source_stream.h index eda81c83..d255437 100644 --- a/content/browser/loader/merkle_integrity_source_stream.h +++ b/content/browser/loader/merkle_integrity_source_stream.h
@@ -8,10 +8,12 @@ #include <stdint.h> #include <string> +#include "base/containers/span.h" #include "base/macros.h" #include "base/strings/string_piece.h" #include "content/common/content_export.h" #include "net/filter/filter_source_stream.h" +#include "third_party/boringssl/src/include/openssl/sha.h" namespace content { @@ -36,14 +38,48 @@ std::string GetTypeAsString() const override; private: - bool ProcessInput(bool upstream_eof_reached); + // Processes as many bytes of |input| as are available or fit in + // |output|. Both |input| and |output| are advanced past any bytes consumed or + // written to, respectively. Returns true if all input processed, possibly + // none, was valid and false on fatal error. + bool FilterDataImpl(base::span<char>* output, + base::span<const char>* input, + bool upstream_eof_reached); - std::string input_; - std::string output_; - // SHA-256 hash for the next record, or empty if validation is completed. - std::string next_proof_; - uint64_t record_size_; - bool failed_; + // Copies |partial_output_| to output, as much as fits and advances both + // buffers. Returns whether all output was copied. + bool CopyPartialOutput(base::span<char>* output); + + // Consumes the next |len| bytes of data from |partial_input_| and |input| + // and, if available, points |result| to it and returns true. |result| will + // point into either |input| or data copied to |storage|. |input| is advanced + // past any consumed bytes. If |len| bytes are not available, returns false + // and fully consumes |input| |partial_input_| for a future call. + bool ConsumeBytes(base::span<const char>* input, + size_t len, + base::span<const char>* result, + std::string* storage); + + // Processes a record and returns whether it was valid. If valid, writes the + // contents into |output|, advancing past any bytes written. If |output| was + // not large enough, excess data will be copied into an internal buffer for a + // future call. + bool ProcessRecord(base::span<const char> record, + bool is_final, + base::span<char>* output); + + // The partial input block, if the previous input buffer was too small. + std::string partial_input_; + // The partial output block, if the previous output buffer was too small. + std::string partial_output_; + // The index of |partial_output_| that has not been returned yet. + size_t partial_output_offset_ = 0; + // SHA-256 hash for the next record, if |final_record_done_| is false. + uint8_t next_proof_[SHA256_DIGEST_LENGTH]; + size_t record_size_ = 0; + bool failed_ = false; + // Whether the final record has been processed. + bool final_record_done_ = false; DISALLOW_COPY_AND_ASSIGN(MerkleIntegritySourceStream); };
diff --git a/content/browser/loader/merkle_integrity_source_stream_unittest.cc b/content/browser/loader/merkle_integrity_source_stream_unittest.cc index cffe7cac..dc1d802e 100644 --- a/content/browser/loader/merkle_integrity_source_stream_unittest.cc +++ b/content/browser/loader/merkle_integrity_source_stream_unittest.cc
@@ -22,6 +22,8 @@ "mi-sha256=dcRDgR2GM35DluAV13PzgnG6-pvQwPywfFvAu1UeFrs"; const char kMIMultipleRecords[] = "mi-sha256=IVa9shfs0nyKEhHqtB3WVNANJ2Njm5KjQLjRtnbkYJ4"; +const char kMIWholeNumberOfRecords[] = + "mi-sha256=L2vdwBplKvIr0ZPkcuskWZfEVDgVdHa6aD363UpKuZs"; enum class ReadResultType { // Each call to AddReadResult is a separate read from the lower layer @@ -177,22 +179,57 @@ EXPECT_EQ(net::ERR_CONTENT_DECODING_FAILED, result); } +TEST_P(MerkleIntegritySourceStreamTest, WrongMIAttributeName) { + Init("mi-sha255=bjQLnP-zepicpUTmu3gKLHiQHT-zNzh2hRGjBhevoB0"); + source()->AddReadResult(nullptr, 0, net::OK, GetParam().mode); + std::string actual_output; + int result = ReadStream(&actual_output); + EXPECT_EQ(net::ERR_CONTENT_DECODING_FAILED, result); +} + +TEST_P(MerkleIntegritySourceStreamTest, HashTooShort) { + Init("mi-sha256=bjQLnP-zepicpUTmu3gKLHiQHT-zNzh2hRGjBhevoA"); + source()->AddReadResult(nullptr, 0, net::OK, GetParam().mode); + std::string actual_output; + int result = ReadStream(&actual_output); + EXPECT_EQ(net::ERR_CONTENT_DECODING_FAILED, result); +} + +TEST_P(MerkleIntegritySourceStreamTest, HashTooLong) { + Init("mi-sha256=bjQLnP-zepicpUTmu3gKLHiQHT-zNzh2hRGjBhevoB0A"); + source()->AddReadResult(nullptr, 0, net::OK, GetParam().mode); + std::string actual_output; + int result = ReadStream(&actual_output); + EXPECT_EQ(net::ERR_CONTENT_DECODING_FAILED, result); +} + TEST_P(MerkleIntegritySourceStreamTest, RecordSizeOnly) { Init(kMIEmptyBody); - const uint8_t record_size[] = {0, 0, 0, 0, 0, 0, 0, 10}; - source()->AddReadResult(reinterpret_cast<const char*>(record_size), - sizeof(record_size), net::OK, GetParam().mode); + const uint8_t kRecordSize[] = {0, 0, 0, 0, 0, 0, 0, 10}; + source()->AddReadResult(reinterpret_cast<const char*>(kRecordSize), + sizeof(kRecordSize), net::OK, GetParam().mode); source()->AddReadResult(nullptr, 0, net::OK, GetParam().mode); std::string actual_output; int result = ReadStream(&actual_output); EXPECT_EQ(net::OK, result); } +TEST_P(MerkleIntegritySourceStreamTest, TruncatedRecordSize) { + Init(kMIEmptyBody); + const uint8_t kRecordSize[] = {0, 0, 0, 0, 0, 0, 1}; + source()->AddReadResult(reinterpret_cast<const char*>(kRecordSize), + sizeof(kRecordSize), net::OK, GetParam().mode); + source()->AddReadResult(nullptr, 0, net::OK, GetParam().mode); + std::string actual_output; + int result = ReadStream(&actual_output); + EXPECT_EQ(net::ERR_CONTENT_DECODING_FAILED, result); +} + TEST_P(MerkleIntegritySourceStreamTest, RecordSizeOnlyWrongHash) { Init(kMISingleRecord); - const uint8_t record_size[] = {0, 0, 0, 0, 0, 0, 0, 10}; - source()->AddReadResult(reinterpret_cast<const char*>(record_size), - sizeof(record_size), net::OK, GetParam().mode); + const uint8_t kRecordSize[] = {0, 0, 0, 0, 0, 0, 0, 10}; + source()->AddReadResult(reinterpret_cast<const char*>(kRecordSize), + sizeof(kRecordSize), net::OK, GetParam().mode); source()->AddReadResult(nullptr, 0, net::OK, GetParam().mode); std::string actual_output; int result = ReadStream(&actual_output); @@ -202,10 +239,10 @@ TEST_P(MerkleIntegritySourceStreamTest, RecordSizeHuge) { Init(kMIEmptyBody); // 2^64 - 1 is far too large. - const uint8_t record_size[] = {0xff, 0xff, 0xff, 0xff, + const uint8_t kRecordSize[] = {0xff, 0xff, 0xff, 0xff, 0xff, 0xff, 0xff, 0xff}; - source()->AddReadResult(reinterpret_cast<const char*>(record_size), - sizeof(record_size), net::OK, GetParam().mode); + source()->AddReadResult(reinterpret_cast<const char*>(kRecordSize), + sizeof(kRecordSize), net::OK, GetParam().mode); std::string actual_output; int result = ReadStream(&actual_output); EXPECT_EQ(net::ERR_CONTENT_DECODING_FAILED, result); @@ -214,10 +251,22 @@ TEST_P(MerkleIntegritySourceStreamTest, RecordSizeTooBig) { Init(kMIEmptyBody); // 2^16 + 1 just exceeds the limit. - const uint8_t record_size[] = {0x00, 0x00, 0x00, 0x00, + const uint8_t kRecordSize[] = {0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x40, 0x01}; - source()->AddReadResult(reinterpret_cast<const char*>(record_size), - sizeof(record_size), net::OK, GetParam().mode); + source()->AddReadResult(reinterpret_cast<const char*>(kRecordSize), + sizeof(kRecordSize), net::OK, GetParam().mode); + std::string actual_output; + int result = ReadStream(&actual_output); + EXPECT_EQ(net::ERR_CONTENT_DECODING_FAILED, result); +} + +TEST_P(MerkleIntegritySourceStreamTest, RecordSizeZero) { + Init(kMIEmptyBody); + // Zero is not a valid record size. + const uint8_t kRecordSize[] = {0x00, 0x00, 0x00, 0x00, + 0x00, 0x00, 0x00, 0x00}; + source()->AddReadResult(reinterpret_cast<const char*>(kRecordSize), + sizeof(kRecordSize), net::OK, GetParam().mode); std::string actual_output; int result = ReadStream(&actual_output); EXPECT_EQ(net::ERR_CONTENT_DECODING_FAILED, result); @@ -226,26 +275,26 @@ // https://tools.ietf.org/html/draft-thomson-http-mice-02#section-4.1 TEST_P(MerkleIntegritySourceStreamTest, SingleRecord) { Init(kMISingleRecord); - const uint8_t record_size[] = {0, 0, 0, 0, 0, 0, 0, 0x29}; - const std::string message("When I grow up, I want to be a watermelon"); - source()->AddReadResult(reinterpret_cast<const char*>(record_size), - sizeof(record_size), net::OK, GetParam().mode); - source()->AddReadResult(message.data(), message.size(), net::OK, + const uint8_t kRecordSize[] = {0, 0, 0, 0, 0, 0, 0, 41}; + const std::string kMessage("When I grow up, I want to be a watermelon"); + source()->AddReadResult(reinterpret_cast<const char*>(kRecordSize), + sizeof(kRecordSize), net::OK, GetParam().mode); + source()->AddReadResult(kMessage.data(), kMessage.size(), net::OK, GetParam().mode); source()->AddReadResult(nullptr, 0, net::OK, GetParam().mode); std::string actual_output; int rv = ReadStream(&actual_output); - EXPECT_EQ(static_cast<int>(message.size()), rv); - EXPECT_EQ(message, actual_output); + EXPECT_EQ(static_cast<int>(kMessage.size()), rv); + EXPECT_EQ(kMessage, actual_output); } TEST_P(MerkleIntegritySourceStreamTest, SingleRecordWrongHash) { Init(kMIEmptyBody); - const uint8_t record_size[] = {0, 0, 0, 0, 0, 0, 0, 0x29}; - const std::string message("When I grow up, I want to be a watermelon"); - source()->AddReadResult(reinterpret_cast<const char*>(record_size), - sizeof(record_size), net::OK, GetParam().mode); - source()->AddReadResult(message.data(), message.size(), net::OK, + const uint8_t kRecordSize[] = {0, 0, 0, 0, 0, 0, 0, 41}; + const std::string kMessage("When I grow up, I want to be a watermelon"); + source()->AddReadResult(reinterpret_cast<const char*>(kRecordSize), + sizeof(kRecordSize), net::OK, GetParam().mode); + source()->AddReadResult(kMessage.data(), kMessage.size(), net::OK, GetParam().mode); source()->AddReadResult(nullptr, 0, net::OK, GetParam().mode); std::string actual_output; @@ -254,55 +303,244 @@ EXPECT_EQ(0u, actual_output.size()); } +// The final record may not be larger than the record size. +TEST_P(MerkleIntegritySourceStreamTest, SingleRecordTooLarge) { + Init(kMISingleRecord); + const uint8_t kRecordSize[] = {0, 0, 0, 0, 0, 0, 0, 40}; + const std::string kMessage("When I grow up, I want to be a watermelon"); + source()->AddReadResult(reinterpret_cast<const char*>(kRecordSize), + sizeof(kRecordSize), net::OK, GetParam().mode); + source()->AddReadResult(kMessage.data(), kMessage.size(), net::OK, + GetParam().mode); + source()->AddReadResult(nullptr, 0, net::OK, GetParam().mode); + std::string actual_output; + int rv = ReadStream(&actual_output); + EXPECT_EQ(net::ERR_CONTENT_DECODING_FAILED, rv); + EXPECT_EQ("", actual_output); +} + // https://tools.ietf.org/html/draft-thomson-http-mice-02#section-4.2 TEST_P(MerkleIntegritySourceStreamTest, MultipleRecords) { Init(kMIMultipleRecords); - const uint8_t record_size[] = {0, 0, 0, 0, 0, 0, 0, 16}; - const std::string message("When I grow up, I want to be a watermelon"); + const uint8_t kRecordSize[] = {0, 0, 0, 0, 0, 0, 0, 16}; + const std::string kMessage("When I grow up, I want to be a watermelon"); - source()->AddReadResult(reinterpret_cast<const char*>(record_size), - sizeof(record_size), net::OK, GetParam().mode); - source()->AddReadResult(message.data(), 16, net::OK, GetParam().mode); + source()->AddReadResult(reinterpret_cast<const char*>(kRecordSize), + sizeof(kRecordSize), net::OK, GetParam().mode); + source()->AddReadResult(kMessage.data(), 16, net::OK, GetParam().mode); std::string hash1 = Base64Decode("OElbplJlPK-Rv6JNK6p5_515IaoPoZo-2elWL7OQ60A"); source()->AddReadResult(hash1.data(), 32, net::OK, GetParam().mode); - source()->AddReadResult(message.data() + 16, 16, net::OK, GetParam().mode); + source()->AddReadResult(kMessage.data() + 16, 16, net::OK, GetParam().mode); std::string hash2 = Base64Decode("iPMpmgExHPrbEX3_RvwP4d16fWlK4l--p75PUu_KyN0"); source()->AddReadResult(hash2.data(), 32, net::OK, GetParam().mode); - source()->AddReadResult(message.data() + 32, message.size() - 32, net::OK, + source()->AddReadResult(kMessage.data() + 32, kMessage.size() - 32, net::OK, GetParam().mode); source()->AddReadResult(nullptr, 0, net::OK, GetParam().mode); std::string actual_output; int rv = ReadStream(&actual_output); - EXPECT_EQ(static_cast<int>(message.size()), rv); - EXPECT_EQ(message, actual_output); + EXPECT_EQ(static_cast<int>(kMessage.size()), rv); + EXPECT_EQ(kMessage, actual_output); +} + +TEST_P(MerkleIntegritySourceStreamTest, MultipleRecordsAllAtOnce) { + Init(kMIMultipleRecords); + const uint8_t kRecordSize[] = {0, 0, 0, 0, 0, 0, 0, 16}; + const std::string kMessage("When I grow up, I want to be a watermelon"); + + std::string body(reinterpret_cast<const char*>(kRecordSize), + sizeof(kRecordSize)); + body += kMessage.substr(0, 16); + body += Base64Decode("OElbplJlPK-Rv6JNK6p5_515IaoPoZo-2elWL7OQ60A"); + body += kMessage.substr(16, 16); + body += Base64Decode("iPMpmgExHPrbEX3_RvwP4d16fWlK4l--p75PUu_KyN0"); + body += kMessage.substr(32); + + source()->AddReadResult(body.data(), body.size(), net::OK, GetParam().mode); + source()->AddReadResult(nullptr, 0, net::OK, GetParam().mode); + std::string actual_output; + int rv = ReadStream(&actual_output); + EXPECT_EQ(static_cast<int>(kMessage.size()), rv); + EXPECT_EQ(kMessage, actual_output); } TEST_P(MerkleIntegritySourceStreamTest, MultipleRecordsWrongLastRecordHash) { Init(kMIMultipleRecords); - const uint8_t record_size[] = {0, 0, 0, 0, 0, 0, 0, 16}; - const std::string message("When I grow up, I want to be a watermelon!"); + const uint8_t kRecordSize[] = {0, 0, 0, 0, 0, 0, 0, 16}; + const std::string kMessage("When I grow up, I want to be a watermelon!"); - source()->AddReadResult(reinterpret_cast<const char*>(record_size), - sizeof(record_size), net::OK, GetParam().mode); - source()->AddReadResult(message.data(), 16, net::OK, GetParam().mode); + source()->AddReadResult(reinterpret_cast<const char*>(kRecordSize), + sizeof(kRecordSize), net::OK, GetParam().mode); + source()->AddReadResult(kMessage.data(), 16, net::OK, GetParam().mode); std::string hash1 = Base64Decode("OElbplJlPK-Rv6JNK6p5_515IaoPoZo-2elWL7OQ60A"); source()->AddReadResult(hash1.data(), 32, net::OK, GetParam().mode); - source()->AddReadResult(message.data() + 16, 16, net::OK, GetParam().mode); + source()->AddReadResult(kMessage.data() + 16, 16, net::OK, GetParam().mode); std::string hash2 = Base64Decode("iPMpmgExHPrbEX3_RvwP4d16fWlK4l--p75PUu_KyN0"); source()->AddReadResult(hash2.data(), 32, net::OK, GetParam().mode); - source()->AddReadResult(message.data() + 32, message.size() - 32, net::OK, + source()->AddReadResult(kMessage.data() + 32, kMessage.size() - 32, net::OK, GetParam().mode); source()->AddReadResult(nullptr, 0, net::OK, GetParam().mode); std::string actual_output; int rv = ReadStream(&actual_output); EXPECT_EQ(net::ERR_CONTENT_DECODING_FAILED, rv); - EXPECT_EQ(message.substr(0, 32), actual_output); + EXPECT_EQ(kMessage.substr(0, 32), actual_output); +} + +TEST_P(MerkleIntegritySourceStreamTest, MultipleRecordsWrongFirstRecordHash) { + Init(kMIEmptyBody); + const uint8_t kRecordSize[] = {0, 0, 0, 0, 0, 0, 0, 16}; + const std::string kMessage("When I grow up, I want to be a watermelon!"); + + source()->AddReadResult(reinterpret_cast<const char*>(kRecordSize), + sizeof(kRecordSize), net::OK, GetParam().mode); + source()->AddReadResult(kMessage.data(), 16, net::OK, GetParam().mode); + std::string hash1 = + Base64Decode("OElbplJlPK-Rv6JNK6p5_515IaoPoZo-2elWL7OQ60A"); + source()->AddReadResult(hash1.data(), 32, net::OK, GetParam().mode); + + std::string actual_output; + int rv = ReadStream(&actual_output); + EXPECT_EQ(net::ERR_CONTENT_DECODING_FAILED, rv); + EXPECT_EQ("", actual_output); +} + +TEST_P(MerkleIntegritySourceStreamTest, TrailingNetError) { + Init(kMIMultipleRecords); + const uint8_t kRecordSize[] = {0, 0, 0, 0, 0, 0, 0, 16}; + const std::string kMessage("When I grow up, I want to be a watermelon"); + + source()->AddReadResult(reinterpret_cast<const char*>(kRecordSize), + sizeof(kRecordSize), net::OK, GetParam().mode); + source()->AddReadResult(kMessage.data(), 16, net::OK, GetParam().mode); + std::string hash1 = + Base64Decode("OElbplJlPK-Rv6JNK6p5_515IaoPoZo-2elWL7OQ60A"); + source()->AddReadResult(hash1.data(), 32, net::OK, GetParam().mode); + source()->AddReadResult(kMessage.data() + 16, 16, net::OK, GetParam().mode); + std::string hash2 = + Base64Decode("iPMpmgExHPrbEX3_RvwP4d16fWlK4l--p75PUu_KyN0"); + source()->AddReadResult(hash2.data(), 32, net::OK, GetParam().mode); + source()->AddReadResult(kMessage.data() + 32, kMessage.size() - 32, net::OK, + GetParam().mode); + source()->AddReadResult(nullptr, 0, net::ERR_FAILED, GetParam().mode); + + std::string actual_output; + int rv = ReadStream(&actual_output); + EXPECT_EQ(net::ERR_FAILED, rv); + // MerkleIntegritySourceStream cannot read the last record without a clean EOF + // to denote its end. + EXPECT_EQ(kMessage.substr(0, 32), actual_output); +} + +// Test that truncations are noticed, by way of the final record not matching +// the hash. +TEST_P(MerkleIntegritySourceStreamTest, Truncated) { + Init(kMIMultipleRecords); + const uint8_t kRecordSize[] = {0, 0, 0, 0, 0, 0, 0, 16}; + const std::string kMessage("When I grow up, I want to be a w"); + + source()->AddReadResult(reinterpret_cast<const char*>(kRecordSize), + sizeof(kRecordSize), net::OK, GetParam().mode); + source()->AddReadResult(kMessage.data(), 16, net::OK, GetParam().mode); + std::string hash1 = + Base64Decode("OElbplJlPK-Rv6JNK6p5_515IaoPoZo-2elWL7OQ60A"); + source()->AddReadResult(hash1.data(), 32, net::OK, GetParam().mode); + source()->AddReadResult(kMessage.data() + 16, 16, net::OK, GetParam().mode); + std::string hash2 = + Base64Decode("iPMpmgExHPrbEX3_RvwP4d16fWlK4l--p75PUu_KyN0"); + source()->AddReadResult(hash2.data(), 32, net::OK, GetParam().mode); + // |hash2| is the hash of "atermelon", but this stream ends early. Decoding + // thus should fail. + source()->AddReadResult(nullptr, 0, net::OK, GetParam().mode); + + std::string actual_output; + int rv = ReadStream(&actual_output); + EXPECT_EQ(net::ERR_CONTENT_DECODING_FAILED, rv); + EXPECT_EQ(kMessage, actual_output); +} + +// Test that the final record is allowed to be empty. +// +// TODO(davidben): This does not match the specification and means some inputs +// have two valid encodings. However, the specification's version cannot +// represent the empty string. Update the code and possibly this test depending +// on how https://github.com/martinthomson/http-mice/issues/3 is resolved. +TEST_P(MerkleIntegritySourceStreamTest, EmptyFinalRecord) { + Init("mi-sha256=JJnIuaOEc2247K9V88VQAQy1GJuQ6ylaVM7mG69QkE4"); + const uint8_t kRecordSize[] = {0, 0, 0, 0, 0, 0, 0, 16}; + const std::string kMessage( + "When I grow up, I want to be a watermelon!! \xf0\x9f\x8d\x89"); + + source()->AddReadResult(reinterpret_cast<const char*>(kRecordSize), + sizeof(kRecordSize), net::OK, GetParam().mode); + source()->AddReadResult(kMessage.data(), 16, net::OK, GetParam().mode); + std::string hash1 = + Base64Decode("hhJEKpkbuZoWUjzBPAZxMUN2DXdJ6epkS0McZh77IXo"); + source()->AddReadResult(hash1.data(), 32, net::OK, GetParam().mode); + source()->AddReadResult(kMessage.data() + 16, 16, net::OK, GetParam().mode); + std::string hash2 = + Base64Decode("RKTTVSMiH3bkxUQKreVATPL1KUd5eqRdmDgRQcZq_80"); + source()->AddReadResult(hash2.data(), 32, net::OK, GetParam().mode); + source()->AddReadResult(kMessage.data() + 32, 16, net::OK, GetParam().mode); + std::string hash3 = + Base64Decode("bjQLnP-zepicpUTmu3gKLHiQHT-zNzh2hRGjBhevoB0"); + source()->AddReadResult(hash3.data(), 32, net::OK, GetParam().mode); + source()->AddReadResult(nullptr, 0, net::OK, GetParam().mode); + + std::string actual_output; + int rv = ReadStream(&actual_output); + EXPECT_EQ(static_cast<int>(kMessage.size()), rv); + EXPECT_EQ(kMessage, actual_output); +} + +TEST_P(MerkleIntegritySourceStreamTest, WholeNumberOfRecords) { + Init(kMIWholeNumberOfRecords); + const uint8_t kRecordSize[] = {0, 0, 0, 0, 0, 0, 0, 16}; + const std::string kMessage( + "When I grow up, I want to be a watermelon!! \xf0\x9f\x8d\x89"); + + source()->AddReadResult(reinterpret_cast<const char*>(kRecordSize), + sizeof(kRecordSize), net::OK, GetParam().mode); + source()->AddReadResult(kMessage.data(), 16, net::OK, GetParam().mode); + std::string hash1 = + Base64Decode("2s-MNG6NrTt556s__HYnQTjG3WOktEcXZ61O8mzG9f4"); + source()->AddReadResult(hash1.data(), 32, net::OK, GetParam().mode); + source()->AddReadResult(kMessage.data() + 16, 16, net::OK, GetParam().mode); + std::string hash2 = + Base64Decode("qa_cQSMjFyZsm0cnYG4H6LqwOM_hzMSclK6I8iVoZYQ"); + source()->AddReadResult(hash2.data(), 32, net::OK, GetParam().mode); + source()->AddReadResult(kMessage.data() + 32, 16, net::OK, GetParam().mode); + + source()->AddReadResult(nullptr, 0, net::OK, GetParam().mode); + std::string actual_output; + int rv = ReadStream(&actual_output); + EXPECT_EQ(static_cast<int>(kMessage.size()), rv); + EXPECT_EQ(kMessage, actual_output); +} + +TEST_P(MerkleIntegritySourceStreamTest, WholeNumberOfRecordsAllAtOnce) { + Init(kMIWholeNumberOfRecords); + const uint8_t kRecordSize[] = {0, 0, 0, 0, 0, 0, 0, 16}; + const std::string kMessage( + "When I grow up, I want to be a watermelon!! \xf0\x9f\x8d\x89"); + std::string body(reinterpret_cast<const char*>(kRecordSize), + sizeof(kRecordSize)); + body += kMessage.substr(0, 16); + body += Base64Decode("2s-MNG6NrTt556s__HYnQTjG3WOktEcXZ61O8mzG9f4"); + body += kMessage.substr(16, 16); + body += Base64Decode("qa_cQSMjFyZsm0cnYG4H6LqwOM_hzMSclK6I8iVoZYQ"); + body += kMessage.substr(32, 16); + + source()->AddReadResult(body.data(), body.size(), net::OK, GetParam().mode); + source()->AddReadResult(nullptr, 0, net::OK, GetParam().mode); + std::string actual_output; + int rv = ReadStream(&actual_output); + EXPECT_EQ(static_cast<int>(kMessage.size()), rv); + EXPECT_EQ(kMessage, actual_output); } } // namespace content
diff --git a/content/browser/loader/navigation_url_loader_network_service.cc b/content/browser/loader/navigation_url_loader_network_service.cc index 6863c34..5c0917bd 100644 --- a/content/browser/loader/navigation_url_loader_network_service.cc +++ b/content/browser/loader/navigation_url_loader_network_service.cc
@@ -300,7 +300,8 @@ previous_request_info.frame_tree_node_id, previous_request_info.is_for_guests_only, previous_request_info.report_raw_headers, - previous_request_info.is_prerendering); + previous_request_info.is_prerendering, + nullptr /* blob_url_loader_factory */); } // Called for requests that we don't have a URLLoaderFactory for. @@ -546,6 +547,23 @@ return; } + // Requests to Blob scheme won't get redirected to/from other schemes + // or be intercepted, so we just let it go here. + if (request_info->common_params.url.SchemeIsBlob() && + request_info->blob_url_loader_factory) { + url_loader_ = ThrottlingURLLoader::CreateLoaderAndStart( + network::SharedURLLoaderFactory::Create( + std::move(request_info->blob_url_loader_factory)), + GetContentClient()->browser()->CreateURLLoaderThrottles( + *resource_request_, resource_context_, web_contents_getter_, + navigation_ui_data_.get(), frame_tree_node_id_), + 0 /* routing_id */, 0 /* request_id? */, + network::mojom::kURLLoadOptionNone, resource_request_.get(), this, + kNavigationUrlLoaderTrafficAnnotation, + base::ThreadTaskRunnerHandle::Get()); + return; + } + if (service_worker_navigation_handle_core) { std::unique_ptr<NavigationLoaderInterceptor> service_worker_interceptor = CreateServiceWorkerInterceptor(*request_info, @@ -836,6 +854,16 @@ } else { ResourceDispatcherHostImpl* rdh = ResourceDispatcherHostImpl::Get(); net::URLRequest* url_request = rdh->GetURLRequest(global_request_id_); + + // The |url_request| maybe have been removed from the resource dispatcher + // host during the time it took for OnReceiveResponse() to be received. In + // this case, it means the request has been canceled. + // See https://crbug.com/828156. + if (!url_request) { + OnComplete(network::URLLoaderCompletionStatus(net::ERR_ABORTED)); + return; + } + ResourceRequestInfoImpl* info = ResourceRequestInfoImpl::ForRequest(url_request); is_download = !response_intercepted && info->IsDownload();
diff --git a/content/browser/loader/navigation_url_loader_network_service_unittest.cc b/content/browser/loader/navigation_url_loader_network_service_unittest.cc index ce04d90f..34aad1e7 100644 --- a/content/browser/loader/navigation_url_loader_network_service_unittest.cc +++ b/content/browser/loader/navigation_url_loader_network_service_unittest.cc
@@ -152,7 +152,8 @@ common_params, std::move(begin_params), url, is_main_frame, false /* parent_is_main_frame */, false /* are_ancestors_secure */, -1 /* frame_tree_node_id */, false /* is_for_guests_only */, - false /* report_raw_headers */, false /* is_prerenering */)); + false /* report_raw_headers */, false /* is_prerenering */, + nullptr /* blob_url_loader_factory */)); std::vector<std::unique_ptr<NavigationLoaderInterceptor>> interceptors; most_recent_resource_request_ = base::nullopt; interceptors.push_back(std::make_unique<TestNavigationLoaderInterceptor>(
diff --git a/content/browser/loader/navigation_url_loader_unittest.cc b/content/browser/loader/navigation_url_loader_unittest.cc index 4bd10b3..9a2d4ad 100644 --- a/content/browser/loader/navigation_url_loader_unittest.cc +++ b/content/browser/loader/navigation_url_loader_unittest.cc
@@ -123,7 +123,8 @@ std::unique_ptr<NavigationRequestInfo> request_info( new NavigationRequestInfo(common_params, std::move(begin_params), url, - true, false, false, -1, false, false, false)); + true, false, false, -1, false, false, false, + nullptr)); return NavigationURLLoader::Create( browser_context_->GetResourceContext(), BrowserContext::GetDefaultStoragePartition(browser_context_.get()),
diff --git a/content/browser/loader/resource_dispatcher_host_unittest.cc b/content/browser/loader/resource_dispatcher_host_unittest.cc index 04dfc93..9deffd99d 100644 --- a/content/browser/loader/resource_dispatcher_host_unittest.cc +++ b/content/browser/loader/resource_dispatcher_host_unittest.cc
@@ -818,7 +818,8 @@ common_params.url = url; std::unique_ptr<NavigationRequestInfo> request_info( new NavigationRequestInfo(common_params, std::move(begin_params), url, - true, false, false, -1, false, false, false)); + true, false, false, -1, false, false, false, + nullptr)); std::unique_ptr<NavigationURLLoader> test_loader = NavigationURLLoader::Create( browser_context_->GetResourceContext(),
diff --git a/content/browser/renderer_host/delegated_frame_host.cc b/content/browser/renderer_host/delegated_frame_host.cc index cfdb693..36e00604 100644 --- a/content/browser/renderer_host/delegated_frame_host.cc +++ b/content/browser/renderer_host/delegated_frame_host.cc
@@ -132,12 +132,6 @@ const gfx::Rect& src_subrect, const gfx::Size& output_size, base::OnceCallback<void(const SkBitmap&)> callback) { - if (!CanCopyFromCompositingSurface() || - current_frame_size_in_dip_.IsEmpty()) { - std::move(callback).Run(SkBitmap()); - return; - } - std::unique_ptr<viz::CopyOutputRequest> request = std::make_unique<viz::CopyOutputRequest>( viz::CopyOutputRequest::ResultFormat::RGBA_BITMAP, @@ -148,24 +142,41 @@ }, std::move(callback))); - if (src_subrect.IsEmpty()) { - request->set_area(gfx::Rect(current_frame_size_in_dip_)); - } else { + if (!src_subrect.IsEmpty()) request->set_area(src_subrect); - } + if (!output_size.IsEmpty()) + request->set_result_selection(gfx::Rect(output_size)); + // If there is enough information to populate the copy output request fields, + // then process it now. Otherwise, wait until the information becomes + // available. + if (CanCopyFromCompositingSurface()) + ProcessCopyOutputRequest(std::move(request)); + else + pending_first_frame_requests_.push_back(std::move(request)); +} + +void DelegatedFrameHost::ProcessCopyOutputRequest( + std::unique_ptr<viz::CopyOutputRequest> request) { + if (!request->has_area()) + request->set_area(gfx::Rect(pending_surface_dip_size_)); + + // TODO(vmpstr): Should use pending device scale factor. We need to plumb + // it here. request->set_area( gfx::ScaleToRoundedRect(request->area(), active_device_scale_factor_)); - if (!output_size.IsEmpty()) { - request->set_result_selection(gfx::Rect(output_size)); + if (request->has_result_selection()) { + const gfx::Rect& area = request->area(); + const gfx::Rect& result_selection = request->result_selection(); request->SetScaleRatio( - gfx::Vector2d(request->area().width(), request->area().height()), - gfx::Vector2d(output_size.width(), output_size.height())); + gfx::Vector2d(area.width(), area.height()), + gfx::Vector2d(result_selection.width(), result_selection.height())); } - GetHostFrameSinkManager()->RequestCopyOfOutput(frame_sink_id_, - std::move(request)); + GetHostFrameSinkManager()->RequestCopyOfOutput( + viz::SurfaceId(frame_sink_id_, pending_local_surface_id_), + std::move(request)); } bool DelegatedFrameHost::CanCopyFromCompositingSurface() const { @@ -552,6 +563,13 @@ frame_evictor_->SwappedFrame(client_->DelegatedFrameHostIsVisible()); // Note: the frame may have been evicted immediately. + + if (!pending_first_frame_requests_.empty()) { + DCHECK(CanCopyFromCompositingSurface()); + for (auto& request : pending_first_frame_requests_) + ProcessCopyOutputRequest(std::move(request)); + pending_first_frame_requests_.clear(); + } } void DelegatedFrameHost::OnFrameTokenChanged(uint32_t frame_token) {
diff --git a/content/browser/renderer_host/delegated_frame_host.h b/content/browser/renderer_host/delegated_frame_host.h index 1047ecd..d1eedbe8 100644 --- a/content/browser/renderer_host/delegated_frame_host.h +++ b/content/browser/renderer_host/delegated_frame_host.h
@@ -229,6 +229,9 @@ void CreateCompositorFrameSinkSupport(); void ResetCompositorFrameSinkSupport(); + void ProcessCopyOutputRequest( + std::unique_ptr<viz::CopyOutputRequest> request); + const viz::FrameSinkId frame_sink_id_; DelegatedFrameHostClient* const client_; const bool enable_surface_synchronization_; @@ -294,6 +297,9 @@ uint32_t first_parent_sequence_number_after_navigation_ = 0; bool received_frame_after_navigation_ = false; + + std::vector<std::unique_ptr<viz::CopyOutputRequest>> + pending_first_frame_requests_; }; } // namespace content
diff --git a/content/browser/renderer_host/input/input_router.h b/content/browser/renderer_host/input/input_router.h index 01645d1..6108648 100644 --- a/content/browser/renderer_host/input/input_router.h +++ b/content/browser/renderer_host/input/input_router.h
@@ -55,7 +55,10 @@ virtual void SetDeviceScaleFactor(float device_scale_factor) = 0; // Sets the frame tree node id of associated frame, used when tracing - // input event latencies to relate events to their target frames. + // input event latencies to relate events to their target frames. Since + // input always flows to Local Frame Roots, the |frameTreeNodeId| is + // relative to the Frame associated with the Local Frame Root for the + // widget owning this InputRouter. virtual void SetFrameTreeNodeId(int frameTreeNodeId) = 0; // Return the currently allowed touch-action.
diff --git a/content/browser/renderer_host/input/touch_selection_controller_client_aura.cc b/content/browser/renderer_host/input/touch_selection_controller_client_aura.cc index 8b890578..746afa48 100644 --- a/content/browser/renderer_host/input/touch_selection_controller_client_aura.cc +++ b/content/browser/renderer_host/input/touch_selection_controller_client_aura.cc
@@ -174,9 +174,9 @@ bool TouchSelectionControllerClientAura::HandleContextMenu( const ContextMenuParams& params) { - if (params.source_type == ui::MENU_SOURCE_LONG_PRESS && - params.is_editable && - params.selection_text.empty() && + if ((params.source_type == ui::MENU_SOURCE_LONG_PRESS || + params.source_type == ui::MENU_SOURCE_LONG_TAP) && + params.is_editable && params.selection_text.empty() && IsQuickMenuAvailable()) { quick_menu_requested_ = true; UpdateQuickMenu(); @@ -184,6 +184,7 @@ } const bool from_touch = params.source_type == ui::MENU_SOURCE_LONG_PRESS || + params.source_type == ui::MENU_SOURCE_LONG_TAP || params.source_type == ui::MENU_SOURCE_TOUCH; if (from_touch && !params.selection_text.empty()) return true;
diff --git a/content/browser/renderer_host/render_widget_host_view_aura.cc b/content/browser/renderer_host/render_widget_host_view_aura.cc index 5d7f4663..1b5bdf1f 100644 --- a/content/browser/renderer_host/render_widget_host_view_aura.cc +++ b/content/browser/renderer_host/render_widget_host_view_aura.cc
@@ -843,10 +843,6 @@ const gfx::Rect& src_subrect, const gfx::Size& dst_size, base::OnceCallback<void(const SkBitmap&)> callback) { - if (!IsSurfaceAvailableForCopy()) { - std::move(callback).Run(SkBitmap()); - return; - } delegated_frame_host_->CopyFromCompositingSurface(src_subrect, dst_size, std::move(callback)); } @@ -888,13 +884,6 @@ delegated_frame_host_->SubmitCompositorFrame( local_surface_id, std::move(frame), std::move(hit_test_region_list)); - if (frame.metadata.selection.start != selection_start_ || - frame.metadata.selection.end != selection_end_) { - selection_start_ = frame.metadata.selection.start; - selection_end_ = frame.metadata.selection.end; - selection_controller_client_->UpdateClientSelectionBounds(selection_start_, - selection_end_); - } } void RenderWidgetHostViewAura::OnDidNotProduceFrame( @@ -1793,10 +1782,17 @@ // implementation: void RenderWidgetHostViewAura::OnRenderFrameMetadataChanged() { RenderWidgetHostViewBase::OnRenderFrameMetadataChanged(); - UpdateBackgroundColorFromRenderer(host() - ->render_frame_metadata_provider() - ->LastRenderFrameMetadata() - .root_background_color); + const cc::RenderFrameMetadata& metadata = + host()->render_frame_metadata_provider()->LastRenderFrameMetadata(); + UpdateBackgroundColorFromRenderer(metadata.root_background_color); + + if (metadata.selection.start != selection_start_ || + metadata.selection.end != selection_end_) { + selection_start_ = metadata.selection.start; + selection_end_ = metadata.selection.end; + selection_controller_client_->UpdateClientSelectionBounds(selection_start_, + selection_end_); + } } //////////////////////////////////////////////////////////////////////////////// @@ -2090,16 +2086,6 @@ has_snapped_to_boundary_ = true; } -bool RenderWidgetHostViewAura::OnShowContextMenu( - const ContextMenuParams& params) { -#if defined(OS_WIN) - event_handler_->SetContextMenuParams(params); - return params.source_type != ui::MENU_SOURCE_LONG_PRESS; -#else - return true; -#endif // defined(OS_WIN) -} - void RenderWidgetHostViewAura::SetSelectionControllerClientForTest( std::unique_ptr<TouchSelectionControllerClientAura> client) { selection_controller_client_.swap(client);
diff --git a/content/browser/renderer_host/render_widget_host_view_aura.h b/content/browser/renderer_host/render_widget_host_view_aura.h index 06484c45d..cab0fa3 100644 --- a/content/browser/renderer_host/render_widget_host_view_aura.h +++ b/content/browser/renderer_host/render_widget_host_view_aura.h
@@ -314,13 +314,6 @@ void SnapToPhysicalPixelBoundary(); - // Called when the context menu is about to be displayed. - // Returns true if the context menu should be displayed. We only return false - // on Windows if the context menu is being displayed in response to a long - // press gesture. On Windows we should be consistent like other apps and - // display the menu when the touch is released. - bool OnShowContextMenu(const ContextMenuParams& params); - // Used in tests to set a mock client for touch selection controller. It will // create a new touch selection controller for the new client. void SetSelectionControllerClientForTest(
diff --git a/content/browser/renderer_host/render_widget_host_view_aura_unittest.cc b/content/browser/renderer_host/render_widget_host_view_aura_unittest.cc index a3260aa..8fe4e1b 100644 --- a/content/browser/renderer_host/render_widget_host_view_aura_unittest.cc +++ b/content/browser/renderer_host/render_widget_host_view_aura_unittest.cc
@@ -6268,31 +6268,12 @@ // A context menu request with the MENU_SOURCE_LONG_PRESS source type should // result in the MockWebContentsViewDelegate::ShowContextMenu method // getting called on non Windows platforms. This means that the request - // worked correctly. On Windows this should be blocked. + // worked correctly. delegate->ClearState(); context_menu_params.source_type = ui::MENU_SOURCE_LONG_PRESS; contents()->ShowContextMenu(contents()->GetRenderViewHost()->GetMainFrame(), context_menu_params); -#if defined(OS_WIN) - EXPECT_FALSE(delegate->context_menu_request_received()); -#else EXPECT_TRUE(delegate->context_menu_request_received()); -#endif - -#if defined(OS_WIN) - // On Windows the context menu request blocked above should be received when - // the ET_GESTURE_LONG_TAP gesture is sent to the RenderWidgetHostViewAura - // instance. This means that the touch was released. - delegate->ClearState(); - - ui::GestureEventDetails event_details(ui::ET_GESTURE_LONG_TAP); - ui::GestureEvent gesture_event( - 100, 100, 0, ui::EventTimeForNow(), event_details); - view()->OnGestureEvent(&gesture_event); - - EXPECT_TRUE(delegate->context_menu_request_received()); - EXPECT_EQ(delegate->context_menu_source_type(), ui::MENU_SOURCE_TOUCH); -#endif RenderViewHostFactory::set_is_real_render_view_host(false); }
diff --git a/content/browser/renderer_host/render_widget_host_view_child_frame.cc b/content/browser/renderer_host/render_widget_host_view_child_frame.cc index 7701924..d2ef6245 100644 --- a/content/browser/renderer_host/render_widget_host_view_child_frame.cc +++ b/content/browser/renderer_host/render_widget_host_view_child_frame.cc
@@ -629,11 +629,6 @@ SendSurfaceInfoToEmbedder(); } - if (selection_controller_client_) { - selection_controller_client_->UpdateSelectionBoundsIfNeeded( - frame.metadata.selection, current_device_scale_factor_); - } - ProcessFrameSwappedCallbacks(); } @@ -873,8 +868,9 @@ gfx::Vector2d(output_size.width(), output_size.height())); } - GetHostFrameSinkManager()->RequestCopyOfOutput(frame_sink_id_, - std::move(request)); + GetHostFrameSinkManager()->RequestCopyOfOutput( + viz::SurfaceId(frame_sink_id_, last_received_local_surface_id_), + std::move(request)); } void RenderWidgetHostViewChildFrame::ReclaimResources( @@ -920,6 +916,16 @@ return root_view->GetTouchSelectionControllerClientManager(); } +void RenderWidgetHostViewChildFrame::OnRenderFrameMetadataChanged() { + RenderWidgetHostViewBase::OnRenderFrameMetadataChanged(); + if (selection_controller_client_) { + const cc::RenderFrameMetadata& metadata = + host()->render_frame_metadata_provider()->LastRenderFrameMetadata(); + selection_controller_client_->UpdateSelectionBoundsIfNeeded( + metadata.selection, current_device_scale_factor_); + } +} + void RenderWidgetHostViewChildFrame::SetWantsAnimateOnlyBeginFrames() { if (support_) support_->SetWantsAnimateOnlyBeginFrames();
diff --git a/content/browser/renderer_host/render_widget_host_view_child_frame.h b/content/browser/renderer_host/render_widget_host_view_child_frame.h index 5d6cc9e8..bc1fdc58 100644 --- a/content/browser/renderer_host/render_widget_host_view_child_frame.h +++ b/content/browser/renderer_host/render_widget_host_view_child_frame.h
@@ -160,6 +160,7 @@ const gfx::PointF& point) override; TouchSelectionControllerClientManager* GetTouchSelectionControllerClientManager() override; + void OnRenderFrameMetadataChanged() override; bool IsRenderWidgetHostViewChildFrame() override;
diff --git a/content/browser/renderer_host/render_widget_host_view_event_handler.cc b/content/browser/renderer_host/render_widget_host_view_event_handler.cc index b480943..5fe9c8a 100644 --- a/content/browser/renderer_host/render_widget_host_view_event_handler.cc +++ b/content/browser/renderer_host/render_widget_host_view_event_handler.cc
@@ -162,15 +162,6 @@ } #if defined(OS_WIN) -void RenderWidgetHostViewEventHandler::SetContextMenuParams( - const ContextMenuParams& params) { - last_context_menu_params_.reset(); - if (params.source_type == ui::MENU_SOURCE_LONG_PRESS) { - last_context_menu_params_.reset(new ContextMenuParams); - *last_context_menu_params_ = params; - } -} - void RenderWidgetHostViewEventHandler::UpdateMouseLockRegion() { RECT window_rect = display::Screen::GetScreen() @@ -716,29 +707,6 @@ case ui::ET_GESTURE_SCROLL_END: delegate_->selection_controller_client()->OnScrollCompleted(); break; -#if defined(OS_WIN) - case ui::ET_GESTURE_LONG_TAP: { - if (!last_context_menu_params_) - break; - - std::unique_ptr<ContextMenuParams> context_menu_params = - std::move(last_context_menu_params_); - - // On Windows we want to display the context menu when the long press - // gesture is released. To achieve that, we switch the saved context - // menu params source type to MENU_SOURCE_TOUCH. This is to ensure that - // the RenderWidgetHostViewBase::OnShowContextMenu function which is - // called from the ShowContextMenu call below, does not treat it as - // a context menu request coming in from the long press gesture. - DCHECK(context_menu_params->source_type == ui::MENU_SOURCE_LONG_PRESS); - context_menu_params->source_type = ui::MENU_SOURCE_TOUCH; - - delegate_->ShowContextMenu(*context_menu_params); - event->SetHandled(); - // WARNING: we may have been deleted during the call to ShowContextMenu(). - break; - } -#endif default: break; }
diff --git a/content/browser/renderer_host/render_widget_host_view_event_handler.h b/content/browser/renderer_host/render_widget_host_view_event_handler.h index c06981f..59a3911b 100644 --- a/content/browser/renderer_host/render_widget_host_view_event_handler.h +++ b/content/browser/renderer_host/render_widget_host_view_event_handler.h
@@ -258,12 +258,6 @@ // object. ui::MotionEventAura pointer_state_; -#if defined(OS_WIN) - // Contains a copy of the last context menu request parameters. Only set when - // we receive a request to show the context menu on a long press. - std::unique_ptr<ContextMenuParams> last_context_menu_params_; -#endif // defined(OS_WIN) - // The following are not owned. They should outlive |this| RenderWidgetHostImpl* const host_; // Should create |this| and own it.
diff --git a/content/browser/web_contents/web_contents_view_aura.cc b/content/browser/web_contents/web_contents_view_aura.cc index f544135..11bae2c 100644 --- a/content/browser/web_contents/web_contents_view_aura.cc +++ b/content/browser/web_contents/web_contents_view_aura.cc
@@ -882,11 +882,6 @@ } if (delegate_) { - RenderWidgetHostViewAura* view = ToRenderWidgetHostViewAura( - web_contents_->GetRenderWidgetHostView()); - if (view && !view->OnShowContextMenu(params)) - return; - delegate_->ShowContextMenu(render_frame_host, params); // WARNING: we may have been deleted during the call to ShowContextMenu(). }
diff --git a/content/common/DEPS b/content/common/DEPS index 66e5800..2738ff18 100644 --- a/content/common/DEPS +++ b/content/common/DEPS
@@ -12,6 +12,7 @@ "+services/service_manager/public/cpp", "+services/service_manager/sandbox", "+services/video_capture/public/mojom", + "+services/viz/public/cpp", "+services/viz/public/interfaces", # No inclusion of WebKit from the browser, other than the ones in
diff --git a/content/common/frame.mojom b/content/common/frame.mojom index e7f954c..c0e2147 100644 --- a/content/common/frame.mojom +++ b/content/common/frame.mojom
@@ -16,6 +16,7 @@ import "services/network/public/mojom/url_loader.mojom"; import "services/service_manager/public/mojom/interface_provider.mojom"; import "services/viz/public/interfaces/compositing/surface_id.mojom"; +import "third_party/WebKit/public/mojom/blob/blob_url_store.mojom"; import "third_party/WebKit/public/mojom/feature_policy/feature_policy.mojom"; import "third_party/WebKit/public/platform/referrer.mojom"; import "third_party/WebKit/public/web/commit_result.mojom"; @@ -267,9 +268,18 @@ DidCommitProvisionalLoadParams params); // Sent by the renderer to request a navigation. + // |blob_url_token| should be non-null when this is a navigation to a blob: + // URL. The token will then be used to look up the blob associated with the + // blob URL. Without this by the time the navigation code starts fetching + // the URL the blob URL might no longer be valid. |blob_url_token| is + // not part of BeginNavigationParams because that struct needs to be + // cloneable, and thus can't contain mojo interfaces. + // If an invalid BlobURLToken is passed in, or if the token doesn't match the + // url in |common_params|, the navigation will result in a network error. BeginNavigation( CommonNavigationParams common_params, - BeginNavigationParams begin_params); + BeginNavigationParams begin_params, + blink.mojom.BlobURLToken? blob_url_token); // Sent when a subresource response has started. // |cert_status| is the bitmask of status info of the SSL certificate. (see
diff --git a/content/common/input/synthetic_pointer_action_params.cc b/content/common/input/synthetic_pointer_action_params.cc index 23a42ec..a54e974b 100644 --- a/content/common/input/synthetic_pointer_action_params.cc +++ b/content/common/input/synthetic_pointer_action_params.cc
@@ -27,6 +27,10 @@ return blink::WebMouseEvent::kMiddleButtonDown; case SyntheticPointerActionParams::Button::RIGHT: return blink::WebMouseEvent::kRightButtonDown; + case SyntheticPointerActionParams::Button::BACK: + return blink::WebMouseEvent::kBackButtonDown; + case SyntheticPointerActionParams::Button::FORWARD: + return blink::WebMouseEvent::kForwardButtonDown; } NOTREACHED(); return blink::WebMouseEvent::kNoModifiers; @@ -43,9 +47,13 @@ return blink::WebMouseEvent::Button::kMiddle; case SyntheticPointerActionParams::Button::RIGHT: return blink::WebMouseEvent::Button::kRight; + case SyntheticPointerActionParams::Button::BACK: + return blink::WebMouseEvent::Button::kBack; + case SyntheticPointerActionParams::Button::FORWARD: + return blink::WebMouseEvent::Button::kForward; } NOTREACHED(); return blink::WebMouseEvent::Button::kNoButton; } -} // namespace content \ No newline at end of file +} // namespace content
diff --git a/content/common/input/synthetic_pointer_action_params.h b/content/common/input/synthetic_pointer_action_params.h index 970cc8c..4471be5c 100644 --- a/content/common/input/synthetic_pointer_action_params.h +++ b/content/common/input/synthetic_pointer_action_params.h
@@ -33,7 +33,14 @@ POINTER_ACTION_TYPE_MAX = IDLE }; - enum class Button { LEFT, MIDDLE, RIGHT, BUTTON_MAX = RIGHT }; + enum class Button { + LEFT, + MIDDLE, + RIGHT, + BACK, + FORWARD, + BUTTON_MAX = FORWARD + }; SyntheticPointerActionParams(); SyntheticPointerActionParams(PointerActionType action_type);
diff --git a/content/common/render_frame_metadata.mojom b/content/common/render_frame_metadata.mojom index 3d88ed8..a2283f9d 100644 --- a/content/common/render_frame_metadata.mojom +++ b/content/common/render_frame_metadata.mojom
@@ -4,6 +4,7 @@ module content.mojom; +import "services/viz/public/interfaces/compositing/selection.mojom"; import "ui/gfx/geometry/mojo/geometry.mojom"; // See components/viz/service/quads/render_frame_metadata.h @@ -20,6 +21,10 @@ // Indicates whether the scroll offset of the root layer is at top, i.e., // whether scroll_offset.y() == 0. bool is_scroll_offset_at_top; + + // Selection region relative to the current viewport. If the selection is + // empty or otherwise unused, the bound types will indicate such. + viz.mojom.Selection selection; }; // This interface is provided by the renderer. It can optionally enable
diff --git a/content/common/render_frame_metadata_struct_traits.cc b/content/common/render_frame_metadata_struct_traits.cc index abef9f1..e6129ebf 100644 --- a/content/common/render_frame_metadata_struct_traits.cc +++ b/content/common/render_frame_metadata_struct_traits.cc
@@ -4,7 +4,9 @@ #include "content/common/render_frame_metadata_struct_traits.h" +#include "services/viz/public/cpp/compositing/selection_struct_traits.h" #include "ui/gfx/geometry/mojo/geometry_struct_traits.h" +#include "ui/gfx/mojo/selection_bound_struct_traits.h" namespace mojo { @@ -15,7 +17,8 @@ cc::RenderFrameMetadata* out) { out->root_background_color = data.root_background_color(); out->is_scroll_offset_at_top = data.is_scroll_offset_at_top(); - return data.ReadRootScrollOffset(&out->root_scroll_offset); + return data.ReadRootScrollOffset(&out->root_scroll_offset) && + data.ReadSelection(&out->selection); } } // namespace mojo
diff --git a/content/common/render_frame_metadata_struct_traits.h b/content/common/render_frame_metadata_struct_traits.h index ee9edc63..de13e7a 100644 --- a/content/common/render_frame_metadata_struct_traits.h +++ b/content/common/render_frame_metadata_struct_traits.h
@@ -28,6 +28,11 @@ return metadata.is_scroll_offset_at_top; } + static const viz::Selection<gfx::SelectionBound>& selection( + const cc::RenderFrameMetadata& metadata) { + return metadata.selection; + } + static bool Read(content::mojom::RenderFrameMetadataDataView data, cc::RenderFrameMetadata* out); };
diff --git a/content/public/android/java/src/org/chromium/content/browser/ContentViewCoreImpl.java b/content/public/android/java/src/org/chromium/content/browser/ContentViewCoreImpl.java index da59b098..0faca8a 100644 --- a/content/public/android/java/src/org/chromium/content/browser/ContentViewCoreImpl.java +++ b/content/public/android/java/src/org/chromium/content/browser/ContentViewCoreImpl.java
@@ -13,7 +13,6 @@ import android.view.KeyEvent; import android.view.MotionEvent; import android.view.Surface; -import android.view.View; import android.view.ViewGroup; import org.chromium.base.ObserverList; @@ -579,19 +578,6 @@ // End FrameLayout overrides. - @SuppressWarnings("javadoc") - @Override - public boolean awakenScrollBars(int startDelay, boolean invalidate) { - // For the default implementation of ContentView which draws the scrollBars on the native - // side, calling this function may get us into a bad state where we keep drawing the - // scrollBars, so disable it by always returning false. - if (mContainerView.getScrollBarStyle() == View.SCROLLBARS_INSIDE_OVERLAY) { - return false; - } else { - return mContainerViewInternals.super_awakenScrollBars(startDelay, invalidate); - } - } - @Override public void updateMultiTouchZoomSupport(boolean supportsMultiTouchZoom) { if (mNativeContentViewCore == 0) return;
diff --git a/content/public/android/java/src/org/chromium/content/browser/PopupZoomer.java b/content/public/android/java/src/org/chromium/content/browser/PopupZoomer.java index bad03ddf3..7270ccf 100644 --- a/content/public/android/java/src/org/chromium/content/browser/PopupZoomer.java +++ b/content/public/android/java/src/org/chromium/content/browser/PopupZoomer.java
@@ -21,6 +21,7 @@ import android.graphics.Region.Op; import android.graphics.drawable.ColorDrawable; import android.graphics.drawable.Drawable; +import android.os.Build; import android.os.SystemClock; import android.view.GestureDetector; import android.view.MotionEvent; @@ -264,7 +265,11 @@ RectF canvasRect = new RectF(0, 0, canvas.getWidth(), canvas.getHeight()); float overlayCornerRadius = getOverlayCornerRadius(getContext()); path.addRoundRect(canvasRect, overlayCornerRadius, overlayCornerRadius, Direction.CCW); - canvas.clipPath(path, Op.XOR); + if (Build.VERSION.SDK_INT >= Build.VERSION_CODES.O) { + canvas.clipOutPath(path); + } else { + canvas.clipPath(path, Op.DIFFERENCE); + } Paint clearPaint = new Paint(); clearPaint.setXfermode(new PorterDuffXfermode(Mode.SRC)); clearPaint.setColor(Color.TRANSPARENT);
diff --git a/content/public/android/java/src/org/chromium/content_public/browser/ContentViewCore.java b/content/public/android/java/src/org/chromium/content_public/browser/ContentViewCore.java index 9e92759c..792ca034 100644 --- a/content/public/android/java/src/org/chromium/content_public/browser/ContentViewCore.java +++ b/content/public/android/java/src/org/chromium/content_public/browser/ContentViewCore.java
@@ -80,11 +80,6 @@ * @see View#onScrollChanged(int, int, int, int) */ void onScrollChanged(int lPix, int tPix, int oldlPix, int oldtPix); - - /** - * @see View#awakenScrollBars(int, boolean) - */ - boolean super_awakenScrollBars(int startDelay, boolean invalidate); } /** @@ -250,11 +245,6 @@ int computeVerticalScrollExtent(); /** - * @see View#awakenScrollBars(int, boolean) - */ - boolean awakenScrollBars(int startDelay, boolean invalidate); - - /** * Enable or disable multi-touch zoom support. * @param supportsMultiTouchZoom {@code true} if the feature is enabled. */
diff --git a/content/public/android/javatests/src/org/chromium/content/browser/ContentViewScrollingTest.java b/content/public/android/javatests/src/org/chromium/content/browser/ContentViewScrollingTest.java index 8702271..034c1ee 100644 --- a/content/public/android/javatests/src/org/chromium/content/browser/ContentViewScrollingTest.java +++ b/content/public/android/javatests/src/org/chromium/content/browser/ContentViewScrollingTest.java
@@ -78,11 +78,6 @@ } } - @Override - public boolean super_awakenScrollBars(int startDelay, boolean invalidate) { - return false; - } - /** * @return Whether OnScrollChanged() has been called. */
diff --git a/content/public/test/android/javatests/src/org/chromium/content/browser/test/util/TestContentViewCore.java b/content/public/test/android/javatests/src/org/chromium/content/browser/test/util/TestContentViewCore.java index bd157f8..daa04100 100644 --- a/content/public/test/android/javatests/src/org/chromium/content/browser/test/util/TestContentViewCore.java +++ b/content/public/test/android/javatests/src/org/chromium/content/browser/test/util/TestContentViewCore.java
@@ -122,11 +122,6 @@ } @Override - public boolean awakenScrollBars(int startDelay, boolean invalidate) { - return false; - } - - @Override public void updateMultiTouchZoomSupport(boolean supportsMultiTouchZoom) {} @Override
diff --git a/content/public/test/browser_test_utils.cc b/content/public/test/browser_test_utils.cc index 194a921..085ab671 100644 --- a/content/public/test/browser_test_utils.cc +++ b/content/public/test/browser_test_utils.cc
@@ -915,7 +915,7 @@ ->OnTouchEvent(&touch); } -void SimulateLongPressAt(WebContents* web_contents, const gfx::Point& point) { +void SimulateLongTapAt(WebContents* web_contents, const gfx::Point& point) { RenderWidgetHostViewAura* rwhva = static_cast<RenderWidgetHostViewAura*>( web_contents->GetRenderWidgetHostView()); @@ -941,6 +941,12 @@ ui::ET_TOUCH_RELEASED, point, base::TimeTicks(), ui::PointerDetails(ui::EventPointerType::POINTER_TYPE_TOUCH, 0)); rwhva->OnTouchEvent(&touch_end); + + ui::GestureEventDetails long_tap_details(ui::ET_GESTURE_LONG_TAP); + long_tap_details.set_device_type(ui::GestureDeviceType::DEVICE_TOUCHSCREEN); + ui::GestureEvent long_tap(point.x(), point.y(), 0, ui::EventTimeForNow(), + long_tap_details, touch_end.unique_event_id()); + rwhva->OnGestureEvent(&long_tap); } #endif
diff --git a/content/public/test/browser_test_utils.h b/content/public/test/browser_test_utils.h index 236488a..2fe3f83 100644 --- a/content/public/test/browser_test_utils.h +++ b/content/public/test/browser_test_utils.h
@@ -193,7 +193,7 @@ // Generates a TouchStart at |point|. void SimulateTouchPressAt(WebContents* web_contents, const gfx::Point& point); -void SimulateLongPressAt(WebContents* web_contents, const gfx::Point& point); +void SimulateLongTapAt(WebContents* web_contents, const gfx::Point& point); #endif // Taps the screen with modifires at |point|.
diff --git a/content/public/test/browsing_data_remover_test_util.cc b/content/public/test/browsing_data_remover_test_util.cc index 184d8063..a153d10 100644 --- a/content/public/test/browsing_data_remover_test_util.cc +++ b/content/public/test/browsing_data_remover_test_util.cc
@@ -19,12 +19,25 @@ ~BrowsingDataRemoverCompletionObserver() {} void BrowsingDataRemoverCompletionObserver::BlockUntilCompletion() { - base::TaskScheduler::GetInstance()->FlushForTesting(); + base::TaskScheduler::GetInstance()->FlushAsyncForTesting(base::BindOnce( + [](BrowsingDataRemoverCompletionObserver* observer) { + observer->flush_for_testing_complete_ = true; + observer->QuitRunLoopWhenTasksComplete(); + }, + base::Unretained(this))); run_loop_.Run(); } void BrowsingDataRemoverCompletionObserver::OnBrowsingDataRemoverDone() { + browsing_data_remover_done_ = true; observer_.RemoveAll(); + QuitRunLoopWhenTasksComplete(); +} + +void BrowsingDataRemoverCompletionObserver::QuitRunLoopWhenTasksComplete() { + if (!flush_for_testing_complete_ || !browsing_data_remover_done_) + return; + run_loop_.QuitWhenIdle(); } @@ -52,9 +65,16 @@ } void BrowsingDataRemoverCompletionInhibitor::BlockUntilNearCompletion() { - base::TaskScheduler::GetInstance()->FlushForTesting(); + base::TaskScheduler::GetInstance()->FlushAsyncForTesting(base::BindOnce( + [](BrowsingDataRemoverCompletionInhibitor* inhibitor) { + inhibitor->flush_for_testing_complete_ = true; + inhibitor->QuitRunLoopWhenTasksComplete(); + }, + base::Unretained(this))); run_loop_->Run(); run_loop_ = std::make_unique<base::RunLoop>(); + flush_for_testing_complete_ = false; + browsing_data_remover_would_complete_done_ = false; } void BrowsingDataRemoverCompletionInhibitor::ContinueToCompletion() { @@ -67,6 +87,16 @@ const base::Closure& continue_to_completion) { DCHECK(continue_to_completion_callback_.is_null()); continue_to_completion_callback_ = continue_to_completion; + browsing_data_remover_would_complete_done_ = true; + QuitRunLoopWhenTasksComplete(); +} + +void BrowsingDataRemoverCompletionInhibitor::QuitRunLoopWhenTasksComplete() { + if (!flush_for_testing_complete_ || + !browsing_data_remover_would_complete_done_) { + return; + } + run_loop_->QuitWhenIdle(); }
diff --git a/content/public/test/browsing_data_remover_test_util.h b/content/public/test/browsing_data_remover_test_util.h index 403745c..4d31980 100644 --- a/content/public/test/browsing_data_remover_test_util.h +++ b/content/public/test/browsing_data_remover_test_util.h
@@ -29,6 +29,15 @@ void OnBrowsingDataRemoverDone() override; private: + void QuitRunLoopWhenTasksComplete(); + + // Tracks when the Task Scheduler task flushing is done. + bool flush_for_testing_complete_ = false; + + // Tracks when BrowsingDataRemover::Observer::OnBrowsingDataRemoverDone() is + // called. + bool browsing_data_remover_done_ = false; + base::RunLoop run_loop_; ScopedObserver<BrowsingDataRemover, BrowsingDataRemover::Observer> observer_; @@ -57,6 +66,14 @@ const base::Closure& continue_to_completion); private: + void QuitRunLoopWhenTasksComplete(); + + // Tracks when the Task Scheduler task flushing is done. + bool flush_for_testing_complete_ = false; + + // Tracks when OnBrowsingDataRemoverWouldComplete() is called. + bool browsing_data_remover_would_complete_done_ = false; + // Not owned by this class. If the pointer becomes invalid, the owner of // this class is responsible for calling Reset(). BrowsingDataRemover* remover_;
diff --git a/content/public/test/navigation_simulator.cc b/content/public/test/navigation_simulator.cc index ace5769c..65dc166 100644 --- a/content/public/test/navigation_simulator.cc +++ b/content/public/test/navigation_simulator.cc
@@ -861,7 +861,7 @@ : FrameMsg_Navigate_Type::DIFFERENT_DOCUMENT; common_params.has_user_gesture = has_user_gesture_; render_frame_host_->frame_host_binding_for_testing().impl()->BeginNavigation( - common_params, std::move(begin_params)); + common_params, std::move(begin_params), nullptr); NavigationRequest* request = render_frame_host_->frame_tree_node()->navigation_request();
diff --git a/content/renderer/device_sensors/device_motion_event_pump_unittest.cc b/content/renderer/device_sensors/device_motion_event_pump_unittest.cc index 5d72c91..75d248f 100644 --- a/content/renderer/device_sensors/device_motion_event_pump_unittest.cc +++ b/content/renderer/device_sensors/device_motion_event_pump_unittest.cc
@@ -15,9 +15,9 @@ #include "base/threading/thread_task_runner_handle.h" #include "base/time/time.h" #include "content/public/test/test_utils.h" -#include "content/renderer/device_sensors/fake_sensor_and_provider.h" #include "mojo/public/cpp/bindings/interface_request.h" #include "services/device/public/cpp/generic_sensor/motion_data.h" +#include "services/device/public/cpp/test/fake_sensor_and_provider.h" #include "services/device/public/mojom/sensor.mojom.h" #include "services/device/public/mojom/sensor_provider.mojom.h" #include "testing/gtest/include/gtest/gtest.h" @@ -27,6 +27,8 @@ namespace content { +using device::FakeSensorProvider; + class MockDeviceMotionListener : public blink::WebDeviceMotionListener { public: MockDeviceMotionListener() @@ -216,9 +218,9 @@ ExpectAllThreeSensorsStateToBe(DeviceMotionEventPump::SensorState::ACTIVE); - sensor_provider()->SetAccelerometerData(1, 2, 3); - sensor_provider()->SetLinearAccelerationSensorData(4, 5, 6); - sensor_provider()->SetGyroscopeData(7, 8, 9); + sensor_provider()->UpdateAccelerometerData(1, 2, 3); + sensor_provider()->UpdateLinearAccelerationSensorData(4, 5, 6); + sensor_provider()->UpdateGyroscopeData(7, 8, 9); FireEvent(); @@ -262,8 +264,8 @@ DeviceMotionEventPump::SensorState::NOT_INITIALIZED); ExpectGyroscopeStateToBe(DeviceMotionEventPump::SensorState::ACTIVE); - sensor_provider()->SetAccelerometerData(1, 2, 3); - sensor_provider()->SetGyroscopeData(7, 8, 9); + sensor_provider()->UpdateAccelerometerData(1, 2, 3); + sensor_provider()->UpdateGyroscopeData(7, 8, 9); FireEvent(); @@ -302,9 +304,9 @@ ExpectAllThreeSensorsStateToBe(DeviceMotionEventPump::SensorState::ACTIVE); - sensor_provider()->SetAccelerometerData(NAN, 2, 3); - sensor_provider()->SetLinearAccelerationSensorData(4, NAN, 6); - sensor_provider()->SetGyroscopeData(7, 8, NAN); + sensor_provider()->UpdateAccelerometerData(NAN, 2, 3); + sensor_provider()->UpdateLinearAccelerationSensorData(4, NAN, 6); + sensor_provider()->UpdateGyroscopeData(7, 8, NAN); FireEvent(); @@ -379,15 +381,15 @@ FireEvent(); EXPECT_FALSE(listener()->did_change_device_motion()); - sensor_provider()->SetAccelerometerData(1, 2, 3); + sensor_provider()->UpdateAccelerometerData(1, 2, 3); FireEvent(); EXPECT_FALSE(listener()->did_change_device_motion()); - sensor_provider()->SetLinearAccelerationSensorData(4, 5, 6); + sensor_provider()->UpdateLinearAccelerationSensorData(4, 5, 6); FireEvent(); EXPECT_FALSE(listener()->did_change_device_motion()); - sensor_provider()->SetGyroscopeData(7, 8, 9); + sensor_provider()->UpdateGyroscopeData(7, 8, 9); FireEvent(); // Event is fired only after all the available sensors have data. EXPECT_TRUE(listener()->did_change_device_motion()); @@ -410,9 +412,9 @@ ExpectAllThreeSensorsStateToBe(DeviceMotionEventPump::SensorState::ACTIVE); - sensor_provider()->SetAccelerometerData(1, 2, 3); - sensor_provider()->SetLinearAccelerationSensorData(4, 5, 6); - sensor_provider()->SetGyroscopeData(7, 8, 9); + sensor_provider()->UpdateAccelerometerData(1, 2, 3); + sensor_provider()->UpdateLinearAccelerationSensorData(4, 5, 6); + sensor_provider()->UpdateGyroscopeData(7, 8, 9); blink::scheduler::GetSingleThreadTaskRunnerForTesting()->PostDelayedTask( FROM_HERE, base::MessageLoop::QuitWhenIdleClosure(),
diff --git a/content/renderer/device_sensors/device_orientation_event_pump_unittest.cc b/content/renderer/device_sensors/device_orientation_event_pump_unittest.cc index 836d5f1..2d58a77 100644 --- a/content/renderer/device_sensors/device_orientation_event_pump_unittest.cc +++ b/content/renderer/device_sensors/device_orientation_event_pump_unittest.cc
@@ -12,9 +12,9 @@ #include "base/message_loop/message_loop.h" #include "base/run_loop.h" #include "content/public/test/test_utils.h" -#include "content/renderer/device_sensors/fake_sensor_and_provider.h" #include "mojo/public/cpp/bindings/interface_request.h" #include "services/device/public/cpp/generic_sensor/orientation_data.h" +#include "services/device/public/cpp/test/fake_sensor_and_provider.h" #include "services/device/public/mojom/sensor.mojom.h" #include "services/device/public/mojom/sensor_provider.mojom.h" #include "testing/gtest/include/gtest/gtest.h" @@ -29,6 +29,8 @@ namespace content { +using device::FakeSensorProvider; + class MockDeviceOrientationListener : public blink::WebDeviceOrientationListener { public: @@ -344,7 +346,7 @@ ExpectRelativeOrientationSensorStateToBe( DeviceOrientationEventPump::SensorState::ACTIVE); - sensor_provider()->SetRelativeOrientationSensorData( + sensor_provider()->UpdateRelativeOrientationSensorData( 1 /* alpha */, 2 /* beta */, 3 /* gamma */); FireEvent(); @@ -379,7 +381,7 @@ ExpectAbsoluteOrientationSensorStateToBe( DeviceOrientationEventPump::SensorState::ACTIVE); - sensor_provider()->SetAbsoluteOrientationSensorData( + sensor_provider()->UpdateAbsoluteOrientationSensorData( 4 /* alpha */, 5 /* beta */, 6 /* gamma */); FireEvent(); @@ -415,7 +417,7 @@ ExpectRelativeOrientationSensorStateToBe( DeviceOrientationEventPump::SensorState::ACTIVE); - sensor_provider()->SetRelativeOrientationSensorData( + sensor_provider()->UpdateRelativeOrientationSensorData( NAN /* alpha */, 2 /* beta */, 3 /* gamma */); FireEvent(); @@ -448,7 +450,7 @@ ExpectAbsoluteOrientationSensorStateToBe( DeviceOrientationEventPump::SensorState::ACTIVE); - sensor_provider()->SetAbsoluteOrientationSensorData( + sensor_provider()->UpdateAbsoluteOrientationSensorData( 4 /* alpha */, NAN /* beta */, 6 /* gamma */); FireEvent(); @@ -556,7 +558,7 @@ ExpectRelativeOrientationSensorStateToBe( DeviceOrientationEventPump::SensorState::ACTIVE); - sensor_provider()->SetRelativeOrientationSensorData( + sensor_provider()->UpdateRelativeOrientationSensorData( 1 /* alpha */, 2 /* beta */, 3 /* gamma */); FireEvent(); @@ -576,7 +578,7 @@ listener()->set_did_change_device_orientation(false); - sensor_provider()->SetRelativeOrientationSensorData( + sensor_provider()->UpdateRelativeOrientationSensorData( 1 + DeviceOrientationEventPump::kOrientationThreshold / 2.0 /* alpha */, 2 /* beta */, 3 /* gamma */); @@ -595,7 +597,7 @@ listener()->set_did_change_device_orientation(false); - sensor_provider()->SetRelativeOrientationSensorData( + sensor_provider()->UpdateRelativeOrientationSensorData( 1 + DeviceOrientationEventPump::kOrientationThreshold /* alpha */, 2 /* beta */, 3 /* gamma */); @@ -631,7 +633,7 @@ ExpectAbsoluteOrientationSensorStateToBe( DeviceOrientationEventPump::SensorState::ACTIVE); - sensor_provider()->SetAbsoluteOrientationSensorData( + sensor_provider()->UpdateAbsoluteOrientationSensorData( 4 /* alpha */, 5 /* beta */, 6 /* gamma */); FireEvent(); @@ -654,7 +656,7 @@ listener()->set_did_change_device_orientation(false); - sensor_provider()->SetAbsoluteOrientationSensorData( + sensor_provider()->UpdateAbsoluteOrientationSensorData( 4 /* alpha */, 5 + DeviceOrientationEventPump::kOrientationThreshold / 2.0 /* beta */, 6 /* gamma */); @@ -674,7 +676,7 @@ listener()->set_did_change_device_orientation(false); - sensor_provider()->SetAbsoluteOrientationSensorData( + sensor_provider()->UpdateAbsoluteOrientationSensorData( 4 /* alpha */, 5 + DeviceOrientationEventPump::kOrientationThreshold + kEpsilon /* beta */, @@ -845,7 +847,7 @@ ExpectAbsoluteOrientationSensorStateToBe( DeviceOrientationEventPump::SensorState::ACTIVE); - sensor_provider()->SetAbsoluteOrientationSensorData( + sensor_provider()->UpdateAbsoluteOrientationSensorData( 4 /* alpha */, 5 /* beta */, 6 /* gamma */); FireEvent(); @@ -875,7 +877,7 @@ ExpectAbsoluteOrientationSensorStateToBe( DeviceOrientationEventPump::SensorState::ACTIVE); - sensor_provider()->SetAbsoluteOrientationSensorData( + sensor_provider()->UpdateAbsoluteOrientationSensorData( 4 /* alpha */, NAN /* beta */, 6 /* gamma */); FireEvent(); @@ -948,7 +950,7 @@ ExpectAbsoluteOrientationSensorStateToBe( DeviceOrientationEventPump::SensorState::ACTIVE); - sensor_provider()->SetAbsoluteOrientationSensorData( + sensor_provider()->UpdateAbsoluteOrientationSensorData( 4 /* alpha */, 5 /* beta */, 6 /* gamma */); FireEvent(); @@ -966,7 +968,7 @@ listener()->set_did_change_device_orientation(false); - sensor_provider()->SetAbsoluteOrientationSensorData( + sensor_provider()->UpdateAbsoluteOrientationSensorData( 4 /* alpha */, 5 + DeviceOrientationEventPump::kOrientationThreshold / 2.0 /* beta */, 6 /* gamma */); @@ -986,7 +988,7 @@ listener()->set_did_change_device_orientation(false); - sensor_provider()->SetAbsoluteOrientationSensorData( + sensor_provider()->UpdateAbsoluteOrientationSensorData( 4 /* alpha */, 5 + DeviceOrientationEventPump::kOrientationThreshold + kEpsilon /* beta */,
diff --git a/content/renderer/device_sensors/fake_sensor_and_provider.cc b/content/renderer/device_sensors/fake_sensor_and_provider.cc deleted file mode 100644 index 84e29b5..0000000 --- a/content/renderer/device_sensors/fake_sensor_and_provider.cc +++ /dev/null
@@ -1,241 +0,0 @@ -// Copyright 2018 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 "content/renderer/device_sensors/fake_sensor_and_provider.h" - -#include <memory> -#include <utility> - -#include "base/logging.h" -#include "base/time/time.h" -#include "mojo/public/cpp/bindings/interface_request.h" -#include "mojo/public/cpp/bindings/strong_binding.h" -#include "testing/gtest/include/gtest/gtest.h" - -namespace content { - -FakeSensor::FakeSensor(device::mojom::SensorType sensor_type) - : sensor_type_(sensor_type) { - shared_buffer_handle_ = mojo::SharedBufferHandle::Create( - sizeof(device::SensorReadingSharedBuffer) * - static_cast<uint64_t>(device::mojom::SensorType::LAST)); - - if (!shared_buffer_handle_.is_valid()) - return; - - // Create read/write mapping now, to ensure it is kept writable - // after the region is sealed read-only on Android. - shared_buffer_mapping_ = shared_buffer_handle_->MapAtOffset( - device::mojom::SensorInitParams::kReadBufferSizeForTests, - GetBufferOffset()); -} - -FakeSensor::~FakeSensor() = default; - -void FakeSensor::AddConfiguration( - const device::PlatformSensorConfiguration& configuration, - AddConfigurationCallback callback) { - std::move(callback).Run(true); -} - -void FakeSensor::GetDefaultConfiguration( - GetDefaultConfigurationCallback callback) { - std::move(callback).Run(GetDefaultConfiguration()); -} - -void FakeSensor::RemoveConfiguration( - const device::PlatformSensorConfiguration& configuration) {} - -void FakeSensor::Suspend() {} - -void FakeSensor::Resume() {} - -void FakeSensor::ConfigureReadingChangeNotifications(bool enabled) { - reading_notification_enabled_ = enabled; -} - -device::PlatformSensorConfiguration FakeSensor::GetDefaultConfiguration() { - return device::PlatformSensorConfiguration(60 /* frequency */); -} - -device::mojom::ReportingMode FakeSensor::GetReportingMode() { - return device::mojom::ReportingMode::ON_CHANGE; -} - -double FakeSensor::GetMaximumSupportedFrequency() { - return 60.0; -} - -double FakeSensor::GetMinimumSupportedFrequency() { - return 1.0; -} - -device::mojom::SensorClientRequest FakeSensor::GetClient() { - return mojo::MakeRequest(&client_); -} - -mojo::ScopedSharedBufferHandle FakeSensor::GetSharedBufferHandle() { - return shared_buffer_handle_->Clone( - mojo::SharedBufferHandle::AccessMode::READ_ONLY); -} - -uint64_t FakeSensor::GetBufferOffset() { - return device::SensorReadingSharedBuffer::GetOffset(sensor_type_); -} - -void FakeSensor::SetReading(device::SensorReading reading) { - reading_ = reading; - SensorReadingChanged(); -} - -void FakeSensor::SensorReadingChanged() { - if (!shared_buffer_mapping_.get()) - return; - - auto* buffer = static_cast<device::SensorReadingSharedBuffer*>( - shared_buffer_mapping_.get()); - - auto& seqlock = buffer->seqlock.value(); - seqlock.WriteBegin(); - buffer->reading = reading_; - seqlock.WriteEnd(); - - if (client_ && reading_notification_enabled_) - client_->SensorReadingChanged(); -} - -FakeSensorProvider::FakeSensorProvider() : binding_(this) {} - -FakeSensorProvider::~FakeSensorProvider() = default; - -void FakeSensorProvider::GetSensor(device::mojom::SensorType type, - GetSensorCallback callback) { - std::unique_ptr<FakeSensor> sensor; - - switch (type) { - case device::mojom::SensorType::ACCELEROMETER: - if (accelerometer_is_available_) { - sensor = std::make_unique<FakeSensor>( - device::mojom::SensorType::ACCELEROMETER); - accelerometer_ = sensor.get(); - } - break; - case device::mojom::SensorType::LINEAR_ACCELERATION: - if (linear_acceleration_sensor_is_available_) { - sensor = std::make_unique<FakeSensor>( - device::mojom::SensorType::LINEAR_ACCELERATION); - linear_acceleration_sensor_ = sensor.get(); - } - break; - case device::mojom::SensorType::GYROSCOPE: - if (gyroscope_is_available_) { - sensor = - std::make_unique<FakeSensor>(device::mojom::SensorType::GYROSCOPE); - gyroscope_ = sensor.get(); - } - break; - case device::mojom::SensorType::RELATIVE_ORIENTATION_EULER_ANGLES: - if (relative_orientation_sensor_is_available_) { - sensor = std::make_unique<FakeSensor>( - device::mojom::SensorType::RELATIVE_ORIENTATION_EULER_ANGLES); - relative_orientation_sensor_ = sensor.get(); - } - break; - case device::mojom::SensorType::ABSOLUTE_ORIENTATION_EULER_ANGLES: - if (absolute_orientation_sensor_is_available_) { - sensor = std::make_unique<FakeSensor>( - device::mojom::SensorType::ABSOLUTE_ORIENTATION_EULER_ANGLES); - absolute_orientation_sensor_ = sensor.get(); - } - break; - default: - NOTIMPLEMENTED(); - } - - if (sensor) { - auto init_params = device::mojom::SensorInitParams::New(); - init_params->client_request = sensor->GetClient(); - init_params->memory = sensor->GetSharedBufferHandle(); - init_params->buffer_offset = sensor->GetBufferOffset(); - init_params->default_configuration = sensor->GetDefaultConfiguration(); - init_params->maximum_frequency = sensor->GetMaximumSupportedFrequency(); - init_params->minimum_frequency = sensor->GetMinimumSupportedFrequency(); - - mojo::MakeStrongBinding(std::move(sensor), - mojo::MakeRequest(&init_params->sensor)); - std::move(callback).Run(device::mojom::SensorCreationResult::SUCCESS, - std::move(init_params)); - } else { - std::move(callback).Run( - device::mojom::SensorCreationResult::ERROR_NOT_AVAILABLE, nullptr); - } -} - -void FakeSensorProvider::Bind(device::mojom::SensorProviderRequest request) { - DCHECK(!binding_.is_bound()); - binding_.Bind(std::move(request)); -} - -void FakeSensorProvider::SetAccelerometerData(double x, double y, double z) { - device::SensorReading reading; - reading.raw.timestamp = - (base::TimeTicks::Now() - base::TimeTicks()).InSecondsF(); - reading.accel.x = x; - reading.accel.y = y; - reading.accel.z = z; - EXPECT_TRUE(accelerometer_); - accelerometer_->SetReading(reading); -} - -void FakeSensorProvider::SetLinearAccelerationSensorData(double x, - double y, - double z) { - device::SensorReading reading; - reading.raw.timestamp = - (base::TimeTicks::Now() - base::TimeTicks()).InSecondsF(); - reading.accel.x = x; - reading.accel.y = y; - reading.accel.z = z; - EXPECT_TRUE(linear_acceleration_sensor_); - linear_acceleration_sensor_->SetReading(reading); -} - -void FakeSensorProvider::SetGyroscopeData(double x, double y, double z) { - device::SensorReading reading; - reading.raw.timestamp = - (base::TimeTicks::Now() - base::TimeTicks()).InSecondsF(); - reading.gyro.x = x; - reading.gyro.y = y; - reading.gyro.z = z; - EXPECT_TRUE(gyroscope_); - gyroscope_->SetReading(reading); -} - -void FakeSensorProvider::SetRelativeOrientationSensorData(double alpha, - double beta, - double gamma) { - device::SensorReading reading; - reading.raw.timestamp = - (base::TimeTicks::Now() - base::TimeTicks()).InSecondsF(); - reading.orientation_euler.x = beta; - reading.orientation_euler.y = gamma; - reading.orientation_euler.z = alpha; - EXPECT_TRUE(relative_orientation_sensor_); - relative_orientation_sensor_->SetReading(reading); -} - -void FakeSensorProvider::SetAbsoluteOrientationSensorData(double alpha, - double beta, - double gamma) { - device::SensorReading reading; - reading.raw.timestamp = - (base::TimeTicks::Now() - base::TimeTicks()).InSecondsF(); - reading.orientation_euler.x = beta; - reading.orientation_euler.y = gamma; - reading.orientation_euler.z = alpha; - EXPECT_TRUE(absolute_orientation_sensor_); - absolute_orientation_sensor_->SetReading(reading); -} - -} // namespace content
diff --git a/content/renderer/device_sensors/fake_sensor_and_provider.h b/content/renderer/device_sensors/fake_sensor_and_provider.h deleted file mode 100644 index fb934e3..0000000 --- a/content/renderer/device_sensors/fake_sensor_and_provider.h +++ /dev/null
@@ -1,136 +0,0 @@ -// Copyright 2018 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 CONTENT_RENDERER_DEVICE_SENSORS_FAKE_SENSOR_AND_PROVIDER_H_ -#define CONTENT_RENDERER_DEVICE_SENSORS_FAKE_SENSOR_AND_PROVIDER_H_ - -#include "base/macros.h" -#include "mojo/public/cpp/bindings/binding.h" -#include "mojo/public/cpp/system/buffer.h" -#include "services/device/public/cpp/generic_sensor/sensor_reading.h" -#include "services/device/public/mojom/sensor.mojom.h" -#include "services/device/public/mojom/sensor_provider.mojom.h" - -// TODO(juncai): Move this file in a new -// //services/device/public/cpp/generic_sensor:test_support source_set and -// share it with device_sensor_browsertest.cc and generic_sensor_browsertest.cc. - -namespace content { - -class FakeSensor : public device::mojom::Sensor { - public: - FakeSensor(device::mojom::SensorType sensor_type); - ~FakeSensor() override; - - // device::mojom::Sensor: - void AddConfiguration( - const device::PlatformSensorConfiguration& configuration, - AddConfigurationCallback callback) override; - void GetDefaultConfiguration( - GetDefaultConfigurationCallback callback) override; - void RemoveConfiguration( - const device::PlatformSensorConfiguration& configuration) override; - void Suspend() override; - void Resume() override; - void ConfigureReadingChangeNotifications(bool enabled) override; - - device::PlatformSensorConfiguration GetDefaultConfiguration(); - - device::mojom::ReportingMode GetReportingMode(); - - double GetMaximumSupportedFrequency(); - - double GetMinimumSupportedFrequency(); - - device::mojom::SensorClientRequest GetClient(); - - mojo::ScopedSharedBufferHandle GetSharedBufferHandle(); - - uint64_t GetBufferOffset(); - - void SetReading(device::SensorReading reading); - - private: - void SensorReadingChanged(); - - device::mojom::SensorType sensor_type_; - bool reading_notification_enabled_ = true; - mojo::ScopedSharedBufferHandle shared_buffer_handle_; - mojo::ScopedSharedBufferMapping shared_buffer_mapping_; - device::mojom::SensorClientPtr client_; - device::SensorReading reading_; - - DISALLOW_COPY_AND_ASSIGN(FakeSensor); -}; - -class FakeSensorProvider : public device::mojom::SensorProvider { - public: - FakeSensorProvider(); - ~FakeSensorProvider() override; - - // device::mojom::sensorProvider: - void GetSensor(device::mojom::SensorType type, - GetSensorCallback callback) override; - - void Bind(device::mojom::SensorProviderRequest request); - - void set_accelerometer_is_available(bool accelerometer_is_available) { - accelerometer_is_available_ = accelerometer_is_available; - } - - void set_linear_acceleration_sensor_is_available( - bool linear_acceleration_sensor_is_available) { - linear_acceleration_sensor_is_available_ = - linear_acceleration_sensor_is_available; - } - - void set_gyroscope_is_available(bool gyroscope_is_available) { - gyroscope_is_available_ = gyroscope_is_available; - } - - void set_relative_orientation_sensor_is_available( - bool relative_orientation_sensor_is_available) { - relative_orientation_sensor_is_available_ = - relative_orientation_sensor_is_available; - } - - void set_absolute_orientation_sensor_is_available( - bool absolute_orientation_sensor_is_available) { - absolute_orientation_sensor_is_available_ = - absolute_orientation_sensor_is_available; - } - - void SetAccelerometerData(double x, double y, double z); - - void SetLinearAccelerationSensorData(double x, double y, double z); - - void SetGyroscopeData(double x, double y, double z); - - void SetRelativeOrientationSensorData(double alpha, - double beta, - double gamma); - - void SetAbsoluteOrientationSensorData(double alpha, - double beta, - double gamma); - - private: - FakeSensor* accelerometer_ = nullptr; - FakeSensor* linear_acceleration_sensor_ = nullptr; - FakeSensor* gyroscope_ = nullptr; - FakeSensor* relative_orientation_sensor_ = nullptr; - FakeSensor* absolute_orientation_sensor_ = nullptr; - bool accelerometer_is_available_ = true; - bool linear_acceleration_sensor_is_available_ = true; - bool gyroscope_is_available_ = true; - bool relative_orientation_sensor_is_available_ = true; - bool absolute_orientation_sensor_is_available_ = true; - mojo::Binding<device::mojom::SensorProvider> binding_; - - DISALLOW_COPY_AND_ASSIGN(FakeSensorProvider); -}; - -} // namespace content - -#endif // CONTENT_RENDERER_DEVICE_SENSORS_FAKE_SENSOR_AND_PROVIDER_H_
diff --git a/content/renderer/gpu/actions_parser.cc b/content/renderer/gpu/actions_parser.cc index 8094caf..9399e4d 100644 --- a/content/renderer/gpu/actions_parser.cc +++ b/content/renderer/gpu/actions_parser.cc
@@ -47,6 +47,10 @@ return SyntheticPointerActionParams::Button::MIDDLE; if (button == "right") return SyntheticPointerActionParams::Button::RIGHT; + if (button == "back") + return SyntheticPointerActionParams::Button::BACK; + if (button == "forward") + return SyntheticPointerActionParams::Button::FORWARD; NOTREACHED() << "Unexpected button"; return SyntheticPointerActionParams::Button(); } @@ -210,7 +214,8 @@ "actions[%d].actions.button is not a string", action_index_); return false; } else if (button_name != "left" && button_name != "middle" && - button_name != "right") { + button_name != "right" && button_name != "back" && + button_name != "forward") { error_message_ = base::StringPrintf( "actions[%d].actions.button is an unsupported button", action_index_); return false;
diff --git a/content/renderer/gpu/gpu_benchmarking_extension.cc b/content/renderer/gpu/gpu_benchmarking_extension.cc index 29d9b3e..8bff38c0 100644 --- a/content/renderer/gpu/gpu_benchmarking_extension.cc +++ b/content/renderer/gpu/gpu_benchmarking_extension.cc
@@ -970,8 +970,12 @@ // Get all the pointer actions from the user input and wrap them into a // SyntheticPointerActionListParams object. ActionsParser actions_parser(value.get()); - if (!actions_parser.ParsePointerActionSequence()) + if (!actions_parser.ParsePointerActionSequence()) { + // TODO(dtapuska): Throw an error here, some layout tests start + // failing when this is done though. + // args->ThrowTypeError(actions_parser.error_message()); return false; + } if (!GetOptionalArg(args, &callback)) { args->ThrowError();
diff --git a/content/renderer/render_frame_impl.cc b/content/renderer/render_frame_impl.cc index 3484393..252167b 100644 --- a/content/renderer/render_frame_impl.cc +++ b/content/renderer/render_frame_impl.cc
@@ -4143,6 +4143,8 @@ info.source_location = pending_navigation_info_->source_location; info.devtools_initiator_info = pending_navigation_info_->devtools_initiator_info; + info.blob_url_token = + pending_navigation_info_->blob_url_token.PassInterface().PassHandle(); pending_navigation_info_.reset(nullptr); BeginNavigation(info); @@ -6965,6 +6967,15 @@ if (info.is_client_redirect) client_side_redirect_url = frame_->GetDocument().Url(); + blink::mojom::BlobURLTokenPtr blob_url_token; + if (info.blob_url_token.is_valid()) { + blink::mojom::BlobURLTokenPtr token(blink::mojom::BlobURLTokenPtrInfo( + mojo::ScopedMessagePipeHandle(info.blob_url_token.get()), + blink::mojom::BlobURLToken::Version_)); + token->Clone(MakeRequest(&blob_url_token)); + ignore_result(token.PassInterface().PassHandle().release()); + } + int load_flags = GetLoadFlagsForWebURLRequest(info.url_request); std::unique_ptr<base::DictionaryValue> initiator = GetDevToolsInitiator(info.devtools_initiator_info); @@ -6978,7 +6989,8 @@ initiator_origin, client_side_redirect_url, std::move(initiator)); GetFrameHost()->BeginNavigation(MakeCommonNavigationParams(info, load_flags), - std::move(begin_navigation_params)); + std::move(begin_navigation_params), + std::move(blob_url_token)); } void RenderFrameImpl::LoadDataURL( @@ -7563,7 +7575,17 @@ triggering_event_info(info.triggering_event_info), form(info.form), source_location(info.source_location), - devtools_initiator_info(info.devtools_initiator_info) {} + devtools_initiator_info(info.devtools_initiator_info) { + if (info.blob_url_token.is_valid()) { + blink::mojom::BlobURLTokenPtr token(blink::mojom::BlobURLTokenPtrInfo( + mojo::ScopedMessagePipeHandle(info.blob_url_token.get()), + blink::mojom::BlobURLToken::Version_)); + token->Clone(MakeRequest(&blob_url_token)); + ignore_result(token.PassInterface().PassHandle().release()); + } +} + +RenderFrameImpl::PendingNavigationInfo::~PendingNavigationInfo() = default; void RenderFrameImpl::BindWidget(mojom::WidgetRequest request) { GetRenderWidget()->SetWidgetBinding(std::move(request));
diff --git a/content/renderer/render_frame_impl.h b/content/renderer/render_frame_impl.h index 43695e8..c2e7898 100644 --- a/content/renderer/render_frame_impl.h +++ b/content/renderer/render_frame_impl.h
@@ -1630,8 +1630,10 @@ blink::WebFormElement form; blink::WebSourceLocation source_location; blink::WebString devtools_initiator_info; + blink::mojom::BlobURLTokenPtr blob_url_token; explicit PendingNavigationInfo(const NavigationPolicyInfo& info); + ~PendingNavigationInfo(); }; // Contains information about a pending navigation to be sent to the browser.
diff --git a/content/test/BUILD.gn b/content/test/BUILD.gn index 3cfe3421..2c8c5ea 100644 --- a/content/test/BUILD.gn +++ b/content/test/BUILD.gn
@@ -908,6 +908,7 @@ "//services/catalog:lib", "//services/device/public/cpp:device_features", "//services/device/public/cpp/generic_sensor", + "//services/device/public/cpp/test:test_support", "//services/device/public/mojom", "//services/device/public/mojom:generic_sensor", "//services/network:test_support", @@ -1570,8 +1571,6 @@ "../renderer/child_frame_compositing_helper_unittest.cc", "../renderer/device_sensors/device_motion_event_pump_unittest.cc", "../renderer/device_sensors/device_orientation_event_pump_unittest.cc", - "../renderer/device_sensors/fake_sensor_and_provider.cc", - "../renderer/device_sensors/fake_sensor_and_provider.h", "../renderer/dom_storage/dom_storage_cached_area_unittest.cc", "../renderer/dom_storage/local_storage_cached_area_unittest.cc", "../renderer/dom_storage/local_storage_cached_areas_unittest.cc", @@ -1721,6 +1720,7 @@ "//printing", "//services/catalog:lib", "//services/device/public/cpp/generic_sensor", + "//services/device/public/cpp/test:test_support", "//services/device/public/mojom", "//services/file:lib", "//services/file/public/mojom",
diff --git a/content/test/data/fuzzer_dictionaries/merkle_integrity_source_stream_fuzzer.dict b/content/test/data/fuzzer_dictionaries/merkle_integrity_source_stream_fuzzer.dict new file mode 100644 index 0000000..87687fc --- /dev/null +++ b/content/test/data/fuzzer_dictionaries/merkle_integrity_source_stream_fuzzer.dict
@@ -0,0 +1,15 @@ +# Copyright 2018 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. + +# The fuzzer build fills all hashes with 0x42. +"\x42\x42\x42\x42\x42\x42\x42\x42\x42\x42\x42\x42\x42\x42\x42\x42\x42\x42\x42\x42\x42\x42\x42\x42\x42\x42\x42\x42\x42\x42\x42\x42" + +# The header version of the hash. +"mi-sha256=QkJCQkJCQkJCQkJCQkJCQkJCQkJCQkJCQkJCQkJCQkI\\ " + +# base::FuzzedDataProvider separator. +"\\ " + +# Use a 16-byte record size if you don't have better ideas. +"\x00\x00\x00\x00\x00\x00\x00\x10"
diff --git a/content/test/fuzzer/BUILD.gn b/content/test/fuzzer/BUILD.gn index 4aec9d2..b1bde37 100644 --- a/content/test/fuzzer/BUILD.gn +++ b/content/test/fuzzer/BUILD.gn
@@ -144,3 +144,24 @@ seed_corpus = "//third_party/WebKit/LayoutTests/http/tests/appcache/resources/" } + +fuzzer_test("merkle_integrity_source_stream_fuzzer") { + sources = [ + "merkle_integrity_source_stream_fuzzer.cc", + ] + + # This fuzzer depends on net::FuzzedSourceStream, in net_fuzzer_test_support, + # but both it and //content:test_support set up similar globals. As + # MerkleIntegritySourceStream does not depend on anything in //content and + # will ultimately live in //net, use the //net one instead of the //content + # one. + deps = [ + "//content/browser:for_content_tests", + "//content/renderer:for_content_tests", + "//content/shell:content_shell_lib", + "//content/test:test_support", + "//net:net_fuzzer_test_support", + "//net:test_support", + ] + dict = "//content/test/data/fuzzer_dictionaries/merkle_integrity_source_stream_fuzzer.dict" +}
diff --git a/content/test/fuzzer/merkle_integrity_source_stream_fuzzer.cc b/content/test/fuzzer/merkle_integrity_source_stream_fuzzer.cc new file mode 100644 index 0000000..8e3a419 --- /dev/null +++ b/content/test/fuzzer/merkle_integrity_source_stream_fuzzer.cc
@@ -0,0 +1,42 @@ +// Copyright 2018 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 "content/browser/loader/merkle_integrity_source_stream.h" // nogncheck + +#include <string> + +#include "base/logging.h" +#include "base/memory/scoped_refptr.h" +#include "base/test/fuzzed_data_provider.h" +#include "net/base/io_buffer.h" +#include "net/base/test_completion_callback.h" +#include "net/filter/fuzzed_source_stream.h" + +// Fuzzer for MerkleIntegritySourceStream +// +// |data| contains a header prefix, and then is used to build a +// FuzzedSourceStream. +extern "C" int LLVMFuzzerTestOneInput(const uint8_t* data, size_t size) { + base::FuzzedDataProvider data_provider(data, size); + std::string header = data_provider.ConsumeRandomLengthString(256); + + net::TestCompletionCallback callback; + auto fuzzed_source_stream = + std::make_unique<net::FuzzedSourceStream>(&data_provider); + auto mi_stream = std::make_unique<content::MerkleIntegritySourceStream>( + header, std::move(fuzzed_source_stream)); + while (true) { + size_t read_size = data_provider.ConsumeUint32InRange(1, 1024); + auto io_buffer = base::MakeRefCounted<net::IOBufferWithSize>(read_size); + int result = mi_stream->Read(io_buffer.get(), io_buffer->size(), + callback.callback()); + // Releasing the pointer to IOBuffer immediately is more likely to lead to a + // use-after-free. + io_buffer = nullptr; + if (callback.GetResult(result) <= 0) + break; + } + + return 0; +}
diff --git a/content/test/gpu/gpu_tests/pixel_expectations.py b/content/test/gpu/gpu_tests/pixel_expectations.py index 173e8c5..7d91e3ce 100644 --- a/content/test/gpu/gpu_tests/pixel_expectations.py +++ b/content/test/gpu/gpu_tests/pixel_expectations.py
@@ -111,3 +111,17 @@ ['linux', 'mac', 'win'], bug=744658) self.Fail('Pixel_CSS3DBlueBox_NoGpuProcess', ['linux', 'mac', 'win'], bug=744658) + + # TODO(enne): temporarily suppress these tests until rebaselined. + self.Fail('Pixel_2DCanvasWebGL', ['android'], bug=972546) + self.Fail('Pixel_Canvas2DRedBox', ['android'], bug=972546) + self.Fail('Pixel_CanvasDisplayLinearRGBAccelerated2D', + ['android'], bug=972546) + self.Fail('Pixel_CanvasDisplayLinearRGBUnaccelerated2DGPUCompositing', + ['android'], bug=972546) + self.Fail('Pixel_WebGLGreenTriangle_AA_Alpha', ['android'], bug=972546) + self.Fail('Pixel_WebGLGreenTriangle_AA_NoAlpha', ['android'], bug=972546) + self.Fail('Pixel_WebGLGreenTriangle_NoAA_Alpha', ['android'], bug=972546) + self.Fail('Pixel_WebGLGreenTriangle_NoAA_NoAlpha', ['android'], bug=972546) + self.Fail('Pixel_WebGLTransparentGreenTriangle_NoAlpha_ImplicitClear', + ['android'], bug=972546)
diff --git a/content/test/gpu/gpu_tests/webgl2_conformance_expectations.py b/content/test/gpu/gpu_tests/webgl2_conformance_expectations.py index 432d8b8f..8b626be 100644 --- a/content/test/gpu/gpu_tests/webgl2_conformance_expectations.py +++ b/content/test/gpu/gpu_tests/webgl2_conformance_expectations.py
@@ -121,9 +121,13 @@ self.Fail('conformance2/transform_feedback/switching-objects.html', ['linux', 'intel', 'no_angle'], bug=696345) self.Fail('conformance2/transform_feedback/switching-objects.html', + ['linux', 'amd', 'no_angle'], bug=696345) + self.Fail('conformance2/transform_feedback/switching-objects.html', ['mac', 'intel', 'no_angle'], bug=696345) self.Fail('conformance2/transform_feedback/switching-objects.html', ['mac', 'amd', 'no_angle'], bug=696345) + self.Fail('conformance2/transform_feedback/switching-objects.html', + ['mac', 'nvidia', 'no_angle'], bug=828579) # transform_feedback/too-small-buffers.html self.Fail('conformance2/transform_feedback/too-small-buffers.html', @@ -252,6 +256,8 @@ self.Fail('conformance2/rendering/' + 'blitframebuffer-srgb-and-linear-drawbuffers.html', ['win', 'nvidia', 'opengl'], bug=2355) # ANGLE bug ID + self.Fail('conformance2/rendering/clipping-wide-points.html', + ['win', 'nvidia', 'opengl'], bug=828572) self.Flaky('deqp/functional/gles3/transformfeedback/*', ['win', ('nvidia', 0x1cb3), 'opengl'], bug=822733)
diff --git a/content/test/test_render_frame.cc b/content/test/test_render_frame.cc index 83912c57..2644a43 100644 --- a/content/test/test_render_frame.cc +++ b/content/test/test_render_frame.cc
@@ -82,7 +82,8 @@ } void BeginNavigation(const CommonNavigationParams& common_params, - mojom::BeginNavigationParamsPtr begin_params) override {} + mojom::BeginNavigationParamsPtr begin_params, + blink::mojom::BlobURLTokenPtr blob_url_token) override {} void SubresourceResponseStarted(const GURL& url, net::CertStatus cert_status) override {}
diff --git a/content/test/test_render_frame_host.cc b/content/test/test_render_frame_host.cc index 23db12f..3de1d9b 100644 --- a/content/test/test_render_frame_host.cc +++ b/content/test/test_render_frame_host.cc
@@ -531,7 +531,7 @@ common_params.transition = ui::PAGE_TRANSITION_LINK; common_params.navigation_type = FrameMsg_Navigate_Type::DIFFERENT_DOCUMENT; common_params.has_user_gesture = has_user_gesture; - BeginNavigation(common_params, std::move(begin_params)); + BeginNavigation(common_params, std::move(begin_params), nullptr); } }
diff --git a/extensions/browser/extension_function_histogram_value.h b/extensions/browser/extension_function_histogram_value.h index 24df2902b..968d88e9 100644 --- a/extensions/browser/extension_function_histogram_value.h +++ b/extensions/browser/extension_function_histogram_value.h
@@ -1294,6 +1294,7 @@ DECLARATIVENETREQUEST_ADDWHITELISTEDPAGES, DECLARATIVENETREQUEST_REMOVEWHITELISTEDPAGES, DECLARATIVENETREQUEST_GETWHITELISTEDPAGES, + DEVELOPERPRIVATE_INSTALLDROPPEDFILE, // Last entry: Add new entries above, then run: // python tools/metrics/histograms/update_extension_histograms.py ENUM_BOUNDARY
diff --git a/extensions/browser/install/extension_install_ui.cc b/extensions/browser/install/extension_install_ui.cc index 03441b6..ed681e1a 100644 --- a/extensions/browser/install/extension_install_ui.cc +++ b/extensions/browser/install/extension_install_ui.cc
@@ -7,7 +7,7 @@ namespace extensions { // static -bool ExtensionInstallUI::disable_failure_ui_for_tests_ = false; +bool ExtensionInstallUI::disable_ui_for_tests_ = false; ExtensionInstallUI::ExtensionInstallUI() { }
diff --git a/extensions/browser/install/extension_install_ui.h b/extensions/browser/install/extension_install_ui.h index e17529c..2637882 100644 --- a/extensions/browser/install/extension_install_ui.h +++ b/extensions/browser/install/extension_install_ui.h
@@ -49,18 +49,14 @@ virtual gfx::NativeWindow GetDefaultInstallDialogParent() = 0; #if defined(UNIT_TEST) - static void set_disable_failure_ui_for_tests() { - disable_failure_ui_for_tests_ = true; - } + static void set_disable_ui_for_tests() { disable_ui_for_tests_ = true; } #endif protected: - static bool disable_failure_ui_for_tests() { - return disable_failure_ui_for_tests_; - } + static bool disable_ui_for_tests() { return disable_ui_for_tests_; } private: - static bool disable_failure_ui_for_tests_; + static bool disable_ui_for_tests_; DISALLOW_COPY_AND_ASSIGN(ExtensionInstallUI); };
diff --git a/headless/lib/browser/headless_browser_context_impl.cc b/headless/lib/browser/headless_browser_context_impl.cc index eb14f1b..92e3143 100644 --- a/headless/lib/browser/headless_browser_context_impl.cc +++ b/headless/lib/browser/headless_browser_context_impl.cc
@@ -209,8 +209,7 @@ void HeadlessBrowserContextImpl::InitWhileIOAllowed() { if (!context_options_->user_data_dir().empty()) { - path_ = - context_options_->user_data_dir().Append(FILE_PATH_LITERAL("Default")); + path_ = context_options_->user_data_dir().Append(kDefaultProfileName); } else { PathService::Get(base::DIR_EXE, &path_); }
diff --git a/headless/lib/browser/headless_browser_impl.cc b/headless/lib/browser/headless_browser_impl.cc index b6cb7ddc..f1c26d6 100644 --- a/headless/lib/browser/headless_browser_impl.cc +++ b/headless/lib/browser/headless_browser_impl.cc
@@ -70,6 +70,9 @@ } // namespace +const base::FilePath::CharType kDefaultProfileName[] = + FILE_PATH_LITERAL("Default"); + HeadlessBrowserImpl::HeadlessBrowserImpl( base::OnceCallback<void(HeadlessBrowser*)> on_start_callback, HeadlessBrowser::Options options)
diff --git a/headless/lib/browser/headless_browser_impl.h b/headless/lib/browser/headless_browser_impl.h index b193b72..c1fc116 100644 --- a/headless/lib/browser/headless_browser_impl.h +++ b/headless/lib/browser/headless_browser_impl.h
@@ -33,6 +33,8 @@ class HeadlessBrowserContextImpl; class HeadlessBrowserMainParts; +extern const base::FilePath::CharType kDefaultProfileName[]; + // Exported for tests. class HEADLESS_EXPORT HeadlessBrowserImpl : public HeadlessBrowser, public HeadlessDevToolsTarget {
diff --git a/headless/lib/headless_content_main_delegate.cc b/headless/lib/headless_content_main_delegate.cc index 8214d381..07630e7 100644 --- a/headless/lib/headless_content_main_delegate.cc +++ b/headless/lib/headless_content_main_delegate.cc
@@ -160,10 +160,23 @@ base::FilePath log_path; logging::LoggingSettings settings; - if (PathService::Get(base::DIR_MODULE, &log_path)) { +// In release builds we should log into the user profile directory. +#ifdef NDEBUG + if (!browser_->options()->user_data_dir.empty()) { + log_path = browser_->options()->user_data_dir; + log_path = log_path.Append(kDefaultProfileName); + base::CreateDirectory(log_path); log_path = log_path.Append(log_filename); - } else { - log_path = log_filename; + } +#endif // NDEBUG + + // Otherwise we log to where the executable is. + if (log_path.empty()) { + if (PathService::Get(base::DIR_MODULE, &log_path)) { + log_path = log_path.Append(log_filename); + } else { + log_path = log_filename; + } } std::string filename;
diff --git a/infra/config/branch/cq.cfg b/infra/config/branch/cq.cfg index 3361c248..fd8cb65 100644 --- a/infra/config/branch/cq.cfg +++ b/infra/config/branch/cq.cfg
@@ -33,7 +33,7 @@ name: "master.tryserver.chromium.android" builders { name: "android_arm64_dbg_recipe" - equivalent_to { bucket: "luci.chromium.try" percentage: 10 } + equivalent_to { bucket: "luci.chromium.try" percentage: 50 } } builders { name: "android_clang_dbg_recipe" @@ -87,7 +87,7 @@ } builders { name: "fuchsia_arm64" - equivalent_to { bucket: "luci.chromium.try" percentage: 0 } + equivalent_to { bucket: "luci.chromium.try" percentage: 100 } } builders { name: "fuchsia_x64"
diff --git a/infra/config/global/cr-buildbucket.cfg b/infra/config/global/cr-buildbucket.cfg index de0040e..45e25b8 100644 --- a/infra/config/global/cr-buildbucket.cfg +++ b/infra/config/global/cr-buildbucket.cfg
@@ -453,6 +453,22 @@ } builders { + name: "Deterministic Android" + mixins: "linux-ci" + recipe { + name: "swarming/deterministic_build" + } + } + + builders { + name: "Deterministic Android (dbg)" + mixins: "linux-ci" + recipe { + name: "swarming/deterministic_build" + } + } + + builders { name: "Marshmallow 64 bit Tester" mixins: "android-ci" dimensions: "os:Ubuntu-14.04" @@ -520,6 +536,14 @@ } builders { + name: "Deterministic Linux (dbg)" + mixins: "linux-ci" + recipe { + name: "swarming/deterministic_build" + } + } + + builders { name: "Linux ASan LSan Builder" mixins: "linux" mixins: "memory-ci" @@ -554,6 +578,12 @@ } builders { + name: "Linux Builder Jumbo" + mixins: "linux-ci" + dimensions: "cores:32" + } + + builders { name: "Linux Builder (dbg)" mixins: "linux-ci" dimensions: "cores:32" @@ -745,6 +775,12 @@ dimensions: "cores:32" } builders { + name: "Win x64 Builder (dbg)" + mixins: "win-ci" + dimensions: "cores:32" + dimensions: "os:Windows" + } + builders { name: "Win7 (32) Tests" mixins: "win-ci" dimensions: "os:Windows-7"
diff --git a/infra/config/global/luci-milo-dev.cfg b/infra/config/global/luci-milo-dev.cfg index befffb1..ff68595 100644 --- a/infra/config/global/luci-milo-dev.cfg +++ b/infra/config/global/luci-milo-dev.cfg
@@ -1459,17 +1459,6 @@ } builders: { - name: "buildbucket/luci.chromium.ci/Win Builder (dbg)" - category: "win|debug|builder|32" - short_name: "ᕕ(ᐛ)ᕗ" - } - builders: { - name: "buildbot/chromium.win/Win Builder (dbg)" - category: "win|debug|builder|32" - short_name: "(ಥ_ಥ)" - } - - builders: { name: "buildbucket/luci.chromium.ci/Win7 (32) Tests" category: "win|release|tester|7" short_name: "ᕕ(ᐛ)ᕗ" @@ -1490,17 +1479,6 @@ category: "win|release|tester|7" short_name: "(ಥ_ಥ)" } - - builders: { - name: "buildbucket/luci.chromium.ci/Win7 Tests (dbg)(1)" - category: "win|debug|tester|7" - short_name: "ᕕ(ᐛ)ᕗ" - } - builders: { - name: "buildbot/chromium.win/Win7 Tests (dbg)(1)" - category: "win|debug|tester|7" - short_name: "(ಥ_ಥ)" - } } # Everything below was generated from buildermap.json.
diff --git a/infra/config/global/luci-milo.cfg b/infra/config/global/luci-milo.cfg index 4f36afd1..a9ed5bb 100644 --- a/infra/config/global/luci-milo.cfg +++ b/infra/config/global/luci-milo.cfg
@@ -767,6 +767,7 @@ } builders: { name: "buildbot/chromium.win/Win x64 Builder (dbg)" + name: "buildbucket/luci.chromium.ci/Win x64 Builder (dbg)" category: "debug|builder" short_name: "64" } @@ -886,6 +887,11 @@ short_name: "bld" } builders: { + name: "buildbucket/luci.chromium.ci/Linux Jumbo Builder" + category: "jumbo" + short_name: "jumbo" + } + builders: { name: "buildbucket/luci.chromium.ci/Linux Tests" category: "release" short_name: "tst" @@ -1565,17 +1571,6 @@ } builders: { - name: "buildbucket/luci.chromium.ci/Win Builder (dbg)" - category: "win|debug|builder|32" - short_name: "ᕕ(ᐛ)ᕗ" - } - builders: { - name: "buildbot/chromium.win/Win Builder (dbg)" - category: "win|debug|builder|32" - short_name: "(ಥ_ಥ)" - } - - builders: { name: "buildbucket/luci.chromium.ci/Win7 (32) Tests" category: "win|release|tester|7|(32)" short_name: "ᕕ(ᐛ)ᕗ" @@ -1597,17 +1592,6 @@ short_name: "(ಥ_ಥ)" } - builders: { - name: "buildbucket/luci.chromium.ci/Win7 Tests (dbg)(1)" - category: "win|debug|tester|7" - short_name: "ᕕ(ᐛ)ᕗ" - } - builders: { - name: "buildbot/chromium.win/Win7 Tests (dbg)(1)" - category: "win|debug|tester|7" - short_name: "(ಥ_ಥ)" - } - # GPU FYI Window bots, prefixed with GPU FYI|Windows builders: { name: "buildbucket/luci.chromium.ci/GPU FYI Win Builder"
diff --git a/infra/config/global/luci-scheduler.cfg b/infra/config/global/luci-scheduler.cfg index b715e0a..992c02c 100644 --- a/infra/config/global/luci-scheduler.cfg +++ b/infra/config/global/luci-scheduler.cfg
@@ -64,6 +64,8 @@ triggers: "Android FYI Release (NVIDIA Shield TV)" triggers: "Android x64 Builder (dbg)" triggers: "Android x86 Builder (dbg)" + triggers: "Deterministic Android" + triggers: "Deterministic Android (dbg)" triggers: "Optional Android Release (Nexus 5X)" # ChromeOS. Sorted alphabetically. @@ -72,6 +74,7 @@ # Linux. Sorted alphabetically. triggers: "Cast Linux" triggers: "Deterministic Linux" + triggers: "Deterministic Linux (dbg)" triggers: "Fuchsia ARM64" triggers: "Fuchsia ARM64 Cast Audio" triggers: "Fuchsia x64" @@ -85,6 +88,7 @@ triggers: "linux-blink-heap-verification" triggers: "Linux ASan LSan Builder" triggers: "Linux Builder" + triggers: "Linux Builder Jumbo" triggers: "Linux Builder (dbg)" triggers: "Linux Builder (dbg)(32)" triggers: "Linux FYI GPU TSAN Release" @@ -96,7 +100,6 @@ triggers: "Mac Builder" triggers: "Mac Builder (dbg)" triggers: "Mac FYI GPU ASAN Release" - triggers: "WebKit Mac Builder (dbg)" # Windows. Sorted alphabetically. triggers: "GPU FYI Win Builder" @@ -108,6 +111,7 @@ triggers: "GPU FYI Win x64 dEQP Builder" triggers: "Win Builder" triggers: "Win Builder (dbg)" + triggers: "Win x64 Builder (dbg)" } @@ -250,6 +254,26 @@ } job { + id: "Deterministic Android" + acl_sets: "default" + buildbucket: { + server: "cr-buildbucket.appspot.com" + bucket: "luci.chromium.ci" + builder: "Deterministic Android" + } +} + +job { + id: "Deterministic Android (dbg)" + acl_sets: "default" + buildbucket: { + server: "cr-buildbucket.appspot.com" + bucket: "luci.chromium.ci" + builder: "Deterministic Android (dbg)" + } +} + +job { id: "Marshmallow 64 bit Tester" # triggered by "Android arm64 Builder (dbg)" acl_sets: "triggered-by-parent-builders" @@ -359,6 +383,16 @@ } job { + id: "Deterministic Linux (dbg)" + acl_sets: "default" + buildbucket: { + server: "cr-buildbucket.appspot.com" + bucket: "luci.chromium.ci" + builder: "Deterministic Linux (dbg)" + } +} + +job { id: "Fuchsia ARM64" acl_sets: "default" buildbucket: { @@ -604,6 +638,17 @@ } job { + id: "Linux Builder Jumbo" + acl_sets: "default" + buildbucket: { + server: "cr-buildbucket.appspot.com" + bucket: "luci.chromium.ci" + builder: "Linux Builder Jumbo" + } +} + + +job { id: "Linux Tests (dbg)(1)" # Triggered by "Linux Builder (dbg)". acl_sets: "triggered-by-parent-builders" @@ -1193,6 +1238,16 @@ } job { + id: "Win x64 Builder (dbg)" + acl_sets: "default" + buildbucket: { + server: "cr-buildbucket.appspot.com" + bucket: "luci.chromium.ci" + builder: "Win x64 Builder (dbg)" + } +} + +job { id: "Win Builder" acl_sets: "default" buildbucket: { @@ -1239,7 +1294,7 @@ job { id: "Win10 Tests x64 (dbg)" - # Triggered by "Win Builder (dbg)" + # Triggered by "Win x64 Builder (dbg)" acl_sets: "triggered-by-parent-builders" buildbucket: { server: "cr-buildbucket.appspot.com"
diff --git a/ios/chrome/app/main_controller.mm b/ios/chrome/app/main_controller.mm index 05d61caa..2e89c94c 100644 --- a/ios/chrome/app/main_controller.mm +++ b/ios/chrome/app/main_controller.mm
@@ -114,7 +114,6 @@ #import "ios/chrome/browser/ui/commands/open_new_tab_command.h" #import "ios/chrome/browser/ui/commands/open_url_command.h" #import "ios/chrome/browser/ui/commands/show_signin_command.h" -#import "ios/chrome/browser/ui/commands/start_voice_search_command.h" #import "ios/chrome/browser/ui/download/legacy_download_manager_controller.h" #import "ios/chrome/browser/ui/external_file_remover_factory.h" #import "ios/chrome/browser/ui/external_file_remover_impl.h" @@ -420,7 +419,7 @@ // Shows the tab switcher UI. - (void)showTabSwitcher; // Starts a voice search on the current BVC. -- (void)startVoiceSearchInCurrentBVCWithOriginView:(UIView*)originView; +- (void)startVoiceSearchInCurrentBVC; // Dismisses the tab switcher UI without animation into the given model. - (void)dismissTabSwitcherWithoutAnimationInModel:(TabModel*)tabModel; // Dismisses |signinInteractionCoordinator|. @@ -1414,9 +1413,9 @@ [self.currentBVC.dispatcher openNewTab:command]; } -- (void)startVoiceSearch:(StartVoiceSearchCommand*)command { +- (void)startVoiceSearch { if (!_isProcessingTabSwitcherCommand) { - [self startVoiceSearchInCurrentBVCWithOriginView:command.originView]; + [self startVoiceSearchInCurrentBVC]; _isProcessingVoiceSearchCommand = YES; dispatch_after(dispatch_time(DISPATCH_TIME_NOW, kExpectedTransitionDurationInNanoSeconds), @@ -1426,6 +1425,10 @@ } } +- (void)startVoiceSearch:(StartVoiceSearchCommand*)command { + [self startVoiceSearch]; +} + - (void)showHistory { if (experimental_flags::IsCollectionsUIRebootEnabled()) { // New History UIReboot coordinator. @@ -1674,15 +1677,15 @@ [self closeSettingsAnimated:YES completion:completion]; } -- (void)startVoiceSearchInCurrentBVCWithOriginView:(UIView*)originView { +- (void)startVoiceSearchInCurrentBVC { // If the background (non-current) BVC is playing TTS audio, call // -startVoiceSearch on it to stop the TTS. BrowserViewController* backgroundBVC = self.mainBVC == self.currentBVC ? self.otrBVC : self.mainBVC; if (backgroundBVC.playingTTS) - [backgroundBVC startVoiceSearchWithOriginView:originView]; + [backgroundBVC startVoiceSearch]; else - [self.currentBVC startVoiceSearchWithOriginView:originView]; + [self.currentBVC startVoiceSearch]; } #pragma mark - Preferences Management @@ -2185,7 +2188,7 @@ case START_VOICE_SEARCH: if (@available(iOS 11, *)) { return ^{ - [self startVoiceSearchInCurrentBVCWithOriginView:nil]; + [self startVoiceSearchInCurrentBVC]; }; } else { return ^{ @@ -2201,8 +2204,7 @@ // TODO(crbug.com/766951): remove this workaround. dispatch_after(dispatch_time(DISPATCH_TIME_NOW, 100 * NSEC_PER_MSEC), dispatch_get_main_queue(), ^{ - [self - startVoiceSearchInCurrentBVCWithOriginView:nil]; + [self startVoiceSearchInCurrentBVC]; }); };
diff --git a/ios/chrome/browser/ui/browser_view_controller.h b/ios/chrome/browser/ui/browser_view_controller.h index b12202a..e38aff5f 100644 --- a/ios/chrome/browser/ui/browser_view_controller.h +++ b/ios/chrome/browser/ui/browser_view_controller.h
@@ -137,9 +137,8 @@ // related to showing the previously selected tab. - (void)expectNewForegroundTab; -// Shows the voice search UI. |originView|'s center is used for the presentation -// and dismissal animations of the Voice Search UI. |originView| can be nil. -- (void)startVoiceSearchWithOriginView:(UIView*)originView; +// Shows the voice search UI. +- (void)startVoiceSearch; // Dismisses all presented views, excluding the omnibox if |dismissOmnibox| is // NO, then calls |completion|.
diff --git a/ios/chrome/browser/ui/browser_view_controller.mm b/ios/chrome/browser/ui/browser_view_controller.mm index 224256ef..86873cc0 100644 --- a/ios/chrome/browser/ui/browser_view_controller.mm +++ b/ios/chrome/browser/ui/browser_view_controller.mm
@@ -136,7 +136,6 @@ #import "ios/chrome/browser/ui/commands/reading_list_add_command.h" #import "ios/chrome/browser/ui/commands/show_signin_command.h" #import "ios/chrome/browser/ui/commands/snackbar_commands.h" -#import "ios/chrome/browser/ui/commands/start_voice_search_command.h" #import "ios/chrome/browser/ui/commands/toolbar_commands.h" #import "ios/chrome/browser/ui/content_suggestions/ntp_home_constant.h" #import "ios/chrome/browser/ui/context_menu/context_menu_coordinator.h" @@ -558,9 +557,6 @@ // Notifies the toolbar menu of reading list changes. ReadingListMenuNotifier* _readingListMenuNotifier; - // The view used by the voice search presentation animation. - __weak UIView* _voiceSearchButton; - // Coordinator for the share menu (Activity Services). ActivityServiceLegacyCoordinator* _activityServiceCoordinator; @@ -1453,8 +1449,7 @@ _expectingForegroundTab = YES; } -- (void)startVoiceSearchWithOriginView:(UIView*)originView { - _voiceSearchButton = originView; +- (void)startVoiceSearch { // Delay Voice Search until new tab animations have finished. if (self.inNewTabAnimation) { _startVoiceSearchAfterNewTabAnimation = YES; @@ -4974,7 +4969,7 @@ ProceduralBlock startVoiceSearchIfNecessaryBlock = ^void() { if (_startVoiceSearchAfterNewTabAnimation) { _startVoiceSearchAfterNewTabAnimation = NO; - [self startVoiceSearchWithOriginView:nil]; + [self startVoiceSearch]; } }; @@ -5426,10 +5421,6 @@ #pragma mark - VoiceSearchPresenter (Public) -- (UIView*)voiceSearchButton { - return _voiceSearchButton; -} - - (id<LogoAnimationControllerOwner>)logoAnimationControllerOwner { return [self currentLogoAnimationControllerOwner]; }
diff --git a/ios/chrome/browser/ui/commands/application_commands.h b/ios/chrome/browser/ui/commands/application_commands.h index 539f495..4ddef747 100644 --- a/ios/chrome/browser/ui/commands/application_commands.h +++ b/ios/chrome/browser/ui/commands/application_commands.h
@@ -64,6 +64,9 @@ - (void)switchModesAndOpenNewTab:(OpenNewTabCommand*)newTabCommand; // Starts a voice search on the current BVC. +- (void)startVoiceSearch; +// Deprecated |-startVoiceSearchCommand|. +// TODO(crbug.com/805123): Remove this command. - (void)startVoiceSearch:(StartVoiceSearchCommand*)command; // Shows the History UI.
diff --git a/ios/chrome/browser/ui/content_suggestions/BUILD.gn b/ios/chrome/browser/ui/content_suggestions/BUILD.gn index 286d9c4b..1b95dfe8 100644 --- a/ios/chrome/browser/ui/content_suggestions/BUILD.gn +++ b/ios/chrome/browser/ui/content_suggestions/BUILD.gn
@@ -248,6 +248,7 @@ "//ios/chrome/browser/ui/content_suggestions/cells:cells_ui", "//ios/chrome/browser/ui/location_bar:location_bar", "//ios/chrome/browser/ui/ntp:ntp_controller", + "//ios/chrome/browser/ui/toolbar/buttons:buttons", "//ios/chrome/test/app:test_support", "//ios/chrome/test/base:base", "//ios/chrome/test/earl_grey:test_support",
diff --git a/ios/chrome/browser/ui/content_suggestions/content_suggestions_header_view_controller.mm b/ios/chrome/browser/ui/content_suggestions/content_suggestions_header_view_controller.mm index 2e8f737..ed10fa8f 100644 --- a/ios/chrome/browser/ui/content_suggestions/content_suggestions_header_view_controller.mm +++ b/ios/chrome/browser/ui/content_suggestions/content_suggestions_header_view_controller.mm
@@ -11,7 +11,6 @@ #import "ios/chrome/browser/ui/UIView+SizeClassSupport.h" #import "ios/chrome/browser/ui/commands/application_commands.h" #import "ios/chrome/browser/ui/commands/browser_commands.h" -#include "ios/chrome/browser/ui/commands/start_voice_search_command.h" #import "ios/chrome/browser/ui/content_suggestions/content_suggestions_collection_synchronizing.h" #import "ios/chrome/browser/ui/content_suggestions/content_suggestions_collection_utils.h" #import "ios/chrome/browser/ui/content_suggestions/content_suggestions_commands.h" @@ -366,9 +365,7 @@ UIView* voiceSearchButton = base::mac::ObjCCastStrict<UIView>(sender); [NamedGuide guideWithName:kVoiceSearchButtonGuide view:voiceSearchButton] .constrainedView = voiceSearchButton; - StartVoiceSearchCommand* command = - [[StartVoiceSearchCommand alloc] initWithOriginView:voiceSearchButton]; - [self.dispatcher startVoiceSearch:command]; + [self.dispatcher startVoiceSearch]; } - (void)preloadVoiceSearch:(id)sender {
diff --git a/ios/chrome/browser/ui/content_suggestions/ntp_home_egtest.mm b/ios/chrome/browser/ui/content_suggestions/ntp_home_egtest.mm index bd6bdf5..5e6b8bb 100644 --- a/ios/chrome/browser/ui/content_suggestions/ntp_home_egtest.mm +++ b/ios/chrome/browser/ui/content_suggestions/ntp_home_egtest.mm
@@ -24,8 +24,10 @@ #import "ios/chrome/browser/ui/content_suggestions/ntp_home_constant.h" #import "ios/chrome/browser/ui/content_suggestions/ntp_home_provider_test_singleton.h" #import "ios/chrome/browser/ui/content_suggestions/ntp_home_test_utils.h" +#import "ios/chrome/browser/ui/location_bar/location_bar_coordinator.h" #import "ios/chrome/browser/ui/location_bar/location_bar_legacy_coordinator.h" #import "ios/chrome/browser/ui/ntp/new_tab_page_controller.h" +#import "ios/chrome/browser/ui/toolbar/buttons/toolbar_constants.h" #include "ios/chrome/browser/ui/ui_util.h" #import "ios/chrome/browser/ui/uikit_ui_util.h" #include "ios/chrome/grit/ios_strings.h" @@ -406,9 +408,10 @@ // It is important for ranking algorithm of omnibox that requests from fakebox // and real omnibox are marked appropriately. - (void)testTapFakeOmniboxLogsCorrectly { - if (!IsIPadIdiom()) { - // This logging only happens on iPad, since on iPhone there is no real - // omnibox on NTP, only fakebox. + if (!IsIPadIdiom() || IsUIRefreshPhase1Enabled()) { + // This logging only happens on iPad pre-UIRefresh, since on iPhone there is + // no real omnibox on NTP, only fakebox, and post-UIRefresh the NTP never + // shows multiple omniboxes. return; } @@ -428,6 +431,33 @@ GREYAssertTrue(tapped, @"The tap on the fakebox was not correctly logged."); } +// Tests that tapping the omnibox search button logs correctly. +// It is important for ranking algorithm of omnibox that requests from the +// search button and real omnibox are marked appropriately. +- (void)testTapOmniboxSearchButtonLogsCorrectly { + if (IsIPadIdiom() || !IsUIRefreshPhase1Enabled()) { + // This logging only happens on iPhone, since on iPad there's no secondary + // toolbar. + return; + } + + // Swizzle the method that needs to be called for correct logging. + __block BOOL tapped = NO; + ScopedBlockSwizzler swizzler([LocationBarCoordinator class], + @selector(focusOmniboxFromSearchButton), ^() { + tapped = YES; + }); + + // Tap the search button. + [[EarlGrey selectElementWithMatcher:grey_accessibilityID( + kToolbarOmniboxButtonIdentifier)] + performAction:grey_tap()]; + + // Check that the page is loaded. + GREYAssertTrue(tapped, + @"The tap on the search button was not correctly logged."); +} + // Tests that tapping the fake omnibox moves the collection. - (void)testTapFakeOmniboxScroll { // Get the collection and its layout.
diff --git a/ios/chrome/browser/ui/download/download_manager_view_controller.mm b/ios/chrome/browser/ui/download/download_manager_view_controller.mm index 45843ef..cccedfd 100644 --- a/ios/chrome/browser/ui/download/download_manager_view_controller.mm +++ b/ios/chrome/browser/ui/download/download_manager_view_controller.mm
@@ -96,6 +96,10 @@ @property(nonatomic) NSLayoutConstraint* installDriveControlsRowTrailingConstraint; +// Represents constraint for self.view.statusLabel, which is either anchored to +// self.closeButton or to self.actionButton (when visible). +@property(nonatomic) NSLayoutConstraint* statusLabelTrailingConstraint; + @end @implementation DownloadManagerViewController @@ -115,6 +119,7 @@ _installDriveControlsRowLeadingConstraint; @synthesize installDriveControlsRowTrailingConstraint = _installDriveControlsRowTrailingConstraint; +@synthesize statusLabelTrailingConstraint = _statusLabelTrailingConstraint; #pragma mark - UIViewController overrides @@ -227,10 +232,8 @@ constraintEqualToAnchor:downloadRow.centerYAnchor], [statusLabel.leadingAnchor constraintEqualToAnchor:stateIcon.trailingAnchor constant:kElementMargin], - [statusLabel.trailingAnchor - constraintLessThanOrEqualToAnchor:actionButton.leadingAnchor - constant:-kElementMargin], ]]; + [self updateStatusLabelTrailingConstraint]; // action button constraints. [NSLayoutConstraint activateConstraints:@[ @@ -336,6 +339,7 @@ [self updateStatusLabel]; [self updateActionButton]; [self updateProgressView]; + [self updateStatusLabelTrailingConstraint]; } } @@ -613,6 +617,28 @@ self.installDriveControlsRowTrailingConstraint.constant = -constant; } +// Anchors self.view.statusLabel to self.closeButton or to self.actionButton +// (when download is not in progress and action button is visible). +- (void)updateStatusLabelTrailingConstraint { + if (!self.viewLoaded || !self.view.superview) { + // Constraints can not be set if UI elements do not have a common view. + // This method will be called again when self.view is added to superview. + return; + } + + self.statusLabelTrailingConstraint.active = NO; + + UIView* secondAnchorElement = _state == kDownloadManagerStateInProgress + ? self.closeButton + : self.actionButton; + + self.statusLabelTrailingConstraint = [self.statusLabel.trailingAnchor + constraintEqualToAnchor:secondAnchorElement.leadingAnchor + constant:-kElementMargin]; + + self.statusLabelTrailingConstraint.active = YES; +} + // Updates state icon depending. - (void)updateStateIcon { [self.stateIcon setState:_state animated:YES]; @@ -654,7 +680,6 @@ } self.statusLabel.text = statusText; - [self.statusLabel sizeToFit]; } // Updates title and hidden state for action button depending on |state|.
diff --git a/ios/chrome/browser/ui/key_commands_provider.mm b/ios/chrome/browser/ui/key_commands_provider.mm index 938413be..97d09d2 100644 --- a/ios/chrome/browser/ui/key_commands_provider.mm +++ b/ios/chrome/browser/ui/key_commands_provider.mm
@@ -7,7 +7,6 @@ #include "base/logging.h" #include "components/strings/grit/components_strings.h" #import "ios/chrome/browser/ui/commands/open_new_tab_command.h" -#include "ios/chrome/browser/ui/commands/start_voice_search_command.h" #import "ios/chrome/browser/ui/keyboard/UIKeyCommand+Chrome.h" #include "ios/chrome/browser/ui/rtl_geometry.h" #import "ios/chrome/browser/ui/util/named_guide.h" @@ -203,10 +202,7 @@ [[NamedGuide guideWithName:kVoiceSearchButtonGuide view:baseView] resetConstraints]; - StartVoiceSearchCommand* command = - [[StartVoiceSearchCommand alloc] - initWithOriginView:nil]; - [weakDispatcher startVoiceSearch:command]; + [weakDispatcher startVoiceSearch]; }], ]]; }
diff --git a/ios/chrome/browser/ui/location_bar/location_bar_coordinator.h b/ios/chrome/browser/ui/location_bar/location_bar_coordinator.h index a30dd52..30a0eee 100644 --- a/ios/chrome/browser/ui/location_bar/location_bar_coordinator.h +++ b/ios/chrome/browser/ui/location_bar/location_bar_coordinator.h
@@ -56,9 +56,6 @@ // Indicates if the omnibox currently displays a popup with suggestions. - (BOOL)showingOmniboxPopup; -// Focuses omnibox with fakebox as the focus event source. -- (void)focusOmniboxFromFakebox; - // Indicates when the omnibox is the first responder. - (BOOL)isOmniboxFirstResponder;
diff --git a/ios/chrome/browser/ui/location_bar/location_bar_coordinator.mm b/ios/chrome/browser/ui/location_bar/location_bar_coordinator.mm index f65368d3..35b4ecc5 100644 --- a/ios/chrome/browser/ui/location_bar/location_bar_coordinator.mm +++ b/ios/chrome/browser/ui/location_bar/location_bar_coordinator.mm
@@ -160,10 +160,6 @@ return self.omniboxPopupCoordinator.isOpen; } -- (void)focusOmniboxFromFakebox { - [self focusOmnibox]; -} - - (BOOL)isOmniboxFirstResponder { return [self.locationBarView.textField isFirstResponder]; } @@ -250,6 +246,11 @@ // methods are already necessary though. #pragma mark - OmniboxFocuser +- (void)focusOmniboxFromSearchButton { + [self.omniboxCoordinator setNextFocusSourceAsSearchButton]; + [self focusOmnibox]; +} + - (void)focusOmnibox { [self.locationBarView.textField becomeFirstResponder]; }
diff --git a/ios/chrome/browser/ui/location_bar/location_bar_legacy_coordinator.mm b/ios/chrome/browser/ui/location_bar/location_bar_legacy_coordinator.mm index 2603dcd..a67b559 100644 --- a/ios/chrome/browser/ui/location_bar/location_bar_legacy_coordinator.mm +++ b/ios/chrome/browser/ui/location_bar/location_bar_legacy_coordinator.mm
@@ -250,6 +250,10 @@ // methods are already necessary though. #pragma mark - OmniboxFocuser +- (void)focusOmniboxFromSearchButton { + NOTREACHED(); +} + - (void)focusOmnibox { [self.locationBarView.textField becomeFirstResponder]; }
diff --git a/ios/chrome/browser/ui/omnibox/omnibox_coordinator.h b/ios/chrome/browser/ui/omnibox/omnibox_coordinator.h index eef7c269..192fdee 100644 --- a/ios/chrome/browser/ui/omnibox/omnibox_coordinator.h +++ b/ios/chrome/browser/ui/omnibox/omnibox_coordinator.h
@@ -37,7 +37,7 @@ // Update the contents and the styling of the omnibox. - (void)updateOmniboxState; // Marks the next omnibox focus event source as the fakebox. -- (void)setNextFocusSourceAsFakebox; +- (void)setNextFocusSourceAsSearchButton; // Use this method to resign |textField| as the first responder. - (void)endEditing; // Creates a child popup coordinator. The popup coordinator is linked to the
diff --git a/ios/chrome/browser/ui/omnibox/omnibox_coordinator.mm b/ios/chrome/browser/ui/omnibox/omnibox_coordinator.mm index 9ce35830..4603d8b7 100644 --- a/ios/chrome/browser/ui/omnibox/omnibox_coordinator.mm +++ b/ios/chrome/browser/ui/omnibox/omnibox_coordinator.mm
@@ -45,9 +45,9 @@ _editView->UpdateAppearance(); } -- (void)setNextFocusSourceAsFakebox { +- (void)setNextFocusSourceAsSearchButton { OmniboxEditModel* model = _editView->model(); - model->set_focus_source(OmniboxEditModel::FocusSource::FAKEBOX); + model->set_focus_source(OmniboxEditModel::FocusSource::SEARCH_BUTTON); } - (void)endEditing {
diff --git a/ios/chrome/browser/ui/omnibox/omnibox_view_ios.mm b/ios/chrome/browser/ui/omnibox/omnibox_view_ios.mm index 202890d..a149fe81 100644 --- a/ios/chrome/browser/ui/omnibox/omnibox_view_ios.mm +++ b/ios/chrome/browser/ui/omnibox/omnibox_view_ios.mm
@@ -407,8 +407,10 @@ [field_ setText:[field_ text]]; OnBeforePossibleChange(); // In the case where the user taps the fakebox on the Google landing page, - // the focus source is already set to FAKEBOX. Otherwise, set it to OMNIBOX. - if (model()->focus_source() != OmniboxEditModel::FocusSource::FAKEBOX) { + // or from the secondary toolbar search button, the focus source is already + // set to FAKEBOX or SEARCH_BUTTON respectively. Otherwise, set it to OMNIBOX. + if (model()->focus_source() != OmniboxEditModel::FocusSource::FAKEBOX && + model()->focus_source() != OmniboxEditModel::FocusSource::SEARCH_BUTTON) { model()->set_focus_source(OmniboxEditModel::FocusSource::OMNIBOX); }
diff --git a/ios/chrome/browser/ui/toolbar/adaptive/primary_toolbar_coordinator.mm b/ios/chrome/browser/ui/toolbar/adaptive/primary_toolbar_coordinator.mm index 10187cc9..9b643a4 100644 --- a/ios/chrome/browser/ui/toolbar/adaptive/primary_toolbar_coordinator.mm +++ b/ios/chrome/browser/ui/toolbar/adaptive/primary_toolbar_coordinator.mm
@@ -136,13 +136,7 @@ #pragma mark - FakeboxFocuser - (void)focusFakebox { - if (IsIPadIdiom()) { - // On iPhone there is no visible omnibox, so there's no need to indicate - // interaction was initiated from the fakebox. - [self.locationBarCoordinator focusOmniboxFromFakebox]; - } else { - [self.locationBarCoordinator focusOmnibox]; - } + [self.locationBarCoordinator focusOmnibox]; } - (void)onFakeboxBlur {
diff --git a/ios/chrome/browser/ui/toolbar/buttons/toolbar_button_factory.mm b/ios/chrome/browser/ui/toolbar/buttons/toolbar_button_factory.mm index b9eecee..ff0b385 100644 --- a/ios/chrome/browser/ui/toolbar/buttons/toolbar_button_factory.mm +++ b/ios/chrome/browser/ui/toolbar/buttons/toolbar_button_factory.mm
@@ -427,7 +427,7 @@ [self configureButton:omniboxButton width:kAdaptiveToolbarButtonWidth]; [omniboxButton addTarget:self.dispatcher - action:@selector(focusOmnibox) + action:@selector(focusOmniboxFromSearchButton) forControlEvents:UIControlEventTouchUpInside]; omniboxButton.accessibilityIdentifier = kToolbarOmniboxButtonIdentifier;
diff --git a/ios/chrome/browser/ui/toolbar/clean/toolbar_view_controller.mm b/ios/chrome/browser/ui/toolbar/clean/toolbar_view_controller.mm index 24d1f44..5acb7ddaf 100644 --- a/ios/chrome/browser/ui/toolbar/clean/toolbar_view_controller.mm +++ b/ios/chrome/browser/ui/toolbar/clean/toolbar_view_controller.mm
@@ -10,7 +10,6 @@ #import "ios/chrome/browser/ui/commands/application_commands.h" #import "ios/chrome/browser/ui/commands/browser_commands.h" #import "ios/chrome/browser/ui/commands/history_popup_commands.h" -#import "ios/chrome/browser/ui/commands/start_voice_search_command.h" #import "ios/chrome/browser/ui/fullscreen/fullscreen_animator.h" #import "ios/chrome/browser/ui/fullscreen/fullscreen_foreground_animator.h" #import "ios/chrome/browser/ui/fullscreen/fullscreen_scroll_end_animator.h" @@ -658,9 +657,7 @@ UIView* view = base::mac::ObjCCastStrict<UIView>(sender); [NamedGuide guideWithName:kVoiceSearchButtonGuide view:view].constrainedView = view; - StartVoiceSearchCommand* command = - [[StartVoiceSearchCommand alloc] initWithOriginView:view]; - [self.dispatcher startVoiceSearch:command]; + [self.dispatcher startVoiceSearch]; } // Sets all Toolbar Buttons opacity to |alpha|.
diff --git a/ios/chrome/browser/ui/toolbar/keyboard_assist/toolbar_assistive_keyboard_delegate.mm b/ios/chrome/browser/ui/toolbar/keyboard_assist/toolbar_assistive_keyboard_delegate.mm index 828d30c..afb6ac8e 100644 --- a/ios/chrome/browser/ui/toolbar/keyboard_assist/toolbar_assistive_keyboard_delegate.mm +++ b/ios/chrome/browser/ui/toolbar/keyboard_assist/toolbar_assistive_keyboard_delegate.mm
@@ -9,7 +9,6 @@ #import "ios/chrome/browser/ui/commands/application_commands.h" #import "ios/chrome/browser/ui/commands/browser_commands.h" #import "ios/chrome/browser/ui/commands/external_search_commands.h" -#import "ios/chrome/browser/ui/commands/start_voice_search_command.h" #import "ios/chrome/browser/ui/location_bar/location_bar_constants.h" #import "ios/chrome/browser/ui/omnibox/omnibox_text_field_ios.h" #import "ios/chrome/browser/ui/util/named_guide.h" @@ -56,9 +55,7 @@ CGRectGetHeight(frame); self.voiceSearchButtonGuide.constrainedFrame = frame; } - StartVoiceSearchCommand* command = - [[StartVoiceSearchCommand alloc] initWithOriginView:view]; - [self.dispatcher startVoiceSearch:command]; + [self.dispatcher startVoiceSearch]; } }
diff --git a/ios/chrome/browser/ui/toolbar/public/omnibox_focuser.h b/ios/chrome/browser/ui/toolbar/public/omnibox_focuser.h index 8fab70ad..b372bb4 100644 --- a/ios/chrome/browser/ui/toolbar/public/omnibox_focuser.h +++ b/ios/chrome/browser/ui/toolbar/public/omnibox_focuser.h
@@ -11,6 +11,8 @@ @protocol OmniboxFocuser // Give focus to the omnibox, if it is visible. No-op if it is not visible. - (void)focusOmnibox; +// Set next focus source as SEARCH_BUTTON and then call -focusOmnibox. +- (void)focusOmniboxFromSearchButton; // Cancel omnibox edit (from shield tap or cancel button tap). - (void)cancelOmniboxEdit; @end
diff --git a/ios/public/provider/chrome/browser/voice/voice_search_presenter.h b/ios/public/provider/chrome/browser/voice/voice_search_presenter.h index 7b76a62..3924051 100644 --- a/ios/public/provider/chrome/browser/voice/voice_search_presenter.h +++ b/ios/public/provider/chrome/browser/voice/voice_search_presenter.h
@@ -10,11 +10,7 @@ #import "ios/public/provider/chrome/browser/voice/logo_animation_controller.h" // Protocol used by UIViewControllers that present VoiceSearch. -@protocol VoiceSearchPresenter<LogoAnimationControllerOwnerOwner, NSObject> - -// The button that was tapped in order to trigger VoiceSearch. -@property(nonatomic, readonly) UIView* voiceSearchButton; - +@protocol VoiceSearchPresenter<LogoAnimationControllerOwnerOwner> @end #endif // IOS_PUBLIC_PROVIDER_CHROME_BROWSER_VOICE_VOICE_SEARCH_PRESENTER_H_
diff --git a/media/audio/audio_manager_base.cc b/media/audio/audio_manager_base.cc index 04445f2..d9dbf26 100644 --- a/media/audio/audio_manager_base.cc +++ b/media/audio/audio_manager_base.cc
@@ -539,7 +539,7 @@ if (output_device_id.empty()) { // Some characters are added to avoid accidentally // giving the input the same group id as an output. - return input_device_id + "input"; + return real_input_device_id + "input"; } return GetGroupIDOutput(output_device_id); }
diff --git a/net/cert/root_cert_list_generated.h b/net/cert/root_cert_list_generated.h index 26c4b55..d041ed7 100644 --- a/net/cert/root_cert_list_generated.h +++ b/net/cert/root_cert_list_generated.h
@@ -2530,6 +2530,12 @@ }, 41}, {{ + 0xCB, 0xAD, 0x7B, 0x1D, 0x38, 0x48, 0x49, 0xDF, 0x09, 0x46, 0xB7, + 0xEE, 0x8E, 0x7F, 0x5F, 0x7C, 0xE3, 0xAE, 0xD8, 0x76, 0xFD, 0xA7, + 0xBC, 0x9D, 0x30, 0xD8, 0xB1, 0x6F, 0x29, 0xFF, 0x2C, 0x53, + }, + 492}, + {{ 0xCB, 0xE5, 0xAC, 0x15, 0xD8, 0x8B, 0x5C, 0xAC, 0x3F, 0x81, 0xE6, 0xDF, 0x3B, 0xFB, 0x57, 0xBE, 0xA6, 0x09, 0x58, 0x81, 0x3A, 0x47, 0xB7, 0x7F, 0x3C, 0x5C, 0xB6, 0xB9, 0x81, 0x91, 0xBD, 0xB5, @@ -2608,6 +2614,12 @@ }, 472}, {{ + 0xD4, 0x9C, 0x6F, 0x28, 0x9C, 0xD0, 0x56, 0x51, 0x94, 0x92, 0x48, + 0x0F, 0x19, 0x2F, 0x00, 0xA6, 0xFC, 0x7C, 0x18, 0x62, 0xDA, 0xB2, + 0xE7, 0xB5, 0xD8, 0xE0, 0x5F, 0x66, 0x78, 0xFA, 0xE1, 0x41, + }, + 491}, + {{ 0xD4, 0xAF, 0x6C, 0x0A, 0x48, 0x23, 0x10, 0xBD, 0x7C, 0x54, 0xBB, 0x7A, 0xB1, 0x21, 0x91, 0x6F, 0x86, 0xC0, 0xC0, 0x7C, 0xD5, 0x2F, 0xCA, 0xC3, 0x2D, 0x38, 0x44, 0xC2, 0x60, 0x05, 0x11, 0x5F,
diff --git a/net/cookies/cookie_monster.cc b/net/cookies/cookie_monster.cc index eda1bb23..ee28f640 100644 --- a/net/cookies/cookie_monster.cc +++ b/net/cookies/cookie_monster.cc
@@ -126,46 +126,20 @@ std::move(callback).Run(result); } -// See |InstrumentGetCookieListClosure()| below. -class GetCookieListRequestTracker { - public: - GetCookieListRequestTracker() : weak_ptr_factory_(this) { - // If this callback isn't destroyed within 60 seconds, we'll issue a crash - // dump. - base::ThreadTaskRunnerHandle::Get()->PostDelayedTask( - FROM_HERE, - base::BindOnce(&GetCookieListRequestTracker::CrashToReportTimeout, - weak_ptr_factory_.GetWeakPtr()), - base::TimeDelta::FromSeconds(60)); - } - - ~GetCookieListRequestTracker() { - UMA_HISTOGRAM_CUSTOM_TIMES("Cookie.GetCookieListCompletionTime", - request_timer_.Elapsed(), - base::TimeDelta::FromMilliseconds(10), - base::TimeDelta::FromSeconds(60), 50); - } - - private: - void CrashToReportTimeout() { base::debug::DumpWithoutCrashing(); } - - base::ElapsedTimer request_timer_; - base::WeakPtrFactory<GetCookieListRequestTracker> weak_ptr_factory_; - - DISALLOW_COPY_AND_ASSIGN(GetCookieListRequestTracker); -}; - // Wraps a OnceClosure -- specifically one used by // |GetCookieListWithOptionsAsync()| -- with additional bound state to track the -// duration between when its creation and destruction time. If the callback -// still exists after 60 seconds, we'll also log a crash dump. -// +// duration between when its creation and destruction time. // See https://crbug.com/824024 for context. base::OnceClosure InstrumentGetCookieListClosure(base::OnceClosure closure) { return base::BindOnce( - [](std::unique_ptr<GetCookieListRequestTracker> tracker, - base::OnceClosure closure) { std::move(closure).Run(); }, - std::make_unique<GetCookieListRequestTracker>(), std::move(closure)); + [](std::unique_ptr<base::ElapsedTimer> timer, base::OnceClosure closure) { + UMA_HISTOGRAM_CUSTOM_TIMES("Cookie.GetCookieListCompletionTime", + timer->Elapsed(), + base::TimeDelta::FromMilliseconds(10), + base::TimeDelta::FromSeconds(60), 50); + std::move(closure).Run(); + }, + std::make_unique<base::ElapsedTimer>(), std::move(closure)); } } // namespace
diff --git a/net/data/ssl/root_stores/root_stores.json b/net/data/ssl/root_stores/root_stores.json index c2d141e..96dc9e1 100644 --- a/net/data/ssl/root_stores/root_stores.json +++ b/net/data/ssl/root_stores/root_stores.json
@@ -30,7 +30,8 @@ "windows/170419224008", "windows/170613190204", "windows/170922155710", - "windows/171121202507" + "windows/171121202507", + "windows/180122185731" ], "007e452fd5cf838946696dfe37a2db2ef3991436d27bcbab45922053c15a87a8": [ "windows/080328202117", @@ -79,7 +80,8 @@ "windows/170419224008", "windows/170613190204", "windows/170922155710", - "windows/171121202507" + "windows/171121202507", + "windows/180122185731" ], "00ab444abd6bdba33da8de569ac4ecde326d1be1a61442d5eec3975a0c243f04": [ "windows/070201011524", @@ -133,7 +135,8 @@ "windows/170419224008", "windows/170613190204", "windows/170922155710", - "windows/171121202507" + "windows/171121202507", + "windows/180122185731" ], "02ed0eb28c14da45165c566791700d6451d7fb56f0b2ab1d3b8eb070e56edff5": [ "android/kitkat-cts-release", @@ -148,6 +151,7 @@ "android/nougat-cts-release", "android/nougat-mr1-cts-release", "android/oreo-cts-release", + "android/oreo-mr1-cts-release", "macos/10.10.0", "macos/10.10.3", "macos/10.10.4", @@ -159,6 +163,9 @@ "macos/10.12.1", "macos/10.12.2", "macos/10.13.0", + "macos/10.13.1", + "macos/10.13.2", + "macos/10.13.3", "macos/10.9.2", "macos/10.9.4", "macos/10.9.5", @@ -167,6 +174,7 @@ "mozilla/2.14", "mozilla/2.16", "mozilla/2.18", + "mozilla/2.20", "mozilla/2.9", "windows/130626232015", "windows/131003230417", @@ -189,7 +197,8 @@ "windows/170419224008", "windows/170613190204", "windows/170922155710", - "windows/171121202507" + "windows/171121202507", + "windows/180122185731" ], "03458b6abeecc214953d97149af45391691de9f9cdcc2647863a3d67c95c243b": [ "android/kitkat-cts-release", @@ -242,6 +251,7 @@ "android/nougat-cts-release", "android/nougat-mr1-cts-release", "android/oreo-cts-release", + "android/oreo-mr1-cts-release", "macos/10.10.0", "macos/10.10.3", "macos/10.10.4", @@ -253,6 +263,9 @@ "macos/10.12.1", "macos/10.12.2", "macos/10.13.0", + "macos/10.13.1", + "macos/10.13.2", + "macos/10.13.3", "macos/10.9.0", "macos/10.9.2", "macos/10.9.4", @@ -262,6 +275,7 @@ "mozilla/2.14", "mozilla/2.16", "mozilla/2.18", + "mozilla/2.20", "mozilla/2.9", "windows/100503224537", "windows/100719231554", @@ -300,7 +314,8 @@ "windows/170419224008", "windows/170613190204", "windows/170922155710", - "windows/171121202507" + "windows/171121202507", + "windows/180122185731" ], "0378b202ccabba99a12e569a11a077db1edb39482061c75d0073059d9ab5b513": [ "windows/071219233937", @@ -339,6 +354,7 @@ "android/nougat-cts-release", "android/nougat-mr1-cts-release", "android/oreo-cts-release", + "android/oreo-mr1-cts-release", "mozilla/2.10", "mozilla/2.11", "mozilla/2.14", @@ -385,7 +401,8 @@ "windows/170419224008", "windows/170613190204", "windows/170922155710", - "windows/171121202507" + "windows/171121202507", + "windows/180122185731" ], "04048028bf1f2864d48f9ad4d83294366a828856553f3b14303f90147f5d40ef": [ "android/kitkat-cts-release", @@ -400,6 +417,7 @@ "android/nougat-cts-release", "android/nougat-mr1-cts-release", "android/oreo-cts-release", + "android/oreo-mr1-cts-release", "macos/10.10.0", "macos/10.10.3", "macos/10.10.4", @@ -411,6 +429,9 @@ "macos/10.12.1", "macos/10.12.2", "macos/10.13.0", + "macos/10.13.1", + "macos/10.13.2", + "macos/10.13.3", "macos/10.9.0", "macos/10.9.2", "macos/10.9.4", @@ -420,6 +441,7 @@ "mozilla/2.14", "mozilla/2.16", "mozilla/2.18", + "mozilla/2.20", "mozilla/2.9", "windows/091029013045", "windows/100503224537", @@ -459,7 +481,8 @@ "windows/170419224008", "windows/170613190204", "windows/170922155710", - "windows/171121202507" + "windows/171121202507", + "windows/180122185731" ], "04acfb3b24793f300f67ef87e44dd72cb9b28b204f389a7cd5ae28785c7d42cd": [ "macos/10.10.0", @@ -473,6 +496,9 @@ "macos/10.12.1", "macos/10.12.2", "macos/10.13.0", + "macos/10.13.1", + "macos/10.13.2", + "macos/10.13.3", "macos/10.9.0", "macos/10.9.2", "macos/10.9.4", @@ -519,14 +545,16 @@ "windows/170419224008", "windows/170613190204", "windows/170922155710", - "windows/171121202507" + "windows/171121202507", + "windows/180122185731" ], "04f1bec36951bc1454a904ce32890c5da3cde1356b7900f6e62dfa2041ebad51": [ "windows/170228174808", "windows/170419224008", "windows/170613190204", "windows/170922155710", - "windows/171121202507" + "windows/171121202507", + "windows/180122185731" ], "0536801fbb443b3e905fd6d70d8c81eb88551be8061299110d2b4f82e64cade1": [ "windows/100719231554", @@ -565,7 +593,8 @@ "windows/170419224008", "windows/170613190204", "windows/170922155710", - "windows/171121202507" + "windows/171121202507", + "windows/180122185731" ], "058a40323ec8c46262c3052a5d357b91ac24d3da26351b3ff4407e99f7a4e9b4": [ "windows/070201011524", @@ -619,7 +648,8 @@ "windows/170419224008", "windows/170613190204", "windows/170922155710", - "windows/171121202507" + "windows/171121202507", + "windows/180122185731" ], "05d38c2a70bfc500ccb0cb509159b46b065c6ac9cb42d2e6f16167841434572a": [ "windows/120223022238", @@ -648,7 +678,8 @@ "windows/170419224008", "windows/170613190204", "windows/170922155710", - "windows/171121202507" + "windows/171121202507", + "windows/180122185731" ], "063e4afac491dfd332f3089b8542e94617d893d7fe944e10a7937ee29d9693c0": [ "android/kitkat-cts-release", @@ -663,6 +694,7 @@ "android/nougat-cts-release", "android/nougat-mr1-cts-release", "android/oreo-cts-release", + "android/oreo-mr1-cts-release", "macos/10.10.0", "macos/10.10.3", "macos/10.10.4", @@ -674,6 +706,9 @@ "macos/10.12.1", "macos/10.12.2", "macos/10.13.0", + "macos/10.13.1", + "macos/10.13.2", + "macos/10.13.3", "macos/10.9.2", "macos/10.9.4", "macos/10.9.5", @@ -682,6 +717,7 @@ "mozilla/2.14", "mozilla/2.16", "mozilla/2.18", + "mozilla/2.20", "mozilla/2.9", "windows/090501224247", "windows/090825180842", @@ -724,7 +760,8 @@ "windows/170419224008", "windows/170613190204", "windows/170922155710", - "windows/171121202507" + "windows/171121202507", + "windows/180122185731" ], "0687260331a72403d909f105e69bcf0d32e1bd2493ffc6d9206d11bcd6770739": [ "android/kitkat-cts-release", @@ -739,6 +776,7 @@ "android/nougat-cts-release", "android/nougat-mr1-cts-release", "android/oreo-cts-release", + "android/oreo-mr1-cts-release", "macos/10.10.0", "macos/10.10.3", "macos/10.10.4", @@ -750,6 +788,9 @@ "macos/10.12.1", "macos/10.12.2", "macos/10.13.0", + "macos/10.13.1", + "macos/10.13.2", + "macos/10.13.3", "macos/10.9.0", "macos/10.9.2", "macos/10.9.4", @@ -759,6 +800,7 @@ "mozilla/2.14", "mozilla/2.16", "mozilla/2.18", + "mozilla/2.20", "mozilla/2.9", "windows/070109202240", "windows/070201011524", @@ -812,7 +854,8 @@ "windows/170419224008", "windows/170613190204", "windows/170922155710", - "windows/171121202507" + "windows/171121202507", + "windows/180122185731" ], "06a2c9a3379ab3c156159a27ca9ecdbd4ef75309b409cf70aeca9a12330f380e": [ "macos/10.9.0", @@ -884,7 +927,8 @@ "windows/170419224008", "windows/170613190204", "windows/170922155710", - "windows/171121202507" + "windows/171121202507", + "windows/180122185731" ], "07453d53793bf41819a5251c69f88e2bb344b59ca828b5a543781599eaf3d602": [ "windows/070109202240", @@ -926,12 +970,14 @@ ], "0753e940378c1bd5e3836e395daea5cb839e5046f1bd0eae1951cf10fec7c965": [ "mozilla/2.18", + "mozilla/2.20", "windows/161112005943", "windows/170228174808", "windows/170419224008", "windows/170613190204", "windows/170922155710", - "windows/171121202507" + "windows/171121202507", + "windows/180122185731" ], "075bfcca2d55ae6e35742c32afd0ca8ea4c958feefc23224999541c033d69c8d": [ "windows/120125230451", @@ -961,7 +1007,8 @@ "windows/170419224008", "windows/170613190204", "windows/170922155710", - "windows/171121202507" + "windows/171121202507", + "windows/180122185731" ], "0771920c8cb874d5c5a4dc0d6a51a2d495d38c4de2cd5b83d2a06faa051935f6": [ "windows/121102212406", @@ -988,7 +1035,8 @@ "windows/170419224008", "windows/170613190204", "windows/170922155710", - "windows/171121202507" + "windows/171121202507", + "windows/180122185731" ], "0791ca0749b20782aad3c7d7bd0cdfc9485835843eb2d7996009ce43ab6c6927": [ "android/kitkat-cts-release", @@ -1085,7 +1133,8 @@ "windows/170419224008", "windows/170613190204", "windows/170922155710", - "windows/171121202507" + "windows/171121202507", + "windows/180122185731" ], "0a81ec5a929777f145904af38d5d509f66b5e2c58fcdb531058b0e17f3f0b41b": [ "android/kitkat-cts-release", @@ -1100,6 +1149,7 @@ "android/nougat-cts-release", "android/nougat-mr1-cts-release", "android/oreo-cts-release", + "android/oreo-mr1-cts-release", "macos/10.10.0", "macos/10.10.3", "macos/10.10.4", @@ -1111,6 +1161,9 @@ "macos/10.12.1", "macos/10.12.2", "macos/10.13.0", + "macos/10.13.1", + "macos/10.13.2", + "macos/10.13.3", "macos/10.9.0", "macos/10.9.2", "macos/10.9.4", @@ -1120,6 +1173,7 @@ "mozilla/2.14", "mozilla/2.16", "mozilla/2.18", + "mozilla/2.20", "mozilla/2.9", "windows/100503224537", "windows/100719231554", @@ -1158,7 +1212,8 @@ "windows/170419224008", "windows/170613190204", "windows/170922155710", - "windows/171121202507" + "windows/171121202507", + "windows/180122185731" ], "0b5eed4e846403cf55e065848440ed2a82758bf5b9aa1f253d4613cfa080ff3f": [ "android/kitkat-cts-release", @@ -1259,7 +1314,8 @@ "windows/170419224008", "windows/170613190204", "windows/170922155710", - "windows/171121202507" + "windows/171121202507", + "windows/180122185731" ], "0c0b6b2bd1edd7b27fead157f8e846b335b784a39f06c47216c8746f64c5ceda": [ "windows/140912180251", @@ -1278,7 +1334,8 @@ "windows/170419224008", "windows/170613190204", "windows/170922155710", - "windows/171121202507" + "windows/171121202507", + "windows/180122185731" ], "0c258a12a5674aef25f28ba7dcfaeceea348e541e6f5cc4ee63b71b361606ac3": [ "android/kitkat-cts-release", @@ -1293,6 +1350,7 @@ "android/nougat-cts-release", "android/nougat-mr1-cts-release", "android/oreo-cts-release", + "android/oreo-mr1-cts-release", "macos/10.10.0", "macos/10.10.3", "macos/10.10.4", @@ -1304,6 +1362,9 @@ "macos/10.12.1", "macos/10.12.2", "macos/10.13.0", + "macos/10.13.1", + "macos/10.13.2", + "macos/10.13.3", "macos/10.9.0", "macos/10.9.2", "macos/10.9.4", @@ -1366,7 +1427,8 @@ "windows/170419224008", "windows/170613190204", "windows/170922155710", - "windows/171121202507" + "windows/171121202507", + "windows/180122185731" ], "0c2cd63df7806fa399ede809116b575bf87989f06518f9808c860503178baf66": [ "android/kitkat-cts-release", @@ -1381,6 +1443,7 @@ "android/nougat-cts-release", "android/nougat-mr1-cts-release", "android/oreo-cts-release", + "android/oreo-mr1-cts-release", "macos/10.10.0", "macos/10.10.3", "macos/10.10.4", @@ -1392,6 +1455,9 @@ "macos/10.12.1", "macos/10.12.2", "macos/10.13.0", + "macos/10.13.1", + "macos/10.13.2", + "macos/10.13.3", "macos/10.9.0", "macos/10.9.2", "macos/10.9.4", @@ -1401,6 +1467,7 @@ "mozilla/2.14", "mozilla/2.16", "mozilla/2.18", + "mozilla/2.20", "mozilla/2.9", "windows/070109202240", "windows/070201011524", @@ -1438,6 +1505,9 @@ "macos/10.12.1", "macos/10.12.2", "macos/10.13.0", + "macos/10.13.1", + "macos/10.13.2", + "macos/10.13.3", "macos/10.9.0", "macos/10.9.2", "macos/10.9.4", @@ -1479,7 +1549,8 @@ "windows/170419224008", "windows/170613190204", "windows/170922155710", - "windows/171121202507" + "windows/171121202507", + "windows/180122185731" ], "0ed3ffab6c149c8b4e71058e8668d429abfda681c2fff508207641f0d751a3e5": [ "macos/10.10.0", @@ -1493,6 +1564,9 @@ "macos/10.12.1", "macos/10.12.2", "macos/10.13.0", + "macos/10.13.1", + "macos/10.13.2", + "macos/10.13.3", "macos/10.9.2", "macos/10.9.4", "macos/10.9.5" @@ -1566,7 +1640,8 @@ "windows/170419224008", "windows/170613190204", "windows/170922155710", - "windows/171121202507" + "windows/171121202507", + "windows/180122185731" ], "0f993c8aef97baaf5687140ed59ad1821bb4afacf0aa9a58b5d57a338a3afbcb": [ "android/kitkat-cts-release", @@ -1581,6 +1656,7 @@ "android/nougat-cts-release", "android/nougat-mr1-cts-release", "android/oreo-cts-release", + "android/oreo-mr1-cts-release", "macos/10.10.0", "macos/10.10.3", "macos/10.10.4", @@ -1592,6 +1668,9 @@ "macos/10.12.1", "macos/10.12.2", "macos/10.13.0", + "macos/10.13.1", + "macos/10.13.2", + "macos/10.13.3", "macos/10.9.0", "macos/10.9.2", "macos/10.9.4", @@ -1601,6 +1680,7 @@ "mozilla/2.14", "mozilla/2.16", "mozilla/2.18", + "mozilla/2.20", "mozilla/2.9", "windows/070109202240", "windows/070201011524", @@ -1654,7 +1734,8 @@ "windows/170419224008", "windows/170613190204", "windows/170922155710", - "windows/171121202507" + "windows/171121202507", + "windows/180122185731" ], "126bf01c1094d2f0ca2e352380b3c724294546ccc65597bef7f12d8a171f1984": [ "macos/10.10.0", @@ -1668,6 +1749,9 @@ "macos/10.12.1", "macos/10.12.2", "macos/10.13.0", + "macos/10.13.1", + "macos/10.13.2", + "macos/10.13.3", "macos/10.9.2", "macos/10.9.4", "macos/10.9.5", @@ -1691,7 +1775,8 @@ "windows/170419224008", "windows/170613190204", "windows/170922155710", - "windows/171121202507" + "windows/171121202507", + "windows/180122185731" ], "12d480c1a3c664781b99d9df0e9faf3f1cacee1b3c30c3123a337a4a454ffed2": [ "windows/071219233937", @@ -1741,7 +1826,8 @@ "windows/170419224008", "windows/170613190204", "windows/170922155710", - "windows/171121202507" + "windows/171121202507", + "windows/180122185731" ], "136335439334a7698016a0d324de72284e079d7b5220bb8fbd747816eebebaca": [ "android/kitkat-cts-release", @@ -1756,6 +1842,7 @@ "android/nougat-cts-release", "android/nougat-mr1-cts-release", "android/oreo-cts-release", + "android/oreo-mr1-cts-release", "macos/10.10.0", "macos/10.10.3", "macos/10.10.4", @@ -1767,6 +1854,9 @@ "macos/10.12.1", "macos/10.12.2", "macos/10.13.0", + "macos/10.13.1", + "macos/10.13.2", + "macos/10.13.3", "macos/10.9.2", "macos/10.9.4", "macos/10.9.5", @@ -1775,6 +1865,7 @@ "mozilla/2.14", "mozilla/2.16", "mozilla/2.18", + "mozilla/2.20", "mozilla/2.9", "windows/090501224247", "windows/090825180842", @@ -1817,7 +1908,8 @@ "windows/170419224008", "windows/170613190204", "windows/170922155710", - "windows/171121202507" + "windows/171121202507", + "windows/180122185731" ], "1465fa205397b876faa6f0a9958e5590e40fcc7faa4fb7c2c8677521fb5fb658": [ "android/kitkat-cts-release", @@ -1832,6 +1924,7 @@ "android/nougat-cts-release", "android/nougat-mr1-cts-release", "android/oreo-cts-release", + "android/oreo-mr1-cts-release", "macos/10.10.0", "macos/10.10.3", "macos/10.10.4", @@ -1843,6 +1936,9 @@ "macos/10.12.1", "macos/10.12.2", "macos/10.13.0", + "macos/10.13.1", + "macos/10.13.2", + "macos/10.13.3", "macos/10.9.0", "macos/10.9.2", "macos/10.9.4", @@ -1852,6 +1948,7 @@ "mozilla/2.14", "mozilla/2.16", "mozilla/2.18", + "mozilla/2.20", "mozilla/2.9", "windows/070109202240", "windows/070201011524", @@ -1905,7 +2002,8 @@ "windows/170419224008", "windows/170613190204", "windows/170922155710", - "windows/171121202507" + "windows/171121202507", + "windows/180122185731" ], "1501f89c5c4dcf36cf588a17c9fd7cfceb9ee01e8729be355e25de80eb6284b4": [ "windows/160414222039", @@ -1915,16 +2013,22 @@ "windows/170419224008", "windows/170613190204", "windows/170922155710", - "windows/171121202507" + "windows/171121202507", + "windows/180122185731" ], "152a402bfcdf2cd548054d2275b39c7fca3ec0978078b0f0ea76e561a6c7433e": [ "android/nougat-mr1-cts-release", "android/oreo-cts-release", + "android/oreo-mr1-cts-release", + "macos/10.13.1", + "macos/10.13.2", + "macos/10.13.3", "mozilla/2.10", "mozilla/2.11", "mozilla/2.14", "mozilla/2.16", "mozilla/2.18", + "mozilla/2.20", "mozilla/2.9", "windows/150618202535", "windows/150723231635", @@ -1940,7 +2044,8 @@ "windows/170419224008", "windows/170613190204", "windows/170922155710", - "windows/171121202507" + "windows/171121202507", + "windows/180122185731" ], "1594cb5b826c315de3bc932c56895ff23a3a988b5dc1f034d214dfd858d89ee8": [ "windows/070109202240", @@ -1982,7 +2087,8 @@ ], "15d5b8774619ea7d54ce1ca6d0b0c403e037a917f131e8a04e1e6b7a71babce5": [ "windows/170922155710", - "windows/171121202507" + "windows/171121202507", + "windows/180122185731" ], "15f0ba00a3ac7af3ac884c072b1011a077bd77c097f40164b2f8598abd83860c": [ "android/kitkat-cts-release", @@ -1997,6 +2103,7 @@ "android/nougat-cts-release", "android/nougat-mr1-cts-release", "android/oreo-cts-release", + "android/oreo-mr1-cts-release", "macos/10.10.0", "macos/10.10.3", "macos/10.10.4", @@ -2008,6 +2115,9 @@ "macos/10.12.1", "macos/10.12.2", "macos/10.13.0", + "macos/10.13.1", + "macos/10.13.2", + "macos/10.13.3", "macos/10.9.0", "macos/10.9.2", "macos/10.9.4", @@ -2017,6 +2127,7 @@ "mozilla/2.14", "mozilla/2.16", "mozilla/2.18", + "mozilla/2.20", "mozilla/2.9", "windows/070109202240", "windows/070201011524", @@ -2055,6 +2166,7 @@ "android/nougat-cts-release", "android/nougat-mr1-cts-release", "android/oreo-cts-release", + "android/oreo-mr1-cts-release", "macos/10.10.0", "macos/10.10.3", "macos/10.10.4", @@ -2066,6 +2178,9 @@ "macos/10.12.1", "macos/10.12.2", "macos/10.13.0", + "macos/10.13.1", + "macos/10.13.2", + "macos/10.13.3", "macos/10.9.0", "macos/10.9.2", "macos/10.9.4", @@ -2075,6 +2190,7 @@ "mozilla/2.14", "mozilla/2.16", "mozilla/2.18", + "mozilla/2.20", "mozilla/2.9", "windows/070109202240", "windows/070201011524", @@ -2128,7 +2244,8 @@ "windows/170419224008", "windows/170613190204", "windows/170922155710", - "windows/171121202507" + "windows/171121202507", + "windows/180122185731" ], "1793927a0614549789adce2f8f34f7f0b66d0f3ae3a3b84d21ec15dbba4fadc7": [ "android/kitkat-cts-release", @@ -2143,14 +2260,19 @@ "android/nougat-cts-release", "android/nougat-mr1-cts-release", "android/oreo-cts-release", + "android/oreo-mr1-cts-release", "macos/10.12.1", "macos/10.12.2", "macos/10.13.0", + "macos/10.13.1", + "macos/10.13.2", + "macos/10.13.3", "mozilla/2.10", "mozilla/2.11", "mozilla/2.14", "mozilla/2.16", "mozilla/2.18", + "mozilla/2.20", "mozilla/2.9", "windows/081103235012", "windows/090203164005", @@ -2195,7 +2317,8 @@ "windows/170419224008", "windows/170613190204", "windows/170922155710", - "windows/171121202507" + "windows/171121202507", + "windows/180122185731" ], "179fbc148a3dd00fd24ea13458cc43bfa7f59c8182d783a513f6ebec100c8924": [ "android/lollipop-mr1-cts-release", @@ -2206,6 +2329,7 @@ "android/nougat-cts-release", "android/nougat-mr1-cts-release", "android/oreo-cts-release", + "android/oreo-mr1-cts-release", "macos/10.10.0", "macos/10.10.3", "macos/10.10.4", @@ -2217,6 +2341,9 @@ "macos/10.12.1", "macos/10.12.2", "macos/10.13.0", + "macos/10.13.1", + "macos/10.13.2", + "macos/10.13.3", "macos/10.9.2", "macos/10.9.4", "macos/10.9.5", @@ -2225,6 +2352,7 @@ "mozilla/2.14", "mozilla/2.16", "mozilla/2.18", + "mozilla/2.20", "mozilla/2.9", "windows/130626232015", "windows/131003230417", @@ -2247,14 +2375,20 @@ "windows/170419224008", "windows/170613190204", "windows/170922155710", - "windows/171121202507" + "windows/171121202507", + "windows/180122185731" ], "18ce6cfe7bf14e60b2e347b8dfe868cb31d02ebb3ada271569f50343b46db3a4": [ "android/oreo-cts-release", + "android/oreo-mr1-cts-release", + "macos/10.13.1", + "macos/10.13.2", + "macos/10.13.3", "mozilla/2.11", "mozilla/2.14", "mozilla/2.16", "mozilla/2.18", + "mozilla/2.20", "windows/160113232859", "windows/160123000836", "windows/160128175153", @@ -2265,7 +2399,8 @@ "windows/170419224008", "windows/170613190204", "windows/170922155710", - "windows/171121202507" + "windows/171121202507", + "windows/180122185731" ], "18f1fc7f205df8adddeb7fe007dd57e3af375a9c4d8d73546bf4f1fed1e18d35": [ "android/kitkat-cts-release", @@ -2280,6 +2415,7 @@ "android/nougat-cts-release", "android/nougat-mr1-cts-release", "android/oreo-cts-release", + "android/oreo-mr1-cts-release", "macos/10.10.0", "macos/10.10.3", "macos/10.10.4", @@ -2291,6 +2427,9 @@ "macos/10.12.1", "macos/10.12.2", "macos/10.13.0", + "macos/10.13.1", + "macos/10.13.2", + "macos/10.13.3", "macos/10.9.0", "macos/10.9.2", "macos/10.9.4", @@ -2300,6 +2439,7 @@ "mozilla/2.14", "mozilla/2.16", "mozilla/2.18", + "mozilla/2.20", "mozilla/2.9", "windows/070109202240", "windows/070201011524", @@ -2353,12 +2493,14 @@ "windows/170419224008", "windows/170613190204", "windows/170922155710", - "windows/171121202507" + "windows/171121202507", + "windows/180122185731" ], "19abcdff3a74402fa8f0ca206bf7fab0dffff3ae2bbd719584d21090a4353207": [ "windows/170613190204", "windows/170922155710", - "windows/171121202507" + "windows/171121202507", + "windows/180122185731" ], "1a0d20445de5ba1862d19ef880858cbce50102b36e8f0a040c3c69e74522fe6e": [ "windows/110919210309", @@ -2390,7 +2532,8 @@ "windows/170419224008", "windows/170613190204", "windows/170922155710", - "windows/171121202507" + "windows/171121202507", + "windows/180122185731" ], "1a2512cda6744abea11432a2fdc9f8c088db5a98c89e13352574cde4d9e80cdd": [ "windows/140912180251", @@ -2409,7 +2552,8 @@ "windows/170419224008", "windows/170613190204", "windows/170922155710", - "windows/171121202507" + "windows/171121202507", + "windows/180122185731" ], "1aa980c8c0d316f25029978982f033cbb3a3f4188d669f2de6a8d84ee00a1575": [ "windows/080328202117", @@ -2458,14 +2602,20 @@ "windows/170419224008", "windows/170613190204", "windows/170922155710", - "windows/171121202507" + "windows/171121202507", + "windows/180122185731" ], "1ba5b2aa8c65401a82960118f80bec4f62304d83cec4713a19c39c011ea46db4": [ "android/oreo-cts-release", + "android/oreo-mr1-cts-release", + "macos/10.13.1", + "macos/10.13.2", + "macos/10.13.3", "mozilla/2.11", "mozilla/2.14", "mozilla/2.16", "mozilla/2.18", + "mozilla/2.20", "windows/160113232859", "windows/160123000836", "windows/160128175153", @@ -2476,7 +2626,8 @@ "windows/170419224008", "windows/170613190204", "windows/170922155710", - "windows/171121202507" + "windows/171121202507", + "windows/180122185731" ], "1ba622b36325544ae922afc22ef9d367943794f6e16874f368a733c65c9d5279": [ "windows/111018233154", @@ -2507,7 +2658,8 @@ "windows/170419224008", "windows/170613190204", "windows/170922155710", - "windows/171121202507" + "windows/171121202507", + "windows/180122185731" ], "1c01c6f4dbb2fefc22558b2bca32563f49844acfc32b7be4b0ff599f9e8c7af7": [ "android/kitkat-cts-release", @@ -2566,7 +2718,8 @@ "windows/170419224008", "windows/170613190204", "windows/170922155710", - "windows/171121202507" + "windows/171121202507", + "windows/180122185731" ], "1d4f0596fca2611d09f84c78f2ea565ef2eab9cfc272a1718bd336e6e0ae021a": [ "windows/070109202240", @@ -2634,7 +2787,8 @@ "windows/170419224008", "windows/170613190204", "windows/170922155710", - "windows/171121202507" + "windows/171121202507", + "windows/180122185731" ], "1e49ac5dc69e86d0565da2c1305c419330b0b781bfec50e54a1b35af7fddd501": [ "macos/10.11.0", @@ -2645,6 +2799,9 @@ "macos/10.12.1", "macos/10.12.2", "macos/10.13.0", + "macos/10.13.1", + "macos/10.13.2", + "macos/10.13.3", "windows/100927165108", "windows/110125205412", "windows/110218005058", @@ -2680,7 +2837,8 @@ "windows/170419224008", "windows/170613190204", "windows/170922155710", - "windows/171121202507" + "windows/171121202507", + "windows/180122185731" ], "1e51942b84fd467bf77d1c89da241c04254dc8f3ef4c22451fe7a89978bdcd4f": [ "windows/160916174005", @@ -2689,7 +2847,8 @@ "windows/170419224008", "windows/170613190204", "windows/170922155710", - "windows/171121202507" + "windows/171121202507", + "windows/180122185731" ], "1e910b40c08184c0ca20468e824502ff2485163f77b03bb73296823f03885621": [ "windows/111018233154", @@ -2720,21 +2879,24 @@ "windows/170419224008", "windows/170613190204", "windows/170922155710", - "windows/171121202507" + "windows/171121202507", + "windows/180122185731" ], "209e956af04df3996507c887d356230d6eb49fdbdd2d8a058ff50b8f80f690aa": [ "windows/170228174808", "windows/170419224008", "windows/170613190204", "windows/170922155710", - "windows/171121202507" + "windows/171121202507", + "windows/180122185731" ], "2193cfea381211a1aeaa2de984e630643a87160b1208118145eafb8e1bc69958": [ "windows/170228174808", "windows/170419224008", "windows/170613190204", "windows/170922155710", - "windows/171121202507" + "windows/171121202507", + "windows/180122185731" ], "21db20123660bb2ed418205da11ee7a85a65e2bc6e55b5af7e7899c8a266d92e": [ "android/kitkat-cts-release", @@ -2760,6 +2922,9 @@ "macos/10.12.1", "macos/10.12.2", "macos/10.13.0", + "macos/10.13.1", + "macos/10.13.2", + "macos/10.13.3", "macos/10.9.0", "macos/10.9.2", "macos/10.9.4", @@ -2820,7 +2985,8 @@ "windows/170419224008", "windows/170613190204", "windows/170922155710", - "windows/171121202507" + "windows/171121202507", + "windows/180122185731" ], "229ccc196d32c98421cc119e78486eebef603aecd525c6b88b47abb740692b96": [ "windows/150618202535", @@ -2837,17 +3003,20 @@ "windows/170419224008", "windows/170613190204", "windows/170922155710", - "windows/171121202507" + "windows/171121202507", + "windows/180122185731" ], "22a2c1f7bded704cc1e701b5f408c310880fe956b5de2a4a44f99c873a25a7c8": [ "mozilla/2.18", + "mozilla/2.20", "windows/160916174005", "windows/161112005943", "windows/170228174808", "windows/170419224008", "windows/170613190204", "windows/170922155710", - "windows/171121202507" + "windows/171121202507", + "windows/180122185731" ], "22e0d11dc9207e16c92b2ee18cfdb2c2e940626847921fc528cedd2f7932f714": [ "windows/070109202240", @@ -2897,6 +3066,9 @@ "macos/10.12.1", "macos/10.12.2", "macos/10.13.0", + "macos/10.13.1", + "macos/10.13.2", + "macos/10.13.3", "macos/10.9.0", "macos/10.9.2", "macos/10.9.4", @@ -2947,7 +3119,8 @@ "windows/170419224008", "windows/170613190204", "windows/170922155710", - "windows/171121202507" + "windows/171121202507", + "windows/180122185731" ], "2399561127a57125de8cefea610ddf2fa078b5c8067f4e828290bfb860e84b3c": [ "android/kitkat-cts-release", @@ -2962,6 +3135,7 @@ "android/nougat-cts-release", "android/nougat-mr1-cts-release", "android/oreo-cts-release", + "android/oreo-mr1-cts-release", "macos/10.10.0", "macos/10.10.3", "macos/10.10.4", @@ -2973,6 +3147,9 @@ "macos/10.12.1", "macos/10.12.2", "macos/10.13.0", + "macos/10.13.1", + "macos/10.13.2", + "macos/10.13.3", "macos/10.9.2", "macos/10.9.4", "macos/10.9.5", @@ -2981,6 +3158,7 @@ "mozilla/2.14", "mozilla/2.16", "mozilla/2.18", + "mozilla/2.20", "mozilla/2.9", "windows/090825180842", "windows/091013033632", @@ -3022,7 +3200,8 @@ "windows/170419224008", "windows/170613190204", "windows/170922155710", - "windows/171121202507" + "windows/171121202507", + "windows/180122185731" ], "248302a977f40f7dd6a2b770586adfaac3eb1e85fd1a102dbd7863c72b8f8ef2": [ "macos/10.10.0", @@ -3036,7 +3215,8 @@ "windows/170419224008", "windows/170613190204", "windows/170922155710", - "windows/171121202507" + "windows/171121202507", + "windows/180122185731" ], "2530cc8e98321502bad96f9b1fba1b099e2d299e0f4548bb914f363bc0d4531f": [ "android/kitkat-cts-release", @@ -3051,6 +3231,7 @@ "android/nougat-cts-release", "android/nougat-mr1-cts-release", "android/oreo-cts-release", + "android/oreo-mr1-cts-release", "macos/10.10.0", "macos/10.10.3", "macos/10.10.4", @@ -3062,6 +3243,9 @@ "macos/10.12.1", "macos/10.12.2", "macos/10.13.0", + "macos/10.13.1", + "macos/10.13.2", + "macos/10.13.3", "macos/10.9.2", "macos/10.9.4", "macos/10.9.5", @@ -3070,6 +3254,7 @@ "mozilla/2.14", "mozilla/2.16", "mozilla/2.18", + "mozilla/2.20", "mozilla/2.9" ], "2602d21e81277a83f6048128f61d794a06f474e1f75e49740a817c2666f62211": [ @@ -3122,6 +3307,9 @@ "macos/10.12.1", "macos/10.12.2", "macos/10.13.0", + "macos/10.13.1", + "macos/10.13.2", + "macos/10.13.3", "macos/10.9.2", "macos/10.9.4", "macos/10.9.5", @@ -3154,16 +3342,22 @@ "windows/170419224008", "windows/170613190204", "windows/170922155710", - "windows/171121202507" + "windows/171121202507", + "windows/180122185731" ], "27995829fe6a7515c1bfe848f9c4761db16c225929257bf40d0894f29ea8baf2": [ "android/nougat-mr1-cts-release", "android/oreo-cts-release", + "android/oreo-mr1-cts-release", + "macos/10.13.1", + "macos/10.13.2", + "macos/10.13.3", "mozilla/2.10", "mozilla/2.11", "mozilla/2.14", "mozilla/2.16", "mozilla/2.18", + "mozilla/2.20", "mozilla/2.9", "windows/150618202535", "windows/150723231635", @@ -3179,7 +3373,8 @@ "windows/170419224008", "windows/170613190204", "windows/170922155710", - "windows/171121202507" + "windows/171121202507", + "windows/180122185731" ], "2834991cf677466d22baac3b0055e5b911d9a9e55f5b85ba02dc566782c30e8a": [ "macos/10.10.0", @@ -3265,7 +3460,8 @@ ], "2a575471e31340bc21581cbd2cf13e158463203ece94bcf9d3cc196bf09a5472": [ "windows/170922155710", - "windows/171121202507" + "windows/171121202507", + "windows/180122185731" ], "2a8da2f8d23e0cd3b5871ecfb0f42276ca73230667f474eede71c5ee32cc3ec6": [ "windows/160414222039", @@ -3275,7 +3471,8 @@ "windows/170419224008", "windows/170613190204", "windows/170922155710", - "windows/171121202507" + "windows/171121202507", + "windows/180122185731" ], "2a99f5bc1174b73cbb1d620884e01c34e51ccb3978da125f0e33268883bf4158": [ "android/marshmallow-cts-release", @@ -3285,6 +3482,7 @@ "android/nougat-cts-release", "android/nougat-mr1-cts-release", "android/oreo-cts-release", + "android/oreo-mr1-cts-release", "macos/10.10.0", "macos/10.10.3", "macos/10.10.4", @@ -3296,6 +3494,9 @@ "macos/10.12.1", "macos/10.12.2", "macos/10.13.0", + "macos/10.13.1", + "macos/10.13.2", + "macos/10.13.3", "macos/10.9.4", "macos/10.9.5", "mozilla/2.10", @@ -3303,6 +3504,7 @@ "mozilla/2.14", "mozilla/2.16", "mozilla/2.18", + "mozilla/2.20", "mozilla/2.9", "windows/140912180251", "windows/150122021939", @@ -3321,11 +3523,13 @@ "windows/170419224008", "windows/170613190204", "windows/170922155710", - "windows/171121202507" + "windows/171121202507", + "windows/180122185731" ], "2cabeafe37d06ca22aba7391c0033d25982952c453647349763a3ab5ad6ccf69": [ "windows/170922155710", - "windows/171121202507" + "windows/171121202507", + "windows/180122185731" ], "2ce1cb0bf9d2f9e102993fbe215152c3b2dd0cabde1c68e5319b839154dbb7f5": [ "android/kitkat-cts-release", @@ -3340,6 +3544,7 @@ "android/nougat-cts-release", "android/nougat-mr1-cts-release", "android/oreo-cts-release", + "android/oreo-mr1-cts-release", "macos/10.10.0", "macos/10.10.3", "macos/10.10.4", @@ -3351,6 +3556,9 @@ "macos/10.12.1", "macos/10.12.2", "macos/10.13.0", + "macos/10.13.1", + "macos/10.13.2", + "macos/10.13.3", "macos/10.9.0", "macos/10.9.2", "macos/10.9.4", @@ -3360,6 +3568,7 @@ "mozilla/2.14", "mozilla/2.16", "mozilla/2.18", + "mozilla/2.20", "mozilla/2.9", "windows/100503224537", "windows/100719231554", @@ -3398,7 +3607,8 @@ "windows/170419224008", "windows/170613190204", "windows/170922155710", - "windows/171121202507" + "windows/171121202507", + "windows/180122185731" ], "2d47437de17951215a12f3c58e51c729a58026ef1fcc0a5fb3d9dc012f600d19": [ "android/kitkat-cts-release", @@ -3476,7 +3686,8 @@ "windows/170419224008", "windows/170613190204", "windows/170922155710", - "windows/171121202507" + "windows/171121202507", + "windows/180122185731" ], "2d66a702ae81ba03af8cff55ab318afa919039d9f31b4d64388680f81311b65a": [ "windows/110919210309", @@ -3508,7 +3719,8 @@ "windows/170419224008", "windows/170613190204", "windows/170922155710", - "windows/171121202507" + "windows/171121202507", + "windows/180122185731" ], "2dc62c3f6c0cc9020bba77e1c511511024b943ee598856da5a22e222b7277a20": [ "macos/10.9.0", @@ -3577,7 +3789,8 @@ "windows/170419224008", "windows/170613190204", "windows/170922155710", - "windows/171121202507" + "windows/171121202507", + "windows/180122185731" ], "2dfcbacadf22a6ff107a51fd3e8b9e17858028879b13f7c3b57b3e1bd2315809": [ "windows/070109202240", @@ -3619,8 +3832,10 @@ ], "2e7bf16cc22485a7bbe2aa8696750761b0ae39be3b2fe9d0cc6d4ef73491425c": [ "mozilla/2.18", + "mozilla/2.20", "windows/170922155710", - "windows/171121202507" + "windows/171121202507", + "windows/180122185731" ], "2f1062f8bf84e7eb83a0f64c98d891fbe2c811b17ffac0bce1a6dc9c7c3dcbb7": [ "macos/10.9.0", @@ -3715,6 +3930,7 @@ "android/nougat-cts-release", "android/nougat-mr1-cts-release", "android/oreo-cts-release", + "android/oreo-mr1-cts-release", "macos/10.10.3", "macos/10.10.4", "macos/10.11.0", @@ -3725,11 +3941,15 @@ "macos/10.12.1", "macos/10.12.2", "macos/10.13.0", + "macos/10.13.1", + "macos/10.13.2", + "macos/10.13.3", "mozilla/2.10", "mozilla/2.11", "mozilla/2.14", "mozilla/2.16", "mozilla/2.18", + "mozilla/2.20", "mozilla/2.9", "windows/140912180251", "windows/150122021939", @@ -3749,7 +3969,8 @@ "windows/170419224008", "windows/170613190204", "windows/170922155710", - "windows/171121202507" + "windows/171121202507", + "windows/180122185731" ], "31ad6648f8104138c738f39ea4320133393e3a18cc02296ef97c2ac9ef6731d0": [ "android/lollipop-cts-release", @@ -3761,6 +3982,7 @@ "android/nougat-cts-release", "android/nougat-mr1-cts-release", "android/oreo-cts-release", + "android/oreo-mr1-cts-release", "macos/10.10.0", "macos/10.10.3", "macos/10.10.4", @@ -3772,6 +3994,9 @@ "macos/10.12.1", "macos/10.12.2", "macos/10.13.0", + "macos/10.13.1", + "macos/10.13.2", + "macos/10.13.3", "macos/10.9.2", "macos/10.9.4", "macos/10.9.5", @@ -3780,6 +4005,7 @@ "mozilla/2.14", "mozilla/2.16", "mozilla/2.18", + "mozilla/2.20", "mozilla/2.9", "windows/131003230417", "windows/140312052931", @@ -3801,7 +4027,8 @@ "windows/170419224008", "windows/170613190204", "windows/170922155710", - "windows/171121202507" + "windows/171121202507", + "windows/180122185731" ], "31eace9b4c9c71734a185680bc24866ca6cbd82b3cb61bcc8706261b59ce1073": [ "windows/070109202240", @@ -3962,17 +4189,20 @@ "windows/170419224008", "windows/170613190204", "windows/170922155710", - "windows/171121202507" + "windows/171121202507", + "windows/180122185731" ], "3417bb06cc6007da1b961c920b8ab4ce3fad820e4aa30b9acbc4a74ebdcebc65": [ "mozilla/2.18", + "mozilla/2.20", "windows/160916174005", "windows/161112005943", "windows/170228174808", "windows/170419224008", "windows/170613190204", "windows/170922155710", - "windows/171121202507" + "windows/171121202507", + "windows/180122185731" ], "341de98b1392abf7f4ab90a960cf25d4bd6ec65b9a51ce6ed067d00ec7ce9b7f": [ "macos/10.10.0", @@ -4002,7 +4232,8 @@ "windows/170419224008", "windows/170613190204", "windows/170922155710", - "windows/171121202507" + "windows/171121202507", + "windows/180122185731" ], "35ae5bddd8f7ae635cffba5682a8f00b95f48462c7108ee9a0e5292b074aafb2": [ "android/kitkat-cts-release", @@ -4080,7 +4311,8 @@ "windows/170419224008", "windows/170613190204", "windows/170922155710", - "windows/171121202507" + "windows/171121202507", + "windows/180122185731" ], "363f3c849eab03b0a2a0f636d7b86d04d3ac7fcfe26a0a9121ab9795f6e176df": [ "macos/10.10.0", @@ -4094,6 +4326,9 @@ "macos/10.12.1", "macos/10.12.2", "macos/10.13.0", + "macos/10.13.1", + "macos/10.13.2", + "macos/10.13.3", "macos/10.9.2", "macos/10.9.4", "macos/10.9.5" @@ -4150,7 +4385,8 @@ "windows/170419224008", "windows/170613190204", "windows/170922155710", - "windows/171121202507" + "windows/171121202507", + "windows/180122185731" ], "37d51006c512eaab626421f1ec8c92013fc5f82ae98ee533eb4619b8deb4d06c": [ "android/kitkat-cts-release", @@ -4165,6 +4401,7 @@ "android/nougat-cts-release", "android/nougat-mr1-cts-release", "android/oreo-cts-release", + "android/oreo-mr1-cts-release", "macos/10.10.0", "macos/10.10.3", "macos/10.10.4", @@ -4176,6 +4413,9 @@ "macos/10.12.1", "macos/10.12.2", "macos/10.13.0", + "macos/10.13.1", + "macos/10.13.2", + "macos/10.13.3", "macos/10.9.0", "macos/10.9.2", "macos/10.9.4", @@ -4185,6 +4425,7 @@ "mozilla/2.14", "mozilla/2.16", "mozilla/2.18", + "mozilla/2.20", "mozilla/2.9", "windows/070109202240", "windows/070201011524", @@ -4238,7 +4479,8 @@ "windows/170419224008", "windows/170613190204", "windows/170922155710", - "windows/171121202507" + "windows/171121202507", + "windows/180122185731" ], "37d8dc8af7867845da3344a6b1bade448d8a80e47b5579f96bf631768f9f30f6": [ "windows/070201011524", @@ -4433,6 +4675,9 @@ "macos/10.12.1", "macos/10.12.2", "macos/10.13.0", + "macos/10.13.1", + "macos/10.13.2", + "macos/10.13.3", "macos/10.9.0", "macos/10.9.2", "macos/10.9.4", @@ -4488,7 +4733,8 @@ "windows/170419224008", "windows/170613190204", "windows/170922155710", - "windows/171121202507" + "windows/171121202507", + "windows/180122185731" ], "3c4fb0b95ab8b30032f432b86f535fe172c185d0fd39865837cf36187fa6f428": [ "android/marshmallow-cts-release", @@ -4498,6 +4744,7 @@ "android/nougat-cts-release", "android/nougat-mr1-cts-release", "android/oreo-cts-release", + "android/oreo-mr1-cts-release", "macos/10.11.0", "macos/10.11.1", "macos/10.11.2", @@ -4506,11 +4753,15 @@ "macos/10.12.1", "macos/10.12.2", "macos/10.13.0", + "macos/10.13.1", + "macos/10.13.2", + "macos/10.13.3", "mozilla/2.10", "mozilla/2.11", "mozilla/2.14", "mozilla/2.16", "mozilla/2.18", + "mozilla/2.20", "mozilla/2.9", "windows/140912180251", "windows/150122021939", @@ -4530,7 +4781,8 @@ "windows/170419224008", "windows/170613190204", "windows/170922155710", - "windows/171121202507" + "windows/171121202507", + "windows/180122185731" ], "3c5f81fea5fab82c64bfa2eaecafcde8e077fc8620a7cae537163df36edbf378": [ "android/kitkat-cts-release", @@ -4545,6 +4797,7 @@ "android/nougat-cts-release", "android/nougat-mr1-cts-release", "android/oreo-cts-release", + "android/oreo-mr1-cts-release", "macos/10.10.0", "macos/10.10.3", "macos/10.10.4", @@ -4556,6 +4809,9 @@ "macos/10.12.1", "macos/10.12.2", "macos/10.13.0", + "macos/10.13.1", + "macos/10.13.2", + "macos/10.13.3", "macos/10.9.4", "macos/10.9.5", "mozilla/2.10", @@ -4563,6 +4819,7 @@ "mozilla/2.14", "mozilla/2.16", "mozilla/2.18", + "mozilla/2.20", "mozilla/2.9", "windows/100927165108", "windows/110125205412", @@ -4599,7 +4856,8 @@ "windows/170419224008", "windows/170613190204", "windows/170922155710", - "windows/171121202507" + "windows/171121202507", + "windows/180122185731" ], "3ccc3ccfe45496d07b620dbf1328e8a1490018f48633c8a28a995ca60408b0be": [ "windows/070109202240", @@ -4654,7 +4912,8 @@ "windows/170419224008", "windows/170613190204", "windows/170922155710", - "windows/171121202507" + "windows/171121202507", + "windows/180122185731" ], "3cfc3c14d1f684ff17e38c43ca440c00b967ec933e8bfe064ca1d72c90f2adb0": [ "mozilla/2.10", @@ -4689,6 +4948,7 @@ "android/nougat-cts-release", "android/nougat-mr1-cts-release", "android/oreo-cts-release", + "android/oreo-mr1-cts-release", "macos/10.10.0", "macos/10.10.3", "macos/10.10.4", @@ -4700,6 +4960,9 @@ "macos/10.12.1", "macos/10.12.2", "macos/10.13.0", + "macos/10.13.1", + "macos/10.13.2", + "macos/10.13.3", "macos/10.9.2", "macos/10.9.4", "macos/10.9.5", @@ -4708,6 +4971,7 @@ "mozilla/2.14", "mozilla/2.16", "mozilla/2.18", + "mozilla/2.20", "mozilla/2.9", "windows/110627203812", "windows/110830002513", @@ -4741,7 +5005,8 @@ "windows/170419224008", "windows/170613190204", "windows/170922155710", - "windows/171121202507" + "windows/171121202507", + "windows/180122185731" ], "3e9099b5015e8f486c00bcea9d111ee721faba355a89bcf1df69561e3dc6325c": [ "android/kitkat-cts-release", @@ -4756,6 +5021,7 @@ "android/nougat-cts-release", "android/nougat-mr1-cts-release", "android/oreo-cts-release", + "android/oreo-mr1-cts-release", "macos/10.10.0", "macos/10.10.3", "macos/10.10.4", @@ -4767,6 +5033,9 @@ "macos/10.12.1", "macos/10.12.2", "macos/10.13.0", + "macos/10.13.1", + "macos/10.13.2", + "macos/10.13.3", "macos/10.9.0", "macos/10.9.2", "macos/10.9.4", @@ -4776,6 +5045,7 @@ "mozilla/2.14", "mozilla/2.16", "mozilla/2.18", + "mozilla/2.20", "mozilla/2.9", "windows/070109202240", "windows/070201011524", @@ -4829,7 +5099,8 @@ "windows/170419224008", "windows/170613190204", "windows/170922155710", - "windows/171121202507" + "windows/171121202507", + "windows/180122185731" ], "3f06e55681d496f5be169eb5389f9f2b8ff61e1708df6881724849cd5d27cb69": [ "android/kitkat-cts-release", @@ -4980,7 +5251,8 @@ "windows/170419224008", "windows/170613190204", "windows/170922155710", - "windows/171121202507" + "windows/171121202507", + "windows/180122185731" ], "417dcf3180f4ed1a3747acf1179316cd48cb05c5788435168aed98c98cdcb615": [ "windows/121102212406", @@ -5007,7 +5279,8 @@ "windows/170419224008", "windows/170613190204", "windows/170922155710", - "windows/171121202507" + "windows/171121202507", + "windows/180122185731" ], "41c923866ab4cad6b7ad578081582e020797a6cbdf4fff78ce8396b38937d7f5": [ "android/kitkat-cts-release", @@ -5022,6 +5295,7 @@ "android/nougat-cts-release", "android/nougat-mr1-cts-release", "android/oreo-cts-release", + "android/oreo-mr1-cts-release", "macos/10.10.0", "macos/10.10.3", "macos/10.10.4", @@ -5033,6 +5307,9 @@ "macos/10.12.1", "macos/10.12.2", "macos/10.13.0", + "macos/10.13.1", + "macos/10.13.2", + "macos/10.13.3", "macos/10.9.0", "macos/10.9.2", "macos/10.9.4", @@ -5042,6 +5319,7 @@ "mozilla/2.14", "mozilla/2.16", "mozilla/2.18", + "mozilla/2.20", "mozilla/2.9", "windows/070201011524", "windows/070522004642", @@ -5094,7 +5372,8 @@ "windows/170419224008", "windows/170613190204", "windows/170922155710", - "windows/171121202507" + "windows/171121202507", + "windows/180122185731" ], "41d4f6dcf130b9843a3b9a9530953e925fdd84e8b7aeb8f205b8fae39352617d": [ "macos/10.10.0", @@ -5118,6 +5397,7 @@ "android/nougat-cts-release", "android/nougat-mr1-cts-release", "android/oreo-cts-release", + "android/oreo-mr1-cts-release", "macos/10.10.0", "macos/10.10.3", "macos/10.10.4", @@ -5129,6 +5409,9 @@ "macos/10.12.1", "macos/10.12.2", "macos/10.13.0", + "macos/10.13.1", + "macos/10.13.2", + "macos/10.13.3", "macos/10.9.0", "macos/10.9.2", "macos/10.9.4", @@ -5138,6 +5421,7 @@ "mozilla/2.14", "mozilla/2.16", "mozilla/2.18", + "mozilla/2.20", "mozilla/2.9", "windows/070109202240", "windows/070201011524", @@ -5191,7 +5475,8 @@ "windows/170419224008", "windows/170613190204", "windows/170922155710", - "windows/171121202507" + "windows/171121202507", + "windows/180122185731" ], "4210f199499a9ac33c8de02ba6dbaa14408bdd8a6e324689c1922d069715a332": [ "windows/100503224537", @@ -5231,7 +5516,8 @@ "windows/170419224008", "windows/170613190204", "windows/170922155710", - "windows/171121202507" + "windows/171121202507", + "windows/180122185731" ], "42143a511a3afcdd80d555debb4191ec6bb285ee66e62ec657ed20adf7d55faa": [ "windows/090825180842", @@ -5274,7 +5560,8 @@ "windows/170419224008", "windows/170613190204", "windows/170922155710", - "windows/171121202507" + "windows/171121202507", + "windows/180122185731" ], "4348a0e9444c78cb265e058d5e8944b4d84f9662bd26db257f8934a443c70161": [ "android/kitkat-cts-release", @@ -5289,6 +5576,7 @@ "android/nougat-cts-release", "android/nougat-mr1-cts-release", "android/oreo-cts-release", + "android/oreo-mr1-cts-release", "macos/10.10.0", "macos/10.10.3", "macos/10.10.4", @@ -5300,6 +5588,9 @@ "macos/10.12.1", "macos/10.12.2", "macos/10.13.0", + "macos/10.13.1", + "macos/10.13.2", + "macos/10.13.3", "macos/10.9.0", "macos/10.9.2", "macos/10.9.4", @@ -5309,6 +5600,7 @@ "mozilla/2.14", "mozilla/2.16", "mozilla/2.18", + "mozilla/2.20", "mozilla/2.9", "windows/070109202240", "windows/070201011524", @@ -5362,7 +5654,8 @@ "windows/170419224008", "windows/170613190204", "windows/170922155710", - "windows/171121202507" + "windows/171121202507", + "windows/180122185731" ], "43df5774b03e7fef5fe40d931a7bedf1bb2e6b42738c4e6d3841103d3aa7f339": [ "android/kitkat-cts-release", @@ -5377,6 +5670,7 @@ "android/nougat-cts-release", "android/nougat-mr1-cts-release", "android/oreo-cts-release", + "android/oreo-mr1-cts-release", "macos/10.10.0", "macos/10.10.3", "macos/10.10.4", @@ -5388,6 +5682,9 @@ "macos/10.12.1", "macos/10.12.2", "macos/10.13.0", + "macos/10.13.1", + "macos/10.13.2", + "macos/10.13.3", "macos/10.9.2", "macos/10.9.4", "macos/10.9.5", @@ -5396,6 +5693,7 @@ "mozilla/2.14", "mozilla/2.16", "mozilla/2.18", + "mozilla/2.20", "mozilla/2.9", "windows/090825180842", "windows/091013033632", @@ -5437,7 +5735,8 @@ "windows/170419224008", "windows/170613190204", "windows/170922155710", - "windows/171121202507" + "windows/171121202507", + "windows/180122185731" ], "43f257412d440d627476974f877da8f1fc2444565a367ae60eddc27a412531ae": [ "macos/10.10.0", @@ -5451,6 +5750,9 @@ "macos/10.12.1", "macos/10.12.2", "macos/10.13.0", + "macos/10.13.1", + "macos/10.13.2", + "macos/10.13.3", "macos/10.9.0", "macos/10.9.2", "macos/10.9.4", @@ -5572,11 +5874,13 @@ "44b545aa8a25e65a73ca15dc27fc36d24c1cb9953a066539b11582dc487b4833": [ "android/nougat-mr1-cts-release", "android/oreo-cts-release", + "android/oreo-mr1-cts-release", "mozilla/2.10", "mozilla/2.11", "mozilla/2.14", "mozilla/2.16", "mozilla/2.18", + "mozilla/2.20", "mozilla/2.9", "windows/151119231843", "windows/160113232859", @@ -5589,7 +5893,8 @@ "windows/170419224008", "windows/170613190204", "windows/170922155710", - "windows/171121202507" + "windows/171121202507", + "windows/180122185731" ], "45140b3247eb9cc8c5b4f0d7b53091f73292089e6e5a63e2749dd3aca9198eda": [ "android/kitkat-cts-release", @@ -5604,6 +5909,7 @@ "android/nougat-cts-release", "android/nougat-mr1-cts-release", "android/oreo-cts-release", + "android/oreo-mr1-cts-release", "macos/10.10.0", "macos/10.10.3", "macos/10.10.4", @@ -5615,6 +5921,9 @@ "macos/10.12.1", "macos/10.12.2", "macos/10.13.0", + "macos/10.13.1", + "macos/10.13.2", + "macos/10.13.3", "macos/10.9.0", "macos/10.9.2", "macos/10.9.4", @@ -5624,6 +5933,7 @@ "mozilla/2.14", "mozilla/2.16", "mozilla/2.18", + "mozilla/2.20", "mozilla/2.9", "windows/100503224537", "windows/100719231554", @@ -5662,7 +5972,8 @@ "windows/170419224008", "windows/170613190204", "windows/170922155710", - "windows/171121202507" + "windows/171121202507", + "windows/180122185731" ], "46273285615d96e52da9fc2ed8c036f10af3d9f6280f8d288706c52b2011b4da": [ "windows/090501224247", @@ -5706,19 +6017,23 @@ "windows/170419224008", "windows/170613190204", "windows/170922155710", - "windows/171121202507" + "windows/171121202507", + "windows/180122185731" ], "46edc3689046d53a453fb3104ab80dcaec658b2660ea1629dd7e867990648716": [ + "android/oreo-mr1-cts-release", "mozilla/2.14", "mozilla/2.16", "mozilla/2.18", + "mozilla/2.20", "windows/160916174005", "windows/161112005943", "windows/170228174808", "windows/170419224008", "windows/170613190204", "windows/170922155710", - "windows/171121202507" + "windows/171121202507", + "windows/180122185731" ], "488e134f30c5db56b76473e608086842bf21af8ab3cd7ac67ebdf125d531834e": [ "windows/090825180842", @@ -5761,7 +6076,8 @@ "windows/170419224008", "windows/170613190204", "windows/170922155710", - "windows/171121202507" + "windows/171121202507", + "windows/180122185731" ], "488fca189eaadf54a3f920ed39e587183ba512232999fae3e4a285fe98e298d1": [ "windows/150122021939", @@ -5829,11 +6145,13 @@ "android/nougat-cts-release", "android/nougat-mr1-cts-release", "android/oreo-cts-release", + "android/oreo-mr1-cts-release", "mozilla/2.10", "mozilla/2.11", "mozilla/2.14", "mozilla/2.16", "mozilla/2.18", + "mozilla/2.20", "mozilla/2.9", "windows/140912180251", "windows/150122021939", @@ -5853,7 +6171,8 @@ "windows/170419224008", "windows/170613190204", "windows/170922155710", - "windows/171121202507" + "windows/171121202507", + "windows/180122185731" ], "49c8175a9815e08bef129a929de1bacad04e4db67a8c839293953e5031c81ca0": [ "windows/070109202240", @@ -5906,6 +6225,7 @@ "android/nougat-cts-release", "android/nougat-mr1-cts-release", "android/oreo-cts-release", + "android/oreo-mr1-cts-release", "macos/10.10.0", "macos/10.10.3", "macos/10.10.4", @@ -5917,6 +6237,9 @@ "macos/10.12.1", "macos/10.12.2", "macos/10.13.0", + "macos/10.13.1", + "macos/10.13.2", + "macos/10.13.3", "macos/10.9.2", "macos/10.9.4", "macos/10.9.5", @@ -5925,6 +6248,7 @@ "mozilla/2.14", "mozilla/2.16", "mozilla/2.18", + "mozilla/2.20", "mozilla/2.9", "windows/120223022238", "windows/120406192127", @@ -5952,7 +6276,8 @@ "windows/170419224008", "windows/170613190204", "windows/170922155710", - "windows/171121202507" + "windows/171121202507", + "windows/180122185731" ], "49f74f824f2e059fe99c98af3219ec0d9a004d1b64dd2fd1452616318ab806c0": [ "windows/070109202240", @@ -6005,6 +6330,7 @@ "android/nougat-cts-release", "android/nougat-mr1-cts-release", "android/oreo-cts-release", + "android/oreo-mr1-cts-release", "macos/10.10.0", "macos/10.10.3", "macos/10.10.4", @@ -6016,6 +6342,9 @@ "macos/10.12.1", "macos/10.12.2", "macos/10.13.0", + "macos/10.13.1", + "macos/10.13.2", + "macos/10.13.3", "macos/10.9.2", "macos/10.9.4", "macos/10.9.5", @@ -6024,6 +6353,7 @@ "mozilla/2.14", "mozilla/2.16", "mozilla/2.18", + "mozilla/2.20", "mozilla/2.9", "windows/090825180842", "windows/091013033632", @@ -6065,7 +6395,8 @@ "windows/170419224008", "windows/170613190204", "windows/170922155710", - "windows/171121202507" + "windows/171121202507", + "windows/180122185731" ], "4b22d5a6aec99f3cdb79aa5ec06838479cd5ecba7164f7f22dc1d65f63d85708": [ "android/lollipop-cts-release", @@ -6100,7 +6431,8 @@ "windows/170419224008", "windows/170613190204", "windows/170922155710", - "windows/171121202507" + "windows/171121202507", + "windows/180122185731" ], "4bdb7418bdf7ffe33ba0884afa7c0c61fd85a153972f65f7d01cb3ec7eb4073c": [ "windows/070109202240", @@ -6170,7 +6502,8 @@ "windows/170419224008", "windows/170613190204", "windows/170922155710", - "windows/171121202507" + "windows/171121202507", + "windows/180122185731" ], "4d2491414cfe956746ec4cefa6cf6f72e28a1329432f9d8a907ac4cb5dadc15a": [ "android/marshmallow-cts-release", @@ -6180,6 +6513,7 @@ "android/nougat-cts-release", "android/nougat-mr1-cts-release", "android/oreo-cts-release", + "android/oreo-mr1-cts-release", "macos/10.10.0", "macos/10.10.3", "macos/10.10.4", @@ -6191,6 +6525,9 @@ "macos/10.12.1", "macos/10.12.2", "macos/10.13.0", + "macos/10.13.1", + "macos/10.13.2", + "macos/10.13.3", "macos/10.9.4", "macos/10.9.5", "mozilla/2.10", @@ -6198,6 +6535,7 @@ "mozilla/2.14", "mozilla/2.16", "mozilla/2.18", + "mozilla/2.20", "mozilla/2.9", "windows/140912180251", "windows/150122021939", @@ -6217,7 +6555,8 @@ "windows/170419224008", "windows/170613190204", "windows/170922155710", - "windows/171121202507" + "windows/171121202507", + "windows/180122185731" ], "4d9ebb28825c9643ab15d54e5f9614f13cb3e95de3cf4eac971301f320f9226e": [ "windows/090825180842", @@ -6260,7 +6599,8 @@ "windows/170419224008", "windows/170613190204", "windows/170922155710", - "windows/171121202507" + "windows/171121202507", + "windows/180122185731" ], "4dbb0157a691fa7382289d65c0332ddb1dcb640b40ad10f010a43e20f3afed1e": [ "windows/070109202240", @@ -6347,14 +6687,19 @@ "android/nougat-cts-release", "android/nougat-mr1-cts-release", "android/oreo-cts-release", + "android/oreo-mr1-cts-release", "macos/10.12.1", "macos/10.12.2", "macos/10.13.0", + "macos/10.13.1", + "macos/10.13.2", + "macos/10.13.3", "mozilla/2.10", "mozilla/2.11", "mozilla/2.14", "mozilla/2.16", "mozilla/2.18", + "mozilla/2.20", "mozilla/2.9", "windows/100927165108", "windows/110125205412", @@ -6391,7 +6736,8 @@ "windows/170419224008", "windows/170613190204", "windows/170922155710", - "windows/171121202507" + "windows/171121202507", + "windows/180122185731" ], "507941c74460a0b47086220d4e9932572ab5d1b5bbcb8980ab1cb17651a844d2": [ "android/kitkat-cts-release", @@ -6414,6 +6760,9 @@ "macos/10.12.1", "macos/10.12.2", "macos/10.13.0", + "macos/10.13.1", + "macos/10.13.2", + "macos/10.13.3", "macos/10.9.2", "macos/10.9.4", "macos/10.9.5", @@ -6469,7 +6818,8 @@ "windows/170419224008", "windows/170613190204", "windows/170922155710", - "windows/171121202507" + "windows/171121202507", + "windows/180122185731" ], "513b2cecb810d4cde5dd85391adfc6c2dd60d87bb736d2b521484aa47a0ebef6": [ "android/kitkat-cts-release", @@ -6484,6 +6834,7 @@ "android/nougat-cts-release", "android/nougat-mr1-cts-release", "android/oreo-cts-release", + "android/oreo-mr1-cts-release", "macos/10.10.0", "macos/10.10.3", "macos/10.10.4", @@ -6495,6 +6846,9 @@ "macos/10.12.1", "macos/10.12.2", "macos/10.13.0", + "macos/10.13.1", + "macos/10.13.2", + "macos/10.13.3", "macos/10.9.0", "macos/10.9.2", "macos/10.9.4", @@ -6504,6 +6858,7 @@ "mozilla/2.14", "mozilla/2.16", "mozilla/2.18", + "mozilla/2.20", "mozilla/2.9", "windows/091029013045", "windows/100503224537", @@ -6543,7 +6898,8 @@ "windows/170419224008", "windows/170613190204", "windows/170922155710", - "windows/171121202507" + "windows/171121202507", + "windows/180122185731" ], "51847c8cbd2e9a72c91e292d2ae247d7de1e3fd270547a20ef7d610f38b8842c": [ "macos/10.10.0", @@ -6649,14 +7005,19 @@ "android/nougat-cts-release", "android/nougat-mr1-cts-release", "android/oreo-cts-release", + "android/oreo-mr1-cts-release", "macos/10.12.1", "macos/10.12.2", "macos/10.13.0", + "macos/10.13.1", + "macos/10.13.2", + "macos/10.13.3", "mozilla/2.10", "mozilla/2.11", "mozilla/2.14", "mozilla/2.16", "mozilla/2.18", + "mozilla/2.20", "mozilla/2.9", "windows/100927165108", "windows/110125205412", @@ -6693,7 +7054,8 @@ "windows/170419224008", "windows/170613190204", "windows/170922155710", - "windows/171121202507" + "windows/171121202507", + "windows/180122185731" ], "53dfdfa4e297fcfe07594e8c62d5b8ab06b32c7549f38a163094fd6429d5da43": [ "macos/10.10.0", @@ -6707,6 +7069,9 @@ "macos/10.12.1", "macos/10.12.2", "macos/10.13.0", + "macos/10.13.1", + "macos/10.13.2", + "macos/10.13.3", "macos/10.9.2", "macos/10.9.4", "macos/10.9.5", @@ -6731,21 +7096,25 @@ "windows/170419224008", "windows/170613190204", "windows/170922155710", - "windows/171121202507" + "windows/171121202507", + "windows/180122185731" ], "54455f7129c20b1447c418f997168f24c58fc5023bf5da5be2eb6e1dd8902ed5": [ "android/oreo-cts-release", + "android/oreo-mr1-cts-release", "mozilla/2.11", "mozilla/2.14", "mozilla/2.16", "mozilla/2.18", + "mozilla/2.20", "windows/160916174005", "windows/161112005943", "windows/170228174808", "windows/170419224008", "windows/170613190204", "windows/170922155710", - "windows/171121202507" + "windows/171121202507", + "windows/180122185731" ], "54ae8a683fe2d78ff1ef0e0b3f58425092953ba08c67fe4a95595d1cebcdcb30": [ "windows/140912180251", @@ -6764,7 +7133,8 @@ "windows/170419224008", "windows/170613190204", "windows/170922155710", - "windows/171121202507" + "windows/171121202507", + "windows/180122185731" ], "54b4fc43d44aa4ca9fc03ca7e9949fbae267a064d02da21852412a381b5d1537": [ "windows/140912180251", @@ -6785,7 +7155,8 @@ "windows/170419224008", "windows/170613190204", "windows/170922155710", - "windows/171121202507" + "windows/171121202507", + "windows/180122185731" ], "552f7bdcf1a7af9e6ce672017f4f12abf77240c78e761ac203d1d9d20ac89988": [ "android/lollipop-cts-release", @@ -6797,6 +7168,7 @@ "android/nougat-cts-release", "android/nougat-mr1-cts-release", "android/oreo-cts-release", + "android/oreo-mr1-cts-release", "macos/10.10.0", "macos/10.10.3", "macos/10.10.4", @@ -6808,6 +7180,9 @@ "macos/10.12.1", "macos/10.12.2", "macos/10.13.0", + "macos/10.13.1", + "macos/10.13.2", + "macos/10.13.3", "macos/10.9.2", "macos/10.9.4", "macos/10.9.5", @@ -6816,6 +7191,7 @@ "mozilla/2.14", "mozilla/2.16", "mozilla/2.18", + "mozilla/2.20", "mozilla/2.9", "windows/131003230417", "windows/140312052931", @@ -6837,7 +7213,8 @@ "windows/170419224008", "windows/170613190204", "windows/170922155710", - "windows/171121202507" + "windows/171121202507", + "windows/180122185731" ], "5533a0401f612c688ebce5bf53f2ec14a734eb178bfae00e50e85dae6723078a": [ "windows/131003230417", @@ -6860,7 +7237,8 @@ "windows/170419224008", "windows/170613190204", "windows/170922155710", - "windows/171121202507" + "windows/171121202507", + "windows/180122185731" ], "55926084ec963a64b96e2abe01ce0ba86a64fbfebcc7aab5afc155b37fd76066": [ "android/kitkat-cts-release", @@ -6874,6 +7252,7 @@ "android/nougat-cts-release", "android/nougat-mr1-cts-release", "android/oreo-cts-release", + "android/oreo-mr1-cts-release", "macos/10.10.0", "macos/10.10.3", "macos/10.10.4", @@ -6885,6 +7264,9 @@ "macos/10.12.1", "macos/10.12.2", "macos/10.13.0", + "macos/10.13.1", + "macos/10.13.2", + "macos/10.13.3", "macos/10.9.2", "macos/10.9.4", "macos/10.9.5", @@ -6893,6 +7275,7 @@ "mozilla/2.14", "mozilla/2.16", "mozilla/2.18", + "mozilla/2.20", "mozilla/2.9", "windows/111018233154", "windows/120125230451", @@ -6922,7 +7305,8 @@ "windows/170419224008", "windows/170613190204", "windows/170922155710", - "windows/171121202507" + "windows/171121202507", + "windows/180122185731" ], "5607e260163f49c8ea4175a1c0a53b13195cb7d07845611e943a2ff507036834": [ "windows/070522004642", @@ -6975,7 +7359,8 @@ "windows/170419224008", "windows/170613190204", "windows/170922155710", - "windows/171121202507" + "windows/171121202507", + "windows/180122185731" ], "568d6905a2c88708a4b3025190edcfedb1974a606a13c6e5290fcb2ae63edab5": [ "android/kitkat-cts-release", @@ -6990,6 +7375,7 @@ "android/nougat-cts-release", "android/nougat-mr1-cts-release", "android/oreo-cts-release", + "android/oreo-mr1-cts-release", "macos/10.10.0", "macos/10.10.3", "macos/10.10.4", @@ -7001,6 +7387,9 @@ "macos/10.12.1", "macos/10.12.2", "macos/10.13.0", + "macos/10.13.1", + "macos/10.13.2", + "macos/10.13.3", "macos/10.9.0", "macos/10.9.2", "macos/10.9.4", @@ -7010,6 +7399,7 @@ "mozilla/2.14", "mozilla/2.16", "mozilla/2.18", + "mozilla/2.20", "mozilla/2.9", "windows/100503224537", "windows/100719231554", @@ -7048,16 +7438,22 @@ "windows/170419224008", "windows/170613190204", "windows/170922155710", - "windows/171121202507" + "windows/171121202507", + "windows/180122185731" ], "56c77128d98c18d91b4cfdffbc25ee9103d4758ea2abad826a90f3457d460eb4": [ "android/nougat-mr1-cts-release", "android/oreo-cts-release", + "android/oreo-mr1-cts-release", + "macos/10.13.1", + "macos/10.13.2", + "macos/10.13.3", "mozilla/2.10", "mozilla/2.11", "mozilla/2.14", "mozilla/2.16", "mozilla/2.18", + "mozilla/2.20", "mozilla/2.9", "windows/150618202535", "windows/150723231635", @@ -7073,7 +7469,8 @@ "windows/170419224008", "windows/170613190204", "windows/170922155710", - "windows/171121202507" + "windows/171121202507", + "windows/180122185731" ], "56ce347cc6df4c35943dfdeaee023f9739a3f1cedeee0cd88dc2386bc8a91eaf": [ "windows/070109202240", @@ -7187,6 +7584,7 @@ "android/nougat-cts-release", "android/nougat-mr1-cts-release", "android/oreo-cts-release", + "android/oreo-mr1-cts-release", "macos/10.10.0", "macos/10.10.3", "macos/10.10.4", @@ -7198,6 +7596,9 @@ "macos/10.12.1", "macos/10.12.2", "macos/10.13.0", + "macos/10.13.1", + "macos/10.13.2", + "macos/10.13.3", "macos/10.9.2", "macos/10.9.4", "macos/10.9.5", @@ -7206,6 +7607,7 @@ "mozilla/2.14", "mozilla/2.16", "mozilla/2.18", + "mozilla/2.20", "mozilla/2.9", "windows/140912180251", "windows/150122021939", @@ -7225,7 +7627,8 @@ "windows/170419224008", "windows/170613190204", "windows/170922155710", - "windows/171121202507" + "windows/171121202507", + "windows/180122185731" ], "59b3829f1ff443344958fae8bff621b684c848cfbf7ead6b63a6ca50f2794f89": [ "macos/10.11.0", @@ -7236,6 +7639,9 @@ "macos/10.12.1", "macos/10.12.2", "macos/10.13.0", + "macos/10.13.1", + "macos/10.13.2", + "macos/10.13.3", "windows/100927165108", "windows/110125205412", "windows/110218005058", @@ -7271,7 +7677,8 @@ "windows/170419224008", "windows/170613190204", "windows/170922155710", - "windows/171121202507" + "windows/171121202507", + "windows/180122185731" ], "5a1b5d6bc65523b40a6deffa45b48e4288ae8dd86dd70a5b858d4a5affc94f71": [ "windows/071219233937", @@ -7321,10 +7728,12 @@ "windows/170419224008", "windows/170613190204", "windows/170922155710", - "windows/171121202507" + "windows/171121202507", + "windows/180122185731" ], "5a885db19c01d912c5759388938cafbbdf031ab2d48e91ee15589b42971d039c": [ "mozilla/2.18", + "mozilla/2.20", "windows/160414222039", "windows/160916174005", "windows/161112005943", @@ -7332,7 +7741,8 @@ "windows/170419224008", "windows/170613190204", "windows/170922155710", - "windows/171121202507" + "windows/171121202507", + "windows/180122185731" ], "5adfa25013bed3710831572de51c4b9a21171c00313249c4cb4719d37fbb8d20": [ "windows/160916174005", @@ -7341,7 +7751,8 @@ "windows/170419224008", "windows/170613190204", "windows/170922155710", - "windows/171121202507" + "windows/171121202507", + "windows/180122185731" ], "5b1d9d24de0afea8b35ba04a1c3e25d0812cdf7c4625de0a89af9fe4bbd1bb15": [ "windows/110919210309", @@ -7373,7 +7784,8 @@ "windows/170419224008", "windows/170613190204", "windows/170922155710", - "windows/171121202507" + "windows/171121202507", + "windows/180122185731" ], "5b38bd129e83d5a0cad23921089490d50d4aae370428f8ddfffffa4c1564e184": [ "macos/10.10.0", @@ -7397,6 +7809,7 @@ "android/nougat-cts-release", "android/nougat-mr1-cts-release", "android/oreo-cts-release", + "android/oreo-mr1-cts-release", "macos/10.10.0", "macos/10.10.3", "macos/10.10.4", @@ -7408,6 +7821,9 @@ "macos/10.12.1", "macos/10.12.2", "macos/10.13.0", + "macos/10.13.1", + "macos/10.13.2", + "macos/10.13.3", "macos/10.9.0", "macos/10.9.2", "macos/10.9.4", @@ -7417,6 +7833,7 @@ "mozilla/2.14", "mozilla/2.16", "mozilla/2.18", + "mozilla/2.20", "mozilla/2.9", "windows/090501224247", "windows/090825180842", @@ -7459,7 +7876,8 @@ "windows/170419224008", "windows/170613190204", "windows/170922155710", - "windows/171121202507" + "windows/171121202507", + "windows/180122185731" ], "5cc3d78e4e1d5e45547a04e6873e64f90cf9536d1ccc2ef800f355c4c5fd70fd": [ "android/marshmallow-cts-release", @@ -7469,14 +7887,19 @@ "android/nougat-cts-release", "android/nougat-mr1-cts-release", "android/oreo-cts-release", + "android/oreo-mr1-cts-release", "macos/10.12.1", "macos/10.12.2", "macos/10.13.0", + "macos/10.13.1", + "macos/10.13.2", + "macos/10.13.3", "mozilla/2.10", "mozilla/2.11", "mozilla/2.14", "mozilla/2.16", "mozilla/2.18", + "mozilla/2.20", "mozilla/2.9", "windows/130420010442", "windows/130626232015", @@ -7500,7 +7923,8 @@ "windows/170419224008", "windows/170613190204", "windows/170922155710", - "windows/171121202507" + "windows/171121202507", + "windows/180122185731" ], "5d56499be4d2e08bcfcad08a3e38723d50503bde706948e42f55603019e528ae": [ "android/marshmallow-cts-release", @@ -7510,6 +7934,7 @@ "android/nougat-cts-release", "android/nougat-mr1-cts-release", "android/oreo-cts-release", + "android/oreo-mr1-cts-release", "macos/10.10.3", "macos/10.10.4", "macos/10.11.0", @@ -7520,11 +7945,15 @@ "macos/10.12.1", "macos/10.12.2", "macos/10.13.0", + "macos/10.13.1", + "macos/10.13.2", + "macos/10.13.3", "mozilla/2.10", "mozilla/2.11", "mozilla/2.14", "mozilla/2.16", "mozilla/2.18", + "mozilla/2.20", "mozilla/2.9", "windows/140912180251", "windows/150122021939", @@ -7544,7 +7973,8 @@ "windows/170419224008", "windows/170613190204", "windows/170922155710", - "windows/171121202507" + "windows/171121202507", + "windows/180122185731" ], "5e3571f33f45a7df1537a68b5ffb9e036af9d2f5bc4c9717130dc43d7175aac7": [ "windows/070201011524", @@ -7597,7 +8027,8 @@ "windows/170419224008", "windows/170613190204", "windows/170922155710", - "windows/171121202507" + "windows/171121202507", + "windows/180122185731" ], "5edb7ac43b82a06a8761e8d7be4979ebf2611f7dd79bf91c1c6b566a219ed766": [ "android/kitkat-cts-release", @@ -7612,6 +8043,7 @@ "android/nougat-cts-release", "android/nougat-mr1-cts-release", "android/oreo-cts-release", + "android/oreo-mr1-cts-release", "macos/10.10.0", "macos/10.10.3", "macos/10.10.4", @@ -7623,6 +8055,9 @@ "macos/10.12.1", "macos/10.12.2", "macos/10.13.0", + "macos/10.13.1", + "macos/10.13.2", + "macos/10.13.3", "macos/10.9.2", "macos/10.9.4", "macos/10.9.5", @@ -7631,6 +8066,7 @@ "mozilla/2.14", "mozilla/2.16", "mozilla/2.18", + "mozilla/2.20", "mozilla/2.9", "windows/090825180842", "windows/091013033632", @@ -7672,7 +8108,8 @@ "windows/170419224008", "windows/170613190204", "windows/170922155710", - "windows/171121202507" + "windows/171121202507", + "windows/180122185731" ], "5f0b62eab5e353ea6521651658fbb65359f443280a4afbd104d77d10f9f04c07": [ "android/kitkat-cts-release", @@ -7737,7 +8174,8 @@ "windows/170419224008", "windows/170613190204", "windows/170922155710", - "windows/171121202507" + "windows/171121202507", + "windows/180122185731" ], "5f960eebd716dbcb4d8a78b996e680ec2547441e69b4e44e98a595502e28a002": [ "android/kitkat-mr1-release", @@ -7793,7 +8231,8 @@ "windows/170419224008", "windows/170613190204", "windows/170922155710", - "windows/171121202507" + "windows/171121202507", + "windows/180122185731" ], "604d32d036895aed3bfefaeb727c009ec0f2b3cdfa42a1c71730e6a72c3be9d4": [ "windows/150618202535", @@ -7810,7 +8249,8 @@ "windows/170419224008", "windows/170613190204", "windows/170922155710", - "windows/171121202507" + "windows/171121202507", + "windows/180122185731" ], "606223d9db80df3939601e74b7e828e2800cce4273f76f276aa62db0a8e3b6c1": [ "windows/071219233937", @@ -7980,7 +8420,8 @@ "windows/170419224008", "windows/170613190204", "windows/170922155710", - "windows/171121202507" + "windows/171121202507", + "windows/180122185731" ], "62dd0be9b9f50a163ea0f8e75c053b1eca57ea55c8688f647c6881f2c8357b95": [ "android/kitkat-cts-release", @@ -7995,6 +8436,7 @@ "android/nougat-cts-release", "android/nougat-mr1-cts-release", "android/oreo-cts-release", + "android/oreo-mr1-cts-release", "macos/10.10.0", "macos/10.10.3", "macos/10.10.4", @@ -8006,6 +8448,9 @@ "macos/10.12.1", "macos/10.12.2", "macos/10.13.0", + "macos/10.13.1", + "macos/10.13.2", + "macos/10.13.3", "macos/10.9.0", "macos/10.9.2", "macos/10.9.4", @@ -8015,6 +8460,7 @@ "mozilla/2.14", "mozilla/2.16", "mozilla/2.18", + "mozilla/2.20", "mozilla/2.9", "windows/070201011524", "windows/070522004642", @@ -8067,7 +8513,8 @@ "windows/170419224008", "windows/170613190204", "windows/170922155710", - "windows/171121202507" + "windows/171121202507", + "windows/180122185731" ], "62f240278c564c4dd8bf7d9d4f6f366ea894d22f5f34d989a983acec2fffed50": [ "android/kitkat-cts-release", @@ -8205,7 +8652,8 @@ "windows/170419224008", "windows/170613190204", "windows/170922155710", - "windows/171121202507" + "windows/171121202507", + "windows/180122185731" ], "63343abfb89a6a03ebb57e9b3f5fa7be7c4f5c756f3017b3a8c488c3653e9179": [ "macos/10.10.0", @@ -8219,6 +8667,9 @@ "macos/10.12.1", "macos/10.12.2", "macos/10.13.0", + "macos/10.13.1", + "macos/10.13.2", + "macos/10.13.3", "macos/10.9.4", "macos/10.9.5" ], @@ -8249,7 +8700,11 @@ ], "65353833cf234c79562164f90849c0d104dbabf8ee41064d83e8cbe03ba1c5a5": [ "windows/170922155710", - "windows/171121202507" + "windows/171121202507", + "windows/180122185731" + ], + "657cfe2fa73faa38462571f332a2363a46fce7020951710702cdfbb6eeda3305": [ + "windows/180122185731" ], "6639d13cab85df1ad9a23c443b3a60901e2b138d456fa71183578108884ec6bf": [ "macos/10.10.0", @@ -8263,6 +8718,9 @@ "macos/10.12.1", "macos/10.12.2", "macos/10.13.0", + "macos/10.13.1", + "macos/10.13.2", + "macos/10.13.3", "macos/10.9.0", "macos/10.9.2", "macos/10.9.4", @@ -8281,6 +8739,7 @@ "android/nougat-cts-release", "android/nougat-mr1-cts-release", "android/oreo-cts-release", + "android/oreo-mr1-cts-release", "macos/10.10.0", "macos/10.10.3", "macos/10.10.4", @@ -8292,6 +8751,9 @@ "macos/10.12.1", "macos/10.12.2", "macos/10.13.0", + "macos/10.13.1", + "macos/10.13.2", + "macos/10.13.3", "macos/10.9.0", "macos/10.9.2", "macos/10.9.4", @@ -8301,6 +8763,7 @@ "mozilla/2.14", "mozilla/2.16", "mozilla/2.18", + "mozilla/2.20", "mozilla/2.9", "windows/090203164005", "windows/090501224247", @@ -8344,7 +8807,8 @@ "windows/170419224008", "windows/170613190204", "windows/170922155710", - "windows/171121202507" + "windows/171121202507", + "windows/180122185731" ], "67ec2059fbf52d2e6ab51a5a9b3fc2e1dcd658a1ef3a8f31107bc98028b494a2": [ "windows/070109202240", @@ -8473,6 +8937,7 @@ "android/nougat-cts-release", "android/nougat-mr1-cts-release", "android/oreo-cts-release", + "android/oreo-mr1-cts-release", "macos/10.10.0", "macos/10.10.3", "macos/10.10.4", @@ -8484,6 +8949,9 @@ "macos/10.12.1", "macos/10.12.2", "macos/10.13.0", + "macos/10.13.1", + "macos/10.13.2", + "macos/10.13.3", "macos/10.9.0", "macos/10.9.2", "macos/10.9.4", @@ -8493,6 +8961,7 @@ "mozilla/2.14", "mozilla/2.16", "mozilla/2.18", + "mozilla/2.20", "mozilla/2.9", "windows/090825180842", "windows/091013033632", @@ -8534,7 +9003,8 @@ "windows/170419224008", "windows/170613190204", "windows/170922155710", - "windows/171121202507" + "windows/171121202507", + "windows/180122185731" ], "68ad50909b04363c605ef13581a939ff2c96372e3f12325b0a6861e1d59f6603": [ "windows/100927165108", @@ -8572,7 +9042,8 @@ "windows/170419224008", "windows/170613190204", "windows/170922155710", - "windows/171121202507" + "windows/171121202507", + "windows/180122185731" ], "69ddd7ea90bb57c93e135dc85ea6fcd5480b603239bdc454fc758b2a26cf7f79": [ "android/kitkat-cts-release", @@ -8587,6 +9058,7 @@ "android/nougat-cts-release", "android/nougat-mr1-cts-release", "android/oreo-cts-release", + "android/oreo-mr1-cts-release", "macos/10.10.0", "macos/10.10.3", "macos/10.10.4", @@ -8598,6 +9070,9 @@ "macos/10.12.1", "macos/10.12.2", "macos/10.13.0", + "macos/10.13.1", + "macos/10.13.2", + "macos/10.13.3", "macos/10.9.2", "macos/10.9.4", "macos/10.9.5", @@ -8606,6 +9081,7 @@ "mozilla/2.14", "mozilla/2.16", "mozilla/2.18", + "mozilla/2.20", "mozilla/2.9", "windows/090825180842", "windows/091013033632", @@ -8647,7 +9123,8 @@ "windows/170419224008", "windows/170613190204", "windows/170922155710", - "windows/171121202507" + "windows/171121202507", + "windows/180122185731" ], "69fac9bd55fb0ac78d53bbee5cf1d597989fd0aaab20a25151bdf1733ee7d122": [ "android/kitkat-cts-release", @@ -8662,6 +9139,7 @@ "android/nougat-cts-release", "android/nougat-mr1-cts-release", "android/oreo-cts-release", + "android/oreo-mr1-cts-release", "macos/10.10.0", "macos/10.10.3", "macos/10.10.4", @@ -8673,6 +9151,9 @@ "macos/10.12.1", "macos/10.12.2", "macos/10.13.0", + "macos/10.13.1", + "macos/10.13.2", + "macos/10.13.3", "macos/10.9.0", "macos/10.9.2", "macos/10.9.4", @@ -8682,6 +9163,7 @@ "mozilla/2.14", "mozilla/2.16", "mozilla/2.18", + "mozilla/2.20", "mozilla/2.9", "windows/070109202240", "windows/070201011524", @@ -8735,22 +9217,28 @@ "windows/170419224008", "windows/170613190204", "windows/170922155710", - "windows/171121202507" + "windows/171121202507", + "windows/180122185731" ], "6b9c08e86eb0f767cfad65cd98b62149e5494a67f5845e7bd1ed019f27b86bd6": [ "android/nougat-cts-release", "android/nougat-mr1-cts-release", "android/oreo-cts-release", + "android/oreo-mr1-cts-release", "macos/10.11.4", "macos/10.12.0", "macos/10.12.1", "macos/10.12.2", "macos/10.13.0", + "macos/10.13.1", + "macos/10.13.2", + "macos/10.13.3", "mozilla/2.10", "mozilla/2.11", "mozilla/2.14", "mozilla/2.16", "mozilla/2.18", + "mozilla/2.20", "mozilla/2.9", "windows/160113232859", "windows/160123000836", @@ -8762,7 +9250,8 @@ "windows/170419224008", "windows/170613190204", "windows/170922155710", - "windows/171121202507" + "windows/171121202507", + "windows/180122185731" ], "6baf50ae3467eff3c35fefdc76a02a97fab6267723eda91e99f1b3dc2b28f82e": [ "windows/090825180842", @@ -8805,7 +9294,8 @@ "windows/170419224008", "windows/170613190204", "windows/170922155710", - "windows/171121202507" + "windows/171121202507", + "windows/180122185731" ], "6c61dac3a2def031506be036d2a6fe401994fbd13df9c8d466599274c446ec98": [ "android/kitkat-cts-release", @@ -8820,6 +9310,7 @@ "android/nougat-cts-release", "android/nougat-mr1-cts-release", "android/oreo-cts-release", + "android/oreo-mr1-cts-release", "macos/10.10.0", "macos/10.10.3", "macos/10.10.4", @@ -8831,6 +9322,9 @@ "macos/10.12.1", "macos/10.12.2", "macos/10.13.0", + "macos/10.13.1", + "macos/10.13.2", + "macos/10.13.3", "macos/10.9.0", "macos/10.9.2", "macos/10.9.4", @@ -8840,6 +9334,7 @@ "mozilla/2.14", "mozilla/2.16", "mozilla/2.18", + "mozilla/2.20", "mozilla/2.9", "windows/090203164005", "windows/090501224247", @@ -8883,16 +9378,22 @@ "windows/170419224008", "windows/170613190204", "windows/170922155710", - "windows/171121202507" + "windows/171121202507", + "windows/180122185731" ], "6cc05041e6445e74696c4cfbc9f80f543b7eabbb44b4ce6f787c6a9971c42f17": [ "android/nougat-mr1-cts-release", "android/oreo-cts-release", + "android/oreo-mr1-cts-release", + "macos/10.13.1", + "macos/10.13.2", + "macos/10.13.3", "mozilla/2.10", "mozilla/2.11", "mozilla/2.14", "mozilla/2.16", "mozilla/2.18", + "mozilla/2.20", "mozilla/2.9", "windows/150618202535", "windows/150723231635", @@ -8908,7 +9409,8 @@ "windows/170419224008", "windows/170613190204", "windows/170922155710", - "windows/171121202507" + "windows/171121202507", + "windows/180122185731" ], "6ccfd302fc44bf4599329b9750878ea44e7e8566564bcbd586169762dd10c74e": [ "windows/130626232015", @@ -8932,7 +9434,8 @@ "windows/170419224008", "windows/170613190204", "windows/170922155710", - "windows/171121202507" + "windows/171121202507", + "windows/180122185731" ], "6cf5f658436d10507eba9df463987480bc8560a8e26ef4691e1d3c9a878a0952": [ "macos/10.10.0", @@ -8964,6 +9467,7 @@ "android/nougat-cts-release", "android/nougat-mr1-cts-release", "android/oreo-cts-release", + "android/oreo-mr1-cts-release", "macos/10.10.0", "macos/10.10.3", "macos/10.10.4", @@ -8975,6 +9479,9 @@ "macos/10.12.1", "macos/10.12.2", "macos/10.13.0", + "macos/10.13.1", + "macos/10.13.2", + "macos/10.13.3", "macos/10.9.0", "macos/10.9.2", "macos/10.9.4", @@ -8984,6 +9491,7 @@ "mozilla/2.14", "mozilla/2.16", "mozilla/2.18", + "mozilla/2.20", "mozilla/2.9", "windows/091029013045", "windows/100503224537", @@ -9023,7 +9531,8 @@ "windows/170419224008", "windows/170613190204", "windows/170922155710", - "windows/171121202507" + "windows/171121202507", + "windows/180122185731" ], "6dea86a1e66620a040c3c5943cb215d2ca87fb6ac09b59707e29d2facbd66b4e": [ "android/kitkat-mr1-release", @@ -9120,6 +9629,9 @@ "macos/10.12.1", "macos/10.12.2", "macos/10.13.0", + "macos/10.13.1", + "macos/10.13.2", + "macos/10.13.3", "macos/10.9.0", "macos/10.9.2", "macos/10.9.4", @@ -9180,7 +9692,8 @@ "windows/170419224008", "windows/170613190204", "windows/170922155710", - "windows/171121202507" + "windows/171121202507", + "windows/180122185731" ], "6ec6614e9a8efd47d6318ffdfd0bf65b493a141f77c38d0b319be1bbbc053dd2": [ "windows/110919210309", @@ -9212,7 +9725,8 @@ "windows/170419224008", "windows/170613190204", "windows/170922155710", - "windows/171121202507" + "windows/171121202507", + "windows/180122185731" ], "6f2bc4cb632c24eae6782c0f39758932d1e1dc9b3e070f9303073fff38b288e2": [ "macos/10.9.0" @@ -9232,6 +9746,9 @@ "macos/10.12.1", "macos/10.12.2", "macos/10.13.0", + "macos/10.13.1", + "macos/10.13.2", + "macos/10.13.3", "macos/10.9.0", "macos/10.9.2", "macos/10.9.4", @@ -9288,7 +9805,8 @@ "windows/170419224008", "windows/170613190204", "windows/170922155710", - "windows/171121202507" + "windows/171121202507", + "windows/180122185731" ], "6fff78e400a70c11011cd85977c459fb5af96a3df0540820d0f4b8607875e58f": [ "macos/10.10.0", @@ -9302,6 +9820,9 @@ "macos/10.12.1", "macos/10.12.2", "macos/10.13.0", + "macos/10.13.1", + "macos/10.13.2", + "macos/10.13.3", "macos/10.9.0", "macos/10.9.2", "macos/10.9.4", @@ -9320,6 +9841,7 @@ "android/nougat-cts-release", "android/nougat-mr1-cts-release", "android/oreo-cts-release", + "android/oreo-mr1-cts-release", "macos/10.10.0", "macos/10.10.3", "macos/10.10.4", @@ -9331,6 +9853,9 @@ "macos/10.12.1", "macos/10.12.2", "macos/10.13.0", + "macos/10.13.1", + "macos/10.13.2", + "macos/10.13.3", "macos/10.9.0", "macos/10.9.2", "macos/10.9.4", @@ -9340,6 +9865,7 @@ "mozilla/2.14", "mozilla/2.16", "mozilla/2.18", + "mozilla/2.20", "mozilla/2.9", "windows/100503224537", "windows/100719231554", @@ -9378,7 +9904,8 @@ "windows/170419224008", "windows/170613190204", "windows/170922155710", - "windows/171121202507" + "windows/171121202507", + "windows/180122185731" ], "70b922bfda0e3f4a342e4ee22d579ae598d071cc5ec9c30f123680340388aea5": [ "macos/10.10.0", @@ -9392,6 +9919,9 @@ "macos/10.12.1", "macos/10.12.2", "macos/10.13.0", + "macos/10.13.1", + "macos/10.13.2", + "macos/10.13.3", "macos/10.9.2", "macos/10.9.4", "macos/10.9.5", @@ -9412,11 +9942,13 @@ "windows/170419224008", "windows/170613190204", "windows/170922155710", - "windows/171121202507" + "windows/171121202507", + "windows/180122185731" ], "71cca5391f9e794b04802530b363e121da8a3043bb26662fea4dca7fc951a4bd": [ "windows/170922155710", - "windows/171121202507" + "windows/171121202507", + "windows/180122185731" ], "7286ce249fe9e32bd4752257c17cd8f6991a9c1e6f1a3cc73304ed023e6ae4eb": [ "windows/131003230417", @@ -9439,7 +9971,8 @@ "windows/170419224008", "windows/170613190204", "windows/170922155710", - "windows/171121202507" + "windows/171121202507", + "windows/180122185731" ], "730b619eaa759863c65360b7412e1457eca96844ef2f16d91fcf2efe46a647e9": [ "windows/070109202240", @@ -9525,7 +10058,8 @@ "windows/170419224008", "windows/170613190204", "windows/170922155710", - "windows/171121202507" + "windows/171121202507", + "windows/180122185731" ], "73c176434f1bc6d5adf45b0e76e727287c8de57616c1e6e6141a2b2cbc7d8e4c": [ "android/kitkat-cts-release", @@ -9540,6 +10074,7 @@ "android/nougat-cts-release", "android/nougat-mr1-cts-release", "android/oreo-cts-release", + "android/oreo-mr1-cts-release", "macos/10.10.0", "macos/10.10.3", "macos/10.10.4", @@ -9551,6 +10086,9 @@ "macos/10.12.1", "macos/10.12.2", "macos/10.13.0", + "macos/10.13.1", + "macos/10.13.2", + "macos/10.13.3", "macos/10.9.0", "macos/10.9.2", "macos/10.9.4", @@ -9560,6 +10098,7 @@ "mozilla/2.14", "mozilla/2.16", "mozilla/2.18", + "mozilla/2.20", "mozilla/2.9", "windows/070109202240", "windows/070201011524", @@ -9613,7 +10152,8 @@ "windows/170419224008", "windows/170613190204", "windows/170922155710", - "windows/171121202507" + "windows/171121202507", + "windows/180122185731" ], "7431e5f4c3c1ce4690774f0b61e05440883ba9a01ed00ba6abd7806ed3b118cf": [ "android/kitkat-cts-release", @@ -9628,6 +10168,7 @@ "android/nougat-cts-release", "android/nougat-mr1-cts-release", "android/oreo-cts-release", + "android/oreo-mr1-cts-release", "macos/10.10.0", "macos/10.10.3", "macos/10.10.4", @@ -9639,6 +10180,9 @@ "macos/10.12.1", "macos/10.12.2", "macos/10.13.0", + "macos/10.13.1", + "macos/10.13.2", + "macos/10.13.3", "macos/10.9.0", "macos/10.9.2", "macos/10.9.4", @@ -9648,6 +10192,7 @@ "mozilla/2.14", "mozilla/2.16", "mozilla/2.18", + "mozilla/2.20", "mozilla/2.9", "windows/070109202240", "windows/070201011524", @@ -9701,7 +10246,8 @@ "windows/170419224008", "windows/170613190204", "windows/170922155710", - "windows/171121202507" + "windows/171121202507", + "windows/180122185731" ], "744b1147b4a9a69c32785e9e37c3323241ef29f63e76f1603d6761a783d8a0fe": [ "windows/150122021939", @@ -9761,7 +10307,8 @@ "windows/170419224008", "windows/170613190204", "windows/170922155710", - "windows/171121202507" + "windows/171121202507", + "windows/180122185731" ], "75c9d4361cb96e993abd9620cf043be9407a4633f202f0f4c0e17851cc6089cd": [ "macos/10.10.0", @@ -9824,11 +10371,13 @@ "android/nougat-cts-release", "android/nougat-mr1-cts-release", "android/oreo-cts-release", + "android/oreo-mr1-cts-release", "mozilla/2.10", "mozilla/2.11", "mozilla/2.14", "mozilla/2.16", "mozilla/2.18", + "mozilla/2.20", "mozilla/2.9", "windows/070109202240", "windows/070201011524", @@ -9882,7 +10431,8 @@ "windows/170419224008", "windows/170613190204", "windows/170922155710", - "windows/171121202507" + "windows/171121202507", + "windows/180122185731" ], "767c955a76412c89af688e90a1c70f556cfd6b6025dbea10416d7eb6831f8c40": [ "android/kitkat-cts-release", @@ -9897,6 +10447,7 @@ "android/nougat-cts-release", "android/nougat-mr1-cts-release", "android/oreo-cts-release", + "android/oreo-mr1-cts-release", "macos/10.10.0", "macos/10.10.3", "macos/10.10.4", @@ -9908,6 +10459,9 @@ "macos/10.12.1", "macos/10.12.2", "macos/10.13.0", + "macos/10.13.1", + "macos/10.13.2", + "macos/10.13.3", "macos/10.9.0", "macos/10.9.2", "macos/10.9.4", @@ -9970,7 +10524,8 @@ "windows/170419224008", "windows/170613190204", "windows/170922155710", - "windows/171121202507" + "windows/171121202507", + "windows/180122185731" ], "76ef4762e573206006cbc338b17ca4bc200574a11928d90c3ef31c5e803e6c6f": [ "windows/070109202240", @@ -10103,7 +10658,8 @@ "windows/170419224008", "windows/170613190204", "windows/170922155710", - "windows/171121202507" + "windows/171121202507", + "windows/180122185731" ], "77e04c9a751c73f23e2a1336112ec8d5153d382a152fed89d7532c3102771f3c": [ "windows/090501224247", @@ -10147,7 +10703,8 @@ "windows/170419224008", "windows/170613190204", "windows/170922155710", - "windows/171121202507" + "windows/171121202507", + "windows/180122185731" ], "781d64dfa77b00f2c006700b1fda86bf68b865a603c7a656f92e90c042ca2873": [ "windows/080328202117", @@ -10194,7 +10751,8 @@ "windows/161112005943", "windows/170613190204", "windows/170922155710", - "windows/171121202507" + "windows/171121202507", + "windows/180122185731" ], "7908b40314c138100b518d0735807ffbfcf8518a0095337105ba386b153dd927": [ "android/kitkat-cts-release", @@ -10209,6 +10767,7 @@ "android/nougat-cts-release", "android/nougat-mr1-cts-release", "android/oreo-cts-release", + "android/oreo-mr1-cts-release", "macos/10.10.0", "macos/10.10.3", "macos/10.10.4", @@ -10220,6 +10779,9 @@ "macos/10.12.1", "macos/10.12.2", "macos/10.13.0", + "macos/10.13.1", + "macos/10.13.2", + "macos/10.13.3", "macos/10.9.0", "macos/10.9.2", "macos/10.9.4", @@ -10229,6 +10791,7 @@ "mozilla/2.14", "mozilla/2.16", "mozilla/2.18", + "mozilla/2.20", "mozilla/2.9", "windows/070109202240", "windows/070201011524", @@ -10282,7 +10845,8 @@ "windows/170419224008", "windows/170613190204", "windows/170922155710", - "windows/171121202507" + "windows/171121202507", + "windows/180122185731" ], "793cbf4559b9fde38ab22df16869f69881ae14c4b0139ac788a78a1afcca02fb": [ "android/kitkat-cts-release", @@ -10422,7 +10986,8 @@ "windows/170419224008", "windows/170613190204", "windows/170922155710", - "windows/171121202507" + "windows/171121202507", + "windows/180122185731" ], "7af6ea9f753a1e709bd64d0beb867c11e8c295a56e24a6e0471459dccdaa1558": [ "macos/10.11.0", @@ -10433,6 +10998,9 @@ "macos/10.12.1", "macos/10.12.2", "macos/10.13.0", + "macos/10.13.1", + "macos/10.13.2", + "macos/10.13.3", "windows/100927165108", "windows/110125205412", "windows/110218005058", @@ -10468,7 +11036,8 @@ "windows/170419224008", "windows/170613190204", "windows/170922155710", - "windows/171121202507" + "windows/171121202507", + "windows/180122185731" ], "7afc9d01a62f03a2de9637936d4afe68090d2de18d03f29c88cfb0b1ba63587f": [ "macos/10.10.0", @@ -10482,6 +11051,9 @@ "macos/10.12.1", "macos/10.12.2", "macos/10.13.0", + "macos/10.13.1", + "macos/10.13.2", + "macos/10.13.3", "macos/10.9.0", "macos/10.9.2", "macos/10.9.4", @@ -10594,6 +11166,7 @@ "android/nougat-cts-release", "android/nougat-mr1-cts-release", "android/oreo-cts-release", + "android/oreo-mr1-cts-release", "macos/10.10.0", "macos/10.10.3", "macos/10.10.4", @@ -10605,6 +11178,9 @@ "macos/10.12.1", "macos/10.12.2", "macos/10.13.0", + "macos/10.13.1", + "macos/10.13.2", + "macos/10.13.3", "macos/10.9.2", "macos/10.9.4", "macos/10.9.5", @@ -10613,6 +11189,7 @@ "mozilla/2.14", "mozilla/2.16", "mozilla/2.18", + "mozilla/2.20", "mozilla/2.9", "windows/131003230417", "windows/140312052931", @@ -10634,7 +11211,8 @@ "windows/170419224008", "windows/170613190204", "windows/170922155710", - "windows/171121202507" + "windows/171121202507", + "windows/180122185731" ], "7d2bf3489ebc9ad3448b8b0827715a3cbfe3d523e3b56a9b5fc1d2a2da2f20fe": [ "windows/100503224537", @@ -10674,7 +11252,8 @@ "windows/170419224008", "windows/170613190204", "windows/170922155710", - "windows/171121202507" + "windows/171121202507", + "windows/180122185731" ], "7d3b465a6014e526c0affcee2127d2311727ad811c26842d006af37306cc80bd": [ "android/kitkat-cts-release", @@ -10779,7 +11358,8 @@ "windows/170419224008", "windows/170613190204", "windows/170922155710", - "windows/171121202507" + "windows/171121202507", + "windows/180122185731" ], "7e37cb8b4c47090cab36551ba6f45db840680fba166a952db100717f43053fc2": [ "android/lollipop-cts-release", @@ -10791,6 +11371,7 @@ "android/nougat-cts-release", "android/nougat-mr1-cts-release", "android/oreo-cts-release", + "android/oreo-mr1-cts-release", "macos/10.10.0", "macos/10.10.3", "macos/10.10.4", @@ -10802,6 +11383,9 @@ "macos/10.12.1", "macos/10.12.2", "macos/10.13.0", + "macos/10.13.1", + "macos/10.13.2", + "macos/10.13.3", "macos/10.9.2", "macos/10.9.4", "macos/10.9.5", @@ -10810,6 +11394,7 @@ "mozilla/2.14", "mozilla/2.16", "mozilla/2.18", + "mozilla/2.20", "mozilla/2.9", "windows/131003230417", "windows/140312052931", @@ -10831,7 +11416,8 @@ "windows/170419224008", "windows/170613190204", "windows/170922155710", - "windows/171121202507" + "windows/171121202507", + "windows/180122185731" ], "7f12cd5f7e5e290ec7d85179d5b72c20a5be7508ffdb5bf81ab9684a7fc9f667": [ "android/kitkat-cts-release", @@ -10906,7 +11492,8 @@ "windows/170419224008", "windows/170613190204", "windows/170922155710", - "windows/171121202507" + "windows/171121202507", + "windows/180122185731" ], "8095210805db4bbc355e4428d8fd6ec2cde3ab5fb97a9942988eb8f4dcd06016": [ "android/kitkat-cts-release", @@ -10988,7 +11575,8 @@ "windows/170419224008", "windows/170613190204", "windows/170922155710", - "windows/171121202507" + "windows/171121202507", + "windows/180122185731" ], "81c2568503eb3be5eec366653960e6d1be9448915e4605b793fbeb34ccb2470f": [ "windows/120223022238", @@ -11017,7 +11605,8 @@ "windows/170419224008", "windows/170613190204", "windows/170922155710", - "windows/171121202507" + "windows/171121202507", + "windows/180122185731" ], "82d42db3d657f1944e65c192b1dd58db8df8417b89165b045f5c6a70c5f8939e": [ "windows/130626232015", @@ -11047,6 +11636,9 @@ "macos/10.12.1", "macos/10.12.2", "macos/10.13.0", + "macos/10.13.1", + "macos/10.13.2", + "macos/10.13.3", "macos/10.9.0", "macos/10.9.2", "macos/10.9.4", @@ -11094,7 +11686,8 @@ "windows/170419224008", "windows/170613190204", "windows/170922155710", - "windows/171121202507" + "windows/171121202507", + "windows/180122185731" ], "83ce3c1229688a593d485f81973c0f9195431eda37cc5e36430e79c7a888638b": [ "android/kitkat-cts-release", @@ -11159,7 +11752,8 @@ "windows/170419224008", "windows/170613190204", "windows/170922155710", - "windows/171121202507" + "windows/171121202507", + "windows/180122185731" ], "847df6a78497943f27fc72eb93f9a637320a02b561d0a91b09e87a7807ed7c61": [ "windows/110919210309", @@ -11191,20 +11785,24 @@ "windows/170419224008", "windows/170613190204", "windows/170922155710", - "windows/171121202507" + "windows/171121202507", + "windows/180122185731" ], "8560f91c3624daba9570b5fea0dbe36ff11a8323be9486854fb3f34a5571198d": [ - "windows/171121202507" + "windows/171121202507", + "windows/180122185731" ], "85666a562ee0be5ce925c1d8890a6f76a87ec16d4d7d5f29ea7419cf20123b69": [ "mozilla/2.18", + "mozilla/2.20", "windows/160916174005", "windows/161112005943", "windows/170228174808", "windows/170419224008", "windows/170613190204", "windows/170922155710", - "windows/171121202507" + "windows/171121202507", + "windows/180122185731" ], "85a0dd7dd720adb7ff05f83d542b209dc7ff4528f7d677b18389fea5e5c49e86": [ "android/kitkat-cts-release", @@ -11219,6 +11817,7 @@ "android/nougat-cts-release", "android/nougat-mr1-cts-release", "android/oreo-cts-release", + "android/oreo-mr1-cts-release", "macos/10.10.0", "macos/10.10.3", "macos/10.10.4", @@ -11230,6 +11829,9 @@ "macos/10.12.1", "macos/10.12.2", "macos/10.13.0", + "macos/10.13.1", + "macos/10.13.2", + "macos/10.13.3", "macos/10.9.0", "macos/10.9.2", "macos/10.9.4", @@ -11239,6 +11841,7 @@ "mozilla/2.14", "mozilla/2.16", "mozilla/2.18", + "mozilla/2.20", "mozilla/2.9", "windows/070109202240", "windows/070201011524", @@ -11291,7 +11894,8 @@ "windows/170419224008", "windows/170613190204", "windows/170922155710", - "windows/171121202507" + "windows/171121202507", + "windows/180122185731" ], "85e0dfae3e55a843195f8b08c8349050e4689372f6e133ad0d199af96e95cc08": [ "windows/070109202240", @@ -11352,6 +11956,9 @@ "macos/10.12.1", "macos/10.12.2", "macos/10.13.0", + "macos/10.13.1", + "macos/10.13.2", + "macos/10.13.3", "macos/10.9.0", "macos/10.9.2", "macos/10.9.4", @@ -11411,7 +12018,8 @@ "windows/170419224008", "windows/170613190204", "windows/170922155710", - "windows/171121202507" + "windows/171121202507", + "windows/180122185731" ], "87c678bfb8b25f38f7e97b336956bbcf144bbacaa53647e61a2325bc1055316b": [ "android/kitkat-cts-release", @@ -11461,11 +12069,13 @@ "android/nougat-cts-release", "android/nougat-mr1-cts-release", "android/oreo-cts-release", + "android/oreo-mr1-cts-release", "mozilla/2.10", "mozilla/2.11", "mozilla/2.14", "mozilla/2.16", "mozilla/2.18", + "mozilla/2.20", "mozilla/2.9", "windows/070109202240", "windows/070201011524", @@ -11519,7 +12129,8 @@ "windows/170419224008", "windows/170613190204", "windows/170922155710", - "windows/171121202507" + "windows/171121202507", + "windows/180122185731" ], "885de64c340e3ea70658f01e1145f957fcda27aabeea1ab9faa9fdb0102d4077": [ "windows/070109202240", @@ -11574,7 +12185,8 @@ "windows/170419224008", "windows/170613190204", "windows/170922155710", - "windows/171121202507" + "windows/171121202507", + "windows/180122185731" ], "88ef81de202eb018452e43f864725cea5fbd1fc2d9d205730709c5d8b8690f46": [ "android/lollipop-cts-release", @@ -11586,6 +12198,7 @@ "android/nougat-cts-release", "android/nougat-mr1-cts-release", "android/oreo-cts-release", + "android/oreo-mr1-cts-release", "macos/10.10.3", "macos/10.10.4", "macos/10.11.0", @@ -11596,11 +12209,15 @@ "macos/10.12.1", "macos/10.12.2", "macos/10.13.0", + "macos/10.13.1", + "macos/10.13.2", + "macos/10.13.3", "mozilla/2.10", "mozilla/2.11", "mozilla/2.14", "mozilla/2.16", "mozilla/2.18", + "mozilla/2.20", "mozilla/2.9", "windows/130626232015", "windows/131003230417", @@ -11623,7 +12240,8 @@ "windows/170419224008", "windows/170613190204", "windows/170922155710", - "windows/171121202507" + "windows/171121202507", + "windows/180122185731" ], "894ce6ddb012cb3f736954668de63f436080e95f17b7a81bd924eb21bee9e440": [ "windows/071219233937", @@ -11673,7 +12291,8 @@ "windows/170419224008", "windows/170613190204", "windows/170922155710", - "windows/171121202507" + "windows/171121202507", + "windows/180122185731" ], "894ebc0b23da2a50c0186b7f8f25ef1f6b2935af32a94584ef80aaf877a3a06e": [ "macos/10.10.0", @@ -11687,6 +12306,9 @@ "macos/10.12.1", "macos/10.12.2", "macos/10.13.0", + "macos/10.13.1", + "macos/10.13.2", + "macos/10.13.3", "macos/10.9.0", "macos/10.9.2", "macos/10.9.4", @@ -11725,7 +12347,8 @@ "windows/170419224008", "windows/170613190204", "windows/170922155710", - "windows/171121202507" + "windows/171121202507", + "windows/180122185731" ], "8a866fd1b276b57e578e921c65828a2bed58e9f2f288054134b7f1f4bfc9cc74": [ "android/lollipop-cts-release", @@ -11737,6 +12360,7 @@ "android/nougat-cts-release", "android/nougat-mr1-cts-release", "android/oreo-cts-release", + "android/oreo-mr1-cts-release", "macos/10.10.3", "macos/10.10.4", "macos/10.11.0", @@ -11747,11 +12371,15 @@ "macos/10.12.1", "macos/10.12.2", "macos/10.13.0", + "macos/10.13.1", + "macos/10.13.2", + "macos/10.13.3", "mozilla/2.10", "mozilla/2.11", "mozilla/2.14", "mozilla/2.16", "mozilla/2.18", + "mozilla/2.20", "mozilla/2.9", "windows/130626232015", "windows/131003230417", @@ -11774,7 +12402,8 @@ "windows/170419224008", "windows/170613190204", "windows/170922155710", - "windows/171121202507" + "windows/171121202507", + "windows/180122185731" ], "8a968aadd88b20519672a452a3d6e31eacb71c26bcaf65b32f9793bf2ffa54a9": [ "macos/10.10.0", @@ -11808,7 +12437,8 @@ "windows/170419224008", "windows/170613190204", "windows/170922155710", - "windows/171121202507" + "windows/171121202507", + "windows/180122185731" ], "8b45da1c06f791eb0cabf26be588f5fb23165c2e614bf885562d0dce50b29b02": [ "android/nougat-cts-release", @@ -11833,7 +12463,8 @@ "windows/170419224008", "windows/170613190204", "windows/170922155710", - "windows/171121202507" + "windows/171121202507", + "windows/180122185731" ], "8ba1bd9c88efb3947e60ebe21137f81df7f09994cef27f097055018b8194c634": [ "windows/140912180251", @@ -11852,7 +12483,8 @@ "windows/170419224008", "windows/170613190204", "windows/170922155710", - "windows/171121202507" + "windows/171121202507", + "windows/180122185731" ], "8c4edfd04348f322969e7e29a4cd4dca004655061c16e1b076422ef342ad630e": [ "android/kitkat-cts-release", @@ -11918,7 +12550,8 @@ "windows/170419224008", "windows/170613190204", "windows/170922155710", - "windows/171121202507" + "windows/171121202507", + "windows/180122185731" ], "8c7209279ac04e275e16d07fd3b775e80154b5968046e31f52dd25766324e9a7": [ "android/kitkat-cts-release", @@ -11943,6 +12576,9 @@ "macos/10.12.1", "macos/10.12.2", "macos/10.13.0", + "macos/10.13.1", + "macos/10.13.2", + "macos/10.13.3", "macos/10.9.0", "macos/10.9.2", "macos/10.9.4", @@ -11965,6 +12601,7 @@ "android/nougat-cts-release", "android/nougat-mr1-cts-release", "android/oreo-cts-release", + "android/oreo-mr1-cts-release", "macos/10.10.0", "macos/10.10.3", "macos/10.10.4", @@ -11976,6 +12613,9 @@ "macos/10.12.1", "macos/10.12.2", "macos/10.13.0", + "macos/10.13.1", + "macos/10.13.2", + "macos/10.13.3", "macos/10.9.0", "macos/10.9.2", "macos/10.9.4", @@ -11985,6 +12625,7 @@ "mozilla/2.14", "mozilla/2.16", "mozilla/2.18", + "mozilla/2.20", "mozilla/2.9", "windows/070109202240", "windows/070201011524", @@ -12038,7 +12679,8 @@ "windows/170419224008", "windows/170613190204", "windows/170922155710", - "windows/171121202507" + "windows/171121202507", + "windows/180122185731" ], "8da084fcf99ce07722f89b3205939806fa5cb811e1c813f6a108c7d336b3408e": [ "android/kitkat-cts-release", @@ -12143,7 +12785,8 @@ "windows/170419224008", "windows/170613190204", "windows/170922155710", - "windows/171121202507" + "windows/171121202507", + "windows/180122185731" ], "8dbb5a7c06c20ef62dd912a36740992ff6e1e8583d42ede257c3affd7c769399": [ "windows/070109202240", @@ -12212,7 +12855,8 @@ "windows/170419224008", "windows/170613190204", "windows/170922155710", - "windows/171121202507" + "windows/171121202507", + "windows/180122185731" ], "8e8c6ebf77dc73db3e38e93f4803e62b6b5933beb51ee4152f68d7aa14426b31": [ "windows/090825180842", @@ -12223,10 +12867,15 @@ ], "8ecde6884f3d87b1125ba31ac3fcb13d7016de7f57cc904fe1cb97c6ae98196e": [ "android/oreo-cts-release", + "android/oreo-mr1-cts-release", + "macos/10.13.1", + "macos/10.13.2", + "macos/10.13.3", "mozilla/2.11", "mozilla/2.14", "mozilla/2.16", "mozilla/2.18", + "mozilla/2.20", "windows/160113232859", "windows/160123000836", "windows/160128175153", @@ -12237,7 +12886,8 @@ "windows/170419224008", "windows/170613190204", "windows/170922155710", - "windows/171121202507" + "windows/171121202507", + "windows/180122185731" ], "8f1ecdaf29bcd56eddd6b5d56a07fcac2b74d4bcd179179144a0365c27dcf14b": [ "windows/121102212406", @@ -12318,7 +12968,8 @@ "windows/170419224008", "windows/170613190204", "windows/170922155710", - "windows/171121202507" + "windows/171121202507", + "windows/180122185731" ], "8f9e2751dcd574e9ba90e744ea92581fd0af640ae86ac1ce2198c90f96b44823": [ "windows/070109202240", @@ -12414,6 +13065,7 @@ "android/nougat-cts-release", "android/nougat-mr1-cts-release", "android/oreo-cts-release", + "android/oreo-mr1-cts-release", "macos/10.10.3", "macos/10.10.4", "macos/10.11.0", @@ -12424,11 +13076,15 @@ "macos/10.12.1", "macos/10.12.2", "macos/10.13.0", + "macos/10.13.1", + "macos/10.13.2", + "macos/10.13.3", "mozilla/2.10", "mozilla/2.11", "mozilla/2.14", "mozilla/2.16", "mozilla/2.18", + "mozilla/2.20", "mozilla/2.9", "windows/130626232015", "windows/131003230417", @@ -12448,7 +13104,8 @@ "windows/170419224008", "windows/170613190204", "windows/170922155710", - "windows/171121202507" + "windows/171121202507", + "windows/180122185731" ], "90f3e05396995ff20922c44592db62d7845e1bf64aef512cca75bc669caa2479": [ "windows/070702210503", @@ -12500,7 +13157,8 @@ "windows/170419224008", "windows/170613190204", "windows/170922155710", - "windows/171121202507" + "windows/171121202507", + "windows/180122185731" ], "9111240747e1f652f66d1f712a11f698963b491702e312f7513da3d0fc1e5a28": [ "windows/150122021939", @@ -12524,6 +13182,7 @@ "android/nougat-cts-release", "android/nougat-mr1-cts-release", "android/oreo-cts-release", + "android/oreo-mr1-cts-release", "macos/10.10.0", "macos/10.10.3", "macos/10.10.4", @@ -12535,6 +13194,9 @@ "macos/10.12.1", "macos/10.12.2", "macos/10.13.0", + "macos/10.13.1", + "macos/10.13.2", + "macos/10.13.3", "macos/10.9.2", "macos/10.9.4", "macos/10.9.5", @@ -12543,6 +13205,7 @@ "mozilla/2.14", "mozilla/2.16", "mozilla/2.18", + "mozilla/2.20", "mozilla/2.9", "windows/131003230417", "windows/140312052931", @@ -12564,7 +13227,8 @@ "windows/170419224008", "windows/170613190204", "windows/170922155710", - "windows/171121202507" + "windows/171121202507", + "windows/180122185731" ], "92a9d9833fe1944db366e8bfae7a95b6480c2d6c6c2a1be65d4236b608fca1bb": [ "macos/10.10.0", @@ -12578,6 +13242,9 @@ "macos/10.12.1", "macos/10.12.2", "macos/10.13.0", + "macos/10.13.1", + "macos/10.13.2", + "macos/10.13.3", "macos/10.9.0", "macos/10.9.2", "macos/10.9.4", @@ -12647,7 +13314,8 @@ "windows/170419224008", "windows/170613190204", "windows/170922155710", - "windows/171121202507" + "windows/171121202507", + "windows/180122185731" ], "92d8092ee77bc9208f0897dc05271894e63ef27933ae537fb983eef0eae3eec8": [ "macos/10.10.0", @@ -12661,6 +13329,9 @@ "macos/10.12.1", "macos/10.12.2", "macos/10.13.0", + "macos/10.13.1", + "macos/10.13.2", + "macos/10.13.3", "macos/10.9.2", "macos/10.9.4", "macos/10.9.5" @@ -12677,6 +13348,9 @@ "macos/10.12.1", "macos/10.12.2", "macos/10.13.0", + "macos/10.13.1", + "macos/10.13.2", + "macos/10.13.3", "macos/10.9.0", "macos/10.9.2", "macos/10.9.4", @@ -12724,7 +13398,8 @@ "windows/170419224008", "windows/170613190204", "windows/170922155710", - "windows/171121202507" + "windows/171121202507", + "windows/180122185731" ], "940ef46536713d8e2eb4b501e80b6abd8eb4e9928dba44784ce7d7e98595dfe8": [ "macos/10.9.0" @@ -12780,7 +13455,8 @@ "windows/170419224008", "windows/170613190204", "windows/170922155710", - "windows/171121202507" + "windows/171121202507", + "windows/180122185731" ], "959dc5880c457cd92e5447aaa5609db09ed47bd02c17a0edefdc819e756c74e5": [ "macos/10.10.0", @@ -12804,11 +13480,13 @@ "android/nougat-cts-release", "android/nougat-mr1-cts-release", "android/oreo-cts-release", + "android/oreo-mr1-cts-release", "mozilla/2.10", "mozilla/2.11", "mozilla/2.14", "mozilla/2.16", "mozilla/2.18", + "mozilla/2.20", "mozilla/2.9", "windows/070201011524", "windows/070522004642", @@ -12861,7 +13539,8 @@ "windows/170419224008", "windows/170613190204", "windows/170922155710", - "windows/171121202507" + "windows/171121202507", + "windows/180122185731" ], "9676f287356c89a12683d65234098cb77c4f1c18f23c0e541de0e196725b7ebe": [ "macos/10.10.0", @@ -12881,14 +13560,19 @@ "96bcec06264976f37460779acf28c5a7cfe8a3c0aae11a8ffcee05c0bddf08c6": [ "android/nougat-mr1-cts-release", "android/oreo-cts-release", + "android/oreo-mr1-cts-release", "macos/10.12.1", "macos/10.12.2", "macos/10.13.0", + "macos/10.13.1", + "macos/10.13.2", + "macos/10.13.3", "mozilla/2.10", "mozilla/2.11", "mozilla/2.14", "mozilla/2.16", "mozilla/2.18", + "mozilla/2.20", "mozilla/2.9" ], "978cd966f2faa07ba7aa9500d9c02e9d77f2cdada6ad6ba74af4b91c66593c50": [ @@ -12903,6 +13587,7 @@ "android/nougat-cts-release", "android/nougat-mr1-cts-release", "android/oreo-cts-release", + "android/oreo-mr1-cts-release", "macos/10.10.0", "macos/10.10.3", "macos/10.10.4", @@ -12914,6 +13599,9 @@ "macos/10.12.1", "macos/10.12.2", "macos/10.13.0", + "macos/10.13.1", + "macos/10.13.2", + "macos/10.13.3", "macos/10.9.0", "macos/10.9.2", "macos/10.9.4", @@ -12966,7 +13654,8 @@ "windows/170419224008", "windows/170613190204", "windows/170922155710", - "windows/171121202507" + "windows/171121202507", + "windows/180122185731" ], "97f654859cbde586fd90311e82ec7902c238cba0d6e529564c9c88f44895ec50": [ "windows/160916174005", @@ -12975,7 +13664,8 @@ "windows/170419224008", "windows/170613190204", "windows/170922155710", - "windows/171121202507" + "windows/171121202507", + "windows/180122185731" ], "9806ab8509e2f35e192f275f0c308b9409b42512f90c659598c22be613962272": [ "windows/070109202240", @@ -13018,7 +13708,8 @@ "windows/170419224008", "windows/170613190204", "windows/170922155710", - "windows/171121202507" + "windows/171121202507", + "windows/180122185731" ], "9a114025197c5bb95d94e63d55cd43790847b646b23cdf11ada4a00eff15fb48": [ "android/kitkat-cts-release", @@ -13033,6 +13724,7 @@ "android/nougat-cts-release", "android/nougat-mr1-cts-release", "android/oreo-cts-release", + "android/oreo-mr1-cts-release", "macos/10.10.0", "macos/10.10.3", "macos/10.10.4", @@ -13044,6 +13736,9 @@ "macos/10.12.1", "macos/10.12.2", "macos/10.13.0", + "macos/10.13.1", + "macos/10.13.2", + "macos/10.13.3", "macos/10.9.2", "macos/10.9.4", "macos/10.9.5", @@ -13052,6 +13747,7 @@ "mozilla/2.14", "mozilla/2.16", "mozilla/2.18", + "mozilla/2.20", "mozilla/2.9", "windows/111018233154", "windows/120125230451", @@ -13081,7 +13777,8 @@ "windows/170419224008", "windows/170613190204", "windows/170922155710", - "windows/171121202507" + "windows/171121202507", + "windows/180122185731" ], "9a6ec012e1a7da9dbe34194d478ad7c0db1822fb071df12981496ed104384113": [ "android/kitkat-cts-release", @@ -13096,11 +13793,13 @@ "android/nougat-cts-release", "android/nougat-mr1-cts-release", "android/oreo-cts-release", + "android/oreo-mr1-cts-release", "mozilla/2.10", "mozilla/2.11", "mozilla/2.14", "mozilla/2.16", "mozilla/2.18", + "mozilla/2.20", "mozilla/2.9", "windows/130420010442", "windows/130626232015", @@ -13124,7 +13823,8 @@ "windows/170419224008", "windows/170613190204", "windows/170922155710", - "windows/171121202507" + "windows/171121202507", + "windows/180122185731" ], "9a73929a500f1a0bf49dcb046e8039169696557345e9f813f10ff9380db22695": [ "macos/10.10.0", @@ -13138,6 +13838,9 @@ "macos/10.12.1", "macos/10.12.2", "macos/10.13.0", + "macos/10.13.1", + "macos/10.13.2", + "macos/10.13.3", "macos/10.9.0", "macos/10.9.2", "macos/10.9.4", @@ -13156,6 +13859,7 @@ "android/nougat-cts-release", "android/nougat-mr1-cts-release", "android/oreo-cts-release", + "android/oreo-mr1-cts-release", "macos/10.10.0", "macos/10.10.3", "macos/10.10.4", @@ -13167,6 +13871,9 @@ "macos/10.12.1", "macos/10.12.2", "macos/10.13.0", + "macos/10.13.1", + "macos/10.13.2", + "macos/10.13.3", "macos/10.9.0", "macos/10.9.2", "macos/10.9.4", @@ -13176,6 +13883,7 @@ "mozilla/2.14", "mozilla/2.16", "mozilla/2.18", + "mozilla/2.20", "mozilla/2.9", "windows/070109202240", "windows/070201011524", @@ -13229,7 +13937,8 @@ "windows/170419224008", "windows/170613190204", "windows/170922155710", - "windows/171121202507" + "windows/171121202507", + "windows/180122185731" ], "9b14e8f5f6ea167666e76dcd6becc190861d5e8970b99a9470f0231236049704": [ "windows/131003230417", @@ -13248,7 +13957,8 @@ "windows/170419224008", "windows/170613190204", "windows/170922155710", - "windows/171121202507" + "windows/171121202507", + "windows/180122185731" ], "9cefb0cb7b74e642932532831e0dc8f4d68ad414261fc3f474b795e72a164e57": [ "windows/150618202535", @@ -13265,7 +13975,8 @@ "windows/170419224008", "windows/170613190204", "windows/170922155710", - "windows/171121202507" + "windows/171121202507", + "windows/180122185731" ], "9d190b2e314566685be8a889e27aa8c7d7ae1d8aaddba3c1ecf9d24863cd34b9": [ "macos/10.10.0", @@ -13279,6 +13990,9 @@ "macos/10.12.1", "macos/10.12.2", "macos/10.13.0", + "macos/10.13.1", + "macos/10.13.2", + "macos/10.13.3", "macos/10.9.2", "macos/10.9.4", "macos/10.9.5" @@ -13394,6 +14108,9 @@ "macos/10.12.1", "macos/10.12.2", "macos/10.13.0", + "macos/10.13.1", + "macos/10.13.2", + "macos/10.13.3", "macos/10.9.0", "macos/10.9.2", "macos/10.9.4", @@ -13412,11 +14129,13 @@ "android/nougat-cts-release", "android/nougat-mr1-cts-release", "android/oreo-cts-release", + "android/oreo-mr1-cts-release", "mozilla/2.10", "mozilla/2.11", "mozilla/2.14", "mozilla/2.16", "mozilla/2.18", + "mozilla/2.20", "mozilla/2.9", "windows/070109202240", "windows/070201011524", @@ -13470,16 +14189,19 @@ "windows/170419224008", "windows/170613190204", "windows/170922155710", - "windows/171121202507" + "windows/171121202507", + "windows/180122185731" ], "a040929a02ce53b4acf4f2ffc6981ce4496f755e6d45fe0b2a692bcd52523f36": [ "android/nougat-mr1-cts-release", "android/oreo-cts-release", + "android/oreo-mr1-cts-release", "mozilla/2.10", "mozilla/2.11", "mozilla/2.14", "mozilla/2.16", "mozilla/2.18", + "mozilla/2.20", "mozilla/2.9", "windows/151119231843", "windows/160113232859", @@ -13492,7 +14214,8 @@ "windows/170419224008", "windows/170613190204", "windows/170922155710", - "windows/171121202507" + "windows/171121202507", + "windows/180122185731" ], "a0459b9f63b22559f5fa5d4c6db3f9f72ff19342033578f073bf1d1b46cbb912": [ "android/kitkat-cts-release", @@ -13507,11 +14230,13 @@ "android/nougat-cts-release", "android/nougat-mr1-cts-release", "android/oreo-cts-release", + "android/oreo-mr1-cts-release", "mozilla/2.10", "mozilla/2.11", "mozilla/2.14", "mozilla/2.16", "mozilla/2.18", + "mozilla/2.20", "mozilla/2.9", "windows/070109202240", "windows/070201011524", @@ -13565,23 +14290,32 @@ "windows/170419224008", "windows/170613190204", "windows/170922155710", - "windows/171121202507" + "windows/171121202507", + "windows/180122185731" ], "a1339d33281a0b56e557d3d32b1ce7f9367eb094bd5fa72a7e5004c8ded7cafe": [ "android/nougat-cts-release", "android/nougat-mr1-cts-release", "android/oreo-cts-release", + "android/oreo-mr1-cts-release", "mozilla/2.10", "mozilla/2.11", "mozilla/2.14", "mozilla/2.16", "mozilla/2.18", + "mozilla/2.20", "mozilla/2.9", "windows/170228174808", "windows/170419224008", "windows/170613190204", "windows/170922155710", - "windows/171121202507" + "windows/171121202507", + "windows/180122185731" + ], + "a1a86d04121eb87f027c66f53303c28e5739f943fc84b38ad6af009035dd9457": [ + "macos/10.13.1", + "macos/10.13.2", + "macos/10.13.3" ], "a1b2dbeb64e706c6169e3c4118b23baa09018a8427666d8bf0e28891ec051950": [ "windows/110919210309", @@ -13613,7 +14347,8 @@ "windows/170419224008", "windows/170613190204", "windows/170922155710", - "windows/171121202507" + "windows/171121202507", + "windows/180122185731" ], "a1f05ccb80c2d710ec7d479abdcbb879e58d7edb7149fe78a87884e3d0bad0f9": [ "macos/10.10.0", @@ -13627,6 +14362,9 @@ "macos/10.12.1", "macos/10.12.2", "macos/10.13.0", + "macos/10.13.1", + "macos/10.13.2", + "macos/10.13.3", "macos/10.9.0", "macos/10.9.2", "macos/10.9.4", @@ -13674,7 +14412,8 @@ "windows/170419224008", "windows/170613190204", "windows/170922155710", - "windows/171121202507" + "windows/171121202507", + "windows/180122185731" ], "a22dba681e97376e2d397d728aae3a9b6296b9fdba60bc2e11f647f2c675fb37": [ "android/kitkat-cts-release", @@ -13689,6 +14428,7 @@ "android/nougat-cts-release", "android/nougat-mr1-cts-release", "android/oreo-cts-release", + "android/oreo-mr1-cts-release", "macos/10.10.0", "macos/10.10.3", "macos/10.10.4", @@ -13700,6 +14440,9 @@ "macos/10.12.1", "macos/10.12.2", "macos/10.13.0", + "macos/10.13.1", + "macos/10.13.2", + "macos/10.13.3", "macos/10.9.0", "macos/10.9.2", "macos/10.9.4", @@ -13759,7 +14502,8 @@ "windows/170419224008", "windows/170613190204", "windows/170922155710", - "windows/171121202507" + "windows/171121202507", + "windows/180122185731" ], "a31f093053bd12c1f5c3c6efd498023fd2914d7758d05d698ce084b50626e0e5": [ "macos/10.10.0", @@ -13773,6 +14517,9 @@ "macos/10.12.1", "macos/10.12.2", "macos/10.13.0", + "macos/10.13.1", + "macos/10.13.2", + "macos/10.13.3", "macos/10.9.0", "macos/10.9.2", "macos/10.9.4", @@ -13823,7 +14570,8 @@ "windows/170419224008", "windows/170613190204", "windows/170922155710", - "windows/171121202507" + "windows/171121202507", + "windows/180122185731" ], "a3cc68595dfe7e86d8ad1772a8b5284add54ace3b8a798df47bccafb1fdb84df": [ "windows/160414222039", @@ -13833,7 +14581,8 @@ "windows/170419224008", "windows/170613190204", "windows/170922155710", - "windows/171121202507" + "windows/171121202507", + "windows/180122185731" ], "a3d7435a18c46b23b6a4f8929cd59050c9168b03a7fad532626f297cac5356e4": [ "windows/110919210309", @@ -13865,7 +14614,8 @@ "windows/170419224008", "windows/170613190204", "windows/170922155710", - "windows/171121202507" + "windows/171121202507", + "windows/180122185731" ], "a4310d50af18a6447190372a86afaf8b951ffb431d837f1e5688b45971ed1557": [ "android/kitkat-cts-release", @@ -13880,6 +14630,7 @@ "android/nougat-cts-release", "android/nougat-mr1-cts-release", "android/oreo-cts-release", + "android/oreo-mr1-cts-release", "macos/10.10.0", "macos/10.10.3", "macos/10.10.4", @@ -13891,6 +14642,9 @@ "macos/10.12.1", "macos/10.12.2", "macos/10.13.0", + "macos/10.13.1", + "macos/10.13.2", + "macos/10.13.3", "macos/10.9.0", "macos/10.9.2", "macos/10.9.4", @@ -13900,6 +14654,7 @@ "mozilla/2.14", "mozilla/2.16", "mozilla/2.18", + "mozilla/2.20", "mozilla/2.9", "windows/090825180842", "windows/091013033632", @@ -13941,7 +14696,8 @@ "windows/170419224008", "windows/170613190204", "windows/170922155710", - "windows/171121202507" + "windows/171121202507", + "windows/180122185731" ], "a45ede3bbbf09c8ae15c72efc07268d693a21c996fd51e67ca079460fd6d8873": [ "android/kitkat-cts-release", @@ -13956,6 +14712,7 @@ "android/nougat-cts-release", "android/nougat-mr1-cts-release", "android/oreo-cts-release", + "android/oreo-mr1-cts-release", "macos/10.10.0", "macos/10.10.3", "macos/10.10.4", @@ -13967,6 +14724,9 @@ "macos/10.12.1", "macos/10.12.2", "macos/10.13.0", + "macos/10.13.1", + "macos/10.13.2", + "macos/10.13.3", "macos/10.9.0", "macos/10.9.2", "macos/10.9.4", @@ -13976,6 +14736,7 @@ "mozilla/2.14", "mozilla/2.16", "mozilla/2.18", + "mozilla/2.20", "mozilla/2.9", "windows/070109202240", "windows/070201011524", @@ -14029,7 +14790,8 @@ "windows/170419224008", "windows/170613190204", "windows/170922155710", - "windows/171121202507" + "windows/171121202507", + "windows/180122185731" ], "a4b6b3996fc2f306b3fd8681bd63413d8c5009cc4fa329c2ccf0e2fa1b140305": [ "android/kitkat-cts-release", @@ -14139,7 +14901,8 @@ "windows/170419224008", "windows/170613190204", "windows/170922155710", - "windows/171121202507" + "windows/171121202507", + "windows/180122185731" ], "a6c51e0da5ca0a9309d2e4c0e40c2af9107aae8203857fe198e3e769e343085c": [ "android/kitkat-cts-release", @@ -14280,7 +15043,8 @@ "windows/170419224008", "windows/170613190204", "windows/170922155710", - "windows/171121202507" + "windows/171121202507", + "windows/180122185731" ], "a798a1c70e9b6d50eaa5724a26fac7991848edc61bf48d79816bcafb66972128": [ "windows/070109202240", @@ -14380,7 +15144,8 @@ "windows/170419224008", "windows/170613190204", "windows/170922155710", - "windows/171121202507" + "windows/171121202507", + "windows/180122185731" ], "aad9ceed5aa6b1cea28596a8e4e1abed9386d6ebc9d4aad9acde0fa36ba069d0": [ "macos/10.10.0", @@ -14438,7 +15203,8 @@ "windows/170419224008", "windows/170613190204", "windows/170922155710", - "windows/171121202507" + "windows/171121202507", + "windows/180122185731" ], "ab7036365c7154aa29c2c29f5d4191163b162a2225011357d56d07ffa7bc1f72": [ "macos/10.10.0", @@ -14498,7 +15264,8 @@ "windows/170419224008", "windows/170613190204", "windows/170922155710", - "windows/171121202507" + "windows/171121202507", + "windows/180122185731" ], "ad016f958050e0e7e46fae7dcc50197ed8e3ff0a4b262e5ddcdb3edddc7d6578": [ "windows/100503224537", @@ -14538,7 +15305,8 @@ "windows/170419224008", "windows/170613190204", "windows/170922155710", - "windows/171121202507" + "windows/171121202507", + "windows/180122185731" ], "ad7539e5cdc985fa95244055a9202d63460ec921467d034cfdbe87ec6d00fedc": [ "windows/130626232015", @@ -14590,6 +15358,9 @@ "macos/10.12.1", "macos/10.12.2", "macos/10.13.0", + "macos/10.13.1", + "macos/10.13.2", + "macos/10.13.3", "macos/10.9.2", "macos/10.9.4", "macos/10.9.5", @@ -14645,7 +15416,8 @@ "windows/170419224008", "windows/170613190204", "windows/170922155710", - "windows/171121202507" + "windows/171121202507", + "windows/180122185731" ], "ae92e90000541a9ebc101b70b6c33a62f5a53a55ba815e81d31abddf03507f5d": [ "windows/070109202240", @@ -14700,7 +15472,8 @@ "windows/170419224008", "windows/170613190204", "windows/170922155710", - "windows/171121202507" + "windows/171121202507", + "windows/180122185731" ], "af6d08eef3cac4e1584abc63c8a9472ac529af99f3f791319a43776063f58dca": [ "windows/070109202240", @@ -14755,7 +15528,8 @@ "windows/170419224008", "windows/170613190204", "windows/170922155710", - "windows/171121202507" + "windows/171121202507", + "windows/180122185731" ], "af71a3bca322e5224df546895696ce449a8bd2bd130f7a7ae457767f5c23d8f8": [ "windows/070109202240", @@ -14919,7 +15693,8 @@ "windows/170419224008", "windows/170613190204", "windows/170922155710", - "windows/171121202507" + "windows/171121202507", + "windows/180122185731" ], "b04d708f1ae0456265dd1b66907a2691a28680b853e031df3df9083af71614d7": [ "windows/070109202240", @@ -14971,6 +15746,9 @@ "macos/10.12.1", "macos/10.12.2", "macos/10.13.0", + "macos/10.13.1", + "macos/10.13.2", + "macos/10.13.3", "macos/10.9.0", "macos/10.9.2", "macos/10.9.4", @@ -15027,7 +15805,8 @@ "windows/170419224008", "windows/170613190204", "windows/170922155710", - "windows/171121202507" + "windows/171121202507", + "windows/180122185731" ], "b0b1730ecbc7ff4505142c49f1295e6eda6bcaed7e2c68c5be91b5a11001f024": [ "macos/10.10.0", @@ -15041,6 +15820,9 @@ "macos/10.12.1", "macos/10.12.2", "macos/10.13.0", + "macos/10.13.1", + "macos/10.13.2", + "macos/10.13.3", "macos/10.9.0", "macos/10.9.2", "macos/10.9.4", @@ -15058,6 +15840,7 @@ "android/nougat-cts-release", "android/nougat-mr1-cts-release", "android/oreo-cts-release", + "android/oreo-mr1-cts-release", "macos/10.10.0", "macos/10.10.3", "macos/10.10.4", @@ -15069,6 +15852,9 @@ "macos/10.12.1", "macos/10.12.2", "macos/10.13.0", + "macos/10.13.1", + "macos/10.13.2", + "macos/10.13.3", "macos/10.9.2", "macos/10.9.4", "macos/10.9.5", @@ -15077,6 +15863,7 @@ "mozilla/2.14", "mozilla/2.16", "mozilla/2.18", + "mozilla/2.20", "mozilla/2.9", "windows/131003230417", "windows/140312052931", @@ -15098,7 +15885,8 @@ "windows/170419224008", "windows/170613190204", "windows/170922155710", - "windows/171121202507" + "windows/171121202507", + "windows/180122185731" ], "b2259996fff735ab35014ef63f3d413190079dd03a0962432635a8695f995305": [ "windows/100927165108", @@ -15157,7 +15945,8 @@ "windows/170419224008", "windows/170613190204", "windows/170922155710", - "windows/171121202507" + "windows/171121202507", + "windows/180122185731" ], "b32396746453442f353e616292bb20bbaa5d23b546450fdb9c54b8386167d529": [ "macos/10.10.0", @@ -15171,6 +15960,9 @@ "macos/10.12.1", "macos/10.12.2", "macos/10.13.0", + "macos/10.13.1", + "macos/10.13.2", + "macos/10.13.3", "macos/10.9.2", "macos/10.9.4", "macos/10.9.5", @@ -15195,7 +15987,8 @@ "windows/170419224008", "windows/170613190204", "windows/170922155710", - "windows/171121202507" + "windows/171121202507", + "windows/180122185731" ], "b3c962d34019fb38ab9fe9c62399742ab26c43c2d18ce3f2b13c14321e52964b": [ "windows/070109202240", @@ -15349,7 +16142,8 @@ "windows/170419224008", "windows/170613190204", "windows/170922155710", - "windows/171121202507" + "windows/171121202507", + "windows/180122185731" ], "b478b812250df878635c2aa7ec7d155eaa625ee82916e2cd294361886cd1fbd4": [ "android/kitkat-cts-release", @@ -15364,6 +16158,7 @@ "android/nougat-cts-release", "android/nougat-mr1-cts-release", "android/oreo-cts-release", + "android/oreo-mr1-cts-release", "macos/10.10.0", "macos/10.10.3", "macos/10.10.4", @@ -15375,6 +16170,9 @@ "macos/10.12.1", "macos/10.12.2", "macos/10.13.0", + "macos/10.13.1", + "macos/10.13.2", + "macos/10.13.3", "macos/10.9.2", "macos/10.9.4", "macos/10.9.5", @@ -15383,6 +16181,7 @@ "mozilla/2.14", "mozilla/2.16", "mozilla/2.18", + "mozilla/2.20", "mozilla/2.9", "windows/090825180842", "windows/091013033632", @@ -15424,7 +16223,8 @@ "windows/170419224008", "windows/170613190204", "windows/170922155710", - "windows/171121202507" + "windows/171121202507", + "windows/180122185731" ], "b5bd2cb79cbd1907298d6bdf4842e516d8c78fa6fc96d25f71af814e16cc245e": [ "windows/080828200829", @@ -15471,7 +16271,8 @@ "windows/170419224008", "windows/170613190204", "windows/170922155710", - "windows/171121202507" + "windows/171121202507", + "windows/180122185731" ], "b6191a50d0c3977f7da99bcdaac86a227daeb9679ec70ba3b0c9d92271c170d3": [ "android/kitkat-cts-release", @@ -15486,6 +16287,7 @@ "android/nougat-cts-release", "android/nougat-mr1-cts-release", "android/oreo-cts-release", + "android/oreo-mr1-cts-release", "macos/10.10.0", "macos/10.10.3", "macos/10.10.4", @@ -15497,6 +16299,9 @@ "macos/10.12.1", "macos/10.12.2", "macos/10.13.0", + "macos/10.13.1", + "macos/10.13.2", + "macos/10.13.3", "macos/10.9.0", "macos/10.9.2", "macos/10.9.4", @@ -15506,6 +16311,7 @@ "mozilla/2.14", "mozilla/2.16", "mozilla/2.18", + "mozilla/2.20", "mozilla/2.9", "windows/070109202240", "windows/070201011524", @@ -15559,7 +16365,8 @@ "windows/170419224008", "windows/170613190204", "windows/170922155710", - "windows/171121202507" + "windows/171121202507", + "windows/180122185731" ], "b644d955fff29b74e3b5687e908ee7c3c9197ba3336cc6328531f6c057d677fd": [ "windows/100927165108", @@ -15597,21 +16404,27 @@ "windows/170419224008", "windows/170613190204", "windows/170922155710", - "windows/171121202507" + "windows/171121202507", + "windows/180122185731" ], "b676f2eddae8775cd36cb0f63cd1d4603961f49e6265ba013a2f0307b6d0b804": [ "android/nougat-cts-release", "android/nougat-mr1-cts-release", "android/oreo-cts-release", + "android/oreo-mr1-cts-release", "macos/10.12.0", "macos/10.12.1", "macos/10.12.2", "macos/10.13.0", + "macos/10.13.1", + "macos/10.13.2", + "macos/10.13.3", "mozilla/2.10", "mozilla/2.11", "mozilla/2.14", "mozilla/2.16", "mozilla/2.18", + "mozilla/2.20", "mozilla/2.9", "windows/160916174005", "windows/161112005943", @@ -15619,7 +16432,8 @@ "windows/170419224008", "windows/170613190204", "windows/170922155710", - "windows/171121202507" + "windows/171121202507", + "windows/180122185731" ], "b7a7ec419454411761225ecf30d99585f851356077bf83274b11588fd05521b8": [ "macos/10.9.0" @@ -15682,11 +16496,16 @@ "b7c36231706e81078c367cb896198f1e3208dd926949dd8f5709a410f75b6292": [ "android/nougat-mr1-cts-release", "android/oreo-cts-release", + "android/oreo-mr1-cts-release", + "macos/10.13.1", + "macos/10.13.2", + "macos/10.13.3", "mozilla/2.10", "mozilla/2.11", "mozilla/2.14", "mozilla/2.16", "mozilla/2.18", + "mozilla/2.20", "mozilla/2.9", "windows/150618202535", "windows/150723231635", @@ -15702,7 +16521,8 @@ "windows/170419224008", "windows/170613190204", "windows/170922155710", - "windows/171121202507" + "windows/171121202507", + "windows/180122185731" ], "b8bbe523bfca3b11d50f73f7f10b3ec8ec958aa1dc86f66d9541907ff1a110ef": [ "windows/090203164005", @@ -15797,7 +16617,8 @@ "windows/170419224008", "windows/170613190204", "windows/170922155710", - "windows/171121202507" + "windows/171121202507", + "windows/180122185731" ], "ba7f1136389075b8e86c53c095fa14f5c83b6b017a0244ed7637114620d3a3b1": [ "macos/10.9.0", @@ -15818,6 +16639,7 @@ "android/nougat-cts-release", "android/nougat-mr1-cts-release", "android/oreo-cts-release", + "android/oreo-mr1-cts-release", "macos/10.10.0", "macos/10.10.3", "macos/10.10.4", @@ -15829,6 +16651,9 @@ "macos/10.12.1", "macos/10.12.2", "macos/10.13.0", + "macos/10.13.1", + "macos/10.13.2", + "macos/10.13.3", "macos/10.9.2", "macos/10.9.4", "macos/10.9.5", @@ -15837,6 +16662,7 @@ "mozilla/2.14", "mozilla/2.16", "mozilla/2.18", + "mozilla/2.20", "mozilla/2.9", "windows/130420010442", "windows/130626232015", @@ -15860,7 +16686,8 @@ "windows/170419224008", "windows/170613190204", "windows/170922155710", - "windows/171121202507" + "windows/171121202507", + "windows/180122185731" ], "bc23f98a313cb92de3bbfc3a5a9f4461ac39494c4ae15a9e9df131e99b73019a": [ "android/kitkat-cts-release", @@ -15973,6 +16800,7 @@ "android/nougat-cts-release", "android/nougat-mr1-cts-release", "android/oreo-cts-release", + "android/oreo-mr1-cts-release", "macos/10.10.0", "macos/10.10.3", "macos/10.10.4", @@ -15984,6 +16812,9 @@ "macos/10.12.1", "macos/10.12.2", "macos/10.13.0", + "macos/10.13.1", + "macos/10.13.2", + "macos/10.13.3", "macos/10.9.0", "macos/10.9.2", "macos/10.9.4", @@ -15993,6 +16824,7 @@ "mozilla/2.14", "mozilla/2.16", "mozilla/2.18", + "mozilla/2.20", "mozilla/2.9", "windows/100719231554", "windows/100927165108", @@ -16030,7 +16862,8 @@ "windows/170419224008", "windows/170613190204", "windows/170922155710", - "windows/171121202507" + "windows/171121202507", + "windows/180122185731" ], "bd81ce3b4f6591d11a67b5fc7a47fdef25521bf9aa4e18b9e3df2e34a7803be8": [ "android/kitkat-cts-release", @@ -16073,6 +16906,7 @@ "android/nougat-cts-release", "android/nougat-mr1-cts-release", "android/oreo-cts-release", + "android/oreo-mr1-cts-release", "macos/10.10.0", "macos/10.10.3", "macos/10.10.4", @@ -16084,6 +16918,9 @@ "macos/10.12.1", "macos/10.12.2", "macos/10.13.0", + "macos/10.13.1", + "macos/10.13.2", + "macos/10.13.3", "macos/10.9.0", "macos/10.9.2", "macos/10.9.4", @@ -16093,6 +16930,7 @@ "mozilla/2.14", "mozilla/2.16", "mozilla/2.18", + "mozilla/2.20", "mozilla/2.9", "windows/070201011524", "windows/070522004642", @@ -16145,7 +16983,8 @@ "windows/170419224008", "windows/170613190204", "windows/170922155710", - "windows/171121202507" + "windows/171121202507", + "windows/180122185731" ], "bebce57dcb85f60a93bfa5019edb1a294bf6d81f82d9b4e71f502f0b15a1fc08": [ "windows/160916174005", @@ -16154,7 +16993,8 @@ "windows/170419224008", "windows/170613190204", "windows/170922155710", - "windows/171121202507" + "windows/171121202507", + "windows/180122185731" ], "bec94911c2955676db6c0a550986d76e3ba005667c442c9762b4fbb773de228c": [ "android/lollipop-mr1-cts-release", @@ -16165,6 +17005,7 @@ "android/nougat-cts-release", "android/nougat-mr1-cts-release", "android/oreo-cts-release", + "android/oreo-mr1-cts-release", "macos/10.10.0", "macos/10.10.3", "macos/10.10.4", @@ -16176,6 +17017,9 @@ "macos/10.12.1", "macos/10.12.2", "macos/10.13.0", + "macos/10.13.1", + "macos/10.13.2", + "macos/10.13.3", "macos/10.9.2", "macos/10.9.4", "macos/10.9.5", @@ -16184,6 +17028,7 @@ "mozilla/2.14", "mozilla/2.16", "mozilla/2.18", + "mozilla/2.20", "mozilla/2.9", "windows/130626232015", "windows/131003230417", @@ -16206,7 +17051,8 @@ "windows/170419224008", "windows/170613190204", "windows/170922155710", - "windows/171121202507" + "windows/171121202507", + "windows/180122185731" ], "bf0feefb9e3a581ad5f9e9db7589985743d261085c4d314f6f5d7259aa421612": [ "android/kitkat-cts-release", @@ -16221,6 +17067,7 @@ "android/nougat-cts-release", "android/nougat-mr1-cts-release", "android/oreo-cts-release", + "android/oreo-mr1-cts-release", "macos/10.9.0", "macos/10.9.2", "macos/10.9.4", @@ -16230,6 +17077,7 @@ "mozilla/2.14", "mozilla/2.16", "mozilla/2.18", + "mozilla/2.20", "mozilla/2.9", "windows/090501224247", "windows/090825180842", @@ -16276,6 +17124,7 @@ "android/nougat-cts-release", "android/nougat-mr1-cts-release", "android/oreo-cts-release", + "android/oreo-mr1-cts-release", "macos/10.10.0", "macos/10.10.3", "macos/10.10.4", @@ -16287,6 +17136,9 @@ "macos/10.12.1", "macos/10.12.2", "macos/10.13.0", + "macos/10.13.1", + "macos/10.13.2", + "macos/10.13.3", "macos/10.9.0", "macos/10.9.2", "macos/10.9.4", @@ -16296,6 +17148,7 @@ "mozilla/2.14", "mozilla/2.16", "mozilla/2.18", + "mozilla/2.20", "mozilla/2.9", "windows/090825180842", "windows/091013033632", @@ -16337,10 +17190,12 @@ "windows/170419224008", "windows/170613190204", "windows/170922155710", - "windows/171121202507" + "windows/171121202507", + "windows/180122185731" ], "bfff8fd04433487d6a8aa60c1a29767a9fc2bbb05e420f713a13b992891d3893": [ "mozilla/2.18", + "mozilla/2.20", "windows/150618202535", "windows/150723231635", "windows/150820181119", @@ -16355,7 +17210,8 @@ "windows/170419224008", "windows/170613190204", "windows/170922155710", - "windows/171121202507" + "windows/171121202507", + "windows/180122185731" ], "c0a6f4dc63a24bfdcf54ef2a6a082a0a72de35803e2ff5ff527ae5d87206dfd5": [ "android/kitkat-cts-release", @@ -16370,6 +17226,7 @@ "android/nougat-cts-release", "android/nougat-mr1-cts-release", "android/oreo-cts-release", + "android/oreo-mr1-cts-release", "macos/10.10.0", "macos/10.10.3", "macos/10.10.4", @@ -16381,6 +17238,9 @@ "macos/10.12.1", "macos/10.12.2", "macos/10.13.0", + "macos/10.13.1", + "macos/10.13.2", + "macos/10.13.3", "macos/10.9.0", "macos/10.9.2", "macos/10.9.4", @@ -16390,6 +17250,7 @@ "mozilla/2.14", "mozilla/2.16", "mozilla/2.18", + "mozilla/2.20", "mozilla/2.9", "windows/080328202117", "windows/080612204220", @@ -16436,7 +17297,8 @@ "windows/170419224008", "windows/170613190204", "windows/170922155710", - "windows/171121202507" + "windows/171121202507", + "windows/180122185731" ], "c0c05a8d8da55eaf27aa9b910b0a6ef0d8bbded346928db872e182c2073e9802": [ "macos/10.10.0", @@ -16450,6 +17312,9 @@ "macos/10.12.1", "macos/10.12.2", "macos/10.13.0", + "macos/10.13.1", + "macos/10.13.2", + "macos/10.13.3", "macos/10.9.2", "macos/10.9.4", "macos/10.9.5", @@ -16513,7 +17378,8 @@ "windows/151119231843" ], "c1727f3b673e6ae7f12f23d789a7be38b918223ef6911c592da1f583444a547e": [ - "windows/171121202507" + "windows/171121202507", + "windows/180122185731" ], "c1b12f480020336e5b04f520bc19c2e2e10ab42c9d9235f05cbec33ffa4d4dea": [ "windows/070109202240", @@ -16568,7 +17434,8 @@ "windows/170419224008", "windows/170613190204", "windows/170922155710", - "windows/171121202507" + "windows/171121202507", + "windows/180122185731" ], "c1b48299aba5208fe9630ace55ca68a03eda5a519c8802a0d3a673be8f8e557d": [ "android/kitkat-cts-release", @@ -16582,6 +17449,7 @@ "android/nougat-cts-release", "android/nougat-mr1-cts-release", "android/oreo-cts-release", + "android/oreo-mr1-cts-release", "macos/10.10.0", "macos/10.10.3", "macos/10.10.4", @@ -16593,6 +17461,9 @@ "macos/10.12.1", "macos/10.12.2", "macos/10.13.0", + "macos/10.13.1", + "macos/10.13.2", + "macos/10.13.3", "macos/10.9.0", "macos/10.9.2", "macos/10.9.4", @@ -16602,6 +17473,7 @@ "mozilla/2.14", "mozilla/2.16", "mozilla/2.18", + "mozilla/2.20", "mozilla/2.9", "windows/070109202240", "windows/070201011524", @@ -16655,7 +17527,8 @@ "windows/170419224008", "windows/170613190204", "windows/170922155710", - "windows/171121202507" + "windows/171121202507", + "windows/180122185731" ], "c1cf0b52096435e3f1b71daaec455a2311c8404f5583a9e213c69d857d943305": [ "android/kitkat-mr1-release", @@ -16701,7 +17574,8 @@ "windows/170419224008", "windows/170613190204", "windows/170922155710", - "windows/171121202507" + "windows/171121202507", + "windows/180122185731" ], "c2157309d9aee17bf34f4df5e88dbaeba57e0361eb814cbc239f4d54d329a38d": [ "windows/140912180251", @@ -16722,7 +17596,8 @@ "windows/170419224008", "windows/170613190204", "windows/170922155710", - "windows/171121202507" + "windows/171121202507", + "windows/180122185731" ], "c2959db8339e8dbcf6409ca92a66c49fd2e32494940a901143bd7eb72827dec2": [ "windows/070109202240", @@ -16774,6 +17649,9 @@ "macos/10.12.1", "macos/10.12.2", "macos/10.13.0", + "macos/10.13.1", + "macos/10.13.2", + "macos/10.13.3", "macos/10.9.4", "macos/10.9.5" ], @@ -16796,7 +17674,8 @@ "windows/170419224008", "windows/170613190204", "windows/170922155710", - "windows/171121202507" + "windows/171121202507", + "windows/180122185731" ], "c34c5df53080078ffe45b21a7f600469917204f4f0293f1d7209393e5265c04f": [ "windows/150723231635", @@ -16812,7 +17691,8 @@ "windows/170419224008", "windows/170613190204", "windows/170922155710", - "windows/171121202507" + "windows/171121202507", + "windows/180122185731" ], "c3846bf24b9e93ca64274c0ec67c1ecc5e024ffcacd2d74019350e81fe546ae4": [ "android/kitkat-cts-release", @@ -16827,6 +17707,7 @@ "android/nougat-cts-release", "android/nougat-mr1-cts-release", "android/oreo-cts-release", + "android/oreo-mr1-cts-release", "macos/10.10.0", "macos/10.10.3", "macos/10.10.4", @@ -16838,6 +17719,9 @@ "macos/10.12.1", "macos/10.12.2", "macos/10.13.0", + "macos/10.13.1", + "macos/10.13.2", + "macos/10.13.3", "macos/10.9.0", "macos/10.9.2", "macos/10.9.4", @@ -16847,6 +17731,7 @@ "mozilla/2.14", "mozilla/2.16", "mozilla/2.18", + "mozilla/2.20", "mozilla/2.9", "windows/070109202240", "windows/070201011524", @@ -16900,7 +17785,8 @@ "windows/170419224008", "windows/170613190204", "windows/170922155710", - "windows/171121202507" + "windows/171121202507", + "windows/180122185731" ], "c38dcb38959393358691ea4d4f3ce495ce748996e64ed1891d897a0fc4dd55c6": [ "android/kitkat-mr1-release", @@ -16968,7 +17854,8 @@ ], "c45d7bb08e6d67e62e4235110b564e5f78fd92ef058c840aea4e6455d7585c60": [ "windows/170922155710", - "windows/171121202507" + "windows/171121202507", + "windows/180122185731" ], "c470cf547e2302b977fb29dd71a89a7b6c1f60777b0329f56017f328bf4f6be6": [ "android/kitkat-cts-release", @@ -17086,6 +17973,9 @@ "macos/10.12.1", "macos/10.12.2", "macos/10.13.0", + "macos/10.13.1", + "macos/10.13.2", + "macos/10.13.3", "macos/10.9.2", "macos/10.9.4", "macos/10.9.5", @@ -17139,7 +18029,8 @@ "windows/170419224008", "windows/170613190204", "windows/170922155710", - "windows/171121202507" + "windows/171121202507", + "windows/180122185731" ], "c57bacf238f9336c3dfba62d12bcf5823603e5842c44e62f5448cc7e5f4cad59": [ "macos/10.9.0" @@ -17168,6 +18059,9 @@ "macos/10.12.1", "macos/10.12.2", "macos/10.13.0", + "macos/10.13.1", + "macos/10.13.2", + "macos/10.13.3", "macos/10.9.0", "macos/10.9.2", "macos/10.9.4", @@ -17217,7 +18111,8 @@ "windows/170419224008", "windows/170613190204", "windows/170922155710", - "windows/171121202507" + "windows/171121202507", + "windows/180122185731" ], "c795ff8ff20c966688f064a1e091421d3110a3456c17ec2404b998738741f622": [ "windows/150618202535", @@ -17234,7 +18129,8 @@ "windows/170419224008", "windows/170613190204", "windows/170922155710", - "windows/171121202507" + "windows/171121202507", + "windows/180122185731" ], "c7ba6567de93a798ae1faa791e712d378fae1f93c4397fea441bb7cbe6fd5995": [ "android/kitkat-cts-release", @@ -17260,6 +18156,9 @@ "macos/10.12.1", "macos/10.12.2", "macos/10.13.0", + "macos/10.13.1", + "macos/10.13.2", + "macos/10.13.3", "macos/10.9.2", "macos/10.9.4", "macos/10.9.5", @@ -17289,7 +18188,8 @@ "windows/170419224008", "windows/170613190204", "windows/170922155710", - "windows/171121202507" + "windows/171121202507", + "windows/180122185731" ], "ca2d82a08677072f8ab6764ff035676cfe3e5e325e012172df3f92096db79b85": [ "android/kitkat-cts-release", @@ -17360,7 +18260,8 @@ "windows/170419224008", "windows/170613190204", "windows/170922155710", - "windows/171121202507" + "windows/171121202507", + "windows/180122185731" ], "ca42dd41745fd0b81eb902362cf9d8bf719da1bd1b1efc946f5b4c99f42c1b9e": [ "android/kitkat-cts-release", @@ -17375,6 +18276,7 @@ "android/nougat-cts-release", "android/nougat-mr1-cts-release", "android/oreo-cts-release", + "android/oreo-mr1-cts-release", "macos/10.10.0", "macos/10.10.3", "macos/10.10.4", @@ -17386,6 +18288,9 @@ "macos/10.12.1", "macos/10.12.2", "macos/10.13.0", + "macos/10.13.1", + "macos/10.13.2", + "macos/10.13.3", "macos/10.9.0", "macos/10.9.2", "macos/10.9.4", @@ -17395,6 +18300,7 @@ "mozilla/2.14", "mozilla/2.16", "mozilla/2.18", + "mozilla/2.20", "mozilla/2.9", "windows/070201011524", "windows/070522004642", @@ -17447,7 +18353,8 @@ "windows/170419224008", "windows/170613190204", "windows/170922155710", - "windows/171121202507" + "windows/171121202507", + "windows/180122185731" ], "ca7a5e68c53d2c51f72f6b465d3ed753f5903ec7901c8d0f55d868337c81975a": [ "windows/110125205412", @@ -17484,7 +18391,8 @@ "windows/170419224008", "windows/170613190204", "windows/170922155710", - "windows/171121202507" + "windows/171121202507", + "windows/180122185731" ], "cb3ccbb76031e5e0138f8dd39a23f9de47ffc35e43c1144cea27d46a5ab1cb5f": [ "android/lollipop-cts-release", @@ -17496,6 +18404,7 @@ "android/nougat-cts-release", "android/nougat-mr1-cts-release", "android/oreo-cts-release", + "android/oreo-mr1-cts-release", "macos/10.10.0", "macos/10.10.3", "macos/10.10.4", @@ -17507,6 +18416,9 @@ "macos/10.12.1", "macos/10.12.2", "macos/10.13.0", + "macos/10.13.1", + "macos/10.13.2", + "macos/10.13.3", "macos/10.9.2", "macos/10.9.4", "macos/10.9.5", @@ -17515,6 +18427,7 @@ "mozilla/2.14", "mozilla/2.16", "mozilla/2.18", + "mozilla/2.20", "mozilla/2.9", "windows/131003230417", "windows/140312052931", @@ -17536,7 +18449,8 @@ "windows/170419224008", "windows/170613190204", "windows/170922155710", - "windows/171121202507" + "windows/171121202507", + "windows/180122185731" ], "cb627d18b58ad56dde331a30456bc65c601a4e9b18dedcea08e7daaa07815ff0": [ "macos/10.10.0", @@ -17550,6 +18464,9 @@ "macos/10.12.1", "macos/10.12.2", "macos/10.13.0", + "macos/10.13.1", + "macos/10.13.2", + "macos/10.13.3", "macos/10.9.2", "macos/10.9.4", "macos/10.9.5" @@ -17576,6 +18493,7 @@ "android/nougat-cts-release", "android/nougat-mr1-cts-release", "android/oreo-cts-release", + "android/oreo-mr1-cts-release", "macos/10.10.0", "macos/10.10.3", "macos/10.10.4", @@ -17587,6 +18505,9 @@ "macos/10.12.1", "macos/10.12.2", "macos/10.13.0", + "macos/10.13.1", + "macos/10.13.2", + "macos/10.13.3", "macos/10.9.0", "macos/10.9.2", "macos/10.9.4", @@ -17596,6 +18517,7 @@ "mozilla/2.14", "mozilla/2.16", "mozilla/2.18", + "mozilla/2.20", "mozilla/2.9", "windows/100503224537", "windows/100719231554", @@ -17634,7 +18556,8 @@ "windows/170419224008", "windows/170613190204", "windows/170922155710", - "windows/171121202507" + "windows/171121202507", + "windows/180122185731" ], "cbb5af185e942a2402f9eacbc0ed5bb876eea3c1223623d00447e4f3ba554b65": [ "macos/10.10.0", @@ -17648,6 +18571,9 @@ "macos/10.12.1", "macos/10.12.2", "macos/10.13.0", + "macos/10.13.1", + "macos/10.13.2", + "macos/10.13.3", "macos/10.9.0", "macos/10.9.2", "macos/10.9.4", @@ -17692,7 +18618,8 @@ "windows/170419224008", "windows/170613190204", "windows/170922155710", - "windows/171121202507" + "windows/171121202507", + "windows/180122185731" ], "ccc89489371bad111c90619bea240a2e6dadd99f9f6e1d4d41e58ed6de3d0285": [ "windows/070109202240", @@ -17747,7 +18674,8 @@ "windows/170419224008", "windows/170613190204", "windows/170922155710", - "windows/171121202507" + "windows/171121202507", + "windows/180122185731" ], "cd0b3b2aa174b55f18c7502f3c3a76f2198175ce45637370cf4f48b9c2ce4fbf": [ "windows/090825180842", @@ -17790,7 +18718,8 @@ "windows/170419224008", "windows/170613190204", "windows/170922155710", - "windows/171121202507" + "windows/171121202507", + "windows/180122185731" ], "cd201256fe5ced0bfff8df595fff36b1416d5313a999f532ef4a9915df96dee0": [ "windows/090825180842", @@ -17833,7 +18762,8 @@ "windows/170419224008", "windows/170613190204", "windows/170922155710", - "windows/171121202507" + "windows/171121202507", + "windows/180122185731" ], "cd808284cf746ff2fd6eb58aa1d59c4ad4b3ca56fdc6274a8926a7835f32313d": [ "macos/10.10.0", @@ -17904,7 +18834,8 @@ "windows/170419224008", "windows/170613190204", "windows/170922155710", - "windows/171121202507" + "windows/171121202507", + "windows/180122185731" ], "cecddc905099d8dadfc5b1d209b737cbe2c18cfb2c10c0ff0bcf0d3286fc1aa2": [ "android/kitkat-cts-release", @@ -17919,6 +18850,7 @@ "android/nougat-cts-release", "android/nougat-mr1-cts-release", "android/oreo-cts-release", + "android/oreo-mr1-cts-release", "macos/10.10.0", "macos/10.10.3", "macos/10.10.4", @@ -17930,6 +18862,9 @@ "macos/10.12.1", "macos/10.12.2", "macos/10.13.0", + "macos/10.13.1", + "macos/10.13.2", + "macos/10.13.3", "macos/10.9.0", "macos/10.9.2", "macos/10.9.4", @@ -17939,6 +18874,7 @@ "mozilla/2.14", "mozilla/2.16", "mozilla/2.18", + "mozilla/2.20", "mozilla/2.9", "windows/070109202240", "windows/070201011524", @@ -17992,7 +18928,8 @@ "windows/170419224008", "windows/170613190204", "windows/170922155710", - "windows/171121202507" + "windows/171121202507", + "windows/180122185731" ], "cf56ff46a4a186109dd96584b5eeb58a510c4275b0e5f94f40bbae865e19f673": [ "android/kitkat-cts-release", @@ -18056,7 +18993,8 @@ "d1a0319098034e3aec729a0b5c3111229d9d26e3e623e8c5e6843fa06ee8e2e4": [ "windows/170613190204", "windows/170922155710", - "windows/171121202507" + "windows/171121202507", + "windows/180122185731" ], "d1c339ea2784eb870f934fc5634e4aa9ad5505016401f26465d37a574663359f": [ "macos/10.10.0", @@ -18070,6 +19008,9 @@ "macos/10.12.1", "macos/10.12.2", "macos/10.13.0", + "macos/10.13.1", + "macos/10.13.2", + "macos/10.13.3", "macos/10.9.0", "macos/10.9.2", "macos/10.9.4", @@ -18102,17 +19043,20 @@ "windows/170419224008", "windows/170613190204", "windows/170922155710", - "windows/171121202507" + "windows/171121202507", + "windows/180122185731" ], "d40e9c86cd8fe468c1776959f49ea774fa548684b6c406f3909261f4dce2575c": [ "mozilla/2.18", + "mozilla/2.20", "windows/160414222039", "windows/160916174005", "windows/170228174808", "windows/170419224008", "windows/170613190204", "windows/170922155710", - "windows/171121202507" + "windows/171121202507", + "windows/180122185731" ], "d41d829e8c1659822af93fce62bffcde264fc84e8b950c5ff275d052354695a3": [ "android/kitkat-cts-release", @@ -18186,7 +19130,8 @@ "windows/170419224008", "windows/170613190204", "windows/170922155710", - "windows/171121202507" + "windows/171121202507", + "windows/180122185731" ], "d43af9b35473755c9684fc06d7d8cb70ee5c28e773fb294eb41ee71722924d24": [ "windows/161112005943", @@ -18194,7 +19139,8 @@ "windows/170419224008", "windows/170613190204", "windows/170922155710", - "windows/171121202507" + "windows/171121202507", + "windows/180122185731" ], "d487a56f83b07482e85e963394c1ecc2c9e51d0903ee946b02c301581ed99e16": [ "android/nougat-cts-release", @@ -18219,7 +19165,8 @@ "windows/170419224008", "windows/170613190204", "windows/170922155710", - "windows/171121202507" + "windows/171121202507", + "windows/180122185731" ], "d48d3d23eedb50a459e55197601c27774b9d7b18c94d5a059511a10250b93168": [ "windows/160414222039", @@ -18229,7 +19176,8 @@ "windows/170419224008", "windows/170613190204", "windows/170922155710", - "windows/171121202507" + "windows/171121202507", + "windows/180122185731" ], "d68f7730b1ec2b3fb698c96d76540c9997415a25737dcd61d44960db77d2723d": [ "macos/10.9.0" @@ -18267,7 +19215,8 @@ "windows/170419224008", "windows/170613190204", "windows/170922155710", - "windows/171121202507" + "windows/171121202507", + "windows/180122185731" ], "d7a7a0fb5d7e2731d771e9484ebcdef71d5f0c3e0a2948782bc83ee0ea699ef4": [ "android/kitkat-cts-release", @@ -18282,6 +19231,7 @@ "android/nougat-cts-release", "android/nougat-mr1-cts-release", "android/oreo-cts-release", + "android/oreo-mr1-cts-release", "macos/10.10.0", "macos/10.10.3", "macos/10.10.4", @@ -18293,6 +19243,9 @@ "macos/10.12.1", "macos/10.12.2", "macos/10.13.0", + "macos/10.13.1", + "macos/10.13.2", + "macos/10.13.3", "macos/10.9.0", "macos/10.9.2", "macos/10.9.4", @@ -18302,6 +19255,7 @@ "mozilla/2.14", "mozilla/2.16", "mozilla/2.18", + "mozilla/2.20", "mozilla/2.9", "windows/070109202240", "windows/070201011524", @@ -18355,11 +19309,13 @@ "windows/170419224008", "windows/170613190204", "windows/170922155710", - "windows/171121202507" + "windows/171121202507", + "windows/180122185731" ], "d7ba3f4ff8ad05633451470dda3378a3491b90005e5c687d2b68d53647cfdd66": [ "windows/170922155710", - "windows/171121202507" + "windows/171121202507", + "windows/180122185731" ], "d80fef910ae3f104723b045cec2d019f441ce6213adf156791e70c1790110a31": [ "windows/150618202535", @@ -18375,7 +19331,8 @@ "windows/170419224008", "windows/170613190204", "windows/170922155710", - "windows/171121202507" + "windows/171121202507", + "windows/180122185731" ], "d8e0febc1db2e38d00940f37d27d41344d993e734b99d5656d9778d4d8143624": [ "android/kitkat-cts-release", @@ -18390,6 +19347,7 @@ "android/nougat-cts-release", "android/nougat-mr1-cts-release", "android/oreo-cts-release", + "android/oreo-mr1-cts-release", "macos/10.10.0", "macos/10.10.3", "macos/10.10.4", @@ -18401,6 +19359,9 @@ "macos/10.12.1", "macos/10.12.2", "macos/10.13.0", + "macos/10.13.1", + "macos/10.13.2", + "macos/10.13.3", "macos/10.9.0", "macos/10.9.2", "macos/10.9.4", @@ -18462,7 +19423,8 @@ "windows/170419224008", "windows/170613190204", "windows/170922155710", - "windows/171121202507" + "windows/171121202507", + "windows/180122185731" ], "d95fea3ca4eedce74cd76e75fc6d1ff62c441f0fa8bc77f034b19e5db258015d": [ "android/kitkat-cts-release", @@ -18487,6 +19449,9 @@ "macos/10.12.1", "macos/10.12.2", "macos/10.13.0", + "macos/10.13.1", + "macos/10.13.2", + "macos/10.13.3", "macos/10.9.2", "macos/10.9.4", "macos/10.9.5", @@ -18515,7 +19480,8 @@ "windows/170419224008", "windows/170613190204", "windows/170922155710", - "windows/171121202507" + "windows/171121202507", + "windows/180122185731" ], "da98f640194df128c7888bc8e3479a9dd31795ff087c649052fbafb02eaef184": [ "macos/10.10.0", @@ -18538,6 +19504,7 @@ "android/nougat-cts-release", "android/nougat-mr1-cts-release", "android/oreo-cts-release", + "android/oreo-mr1-cts-release", "macos/10.10.0", "macos/10.10.3", "macos/10.10.4", @@ -18549,6 +19516,9 @@ "macos/10.12.1", "macos/10.12.2", "macos/10.13.0", + "macos/10.13.1", + "macos/10.13.2", + "macos/10.13.3", "macos/10.9.2", "macos/10.9.4", "macos/10.9.5", @@ -18557,6 +19527,7 @@ "mozilla/2.14", "mozilla/2.16", "mozilla/2.18", + "mozilla/2.20", "mozilla/2.9", "windows/100503224537", "windows/100719231554", @@ -18595,14 +19566,16 @@ "windows/170419224008", "windows/170613190204", "windows/170922155710", - "windows/171121202507" + "windows/171121202507", + "windows/180122185731" ], "ddbf149733bc2bf8a09d7f012b01a6dea11d7bae26713783ef6407a2495bf189": [ "windows/170228174808", "windows/170419224008", "windows/170613190204", "windows/170922155710", - "windows/171121202507" + "windows/171121202507", + "windows/180122185731" ], "ddff53ecd7743b60bb7b2795ff5732fa785f9a14df1120fb40a38cf84ca2a566": [ "windows/070201011524", @@ -18656,7 +19629,8 @@ "windows/170419224008", "windows/170613190204", "windows/170922155710", - "windows/171121202507" + "windows/171121202507", + "windows/180122185731" ], "df545bf919a2439c36983b54cdfc903dfa4f37d3996d8d84b4c31eec6f3c163e": [ "windows/100719231554", @@ -18695,7 +19669,8 @@ "windows/170419224008", "windows/170613190204", "windows/170922155710", - "windows/171121202507" + "windows/171121202507", + "windows/180122185731" ], "e0e17aea06cf9ce12aae8190345a2c59720130a7d8ff72f3745ad75dbaa365b6": [ "windows/140912180251", @@ -18716,7 +19691,8 @@ "windows/170419224008", "windows/170613190204", "windows/170922155710", - "windows/171121202507" + "windows/171121202507", + "windows/180122185731" ], "e17890ee09a3fbf4f48b9c414a17d637b7a50647e9bc752322727fcc1742a911": [ "android/kitkat-cts-release", @@ -18741,6 +19717,9 @@ "macos/10.12.1", "macos/10.12.2", "macos/10.13.0", + "macos/10.13.1", + "macos/10.13.2", + "macos/10.13.3", "macos/10.9.0", "macos/10.9.2", "macos/10.9.4", @@ -18763,6 +19742,7 @@ "android/nougat-cts-release", "android/nougat-mr1-cts-release", "android/oreo-cts-release", + "android/oreo-mr1-cts-release", "macos/10.10.0", "macos/10.10.3", "macos/10.10.4", @@ -18774,6 +19754,9 @@ "macos/10.12.1", "macos/10.12.2", "macos/10.13.0", + "macos/10.13.1", + "macos/10.13.2", + "macos/10.13.3", "macos/10.9.2", "macos/10.9.4", "macos/10.9.5", @@ -18782,6 +19765,7 @@ "mozilla/2.14", "mozilla/2.16", "mozilla/2.18", + "mozilla/2.20", "mozilla/2.9", "windows/131003230417", "windows/140312052931", @@ -18803,7 +19787,8 @@ "windows/170419224008", "windows/170613190204", "windows/170922155710", - "windows/171121202507" + "windows/171121202507", + "windows/180122185731" ], "e28393773da845a679f2080cc7fb44a3b7a1c3792cb7eb7729fdcb6a8d99aea7": [ "android/kitkat-cts-release", @@ -18867,7 +19852,8 @@ "windows/170419224008", "windows/170613190204", "windows/170922155710", - "windows/171121202507" + "windows/171121202507", + "windows/180122185731" ], "e3268f6106ba8b665a1a962ddea1459d2a46972f1f2440329b390b895749ad45": [ "macos/10.10.3", @@ -18879,14 +19865,22 @@ "macos/10.12.0", "macos/10.12.1", "macos/10.12.2", - "macos/10.13.0" + "macos/10.13.0", + "macos/10.13.1", + "macos/10.13.2", + "macos/10.13.3" ], "e35d28419ed02025cfa69038cd623962458da5c695fbdea3c22b0bfb25897092": [ "android/oreo-cts-release", + "android/oreo-mr1-cts-release", + "macos/10.13.1", + "macos/10.13.2", + "macos/10.13.3", "mozilla/2.11", "mozilla/2.14", "mozilla/2.16", "mozilla/2.18", + "mozilla/2.20", "windows/160113232859", "windows/160123000836", "windows/160128175153", @@ -18897,7 +19891,8 @@ "windows/170419224008", "windows/170613190204", "windows/170922155710", - "windows/171121202507" + "windows/171121202507", + "windows/180122185731" ], "e389360d0fdbaeb3d250584b4730314e222f39c156a020144e8d960561791506": [ "android/kitkat-cts-release", @@ -18978,6 +19973,7 @@ "android/nougat-cts-release", "android/nougat-mr1-cts-release", "android/oreo-cts-release", + "android/oreo-mr1-cts-release", "macos/10.10.0", "macos/10.10.3", "macos/10.10.4", @@ -18989,6 +19985,9 @@ "macos/10.12.1", "macos/10.12.2", "macos/10.13.0", + "macos/10.13.1", + "macos/10.13.2", + "macos/10.13.3", "macos/10.9.0", "macos/10.9.2", "macos/10.9.4", @@ -18998,6 +19997,7 @@ "mozilla/2.14", "mozilla/2.16", "mozilla/2.18", + "mozilla/2.20", "mozilla/2.9", "windows/080328202117", "windows/080612204220", @@ -19045,7 +20045,8 @@ "windows/170419224008", "windows/170613190204", "windows/170922155710", - "windows/171121202507" + "windows/171121202507", + "windows/180122185731" ], "e3efb6118a92e3b858fd806f690e31d46b95ca1bd756da2b3037fe2f87cc9137": [ "macos/10.9.0", @@ -19066,6 +20067,7 @@ "android/nougat-cts-release", "android/nougat-mr1-cts-release", "android/oreo-cts-release", + "android/oreo-mr1-cts-release", "macos/10.10.0", "macos/10.10.3", "macos/10.10.4", @@ -19077,6 +20079,9 @@ "macos/10.12.1", "macos/10.12.2", "macos/10.13.0", + "macos/10.13.1", + "macos/10.13.2", + "macos/10.13.3", "macos/10.9.0", "macos/10.9.2", "macos/10.9.4", @@ -19133,7 +20138,8 @@ "windows/170419224008", "windows/170613190204", "windows/170922155710", - "windows/171121202507" + "windows/171121202507", + "windows/180122185731" ], "e57210ab812c8df308267cb4291b98e956597ca36ec2b95189ef1723396bcac8": [ "windows/070109202240", @@ -19289,7 +20295,8 @@ "windows/170419224008", "windows/170613190204", "windows/170922155710", - "windows/171121202507" + "windows/171121202507", + "windows/180122185731" ], "e6b8f8766485f807ae7f8dac1670461f07c0a13eef3a1ff717538d7abad391b4": [ "android/kitkat-cts-release", @@ -19399,14 +20406,16 @@ "windows/170419224008", "windows/170613190204", "windows/170922155710", - "windows/171121202507" + "windows/171121202507", + "windows/180122185731" ], "e74fbda55bd564c473a36b441aa799c8a68e077440e8288b9fa1e50e4bbaca11": [ "windows/170228174808", "windows/170419224008", "windows/170613190204", "windows/170922155710", - "windows/171121202507" + "windows/171121202507", + "windows/180122185731" ], "e75e72ed9f560eec6eb4800073a43fc3ad19195a392282017895974a99026b6c": [ "android/kitkat-cts-release", @@ -19421,6 +20430,7 @@ "android/nougat-cts-release", "android/nougat-mr1-cts-release", "android/oreo-cts-release", + "android/oreo-mr1-cts-release", "macos/10.10.0", "macos/10.10.3", "macos/10.10.4", @@ -19432,6 +20442,9 @@ "macos/10.12.1", "macos/10.12.2", "macos/10.13.0", + "macos/10.13.1", + "macos/10.13.2", + "macos/10.13.3", "macos/10.9.0", "macos/10.9.2", "macos/10.9.4", @@ -19441,6 +20454,7 @@ "mozilla/2.14", "mozilla/2.16", "mozilla/2.18", + "mozilla/2.20", "mozilla/2.9", "windows/070109202240", "windows/070201011524", @@ -19494,7 +20508,8 @@ "windows/170419224008", "windows/170613190204", "windows/170922155710", - "windows/171121202507" + "windows/171121202507", + "windows/180122185731" ], "e7685634efacf69ace939a6b255b7b4fabef42935b50a265acb5cb6027e44e70": [ "macos/10.10.0", @@ -19554,7 +20569,8 @@ "windows/170419224008", "windows/170613190204", "windows/170922155710", - "windows/171121202507" + "windows/171121202507", + "windows/180122185731" ], "e793c9b02fd8aa13e21c31228accb08119643b749c898964b1746d46c3d4cbd2": [ "android/lollipop-mr1-cts-release", @@ -19565,14 +20581,19 @@ "android/nougat-cts-release", "android/nougat-mr1-cts-release", "android/oreo-cts-release", + "android/oreo-mr1-cts-release", "macos/10.12.1", "macos/10.12.2", "macos/10.13.0", + "macos/10.13.1", + "macos/10.13.2", + "macos/10.13.3", "mozilla/2.10", "mozilla/2.11", "mozilla/2.14", "mozilla/2.16", "mozilla/2.18", + "mozilla/2.20", "mozilla/2.9", "windows/100927165108", "windows/110125205412", @@ -19609,7 +20630,8 @@ "windows/170419224008", "windows/170613190204", "windows/170922155710", - "windows/171121202507" + "windows/171121202507", + "windows/180122185731" ], "e873d4082a7b4632934f48a5cc1ee500932f661e56c3467c5c84d31447476b0c": [ "windows/070109202240", @@ -19814,6 +20836,7 @@ "android/nougat-cts-release", "android/nougat-mr1-cts-release", "android/oreo-cts-release", + "android/oreo-mr1-cts-release", "macos/10.10.0", "macos/10.10.3", "macos/10.10.4", @@ -19825,6 +20848,9 @@ "macos/10.12.1", "macos/10.12.2", "macos/10.13.0", + "macos/10.13.1", + "macos/10.13.2", + "macos/10.13.3", "macos/10.9.2", "macos/10.9.4", "macos/10.9.5", @@ -19833,6 +20859,7 @@ "mozilla/2.14", "mozilla/2.16", "mozilla/2.18", + "mozilla/2.20", "mozilla/2.9", "windows/090203164005", "windows/090501224247", @@ -19876,7 +20903,8 @@ "windows/170419224008", "windows/170613190204", "windows/170922155710", - "windows/171121202507" + "windows/171121202507", + "windows/180122185731" ], "eac0220c5c9fecc5121d3720872d06707b5266be25d4ebb56ab804bbbf85fe03": [ "macos/10.10.0", @@ -19936,7 +20964,8 @@ "windows/170419224008", "windows/170613190204", "windows/170922155710", - "windows/171121202507" + "windows/171121202507", + "windows/180122185731" ], "eb04cf5eb1f39afa762f2bb120f296cba520c1b97db1589565b81cb9a17b7244": [ "android/kitkat-cts-release", @@ -19951,6 +20980,7 @@ "android/nougat-cts-release", "android/nougat-mr1-cts-release", "android/oreo-cts-release", + "android/oreo-mr1-cts-release", "macos/10.10.0", "macos/10.10.3", "macos/10.10.4", @@ -19962,6 +20992,9 @@ "macos/10.12.1", "macos/10.12.2", "macos/10.13.0", + "macos/10.13.1", + "macos/10.13.2", + "macos/10.13.3", "macos/10.9.0", "macos/10.9.2", "macos/10.9.4", @@ -19971,6 +21004,7 @@ "mozilla/2.14", "mozilla/2.16", "mozilla/2.18", + "mozilla/2.20", "mozilla/2.9", "windows/070109202240", "windows/070201011524", @@ -20024,7 +21058,8 @@ "windows/170419224008", "windows/170613190204", "windows/170922155710", - "windows/171121202507" + "windows/171121202507", + "windows/180122185731" ], "eb7e05aa58e7bd328a282bf8867033f3c035342b516ee85c01673dffffbbfe58": [ "windows/090203164005", @@ -20069,16 +21104,20 @@ "windows/170419224008", "windows/170613190204", "windows/170922155710", - "windows/171121202507" + "windows/171121202507", + "windows/180122185731" ], "ebc5570c29018c4d67b1aa127baf12f703b4611ebc17b7dab5573894179b93fa": [ "android/oreo-cts-release", + "android/oreo-mr1-cts-release", "mozilla/2.11", "mozilla/2.14", "mozilla/2.16", "mozilla/2.18", + "mozilla/2.20", "windows/170922155710", - "windows/171121202507" + "windows/171121202507", + "windows/180122185731" ], "ebd41040e4bb3ec742c9e381d31ef2a41a48b6685c96e7cef3c1df6cd4331c99": [ "android/kitkat-cts-release", @@ -20093,6 +21132,7 @@ "android/nougat-cts-release", "android/nougat-mr1-cts-release", "android/oreo-cts-release", + "android/oreo-mr1-cts-release", "macos/10.10.0", "macos/10.10.3", "macos/10.10.4", @@ -20104,6 +21144,9 @@ "macos/10.12.1", "macos/10.12.2", "macos/10.13.0", + "macos/10.13.1", + "macos/10.13.2", + "macos/10.13.3", "macos/10.9.0", "macos/10.9.2", "macos/10.9.4", @@ -20113,6 +21156,7 @@ "mozilla/2.14", "mozilla/2.16", "mozilla/2.18", + "mozilla/2.20", "mozilla/2.9", "windows/080328202117", "windows/080612204220", @@ -20160,7 +21204,8 @@ "windows/170419224008", "windows/170613190204", "windows/170922155710", - "windows/171121202507" + "windows/171121202507", + "windows/180122185731" ], "ebf3c02a8789b1fb7d511995d663b72906d913ce0d5e10568a8a77e2586167e7": [ "android/kitkat-cts-release", @@ -20296,7 +21341,8 @@ "windows/170419224008", "windows/170613190204", "windows/170922155710", - "windows/171121202507" + "windows/171121202507", + "windows/180122185731" ], "edf7ebbca27a2a384d387b7d4010c666e2edb4843e4c29b4ae1d5b9332e6b24d": [ "android/kitkat-cts-release", @@ -20311,6 +21357,7 @@ "android/nougat-cts-release", "android/nougat-mr1-cts-release", "android/oreo-cts-release", + "android/oreo-mr1-cts-release", "macos/10.10.0", "macos/10.10.3", "macos/10.10.4", @@ -20322,6 +21369,9 @@ "macos/10.12.1", "macos/10.12.2", "macos/10.13.0", + "macos/10.13.1", + "macos/10.13.2", + "macos/10.13.3", "macos/10.9.2", "macos/10.9.4", "macos/10.9.5", @@ -20330,6 +21380,7 @@ "mozilla/2.14", "mozilla/2.16", "mozilla/2.18", + "mozilla/2.20", "mozilla/2.9", "windows/111018233154", "windows/120125230451", @@ -20359,7 +21410,8 @@ "windows/170419224008", "windows/170613190204", "windows/170922155710", - "windows/171121202507" + "windows/171121202507", + "windows/180122185731" ], "eec5496b988ce98625b934092eec2908bed0b0f316c2d4730c84eaf1f3d34881": [ "android/kitkat-cts-release", @@ -20374,6 +21426,7 @@ "android/nougat-cts-release", "android/nougat-mr1-cts-release", "android/oreo-cts-release", + "android/oreo-mr1-cts-release", "macos/10.10.0", "macos/10.10.3", "macos/10.10.4", @@ -20385,6 +21438,9 @@ "macos/10.12.1", "macos/10.12.2", "macos/10.13.0", + "macos/10.13.1", + "macos/10.13.2", + "macos/10.13.3", "macos/10.9.2", "macos/10.9.4", "macos/10.9.5", @@ -20393,6 +21449,7 @@ "mozilla/2.14", "mozilla/2.16", "mozilla/2.18", + "mozilla/2.20", "mozilla/2.9", "windows/120223022238", "windows/120406192127", @@ -20420,7 +21477,8 @@ "windows/170419224008", "windows/170613190204", "windows/170922155710", - "windows/171121202507" + "windows/171121202507", + "windows/180122185731" ], "eefca888db442cea1f03fac5de5b1af210ae03f5e1658ddb880c645e78624546": [ "windows/091013033632", @@ -20461,6 +21519,7 @@ "android/nougat-cts-release", "android/nougat-mr1-cts-release", "android/oreo-cts-release", + "android/oreo-mr1-cts-release", "macos/10.10.0", "macos/10.10.3", "macos/10.10.4", @@ -20472,6 +21531,9 @@ "macos/10.12.1", "macos/10.12.2", "macos/10.13.0", + "macos/10.13.1", + "macos/10.13.2", + "macos/10.13.3", "macos/10.9.0", "macos/10.9.2", "macos/10.9.4", @@ -20533,7 +21595,8 @@ "windows/170419224008", "windows/170613190204", "windows/170922155710", - "windows/171121202507" + "windows/171121202507", + "windows/180122185731" ], "efb5157e9c66caa1dcc63c9fac0127cde83b7a426c4579b7b43a41ba46a56deb": [ "windows/111018233154", @@ -20564,7 +21627,8 @@ "windows/170419224008", "windows/170613190204", "windows/170922155710", - "windows/171121202507" + "windows/171121202507", + "windows/180122185731" ], "f00355eef101c7df4e46cce6417dffce3db82dbb1369c3b439c4e33bee445c42": [ "windows/070201011524", @@ -20618,7 +21682,8 @@ "windows/170419224008", "windows/170613190204", "windows/170922155710", - "windows/171121202507" + "windows/171121202507", + "windows/180122185731" ], "f008733ec500dc498763cc9264c6fcea40ec22000e927d053ce9c90bfa046cb2": [ "macos/10.10.0", @@ -20632,6 +21697,9 @@ "macos/10.12.1", "macos/10.12.2", "macos/10.13.0", + "macos/10.13.1", + "macos/10.13.2", + "macos/10.13.3", "macos/10.9.0", "macos/10.9.2", "macos/10.9.4", @@ -20686,7 +21754,8 @@ "windows/170419224008", "windows/170613190204", "windows/170922155710", - "windows/171121202507" + "windows/171121202507", + "windows/180122185731" ], "f09b122c7114f4a09bd4ea4f4a99d558b46e4c25cd81140d29c05613914c3841": [ "android/kitkat-cts-release", @@ -20712,6 +21781,9 @@ "macos/10.12.1", "macos/10.12.2", "macos/10.13.0", + "macos/10.13.1", + "macos/10.13.2", + "macos/10.13.3", "macos/10.9.2", "macos/10.9.4", "macos/10.9.5", @@ -20745,7 +21817,8 @@ "windows/170419224008", "windows/170613190204", "windows/170922155710", - "windows/171121202507" + "windows/171121202507", + "windows/180122185731" ], "f1b13f5c9a326403b0f31bbe7699cd17c7d1c0b981586dd1a7b219c52508fe99": [ "windows/070702210503", @@ -20797,7 +21870,8 @@ "windows/170419224008", "windows/170613190204", "windows/170922155710", - "windows/171121202507" + "windows/171121202507", + "windows/180122185731" ], "f1c1b50ae5a20dd8030ec9f6bc24823dd367b5255759b4e71b61fce9f7375d73": [ "android/kitkat-cts-release", @@ -20812,6 +21886,7 @@ "android/nougat-cts-release", "android/nougat-mr1-cts-release", "android/oreo-cts-release", + "android/oreo-mr1-cts-release", "macos/10.10.0", "macos/10.10.3", "macos/10.10.4", @@ -20823,6 +21898,9 @@ "macos/10.12.1", "macos/10.12.2", "macos/10.13.0", + "macos/10.13.1", + "macos/10.13.2", + "macos/10.13.3", "macos/10.9.0", "macos/10.9.2", "macos/10.9.4", @@ -20832,6 +21910,7 @@ "mozilla/2.14", "mozilla/2.16", "mozilla/2.18", + "mozilla/2.20", "mozilla/2.9", "windows/070109202240", "windows/070201011524", @@ -20885,7 +21964,8 @@ "windows/170419224008", "windows/170613190204", "windows/170922155710", - "windows/171121202507" + "windows/171121202507", + "windows/180122185731" ], "f1f3cc207a6d47947b8cb9c30422229de0d71fb867e0b9a3eda08e0e1736bc28": [ "windows/070109202240", @@ -20942,7 +22022,8 @@ "windows/170419224008", "windows/170613190204", "windows/170922155710", - "windows/171121202507" + "windows/171121202507", + "windows/180122185731" ], "f356bea244b7a91eb35d53ca9ad7864ace018e2d35d5f8f96ddf68a6f41aa474": [ "android/kitkat-cts-release", @@ -20956,14 +22037,19 @@ "android/nougat-cts-release", "android/nougat-mr1-cts-release", "android/oreo-cts-release", + "android/oreo-mr1-cts-release", "macos/10.12.1", "macos/10.12.2", "macos/10.13.0", + "macos/10.13.1", + "macos/10.13.2", + "macos/10.13.3", "mozilla/2.10", "mozilla/2.11", "mozilla/2.14", "mozilla/2.16", "mozilla/2.18", + "mozilla/2.20", "mozilla/2.9", "windows/110919210309", "windows/111018233154", @@ -20994,7 +22080,8 @@ "windows/170419224008", "windows/170613190204", "windows/170922155710", - "windows/171121202507" + "windows/171121202507", + "windows/180122185731" ], "f375e2f77a108bacc4234894a9af308edeca1acd8fbde0e7aaa9634e9daf7e1c": [ "windows/091029013045", @@ -21076,7 +22163,8 @@ "windows/170419224008", "windows/170613190204", "windows/170922155710", - "windows/171121202507" + "windows/171121202507", + "windows/180122185731" ], "f4336bc2ac75950beccf1c1f2f9da6dddafd1f41161ca71f59c76889bd474033": [ "windows/110919210309", @@ -21108,7 +22196,8 @@ "windows/170419224008", "windows/170613190204", "windows/170922155710", - "windows/171121202507" + "windows/171121202507", + "windows/180122185731" ], "f4c149551a3013a35bc7bffe17a7f3449bc1ab5b5a0ae74b06c23b90004c0104": [ "android/kitkat-cts-release", @@ -21268,6 +22357,7 @@ "android/nougat-cts-release", "android/nougat-mr1-cts-release", "android/oreo-cts-release", + "android/oreo-mr1-cts-release", "macos/10.10.0", "macos/10.10.3", "macos/10.10.4", @@ -21279,6 +22369,9 @@ "macos/10.12.1", "macos/10.12.2", "macos/10.13.0", + "macos/10.13.1", + "macos/10.13.2", + "macos/10.13.3", "macos/10.9.2", "macos/10.9.4", "macos/10.9.5", @@ -21308,7 +22401,8 @@ "windows/170419224008", "windows/170613190204", "windows/170922155710", - "windows/171121202507" + "windows/171121202507", + "windows/180122185731" ], "f9e67d336c51002ac054c632022d66dda2e7e3fff10ad061ed31d8bbb410cfb2": [ "android/kitkat-cts-release", @@ -21323,6 +22417,7 @@ "android/nougat-cts-release", "android/nougat-mr1-cts-release", "android/oreo-cts-release", + "android/oreo-mr1-cts-release", "macos/10.10.0", "macos/10.10.3", "macos/10.10.4", @@ -21334,6 +22429,9 @@ "macos/10.12.1", "macos/10.12.2", "macos/10.13.0", + "macos/10.13.1", + "macos/10.13.2", + "macos/10.13.3", "macos/10.9.0", "macos/10.9.2", "macos/10.9.4", @@ -21343,6 +22441,7 @@ "mozilla/2.14", "mozilla/2.16", "mozilla/2.18", + "mozilla/2.20", "mozilla/2.9", "windows/070109202240", "windows/070201011524", @@ -21396,7 +22495,8 @@ "windows/170419224008", "windows/170613190204", "windows/170922155710", - "windows/171121202507" + "windows/171121202507", + "windows/180122185731" ], "fabcf5197cdd7f458ac33832d3284021db2425fd6bea7a2e69b7486e8f51f9cc": [ "macos/10.10.0", @@ -21410,6 +22510,9 @@ "macos/10.12.1", "macos/10.12.2", "macos/10.13.0", + "macos/10.13.1", + "macos/10.13.2", + "macos/10.13.3", "macos/10.9.2", "macos/10.9.4", "macos/10.9.5", @@ -21433,13 +22536,15 @@ "windows/170419224008", "windows/170613190204", "windows/170922155710", - "windows/171121202507" + "windows/171121202507", + "windows/180122185731" ], "fad540811afae0dc767cdf6572a088fa3ce8493dd82b3b869a67d10aab4e8124": [ "windows/170419224008", "windows/170613190204", "windows/170922155710", - "windows/171121202507" + "windows/171121202507", + "windows/180122185731" ], "fb47d92a9909fd4fa9bec02737543e1f3514ced747407a8d9cfa397b0915067c": [ "windows/120223022238", @@ -21468,7 +22573,8 @@ "windows/170419224008", "windows/170613190204", "windows/170922155710", - "windows/171121202507" + "windows/171121202507", + "windows/180122185731" ], "fc0a0fe27c9dc13c81238a5913a1daf8184168beb7e5a4512a771fd4f453651d": [ "windows/070109202240", @@ -21509,7 +22615,8 @@ "windows/170419224008", "windows/170613190204", "windows/170922155710", - "windows/171121202507" + "windows/171121202507", + "windows/180122185731" ], "fcbfe2886206f72b27593c8b070297e12d769ed10ed7930705a8098effc14d17": [ "android/kitkat-cts-release", @@ -21524,6 +22631,7 @@ "android/nougat-cts-release", "android/nougat-mr1-cts-release", "android/oreo-cts-release", + "android/oreo-mr1-cts-release", "macos/10.10.0", "macos/10.10.3", "macos/10.10.4", @@ -21535,6 +22643,9 @@ "macos/10.12.1", "macos/10.12.2", "macos/10.13.0", + "macos/10.13.1", + "macos/10.13.2", + "macos/10.13.3", "macos/10.9.2", "macos/10.9.4", "macos/10.9.5", @@ -21578,7 +22689,8 @@ "windows/170419224008", "windows/170613190204", "windows/170922155710", - "windows/171121202507" + "windows/171121202507", + "windows/180122185731" ], "fd73dad31c644ff1b43bef0ccdda96710b9cd9875eca7e31707af3e96d522bbd": [ "android/kitkat-cts-release", @@ -21593,6 +22705,7 @@ "android/nougat-cts-release", "android/nougat-mr1-cts-release", "android/oreo-cts-release", + "android/oreo-mr1-cts-release", "macos/10.10.0", "macos/10.10.3", "macos/10.10.4", @@ -21604,6 +22717,9 @@ "macos/10.12.1", "macos/10.12.2", "macos/10.13.0", + "macos/10.13.1", + "macos/10.13.2", + "macos/10.13.3", "macos/10.9.2", "macos/10.9.4", "macos/10.9.5", @@ -21612,6 +22728,7 @@ "mozilla/2.14", "mozilla/2.16", "mozilla/2.18", + "mozilla/2.20", "mozilla/2.9", "windows/110919210309", "windows/111018233154", @@ -21642,7 +22759,8 @@ "windows/170419224008", "windows/170613190204", "windows/170922155710", - "windows/171121202507" + "windows/171121202507", + "windows/180122185731" ], "fe7114d07a147759891ff37b4f53eb43568296bc3bf89bc12cafb186985ef28d": [ "windows/071219233937", @@ -21692,7 +22810,8 @@ "windows/170419224008", "windows/170613190204", "windows/170922155710", - "windows/171121202507" + "windows/171121202507", + "windows/180122185731" ], "fe863d0822fe7a2353fa484d5924e875656d3dc9fb58771f6f616f9d571bc592": [ "macos/10.10.0", @@ -21706,6 +22825,9 @@ "macos/10.12.1", "macos/10.12.2", "macos/10.13.0", + "macos/10.13.1", + "macos/10.13.2", + "macos/10.13.3", "macos/10.9.2", "macos/10.9.4", "macos/10.9.5" @@ -21723,6 +22845,7 @@ "android/nougat-cts-release", "android/nougat-mr1-cts-release", "android/oreo-cts-release", + "android/oreo-mr1-cts-release", "macos/10.10.0", "macos/10.10.3", "macos/10.10.4", @@ -21734,6 +22857,9 @@ "macos/10.12.1", "macos/10.12.2", "macos/10.13.0", + "macos/10.13.1", + "macos/10.13.2", + "macos/10.13.3", "macos/10.9.0", "macos/10.9.2", "macos/10.9.4", @@ -21743,6 +22869,7 @@ "mozilla/2.14", "mozilla/2.16", "mozilla/2.18", + "mozilla/2.20", "mozilla/2.9", "windows/070109202240", "windows/070201011524", @@ -21795,7 +22922,8 @@ "windows/170419224008", "windows/170613190204", "windows/170922155710", - "windows/171121202507" + "windows/171121202507", + "windows/180122185731" ], "ffcef2224e29b0b36ec8314e686822f3ac0f1c5e0c2d5c0eb2484ce7e2540fd0": [ "windows/070109202240", @@ -21842,19 +22970,21 @@ "windows/151119231843" ] }, - "last_spki_id": 490, + "last_spki_id": 492, "spkis": { "004124ad6037fd5f3319e7a23d4d9c811f5598d66c4754155b0aaa9e8f00621f": { "fingerprints": [ "ddff53ecd7743b60bb7b2795ff5732fa785f9a14df1120fb40a38cf84ca2a566" ], - "id": 357 + "id": 357, + "legacy": true }, "006cb226a772c7182d7772383e373f0f229e7dfe3444810a8d6e50905d20d661": { "fingerprints": [ "f008733ec500dc498763cc9264c6fcea40ec22000e927d053ce9c90bfa046cb2" ], - "id": 251 + "id": 251, + "legacy": true }, "006d7be7555dd82026442c4f1a27a80e89a1989cb87b34448ed2194c18196d5e": { "fingerprints": [ @@ -21867,32 +22997,37 @@ "fingerprints": [ "6f2bc4cb632c24eae6782c0f39758932d1e1dc9b3e070f9303073fff38b288e2" ], - "id": 283 + "id": 283, + "legacy": true }, "0206ead163b10ea2f8620868ebd7a15f64a20250d16cd57d6e87c4fff1a2197c": { "fingerprints": [ "d80fef910ae3f104723b045cec2d019f441ce6213adf156791e70c1790110a31" ], - "id": 456 + "id": 456, + "legacy": true }, "02376d0908ac23041cc7d666d9daf192554f7fc36317aa9cb800908616b28af8": { "fingerprints": [ "847df6a78497943f27fc72eb93f9a637320a02b561d0a91b09e87a7807ed7c61" ], - "id": 411 + "id": 411, + "legacy": true }, "023c81cce8e7c64fa942d3c15048707d35d9bb5b87f4f544c5bf1bc5643af2fa": { "fingerprints": [ "83ce3c1229688a593d485f81973c0f9195431eda37cc5e36430e79c7a888638b", "797e51f883e855d021e5c770566692999407895593235def52a011f716f8b6bf" ], - "id": 69 + "id": 69, + "legacy": true }, "04a6ea654b23658973c98198c64a3a691c0da72ebebd9aebf75324cde6960eaa": { "fingerprints": [ "c1cf0b52096435e3f1b71daaec455a2311c8404f5583a9e213c69d857d943305" ], - "id": 157 + "id": 157, + "legacy": true }, "051cf9fa95e40e9b83edaeda6961f6168c7879c4660172479cdd51ab03cea62b": { "fingerprints": [ @@ -21904,7 +23039,8 @@ "fingerprints": [ "8c7209279ac04e275e16d07fd3b775e80154b5968046e31f52dd25766324e9a7" ], - "id": 136 + "id": 136, + "legacy": true }, "05570ae6eb0fceb4210e6db79486b7094caf200401e149b6677441b5f25e449b": { "fingerprints": [ @@ -21922,19 +23058,22 @@ "fingerprints": [ "3ccc3ccfe45496d07b620dbf1328e8a1490018f48633c8a28a995ca60408b0be" ], - "id": 309 + "id": 309, + "legacy": true }, "0656f5955204c8d2bc8b1ca475e2a4fa6e124d124512784157c858b55471141a": { "fingerprints": [ "bc23f98a313cb92de3bbfc3a5a9f4461ac39494c4ae15a9e9df131e99b73019a" ], - "id": 78 + "id": 78, + "legacy": true }, "06c7bd9553f710e058eb27b15d47dd62d7fd4352d91da96e1efc50e15354b8d7": { "fingerprints": [ "1594cb5b826c315de3bc932c56895ff23a3a988b5dc1f034d214dfd858d89ee8" ], - "id": 302 + "id": 302, + "legacy": true }, "07e854f26a7cbd389927aa041bfef1b6cd21dd143818ad947dc655a9e587fe88": { "fingerprints": [ @@ -21947,7 +23086,8 @@ "07453d53793bf41819a5251c69f88e2bb344b59ca828b5a543781599eaf3d602", "39f6033ca664cedb216744d3c6f2b2e8e3cebd6869f7dff47e0db91a79c416f8" ], - "id": 338 + "id": 338, + "legacy": true }, "08b3a6335fce5ef48f8f0e543986c07fd18a3b1226129f61864bbd5bdd1f1cc9": { "fingerprints": [ @@ -21959,13 +23099,15 @@ "fingerprints": [ "58d017279cd4dc63abddb196a6c9906c30c4e08783eae8c1609954d69355596b" ], - "id": 114 + "id": 114, + "legacy": true }, "0999bf900bd5c297865e21e1aade6cf6bb3a94d11ae5ea798442a4e2f813241f": { "fingerprints": [ "8dbb5a7c06c20ef62dd912a36740992ff6e1e8583d42ede257c3affd7c769399" ], - "id": 329 + "id": 329, + "legacy": true }, "0b9fa5a59eed715c26c1020c711b4f6ec42d58b0015e14337a39dad301c5afc3": { "fingerprints": [ @@ -21978,7 +23120,8 @@ "57014f3cbe1782aa9b7921c5e3a95afd26d5727d9475d0142e6b6d27798133c0", "5b38bd129e83d5a0cad23921089490d50d4aae370428f8ddfffffa4c1564e184" ], - "id": 250 + "id": 250, + "legacy": true }, "0c7acaa710226720bbc940349ee2e6148652a89dbf406a232c895f6dc78ebb9a": { "fingerprints": [ @@ -21990,25 +23133,29 @@ "fingerprints": [ "af71a3bca322e5224df546895696ce449a8bd2bd130f7a7ae457767f5c23d8f8" ], - "id": 314 + "id": 314, + "legacy": true }, "0f9c1299557598cf7521bcc8798420a155cec1bb23a57ac37f5120fc9a2057f8": { "fingerprints": [ "a73563e859cbcfa173cf3285debf2578ede15d47a3bee385861ab7a4fb6d7b6e" ], - "id": 433 + "id": 433, + "legacy": true }, "0fe14c264b17bb6f0d653e7a70eb363dbf54be158039eddae5c25711df48c103": { "fingerprints": [ "6fff78e400a70c11011cd85977c459fb5af96a3df0540820d0f4b8607875e58f" ], - "id": 270 + "id": 270, + "legacy": true }, "1069fa47a0aa4f8cf7111b1caea365eeaed10bfff32660def6e0614bfae70875": { "fingerprints": [ "a53125188d2110aa964b02c7b7c6da3203170894e5fb71fffb6667d5e6810a36" ], - "id": 45 + "id": 45, + "legacy": true }, "10ba3485ca8bb6880ab9531a4063e4001555561c7f2e055165f49b2d74fc5f6b": { "fingerprints": [ @@ -22020,25 +23167,29 @@ "fingerprints": [ "a9c77af1bcdfaa3739442b0b2734c68eaf2e9833f0d766fbcaa6f2aeb42dec02" ], - "id": 442 + "id": 442, + "legacy": true }, "112432e4bb848c45549fcbf0c710c566d0082bbbc4e9b38e6c76ad46448128fc": { "fingerprints": [ "afe80a97ea11159190e927e08ec2e60c59a40559483a3fee838a85321b3aeaad" ], - "id": 388 + "id": 388, + "legacy": true }, "1255cabe8152fa64df942f7a47417e29f96c1ce11bf8c84ecbe2815cc1280810": { "fingerprints": [ "9bea11c976fe014764c1be56a6f914b5a560317abd9988393382e5161aa0493c" ], - "id": 469 + "id": 469, + "legacy": true }, "1462009b2de65d6d4d39be892bd2c186490531ce6590e48fe196070d317b60b0": { "fingerprints": [ "739710c5245e33ec8a243a1b20048fc9d5f4528599213845c164d004b8b667f9" ], - "id": 330 + "id": 330, + "legacy": true }, "149f2ee63b9a5e5803240a770dc991fc2e3445e62831c245a49bc4f1f738ff9c": { "fingerprints": [ @@ -22050,13 +23201,15 @@ "fingerprints": [ "c7ba6567de93a798ae1faa791e712d378fae1f93c4397fea441bb7cbe6fd5995" ], - "id": 146 + "id": 146, + "legacy": true }, "15bb28d9207e13f8bc9557dd785eba773bea944e04d7e08ff8aa55ef3194aa20": { "fingerprints": [ "4210f199499a9ac33c8de02ba6dbaa14408bdd8a6e324689c1922d069715a332" ], - "id": 400 + "id": 400, + "legacy": true }, "15e7e717b428feee3af3afd9150dbad497008d3a3ff016964719907bdb01a645": { "fingerprints": [ @@ -22080,31 +23233,36 @@ "fingerprints": [ "f773bc65659f1bc59087bf214eead864010d5887cd2cd84e4f1ba7523fe55640" ], - "id": 300 + "id": 300, + "legacy": true }, "16a9e012d32329f282b10bbf57c7c0b42ae80f6ac9542eb409bc1c2cde50d322": { "fingerprints": [ "341de98b1392abf7f4ab90a960cf25d4bd6ec65b9a51ce6ed067d00ec7ce9b7f" ], - "id": 229 + "id": 229, + "legacy": true }, "16d82d67a1ed8e89f9ab58f7d0fd3eb0d0017687fcaeecd40475f10083a5b593": { "fingerprints": [ "5f960eebd716dbcb4d8a78b996e680ec2547441e69b4e44e98a595502e28a002" ], - "id": 165 + "id": 165, + "legacy": true }, "17755a5c295f3d2d72e6f031a1f07f400c588b9e582b22f17eae31a1590d1185": { "fingerprints": [ "ca2d82a08677072f8ab6764ff035676cfe3e5e325e012172df3f92096db79b85" ], - "id": 52 + "id": 52, + "legacy": true }, "18cfa64518e916cafe985561513cab7a897a54bd23b8e26874c5c7cbd1249cfc": { "fingerprints": [ "85e0dfae3e55a843195f8b08c8349050e4689372f6e133ad0d199af96e95cc08" ], - "id": 317 + "id": 317, + "legacy": true }, "1906c6124dbb438578d00e066d5054c6c37f0fa6028c05545e0994eddaec8629": { "fingerprints": [ @@ -22116,19 +23274,22 @@ "fingerprints": [ "2f274e48aba4ac7b765933101775506dc30ee38ef6acd5c04932cfe041234220" ], - "id": 162 + "id": 162, + "legacy": true }, "19ad98de02155d7e33e9dd21f0e45610fd11d28044b8318bbebf9f6337888df0": { "fingerprints": [ "1e910b40c08184c0ca20468e824502ff2485163f77b03bb73296823f03885621" ], - "id": 417 + "id": 417, + "legacy": true }, "1a421223e89bd87c403b48fa616948470d0f2c21ce2ac7bdd22755061c62ba92": { "fingerprints": [ "7b1a15d7e5e130c579e68fca189257f837b5c188f1b2b2a791e967cc88cc6528" ], - "id": 304 + "id": 304, + "legacy": true }, "1a7a3a1a68dd2361e3f3bb855f3b26fcd88b197d8dd4de06cf1b362ac89ec13b": { "fingerprints": [ @@ -22140,13 +23301,15 @@ "fingerprints": [ "1ba622b36325544ae922afc22ef9d367943794f6e16874f368a733c65c9d5279" ], - "id": 419 + "id": 419, + "legacy": true }, "1c294bc25243768913ed4ad5ed61cb02bfbae0bce6e6e72e5f9658f346b42496": { "fingerprints": [ "6d3795731a95f8b8a471b9aae5c4f05691b1c11a140fd4b981ad891c367fafd3" ], - "id": 244 + "id": 244, + "legacy": true }, "1d75d0831b9e0885394d32c7a1bfdb3dbc1c28e2b0e8391fb135981dbc5ba936": { "fingerprints": [ @@ -22165,13 +23328,15 @@ "fingerprints": [ "4be8b5a1c76c6aead0611918fccf9dbd398b67fb12294758bdf994d0f9682f60" ], - "id": 416 + "id": 416, + "legacy": true }, "1f4224cec84fc99ced881ff6fcfd3e21f8c519c547aa6a5dd3de247302ce50d1": { "fingerprints": [ "e28393773da845a679f2080cc7fb44a3b7a1c3792cb7eb7729fdcb6a8d99aea7" ], - "id": 88 + "id": 88, + "legacy": true }, "2021917e98263945c859c43f1d73cb4139053c414fa03ca3bc7ee88614298f3b": { "fingerprints": [ @@ -22183,49 +23348,57 @@ "fingerprints": [ "ad016f958050e0e7e46fae7dcc50197ed8e3ff0a4b262e5ddcdb3edddc7d6578" ], - "id": 398 + "id": 398, + "legacy": true }, "20e24a5a3393d6c3adc384faf95152e1f9aa7222774028b53c5a34ed0c6cb399": { "fingerprints": [ "527b050527df529c0f7ad00cef1e7ba421788182615c326c8b6d1a2061a0bd7c" ], - "id": 351 + "id": 351, + "legacy": true }, "21ae412566324725ffefc1dccf88f16f8d6bf4dbbb37fe8caba47e8d66c2cdf9": { "fingerprints": [ "fad540811afae0dc767cdf6572a088fa3ce8493dd82b3b869a67d10aab4e8124" ], - "id": 477 + "id": 477, + "legacy": true }, "22050a92836481c2f3c1f8417d37447a167007ac9ba64ea228cb6a1e14c64b8b": { "fingerprints": [ "1aa980c8c0d316f25029978982f033cbb3a3f4188d669f2de6a8d84ee00a1575" ], - "id": 379 + "id": 379, + "legacy": true }, "22076e5aef44bb9a416a28b7d1c44322d7059f60feffa5caf6c5be8447891303": { "fingerprints": [ "cbb5af185e942a2402f9eacbc0ed5bb876eea3c1223623d00447e4f3ba554b65" ], - "id": 226 + "id": 226, + "legacy": true }, "232cbe2d9e6994c1ceb7fbee23ab1657defb6b3564726f1e78951cef3a2b095d": { "fingerprints": [ "fc0a0fe27c9dc13c81238a5913a1daf8184168beb7e5a4512a771fd4f453651d" ], - "id": 339 + "id": 339, + "legacy": true }, "2364d692dccae13da56ad4a07c1325dc575215ff1a071681dfca5dd6ed7c8452": { "fingerprints": [ "1e1a6984b4e76bd709aee3e9c9cf3118eac096dab9cc20dc25faab67297e965a" ], - "id": 422 + "id": 422, + "legacy": true }, "23849d094923d44a4881b63ab185e9be15aac8ef2c3044d934bc7f26e2d2cd69": { "fingerprints": [ "77407312c63a153d5bc00b4e51759cdfdac237dc2a33b67946e98e9bfa680ae3" ], - "id": 115 + "id": 115, + "legacy": true }, "23f2edff3ede90259a9e30f40af8f912a5e5b3694e6938440341f6060e014ffa": { "fingerprints": [ @@ -22237,7 +23410,8 @@ "fingerprints": [ "2a8da2f8d23e0cd3b5871ecfb0f42276ca73230667f474eede71c5ee32cc3ec6" ], - "id": 460 + "id": 460, + "legacy": true }, "2596904dc4d699ae20c2cef4dce47f285937d77464ac370746f52dea76ba0c28": { "fingerprints": [ @@ -22249,7 +23423,8 @@ "fingerprints": [ "0b5eed4e846403cf55e065848440ed2a82758bf5b9aa1f253d4613cfa080ff3f" ], - "id": 61 + "id": 61, + "legacy": true }, "25b41b506e4930952823a6eb9f1d31def645ea38a5c6c6a96d71957e384df058": { "fingerprints": [ @@ -22267,43 +23442,50 @@ "fingerprints": [ "cf56ff46a4a186109dd96584b5eeb58a510c4275b0e5f94f40bbae865e19f673" ], - "id": 140 + "id": 140, + "legacy": true }, "278a6391d3d36b49aa4080f56a36b3c10fba4e28aa6a9592a82e7535113a12d3": { "fingerprints": [ "8f62d7736f99dbd33ee00e10c7e329339c988a5b47ef25f408293cf2426b4d44" ], - "id": 163 + "id": 163, + "legacy": true }, "282fb5cfbaf01518d9704de7884d7a25ff01cf882e994290d5995d5eb6c44988": { "fingerprints": [ "c1727f3b673e6ae7f12f23d789a7be38b918223ef6911c592da1f583444a547e" ], - "id": 489 + "id": 489, + "legacy": true }, "283310819f5e09204995d8ad9ff6fc10746297b5c0ae06bdd1e1124b10a0d7ad": { "fingerprints": [ "956057517ff3bb35049342288c1c9dce852daca652b465e9747253b5f93b1f5e" ], - "id": 343 + "id": 343, + "legacy": true }, "2896b4ddbe61457183cc7ed27bd78ac50a207f6901c5c52e53dc1676f9bb1e06": { "fingerprints": [ "b0877aee2d39274df831f66fdeeb7717557c258fc9eb55231a9f8a647a75433f" ], - "id": 241 + "id": 241, + "legacy": true }, "29e7fdda489e46ee486efd75acc48f251932dc9da1872b31753cd64719567aa5": { "fingerprints": [ "9b14e8f5f6ea167666e76dcd6becc190861d5e8970b99a9470f0231236049704" ], - "id": 441 + "id": 441, + "legacy": true }, "2a29337c3d6224cc53f0bb5e5d5820c0d8848b04871328f090fee3cd6bf821b4": { "fingerprints": [ "4404e33b5e140dcf998051fdfc8028c7c81615c5ee737b111b588233a9b535a0" ], - "id": 83 + "id": 83, + "legacy": true }, "2a4212605aa3e8aecb0fc19806cf3b40b53b95f1a34dbbd6e3ed27230324abb3": { "fingerprints": [ @@ -22315,13 +23497,15 @@ "fingerprints": [ "8177d1a82ba501afdd1e9483ad7da912ee1e9fcb2a5a061fa3c479fa804ce6ba" ], - "id": 359 + "id": 359, + "legacy": true }, "2a8bed32ae680d2d187b9a7afd171d83fd0b935eaf9e2c1b43e80278d2063e39": { "fingerprints": [ "3b222e566711e992300dc0b15ab9473dafdef8c84d0cef7d3317b4c1821d1436" ], - "id": 161 + "id": 161, + "legacy": true }, "2a8f2d8af0eb123898f74c866ac3fa669054e23c17bc7a95bd0234192dc635d0": { "fingerprints": [ @@ -22339,7 +23523,8 @@ "fingerprints": [ "56ce347cc6df4c35943dfdeaee023f9739a3f1cedeee0cd88dc2386bc8a91eaf" ], - "id": 311 + "id": 311, + "legacy": true }, "2bcee858158cf5465fc9d76f0dfa312fef25a4dca8501da9b46b67d1fbfa1b64": { "fingerprints": [ @@ -22352,33 +23537,38 @@ "fingerprints": [ "ad7539e5cdc985fa95244055a9202d63460ec921467d034cfdbe87ec6d00fedc" ], - "id": 438 + "id": 438, + "legacy": true }, "2da8f9ea3454d21146464a3f9d028dc4c7fbb57b1c52c73c2b0572a2f599a2d3": { "fingerprints": [ "43f257412d440d627476974f877da8f1fc2444565a367ae60eddc27a412531ae" ], - "id": 269 + "id": 269, + "legacy": true }, "2dc9470be63ef4acf1bd828609402bb7b87bd99638a643934e88682d1be8c308": { "fingerprints": [ "d17cd8ecd586b712238a482ce46fa5293970742f276d8ab6a9e46ee0288f3355", "51847c8cbd2e9a72c91e292d2ae247d7de1e3fd270547a20ef7d610f38b8842c" ], - "id": 248 + "id": 248, + "legacy": true }, "2dee5171596ab8f3cd3c7635fea8e6c3006aa9e31db39d03a7480ddb2428a33e": { "fingerprints": [ "f5074a8f5b9a5b8142f34abe152f60364d770eae75ee3eeceb45b6b996509788", "ba7f1136389075b8e86c53c095fa14f5c83b6b017a0244ed7637114620d3a3b1" ], - "id": 264 + "id": 264, + "legacy": true }, "2e00915a9f7be06ab2370c7b7c200c0a96d5ac6a50ce1874dbefde4022d4de8e": { "fingerprints": [ "c57a3acbe8c06ba1988a83485bf326f2448775379849de01ca43571af357e74b" ], - "id": 272 + "id": 272, + "legacy": true }, "2fc5667a4b9a2678ed6ac6ad25465fcbf6094bfcd9504097c7a8fa47ade5e888": { "fingerprints": [ @@ -22391,43 +23581,50 @@ "fingerprints": [ "407c276bead2e4af0661ef6697341dec0a1f9434e4eafb2d3d32a90549d9de4a" ], - "id": 427 + "id": 427, + "legacy": true }, "3027a298fa57314dc0e3dd1019411b8f404c43c3f934ce3bdf856512c80aa15c": { "fingerprints": [ "fe863d0822fe7a2353fa484d5924e875656d3dc9fb58771f6f616f9d571bc592" ], - "id": 256 + "id": 256, + "legacy": true }, "309f13d49ea66f523241b55524744464e28cc1b82ef79b64e4d581880dcd771f": { "fingerprints": [ "6639d13cab85df1ad9a23c443b3a60901e2b138d456fa71183578108884ec6bf" ], - "id": 237 + "id": 237, + "legacy": true }, "30ab1bcd7bed1ff2679f71228820420a7063c6cead7ec30d4a016154876dddb5": { "fingerprints": [ "c57bacf238f9336c3dfba62d12bcf5823603e5842c44e62f5448cc7e5f4cad59" ], - "id": 280 + "id": 280, + "legacy": true }, "30b71c4f9122476e761e620eec42bfa5f84c493cd49bbb1834b26e555f60de40": { "fingerprints": [ "00ab444abd6bdba33da8de569ac4ecde326d1be1a61442d5eec3975a0c243f04" ], - "id": 360 + "id": 360, + "legacy": true }, "31512680233f5f2a1f29437f56d4988cf0afc41cc6c5da6275928e9c0beade27": { "fingerprints": [ "363f3c849eab03b0a2a0f636d7b86d04d3ac7fcfe26a0a9121ab9795f6e176df" ], - "id": 254 + "id": 254, + "legacy": true }, "31de0cb19f2adbb0d1cd7b1b31ef8ee3eb59b74459aef94b480beeeeb85c64c9": { "fingerprints": [ "f4c149551a3013a35bc7bffe17a7f3449bc1ab5b5a0ae74b06c23b90004c0104" ], - "id": 147 + "id": 147, + "legacy": true }, "3219b09114ff495a3eb6eb00c2efeab34002ae5f0a56c7679ea087a3fa037e4f": { "fingerprints": [ @@ -22446,7 +23643,8 @@ "fingerprints": [ "e74fbda55bd564c473a36b441aa799c8a68e077440e8288b9fa1e50e4bbaca11" ], - "id": 471 + "id": 471, + "legacy": true }, "3380709af3b096be3cc2a40548142c0a520028db09e2cb77ae2206616ab6cbb4": { "fingerprints": [ @@ -22458,13 +23656,15 @@ "fingerprints": [ "959dc5880c457cd92e5447aaa5609db09ed47bd02c17a0edefdc819e756c74e5" ], - "id": 233 + "id": 233, + "legacy": true }, "33fa5a5300613d466e6f85c8051695bed5d1fad59f25e040acda0472a74f3c20": { "fingerprints": [ "d3d607a9ff24a19523b6da9d2c649446f8788cb96d9fd130972e120c13677730" ], - "id": 458 + "id": 458, + "legacy": true }, "348767cdad3bdd28b2b8dd5351aec30c68cec5cd69d276df3827dbc4f5806464": { "fingerprints": [ @@ -22476,13 +23676,15 @@ "fingerprints": [ "21db20123660bb2ed418205da11ee7a85a65e2bc6e55b5af7e7899c8a266d92e" ], - "id": 138 + "id": 138, + "legacy": true }, "3551de58a7d79cd980283df81790d63a982c1a63b30482ec5821db7661554ef9": { "fingerprints": [ "35ae5bddd8f7ae635cffba5682a8f00b95f48462c7108ee9a0e5292b074aafb2" ], - "id": 150 + "id": 150, + "legacy": true }, "36abc32656acfc645c61b71613c4bf21c787f5cabbee48348d58597803d7abc9": { "fingerprints": [ @@ -22506,37 +23708,43 @@ "fingerprints": [ "8f9adb6d895dab5adf5c3d3fab83927be0fb64ef82485c62280d584e8bd55d22" ], - "id": 459 + "id": 459, + "legacy": true }, "381a3fc7a8b082fa28613a4d07f2c7553f4e1918ee07caa9e8b7cede5a9ca06a": { "fingerprints": [ "d487a56f83b07482e85e963394c1ecc2c9e51d0903ee946b02c301581ed99e16" ], - "id": 192 + "id": 192, + "legacy": true }, "3861d7b6961fcdb2120456ff6fc2eb7704b1a741b4bd933a8376f5e1915ca698": { "fingerprints": [ "0791ca0749b20782aad3c7d7bd0cdfc9485835843eb2d7996009ce43ab6c6927" ], - "id": 101 + "id": 101, + "legacy": true }, "3a0d885cb346d8f01fd300af1546f6355c00690e340ed98f346e77b574be3fd8": { "fingerprints": [ "6e5e93ae867fd3e3e78304e054d1a6aeaed0295d58c0e3fc4c9ffe310a3488cc" ], - "id": 303 + "id": 303, + "legacy": true }, "3a6c24e80f681d8b1047cec051c27594f885ba0887a26379092dfef506160e9b": { "fingerprints": [ "06a2c9a3379ab3c156159a27ca9ecdbd4ef75309b409cf70aeca9a12330f380e" ], - "id": 279 + "id": 279, + "legacy": true }, "3a803e7c0a43a29fd73672e3d0bb2c3653d948ede0b3cb1db4ce75a857e89af1": { "fingerprints": [ "b7b12b171f821daa990cd0fe5087b128448ba8e5184f84c51e02b5c8fb962b24" ], - "id": 143 + "id": 143, + "legacy": true }, "3b0d73b4be4a854adc3e51d7ef9fa48aefbb2cdd824d67bdc7d7d09a2abc2d43": { "fingerprints": [ @@ -22548,19 +23756,22 @@ "fingerprints": [ "62b9267266212832a8e22dab933d91c7011274acf71703f9cc97833751a6e94f" ], - "id": 14 + "id": 14, + "legacy": true }, "3bde97686e3af51d3f572c4888c12bd1d1e097f12f49ec3c92896551e36f0085": { "fingerprints": [ "6cf5f658436d10507eba9df463987480bc8560a8e26ef4691e1d3c9a878a0952" ], - "id": 245 + "id": 245, + "legacy": true }, "3c196f84e2a0c61fec18bacabd31783b574517aad8ebc6ce6d1d7dc82b3c50df": { "fingerprints": [ "527a42267daea8d8f54e91d282d5c25b615bc0dc73dc63a58f916c4ed5bf59ac" ], - "id": 318 + "id": 318, + "legacy": true }, "3c35e164bedd2cf12beb83ecff78b5e80da8158d2830217e4ebffce8928899a6": { "fingerprints": [ @@ -22572,49 +23783,57 @@ "fingerprints": [ "67ec2059fbf52d2e6ab51a5a9b3fc2e1dcd658a1ef3a8f31107bc98028b494a2" ], - "id": 315 + "id": 315, + "legacy": true }, "3d8d061edcf7b3d45995ba4341328d1be7b7eb4e9d14fee70d2f18ad68bea7c5": { "fingerprints": [ "732ff5bc473c33efaad9b187fb459a732ffbeea59df0fdfb8e2fb5def4032afe" ], - "id": 436 + "id": 436, + "legacy": true }, "3ea7b5c045a99a9771e2dea8e8098ba2732d17ceee82279552feee905530f35f": { "fingerprints": [ "075bfcca2d55ae6e35742c32afd0ca8ea4c958feefc23224999541c033d69c8d" ], - "id": 420 + "id": 420, + "legacy": true }, "3ec18dfeb894a9ea20eb2cd40c693e2a29144fe2ec60b4f7b89026040b39aebe": { "fingerprints": [ "a3cc68595dfe7e86d8ad1772a8b5284add54ace3b8a798df47bccafb1fdb84df" ], - "id": 461 + "id": 461, + "legacy": true }, "3ee6b341402851b27e64021a3023aac7c1a0d2def27d5bce5c2dbeb0b22dcc71": { "fingerprints": [ "65353833cf234c79562164f90849c0d104dbabf8ee41064d83e8cbe03ba1c5a5" ], - "id": 481 + "id": 481, + "legacy": true }, "3fab784fc3c9ab9eedc12ecdc0db550f4c3dbfd3e86d78815333c5eba518cb9d": { "fingerprints": [ "a31f093053bd12c1f5c3c6efd498023fd2914d7758d05d698ce084b50626e0e5" ], - "id": 225 + "id": 225, + "legacy": true }, "3fb63c29f47bcc4e6aadb3577ce7ca8543e0bbaba553676b8fd161295bdb9011": { "fingerprints": [ "0b9f26dfca684c2cfce23e4e4dd567c886ba259e1db267f9806f0c5a099711f2" ], - "id": 368 + "id": 368, + "legacy": true }, "4002fcd311d07331567e71bcd971e46048c8dce8d1659711753b3daa2a269afa": { "fingerprints": [ "85fb2f91dd12275a0145b636534f84024ad68b69b8ee88684ff711375805b348" ], - "id": 47 + "id": 47, + "legacy": true }, "40fcfc28875dccbfebcbdf6cd7433312da63c4efcf3bd7b1b505c22020ae0274": { "fingerprints": [ @@ -22626,7 +23845,8 @@ "fingerprints": [ "15d5b8774619ea7d54ce1ca6d0b0c403e037a917f131e8a04e1e6b7a71babce5" ], - "id": 485 + "id": 485, + "legacy": true }, "4223894003a881c5df6bab163db235c221a18d54bf759945820e670da82e3f39": { "fingerprints": [ @@ -22638,98 +23858,114 @@ "fingerprints": [ "2d66a702ae81ba03af8cff55ab318afa919039d9f31b4d64388680f81311b65a" ], - "id": 409 + "id": 409, + "legacy": true }, "42a807cec5ae9c0f03b40ca043ac70468b5219bd75cc5bbea51d921dd100156f": { "fingerprints": [ "5adfa25013bed3710831572de51c4b9a21171c00313249c4cb4719d37fbb8d20" ], - "id": 466 + "id": 466, + "legacy": true }, "431b79fd9355d10dc1b50dbf6a6b62d7a5b6d356541c27605255ca4ca79420c1": { "fingerprints": [ "f563c5c3e512e63b97b5438f2bd4a9ae78a4f9ead92bcc34fe973bdc7c6d2148" ], - "id": 340 + "id": 340, + "legacy": true }, "4376a99396769fd487240ee8b573ad49706a5b9473616acef38409e91586dc1e": { "fingerprints": [ "c2157309d9aee17bf34f4df5e88dbaeba57e0361eb814cbc239f4d54d329a38d" ], - "id": 444 + "id": 444, + "legacy": true }, "439c19ff3edb265ef1a920f74a4802d3dd95ace024e21e5a6ce8e064dc1566cd": { "fingerprints": [ "34bb34e14faed0d3392f2fc441c0ecd5fd88ad88118df2d1ba76cdec1eea10b8" ], - "id": 447 + "id": 447, + "legacy": true }, "43c74262f7492662d2459bcc9899bac54a4ecc01e1a3f5e76558992b40152418": { "fingerprints": [ "a3d7435a18c46b23b6a4f8929cd59050c9168b03a7fad532626f297cac5356e4" ], - "id": 414 + "id": 414, + "legacy": true }, "43cffc359f2e8caa57388ee9f6f1dbe93bf093682a699ac3852e6d1f8579e7f9": { "fingerprints": [ "39df7b682b7b938f84715481ccde8d60d8f22ec598877d0aaac12b59182b0312" ], - "id": 56 + "id": 56, + "legacy": true }, "4462c107c485dd6a5443f5e7a1604416034a374c3f4d10875f1c3715027563af": { "fingerprints": [ "f38406e540d7a9d90cb4a9479299640ffb6df9e224ecc7a01c0d9558d8dad77d" ], - "id": 156 + "id": 156, + "legacy": true }, "44a3d80d3f5348596d80a09842c23a39774439f8b0b919239d2a03dac5ce5213": { "fingerprints": [ "b2f3c4216af7aff72462466dc13cd2810db8eed853eabb9a063a608efc18fbe8" ], - "id": 403 + "id": 403, + "legacy": true }, "44af8afcf1395d2a8e30ef812ce19ceb2e8948dfd21e00fbaa34689f9a24721f": { "fingerprints": [ "c470cf547e2302b977fb29dd71a89a7b6c1f60777b0329f56017f328bf4f6be6" ], - "id": 51 + "id": 51, + "legacy": true }, "463dbb9b0a26ed2616397b643125fbd29b66cf3a46fdb4384b209e78237a1aff": { "fingerprints": [ "2930bd09a07126bdc17288d4f2ad84645ec948607907a97b5ed0b0b05879ef69" ], - "id": 353 + "id": 353, + "legacy": true }, "4691cbfde84a6b6052ddbe152bb0c216ae25a86e5747813dbc0f147f338570be": { "fingerprints": [ "bd81ce3b4f6591d11a67b5fc7a47fdef25521bf9aa4e18b9e3df2e34a7803be8" ], - "id": 2 + "id": 2, + "legacy": true }, "4697a5abea0070a395456fd358e91f72f227d5850933227f1e0bc79ff847bfac": { "fingerprints": [ "2dfcbacadf22a6ff107a51fd3e8b9e17858028879b13f7c3b57b3e1bd2315809" ], - "id": 352 + "id": 352, + "legacy": true }, "479d130bf3fc61dc2f1d508d239a13276ae7b3c9841011a02c1402c7e677bd5f": { "fingerprints": [ "f59db3f45d57fcec94ccd516e6c8ccb20dd4363feb2c44d8656e95f50fdd8df8", "2f1062f8bf84e7eb83a0f64c98d891fbe2c811b17ffac0bce1a6dc9c7c3dcbb7" ], - "id": 263 + "id": 263, + "legacy": true }, "47c7a149ca82fa7ba940a4d711d010625c6cb0b748b17016c46e25ce7acd2b0c": { "fingerprints": [ "92d8092ee77bc9208f0897dc05271894e63ef27933ae537fb983eef0eae3eec8" ], - "id": 266 + "id": 266, + "legacy": true }, "482f76a2a9346dbb077619bbe1efecd54107e992ff4e8f4d70a39e2405d939d4": { "fingerprints": [ "e3efb6118a92e3b858fd806f690e31d46b95ca1bd756da2b3037fe2f87cc9137" ], - "id": 278 + "id": 278, + "legacy": true }, "4905466623ab4178be92ac5cbd6584f7a1e17f27652d5a85af89504ea239aaaa": { "fingerprints": [ @@ -22747,25 +23983,29 @@ "fingerprints": [ "9db930a7bced5a599da673d0bb12c4c6c7ab5b3f88f39c24ee20a24716b379df" ], - "id": 332 + "id": 332, + "legacy": true }, "49b80685d332e072c0e7b720032647e842106104e0b1139ab9e811bfb11ec034": { "fingerprints": [ "940ef46536713d8e2eb4b501e80b6abd8eb4e9928dba44784ce7d7e98595dfe8" ], - "id": 285 + "id": 285, + "legacy": true }, "49cbd83c03cabfa0713b97bc96481d035fd4ebe06f07fab5640ed9232d8110b2": { "fingerprints": [ "c34c5df53080078ffe45b21a7f600469917204f4f0293f1d7209393e5265c04f" ], - "id": 457 + "id": 457, + "legacy": true }, "4a2659666dc0203b916f53d80ad8f61ac30bea161f485cc7527e6a5937e49216": { "fingerprints": [ "8de78655e1be7f7847800b93f694d21d368cc06e033e7fab04bb5eb99da6b700" ], - "id": 188 + "id": 188, + "legacy": true }, "4a49edbd2f8f8230bd5592b313573fe1c172a45fa98011cc1eddbb36ade3fce5": { "fingerprints": [ @@ -22783,37 +24023,43 @@ "fingerprints": [ "b5bd2cb79cbd1907298d6bdf4842e516d8c78fa6fc96d25f71af814e16cc245e" ], - "id": 381 + "id": 381, + "legacy": true }, "4ba6031ca305b09e53bde3705145481d0332b651fe30370dd5254cc4d2cb32f3": { "fingerprints": [ "76ef4762e573206006cbc338b17ca4bc200574a11928d90c3ef31c5e803e6c6f" ], - "id": 328 + "id": 328, + "legacy": true }, "4bdc636f48d21fb68c5a3cd4a20685788043bdb524e7e84d4192c451ee3429b5": { "fingerprints": [ "92bf5119abeccad0b1332dc4e1d05fba75b5679044ee0ca26e931f744f2f33cf" ], - "id": 131 + "id": 131, + "legacy": true }, "4cc29758a2cb9b50109987f37537cf0c55ba2e6798937307a00296b01dffe44a": { "fingerprints": [ "6cfb09893dfdf9457e3303592aa4755bc859ab6ba6a2e11c11cddc2409abda02" ], - "id": 284 + "id": 284, + "legacy": true }, "4d40e7af4304a09de87fbf9896204c055141e3f809b2fe733bb2310fdf98a162": { "fingerprints": [ "6ea54741d004667eed1b4816634aa3a79e6e4b96950f8279dafc8d9bd8812137" ], - "id": 155 + "id": 155, + "legacy": true }, "4e6c1616637199b5077a80ad0c2248c725e576fc8a719989456bc9cafddb7524": { "fingerprints": [ "c795ff8ff20c966688f064a1e091421d3110a3456c17ec2404b998738741f622" ], - "id": 454 + "id": 454, + "legacy": true }, "4eada9b5311e718199d98ea82b95005cba93198ab1f97efcbe8dc6201628f8af": { "fingerprints": [ @@ -22825,25 +24071,29 @@ "fingerprints": [ "209e956af04df3996507c887d356230d6eb49fdbdd2d8a058ff50b8f80f690aa" ], - "id": 470 + "id": 470, + "legacy": true }, "4f7162b974491c98585ec28fe759aa00c330d0b465190a896cc4b616231831fc": { "fingerprints": [ "c1d80ce474a51128b77e794a98aa2d62a0225da3f419e5c7ed73dfbf660e7109" ], - "id": 476 + "id": 476, + "legacy": true }, "508f8c6178af329bb6bb753ab943d9023be796c3adbb6c5cd4664b66feeccae5": { "fingerprints": [ "6ec6614e9a8efd47d6318ffdfd0bf65b493a141f77c38d0b319be1bbbc053dd2" ], - "id": 413 + "id": 413, + "legacy": true }, "5094b73b736adf73a0cbf43e27bf14407b4a36aa363a457fce33949ceba8e649": { "fingerprints": [ "eb7e05aa58e7bd328a282bf8867033f3c035342b516ee85c01673dffffbbfe58" ], - "id": 385 + "id": 385, + "legacy": true }, "50cc86ba96db3263c79a43ead07553d9f56659e6907e72d8c026637a1cdc85dc": { "fingerprints": [ @@ -22861,7 +24111,8 @@ "fingerprints": [ "b644d955fff29b74e3b5687e908ee7c3c9197ba3336cc6328531f6c057d677fd" ], - "id": 406 + "id": 406, + "legacy": true }, "5192438ec369d7ee0ce71f5c6db75f941efbf72e58441715e99eab04c2c8acee": { "fingerprints": [ @@ -22873,13 +24124,15 @@ "fingerprints": [ "c2959db8339e8dbcf6409ca92a66c49fd2e32494940a901143bd7eb72827dec2" ], - "id": 324 + "id": 324, + "legacy": true }, "522c3960328026a1e322389a8a08fedc1b86d9c2b59b33484b77f7ce790635d7": { "fingerprints": [ "687ea89089309d2cfe107db059fb10d676f45d3283aee056903eea0cf3c188f8" ], - "id": 320 + "id": 320, + "legacy": true }, "5375662628fa0a6840aec8c592bf5d8de564ed3efb62c7c932fca8d754d9bbd6": { "fingerprints": [ @@ -22897,7 +24150,8 @@ "fingerprints": [ "c45d7bb08e6d67e62e4235110b564e5f78fd92ef058c840aea4e6455d7585c60" ], - "id": 484 + "id": 484, + "legacy": true }, "56174d3ad971a8944964b189811f3008493a6a90422e3c5804ec838d4f94f622": { "fingerprints": [ @@ -22921,31 +24175,36 @@ "fingerprints": [ "e389360d0fdbaeb3d250584b4730314e222f39c156a020144e8d960561791506" ], - "id": 121 + "id": 121, + "legacy": true }, "57a742a88d3e18fc0bc611bc7976c22edc50011757512b1a7e2e1d069b3ecba0": { "fingerprints": [ "bebce57dcb85f60a93bfa5019edb1a294bf6d81f82d9b4e71f502f0b15a1fc08" ], - "id": 464 + "id": 464, + "legacy": true }, "58044626c34c1a7b158ddb676d9e2e65443d818dab3116231e2d62ab6426a0b7": { "fingerprints": [ "7286ce249fe9e32bd4752257c17cd8f6991a9c1e6f1a3cc73304ed023e6ae4eb" ], - "id": 440 + "id": 440, + "legacy": true }, "5899d913ead119b9cdb7ba2f30efe0df68ad2cd225bdf493e8323a25aa4dbe23": { "fingerprints": [ "d7ba3f4ff8ad05633451470dda3378a3491b90005e5c687d2b68d53647cfdd66" ], - "id": 482 + "id": 482, + "legacy": true }, "58a2a698d86fd8497d41f68e4caeb4a98874f433da913dd26c5ca44d08ff72fe": { "fingerprints": [ "0536801fbb443b3e905fd6d70d8c81eb88551be8061299110d2b4f82e64cade1" ], - "id": 401 + "id": 401, + "legacy": true }, "58dd61feb36ea7d258724371709149cb121337864cacb2d0999ad20739d06477": { "fingerprints": [ @@ -22975,43 +24234,50 @@ "fingerprints": [ "1d4f0596fca2611d09f84c78f2ea565ef2eab9cfc272a1718bd336e6e0ae021a" ], - "id": 346 + "id": 346, + "legacy": true }, "5c41a73ab2c35dfcd771f6fd6e3e8fac9b469d386cadda56a95b646eb48cca34": { "fingerprints": [ "d43af9b35473755c9684fc06d7d8cb70ee5c28e773fb294eb41ee71722924d24" ], - "id": 468 + "id": 468, + "legacy": true }, "5dee74cc343db93f8deaf9e41fbc65b334254b5b23b568fa2814db8b7321ac85": { "fingerprints": [ "4dbb0157a691fa7382289d65c0332ddb1dcb640b40ad10f010a43e20f3afed1e" ], - "id": 296 + "id": 296, + "legacy": true }, "5e7673a17a08d61413cd51b57dbaacbebfe5acb915e3966e5321b13eb9efaaeb": { "fingerprints": [ "6dea86a1e66620a040c3c5943cb215d2ca87fb6ac09b59707e29d2facbd66b4e" ], - "id": 159 + "id": 159, + "legacy": true }, "5efa073f49426344483ab0ddbbdda5e35972f9c47c74ddf98ec42290b251ca97": { "fingerprints": [ "aad9ceed5aa6b1cea28596a8e4e1abed9386d6ebc9d4aad9acde0fa36ba069d0" ], - "id": 271 + "id": 271, + "legacy": true }, "5f665b4060be9efaf6ad739f6b39a1db9847277eb8dc144045376de1009e3127": { "fingerprints": [ "630419aec478cbb4bb8083de9d9cf279752f039def16e46471b679ca93002db0" ], - "id": 164 + "id": 164, + "legacy": true }, "6046136879e56450400f7db2ecd0df1b88f667c1e3fffc52964ff9e2e48e85f5": { "fingerprints": [ "730b619eaa759863c65360b7412e1457eca96844ef2f16d91fcf2efe46a647e9" ], - "id": 344 + "id": 344, + "legacy": true }, "6106c0e3a0a299831875127bd7d3cc1859803d511cac11eb6e0840dd166fc10e": { "fingerprints": [ @@ -23036,13 +24302,15 @@ "fingerprints": [ "e609078465a419780cb6ac4c1c0bfb4653d9d9cc6eb3946eb7f3d69997bad598" ], - "id": 5 + "id": 5, + "legacy": true }, "62a31a5c730dba674ddb25de33df143644375b49af07878a667b813491c73971": { "fingerprints": [ "31eace9b4c9c71734a185680bc24866ca6cbd82b3cb61bcc8706261b59ce1073" ], - "id": 323 + "id": 323, + "legacy": true }, "63d9af9b47b1064d49a10e7b7fd566dbc8caa399459bfc2829c571ad8c6ef34a": { "fingerprints": [ @@ -23054,13 +24322,15 @@ "fingerprints": [ "0c0b6b2bd1edd7b27fead157f8e846b335b784a39f06c47216c8746f64c5ceda" ], - "id": 448 + "id": 448, + "legacy": true }, "651bd66f5c3dc637957ef5185e4fa671c21654b1c0ea49384f44bcb256a5084c": { "fingerprints": [ "3f9da4744ec9676cd38b530e500a463fbcb18165977ff0da6d5993c3fe5fab7c" ], - "id": 362 + "id": 362, + "legacy": true }, "6544ff9adb642c4c3698a60d8143b6b93bcef01365b540f614dcc2a45ab94d31": { "fingerprints": [ @@ -23073,19 +24343,22 @@ "0ed3ffab6c149c8b4e71058e8668d429abfda681c2fff508207641f0d751a3e5", "ca7a5e68c53d2c51f72f6b465d3ed753f5903ec7901c8d0f55d868337c81975a" ], - "id": 221 + "id": 221, + "legacy": true }, "66b00539826a37484930191e028f62dab1cbc89b3acd472dc4e5905e47bf7364": { "fingerprints": [ "6ea1db6719d6041a06fc0898e5b3cf349a8fa8ecee85edb005965628f617f7c8" ], - "id": 428 + "id": 428, + "legacy": true }, "674039e472561963c8cb00d21a97a90a18bb8a1c4c317ac67e382a652bb573c0": { "fingerprints": [ "c2b9b042dd57830e7d117dac55ac8ae19407d38e41d88f3215bc3a890444a050" ], - "id": 216 + "id": 216, + "legacy": true }, "675605f1567e25fbd2526befea2aefbdb2279f3e1baa3a303ae7555d1bda3ee4": { "fingerprints": [ @@ -23097,13 +24370,15 @@ "fingerprints": [ "604d32d036895aed3bfefaeb727c009ec0f2b3cdfa42a1c71730e6a72c3be9d4" ], - "id": 452 + "id": 452, + "legacy": true }, "67a84264d42e204a9a5b0a3667b951db22c505df95ed983b5e8c4d1fce77af43": { "fingerprints": [ "19abcdff3a74402fa8f0ca206bf7fab0dffff3ae2bbd719584d21090a4353207" ], - "id": 480 + "id": 480, + "legacy": true }, "67dc4f32fa10e7d01a79a073aa0c9e0212ec2ffc3d779e0aa7f9c0f0e1c2c893": { "fingerprints": [ @@ -23115,37 +24390,43 @@ "fingerprints": [ "d41d829e8c1659822af93fce62bffcde264fc84e8b950c5ff275d052354695a3" ], - "id": 126 + "id": 126, + "legacy": true }, "682747f8ba621b87cdd3bc295ed5cabce722a1c0c0363d1d68b38928d2787f1e": { "fingerprints": [ "2cabeafe37d06ca22aba7391c0033d25982952c453647349763a3ab5ad6ccf69" ], - "id": 487 + "id": 487, + "legacy": true }, "689bf45b3083fdead55f147fd105e3cf218ad58edf3e4b301c0c5eeea6cf210d": { "fingerprints": [ "417dcf3180f4ed1a3747acf1179316cd48cb05c5788435168aed98c98cdcb615" ], - "id": 429 + "id": 429, + "legacy": true }, "68c3692214724d4b55a760f470b4fca8b5e0fe1d729cff22feb4ca88acd39809": { "fingerprints": [ "ae4457b40d9eda96677b0d3c92d57b5177abd7ac1037958356d1e094518be5f2" ], - "id": 231 + "id": 231, + "legacy": true }, "6a436b58d9d830e8d5b8a642505ad6b41406adcd6894d9414f7be0a1467badb7": { "fingerprints": [ "05d38c2a70bfc500ccb0cb509159b46b065c6ac9cb42d2e6f16167841434572a" ], - "id": 426 + "id": 426, + "legacy": true }, "6a7b1482127002f9005a87356e1dc3e00b70bbbfa795024ff8beff74c4259b75": { "fingerprints": [ "f657a633eeb9bc5d15a461751749ea4b316727dcf1a9f986b5458445f6485dde" ], - "id": 421 + "id": 421, + "legacy": true }, "6b1a505e0246f2f60c490ff0c097a7be27210cbb7500237f88b0cd48298bc9b8": { "fingerprints": [ @@ -23164,7 +24445,8 @@ "fingerprints": [ "3266967e59cd68008d9dd320811185c704205e8d95fdd84f1c7b311e6704fc32" ], - "id": 261 + "id": 261, + "legacy": true }, "6bcfc86c8ddc2af2e6a1180a2ddabb37b7ea3755316b64b9b8951bf0ca351f06": { "fingerprints": [ @@ -23182,20 +24464,23 @@ "fingerprints": [ "2dc62c3f6c0cc9020bba77e1c511511024b943ee598856da5a22e222b7277a20" ], - "id": 277 + "id": 277, + "legacy": true }, "6cae87c558d2441568e38270a8dd8ff484a259dc4f3ce94ccf434c1fa99811f6": { "fingerprints": [ "9806ab8509e2f35e192f275f0c308b9409b42512f90c659598c22be613962272" ], - "id": 325 + "id": 325, + "legacy": true }, "6d28f9e405148b69027da990815211c858841c543feced008c238021983c095a": { "fingerprints": [ "0378b202ccabba99a12e569a11a077db1edb39482061c75d0073059d9ab5b513", "e5c01cb4093279faa19fcfa24ea43eb1b26d07a615adf7240184a1e716b761c9" ], - "id": 376 + "id": 376, + "legacy": true }, "6d6f0c340971a218a31d10330ea9ae7c7a6550534c6eefeddd2118e114db473e": { "fingerprints": [ @@ -23219,19 +24504,22 @@ "fingerprints": [ "2d47437de17951215a12f3c58e51c729a58026ef1fcc0a5fb3d9dc012f600d19" ], - "id": 151 + "id": 151, + "legacy": true }, "7006a38311e58fb193484233218210c66125a0e4a826aed539ac561dfbfbd903": { "fingerprints": [ "92a9d9833fe1944db366e8bfae7a95b6480c2d6c6c2a1be65d4236b608fca1bb" ], - "id": 227 + "id": 227, + "legacy": true }, "7016270b60b28c6e177edebd718007dfd3310c64a737b7db01a07690c343bc27": { "fingerprints": [ "cd0b3b2aa174b55f18c7502f3c3a76f2198175ce45637370cf4f48b9c2ce4fbf" ], - "id": 389 + "id": 389, + "legacy": true }, "702116ccd8bf23e16466f0e0dba0ed6a239a9c1cd6a8f5a66b39af3595020385": { "fingerprints": [ @@ -23249,13 +24537,15 @@ "fingerprints": [ "126bf01c1094d2f0ca2e352380b3c724294546ccc65597bef7f12d8a171f1984" ], - "id": 242 + "id": 242, + "legacy": true }, "71ed918a7ac6d17b3849c20180b3e7334691bc5fb73377f0070afa0be789b2d1": { "fingerprints": [ "c31eef5682abb551ebc828ded84098518a6768526d152ee164cfb972a1425d53" ], - "id": 446 + "id": 446, + "legacy": true }, "76ee8590374c715437bbca6bba6028eadde2dc6dbbb8c3f610e851f11d1ab7f5": { "fingerprints": [ @@ -23279,19 +24569,22 @@ "fingerprints": [ "6ccfd302fc44bf4599329b9750878ea44e7e8566564bcbd586169762dd10c74e" ], - "id": 435 + "id": 435, + "legacy": true }, "78cf3d3c72daf91cc51b871357a551cf95b837d074c270b08facd463a8d39bb3": { "fingerprints": [ "82d42db3d657f1944e65c192b1dd58db8df8417b89165b045f5c6a70c5f8939e" ], - "id": 437 + "id": 437, + "legacy": true }, "7aedddf36b18f8acb7379fe1ce183212b2350d0788abe0e82457be9badad6d54": { "fingerprints": [ "8b45da1c06f791eb0cabf26be588f5fb23165c2e614bf885562d0dce50b29b02" ], - "id": 195 + "id": 195, + "legacy": true }, "7afe4b071a2f1f46f8ba944a26d584d5960b92fb48c3ba1b7cab84905f32aacd": { "fingerprints": [ @@ -23304,7 +24597,8 @@ "fingerprints": [ "af6d08eef3cac4e1584abc63c8a9472ac529af99f3f791319a43776063f58dca" ], - "id": 341 + "id": 341, + "legacy": true }, "7caa03465124590c601e567e52148e952c0cffe89000530fe0d95b6d50eaae41": { "fingerprints": [ @@ -23322,13 +24616,15 @@ "fingerprints": [ "e57210ab812c8df308267cb4291b98e956597ca36ec2b95189ef1723396bcac8" ], - "id": 306 + "id": 306, + "legacy": true }, "7d6c3ebf9ea735d1854beea7cb941ab1e3503515e087bbb5be695d05f2f556e4": { "fingerprints": [ "2193cfea381211a1aeaa2de984e630643a87160b1208118145eafb8e1bc69958" ], - "id": 473 + "id": 473, + "legacy": true }, "7e0ead76bb6819dc2f54511a84354f6e8b307b9dd82058ea6c004f01d9dda5df": { "fingerprints": [ @@ -23340,7 +24636,8 @@ "fingerprints": [ "f375e2f77a108bacc4234894a9af308edeca1acd8fbde0e7aaa9634e9daf7e1c" ], - "id": 395 + "id": 395, + "legacy": true }, "7e8782c150ce3952f802e636023a5d3e95bb5d68e33e85adb2ba178125cebf15": { "fingerprints": [ @@ -23352,7 +24649,8 @@ "fingerprints": [ "7af6ea9f753a1e709bd64d0beb867c11e8c295a56e24a6e0471459dccdaa1558" ], - "id": 274 + "id": 274, + "legacy": true }, "7f4296fc5b6a4e3b35d3c369623e364ab1af381d8fa7121533c9d6c633ea2461": { "fingerprints": [ @@ -23364,13 +24662,15 @@ "fingerprints": [ "22e0d11dc9207e16c92b2ee18cfdb2c2e940626847921fc528cedd2f7932f714" ], - "id": 349 + "id": 349, + "legacy": true }, "805c6696266b96b147468a321eba9eb8b5968f2c477cdd95fdadd1fc63dd614b": { "fingerprints": [ "a9a9ca22890d694919c095bb8064cbc4a525a5dbfaf801ec935dbccc07c8baee" ], - "id": 298 + "id": 298, + "legacy": true }, "808d68b3fab4884a5f971ace7d10550d7a95a163774f3ec36afffb213fbe4c74": { "fingerprints": [ @@ -23382,25 +24682,29 @@ "fingerprints": [ "53dfdfa4e297fcfe07594e8c62d5b8ab06b32c7549f38a163094fd6429d5da43" ], - "id": 258 + "id": 258, + "legacy": true }, "80dbfb97bdd3926baee41f73c5588faa17d707b03adf4907a2bc677f3ef1717c": { "fingerprints": [ "7afc9d01a62f03a2de9637936d4afe68090d2de18d03f29c88cfb0b1ba63587f" ], - "id": 214 + "id": 214, + "legacy": true }, "816ba0bfdf5fd64d568ec0d052f71164d9e2ccae12e0219ed6cd81e7e845fb84": { "fingerprints": [ "fb47d92a9909fd4fa9bec02737543e1f3514ced747407a8d9cfa397b0915067c" ], - "id": 423 + "id": 423, + "legacy": true }, "81a98fc788c35f557645a95224e50cd1dac8ffb209dc1e5688aa29205f132218": { "fingerprints": [ "c38dcb38959393358691ea4d4f3ce495ce748996e64ed1891d897a0fc4dd55c6" ], - "id": 166 + "id": 166, + "legacy": true }, "82b5f84daf47a59c7ab521e4982aefa40a53406a3aec26039efa6b2e0e7244c1": { "fingerprints": [ @@ -23412,27 +24716,31 @@ "fingerprints": [ "1e49ac5dc69e86d0565da2c1305c419330b0b781bfec50e54a1b35af7fddd501" ], - "id": 276 + "id": 276, + "legacy": true }, "85a3d81d2ad0c79df0a79684e0e2666009a09de15760ea1d76cf0ee7b2825dbd": { "fingerprints": [ "a1b2dbeb64e706c6169e3c4118b23baa09018a8427666d8bf0e28891ec051950" ], - "id": 410 + "id": 410, + "legacy": true }, "85d26be90d934fccdb4ff7b38d8c79ca7652b816d6a52446ca8428a6b85dc57c": { "fingerprints": [ "e3268f6106ba8b665a1a962ddea1459d2a46972f1f2440329b390b895749ad45", "e0e17aea06cf9ce12aae8190345a2c59720130a7d8ff72f3745ad75dbaa365b6" ], - "id": 273 + "id": 273, + "legacy": true }, "860a7f19210d5ead057a78532b80951453cb2907315f3ba7aa47b69897d70f3f": { "fingerprints": [ "bd469ff45faae7c54ccbd69d3f3b002255d9b06b10b1d0fa388bf96b918b2ce9", "944554239d91ed9efedcf906d5e8113160b46fc816dc6bdc77b89da29b6562b9" ], - "id": 249 + "id": 249, + "legacy": true }, "86a68f050034126a540d39db2c5f917ef66a94fb9619fa1ecd827cea46ba0cb0": { "fingerprints": [ @@ -23444,25 +24752,29 @@ "fingerprints": [ "b9bea7860a962ea3611dab97ab6da3e21c1068b97d55575ed0e11279c11c8932" ], - "id": 53 + "id": 53, + "legacy": true }, "86c84b1c3a66f4285af797052467e3ed236fd2986f033c02c4771be0b970482a": { "fingerprints": [ "90f3e05396995ff20922c44592db62d7845e1bf64aef512cca75bc669caa2479" ], - "id": 366 + "id": 366, + "legacy": true }, "87157a7585f4d03b00a398461e164e4806e1b3f46d03afbdc9def4e4778be2e9": { "fingerprints": [ "007e452fd5cf838946696dfe37a2db2ef3991436d27bcbab45922053c15a87a8" ], - "id": 378 + "id": 378, + "legacy": true }, "871a9194f4eed5b312ff40c84c1d524aed2f778bbff25f138cf81f680a7adc67": { "fingerprints": [ "2a575471e31340bc21581cbd2cf13e158463203ece94bcf9d3cc196bf09a5472" ], - "id": 483 + "id": 483, + "legacy": true }, "87af34d66fb3f2fdf36e09111e9aba2f6f44b207f3863f3d0b54b25023909aa5": { "fingerprints": [ @@ -23474,7 +24786,8 @@ "fingerprints": [ "e5bda820e5ce15bfd07ba11ffb1c7c8a5910ce1b90175c34308bc2500453ccdc" ], - "id": 322 + "id": 322, + "legacy": true }, "891ff898e4a8d555140056e3176eea91f4d808ee7f6d1bfbcce6f84807639f91": { "fingerprints": [ @@ -23486,7 +24799,8 @@ "fingerprints": [ "ffcef2224e29b0b36ec8314e686822f3ac0f1c5e0c2d5c0eb2484ce7e2540fd0" ], - "id": 321 + "id": 321, + "legacy": true }, "8a27b5557b4bec7cc0305fbf3d53d1f71cd3f34910c5d65e27ecddb82077ba3d": { "fingerprints": [ @@ -23504,31 +24818,36 @@ "fingerprints": [ "cd201256fe5ced0bfff8df595fff36b1416d5313a999f532ef4a9915df96dee0" ], - "id": 392 + "id": 392, + "legacy": true }, "8a903b600a080b38dfe20dfb6acd23122f64620e5808b9fc8688952fc1a3559c": { "fingerprints": [ "59b3829f1ff443344958fae8bff621b684c848cfbf7ead6b63a6ca50f2794f89" ], - "id": 275 + "id": 275, + "legacy": true }, "8ab4e88556cbf864a5e9fd50171cd4ed8424e8f0801b99e236c810915950ae4b": { "fingerprints": [ "894ce6ddb012cb3f736954668de63f436080e95f17b7a81bd924eb21bee9e440" ], - "id": 370 + "id": 370, + "legacy": true }, "8adb238554a0cbfc3a11fecc183e3cd2c23d25e7894cf2bbae58eb70a44e7cf3": { "fingerprints": [ "9676f287356c89a12683d65234098cb77c4f1c18f23c0e541de0e196725b7ebe" ], - "id": 234 + "id": 234, + "legacy": true }, "8b49506a3461063ea8cc13ffce2b581de15a94b957092a93123467b89ed802e2": { "fingerprints": [ "606223d9db80df3939601e74b7e828e2800cce4273f76f276aa62db0a8e3b6c1" ], - "id": 375 + "id": 375, + "legacy": true }, "8bb593a93be1d0e8a822bb887c547890c3e706aad2dab76254f97fb36b82fc26": { "fingerprints": [ @@ -23540,7 +24859,8 @@ "fingerprints": [ "efb5157e9c66caa1dcc63c9fac0127cde83b7a426c4579b7b43a41ba46a56deb" ], - "id": 418 + "id": 418, + "legacy": true }, "8d767764b3cbda08929d072a22a561f4dcdd1bc57d3cbddc948c47d2b47f9122": { "fingerprints": [ @@ -23552,31 +24872,36 @@ "fingerprints": [ "b8bbe523bfca3b11d50f73f7f10b3ec8ec958aa1dc86f66d9541907ff1a110ef" ], - "id": 384 + "id": 384, + "legacy": true }, "8e15d426cd04898f218be2e5fe3784f375094cc435dc61ad86c4a3c01511dbe1": { "fingerprints": [ "7a77c6c61eeeb9aa65c4ea410d65d895b26a81123283009db104b48de80b2479" ], - "id": 439 + "id": 439, + "legacy": true }, "8e8046ec4cac015a507ce0d2d0154a4b40e8e42b3165cfa546571435112d17e5": { "fingerprints": [ "d48d3d23eedb50a459e55197601c27774b9d7b18c94d5a059511a10250b93168" ], - "id": 463 + "id": 463, + "legacy": true }, "8e8b56f5918a25bd85dce76663fd94cc23690f10ea9586613171c6f8378890d5": { "fingerprints": [ "894ebc0b23da2a50c0186b7f8f25ef1f6b2935af32a94584ef80aaf877a3a06e" ], - "id": 239 + "id": 239, + "legacy": true }, "8ed5b4c041b6b293c0e6413015066d318483c901ff69e86a521d0cb25569f3e8": { "fingerprints": [ "8327bc8c9d69947b3de3c27511537267f59c21b9fa7b613fafbccd53b7024000" ], - "id": 228 + "id": 228, + "legacy": true }, "8fd112c3c8370f147d5ccd3a7d865eb8dd540783bac69fc60088e3743ff33378": { "fingerprints": [ @@ -23588,19 +24913,22 @@ "fingerprints": [ "ce7dd096c8fde2bf5c438edb574bd6454385334ee8ff106c0f93d5051be6bac3" ], - "id": 336 + "id": 336, + "legacy": true }, "913119f2cd3f48aca74ea6443ee50e0de1202d9c54f336dc9300affe97d4577c": { "fingerprints": [ "eefca888db442cea1f03fac5de5b1af210ae03f5e1658ddb880c645e78624546" ], - "id": 394 + "id": 394, + "legacy": true }, "915086ccd4ed1ea749b427f6b0ceb4a0ef5b4a1cf18070539c0f2a758185a382": { "fingerprints": [ "eac0220c5c9fecc5121d3720872d06707b5266be25d4ebb56ab804bbbf85fe03" ], - "id": 224 + "id": 224, + "legacy": true }, "927a1b8562280576d048c50321ada43d8703d2d9521a18c28b8c46cc6aae4efd": { "fingerprints": [ @@ -23625,25 +24953,29 @@ "b41d516a5351d42deea191fa6edf2a67dee2f36dc969012c76669e616b900ddf", "77e04c9a751c73f23e2a1336112ec8d5153d382a152fed89d7532c3102771f3c" ], - "id": 319 + "id": 319, + "legacy": true }, "93657f8530c596bf909e50da7d8d9cbb36b824cc16ab589137e1438011bc9901": { "fingerprints": [ "d68f7730b1ec2b3fb698c96d76540c9997415a25737dcd61d44960db77d2723d" ], - "id": 282 + "id": 282, + "legacy": true }, "9392ae2149924ade37e645dba1ff4bdddcda2b291b6097669d2afa5c7a372619": { "fingerprints": [ "8da084fcf99ce07722f89b3205939806fa5cb811e1c813f6a108c7d336b3408e" ], - "id": 76 + "id": 76, + "legacy": true }, "93a9b3c96aae1cd661215d0c2a065da963d7160d1c694621bcb28c406df64db2": { "fingerprints": [ "8a968aadd88b20519672a452a3d6e31eacb71c26bcaf65b32f9793bf2ffa54a9" ], - "id": 246 + "id": 246, + "legacy": true }, "94072ad3f58f70f93098e5a5f6c04c96c710bd849d83184919ae90eb890ae400": { "fingerprints": [ @@ -23655,7 +24987,8 @@ "fingerprints": [ "958abbaeff760f4fbf66ff0f2c2708f4739b2c686127239a2c4ec87a68a984c8" ], - "id": 478 + "id": 478, + "legacy": true }, "942a6916a6e4ae527711c5450247a2a74fb8e156a8254ca66e739a11493bb445": { "fingerprints": [ @@ -23667,7 +25000,8 @@ "fingerprints": [ "632d80bb096d209677d1734e5b35ea9d3019b9c44f8fcb2640c879039ac94ee8" ], - "id": 391 + "id": 391, + "legacy": true }, "951ee046fa83316e6786c08c44f13b4ca2ead2d2644d63314391c0cc70887d0d": { "fingerprints": [ @@ -23686,19 +25020,22 @@ "fingerprints": [ "49f74f824f2e059fe99c98af3219ec0d9a004d1b64dd2fd1452616318ab806c0" ], - "id": 347 + "id": 347, + "legacy": true }, "95735473bd67a3b95a8d5f90c5a21ace1e0d7947320674d4ab847972b91544d2": { "fingerprints": [ "b32396746453442f353e616292bb20bbaa5d23b546450fdb9c54b8386167d529" ], - "id": 259 + "id": 259, + "legacy": true }, "96475b35acb1c9303a90bd1dbf57418f78e29af11c4de8c8cba2e5f9309e38d4": { "fingerprints": [ "b04d708f1ae0456265dd1b66907a2691a28680b853e031df3df9083af71614d7" ], - "id": 316 + "id": 316, + "legacy": true }, "967b0cd93fcef7f27ce2c245767ae9b05a776b0649f9965b6290968469686872": { "fingerprints": [ @@ -23716,7 +25053,8 @@ "fingerprints": [ "997e15c5a4481a8598499753971ee2601d1047c3635aff21af4221a817fd2d96" ], - "id": 425 + "id": 425, + "legacy": true }, "9736ac3b25d16c45a45418a964578156480a8cc434541ddc5dd59233229868de": { "fingerprints": [ @@ -23728,140 +25066,163 @@ "fingerprints": [ "cbd8ed38d4a2d677d453d70dd8890af4f6374cba6299943f1ab3a6936c6fd795" ], - "id": 396 + "id": 396, + "legacy": true }, "98008e2edbb72bad42da2fcb06ac1aaa0b2e6e0c72e8ca204fbafd1bb4879441": { "fingerprints": [ "04acfb3b24793f300f67ef87e44dd72cb9b28b204f389a7cd5ae28785c7d42cd" ], - "id": 238 + "id": 238, + "legacy": true }, "980922eee07f86bc7f5e5e95d57db8bdae68e17a421c4e72a96a708a87920124": { "fingerprints": [ "327a3d761abadea034eb998406275cb1a4776efdae2fdf6d0168ea1c4f5567d0" ], - "id": 149 + "id": 149, + "legacy": true }, "9847e5653e5e9e847516e5cb818606aa7544a19be67fd7366d506988e8d84347": { "fingerprints": [ "71cca5391f9e794b04802530b363e121da8a3043bb26662fea4dca7fc951a4bd" ], - "id": 486 + "id": 486, + "legacy": true }, "98b3f10a025041910f197cf17ca0fcdfed75fb2c8c14a843e04d5656c9ebac1a": { "fingerprints": [ "9a73929a500f1a0bf49dcb046e8039169696557345e9f813f10ff9380db22695" ], - "id": 235 + "id": 235, + "legacy": true }, "98ca29f313386721afbf5d14f1abcaa1dc63cc8d1fd7dc361f6b01368938f24b": { "fingerprints": [ "7c7ed4240bb253bb35c376e12e00b027f1659df9d8267422a93eed75edc7adfb" ], - "id": 223 + "id": 223, + "legacy": true }, "991b5ed1b2fd364b9f634b624b305203f29908be318ef6399222d8a3ef7990e5": { "fingerprints": [ "2602d21e81277a83f6048128f61d794a06f474e1f75e49740a817c2666f62211" ], - "id": 299 + "id": 299, + "legacy": true }, "99333c3a665cf0efbb7488b3807b8b65f87b5b29d6880f028edc28442eeae669": { "fingerprints": [ "8b3fdb151af759c566143e07c950ede4f9e8c7cf808453d33bcb78e52a400af9" ], - "id": 434 + "id": 434, + "legacy": true }, "9962ab1699b0eb7c7e8a578bc79893042031c1158c633613199a90b9652a2a75": { "fingerprints": [ "1501f89c5c4dcf36cf588a17c9fd7cfceb9ee01e8729be355e25de80eb6284b4" ], - "id": 462 + "id": 462, + "legacy": true }, "9adb99c93ab256ecca2b5350c75048a8584c12dfc248e3f60ea9354c34ebfcce": { "fingerprints": [ "03458b6abeecc214953d97149af45391691de9f9cdcc2647863a3d67c95c243b" ], - "id": 65 + "id": 65, + "legacy": true }, "9b219d0fbff36a5fb32090571906bceea68617c833a3f61b81e962a8e64db8af": { "fingerprints": [ "63343abfb89a6a03ebb57e9b3f5fa7be7c4f5c756f3017b3a8c488c3653e9179" ], - "id": 217 + "id": 217, + "legacy": true }, "9c6f6a123cbaa4ee34dbeceee24c97d738878cb423f3c2273903424f5d1f6dd5": { "fingerprints": [ "87c678bfb8b25f38f7e97b336956bbcf144bbacaa53647e61a2325bc1055316b", "b4410b73e2e6eaca47fbc42f8fa4018af4381dc54cfaa84450461eed09454de9" ], - "id": 135 + "id": 135, + "legacy": true }, "9d98a1fb60538c4cc4857ff1a8c8034faf6fc592093f619994b2c813d250b864": { "fingerprints": [ "7d8ce822222b90c0b14342c7a8145d1f24351f4d1a1fe0edfd312ee73fb00149" ], - "id": 333 + "id": 333, + "legacy": true }, "9dc38a9edcf82842b674da186b6d6215ab9e2ec6d72f57b08a892728c31431f3": { "fingerprints": [ "ae92e90000541a9ebc101b70b6c33a62f5a53a55ba815e81d31abddf03507f5d" ], - "id": 342 + "id": 342, + "legacy": true }, "9dd55fc573f546cb6a3831d1112d8710a6f4f82dc87f5fae9d3a1a028dd36e4b": { "fingerprints": [ "1c01c6f4dbb2fefc22558b2bca32563f49844acfc32b7be4b0ff599f9e8c7af7" ], - "id": 11 + "id": 11, + "legacy": true }, "9e5a34b08929bc0a581c8936aafd6ab7517bb15188b4f6fc02c45906f71595b0": { "fingerprints": [ "5e3571f33f45a7df1537a68b5ffb9e036af9d2f5bc4c9717130dc43d7175aac7" ], - "id": 354 + "id": 354, + "legacy": true }, "9ea9fe274537f4f935642cde824fd77eb0e125cf118ab9b4c219f6cbf959b18d": { "fingerprints": [ "8f1ecdaf29bcd56eddd6b5d56a07fcac2b74d4bcd179179144a0365c27dcf14b" ], - "id": 431 + "id": 431, + "legacy": true }, "9ecc51368e86e3460f66c295e4942dd53080f27b1e410aff2d1aa9d4e6bc7e7c": { "fingerprints": [ "62f240278c564c4dd8bf7d9d4f6f366ea894d22f5f34d989a983acec2fffed50" ], - "id": 144 + "id": 144, + "legacy": true }, "9efd911d6ff46f1831111df3c54cd2611cae2398ff7386d1cb6b4f32e3337ed6": { "fingerprints": [ "b2259996fff735ab35014ef63f3d413190079dd03a0962432635a8695f995305" ], - "id": 407 + "id": 407, + "legacy": true }, "a12574f4eb7395cc630a15fec8db1c7c828f66699d984c8c897eca44c808f55d": { "fingerprints": [ "c499f6cecc5da4d61f14ed0405270c5249d0e79615b0da42659ed2d7ffef8a40" ], - "id": 310 + "id": 310, + "legacy": true }, "a1d45d06297341b1f3a735cfa38f283e6879fec06281a361e5f417cc70d29dc9": { "fingerprints": [ "81c2568503eb3be5eec366653960e6d1be9448915e4605b793fbeb34ccb2470f" ], - "id": 424 + "id": 424, + "legacy": true }, "a25a7214c2b6c86142ada39dff2d73d865aa57843fdd2db77b3febf82683de2d": { "fingerprints": [ "c0c05a8d8da55eaf27aa9b910b0a6ef0d8bbded346928db872e182c2073e9802" ], - "id": 240 + "id": 240, + "legacy": true }, "a2dc98ca7cbbee1822b25b267bd5ca502fa7b0cf4fff0703ee6a416703f3c7ea": { "fingerprints": [ "c1b12f480020336e5b04f520bc19c2e2e10ab42c9d9235f05cbec33ffa4d4dea" ], - "id": 334 + "id": 334, + "legacy": true }, "a320f4d534d7be97c1ae8dd0499735bc895c323add2d388bfccf662c23d7f99a": { "fingerprints": [ @@ -23873,43 +25234,50 @@ "fingerprints": [ "49c8175a9815e08bef129a929de1bacad04e4db67a8c839293953e5031c81ca0" ], - "id": 307 + "id": 307, + "legacy": true }, "a4003bd5bdd894e01a8e01e06b62c7aa82f03de5253133570aad4fd0e7d81d3c": { "fingerprints": [ "7f12cd5f7e5e290ec7d85179d5b72c20a5be7508ffdb5bf81ab9684a7fc9f667" ], - "id": 106 + "id": 106, + "legacy": true }, "a4b89bb70656ea498f2d9e00a497fdb9dcd20b81b8938e952bba2df9f65729c3": { "fingerprints": [ "5a1b5d6bc65523b40a6deffa45b48e4288ae8dd86dd70a5b858d4a5affc94f71" ], - "id": 371 + "id": 371, + "legacy": true }, "a4cbf48516af3160ebc62acac6e7f258609ed0891535010c16692493a9fe1fbf": { "fingerprints": [ "8ba1bd9c88efb3947e60ebe21137f81df7f09994cef27f097055018b8194c634" ], - "id": 449 + "id": 449, + "legacy": true }, "a51a2f3a050e838a5050696578dbbedaac1a107ee2d9d48fae505d18d0da5cf8": { "fingerprints": [ "70b922bfda0e3f4a342e4ee22d579ae598d071cc5ec9c30f123680340388aea5" ], - "id": 260 + "id": 260, + "legacy": true }, "a5204dbb2754b97e3c8a104eacb374a6498a438773c75077f0063c2ceb25d2a2": { "fingerprints": [ "e8b28d2a3d81f63b4e4467c2190a631fc062353b5f2d25851dda6b644ac78b3f" ], - "id": 305 + "id": 305, + "legacy": true }, "a59d2f09c8b168cd9afa3bc3eb4db0d7a43588d523287f2b83a822eb33709170": { "fingerprints": [ "9cefb0cb7b74e642932532831e0dc8f4d68ad414261fc3f474b795e72a164e57" ], - "id": 453 + "id": 453, + "legacy": true }, "a6e11ff15ec326a5e3f18ad33a056694dc84c699766d028a5ad0efe1a8e53ac7": { "fingerprints": [ @@ -23921,38 +25289,44 @@ "fingerprints": [ "5f0b62eab5e353ea6521651658fbb65359f443280a4afbd104d77d10f9f04c07" ], - "id": 70 + "id": 70, + "legacy": true }, "a74b4b6a2eb55b9864c04ecb16003ff5db5b51e42cf859f95e9d0a1dd4644096": { "fingerprints": [ "e8c6aa6b5f58a8f2a6365cf98e65693563a38b7b2f32cf1be06f2d2229d4bf59" ], - "id": 364 + "id": 364, + "legacy": true }, "a76e2949cb87f6236b5f68c690747587d6448ea21cfead7950084ac015190b25": { "fingerprints": [ "229ccc196d32c98421cc119e78486eebef603aecd525c6b88b47abb740692b96" ], - "id": 455 + "id": 455, + "legacy": true }, "a798d92f76c9c6755e5f55f86cd14aedcc0655371e27ccde0377745ce3c50013": { "fingerprints": [ "058a40323ec8c46262c3052a5d357b91ac24d3da26351b3ff4407e99f7a4e9b4" ], - "id": 356 + "id": 356, + "legacy": true }, "a7a8f039894f5f675e92a778e008e424c9417dba06a1738b45b4e08d36fc2d7c": { "fingerprints": [ "75c9d4361cb96e993abd9620cf043be9407a4633f202f0f4c0e17851cc6089cd", "f28630babf256e567b5821069fcf13148ab9a23e28fc0d70615aae6ed284f4c8" ], - "id": 220 + "id": 220, + "legacy": true }, "a7e39bd7df609bef3262bf3db4dc8f3814e0db5a7a52156a6d0c35b4dae8a6ad": { "fingerprints": [ "b3c962d34019fb38ab9fe9c62399742ab26c43c2d18ce3f2b13c14321e52964b" ], - "id": 301 + "id": 301, + "legacy": true }, "a81293445db196a2030f9e455fe3c74a9a4f8317b02b01406027a8708174434c": { "fingerprints": [ @@ -23964,7 +25338,8 @@ "fingerprints": [ "93e65ec762f055dc718a332582c41a04430d72e3cb87e8b897b67516f0d1aa39" ], - "id": 268 + "id": 268, + "legacy": true }, "a87443b3d896eb257ccce99b95ada9bc81b9db4e3142aa9a99af0942cb0a4a3a": { "fingerprints": [ @@ -23976,13 +25351,15 @@ "fingerprints": [ "a71272aeaaa3cfe8727f7fb39f0fb3d1e5426e9060b06ee6f13e9a3c5833cd43" ], - "id": 4 + "id": 4, + "legacy": true }, "aa1c2bedb1a508baad7fb3f5e02897b907c748dea9b7908904aadbd0497aab6a": { "fingerprints": [ "cd808284cf746ff2fd6eb58aa1d59c4ad4b3ca56fdc6274a8926a7835f32313d" ], - "id": 252 + "id": 252, + "legacy": true }, "aa2630a7b617b04d0a294bab7a8caaa5016e6dbe604837a83a85719fab667eb5": { "fingerprints": [ @@ -23994,19 +25371,22 @@ "fingerprints": [ "cb6b05d9e8e57cd882b10b4db70de4bb1de42ba48a7bd0318b635bf6e7781a9d" ], - "id": 265 + "id": 265, + "legacy": true }, "ab39a4b025955691a40269f353fa1d5cb94eaf6c7ea9808484bbbb62fd9f68f3": { "fingerprints": [ "2834991cf677466d22baac3b0055e5b911d9a9e55f5b85ba02dc566782c30e8a" ], - "id": 262 + "id": 262, + "legacy": true }, "ab5cdb3356397356d6e691973c25b8618b65d76a90486ea7a8a5c17767f4673a": { "fingerprints": [ "309b4a87f6ca56c93169aaa99c6d988854d7892bd5437e2d07b29cbeda55d35d" ], - "id": 160 + "id": 160, + "legacy": true }, "ab98495276adf1ecaff28f35c53048781e5c1718dab9c8e67a504f4f6a51328f": { "fingerprints": [ @@ -24018,61 +25398,71 @@ "fingerprints": [ "2dde9d0c0a90e7b32b5abc01f41799d42e95a1e3c31c3b39373bb8141ea54471" ], - "id": 451 + "id": 451, + "legacy": true }, "ac447dedd0432aab9c070f2cca01b6dab09bef07cf4ca6aaa755634f857b315a": { "fingerprints": [ "d1a0319098034e3aec729a0b5c3111229d9d26e3e623e8c5e6843fa06ee8e2e4" ], - "id": 479 + "id": 479, + "legacy": true }, "acf65e1d62cb58a2bafd6ffab40fb88699c47397cf5cb483d42d69cad34cd48b": { "fingerprints": [ "e6b8f8766485f807ae7f8dac1670461f07c0a13eef3a1ff717538d7abad391b4" ], - "id": 24 + "id": 24, + "legacy": true }, "acf7ad98e6f065866e6f8cdf0ceb6f7481f6957b6dff823f6b94d79f01a61c39": { "fingerprints": [ "ea7e312ece487b4c0aa63cc80ab9fcb33c720573f8945f7761745fc63863d39d" ], - "id": 382 + "id": 382, + "legacy": true }, "ad304c884a5d376bd195209a14c39e07f0d3f5cf893d802b053e1b926e55d774": { "fingerprints": [ "488e134f30c5db56b76473e608086842bf21af8ab3cd7ac67ebdf125d531834e" ], - "id": 390 + "id": 390, + "legacy": true }, "ae2033b3082825a703e5a6adc3221a86854aa411db047dd5f53eb84aa14bdc01": { "fingerprints": [ "c109e0d1b64000b01e894bdaa955e1ff91b6d084a838d90e044b9e3fcd2a8bfa" ], - "id": 383 + "id": 383, + "legacy": true }, "ae56d847973d199390e66e4024c9f87d87371e8ba8876af83d1e644f54664738": { "fingerprints": [ "b7a7ec419454411761225ecf30d99585f851356077bf83274b11588fd05521b8" ], - "id": 281 + "id": 281, + "legacy": true }, "af110f6b5ae8b767eac6e0aa273f3816e7a40a644edacb4398146356e77509d6": { "fingerprints": [ "46273285615d96e52da9fc2ed8c036f10af3d9f6280f8d288706c52b2011b4da" ], - "id": 386 + "id": 386, + "legacy": true }, "af207c61fd9c7cf92c2afe8154282dc3f2cbf32f75cd172814c52b03b7ebc258": { "fingerprints": [ "cb627d18b58ad56dde331a30456bc65c601a4e9b18dedcea08e7daaa07815ff0" ], - "id": 257 + "id": 257, + "legacy": true }, "af6ab51b7bad1dedd533eb59332b6227d6557f20b4443216db735b92280c7a44": { "fingerprints": [ "bcdd8df4276366d7ff4b688dc81500d8e98252c049c8ff1e8c82f2baec9d5c16" ], - "id": 337 + "id": 337, + "legacy": true }, "aff988906dde12955d9bebbf928fdcc31cce328d5b9384f21c8941ca26e20391": { "fingerprints": [ @@ -24090,7 +25480,8 @@ "fingerprints": [ "5b1d9d24de0afea8b35ba04a1c3e25d0812cdf7c4625de0a89af9fe4bbd1bb15" ], - "id": 412 + "id": 412, + "legacy": true }, "b0f6f15b4817ebe6fe0b4bfcd7d3ace4c758b0ab6f8a9da2ed92e618239d9c98": { "fingerprints": [ @@ -24104,25 +25495,29 @@ "e7685634efacf69ace939a6b255b7b4fabef42935b50a265acb5cb6027e44e70", "6872586219c349d85aaa4586a14451f2451ae3b6092dbb1effb0147c33bf0fd4" ], - "id": 72 + "id": 72, + "legacy": true }, "b16cb1ba529a39e2dfd53b3ff5a79f1904614d83e31304f0278bb40b38cf7824": { "fingerprints": [ "0771920c8cb874d5c5a4dc0d6a51a2d495d38c4de2cd5b83d2a06faa051935f6" ], - "id": 432 + "id": 432, + "legacy": true }, "b1be0f7a5e638b559d8b521fef6017ad8fa16eb0548e846b2ac4b41d89b41f14": { "fingerprints": [ "da98f640194df128c7888bc8e3479a9dd31795ff087c649052fbafb02eaef184" ], - "id": 211 + "id": 211, + "legacy": true }, "b213a9cbaa9a8831ac0b3aa80e9d15856cd43a7cc2e0bac5fcb84a24751a8a78": { "fingerprints": [ "54ae8a683fe2d78ff1ef0e0b3f58425092953ba08c67fe4a95595d1cebcdcb30" ], - "id": 450 + "id": 450, + "legacy": true }, "b21d2a743318712ba16f39919d961a4bafba3bca9a43a75b1fcfe22c5d70caba": { "fingerprints": [ @@ -24134,50 +25529,58 @@ "fingerprints": [ "ebf3c02a8789b1fb7d511995d663b72906d913ce0d5e10568a8a77e2586167e7" ], - "id": 48 + "id": 48, + "legacy": true }, "b3182e289ae34ddf2be643ab79c244301605fa0f1eaae6d10fb929600af84df0": { "fingerprints": [ "f00355eef101c7df4e46cce6417dffce3db82dbb1369c3b439c4e33bee445c42" ], - "id": 355 + "id": 355, + "legacy": true }, "b4296d5fe60e52f3f0ff99da75af5e7e62599f99ebe0fa413f66e6b425c3d09f": { "fingerprints": [ "9df0ec44f55b36d79d4b53c208bef8cb63d78dcc8fcafde1662312f212204a37" ], - "id": 348 + "id": 348, + "legacy": true }, "b489ccb224b9a6b81dd274ceaf5209c252998c9a76af48e4f4c50a0728461825": { "fingerprints": [ "1e51942b84fd467bf77d1c89da241c04254dc8f3ef4c22451fe7a89978bdcd4f" ], - "id": 465 + "id": 465, + "legacy": true }, "b4a039eafc4310ba9bde093edb8f9d9d0b3d4c7c004d48288c35dbcc19467d18": { "fingerprints": [ "af8b6762a1e528228161a95d5c559ee266278f75d79e830189a503506abd6b4c" ], - "id": 82 + "id": 82, + "legacy": true }, "b5ec35baab538884cfa8dd97376b102f03e53b482c64100c250722ae9b042cbc": { "fingerprints": [ "fc50b26bdc4a8fdf1344cc80157ae13ac671e2706facfc0605fe34e249eb72d6" ], - "id": 430 + "id": 430, + "legacy": true }, "b638cff05c8a832758edc3028af9e2d55514568bc6bb34ab36d140b97ac6b12d": { "fingerprints": [ "0f4e9cdd264b025550d170806340214fe94434c9b02f697ec710fc5feafb5e38" ], - "id": 68 + "id": 68, + "legacy": true }, "b656a4343831a2acf11eeabc3a44b97025fffba2b910da8714cf827d81be10c9": { "fingerprints": [ "796b93d0a3ba22e191f2495f150a5f9bfee2ce1503da217b74b8a984685110f1", "1a2512cda6744abea11432a2fdc9f8c088db5a98c89e13352574cde4d9e80cdd" ], - "id": 408 + "id": 408, + "legacy": true }, "b738290cc08547e79ac67f831ebb33547c4e7db4514e2d2988c23c441340eb41": { "fingerprints": [ @@ -24189,13 +25592,15 @@ "fingerprints": [ "04f1bec36951bc1454a904ce32890c5da3cde1356b7900f6e62dfa2041ebad51" ], - "id": 475 + "id": 475, + "legacy": true }, "b9182f52af0dd18e3a99ebbae7883d4e4cc7fe2f81fad0d36ca661efc32d0a92": { "fingerprints": [ "4bdb7418bdf7ffe33ba0884afa7c0c61fd85a153972f65f7d01cb3ec7eb4073c" ], - "id": 312 + "id": 312, + "legacy": true }, "b94c198300cec5c057ad0727b70bbe91816992256439a7b32f4598119dda9c97": { "fingerprints": [ @@ -24219,7 +25624,8 @@ "fingerprints": [ "fabcf5197cdd7f458ac33832d3284021db2425fd6bea7a2e69b7486e8f51f9cc" ], - "id": 243 + "id": 243, + "legacy": true }, "bcfb44aab9ad021015706b4121ea761c81c9e88967590f6f94ae744dc88b78fb": { "fingerprints": [ @@ -24243,32 +25649,37 @@ "fingerprints": [ "fe7114d07a147759891ff37b4f53eb43568296bc3bf89bc12cafb186985ef28d" ], - "id": 372 + "id": 372, + "legacy": true }, "bf01c35f337113f167b4a50186765e7b1e3890af586328f185cd0d6bae813521": { "fingerprints": [ "f4336bc2ac75950beccf1c1f2f9da6dddafd1f41161ca71f59c76889bd474033" ], - "id": 415 + "id": 415, + "legacy": true }, "bfe82909872e4434f115c51a56168019594d0e03dca363d9f3b4839d0babcde5": { "fingerprints": [ "68ad50909b04363c605ef13581a939ff2c96372e3f12325b0a6861e1d59f6603" ], - "id": 404 + "id": 404, + "legacy": true }, "c06c872fc2d0ac08d78d421981fbda4e35500d0946f79894edd21ac29dec0719": { "fingerprints": [ "2605875afcc176b2d66dd66a995d7f8d5ebb86ce120d0e7e9e7c6ef294a27d4c" ], - "id": 232 + "id": 232, + "legacy": true }, "c07135f6b452398264a4776dbd0a6a307c60a36f967bd26321dcb817b5c0c481": { "fingerprints": [ "44640a0a0e4d000fbd574d2b8a07bdb4d1dfed3b45baaba76f785778c7011961", "61dc0c0391694c655200c1505ebcc9e4e216bc31a5c51a3611283423c1d89e37" ], - "id": 167 + "id": 167, + "legacy": true }, "c1ad1b1898ec395048df070bfa217e25c913bed8ca6b73de085528846a0103c1": { "fingerprints": [ @@ -24280,13 +25691,15 @@ "fingerprints": [ "8fdd298d1c93b22bfc42aab1c3a15f0d01832ca0a1aef28d5680f06e6c7fd4ef" ], - "id": 26 + "id": 26, + "legacy": true }, "c42533d3af4998f5ad9f072521d85d472fa7ffdcfc588c8247b337dc77109389": { "fingerprints": [ "12d480c1a3c664781b99d9df0e9faf3f1cacee1b3c30c3123a337a4a454ffed2" ], - "id": 373 + "id": 373, + "legacy": true }, "c444b5b66ce5d71e1b5e40f27385c95cbfd24a05b56f70cac0992f0f50c3379c": { "fingerprints": [ @@ -24298,19 +25711,22 @@ "fingerprints": [ "5533a0401f612c688ebce5bf53f2ec14a734eb178bfae00e50e85dae6723078a" ], - "id": 443 + "id": 443, + "legacy": true }, "c5697be91cd655539b560758e91b6e085461623741034c485e47d7e9d25a03c0": { "fingerprints": [ "06db3af2db7baee00c03b9578288bbde541d906eb0069327413295ffb486008e" ], - "id": 213 + "id": 213, + "legacy": true }, "c5ea259c629803508649f02177f63c32fa85cc4ad5c35f0d541c45df10a49fd7": { "fingerprints": [ "3cfc3c14d1f684ff17e38c43ca440c00b967ec933e8bfe064ca1d72c90f2adb0" ], - "id": 286 + "id": 286, + "legacy": true }, "c63d68c648a18b77641c427a669d61c9768a55f4fcd0322eac96c57700299cf1": { "fingerprints": [ @@ -24323,13 +25739,15 @@ "fingerprints": [ "8095210805db4bbc355e4428d8fd6ec2cde3ab5fb97a9942988eb8f4dcd06016" ], - "id": 3 + "id": 3, + "legacy": true }, "c746127c5f6b529ce9e2948efd9465444089319acf03f34d0bf37eadc77db22f": { "fingerprints": [ "6fdb3f76c8b801a75338d8a50a7c02879f6198b57e594d318d3832900fedcd79" ], - "id": 43 + "id": 43, + "legacy": true }, "c784333d20bcd742b9fdc3236f4e509b8937070e73067e254dd3bf9c45bf4dde": { "fingerprints": [ @@ -24347,43 +25765,57 @@ "fingerprints": [ "6468bf8cf3cf688ebb2a6841bd70e97b5229b49df8690d7b74193e9ce3886141" ], - "id": 397 + "id": 397, + "legacy": true }, "c90d009c47eeb9f2a29ae848f5d930f2b41ef5edbc5c5695c1414345c1dd67b4": { "fingerprints": [ "37d8dc8af7867845da3344a6b1bade448d8a80e47b5579f96bf631768f9f30f6" ], - "id": 358 + "id": 358, + "legacy": true }, "c954c2c0b189825bb65ddb3ddca080b7dbcfe6b17cade1022bada818336677d0": { "fingerprints": [ "e873d4082a7b4632934f48a5cc1ee500932f661e56c3467c5c84d31447476b0c" ], - "id": 308 + "id": 308, + "legacy": true }, "c9905b0ee01202293ca026e64f08412442c5504c06e44ca7e9726d61f20e4089": { "fingerprints": [ "df545bf919a2439c36983b54cdfc903dfa4f37d3996d8d84b4c31eec6f3c163e" ], - "id": 402 + "id": 402, + "legacy": true }, "cb6e91711ad6d55c8906f379cb071fb5c47933654a7415612eee6629f26fbcd7": { "fingerprints": [ "f09b122c7114f4a09bd4ea4f4a99d558b46e4c25cd81140d29c05613914c3841" ], - "id": 41 + "id": 41, + "legacy": true + }, + "cbad7b1d384849df0946b7ee8e7f5f7ce3aed876fda7bc9d30d8b16f29ff2c53": { + "fingerprints": [ + "657cfe2fa73faa38462571f332a2363a46fce7020951710702cdfbb6eeda3305" + ], + "id": 492, + "legacy": true }, "cbe5ac15d88b5cac3f81e6df3bfb57bea60958813a47b77f3c5cb6b98191bdb5": { "fingerprints": [ "ecc3e9c3407503bee091aa952f41348ff88baa863b2264befac807901574e939" ], - "id": 8 + "id": 8, + "legacy": true }, "cc4997863c8c48a4cb5c3e6537dc06028d8638be49f5f8a2ba56f2f2c8a8c779": { "fingerprints": [ "a1f05ccb80c2d710ec7d479abdcbb879e58d7edb7149fe78a87884e3d0bad0f9" ], - "id": 267 + "id": 267, + "legacy": true }, "ce24eb0626defd8168c96a7701f09301600fe5dd0dbce58e9c97b830af02ef28": { "fingerprints": [ @@ -24407,7 +25839,8 @@ "fingerprints": [ "507941c74460a0b47086220d4e9932572ab5d1b5bbcb8980ab1cb17651a844d2" ], - "id": 148 + "id": 148, + "legacy": true }, "d0773adb60043e954309d9714fe053eaad8aa5b9586edba468e276df82065adf": { "fingerprints": [ @@ -24431,7 +25864,8 @@ "fingerprints": [ "f1b13f5c9a326403b0f31bbe7699cd17c7d1c0b981586dd1a7b219c52508fe99" ], - "id": 367 + "id": 367, + "legacy": true }, "d2a5f32f0e01b910ef4e3b46bf84e5af5fb5689e7d1507e929e368ac88c6cc76": { "fingerprints": [ @@ -24443,74 +25877,93 @@ "fingerprints": [ "9d190b2e314566685be8a889e27aa8c7d7ae1d8aaddba3c1ecf9d24863cd34b9" ], - "id": 255 + "id": 255, + "legacy": true }, "d3980aadd21638c70d74a4bb1f8ab5e11724e62ed408f9fa8d3d4d916900286b": { "fingerprints": [ "24a55c2ab051442d0617766541239a4ad032d7c55175aa34ffde2fbc4f5c5294" ], - "id": 472 + "id": 472, + "legacy": true + }, + "d49c6f289cd056519492480f192f00a6fc7c1862dab2e7b5d8e05f6678fae141": { + "fingerprints": [ + "a1a86d04121eb87f027c66f53303c28e5739f943fc84b38ad6af009035dd9457" + ], + "id": 491, + "legacy": true }, "d4af6c0a482310bd7c54bb7ab121916f86c0c07cd52fcac32d3844c26005115f": { "fingerprints": [ "614fd18da1490560cdad1196e2492ab7062eab1a67b3a30f1d0585a7d6ba6824" ], - "id": 326 + "id": 326, + "legacy": true }, "d5597ea3453a6261f5d42eb9caf5bdb4e38a1edebdb5bea6d7c0bc1a8abecab2": { "fingerprints": [ "0e88eb6ea256e19ef8d3abd61a24d38dbad632816dd957294427e4724d81a386" ], - "id": 405 + "id": 405, + "legacy": true }, "d646f3ea2d7003fcaa77ad219136c78e024a6f2e2307dfb8cfa97a171373ecdf": { "fingerprints": [ "74cb3a4ea791afb0a2d1a0b13301b3bee0e50ad5c79a1a6f2c663e6f4ee7a484" ], - "id": 374 + "id": 374, + "legacy": true }, "d6a18443d348db994f934ccd8e635d833a27ac1e56f8afaf7c97cb4f43eab68b": { "fingerprints": [ "4b22d5a6aec99f3cdb79aa5ec06838479cd5ecba7164f7f22dc1d65f63d85708" ], - "id": 172 + "id": 172, + "legacy": true }, "d8fb33e385c9c2da729a84706ba927dcbb79273e122ffd9673363b70b7f36cbb": { "fingerprints": [ "8c4edfd04348f322969e7e29a4cd4dca004655061c16e1b076422ef342ad630e" ], - "id": 153 + "id": 153, + "legacy": true }, "d92405c46d912a563e43287f56cd410a1cdf6367c57c9ea7c5cae039dcbcce50": { "fingerprints": [ "8da75f1327217c88060fd2529eff2816e50b0c74541ea4ea3dfcee66a71efe09" ], - "id": 365 + "id": 365, + "legacy": true }, "d9c473cee25f94d1bc6062bd62911477276f064b827a944e064f85d0912d2c5e": { "fingerprints": [ "248302a977f40f7dd6a2b770586adfaac3eb1e85fd1a102dbd7863c72b8f8ef2" ], - "id": 253 + "id": 253, + "legacy": true }, "da800b80b2a87d399e66fa19d72fdf49983b47d8cf322c7c79503a0c7e28feaf": { "fingerprints": [ "3a43e220fe7f3ea9653d1e21742eac2b75c20fd8980305bc502caf8c2d9b41a1" ], - "id": 230 + "id": 230, + "legacy": true }, "da8796be34cc81abee7304c4d2bca0ac984c5b24b61b13e2285e1d27ad8cebf0": { "fingerprints": [ "7b1f8d8eff5d7349fedb7eae89c29aacc41704f1503ae3c8c2eba10225d0f568", "ae2fec829118a2455ad6a415e71823eb9b7b6e3578a51ac8a51446eadbb0979c" ], - "id": 218 + "id": 218, + "legacy": true }, "db15c0062b520f318a19dacfecd64f9e7a3fbe609fd586796f20ae028e8e3058": { "fingerprints": [ "d6f034bd94aa233f0297eca4245b283973e447aa590f310c77f48fdf83112254" ], - "id": 168 + "id": 168, + "legacy": true }, "dbc1e3a15238a0483bcdb8fdec616e03e705a48e2a501157cadf3b9c7311c5e5": { "fingerprints": [ @@ -24522,7 +25975,8 @@ "fingerprints": [ "7d2bf3489ebc9ad3448b8b0827715a3cbfe3d523e3b56a9b5fc1d2a2da2f20fe" ], - "id": 399 + "id": 399, + "legacy": true }, "dd5ed1c090f9f448061baa94a6bb11017544e9eefaa20cc714ce6c633f5dc629": { "fingerprints": [ @@ -24534,56 +25988,65 @@ "fingerprints": [ "41d4f6dcf130b9843a3b9a9530953e925fdd84e8b7aeb8f205b8fae39352617d" ], - "id": 236 + "id": 236, + "legacy": true }, "df530bac9fcd914c252c2fbdceddc6183d4ae8c680ad65f03e204861dd7b1c73": { "fingerprints": [ "885de64c340e3ea70658f01e1145f957fcda27aabeea1ab9faa9fdb0102d4077" ], - "id": 313 + "id": 313, + "legacy": true }, "e0ef882da48ab0b7efb0d9ba15b2717dd08f043c25ac09b56b8b57fceeb5a35d": { "fingerprints": [ "e6e4a951ecbf7d8edc01bc873f7b6fd35868bdb10ed786f3a1b1ee16d8cec3e9" ], - "id": 369 + "id": 369, + "legacy": true }, "e156445fa20c32ad00937b27d096b8963bcc863950333a877e68fa69707a03af": { "fingerprints": [ "54b4fc43d44aa4ca9fc03ca7e9949fbae267a064d02da21852412a381b5d1537" ], - "id": 445 + "id": 445, + "legacy": true }, "e26613a578e158c2a44e4fec41e6f37a0a991fe1a5fe736c303f4420a90fb50a": { "fingerprints": [ "f1f3cc207a6d47947b8cb9c30422229de0d71fb867e0b9a3eda08e0e1736bc28" ], - "id": 331 + "id": 331, + "legacy": true }, "e2d891efb738669105d530de5ed72e2b2ac3f4a67078b5349b3fdaca496f5eb8": { "fingerprints": [ "3f06e55681d496f5be169eb5389f9f2b8ff61e1708df6881724849cd5d27cb69" ], - "id": 9 + "id": 9, + "legacy": true }, "e3b0c44298fc1c149afbf4c8996fb92427ae41e4649b934ca495991b7852b855": { "fingerprints": [ "e3b0c44298fc1c149afbf4c8996fb92427ae41e4649b934ca495991b7852b855" ], - "id": 488 + "id": 488, + "legacy": true }, "e42f24bd4d37f4aa2e56b979d83d1e65219fe0e9e3a382a1b3cb66c93955de75": { "fingerprints": [ "c766a9bef2d4071c863a31aa4920e813b2d198608cb7b7cfe21143b836df09ea", "e17890ee09a3fbf4f48b9c414a17d637b7a50647e9bc752322727fcc1742a911" ], - "id": 29 + "id": 29, + "legacy": true }, "e43dea894f42cecf4a1dd60ed1dab82f7c0a308ae32a3d49a7aa1a3e957015f7": { "fingerprints": [ "2dc70e588d340de5966ae32f6fc796bdb5de6d7c25cd249a4be64e9df9036323" ], - "id": 212 + "id": 212, + "legacy": true }, "e5ca37bc7b6c361979bc6b123ca9a1db019046d7ff5f57dfb854b19d10b0682f": { "fingerprints": [ @@ -24601,13 +26064,15 @@ "fingerprints": [ "a798a1c70e9b6d50eaa5724a26fac7991848edc61bf48d79816bcafb66972128" ], - "id": 345 + "id": 345, + "legacy": true }, "ea2f9e087eaebbdfc0569eca18364e5236254624854f92e37871b5ee36744883": { "fingerprints": [ "4e7480ad702a379dc589adb4faa625e6a5993f87ef2375d5437ffe3b79be4e96" ], - "id": 297 + "id": 297, + "legacy": true }, "ea87f462deefffbd7775aa2a4b7e0fcb91c22eee6df69ed90100ccc73b311476": { "fingerprints": [ @@ -24621,7 +26086,8 @@ "b0b1730ecbc7ff4505142c49f1295e6eda6bcaed7e2c68c5be91b5a11001f024", "0d83b611b648a1a75eb8558400795375cad92e264ed8e9d7a757c1f5ee2bb22d" ], - "id": 215 + "id": 215, + "legacy": true }, "ec9056fe9509411609763aee831ef37c832b75b3d727528fc7c75201c1ff28e6": { "fingerprints": [ @@ -24639,32 +26105,37 @@ "fingerprints": [ "781d64dfa77b00f2c006700b1fda86bf68b865a603c7a656f92e90c042ca2873" ], - "id": 377 + "id": 377, + "legacy": true }, "ede4b1535a529bf1606bc6ff757b91470aa30aeaffd2d6df2eba340dae302fca": { "fingerprints": [ "e8a2f441657678975f2b97d775719c7d49d92234554540ec14d92e16fe27d2cb", "3deae6ae975284e0e6fa2eb76ce46e12441869a2a7d4e67dc7ab8664fefdbbb0" ], - "id": 219 + "id": 219, + "legacy": true }, "ef4fa1c630f04950e0e2d10dc19f149d08ab46dec95da3131cbaea8af8ea3027": { "fingerprints": [ "42143a511a3afcdd80d555debb4191ec6bb285ee66e62ec657ed20adf7d55faa" ], - "id": 393 + "id": 393, + "legacy": true }, "ef53ffaf0ceb040d077f5bd80a9deef6d4507fdb6f9bcf8c3594bece7ebdb025": { "fingerprints": [ "36544d2fce03c6c72b70eb1a8064264dc1511768c2d8f76a8b9f1f2bbd153b7d" ], - "id": 361 + "id": 361, + "legacy": true }, "effee1f1e5f39f42ff80d471c9c5a799a8c843f9b676315f9eab3f4c7a2f7fc8": { "fingerprints": [ "4898c6888c0cffb0d3e31aca8a37d4e3515ff746d02635d86646cfa0a3185ae7" ], - "id": 129 + "id": 129, + "legacy": true }, "f1c6ba670cfc88e4df52973cae420f0a089dd474144fe5806c420064e1591229": { "fingerprints": [ @@ -24676,7 +26147,8 @@ "fingerprints": [ "ddbf149733bc2bf8a09d7f012b01a6dea11d7bae26713783ef6407a2495bf189" ], - "id": 474 + "id": 474, + "legacy": true }, "f3438e23b3ce532522facf307923f58fd18608e9ba7addc30e952b43c49616c3": { "fingerprints": [ @@ -24688,13 +26160,15 @@ "fingerprints": [ "97f654859cbde586fd90311e82ec7902c238cba0d6e529564c9c88f44895ec50" ], - "id": 467 + "id": 467, + "legacy": true }, "f463c54d9f1a047aed52656ac785e07ebec528e0207bfd3f55d893237668f6ae": { "fingerprints": [ "d95fea3ca4eedce74cd76e75fc6d1ff62c441f0fa8bc77f034b19e5db258015d" ], - "id": 96 + "id": 96, + "legacy": true }, "f48badd7df6a06690d0ae31373b12855f8dedb14517f362a313101cc98cc6b35": { "fingerprints": [ @@ -24707,43 +26181,50 @@ "3f9f27d583204b9e09c8a3d2066c4b57d3a2479c3693650880505698105dbce9", "ab7036365c7154aa29c2c29f5d4191163b162a2225011357d56d07ffa7bc1f72" ], - "id": 118 + "id": 118, + "legacy": true }, "f5857d8862bc2ba3c9ddca3f84146dc8d81f4d579d2b387bf60065381ee641dd": { "fingerprints": [ "ccc89489371bad111c90619bea240a2e6dadd99f9f6e1d4d41e58ed6de3d0285" ], - "id": 335 + "id": 335, + "legacy": true }, "f5e19c8e14fe755f551cec2b7113e7c98023b176ebe6c1abcf872b2a7b932304": { "fingerprints": [ "5607e260163f49c8ea4175a1c0a53b13195cb7d07845611e943a2ff507036834" ], - "id": 363 + "id": 363, + "legacy": true }, "f6146bc238e8fce0d47b7074c9a26b1aa0f883528510f06d9cfec41ff6ca1968": { "fingerprints": [ "e606ddeee2ee7f5cdef5d9058ff8b7d0a9f042877f6a171ed8ff6960e4cc5ea5" ], - "id": 247 + "id": 247, + "legacy": true }, "f6b59c8e2789a1fd5d5b253742feadc6925cb93edc345e53166e12c52ba2a601": { "fingerprints": [ "8f9e2751dcd574e9ba90e744ea92581fd0af640ae86ac1ce2198c90f96b44823" ], - "id": 327 + "id": 327, + "legacy": true }, "f73be5eba536912c557fb855517ad1ee0487bd8f63498c3949164177ba06c5de": { "fingerprints": [ "77a03f69e4f3955589acaca06f6773a0d98d16dea05c6d94ee3ef6fb2beb7605" ], - "id": 380 + "id": 380, + "legacy": true }, "f7aff41b2709f175f8aba17e567b27046b2dd54bf6e7e263d3295873437b9cff": { "fingerprints": [ "6baf50ae3467eff3c35fefdc76a02a97fab6267723eda91e99f1b3dc2b28f82e" ], - "id": 387 + "id": 387, + "legacy": true }, "f7ecded5c66047d28ed6466b543c40e0743abe81d109254dcf845d4c2c7853c5": { "fingerprints": [ @@ -24755,20 +26236,23 @@ "fingerprints": [ "9f9744463be13714754e1a3becf98c08cc205e4ab32028f4e2830c4a1b2775b8" ], - "id": 222 + "id": 222, + "legacy": true }, "fac95de3c24a174194800cffaa3ca51d7116630664a9b60c8758b4ef0dc58f88": { "fingerprints": [ "793cbf4559b9fde38ab22df16869f69881ae14c4b0139ac788a78a1afcca02fb", "8688e58f4c7a945fadce7f62bfef521b82da7dc38bfdb0163478a5fe42e57870" ], - "id": 119 + "id": 119, + "legacy": true }, "faddde04bcf08ca8f4e22efd2afeade6bf3d850ae47be96a82d539494f120cbd": { "fingerprints": [ "8f633df0191a417dcd4f6331f0e90eb947158c8a3ea59bfe81420041315eac6c" ], - "id": 350 + "id": 350, + "legacy": true }, "fbe3018031f9586bcbf41727e417b7d1c45c2f47f93be372a17b96b50757d5a2": { "fingerprints": [ @@ -24780,25 +26264,29 @@ "fingerprints": [ "39c75caecee8920c909f132491641350b57e2702a65a991545b01d1be4a2220b" ], - "id": 158 + "id": 158, + "legacy": true }, "fcf7da983603e88862030d96137d8e13031badfb4d56c1fd4cacc339f6bdbb2a": { "fingerprints": [ "7d3b465a6014e526c0affcee2127d2311727ad811c26842d006af37306cc80bd" ], - "id": 28 + "id": 28, + "legacy": true }, "fd371bea9755ff60c8828c849b8e5215de532d61b009855fa0ad630d90eef82e": { "fingerprints": [ "8560f91c3624daba9570b5fea0dbe36ff11a8323be9486854fb3f34a5571198d" ], - "id": 490 + "id": 490, + "legacy": true }, "fd872d176617e50c266119d0fdb047b0732da2048b121af7b9860ca3e2f2f2be": { "fingerprints": [ "a6c51e0da5ca0a9309d2e4c0e40c2af9107aae8203857fe198e3e769e343085c" ], - "id": 123 + "id": 123, + "legacy": true }, "fea2b7d645fba73d753c1ec9a7870c40e1f7b0c561e927b985bf711866e36f22": { "fingerprints": [ @@ -24816,7 +26304,8 @@ "fingerprints": [ "08297a4047dba23680c731db6e317653ca7848e1bebd3a0b0179a707f92cf178" ], - "id": 54 + "id": 54, + "legacy": true } } } \ No newline at end of file
diff --git a/net/socket/ssl_client_socket.h b/net/socket/ssl_client_socket.h index b173c76..dd3d401d 100644 --- a/net/socket/ssl_client_socket.h +++ b/net/socket/ssl_client_socket.h
@@ -162,9 +162,9 @@ FRIEND_TEST_ALL_PREFIXES(SSLClientSocket, SerializeNextProtos); // For signed_cert_timestamps_received_ and stapled_ocsp_response_received_. FRIEND_TEST_ALL_PREFIXES(SSLClientSocketTest, - ConnectSignedCertTimestampsEnabledTLSExtension); + ConnectSignedCertTimestampsTLSExtension); FRIEND_TEST_ALL_PREFIXES(SSLClientSocketTest, - ConnectSignedCertTimestampsEnabledOCSP); + ConnectSignedCertTimestampsEnablesOCSP); FRIEND_TEST_ALL_PREFIXES(SSLClientSocketTest, ConnectSignedCertTimestampsDisabled); FRIEND_TEST_ALL_PREFIXES(SSLClientSocketTest,
diff --git a/net/socket/ssl_client_socket_impl.cc b/net/socket/ssl_client_socket_impl.cc index 04c85c9..9fee5da 100644 --- a/net/socket/ssl_client_socket_impl.cc +++ b/net/socket/ssl_client_socket_impl.cc
@@ -962,10 +962,8 @@ wire_protos.size()); } - if (ssl_config_.signed_cert_timestamps_enabled) { - SSL_enable_signed_cert_timestamps(ssl_.get()); - SSL_enable_ocsp_stapling(ssl_.get()); - } + SSL_enable_signed_cert_timestamps(ssl_.get()); + SSL_enable_ocsp_stapling(ssl_.get()); if (cert_verifier_->SupportsOCSPStapling()) SSL_enable_ocsp_stapling(ssl_.get());
diff --git a/net/socket/ssl_client_socket_unittest.cc b/net/socket/ssl_client_socket_unittest.cc index 91acc11..ce747beb 100644 --- a/net/socket/ssl_client_socket_unittest.cc +++ b/net/socket/ssl_client_socket_unittest.cc
@@ -2448,7 +2448,9 @@ EXPECT_EQ(CLIENT_CERT_ECDSA_SIGN, request_info->cert_key_types[1]); } -TEST_F(SSLClientSocketTest, ConnectSignedCertTimestampsEnabledTLSExtension) { +// Tests that the Certificate Transparency (RFC 6962) TLS extension is +// supported. +TEST_F(SSLClientSocketTest, ConnectSignedCertTimestampsTLSExtension) { // Encoding of SCT List containing 'test'. base::StringPiece sct_ext("\x00\x06\x00\x04test", 8); @@ -2457,7 +2459,6 @@ ASSERT_TRUE(StartTestServer(ssl_options)); SSLConfig ssl_config; - ssl_config.signed_cert_timestamps_enabled = true; MockCTVerifier ct_verifier; SetCTVerifier(&ct_verifier); @@ -2610,8 +2611,9 @@ static_cast<int>(ct::CTPolicyCompliance::CT_POLICY_COMPLIES_VIA_SCTS), 1); } -// Test that enabling Signed Certificate Timestamps enables OCSP stapling. -TEST_F(SSLClientSocketTest, ConnectSignedCertTimestampsEnabledOCSP) { +// Tests that OCSP stapling is requested, as per Certificate Transparency (RFC +// 6962). +TEST_F(SSLClientSocketTest, ConnectSignedCertTimestampsEnablesOCSP) { SpawnedTestServer::SSLOptions ssl_options; ssl_options.staple_ocsp_response = true; // The test server currently only knows how to generate OCSP responses @@ -2621,10 +2623,6 @@ ASSERT_TRUE(StartTestServer(ssl_options)); SSLConfig ssl_config; - // Enabling Signed Cert Timestamps ensures we request OCSP stapling for - // Certificate Transparency verification regardless of whether the platform - // is able to process the OCSP status itself. - ssl_config.signed_cert_timestamps_enabled = true; int rv; ASSERT_TRUE(CreateAndConnectSSLClientSocket(ssl_config, &rv)); @@ -2633,22 +2631,6 @@ EXPECT_TRUE(sock_->stapled_ocsp_response_received_); } -TEST_F(SSLClientSocketTest, ConnectSignedCertTimestampsDisabled) { - SpawnedTestServer::SSLOptions ssl_options; - ssl_options.signed_cert_timestamps_tls_ext = "test"; - - ASSERT_TRUE(StartTestServer(ssl_options)); - - SSLConfig ssl_config; - ssl_config.signed_cert_timestamps_enabled = false; - - int rv; - ASSERT_TRUE(CreateAndConnectSSLClientSocket(ssl_config, &rv)); - EXPECT_THAT(rv, IsOk()); - - EXPECT_FALSE(sock_->signed_cert_timestamps_received_); -} - // Tests that IsConnectedAndIdle and WasEverUsed behave as expected. TEST_F(SSLClientSocketTest, ReuseStates) { ASSERT_TRUE(StartTestServer(SpawnedTestServer::SSLOptions()));
diff --git a/net/ssl/ssl_config.cc b/net/ssl/ssl_config.cc index 883c7f8d..50538a0 100644 --- a/net/ssl/ssl_config.cc +++ b/net/ssl/ssl_config.cc
@@ -32,7 +32,6 @@ version_interference_probe(false), channel_id_enabled(true), false_start_enabled(true), - signed_cert_timestamps_enabled(true), require_ecdhe(false), send_client_cert(false), verify_ev_cert(false),
diff --git a/net/ssl/ssl_config.h b/net/ssl/ssl_config.h index da55dad..bbfe459 100644 --- a/net/ssl/ssl_config.h +++ b/net/ssl/ssl_config.h
@@ -124,9 +124,6 @@ std::vector<TokenBindingParam> token_binding_params; bool false_start_enabled; // True if we'll use TLS False Start. - // True if the Certificate Transparency signed_certificate_timestamp - // TLS extension is enabled. - bool signed_cert_timestamps_enabled; // If true, causes only ECDHE cipher suites to be enabled. bool require_ecdhe;
diff --git a/pdf/out_of_process_instance.cc b/pdf/out_of_process_instance.cc index 3e47b62..8be81af 100644 --- a/pdf/out_of_process_instance.cc +++ b/pdf/out_of_process_instance.cc
@@ -1500,7 +1500,8 @@ void OutOfProcessInstance::DocumentPaintOccurred() {} void OutOfProcessInstance::DocumentLoadComplete( - const PDFEngine::DocumentFeatures& document_features) { + const PDFEngine::DocumentFeatures& document_features, + uint32_t file_size) { // Clear focus state for OSK. FormTextFieldFocusChange(false); @@ -1565,6 +1566,9 @@ } pp::PDF::SetContentRestriction(this, content_restrictions); + static const int32_t kMaxFileSizeInKB = 12 * 1024 * 1024; + HistogramCustomCounts("PDF.FileSizeInKB", file_size / 1024, 0, + kMaxFileSizeInKB, 50); HistogramCustomCounts("PDF.PageCount", document_features.page_count, 1, 1000000, 50); HistogramEnumeration("PDF.HasAttachment",
diff --git a/pdf/out_of_process_instance.h b/pdf/out_of_process_instance.h index edc6cd9..654623f9 100644 --- a/pdf/out_of_process_instance.h +++ b/pdf/out_of_process_instance.h
@@ -135,7 +135,8 @@ bool case_sensitive) override; void DocumentPaintOccurred() override; void DocumentLoadComplete( - const PDFEngine::DocumentFeatures& document_features) override; + const PDFEngine::DocumentFeatures& document_features, + uint32_t file_size) override; void DocumentLoadFailed() override; void FontSubstituted() override; pp::Instance* GetPluginInstance() override;
diff --git a/pdf/pdf_engine.h b/pdf/pdf_engine.h index d6964c6d..ed1e468e 100644 --- a/pdf/pdf_engine.h +++ b/pdf/pdf_engine.h
@@ -235,8 +235,8 @@ virtual void DocumentPaintOccurred() = 0; // Notifies the client that the document has finished loading. - virtual void DocumentLoadComplete( - const DocumentFeatures& document_features) = 0; + virtual void DocumentLoadComplete(const DocumentFeatures& document_features, + uint32_t file_size) = 0; // Notifies the client that the document has failed to load. virtual void DocumentLoadFailed() = 0;
diff --git a/pdf/pdfium/pdfium_engine.cc b/pdf/pdfium/pdfium_engine.cc index e3eeead..04b0849 100644 --- a/pdf/pdfium/pdfium_engine.cc +++ b/pdf/pdfium/pdfium_engine.cc
@@ -1378,7 +1378,8 @@ (FPDFAvail_IsLinearized(fpdf_availability_) == PDF_LINEARIZED); document_features.is_tagged = FPDFCatalog_IsTagged(doc_); document_features.form_type = static_cast<FormType>(FPDF_GetFormType(doc_)); - client_->DocumentLoadComplete(document_features); + client_->DocumentLoadComplete(document_features, + doc_loader_->bytes_received()); } }
diff --git a/pdf/preview_mode_client.cc b/pdf/preview_mode_client.cc index d2fc67b..cfe2bfc 100644 --- a/pdf/preview_mode_client.cc +++ b/pdf/preview_mode_client.cc
@@ -136,7 +136,8 @@ } void PreviewModeClient::DocumentLoadComplete( - const PDFEngine::DocumentFeatures& document_features) { + const PDFEngine::DocumentFeatures& document_features, + uint32_t file_size) { client_->PreviewDocumentLoadComplete(); }
diff --git a/pdf/preview_mode_client.h b/pdf/preview_mode_client.h index b12dc3329..3786478b 100644 --- a/pdf/preview_mode_client.h +++ b/pdf/preview_mode_client.h
@@ -66,7 +66,8 @@ bool case_sensitive) override; void DocumentPaintOccurred() override; void DocumentLoadComplete( - const PDFEngine::DocumentFeatures& document_features) override; + const PDFEngine::DocumentFeatures& document_features, + uint32_t file_size) override; void DocumentLoadFailed() override; void FontSubstituted() override; pp::Instance* GetPluginInstance() override;
diff --git a/services/device/public/cpp/generic_sensor/sensor_traits.cc b/services/device/public/cpp/generic_sensor/sensor_traits.cc index f284493..849b1dc 100644 --- a/services/device/public/cpp/generic_sensor/sensor_traits.cc +++ b/services/device/public/cpp/generic_sensor/sensor_traits.cc
@@ -37,10 +37,44 @@ case SensorType::RELATIVE_ORIENTATION_QUATERNION: return SensorTraits< SensorType::RELATIVE_ORIENTATION_QUATERNION>::kMaxAllowedFrequency; - default: - NOTREACHED() << "Unknown sensor type " << type; - return SensorTraits<SensorType::LAST>::kMaxAllowedFrequency; + // No default so the compiler will warn us if a new type is added. } + NOTREACHED() << "Unknown sensor type " << type; + return SensorTraits<SensorType::LAST>::kMaxAllowedFrequency; +} + +double GetSensorDefaultFrequency(mojom::SensorType type) { + switch (type) { + case SensorType::AMBIENT_LIGHT: + return SensorTraits<SensorType::AMBIENT_LIGHT>::kDefaultFrequency; + case SensorType::PROXIMITY: + return SensorTraits<SensorType::PROXIMITY>::kDefaultFrequency; + case SensorType::ACCELEROMETER: + return SensorTraits<SensorType::ACCELEROMETER>::kDefaultFrequency; + case SensorType::LINEAR_ACCELERATION: + return SensorTraits<SensorType::LINEAR_ACCELERATION>::kDefaultFrequency; + case SensorType::GYROSCOPE: + return SensorTraits<SensorType::GYROSCOPE>::kDefaultFrequency; + case SensorType::MAGNETOMETER: + return SensorTraits<SensorType::MAGNETOMETER>::kDefaultFrequency; + case SensorType::PRESSURE: + return SensorTraits<SensorType::PRESSURE>::kDefaultFrequency; + case SensorType::ABSOLUTE_ORIENTATION_EULER_ANGLES: + return SensorTraits< + SensorType::ABSOLUTE_ORIENTATION_EULER_ANGLES>::kDefaultFrequency; + case SensorType::ABSOLUTE_ORIENTATION_QUATERNION: + return SensorTraits< + SensorType::ABSOLUTE_ORIENTATION_QUATERNION>::kDefaultFrequency; + case SensorType::RELATIVE_ORIENTATION_EULER_ANGLES: + return SensorTraits< + SensorType::RELATIVE_ORIENTATION_EULER_ANGLES>::kDefaultFrequency; + case SensorType::RELATIVE_ORIENTATION_QUATERNION: + return SensorTraits< + SensorType::RELATIVE_ORIENTATION_QUATERNION>::kDefaultFrequency; + // No default so the compiler will warn us if a new type is added. + } + NOTREACHED() << "Unknown sensor type " << type; + return SensorTraits<SensorType::LAST>::kDefaultFrequency; } } // namespace device
diff --git a/services/device/public/cpp/generic_sensor/sensor_traits.h b/services/device/public/cpp/generic_sensor/sensor_traits.h index 8a76ee9..6d935129 100644 --- a/services/device/public/cpp/generic_sensor/sensor_traits.h +++ b/services/device/public/cpp/generic_sensor/sensor_traits.h
@@ -30,6 +30,8 @@ double GetSensorMaxAllowedFrequency(mojom::SensorType type); +double GetSensorDefaultFrequency(mojom::SensorType type); + } // namespace device #endif // SERVICES_DEVICE_PUBLIC_CPP_GENERIC_SENSOR_SENSOR_TRAITS_H_
diff --git a/services/device/public/cpp/test/BUILD.gn b/services/device/public/cpp/test/BUILD.gn index 3a8db4a..a560983 100644 --- a/services/device/public/cpp/test/BUILD.gn +++ b/services/device/public/cpp/test/BUILD.gn
@@ -3,18 +3,25 @@ # found in the LICENSE file. source_set("test_support") { + testonly = true + sources = [ + "fake_sensor_and_provider.cc", + "fake_sensor_and_provider.h", "test_wake_lock_provider.cc", "test_wake_lock_provider.h", ] public_deps = [ "//base", + "//services/device/public/cpp/generic_sensor", "//services/device/public/mojom", "//services/service_manager/public/cpp", ] deps = [ "//mojo/public/cpp/bindings", + "//mojo/public/cpp/system", + "//testing/gtest", ] }
diff --git a/services/device/public/cpp/test/fake_sensor_and_provider.cc b/services/device/public/cpp/test/fake_sensor_and_provider.cc new file mode 100644 index 0000000..80976ef --- /dev/null +++ b/services/device/public/cpp/test/fake_sensor_and_provider.cc
@@ -0,0 +1,317 @@ +// Copyright 2018 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 "services/device/public/cpp/test/fake_sensor_and_provider.h" + +#include <memory> +#include <utility> + +#include "base/logging.h" +#include "base/time/time.h" +#include "mojo/public/cpp/bindings/interface_request.h" +#include "mojo/public/cpp/bindings/strong_binding.h" +#include "services/device/public/cpp/generic_sensor/sensor_traits.h" +#include "testing/gtest/include/gtest/gtest.h" + +namespace { + +const uint64_t kReadingBufferSize = sizeof(device::SensorReadingSharedBuffer); +const uint64_t kSharedBufferSizeInBytes = + kReadingBufferSize * static_cast<uint64_t>(device::mojom::SensorType::LAST); + +} // namespace + +namespace device { + +FakeSensor::FakeSensor(mojom::SensorType sensor_type, + SensorReadingSharedBuffer* buffer) + : sensor_type_(sensor_type), buffer_(buffer) {} + +FakeSensor::~FakeSensor() = default; + +void FakeSensor::AddConfiguration( + const PlatformSensorConfiguration& configuration, + AddConfigurationCallback callback) { + std::move(callback).Run(true); + SensorReadingChanged(); +} + +void FakeSensor::GetDefaultConfiguration( + GetDefaultConfigurationCallback callback) { + std::move(callback).Run(GetDefaultConfiguration()); +} + +void FakeSensor::RemoveConfiguration( + const PlatformSensorConfiguration& configuration) {} + +void FakeSensor::Suspend() {} + +void FakeSensor::Resume() {} + +void FakeSensor::ConfigureReadingChangeNotifications(bool enabled) { + reading_notification_enabled_ = enabled; +} + +PlatformSensorConfiguration FakeSensor::GetDefaultConfiguration() { + return PlatformSensorConfiguration(GetSensorDefaultFrequency(sensor_type_)); +} + +mojom::ReportingMode FakeSensor::GetReportingMode() { + return mojom::ReportingMode::ON_CHANGE; +} + +double FakeSensor::GetMaximumSupportedFrequency() { + return GetSensorMaxAllowedFrequency(sensor_type_); +} + +double FakeSensor::GetMinimumSupportedFrequency() { + return 1.0; +} + +mojom::SensorClientRequest FakeSensor::GetClient() { + return mojo::MakeRequest(&client_); +} + +uint64_t FakeSensor::GetBufferOffset() { + return SensorReadingSharedBuffer::GetOffset(sensor_type_); +} + +void FakeSensor::SetReading(SensorReading reading) { + reading_ = reading; + SensorReadingChanged(); +} + +void FakeSensor::SensorReadingChanged() { + auto& seqlock = buffer_->seqlock.value(); + seqlock.WriteBegin(); + buffer_->reading = reading_; + seqlock.WriteEnd(); + + if (client_ && reading_notification_enabled_) + client_->SensorReadingChanged(); +} + +FakeSensorProvider::FakeSensorProvider() : binding_(this) {} + +FakeSensorProvider::~FakeSensorProvider() = default; + +void FakeSensorProvider::GetSensor(mojom::SensorType type, + GetSensorCallback callback) { + if (!CreateSharedBufferIfNeeded()) { + std::move(callback).Run(mojom::SensorCreationResult::ERROR_NOT_AVAILABLE, + nullptr); + return; + } + + SensorReadingSharedBuffer* buffer = GetSensorReadingSharedBufferForType(type); + + std::unique_ptr<FakeSensor> sensor; + + switch (type) { + case mojom::SensorType::AMBIENT_LIGHT: + if (ambient_light_sensor_is_available_) { + sensor = std::make_unique<FakeSensor>(mojom::SensorType::AMBIENT_LIGHT, + buffer); + ambient_light_sensor_ = sensor.get(); + ambient_light_sensor_->SetReading(ambient_light_sensor_reading_); + } + break; + case mojom::SensorType::ACCELEROMETER: + if (accelerometer_is_available_) { + sensor = std::make_unique<FakeSensor>(mojom::SensorType::ACCELEROMETER, + buffer); + accelerometer_ = sensor.get(); + accelerometer_->SetReading(accelerometer_reading_); + } + break; + case mojom::SensorType::LINEAR_ACCELERATION: + if (linear_acceleration_sensor_is_available_) { + sensor = std::make_unique<FakeSensor>( + mojom::SensorType::LINEAR_ACCELERATION, buffer); + linear_acceleration_sensor_ = sensor.get(); + linear_acceleration_sensor_->SetReading( + linear_acceleration_sensor_reading_); + } + break; + case mojom::SensorType::GYROSCOPE: + if (gyroscope_is_available_) { + sensor = + std::make_unique<FakeSensor>(mojom::SensorType::GYROSCOPE, buffer); + gyroscope_ = sensor.get(); + gyroscope_->SetReading(gyroscope_reading_); + } + break; + case mojom::SensorType::RELATIVE_ORIENTATION_EULER_ANGLES: + if (relative_orientation_sensor_is_available_) { + sensor = std::make_unique<FakeSensor>( + mojom::SensorType::RELATIVE_ORIENTATION_EULER_ANGLES, buffer); + relative_orientation_sensor_ = sensor.get(); + relative_orientation_sensor_->SetReading( + relative_orientation_sensor_reading_); + } + break; + case mojom::SensorType::ABSOLUTE_ORIENTATION_EULER_ANGLES: + if (absolute_orientation_sensor_is_available_) { + sensor = std::make_unique<FakeSensor>( + mojom::SensorType::ABSOLUTE_ORIENTATION_EULER_ANGLES, buffer); + absolute_orientation_sensor_ = sensor.get(); + absolute_orientation_sensor_->SetReading( + absolute_orientation_sensor_reading_); + } + break; + default: + NOTIMPLEMENTED(); + } + + if (sensor) { + auto init_params = mojom::SensorInitParams::New(); + init_params->client_request = sensor->GetClient(); + init_params->memory = shared_buffer_handle_->Clone( + mojo::SharedBufferHandle::AccessMode::READ_ONLY); + init_params->buffer_offset = sensor->GetBufferOffset(); + init_params->default_configuration = sensor->GetDefaultConfiguration(); + init_params->maximum_frequency = sensor->GetMaximumSupportedFrequency(); + init_params->minimum_frequency = sensor->GetMinimumSupportedFrequency(); + + mojo::MakeStrongBinding(std::move(sensor), + mojo::MakeRequest(&init_params->sensor)); + std::move(callback).Run(mojom::SensorCreationResult::SUCCESS, + std::move(init_params)); + } else { + std::move(callback).Run(mojom::SensorCreationResult::ERROR_NOT_AVAILABLE, + nullptr); + } +} + +void FakeSensorProvider::Bind(mojom::SensorProviderRequest request) { + DCHECK(!binding_.is_bound()); + binding_.Bind(std::move(request)); +} + +void FakeSensorProvider::SetAmbientLightSensorData(double value) { + ambient_light_sensor_reading_.als.timestamp = + (base::TimeTicks::Now() - base::TimeTicks()).InSecondsF(); + ambient_light_sensor_reading_.als.value = value; +} + +void FakeSensorProvider::SetAccelerometerData(double x, double y, double z) { + accelerometer_reading_.raw.timestamp = + (base::TimeTicks::Now() - base::TimeTicks()).InSecondsF(); + accelerometer_reading_.accel.x = x; + accelerometer_reading_.accel.y = y; + accelerometer_reading_.accel.z = z; +} + +void FakeSensorProvider::SetLinearAccelerationSensorData(double x, + double y, + double z) { + linear_acceleration_sensor_reading_.raw.timestamp = + (base::TimeTicks::Now() - base::TimeTicks()).InSecondsF(); + linear_acceleration_sensor_reading_.accel.x = x; + linear_acceleration_sensor_reading_.accel.y = y; + linear_acceleration_sensor_reading_.accel.z = z; +} + +void FakeSensorProvider::SetGyroscopeData(double x, double y, double z) { + gyroscope_reading_.raw.timestamp = + (base::TimeTicks::Now() - base::TimeTicks()).InSecondsF(); + gyroscope_reading_.gyro.x = x; + gyroscope_reading_.gyro.y = y; + gyroscope_reading_.gyro.z = z; +} + +void FakeSensorProvider::SetRelativeOrientationSensorData(double alpha, + double beta, + double gamma) { + relative_orientation_sensor_reading_.raw.timestamp = + (base::TimeTicks::Now() - base::TimeTicks()).InSecondsF(); + relative_orientation_sensor_reading_.orientation_euler.x = beta; + relative_orientation_sensor_reading_.orientation_euler.y = gamma; + relative_orientation_sensor_reading_.orientation_euler.z = alpha; +} + +void FakeSensorProvider::SetAbsoluteOrientationSensorData(double alpha, + double beta, + double gamma) { + absolute_orientation_sensor_reading_.raw.timestamp = + (base::TimeTicks::Now() - base::TimeTicks()).InSecondsF(); + absolute_orientation_sensor_reading_.orientation_euler.x = beta; + absolute_orientation_sensor_reading_.orientation_euler.y = gamma; + absolute_orientation_sensor_reading_.orientation_euler.z = alpha; +} + +void FakeSensorProvider::UpdateAmbientLightSensorData(double value) { + SetAmbientLightSensorData(value); + EXPECT_TRUE(ambient_light_sensor_); + ambient_light_sensor_->SetReading(ambient_light_sensor_reading_); +} + +void FakeSensorProvider::UpdateAccelerometerData(double x, double y, double z) { + SetAccelerometerData(x, y, z); + EXPECT_TRUE(accelerometer_); + accelerometer_->SetReading(accelerometer_reading_); +} + +void FakeSensorProvider::UpdateLinearAccelerationSensorData(double x, + double y, + double z) { + SetLinearAccelerationSensorData(x, y, z); + EXPECT_TRUE(linear_acceleration_sensor_); + linear_acceleration_sensor_->SetReading(linear_acceleration_sensor_reading_); +} + +void FakeSensorProvider::UpdateGyroscopeData(double x, double y, double z) { + SetGyroscopeData(x, y, z); + EXPECT_TRUE(gyroscope_); + gyroscope_->SetReading(gyroscope_reading_); +} + +void FakeSensorProvider::UpdateRelativeOrientationSensorData(double alpha, + double beta, + double gamma) { + SetRelativeOrientationSensorData(alpha, beta, gamma); + EXPECT_TRUE(relative_orientation_sensor_); + relative_orientation_sensor_->SetReading( + relative_orientation_sensor_reading_); +} + +void FakeSensorProvider::UpdateAbsoluteOrientationSensorData(double alpha, + double beta, + double gamma) { + SetAbsoluteOrientationSensorData(alpha, beta, gamma); + EXPECT_TRUE(absolute_orientation_sensor_); + absolute_orientation_sensor_->SetReading( + absolute_orientation_sensor_reading_); +} + +bool FakeSensorProvider::CreateSharedBufferIfNeeded() { + if (shared_buffer_mapping_.get()) + return true; + + if (!shared_buffer_handle_.is_valid()) { + shared_buffer_handle_ = + mojo::SharedBufferHandle::Create(kSharedBufferSizeInBytes); + if (!shared_buffer_handle_.is_valid()) + return false; + } + + // Create read/write mapping now, to ensure it is kept writable + // after the region is sealed read-only on Android. + shared_buffer_mapping_ = shared_buffer_handle_->Map(kSharedBufferSizeInBytes); + return shared_buffer_mapping_.get() != nullptr; +} + +SensorReadingSharedBuffer* +FakeSensorProvider::GetSensorReadingSharedBufferForType( + mojom::SensorType type) { + auto* ptr = static_cast<char*>(shared_buffer_mapping_.get()); + if (!ptr) + return nullptr; + + ptr += SensorReadingSharedBuffer::GetOffset(type); + memset(ptr, 0, kReadingBufferSize); + return reinterpret_cast<SensorReadingSharedBuffer*>(ptr); +} + +} // namespace device
diff --git a/services/device/public/cpp/test/fake_sensor_and_provider.h b/services/device/public/cpp/test/fake_sensor_and_provider.h new file mode 100644 index 0000000..c973056 --- /dev/null +++ b/services/device/public/cpp/test/fake_sensor_and_provider.h
@@ -0,0 +1,151 @@ +// Copyright 2018 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 SERVICES_DEVICE_PUBLIC_CPP_TEST_FAKE_SENSOR_AND_PROVIDER_H_ +#define SERVICES_DEVICE_PUBLIC_CPP_TEST_FAKE_SENSOR_AND_PROVIDER_H_ + +#include "base/macros.h" +#include "mojo/public/cpp/bindings/binding.h" +#include "mojo/public/cpp/system/buffer.h" +#include "services/device/public/cpp/generic_sensor/sensor_reading.h" +#include "services/device/public/mojom/sensor.mojom.h" +#include "services/device/public/mojom/sensor_provider.mojom.h" + +namespace device { + +class FakeSensor : public mojom::Sensor { + public: + FakeSensor(mojom::SensorType sensor_type, SensorReadingSharedBuffer* buffer); + ~FakeSensor() override; + + // mojom::Sensor: + void AddConfiguration(const PlatformSensorConfiguration& configuration, + AddConfigurationCallback callback) override; + void GetDefaultConfiguration( + GetDefaultConfigurationCallback callback) override; + void RemoveConfiguration( + const PlatformSensorConfiguration& configuration) override; + void Suspend() override; + void Resume() override; + void ConfigureReadingChangeNotifications(bool enabled) override; + + PlatformSensorConfiguration GetDefaultConfiguration(); + mojom::ReportingMode GetReportingMode(); + double GetMaximumSupportedFrequency(); + double GetMinimumSupportedFrequency(); + mojom::SensorClientRequest GetClient(); + mojo::ScopedSharedBufferHandle GetSharedBufferHandle(); + uint64_t GetBufferOffset(); + void SetReading(SensorReading reading); + + private: + void SensorReadingChanged(); + + mojom::SensorType sensor_type_; + SensorReadingSharedBuffer* buffer_; + bool reading_notification_enabled_ = true; + mojom::SensorClientPtr client_; + SensorReading reading_; + + DISALLOW_COPY_AND_ASSIGN(FakeSensor); +}; + +class FakeSensorProvider : public mojom::SensorProvider { + public: + FakeSensorProvider(); + ~FakeSensorProvider() override; + + // mojom::sensorProvider: + void GetSensor(mojom::SensorType type, GetSensorCallback callback) override; + + void Bind(mojom::SensorProviderRequest request); + + void set_ambient_light_sensor_is_available( + bool ambient_light_sensor_is_available) { + ambient_light_sensor_is_available_ = ambient_light_sensor_is_available; + } + void set_accelerometer_is_available(bool accelerometer_is_available) { + accelerometer_is_available_ = accelerometer_is_available; + } + void set_linear_acceleration_sensor_is_available( + bool linear_acceleration_sensor_is_available) { + linear_acceleration_sensor_is_available_ = + linear_acceleration_sensor_is_available; + } + void set_gyroscope_is_available(bool gyroscope_is_available) { + gyroscope_is_available_ = gyroscope_is_available; + } + void set_relative_orientation_sensor_is_available( + bool relative_orientation_sensor_is_available) { + relative_orientation_sensor_is_available_ = + relative_orientation_sensor_is_available; + } + void set_absolute_orientation_sensor_is_available( + bool absolute_orientation_sensor_is_available) { + absolute_orientation_sensor_is_available_ = + absolute_orientation_sensor_is_available; + } + + void SetAmbientLightSensorData(double value); + void SetAccelerometerData(double x, double y, double z); + void SetLinearAccelerationSensorData(double x, double y, double z); + void SetGyroscopeData(double x, double y, double z); + void SetRelativeOrientationSensorData(double alpha, + double beta, + double gamma); + void SetAbsoluteOrientationSensorData(double alpha, + double beta, + double gamma); + + // The Update* functions here write the sensor data to the shared memory and + // notify sensor's client that the sensor data has changed. The Set* + // functions above only set |*_reading_| member variable for corresponding + // sensor which will be the value when the sensor is first created. + void UpdateAmbientLightSensorData(double value); + void UpdateAccelerometerData(double x, double y, double z); + void UpdateLinearAccelerationSensorData(double x, double y, double z); + void UpdateGyroscopeData(double x, double y, double z); + void UpdateRelativeOrientationSensorData(double alpha, + double beta, + double gamma); + void UpdateAbsoluteOrientationSensorData(double alpha, + double beta, + double gamma); + + private: + bool CreateSharedBufferIfNeeded(); + SensorReadingSharedBuffer* GetSensorReadingSharedBufferForType( + mojom::SensorType type); + + // The following sensor pointers are owned by the caller of + // FakeSensorProvider::GetSensor(). + FakeSensor* ambient_light_sensor_ = nullptr; + FakeSensor* accelerometer_ = nullptr; + FakeSensor* linear_acceleration_sensor_ = nullptr; + FakeSensor* gyroscope_ = nullptr; + FakeSensor* relative_orientation_sensor_ = nullptr; + FakeSensor* absolute_orientation_sensor_ = nullptr; + + SensorReading ambient_light_sensor_reading_; + SensorReading accelerometer_reading_; + SensorReading linear_acceleration_sensor_reading_; + SensorReading gyroscope_reading_; + SensorReading relative_orientation_sensor_reading_; + SensorReading absolute_orientation_sensor_reading_; + bool ambient_light_sensor_is_available_ = true; + bool accelerometer_is_available_ = true; + bool linear_acceleration_sensor_is_available_ = true; + bool gyroscope_is_available_ = true; + bool relative_orientation_sensor_is_available_ = true; + bool absolute_orientation_sensor_is_available_ = true; + mojo::Binding<mojom::SensorProvider> binding_; + mojo::ScopedSharedBufferHandle shared_buffer_handle_; + mojo::ScopedSharedBufferMapping shared_buffer_mapping_; + + DISALLOW_COPY_AND_ASSIGN(FakeSensorProvider); +}; + +} // namespace device + +#endif // SERVICES_DEVICE_PUBLIC_CPP_TEST_FAKE_SENSOR_AND_PROVIDER_H_
diff --git a/services/network/test/test_url_loader_factory.cc b/services/network/test/test_url_loader_factory.cc index eb6da34..d2582233 100644 --- a/services/network/test/test_url_loader_factory.cc +++ b/services/network/test/test_url_loader_factory.cc
@@ -60,6 +60,10 @@ responses_.clear(); } +void TestURLLoaderFactory::SetInterceptor(const Interceptor& interceptor) { + interceptor_ = interceptor; +} + void TestURLLoaderFactory::CreateLoaderAndStart( mojom::URLLoaderRequest request, int32_t routing_id, @@ -68,6 +72,9 @@ const ResourceRequest& url_request, mojom::URLLoaderClientPtr client, const net::MutableNetworkTrafficAnnotationTag& traffic_annotation) { + if (interceptor_) + interceptor_.Run(url_request); + if (CreateLoaderAndStartInternal(url_request.url, client.get())) return;
diff --git a/services/network/test/test_url_loader_factory.h b/services/network/test/test_url_loader_factory.h index 9a2ff86..1bdd0e4 100644 --- a/services/network/test/test_url_loader_factory.h +++ b/services/network/test/test_url_loader_factory.h
@@ -41,6 +41,9 @@ // Clear all the responses that were previously set. void ClearResponses(); + using Interceptor = base::RepeatingCallback<void(const ResourceRequest&)>; + void SetInterceptor(const Interceptor& interceptor); + // mojom::URLLoaderFactory implementation. void CreateLoaderAndStart(mojom::URLLoaderRequest request, int32_t routing_id, @@ -78,6 +81,8 @@ }; std::vector<Pending> pending_; + Interceptor interceptor_; + DISALLOW_COPY_AND_ASSIGN(TestURLLoaderFactory); };
diff --git a/services/viz/privileged/interfaces/compositing/frame_sink_manager.mojom b/services/viz/privileged/interfaces/compositing/frame_sink_manager.mojom index 028f5528..c8243af 100644 --- a/services/viz/privileged/interfaces/compositing/frame_sink_manager.mojom +++ b/services/viz/privileged/interfaces/compositing/frame_sink_manager.mojom
@@ -129,10 +129,10 @@ // Marks the given SurfaceIds for destruction. EvictSurfaces(array<SurfaceId> surface_ids); - // Takes a snapshot of |frame_sink_id|. Next time a display frame is - // generated, the snapshot will be taken from the Surface belonging to - // |frame_sink_id| that is reachable from the root Surface. - RequestCopyOfOutput(FrameSinkId frame_sink_id, CopyOutputRequest request); + // Takes a snapshot of |surface_id| or a newer surface with the same + // FrameSinkId. The request will be queued up until such surface exists and is + // reachable from the root surface. + RequestCopyOfOutput(SurfaceId surface_id, CopyOutputRequest request); }; // The FrameSinkManagerClient interface is implemented by the Display
diff --git a/storage/browser/blob/blob_storage_context.h b/storage/browser/blob/blob_storage_context.h index e79e609..86a4556 100644 --- a/storage/browser/blob/blob_storage_context.h +++ b/storage/browser/blob/blob_storage_context.h
@@ -164,6 +164,7 @@ friend class BlobDataHandle::BlobDataHandleShared; friend class BlobRegistryImplTest; friend class BlobStorageContextTest; + friend class BlobURLTokenImpl; enum class TransportQuotaType { MEMORY, FILE };
diff --git a/storage/browser/blob/blob_storage_registry.cc b/storage/browser/blob/blob_storage_registry.cc index eed1d96..0ad1ecc 100644 --- a/storage/browser/blob/blob_storage_registry.cc +++ b/storage/browser/blob/blob_storage_registry.cc
@@ -92,4 +92,28 @@ return entry; } +void BlobStorageRegistry::AddTokenMapping(const base::UnguessableToken& token, + const GURL& url, + const std::string& uuid) { + DCHECK(token_to_url_and_uuid_.find(token) == token_to_url_and_uuid_.end()); + token_to_url_and_uuid_.emplace(token, std::make_pair(url, uuid)); +} + +void BlobStorageRegistry::RemoveTokenMapping( + const base::UnguessableToken& token) { + DCHECK(token_to_url_and_uuid_.find(token) != token_to_url_and_uuid_.end()); + token_to_url_and_uuid_.erase(token); +} + +bool BlobStorageRegistry::GetTokenMapping(const base::UnguessableToken& token, + GURL* url, + std::string* uuid) const { + auto it = token_to_url_and_uuid_.find(token); + if (it == token_to_url_and_uuid_.end()) + return false; + *url = it->second.first; + *uuid = it->second.second; + return true; +} + } // namespace storage
diff --git a/storage/browser/blob/blob_storage_registry.h b/storage/browser/blob/blob_storage_registry.h index 26d391fb..f1cadc1 100644 --- a/storage/browser/blob/blob_storage_registry.h +++ b/storage/browser/blob/blob_storage_registry.h
@@ -15,6 +15,7 @@ #include "base/callback_forward.h" #include "base/macros.h" +#include "base/unguessable_token.h" #include "storage/browser/storage_browser_export.h" #include "storage/common/blob_storage/blob_storage_constants.h" @@ -68,11 +69,21 @@ size_t blob_count() const { return blob_map_.size(); } size_t url_count() const { return url_to_uuid_.size(); } + void AddTokenMapping(const base::UnguessableToken& token, + const GURL& url, + const std::string& uuid); + void RemoveTokenMapping(const base::UnguessableToken& token); + bool GetTokenMapping(const base::UnguessableToken& token, + GURL* url, + std::string* uuid) const; + private: friend class ViewBlobInternalsJob; std::unordered_map<std::string, std::unique_ptr<BlobEntry>> blob_map_; std::map<GURL, std::string> url_to_uuid_; + std::map<base::UnguessableToken, std::pair<GURL, std::string>> + token_to_url_and_uuid_; DISALLOW_COPY_AND_ASSIGN(BlobStorageRegistry); };
diff --git a/storage/browser/blob/blob_url_loader_factory.cc b/storage/browser/blob/blob_url_loader_factory.cc index 0a7a407..76373fe 100644 --- a/storage/browser/blob/blob_url_loader_factory.cc +++ b/storage/browser/blob/blob_url_loader_factory.cc
@@ -4,11 +4,33 @@ #include "storage/browser/blob/blob_url_loader_factory.h" +#include "mojo/public/cpp/bindings/callback_helpers.h" #include "storage/browser/blob/blob_data_handle.h" +#include "storage/browser/blob/blob_storage_context.h" #include "storage/browser/blob/blob_url_loader.h" namespace storage { +namespace { + +// The BlobURLTokenPtr parameter is passed in to make sure the connection stays +// alive until this method is called, it is not otherwise used by this method. +void CreateFactoryForToken(blink::mojom::BlobURLTokenPtr, + const base::WeakPtr<BlobStorageContext>& context, + network::mojom::URLLoaderFactoryRequest request, + const base::UnguessableToken& token) { + std::unique_ptr<BlobDataHandle> handle; + GURL blob_url; + if (context) { + std::string uuid; + if (context->registry().GetTokenMapping(token, &blob_url, &uuid)) + handle = context->GetBlobDataFromUUID(uuid); + } + BlobURLLoaderFactory::Create(std::move(handle), blob_url, std::move(request)); +} + +} // namespace + // static void BlobURLLoaderFactory::Create( std::unique_ptr<BlobDataHandle> handle, @@ -17,6 +39,22 @@ new BlobURLLoaderFactory(std::move(handle), blob_url, std::move(request)); } +// static +void BlobURLLoaderFactory::Create( + blink::mojom::BlobURLTokenPtr token, + base::WeakPtr<BlobStorageContext> context, + network::mojom::URLLoaderFactoryRequest request) { + // Not every URLLoaderFactory user deals with the URLLoaderFactory simply + // disconnecting very well, so make sure we always at least bind the request + // to some factory that can then fail with a network error. Hence the callback + // is wrapped in WrapCallbackWithDefaultInvokeIfNotRun. + auto* raw_token = token.get(); + raw_token->GetToken(mojo::WrapCallbackWithDefaultInvokeIfNotRun( + base::BindOnce(&CreateFactoryForToken, std::move(token), + std::move(context), std::move(request)), + base::UnguessableToken())); +} + void BlobURLLoaderFactory::CreateLoaderAndStart( network::mojom::URLLoaderRequest loader, int32_t routing_id, @@ -25,8 +63,10 @@ const network::ResourceRequest& request, network::mojom::URLLoaderClientPtr client, const net::MutableNetworkTrafficAnnotationTag& traffic_annotation) { - if (request.url != url_) { + if (url_.is_valid() && request.url != url_) { bindings_.ReportBadMessage("Invalid URL when attempting to fetch Blob"); + client->OnComplete( + network::URLLoaderCompletionStatus(net::ERR_INVALID_URL)); return; } DCHECK(!request.download_to_file);
diff --git a/storage/browser/blob/blob_url_loader_factory.h b/storage/browser/blob/blob_url_loader_factory.h index 888fc74..4c8a34e 100644 --- a/storage/browser/blob/blob_url_loader_factory.h +++ b/storage/browser/blob/blob_url_loader_factory.h
@@ -8,10 +8,12 @@ #include "mojo/public/cpp/bindings/binding_set.h" #include "services/network/public/mojom/url_loader_factory.mojom.h" #include "storage/browser/storage_browser_export.h" +#include "third_party/WebKit/public/mojom/blob/blob_url_store.mojom.h" namespace storage { class BlobDataHandle; +class BlobStorageContext; // URLLoaderFactory that can create loaders for exactly one url, loading the // blob that was passed to its constructor. This factory keeps the blob alive. @@ -23,6 +25,13 @@ const GURL& blob_url, network::mojom::URLLoaderFactoryRequest request); + // Creates a factory for a BlobURLToken. The token is used to look up the blob + // and blob URL in the (browser side) BlobStorageRegistry, to ensure you can't + // use a blob URL to load the contents of an unrelated blob. + static void Create(blink::mojom::BlobURLTokenPtr token, + base::WeakPtr<BlobStorageContext> context, + network::mojom::URLLoaderFactoryRequest request); + // URLLoaderFactory: void CreateLoaderAndStart(network::mojom::URLLoaderRequest loader, int32_t routing_id,
diff --git a/storage/browser/blob/blob_url_store_impl.cc b/storage/browser/blob/blob_url_store_impl.cc index f2775abb..2a485dd 100644 --- a/storage/browser/blob/blob_url_store_impl.cc +++ b/storage/browser/blob/blob_url_store_impl.cc
@@ -4,6 +4,7 @@ #include "storage/browser/blob/blob_url_store_impl.h" +#include "mojo/public/cpp/bindings/strong_binding.h" #include "storage/browser/blob/blob_impl.h" #include "storage/browser/blob/blob_storage_context.h" #include "storage/browser/blob/blob_url_loader_factory.h" @@ -11,6 +12,53 @@ namespace storage { +// Self deletes when the last binding to it is closed. +class BlobURLTokenImpl : public blink::mojom::BlobURLToken { + public: + BlobURLTokenImpl(base::WeakPtr<BlobStorageContext> context, + const GURL& url, + std::unique_ptr<BlobDataHandle> blob, + blink::mojom::BlobURLTokenRequest request) + : context_(std::move(context)), + url_(url), + blob_(std::move(blob)), + token_(base::UnguessableToken::Create()) { + bindings_.AddBinding(this, std::move(request)); + bindings_.set_connection_error_handler(base::BindRepeating( + &BlobURLTokenImpl::OnConnectionError, base::Unretained(this))); + if (context_) { + context_->mutable_registry()->AddTokenMapping(token_, url_, + blob_->uuid()); + } + } + + ~BlobURLTokenImpl() override { + if (context_) + context_->mutable_registry()->RemoveTokenMapping(token_); + } + + void GetToken(GetTokenCallback callback) override { + std::move(callback).Run(token_); + } + + void Clone(blink::mojom::BlobURLTokenRequest request) override { + bindings_.AddBinding(this, std::move(request)); + } + + private: + void OnConnectionError() { + if (!bindings_.empty()) + return; + delete this; + } + + base::WeakPtr<BlobStorageContext> context_; + mojo::BindingSet<blink::mojom::BlobURLToken> bindings_; + const GURL url_; + const std::unique_ptr<BlobDataHandle> blob_; + const base::UnguessableToken token_; +}; + BlobURLStoreImpl::BlobURLStoreImpl(base::WeakPtr<BlobStorageContext> context, BlobRegistryImpl::Delegate* delegate) : context_(std::move(context)), @@ -72,6 +120,18 @@ std::move(request)); } +void BlobURLStoreImpl::ResolveForNavigation( + const GURL& url, + blink::mojom::BlobURLTokenRequest token) { + if (!context_) + return; + std::unique_ptr<BlobDataHandle> blob_handle = + context_->GetBlobDataFromPublicURL(url); + if (!blob_handle) + return; + new BlobURLTokenImpl(context_, url, std::move(blob_handle), std::move(token)); +} + void BlobURLStoreImpl::RegisterWithUUID(blink::mojom::BlobPtr blob, const GURL& url, RegisterCallback callback,
diff --git a/storage/browser/blob/blob_url_store_impl.h b/storage/browser/blob/blob_url_store_impl.h index ea92402..985454c 100644 --- a/storage/browser/blob/blob_url_store_impl.h +++ b/storage/browser/blob/blob_url_store_impl.h
@@ -28,6 +28,8 @@ void ResolveAsURLLoaderFactory( const GURL& url, network::mojom::URLLoaderFactoryRequest request) override; + void ResolveForNavigation(const GURL& url, + blink::mojom::BlobURLTokenRequest token) override; private: void RegisterWithUUID(blink::mojom::BlobPtr blob,
diff --git a/testing/buildbot/chromium.fyi.json b/testing/buildbot/chromium.fyi.json index 6eabfc3e..a430dfe 100644 --- a/testing/buildbot/chromium.fyi.json +++ b/testing/buildbot/chromium.fyi.json
@@ -8551,12 +8551,6 @@ "swarming": { "can_use_on_swarming_builders": false }, - "test": "mini_installer_tests" - }, - { - "swarming": { - "can_use_on_swarming_builders": false - }, "test": "native_theme_unittests" }, {
diff --git a/testing/buildbot/chromium.linux.json b/testing/buildbot/chromium.linux.json index 8d48510..2aebec28 100644 --- a/testing/buildbot/chromium.linux.json +++ b/testing/buildbot/chromium.linux.json
@@ -606,6 +606,11 @@ "sync_integration_tests" ] }, + "Linux Builder Jumbo": { + "additional_compile_targets": [ + "all" + ] + }, "Linux Tests": { "gtest_tests": [ {
diff --git a/testing/buildbot/chromium.win.json b/testing/buildbot/chromium.win.json index 5903956e..566df5c 100644 --- a/testing/buildbot/chromium.win.json +++ b/testing/buildbot/chromium.win.json
@@ -1126,6 +1126,16 @@ }, "test": "wtf_unittests" } + ], + "isolated_scripts": [ + { + "experiment_percentage": 10, + "isolate_name": "mini_installer_tests", + "name": "mini_installer_tests", + "swarming": { + "can_use_on_swarming_builders": true + } + } ] }, "Win10 Tests x64 (dbg)": {
diff --git a/testing/buildbot/filters/viz.browser_tests.filter b/testing/buildbot/filters/viz.browser_tests.filter index 29337de..98cacf3 100644 --- a/testing/buildbot/filters/viz.browser_tests.filter +++ b/testing/buildbot/filters/viz.browser_tests.filter
@@ -93,7 +93,10 @@ -ThumbnailTest.ShouldContainProperContentIfCapturedOnTabSwitch # Windows timeouts. https://crbug.com/821029 +-BrowserNavigatorTest.Disposition_NewPopupFromAppPopup +-ExtensionApiCaptureTest.CaptureNullWindow -ManifestVerifierBrowserTest.* +-OmniboxPopupContentsViewTest.ThemeIntegration/* -PDFIsolatedExtensionTest.MultipleDomains -PrefHashBrowserTest* -UserInitiatedRunsDisabled*
diff --git a/testing/buildbot/filters/viz.content_browsertests.filter b/testing/buildbot/filters/viz.content_browsertests.filter index b1f1132..a14eddf5f 100644 --- a/testing/buildbot/filters/viz.content_browsertests.filter +++ b/testing/buildbot/filters/viz.content_browsertests.filter
@@ -66,11 +66,6 @@ -SitePerProcessBrowserTest.HiddenOOPIFWillNotGenerateCompositorFramesAfterNavigation -SitePerProcessBrowserTest.SubframeVisibleAfterRenderViewBecomesSwappedOut -# Touch selection information is not provided to the browser -# http://crbug.com/777882 --TouchSelectionControllerClientAuraScaleFactorTest.* --TouchSelectionControllerClientAuraTest.* - #### Tab Capture # Copy Surface timing out http://crbug.com/785257 -GLAndSoftwareCompositing/CompositingRenderWidgetHostViewBrowserTest.CopyFromSurface*
diff --git a/testing/buildbot/test_suites.pyl b/testing/buildbot/test_suites.pyl index 1671b374..2a0a61d 100644 --- a/testing/buildbot/test_suites.pyl +++ b/testing/buildbot/test_suites.pyl
@@ -1296,10 +1296,6 @@ 'sandbox_mac_unittests': {}, }, - 'mini_installer_tests_isolated_tests': { - 'mini_installer_tests': {}, - }, - 'mojo_chromiumos_specific_gtests': { 'wayland_client_perftests': {}, }, @@ -1816,6 +1812,12 @@ 'zucchini_unittests': {}, }, + 'win_specific_isolated_scripts': { + 'mini_installer_tests': { + 'experiment_percentage': 10, + }, + }, + 'win7_32_bit_gtests': { 'base_unittests': {}, 'battor_agent_unittests': {}, @@ -2238,7 +2240,6 @@ 'chromium_gtests', 'chromium_gtests_for_devices_with_graphical_output', 'interactive_ui_tests_gtests', - 'mini_installer_tests_isolated_tests', 'non_android_chromium_gtests', 'non_android_and_cast_chromium_gtests', 'non_android_and_cast_and_chromeos_chromium_gtests',
diff --git a/testing/buildbot/waterfalls.pyl b/testing/buildbot/waterfalls.pyl index fd025a8..2313f8d8 100644 --- a/testing/buildbot/waterfalls.pyl +++ b/testing/buildbot/waterfalls.pyl
@@ -1435,6 +1435,11 @@ 'scripts': 'check_network_annotations_script', } }, + 'Linux Builder Jumbo': { + 'additional_compile_targets': [ + 'all' + ] + }, 'Linux Builder (dbg)': { 'additional_compile_targets': [ 'all' @@ -2066,6 +2071,7 @@ 'Win10 Tests x64': { 'test_suites': { 'gtest_tests': 'chromium_win_gtests', + 'isolated_scripts': 'win_specific_isolated_scripts', }, }, 'Win7 (32) Tests': {
diff --git a/third_party/WebKit/LayoutTests/FlagExpectations/enable-blink-features=LayoutNG b/third_party/WebKit/LayoutTests/FlagExpectations/enable-blink-features=LayoutNG index 9cd148ad..29f45e0f 100644 --- a/third_party/WebKit/LayoutTests/FlagExpectations/enable-blink-features=LayoutNG +++ b/third_party/WebKit/LayoutTests/FlagExpectations/enable-blink-features=LayoutNG
@@ -223,9 +223,7 @@ crbug.com/591099 editing/pasteboard/copy-paste-white-space.html [ Failure ] crbug.com/591099 editing/pasteboard/drag-image-to-contenteditable-in-iframe.html [ Failure ] crbug.com/591099 editing/pasteboard/drag-list-item.html [ Failure ] -crbug.com/591099 editing/pasteboard/drag-selected-image-to-contenteditable.html [ Failure ] crbug.com/591099 editing/pasteboard/innerText-inline-table.html [ Failure ] -crbug.com/591099 editing/pasteboard/input-field-1.html [ Failure ] crbug.com/591099 editing/pasteboard/merge-start-blockquote.html [ Failure ] crbug.com/591099 editing/pasteboard/merge-start-list.html [ Failure ] crbug.com/591099 editing/pasteboard/paste-noscript.html [ Failure ] @@ -238,7 +236,6 @@ crbug.com/591099 editing/selection/caret-at-bidi-boundary.html [ Failure ] crbug.com/591099 editing/selection/continuations-with-move-caret-to-boundary.html [ Failure ] crbug.com/591099 editing/selection/continuations-without-move-caret-to-boundary.html [ Failure ] -crbug.com/805301 editing/selection/designmode-no-caret.html [ Failure ] crbug.com/591099 editing/selection/dont-select-text-overflow-ellipsis-when-wrapping-ltr-mixed.html [ Failure ] crbug.com/591099 editing/selection/dont-select-text-overflow-ellipsis-when-wrapping-rtl-mixed.html [ Failure ] crbug.com/591099 editing/selection/dont-select-text-overflow-ellipsis-when-wrapping-rtl.html [ Failure ] @@ -507,7 +504,6 @@ crbug.com/591099 external/wpt/css/css-text/line-breaking/line-breaking-ic-002.html [ Pass ] crbug.com/591099 external/wpt/css/css-text/line-breaking/line-breaking-ic-003.html [ Pass ] crbug.com/591099 external/wpt/css/css-text/white-space/pre-wrap-002.html [ Pass ] -crbug.com/591099 external/wpt/css/css-text/white-space/pre-wrap-011.html [ Failure ] crbug.com/591099 external/wpt/css/css-text/white-space/seg-break-transformation-001.html [ Failure ] crbug.com/591099 external/wpt/css/css-text/white-space/seg-break-transformation-002.html [ Failure ] crbug.com/591099 external/wpt/css/css-text/white-space/seg-break-transformation-003.html [ Failure ] @@ -1012,21 +1008,11 @@ crbug.com/591099 fast/clip/overflow-border-radius-composited-parent.html [ Failure ] crbug.com/591099 fast/clip/overflow-border-radius-composited.html [ Failure ] crbug.com/591099 fast/clip/overflow-border-radius-transformed.html [ Failure ] -crbug.com/591099 fast/css-generated-content/009.html [ Failure ] -crbug.com/591099 fast/css-generated-content/012.html [ Failure ] crbug.com/591099 fast/css-generated-content/015.html [ Failure ] crbug.com/805301 fast/css-generated-content/crash-selection-editing-removes-pseudo.html [ Failure ] crbug.com/591099 fast/css-generated-content/first-letter-next-sibling-crash.html [ Crash ] crbug.com/591099 fast/css-generated-content/float-first-letter-siblings-convert-to-inline.html [ Crash ] crbug.com/714962 fast/css-generated-content/hover-inline.html [ Failure ] -crbug.com/591099 fast/css-generated-content/table-before-after-child-add.html [ Failure ] -crbug.com/591099 fast/css-generated-content/table-cell-before-after-child-add.html [ Failure ] -crbug.com/591099 fast/css-generated-content/table-row-before-after-child-add.html [ Failure ] -crbug.com/591099 fast/css-generated-content/table-row-group-to-inline.html [ Failure ] -crbug.com/591099 fast/css-generated-content/table-row-group-with-before.html [ Failure ] -crbug.com/591099 fast/css-generated-content/table-row-with-before.html [ Failure ] -crbug.com/591099 fast/css-generated-content/table-table-before-after-child-add.html [ Failure ] -crbug.com/591099 fast/css-generated-content/table-with-before.html [ Failure ] crbug.com/591099 fast/css-grid-layout/auto-content-resolution-columns.html [ Failure ] crbug.com/591099 fast/css-grid-layout/breadth-size-resolution-grid.html [ Failure ] crbug.com/591099 fast/css-grid-layout/calc-resolution-grid-item.html [ Failure ] @@ -1285,7 +1271,6 @@ crbug.com/591099 fast/forms/selection-direction.html [ Timeout ] crbug.com/591099 fast/forms/suggestion-picker/date-suggestion-picker-appearance-zoom125.html [ Failure ] crbug.com/591099 fast/forms/suggestion-picker/date-suggestion-picker-appearance-zoom200.html [ Failure ] -crbug.com/591099 fast/forms/suggestion-picker/datetimelocal-suggestion-picker-appearance.html [ Failure ] crbug.com/591099 fast/forms/text-control-intrinsic-widths.html [ Timeout ] crbug.com/591099 fast/forms/text/input-appearance-preventDefault.html [ Failure ] crbug.com/591099 fast/forms/text/text-appearance-datalist.html [ Failure ] @@ -1662,7 +1647,6 @@ crbug.com/591099 fast/text/whitespace/inline-whitespace-wrapping-4.html [ Failure ] crbug.com/591099 fast/text/whitespace/inline-whitespace-wrapping-5.html [ Failure ] crbug.com/591099 fast/text/whitespace/normal-after-nowrap-breaking.html [ Failure ] -crbug.com/591099 fast/text/whitespace/pre-wrap-spaces-after-newline.html [ Failure ] crbug.com/591099 fast/text/zero-width-characters-complex-script.html [ Failure ] crbug.com/591099 fast/text/zero-width-characters.html [ Failure ] crbug.com/591099 fast/writing-mode/Kusa-Makura-background-canvas.html [ Failure ] @@ -2208,7 +2192,6 @@ crbug.com/591099 tables/mozilla/bugs/bug101674.html [ Failure ] crbug.com/591099 tables/mozilla/bugs/bug110566.html [ Failure ] crbug.com/591099 tables/mozilla/bugs/bug12008.html [ Failure ] -crbug.com/591099 tables/mozilla/bugs/bug126742.html [ Failure ] crbug.com/591099 tables/mozilla/bugs/bug1271.html [ Failure ] crbug.com/591099 tables/mozilla/bugs/bug131020-2.html [ Failure ] crbug.com/591099 tables/mozilla/bugs/bug131020.html [ Failure ]
diff --git a/third_party/WebKit/LayoutTests/TestExpectations b/third_party/WebKit/LayoutTests/TestExpectations index 9f24880..02f18c7 100644 --- a/third_party/WebKit/LayoutTests/TestExpectations +++ b/third_party/WebKit/LayoutTests/TestExpectations
@@ -896,7 +896,6 @@ crbug.com/666657 external/wpt/css/css-text-decor/text-emphasis-position-below-left-002.xht [ Failure ] crbug.com/666657 external/wpt/css/css-text-decor/text-emphasis-position-below-right-001.xht [ Failure ] crbug.com/666657 external/wpt/css/css-text-decor/text-emphasis-position-below-right-002.xht [ Failure ] -crbug.com/666657 external/wpt/css/css-text-decor/text-emphasis-style-001.html [ Failure ] crbug.com/666657 external/wpt/css/css-text-decor/text-emphasis-style-002.html [ Failure ] crbug.com/666657 external/wpt/css/css-text-decor/text-emphasis-style-006.html [ Failure ] crbug.com/666657 external/wpt/css/css-text-decor/text-emphasis-style-007.html [ Failure ] @@ -1631,10 +1630,6 @@ crbug.com/805463 external/wpt/acid/acid3/numbered-tests.html [ Skip ] -# These tests have unstable error messages, so they can't be rebaselined. -crbug.com/626703 external/wpt/html/semantics/document-metadata/the-link-element/link-load-error-events.html [ Failure ] -crbug.com/626703 external/wpt/html/semantics/document-metadata/the-link-element/link-load-error-events.https.html [ Failure ] - # ====== New tests from wpt-importer added here ====== crbug.com/626703 external/wpt/html/editing/dnd/the-datatransfer-interface/DataTransfer-types-manual.html [ Skip ] crbug.com/626703 external/wpt/webvr/idlharness.https.html [ Timeout ]
diff --git a/third_party/WebKit/LayoutTests/editing/deleting/merge-whitespace-pre.html b/third_party/WebKit/LayoutTests/editing/deleting/merge-whitespace-pre.html index 6c828aa..da2fc3fc 100644 --- a/third_party/WebKit/LayoutTests/editing/deleting/merge-whitespace-pre.html +++ b/third_party/WebKit/LayoutTests/editing/deleting/merge-whitespace-pre.html
@@ -1,13 +1,21 @@ -<p>This test places the caret before the 'b' in 'bar' and Delete. Afterword, 'foobar' should be in the first paragraph and 'baz' should be in the second.</p> -<div contenteditable="true"> -<div>foo</div> -<pre id="test">bar -baz</pre> -</div> - +<!doctype HTML> +<script src="../../resources/testharness.js"></script> +<script src="../../resources/testharnessreport.js"></script> +<script src="../assert_selection.js"></script> <script> -var s = window.getSelection(); -var e = document.getElementById("test"); -s.collapse(e, 0); -document.execCommand("Delete"); +selection_test( + [ + '<div contenteditable>', + '<div>foo</div>', + '<pre>|bar\nbaz</pre>', + '</div>', + ], + 'Delete', + [ + '<div contenteditable>', + '<div>foo|bar</div>', + '<pre>baz</pre>', + '</div>', + ], + 'Delete to merge whitespaces'); </script>
diff --git a/third_party/WebKit/LayoutTests/editing/execCommand/align-in-span-expected.txt b/third_party/WebKit/LayoutTests/editing/execCommand/align-in-span-expected.txt deleted file mode 100644 index 4d8e8060..0000000 --- a/third_party/WebKit/LayoutTests/editing/execCommand/align-in-span-expected.txt +++ /dev/null
@@ -1,4 +0,0 @@ -Line 1. -Select all text in this line and use justify command. -Line 3. -
diff --git a/third_party/WebKit/LayoutTests/editing/execCommand/align-in-span.html b/third_party/WebKit/LayoutTests/editing/execCommand/align-in-span.html index 9b55dcf..b20a3e2 100644 --- a/third_party/WebKit/LayoutTests/editing/execCommand/align-in-span.html +++ b/third_party/WebKit/LayoutTests/editing/execCommand/align-in-span.html
@@ -1,31 +1,23 @@ -<html> -<head> -<script type="text/javascript"> - -function selectAndJustify() -{ - if (window.testRunner) - testRunner.dumpAsText(); - - var elem = document.getElementById("test"); - var selection = window.getSelection(); - selection.setBaseAndExtent(elem, 2, elem, 6); - document.execCommand('JustifyCenter', false, null); -} - -</script> -</head> - -<body> - <span id="test" contenteditable="true" > - Line 1. - <br> - <b>Select all text in this line and use justify command.</b> - <br> - Line 3. - </span> -</body> +<!doctype HTML> +<script src="../../resources/testharness.js"></script> +<script src="../../resources/testharnessreport.js"></script> +<script src="../assert_selection.js"></script> <script> -selectAndJustify(); +selection_test( + [ + '<span contenteditable>', + 'ab<br>', + '^<b>CD</b><br>|', + 'de', + '</span>' + ], + 'justifyCenter', + [ + '<span contenteditable>', + 'ab<br>', + '<div style="text-align: center;"><b>^CD</b></div>', + '<div style="text-align: center;">|de</div>', + '</span>', + ], + 'justifyCenter in SPAN'); </script> -</html>
diff --git a/third_party/WebKit/LayoutTests/editing/inserting/4875189-1.html b/third_party/WebKit/LayoutTests/editing/inserting/4875189-1.html index 19532c5..07bd8c7 100644 --- a/third_party/WebKit/LayoutTests/editing/inserting/4875189-1.html +++ b/third_party/WebKit/LayoutTests/editing/inserting/4875189-1.html
@@ -1,12 +1,11 @@ -<p>This tests for a bug when replacing the contents of a list. The list shouldn't be removed, just its contents.</p> -<div contenteditable="true"><ul><li id="li">You shouldn't see this.</li></ul></div> - +<!doctype HTML> +<script src="../../resources/testharness.js"></script> +<script src="../../resources/testharnessreport.js"></script> +<script src="../assert_selection.js"></script> <script> -var r = document.createRange(); -var li = document.getElementById("li"); -r.setStart(li, 0); -r.setEnd(li, li.childNodes.length); -var selection = window.getSelection(); -selection.addRange(r); -document.execCommand("InsertHTML", false, "This should be in a list item.") +selection_test( + '<div contenteditable><ul><li>^ab|</li></ul></div>', + 'insertHTML CD', + '<div contenteditable><ul><li>CD|</li></ul></div>', + 'InsertHTML to replace content of list item'); </script>
diff --git a/third_party/WebKit/LayoutTests/editing/inserting/4959067.html b/third_party/WebKit/LayoutTests/editing/inserting/4959067.html index 498cfd9..61ac3a7 100644 --- a/third_party/WebKit/LayoutTests/editing/inserting/4959067.html +++ b/third_party/WebKit/LayoutTests/editing/inserting/4959067.html
@@ -1,22 +1,26 @@ -<p>This tests to make sure that insertion over a fully selected special element doesn't do expansion.</p> -<div contenteditable="true"> -<ul id="ul"><li><a id="anchor" href="http://www.google.com/">foo</a></li></ul> -</div> -<ul id="console"></ul> +<!doctype HTML> +<script src="../../resources/testharness.js"></script> +<script src="../../resources/testharnessreport.js"></script> +<script src="../assert_selection.js"></script> <script> -function log(str) { - var li = document.createElement("li"); - var text = document.createTextNode(str); - var console = document.getElementById("console"); - li.appendChild(text); - console.appendChild(li); -} - -var sel = window.getSelection(); -var anchor = document.getElementById("anchor"); -sel.setBaseAndExtent(anchor, 0, anchor, anchor.childNodes.length); -document.execCommand("InsertText", false, "foo"); -anchor = document.getElementById("anchor"); -if (!anchor) - log("Failure: a special element was removed during insertion."); +// This tests to make sure that insertion over a fully selected special element +// doesn't do expansion. +selection_test( + [ + '<div contenteditable>', + '<ul><li><a href="http://www.google.com/" id="anchor">^ab|</a></li></ul>', + '</div>', + ], + selection => { + const anchor = selection.document.getElementById('anchor'); + selection.document.execCommand('insertText', false, 'CD'); + assert_equals(anchor, selection.document.getElementById('anchor'), + 'We should keep an A element'); + }, + [ + '<div contenteditable>', + '<ul><li><a href="http://www.google.com/" id="anchor">CD|</a></li></ul>', + '</div>', + ], + 'insertText to replace contents of A'); </script>
diff --git a/third_party/WebKit/LayoutTests/editing/inserting/editable-inline-element.html b/third_party/WebKit/LayoutTests/editing/inserting/editable-inline-element.html index 0d768a0..108ae19 100644 --- a/third_party/WebKit/LayoutTests/editing/inserting/editable-inline-element.html +++ b/third_party/WebKit/LayoutTests/editing/inserting/editable-inline-element.html
@@ -1,10 +1,11 @@ -<p>This tests InsertParagraph inside an editable inline element.</p> -<div style="border: 1px solid red;"><span id="span" contenteditable="true">foo</span></div> - +<!doctype HTML> +<script src="../../resources/testharness.js"></script> +<script src="../../resources/testharnessreport.js"></script> +<script src="../assert_selection.js"></script> <script> -var sel = window.getSelection(); -var span = document.getElementById("span"); - -sel.collapse(span, 0); -document.execCommand("InsertParagraph"); +selection_test( + '<span contenteditable>|foo</span>', + 'insertParagraph', + '<span contenteditable><br>|foo</span>', + 'InsertParagraph in inline element'); </script>
diff --git a/third_party/WebKit/LayoutTests/editing/selection/focus-body.html b/third_party/WebKit/LayoutTests/editing/selection/focus-body.html index 9cc8f99..13dfbda 100644 --- a/third_party/WebKit/LayoutTests/editing/selection/focus-body.html +++ b/third_party/WebKit/LayoutTests/editing/selection/focus-body.html
@@ -1,9 +1,15 @@ +<!doctype HTML> +<script src="../../resources/testharness.js"></script> +<script src="../../resources/testharnessreport.js"></script> +<script src="../assert_selection.js"></script> <script> -if (window.testRunner) - testRunner.dumpEditingCallbacks(); +selection_test( + 'ab', + selection => { + const body = selection.document.body; + body.setAttribute('contenteditable', 'true'); + body.focus(); + }, + '|ab', + 'Focus to editable body should set caret instead of selecting body contents'); </script> -<body contenteditable="true">This test focuses an editable body. Its contents should not be selected. -<script> -document.body.focus(); -</script> -</body>
diff --git a/third_party/WebKit/LayoutTests/external/WPT_BASE_MANIFEST.json b/third_party/WebKit/LayoutTests/external/WPT_BASE_MANIFEST.json index f6e7fea..3c9b1924 100644 --- a/third_party/WebKit/LayoutTests/external/WPT_BASE_MANIFEST.json +++ b/third_party/WebKit/LayoutTests/external/WPT_BASE_MANIFEST.json
@@ -116896,11 +116896,6 @@ {} ] ], - "css/css-fonts/test_font_family_parsing-expected.txt": [ - [ - {} - ] - ], "css/css-fonts/test_font_feature_values_parsing-expected.txt": [ [ {} @@ -125256,6 +125251,11 @@ {} ] ], + "css/css-typed-om/the-stylepropertymap/properties/image-rendering-expected.txt": [ + [ + {} + ] + ], "css/css-typed-om/the-stylepropertymap/properties/line-height-expected.txt": [ [ {} @@ -125291,6 +125291,11 @@ {} ] ], + "css/css-typed-om/the-stylepropertymap/properties/text-combine-upright-expected.txt": [ + [ + {} + ] + ], "css/css-typed-om/the-stylepropertymap/properties/text-decoration-line-expected.txt": [ [ {} @@ -125311,16 +125316,31 @@ {} ] ], + "css/css-typed-om/the-stylepropertymap/properties/text-overflow-expected.txt": [ + [ + {} + ] + ], "css/css-typed-om/the-stylepropertymap/properties/text-transform-expected.txt": [ [ {} ] ], + "css/css-typed-om/the-stylepropertymap/properties/transform-style-expected.txt": [ + [ + {} + ] + ], "css/css-typed-om/the-stylepropertymap/properties/transition-duration-expected.txt": [ [ {} ] ], + "css/css-typed-om/the-stylepropertymap/properties/user-select-expected.txt": [ + [ + {} + ] + ], "css/css-typed-om/the-stylepropertymap/properties/writing-mode-expected.txt": [ [ {} @@ -130291,11 +130311,6 @@ {} ] ], - "css/cssom/variable-names-expected.txt": [ - [ - {} - ] - ], "css/geometry/DOMMatrix2DInit-validate-fixup-expected.txt": [ [ {} @@ -159826,11 +159841,26 @@ {} ] ], + "streams/readable-streams/default-reader-expected.txt": [ + [ + {} + ] + ], + "streams/readable-streams/default-reader.dedicatedworker-expected.txt": [ + [ + {} + ] + ], "streams/readable-streams/default-reader.js": [ [ {} ] ], + "streams/readable-streams/default-reader.serviceworker.https-expected.txt": [ + [ + {} + ] + ], "streams/readable-streams/floating-point-total-queue-size.js": [ [ {} @@ -161311,11 +161341,6 @@ {} ] ], - "web-animations/interfaces/AnimationEffect/getComputedTiming-expected.txt": [ - [ - {} - ] - ], "web-animations/interfaces/AnimationEffect/updateTiming-expected.txt": [ [ {} @@ -161326,11 +161351,6 @@ {} ] ], - "web-animations/interfaces/AnimationPlaybackEvent/constructor-expected.txt": [ - [ - {} - ] - ], "web-animations/interfaces/Document/getAnimations-expected.txt": [ [ {} @@ -161416,11 +161436,6 @@ {} ] ], - "web-animations/timing-model/animation-effects/local-time-expected.txt": [ - [ - {} - ] - ], "web-animations/timing-model/animation-effects/phases-and-states-expected.txt": [ [ {} @@ -184877,6 +184892,12 @@ {} ] ], + "css/css-typed-om/the-stylepropertymap/properties/image-rendering.html": [ + [ + "/css/css-typed-om/the-stylepropertymap/properties/image-rendering.html", + {} + ] + ], "css/css-typed-om/the-stylepropertymap/properties/inline-size.html": [ [ "/css/css-typed-om/the-stylepropertymap/properties/inline-size.html", @@ -185081,6 +185102,18 @@ {} ] ], + "css/css-typed-om/the-stylepropertymap/properties/text-anchor.html": [ + [ + "/css/css-typed-om/the-stylepropertymap/properties/text-anchor.html", + {} + ] + ], + "css/css-typed-om/the-stylepropertymap/properties/text-combine-upright.html": [ + [ + "/css/css-typed-om/the-stylepropertymap/properties/text-combine-upright.html", + {} + ] + ], "css/css-typed-om/the-stylepropertymap/properties/text-decoration-color.html": [ [ "/css/css-typed-om/the-stylepropertymap/properties/text-decoration-color.html", @@ -185135,6 +185168,18 @@ {} ] ], + "css/css-typed-om/the-stylepropertymap/properties/text-overflow.html": [ + [ + "/css/css-typed-om/the-stylepropertymap/properties/text-overflow.html", + {} + ] + ], + "css/css-typed-om/the-stylepropertymap/properties/text-rendering.html": [ + [ + "/css/css-typed-om/the-stylepropertymap/properties/text-rendering.html", + {} + ] + ], "css/css-typed-om/the-stylepropertymap/properties/text-transform.html": [ [ "/css/css-typed-om/the-stylepropertymap/properties/text-transform.html", @@ -185153,6 +185198,12 @@ {} ] ], + "css/css-typed-om/the-stylepropertymap/properties/transform-style.html": [ + [ + "/css/css-typed-om/the-stylepropertymap/properties/transform-style.html", + {} + ] + ], "css/css-typed-om/the-stylepropertymap/properties/transform.html": [ [ "/css/css-typed-om/the-stylepropertymap/properties/transform.html", @@ -185171,6 +185222,12 @@ {} ] ], + "css/css-typed-om/the-stylepropertymap/properties/user-select.html": [ + [ + "/css/css-typed-om/the-stylepropertymap/properties/user-select.html", + {} + ] + ], "css/css-typed-om/the-stylepropertymap/properties/vertical-align.html": [ [ "/css/css-typed-om/the-stylepropertymap/properties/vertical-align.html", @@ -186419,6 +186476,12 @@ {} ] ], + "css/cssom/font-shorthand-serialization.html": [ + [ + "/css/cssom/font-shorthand-serialization.html", + {} + ] + ], "css/cssom/getComputedStyle-dynamic-subdoc.html": [ [ "/css/cssom/getComputedStyle-dynamic-subdoc.html", @@ -252403,7 +252466,7 @@ "testharness" ], "bluetooth/resources/bluetooth-helpers.js": [ - "9d2b233c511627f6a4fe93bdaf16ba28c4a6ead9", + "f19d8ab872de44f50c37aac3e3ad97ab0e502b59", "support" ], "bluetooth/resources/health-thermometer-iframe.html": [ @@ -285950,10 +286013,6 @@ "a793f06cceb92b34dc27728307995774a5d95b63", "testharness" ], - "css/css-fonts/test_font_family_parsing-expected.txt": [ - "e613962d38ffc953f97c095efe97aea3d63eee5e", - "support" - ], "css/css-fonts/test_font_family_parsing.html": [ "0aaa1c1bb9497df1cddbeda60f7d522568dc2f01", "testharness" @@ -306130,6 +306189,14 @@ "617ec941ab1cbd02b31b8a9bb7ce6da311109476", "testharness" ], + "css/css-typed-om/the-stylepropertymap/properties/image-rendering-expected.txt": [ + "2b10e5f9dfdc1cc499d9bea6a7e4c3cb966bbdf8", + "support" + ], + "css/css-typed-om/the-stylepropertymap/properties/image-rendering.html": [ + "6d1fffc1886bf0318487e7b51d48a30a467d55dd", + "testharness" + ], "css/css-typed-om/the-stylepropertymap/properties/inline-size.html": [ "531ad3bba92bfdb60377dc755d40f3300d0843e0", "testharness" @@ -306294,6 +306361,18 @@ "88a1f5866a767c25dec2ef75728c68c5631d371f", "testharness" ], + "css/css-typed-om/the-stylepropertymap/properties/text-anchor.html": [ + "84258638bb77a8d001570dc1751ce80ed8506a54", + "testharness" + ], + "css/css-typed-om/the-stylepropertymap/properties/text-combine-upright-expected.txt": [ + "cdabdc0dd6cfb006a7f97d88f5adf24a3a67b181", + "support" + ], + "css/css-typed-om/the-stylepropertymap/properties/text-combine-upright.html": [ + "a0bc476f703a11611f74af5e1ee813373842b614", + "testharness" + ], "css/css-typed-om/the-stylepropertymap/properties/text-decoration-color.html": [ "fe6d3765ca8fea1c1963a310d0aa35fa68089a9b", "testharness" @@ -306346,6 +306425,18 @@ "919ebc1fadf6e097071a0f1618afeed0849f18e6", "testharness" ], + "css/css-typed-om/the-stylepropertymap/properties/text-overflow-expected.txt": [ + "ecd1db7a12ee95c8ca1a1e5a1aa960af8204036c", + "support" + ], + "css/css-typed-om/the-stylepropertymap/properties/text-overflow.html": [ + "f0aab5cd85a0a63f3c3d2ac2cbd8721cdffdc0dd", + "testharness" + ], + "css/css-typed-om/the-stylepropertymap/properties/text-rendering.html": [ + "2e18286848b05dda619c9708d858d19b7dbcd8d2", + "testharness" + ], "css/css-typed-om/the-stylepropertymap/properties/text-transform-expected.txt": [ "3999d23023fb88ad5e47879574f7b3bd92d91528", "support" @@ -306362,6 +306453,14 @@ "85cbf6daa2686a518566e4ccbfc2ba39197b190e", "testharness" ], + "css/css-typed-om/the-stylepropertymap/properties/transform-style-expected.txt": [ + "021aa724fc44af31319271d3e6add45bba2a5faf", + "support" + ], + "css/css-typed-om/the-stylepropertymap/properties/transform-style.html": [ + "b36e671f379b935611a0c29348c469115b204488", + "testharness" + ], "css/css-typed-om/the-stylepropertymap/properties/transform.html": [ "2723b6d3e9a213a1b33e9ecfafd5fd42eb8bca33", "testharness" @@ -306378,6 +306477,14 @@ "b676714807b4fcdfd5ba7555f7c2ee3d1d9590d2", "testharness" ], + "css/css-typed-om/the-stylepropertymap/properties/user-select-expected.txt": [ + "b626905dec44c166f27bf2b6546d49a0b246b7ba", + "support" + ], + "css/css-typed-om/the-stylepropertymap/properties/user-select.html": [ + "a4c544daf99e01d99b9115fb575248f8dad337df", + "testharness" + ], "css/css-typed-om/the-stylepropertymap/properties/vertical-align.html": [ "41ae6fd66b5a0e6f3b5f154d839362a4921712cc", "testharness" @@ -316050,6 +316157,10 @@ "c9ed57c7ef7a035c25feff4ea60547a57d727f31", "testharness" ], + "css/cssom/font-shorthand-serialization.html": [ + "9d0bce1c0d74bf90aca1eb8ee6aa2e2ed2b92b30", + "testharness" + ], "css/cssom/getComputedStyle-dynamic-subdoc.html": [ "45d94c17f0a88877a8218135c94d331afcdf7df4", "testharness" @@ -316171,11 +316282,11 @@ "testharness" ], "css/cssom/serialize-variable-reference-expected.txt": [ - "323c653a5f432a779ec33c1ed1806f2a46a7392b", + "e9608c8cffb0c8fe511b043186add323628f7b6f", "support" ], "css/cssom/serialize-variable-reference.html": [ - "85a25fcb99fe433e3f71bc1b6fec92815da2704d", + "65054797d336c1a4b77c6f66e7b466dc24095517", "testharness" ], "css/cssom/setproperty-null-undefined.html": [ @@ -316414,10 +316525,6 @@ "0c1c8fb977b24bb3b5ca33051b32932f36f5a960", "testharness" ], - "css/cssom/variable-names-expected.txt": [ - "bcdca67e9b5107f2c0dd633ebcb2e2eaba367070", - "support" - ], "css/cssom/variable-names.html": [ "0da19a40542ea2eb282bf04e6ea65d15490fc097", "testharness" @@ -339287,7 +339394,7 @@ "support" ], "html/semantics/document-metadata/the-link-element/resources/link-load-error-events.sub.js": [ - "0c45045a1db6958751dfe112aa3234ca936263e7", + "1c5d8fe0b94b033b8e6ee7bcf54bd35ba2febd36", "support" ], "html/semantics/document-metadata/the-link-element/resources/stylesheet.css": [ @@ -372266,6 +372373,14 @@ "42cf0e2dd45eae0311c210cced7d9c9c83620501", "testharness" ], + "streams/readable-streams/default-reader-expected.txt": [ + "9e64aef5c85f4e1052adca8eb7807f145d5349ae", + "support" + ], + "streams/readable-streams/default-reader.dedicatedworker-expected.txt": [ + "9e64aef5c85f4e1052adca8eb7807f145d5349ae", + "support" + ], "streams/readable-streams/default-reader.dedicatedworker.html": [ "42750f1d324f57507feb0260704a55c4cc0f8382", "testharness" @@ -372275,7 +372390,11 @@ "testharness" ], "streams/readable-streams/default-reader.js": [ - "8746e2c94c2bc28431aefaae71d83f87c5738cde", + "639fc79798f07714549495a52364408773ac830a", + "support" + ], + "streams/readable-streams/default-reader.serviceworker.https-expected.txt": [ + "00c50429a7ef205bffe70fefe1f9751f0869c3e3", "support" ], "streams/readable-streams/default-reader.serviceworker.https.html": [ @@ -373211,7 +373330,7 @@ "testharness" ], "svg/linking/reftests/href-a-element-attr-change.html": [ - "6605832f7f8bff45a35fd436effa0c01e12c91e5", + "74ac37244250ec2d03a50b3e487b39d344ca7dc1", "reftest" ], "svg/linking/reftests/href-a-element-ref.html": [ @@ -375022,10 +375141,6 @@ "01f669542434f03d37e9f148a4f3135fe3122d46", "testharness" ], - "web-animations/interfaces/AnimationEffect/getComputedTiming-expected.txt": [ - "ed031dc998b9bbd6d9483fa69f213f5a2233e46d", - "support" - ], "web-animations/interfaces/AnimationEffect/getComputedTiming.html": [ "e0d4ba4c0f1a5da4d126c501eca733e00adbef1a", "testharness" @@ -375042,10 +375157,6 @@ "ed031dc998b9bbd6d9483fa69f213f5a2233e46d", "support" ], - "web-animations/interfaces/AnimationPlaybackEvent/constructor-expected.txt": [ - "9f5f2918d1c87c03c88105706ea87e85063d7e7c", - "support" - ], "web-animations/interfaces/AnimationPlaybackEvent/constructor.html": [ "5aff03b7fa469e5ec0dc02a389eca963ae24b470", "testharness" @@ -375182,10 +375293,6 @@ "617bfd8c533d159c4e56ea823917d580fe262bf6", "testharness" ], - "web-animations/timing-model/animation-effects/local-time-expected.txt": [ - "c6ed79812e283047a350d26f22c4baf3cda691ba", - "support" - ], "web-animations/timing-model/animation-effects/local-time.html": [ "cd76b6be13cba0bc7d3b1a0e87b70c6a66222f40", "testharness" @@ -376731,11 +376838,11 @@ "testharness" ], "webrtc/RTCDTMFSender-ontonechange.https-expected.txt": [ - "eee9ec7f5a022d109c10368a262c17b244401937", + "caa6ccc6a286883d4ecea875544462c1abaef503", "support" ], "webrtc/RTCDTMFSender-ontonechange.https.html": [ - "4f53cbc7fafeeed5202774b58d4bf721055b382e", + "ecc1e77f083cb91af78b1bcb7311fe4b5b96313e", "testharness" ], "webrtc/RTCDataChannel-bufferedAmount-expected.txt": [
diff --git a/third_party/WebKit/LayoutTests/external/wpt/FileAPI/url/url-in-tags-revoke.window.js b/third_party/WebKit/LayoutTests/external/wpt/FileAPI/url/url-in-tags-revoke.window.js index e610e0b..a564730 100644 --- a/third_party/WebKit/LayoutTests/external/wpt/FileAPI/url/url-in-tags-revoke.window.js +++ b/third_party/WebKit/LayoutTests/external/wpt/FileAPI/url/url-in-tags-revoke.window.js
@@ -17,6 +17,27 @@ }, 'Fetching a blob URL immediately before revoking it works in an iframe.'); async_test(t => { + const run_result = 'test_frame_OK'; + const blob_contents = '<!doctype html>\n<meta charset="utf-8">\n' + + '<script>window.test_result = "' + run_result + '";</script>'; + const blob = new Blob([blob_contents], {type: 'text/html'}); + const url = URL.createObjectURL(blob); + + const frame = document.createElement('iframe'); + frame.setAttribute('src', '/common/blank.html'); + frame.setAttribute('style', 'display:none;'); + document.body.appendChild(frame); + + frame.onload = t.step_func(() => { + frame.contentWindow.location = url; + URL.revokeObjectURL(url); + frame.onload = t.step_func_done(() => { + assert_equals(frame.contentWindow.test_result, run_result); + }); + }); +}, 'Fetching a blob URL immediately before revoking it works in an iframe navigation.'); + +async_test(t => { const run_result = 'test_script_OK'; const blob_contents = 'window.script_test_result = "' + run_result + '";'; const blob = new Blob([blob_contents]);
diff --git a/third_party/WebKit/LayoutTests/external/wpt/css/css-text-decor/reference/text-emphasis-style-001-ref.html b/third_party/WebKit/LayoutTests/external/wpt/css/css-text-decor/reference/text-emphasis-style-001-ref.html index 44588741..6222a7c 100644 --- a/third_party/WebKit/LayoutTests/external/wpt/css/css-text-decor/reference/text-emphasis-style-001-ref.html +++ b/third_party/WebKit/LayoutTests/external/wpt/css/css-text-decor/reference/text-emphasis-style-001-ref.html
@@ -6,7 +6,7 @@ <link rel="author" title="Takanori Koroki" href="mailto:tak.koroki@gmail.com"> </head> <body> - <p>Test passes if there is no dots avobe the text of "Text sample".</p> + <p>Test passes if there is no dots above the text of "Text sample".</p> <p>Text sample</p> </body> </html>
diff --git a/third_party/WebKit/LayoutTests/external/wpt/html/semantics/document-metadata/the-link-element/link-load-error-events-expected.txt b/third_party/WebKit/LayoutTests/external/wpt/html/semantics/document-metadata/the-link-element/link-load-error-events-expected.txt new file mode 100644 index 0000000..354818f --- /dev/null +++ b/third_party/WebKit/LayoutTests/external/wpt/html/semantics/document-metadata/the-link-element/link-load-error-events-expected.txt
@@ -0,0 +1,20 @@ +This is a testharness.js-based test. +PASS Basic load of stylesheet +PASS Attempted load of nonexistent stylesheet +PASS Import of stylesheet +PASS Import of nonexistent stylesheet +PASS Import of import of stylesheet +FAIL Import of import of nonexistent stylesheet assert_unreached: load fired when error expected Reached unreachable code +FAIL Load of non-CSS stylesheet assert_unreached: load fired when error expected Reached unreachable code +FAIL Import of non-CSS stylesheet assert_unreached: load fired when error expected Reached unreachable code +FAIL Import of import of non-CSS stylesheet assert_unreached: load fired when error expected Reached unreachable code +PASS Load of http:// stylesheet +PASS Import of http:// stylesheet +PASS Import of import of http:// stylesheet +PASS Load of https:// stylesheet +PASS Import of https:// stylesheet +PASS Import of import of https:// stylesheet +PASS Slow successful import, fast failing import +PASS Fast successful import, slow failing import +Harness: the test ran to completion. +
diff --git a/third_party/WebKit/LayoutTests/external/wpt/html/semantics/document-metadata/the-link-element/link-load-error-events.https-expected.txt b/third_party/WebKit/LayoutTests/external/wpt/html/semantics/document-metadata/the-link-element/link-load-error-events.https-expected.txt new file mode 100644 index 0000000..b0674ff --- /dev/null +++ b/third_party/WebKit/LayoutTests/external/wpt/html/semantics/document-metadata/the-link-element/link-load-error-events.https-expected.txt
@@ -0,0 +1,20 @@ +This is a testharness.js-based test. +PASS Basic load of stylesheet +PASS Attempted load of nonexistent stylesheet +PASS Import of stylesheet +PASS Import of nonexistent stylesheet +PASS Import of import of stylesheet +FAIL Import of import of nonexistent stylesheet assert_unreached: load fired when error expected Reached unreachable code +FAIL Load of non-CSS stylesheet assert_unreached: load fired when error expected Reached unreachable code +FAIL Import of non-CSS stylesheet assert_unreached: load fired when error expected Reached unreachable code +FAIL Import of import of non-CSS stylesheet assert_unreached: load fired when error expected Reached unreachable code +PASS Load of http:// stylesheet +PASS Import of http:// stylesheet +FAIL Import of import of http:// stylesheet assert_unreached: load fired when error expected Reached unreachable code +PASS Load of https:// stylesheet +PASS Import of https:// stylesheet +PASS Import of import of https:// stylesheet +PASS Slow successful import, fast failing import +PASS Fast successful import, slow failing import +Harness: the test ran to completion. +
diff --git a/third_party/WebKit/LayoutTests/external/wpt/html/semantics/document-metadata/the-link-element/resources/link-load-error-events.sub.js b/third_party/WebKit/LayoutTests/external/wpt/html/semantics/document-metadata/the-link-element/resources/link-load-error-events.sub.js index ac56a01..33c8709 100644 --- a/third_party/WebKit/LayoutTests/external/wpt/html/semantics/document-metadata/the-link-element/resources/link-load-error-events.sub.js +++ b/third_party/WebKit/LayoutTests/external/wpt/html/semantics/document-metadata/the-link-element/resources/link-load-error-events.sub.js
@@ -7,6 +7,10 @@ * avoids issues around caching of sheets based on URL. */ +// Our URLs are random, so we don't use them in error messages by +// default, but enable doing it if someone wants to debug things. +const DEBUG_URLS = false; + var isHttps = location.protocol == "https:"; var tests = [ @@ -113,12 +117,13 @@ var t = async_test(description); var link = document.createElement("link"); link.rel = "stylesheet"; + hrefString = DEBUG_URLS ? `: ${href}` : ""; if (success) { link.onload = t.step_func_done(() => {}); - link.onerror = t.step_func_done(() => assert_unreached(`error fired when load expected: ${href}`) ); + link.onerror = t.step_func_done(() => assert_unreached(`error fired when load expected${hrefString}`) ); } else { link.onerror = t.step_func_done(() => {}); - link.onload = t.step_func_done(() => assert_unreached(`load fired when error expected: ${href}`) ); + link.onload = t.step_func_done(() => assert_unreached(`load fired when error expected${hrefString}`) ); } link.href = href; document.head.appendChild(link);
diff --git a/third_party/WebKit/LayoutTests/external/wpt/streams/readable-streams/default-reader-expected.txt b/third_party/WebKit/LayoutTests/external/wpt/streams/readable-streams/default-reader-expected.txt new file mode 100644 index 0000000..0426dc27 --- /dev/null +++ b/third_party/WebKit/LayoutTests/external/wpt/streams/readable-streams/default-reader-expected.txt
@@ -0,0 +1,30 @@ +This is a testharness.js-based test. +PASS Can get the ReadableStreamDefaultReader constructor indirectly +PASS ReadableStreamDefaultReader constructor should get a ReadableStream object as argument +PASS ReadableStreamDefaultReader instances should have the correct list of properties +PASS ReadableStreamDefaultReader closed should always return the same promise object +PASS Constructing a ReadableStreamDefaultReader directly should fail if the stream is already locked (via direct construction) +PASS Getting a ReadableStreamDefaultReader via getReader should fail if the stream is already locked (via direct construction) +PASS Constructing a ReadableStreamDefaultReader directly should fail if the stream is already locked (via getReader) +PASS Getting a ReadableStreamDefaultReader via getReader should fail if the stream is already locked (via getReader) +PASS Constructing a ReadableStreamDefaultReader directly should be OK if the stream is closed +PASS Constructing a ReadableStreamDefaultReader directly should be OK if the stream is errored +PASS Reading from a reader for an empty stream will wait until a chunk is available +PASS cancel() on a reader does not release the reader +PASS closed should be fulfilled after stream is closed (.closed access before acquiring) +PASS closed should be rejected after reader releases its lock (multiple stream locks) +PASS Multiple readers can access the stream in sequence +PASS Cannot use an already-released reader to unlock a stream again +PASS cancel() on a released reader is a no-op and does not pass through +PASS Getting a second reader after erroring the stream and releasing the reader should succeed +PASS ReadableStreamDefaultReader closed promise should be rejected with undefined if that is the error +PASS ReadableStreamDefaultReader: if start rejects with no parameter, it should error the stream with an undefined error +PASS Erroring a ReadableStream after checking closed should reject ReadableStreamDefaultReader closed promise +PASS Erroring a ReadableStream before checking closed should reject ReadableStreamDefaultReader closed promise +PASS Reading twice on a stream that gets closed +PASS Reading twice on a closed stream +PASS Reading twice on an errored stream +PASS Reading twice on a stream that gets errored +FAIL getReader() should call ToString() on mode assert_true: toString() should be called expected true got false +Harness: the test ran to completion. +
diff --git a/third_party/WebKit/LayoutTests/external/wpt/streams/readable-streams/default-reader.dedicatedworker-expected.txt b/third_party/WebKit/LayoutTests/external/wpt/streams/readable-streams/default-reader.dedicatedworker-expected.txt new file mode 100644 index 0000000..0426dc27 --- /dev/null +++ b/third_party/WebKit/LayoutTests/external/wpt/streams/readable-streams/default-reader.dedicatedworker-expected.txt
@@ -0,0 +1,30 @@ +This is a testharness.js-based test. +PASS Can get the ReadableStreamDefaultReader constructor indirectly +PASS ReadableStreamDefaultReader constructor should get a ReadableStream object as argument +PASS ReadableStreamDefaultReader instances should have the correct list of properties +PASS ReadableStreamDefaultReader closed should always return the same promise object +PASS Constructing a ReadableStreamDefaultReader directly should fail if the stream is already locked (via direct construction) +PASS Getting a ReadableStreamDefaultReader via getReader should fail if the stream is already locked (via direct construction) +PASS Constructing a ReadableStreamDefaultReader directly should fail if the stream is already locked (via getReader) +PASS Getting a ReadableStreamDefaultReader via getReader should fail if the stream is already locked (via getReader) +PASS Constructing a ReadableStreamDefaultReader directly should be OK if the stream is closed +PASS Constructing a ReadableStreamDefaultReader directly should be OK if the stream is errored +PASS Reading from a reader for an empty stream will wait until a chunk is available +PASS cancel() on a reader does not release the reader +PASS closed should be fulfilled after stream is closed (.closed access before acquiring) +PASS closed should be rejected after reader releases its lock (multiple stream locks) +PASS Multiple readers can access the stream in sequence +PASS Cannot use an already-released reader to unlock a stream again +PASS cancel() on a released reader is a no-op and does not pass through +PASS Getting a second reader after erroring the stream and releasing the reader should succeed +PASS ReadableStreamDefaultReader closed promise should be rejected with undefined if that is the error +PASS ReadableStreamDefaultReader: if start rejects with no parameter, it should error the stream with an undefined error +PASS Erroring a ReadableStream after checking closed should reject ReadableStreamDefaultReader closed promise +PASS Erroring a ReadableStream before checking closed should reject ReadableStreamDefaultReader closed promise +PASS Reading twice on a stream that gets closed +PASS Reading twice on a closed stream +PASS Reading twice on an errored stream +PASS Reading twice on a stream that gets errored +FAIL getReader() should call ToString() on mode assert_true: toString() should be called expected true got false +Harness: the test ran to completion. +
diff --git a/third_party/WebKit/LayoutTests/external/wpt/streams/readable-streams/default-reader.js b/third_party/WebKit/LayoutTests/external/wpt/streams/readable-streams/default-reader.js index 7543545c..9b645e2 100644 --- a/third_party/WebKit/LayoutTests/external/wpt/streams/readable-streams/default-reader.js +++ b/third_party/WebKit/LayoutTests/external/wpt/streams/readable-streams/default-reader.js
@@ -485,4 +485,17 @@ }, 'Reading twice on a stream that gets errored'); +test(() => { + const rs = new ReadableStream(); + let toStringCalled = false; + const mode = { + toString() { + toStringCalled = true; + return ''; + } + }; + assert_throws(new RangeError(), () => rs.getReader({ mode }), 'getReader() should throw'); + assert_true(toStringCalled, 'toString() should be called'); +}, 'getReader() should call ToString() on mode'); + done();
diff --git a/third_party/WebKit/LayoutTests/external/wpt/streams/readable-streams/default-reader.serviceworker.https-expected.txt b/third_party/WebKit/LayoutTests/external/wpt/streams/readable-streams/default-reader.serviceworker.https-expected.txt new file mode 100644 index 0000000..1afbabd --- /dev/null +++ b/third_party/WebKit/LayoutTests/external/wpt/streams/readable-streams/default-reader.serviceworker.https-expected.txt
@@ -0,0 +1,31 @@ +This is a testharness.js-based test. +PASS Service worker test setup +PASS Can get the ReadableStreamDefaultReader constructor indirectly +PASS ReadableStreamDefaultReader constructor should get a ReadableStream object as argument +PASS ReadableStreamDefaultReader instances should have the correct list of properties +PASS ReadableStreamDefaultReader closed should always return the same promise object +PASS Constructing a ReadableStreamDefaultReader directly should fail if the stream is already locked (via direct construction) +PASS Getting a ReadableStreamDefaultReader via getReader should fail if the stream is already locked (via direct construction) +PASS Constructing a ReadableStreamDefaultReader directly should fail if the stream is already locked (via getReader) +PASS Getting a ReadableStreamDefaultReader via getReader should fail if the stream is already locked (via getReader) +PASS Constructing a ReadableStreamDefaultReader directly should be OK if the stream is closed +PASS Constructing a ReadableStreamDefaultReader directly should be OK if the stream is errored +PASS Reading from a reader for an empty stream will wait until a chunk is available +PASS cancel() on a reader does not release the reader +PASS closed should be fulfilled after stream is closed (.closed access before acquiring) +PASS closed should be rejected after reader releases its lock (multiple stream locks) +PASS Multiple readers can access the stream in sequence +PASS Cannot use an already-released reader to unlock a stream again +PASS cancel() on a released reader is a no-op and does not pass through +PASS Getting a second reader after erroring the stream and releasing the reader should succeed +PASS ReadableStreamDefaultReader closed promise should be rejected with undefined if that is the error +PASS ReadableStreamDefaultReader: if start rejects with no parameter, it should error the stream with an undefined error +PASS Erroring a ReadableStream after checking closed should reject ReadableStreamDefaultReader closed promise +PASS Erroring a ReadableStream before checking closed should reject ReadableStreamDefaultReader closed promise +PASS Reading twice on a stream that gets closed +PASS Reading twice on a closed stream +PASS Reading twice on an errored stream +PASS Reading twice on a stream that gets errored +FAIL getReader() should call ToString() on mode assert_true: toString() should be called expected true got false +Harness: the test ran to completion. +
diff --git a/third_party/WebKit/LayoutTests/external/wpt/svg/linking/reftests/href-a-element-attr-change.html b/third_party/WebKit/LayoutTests/external/wpt/svg/linking/reftests/href-a-element-attr-change.html index ceb0f18..c74b2e01 100644 --- a/third_party/WebKit/LayoutTests/external/wpt/svg/linking/reftests/href-a-element-attr-change.html +++ b/third_party/WebKit/LayoutTests/external/wpt/svg/linking/reftests/href-a-element-attr-change.html
@@ -1,5 +1,5 @@ <!DOCTYPE html> -<html class="retest-wait"> +<html class="reftest-wait"> <meta charset="utf-8"> <title>href - a element</title> <meta name="assert"
diff --git a/third_party/WebKit/LayoutTests/fast/events/mouse-event-buttons-attribute-expected.txt b/third_party/WebKit/LayoutTests/fast/events/mouse-event-buttons-attribute-expected.txt index ae8f5a0..26d40b1 100644 --- a/third_party/WebKit/LayoutTests/fast/events/mouse-event-buttons-attribute-expected.txt +++ b/third_party/WebKit/LayoutTests/fast/events/mouse-event-buttons-attribute-expected.txt
@@ -105,12 +105,6 @@ 6. targetDiv received mouseleave buttons: 0 ===== longPressAction with initial state=[] and showContextMenuOnMouseUp=true ===== -1. targetDiv received mouseover buttons: 0 -2. targetDiv received mouseenter buttons: 0 -3. targetDiv received mousemove buttons: 0 -4. targetDiv received contextmenu buttons: 0 -5. targetDiv received mouseout buttons: 0 -6. targetDiv received mouseleave buttons: 0 ===== longTapAction with initial state=[] and showContextMenuOnMouseUp=false ===== 1. targetDiv received mouseover buttons: 0
diff --git a/third_party/WebKit/LayoutTests/fast/events/pointerevents/touch-pointer-long-press.html b/third_party/WebKit/LayoutTests/fast/events/pointerevents/touch-pointer-long-press.html index 5fbaffc..8c2c573e 100644 --- a/third_party/WebKit/LayoutTests/fast/events/pointerevents/touch-pointer-long-press.html +++ b/third_party/WebKit/LayoutTests/fast/events/pointerevents/touch-pointer-long-press.html
@@ -42,10 +42,24 @@ function runTests() { var rect = document.getElementById("target").getBoundingClientRect(); + + internals.settings.setShowContextMenuOnMouseUp(false); eventSender.gestureLongPress(rect.left + 5, rect.top + 5); testReceivedEvents([ "mouseover", "mouseenter", "mousemove", "contextmenu" - ], "Long press events"); + ], "Long press events show contextmenu"); + + eventSender.gestureLongTap(rect.left + 5, rect.top + 5); + testReceivedEvents([], "Long tap events no contextmenu"); + + internals.settings.setShowContextMenuOnMouseUp(true); + eventSender.gestureLongPress(rect.left + 5, rect.top + 5); + testReceivedEvents([], "Long press events no contextmenu"); + + eventSender.gestureLongTap(rect.left + 5, rect.top + 5); + testReceivedEvents([ + "mousemove", "contextmenu" + ], "Long tap events show contextmenu"); }
diff --git a/third_party/WebKit/LayoutTests/fast/events/pointerevents/touch-pointer-mouse.html b/third_party/WebKit/LayoutTests/fast/events/pointerevents/touch-pointer-mouse.html index a555df9e..72b1601c 100644 --- a/third_party/WebKit/LayoutTests/fast/events/pointerevents/touch-pointer-mouse.html +++ b/third_party/WebKit/LayoutTests/fast/events/pointerevents/touch-pointer-mouse.html
@@ -109,6 +109,7 @@ eventSender.touchCancel(); eventSender.gestureLongPress(x, y, tapWidth, tapHeight, uniqueId); + eventSender.gestureLongTap(x, y, tapWidth, tapHeight, uniqueId + 1); } function testLongPressWithoutPairedGE() { @@ -127,9 +128,11 @@ eventSender.gestureTapDown(x, y, tapWidth, tapHeight, uniqueId+1); eventSender.gestureLongPress(x, y); + eventSender.gestureLongTap(x, y); eventSender.gestureTapDown(x, y, tapWidth, tapHeight, uniqueId+2); eventSender.gestureLongPress(x, y); + eventSender.gestureLongTap(x, y); } function runTests() {
diff --git a/third_party/WebKit/LayoutTests/fast/events/touch/gesture/context-menu-on-long-press-expected.txt b/third_party/WebKit/LayoutTests/fast/events/touch/gesture/context-menu-on-long-press-expected.txt index 1139b4a..583523c 100644 --- a/third_party/WebKit/LayoutTests/fast/events/touch/gesture/context-menu-on-long-press-expected.txt +++ b/third_party/WebKit/LayoutTests/fast/events/touch/gesture/context-menu-on-long-press-expected.txt
@@ -5,11 +5,21 @@ TEST COMPLETE showContextMenuOnMouseUp = true -Event sequence: mouseover mouseenter mousemove contextmenu -PASS: Context Menu event seen. +Long press event sequence: +Context Menu event received: false +PASS + +Long tap event sequence: mouseover mouseenter mousemove contextmenu +Context Menu event received: true +PASS showContextMenuOnMouseUp = false -Event sequence: mousemove contextmenu -PASS: Context Menu event seen. +Long press event sequence: mousemove contextmenu +Context Menu event received: true +PASS + +Long tap event sequence: +Context Menu event received: false +PASS
diff --git a/third_party/WebKit/LayoutTests/fast/events/touch/gesture/context-menu-on-long-press.html b/third_party/WebKit/LayoutTests/fast/events/touch/gesture/context-menu-on-long-press.html index 6a46c7c..aabb669 100644 --- a/third_party/WebKit/LayoutTests/fast/events/touch/gesture/context-menu-on-long-press.html +++ b/third_party/WebKit/LayoutTests/fast/events/touch/gesture/context-menu-on-long-press.html
@@ -17,17 +17,27 @@ "use strict"; var eventSequence = ""; -var testResult="" +var ContextmenuReceived = false; function runTest(x, y, mouseUpFlag) { - eventSequence = "Event sequence:"; - testResult="FAIL"; + eventSequence = ""; + ContextmenuReceived = false; internals.settings.setShowContextMenuOnMouseUp(mouseUpFlag); eventSender.gestureLongPress(x, y); debug("showContextMenuOnMouseUp = " + mouseUpFlag) - debug(eventSequence); - debug(testResult); + debug("Long press event sequence:" + eventSequence) + debug("Context Menu event received: " + ContextmenuReceived); + debug(ContextmenuReceived != mouseUpFlag ? "PASS" : "FAIL"); + debug(""); + + eventSequence = ""; + ContextmenuReceived = false; + eventSender.gestureLongTap(x, y); + + debug("Long tap event sequence:" + eventSequence) + debug("Context Menu event received: " + ContextmenuReceived); + debug(ContextmenuReceived == mouseUpFlag ? "PASS" : "FAIL"); debug(""); } @@ -37,7 +47,7 @@ testRunner.dumpAsText(); document.oncontextmenu = function() { - testResult = "PASS: Context Menu event seen."; + ContextmenuReceived = true; } for (let evtType of ["contextmenu", "mouseover", "mousemove", "mouseout", "mouseenter", "mouseleave", "mouseup", "mousedown"]) {
diff --git a/third_party/WebKit/LayoutTests/fast/events/touch/touch-action-preventDefault-expected.txt b/third_party/WebKit/LayoutTests/fast/events/touch/touch-action-preventDefault-expected.txt index 2291d1f..2579c59 100644 --- a/third_party/WebKit/LayoutTests/fast/events/touch/touch-action-preventDefault-expected.txt +++ b/third_party/WebKit/LayoutTests/fast/events/touch/touch-action-preventDefault-expected.txt
@@ -1,4 +1,4 @@ -CONSOLE WARNING: line 13: Unable to preventDefault inside passive event listener due to target being treated as passive. See https://www.chromestatus.com/features/5093566007214080 +CONSOLE ERROR: line 13: Unable to preventDefault inside passive event listener due to target being treated as passive. See https://www.chromestatus.com/features/5093566007214080 This is a testharness.js-based test. PASS Forced passive event listener PASS Forced passive event listener with touch-action
diff --git a/third_party/WebKit/LayoutTests/fast/events/touch/touch-event-cancelable-expected.txt b/third_party/WebKit/LayoutTests/fast/events/touch/touch-event-cancelable-expected.txt index ce87019..99a0b5e 100644 --- a/third_party/WebKit/LayoutTests/fast/events/touch/touch-event-cancelable-expected.txt +++ b/third_party/WebKit/LayoutTests/fast/events/touch/touch-event-cancelable-expected.txt
@@ -2,9 +2,9 @@ CONSOLE MESSAGE: line 21: Calling preventDefault on TouchEvent with cancelable=true CONSOLE MESSAGE: line 39: Sending uncancelable touchmove CONSOLE MESSAGE: line 21: Calling preventDefault on TouchEvent with cancelable=false -CONSOLE WARNING: line 22: Ignored attempt to cancel a touchmove event with cancelable=false, for example because scrolling is in progress and cannot be interrupted. +CONSOLE ERROR: line 22: Ignored attempt to cancel a touchmove event with cancelable=false, for example because scrolling is in progress and cannot be interrupted. CONSOLE MESSAGE: line 64: Sending uncancelable touchmove -CONSOLE WARNING: line 57: Ignored attempt to cancel a touchmove event with cancelable=false, for example because scrolling is in progress and cannot be interrupted. +CONSOLE ERROR: line 57: Ignored attempt to cancel a touchmove event with cancelable=false, for example because scrolling is in progress and cannot be interrupted. This is a testharness.js-based test. PASS Test that touch events may or may not be marked cancelable. http://crbug.com/365681 PASS Test that warning occurs in default mode
diff --git a/third_party/WebKit/LayoutTests/flag-specific/enable-blink-features=LayoutNG/editing/execCommand/align-in-span-expected.txt b/third_party/WebKit/LayoutTests/flag-specific/enable-blink-features=LayoutNG/editing/execCommand/align-in-span-expected.txt deleted file mode 100644 index 6b34927..0000000 --- a/third_party/WebKit/LayoutTests/flag-specific/enable-blink-features=LayoutNG/editing/execCommand/align-in-span-expected.txt +++ /dev/null
@@ -1,4 +0,0 @@ -Line 1. -Select all text in this line and use justify command. -Line 3. -
diff --git a/third_party/WebKit/LayoutTests/flag-specific/enable-blink-features=LayoutNG/editing/pasteboard/drag-selected-image-to-contenteditable-expected.png b/third_party/WebKit/LayoutTests/flag-specific/enable-blink-features=LayoutNG/editing/pasteboard/drag-selected-image-to-contenteditable-expected.png new file mode 100644 index 0000000..bcb70143 --- /dev/null +++ b/third_party/WebKit/LayoutTests/flag-specific/enable-blink-features=LayoutNG/editing/pasteboard/drag-selected-image-to-contenteditable-expected.png Binary files differ
diff --git a/third_party/WebKit/LayoutTests/flag-specific/enable-blink-features=LayoutNG/editing/pasteboard/drag-selected-image-to-contenteditable-expected.txt b/third_party/WebKit/LayoutTests/flag-specific/enable-blink-features=LayoutNG/editing/pasteboard/drag-selected-image-to-contenteditable-expected.txt new file mode 100644 index 0000000..be1c276d --- /dev/null +++ b/third_party/WebKit/LayoutTests/flag-specific/enable-blink-features=LayoutNG/editing/pasteboard/drag-selected-image-to-contenteditable-expected.txt
@@ -0,0 +1,23 @@ +EDITING DELEGATE: webViewDidChangeSelection:WebViewDidChangeSelectionNotification +EDITING DELEGATE: webViewDidChangeSelection:WebViewDidChangeSelectionNotification +EDITING DELEGATE: webViewDidChangeSelection:WebViewDidChangeSelectionNotification +EDITING DELEGATE: webViewDidChange:WebViewDidChangeNotification +layer at (0,0) size 800x600 + LayoutView at (0,0) size 800x600 +layer at (0,0) size 800x600 + LayoutNGBlockFlow {HTML} at (0,0) size 800x600 + LayoutNGBlockFlow {BODY} at (0,0) size 800x584 + LayoutBlockFlow {DIV} at (0,0) size 302x122 [border: (1px solid #000000)] + LayoutImage {IMG} at (1,1) size 76x103 + LayoutNGBlockFlow (anonymous) at (0,122) size 800x103 + LayoutImage {IMG} at (0,0) size 76x103 + LayoutText {#text} at (0,0) size 0x0 + LayoutNGBlockFlow {UL} at (0,241) size 800x20 + LayoutNGListItem {LI} at (40,0) size 760x20 + LayoutNGListMarker (anonymous) at (-18,0) size 10x20 + LayoutText (anonymous) at (0,0) size 10x19 + text run at (0,0) width 10: "\x{2022} " + LayoutText {#text} at (0,0) size 409x19 + text run at (0,0) width 409: "Abe should appear twice, once inside the div and once outside it." +selection start: position 0 of child 0 {IMG} of child 1 {DIV} of body +selection end: position 1 of child 0 {IMG} of child 1 {DIV} of body
diff --git a/third_party/WebKit/LayoutTests/flag-specific/enable-blink-features=LayoutNG/editing/pasteboard/input-field-1-expected.png b/third_party/WebKit/LayoutTests/flag-specific/enable-blink-features=LayoutNG/editing/pasteboard/input-field-1-expected.png new file mode 100644 index 0000000..d3f4fcb1 --- /dev/null +++ b/third_party/WebKit/LayoutTests/flag-specific/enable-blink-features=LayoutNG/editing/pasteboard/input-field-1-expected.png Binary files differ
diff --git a/third_party/WebKit/LayoutTests/flag-specific/enable-blink-features=LayoutNG/editing/pasteboard/input-field-1-expected.txt b/third_party/WebKit/LayoutTests/flag-specific/enable-blink-features=LayoutNG/editing/pasteboard/input-field-1-expected.txt new file mode 100644 index 0000000..272bb80 --- /dev/null +++ b/third_party/WebKit/LayoutTests/flag-specific/enable-blink-features=LayoutNG/editing/pasteboard/input-field-1-expected.txt
@@ -0,0 +1,28 @@ +EDITING DELEGATE: webViewDidChangeSelection:WebViewDidChangeSelectionNotification +EDITING DELEGATE: webViewDidChangeSelection:WebViewDidChangeSelectionNotification +EDITING DELEGATE: webViewDidChangeSelection:WebViewDidChangeSelectionNotification +EDITING DELEGATE: webViewDidChangeSelection:WebViewDidChangeSelectionNotification +EDITING DELEGATE: webViewDidChange:WebViewDidChangeNotification +layer at (0,0) size 800x600 + LayoutView at (0,0) size 800x600 +layer at (0,0) size 800x600 + LayoutNGBlockFlow {HTML} at (0,0) size 800x600 + LayoutNGBlockFlow {BODY} at (8,8) size 784x576 + LayoutNGBlockFlow {P} at (0,0) size 784x20 + LayoutText {#text} at (0,0) size 235x19 + text run at (0,0) width 235: "This tests Copy/Paste of a input field." + LayoutBlockFlow {DIV} at (0,36) size 784x22 + LayoutTextControl {INPUT} at (0,0) size 181x22 [bgcolor=#FFFFFF] [border: (2px inset #EEEEEE)] + LayoutTextControl {INPUT} at (181,0) size 181x22 [bgcolor=#FFFFFF] [border: (2px inset #EEEEEE)] + LayoutNGBlockFlow {UL} at (0,74) size 784x20 + LayoutNGListItem {LI} at (40,0) size 744x20 + LayoutNGListMarker (anonymous) at (-18,0) size 10x20 + LayoutText (anonymous) at (0,0) size 10x19 + text run at (0,0) width 10: "\x{2022} " + LayoutText {#text} at (0,0) size 43x19 + text run at (0,0) width 43: "Passed" +layer at (10,47) size 177x16 + LayoutBlockFlow {DIV} at (2,3) size 177x16 +layer at (191,47) size 177x16 + LayoutBlockFlow {DIV} at (2,3) size 177x16 +caret: position 1 of child 1 {INPUT} of child 2 {DIV} of body
diff --git a/third_party/WebKit/LayoutTests/flag-specific/enable-blink-features=LayoutNG/editing/selection/designmode-no-caret-expected.png b/third_party/WebKit/LayoutTests/flag-specific/enable-blink-features=LayoutNG/editing/selection/designmode-no-caret-expected.png new file mode 100644 index 0000000..973eec7 --- /dev/null +++ b/third_party/WebKit/LayoutTests/flag-specific/enable-blink-features=LayoutNG/editing/selection/designmode-no-caret-expected.png Binary files differ
diff --git a/third_party/WebKit/LayoutTests/flag-specific/enable-blink-features=LayoutNG/editing/selection/designmode-no-caret-expected.txt b/third_party/WebKit/LayoutTests/flag-specific/enable-blink-features=LayoutNG/editing/selection/designmode-no-caret-expected.txt new file mode 100644 index 0000000..dc60799 --- /dev/null +++ b/third_party/WebKit/LayoutTests/flag-specific/enable-blink-features=LayoutNG/editing/selection/designmode-no-caret-expected.txt
@@ -0,0 +1,17 @@ +layer at (0,0) size 800x600 + LayoutView at (0,0) size 800x600 +layer at (0,0) size 800x600 + LayoutBlockFlow {HTML} at (0,0) size 800x600 + LayoutBlockFlow {BODY} at (8,8) size 784x584 + LayoutNGBlockFlow (anonymous) at (0,0) size 769x60 + LayoutText {#text} at (0,0) size 759x59 + text run at (0,0) width 759: "This tests to see that a caret is placed inside an editable document that is entirely editable even when no caret is requested" + text run at (0,20) width 116: "programmatically. " + text run at (116,20) width 185: "We do this as a convenience. " + text run at (301,20) width 418: "Right now, we only do this convenience when a document's frame" + text run at (0,40) width 435: "becomes first responder or when a document's window becomes key." + LayoutBlockFlow {PRE} at (0,73) size 784x32 + LayoutText {#text} at (0,0) size 296x32 + text run at (0,0) width 296: "Test Failed - there should be a caret" + text run at (296,0) width 0: " " + text run at (0,16) width 0: " "
diff --git a/third_party/WebKit/LayoutTests/flag-specific/enable-blink-features=LayoutNG/fast/css-generated-content/009-expected.png b/third_party/WebKit/LayoutTests/flag-specific/enable-blink-features=LayoutNG/fast/css-generated-content/009-expected.png new file mode 100644 index 0000000..d7d80e6 --- /dev/null +++ b/third_party/WebKit/LayoutTests/flag-specific/enable-blink-features=LayoutNG/fast/css-generated-content/009-expected.png Binary files differ
diff --git a/third_party/WebKit/LayoutTests/flag-specific/enable-blink-features=LayoutNG/fast/css-generated-content/009-expected.txt b/third_party/WebKit/LayoutTests/flag-specific/enable-blink-features=LayoutNG/fast/css-generated-content/009-expected.txt new file mode 100644 index 0000000..0a8e365 --- /dev/null +++ b/third_party/WebKit/LayoutTests/flag-specific/enable-blink-features=LayoutNG/fast/css-generated-content/009-expected.txt
@@ -0,0 +1,32 @@ +layer at (0,0) size 800x600 + LayoutView at (0,0) size 800x600 +layer at (0,0) size 800x600 + LayoutNGBlockFlow {HTML} at (0,0) size 800x600 + LayoutNGBlockFlow {BODY} at (8,8) size 784x584 + LayoutNGBlockFlow {P} at (0,0) size 784x20 + LayoutText {#text} at (0,0) size 67x19 + text run at (0,0) width 67: "All of this " + LayoutInline {SPAN} at (0,0) size 88x19 + LayoutText {#text} at (67,0) size 88x19 + text run at (67,0) width 88: "text should be" + LayoutText {#text} at (155,0) size 43x19 + text run at (155,0) width 43: " green." + LayoutNGBlockFlow {UL} at (0,36) size 784x20 + LayoutNGListItem {LI} at (40,0) size 744x20 + LayoutNGListMarker (anonymous) at (-18,0) size 10x20 + LayoutText (anonymous) at (0,0) size 10x19 + text run at (0,0) width 10: "\x{2022} " + LayoutText {#text} at (0,0) size 373x19 + text run at (0,0) width 373: "All of this text should be green. The bullet should be black." + LayoutNGBlockFlow {DIV} at (0,72) size 784x57 [color=#FF0000] + LayoutInline {SPAN} at (0,0) size 429x55 [color=#008000] + LayoutInline {<pseudo:first-letter>} at (0,0) size 35x55 + LayoutTextFragment (anonymous) at (0,1) size 35x55 + text run at (0,1) width 35: "A" + LayoutTextFragment {#text} at (35,29) size 394x19 + text run at (35,29) width 394: "ll of this text should be green, including the big \"A\" first-letter." + LayoutNGBlockFlow {P} at (0,145) size 784x0 + LayoutNGBlockFlow {DIV} at (0,145) size 784x20 + LayoutNGBlockFlow {DIV} at (0,0) size 163x20 [color=#FF0000] + LayoutText {#text} at (0,0) size 163x19 + text run at (0,0) width 163: "This text should be green."
diff --git a/third_party/WebKit/LayoutTests/flag-specific/enable-blink-features=LayoutNG/fast/css-generated-content/012-expected.png b/third_party/WebKit/LayoutTests/flag-specific/enable-blink-features=LayoutNG/fast/css-generated-content/012-expected.png new file mode 100644 index 0000000..8dbf4b6 --- /dev/null +++ b/third_party/WebKit/LayoutTests/flag-specific/enable-blink-features=LayoutNG/fast/css-generated-content/012-expected.png Binary files differ
diff --git a/third_party/WebKit/LayoutTests/flag-specific/enable-blink-features=LayoutNG/fast/css-generated-content/012-expected.txt b/third_party/WebKit/LayoutTests/flag-specific/enable-blink-features=LayoutNG/fast/css-generated-content/012-expected.txt new file mode 100644 index 0000000..9c7e314 --- /dev/null +++ b/third_party/WebKit/LayoutTests/flag-specific/enable-blink-features=LayoutNG/fast/css-generated-content/012-expected.txt
@@ -0,0 +1,27 @@ +layer at (0,0) size 800x600 + LayoutView at (0,0) size 800x600 +layer at (0,0) size 800x600 + LayoutNGBlockFlow {HTML} at (0,0) size 800x600 + LayoutNGBlockFlow {BODY} at (8,8) size 784x568 + LayoutNGBlockFlow {H1} at (0,0) size 784x57 + LayoutText {#text} at (0,1) size 774x55 + text run at (0,1) width 774: "Inheritance bug for floated first-letter" + LayoutNGBlockFlow {P} at (0,89.16) size 784x172 [bgcolor=#EEEEEE] [border: (1px solid #000000)] + LayoutInline {<pseudo:first-letter>} at (0,0) size 54x86 [color=#008000] [border: (1px dashed #008000)] + LayoutTextFragment (anonymous) at (2,2) size 52x84 + text run at (2,2) width 52: "H" + LayoutTextFragment {#text} at (55,48) size 782x122 + text run at (55,48) width 726: "ere is the first paragraph. Here the CSS :first-line rule sets the text to" + text run at (1,87) width 773: "a green, sans-serif font. Then, the CSS :first-letter rule sets the font size to 3em," + text run at (1,115) width 782: "and makes the text bold. And here's some more text to pad out the paragraph and" + text run at (1,143) width 682: "make things look nice (or, at least, to illustrate the problem correctly)." + LayoutNGBlockFlow {P} at (0,285.16) size 784x142 [bgcolor=#EEEEEE] [border: (1px solid #000000)] + LayoutNGBlockFlow (floating) {<pseudo:first-letter>} at (1,1) size 54x88 [color=#008000] [border: (1px dashed #008000)] + LayoutTextFragment (anonymous) at (1,2) size 52x84 + text run at (1,2) width 52: "H" + LayoutTextFragment {#text} at (55,1) size 768x139 + text run at (55,1) width 714: "ere is the second paragraph. This is just like the first except that the" + text run at (55,29) width 680: "rule p.floated:first-letter floats the first letter to the left. However, this" + text run at (55,57) width 683: "floated element should still inherit the font properties (green and sans-" + text run at (55,85) width 702: "serif) from the first-line: selector. It does not -- instead, the font is black," + text run at (1,113) width 540: "and uses the serif font. .... And here's some more text ...."
diff --git a/third_party/WebKit/LayoutTests/flag-specific/enable-blink-features=LayoutNG/fast/css-generated-content/table-before-after-child-add-expected.png b/third_party/WebKit/LayoutTests/flag-specific/enable-blink-features=LayoutNG/fast/css-generated-content/table-before-after-child-add-expected.png new file mode 100644 index 0000000..57b1bbd8 --- /dev/null +++ b/third_party/WebKit/LayoutTests/flag-specific/enable-blink-features=LayoutNG/fast/css-generated-content/table-before-after-child-add-expected.png Binary files differ
diff --git a/third_party/WebKit/LayoutTests/flag-specific/enable-blink-features=LayoutNG/fast/css-generated-content/table-before-after-child-add-expected.txt b/third_party/WebKit/LayoutTests/flag-specific/enable-blink-features=LayoutNG/fast/css-generated-content/table-before-after-child-add-expected.txt new file mode 100644 index 0000000..3cb86c32 --- /dev/null +++ b/third_party/WebKit/LayoutTests/flag-specific/enable-blink-features=LayoutNG/fast/css-generated-content/table-before-after-child-add-expected.txt
@@ -0,0 +1,26 @@ +layer at (0,0) size 800x600 + LayoutView at (0,0) size 800x600 +layer at (0,0) size 800x600 + LayoutNGBlockFlow {HTML} at (0,0) size 800x600 + LayoutNGBlockFlow {BODY} at (8,8) size 784x584 [color=#FF0000] + LayoutNGBlockFlow {P} at (0,0) size 784x20 + LayoutText {#text} at (0,0) size 368x19 + text run at (0,0) width 368: "Should say \x{201C}BEFORE CONTENT AFTER CONTENT\x{201D}" + LayoutTable {DIV} at (0,36) size 77x60 + LayoutTableSection (anonymous) at (0,0) size 77x60 + LayoutTableRow (anonymous) at (0,0) size 77x60 + LayoutTableCell (anonymous) at (0,0) size 77x60 [r=0 c=0 rs=1 cs=1] + LayoutNGBlockFlow (anonymous) at (0,0) size 77x20 + LayoutInline {<pseudo:before>} at (0,0) size 63x19 + LayoutTextFragment (anonymous) at (0,0) size 63x19 + text run at (0,0) width 63: "BEFORE" + LayoutNGBlockFlow {DIV} at (0,20) size 77x20 + LayoutText {#text} at (0,0) size 77x19 + text run at (0,0) width 77: "CONTENT" + LayoutNGBlockFlow (anonymous) at (0,40) size 77x20 + LayoutInline {<pseudo:after>} at (0,0) size 52x19 + LayoutTextFragment (anonymous) at (0,0) size 52x19 + text run at (0,0) width 52: "AFTER" + LayoutNGBlockFlow (anonymous) at (0,96) size 784x20 + LayoutText {#text} at (0,0) size 77x19 + text run at (0,0) width 77: "CONTENT"
diff --git a/third_party/WebKit/LayoutTests/flag-specific/enable-blink-features=LayoutNG/fast/css-generated-content/table-cell-before-after-child-add-expected.png b/third_party/WebKit/LayoutTests/flag-specific/enable-blink-features=LayoutNG/fast/css-generated-content/table-cell-before-after-child-add-expected.png new file mode 100644 index 0000000..cb6bec338 --- /dev/null +++ b/third_party/WebKit/LayoutTests/flag-specific/enable-blink-features=LayoutNG/fast/css-generated-content/table-cell-before-after-child-add-expected.png Binary files differ
diff --git a/third_party/WebKit/LayoutTests/flag-specific/enable-blink-features=LayoutNG/fast/css-generated-content/table-cell-before-after-child-add-expected.txt b/third_party/WebKit/LayoutTests/flag-specific/enable-blink-features=LayoutNG/fast/css-generated-content/table-cell-before-after-child-add-expected.txt new file mode 100644 index 0000000..368b70f --- /dev/null +++ b/third_party/WebKit/LayoutTests/flag-specific/enable-blink-features=LayoutNG/fast/css-generated-content/table-cell-before-after-child-add-expected.txt
@@ -0,0 +1,24 @@ +layer at (0,0) size 800x600 + LayoutView at (0,0) size 800x600 +layer at (0,0) size 800x600 + LayoutNGBlockFlow {HTML} at (0,0) size 800x600 + LayoutNGBlockFlow {BODY} at (8,8) size 784x584 [color=#FF0000] + LayoutNGBlockFlow {P} at (0,0) size 784x20 + LayoutText {#text} at (0,0) size 368x19 + text run at (0,0) width 368: "Should say \x{201C}BEFORE CONTENT AFTER CONTENT\x{201D}" + LayoutTable {DIV} at (0,36) size 192x20 + LayoutTableSection (anonymous) at (0,0) size 192x20 + LayoutTableRow (anonymous) at (0,0) size 192x20 + LayoutNGTableCell {<pseudo:before>} at (0,0) size 63x20 [r=0 c=0 rs=1 cs=1] + LayoutTextFragment (anonymous) at (0,0) size 63x19 + text run at (0,0) width 63: "BEFORE" + LayoutTableCell (anonymous) at (63,0) size 77x20 [r=0 c=1 rs=1 cs=1] + LayoutNGBlockFlow {DIV} at (0,0) size 77x20 + LayoutText {#text} at (0,0) size 77x19 + text run at (0,0) width 77: "CONTENT" + LayoutNGTableCell {<pseudo:after>} at (140,0) size 52x20 [r=0 c=2 rs=1 cs=1] + LayoutTextFragment (anonymous) at (0,0) size 52x19 + text run at (0,0) width 52: "AFTER" + LayoutNGBlockFlow (anonymous) at (0,56) size 784x20 + LayoutText {#text} at (0,0) size 77x19 + text run at (0,0) width 77: "CONTENT"
diff --git a/third_party/WebKit/LayoutTests/flag-specific/enable-blink-features=LayoutNG/fast/css-generated-content/table-row-before-after-child-add-expected.png b/third_party/WebKit/LayoutTests/flag-specific/enable-blink-features=LayoutNG/fast/css-generated-content/table-row-before-after-child-add-expected.png new file mode 100644 index 0000000..57b1bbd8 --- /dev/null +++ b/third_party/WebKit/LayoutTests/flag-specific/enable-blink-features=LayoutNG/fast/css-generated-content/table-row-before-after-child-add-expected.png Binary files differ
diff --git a/third_party/WebKit/LayoutTests/flag-specific/enable-blink-features=LayoutNG/fast/css-generated-content/table-row-before-after-child-add-expected.txt b/third_party/WebKit/LayoutTests/flag-specific/enable-blink-features=LayoutNG/fast/css-generated-content/table-row-before-after-child-add-expected.txt new file mode 100644 index 0000000..a9e5956 --- /dev/null +++ b/third_party/WebKit/LayoutTests/flag-specific/enable-blink-features=LayoutNG/fast/css-generated-content/table-row-before-after-child-add-expected.txt
@@ -0,0 +1,26 @@ +layer at (0,0) size 800x600 + LayoutView at (0,0) size 800x600 +layer at (0,0) size 800x600 + LayoutNGBlockFlow {HTML} at (0,0) size 800x600 + LayoutNGBlockFlow {BODY} at (8,8) size 784x584 [color=#FF0000] + LayoutNGBlockFlow {P} at (0,0) size 784x20 + LayoutText {#text} at (0,0) size 368x19 + text run at (0,0) width 368: "Should say \x{201C}BEFORE CONTENT AFTER CONTENT\x{201D}" + LayoutTable {DIV} at (0,36) size 77x60 + LayoutTableSection (anonymous) at (0,0) size 77x60 + LayoutTableRow {<pseudo:before>} at (0,0) size 77x20 + LayoutTableCell (anonymous) at (0,0) size 77x20 [r=0 c=0 rs=1 cs=1] + LayoutTextFragment (anonymous) at (0,0) size 63x19 + text run at (0,0) width 63: "BEFORE" + LayoutTableRow (anonymous) at (0,20) size 77x20 + LayoutTableCell (anonymous) at (0,20) size 77x20 [r=1 c=0 rs=1 cs=1] + LayoutNGBlockFlow {DIV} at (0,0) size 77x20 + LayoutText {#text} at (0,0) size 77x19 + text run at (0,0) width 77: "CONTENT" + LayoutTableRow {<pseudo:after>} at (0,40) size 77x20 + LayoutTableCell (anonymous) at (0,40) size 77x20 [r=2 c=0 rs=1 cs=1] + LayoutTextFragment (anonymous) at (0,0) size 52x19 + text run at (0,0) width 52: "AFTER" + LayoutNGBlockFlow (anonymous) at (0,96) size 784x20 + LayoutText {#text} at (0,0) size 77x19 + text run at (0,0) width 77: "CONTENT"
diff --git a/third_party/WebKit/LayoutTests/flag-specific/enable-blink-features=LayoutNG/fast/css-generated-content/table-row-group-to-inline-expected.png b/third_party/WebKit/LayoutTests/flag-specific/enable-blink-features=LayoutNG/fast/css-generated-content/table-row-group-to-inline-expected.png new file mode 100644 index 0000000..a4d9871 --- /dev/null +++ b/third_party/WebKit/LayoutTests/flag-specific/enable-blink-features=LayoutNG/fast/css-generated-content/table-row-group-to-inline-expected.png Binary files differ
diff --git a/third_party/WebKit/LayoutTests/flag-specific/enable-blink-features=LayoutNG/fast/css-generated-content/table-row-group-to-inline-expected.txt b/third_party/WebKit/LayoutTests/flag-specific/enable-blink-features=LayoutNG/fast/css-generated-content/table-row-group-to-inline-expected.txt new file mode 100644 index 0000000..29cba32 --- /dev/null +++ b/third_party/WebKit/LayoutTests/flag-specific/enable-blink-features=LayoutNG/fast/css-generated-content/table-row-group-to-inline-expected.txt
@@ -0,0 +1,21 @@ +layer at (0,0) size 800x600 + LayoutView at (0,0) size 800x600 +layer at (0,0) size 800x600 + LayoutNGBlockFlow {HTML} at (0,0) size 800x600 + LayoutNGBlockFlow {BODY} at (8,8) size 784x576 + LayoutNGBlockFlow (anonymous) at (0,0) size 784x20 + LayoutInline {SPAN} at (0,0) size 638x19 + LayoutText {#text} at (0,0) size 638x19 + text run at (0,0) width 638: "This test passes if it does not crash, and if we successfully destroy the table-section generated content." + LayoutText {#text} at (0,0) size 0x0 + LayoutBR {BR} at (638,15) size 0x0 + LayoutNGBlockFlow {UL} at (0,36) size 784x20 + LayoutNGListItem {LI} at (40,0) size 744x20 + LayoutNGListMarker (anonymous) at (-18,0) size 10x20 + LayoutText (anonymous) at (0,0) size 10x19 + text run at (0,0) width 10: "\x{2022} " + LayoutInline {<pseudo:before>} at (0,0) size 31x19 + LayoutTextFragment (anonymous) at (0,0) size 31x19 + text run at (0,0) width 31: "hello" + LayoutText {#text} at (31,0) size 21x19 + text run at (31,0) width 21: "test"
diff --git a/third_party/WebKit/LayoutTests/flag-specific/enable-blink-features=LayoutNG/fast/css-generated-content/table-row-group-with-before-expected.png b/third_party/WebKit/LayoutTests/flag-specific/enable-blink-features=LayoutNG/fast/css-generated-content/table-row-group-with-before-expected.png new file mode 100644 index 0000000..ed5813f --- /dev/null +++ b/third_party/WebKit/LayoutTests/flag-specific/enable-blink-features=LayoutNG/fast/css-generated-content/table-row-group-with-before-expected.png Binary files differ
diff --git a/third_party/WebKit/LayoutTests/flag-specific/enable-blink-features=LayoutNG/fast/css-generated-content/table-row-group-with-before-expected.txt b/third_party/WebKit/LayoutTests/flag-specific/enable-blink-features=LayoutNG/fast/css-generated-content/table-row-group-with-before-expected.txt new file mode 100644 index 0000000..05668c37 --- /dev/null +++ b/third_party/WebKit/LayoutTests/flag-specific/enable-blink-features=LayoutNG/fast/css-generated-content/table-row-group-with-before-expected.txt
@@ -0,0 +1,25 @@ +layer at (0,0) size 800x600 + LayoutView at (0,0) size 800x600 +layer at (0,0) size 800x600 + LayoutNGBlockFlow {HTML} at (0,0) size 800x600 + LayoutNGBlockFlow {BODY} at (8,8) size 784x576 + LayoutNGBlockFlow (anonymous) at (0,0) size 784x20 + LayoutInline {SPAN} at (0,0) size 220x19 + LayoutText {#text} at (0,0) size 220x19 + text run at (0,0) width 220: "This test passes if it does not crash." + LayoutText {#text} at (0,0) size 0x0 + LayoutBR {BR} at (220,15) size 0x0 + LayoutNGBlockFlow {UL} at (0,36) size 784x40 + LayoutNGListItem {LI} at (40,0) size 744x40 + LayoutNGListMarker (anonymous) at (-18,0) size 10x20 + LayoutText (anonymous) at (0,0) size 10x19 + text run at (0,0) width 10: "\x{2022} " + LayoutTable (anonymous) at (0,0) size 31x20 + LayoutTableSection {<pseudo:before>} at (0,0) size 31x20 + LayoutTableRow (anonymous) at (0,0) size 31x20 + LayoutTableCell (anonymous) at (0,0) size 31x20 [r=0 c=0 rs=1 cs=1] + LayoutTextFragment (anonymous) at (0,0) size 31x19 + text run at (0,0) width 31: "hello" + LayoutNGBlockFlow (anonymous) at (0,20) size 744x20 + LayoutText {#text} at (0,0) size 21x19 + text run at (0,0) width 21: "test"
diff --git a/third_party/WebKit/LayoutTests/flag-specific/enable-blink-features=LayoutNG/fast/css-generated-content/table-row-with-before-expected.png b/third_party/WebKit/LayoutTests/flag-specific/enable-blink-features=LayoutNG/fast/css-generated-content/table-row-with-before-expected.png new file mode 100644 index 0000000..ed5813f --- /dev/null +++ b/third_party/WebKit/LayoutTests/flag-specific/enable-blink-features=LayoutNG/fast/css-generated-content/table-row-with-before-expected.png Binary files differ
diff --git a/third_party/WebKit/LayoutTests/flag-specific/enable-blink-features=LayoutNG/fast/css-generated-content/table-row-with-before-expected.txt b/third_party/WebKit/LayoutTests/flag-specific/enable-blink-features=LayoutNG/fast/css-generated-content/table-row-with-before-expected.txt new file mode 100644 index 0000000..0284986 --- /dev/null +++ b/third_party/WebKit/LayoutTests/flag-specific/enable-blink-features=LayoutNG/fast/css-generated-content/table-row-with-before-expected.txt
@@ -0,0 +1,25 @@ +layer at (0,0) size 800x600 + LayoutView at (0,0) size 800x600 +layer at (0,0) size 800x600 + LayoutNGBlockFlow {HTML} at (0,0) size 800x600 + LayoutNGBlockFlow {BODY} at (8,8) size 784x576 + LayoutNGBlockFlow (anonymous) at (0,0) size 784x20 + LayoutInline {SPAN} at (0,0) size 220x19 + LayoutText {#text} at (0,0) size 220x19 + text run at (0,0) width 220: "This test passes if it does not crash." + LayoutText {#text} at (0,0) size 0x0 + LayoutBR {BR} at (220,15) size 0x0 + LayoutNGBlockFlow {UL} at (0,36) size 784x40 + LayoutNGListItem {LI} at (40,0) size 744x40 + LayoutNGListMarker (anonymous) at (-18,0) size 10x20 + LayoutText (anonymous) at (0,0) size 10x19 + text run at (0,0) width 10: "\x{2022} " + LayoutTable (anonymous) at (0,0) size 31x20 + LayoutTableSection (anonymous) at (0,0) size 31x20 + LayoutTableRow {<pseudo:before>} at (0,0) size 31x20 + LayoutTableCell (anonymous) at (0,0) size 31x20 [r=0 c=0 rs=1 cs=1] + LayoutTextFragment (anonymous) at (0,0) size 31x19 + text run at (0,0) width 31: "hello" + LayoutNGBlockFlow (anonymous) at (0,20) size 744x20 + LayoutText {#text} at (0,0) size 21x19 + text run at (0,0) width 21: "test"
diff --git a/third_party/WebKit/LayoutTests/flag-specific/enable-blink-features=LayoutNG/fast/css-generated-content/table-table-before-after-child-add-expected.png b/third_party/WebKit/LayoutTests/flag-specific/enable-blink-features=LayoutNG/fast/css-generated-content/table-table-before-after-child-add-expected.png new file mode 100644 index 0000000..57b1bbd8 --- /dev/null +++ b/third_party/WebKit/LayoutTests/flag-specific/enable-blink-features=LayoutNG/fast/css-generated-content/table-table-before-after-child-add-expected.png Binary files differ
diff --git a/third_party/WebKit/LayoutTests/flag-specific/enable-blink-features=LayoutNG/fast/css-generated-content/table-table-before-after-child-add-expected.txt b/third_party/WebKit/LayoutTests/flag-specific/enable-blink-features=LayoutNG/fast/css-generated-content/table-table-before-after-child-add-expected.txt new file mode 100644 index 0000000..e338b9b --- /dev/null +++ b/third_party/WebKit/LayoutTests/flag-specific/enable-blink-features=LayoutNG/fast/css-generated-content/table-table-before-after-child-add-expected.txt
@@ -0,0 +1,30 @@ +layer at (0,0) size 800x600 + LayoutView at (0,0) size 800x600 +layer at (0,0) size 800x600 + LayoutNGBlockFlow {HTML} at (0,0) size 800x600 + LayoutNGBlockFlow {BODY} at (8,8) size 784x584 [color=#FF0000] + LayoutNGBlockFlow {P} at (0,0) size 784x20 + LayoutText {#text} at (0,0) size 368x19 + text run at (0,0) width 368: "Should say \x{201C}BEFORE CONTENT AFTER CONTENT\x{201D}" + LayoutTable {DIV} at (0,36) size 77x60 + LayoutTableSection (anonymous) at (0,0) size 77x60 + LayoutTableRow (anonymous) at (0,0) size 77x60 + LayoutTableCell (anonymous) at (0,0) size 77x60 [r=0 c=0 rs=1 cs=1] + LayoutTable {<pseudo:before>} at (0,0) size 63x20 + LayoutTableSection (anonymous) at (0,0) size 63x20 + LayoutTableRow (anonymous) at (0,0) size 63x20 + LayoutTableCell (anonymous) at (0,0) size 63x20 [r=0 c=0 rs=1 cs=1] + LayoutTextFragment (anonymous) at (0,0) size 63x19 + text run at (0,0) width 63: "BEFORE" + LayoutNGBlockFlow {DIV} at (0,20) size 77x20 + LayoutText {#text} at (0,0) size 77x19 + text run at (0,0) width 77: "CONTENT" + LayoutTable {<pseudo:after>} at (0,40) size 52x20 + LayoutTableSection (anonymous) at (0,0) size 52x20 + LayoutTableRow (anonymous) at (0,0) size 52x20 + LayoutTableCell (anonymous) at (0,0) size 52x20 [r=0 c=0 rs=1 cs=1] + LayoutTextFragment (anonymous) at (0,0) size 52x19 + text run at (0,0) width 52: "AFTER" + LayoutNGBlockFlow (anonymous) at (0,96) size 784x20 + LayoutText {#text} at (0,0) size 77x19 + text run at (0,0) width 77: "CONTENT"
diff --git a/third_party/WebKit/LayoutTests/flag-specific/enable-blink-features=LayoutNG/fast/css-generated-content/table-with-before-expected.png b/third_party/WebKit/LayoutTests/flag-specific/enable-blink-features=LayoutNG/fast/css-generated-content/table-with-before-expected.png new file mode 100644 index 0000000..ed5813f --- /dev/null +++ b/third_party/WebKit/LayoutTests/flag-specific/enable-blink-features=LayoutNG/fast/css-generated-content/table-with-before-expected.png Binary files differ
diff --git a/third_party/WebKit/LayoutTests/flag-specific/enable-blink-features=LayoutNG/fast/css-generated-content/table-with-before-expected.txt b/third_party/WebKit/LayoutTests/flag-specific/enable-blink-features=LayoutNG/fast/css-generated-content/table-with-before-expected.txt new file mode 100644 index 0000000..1fdaf399 --- /dev/null +++ b/third_party/WebKit/LayoutTests/flag-specific/enable-blink-features=LayoutNG/fast/css-generated-content/table-with-before-expected.txt
@@ -0,0 +1,25 @@ +layer at (0,0) size 800x600 + LayoutView at (0,0) size 800x600 +layer at (0,0) size 800x600 + LayoutNGBlockFlow {HTML} at (0,0) size 800x600 + LayoutNGBlockFlow {BODY} at (8,8) size 784x576 + LayoutNGBlockFlow (anonymous) at (0,0) size 784x20 + LayoutInline {SPAN} at (0,0) size 220x19 + LayoutText {#text} at (0,0) size 220x19 + text run at (0,0) width 220: "This test passes if it does not crash." + LayoutText {#text} at (0,0) size 0x0 + LayoutBR {BR} at (220,15) size 0x0 + LayoutNGBlockFlow {UL} at (0,36) size 784x40 + LayoutNGListItem {LI} at (40,0) size 744x40 + LayoutNGListMarker (anonymous) at (-18,0) size 10x20 + LayoutText (anonymous) at (0,0) size 10x19 + text run at (0,0) width 10: "\x{2022} " + LayoutTable {<pseudo:before>} at (0,0) size 31x20 + LayoutTableSection (anonymous) at (0,0) size 31x20 + LayoutTableRow (anonymous) at (0,0) size 31x20 + LayoutTableCell (anonymous) at (0,0) size 31x20 [r=0 c=0 rs=1 cs=1] + LayoutTextFragment (anonymous) at (0,0) size 31x19 + text run at (0,0) width 31: "hello" + LayoutNGBlockFlow (anonymous) at (0,20) size 744x20 + LayoutText {#text} at (0,0) size 21x19 + text run at (0,0) width 21: "test"
diff --git a/third_party/WebKit/LayoutTests/flag-specific/enable-blink-features=LayoutNG/fast/forms/suggestion-picker/datetimelocal-suggestion-picker-appearance-expected.png b/third_party/WebKit/LayoutTests/flag-specific/enable-blink-features=LayoutNG/fast/forms/suggestion-picker/datetimelocal-suggestion-picker-appearance-expected.png new file mode 100644 index 0000000..f2d1227c --- /dev/null +++ b/third_party/WebKit/LayoutTests/flag-specific/enable-blink-features=LayoutNG/fast/forms/suggestion-picker/datetimelocal-suggestion-picker-appearance-expected.png Binary files differ
diff --git a/third_party/WebKit/LayoutTests/flag-specific/enable-blink-features=LayoutNG/tables/mozilla/bugs/bug126742-expected.png b/third_party/WebKit/LayoutTests/flag-specific/enable-blink-features=LayoutNG/tables/mozilla/bugs/bug126742-expected.png new file mode 100644 index 0000000..fd5aede --- /dev/null +++ b/third_party/WebKit/LayoutTests/flag-specific/enable-blink-features=LayoutNG/tables/mozilla/bugs/bug126742-expected.png Binary files differ
diff --git a/third_party/WebKit/LayoutTests/http/tests/devtools/elements/css-variables/color-swatch-expected.txt b/third_party/WebKit/LayoutTests/http/tests/devtools/elements/css-variables/color-swatch-expected.txt new file mode 100644 index 0000000..a7e41fa --- /dev/null +++ b/third_party/WebKit/LayoutTests/http/tests/devtools/elements/css-variables/color-swatch-expected.txt
@@ -0,0 +1,8 @@ +Verify that swatches for var() functions are updated as CSS variable is changed. +Before css Variable editing: + "color" swatch:red + "background-color" swatch:red +After css Variable editing: + "color" swatch:blue + "background-color" swatch:blue +
diff --git a/third_party/WebKit/LayoutTests/http/tests/devtools/elements/css-variables/color-swatch.js b/third_party/WebKit/LayoutTests/http/tests/devtools/elements/css-variables/color-swatch.js new file mode 100644 index 0000000..a7e2819 --- /dev/null +++ b/third_party/WebKit/LayoutTests/http/tests/devtools/elements/css-variables/color-swatch.js
@@ -0,0 +1,49 @@ +// Copyright 2018 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. + +(async function() { + TestRunner.addResult( + `Verify that swatches for var() functions are updated as CSS variable is changed.`); + await TestRunner.loadModule('elements_test_runner'); + await TestRunner.showPanel('elements'); + await TestRunner.loadHTML(` + <style> + div { + color: var(--bar); + --bar: var(--baz); + --baz: red; + } + + #inspected { + background-color: var(--bar); + } + </style> + <div id="inspected"></div> + `); + + await ElementsTestRunner.selectNodeAndWaitForStylesPromise('inspected'); + TestRunner.addResult('Before css Variable editing:' ); + dumpSwatches(); + + const bazTreeElement = ElementsTestRunner.getMatchedStylePropertyTreeItem('--baz'); + bazTreeElement.startEditing(bazTreeElement.valueElement); + bazTreeElement.valueElement.textContent = 'blue'; + bazTreeElement.kickFreeFlowStyleEditForTest(); + await ElementsTestRunner.waitForStyleAppliedPromise(); + + TestRunner.addResult('After css Variable editing:' ); + dumpSwatches(); + + TestRunner.completeTest(); + + function dumpSwatches() { + const colorTreeElement = ElementsTestRunner.getMatchedStylePropertyTreeItem('color'); + let swatch = colorTreeElement.valueElement.querySelector('span[is=color-swatch]'); + TestRunner.addResult(' "color" swatch:' + swatch.color().asString()); + + const bgTreeElement = ElementsTestRunner.getMatchedStylePropertyTreeItem('background-color'); + swatch = bgTreeElement.valueElement.querySelector('span[is=color-swatch]'); + TestRunner.addResult(' "background-color" swatch:' + swatch.color().asString()); + } +})();
diff --git a/third_party/WebKit/LayoutTests/platform/linux/editing/deleting/merge-whitespace-pre-expected.png b/third_party/WebKit/LayoutTests/platform/linux/editing/deleting/merge-whitespace-pre-expected.png deleted file mode 100644 index 978a14c..0000000 --- a/third_party/WebKit/LayoutTests/platform/linux/editing/deleting/merge-whitespace-pre-expected.png +++ /dev/null Binary files differ
diff --git a/third_party/WebKit/LayoutTests/platform/linux/editing/deleting/merge-whitespace-pre-expected.txt b/third_party/WebKit/LayoutTests/platform/linux/editing/deleting/merge-whitespace-pre-expected.txt deleted file mode 100644 index 42c6a1a..0000000 --- a/third_party/WebKit/LayoutTests/platform/linux/editing/deleting/merge-whitespace-pre-expected.txt +++ /dev/null
@@ -1,18 +0,0 @@ -layer at (0,0) size 800x600 - LayoutView at (0,0) size 800x600 -layer at (0,0) size 800x600 - LayoutBlockFlow {HTML} at (0,0) size 800x600 - LayoutBlockFlow {BODY} at (8,8) size 784x579 - LayoutBlockFlow {P} at (0,0) size 784x40 - LayoutText {#text} at (0,0) size 743x39 - text run at (0,0) width 364: "This test places the caret before the 'b' in 'bar' and Delete. " - text run at (364,0) width 379: "Afterword, 'foobar' should be in the first paragraph and 'baz'" - text run at (0,20) width 152: "should be in the second." - LayoutBlockFlow {DIV} at (0,56) size 784x49 - LayoutBlockFlow {DIV} at (0,0) size 784x20 - LayoutText {#text} at (0,0) size 41x19 - text run at (0,0) width 41: "foobar" - LayoutBlockFlow {PRE} at (0,33) size 784x16 - LayoutText {#text} at (0,0) size 24x16 - text run at (0,0) width 24: "baz" -caret: position 3 of child 0 {#text} of child 1 {DIV} of child 2 {DIV} of body
diff --git a/third_party/WebKit/LayoutTests/platform/linux/editing/inserting/4875189-1-expected.png b/third_party/WebKit/LayoutTests/platform/linux/editing/inserting/4875189-1-expected.png deleted file mode 100644 index 441ebbf..0000000 --- a/third_party/WebKit/LayoutTests/platform/linux/editing/inserting/4875189-1-expected.png +++ /dev/null Binary files differ
diff --git a/third_party/WebKit/LayoutTests/platform/linux/editing/inserting/4875189-1-expected.txt b/third_party/WebKit/LayoutTests/platform/linux/editing/inserting/4875189-1-expected.txt deleted file mode 100644 index 4ea523d..0000000 --- a/third_party/WebKit/LayoutTests/platform/linux/editing/inserting/4875189-1-expected.txt +++ /dev/null
@@ -1,16 +0,0 @@ -layer at (0,0) size 800x600 - LayoutView at (0,0) size 800x600 -layer at (0,0) size 800x600 - LayoutBlockFlow {HTML} at (0,0) size 800x600 - LayoutBlockFlow {BODY} at (8,8) size 784x576 - LayoutBlockFlow {P} at (0,0) size 784x20 - LayoutText {#text} at (0,0) size 652x19 - text run at (0,0) width 358: "This tests for a bug when replacing the contents of a list. " - text run at (358,0) width 294: "The list shouldn't be removed, just its contents." - LayoutBlockFlow {DIV} at (0,36) size 784x20 - LayoutBlockFlow {UL} at (0,0) size 784x20 - LayoutListItem {LI} at (40,0) size 744x20 - LayoutListMarker (anonymous) at (-18,0) size 7x19: bullet - LayoutText {#text} at (0,0) size 177x19 - text run at (0,0) width 177: "This should be in a list item." -caret: position 30 of child 0 {#text} of child 0 {LI} of child 0 {UL} of child 2 {DIV} of body
diff --git a/third_party/WebKit/LayoutTests/platform/linux/editing/inserting/4959067-expected.png b/third_party/WebKit/LayoutTests/platform/linux/editing/inserting/4959067-expected.png deleted file mode 100644 index cc1db1c5..0000000 --- a/third_party/WebKit/LayoutTests/platform/linux/editing/inserting/4959067-expected.png +++ /dev/null Binary files differ
diff --git a/third_party/WebKit/LayoutTests/platform/linux/editing/inserting/4959067-expected.txt b/third_party/WebKit/LayoutTests/platform/linux/editing/inserting/4959067-expected.txt deleted file mode 100644 index 91dcfea..0000000 --- a/third_party/WebKit/LayoutTests/platform/linux/editing/inserting/4959067-expected.txt +++ /dev/null
@@ -1,17 +0,0 @@ -layer at (0,0) size 800x600 - LayoutView at (0,0) size 800x600 -layer at (0,0) size 800x600 - LayoutBlockFlow {HTML} at (0,0) size 800x600 - LayoutBlockFlow {BODY} at (8,8) size 784x576 - LayoutBlockFlow {P} at (0,0) size 784x20 - LayoutText {#text} at (0,0) size 598x19 - text run at (0,0) width 598: "This tests to make sure that insertion over a fully selected special element doesn't do expansion." - LayoutBlockFlow {DIV} at (0,36) size 784x20 - LayoutBlockFlow {UL} at (0,0) size 784x20 - LayoutListItem {LI} at (40,0) size 744x20 - LayoutListMarker (anonymous) at (-18,0) size 7x19: bullet - LayoutInline {A} at (0,0) size 21x19 [color=#0000EE] - LayoutText {#text} at (0,0) size 21x19 - text run at (0,0) width 21: "foo" - LayoutBlockFlow {UL} at (0,72) size 784x0 -caret: position 3 of child 0 {#text} of child 0 {A} of child 0 {LI} of child 1 {UL} of child 2 {DIV} of body
diff --git a/third_party/WebKit/LayoutTests/platform/linux/editing/inserting/editable-inline-element-expected.png b/third_party/WebKit/LayoutTests/platform/linux/editing/inserting/editable-inline-element-expected.png deleted file mode 100644 index 2afd6b03..0000000 --- a/third_party/WebKit/LayoutTests/platform/linux/editing/inserting/editable-inline-element-expected.png +++ /dev/null Binary files differ
diff --git a/third_party/WebKit/LayoutTests/platform/linux/editing/inserting/editable-inline-element-expected.txt b/third_party/WebKit/LayoutTests/platform/linux/editing/inserting/editable-inline-element-expected.txt deleted file mode 100644 index f6e9d0d..0000000 --- a/third_party/WebKit/LayoutTests/platform/linux/editing/inserting/editable-inline-element-expected.txt +++ /dev/null
@@ -1,14 +0,0 @@ -layer at (0,0) size 800x600 - LayoutView at (0,0) size 800x600 -layer at (0,0) size 800x600 - LayoutBlockFlow {HTML} at (0,0) size 800x600 - LayoutBlockFlow {BODY} at (8,8) size 784x584 - LayoutBlockFlow {P} at (0,0) size 784x20 - LayoutText {#text} at (0,0) size 371x19 - text run at (0,0) width 371: "This tests InsertParagraph inside an editable inline element." - LayoutBlockFlow {DIV} at (0,36) size 784x42 [border: (1px solid #FF0000)] - LayoutInline {SPAN} at (0,0) size 21x39 - LayoutBR {BR} at (1,1) size 0x19 - LayoutText {#text} at (1,21) size 21x19 - text run at (1,21) width 21: "foo" -caret: position 0 of child 1 {#text} of child 0 {SPAN} of child 2 {DIV} of body
diff --git a/third_party/WebKit/LayoutTests/platform/linux/editing/selection/focus-body-expected.png b/third_party/WebKit/LayoutTests/platform/linux/editing/selection/focus-body-expected.png deleted file mode 100644 index 9b27e5f..0000000 --- a/third_party/WebKit/LayoutTests/platform/linux/editing/selection/focus-body-expected.png +++ /dev/null Binary files differ
diff --git a/third_party/WebKit/LayoutTests/platform/linux/editing/selection/focus-body-expected.txt b/third_party/WebKit/LayoutTests/platform/linux/editing/selection/focus-body-expected.txt deleted file mode 100644 index e527da5..0000000 --- a/third_party/WebKit/LayoutTests/platform/linux/editing/selection/focus-body-expected.txt +++ /dev/null
@@ -1,10 +0,0 @@ -EDITING DELEGATE: webViewDidChangeSelection:WebViewDidChangeSelectionNotification -layer at (0,0) size 800x600 - LayoutView at (0,0) size 800x600 -layer at (0,0) size 800x600 - LayoutBlockFlow {HTML} at (0,0) size 800x600 - LayoutBlockFlow {BODY} at (8,8) size 784x584 - LayoutText {#text} at (0,0) size 436x19 - text run at (0,0) width 218: "This test focuses an editable body. " - text run at (218,0) width 218: "Its contents should not be selected." -caret: position 0 of child 0 {#text} of body
diff --git a/third_party/WebKit/LayoutTests/platform/linux/fast/multicol/border-radius-clipped-layer-second-column-expected.txt b/third_party/WebKit/LayoutTests/platform/linux/fast/multicol/border-radius-clipped-layer-second-column-expected.txt deleted file mode 100644 index 20e5b24..0000000 --- a/third_party/WebKit/LayoutTests/platform/linux/fast/multicol/border-radius-clipped-layer-second-column-expected.txt +++ /dev/null
@@ -1,26 +0,0 @@ -layer at (0,0) size 800x600 - LayoutView at (0,0) size 800x600 -layer at (0,0) size 800x248 - LayoutBlockFlow {HTML} at (0,0) size 800x248 - LayoutBlockFlow {BODY} at (8,16) size 784x224 - LayoutBlockFlow {P} at (0,0) size 784x40 - LayoutText {#text} at (0,0) size 719x39 - text run at (0,0) width 604: "The word 'PASS' should be seen below on the right hand side, inside a rounded box with black " - text run at (603,0) width 116: "border and yellow" - text run at (0,20) width 79: "background." -layer at (8,72) size 784x168 - LayoutBlockFlow {DIV} at (0,56) size 784x168 - LayoutMultiColumnSet (anonymous) at (0,0) size 784x168 -layer at (8,72) size 392x264 - LayoutMultiColumnFlowThread (anonymous) at (0,0) size 392x264 - LayoutBlockFlow (anonymous) at (0,0) size 392x200 - LayoutBR {BR} at (0,6) size 0x19 - LayoutBR {BR} at (0,38) size 0x19 - LayoutBR {BR} at (0,70) size 0x19 - LayoutBR {BR} at (0,102) size 0x19 - LayoutBR {BR} at (0,134) size 0x19 - LayoutBR {BR} at (0,174) size 0x19 -layer at (8,272) size 392x64 clip at (24,288) size 360x32 - LayoutBlockFlow (relative positioned) {DIV} at (0,200) size 392x64 [bgcolor=#FFFF00] [border: (16px solid #000000)] - LayoutText {#text} at (177,22) size 38x19 - text run at (177,22) width 38: "PASS"
diff --git a/third_party/WebKit/LayoutTests/platform/linux/fast/multicol/composited-inner-multicol-expected.txt b/third_party/WebKit/LayoutTests/platform/linux/fast/multicol/composited-inner-multicol-expected.txt deleted file mode 100644 index 7b105a91..0000000 --- a/third_party/WebKit/LayoutTests/platform/linux/fast/multicol/composited-inner-multicol-expected.txt +++ /dev/null
@@ -1,44 +0,0 @@ -layer at (0,0) size 800x600 - LayoutView at (0,0) size 800x600 -layer at (0,0) size 800x208 - LayoutBlockFlow {HTML} at (0,0) size 800x208 - LayoutBlockFlow {BODY} at (8,16) size 784x184 - LayoutBlockFlow {P} at (0,0) size 784x40 - LayoutText {#text} at (0,0) size 754x39 - text run at (0,0) width 614: "Below you should see the word 'PASS' (with some extra letter spacing), on a yellow background " - text run at (613,0) width 141: "(which should be a bit" - text run at (0,20) width 694: "faded near the top). The first S is below the A, because they composite together and hence are not fragmented." -layer at (8,72) size 480x128 - LayoutBlockFlow {DIV} at (0,56) size 480x128 - LayoutMultiColumnSet (anonymous) at (0,0) size 480x128 -layer at (8,72) size 240x224 - LayoutMultiColumnFlowThread (anonymous) at (0,0) size 240x224 - LayoutBlockFlow (anonymous) at (0,0) size 240x160 - LayoutBR {BR} at (0,6) size 0x19 - LayoutBR {BR} at (0,38) size 0x19 - LayoutBR {BR} at (0,70) size 0x19 - LayoutBR {BR} at (0,102) size 0x19 - LayoutBR {BR} at (0,134) size 0x19 -layer at (16,240) size 80x48 - LayoutBlockFlow {DIV} at (8,168) size 80x48 [bgcolor=#FFFF00] - LayoutMultiColumnSet (anonymous) at (8,8) size 64x32 -layer at (24,248) size 16x128 - LayoutMultiColumnFlowThread (anonymous) at (8,8) size 16x128 - LayoutBlockFlow (anonymous) at (0,0) size 16x32 - LayoutText {#text} at (0,6) size 9x19 - text run at (0,6) width 9: "P" - LayoutBR {BR} at (9,6) size 0x19 - LayoutBlockFlow (anonymous) at (0,96) size 16x32 - LayoutText {#text} at (0,6) size 9x19 - text run at (0,6) width 9: "S" - LayoutBR {BR} at (9,6) size 0x19 -layer at (240,72) size 112x53 transparent - LayoutBlockFlow (positioned) {DIV} at (240,72) size 112x52.80 [bgcolor=#FFFFFF] -layer at (24,280) size 16x64 - LayoutBlockFlow (relative positioned) {DIV} at (0,32) size 16x64 - LayoutText {#text} at (0,6) size 12x19 - text run at (0,6) width 12: "A" - LayoutBR {BR} at (12,6) size 0x19 - LayoutText {#text} at (0,38) size 9x19 - text run at (0,38) width 9: "S" - LayoutBR {BR} at (9,38) size 0x19
diff --git a/third_party/WebKit/LayoutTests/platform/linux/fast/multicol/composited-layer-multiple-fragments-expected.txt b/third_party/WebKit/LayoutTests/platform/linux/fast/multicol/composited-layer-multiple-fragments-expected.txt deleted file mode 100644 index fd2c790..0000000 --- a/third_party/WebKit/LayoutTests/platform/linux/fast/multicol/composited-layer-multiple-fragments-expected.txt +++ /dev/null
@@ -1,43 +0,0 @@ -layer at (0,0) size 800x600 - LayoutView at (0,0) size 800x600 -layer at (0,0) size 800x320 - LayoutBlockFlow {HTML} at (0,0) size 800x320 - LayoutBlockFlow {BODY} at (8,16) size 784x256 - LayoutBlockFlow {P} at (0,0) size 784x40 - LayoutText {#text} at (0,0) size 728x39 - text run at (0,0) width 728: "If no compositing were present, there should be two green squares below. Since some elements are composited, and" - text run at (0,20) width 301: "therefore not fragmented, the output is different." -layer at (8,104) size 60x60 - LayoutBlockFlow {DIV} at (0,88) size 60x60 - LayoutMultiColumnSet (anonymous) at (0,0) size 60x60 -layer at (8,104) size 20x180 - LayoutMultiColumnFlowThread (anonymous) at (0,0) size 20x180 - LayoutBlockFlow {DIV} at (0,0) size 20x20 [bgcolor=#008000] - LayoutBlockFlow {DIV} at (0,20) size 20x20 [bgcolor=#008000] - LayoutBlockFlow {DIV} at (0,80) size 20x20 [bgcolor=#008000] - LayoutBlockFlow {DIV} at (0,140) size 20x20 [bgcolor=#008000] - LayoutBlockFlow {DIV} at (0,160) size 20x20 [bgcolor=#008000] -layer at (8,212) size 60x60 - LayoutBlockFlow {DIV} at (0,196) size 60x60 - LayoutMultiColumnSet (anonymous) at (0,0) size 60x60 -layer at (8,212) size 20x180 - LayoutMultiColumnFlowThread (anonymous) at (0,0) size 20x180 - LayoutBlockFlow {DIV} at (0,0) size 20x20 [bgcolor=#008000] - LayoutBlockFlow {DIV} at (0,20) size 20x20 [bgcolor=#008000] - LayoutBlockFlow {DIV} at (0,140) size 20x20 [bgcolor=#008000] - LayoutBlockFlow {DIV} at (0,160) size 20x20 [bgcolor=#008000] -layer at (8,144) size 20x40 - LayoutBlockFlow {DIV} at (0,40) size 20x40 - LayoutBlockFlow {DIV} at (0,0) size 20x20 [bgcolor=#008000] - LayoutBlockFlow {DIV} at (0,20) size 20x20 [bgcolor=#008000] -layer at (8,204) size 20x40 - LayoutBlockFlow {DIV} at (0,100) size 20x40 - LayoutBlockFlow {DIV} at (0,0) size 20x20 [bgcolor=#008000] - LayoutBlockFlow {DIV} at (0,20) size 20x20 [bgcolor=#008000] -layer at (8,252) size 20x100 - LayoutBlockFlow {DIV} at (0,40) size 20x100 - LayoutBlockFlow {DIV} at (0,0) size 20x20 [bgcolor=#008000] - LayoutBlockFlow {DIV} at (0,20) size 20x20 [bgcolor=#008000] - LayoutBlockFlow {DIV} at (0,40) size 20x20 [bgcolor=#008000] - LayoutBlockFlow {DIV} at (0,60) size 20x20 [bgcolor=#008000] - LayoutBlockFlow {DIV} at (0,80) size 20x20 [bgcolor=#008000]
diff --git a/third_party/WebKit/LayoutTests/platform/linux/fast/multicol/composited-layer-multiple-fragments-translated-expected.txt b/third_party/WebKit/LayoutTests/platform/linux/fast/multicol/composited-layer-multiple-fragments-translated-expected.txt deleted file mode 100644 index 13cde22..0000000 --- a/third_party/WebKit/LayoutTests/platform/linux/fast/multicol/composited-layer-multiple-fragments-translated-expected.txt +++ /dev/null
@@ -1,27 +0,0 @@ -layer at (0,0) size 800x600 - LayoutView at (0,0) size 800x600 -layer at (0,0) size 800x140 - LayoutBlockFlow {HTML} at (0,0) size 800x140 - LayoutBlockFlow {BODY} at (8,16) size 784x116 - LayoutBlockFlow {P} at (0,0) size 784x40 - LayoutText {#text} at (0,0) size 779x39 - text run at (0,0) width 779: "There should be two small green squares vertically aligned below, and another red square to the top-right. The second green" - text run at (0,20) width 535: "square does not overlap the red because it is conmposited, and hence not fragmented." -layer at (8,72) size 60x60 - LayoutBlockFlow {DIV} at (0,56) size 60x60 - LayoutMultiColumnSet (anonymous) at (0,0) size 60x60 -layer at (8,72) size 20x180 - LayoutMultiColumnFlowThread (anonymous) at (0,0) size 20x180 - LayoutBlockFlow (anonymous) at (0,0) size 20x100 - LayoutBR {BR} at (0,0) size 0x19 - LayoutBR {BR} at (0,20) size 0x19 - LayoutBR {BR} at (0,40) size 0x19 - LayoutBR {BR} at (0,60) size 0x19 - LayoutBR {BR} at (0,80) size 0x19 - LayoutBlockFlow {DIV} at (0,160) size 20x20 [bgcolor=#FF0000] -layer at (8,172) size 20x60 - LayoutBlockFlow {DIV} at (0,100) size 20x60 - LayoutBlockFlow {DIV} at (0,0) size 20x20 [bgcolor=#008000] - LayoutBlockFlow (anonymous) at (0,20) size 20x20 - LayoutBR {BR} at (0,0) size 0x19 - LayoutBlockFlow {DIV} at (0,40) size 20x20 [bgcolor=#008000]
diff --git a/third_party/WebKit/LayoutTests/platform/linux/fast/multicol/composited-layer-nested-expected.txt b/third_party/WebKit/LayoutTests/platform/linux/fast/multicol/composited-layer-nested-expected.txt deleted file mode 100644 index 18524823..0000000 --- a/third_party/WebKit/LayoutTests/platform/linux/fast/multicol/composited-layer-nested-expected.txt +++ /dev/null
@@ -1,51 +0,0 @@ -layer at (0,0) size 800x600 - LayoutView at (0,0) size 800x600 -layer at (0,0) size 800x320 - LayoutBlockFlow {HTML} at (0,0) size 800x320 - LayoutBlockFlow {BODY} at (8,16) size 784x256 - LayoutBlockFlow {P} at (0,0) size 784x40 - LayoutText {#text} at (0,0) size 728x39 - text run at (0,0) width 728: "If no compositing were present, there should be two green squares below. Since some elements are composited, and" - text run at (0,20) width 301: "therefore not fragmented, the output is different." -layer at (8,104) size 60x60 - LayoutBlockFlow {DIV} at (0,88) size 60x60 - LayoutMultiColumnSet (anonymous) at (0,0) size 60x60 -layer at (8,104) size 20x180 - LayoutMultiColumnFlowThread (anonymous) at (0,0) size 20x180 - LayoutBlockFlow {DIV} at (0,0) size 20x20 [bgcolor=#008000] - LayoutBlockFlow {DIV} at (0,100) size 20x20 [bgcolor=#008000] - LayoutBlockFlow {DIV} at (0,120) size 20x20 [bgcolor=#008000] - LayoutBlockFlow {DIV} at (0,140) size 20x20 [bgcolor=#008000] - LayoutBlockFlow {DIV} at (0,160) size 20x20 [bgcolor=#008000] -layer at (8,212) size 60x60 - LayoutBlockFlow {DIV} at (0,196) size 60x60 - LayoutMultiColumnSet (anonymous) at (0,0) size 60x60 -layer at (8,212) size 20x180 - LayoutMultiColumnFlowThread (anonymous) at (0,0) size 20x180 -layer at (8,124) size 20x80 - LayoutBlockFlow {DIV} at (0,20) size 20x80 - LayoutBlockFlow {DIV} at (0,0) size 20x20 [bgcolor=#008000] - LayoutBlockFlow {DIV} at (0,60) size 20x20 [bgcolor=#008000] -layer at (8,144) size 20x40 - LayoutBlockFlow {DIV} at (0,20) size 20x40 - LayoutBlockFlow {DIV} at (0,0) size 20x20 [bgcolor=#008000] - LayoutBlockFlow {DIV} at (0,20) size 20x20 [bgcolor=#008000] -layer at (8,212) size 20x180 - LayoutBlockFlow {DIV} at (0,0) size 20x180 - LayoutBlockFlow {DIV} at (0,80) size 20x20 [bgcolor=#008000] -layer at (8,212) size 20x80 - LayoutBlockFlow {DIV} at (0,0) size 20x80 - LayoutBlockFlow {DIV} at (0,0) size 20x20 [bgcolor=#008000] - LayoutBlockFlow {DIV} at (0,20) size 20x20 [bgcolor=#008000] -layer at (8,252) size 20x40 - LayoutBlockFlow {DIV} at (0,40) size 20x40 - LayoutBlockFlow {DIV} at (0,0) size 20x20 [bgcolor=#008000] - LayoutBlockFlow {DIV} at (0,20) size 20x20 [bgcolor=#008000] -layer at (8,312) size 20x80 - LayoutBlockFlow {DIV} at (0,100) size 20x80 - LayoutBlockFlow {DIV} at (0,40) size 20x20 [bgcolor=#008000] - LayoutBlockFlow {DIV} at (0,60) size 20x20 [bgcolor=#008000] -layer at (8,312) size 20x40 - LayoutBlockFlow {DIV} at (0,0) size 20x40 - LayoutBlockFlow {DIV} at (0,0) size 20x20 [bgcolor=#008000] - LayoutBlockFlow {DIV} at (0,20) size 20x20 [bgcolor=#008000]
diff --git a/third_party/WebKit/LayoutTests/platform/linux/fast/multicol/composited-layer-will-change-expected.txt b/third_party/WebKit/LayoutTests/platform/linux/fast/multicol/composited-layer-will-change-expected.txt deleted file mode 100644 index 3ead0cd..0000000 --- a/third_party/WebKit/LayoutTests/platform/linux/fast/multicol/composited-layer-will-change-expected.txt +++ /dev/null
@@ -1,69 +0,0 @@ -layer at (0,0) size 800x600 - LayoutView at (0,0) size 800x600 -layer at (0,0) size 800x428 - LayoutBlockFlow {HTML} at (0,0) size 800x428 - LayoutBlockFlow {BODY} at (8,16) size 784x364 - LayoutBlockFlow {P} at (0,0) size 784x40 - LayoutText {#text} at (0,0) size 728x39 - text run at (0,0) width 728: "If no compositing were present, there should be two green squares below. Since some elements are composited, and" - text run at (0,20) width 301: "therefore not fragmented, the output is different." -layer at (8,104) size 60x60 - LayoutBlockFlow {DIV} at (0,88) size 60x60 - LayoutMultiColumnSet (anonymous) at (0,0) size 60x60 -layer at (8,104) size 20x180 - LayoutMultiColumnFlowThread (anonymous) at (0,0) size 20x180 - LayoutBlockFlow {DIV} at (0,20) size 20x20 [bgcolor=#008000] - LayoutBlockFlow {DIV} at (0,80) size 20x20 [bgcolor=#008000] - LayoutBlockFlow {DIV} at (0,160) size 20x20 [bgcolor=#008000] -layer at (8,212) size 60x60 - LayoutBlockFlow {DIV} at (0,196) size 60x60 - LayoutMultiColumnSet (anonymous) at (0,0) size 60x60 -layer at (8,212) size 20x180 - LayoutMultiColumnFlowThread (anonymous) at (0,0) size 20x180 - LayoutBlockFlow {DIV} at (0,20) size 20x20 [bgcolor=#008000] - LayoutBlockFlow {DIV} at (0,80) size 20x20 [bgcolor=#008000] - LayoutBlockFlow {DIV} at (0,160) size 20x20 [bgcolor=#008000] -layer at (8,320) size 60x60 - LayoutBlockFlow {DIV} at (0,304) size 60x60 - LayoutMultiColumnSet (anonymous) at (0,0) size 60x60 -layer at (8,320) size 20x180 - LayoutMultiColumnFlowThread (anonymous) at (0,0) size 20x180 - LayoutBlockFlow {DIV} at (0,20) size 20x20 [bgcolor=#008000] - LayoutBlockFlow {DIV} at (0,80) size 20x20 [bgcolor=#008000] - LayoutBlockFlow {DIV} at (0,160) size 20x20 [bgcolor=#008000] -layer at (8,104) size 20x20 - LayoutBlockFlow {DIV} at (0,0) size 20x20 - LayoutBlockFlow {DIV} at (0,0) size 20x20 [bgcolor=#008000] -layer at (8,144) size 20x40 - LayoutBlockFlow {DIV} at (0,40) size 20x40 - LayoutBlockFlow {DIV} at (0,0) size 20x20 [bgcolor=#008000] - LayoutBlockFlow {DIV} at (0,20) size 20x20 [bgcolor=#008000] -layer at (8,204) size 20x60 - LayoutBlockFlow {DIV} at (0,100) size 20x60 - LayoutBlockFlow {DIV} at (0,0) size 20x20 [bgcolor=#008000] - LayoutBlockFlow {DIV} at (0,20) size 20x20 [bgcolor=#008000] - LayoutBlockFlow {DIV} at (0,40) size 20x20 [bgcolor=#008000] -layer at (8,212) size 20x20 - LayoutBlockFlow {DIV} at (0,0) size 20x20 - LayoutBlockFlow {DIV} at (0,0) size 20x20 [bgcolor=#008000] -layer at (8,252) size 20x40 - LayoutBlockFlow {DIV} at (0,40) size 20x40 - LayoutBlockFlow {DIV} at (0,0) size 20x20 [bgcolor=#008000] - LayoutBlockFlow {DIV} at (0,20) size 20x20 [bgcolor=#008000] -layer at (8,312) size 20x60 - LayoutBlockFlow {DIV} at (0,100) size 20x60 - LayoutBlockFlow {DIV} at (0,0) size 20x20 [bgcolor=#008000] - LayoutBlockFlow {DIV} at (0,20) size 20x20 [bgcolor=#008000] - LayoutBlockFlow {DIV} at (0,40) size 20x20 [bgcolor=#008000] -layer at (8,320) size 20x20 - LayoutBlockFlow (relative positioned) {DIV} at (0,0) size 20x20 - LayoutBlockFlow {DIV} at (0,0) size 20x20 [bgcolor=#008000] -layer at (8,360) size 20x40 - LayoutBlockFlow (relative positioned) {DIV} at (0,40) size 20x40 - LayoutBlockFlow {DIV} at (0,0) size 20x20 [bgcolor=#008000] - LayoutBlockFlow {DIV} at (0,20) size 20x20 [bgcolor=#008000] -layer at (8,420) size 20x60 - LayoutBlockFlow (relative positioned) {DIV} at (0,100) size 20x60 - LayoutBlockFlow {DIV} at (0,0) size 20x20 [bgcolor=#008000] - LayoutBlockFlow {DIV} at (0,20) size 20x20 [bgcolor=#008000] - LayoutBlockFlow {DIV} at (0,40) size 20x20 [bgcolor=#008000]
diff --git a/third_party/WebKit/LayoutTests/platform/linux/fast/multicol/composited-opacity-2nd-and-3rd-column-expected.txt b/third_party/WebKit/LayoutTests/platform/linux/fast/multicol/composited-opacity-2nd-and-3rd-column-expected.txt deleted file mode 100644 index 4cb04e2..0000000 --- a/third_party/WebKit/LayoutTests/platform/linux/fast/multicol/composited-opacity-2nd-and-3rd-column-expected.txt +++ /dev/null
@@ -1,40 +0,0 @@ -layer at (0,0) size 800x600 - LayoutView at (0,0) size 800x600 -layer at (0,0) size 800x288 - LayoutBlockFlow {HTML} at (0,0) size 800x288 - LayoutBlockFlow {BODY} at (8,16) size 784x264 - LayoutBlockFlow {P} at (0,0) size 784x40 - LayoutText {#text} at (0,0) size 211x19 - text run at (0,0) width 211: "The word 'PASS' should be seen " - LayoutInline {EM} at (0,0) size 34x19 - LayoutText {#text} at (210,0) size 34x19 - text run at (210,0) width 34: "twice" - LayoutText {#text} at (243,0) size 784x39 - text run at (243,0) width 541: " below. The second PASS is not overlapping the yellow because it is composited with" - text run at (0,20) width 249: "the first one, and hence not fragmented." -layer at (8,72) size 272x208 - LayoutBlockFlow {DIV} at (0,56) size 272x208 - LayoutMultiColumnSet (anonymous) at (0,0) size 272x208 -layer at (8,72) size 80x456 - LayoutMultiColumnFlowThread (anonymous) at (0,0) size 80x456 - LayoutBlockFlow (anonymous) at (0,0) size 80x368 - LayoutBR {BR} at (0,6) size 0x19 - LayoutBR {BR} at (0,38) size 0x19 - LayoutBR {BR} at (0,70) size 0x19 - LayoutBR {BR} at (0,102) size 0x19 - LayoutBR {BR} at (0,134) size 0x19 - LayoutBR {BR} at (0,166) size 0x19 - LayoutBR {BR} at (0,214) size 0x19 - LayoutBR {BR} at (0,246) size 0x19 - LayoutBR {BR} at (0,278) size 0x19 - LayoutBR {BR} at (0,310) size 0x19 - LayoutBR {BR} at (0,342) size 0x19 -layer at (0,72) size 800x128 - LayoutBlockFlow (positioned) {DIV} at (0,72) size 800x128 [bgcolor=#FFFF00] -layer at (16,448) size 64x72 transparent - LayoutBlockFlow {DIV} at (8,376) size 64x72 - LayoutText {#text} at (0,6) size 38x19 - text run at (0,6) width 38: "PASS" - LayoutBR {BR} at (37,6) size 1x19 - LayoutText {#text} at (0,46) size 38x19 - text run at (0,46) width 38: "PASS"
diff --git a/third_party/WebKit/LayoutTests/platform/linux/fast/multicol/composited-relpos-clipped-expected.txt b/third_party/WebKit/LayoutTests/platform/linux/fast/multicol/composited-relpos-clipped-expected.txt deleted file mode 100644 index 6578fbd..0000000 --- a/third_party/WebKit/LayoutTests/platform/linux/fast/multicol/composited-relpos-clipped-expected.txt +++ /dev/null
@@ -1,39 +0,0 @@ -layer at (0,0) size 800x600 - LayoutView at (0,0) size 800x600 -layer at (0,0) size 800x288 - LayoutBlockFlow {HTML} at (0,0) size 800x288 - LayoutBlockFlow {BODY} at (8,16) size 784x264 - LayoutBlockFlow {P} at (0,0) size 784x40 - LayoutText {#text} at (0,0) size 770x39 - text run at (0,0) width 770: "There should be one yellow boxes below, on a blue background. There is only one because the content is composited, and" - text run at (0,20) width 140: "hence not fragmented." -layer at (8,72) size 272x208 - LayoutBlockFlow {DIV} at (0,56) size 272x208 - LayoutMultiColumnSet (anonymous) at (0,0) size 272x208 -layer at (8,72) size 128x280 - LayoutMultiColumnFlowThread (anonymous) at (0,0) size 128x280 - LayoutBlockFlow (anonymous) at (0,0) size 128x128 - LayoutBR {BR} at (0,6) size 0x19 - LayoutBR {BR} at (0,38) size 0x19 - LayoutBR {BR} at (0,70) size 0x19 - LayoutBR {BR} at (0,102) size 0x19 -layer at (0,72) size 800x208 - LayoutBlockFlow (positioned) {DIV} at (0,72) size 800x208 [bgcolor=#0000FF] -layer at (16,208) size 112x136 scrollHeight 168 - LayoutBlockFlow (relative positioned) {DIV} at (8,136) size 112x136 [bgcolor=#FFFF00] - LayoutBlockFlow (anonymous) at (0,0) size 112x136 - LayoutText {#text} at (0,6) size 24x19 - text run at (0,6) width 24: "first" - LayoutBR {BR} at (24,6) size 0x19 - LayoutText {#text} at (0,38) size 47x19 - text run at (0,38) width 47: "column" - LayoutBR {BR} at (47,38) size 0x19 - LayoutText {#text} at (0,78) size 44x19 - text run at (0,78) width 44: "second" - LayoutBR {BR} at (44,78) size 0x19 - LayoutText {#text} at (0,110) size 47x19 - text run at (0,110) width 47: "column" - LayoutBR {BR} at (47,110) size 0x19 - LayoutBlockFlow {DIV} at (0,136) size 112x32 [bgcolor=#FF0000] - LayoutText {#text} at (0,6) size 35x19 - text run at (0,6) width 35: "FAIL"
diff --git a/third_party/WebKit/LayoutTests/platform/linux/fast/multicol/composited-relpos-expected.txt b/third_party/WebKit/LayoutTests/platform/linux/fast/multicol/composited-relpos-expected.txt deleted file mode 100644 index 76c4402..0000000 --- a/third_party/WebKit/LayoutTests/platform/linux/fast/multicol/composited-relpos-expected.txt +++ /dev/null
@@ -1,36 +0,0 @@ -layer at (0,0) size 800x600 - LayoutView at (0,0) size 800x600 -layer at (0,0) size 800x288 - LayoutBlockFlow {HTML} at (0,0) size 800x288 - LayoutBlockFlow {BODY} at (8,16) size 784x264 - LayoutBlockFlow {P} at (0,0) size 784x40 - LayoutText {#text} at (0,0) size 753x39 - text run at (0,0) width 395: "There should be one yellow boxbelow, on a blue background. " - text run at (394,0) width 359: "There is only one because the content is composited, and" - text run at (0,20) width 140: "hence not fragmented." -layer at (8,72) size 272x208 - LayoutBlockFlow {DIV} at (0,56) size 272x208 - LayoutMultiColumnSet (anonymous) at (0,0) size 272x208 -layer at (8,72) size 128x280 - LayoutMultiColumnFlowThread (anonymous) at (0,0) size 128x280 - LayoutBlockFlow (anonymous) at (0,0) size 128x128 - LayoutBR {BR} at (0,6) size 0x19 - LayoutBR {BR} at (0,38) size 0x19 - LayoutBR {BR} at (0,70) size 0x19 - LayoutBR {BR} at (0,102) size 0x19 -layer at (0,72) size 800x208 - LayoutBlockFlow (positioned) {DIV} at (0,72) size 800x208 [bgcolor=#0000FF] -layer at (16,208) size 112x136 - LayoutBlockFlow (relative positioned) {DIV} at (8,136) size 112x136 [bgcolor=#FFFF00] - LayoutText {#text} at (0,6) size 24x19 - text run at (0,6) width 24: "first" - LayoutBR {BR} at (24,6) size 0x19 - LayoutText {#text} at (0,38) size 47x19 - text run at (0,38) width 47: "column" - LayoutBR {BR} at (47,38) size 0x19 - LayoutText {#text} at (0,78) size 44x19 - text run at (0,78) width 44: "second" - LayoutBR {BR} at (44,78) size 0x19 - LayoutText {#text} at (0,110) size 47x19 - text run at (0,110) width 47: "column" - LayoutBR {BR} at (47,110) size 0x19
diff --git a/third_party/WebKit/LayoutTests/platform/linux/fast/multicol/composited-relpos-in-clipped-expected.txt b/third_party/WebKit/LayoutTests/platform/linux/fast/multicol/composited-relpos-in-clipped-expected.txt deleted file mode 100644 index f38b199..0000000 --- a/third_party/WebKit/LayoutTests/platform/linux/fast/multicol/composited-relpos-in-clipped-expected.txt +++ /dev/null
@@ -1,38 +0,0 @@ -layer at (0,0) size 800x600 - LayoutView at (0,0) size 800x600 -layer at (0,0) size 800x268 - LayoutBlockFlow {HTML} at (0,0) size 800x268 - LayoutBlockFlow {BODY} at (8,16) size 784x244 - LayoutBlockFlow {P} at (0,0) size 784x20 - LayoutText {#text} at (0,0) size 702x19 - text run at (0,0) width 702: "There should be one yellow box below, on a blue background. the \"second column\" part should be clipped out." -layer at (8,52) size 272x208 - LayoutBlockFlow {DIV} at (0,36) size 272x208 - LayoutMultiColumnSet (anonymous) at (0,0) size 272x208 -layer at (8,52) size 128x280 backgroundClip at (8,52) size 272x208 clip at (8,52) size 272x208 - LayoutMultiColumnFlowThread (anonymous) at (0,0) size 128x280 - LayoutBlockFlow (anonymous) at (0,0) size 128x128 - LayoutBR {BR} at (0,6) size 0x19 - LayoutBR {BR} at (0,38) size 0x19 - LayoutBR {BR} at (0,70) size 0x19 - LayoutBR {BR} at (0,102) size 0x19 -layer at (0,52) size 800x208 - LayoutBlockFlow (positioned) {DIV} at (0,52) size 800x208 [bgcolor=#0000FF] -layer at (16,188) size 112x136 backgroundClip at (16,188) size 112x72 clip at (16,188) size 112x72 scrollHeight 168 - LayoutBlockFlow (relative positioned) {DIV} at (8,136) size 112x136 [bgcolor=#FFFF00] - LayoutBlockFlow (anonymous) at (0,0) size 112x136 - LayoutText {#text} at (0,6) size 24x19 - text run at (0,6) width 24: "first" - LayoutBR {BR} at (24,6) size 0x19 - LayoutText {#text} at (0,38) size 47x19 - text run at (0,38) width 47: "column" - LayoutBR {BR} at (47,38) size 0x19 - LayoutText {#text} at (0,78) size 44x19 - text run at (0,78) width 44: "second" - LayoutBR {BR} at (44,78) size 0x19 - LayoutText {#text} at (0,110) size 47x19 - text run at (0,110) width 47: "column" - LayoutBR {BR} at (47,110) size 0x19 - LayoutBlockFlow {DIV} at (0,136) size 112x32 [bgcolor=#FF0000] - LayoutText {#text} at (0,6) size 35x19 - text run at (0,6) width 35: "FAIL"
diff --git a/third_party/WebKit/LayoutTests/platform/linux/fast/multicol/composited-relpos-overlapping-will-change-expected.txt b/third_party/WebKit/LayoutTests/platform/linux/fast/multicol/composited-relpos-overlapping-will-change-expected.txt deleted file mode 100644 index 4ce1dbd..0000000 --- a/third_party/WebKit/LayoutTests/platform/linux/fast/multicol/composited-relpos-overlapping-will-change-expected.txt +++ /dev/null
@@ -1,41 +0,0 @@ -layer at (0,0) size 800x600 - LayoutView at (0,0) size 800x600 -layer at (0,0) size 800x288 - LayoutBlockFlow {HTML} at (0,0) size 800x288 - LayoutBlockFlow {BODY} at (8,16) size 784x264 - LayoutBlockFlow {P} at (0,0) size 784x40 - LayoutText {#text} at (0,0) size 211x19 - text run at (0,0) width 211: "The word 'PASS' should be seen " - LayoutInline {EM} at (0,0) size 34x19 - LayoutText {#text} at (210,0) size 34x19 - text run at (210,0) width 34: "twice" - LayoutText {#text} at (243,0) size 784x39 - text run at (243,0) width 51: " below. " - text run at (293,0) width 491: "The second PASS is not overlapping the yellow because it is composited with" - text run at (0,20) width 249: "the first one, and hence not fragmented." -layer at (8,72) size 560x208 - LayoutBlockFlow {DIV} at (0,56) size 560x208 - LayoutMultiColumnSet (anonymous) at (0,0) size 560x208 -layer at (8,72) size 176x456 - LayoutMultiColumnFlowThread (anonymous) at (0,0) size 176x456 - LayoutBlockFlow (anonymous) at (0,0) size 176x368 - LayoutBR {BR} at (0,6) size 0x19 - LayoutBR {BR} at (0,38) size 0x19 - LayoutBR {BR} at (0,70) size 0x19 - LayoutBR {BR} at (0,102) size 0x19 - LayoutBR {BR} at (0,134) size 0x19 - LayoutBR {BR} at (0,166) size 0x19 - LayoutBR {BR} at (0,214) size 0x19 - LayoutBR {BR} at (0,246) size 0x19 - LayoutBR {BR} at (0,278) size 0x19 - LayoutBR {BR} at (0,310) size 0x19 - LayoutBR {BR} at (0,342) size 0x19 -layer at (0,72) size 800x128 - LayoutBlockFlow (positioned) {DIV} at (0,72) size 800x128 [bgcolor=#FFFF00] -layer at (16,448) size 160x72 - LayoutBlockFlow (relative positioned) {DIV} at (8,376) size 160x72 - LayoutText {#text} at (0,6) size 38x19 - text run at (0,6) width 38: "PASS" - LayoutBR {BR} at (37,6) size 1x19 - LayoutText {#text} at (0,46) size 38x19 - text run at (0,46) width 38: "PASS"
diff --git a/third_party/WebKit/LayoutTests/platform/linux/fast/multicol/composited-relpos-resize-expected.txt b/third_party/WebKit/LayoutTests/platform/linux/fast/multicol/composited-relpos-resize-expected.txt deleted file mode 100644 index d49b478f..0000000 --- a/third_party/WebKit/LayoutTests/platform/linux/fast/multicol/composited-relpos-resize-expected.txt +++ /dev/null
@@ -1,34 +0,0 @@ -layer at (0,0) size 800x600 - LayoutView at (0,0) size 800x600 -layer at (0,0) size 800x268 - LayoutBlockFlow {HTML} at (0,0) size 800x268 - LayoutBlockFlow {BODY} at (8,16) size 784x244 - LayoutBlockFlow {P} at (0,0) size 784x20 - LayoutText {#text} at (0,0) size 756x19 - text run at (0,0) width 756: "There should be one yellow box below. There is only one because the content is composited, and hence not fragmented." -layer at (8,52) size 706x208 - LayoutBlockFlow {DIV} at (0,36) size 705.59x208 - LayoutMultiColumnSet (anonymous) at (0,0) size 705.59x208 -layer at (8,52) size 353x280 - LayoutMultiColumnFlowThread (anonymous) at (0,0) size 352.80x280 - LayoutBlockFlow (anonymous) at (0,0) size 352.80x128 - LayoutBR {BR} at (0,6) size 0x19 - LayoutBR {BR} at (0,38) size 0x19 - LayoutBR {BR} at (0,70) size 0x19 - LayoutBR {BR} at (0,102) size 0x19 -layer at (0,52) size 800x240 - LayoutBlockFlow (positioned) {DIV} at (0,52) size 800x240 [bgcolor=#00FFFF] -layer at (16,188) size 337x136 - LayoutBlockFlow (relative positioned) {DIV} at (8,136) size 336.80x136 [bgcolor=#FFFF00] - LayoutText {#text} at (0,6) size 24x19 - text run at (0,6) width 24: "first" - LayoutBR {BR} at (24,6) size 0x19 - LayoutText {#text} at (0,38) size 47x19 - text run at (0,38) width 47: "column" - LayoutBR {BR} at (47,38) size 0x19 - LayoutText {#text} at (0,78) size 44x19 - text run at (0,78) width 44: "second" - LayoutBR {BR} at (44,78) size 0x19 - LayoutText {#text} at (0,110) size 47x19 - text run at (0,110) width 47: "column" - LayoutBR {BR} at (47,110) size 0x19
diff --git a/third_party/WebKit/LayoutTests/platform/linux/fast/multicol/composited-with-child-layer-in-next-column-expected.txt b/third_party/WebKit/LayoutTests/platform/linux/fast/multicol/composited-with-child-layer-in-next-column-expected.txt deleted file mode 100644 index 3e271b9..0000000 --- a/third_party/WebKit/LayoutTests/platform/linux/fast/multicol/composited-with-child-layer-in-next-column-expected.txt +++ /dev/null
@@ -1,33 +0,0 @@ -layer at (0,0) size 800x600 - LayoutView at (0,0) size 800x600 -layer at (0,0) size 800x224 - LayoutBlockFlow {HTML} at (0,0) size 800x224 - LayoutBlockFlow {BODY} at (8,16) size 784x200 - LayoutBlockFlow {P} at (0,0) size 784x40 - LayoutText {#text} at (0,0) size 741x39 - text run at (0,0) width 741: "There should be a yellow box in the second column, and the word 'PASS' should be below it. PASS is not in the third" - text run at (0,20) width 461: "column because they are composited together, and hence not fragmented." -layer at (8,72) size 272x144 - LayoutBlockFlow {DIV} at (0,56) size 272x144 - LayoutMultiColumnSet (anonymous) at (0,0) size 272x144 -layer at (8,72) size 80x272 - LayoutMultiColumnFlowThread (anonymous) at (0,0) size 80x272 - LayoutBlockFlow (anonymous) at (0,0) size 80x240 - LayoutBR {BR} at (0,6) size 0x19 - LayoutBR {BR} at (0,38) size 0x19 - LayoutBR {BR} at (0,70) size 0x19 - LayoutBR {BR} at (0,102) size 0x19 - LayoutBR {BR} at (0,150) size 0x19 - LayoutBR {BR} at (0,182) size 0x19 - LayoutBR {BR} at (0,214) size 0x19 -layer at (0,72) size 800x144 - LayoutBlockFlow (positioned) {DIV} at (0,72) size 800x144 [bgcolor=#00FFFF] -layer at (8,312) size 80x32 - LayoutBlockFlow (relative positioned) zI: 2 {DIV} at (0,240) size 80x32 [bgcolor=#FFFF00] - LayoutBlockFlow (anonymous) at (0,0) size 80x80 - LayoutBR {BR} at (0,6) size 0x19 - LayoutBR {BR} at (0,54) size 0x19 -layer at (16,400) size 64x32 transparent - LayoutBlockFlow {DIV} at (8,88) size 64x32 - LayoutText {#text} at (0,6) size 38x19 - text run at (0,6) width 38: "PASS"
diff --git a/third_party/WebKit/LayoutTests/platform/linux/fast/multicol/composited-with-overflow-in-next-column-expected.txt b/third_party/WebKit/LayoutTests/platform/linux/fast/multicol/composited-with-overflow-in-next-column-expected.txt deleted file mode 100644 index 1d72aa59..0000000 --- a/third_party/WebKit/LayoutTests/platform/linux/fast/multicol/composited-with-overflow-in-next-column-expected.txt +++ /dev/null
@@ -1,29 +0,0 @@ -layer at (0,0) size 800x600 - LayoutView at (0,0) size 800x600 -layer at (0,0) size 800x204 - LayoutBlockFlow {HTML} at (0,0) size 800x204 - LayoutBlockFlow {BODY} at (8,16) size 784x180 - LayoutBlockFlow {P} at (0,0) size 784x20 - LayoutText {#text} at (0,0) size 380x19 - text run at (0,0) width 380: "The word 'PASS' should be seen below, in the third column." -layer at (8,52) size 784x144 - LayoutBlockFlow {DIV} at (0,36) size 784x144 - LayoutMultiColumnSet (anonymous) at (0,0) size 784x144 -layer at (8,52) size 251x256 - LayoutMultiColumnFlowThread (anonymous) at (0,0) size 250.66x256 - LayoutBlockFlow (anonymous) at (0,0) size 250.66x240 - LayoutBR {BR} at (0,6) size 0x19 - LayoutBR {BR} at (0,38) size 0x19 - LayoutBR {BR} at (0,70) size 0x19 - LayoutBR {BR} at (0,102) size 0x19 - LayoutBR {BR} at (0,150) size 0x19 - LayoutBR {BR} at (0,182) size 0x19 - LayoutBR {BR} at (0,214) size 0x19 -layer at (0,100) size 800x18 - LayoutBlockFlow (positioned) {DIV} at (0,100) size 800x18 [border: (1px dotted #000000)] -layer at (8,292) size 251x16 - LayoutBlockFlow (relative positioned) {DIV} at (0,240) size 250.66x16 - LayoutBR {BR} at (0,6) size 0x19 - LayoutBR {BR} at (0,54) size 0x19 - LayoutText {#text} at (0,86) size 38x19 - text run at (0,86) width 38: "PASS"
diff --git a/third_party/WebKit/LayoutTests/platform/linux/fast/multicol/multicol-with-child-renderLayer-for-input-expected.txt b/third_party/WebKit/LayoutTests/platform/linux/fast/multicol/multicol-with-child-renderLayer-for-input-expected.txt deleted file mode 100644 index b59021b..0000000 --- a/third_party/WebKit/LayoutTests/platform/linux/fast/multicol/multicol-with-child-renderLayer-for-input-expected.txt +++ /dev/null
@@ -1,29 +0,0 @@ -layer at (0,0) size 800x600 - LayoutView at (0,0) size 800x600 -layer at (0,0) size 800x600 - LayoutBlockFlow {HTML} at (0,0) size 800x600 - LayoutBlockFlow {BODY} at (8,8) size 784x584 -layer at (8,8) size 784x66 - LayoutBlockFlow {DIV} at (0,0) size 784x66 - LayoutMultiColumnSet (anonymous) at (0,0) size 784x66 -layer at (8,8) size 384x132 - LayoutMultiColumnFlowThread (anonymous) at (0,0) size 384x132 - LayoutText {#text} at (0,0) size 378x105 - text run at (0,0) width 69: "Filler Text " - text run at (68,0) width 310: "Filler Text Filler Text Filler Text Filler Text Filler" - text run at (0,20) width 239: "Text Filler Text Filler Text Filler Text " - text run at (238,20) width 70: "Filler Text " - text run at (307,20) width 66: "Filler Text" - text run at (0,40) width 378: "Filler Text Filler Text Filler Text Filler Text Filler Text Filler" - text run at (0,66) width 101: "Text Filler Text " - text run at (100,66) width 70: "Filler Text " - text run at (169,66) width 204: "Filler Text Filler Text Filler Text" - text run at (0,86) width 341: "Filler Text Filler Text Filler Text Filler Text Filler Text" - LayoutText {#text} at (0,0) size 0x0 -layer at (10,116) size 154x22 clip at (12,118) size 150x18 - LayoutTextControl (relative positioned) {INPUT} at (2,108) size 154x22 [bgcolor=#FFFFFF] [border: (2px inset #EEEEEE)] -layer at (12,119) size 150x16 backgroundClip at (0,0) size 0x0 clip at (0,0) size 0x0 - LayoutBlockFlow {DIV} at (2,3) size 150x16 - LayoutText {#text} at (0,0) size 42x16 - text run at (0,0) width 42: "Testing" -caret: position 7 of child 0 {#text} of child 0 {DIV} of {#document-fragment} of child 1 {INPUT} of child 1 {DIV} of body
diff --git a/third_party/WebKit/LayoutTests/platform/linux/fast/multicol/span/invalid-spanner-in-transform-expected.txt b/third_party/WebKit/LayoutTests/platform/linux/fast/multicol/span/invalid-spanner-in-transform-expected.txt deleted file mode 100644 index 3d4cf5e..0000000 --- a/third_party/WebKit/LayoutTests/platform/linux/fast/multicol/span/invalid-spanner-in-transform-expected.txt +++ /dev/null
@@ -1,19 +0,0 @@ -layer at (0,0) size 800x600 - LayoutView at (0,0) size 800x600 -layer at (0,0) size 800x110 - LayoutBlockFlow {HTML} at (0,0) size 800x110 - LayoutBlockFlow {BODY} at (8,16) size 784x86 - LayoutBlockFlow {P} at (0,0) size 784x20 - LayoutText {#text} at (0,0) size 744x19 - text run at (0,0) width 255: "There should be one blue square below. " - text run at (254,0) width 490: "It is not two because they are composited together, and hence not fragmented." -layer at (8,52) size 110x50 - LayoutBlockFlow {DIV} at (0,36) size 110x50 - LayoutMultiColumnSet (anonymous) at (0,0) size 110x50 -layer at (8,52) size 50x100 - LayoutMultiColumnFlowThread (anonymous) at (0,0) size 50x100 -layer at (8,52) size 50x100 - LayoutBlockFlow {DIV} at (0,0) size 50x100 - LayoutBlockFlow {DIV} at (0,0) size 50x100 [bgcolor=#0000FF] - LayoutBR {BR} at (0,15) size 0x19 - LayoutBR {BR} at (0,65) size 0x19
diff --git a/third_party/WebKit/LayoutTests/platform/linux/fast/multicol/vertical-lr/composited-relpos-overlapping-will-change-expected.txt b/third_party/WebKit/LayoutTests/platform/linux/fast/multicol/vertical-lr/composited-relpos-overlapping-will-change-expected.txt deleted file mode 100644 index e442adb..0000000 --- a/third_party/WebKit/LayoutTests/platform/linux/fast/multicol/vertical-lr/composited-relpos-overlapping-will-change-expected.txt +++ /dev/null
@@ -1,42 +0,0 @@ -layer at (0,0) size 800x600 - LayoutView at (0,0) size 800x600 -layer at (0,0) size 800x496 - LayoutBlockFlow {HTML} at (0,0) size 800x496 - LayoutBlockFlow {BODY} at (8,16) size 784x472 - LayoutBlockFlow {P} at (0,0) size 784x40 - LayoutText {#text} at (0,0) size 211x19 - text run at (0,0) width 211: "The word 'PASS' should be seen " - LayoutInline {EM} at (0,0) size 34x19 - LayoutText {#text} at (210,0) size 34x19 - text run at (210,0) width 34: "twice" - LayoutText {#text} at (243,0) size 708x39 - text run at (243,0) width 465: " below. They appear together because they are composited, and hence not" - text run at (0,20) width 75: "fragmented." -layer at (8,72) size 208x416 - LayoutBlockFlow {DIV} at (0,56) size 208x416 - LayoutMultiColumnSet (anonymous) at (0,0) size 208x416 -layer at (8,72) size 456x128 - LayoutMultiColumnFlowThread (anonymous) at (0,0) size 456x128 - LayoutBlockFlow (anonymous) at (0,0) size 368x128 - LayoutBR {BR} at (6,0) size 19x0 - LayoutBR {BR} at (38,0) size 19x0 - LayoutBR {BR} at (70,0) size 19x0 - LayoutBR {BR} at (102,0) size 19x0 - LayoutBR {BR} at (134,0) size 19x0 - LayoutBR {BR} at (166,0) size 19x0 - LayoutBR {BR} at (214,0) size 19x0 - LayoutBR {BR} at (246,0) size 19x0 - LayoutBR {BR} at (278,0) size 19x0 - LayoutBR {BR} at (310,0) size 19x0 - LayoutText {#text} at (342,0) size 19x5 - text run at (342,0) width 5: "r" - LayoutBR {BR} at (342,5) size 19x0 -layer at (0,64) size 160x288 - LayoutBlockFlow (positioned) {DIV} at (0,64) size 160x288 [bgcolor=#FFFF00] -layer at (384,80) size 72x112 - LayoutBlockFlow (relative positioned) {DIV} at (376,8) size 72x112 - LayoutText {#text} at (6,0) size 19x38 - text run at (6,0) width 38: "PASS" - LayoutBR {BR} at (6,37) size 19x1 - LayoutText {#text} at (46,0) size 19x38 - text run at (46,0) width 38: "PASS"
diff --git a/third_party/WebKit/LayoutTests/platform/linux/fast/multicol/vertical-rl/composited-relpos-overlapping-will-change-expected.txt b/third_party/WebKit/LayoutTests/platform/linux/fast/multicol/vertical-rl/composited-relpos-overlapping-will-change-expected.txt deleted file mode 100644 index e682284..0000000 --- a/third_party/WebKit/LayoutTests/platform/linux/fast/multicol/vertical-rl/composited-relpos-overlapping-will-change-expected.txt +++ /dev/null
@@ -1,40 +0,0 @@ -layer at (0,0) size 800x600 - LayoutView at (0,0) size 800x600 -layer at (0,0) size 800x496 - LayoutBlockFlow {HTML} at (0,0) size 800x496 - LayoutBlockFlow {BODY} at (8,16) size 784x472 - LayoutBlockFlow {P} at (0,0) size 784x40 - LayoutText {#text} at (0,0) size 211x19 - text run at (0,0) width 211: "The word 'PASS' should be seen " - LayoutInline {EM} at (0,0) size 34x19 - LayoutText {#text} at (210,0) size 34x19 - text run at (210,0) width 34: "twice" - LayoutText {#text} at (243,0) size 708x39 - text run at (243,0) width 465: " below. They appear together because they are composited, and hence not" - text run at (0,20) width 75: "fragmented." -layer at (8,72) size 208x416 - LayoutBlockFlow {DIV} at (0,56) size 208x416 - LayoutMultiColumnSet (anonymous) at (0,0) size 208x416 -layer at (-240,72) size 456x128 backgroundClip at (0,0) size 800x600 clip at (0,0) size 800x600 - LayoutMultiColumnFlowThread (anonymous) at (0,0) size 456x128 - LayoutBlockFlow (anonymous) at (0,0) size 368x128 - LayoutBR {BR} at (6,0) size 19x0 - LayoutBR {BR} at (38,0) size 19x0 - LayoutBR {BR} at (70,0) size 19x0 - LayoutBR {BR} at (102,0) size 19x0 - LayoutBR {BR} at (134,0) size 19x0 - LayoutBR {BR} at (166,0) size 19x0 - LayoutBR {BR} at (214,0) size 19x0 - LayoutBR {BR} at (246,0) size 19x0 - LayoutBR {BR} at (278,0) size 19x0 - LayoutBR {BR} at (310,0) size 19x0 - LayoutBR {BR} at (342,0) size 19x0 -layer at (0,64) size 160x288 - LayoutBlockFlow (positioned) {DIV} at (0,64) size 160x288 [bgcolor=#FFFF00] -layer at (-232,80) size 72x112 backgroundClip at (0,0) size 800x600 clip at (0,0) size 800x600 - LayoutBlockFlow (relative positioned) {DIV} at (376,8) size 72x112 - LayoutText {#text} at (6,0) size 19x38 - text run at (6,0) width 38: "PASS" - LayoutBR {BR} at (6,37) size 19x1 - LayoutText {#text} at (46,0) size 19x38 - text run at (46,0) width 38: "PASS"
diff --git a/third_party/WebKit/LayoutTests/platform/mac-mac10.10/editing/deleting/merge-whitespace-pre-expected.png b/third_party/WebKit/LayoutTests/platform/mac-mac10.10/editing/deleting/merge-whitespace-pre-expected.png deleted file mode 100644 index b10ef71..0000000 --- a/third_party/WebKit/LayoutTests/platform/mac-mac10.10/editing/deleting/merge-whitespace-pre-expected.png +++ /dev/null Binary files differ
diff --git a/third_party/WebKit/LayoutTests/platform/mac-mac10.10/fast/multicol/multicol-with-child-renderLayer-for-input-expected.txt b/third_party/WebKit/LayoutTests/platform/mac-mac10.10/fast/multicol/multicol-with-child-renderLayer-for-input-expected.txt deleted file mode 100644 index e3f88f2..0000000 --- a/third_party/WebKit/LayoutTests/platform/mac-mac10.10/fast/multicol/multicol-with-child-renderLayer-for-input-expected.txt +++ /dev/null
@@ -1,29 +0,0 @@ -layer at (0,0) size 800x600 - LayoutView at (0,0) size 800x600 -layer at (0,0) size 800x600 - LayoutBlockFlow {HTML} at (0,0) size 800x600 - LayoutBlockFlow {BODY} at (8,8) size 784x584 -layer at (8,8) size 784x59 - LayoutBlockFlow {DIV} at (0,0) size 784x59 - LayoutMultiColumnSet (anonymous) at (0,0) size 784x59 -layer at (8,8) size 384x118 - LayoutMultiColumnFlowThread (anonymous) at (0,0) size 384x118 - LayoutText {#text} at (0,0) size 351x115 - text run at (0,0) width 71: "Filler Text " - text run at (70,0) width 281: "Filler Text Filler Text Filler Text Filler Text" - text run at (0,18) width 284: "Filler Text Filler Text Filler Text Filler Text " - text run at (283,18) width 68: "Filler Text" - text run at (0,36) width 351: "Filler Text Filler Text Filler Text Filler Text Filler Text" - text run at (0,59) width 213: "Filler Text Filler Text Filler Text " - text run at (212,59) width 72: "Filler Text " - text run at (283,59) width 68: "Filler Text" - text run at (0,77) width 351: "Filler Text Filler Text Filler Text Filler Text Filler Text" - text run at (0,97) width 142: "Filler Text Filler Text " - LayoutText {#text} at (0,0) size 0x0 -layer at (152,105) size 131x19 clip at (154,107) size 127x15 - LayoutTextControl (relative positioned) {INPUT} at (143.73,97) size 131x19 [bgcolor=#FFFFFF] [border: (2px inset #EEEEEE)] -layer at (155,108) size 125x13 backgroundClip at (0,0) size 0x0 clip at (0,0) size 0x0 - LayoutBlockFlow {DIV} at (3,3) size 125x13 - LayoutText {#text} at (0,0) size 36x13 - text run at (0,0) width 36: "Testing" -caret: position 7 of child 0 {#text} of child 0 {DIV} of {#document-fragment} of child 1 {INPUT} of child 1 {DIV} of body
diff --git a/third_party/WebKit/LayoutTests/platform/mac-mac10.11/fast/dom/Window/window-resize-contents-expected.txt b/third_party/WebKit/LayoutTests/platform/mac-mac10.11/fast/dom/Window/window-resize-contents-expected.txt new file mode 100644 index 0000000..c56aaafd2 --- /dev/null +++ b/third_party/WebKit/LayoutTests/platform/mac-mac10.11/fast/dom/Window/window-resize-contents-expected.txt
@@ -0,0 +1,6 @@ +CONSOLE MESSAGE: line 20: Initial reference node dimensions 800 x 600 +CONSOLE MESSAGE: line 22: Increasing window size by 10 x 10 +CONSOLE MESSAGE: line 24: Post-resize reference node dimensions 85 x 85 +This test checks that the yellow reference DOM node (which should be as big as the window) gets resized when the window is resized. + +To avoid relayouts and repaints caused by DOM-based logging, it doesn't output anything. Please check the console for confirmation that the node dimensions increase by 10x10.
diff --git a/third_party/WebKit/LayoutTests/platform/mac-mac10.11/fast/multicol/multicol-with-child-renderLayer-for-input-expected.txt b/third_party/WebKit/LayoutTests/platform/mac-mac10.11/fast/multicol/multicol-with-child-renderLayer-for-input-expected.txt deleted file mode 100644 index 2a8707f..0000000 --- a/third_party/WebKit/LayoutTests/platform/mac-mac10.11/fast/multicol/multicol-with-child-renderLayer-for-input-expected.txt +++ /dev/null
@@ -1,29 +0,0 @@ -layer at (0,0) size 800x600 - LayoutView at (0,0) size 800x600 -layer at (0,0) size 800x600 - LayoutBlockFlow {HTML} at (0,0) size 800x600 - LayoutBlockFlow {BODY} at (8,8) size 784x584 -layer at (8,8) size 784x59 - LayoutBlockFlow {DIV} at (0,0) size 784x59 - LayoutMultiColumnSet (anonymous) at (0,0) size 784x59 -layer at (8,8) size 384x118 - LayoutMultiColumnFlowThread (anonymous) at (0,0) size 384x118 - LayoutText {#text} at (0,0) size 351x115 - text run at (0,0) width 71: "Filler Text " - text run at (70,0) width 281: "Filler Text Filler Text Filler Text Filler Text" - text run at (0,18) width 284: "Filler Text Filler Text Filler Text Filler Text " - text run at (283,18) width 68: "Filler Text" - text run at (0,36) width 351: "Filler Text Filler Text Filler Text Filler Text Filler Text" - text run at (0,59) width 213: "Filler Text Filler Text Filler Text " - text run at (212,59) width 72: "Filler Text " - text run at (283,59) width 68: "Filler Text" - text run at (0,77) width 351: "Filler Text Filler Text Filler Text Filler Text Filler Text" - text run at (0,97) width 142: "Filler Text Filler Text " - LayoutText {#text} at (0,0) size 0x0 -layer at (152,105) size 131x19 clip at (154,107) size 127x15 - LayoutTextControl (relative positioned) {INPUT} at (143.73,97) size 131x19 [bgcolor=#FFFFFF] [border: (2px inset #EEEEEE)] -layer at (155,108) size 125x13 backgroundClip at (0,0) size 0x0 clip at (0,0) size 0x0 - LayoutBlockFlow {DIV} at (3,3) size 125x13 - LayoutText {#text} at (0,0) size 38x13 - text run at (0,0) width 38: "Testing" -caret: position 7 of child 0 {#text} of child 0 {DIV} of {#document-fragment} of child 1 {INPUT} of child 1 {DIV} of body
diff --git a/third_party/WebKit/LayoutTests/platform/mac-mac10.12/external/wpt/streams/readable-streams/default-reader.sharedworker-expected.txt b/third_party/WebKit/LayoutTests/platform/mac-mac10.12/external/wpt/streams/readable-streams/default-reader.sharedworker-expected.txt new file mode 100644 index 0000000..0426dc27 --- /dev/null +++ b/third_party/WebKit/LayoutTests/platform/mac-mac10.12/external/wpt/streams/readable-streams/default-reader.sharedworker-expected.txt
@@ -0,0 +1,30 @@ +This is a testharness.js-based test. +PASS Can get the ReadableStreamDefaultReader constructor indirectly +PASS ReadableStreamDefaultReader constructor should get a ReadableStream object as argument +PASS ReadableStreamDefaultReader instances should have the correct list of properties +PASS ReadableStreamDefaultReader closed should always return the same promise object +PASS Constructing a ReadableStreamDefaultReader directly should fail if the stream is already locked (via direct construction) +PASS Getting a ReadableStreamDefaultReader via getReader should fail if the stream is already locked (via direct construction) +PASS Constructing a ReadableStreamDefaultReader directly should fail if the stream is already locked (via getReader) +PASS Getting a ReadableStreamDefaultReader via getReader should fail if the stream is already locked (via getReader) +PASS Constructing a ReadableStreamDefaultReader directly should be OK if the stream is closed +PASS Constructing a ReadableStreamDefaultReader directly should be OK if the stream is errored +PASS Reading from a reader for an empty stream will wait until a chunk is available +PASS cancel() on a reader does not release the reader +PASS closed should be fulfilled after stream is closed (.closed access before acquiring) +PASS closed should be rejected after reader releases its lock (multiple stream locks) +PASS Multiple readers can access the stream in sequence +PASS Cannot use an already-released reader to unlock a stream again +PASS cancel() on a released reader is a no-op and does not pass through +PASS Getting a second reader after erroring the stream and releasing the reader should succeed +PASS ReadableStreamDefaultReader closed promise should be rejected with undefined if that is the error +PASS ReadableStreamDefaultReader: if start rejects with no parameter, it should error the stream with an undefined error +PASS Erroring a ReadableStream after checking closed should reject ReadableStreamDefaultReader closed promise +PASS Erroring a ReadableStream before checking closed should reject ReadableStreamDefaultReader closed promise +PASS Reading twice on a stream that gets closed +PASS Reading twice on a closed stream +PASS Reading twice on an errored stream +PASS Reading twice on a stream that gets errored +FAIL getReader() should call ToString() on mode assert_true: toString() should be called expected true got false +Harness: the test ran to completion. +
diff --git a/third_party/WebKit/LayoutTests/platform/mac-retina/fast/dom/Window/window-resize-contents-expected.txt b/third_party/WebKit/LayoutTests/platform/mac-retina/fast/dom/Window/window-resize-contents-expected.txt new file mode 100644 index 0000000..c56aaafd2 --- /dev/null +++ b/third_party/WebKit/LayoutTests/platform/mac-retina/fast/dom/Window/window-resize-contents-expected.txt
@@ -0,0 +1,6 @@ +CONSOLE MESSAGE: line 20: Initial reference node dimensions 800 x 600 +CONSOLE MESSAGE: line 22: Increasing window size by 10 x 10 +CONSOLE MESSAGE: line 24: Post-resize reference node dimensions 85 x 85 +This test checks that the yellow reference DOM node (which should be as big as the window) gets resized when the window is resized. + +To avoid relayouts and repaints caused by DOM-based logging, it doesn't output anything. Please check the console for confirmation that the node dimensions increase by 10x10.
diff --git a/third_party/WebKit/LayoutTests/platform/mac-retina/fast/multicol/multicol-with-child-renderLayer-for-input-expected.txt b/third_party/WebKit/LayoutTests/platform/mac-retina/fast/multicol/multicol-with-child-renderLayer-for-input-expected.txt deleted file mode 100644 index 2a8707f..0000000 --- a/third_party/WebKit/LayoutTests/platform/mac-retina/fast/multicol/multicol-with-child-renderLayer-for-input-expected.txt +++ /dev/null
@@ -1,29 +0,0 @@ -layer at (0,0) size 800x600 - LayoutView at (0,0) size 800x600 -layer at (0,0) size 800x600 - LayoutBlockFlow {HTML} at (0,0) size 800x600 - LayoutBlockFlow {BODY} at (8,8) size 784x584 -layer at (8,8) size 784x59 - LayoutBlockFlow {DIV} at (0,0) size 784x59 - LayoutMultiColumnSet (anonymous) at (0,0) size 784x59 -layer at (8,8) size 384x118 - LayoutMultiColumnFlowThread (anonymous) at (0,0) size 384x118 - LayoutText {#text} at (0,0) size 351x115 - text run at (0,0) width 71: "Filler Text " - text run at (70,0) width 281: "Filler Text Filler Text Filler Text Filler Text" - text run at (0,18) width 284: "Filler Text Filler Text Filler Text Filler Text " - text run at (283,18) width 68: "Filler Text" - text run at (0,36) width 351: "Filler Text Filler Text Filler Text Filler Text Filler Text" - text run at (0,59) width 213: "Filler Text Filler Text Filler Text " - text run at (212,59) width 72: "Filler Text " - text run at (283,59) width 68: "Filler Text" - text run at (0,77) width 351: "Filler Text Filler Text Filler Text Filler Text Filler Text" - text run at (0,97) width 142: "Filler Text Filler Text " - LayoutText {#text} at (0,0) size 0x0 -layer at (152,105) size 131x19 clip at (154,107) size 127x15 - LayoutTextControl (relative positioned) {INPUT} at (143.73,97) size 131x19 [bgcolor=#FFFFFF] [border: (2px inset #EEEEEE)] -layer at (155,108) size 125x13 backgroundClip at (0,0) size 0x0 clip at (0,0) size 0x0 - LayoutBlockFlow {DIV} at (3,3) size 125x13 - LayoutText {#text} at (0,0) size 38x13 - text run at (0,0) width 38: "Testing" -caret: position 7 of child 0 {#text} of child 0 {DIV} of {#document-fragment} of child 1 {INPUT} of child 1 {DIV} of body
diff --git a/third_party/WebKit/LayoutTests/platform/mac/editing/deleting/merge-whitespace-pre-expected.png b/third_party/WebKit/LayoutTests/platform/mac/editing/deleting/merge-whitespace-pre-expected.png deleted file mode 100644 index f9a074e8..0000000 --- a/third_party/WebKit/LayoutTests/platform/mac/editing/deleting/merge-whitespace-pre-expected.png +++ /dev/null Binary files differ
diff --git a/third_party/WebKit/LayoutTests/platform/mac/editing/deleting/merge-whitespace-pre-expected.txt b/third_party/WebKit/LayoutTests/platform/mac/editing/deleting/merge-whitespace-pre-expected.txt deleted file mode 100644 index b08e768..0000000 --- a/third_party/WebKit/LayoutTests/platform/mac/editing/deleting/merge-whitespace-pre-expected.txt +++ /dev/null
@@ -1,18 +0,0 @@ -layer at (0,0) size 800x600 - LayoutView at (0,0) size 800x600 -layer at (0,0) size 800x600 - LayoutBlockFlow {HTML} at (0,0) size 800x600 - LayoutBlockFlow {BODY} at (8,8) size 784x579 - LayoutBlockFlow {P} at (0,0) size 784x36 - LayoutText {#text} at (0,0) size 755x36 - text run at (0,0) width 371: "This test places the caret before the 'b' in 'bar' and Delete. " - text run at (370,0) width 385: "Afterword, 'foobar' should be in the first paragraph and 'baz'" - text run at (0,18) width 155: "should be in the second." - LayoutBlockFlow {DIV} at (0,52) size 784x46 - LayoutBlockFlow {DIV} at (0,0) size 784x18 - LayoutText {#text} at (0,0) size 42x18 - text run at (0,0) width 42: "foobar" - LayoutBlockFlow {PRE} at (0,31) size 784x15 - LayoutText {#text} at (0,0) size 24x15 - text run at (0,0) width 24: "baz" -caret: position 3 of child 0 {#text} of child 1 {DIV} of child 2 {DIV} of body
diff --git a/third_party/WebKit/LayoutTests/platform/mac/editing/inserting/4875189-1-expected.png b/third_party/WebKit/LayoutTests/platform/mac/editing/inserting/4875189-1-expected.png deleted file mode 100644 index 18ceb0e..0000000 --- a/third_party/WebKit/LayoutTests/platform/mac/editing/inserting/4875189-1-expected.png +++ /dev/null Binary files differ
diff --git a/third_party/WebKit/LayoutTests/platform/mac/editing/inserting/4875189-1-expected.txt b/third_party/WebKit/LayoutTests/platform/mac/editing/inserting/4875189-1-expected.txt deleted file mode 100644 index c01b2575..0000000 --- a/third_party/WebKit/LayoutTests/platform/mac/editing/inserting/4875189-1-expected.txt +++ /dev/null
@@ -1,16 +0,0 @@ -layer at (0,0) size 800x600 - LayoutView at (0,0) size 800x600 -layer at (0,0) size 800x600 - LayoutBlockFlow {HTML} at (0,0) size 800x600 - LayoutBlockFlow {BODY} at (8,8) size 784x576 - LayoutBlockFlow {P} at (0,0) size 784x18 - LayoutText {#text} at (0,0) size 667x18 - text run at (0,0) width 366: "This tests for a bug when replacing the contents of a list. " - text run at (365,0) width 302: "The list shouldn't be removed, just its contents." - LayoutBlockFlow {DIV} at (0,34) size 784x18 - LayoutBlockFlow {UL} at (0,0) size 784x18 - LayoutListItem {LI} at (40,0) size 744x18 - LayoutListMarker (anonymous) at (-17,0) size 7x18: bullet - LayoutText {#text} at (0,0) size 182x18 - text run at (0,0) width 182: "This should be in a list item." -caret: position 30 of child 0 {#text} of child 0 {LI} of child 0 {UL} of child 2 {DIV} of body
diff --git a/third_party/WebKit/LayoutTests/platform/mac/editing/inserting/4959067-expected.png b/third_party/WebKit/LayoutTests/platform/mac/editing/inserting/4959067-expected.png deleted file mode 100644 index 63f928b..0000000 --- a/third_party/WebKit/LayoutTests/platform/mac/editing/inserting/4959067-expected.png +++ /dev/null Binary files differ
diff --git a/third_party/WebKit/LayoutTests/platform/mac/editing/inserting/4959067-expected.txt b/third_party/WebKit/LayoutTests/platform/mac/editing/inserting/4959067-expected.txt deleted file mode 100644 index a3bcecaf..0000000 --- a/third_party/WebKit/LayoutTests/platform/mac/editing/inserting/4959067-expected.txt +++ /dev/null
@@ -1,17 +0,0 @@ -layer at (0,0) size 800x600 - LayoutView at (0,0) size 800x600 -layer at (0,0) size 800x600 - LayoutBlockFlow {HTML} at (0,0) size 800x600 - LayoutBlockFlow {BODY} at (8,8) size 784x576 - LayoutBlockFlow {P} at (0,0) size 784x18 - LayoutText {#text} at (0,0) size 613x18 - text run at (0,0) width 613: "This tests to make sure that insertion over a fully selected special element doesn't do expansion." - LayoutBlockFlow {DIV} at (0,34) size 784x18 - LayoutBlockFlow {UL} at (0,0) size 784x18 - LayoutListItem {LI} at (40,0) size 744x18 - LayoutListMarker (anonymous) at (-17,0) size 7x18: bullet - LayoutInline {A} at (0,0) size 22x18 [color=#0000EE] - LayoutText {#text} at (0,0) size 22x18 - text run at (0,0) width 22: "foo" - LayoutBlockFlow {UL} at (0,68) size 784x0 -caret: position 3 of child 0 {#text} of child 0 {A} of child 0 {LI} of child 1 {UL} of child 2 {DIV} of body
diff --git a/third_party/WebKit/LayoutTests/platform/mac/editing/inserting/editable-inline-element-expected.png b/third_party/WebKit/LayoutTests/platform/mac/editing/inserting/editable-inline-element-expected.png deleted file mode 100644 index 0d4be1fd..0000000 --- a/third_party/WebKit/LayoutTests/platform/mac/editing/inserting/editable-inline-element-expected.png +++ /dev/null Binary files differ
diff --git a/third_party/WebKit/LayoutTests/platform/mac/editing/inserting/editable-inline-element-expected.txt b/third_party/WebKit/LayoutTests/platform/mac/editing/inserting/editable-inline-element-expected.txt deleted file mode 100644 index f685fec9..0000000 --- a/third_party/WebKit/LayoutTests/platform/mac/editing/inserting/editable-inline-element-expected.txt +++ /dev/null
@@ -1,14 +0,0 @@ -layer at (0,0) size 800x600 - LayoutView at (0,0) size 800x600 -layer at (0,0) size 800x600 - LayoutBlockFlow {HTML} at (0,0) size 800x600 - LayoutBlockFlow {BODY} at (8,8) size 784x584 - LayoutBlockFlow {P} at (0,0) size 784x18 - LayoutText {#text} at (0,0) size 382x18 - text run at (0,0) width 382: "This tests InsertParagraph inside an editable inline element." - LayoutBlockFlow {DIV} at (0,34) size 784x38 [border: (1px solid #FF0000)] - LayoutInline {SPAN} at (0,0) size 22x36 - LayoutBR {BR} at (1,1) size 0x18 - LayoutText {#text} at (1,19) size 22x18 - text run at (1,19) width 22: "foo" -caret: position 0 of child 1 {#text} of child 0 {SPAN} of child 2 {DIV} of body
diff --git a/third_party/WebKit/LayoutTests/platform/mac/editing/selection/focus-body-expected.png b/third_party/WebKit/LayoutTests/platform/mac/editing/selection/focus-body-expected.png deleted file mode 100644 index d022c67e3..0000000 --- a/third_party/WebKit/LayoutTests/platform/mac/editing/selection/focus-body-expected.png +++ /dev/null Binary files differ
diff --git a/third_party/WebKit/LayoutTests/platform/mac/editing/selection/focus-body-expected.txt b/third_party/WebKit/LayoutTests/platform/mac/editing/selection/focus-body-expected.txt deleted file mode 100644 index 6901089..0000000 --- a/third_party/WebKit/LayoutTests/platform/mac/editing/selection/focus-body-expected.txt +++ /dev/null
@@ -1,10 +0,0 @@ -EDITING DELEGATE: webViewDidChangeSelection:WebViewDidChangeSelectionNotification -layer at (0,0) size 800x600 - LayoutView at (0,0) size 800x600 -layer at (0,0) size 800x600 - LayoutBlockFlow {HTML} at (0,0) size 800x600 - LayoutBlockFlow {BODY} at (8,8) size 784x584 - LayoutText {#text} at (0,0) size 447x18 - text run at (0,0) width 224: "This test focuses an editable body. " - text run at (223,0) width 224: "Its contents should not be selected." -caret: position 0 of child 0 {#text} of body
diff --git a/third_party/WebKit/LayoutTests/platform/mac/fast/multicol/border-radius-clipped-layer-second-column-expected.txt b/third_party/WebKit/LayoutTests/platform/mac/fast/multicol/border-radius-clipped-layer-second-column-expected.txt deleted file mode 100644 index 2b96710..0000000 --- a/third_party/WebKit/LayoutTests/platform/mac/fast/multicol/border-radius-clipped-layer-second-column-expected.txt +++ /dev/null
@@ -1,26 +0,0 @@ -layer at (0,0) size 800x600 - LayoutView at (0,0) size 800x600 -layer at (0,0) size 800x244 - LayoutBlockFlow {HTML} at (0,0) size 800x244 - LayoutBlockFlow {BODY} at (8,16) size 784x220 - LayoutBlockFlow {P} at (0,0) size 784x36 - LayoutText {#text} at (0,0) size 726x36 - text run at (0,0) width 610: "The word 'PASS' should be seen below on the right hand side, inside a rounded box with black " - text run at (609,0) width 117: "border and yellow" - text run at (0,18) width 80: "background." -layer at (8,68) size 784x168 - LayoutBlockFlow {DIV} at (0,52) size 784x168 - LayoutMultiColumnSet (anonymous) at (0,0) size 784x168 -layer at (8,68) size 392x264 - LayoutMultiColumnFlowThread (anonymous) at (0,0) size 392x264 - LayoutBlockFlow (anonymous) at (0,0) size 392x200 - LayoutBR {BR} at (0,7) size 0x18 - LayoutBR {BR} at (0,39) size 0x18 - LayoutBR {BR} at (0,71) size 0x18 - LayoutBR {BR} at (0,103) size 0x18 - LayoutBR {BR} at (0,135) size 0x18 - LayoutBR {BR} at (0,175) size 0x18 -layer at (8,268) size 392x64 clip at (24,284) size 360x32 - LayoutBlockFlow (relative positioned) {DIV} at (0,200) size 392x64 [bgcolor=#FFFF00] [border: (16px solid #000000)] - LayoutText {#text} at (177,23) size 38x18 - text run at (177,23) width 38: "PASS"
diff --git a/third_party/WebKit/LayoutTests/platform/mac/fast/multicol/composited-inner-multicol-expected.txt b/third_party/WebKit/LayoutTests/platform/mac/fast/multicol/composited-inner-multicol-expected.txt deleted file mode 100644 index dcf4c74..0000000 --- a/third_party/WebKit/LayoutTests/platform/mac/fast/multicol/composited-inner-multicol-expected.txt +++ /dev/null
@@ -1,44 +0,0 @@ -layer at (0,0) size 800x600 - LayoutView at (0,0) size 800x600 -layer at (0,0) size 800x204 - LayoutBlockFlow {HTML} at (0,0) size 800x204 - LayoutBlockFlow {BODY} at (8,16) size 784x180 - LayoutBlockFlow {P} at (0,0) size 784x36 - LayoutText {#text} at (0,0) size 763x36 - text run at (0,0) width 621: "Below you should see the word 'PASS' (with some extra letter spacing), on a yellow background " - text run at (620,0) width 143: "(which should be a bit" - text run at (0,18) width 706: "faded near the top). The first S is below the A, because they composite together and hence are not fragmented." -layer at (8,68) size 480x128 - LayoutBlockFlow {DIV} at (0,52) size 480x128 - LayoutMultiColumnSet (anonymous) at (0,0) size 480x128 -layer at (8,68) size 240x224 - LayoutMultiColumnFlowThread (anonymous) at (0,0) size 240x224 - LayoutBlockFlow (anonymous) at (0,0) size 240x160 - LayoutBR {BR} at (0,7) size 0x18 - LayoutBR {BR} at (0,39) size 0x18 - LayoutBR {BR} at (0,71) size 0x18 - LayoutBR {BR} at (0,103) size 0x18 - LayoutBR {BR} at (0,135) size 0x18 -layer at (16,236) size 80x48 - LayoutBlockFlow {DIV} at (8,168) size 80x48 [bgcolor=#FFFF00] - LayoutMultiColumnSet (anonymous) at (8,8) size 64x32 -layer at (24,244) size 16x128 - LayoutMultiColumnFlowThread (anonymous) at (8,8) size 16x128 - LayoutBlockFlow (anonymous) at (0,0) size 16x32 - LayoutText {#text} at (0,7) size 9x18 - text run at (0,7) width 9: "P" - LayoutBR {BR} at (8,7) size 1x18 - LayoutBlockFlow (anonymous) at (0,96) size 16x32 - LayoutText {#text} at (0,7) size 9x18 - text run at (0,7) width 9: "S" - LayoutBR {BR} at (8,7) size 1x18 -layer at (240,68) size 112x53 transparent - LayoutBlockFlow (positioned) {DIV} at (240,68) size 112x52.80 [bgcolor=#FFFFFF] -layer at (24,276) size 16x64 - LayoutBlockFlow (relative positioned) {DIV} at (0,32) size 16x64 - LayoutText {#text} at (0,7) size 12x18 - text run at (0,7) width 12: "A" - LayoutBR {BR} at (11,7) size 1x18 - LayoutText {#text} at (0,39) size 9x18 - text run at (0,39) width 9: "S" - LayoutBR {BR} at (8,39) size 1x18
diff --git a/third_party/WebKit/LayoutTests/platform/mac/fast/multicol/composited-layer-multiple-fragments-expected.txt b/third_party/WebKit/LayoutTests/platform/mac/fast/multicol/composited-layer-multiple-fragments-expected.txt deleted file mode 100644 index 00cf4f0..0000000 --- a/third_party/WebKit/LayoutTests/platform/mac/fast/multicol/composited-layer-multiple-fragments-expected.txt +++ /dev/null
@@ -1,43 +0,0 @@ -layer at (0,0) size 800x600 - LayoutView at (0,0) size 800x600 -layer at (0,0) size 800x316 - LayoutBlockFlow {HTML} at (0,0) size 800x316 - LayoutBlockFlow {BODY} at (8,16) size 784x252 - LayoutBlockFlow {P} at (0,0) size 784x36 - LayoutText {#text} at (0,0) size 741x36 - text run at (0,0) width 741: "If no compositing were present, there should be two green squares below. Since some elements are composited, and" - text run at (0,18) width 309: "therefore not fragmented, the output is different." -layer at (8,100) size 60x60 - LayoutBlockFlow {DIV} at (0,84) size 60x60 - LayoutMultiColumnSet (anonymous) at (0,0) size 60x60 -layer at (8,100) size 20x180 - LayoutMultiColumnFlowThread (anonymous) at (0,0) size 20x180 - LayoutBlockFlow {DIV} at (0,0) size 20x20 [bgcolor=#008000] - LayoutBlockFlow {DIV} at (0,20) size 20x20 [bgcolor=#008000] - LayoutBlockFlow {DIV} at (0,80) size 20x20 [bgcolor=#008000] - LayoutBlockFlow {DIV} at (0,140) size 20x20 [bgcolor=#008000] - LayoutBlockFlow {DIV} at (0,160) size 20x20 [bgcolor=#008000] -layer at (8,208) size 60x60 - LayoutBlockFlow {DIV} at (0,192) size 60x60 - LayoutMultiColumnSet (anonymous) at (0,0) size 60x60 -layer at (8,208) size 20x180 - LayoutMultiColumnFlowThread (anonymous) at (0,0) size 20x180 - LayoutBlockFlow {DIV} at (0,0) size 20x20 [bgcolor=#008000] - LayoutBlockFlow {DIV} at (0,20) size 20x20 [bgcolor=#008000] - LayoutBlockFlow {DIV} at (0,140) size 20x20 [bgcolor=#008000] - LayoutBlockFlow {DIV} at (0,160) size 20x20 [bgcolor=#008000] -layer at (8,140) size 20x40 - LayoutBlockFlow {DIV} at (0,40) size 20x40 - LayoutBlockFlow {DIV} at (0,0) size 20x20 [bgcolor=#008000] - LayoutBlockFlow {DIV} at (0,20) size 20x20 [bgcolor=#008000] -layer at (8,200) size 20x40 - LayoutBlockFlow {DIV} at (0,100) size 20x40 - LayoutBlockFlow {DIV} at (0,0) size 20x20 [bgcolor=#008000] - LayoutBlockFlow {DIV} at (0,20) size 20x20 [bgcolor=#008000] -layer at (8,248) size 20x100 - LayoutBlockFlow {DIV} at (0,40) size 20x100 - LayoutBlockFlow {DIV} at (0,0) size 20x20 [bgcolor=#008000] - LayoutBlockFlow {DIV} at (0,20) size 20x20 [bgcolor=#008000] - LayoutBlockFlow {DIV} at (0,40) size 20x20 [bgcolor=#008000] - LayoutBlockFlow {DIV} at (0,60) size 20x20 [bgcolor=#008000] - LayoutBlockFlow {DIV} at (0,80) size 20x20 [bgcolor=#008000]
diff --git a/third_party/WebKit/LayoutTests/platform/mac/fast/multicol/composited-layer-multiple-fragments-translated-expected.txt b/third_party/WebKit/LayoutTests/platform/mac/fast/multicol/composited-layer-multiple-fragments-translated-expected.txt deleted file mode 100644 index 56560030..0000000 --- a/third_party/WebKit/LayoutTests/platform/mac/fast/multicol/composited-layer-multiple-fragments-translated-expected.txt +++ /dev/null
@@ -1,27 +0,0 @@ -layer at (0,0) size 800x600 - LayoutView at (0,0) size 800x600 -layer at (0,0) size 800x136 - LayoutBlockFlow {HTML} at (0,0) size 800x136 - LayoutBlockFlow {BODY} at (8,16) size 784x112 - LayoutBlockFlow {P} at (0,0) size 784x36 - LayoutText {#text} at (0,0) size 754x36 - text run at (0,0) width 754: "There should be two small green squares vertically aligned below, and another red square to the top-right. The second" - text run at (0,18) width 585: "green square does not overlap the red because it is conmposited, and hence not fragmented." -layer at (8,68) size 60x60 - LayoutBlockFlow {DIV} at (0,52) size 60x60 - LayoutMultiColumnSet (anonymous) at (0,0) size 60x60 -layer at (8,68) size 20x180 - LayoutMultiColumnFlowThread (anonymous) at (0,0) size 20x180 - LayoutBlockFlow (anonymous) at (0,0) size 20x100 - LayoutBR {BR} at (0,1) size 0x18 - LayoutBR {BR} at (0,21) size 0x18 - LayoutBR {BR} at (0,41) size 0x18 - LayoutBR {BR} at (0,61) size 0x18 - LayoutBR {BR} at (0,81) size 0x18 - LayoutBlockFlow {DIV} at (0,160) size 20x20 [bgcolor=#FF0000] -layer at (8,168) size 20x60 - LayoutBlockFlow {DIV} at (0,100) size 20x60 - LayoutBlockFlow {DIV} at (0,0) size 20x20 [bgcolor=#008000] - LayoutBlockFlow (anonymous) at (0,20) size 20x20 - LayoutBR {BR} at (0,1) size 0x18 - LayoutBlockFlow {DIV} at (0,40) size 20x20 [bgcolor=#008000]
diff --git a/third_party/WebKit/LayoutTests/platform/mac/fast/multicol/composited-layer-nested-expected.txt b/third_party/WebKit/LayoutTests/platform/mac/fast/multicol/composited-layer-nested-expected.txt deleted file mode 100644 index 981abb40..0000000 --- a/third_party/WebKit/LayoutTests/platform/mac/fast/multicol/composited-layer-nested-expected.txt +++ /dev/null
@@ -1,51 +0,0 @@ -layer at (0,0) size 800x600 - LayoutView at (0,0) size 800x600 -layer at (0,0) size 800x316 - LayoutBlockFlow {HTML} at (0,0) size 800x316 - LayoutBlockFlow {BODY} at (8,16) size 784x252 - LayoutBlockFlow {P} at (0,0) size 784x36 - LayoutText {#text} at (0,0) size 741x36 - text run at (0,0) width 741: "If no compositing were present, there should be two green squares below. Since some elements are composited, and" - text run at (0,18) width 309: "therefore not fragmented, the output is different." -layer at (8,100) size 60x60 - LayoutBlockFlow {DIV} at (0,84) size 60x60 - LayoutMultiColumnSet (anonymous) at (0,0) size 60x60 -layer at (8,100) size 20x180 - LayoutMultiColumnFlowThread (anonymous) at (0,0) size 20x180 - LayoutBlockFlow {DIV} at (0,0) size 20x20 [bgcolor=#008000] - LayoutBlockFlow {DIV} at (0,100) size 20x20 [bgcolor=#008000] - LayoutBlockFlow {DIV} at (0,120) size 20x20 [bgcolor=#008000] - LayoutBlockFlow {DIV} at (0,140) size 20x20 [bgcolor=#008000] - LayoutBlockFlow {DIV} at (0,160) size 20x20 [bgcolor=#008000] -layer at (8,208) size 60x60 - LayoutBlockFlow {DIV} at (0,192) size 60x60 - LayoutMultiColumnSet (anonymous) at (0,0) size 60x60 -layer at (8,208) size 20x180 - LayoutMultiColumnFlowThread (anonymous) at (0,0) size 20x180 -layer at (8,120) size 20x80 - LayoutBlockFlow {DIV} at (0,20) size 20x80 - LayoutBlockFlow {DIV} at (0,0) size 20x20 [bgcolor=#008000] - LayoutBlockFlow {DIV} at (0,60) size 20x20 [bgcolor=#008000] -layer at (8,140) size 20x40 - LayoutBlockFlow {DIV} at (0,20) size 20x40 - LayoutBlockFlow {DIV} at (0,0) size 20x20 [bgcolor=#008000] - LayoutBlockFlow {DIV} at (0,20) size 20x20 [bgcolor=#008000] -layer at (8,208) size 20x180 - LayoutBlockFlow {DIV} at (0,0) size 20x180 - LayoutBlockFlow {DIV} at (0,80) size 20x20 [bgcolor=#008000] -layer at (8,208) size 20x80 - LayoutBlockFlow {DIV} at (0,0) size 20x80 - LayoutBlockFlow {DIV} at (0,0) size 20x20 [bgcolor=#008000] - LayoutBlockFlow {DIV} at (0,20) size 20x20 [bgcolor=#008000] -layer at (8,248) size 20x40 - LayoutBlockFlow {DIV} at (0,40) size 20x40 - LayoutBlockFlow {DIV} at (0,0) size 20x20 [bgcolor=#008000] - LayoutBlockFlow {DIV} at (0,20) size 20x20 [bgcolor=#008000] -layer at (8,308) size 20x80 - LayoutBlockFlow {DIV} at (0,100) size 20x80 - LayoutBlockFlow {DIV} at (0,40) size 20x20 [bgcolor=#008000] - LayoutBlockFlow {DIV} at (0,60) size 20x20 [bgcolor=#008000] -layer at (8,308) size 20x40 - LayoutBlockFlow {DIV} at (0,0) size 20x40 - LayoutBlockFlow {DIV} at (0,0) size 20x20 [bgcolor=#008000] - LayoutBlockFlow {DIV} at (0,20) size 20x20 [bgcolor=#008000]
diff --git a/third_party/WebKit/LayoutTests/platform/mac/fast/multicol/composited-layer-will-change-expected.txt b/third_party/WebKit/LayoutTests/platform/mac/fast/multicol/composited-layer-will-change-expected.txt deleted file mode 100644 index 3dde79c..0000000 --- a/third_party/WebKit/LayoutTests/platform/mac/fast/multicol/composited-layer-will-change-expected.txt +++ /dev/null
@@ -1,69 +0,0 @@ -layer at (0,0) size 800x600 - LayoutView at (0,0) size 800x600 -layer at (0,0) size 800x424 - LayoutBlockFlow {HTML} at (0,0) size 800x424 - LayoutBlockFlow {BODY} at (8,16) size 784x360 - LayoutBlockFlow {P} at (0,0) size 784x36 - LayoutText {#text} at (0,0) size 741x36 - text run at (0,0) width 741: "If no compositing were present, there should be two green squares below. Since some elements are composited, and" - text run at (0,18) width 309: "therefore not fragmented, the output is different." -layer at (8,100) size 60x60 - LayoutBlockFlow {DIV} at (0,84) size 60x60 - LayoutMultiColumnSet (anonymous) at (0,0) size 60x60 -layer at (8,100) size 20x180 - LayoutMultiColumnFlowThread (anonymous) at (0,0) size 20x180 - LayoutBlockFlow {DIV} at (0,20) size 20x20 [bgcolor=#008000] - LayoutBlockFlow {DIV} at (0,80) size 20x20 [bgcolor=#008000] - LayoutBlockFlow {DIV} at (0,160) size 20x20 [bgcolor=#008000] -layer at (8,208) size 60x60 - LayoutBlockFlow {DIV} at (0,192) size 60x60 - LayoutMultiColumnSet (anonymous) at (0,0) size 60x60 -layer at (8,208) size 20x180 - LayoutMultiColumnFlowThread (anonymous) at (0,0) size 20x180 - LayoutBlockFlow {DIV} at (0,20) size 20x20 [bgcolor=#008000] - LayoutBlockFlow {DIV} at (0,80) size 20x20 [bgcolor=#008000] - LayoutBlockFlow {DIV} at (0,160) size 20x20 [bgcolor=#008000] -layer at (8,316) size 60x60 - LayoutBlockFlow {DIV} at (0,300) size 60x60 - LayoutMultiColumnSet (anonymous) at (0,0) size 60x60 -layer at (8,316) size 20x180 - LayoutMultiColumnFlowThread (anonymous) at (0,0) size 20x180 - LayoutBlockFlow {DIV} at (0,20) size 20x20 [bgcolor=#008000] - LayoutBlockFlow {DIV} at (0,80) size 20x20 [bgcolor=#008000] - LayoutBlockFlow {DIV} at (0,160) size 20x20 [bgcolor=#008000] -layer at (8,100) size 20x20 - LayoutBlockFlow {DIV} at (0,0) size 20x20 - LayoutBlockFlow {DIV} at (0,0) size 20x20 [bgcolor=#008000] -layer at (8,140) size 20x40 - LayoutBlockFlow {DIV} at (0,40) size 20x40 - LayoutBlockFlow {DIV} at (0,0) size 20x20 [bgcolor=#008000] - LayoutBlockFlow {DIV} at (0,20) size 20x20 [bgcolor=#008000] -layer at (8,200) size 20x60 - LayoutBlockFlow {DIV} at (0,100) size 20x60 - LayoutBlockFlow {DIV} at (0,0) size 20x20 [bgcolor=#008000] - LayoutBlockFlow {DIV} at (0,20) size 20x20 [bgcolor=#008000] - LayoutBlockFlow {DIV} at (0,40) size 20x20 [bgcolor=#008000] -layer at (8,208) size 20x20 - LayoutBlockFlow {DIV} at (0,0) size 20x20 - LayoutBlockFlow {DIV} at (0,0) size 20x20 [bgcolor=#008000] -layer at (8,248) size 20x40 - LayoutBlockFlow {DIV} at (0,40) size 20x40 - LayoutBlockFlow {DIV} at (0,0) size 20x20 [bgcolor=#008000] - LayoutBlockFlow {DIV} at (0,20) size 20x20 [bgcolor=#008000] -layer at (8,308) size 20x60 - LayoutBlockFlow {DIV} at (0,100) size 20x60 - LayoutBlockFlow {DIV} at (0,0) size 20x20 [bgcolor=#008000] - LayoutBlockFlow {DIV} at (0,20) size 20x20 [bgcolor=#008000] - LayoutBlockFlow {DIV} at (0,40) size 20x20 [bgcolor=#008000] -layer at (8,316) size 20x20 - LayoutBlockFlow (relative positioned) {DIV} at (0,0) size 20x20 - LayoutBlockFlow {DIV} at (0,0) size 20x20 [bgcolor=#008000] -layer at (8,356) size 20x40 - LayoutBlockFlow (relative positioned) {DIV} at (0,40) size 20x40 - LayoutBlockFlow {DIV} at (0,0) size 20x20 [bgcolor=#008000] - LayoutBlockFlow {DIV} at (0,20) size 20x20 [bgcolor=#008000] -layer at (8,416) size 20x60 - LayoutBlockFlow (relative positioned) {DIV} at (0,100) size 20x60 - LayoutBlockFlow {DIV} at (0,0) size 20x20 [bgcolor=#008000] - LayoutBlockFlow {DIV} at (0,20) size 20x20 [bgcolor=#008000] - LayoutBlockFlow {DIV} at (0,40) size 20x20 [bgcolor=#008000]
diff --git a/third_party/WebKit/LayoutTests/platform/mac/fast/multicol/composited-opacity-2nd-and-3rd-column-expected.txt b/third_party/WebKit/LayoutTests/platform/mac/fast/multicol/composited-opacity-2nd-and-3rd-column-expected.txt deleted file mode 100644 index 6980d31..0000000 --- a/third_party/WebKit/LayoutTests/platform/mac/fast/multicol/composited-opacity-2nd-and-3rd-column-expected.txt +++ /dev/null
@@ -1,40 +0,0 @@ -layer at (0,0) size 800x600 - LayoutView at (0,0) size 800x600 -layer at (0,0) size 800x284 - LayoutBlockFlow {HTML} at (0,0) size 800x284 - LayoutBlockFlow {BODY} at (8,16) size 784x260 - LayoutBlockFlow {P} at (0,0) size 784x36 - LayoutText {#text} at (0,0) size 211x18 - text run at (0,0) width 211: "The word 'PASS' should be seen " - LayoutInline {EM} at (0,0) size 35x18 - LayoutText {#text} at (210,0) size 35x18 - text run at (210,0) width 35: "twice" - LayoutText {#text} at (244,0) size 759x36 - text run at (244,0) width 515: " below. The second PASS is not overlapping the yellow because it is composited" - text run at (0,18) width 286: "with the first one, and hence not fragmented." -layer at (8,68) size 272x208 - LayoutBlockFlow {DIV} at (0,52) size 272x208 - LayoutMultiColumnSet (anonymous) at (0,0) size 272x208 -layer at (8,68) size 80x456 - LayoutMultiColumnFlowThread (anonymous) at (0,0) size 80x456 - LayoutBlockFlow (anonymous) at (0,0) size 80x368 - LayoutBR {BR} at (0,7) size 0x18 - LayoutBR {BR} at (0,39) size 0x18 - LayoutBR {BR} at (0,71) size 0x18 - LayoutBR {BR} at (0,103) size 0x18 - LayoutBR {BR} at (0,135) size 0x18 - LayoutBR {BR} at (0,167) size 0x18 - LayoutBR {BR} at (0,215) size 0x18 - LayoutBR {BR} at (0,247) size 0x18 - LayoutBR {BR} at (0,279) size 0x18 - LayoutBR {BR} at (0,311) size 0x18 - LayoutBR {BR} at (0,343) size 0x18 -layer at (0,68) size 800x128 - LayoutBlockFlow (positioned) {DIV} at (0,68) size 800x128 [bgcolor=#FFFF00] -layer at (16,444) size 64x72 transparent - LayoutBlockFlow {DIV} at (8,376) size 64x72 - LayoutText {#text} at (0,7) size 37x18 - text run at (0,7) width 37: "PASS" - LayoutBR {BR} at (36,7) size 1x18 - LayoutText {#text} at (0,47) size 37x18 - text run at (0,47) width 37: "PASS"
diff --git a/third_party/WebKit/LayoutTests/platform/mac/fast/multicol/composited-relpos-clipped-expected.txt b/third_party/WebKit/LayoutTests/platform/mac/fast/multicol/composited-relpos-clipped-expected.txt deleted file mode 100644 index bb5bbfa5..0000000 --- a/third_party/WebKit/LayoutTests/platform/mac/fast/multicol/composited-relpos-clipped-expected.txt +++ /dev/null
@@ -1,39 +0,0 @@ -layer at (0,0) size 800x600 - LayoutView at (0,0) size 800x600 -layer at (0,0) size 800x284 - LayoutBlockFlow {HTML} at (0,0) size 800x284 - LayoutBlockFlow {BODY} at (8,16) size 784x260 - LayoutBlockFlow {P} at (0,0) size 784x36 - LayoutText {#text} at (0,0) size 780x36 - text run at (0,0) width 780: "There should be one yellow boxes below, on a blue background. There is only one because the content is composited, and" - text run at (0,18) width 143: "hence not fragmented." -layer at (8,68) size 272x208 - LayoutBlockFlow {DIV} at (0,52) size 272x208 - LayoutMultiColumnSet (anonymous) at (0,0) size 272x208 -layer at (8,68) size 128x280 - LayoutMultiColumnFlowThread (anonymous) at (0,0) size 128x280 - LayoutBlockFlow (anonymous) at (0,0) size 128x128 - LayoutBR {BR} at (0,7) size 0x18 - LayoutBR {BR} at (0,39) size 0x18 - LayoutBR {BR} at (0,71) size 0x18 - LayoutBR {BR} at (0,103) size 0x18 -layer at (0,68) size 800x208 - LayoutBlockFlow (positioned) {DIV} at (0,68) size 800x208 [bgcolor=#0000FF] -layer at (16,204) size 112x136 scrollHeight 168 - LayoutBlockFlow (relative positioned) {DIV} at (8,136) size 112x136 [bgcolor=#FFFF00] - LayoutBlockFlow (anonymous) at (0,0) size 112x136 - LayoutText {#text} at (0,7) size 25x18 - text run at (0,7) width 25: "first" - LayoutBR {BR} at (24,7) size 1x18 - LayoutText {#text} at (0,39) size 48x18 - text run at (0,39) width 48: "column" - LayoutBR {BR} at (47,39) size 1x18 - LayoutText {#text} at (0,79) size 45x18 - text run at (0,79) width 45: "second" - LayoutBR {BR} at (44,79) size 1x18 - LayoutText {#text} at (0,111) size 48x18 - text run at (0,111) width 48: "column" - LayoutBR {BR} at (47,111) size 1x18 - LayoutBlockFlow {DIV} at (0,136) size 112x32 [bgcolor=#FF0000] - LayoutText {#text} at (0,7) size 35x18 - text run at (0,7) width 35: "FAIL"
diff --git a/third_party/WebKit/LayoutTests/platform/mac/fast/multicol/composited-relpos-expected.txt b/third_party/WebKit/LayoutTests/platform/mac/fast/multicol/composited-relpos-expected.txt deleted file mode 100644 index 87ae309..0000000 --- a/third_party/WebKit/LayoutTests/platform/mac/fast/multicol/composited-relpos-expected.txt +++ /dev/null
@@ -1,36 +0,0 @@ -layer at (0,0) size 800x600 - LayoutView at (0,0) size 800x600 -layer at (0,0) size 800x284 - LayoutBlockFlow {HTML} at (0,0) size 800x284 - LayoutBlockFlow {BODY} at (8,16) size 784x260 - LayoutBlockFlow {P} at (0,0) size 784x36 - LayoutText {#text} at (0,0) size 763x36 - text run at (0,0) width 398: "There should be one yellow boxbelow, on a blue background. " - text run at (397,0) width 366: "There is only one because the content is composited, and" - text run at (0,18) width 143: "hence not fragmented." -layer at (8,68) size 272x208 - LayoutBlockFlow {DIV} at (0,52) size 272x208 - LayoutMultiColumnSet (anonymous) at (0,0) size 272x208 -layer at (8,68) size 128x280 - LayoutMultiColumnFlowThread (anonymous) at (0,0) size 128x280 - LayoutBlockFlow (anonymous) at (0,0) size 128x128 - LayoutBR {BR} at (0,7) size 0x18 - LayoutBR {BR} at (0,39) size 0x18 - LayoutBR {BR} at (0,71) size 0x18 - LayoutBR {BR} at (0,103) size 0x18 -layer at (0,68) size 800x208 - LayoutBlockFlow (positioned) {DIV} at (0,68) size 800x208 [bgcolor=#0000FF] -layer at (16,204) size 112x136 - LayoutBlockFlow (relative positioned) {DIV} at (8,136) size 112x136 [bgcolor=#FFFF00] - LayoutText {#text} at (0,7) size 25x18 - text run at (0,7) width 25: "first" - LayoutBR {BR} at (24,7) size 1x18 - LayoutText {#text} at (0,39) size 48x18 - text run at (0,39) width 48: "column" - LayoutBR {BR} at (47,39) size 1x18 - LayoutText {#text} at (0,79) size 45x18 - text run at (0,79) width 45: "second" - LayoutBR {BR} at (44,79) size 1x18 - LayoutText {#text} at (0,111) size 48x18 - text run at (0,111) width 48: "column" - LayoutBR {BR} at (47,111) size 1x18
diff --git a/third_party/WebKit/LayoutTests/platform/mac/fast/multicol/composited-relpos-in-clipped-expected.txt b/third_party/WebKit/LayoutTests/platform/mac/fast/multicol/composited-relpos-in-clipped-expected.txt deleted file mode 100644 index d3a04fa..0000000 --- a/third_party/WebKit/LayoutTests/platform/mac/fast/multicol/composited-relpos-in-clipped-expected.txt +++ /dev/null
@@ -1,38 +0,0 @@ -layer at (0,0) size 800x600 - LayoutView at (0,0) size 800x600 -layer at (0,0) size 800x266 - LayoutBlockFlow {HTML} at (0,0) size 800x266 - LayoutBlockFlow {BODY} at (8,16) size 784x242 - LayoutBlockFlow {P} at (0,0) size 784x18 - LayoutText {#text} at (0,0) size 710x18 - text run at (0,0) width 710: "There should be one yellow box below, on a blue background. the \"second column\" part should be clipped out." -layer at (8,50) size 272x208 - LayoutBlockFlow {DIV} at (0,34) size 272x208 - LayoutMultiColumnSet (anonymous) at (0,0) size 272x208 -layer at (8,50) size 128x280 backgroundClip at (8,50) size 272x208 clip at (8,50) size 272x208 - LayoutMultiColumnFlowThread (anonymous) at (0,0) size 128x280 - LayoutBlockFlow (anonymous) at (0,0) size 128x128 - LayoutBR {BR} at (0,7) size 0x18 - LayoutBR {BR} at (0,39) size 0x18 - LayoutBR {BR} at (0,71) size 0x18 - LayoutBR {BR} at (0,103) size 0x18 -layer at (0,50) size 800x208 - LayoutBlockFlow (positioned) {DIV} at (0,50) size 800x208 [bgcolor=#0000FF] -layer at (16,186) size 112x136 backgroundClip at (16,186) size 112x72 clip at (16,186) size 112x72 scrollHeight 168 - LayoutBlockFlow (relative positioned) {DIV} at (8,136) size 112x136 [bgcolor=#FFFF00] - LayoutBlockFlow (anonymous) at (0,0) size 112x136 - LayoutText {#text} at (0,7) size 25x18 - text run at (0,7) width 25: "first" - LayoutBR {BR} at (24,7) size 1x18 - LayoutText {#text} at (0,39) size 48x18 - text run at (0,39) width 48: "column" - LayoutBR {BR} at (47,39) size 1x18 - LayoutText {#text} at (0,79) size 45x18 - text run at (0,79) width 45: "second" - LayoutBR {BR} at (44,79) size 1x18 - LayoutText {#text} at (0,111) size 48x18 - text run at (0,111) width 48: "column" - LayoutBR {BR} at (47,111) size 1x18 - LayoutBlockFlow {DIV} at (0,136) size 112x32 [bgcolor=#FF0000] - LayoutText {#text} at (0,7) size 35x18 - text run at (0,7) width 35: "FAIL"
diff --git a/third_party/WebKit/LayoutTests/platform/mac/fast/multicol/composited-relpos-overlapping-will-change-expected.txt b/third_party/WebKit/LayoutTests/platform/mac/fast/multicol/composited-relpos-overlapping-will-change-expected.txt deleted file mode 100644 index 932c22d..0000000 --- a/third_party/WebKit/LayoutTests/platform/mac/fast/multicol/composited-relpos-overlapping-will-change-expected.txt +++ /dev/null
@@ -1,41 +0,0 @@ -layer at (0,0) size 800x600 - LayoutView at (0,0) size 800x600 -layer at (0,0) size 800x284 - LayoutBlockFlow {HTML} at (0,0) size 800x284 - LayoutBlockFlow {BODY} at (8,16) size 784x260 - LayoutBlockFlow {P} at (0,0) size 784x36 - LayoutText {#text} at (0,0) size 211x18 - text run at (0,0) width 211: "The word 'PASS' should be seen " - LayoutInline {EM} at (0,0) size 35x18 - LayoutText {#text} at (210,0) size 35x18 - text run at (210,0) width 35: "twice" - LayoutText {#text} at (244,0) size 759x36 - text run at (244,0) width 51: " below. " - text run at (294,0) width 465: "The second PASS is not overlapping the yellow because it is composited" - text run at (0,18) width 286: "with the first one, and hence not fragmented." -layer at (8,68) size 560x208 - LayoutBlockFlow {DIV} at (0,52) size 560x208 - LayoutMultiColumnSet (anonymous) at (0,0) size 560x208 -layer at (8,68) size 176x456 - LayoutMultiColumnFlowThread (anonymous) at (0,0) size 176x456 - LayoutBlockFlow (anonymous) at (0,0) size 176x368 - LayoutBR {BR} at (0,7) size 0x18 - LayoutBR {BR} at (0,39) size 0x18 - LayoutBR {BR} at (0,71) size 0x18 - LayoutBR {BR} at (0,103) size 0x18 - LayoutBR {BR} at (0,135) size 0x18 - LayoutBR {BR} at (0,167) size 0x18 - LayoutBR {BR} at (0,215) size 0x18 - LayoutBR {BR} at (0,247) size 0x18 - LayoutBR {BR} at (0,279) size 0x18 - LayoutBR {BR} at (0,311) size 0x18 - LayoutBR {BR} at (0,343) size 0x18 -layer at (0,68) size 800x128 - LayoutBlockFlow (positioned) {DIV} at (0,68) size 800x128 [bgcolor=#FFFF00] -layer at (16,444) size 160x72 - LayoutBlockFlow (relative positioned) {DIV} at (8,376) size 160x72 - LayoutText {#text} at (0,7) size 37x18 - text run at (0,7) width 37: "PASS" - LayoutBR {BR} at (36,7) size 1x18 - LayoutText {#text} at (0,47) size 37x18 - text run at (0,47) width 37: "PASS"
diff --git a/third_party/WebKit/LayoutTests/platform/mac/fast/multicol/composited-relpos-resize-expected.txt b/third_party/WebKit/LayoutTests/platform/mac/fast/multicol/composited-relpos-resize-expected.txt deleted file mode 100644 index bf547b2..0000000 --- a/third_party/WebKit/LayoutTests/platform/mac/fast/multicol/composited-relpos-resize-expected.txt +++ /dev/null
@@ -1,34 +0,0 @@ -layer at (0,0) size 800x600 - LayoutView at (0,0) size 800x600 -layer at (0,0) size 800x266 - LayoutBlockFlow {HTML} at (0,0) size 800x266 - LayoutBlockFlow {BODY} at (8,16) size 784x242 - LayoutBlockFlow {P} at (0,0) size 784x18 - LayoutText {#text} at (0,0) size 767x18 - text run at (0,0) width 767: "There should be one yellow box below. There is only one because the content is composited, and hence not fragmented." -layer at (8,50) size 706x208 - LayoutBlockFlow {DIV} at (0,34) size 705.59x208 - LayoutMultiColumnSet (anonymous) at (0,0) size 705.59x208 -layer at (8,50) size 353x280 - LayoutMultiColumnFlowThread (anonymous) at (0,0) size 352.80x280 - LayoutBlockFlow (anonymous) at (0,0) size 352.80x128 - LayoutBR {BR} at (0,7) size 0x18 - LayoutBR {BR} at (0,39) size 0x18 - LayoutBR {BR} at (0,71) size 0x18 - LayoutBR {BR} at (0,103) size 0x18 -layer at (0,50) size 800x240 - LayoutBlockFlow (positioned) {DIV} at (0,50) size 800x240 [bgcolor=#00FFFF] -layer at (16,186) size 337x136 - LayoutBlockFlow (relative positioned) {DIV} at (8,136) size 336.80x136 [bgcolor=#FFFF00] - LayoutText {#text} at (0,7) size 25x18 - text run at (0,7) width 25: "first" - LayoutBR {BR} at (24,7) size 1x18 - LayoutText {#text} at (0,39) size 48x18 - text run at (0,39) width 48: "column" - LayoutBR {BR} at (47,39) size 1x18 - LayoutText {#text} at (0,79) size 45x18 - text run at (0,79) width 45: "second" - LayoutBR {BR} at (44,79) size 1x18 - LayoutText {#text} at (0,111) size 48x18 - text run at (0,111) width 48: "column" - LayoutBR {BR} at (47,111) size 1x18
diff --git a/third_party/WebKit/LayoutTests/platform/mac/fast/multicol/composited-with-child-layer-in-next-column-expected.txt b/third_party/WebKit/LayoutTests/platform/mac/fast/multicol/composited-with-child-layer-in-next-column-expected.txt deleted file mode 100644 index 8649d07..0000000 --- a/third_party/WebKit/LayoutTests/platform/mac/fast/multicol/composited-with-child-layer-in-next-column-expected.txt +++ /dev/null
@@ -1,33 +0,0 @@ -layer at (0,0) size 800x600 - LayoutView at (0,0) size 800x600 -layer at (0,0) size 800x220 - LayoutBlockFlow {HTML} at (0,0) size 800x220 - LayoutBlockFlow {BODY} at (8,16) size 784x196 - LayoutBlockFlow {P} at (0,0) size 784x36 - LayoutText {#text} at (0,0) size 749x36 - text run at (0,0) width 749: "There should be a yellow box in the second column, and the word 'PASS' should be below it. PASS is not in the third" - text run at (0,18) width 469: "column because they are composited together, and hence not fragmented." -layer at (8,68) size 272x144 - LayoutBlockFlow {DIV} at (0,52) size 272x144 - LayoutMultiColumnSet (anonymous) at (0,0) size 272x144 -layer at (8,68) size 80x272 - LayoutMultiColumnFlowThread (anonymous) at (0,0) size 80x272 - LayoutBlockFlow (anonymous) at (0,0) size 80x240 - LayoutBR {BR} at (0,7) size 0x18 - LayoutBR {BR} at (0,39) size 0x18 - LayoutBR {BR} at (0,71) size 0x18 - LayoutBR {BR} at (0,103) size 0x18 - LayoutBR {BR} at (0,151) size 0x18 - LayoutBR {BR} at (0,183) size 0x18 - LayoutBR {BR} at (0,215) size 0x18 -layer at (0,68) size 800x144 - LayoutBlockFlow (positioned) {DIV} at (0,68) size 800x144 [bgcolor=#00FFFF] -layer at (8,308) size 80x32 - LayoutBlockFlow (relative positioned) zI: 2 {DIV} at (0,240) size 80x32 [bgcolor=#FFFF00] - LayoutBlockFlow (anonymous) at (0,0) size 80x80 - LayoutBR {BR} at (0,7) size 0x18 - LayoutBR {BR} at (0,55) size 0x18 -layer at (16,396) size 64x32 transparent - LayoutBlockFlow {DIV} at (8,88) size 64x32 - LayoutText {#text} at (0,7) size 37x18 - text run at (0,7) width 37: "PASS"
diff --git a/third_party/WebKit/LayoutTests/platform/mac/fast/multicol/composited-with-overflow-in-next-column-expected.txt b/third_party/WebKit/LayoutTests/platform/mac/fast/multicol/composited-with-overflow-in-next-column-expected.txt deleted file mode 100644 index 2994c272..0000000 --- a/third_party/WebKit/LayoutTests/platform/mac/fast/multicol/composited-with-overflow-in-next-column-expected.txt +++ /dev/null
@@ -1,29 +0,0 @@ -layer at (0,0) size 800x600 - LayoutView at (0,0) size 800x600 -layer at (0,0) size 800x202 - LayoutBlockFlow {HTML} at (0,0) size 800x202 - LayoutBlockFlow {BODY} at (8,16) size 784x178 - LayoutBlockFlow {P} at (0,0) size 784x18 - LayoutText {#text} at (0,0) size 383x18 - text run at (0,0) width 383: "The word 'PASS' should be seen below, in the third column." -layer at (8,50) size 784x144 - LayoutBlockFlow {DIV} at (0,34) size 784x144 - LayoutMultiColumnSet (anonymous) at (0,0) size 784x144 -layer at (8,50) size 251x256 - LayoutMultiColumnFlowThread (anonymous) at (0,0) size 250.66x256 - LayoutBlockFlow (anonymous) at (0,0) size 250.66x240 - LayoutBR {BR} at (0,7) size 0x18 - LayoutBR {BR} at (0,39) size 0x18 - LayoutBR {BR} at (0,71) size 0x18 - LayoutBR {BR} at (0,103) size 0x18 - LayoutBR {BR} at (0,151) size 0x18 - LayoutBR {BR} at (0,183) size 0x18 - LayoutBR {BR} at (0,215) size 0x18 -layer at (0,98) size 800x18 - LayoutBlockFlow (positioned) {DIV} at (0,98) size 800x18 [border: (1px dotted #000000)] -layer at (8,290) size 251x16 - LayoutBlockFlow (relative positioned) {DIV} at (0,240) size 250.66x16 - LayoutBR {BR} at (0,7) size 0x18 - LayoutBR {BR} at (0,55) size 0x18 - LayoutText {#text} at (0,87) size 37x18 - text run at (0,87) width 37: "PASS"
diff --git a/third_party/WebKit/LayoutTests/platform/mac/fast/multicol/multicol-with-child-renderLayer-for-input-expected.txt b/third_party/WebKit/LayoutTests/platform/mac/fast/multicol/multicol-with-child-renderLayer-for-input-expected.txt deleted file mode 100644 index 6589629..0000000 --- a/third_party/WebKit/LayoutTests/platform/mac/fast/multicol/multicol-with-child-renderLayer-for-input-expected.txt +++ /dev/null
@@ -1,29 +0,0 @@ -layer at (0,0) size 800x600 - LayoutView at (0,0) size 800x600 -layer at (0,0) size 800x600 - LayoutBlockFlow {HTML} at (0,0) size 800x600 - LayoutBlockFlow {BODY} at (8,8) size 784x584 -layer at (8,8) size 784x59 - LayoutBlockFlow {DIV} at (0,0) size 784x59 - LayoutMultiColumnSet (anonymous) at (0,0) size 784x59 -layer at (8,8) size 384x118 - LayoutMultiColumnFlowThread (anonymous) at (0,0) size 384x118 - LayoutText {#text} at (0,0) size 351x115 - text run at (0,0) width 71: "Filler Text " - text run at (70,0) width 281: "Filler Text Filler Text Filler Text Filler Text" - text run at (0,18) width 284: "Filler Text Filler Text Filler Text Filler Text " - text run at (283,18) width 68: "Filler Text" - text run at (0,36) width 351: "Filler Text Filler Text Filler Text Filler Text Filler Text" - text run at (0,59) width 213: "Filler Text Filler Text Filler Text " - text run at (212,59) width 72: "Filler Text " - text run at (283,59) width 68: "Filler Text" - text run at (0,77) width 351: "Filler Text Filler Text Filler Text Filler Text Filler Text" - text run at (0,97) width 142: "Filler Text Filler Text " - LayoutText {#text} at (0,0) size 0x0 -layer at (152,105) size 131x19 clip at (154,107) size 127x15 - LayoutTextControl (relative positioned) {INPUT} at (143.73,97) size 131x19 [bgcolor=#FFFFFF] [border: (2px inset #EEEEEE)] -layer at (155,108) size 125x13 backgroundClip at (0,0) size 0x0 clip at (0,0) size 0x0 - LayoutBlockFlow {DIV} at (3,3) size 125x13 - LayoutText {#text} at (0,0) size 39x13 - text run at (0,0) width 39: "Testing" -caret: position 7 of child 0 {#text} of child 0 {DIV} of {#document-fragment} of child 1 {INPUT} of child 1 {DIV} of body
diff --git a/third_party/WebKit/LayoutTests/platform/mac/fast/multicol/span/invalid-spanner-in-transform-expected.txt b/third_party/WebKit/LayoutTests/platform/mac/fast/multicol/span/invalid-spanner-in-transform-expected.txt deleted file mode 100644 index 3071c6d0..0000000 --- a/third_party/WebKit/LayoutTests/platform/mac/fast/multicol/span/invalid-spanner-in-transform-expected.txt +++ /dev/null
@@ -1,19 +0,0 @@ -layer at (0,0) size 800x600 - LayoutView at (0,0) size 800x600 -layer at (0,0) size 800x108 - LayoutBlockFlow {HTML} at (0,0) size 800x108 - LayoutBlockFlow {BODY} at (8,16) size 784x84 - LayoutBlockFlow {P} at (0,0) size 784x18 - LayoutText {#text} at (0,0) size 756x18 - text run at (0,0) width 258: "There should be one blue square below. " - text run at (257,0) width 499: "It is not two because they are composited together, and hence not fragmented." -layer at (8,50) size 110x50 - LayoutBlockFlow {DIV} at (0,34) size 110x50 - LayoutMultiColumnSet (anonymous) at (0,0) size 110x50 -layer at (8,50) size 50x100 - LayoutMultiColumnFlowThread (anonymous) at (0,0) size 50x100 -layer at (8,50) size 50x100 - LayoutBlockFlow {DIV} at (0,0) size 50x100 - LayoutBlockFlow {DIV} at (0,0) size 50x100 [bgcolor=#0000FF] - LayoutBR {BR} at (0,16) size 0x18 - LayoutBR {BR} at (0,66) size 0x18
diff --git a/third_party/WebKit/LayoutTests/platform/mac/fast/multicol/vertical-lr/composited-relpos-overlapping-will-change-expected.txt b/third_party/WebKit/LayoutTests/platform/mac/fast/multicol/vertical-lr/composited-relpos-overlapping-will-change-expected.txt deleted file mode 100644 index f8b001b..0000000 --- a/third_party/WebKit/LayoutTests/platform/mac/fast/multicol/vertical-lr/composited-relpos-overlapping-will-change-expected.txt +++ /dev/null
@@ -1,42 +0,0 @@ -layer at (0,0) size 800x600 - LayoutView at (0,0) size 800x600 -layer at (0,0) size 800x492 - LayoutBlockFlow {HTML} at (0,0) size 800x492 - LayoutBlockFlow {BODY} at (8,16) size 784x468 - LayoutBlockFlow {P} at (0,0) size 784x36 - LayoutText {#text} at (0,0) size 211x18 - text run at (0,0) width 211: "The word 'PASS' should be seen " - LayoutInline {EM} at (0,0) size 35x18 - LayoutText {#text} at (210,0) size 35x18 - text run at (210,0) width 35: "twice" - LayoutText {#text} at (244,0) size 715x36 - text run at (244,0) width 471: " below. They appear together because they are composited, and hence not" - text run at (0,18) width 77: "fragmented." -layer at (8,68) size 208x416 - LayoutBlockFlow {DIV} at (0,52) size 208x416 - LayoutMultiColumnSet (anonymous) at (0,0) size 208x416 -layer at (8,68) size 456x128 - LayoutMultiColumnFlowThread (anonymous) at (0,0) size 456x128 - LayoutBlockFlow (anonymous) at (0,0) size 368x128 - LayoutBR {BR} at (7,0) size 18x0 - LayoutBR {BR} at (39,0) size 18x0 - LayoutBR {BR} at (71,0) size 18x0 - LayoutBR {BR} at (103,0) size 18x0 - LayoutBR {BR} at (135,0) size 18x0 - LayoutBR {BR} at (167,0) size 18x0 - LayoutBR {BR} at (215,0) size 18x0 - LayoutBR {BR} at (247,0) size 18x0 - LayoutBR {BR} at (279,0) size 18x0 - LayoutBR {BR} at (311,0) size 18x0 - LayoutText {#text} at (343,0) size 18x6 - text run at (343,0) width 6: "r" - LayoutBR {BR} at (343,5) size 18x1 -layer at (0,64) size 160x288 - LayoutBlockFlow (positioned) {DIV} at (0,64) size 160x288 [bgcolor=#FFFF00] -layer at (384,76) size 72x112 - LayoutBlockFlow (relative positioned) {DIV} at (376,8) size 72x112 - LayoutText {#text} at (7,0) size 18x37 - text run at (7,0) width 37: "PASS" - LayoutBR {BR} at (7,36) size 18x1 - LayoutText {#text} at (47,0) size 18x37 - text run at (47,0) width 37: "PASS"
diff --git a/third_party/WebKit/LayoutTests/platform/mac/fast/multicol/vertical-rl/composited-relpos-overlapping-will-change-expected.txt b/third_party/WebKit/LayoutTests/platform/mac/fast/multicol/vertical-rl/composited-relpos-overlapping-will-change-expected.txt deleted file mode 100644 index 422a656..0000000 --- a/third_party/WebKit/LayoutTests/platform/mac/fast/multicol/vertical-rl/composited-relpos-overlapping-will-change-expected.txt +++ /dev/null
@@ -1,40 +0,0 @@ -layer at (0,0) size 800x600 - LayoutView at (0,0) size 800x600 -layer at (0,0) size 800x492 - LayoutBlockFlow {HTML} at (0,0) size 800x492 - LayoutBlockFlow {BODY} at (8,16) size 784x468 - LayoutBlockFlow {P} at (0,0) size 784x36 - LayoutText {#text} at (0,0) size 211x18 - text run at (0,0) width 211: "The word 'PASS' should be seen " - LayoutInline {EM} at (0,0) size 35x18 - LayoutText {#text} at (210,0) size 35x18 - text run at (210,0) width 35: "twice" - LayoutText {#text} at (244,0) size 715x36 - text run at (244,0) width 471: " below. They appear together because they are composited, and hence not" - text run at (0,18) width 77: "fragmented." -layer at (8,68) size 208x416 - LayoutBlockFlow {DIV} at (0,52) size 208x416 - LayoutMultiColumnSet (anonymous) at (0,0) size 208x416 -layer at (-240,68) size 456x128 backgroundClip at (0,0) size 800x600 clip at (0,0) size 800x600 - LayoutMultiColumnFlowThread (anonymous) at (0,0) size 456x128 - LayoutBlockFlow (anonymous) at (0,0) size 368x128 - LayoutBR {BR} at (7,0) size 18x0 - LayoutBR {BR} at (39,0) size 18x0 - LayoutBR {BR} at (71,0) size 18x0 - LayoutBR {BR} at (103,0) size 18x0 - LayoutBR {BR} at (135,0) size 18x0 - LayoutBR {BR} at (167,0) size 18x0 - LayoutBR {BR} at (215,0) size 18x0 - LayoutBR {BR} at (247,0) size 18x0 - LayoutBR {BR} at (279,0) size 18x0 - LayoutBR {BR} at (311,0) size 18x0 - LayoutBR {BR} at (343,0) size 18x0 -layer at (0,64) size 160x288 - LayoutBlockFlow (positioned) {DIV} at (0,64) size 160x288 [bgcolor=#FFFF00] -layer at (-232,76) size 72x112 backgroundClip at (0,0) size 800x600 clip at (0,0) size 800x600 - LayoutBlockFlow (relative positioned) {DIV} at (376,8) size 72x112 - LayoutText {#text} at (7,0) size 18x37 - text run at (7,0) width 37: "PASS" - LayoutBR {BR} at (7,36) size 18x1 - LayoutText {#text} at (47,0) size 18x37 - text run at (47,0) width 37: "PASS"
diff --git a/third_party/WebKit/LayoutTests/platform/win/editing/deleting/merge-whitespace-pre-expected.png b/third_party/WebKit/LayoutTests/platform/win/editing/deleting/merge-whitespace-pre-expected.png deleted file mode 100644 index 5114af8..0000000 --- a/third_party/WebKit/LayoutTests/platform/win/editing/deleting/merge-whitespace-pre-expected.png +++ /dev/null Binary files differ
diff --git a/third_party/WebKit/LayoutTests/platform/win/editing/deleting/merge-whitespace-pre-expected.txt b/third_party/WebKit/LayoutTests/platform/win/editing/deleting/merge-whitespace-pre-expected.txt deleted file mode 100644 index ef270e3..0000000 --- a/third_party/WebKit/LayoutTests/platform/win/editing/deleting/merge-whitespace-pre-expected.txt +++ /dev/null
@@ -1,18 +0,0 @@ -layer at (0,0) size 800x600 - LayoutView at (0,0) size 800x600 -layer at (0,0) size 800x600 - LayoutBlockFlow {HTML} at (0,0) size 800x600 - LayoutBlockFlow {BODY} at (8,8) size 784x579 - LayoutBlockFlow {P} at (0,0) size 784x40 - LayoutText {#text} at (0,0) size 777x39 - text run at (0,0) width 352: "This test places the caret before the 'b' in 'bar' and Delete. " - text run at (352,0) width 425: "Afterword, 'foobar' should be in the first paragraph and 'baz' should be" - text run at (0,20) width 83: "in the second." - LayoutBlockFlow {DIV} at (0,56) size 784x49 - LayoutBlockFlow {DIV} at (0,0) size 784x20 - LayoutText {#text} at (0,0) size 40x19 - text run at (0,0) width 40: "foobar" - LayoutBlockFlow {PRE} at (0,33) size 784x16 - LayoutText {#text} at (0,0) size 24x16 - text run at (0,0) width 24: "baz" -caret: position 3 of child 0 {#text} of child 1 {DIV} of child 2 {DIV} of body
diff --git a/third_party/WebKit/LayoutTests/platform/win/editing/inserting/4875189-1-expected.png b/third_party/WebKit/LayoutTests/platform/win/editing/inserting/4875189-1-expected.png deleted file mode 100644 index fcdd11d..0000000 --- a/third_party/WebKit/LayoutTests/platform/win/editing/inserting/4875189-1-expected.png +++ /dev/null Binary files differ
diff --git a/third_party/WebKit/LayoutTests/platform/win/editing/inserting/4875189-1-expected.txt b/third_party/WebKit/LayoutTests/platform/win/editing/inserting/4875189-1-expected.txt deleted file mode 100644 index 50866ba81..0000000 --- a/third_party/WebKit/LayoutTests/platform/win/editing/inserting/4875189-1-expected.txt +++ /dev/null
@@ -1,16 +0,0 @@ -layer at (0,0) size 800x600 - LayoutView at (0,0) size 800x600 -layer at (0,0) size 800x600 - LayoutBlockFlow {HTML} at (0,0) size 800x600 - LayoutBlockFlow {BODY} at (8,8) size 784x576 - LayoutBlockFlow {P} at (0,0) size 784x20 - LayoutText {#text} at (0,0) size 619x19 - text run at (0,0) width 339: "This tests for a bug when replacing the contents of a list. " - text run at (339,0) width 280: "The list shouldn't be removed, just its contents." - LayoutBlockFlow {DIV} at (0,36) size 784x20 - LayoutBlockFlow {UL} at (0,0) size 784x20 - LayoutListItem {LI} at (40,0) size 744x20 - LayoutListMarker (anonymous) at (-18,0) size 7x19: bullet - LayoutText {#text} at (0,0) size 165x19 - text run at (0,0) width 165: "This should be in a list item." -caret: position 30 of child 0 {#text} of child 0 {LI} of child 0 {UL} of child 2 {DIV} of body
diff --git a/third_party/WebKit/LayoutTests/platform/win/editing/inserting/4959067-expected.png b/third_party/WebKit/LayoutTests/platform/win/editing/inserting/4959067-expected.png deleted file mode 100644 index 775ecc0..0000000 --- a/third_party/WebKit/LayoutTests/platform/win/editing/inserting/4959067-expected.png +++ /dev/null Binary files differ
diff --git a/third_party/WebKit/LayoutTests/platform/win/editing/inserting/4959067-expected.txt b/third_party/WebKit/LayoutTests/platform/win/editing/inserting/4959067-expected.txt deleted file mode 100644 index fdc18e4..0000000 --- a/third_party/WebKit/LayoutTests/platform/win/editing/inserting/4959067-expected.txt +++ /dev/null
@@ -1,17 +0,0 @@ -layer at (0,0) size 800x600 - LayoutView at (0,0) size 800x600 -layer at (0,0) size 800x600 - LayoutBlockFlow {HTML} at (0,0) size 800x600 - LayoutBlockFlow {BODY} at (8,8) size 784x576 - LayoutBlockFlow {P} at (0,0) size 784x20 - LayoutText {#text} at (0,0) size 571x19 - text run at (0,0) width 571: "This tests to make sure that insertion over a fully selected special element doesn't do expansion." - LayoutBlockFlow {DIV} at (0,36) size 784x20 - LayoutBlockFlow {UL} at (0,0) size 784x20 - LayoutListItem {LI} at (40,0) size 744x20 - LayoutListMarker (anonymous) at (-18,0) size 7x19: bullet - LayoutInline {A} at (0,0) size 20x19 [color=#0000EE] - LayoutText {#text} at (0,0) size 20x19 - text run at (0,0) width 20: "foo" - LayoutBlockFlow {UL} at (0,72) size 784x0 -caret: position 3 of child 0 {#text} of child 0 {A} of child 0 {LI} of child 1 {UL} of child 2 {DIV} of body
diff --git a/third_party/WebKit/LayoutTests/platform/win/editing/inserting/editable-inline-element-expected.png b/third_party/WebKit/LayoutTests/platform/win/editing/inserting/editable-inline-element-expected.png deleted file mode 100644 index 481fd31..0000000 --- a/third_party/WebKit/LayoutTests/platform/win/editing/inserting/editable-inline-element-expected.png +++ /dev/null Binary files differ
diff --git a/third_party/WebKit/LayoutTests/platform/win/editing/inserting/editable-inline-element-expected.txt b/third_party/WebKit/LayoutTests/platform/win/editing/inserting/editable-inline-element-expected.txt deleted file mode 100644 index 667239d8..0000000 --- a/third_party/WebKit/LayoutTests/platform/win/editing/inserting/editable-inline-element-expected.txt +++ /dev/null
@@ -1,14 +0,0 @@ -layer at (0,0) size 800x600 - LayoutView at (0,0) size 800x600 -layer at (0,0) size 800x600 - LayoutBlockFlow {HTML} at (0,0) size 800x600 - LayoutBlockFlow {BODY} at (8,8) size 784x584 - LayoutBlockFlow {P} at (0,0) size 784x20 - LayoutText {#text} at (0,0) size 351x19 - text run at (0,0) width 351: "This tests InsertParagraph inside an editable inline element." - LayoutBlockFlow {DIV} at (0,36) size 784x42 [border: (1px solid #FF0000)] - LayoutInline {SPAN} at (0,0) size 20x39 - LayoutBR {BR} at (1,1) size 0x19 - LayoutText {#text} at (1,21) size 20x19 - text run at (1,21) width 20: "foo" -caret: position 0 of child 1 {#text} of child 0 {SPAN} of child 2 {DIV} of body
diff --git a/third_party/WebKit/LayoutTests/platform/win/editing/selection/focus-body-expected.png b/third_party/WebKit/LayoutTests/platform/win/editing/selection/focus-body-expected.png deleted file mode 100644 index 9a0a489..0000000 --- a/third_party/WebKit/LayoutTests/platform/win/editing/selection/focus-body-expected.png +++ /dev/null Binary files differ
diff --git a/third_party/WebKit/LayoutTests/platform/win/editing/selection/focus-body-expected.txt b/third_party/WebKit/LayoutTests/platform/win/editing/selection/focus-body-expected.txt deleted file mode 100644 index 064dc78..0000000 --- a/third_party/WebKit/LayoutTests/platform/win/editing/selection/focus-body-expected.txt +++ /dev/null
@@ -1,10 +0,0 @@ -EDITING DELEGATE: webViewDidChangeSelection:WebViewDidChangeSelectionNotification -layer at (0,0) size 800x600 - LayoutView at (0,0) size 800x600 -layer at (0,0) size 800x600 - LayoutBlockFlow {HTML} at (0,0) size 800x600 - LayoutBlockFlow {BODY} at (8,8) size 784x584 - LayoutText {#text} at (0,0) size 421x19 - text run at (0,0) width 210: "This test focuses an editable body. " - text run at (210,0) width 211: "Its contents should not be selected." -caret: position 0 of child 0 {#text} of body
diff --git a/third_party/WebKit/LayoutTests/platform/win/external/wpt/streams/readable-streams/default-reader.sharedworker-expected.txt b/third_party/WebKit/LayoutTests/platform/win/external/wpt/streams/readable-streams/default-reader.sharedworker-expected.txt new file mode 100644 index 0000000..0426dc27 --- /dev/null +++ b/third_party/WebKit/LayoutTests/platform/win/external/wpt/streams/readable-streams/default-reader.sharedworker-expected.txt
@@ -0,0 +1,30 @@ +This is a testharness.js-based test. +PASS Can get the ReadableStreamDefaultReader constructor indirectly +PASS ReadableStreamDefaultReader constructor should get a ReadableStream object as argument +PASS ReadableStreamDefaultReader instances should have the correct list of properties +PASS ReadableStreamDefaultReader closed should always return the same promise object +PASS Constructing a ReadableStreamDefaultReader directly should fail if the stream is already locked (via direct construction) +PASS Getting a ReadableStreamDefaultReader via getReader should fail if the stream is already locked (via direct construction) +PASS Constructing a ReadableStreamDefaultReader directly should fail if the stream is already locked (via getReader) +PASS Getting a ReadableStreamDefaultReader via getReader should fail if the stream is already locked (via getReader) +PASS Constructing a ReadableStreamDefaultReader directly should be OK if the stream is closed +PASS Constructing a ReadableStreamDefaultReader directly should be OK if the stream is errored +PASS Reading from a reader for an empty stream will wait until a chunk is available +PASS cancel() on a reader does not release the reader +PASS closed should be fulfilled after stream is closed (.closed access before acquiring) +PASS closed should be rejected after reader releases its lock (multiple stream locks) +PASS Multiple readers can access the stream in sequence +PASS Cannot use an already-released reader to unlock a stream again +PASS cancel() on a released reader is a no-op and does not pass through +PASS Getting a second reader after erroring the stream and releasing the reader should succeed +PASS ReadableStreamDefaultReader closed promise should be rejected with undefined if that is the error +PASS ReadableStreamDefaultReader: if start rejects with no parameter, it should error the stream with an undefined error +PASS Erroring a ReadableStream after checking closed should reject ReadableStreamDefaultReader closed promise +PASS Erroring a ReadableStream before checking closed should reject ReadableStreamDefaultReader closed promise +PASS Reading twice on a stream that gets closed +PASS Reading twice on a closed stream +PASS Reading twice on an errored stream +PASS Reading twice on a stream that gets errored +FAIL getReader() should call ToString() on mode assert_true: toString() should be called expected true got false +Harness: the test ran to completion. +
diff --git a/third_party/WebKit/LayoutTests/platform/win/fast/multicol/border-radius-clipped-layer-second-column-expected.txt b/third_party/WebKit/LayoutTests/platform/win/fast/multicol/border-radius-clipped-layer-second-column-expected.txt deleted file mode 100644 index 932e34b..0000000 --- a/third_party/WebKit/LayoutTests/platform/win/fast/multicol/border-radius-clipped-layer-second-column-expected.txt +++ /dev/null
@@ -1,25 +0,0 @@ -layer at (0,0) size 800x600 - LayoutView at (0,0) size 800x600 -layer at (0,0) size 800x228 - LayoutBlockFlow {HTML} at (0,0) size 800x228 - LayoutBlockFlow {BODY} at (8,16) size 784x204 - LayoutBlockFlow {P} at (0,0) size 784x20 - LayoutText {#text} at (0,0) size 766x19 - text run at (0,0) width 576: "The word 'PASS' should be seen below on the right hand side, inside a rounded box with black " - text run at (575,0) width 191: "border and yellow background." -layer at (8,52) size 784x168 - LayoutBlockFlow {DIV} at (0,36) size 784x168 - LayoutMultiColumnSet (anonymous) at (0,0) size 784x168 -layer at (8,52) size 392x264 - LayoutMultiColumnFlowThread (anonymous) at (0,0) size 392x264 - LayoutBlockFlow (anonymous) at (0,0) size 392x200 - LayoutBR {BR} at (0,6) size 0x19 - LayoutBR {BR} at (0,38) size 0x19 - LayoutBR {BR} at (0,70) size 0x19 - LayoutBR {BR} at (0,102) size 0x19 - LayoutBR {BR} at (0,134) size 0x19 - LayoutBR {BR} at (0,174) size 0x19 -layer at (8,252) size 392x64 clip at (24,268) size 360x32 - LayoutBlockFlow (relative positioned) {DIV} at (0,200) size 392x64 [bgcolor=#FFFF00] [border: (16px solid #000000)] - LayoutText {#text} at (177,22) size 38x19 - text run at (177,22) width 38: "PASS"
diff --git a/third_party/WebKit/LayoutTests/platform/win/fast/multicol/composited-inner-multicol-expected.txt b/third_party/WebKit/LayoutTests/platform/win/fast/multicol/composited-inner-multicol-expected.txt deleted file mode 100644 index ea985fd..0000000 --- a/third_party/WebKit/LayoutTests/platform/win/fast/multicol/composited-inner-multicol-expected.txt +++ /dev/null
@@ -1,44 +0,0 @@ -layer at (0,0) size 800x600 - LayoutView at (0,0) size 800x600 -layer at (0,0) size 800x208 - LayoutBlockFlow {HTML} at (0,0) size 800x208 - LayoutBlockFlow {BODY} at (8,16) size 784x184 - LayoutBlockFlow {P} at (0,0) size 784x40 - LayoutText {#text} at (0,0) size 756x39 - text run at (0,0) width 586: "Below you should see the word 'PASS' (with some extra letter spacing), on a yellow background " - text run at (585,0) width 171: "(which should be a bit faded" - text run at (0,20) width 629: "near the top). The first S is below the A, because they composite together and hence are not fragmented." -layer at (8,72) size 480x128 - LayoutBlockFlow {DIV} at (0,56) size 480x128 - LayoutMultiColumnSet (anonymous) at (0,0) size 480x128 -layer at (8,72) size 240x224 - LayoutMultiColumnFlowThread (anonymous) at (0,0) size 240x224 - LayoutBlockFlow (anonymous) at (0,0) size 240x160 - LayoutBR {BR} at (0,6) size 0x19 - LayoutBR {BR} at (0,38) size 0x19 - LayoutBR {BR} at (0,70) size 0x19 - LayoutBR {BR} at (0,102) size 0x19 - LayoutBR {BR} at (0,134) size 0x19 -layer at (16,240) size 80x48 - LayoutBlockFlow {DIV} at (8,168) size 80x48 [bgcolor=#FFFF00] - LayoutMultiColumnSet (anonymous) at (8,8) size 64x32 -layer at (24,248) size 16x128 - LayoutMultiColumnFlowThread (anonymous) at (8,8) size 16x128 - LayoutBlockFlow (anonymous) at (0,0) size 16x32 - LayoutText {#text} at (0,6) size 9x19 - text run at (0,6) width 9: "P" - LayoutBR {BR} at (9,6) size 0x19 - LayoutBlockFlow (anonymous) at (0,96) size 16x32 - LayoutText {#text} at (0,6) size 9x19 - text run at (0,6) width 9: "S" - LayoutBR {BR} at (9,6) size 0x19 -layer at (240,72) size 112x53 transparent - LayoutBlockFlow (positioned) {DIV} at (240,72) size 112x52.80 [bgcolor=#FFFFFF] -layer at (24,280) size 16x64 - LayoutBlockFlow (relative positioned) {DIV} at (0,32) size 16x64 - LayoutText {#text} at (0,6) size 11x19 - text run at (0,6) width 11: "A" - LayoutBR {BR} at (11,6) size 0x19 - LayoutText {#text} at (0,38) size 9x19 - text run at (0,38) width 9: "S" - LayoutBR {BR} at (9,38) size 0x19
diff --git a/third_party/WebKit/LayoutTests/platform/win/fast/multicol/composited-layer-multiple-fragments-expected.txt b/third_party/WebKit/LayoutTests/platform/win/fast/multicol/composited-layer-multiple-fragments-expected.txt deleted file mode 100644 index 1629e247..0000000 --- a/third_party/WebKit/LayoutTests/platform/win/fast/multicol/composited-layer-multiple-fragments-expected.txt +++ /dev/null
@@ -1,43 +0,0 @@ -layer at (0,0) size 800x600 - LayoutView at (0,0) size 800x600 -layer at (0,0) size 800x320 - LayoutBlockFlow {HTML} at (0,0) size 800x320 - LayoutBlockFlow {BODY} at (8,16) size 784x256 - LayoutBlockFlow {P} at (0,0) size 784x40 - LayoutText {#text} at (0,0) size 781x39 - text run at (0,0) width 781: "If no compositing were present, there should be two green squares below. Since some elements are composited, and therefore not" - text run at (0,20) width 205: "fragmented, the output is different." -layer at (8,104) size 60x60 - LayoutBlockFlow {DIV} at (0,88) size 60x60 - LayoutMultiColumnSet (anonymous) at (0,0) size 60x60 -layer at (8,104) size 20x180 - LayoutMultiColumnFlowThread (anonymous) at (0,0) size 20x180 - LayoutBlockFlow {DIV} at (0,0) size 20x20 [bgcolor=#008000] - LayoutBlockFlow {DIV} at (0,20) size 20x20 [bgcolor=#008000] - LayoutBlockFlow {DIV} at (0,80) size 20x20 [bgcolor=#008000] - LayoutBlockFlow {DIV} at (0,140) size 20x20 [bgcolor=#008000] - LayoutBlockFlow {DIV} at (0,160) size 20x20 [bgcolor=#008000] -layer at (8,212) size 60x60 - LayoutBlockFlow {DIV} at (0,196) size 60x60 - LayoutMultiColumnSet (anonymous) at (0,0) size 60x60 -layer at (8,212) size 20x180 - LayoutMultiColumnFlowThread (anonymous) at (0,0) size 20x180 - LayoutBlockFlow {DIV} at (0,0) size 20x20 [bgcolor=#008000] - LayoutBlockFlow {DIV} at (0,20) size 20x20 [bgcolor=#008000] - LayoutBlockFlow {DIV} at (0,140) size 20x20 [bgcolor=#008000] - LayoutBlockFlow {DIV} at (0,160) size 20x20 [bgcolor=#008000] -layer at (8,144) size 20x40 - LayoutBlockFlow {DIV} at (0,40) size 20x40 - LayoutBlockFlow {DIV} at (0,0) size 20x20 [bgcolor=#008000] - LayoutBlockFlow {DIV} at (0,20) size 20x20 [bgcolor=#008000] -layer at (8,204) size 20x40 - LayoutBlockFlow {DIV} at (0,100) size 20x40 - LayoutBlockFlow {DIV} at (0,0) size 20x20 [bgcolor=#008000] - LayoutBlockFlow {DIV} at (0,20) size 20x20 [bgcolor=#008000] -layer at (8,252) size 20x100 - LayoutBlockFlow {DIV} at (0,40) size 20x100 - LayoutBlockFlow {DIV} at (0,0) size 20x20 [bgcolor=#008000] - LayoutBlockFlow {DIV} at (0,20) size 20x20 [bgcolor=#008000] - LayoutBlockFlow {DIV} at (0,40) size 20x20 [bgcolor=#008000] - LayoutBlockFlow {DIV} at (0,60) size 20x20 [bgcolor=#008000] - LayoutBlockFlow {DIV} at (0,80) size 20x20 [bgcolor=#008000]
diff --git a/third_party/WebKit/LayoutTests/platform/win/fast/multicol/composited-layer-multiple-fragments-translated-expected.txt b/third_party/WebKit/LayoutTests/platform/win/fast/multicol/composited-layer-multiple-fragments-translated-expected.txt deleted file mode 100644 index c71ba071..0000000 --- a/third_party/WebKit/LayoutTests/platform/win/fast/multicol/composited-layer-multiple-fragments-translated-expected.txt +++ /dev/null
@@ -1,27 +0,0 @@ -layer at (0,0) size 800x600 - LayoutView at (0,0) size 800x600 -layer at (0,0) size 800x140 - LayoutBlockFlow {HTML} at (0,0) size 800x140 - LayoutBlockFlow {BODY} at (8,16) size 784x116 - LayoutBlockFlow {P} at (0,0) size 784x40 - LayoutText {#text} at (0,0) size 744x39 - text run at (0,0) width 744: "There should be two small green squares vertically aligned below, and another red square to the top-right. The second green" - text run at (0,20) width 516: "square does not overlap the red because it is conmposited, and hence not fragmented." -layer at (8,72) size 60x60 - LayoutBlockFlow {DIV} at (0,56) size 60x60 - LayoutMultiColumnSet (anonymous) at (0,0) size 60x60 -layer at (8,72) size 20x180 - LayoutMultiColumnFlowThread (anonymous) at (0,0) size 20x180 - LayoutBlockFlow (anonymous) at (0,0) size 20x100 - LayoutBR {BR} at (0,0) size 0x19 - LayoutBR {BR} at (0,20) size 0x19 - LayoutBR {BR} at (0,40) size 0x19 - LayoutBR {BR} at (0,60) size 0x19 - LayoutBR {BR} at (0,80) size 0x19 - LayoutBlockFlow {DIV} at (0,160) size 20x20 [bgcolor=#FF0000] -layer at (8,172) size 20x60 - LayoutBlockFlow {DIV} at (0,100) size 20x60 - LayoutBlockFlow {DIV} at (0,0) size 20x20 [bgcolor=#008000] - LayoutBlockFlow (anonymous) at (0,20) size 20x20 - LayoutBR {BR} at (0,0) size 0x19 - LayoutBlockFlow {DIV} at (0,40) size 20x20 [bgcolor=#008000]
diff --git a/third_party/WebKit/LayoutTests/platform/win/fast/multicol/composited-layer-nested-expected.txt b/third_party/WebKit/LayoutTests/platform/win/fast/multicol/composited-layer-nested-expected.txt deleted file mode 100644 index 355c26c..0000000 --- a/third_party/WebKit/LayoutTests/platform/win/fast/multicol/composited-layer-nested-expected.txt +++ /dev/null
@@ -1,51 +0,0 @@ -layer at (0,0) size 800x600 - LayoutView at (0,0) size 800x600 -layer at (0,0) size 800x320 - LayoutBlockFlow {HTML} at (0,0) size 800x320 - LayoutBlockFlow {BODY} at (8,16) size 784x256 - LayoutBlockFlow {P} at (0,0) size 784x40 - LayoutText {#text} at (0,0) size 781x39 - text run at (0,0) width 781: "If no compositing were present, there should be two green squares below. Since some elements are composited, and therefore not" - text run at (0,20) width 205: "fragmented, the output is different." -layer at (8,104) size 60x60 - LayoutBlockFlow {DIV} at (0,88) size 60x60 - LayoutMultiColumnSet (anonymous) at (0,0) size 60x60 -layer at (8,104) size 20x180 - LayoutMultiColumnFlowThread (anonymous) at (0,0) size 20x180 - LayoutBlockFlow {DIV} at (0,0) size 20x20 [bgcolor=#008000] - LayoutBlockFlow {DIV} at (0,100) size 20x20 [bgcolor=#008000] - LayoutBlockFlow {DIV} at (0,120) size 20x20 [bgcolor=#008000] - LayoutBlockFlow {DIV} at (0,140) size 20x20 [bgcolor=#008000] - LayoutBlockFlow {DIV} at (0,160) size 20x20 [bgcolor=#008000] -layer at (8,212) size 60x60 - LayoutBlockFlow {DIV} at (0,196) size 60x60 - LayoutMultiColumnSet (anonymous) at (0,0) size 60x60 -layer at (8,212) size 20x180 - LayoutMultiColumnFlowThread (anonymous) at (0,0) size 20x180 -layer at (8,124) size 20x80 - LayoutBlockFlow {DIV} at (0,20) size 20x80 - LayoutBlockFlow {DIV} at (0,0) size 20x20 [bgcolor=#008000] - LayoutBlockFlow {DIV} at (0,60) size 20x20 [bgcolor=#008000] -layer at (8,144) size 20x40 - LayoutBlockFlow {DIV} at (0,20) size 20x40 - LayoutBlockFlow {DIV} at (0,0) size 20x20 [bgcolor=#008000] - LayoutBlockFlow {DIV} at (0,20) size 20x20 [bgcolor=#008000] -layer at (8,212) size 20x180 - LayoutBlockFlow {DIV} at (0,0) size 20x180 - LayoutBlockFlow {DIV} at (0,80) size 20x20 [bgcolor=#008000] -layer at (8,212) size 20x80 - LayoutBlockFlow {DIV} at (0,0) size 20x80 - LayoutBlockFlow {DIV} at (0,0) size 20x20 [bgcolor=#008000] - LayoutBlockFlow {DIV} at (0,20) size 20x20 [bgcolor=#008000] -layer at (8,252) size 20x40 - LayoutBlockFlow {DIV} at (0,40) size 20x40 - LayoutBlockFlow {DIV} at (0,0) size 20x20 [bgcolor=#008000] - LayoutBlockFlow {DIV} at (0,20) size 20x20 [bgcolor=#008000] -layer at (8,312) size 20x80 - LayoutBlockFlow {DIV} at (0,100) size 20x80 - LayoutBlockFlow {DIV} at (0,40) size 20x20 [bgcolor=#008000] - LayoutBlockFlow {DIV} at (0,60) size 20x20 [bgcolor=#008000] -layer at (8,312) size 20x40 - LayoutBlockFlow {DIV} at (0,0) size 20x40 - LayoutBlockFlow {DIV} at (0,0) size 20x20 [bgcolor=#008000] - LayoutBlockFlow {DIV} at (0,20) size 20x20 [bgcolor=#008000]
diff --git a/third_party/WebKit/LayoutTests/platform/win/fast/multicol/composited-layer-will-change-expected.txt b/third_party/WebKit/LayoutTests/platform/win/fast/multicol/composited-layer-will-change-expected.txt deleted file mode 100644 index 2a3a162..0000000 --- a/third_party/WebKit/LayoutTests/platform/win/fast/multicol/composited-layer-will-change-expected.txt +++ /dev/null
@@ -1,69 +0,0 @@ -layer at (0,0) size 800x600 - LayoutView at (0,0) size 800x600 -layer at (0,0) size 800x428 - LayoutBlockFlow {HTML} at (0,0) size 800x428 - LayoutBlockFlow {BODY} at (8,16) size 784x364 - LayoutBlockFlow {P} at (0,0) size 784x40 - LayoutText {#text} at (0,0) size 781x39 - text run at (0,0) width 781: "If no compositing were present, there should be two green squares below. Since some elements are composited, and therefore not" - text run at (0,20) width 205: "fragmented, the output is different." -layer at (8,104) size 60x60 - LayoutBlockFlow {DIV} at (0,88) size 60x60 - LayoutMultiColumnSet (anonymous) at (0,0) size 60x60 -layer at (8,104) size 20x180 - LayoutMultiColumnFlowThread (anonymous) at (0,0) size 20x180 - LayoutBlockFlow {DIV} at (0,20) size 20x20 [bgcolor=#008000] - LayoutBlockFlow {DIV} at (0,80) size 20x20 [bgcolor=#008000] - LayoutBlockFlow {DIV} at (0,160) size 20x20 [bgcolor=#008000] -layer at (8,212) size 60x60 - LayoutBlockFlow {DIV} at (0,196) size 60x60 - LayoutMultiColumnSet (anonymous) at (0,0) size 60x60 -layer at (8,212) size 20x180 - LayoutMultiColumnFlowThread (anonymous) at (0,0) size 20x180 - LayoutBlockFlow {DIV} at (0,20) size 20x20 [bgcolor=#008000] - LayoutBlockFlow {DIV} at (0,80) size 20x20 [bgcolor=#008000] - LayoutBlockFlow {DIV} at (0,160) size 20x20 [bgcolor=#008000] -layer at (8,320) size 60x60 - LayoutBlockFlow {DIV} at (0,304) size 60x60 - LayoutMultiColumnSet (anonymous) at (0,0) size 60x60 -layer at (8,320) size 20x180 - LayoutMultiColumnFlowThread (anonymous) at (0,0) size 20x180 - LayoutBlockFlow {DIV} at (0,20) size 20x20 [bgcolor=#008000] - LayoutBlockFlow {DIV} at (0,80) size 20x20 [bgcolor=#008000] - LayoutBlockFlow {DIV} at (0,160) size 20x20 [bgcolor=#008000] -layer at (8,104) size 20x20 - LayoutBlockFlow {DIV} at (0,0) size 20x20 - LayoutBlockFlow {DIV} at (0,0) size 20x20 [bgcolor=#008000] -layer at (8,144) size 20x40 - LayoutBlockFlow {DIV} at (0,40) size 20x40 - LayoutBlockFlow {DIV} at (0,0) size 20x20 [bgcolor=#008000] - LayoutBlockFlow {DIV} at (0,20) size 20x20 [bgcolor=#008000] -layer at (8,204) size 20x60 - LayoutBlockFlow {DIV} at (0,100) size 20x60 - LayoutBlockFlow {DIV} at (0,0) size 20x20 [bgcolor=#008000] - LayoutBlockFlow {DIV} at (0,20) size 20x20 [bgcolor=#008000] - LayoutBlockFlow {DIV} at (0,40) size 20x20 [bgcolor=#008000] -layer at (8,212) size 20x20 - LayoutBlockFlow {DIV} at (0,0) size 20x20 - LayoutBlockFlow {DIV} at (0,0) size 20x20 [bgcolor=#008000] -layer at (8,252) size 20x40 - LayoutBlockFlow {DIV} at (0,40) size 20x40 - LayoutBlockFlow {DIV} at (0,0) size 20x20 [bgcolor=#008000] - LayoutBlockFlow {DIV} at (0,20) size 20x20 [bgcolor=#008000] -layer at (8,312) size 20x60 - LayoutBlockFlow {DIV} at (0,100) size 20x60 - LayoutBlockFlow {DIV} at (0,0) size 20x20 [bgcolor=#008000] - LayoutBlockFlow {DIV} at (0,20) size 20x20 [bgcolor=#008000] - LayoutBlockFlow {DIV} at (0,40) size 20x20 [bgcolor=#008000] -layer at (8,320) size 20x20 - LayoutBlockFlow (relative positioned) {DIV} at (0,0) size 20x20 - LayoutBlockFlow {DIV} at (0,0) size 20x20 [bgcolor=#008000] -layer at (8,360) size 20x40 - LayoutBlockFlow (relative positioned) {DIV} at (0,40) size 20x40 - LayoutBlockFlow {DIV} at (0,0) size 20x20 [bgcolor=#008000] - LayoutBlockFlow {DIV} at (0,20) size 20x20 [bgcolor=#008000] -layer at (8,420) size 20x60 - LayoutBlockFlow (relative positioned) {DIV} at (0,100) size 20x60 - LayoutBlockFlow {DIV} at (0,0) size 20x20 [bgcolor=#008000] - LayoutBlockFlow {DIV} at (0,20) size 20x20 [bgcolor=#008000] - LayoutBlockFlow {DIV} at (0,40) size 20x20 [bgcolor=#008000]
diff --git a/third_party/WebKit/LayoutTests/platform/win/fast/multicol/composited-opacity-2nd-and-3rd-column-expected.txt b/third_party/WebKit/LayoutTests/platform/win/fast/multicol/composited-opacity-2nd-and-3rd-column-expected.txt deleted file mode 100644 index 1a237ad..0000000 --- a/third_party/WebKit/LayoutTests/platform/win/fast/multicol/composited-opacity-2nd-and-3rd-column-expected.txt +++ /dev/null
@@ -1,40 +0,0 @@ -layer at (0,0) size 800x600 - LayoutView at (0,0) size 800x600 -layer at (0,0) size 800x288 - LayoutBlockFlow {HTML} at (0,0) size 800x288 - LayoutBlockFlow {BODY} at (8,16) size 784x264 - LayoutBlockFlow {P} at (0,0) size 784x40 - LayoutText {#text} at (0,0) size 203x19 - text run at (0,0) width 203: "The word 'PASS' should be seen " - LayoutInline {EM} at (0,0) size 35x19 - LayoutText {#text} at (202,0) size 35x19 - text run at (202,0) width 35: "twice" - LayoutText {#text} at (236,0) size 773x39 - text run at (236,0) width 537: " below. The second PASS is not overlapping the yellow because it is composited with the" - text run at (0,20) width 215: "first one, and hence not fragmented." -layer at (8,72) size 272x208 - LayoutBlockFlow {DIV} at (0,56) size 272x208 - LayoutMultiColumnSet (anonymous) at (0,0) size 272x208 -layer at (8,72) size 80x456 - LayoutMultiColumnFlowThread (anonymous) at (0,0) size 80x456 - LayoutBlockFlow (anonymous) at (0,0) size 80x368 - LayoutBR {BR} at (0,6) size 0x19 - LayoutBR {BR} at (0,38) size 0x19 - LayoutBR {BR} at (0,70) size 0x19 - LayoutBR {BR} at (0,102) size 0x19 - LayoutBR {BR} at (0,134) size 0x19 - LayoutBR {BR} at (0,166) size 0x19 - LayoutBR {BR} at (0,214) size 0x19 - LayoutBR {BR} at (0,246) size 0x19 - LayoutBR {BR} at (0,278) size 0x19 - LayoutBR {BR} at (0,310) size 0x19 - LayoutBR {BR} at (0,342) size 0x19 -layer at (0,72) size 800x128 - LayoutBlockFlow (positioned) {DIV} at (0,72) size 800x128 [bgcolor=#FFFF00] -layer at (16,448) size 64x72 transparent - LayoutBlockFlow {DIV} at (8,376) size 64x72 - LayoutText {#text} at (0,6) size 37x19 - text run at (0,6) width 37: "PASS" - LayoutBR {BR} at (36,6) size 1x19 - LayoutText {#text} at (0,46) size 37x19 - text run at (0,46) width 37: "PASS"
diff --git a/third_party/WebKit/LayoutTests/platform/win/fast/multicol/composited-relpos-clipped-expected.txt b/third_party/WebKit/LayoutTests/platform/win/fast/multicol/composited-relpos-clipped-expected.txt deleted file mode 100644 index 2208609b..0000000 --- a/third_party/WebKit/LayoutTests/platform/win/fast/multicol/composited-relpos-clipped-expected.txt +++ /dev/null
@@ -1,39 +0,0 @@ -layer at (0,0) size 800x600 - LayoutView at (0,0) size 800x600 -layer at (0,0) size 800x288 - LayoutBlockFlow {HTML} at (0,0) size 800x288 - LayoutBlockFlow {BODY} at (8,16) size 784x264 - LayoutBlockFlow {P} at (0,0) size 784x40 - LayoutText {#text} at (0,0) size 775x39 - text run at (0,0) width 775: "There should be one yellow boxes below, on a blue background. There is only one because the content is composited, and hence" - text run at (0,20) width 94: "not fragmented." -layer at (8,72) size 272x208 - LayoutBlockFlow {DIV} at (0,56) size 272x208 - LayoutMultiColumnSet (anonymous) at (0,0) size 272x208 -layer at (8,72) size 128x280 - LayoutMultiColumnFlowThread (anonymous) at (0,0) size 128x280 - LayoutBlockFlow (anonymous) at (0,0) size 128x128 - LayoutBR {BR} at (0,6) size 0x19 - LayoutBR {BR} at (0,38) size 0x19 - LayoutBR {BR} at (0,70) size 0x19 - LayoutBR {BR} at (0,102) size 0x19 -layer at (0,72) size 800x208 - LayoutBlockFlow (positioned) {DIV} at (0,72) size 800x208 [bgcolor=#0000FF] -layer at (16,208) size 112x136 scrollHeight 168 - LayoutBlockFlow (relative positioned) {DIV} at (8,136) size 112x136 [bgcolor=#FFFF00] - LayoutBlockFlow (anonymous) at (0,0) size 112x136 - LayoutText {#text} at (0,6) size 22x19 - text run at (0,6) width 22: "first" - LayoutBR {BR} at (22,6) size 0x19 - LayoutText {#text} at (0,38) size 43x19 - text run at (0,38) width 43: "column" - LayoutBR {BR} at (43,38) size 0x19 - LayoutText {#text} at (0,78) size 43x19 - text run at (0,78) width 43: "second" - LayoutBR {BR} at (43,78) size 0x19 - LayoutText {#text} at (0,110) size 43x19 - text run at (0,110) width 43: "column" - LayoutBR {BR} at (43,110) size 0x19 - LayoutBlockFlow {DIV} at (0,136) size 112x32 [bgcolor=#FF0000] - LayoutText {#text} at (0,6) size 33x19 - text run at (0,6) width 33: "FAIL"
diff --git a/third_party/WebKit/LayoutTests/platform/win/fast/multicol/composited-relpos-expected.txt b/third_party/WebKit/LayoutTests/platform/win/fast/multicol/composited-relpos-expected.txt deleted file mode 100644 index cc0f409..0000000 --- a/third_party/WebKit/LayoutTests/platform/win/fast/multicol/composited-relpos-expected.txt +++ /dev/null
@@ -1,36 +0,0 @@ -layer at (0,0) size 800x600 - LayoutView at (0,0) size 800x600 -layer at (0,0) size 800x288 - LayoutBlockFlow {HTML} at (0,0) size 800x288 - LayoutBlockFlow {BODY} at (8,16) size 784x264 - LayoutBlockFlow {P} at (0,0) size 784x40 - LayoutText {#text} at (0,0) size 781x39 - text run at (0,0) width 376: "There should be one yellow boxbelow, on a blue background. " - text run at (375,0) width 406: "There is only one because the content is composited, and hence not" - text run at (0,20) width 71: "fragmented." -layer at (8,72) size 272x208 - LayoutBlockFlow {DIV} at (0,56) size 272x208 - LayoutMultiColumnSet (anonymous) at (0,0) size 272x208 -layer at (8,72) size 128x280 - LayoutMultiColumnFlowThread (anonymous) at (0,0) size 128x280 - LayoutBlockFlow (anonymous) at (0,0) size 128x128 - LayoutBR {BR} at (0,6) size 0x19 - LayoutBR {BR} at (0,38) size 0x19 - LayoutBR {BR} at (0,70) size 0x19 - LayoutBR {BR} at (0,102) size 0x19 -layer at (0,72) size 800x208 - LayoutBlockFlow (positioned) {DIV} at (0,72) size 800x208 [bgcolor=#0000FF] -layer at (16,208) size 112x136 - LayoutBlockFlow (relative positioned) {DIV} at (8,136) size 112x136 [bgcolor=#FFFF00] - LayoutText {#text} at (0,6) size 22x19 - text run at (0,6) width 22: "first" - LayoutBR {BR} at (22,6) size 0x19 - LayoutText {#text} at (0,38) size 43x19 - text run at (0,38) width 43: "column" - LayoutBR {BR} at (43,38) size 0x19 - LayoutText {#text} at (0,78) size 43x19 - text run at (0,78) width 43: "second" - LayoutBR {BR} at (43,78) size 0x19 - LayoutText {#text} at (0,110) size 43x19 - text run at (0,110) width 43: "column" - LayoutBR {BR} at (43,110) size 0x19
diff --git a/third_party/WebKit/LayoutTests/platform/win/fast/multicol/composited-relpos-in-clipped-expected.txt b/third_party/WebKit/LayoutTests/platform/win/fast/multicol/composited-relpos-in-clipped-expected.txt deleted file mode 100644 index a169d21e..0000000 --- a/third_party/WebKit/LayoutTests/platform/win/fast/multicol/composited-relpos-in-clipped-expected.txt +++ /dev/null
@@ -1,38 +0,0 @@ -layer at (0,0) size 800x600 - LayoutView at (0,0) size 800x600 -layer at (0,0) size 800x268 - LayoutBlockFlow {HTML} at (0,0) size 800x268 - LayoutBlockFlow {BODY} at (8,16) size 784x244 - LayoutBlockFlow {P} at (0,0) size 784x20 - LayoutText {#text} at (0,0) size 667x19 - text run at (0,0) width 667: "There should be one yellow box below, on a blue background. the \"second column\" part should be clipped out." -layer at (8,52) size 272x208 - LayoutBlockFlow {DIV} at (0,36) size 272x208 - LayoutMultiColumnSet (anonymous) at (0,0) size 272x208 -layer at (8,52) size 128x280 backgroundClip at (8,52) size 272x208 clip at (8,52) size 272x208 - LayoutMultiColumnFlowThread (anonymous) at (0,0) size 128x280 - LayoutBlockFlow (anonymous) at (0,0) size 128x128 - LayoutBR {BR} at (0,6) size 0x19 - LayoutBR {BR} at (0,38) size 0x19 - LayoutBR {BR} at (0,70) size 0x19 - LayoutBR {BR} at (0,102) size 0x19 -layer at (0,52) size 800x208 - LayoutBlockFlow (positioned) {DIV} at (0,52) size 800x208 [bgcolor=#0000FF] -layer at (16,188) size 112x136 backgroundClip at (16,188) size 112x72 clip at (16,188) size 112x72 scrollHeight 168 - LayoutBlockFlow (relative positioned) {DIV} at (8,136) size 112x136 [bgcolor=#FFFF00] - LayoutBlockFlow (anonymous) at (0,0) size 112x136 - LayoutText {#text} at (0,6) size 22x19 - text run at (0,6) width 22: "first" - LayoutBR {BR} at (22,6) size 0x19 - LayoutText {#text} at (0,38) size 43x19 - text run at (0,38) width 43: "column" - LayoutBR {BR} at (43,38) size 0x19 - LayoutText {#text} at (0,78) size 43x19 - text run at (0,78) width 43: "second" - LayoutBR {BR} at (43,78) size 0x19 - LayoutText {#text} at (0,110) size 43x19 - text run at (0,110) width 43: "column" - LayoutBR {BR} at (43,110) size 0x19 - LayoutBlockFlow {DIV} at (0,136) size 112x32 [bgcolor=#FF0000] - LayoutText {#text} at (0,6) size 33x19 - text run at (0,6) width 33: "FAIL"
diff --git a/third_party/WebKit/LayoutTests/platform/win/fast/multicol/composited-relpos-overlapping-will-change-expected.txt b/third_party/WebKit/LayoutTests/platform/win/fast/multicol/composited-relpos-overlapping-will-change-expected.txt deleted file mode 100644 index e3e76ba0..0000000 --- a/third_party/WebKit/LayoutTests/platform/win/fast/multicol/composited-relpos-overlapping-will-change-expected.txt +++ /dev/null
@@ -1,41 +0,0 @@ -layer at (0,0) size 800x600 - LayoutView at (0,0) size 800x600 -layer at (0,0) size 800x288 - LayoutBlockFlow {HTML} at (0,0) size 800x288 - LayoutBlockFlow {BODY} at (8,16) size 784x264 - LayoutBlockFlow {P} at (0,0) size 784x40 - LayoutText {#text} at (0,0) size 203x19 - text run at (0,0) width 203: "The word 'PASS' should be seen " - LayoutInline {EM} at (0,0) size 35x19 - LayoutText {#text} at (202,0) size 35x19 - text run at (202,0) width 35: "twice" - LayoutText {#text} at (236,0) size 773x39 - text run at (236,0) width 49: " below. " - text run at (284,0) width 489: "The second PASS is not overlapping the yellow because it is composited with the" - text run at (0,20) width 215: "first one, and hence not fragmented." -layer at (8,72) size 560x208 - LayoutBlockFlow {DIV} at (0,56) size 560x208 - LayoutMultiColumnSet (anonymous) at (0,0) size 560x208 -layer at (8,72) size 176x456 - LayoutMultiColumnFlowThread (anonymous) at (0,0) size 176x456 - LayoutBlockFlow (anonymous) at (0,0) size 176x368 - LayoutBR {BR} at (0,6) size 0x19 - LayoutBR {BR} at (0,38) size 0x19 - LayoutBR {BR} at (0,70) size 0x19 - LayoutBR {BR} at (0,102) size 0x19 - LayoutBR {BR} at (0,134) size 0x19 - LayoutBR {BR} at (0,166) size 0x19 - LayoutBR {BR} at (0,214) size 0x19 - LayoutBR {BR} at (0,246) size 0x19 - LayoutBR {BR} at (0,278) size 0x19 - LayoutBR {BR} at (0,310) size 0x19 - LayoutBR {BR} at (0,342) size 0x19 -layer at (0,72) size 800x128 - LayoutBlockFlow (positioned) {DIV} at (0,72) size 800x128 [bgcolor=#FFFF00] -layer at (16,448) size 160x72 - LayoutBlockFlow (relative positioned) {DIV} at (8,376) size 160x72 - LayoutText {#text} at (0,6) size 37x19 - text run at (0,6) width 37: "PASS" - LayoutBR {BR} at (36,6) size 1x19 - LayoutText {#text} at (0,46) size 37x19 - text run at (0,46) width 37: "PASS"
diff --git a/third_party/WebKit/LayoutTests/platform/win/fast/multicol/composited-relpos-resize-expected.txt b/third_party/WebKit/LayoutTests/platform/win/fast/multicol/composited-relpos-resize-expected.txt deleted file mode 100644 index f5fca35..0000000 --- a/third_party/WebKit/LayoutTests/platform/win/fast/multicol/composited-relpos-resize-expected.txt +++ /dev/null
@@ -1,34 +0,0 @@ -layer at (0,0) size 800x600 - LayoutView at (0,0) size 800x600 -layer at (0,0) size 800x268 - LayoutBlockFlow {HTML} at (0,0) size 800x268 - LayoutBlockFlow {BODY} at (8,16) size 784x244 - LayoutBlockFlow {P} at (0,0) size 784x20 - LayoutText {#text} at (0,0) size 721x19 - text run at (0,0) width 721: "There should be one yellow box below. There is only one because the content is composited, and hence not fragmented." -layer at (8,52) size 706x208 - LayoutBlockFlow {DIV} at (0,36) size 705.59x208 - LayoutMultiColumnSet (anonymous) at (0,0) size 705.59x208 -layer at (8,52) size 353x280 - LayoutMultiColumnFlowThread (anonymous) at (0,0) size 352.80x280 - LayoutBlockFlow (anonymous) at (0,0) size 352.80x128 - LayoutBR {BR} at (0,6) size 0x19 - LayoutBR {BR} at (0,38) size 0x19 - LayoutBR {BR} at (0,70) size 0x19 - LayoutBR {BR} at (0,102) size 0x19 -layer at (0,52) size 800x240 - LayoutBlockFlow (positioned) {DIV} at (0,52) size 800x240 [bgcolor=#00FFFF] -layer at (16,188) size 337x136 - LayoutBlockFlow (relative positioned) {DIV} at (8,136) size 336.80x136 [bgcolor=#FFFF00] - LayoutText {#text} at (0,6) size 22x19 - text run at (0,6) width 22: "first" - LayoutBR {BR} at (22,6) size 0x19 - LayoutText {#text} at (0,38) size 43x19 - text run at (0,38) width 43: "column" - LayoutBR {BR} at (43,38) size 0x19 - LayoutText {#text} at (0,78) size 43x19 - text run at (0,78) width 43: "second" - LayoutBR {BR} at (43,78) size 0x19 - LayoutText {#text} at (0,110) size 43x19 - text run at (0,110) width 43: "column" - LayoutBR {BR} at (43,110) size 0x19
diff --git a/third_party/WebKit/LayoutTests/platform/win/fast/multicol/composited-with-child-layer-in-next-column-expected.txt b/third_party/WebKit/LayoutTests/platform/win/fast/multicol/composited-with-child-layer-in-next-column-expected.txt deleted file mode 100644 index 91691cc..0000000 --- a/third_party/WebKit/LayoutTests/platform/win/fast/multicol/composited-with-child-layer-in-next-column-expected.txt +++ /dev/null
@@ -1,33 +0,0 @@ -layer at (0,0) size 800x600 - LayoutView at (0,0) size 800x600 -layer at (0,0) size 800x224 - LayoutBlockFlow {HTML} at (0,0) size 800x224 - LayoutBlockFlow {BODY} at (8,16) size 784x200 - LayoutBlockFlow {P} at (0,0) size 784x40 - LayoutText {#text} at (0,0) size 752x39 - text run at (0,0) width 752: "There should be a yellow box in the second column, and the word 'PASS' should be below it. PASS is not in the third column" - text run at (0,20) width 395: "because they are composited together, and hence not fragmented." -layer at (8,72) size 272x144 - LayoutBlockFlow {DIV} at (0,56) size 272x144 - LayoutMultiColumnSet (anonymous) at (0,0) size 272x144 -layer at (8,72) size 80x272 - LayoutMultiColumnFlowThread (anonymous) at (0,0) size 80x272 - LayoutBlockFlow (anonymous) at (0,0) size 80x240 - LayoutBR {BR} at (0,6) size 0x19 - LayoutBR {BR} at (0,38) size 0x19 - LayoutBR {BR} at (0,70) size 0x19 - LayoutBR {BR} at (0,102) size 0x19 - LayoutBR {BR} at (0,150) size 0x19 - LayoutBR {BR} at (0,182) size 0x19 - LayoutBR {BR} at (0,214) size 0x19 -layer at (0,72) size 800x144 - LayoutBlockFlow (positioned) {DIV} at (0,72) size 800x144 [bgcolor=#00FFFF] -layer at (8,312) size 80x32 - LayoutBlockFlow (relative positioned) zI: 2 {DIV} at (0,240) size 80x32 [bgcolor=#FFFF00] - LayoutBlockFlow (anonymous) at (0,0) size 80x80 - LayoutBR {BR} at (0,6) size 0x19 - LayoutBR {BR} at (0,54) size 0x19 -layer at (16,400) size 64x32 transparent - LayoutBlockFlow {DIV} at (8,88) size 64x32 - LayoutText {#text} at (0,6) size 37x19 - text run at (0,6) width 37: "PASS"
diff --git a/third_party/WebKit/LayoutTests/platform/win/fast/multicol/composited-with-overflow-in-next-column-expected.txt b/third_party/WebKit/LayoutTests/platform/win/fast/multicol/composited-with-overflow-in-next-column-expected.txt deleted file mode 100644 index 40c84d7..0000000 --- a/third_party/WebKit/LayoutTests/platform/win/fast/multicol/composited-with-overflow-in-next-column-expected.txt +++ /dev/null
@@ -1,29 +0,0 @@ -layer at (0,0) size 800x600 - LayoutView at (0,0) size 800x600 -layer at (0,0) size 800x204 - LayoutBlockFlow {HTML} at (0,0) size 800x204 - LayoutBlockFlow {BODY} at (8,16) size 784x180 - LayoutBlockFlow {P} at (0,0) size 784x20 - LayoutText {#text} at (0,0) size 361x19 - text run at (0,0) width 361: "The word 'PASS' should be seen below, in the third column." -layer at (8,52) size 784x144 - LayoutBlockFlow {DIV} at (0,36) size 784x144 - LayoutMultiColumnSet (anonymous) at (0,0) size 784x144 -layer at (8,52) size 251x256 - LayoutMultiColumnFlowThread (anonymous) at (0,0) size 250.66x256 - LayoutBlockFlow (anonymous) at (0,0) size 250.66x240 - LayoutBR {BR} at (0,6) size 0x19 - LayoutBR {BR} at (0,38) size 0x19 - LayoutBR {BR} at (0,70) size 0x19 - LayoutBR {BR} at (0,102) size 0x19 - LayoutBR {BR} at (0,150) size 0x19 - LayoutBR {BR} at (0,182) size 0x19 - LayoutBR {BR} at (0,214) size 0x19 -layer at (0,100) size 800x18 - LayoutBlockFlow (positioned) {DIV} at (0,100) size 800x18 [border: (1px dotted #000000)] -layer at (8,292) size 251x16 - LayoutBlockFlow (relative positioned) {DIV} at (0,240) size 250.66x16 - LayoutBR {BR} at (0,6) size 0x19 - LayoutBR {BR} at (0,54) size 0x19 - LayoutText {#text} at (0,86) size 37x19 - text run at (0,86) width 37: "PASS"
diff --git a/third_party/WebKit/LayoutTests/platform/win/fast/multicol/multicol-with-child-renderLayer-for-input-expected.txt b/third_party/WebKit/LayoutTests/platform/win/fast/multicol/multicol-with-child-renderLayer-for-input-expected.txt deleted file mode 100644 index 686d8e2..0000000 --- a/third_party/WebKit/LayoutTests/platform/win/fast/multicol/multicol-with-child-renderLayer-for-input-expected.txt +++ /dev/null
@@ -1,28 +0,0 @@ -layer at (0,0) size 800x600 - LayoutView at (0,0) size 800x600 -layer at (0,0) size 800x600 - LayoutBlockFlow {HTML} at (0,0) size 800x600 - LayoutBlockFlow {BODY} at (8,8) size 784x584 -layer at (8,8) size 784x60 - LayoutBlockFlow {DIV} at (0,0) size 784x60 - LayoutMultiColumnSet (anonymous) at (0,0) size 784x60 -layer at (8,8) size 384x106 - LayoutMultiColumnFlowThread (anonymous) at (0,0) size 384x106 - LayoutText {#text} at (0,0) size 380x102 - text run at (0,0) width 64: "Filler Text " - text run at (63,0) width 317: "Filler Text Filler Text Filler Text Filler Text Filler Text" - text run at (0,20) width 192: "Filler Text Filler Text Filler Text " - text run at (191,20) width 65: "Filler Text " - text run at (255,20) width 125: "Filler Text Filler Text" - text run at (0,40) width 380: "Filler Text Filler Text Filler Text Filler Text Filler Text Filler Text" - text run at (0,60) width 64: "Filler Text " - text run at (63,60) width 317: "Filler Text Filler Text Filler Text Filler Text Filler Text" - text run at (0,83) width 192: "Filler Text Filler Text Filler Text " - LayoutText {#text} at (0,0) size 0x0 -layer at (202,90) size 173x22 clip at (204,92) size 169x18 - LayoutTextControl (relative positioned) {INPUT} at (193.64,82) size 173x22 [bgcolor=#FFFFFF] [border: (2px inset #EEEEEE)] -layer at (204,93) size 169x16 backgroundClip at (0,0) size 0x0 clip at (0,0) size 0x0 - LayoutBlockFlow {DIV} at (2,3) size 169x16 - LayoutText {#text} at (0,0) size 41x16 - text run at (0,0) width 41: "Testing" -caret: position 7 of child 0 {#text} of child 0 {DIV} of {#document-fragment} of child 1 {INPUT} of child 1 {DIV} of body
diff --git a/third_party/WebKit/LayoutTests/platform/win/fast/multicol/span/invalid-spanner-in-transform-expected.txt b/third_party/WebKit/LayoutTests/platform/win/fast/multicol/span/invalid-spanner-in-transform-expected.txt deleted file mode 100644 index 73b3074..0000000 --- a/third_party/WebKit/LayoutTests/platform/win/fast/multicol/span/invalid-spanner-in-transform-expected.txt +++ /dev/null
@@ -1,19 +0,0 @@ -layer at (0,0) size 800x600 - LayoutView at (0,0) size 800x600 -layer at (0,0) size 800x110 - LayoutBlockFlow {HTML} at (0,0) size 800x110 - LayoutBlockFlow {BODY} at (8,16) size 784x86 - LayoutBlockFlow {P} at (0,0) size 784x20 - LayoutText {#text} at (0,0) size 715x19 - text run at (0,0) width 244: "There should be one blue square below. " - text run at (243,0) width 472: "It is not two because they are composited together, and hence not fragmented." -layer at (8,52) size 110x50 - LayoutBlockFlow {DIV} at (0,36) size 110x50 - LayoutMultiColumnSet (anonymous) at (0,0) size 110x50 -layer at (8,52) size 50x100 - LayoutMultiColumnFlowThread (anonymous) at (0,0) size 50x100 -layer at (8,52) size 50x100 - LayoutBlockFlow {DIV} at (0,0) size 50x100 - LayoutBlockFlow {DIV} at (0,0) size 50x100 [bgcolor=#0000FF] - LayoutBR {BR} at (0,15) size 0x19 - LayoutBR {BR} at (0,65) size 0x19
diff --git a/third_party/WebKit/LayoutTests/platform/win/fast/multicol/vertical-lr/composited-relpos-overlapping-will-change-expected.txt b/third_party/WebKit/LayoutTests/platform/win/fast/multicol/vertical-lr/composited-relpos-overlapping-will-change-expected.txt deleted file mode 100644 index 5bd13588..0000000 --- a/third_party/WebKit/LayoutTests/platform/win/fast/multicol/vertical-lr/composited-relpos-overlapping-will-change-expected.txt +++ /dev/null
@@ -1,41 +0,0 @@ -layer at (0,0) size 800x600 - LayoutView at (0,0) size 800x600 -layer at (0,0) size 800x476 - LayoutBlockFlow {HTML} at (0,0) size 800x476 - LayoutBlockFlow {BODY} at (8,16) size 784x452 - LayoutBlockFlow {P} at (0,0) size 784x20 - LayoutText {#text} at (0,0) size 203x19 - text run at (0,0) width 203: "The word 'PASS' should be seen " - LayoutInline {EM} at (0,0) size 35x19 - LayoutText {#text} at (202,0) size 35x19 - text run at (202,0) width 35: "twice" - LayoutText {#text} at (236,0) size 524x19 - text run at (236,0) width 524: " below. They appear together because they are composited, and hence not fragmented." -layer at (8,52) size 208x416 - LayoutBlockFlow {DIV} at (0,36) size 208x416 - LayoutMultiColumnSet (anonymous) at (0,0) size 208x416 -layer at (8,52) size 456x128 - LayoutMultiColumnFlowThread (anonymous) at (0,0) size 456x128 - LayoutBlockFlow (anonymous) at (0,0) size 368x128 - LayoutBR {BR} at (6,0) size 19x0 - LayoutBR {BR} at (38,0) size 19x0 - LayoutBR {BR} at (70,0) size 19x0 - LayoutBR {BR} at (102,0) size 19x0 - LayoutBR {BR} at (134,0) size 19x0 - LayoutBR {BR} at (166,0) size 19x0 - LayoutBR {BR} at (214,0) size 19x0 - LayoutBR {BR} at (246,0) size 19x0 - LayoutBR {BR} at (278,0) size 19x0 - LayoutBR {BR} at (310,0) size 19x0 - LayoutText {#text} at (342,0) size 19x5 - text run at (342,0) width 5: "r" - LayoutBR {BR} at (342,5) size 19x0 -layer at (0,64) size 160x288 - LayoutBlockFlow (positioned) {DIV} at (0,64) size 160x288 [bgcolor=#FFFF00] -layer at (384,60) size 72x112 - LayoutBlockFlow (relative positioned) {DIV} at (376,8) size 72x112 - LayoutText {#text} at (6,0) size 19x37 - text run at (6,0) width 37: "PASS" - LayoutBR {BR} at (6,36) size 19x1 - LayoutText {#text} at (46,0) size 19x37 - text run at (46,0) width 37: "PASS"
diff --git a/third_party/WebKit/LayoutTests/platform/win/fast/multicol/vertical-rl/composited-relpos-overlapping-will-change-expected.txt b/third_party/WebKit/LayoutTests/platform/win/fast/multicol/vertical-rl/composited-relpos-overlapping-will-change-expected.txt deleted file mode 100644 index 321a204d..0000000 --- a/third_party/WebKit/LayoutTests/platform/win/fast/multicol/vertical-rl/composited-relpos-overlapping-will-change-expected.txt +++ /dev/null
@@ -1,39 +0,0 @@ -layer at (0,0) size 800x600 - LayoutView at (0,0) size 800x600 -layer at (0,0) size 800x476 - LayoutBlockFlow {HTML} at (0,0) size 800x476 - LayoutBlockFlow {BODY} at (8,16) size 784x452 - LayoutBlockFlow {P} at (0,0) size 784x20 - LayoutText {#text} at (0,0) size 203x19 - text run at (0,0) width 203: "The word 'PASS' should be seen " - LayoutInline {EM} at (0,0) size 35x19 - LayoutText {#text} at (202,0) size 35x19 - text run at (202,0) width 35: "twice" - LayoutText {#text} at (236,0) size 524x19 - text run at (236,0) width 524: " below. They appear together because they are composited, and hence not fragmented." -layer at (8,52) size 208x416 - LayoutBlockFlow {DIV} at (0,36) size 208x416 - LayoutMultiColumnSet (anonymous) at (0,0) size 208x416 -layer at (-240,52) size 456x128 backgroundClip at (0,0) size 800x600 clip at (0,0) size 800x600 - LayoutMultiColumnFlowThread (anonymous) at (0,0) size 456x128 - LayoutBlockFlow (anonymous) at (0,0) size 368x128 - LayoutBR {BR} at (6,0) size 19x0 - LayoutBR {BR} at (38,0) size 19x0 - LayoutBR {BR} at (70,0) size 19x0 - LayoutBR {BR} at (102,0) size 19x0 - LayoutBR {BR} at (134,0) size 19x0 - LayoutBR {BR} at (166,0) size 19x0 - LayoutBR {BR} at (214,0) size 19x0 - LayoutBR {BR} at (246,0) size 19x0 - LayoutBR {BR} at (278,0) size 19x0 - LayoutBR {BR} at (310,0) size 19x0 - LayoutBR {BR} at (342,0) size 19x0 -layer at (0,64) size 160x288 - LayoutBlockFlow (positioned) {DIV} at (0,64) size 160x288 [bgcolor=#FFFF00] -layer at (-232,60) size 72x112 backgroundClip at (0,0) size 800x600 clip at (0,0) size 800x600 - LayoutBlockFlow (relative positioned) {DIV} at (376,8) size 72x112 - LayoutText {#text} at (6,0) size 19x37 - text run at (6,0) width 37: "PASS" - LayoutBR {BR} at (6,36) size 19x1 - LayoutText {#text} at (46,0) size 19x37 - text run at (46,0) width 37: "PASS"
diff --git a/third_party/WebKit/LayoutTests/svg/masking/mask-within-feimage-filter-on-root-crash.html b/third_party/WebKit/LayoutTests/svg/masking/mask-within-feimage-filter-on-root-crash.html new file mode 100644 index 0000000..1a31f38 --- /dev/null +++ b/third_party/WebKit/LayoutTests/svg/masking/mask-within-feimage-filter-on-root-crash.html
@@ -0,0 +1,16 @@ +<!DOCTYPE html> +<title>'mask' within <feImage> should not crash</title> +<script src="../../resources/testharness.js"></script> +<script src="../../resources/testharnessreport.js"></script> +<svg filter="url(#filter)"> + <mask id="mask"> + <rect width="100" height="100" fill="white"/> + </mask> + <filter id="filter"> + <feImage xlink:href="#e"/> + </filter> + <rect id="e" width="200" height="100" fill="green" mask="url(#mask)"/> +</svg> +<script> +test(_ => {}); +</script>
diff --git a/third_party/WebKit/Source/bindings/templates/attributes.cpp.tmpl b/third_party/WebKit/Source/bindings/templates/attributes.cpp.tmpl index dc4af1e..92bee69 100644 --- a/third_party/WebKit/Source/bindings/templates/attributes.cpp.tmpl +++ b/third_party/WebKit/Source/bindings/templates/attributes.cpp.tmpl
@@ -153,7 +153,7 @@ {{release_only_check(attribute.reflect_only, attribute.reflect_missing, attribute.reflect_invalid, attribute.reflect_empty, attribute.cpp_value) - | indent(2)}} + | trim | indent(2)}} {% endif %} {% if attribute.cached_attribute_validation_method %} @@ -238,7 +238,7 @@ const v8::FunctionCallbackInfo<v8::Value>& info {%- endif %}) { {% if attribute.runtime_call_stats.extended_attribute_defined %} - {{ runtime_timer_scope(attribute.runtime_call_stats.getter_counter) | indent(2) }} + {{ runtime_timer_scope(attribute.runtime_call_stats.getter_counter) | trim | indent(2) }} {% else %} {{ runtime_timer_scope_disabled_by_default(attribute.runtime_call_stats.getter_counter) }} {% endif %} @@ -387,7 +387,7 @@ // Prepare the value to be set. {% if attribute.idl_type != 'EventHandler' %} - {{v8_value_to_local_cpp_value(attribute) | indent(2)}} + {{v8_value_to_local_cpp_value(attribute) | trim | indent(2)}} {% endif %} {% if attribute.has_type_checking_interface %} @@ -402,7 +402,7 @@ // Type check per: http://heycam.github.io/webidl/#dfn-attribute-setter // Returns undefined without setting the value if the value is invalid. DummyExceptionStateForTesting dummyExceptionState; - {{declare_enum_validation_variable(attribute.enum_values) | indent(2)}} + {{declare_enum_validation_variable(attribute.enum_values) | trim | indent(2)}} if (!IsValidEnum(cppValue, validValues, WTF_ARRAY_LENGTH(validValues), "{{attribute.enum_type}}", dummyExceptionState)) { ExecutionContext::ForCurrentRealm(info)->AddConsoleMessage( ConsoleMessage::Create(kJSMessageSource, kWarningMessageLevel, @@ -458,7 +458,7 @@ const v8::FunctionCallbackInfo<v8::Value>& info {%- endif %}) { {% if attribute.runtime_call_stats.extended_attribute_defined %} - {{ runtime_timer_scope(attribute.runtime_call_stats.setter_counter) | indent(2) }} + {{ runtime_timer_scope(attribute.runtime_call_stats.setter_counter) | trim | indent(2) }} {% else %} {{ runtime_timer_scope_disabled_by_default(attribute.runtime_call_stats.setter_counter) }} {% endif %} @@ -590,7 +590,7 @@ {% filter runtime_enabled(feature_name) %} static const V8DOMConfiguration::AccessorConfiguration accessor_configurations[] = { {% for attribute in attribute_list | sort %} - {{accessor_configuration(attribute) | indent(4)}}, + {{accessor_configuration(attribute) | trim | indent(4)}}, {% endfor %} }; V8DOMConfiguration::InstallAccessors( @@ -616,7 +616,7 @@ {% filter runtime_enabled(feature_name) %} static const V8DOMConfiguration::AttributeConfiguration attribute_configurations[] = { {% for attribute in attribute_list | sort %} - {{attribute_configuration(attribute) | indent(4)}}, + {{attribute_configuration(attribute) | trim | indent(4)}}, {% endfor %} }; V8DOMConfiguration::InstallAttributes(
diff --git a/third_party/WebKit/Source/bindings/templates/callback_function.cpp.tmpl b/third_party/WebKit/Source/bindings/templates/callback_function.cpp.tmpl index 7fcb1443..790b12c 100644 --- a/third_party/WebKit/Source/bindings/templates/callback_function.cpp.tmpl +++ b/third_party/WebKit/Source/bindings/templates/callback_function.cpp.tmpl
@@ -73,7 +73,7 @@ #if DCHECK_IS_ON() { {% set valid_enum_variables = 'valid_' + argument.name + '_values' %} - {{declare_enum_validation_variable(argument.enum_values, valid_enum_variables) | indent(4)}} + {{declare_enum_validation_variable(argument.enum_values, valid_enum_variables) | trim | indent(4)}} ExceptionState exception_state(GetIsolate(), ExceptionState::kExecutionContext, "{{callback_function_name}}", @@ -128,7 +128,7 @@ ExceptionState::kExecutionContext, "{{callback_function_name}}", "invoke"); - {{v8_value_to_local_cpp_value(return_value_conversion) | indent(4)}} + {{v8_value_to_local_cpp_value(return_value_conversion) | trim | indent(4)}} return v8::Just<{{return_cpp_type}}>(native_result); } {% endif %}
diff --git a/third_party/WebKit/Source/bindings/templates/callback_interface.cpp.tmpl b/third_party/WebKit/Source/bindings/templates/callback_interface.cpp.tmpl index 76bddeb..8c05a42d 100644 --- a/third_party/WebKit/Source/bindings/templates/callback_interface.cpp.tmpl +++ b/third_party/WebKit/Source/bindings/templates/callback_interface.cpp.tmpl
@@ -97,7 +97,7 @@ #if DCHECK_IS_ON() { {% set valid_enum_variables = 'valid_' + argument.name + '_values' %} - {{declare_enum_validation_variable(argument.enum_values, valid_enum_variables) | indent(4)}} + {{declare_enum_validation_variable(argument.enum_values, valid_enum_variables) | trim | indent(4)}} ExceptionState exception_state(GetIsolate(), ExceptionState::kExecutionContext, "{{cpp_class}}",
diff --git a/third_party/WebKit/Source/bindings/templates/dictionary_v8.cpp.tmpl b/third_party/WebKit/Source/bindings/templates/dictionary_v8.cpp.tmpl index 9f5d989..3980400e 100644 --- a/third_party/WebKit/Source/bindings/templates/dictionary_v8.cpp.tmpl +++ b/third_party/WebKit/Source/bindings/templates/dictionary_v8.cpp.tmpl
@@ -83,7 +83,7 @@ {% if member.deprecate_as %} Deprecation::CountDeprecation(CurrentExecutionContext(isolate), WebFeature::k{{member.deprecate_as}}); {% endif %} - {{v8_value_to_local_cpp_value(member) | indent}} + {{v8_value_to_local_cpp_value(member) | trim | indent}} {% if member.is_interface_type %} if (!{{member.name}}CppValue) { exceptionState.ThrowTypeError("member {{member.name}} is not of type {{member.idl_type}}."); @@ -91,7 +91,7 @@ } {% endif %} {% if member.enum_values %} - {{declare_enum_validation_variable(member.enum_values) | indent}} + {{declare_enum_validation_variable(member.enum_values) | trim | indent}} if (!IsValidEnum({{member.name}}CppValue, validValues, WTF_ARRAY_LENGTH(validValues), "{{member.enum_type}}", exceptionState)) return; {% elif member.is_object %}
diff --git a/third_party/WebKit/Source/bindings/templates/interface.cpp.tmpl b/third_party/WebKit/Source/bindings/templates/interface.cpp.tmpl index 374af84..325090f0 100644 --- a/third_party/WebKit/Source/bindings/templates/interface.cpp.tmpl +++ b/third_party/WebKit/Source/bindings/templates/interface.cpp.tmpl
@@ -79,7 +79,7 @@ {% endif %} {{cpp_class}}* impl = {{v8_class}}::ToImpl(info.Holder()); - {{v8_value_to_local_cpp_value(setter) | indent(2)}} + {{v8_value_to_local_cpp_value(setter) | trim | indent(2)}} {% if setter.has_type_checking_interface %} {# Type checking for interface types (if interface not implemented, throw TypeError), per http://www.w3.org/TR/WebIDL/#es-interface #} @@ -439,7 +439,7 @@ {% endif %} {{cpp_class}}* impl = {{v8_class}}::ToImpl(info.Holder()); - {{v8_value_to_local_cpp_value(setter) | indent(2)}} + {{v8_value_to_local_cpp_value(setter) | trim | indent(2)}} {% if setter.has_type_checking_interface %} {# Type checking for interface types (if interface not implemented, throw TypeError), per http://www.w3.org/TR/WebIDL/#es-interface #} @@ -981,7 +981,7 @@ // Named Properties object has SetPrototype method of Immutable Prototype Exotic Objects namedPropertiesObjectTemplate->SetImmutableProto(); V8DOMConfiguration::SetClassString(isolate, namedPropertiesObjectTemplate, "{{interface_name}}Properties"); - {{install_named_property_handler('namedPropertiesObjectTemplate') | indent(2)}} + {{install_named_property_handler('namedPropertiesObjectTemplate') | trim | indent(2)}} return namedPropertiesObjectFunctionTemplate; }
diff --git a/third_party/WebKit/Source/bindings/templates/interface_base.cpp.tmpl b/third_party/WebKit/Source/bindings/templates/interface_base.cpp.tmpl index 501b4bf..4d34aa9 100644 --- a/third_party/WebKit/Source/bindings/templates/interface_base.cpp.tmpl +++ b/third_party/WebKit/Source/bindings/templates/interface_base.cpp.tmpl
@@ -361,7 +361,7 @@ #endif static const V8DOMConfiguration::AttributeConfiguration {{v8_class}}Attributes[] = { {% for data_attribute in data_attributes %} - {{attribute_configuration(data_attribute) | indent(4)}}, + {{attribute_configuration(data_attribute) | trim | indent(4)}}, {% endfor %} }; #if defined(COMPONENT_BUILD) && defined(WIN32) && defined(__clang__) @@ -382,7 +382,7 @@ #endif static const V8DOMConfiguration::AttributeConfiguration {{v8_class}}LazyDataAttributes[] = { {% for data_attribute in lazy_data_attributes %} - {{attribute_configuration(data_attribute) | indent(4)}}, + {{attribute_configuration(data_attribute) | trim | indent(4)}}, {% endfor %} }; #if defined(COMPONENT_BUILD) && defined(WIN32) && defined(__clang__) @@ -397,7 +397,7 @@ {% if accessors %} static const V8DOMConfiguration::AccessorConfiguration {{v8_class}}Accessors[] = { {% for accessor in accessors %} - {{accessor_configuration(accessor) | indent(4)}}, + {{accessor_configuration(accessor) | trim | indent(4)}}, {% endfor %} }; @@ -409,7 +409,7 @@ {% if methods | has_method_configuration(is_partial) %} static const V8DOMConfiguration::MethodConfiguration {{v8_class}}Methods[] = { {% for method in methods | has_method_configuration(is_partial) %} - {{method_configuration(method) | indent(4)}}, + {{method_configuration(method) | trim | indent(4)}}, {% endfor %} }; @@ -486,7 +486,7 @@ // Register IDL constants, attributes and operations. {% if constants %} - {{install_constants() | indent(2)}} + {{install_constants() | trim | indent(2)}} {% endif %} {% if data_attributes %} V8DOMConfiguration::InstallAttributes( @@ -529,11 +529,11 @@ {% if (indexed_property_getter or named_property_getter) and not is_partial %} // Indexed properties - {{install_indexed_property_handler('instanceTemplate') | indent(2)}} + {{install_indexed_property_handler('instanceTemplate') | trim | indent(2)}} {% endif %} {% if named_property_getter and not is_partial and not has_named_properties_object %} // Named properties - {{install_named_property_handler('instanceTemplate') | indent(2)}} + {{install_named_property_handler('instanceTemplate') | trim | indent(2)}} {% endif %} {% if has_array_iterator and not is_partial %} @@ -661,9 +661,9 @@ if method.overloads else method.runtime_enabled_feature_name %} {% if not feature_name %} {% if method.is_cross_origin %} - {{install_origin_safe_method(method, 'instanceTemplate', 'prototypeTemplate') | indent(2)}} + {{install_origin_safe_method(method, 'instanceTemplate', 'prototypeTemplate') | trim | indent(2)}} {% else %} - {{install_custom_signature(method, 'instanceTemplate', 'prototypeTemplate', 'interfaceTemplate', 'signature') | indent(2)}} + {{install_custom_signature(method, 'instanceTemplate', 'prototypeTemplate', 'interfaceTemplate', 'signature') | trim | indent(2)}} {% endif %} {% endif %} {% endfilter %} @@ -701,7 +701,7 @@ {% filter runtime_enabled(feature_name) %} static const V8DOMConfiguration::ConstantConfiguration constant_configurations[] = { {% for constant in constants_list %} - {{constant_configuration(constant) | indent(6)}}, + {{constant_configuration(constant) | trim | indent(6)}}, {% endfor %} }; V8DOMConfiguration::InstallConstants( @@ -714,7 +714,7 @@ {% filter runtime_enabled(feature_name) %} static const V8DOMConfiguration::AttributeConfiguration attribute_configurations[] = { {% for attribute in attribute_list | sort %} - {{attribute_configuration(attribute) | indent(6)}}, + {{attribute_configuration(attribute) | trim | indent(6)}}, {% endfor %} }; V8DOMConfiguration::InstallAttributes( @@ -727,7 +727,7 @@ {% filter runtime_enabled(feature_name) %} static const V8DOMConfiguration::AccessorConfiguration accessor_configurations[] = { {% for attribute in attribute_list | sort %} - {{accessor_configuration(attribute) | indent(6)}}, + {{accessor_configuration(attribute) | trim | indent(6)}}, {% endfor %} }; V8DOMConfiguration::InstallAccessors( @@ -770,9 +770,9 @@ {% if feature_name %} {% filter runtime_enabled(feature_name) %} {% if method.is_cross_origin %} - {{install_origin_safe_method(method, 'instance_template', 'prototype_template') | indent(2)}} + {{install_origin_safe_method(method, 'instance_template', 'prototype_template') | trim | indent(2)}} {% else %} - {{install_custom_signature(method, 'instance_template', 'prototype_template', 'interface_template', 'signature') | indent(2)}} + {{install_custom_signature(method, 'instance_template', 'prototype_template', 'interface_template', 'signature') | trim | indent(2)}} {% endif %} {% endfilter %} {% endif %} @@ -827,7 +827,7 @@ {% filter runtime_enabled(feature_name) %} static const V8DOMConfiguration::AttributeConfiguration attribute_configurations[] = { {% for attribute in attrs | sort %} - {{attribute_configuration(attribute) | indent(6)}}, + {{attribute_configuration(attribute) | trim | indent(6)}}, {% endfor %} }; V8DOMConfiguration::InstallAttributes(isolate, world, instance, prototype, @@ -839,7 +839,7 @@ {% filter runtime_enabled(feature_name) %} static const V8DOMConfiguration::AccessorConfiguration accessor_configurations[] = { {% for attribute in attrs | sort %} - {{accessor_configuration(attribute) | indent(6)}}, + {{accessor_configuration(attribute) | trim | indent(6)}}, {% endfor %} }; V8DOMConfiguration::InstallAccessors(isolate, world, instance, prototype, @@ -863,7 +863,7 @@ {% if method.is_cross_origin %} #error "{{v8_class_or_partial}} should not have runtime enabled and cross origin methods." {% else %} - {{install_custom_signature(method, 'instance', 'prototype', 'interface', 'signature') | indent(2)}} + {{install_custom_signature(method, 'instance', 'prototype', 'interface', 'signature') | trim | indent(2)}} {% endif %} {% endfilter %} {% endif %} @@ -897,13 +897,13 @@ {% filter secure_context(attribute.secure_context_test, 'isSecureContext') %} {% if attribute.is_data_type_property %} static const V8DOMConfiguration::AttributeConfiguration attribute{{attribute.name}}Configuration[] = { - {{attribute_configuration(attribute) | indent(2)}} + {{attribute_configuration(attribute) | trim | indent(2)}} }; for (const auto& attributeConfig : attribute{{attribute.name}}Configuration) V8DOMConfiguration::InstallAttribute(isolate, world, instance, prototype, attributeConfig); {% else %} static const V8DOMConfiguration::AccessorConfiguration accessor{{attribute.name}}Configuration[] = { - {{accessor_configuration(attribute) | indent(2)}} + {{accessor_configuration(attribute) | trim | indent(2)}} }; for (const auto& accessorConfig : accessor{{attribute.name}}Configuration) V8DOMConfiguration::InstallAccessor(isolate, world, instance, prototype, interface, signature, accessorConfig); @@ -921,7 +921,7 @@ {% filter secure_context(method.secure_context_test, 'isSecureContext') %} {% set method_name = method.name.title().replace('_', '') %} static const V8DOMConfiguration::MethodConfiguration method{{method_name}}Configuration[] = { - {{method_configuration(method) | indent(2)}} + {{method_configuration(method) | trim | indent(2)}} }; for (const auto& methodConfig : method{{method_name}}Configuration) V8DOMConfiguration::InstallMethod(isolate, world, instance, prototype, interface, signature, methodConfig); @@ -1009,16 +1009,16 @@ {% set attributes_on_instance = conditional_attributes | selectattr('on_instance') | list %} {% if attributes_on_instance or conditional_interface_objects %} if (!instanceObject.IsEmpty()) { - {{install_conditional_attributes('isSecureContext', attributes_on_instance) | indent(4)}} - {{install_conditional_interface_objects('isSecureContext', conditional_interface_objects) | indent(4)}} + {{install_conditional_attributes('isSecureContext', attributes_on_instance) | trim | indent(4)}} + {{install_conditional_interface_objects('isSecureContext', conditional_interface_objects) | trim | indent(4)}} } {% endif %} {% set attributes_on_prototype = conditional_attributes | selectattr('on_prototype') | list %} {% set attributes_on_interface = conditional_attributes | selectattr('on_interface') | list %} if (!prototypeObject.IsEmpty() || !interfaceObject.IsEmpty()) { - {{install_conditional_attributes('isSecureContext', attributes_on_prototype + attributes_on_interface) | indent(4)}} - {{install_conditional_methods('isSecureContext') | indent(4)}} + {{install_conditional_attributes('isSecureContext', attributes_on_prototype + attributes_on_interface) | trim | indent(4)}} + {{install_conditional_methods('isSecureContext') | trim | indent(4)}} } {% endif %}{# conditional_attributes or conditional_methods #} }
diff --git a/third_party/WebKit/Source/bindings/templates/legacy_callback_interface.cpp.tmpl b/third_party/WebKit/Source/bindings/templates/legacy_callback_interface.cpp.tmpl index 0f67d02..16544e2 100644 --- a/third_party/WebKit/Source/bindings/templates/legacy_callback_interface.cpp.tmpl +++ b/third_party/WebKit/Source/bindings/templates/legacy_callback_interface.cpp.tmpl
@@ -58,7 +58,7 @@ ALLOW_UNUSED_LOCAL(prototypeTemplate); // Register DOM constants. - {{install_constants() | indent(2)}} + {{install_constants() | trim | indent(2)}} } v8::Local<v8::FunctionTemplate> {{v8_class}}::DomTemplate(v8::Isolate* isolate,
diff --git a/third_party/WebKit/Source/bindings/templates/methods.cpp.tmpl b/third_party/WebKit/Source/bindings/templates/methods.cpp.tmpl index 891aed7c..de9e9c847 100644 --- a/third_party/WebKit/Source/bindings/templates/methods.cpp.tmpl +++ b/third_party/WebKit/Source/bindings/templates/methods.cpp.tmpl
@@ -72,7 +72,7 @@ V0CustomElementProcessingStack::CallbackDeliveryScope deliveryScope; {% endif %} - {{function_call | indent(2)}} + {{function_call | trim | indent(2)}} } {% endfilter %} {% endmacro %} @@ -120,9 +120,9 @@ {% for argument in method.arguments %} {% if argument.set_default_value %} if (!info[{{argument.index}}]->IsUndefined()) { - {{generate_argument(method, argument, world_suffix) | indent(2)}} + {{generate_argument(method, argument, world_suffix) | trim | indent(2)}} } else { - {{argument.set_default_value | indent(2)}}; + {{argument.set_default_value | trim | indent(2)}}; } {% else %} {{generate_argument(method, argument, world_suffix)}} @@ -141,9 +141,9 @@ Optional Dictionary arguments default to empty dictionary. #} if (UNLIKELY(numArgsPassed <= {{argument.index}})) { {% if world_suffix %} - {{cpp_method_call(method, argument.v8_set_return_value_for_main_world, argument.cpp_value) | indent(2)}} + {{cpp_method_call(method, argument.v8_set_return_value_for_main_world, argument.cpp_value) | trim | indent(2)}} {% else %} - {{cpp_method_call(method, argument.v8_set_return_value, argument.cpp_value) | indent(2)}} + {{cpp_method_call(method, argument.v8_set_return_value, argument.cpp_value) | trim | indent(2)}} {% endif %} return; } @@ -211,7 +211,7 @@ {{v8_value_to_local_cpp_value(argument)}} {% elif argument.is_explicit_nullable %} if (!info[{{argument.index}}]->IsNullOrUndefined()) { - {{v8_value_to_local_cpp_value(argument) | indent(2)}} + {{v8_value_to_local_cpp_value(argument) | trim | indent(2)}} } {% else %}{# argument is something else #} {{v8_value_to_local_cpp_value(argument)}} @@ -510,7 +510,7 @@ {% macro method_callback(method, world_suffix) %} void {{v8_class_or_partial}}::{{method.name}}MethodCallback{{world_suffix}}(const v8::FunctionCallbackInfo<v8::Value>& info) { {% if method.runtime_call_stats.extended_attribute_defined %} - {{ runtime_timer_scope(method.runtime_call_stats.method_counter) | indent(2) }} + {{ runtime_timer_scope(method.runtime_call_stats.method_counter) | trim | indent(2) }} {% else %} {{ runtime_timer_scope_disabled_by_default(method.runtime_call_stats.method_counter) }} {% endif %} @@ -615,7 +615,7 @@ info.NewTarget().As<v8::Object>()->CreationContext()); {% endif %} - {{function_call | indent(2)}} + {{function_call | trim | indent(2)}} } {% endmacro %} @@ -660,7 +660,7 @@ {######################################} {% macro install_custom_signature(method, instance_template, prototype_template, interface_template, signature) %} const V8DOMConfiguration::MethodConfiguration {{method.name}}MethodConfiguration[] = { - {{method_configuration(method) | indent(2)}} + {{method_configuration(method) | trim | indent(2)}} }; for (const auto& methodConfig : {{method.name}}MethodConfiguration) V8DOMConfiguration::InstallMethod(isolate, world, {{instance_template}}, {{prototype_template}}, {{interface_template}}, {{signature}}, methodConfig); @@ -681,7 +681,7 @@ if method.overloads else method.runtime_enabled_feature_name) %} const V8DOMConfiguration::MethodConfiguration {{method.name}}MethodConfiguration[] = { - {{method_configuration(method) | indent(2)}} + {{method_configuration(method) | trim | indent(2)}} }; for (const auto& methodConfig : {{method.name}}MethodConfiguration) V8DOMConfiguration::InstallMethod(isolate, world, v8::Local<v8::Object>(), prototypeObject, interfaceObject, signature, methodConfig);
diff --git a/third_party/WebKit/Source/bindings/templates/union_container.cpp.tmpl b/third_party/WebKit/Source/bindings/templates/union_container.cpp.tmpl index c6b74e650..a95693e 100644 --- a/third_party/WebKit/Source/bindings/templates/union_container.cpp.tmpl +++ b/third_party/WebKit/Source/bindings/templates/union_container.cpp.tmpl
@@ -41,7 +41,7 @@ DCHECK(IsNull()); {% if member.enum_values %} NonThrowableExceptionState exceptionState; - {{declare_enum_validation_variable(member.enum_values) | indent(2)}} + {{declare_enum_validation_variable(member.enum_values) | trim | indent(2)}} if (!IsValidEnum(value, validValues, WTF_ARRAY_LENGTH(validValues), "{{member.enum_type}}", exceptionState)) { NOTREACHED(); return; @@ -85,7 +85,7 @@ {% if dictionary_type %} {# 3. Dictionaries for null or undefined #} if (IsUndefinedOrNull(v8Value)) { - {{v8_value_to_local_cpp_value(dictionary_type) | indent}} + {{v8_value_to_local_cpp_value(dictionary_type) | trim | indent}} impl.Set{{dictionary_type.type_name}}(cppValue); return; } @@ -93,26 +93,26 @@ {% endif %} {# 4. Platform objects (interfaces) #} {% for interface in interface_types %} - {{assign_and_return_if_hasinstance(interface) | indent(2)}} + {{assign_and_return_if_hasinstance(interface) | trim | indent(2)}} {% endfor %} {# 8. ArrayBuffer #} {% if array_buffer_type %} - {{assign_and_return_if_hasinstance(array_buffer_type) | indent(2)}} + {{assign_and_return_if_hasinstance(array_buffer_type) | trim | indent(2)}} {% endif %} {# 9., 10. ArrayBufferView #} {# FIXME: Individual typed arrays (e.g. Uint8Array) aren\'t supported yet. #} {% if array_buffer_view_type %} - {{assign_and_return_if_hasinstance(array_buffer_view_type) | indent(2)}} + {{assign_and_return_if_hasinstance(array_buffer_view_type) | trim | indent(2)}} {% endif %} {% if array_or_sequence_type %} {# 11.1, 11.2. Sequences and frozen arrays #} if (HasCallableIteratorSymbol(isolate, v8Value, exceptionState)) { - {{v8_value_to_local_cpp_value(array_or_sequence_type) | indent}} + {{v8_value_to_local_cpp_value(array_or_sequence_type) | trim | indent}} {% if array_or_sequence_type.enum_values %} - {{declare_enum_validation_variable(array_or_sequence_type.enum_values) | indent(4)}} + {{declare_enum_validation_variable(array_or_sequence_type.enum_values) | trim | indent(4)}} if (!IsValidEnum(cppValue, validValues, WTF_ARRAY_LENGTH(validValues), "{{array_or_sequence_type.enum_type}}", exceptionState)) return; {% endif %} @@ -124,7 +124,7 @@ {% if dictionary_type %} {# 11.3. Dictionaries #} if (v8Value->IsObject()) { - {{v8_value_to_local_cpp_value(dictionary_type) | indent}} + {{v8_value_to_local_cpp_value(dictionary_type) | trim | indent}} impl.Set{{dictionary_type.type_name}}(cppValue); return; } @@ -133,7 +133,7 @@ {# 11.4. Records #} {% if record_type %} if (v8Value->IsObject()) { - {{v8_value_to_local_cpp_value(record_type) | indent}} + {{v8_value_to_local_cpp_value(record_type) | trim | indent}} impl.Set{{record_type.type_name}}(cppValue); return; } @@ -143,7 +143,7 @@ {# 11.6. Objects #} {% if object_type %} if (IsUndefinedOrNull(v8Value) || v8Value->IsObject()) { - {{v8_value_to_local_cpp_value(object_type) | indent}} + {{v8_value_to_local_cpp_value(object_type) | trim | indent}} impl.Set{{object_type.type_name}}(cppValue); return; } @@ -162,7 +162,7 @@ {% if numeric_type %} {# 13. Number #} if (v8Value->IsNumber()) { - {{v8_value_to_local_cpp_value(numeric_type) | indent}} + {{v8_value_to_local_cpp_value(numeric_type) | trim | indent}} impl.Set{{numeric_type.type_name}}(cppValue); return; } @@ -171,9 +171,9 @@ {% if string_type %} {# 14. String #} { - {{v8_value_to_local_cpp_value(string_type) | indent}} + {{v8_value_to_local_cpp_value(string_type) | trim | indent}} {% if string_type.enum_values %} - {{declare_enum_validation_variable(string_type.enum_values) | indent}} + {{declare_enum_validation_variable(string_type.enum_values) | trim | indent}} if (!IsValidEnum(cppValue, validValues, WTF_ARRAY_LENGTH(validValues), "{{string_type.enum_type}}", exceptionState)) return; {% endif %} @@ -184,7 +184,7 @@ {# 15. Number (fallback) #} {% elif numeric_type %} { - {{v8_value_to_local_cpp_value(numeric_type) | indent}} + {{v8_value_to_local_cpp_value(numeric_type) | trim | indent}} impl.Set{{numeric_type.type_name}}(cppValue); return; }
diff --git a/third_party/WebKit/Source/bindings/tests/results/core/V8SVGTestInterface.cpp b/third_party/WebKit/Source/bindings/tests/results/core/V8SVGTestInterface.cpp index 1912f8c..c80bb4d 100644 --- a/third_party/WebKit/Source/bindings/tests/results/core/V8SVGTestInterface.cpp +++ b/third_party/WebKit/Source/bindings/tests/results/core/V8SVGTestInterface.cpp
@@ -108,8 +108,7 @@ } static const V8DOMConfiguration::AccessorConfiguration V8SVGTestInterfaceAccessors[] = { - { "type", V8SVGTestInterface::typeAttributeGetterCallback, V8SVGTestInterface::typeAttributeSetterCallback, V8PrivateProperty::kNoCachedAccessor, static_cast<v8::PropertyAttribute>(v8::None), V8DOMConfiguration::kOnPrototype, V8DOMConfiguration::kCheckHolder, V8DOMConfiguration::kAllWorlds } -, + { "type", V8SVGTestInterface::typeAttributeGetterCallback, V8SVGTestInterface::typeAttributeSetterCallback, V8PrivateProperty::kNoCachedAccessor, static_cast<v8::PropertyAttribute>(v8::None), V8DOMConfiguration::kOnPrototype, V8DOMConfiguration::kCheckHolder, V8DOMConfiguration::kAllWorlds }, }; static void installV8SVGTestInterfaceTemplate(
diff --git a/third_party/WebKit/Source/bindings/tests/results/core/V8TestAttributeGetters.cpp b/third_party/WebKit/Source/bindings/tests/results/core/V8TestAttributeGetters.cpp index 26020ff02..61afda9 100644 --- a/third_party/WebKit/Source/bindings/tests/results/core/V8TestAttributeGetters.cpp +++ b/third_party/WebKit/Source/bindings/tests/results/core/V8TestAttributeGetters.cpp
@@ -179,20 +179,11 @@ } static const V8DOMConfiguration::AccessorConfiguration V8TestAttributeGettersAccessors[] = { - { "lenientThisLongAttribute", V8TestAttributeGetters::lenientThisLongAttributeAttributeGetterCallback, nullptr, V8PrivateProperty::kNoCachedAccessor, static_cast<v8::PropertyAttribute>(v8::ReadOnly), V8DOMConfiguration::kOnPrototype, V8DOMConfiguration::kDoNotCheckHolder, V8DOMConfiguration::kAllWorlds } -, - - { "stringPromiseAttribute", V8TestAttributeGetters::stringPromiseAttributeAttributeGetterCallback, nullptr, V8PrivateProperty::kNoCachedAccessor, static_cast<v8::PropertyAttribute>(v8::ReadOnly), V8DOMConfiguration::kOnPrototype, V8DOMConfiguration::kDoNotCheckHolder, V8DOMConfiguration::kAllWorlds } -, - - { "lenientThisStringPromiseAttribute", V8TestAttributeGetters::lenientThisStringPromiseAttributeAttributeGetterCallback, nullptr, V8PrivateProperty::kNoCachedAccessor, static_cast<v8::PropertyAttribute>(v8::ReadOnly), V8DOMConfiguration::kOnPrototype, V8DOMConfiguration::kDoNotCheckHolder, V8DOMConfiguration::kAllWorlds } -, - - { "raisesExceptionShortPromiseAttribute", V8TestAttributeGetters::raisesExceptionShortPromiseAttributeAttributeGetterCallback, nullptr, V8PrivateProperty::kNoCachedAccessor, static_cast<v8::PropertyAttribute>(v8::ReadOnly), V8DOMConfiguration::kOnPrototype, V8DOMConfiguration::kDoNotCheckHolder, V8DOMConfiguration::kAllWorlds } -, - - { "floatAttribute", V8TestAttributeGetters::floatAttributeAttributeGetterCallback, nullptr, V8PrivateProperty::kNoCachedAccessor, static_cast<v8::PropertyAttribute>(v8::ReadOnly), V8DOMConfiguration::kOnPrototype, V8DOMConfiguration::kCheckHolder, V8DOMConfiguration::kAllWorlds } -, + { "lenientThisLongAttribute", V8TestAttributeGetters::lenientThisLongAttributeAttributeGetterCallback, nullptr, V8PrivateProperty::kNoCachedAccessor, static_cast<v8::PropertyAttribute>(v8::ReadOnly), V8DOMConfiguration::kOnPrototype, V8DOMConfiguration::kDoNotCheckHolder, V8DOMConfiguration::kAllWorlds }, + { "stringPromiseAttribute", V8TestAttributeGetters::stringPromiseAttributeAttributeGetterCallback, nullptr, V8PrivateProperty::kNoCachedAccessor, static_cast<v8::PropertyAttribute>(v8::ReadOnly), V8DOMConfiguration::kOnPrototype, V8DOMConfiguration::kDoNotCheckHolder, V8DOMConfiguration::kAllWorlds }, + { "lenientThisStringPromiseAttribute", V8TestAttributeGetters::lenientThisStringPromiseAttributeAttributeGetterCallback, nullptr, V8PrivateProperty::kNoCachedAccessor, static_cast<v8::PropertyAttribute>(v8::ReadOnly), V8DOMConfiguration::kOnPrototype, V8DOMConfiguration::kDoNotCheckHolder, V8DOMConfiguration::kAllWorlds }, + { "raisesExceptionShortPromiseAttribute", V8TestAttributeGetters::raisesExceptionShortPromiseAttributeAttributeGetterCallback, nullptr, V8PrivateProperty::kNoCachedAccessor, static_cast<v8::PropertyAttribute>(v8::ReadOnly), V8DOMConfiguration::kOnPrototype, V8DOMConfiguration::kDoNotCheckHolder, V8DOMConfiguration::kAllWorlds }, + { "floatAttribute", V8TestAttributeGetters::floatAttributeAttributeGetterCallback, nullptr, V8PrivateProperty::kNoCachedAccessor, static_cast<v8::PropertyAttribute>(v8::ReadOnly), V8DOMConfiguration::kOnPrototype, V8DOMConfiguration::kCheckHolder, V8DOMConfiguration::kAllWorlds }, }; static void installV8TestAttributeGettersTemplate(
diff --git a/third_party/WebKit/Source/bindings/tests/results/core/V8TestCallbackFunctions.cpp b/third_party/WebKit/Source/bindings/tests/results/core/V8TestCallbackFunctions.cpp index a30ba78..798bbbd 100644 --- a/third_party/WebKit/Source/bindings/tests/results/core/V8TestCallbackFunctions.cpp +++ b/third_party/WebKit/Source/bindings/tests/results/core/V8TestCallbackFunctions.cpp
@@ -155,7 +155,6 @@ } if (UNLIKELY(numArgsPassed <= 0)) { impl->voidMethodOptionalCallbackFunctionInArg(); - return; } if (info[0]->IsFunction()) { @@ -256,8 +255,7 @@ } static const V8DOMConfiguration::AccessorConfiguration V8TestCallbackFunctionsAccessors[] = { - { "customElementsCallbacksReadonlyAttribute", V8TestCallbackFunctions::customElementsCallbacksReadonlyAttributeAttributeGetterCallback, nullptr, V8PrivateProperty::kNoCachedAccessor, static_cast<v8::PropertyAttribute>(v8::ReadOnly), V8DOMConfiguration::kOnPrototype, V8DOMConfiguration::kCheckHolder, V8DOMConfiguration::kAllWorlds } -, + { "customElementsCallbacksReadonlyAttribute", V8TestCallbackFunctions::customElementsCallbacksReadonlyAttributeAttributeGetterCallback, nullptr, V8PrivateProperty::kNoCachedAccessor, static_cast<v8::PropertyAttribute>(v8::ReadOnly), V8DOMConfiguration::kOnPrototype, V8DOMConfiguration::kCheckHolder, V8DOMConfiguration::kAllWorlds }, }; static const V8DOMConfiguration::MethodConfiguration V8TestCallbackFunctionsMethods[] = {
diff --git a/third_party/WebKit/Source/bindings/tests/results/core/V8TestIntegerIndexed.cpp b/third_party/WebKit/Source/bindings/tests/results/core/V8TestIntegerIndexed.cpp index 6486a22..7e5516f 100644 --- a/third_party/WebKit/Source/bindings/tests/results/core/V8TestIntegerIndexed.cpp +++ b/third_party/WebKit/Source/bindings/tests/results/core/V8TestIntegerIndexed.cpp
@@ -315,8 +315,7 @@ } static const V8DOMConfiguration::AccessorConfiguration V8TestIntegerIndexedAccessors[] = { - { "length", V8TestIntegerIndexed::lengthAttributeGetterCallback, V8TestIntegerIndexed::lengthAttributeSetterCallback, V8PrivateProperty::kNoCachedAccessor, static_cast<v8::PropertyAttribute>(v8::None), V8DOMConfiguration::kOnPrototype, V8DOMConfiguration::kCheckHolder, V8DOMConfiguration::kAllWorlds } -, + { "length", V8TestIntegerIndexed::lengthAttributeGetterCallback, V8TestIntegerIndexed::lengthAttributeSetterCallback, V8PrivateProperty::kNoCachedAccessor, static_cast<v8::PropertyAttribute>(v8::None), V8DOMConfiguration::kOnPrototype, V8DOMConfiguration::kCheckHolder, V8DOMConfiguration::kAllWorlds }, }; static const V8DOMConfiguration::MethodConfiguration V8TestIntegerIndexedMethods[] = {
diff --git a/third_party/WebKit/Source/bindings/tests/results/core/V8TestIntegerIndexedGlobal.cpp b/third_party/WebKit/Source/bindings/tests/results/core/V8TestIntegerIndexedGlobal.cpp index 88731b0..17a7fde6 100644 --- a/third_party/WebKit/Source/bindings/tests/results/core/V8TestIntegerIndexedGlobal.cpp +++ b/third_party/WebKit/Source/bindings/tests/results/core/V8TestIntegerIndexedGlobal.cpp
@@ -237,8 +237,7 @@ } static const V8DOMConfiguration::AccessorConfiguration V8TestIntegerIndexedGlobalAccessors[] = { - { "length", V8TestIntegerIndexedGlobal::lengthAttributeGetterCallback, V8TestIntegerIndexedGlobal::lengthAttributeSetterCallback, V8PrivateProperty::kNoCachedAccessor, static_cast<v8::PropertyAttribute>(v8::None), V8DOMConfiguration::kOnInstance, V8DOMConfiguration::kCheckHolder, V8DOMConfiguration::kAllWorlds } -, + { "length", V8TestIntegerIndexedGlobal::lengthAttributeGetterCallback, V8TestIntegerIndexedGlobal::lengthAttributeSetterCallback, V8PrivateProperty::kNoCachedAccessor, static_cast<v8::PropertyAttribute>(v8::None), V8DOMConfiguration::kOnInstance, V8DOMConfiguration::kCheckHolder, V8DOMConfiguration::kAllWorlds }, }; static const V8DOMConfiguration::MethodConfiguration V8TestIntegerIndexedGlobalMethods[] = {
diff --git a/third_party/WebKit/Source/bindings/tests/results/core/V8TestIntegerIndexedPrimaryGlobal.cpp b/third_party/WebKit/Source/bindings/tests/results/core/V8TestIntegerIndexedPrimaryGlobal.cpp index 5fd3b28..2117a6e 100644 --- a/third_party/WebKit/Source/bindings/tests/results/core/V8TestIntegerIndexedPrimaryGlobal.cpp +++ b/third_party/WebKit/Source/bindings/tests/results/core/V8TestIntegerIndexedPrimaryGlobal.cpp
@@ -237,8 +237,7 @@ } static const V8DOMConfiguration::AccessorConfiguration V8TestIntegerIndexedPrimaryGlobalAccessors[] = { - { "length", V8TestIntegerIndexedPrimaryGlobal::lengthAttributeGetterCallback, V8TestIntegerIndexedPrimaryGlobal::lengthAttributeSetterCallback, V8PrivateProperty::kNoCachedAccessor, static_cast<v8::PropertyAttribute>(v8::None), V8DOMConfiguration::kOnInstance, V8DOMConfiguration::kCheckHolder, V8DOMConfiguration::kAllWorlds } -, + { "length", V8TestIntegerIndexedPrimaryGlobal::lengthAttributeGetterCallback, V8TestIntegerIndexedPrimaryGlobal::lengthAttributeSetterCallback, V8PrivateProperty::kNoCachedAccessor, static_cast<v8::PropertyAttribute>(v8::None), V8DOMConfiguration::kOnInstance, V8DOMConfiguration::kCheckHolder, V8DOMConfiguration::kAllWorlds }, }; static const V8DOMConfiguration::MethodConfiguration V8TestIntegerIndexedPrimaryGlobalMethods[] = {
diff --git a/third_party/WebKit/Source/bindings/tests/results/core/V8TestInterface.cpp b/third_party/WebKit/Source/bindings/tests/results/core/V8TestInterface.cpp index c90cf87..c15c538 100644 --- a/third_party/WebKit/Source/bindings/tests/results/core/V8TestInterface.cpp +++ b/third_party/WebKit/Source/bindings/tests/results/core/V8TestInterface.cpp
@@ -3526,106 +3526,44 @@ #pragma clang diagnostic ignored "-Wglobal-constructors" #endif static const V8DOMConfiguration::AttributeConfiguration V8TestInterfaceLazyDataAttributes[] = { - { "testInterfaceConstructorAttribute", V8TestInterface::testInterfaceConstructorAttributeConstructorGetterCallback, nullptr, static_cast<v8::PropertyAttribute>(v8::DontEnum), V8DOMConfiguration::kOnInstance, V8DOMConfiguration::kCheckHolder, V8DOMConfiguration::kAllWorlds } -, - - { "TestInterface", V8TestInterface::TestInterfaceConstructorGetterCallback, nullptr, static_cast<v8::PropertyAttribute>(v8::DontEnum), V8DOMConfiguration::kOnInstance, V8DOMConfiguration::kCheckHolder, V8DOMConfiguration::kAllWorlds } -, - - { "TestInterface2", V8TestInterface::TestInterface2ConstructorGetterCallback, nullptr, static_cast<v8::PropertyAttribute>(v8::DontEnum), V8DOMConfiguration::kOnInstance, V8DOMConfiguration::kCheckHolder, V8DOMConfiguration::kAllWorlds } -, + { "testInterfaceConstructorAttribute", V8TestInterface::testInterfaceConstructorAttributeConstructorGetterCallback, nullptr, static_cast<v8::PropertyAttribute>(v8::DontEnum), V8DOMConfiguration::kOnInstance, V8DOMConfiguration::kCheckHolder, V8DOMConfiguration::kAllWorlds }, + { "TestInterface", V8TestInterface::TestInterfaceConstructorGetterCallback, nullptr, static_cast<v8::PropertyAttribute>(v8::DontEnum), V8DOMConfiguration::kOnInstance, V8DOMConfiguration::kCheckHolder, V8DOMConfiguration::kAllWorlds }, + { "TestInterface2", V8TestInterface::TestInterface2ConstructorGetterCallback, nullptr, static_cast<v8::PropertyAttribute>(v8::DontEnum), V8DOMConfiguration::kOnInstance, V8DOMConfiguration::kCheckHolder, V8DOMConfiguration::kAllWorlds }, }; #if defined(COMPONENT_BUILD) && defined(WIN32) && defined(__clang__) #pragma clang diagnostic pop #endif static const V8DOMConfiguration::AccessorConfiguration V8TestInterfaceAccessors[] = { - { "testInterfaceAttribute", V8TestInterface::testInterfaceAttributeAttributeGetterCallback, V8TestInterface::testInterfaceAttributeAttributeSetterCallback, V8PrivateProperty::kNoCachedAccessor, static_cast<v8::PropertyAttribute>(v8::None), V8DOMConfiguration::kOnPrototype, V8DOMConfiguration::kCheckHolder, V8DOMConfiguration::kAllWorlds } -, - - { "doubleAttribute", V8TestInterface::doubleAttributeAttributeGetterCallback, V8TestInterface::doubleAttributeAttributeSetterCallback, V8PrivateProperty::kNoCachedAccessor, static_cast<v8::PropertyAttribute>(v8::None), V8DOMConfiguration::kOnPrototype, V8DOMConfiguration::kCheckHolder, V8DOMConfiguration::kAllWorlds } -, - - { "floatAttribute", V8TestInterface::floatAttributeAttributeGetterCallback, V8TestInterface::floatAttributeAttributeSetterCallback, V8PrivateProperty::kNoCachedAccessor, static_cast<v8::PropertyAttribute>(v8::None), V8DOMConfiguration::kOnPrototype, V8DOMConfiguration::kCheckHolder, V8DOMConfiguration::kAllWorlds } -, - - { "unrestrictedDoubleAttribute", V8TestInterface::unrestrictedDoubleAttributeAttributeGetterCallback, V8TestInterface::unrestrictedDoubleAttributeAttributeSetterCallback, V8PrivateProperty::kNoCachedAccessor, static_cast<v8::PropertyAttribute>(v8::None), V8DOMConfiguration::kOnPrototype, V8DOMConfiguration::kCheckHolder, V8DOMConfiguration::kAllWorlds } -, - - { "unrestrictedFloatAttribute", V8TestInterface::unrestrictedFloatAttributeAttributeGetterCallback, V8TestInterface::unrestrictedFloatAttributeAttributeSetterCallback, V8PrivateProperty::kNoCachedAccessor, static_cast<v8::PropertyAttribute>(v8::None), V8DOMConfiguration::kOnPrototype, V8DOMConfiguration::kCheckHolder, V8DOMConfiguration::kAllWorlds } -, - - { "testEnumAttribute", V8TestInterface::testEnumAttributeAttributeGetterCallback, V8TestInterface::testEnumAttributeAttributeSetterCallback, V8PrivateProperty::kNoCachedAccessor, static_cast<v8::PropertyAttribute>(v8::None), V8DOMConfiguration::kOnPrototype, V8DOMConfiguration::kCheckHolder, V8DOMConfiguration::kAllWorlds } -, - - { "testEnumOrNullAttribute", V8TestInterface::testEnumOrNullAttributeAttributeGetterCallback, V8TestInterface::testEnumOrNullAttributeAttributeSetterCallback, V8PrivateProperty::kNoCachedAccessor, static_cast<v8::PropertyAttribute>(v8::None), V8DOMConfiguration::kOnPrototype, V8DOMConfiguration::kCheckHolder, V8DOMConfiguration::kAllWorlds } -, - - { "stringOrDoubleAttribute", V8TestInterface::stringOrDoubleAttributeAttributeGetterCallback, V8TestInterface::stringOrDoubleAttributeAttributeSetterCallback, V8PrivateProperty::kNoCachedAccessor, static_cast<v8::PropertyAttribute>(v8::None), V8DOMConfiguration::kOnPrototype, V8DOMConfiguration::kCheckHolder, V8DOMConfiguration::kAllWorlds } -, - - { "withExtendedAttributeStringAttribute", V8TestInterface::withExtendedAttributeStringAttributeAttributeGetterCallback, V8TestInterface::withExtendedAttributeStringAttributeAttributeSetterCallback, V8PrivateProperty::kNoCachedAccessor, static_cast<v8::PropertyAttribute>(v8::None), V8DOMConfiguration::kOnPrototype, V8DOMConfiguration::kCheckHolder, V8DOMConfiguration::kAllWorlds } -, - - { "uncapitalAttribute", V8TestInterface::uncapitalAttributeAttributeGetterCallback, V8TestInterface::uncapitalAttributeAttributeSetterCallback, V8PrivateProperty::kNoCachedAccessor, static_cast<v8::PropertyAttribute>(v8::None), V8DOMConfiguration::kOnPrototype, V8DOMConfiguration::kCheckHolder, V8DOMConfiguration::kAllWorlds } -, - - { "staticStringAttribute", V8TestInterface::staticStringAttributeAttributeGetterCallback, V8TestInterface::staticStringAttributeAttributeSetterCallback, V8PrivateProperty::kNoCachedAccessor, static_cast<v8::PropertyAttribute>(v8::None), V8DOMConfiguration::kOnInterface, V8DOMConfiguration::kCheckHolder, V8DOMConfiguration::kAllWorlds } -, - - { "staticReturnDOMWrapperAttribute", V8TestInterface::staticReturnDOMWrapperAttributeAttributeGetterCallback, V8TestInterface::staticReturnDOMWrapperAttributeAttributeSetterCallback, V8PrivateProperty::kNoCachedAccessor, static_cast<v8::PropertyAttribute>(v8::None), V8DOMConfiguration::kOnInterface, V8DOMConfiguration::kCheckHolder, V8DOMConfiguration::kAllWorlds } -, - - { "staticReadOnlyStringAttribute", V8TestInterface::staticReadOnlyStringAttributeAttributeGetterCallback, nullptr, V8PrivateProperty::kNoCachedAccessor, static_cast<v8::PropertyAttribute>(v8::ReadOnly), V8DOMConfiguration::kOnInterface, V8DOMConfiguration::kCheckHolder, V8DOMConfiguration::kAllWorlds } -, - - { "staticReadOnlyReturnDOMWrapperAttribute", V8TestInterface::staticReadOnlyReturnDOMWrapperAttributeAttributeGetterCallback, nullptr, V8PrivateProperty::kNoCachedAccessor, static_cast<v8::PropertyAttribute>(v8::ReadOnly), V8DOMConfiguration::kOnInterface, V8DOMConfiguration::kCheckHolder, V8DOMConfiguration::kAllWorlds } -, - - { "legacyInterfaceTypeCheckingAttribute", V8TestInterface::legacyInterfaceTypeCheckingAttributeAttributeGetterCallback, V8TestInterface::legacyInterfaceTypeCheckingAttributeAttributeSetterCallback, V8PrivateProperty::kNoCachedAccessor, static_cast<v8::PropertyAttribute>(v8::None), V8DOMConfiguration::kOnPrototype, V8DOMConfiguration::kCheckHolder, V8DOMConfiguration::kAllWorlds } -, - - { "stringNullAsEmptyAttribute", V8TestInterface::stringNullAsEmptyAttributeAttributeGetterCallback, V8TestInterface::stringNullAsEmptyAttributeAttributeSetterCallback, V8PrivateProperty::kNoCachedAccessor, static_cast<v8::PropertyAttribute>(v8::None), V8DOMConfiguration::kOnPrototype, V8DOMConfiguration::kCheckHolder, V8DOMConfiguration::kAllWorlds } -, - - { "usvStringOrNullAttribute", V8TestInterface::usvStringOrNullAttributeAttributeGetterCallback, V8TestInterface::usvStringOrNullAttributeAttributeSetterCallback, V8PrivateProperty::kNoCachedAccessor, static_cast<v8::PropertyAttribute>(v8::None), V8DOMConfiguration::kOnPrototype, V8DOMConfiguration::kCheckHolder, V8DOMConfiguration::kAllWorlds } -, - - { "alwaysExposedAttribute", V8TestInterface::alwaysExposedAttributeAttributeGetterCallback, V8TestInterface::alwaysExposedAttributeAttributeSetterCallback, V8PrivateProperty::kNoCachedAccessor, static_cast<v8::PropertyAttribute>(v8::None), V8DOMConfiguration::kOnPrototype, V8DOMConfiguration::kCheckHolder, V8DOMConfiguration::kAllWorlds } -, - - { "lenientThisAttribute", V8TestInterface::lenientThisAttributeAttributeGetterCallback, V8TestInterface::lenientThisAttributeAttributeSetterCallback, V8PrivateProperty::kNoCachedAccessor, static_cast<v8::PropertyAttribute>(v8::None), V8DOMConfiguration::kOnPrototype, V8DOMConfiguration::kDoNotCheckHolder, V8DOMConfiguration::kAllWorlds } -, - - { "implementsStaticReadOnlyLongAttribute", V8TestInterface::implementsStaticReadOnlyLongAttributeAttributeGetterCallback, nullptr, V8PrivateProperty::kNoCachedAccessor, static_cast<v8::PropertyAttribute>(v8::ReadOnly), V8DOMConfiguration::kOnInterface, V8DOMConfiguration::kCheckHolder, V8DOMConfiguration::kAllWorlds } -, - - { "implementsStaticStringAttribute", V8TestInterface::implementsStaticStringAttributeAttributeGetterCallback, V8TestInterface::implementsStaticStringAttributeAttributeSetterCallback, V8PrivateProperty::kNoCachedAccessor, static_cast<v8::PropertyAttribute>(v8::None), V8DOMConfiguration::kOnInterface, V8DOMConfiguration::kCheckHolder, V8DOMConfiguration::kAllWorlds } -, - - { "implementsReadonlyStringAttribute", V8TestInterface::implementsReadonlyStringAttributeAttributeGetterCallback, nullptr, V8PrivateProperty::kNoCachedAccessor, static_cast<v8::PropertyAttribute>(v8::ReadOnly), V8DOMConfiguration::kOnPrototype, V8DOMConfiguration::kCheckHolder, V8DOMConfiguration::kAllWorlds } -, - - { "implementsStringAttribute", V8TestInterface::implementsStringAttributeAttributeGetterCallback, V8TestInterface::implementsStringAttributeAttributeSetterCallback, V8PrivateProperty::kNoCachedAccessor, static_cast<v8::PropertyAttribute>(v8::None), V8DOMConfiguration::kOnPrototype, V8DOMConfiguration::kCheckHolder, V8DOMConfiguration::kAllWorlds } -, - - { "implementsNodeAttribute", V8TestInterface::implementsNodeAttributeAttributeGetterCallback, V8TestInterface::implementsNodeAttributeAttributeSetterCallback, V8PrivateProperty::kNoCachedAccessor, static_cast<v8::PropertyAttribute>(v8::None), V8DOMConfiguration::kOnPrototype, V8DOMConfiguration::kCheckHolder, V8DOMConfiguration::kAllWorlds } -, - - { "implementsEventHandlerAttribute", V8TestInterface::implementsEventHandlerAttributeAttributeGetterCallback, V8TestInterface::implementsEventHandlerAttributeAttributeSetterCallback, V8PrivateProperty::kNoCachedAccessor, static_cast<v8::PropertyAttribute>(v8::None), V8DOMConfiguration::kOnPrototype, V8DOMConfiguration::kCheckHolder, V8DOMConfiguration::kAllWorlds } -, - - { "implements3StringAttribute", V8TestInterface::implements3StringAttributeAttributeGetterCallback, V8TestInterface::implements3StringAttributeAttributeSetterCallback, V8PrivateProperty::kNoCachedAccessor, static_cast<v8::PropertyAttribute>(v8::None), V8DOMConfiguration::kOnPrototype, V8DOMConfiguration::kCheckHolder, V8DOMConfiguration::kAllWorlds } -, - - { "implements3StaticStringAttribute", V8TestInterface::implements3StaticStringAttributeAttributeGetterCallback, V8TestInterface::implements3StaticStringAttributeAttributeSetterCallback, V8PrivateProperty::kNoCachedAccessor, static_cast<v8::PropertyAttribute>(v8::None), V8DOMConfiguration::kOnInterface, V8DOMConfiguration::kCheckHolder, V8DOMConfiguration::kAllWorlds } -, - - { "partial2LongAttribute", V8TestInterface::partial2LongAttributeAttributeGetterCallback, V8TestInterface::partial2LongAttributeAttributeSetterCallback, V8PrivateProperty::kNoCachedAccessor, static_cast<v8::PropertyAttribute>(v8::None), V8DOMConfiguration::kOnPrototype, V8DOMConfiguration::kCheckHolder, V8DOMConfiguration::kAllWorlds } -, - - { "partial2StaticLongAttribute", V8TestInterface::partial2StaticLongAttributeAttributeGetterCallback, V8TestInterface::partial2StaticLongAttributeAttributeSetterCallback, V8PrivateProperty::kNoCachedAccessor, static_cast<v8::PropertyAttribute>(v8::None), V8DOMConfiguration::kOnInterface, V8DOMConfiguration::kCheckHolder, V8DOMConfiguration::kAllWorlds } -, + { "testInterfaceAttribute", V8TestInterface::testInterfaceAttributeAttributeGetterCallback, V8TestInterface::testInterfaceAttributeAttributeSetterCallback, V8PrivateProperty::kNoCachedAccessor, static_cast<v8::PropertyAttribute>(v8::None), V8DOMConfiguration::kOnPrototype, V8DOMConfiguration::kCheckHolder, V8DOMConfiguration::kAllWorlds }, + { "doubleAttribute", V8TestInterface::doubleAttributeAttributeGetterCallback, V8TestInterface::doubleAttributeAttributeSetterCallback, V8PrivateProperty::kNoCachedAccessor, static_cast<v8::PropertyAttribute>(v8::None), V8DOMConfiguration::kOnPrototype, V8DOMConfiguration::kCheckHolder, V8DOMConfiguration::kAllWorlds }, + { "floatAttribute", V8TestInterface::floatAttributeAttributeGetterCallback, V8TestInterface::floatAttributeAttributeSetterCallback, V8PrivateProperty::kNoCachedAccessor, static_cast<v8::PropertyAttribute>(v8::None), V8DOMConfiguration::kOnPrototype, V8DOMConfiguration::kCheckHolder, V8DOMConfiguration::kAllWorlds }, + { "unrestrictedDoubleAttribute", V8TestInterface::unrestrictedDoubleAttributeAttributeGetterCallback, V8TestInterface::unrestrictedDoubleAttributeAttributeSetterCallback, V8PrivateProperty::kNoCachedAccessor, static_cast<v8::PropertyAttribute>(v8::None), V8DOMConfiguration::kOnPrototype, V8DOMConfiguration::kCheckHolder, V8DOMConfiguration::kAllWorlds }, + { "unrestrictedFloatAttribute", V8TestInterface::unrestrictedFloatAttributeAttributeGetterCallback, V8TestInterface::unrestrictedFloatAttributeAttributeSetterCallback, V8PrivateProperty::kNoCachedAccessor, static_cast<v8::PropertyAttribute>(v8::None), V8DOMConfiguration::kOnPrototype, V8DOMConfiguration::kCheckHolder, V8DOMConfiguration::kAllWorlds }, + { "testEnumAttribute", V8TestInterface::testEnumAttributeAttributeGetterCallback, V8TestInterface::testEnumAttributeAttributeSetterCallback, V8PrivateProperty::kNoCachedAccessor, static_cast<v8::PropertyAttribute>(v8::None), V8DOMConfiguration::kOnPrototype, V8DOMConfiguration::kCheckHolder, V8DOMConfiguration::kAllWorlds }, + { "testEnumOrNullAttribute", V8TestInterface::testEnumOrNullAttributeAttributeGetterCallback, V8TestInterface::testEnumOrNullAttributeAttributeSetterCallback, V8PrivateProperty::kNoCachedAccessor, static_cast<v8::PropertyAttribute>(v8::None), V8DOMConfiguration::kOnPrototype, V8DOMConfiguration::kCheckHolder, V8DOMConfiguration::kAllWorlds }, + { "stringOrDoubleAttribute", V8TestInterface::stringOrDoubleAttributeAttributeGetterCallback, V8TestInterface::stringOrDoubleAttributeAttributeSetterCallback, V8PrivateProperty::kNoCachedAccessor, static_cast<v8::PropertyAttribute>(v8::None), V8DOMConfiguration::kOnPrototype, V8DOMConfiguration::kCheckHolder, V8DOMConfiguration::kAllWorlds }, + { "withExtendedAttributeStringAttribute", V8TestInterface::withExtendedAttributeStringAttributeAttributeGetterCallback, V8TestInterface::withExtendedAttributeStringAttributeAttributeSetterCallback, V8PrivateProperty::kNoCachedAccessor, static_cast<v8::PropertyAttribute>(v8::None), V8DOMConfiguration::kOnPrototype, V8DOMConfiguration::kCheckHolder, V8DOMConfiguration::kAllWorlds }, + { "uncapitalAttribute", V8TestInterface::uncapitalAttributeAttributeGetterCallback, V8TestInterface::uncapitalAttributeAttributeSetterCallback, V8PrivateProperty::kNoCachedAccessor, static_cast<v8::PropertyAttribute>(v8::None), V8DOMConfiguration::kOnPrototype, V8DOMConfiguration::kCheckHolder, V8DOMConfiguration::kAllWorlds }, + { "staticStringAttribute", V8TestInterface::staticStringAttributeAttributeGetterCallback, V8TestInterface::staticStringAttributeAttributeSetterCallback, V8PrivateProperty::kNoCachedAccessor, static_cast<v8::PropertyAttribute>(v8::None), V8DOMConfiguration::kOnInterface, V8DOMConfiguration::kCheckHolder, V8DOMConfiguration::kAllWorlds }, + { "staticReturnDOMWrapperAttribute", V8TestInterface::staticReturnDOMWrapperAttributeAttributeGetterCallback, V8TestInterface::staticReturnDOMWrapperAttributeAttributeSetterCallback, V8PrivateProperty::kNoCachedAccessor, static_cast<v8::PropertyAttribute>(v8::None), V8DOMConfiguration::kOnInterface, V8DOMConfiguration::kCheckHolder, V8DOMConfiguration::kAllWorlds }, + { "staticReadOnlyStringAttribute", V8TestInterface::staticReadOnlyStringAttributeAttributeGetterCallback, nullptr, V8PrivateProperty::kNoCachedAccessor, static_cast<v8::PropertyAttribute>(v8::ReadOnly), V8DOMConfiguration::kOnInterface, V8DOMConfiguration::kCheckHolder, V8DOMConfiguration::kAllWorlds }, + { "staticReadOnlyReturnDOMWrapperAttribute", V8TestInterface::staticReadOnlyReturnDOMWrapperAttributeAttributeGetterCallback, nullptr, V8PrivateProperty::kNoCachedAccessor, static_cast<v8::PropertyAttribute>(v8::ReadOnly), V8DOMConfiguration::kOnInterface, V8DOMConfiguration::kCheckHolder, V8DOMConfiguration::kAllWorlds }, + { "legacyInterfaceTypeCheckingAttribute", V8TestInterface::legacyInterfaceTypeCheckingAttributeAttributeGetterCallback, V8TestInterface::legacyInterfaceTypeCheckingAttributeAttributeSetterCallback, V8PrivateProperty::kNoCachedAccessor, static_cast<v8::PropertyAttribute>(v8::None), V8DOMConfiguration::kOnPrototype, V8DOMConfiguration::kCheckHolder, V8DOMConfiguration::kAllWorlds }, + { "stringNullAsEmptyAttribute", V8TestInterface::stringNullAsEmptyAttributeAttributeGetterCallback, V8TestInterface::stringNullAsEmptyAttributeAttributeSetterCallback, V8PrivateProperty::kNoCachedAccessor, static_cast<v8::PropertyAttribute>(v8::None), V8DOMConfiguration::kOnPrototype, V8DOMConfiguration::kCheckHolder, V8DOMConfiguration::kAllWorlds }, + { "usvStringOrNullAttribute", V8TestInterface::usvStringOrNullAttributeAttributeGetterCallback, V8TestInterface::usvStringOrNullAttributeAttributeSetterCallback, V8PrivateProperty::kNoCachedAccessor, static_cast<v8::PropertyAttribute>(v8::None), V8DOMConfiguration::kOnPrototype, V8DOMConfiguration::kCheckHolder, V8DOMConfiguration::kAllWorlds }, + { "alwaysExposedAttribute", V8TestInterface::alwaysExposedAttributeAttributeGetterCallback, V8TestInterface::alwaysExposedAttributeAttributeSetterCallback, V8PrivateProperty::kNoCachedAccessor, static_cast<v8::PropertyAttribute>(v8::None), V8DOMConfiguration::kOnPrototype, V8DOMConfiguration::kCheckHolder, V8DOMConfiguration::kAllWorlds }, + { "lenientThisAttribute", V8TestInterface::lenientThisAttributeAttributeGetterCallback, V8TestInterface::lenientThisAttributeAttributeSetterCallback, V8PrivateProperty::kNoCachedAccessor, static_cast<v8::PropertyAttribute>(v8::None), V8DOMConfiguration::kOnPrototype, V8DOMConfiguration::kDoNotCheckHolder, V8DOMConfiguration::kAllWorlds }, + { "implementsStaticReadOnlyLongAttribute", V8TestInterface::implementsStaticReadOnlyLongAttributeAttributeGetterCallback, nullptr, V8PrivateProperty::kNoCachedAccessor, static_cast<v8::PropertyAttribute>(v8::ReadOnly), V8DOMConfiguration::kOnInterface, V8DOMConfiguration::kCheckHolder, V8DOMConfiguration::kAllWorlds }, + { "implementsStaticStringAttribute", V8TestInterface::implementsStaticStringAttributeAttributeGetterCallback, V8TestInterface::implementsStaticStringAttributeAttributeSetterCallback, V8PrivateProperty::kNoCachedAccessor, static_cast<v8::PropertyAttribute>(v8::None), V8DOMConfiguration::kOnInterface, V8DOMConfiguration::kCheckHolder, V8DOMConfiguration::kAllWorlds }, + { "implementsReadonlyStringAttribute", V8TestInterface::implementsReadonlyStringAttributeAttributeGetterCallback, nullptr, V8PrivateProperty::kNoCachedAccessor, static_cast<v8::PropertyAttribute>(v8::ReadOnly), V8DOMConfiguration::kOnPrototype, V8DOMConfiguration::kCheckHolder, V8DOMConfiguration::kAllWorlds }, + { "implementsStringAttribute", V8TestInterface::implementsStringAttributeAttributeGetterCallback, V8TestInterface::implementsStringAttributeAttributeSetterCallback, V8PrivateProperty::kNoCachedAccessor, static_cast<v8::PropertyAttribute>(v8::None), V8DOMConfiguration::kOnPrototype, V8DOMConfiguration::kCheckHolder, V8DOMConfiguration::kAllWorlds }, + { "implementsNodeAttribute", V8TestInterface::implementsNodeAttributeAttributeGetterCallback, V8TestInterface::implementsNodeAttributeAttributeSetterCallback, V8PrivateProperty::kNoCachedAccessor, static_cast<v8::PropertyAttribute>(v8::None), V8DOMConfiguration::kOnPrototype, V8DOMConfiguration::kCheckHolder, V8DOMConfiguration::kAllWorlds }, + { "implementsEventHandlerAttribute", V8TestInterface::implementsEventHandlerAttributeAttributeGetterCallback, V8TestInterface::implementsEventHandlerAttributeAttributeSetterCallback, V8PrivateProperty::kNoCachedAccessor, static_cast<v8::PropertyAttribute>(v8::None), V8DOMConfiguration::kOnPrototype, V8DOMConfiguration::kCheckHolder, V8DOMConfiguration::kAllWorlds }, + { "implements3StringAttribute", V8TestInterface::implements3StringAttributeAttributeGetterCallback, V8TestInterface::implements3StringAttributeAttributeSetterCallback, V8PrivateProperty::kNoCachedAccessor, static_cast<v8::PropertyAttribute>(v8::None), V8DOMConfiguration::kOnPrototype, V8DOMConfiguration::kCheckHolder, V8DOMConfiguration::kAllWorlds }, + { "implements3StaticStringAttribute", V8TestInterface::implements3StaticStringAttributeAttributeGetterCallback, V8TestInterface::implements3StaticStringAttributeAttributeSetterCallback, V8PrivateProperty::kNoCachedAccessor, static_cast<v8::PropertyAttribute>(v8::None), V8DOMConfiguration::kOnInterface, V8DOMConfiguration::kCheckHolder, V8DOMConfiguration::kAllWorlds }, + { "partial2LongAttribute", V8TestInterface::partial2LongAttributeAttributeGetterCallback, V8TestInterface::partial2LongAttributeAttributeSetterCallback, V8PrivateProperty::kNoCachedAccessor, static_cast<v8::PropertyAttribute>(v8::None), V8DOMConfiguration::kOnPrototype, V8DOMConfiguration::kCheckHolder, V8DOMConfiguration::kAllWorlds }, + { "partial2StaticLongAttribute", V8TestInterface::partial2StaticLongAttributeAttributeGetterCallback, V8TestInterface::partial2StaticLongAttributeAttributeSetterCallback, V8PrivateProperty::kNoCachedAccessor, static_cast<v8::PropertyAttribute>(v8::None), V8DOMConfiguration::kOnInterface, V8DOMConfiguration::kCheckHolder, V8DOMConfiguration::kAllWorlds }, }; static const V8DOMConfiguration::MethodConfiguration V8TestInterfaceMethods[] = { @@ -3685,7 +3623,6 @@ V8DOMConfiguration::InstallConstants( isolate, interfaceTemplate, prototypeTemplate, V8TestInterfaceConstants, WTF_ARRAY_LENGTH(V8TestInterfaceConstants)); - V8DOMConfiguration::InstallLazyDataAttributes( isolate, world, instanceTemplate, prototypeTemplate, V8TestInterfaceLazyDataAttributes, WTF_ARRAY_LENGTH(V8TestInterfaceLazyDataAttributes)); @@ -3754,14 +3691,9 @@ if (RuntimeEnabledFeatures::FeatureNameEnabled()) { static const V8DOMConfiguration::AccessorConfiguration accessor_configurations[] = { - { "conditionalReadOnlyLongAttribute", V8TestInterface::conditionalReadOnlyLongAttributeAttributeGetterCallback, nullptr, V8PrivateProperty::kNoCachedAccessor, static_cast<v8::PropertyAttribute>(v8::ReadOnly), V8DOMConfiguration::kOnPrototype, V8DOMConfiguration::kCheckHolder, V8DOMConfiguration::kAllWorlds } - , - - { "staticConditionalReadOnlyLongAttribute", V8TestInterface::staticConditionalReadOnlyLongAttributeAttributeGetterCallback, nullptr, V8PrivateProperty::kNoCachedAccessor, static_cast<v8::PropertyAttribute>(v8::ReadOnly), V8DOMConfiguration::kOnInterface, V8DOMConfiguration::kCheckHolder, V8DOMConfiguration::kAllWorlds } - , - - { "conditionalLongAttribute", V8TestInterface::conditionalLongAttributeAttributeGetterCallback, V8TestInterface::conditionalLongAttributeAttributeSetterCallback, V8PrivateProperty::kNoCachedAccessor, static_cast<v8::PropertyAttribute>(v8::None), V8DOMConfiguration::kOnPrototype, V8DOMConfiguration::kCheckHolder, V8DOMConfiguration::kAllWorlds } - , + { "conditionalReadOnlyLongAttribute", V8TestInterface::conditionalReadOnlyLongAttributeAttributeGetterCallback, nullptr, V8PrivateProperty::kNoCachedAccessor, static_cast<v8::PropertyAttribute>(v8::ReadOnly), V8DOMConfiguration::kOnPrototype, V8DOMConfiguration::kCheckHolder, V8DOMConfiguration::kAllWorlds }, + { "staticConditionalReadOnlyLongAttribute", V8TestInterface::staticConditionalReadOnlyLongAttributeAttributeGetterCallback, nullptr, V8PrivateProperty::kNoCachedAccessor, static_cast<v8::PropertyAttribute>(v8::ReadOnly), V8DOMConfiguration::kOnInterface, V8DOMConfiguration::kCheckHolder, V8DOMConfiguration::kAllWorlds }, + { "conditionalLongAttribute", V8TestInterface::conditionalLongAttributeAttributeGetterCallback, V8TestInterface::conditionalLongAttributeAttributeSetterCallback, V8PrivateProperty::kNoCachedAccessor, static_cast<v8::PropertyAttribute>(v8::None), V8DOMConfiguration::kOnPrototype, V8DOMConfiguration::kCheckHolder, V8DOMConfiguration::kAllWorlds }, }; V8DOMConfiguration::InstallAccessors( isolate, world, instance_template, prototype_template, interface_template, @@ -3770,11 +3702,8 @@ } if (RuntimeEnabledFeatures::Implements2FeatureNameEnabled()) { static const V8DOMConfiguration::AccessorConfiguration accessor_configurations[] = { - { "implements2StaticStringAttribute", V8TestInterface::implements2StaticStringAttributeAttributeGetterCallback, V8TestInterface::implements2StaticStringAttributeAttributeSetterCallback, V8PrivateProperty::kNoCachedAccessor, static_cast<v8::PropertyAttribute>(v8::None), V8DOMConfiguration::kOnInterface, V8DOMConfiguration::kCheckHolder, V8DOMConfiguration::kAllWorlds } - , - - { "implements2StringAttribute", V8TestInterface::implements2StringAttributeAttributeGetterCallback, V8TestInterface::implements2StringAttributeAttributeSetterCallback, V8PrivateProperty::kNoCachedAccessor, static_cast<v8::PropertyAttribute>(v8::None), V8DOMConfiguration::kOnPrototype, V8DOMConfiguration::kCheckHolder, V8DOMConfiguration::kAllWorlds } - , + { "implements2StaticStringAttribute", V8TestInterface::implements2StaticStringAttributeAttributeGetterCallback, V8TestInterface::implements2StaticStringAttributeAttributeSetterCallback, V8PrivateProperty::kNoCachedAccessor, static_cast<v8::PropertyAttribute>(v8::None), V8DOMConfiguration::kOnInterface, V8DOMConfiguration::kCheckHolder, V8DOMConfiguration::kAllWorlds }, + { "implements2StringAttribute", V8TestInterface::implements2StringAttributeAttributeGetterCallback, V8TestInterface::implements2StringAttributeAttributeSetterCallback, V8PrivateProperty::kNoCachedAccessor, static_cast<v8::PropertyAttribute>(v8::None), V8DOMConfiguration::kOnPrototype, V8DOMConfiguration::kCheckHolder, V8DOMConfiguration::kAllWorlds }, }; V8DOMConfiguration::InstallAccessors( isolate, world, instance_template, prototype_template, interface_template, @@ -3783,8 +3712,7 @@ } if (RuntimeEnabledFeatures::ImplementsFeatureNameEnabled()) { static const V8DOMConfiguration::AccessorConfiguration accessor_configurations[] = { - { "implementsRuntimeEnabledNodeAttribute", V8TestInterface::implementsRuntimeEnabledNodeAttributeAttributeGetterCallback, V8TestInterface::implementsRuntimeEnabledNodeAttributeAttributeSetterCallback, V8PrivateProperty::kNoCachedAccessor, static_cast<v8::PropertyAttribute>(v8::None), V8DOMConfiguration::kOnPrototype, V8DOMConfiguration::kCheckHolder, V8DOMConfiguration::kAllWorlds } - , + { "implementsRuntimeEnabledNodeAttribute", V8TestInterface::implementsRuntimeEnabledNodeAttributeAttributeGetterCallback, V8TestInterface::implementsRuntimeEnabledNodeAttributeAttributeSetterCallback, V8PrivateProperty::kNoCachedAccessor, static_cast<v8::PropertyAttribute>(v8::None), V8DOMConfiguration::kOnPrototype, V8DOMConfiguration::kCheckHolder, V8DOMConfiguration::kAllWorlds }, }; V8DOMConfiguration::InstallAccessors( isolate, world, instance_template, prototype_template, interface_template, @@ -3793,17 +3721,10 @@ } if (RuntimeEnabledFeatures::PartialFeatureNameEnabled()) { static const V8DOMConfiguration::AccessorConfiguration accessor_configurations[] = { - { "partialCallWithExecutionContextLongAttribute", V8TestInterface::partialCallWithExecutionContextLongAttributeAttributeGetterCallback, V8TestInterface::partialCallWithExecutionContextLongAttributeAttributeSetterCallback, V8PrivateProperty::kNoCachedAccessor, static_cast<v8::PropertyAttribute>(v8::None), V8DOMConfiguration::kOnPrototype, V8DOMConfiguration::kCheckHolder, V8DOMConfiguration::kAllWorlds } - , - - { "partialLongAttribute", V8TestInterface::partialLongAttributeAttributeGetterCallback, V8TestInterface::partialLongAttributeAttributeSetterCallback, V8PrivateProperty::kNoCachedAccessor, static_cast<v8::PropertyAttribute>(v8::None), V8DOMConfiguration::kOnPrototype, V8DOMConfiguration::kCheckHolder, V8DOMConfiguration::kAllWorlds } - , - - { "partialPartialEnumTypeAttribute", V8TestInterface::partialPartialEnumTypeAttributeAttributeGetterCallback, V8TestInterface::partialPartialEnumTypeAttributeAttributeSetterCallback, V8PrivateProperty::kNoCachedAccessor, static_cast<v8::PropertyAttribute>(v8::None), V8DOMConfiguration::kOnPrototype, V8DOMConfiguration::kCheckHolder, V8DOMConfiguration::kAllWorlds } - , - - { "partialStaticLongAttribute", V8TestInterface::partialStaticLongAttributeAttributeGetterCallback, V8TestInterface::partialStaticLongAttributeAttributeSetterCallback, V8PrivateProperty::kNoCachedAccessor, static_cast<v8::PropertyAttribute>(v8::None), V8DOMConfiguration::kOnInterface, V8DOMConfiguration::kCheckHolder, V8DOMConfiguration::kAllWorlds } - , + { "partialCallWithExecutionContextLongAttribute", V8TestInterface::partialCallWithExecutionContextLongAttributeAttributeGetterCallback, V8TestInterface::partialCallWithExecutionContextLongAttributeAttributeSetterCallback, V8PrivateProperty::kNoCachedAccessor, static_cast<v8::PropertyAttribute>(v8::None), V8DOMConfiguration::kOnPrototype, V8DOMConfiguration::kCheckHolder, V8DOMConfiguration::kAllWorlds }, + { "partialLongAttribute", V8TestInterface::partialLongAttributeAttributeGetterCallback, V8TestInterface::partialLongAttributeAttributeSetterCallback, V8PrivateProperty::kNoCachedAccessor, static_cast<v8::PropertyAttribute>(v8::None), V8DOMConfiguration::kOnPrototype, V8DOMConfiguration::kCheckHolder, V8DOMConfiguration::kAllWorlds }, + { "partialPartialEnumTypeAttribute", V8TestInterface::partialPartialEnumTypeAttributeAttributeGetterCallback, V8TestInterface::partialPartialEnumTypeAttributeAttributeSetterCallback, V8PrivateProperty::kNoCachedAccessor, static_cast<v8::PropertyAttribute>(v8::None), V8DOMConfiguration::kOnPrototype, V8DOMConfiguration::kCheckHolder, V8DOMConfiguration::kAllWorlds }, + { "partialStaticLongAttribute", V8TestInterface::partialStaticLongAttributeAttributeGetterCallback, V8TestInterface::partialStaticLongAttributeAttributeSetterCallback, V8PrivateProperty::kNoCachedAccessor, static_cast<v8::PropertyAttribute>(v8::None), V8DOMConfiguration::kOnInterface, V8DOMConfiguration::kCheckHolder, V8DOMConfiguration::kAllWorlds }, }; V8DOMConfiguration::InstallAccessors( isolate, world, instance_template, prototype_template, interface_template, @@ -3902,14 +3823,9 @@ if (!prototypeObject.IsEmpty() || !interfaceObject.IsEmpty()) { if (isSecureContext) { static const V8DOMConfiguration::AccessorConfiguration accessor_configurations[] = { - { "partial2SecureContextAttribute", V8TestInterface::partial2SecureContextAttributeAttributeGetterCallback, V8TestInterface::partial2SecureContextAttributeAttributeSetterCallback, V8PrivateProperty::kNoCachedAccessor, static_cast<v8::PropertyAttribute>(v8::None), V8DOMConfiguration::kOnPrototype, V8DOMConfiguration::kCheckHolder, V8DOMConfiguration::kAllWorlds } - , - - { "partialSecureContextAttribute", V8TestInterface::partialSecureContextAttributeAttributeGetterCallback, V8TestInterface::partialSecureContextAttributeAttributeSetterCallback, V8PrivateProperty::kNoCachedAccessor, static_cast<v8::PropertyAttribute>(v8::None), V8DOMConfiguration::kOnPrototype, V8DOMConfiguration::kCheckHolder, V8DOMConfiguration::kAllWorlds } - , - - { "secureContextAttribute", V8TestInterface::secureContextAttributeAttributeGetterCallback, V8TestInterface::secureContextAttributeAttributeSetterCallback, V8PrivateProperty::kNoCachedAccessor, static_cast<v8::PropertyAttribute>(v8::None), V8DOMConfiguration::kOnPrototype, V8DOMConfiguration::kCheckHolder, V8DOMConfiguration::kAllWorlds } - , + { "partial2SecureContextAttribute", V8TestInterface::partial2SecureContextAttributeAttributeGetterCallback, V8TestInterface::partial2SecureContextAttributeAttributeSetterCallback, V8PrivateProperty::kNoCachedAccessor, static_cast<v8::PropertyAttribute>(v8::None), V8DOMConfiguration::kOnPrototype, V8DOMConfiguration::kCheckHolder, V8DOMConfiguration::kAllWorlds }, + { "partialSecureContextAttribute", V8TestInterface::partialSecureContextAttributeAttributeGetterCallback, V8TestInterface::partialSecureContextAttributeAttributeSetterCallback, V8PrivateProperty::kNoCachedAccessor, static_cast<v8::PropertyAttribute>(v8::None), V8DOMConfiguration::kOnPrototype, V8DOMConfiguration::kCheckHolder, V8DOMConfiguration::kAllWorlds }, + { "secureContextAttribute", V8TestInterface::secureContextAttributeAttributeGetterCallback, V8TestInterface::secureContextAttributeAttributeSetterCallback, V8PrivateProperty::kNoCachedAccessor, static_cast<v8::PropertyAttribute>(v8::None), V8DOMConfiguration::kOnPrototype, V8DOMConfiguration::kCheckHolder, V8DOMConfiguration::kAllWorlds }, }; V8DOMConfiguration::InstallAccessors( isolate, world, instanceObject, prototypeObject, interfaceObject, @@ -3917,8 +3833,7 @@ WTF_ARRAY_LENGTH(accessor_configurations)); if (RuntimeEnabledFeatures::PartialFeatureNameEnabled()) { static const V8DOMConfiguration::AccessorConfiguration accessor_configurations[] = { - { "partialSecureContextLongAttribute", V8TestInterface::partialSecureContextLongAttributeAttributeGetterCallback, V8TestInterface::partialSecureContextLongAttributeAttributeSetterCallback, V8PrivateProperty::kNoCachedAccessor, static_cast<v8::PropertyAttribute>(v8::None), V8DOMConfiguration::kOnPrototype, V8DOMConfiguration::kCheckHolder, V8DOMConfiguration::kAllWorlds } - , + { "partialSecureContextLongAttribute", V8TestInterface::partialSecureContextLongAttributeAttributeGetterCallback, V8TestInterface::partialSecureContextLongAttributeAttributeSetterCallback, V8PrivateProperty::kNoCachedAccessor, static_cast<v8::PropertyAttribute>(v8::None), V8DOMConfiguration::kOnPrototype, V8DOMConfiguration::kCheckHolder, V8DOMConfiguration::kAllWorlds }, }; V8DOMConfiguration::InstallAccessors( isolate, world, instanceObject, prototypeObject, interfaceObject, @@ -3927,11 +3842,8 @@ } if (RuntimeEnabledFeatures::SecureFeatureEnabled()) { static const V8DOMConfiguration::AccessorConfiguration accessor_configurations[] = { - { "partialSecureContextRuntimeEnabledAttribute", V8TestInterface::partialSecureContextRuntimeEnabledAttributeAttributeGetterCallback, V8TestInterface::partialSecureContextRuntimeEnabledAttributeAttributeSetterCallback, V8PrivateProperty::kNoCachedAccessor, static_cast<v8::PropertyAttribute>(v8::None), V8DOMConfiguration::kOnPrototype, V8DOMConfiguration::kCheckHolder, V8DOMConfiguration::kAllWorlds } - , - - { "secureContextRuntimeEnabledAttribute", V8TestInterface::secureContextRuntimeEnabledAttributeAttributeGetterCallback, V8TestInterface::secureContextRuntimeEnabledAttributeAttributeSetterCallback, V8PrivateProperty::kNoCachedAccessor, static_cast<v8::PropertyAttribute>(v8::None), V8DOMConfiguration::kOnPrototype, V8DOMConfiguration::kCheckHolder, V8DOMConfiguration::kAllWorlds } - , + { "partialSecureContextRuntimeEnabledAttribute", V8TestInterface::partialSecureContextRuntimeEnabledAttributeAttributeGetterCallback, V8TestInterface::partialSecureContextRuntimeEnabledAttributeAttributeSetterCallback, V8PrivateProperty::kNoCachedAccessor, static_cast<v8::PropertyAttribute>(v8::None), V8DOMConfiguration::kOnPrototype, V8DOMConfiguration::kCheckHolder, V8DOMConfiguration::kAllWorlds }, + { "secureContextRuntimeEnabledAttribute", V8TestInterface::secureContextRuntimeEnabledAttributeAttributeGetterCallback, V8TestInterface::secureContextRuntimeEnabledAttributeAttributeSetterCallback, V8PrivateProperty::kNoCachedAccessor, static_cast<v8::PropertyAttribute>(v8::None), V8DOMConfiguration::kOnPrototype, V8DOMConfiguration::kCheckHolder, V8DOMConfiguration::kAllWorlds }, }; V8DOMConfiguration::InstallAccessors( isolate, world, instanceObject, prototypeObject, interfaceObject, @@ -3941,8 +3853,7 @@ } if (executionContext && (executionContext->IsDocument())) { static const V8DOMConfiguration::AccessorConfiguration accessor_configurations[] = { - { "windowExposedAttribute", V8TestInterface::windowExposedAttributeAttributeGetterCallback, V8TestInterface::windowExposedAttributeAttributeSetterCallback, V8PrivateProperty::kNoCachedAccessor, static_cast<v8::PropertyAttribute>(v8::None), V8DOMConfiguration::kOnPrototype, V8DOMConfiguration::kCheckHolder, V8DOMConfiguration::kAllWorlds } - , + { "windowExposedAttribute", V8TestInterface::windowExposedAttributeAttributeGetterCallback, V8TestInterface::windowExposedAttributeAttributeSetterCallback, V8PrivateProperty::kNoCachedAccessor, static_cast<v8::PropertyAttribute>(v8::None), V8DOMConfiguration::kOnPrototype, V8DOMConfiguration::kCheckHolder, V8DOMConfiguration::kAllWorlds }, }; V8DOMConfiguration::InstallAccessors( isolate, world, instanceObject, prototypeObject, interfaceObject, @@ -3950,11 +3861,8 @@ WTF_ARRAY_LENGTH(accessor_configurations)); if (isSecureContext) { static const V8DOMConfiguration::AccessorConfiguration accessor_configurations[] = { - { "partialSecureContextWindowExposedAttribute", V8TestInterface::partialSecureContextWindowExposedAttributeAttributeGetterCallback, V8TestInterface::partialSecureContextWindowExposedAttributeAttributeSetterCallback, V8PrivateProperty::kNoCachedAccessor, static_cast<v8::PropertyAttribute>(v8::None), V8DOMConfiguration::kOnPrototype, V8DOMConfiguration::kCheckHolder, V8DOMConfiguration::kAllWorlds } - , - - { "secureContextWindowExposedAttribute", V8TestInterface::secureContextWindowExposedAttributeAttributeGetterCallback, V8TestInterface::secureContextWindowExposedAttributeAttributeSetterCallback, V8PrivateProperty::kNoCachedAccessor, static_cast<v8::PropertyAttribute>(v8::None), V8DOMConfiguration::kOnPrototype, V8DOMConfiguration::kCheckHolder, V8DOMConfiguration::kAllWorlds } - , + { "partialSecureContextWindowExposedAttribute", V8TestInterface::partialSecureContextWindowExposedAttributeAttributeGetterCallback, V8TestInterface::partialSecureContextWindowExposedAttributeAttributeSetterCallback, V8PrivateProperty::kNoCachedAccessor, static_cast<v8::PropertyAttribute>(v8::None), V8DOMConfiguration::kOnPrototype, V8DOMConfiguration::kCheckHolder, V8DOMConfiguration::kAllWorlds }, + { "secureContextWindowExposedAttribute", V8TestInterface::secureContextWindowExposedAttributeAttributeGetterCallback, V8TestInterface::secureContextWindowExposedAttributeAttributeSetterCallback, V8PrivateProperty::kNoCachedAccessor, static_cast<v8::PropertyAttribute>(v8::None), V8DOMConfiguration::kOnPrototype, V8DOMConfiguration::kCheckHolder, V8DOMConfiguration::kAllWorlds }, }; V8DOMConfiguration::InstallAccessors( isolate, world, instanceObject, prototypeObject, interfaceObject, @@ -3962,11 +3870,8 @@ WTF_ARRAY_LENGTH(accessor_configurations)); if (RuntimeEnabledFeatures::SecureFeatureEnabled()) { static const V8DOMConfiguration::AccessorConfiguration accessor_configurations[] = { - { "partialSecureContextWindowExposedRuntimeEnabledAttribute", V8TestInterface::partialSecureContextWindowExposedRuntimeEnabledAttributeAttributeGetterCallback, V8TestInterface::partialSecureContextWindowExposedRuntimeEnabledAttributeAttributeSetterCallback, V8PrivateProperty::kNoCachedAccessor, static_cast<v8::PropertyAttribute>(v8::None), V8DOMConfiguration::kOnPrototype, V8DOMConfiguration::kCheckHolder, V8DOMConfiguration::kAllWorlds } - , - - { "secureContextWindowExposedRuntimeEnabledAttribute", V8TestInterface::secureContextWindowExposedRuntimeEnabledAttributeAttributeGetterCallback, V8TestInterface::secureContextWindowExposedRuntimeEnabledAttributeAttributeSetterCallback, V8PrivateProperty::kNoCachedAccessor, static_cast<v8::PropertyAttribute>(v8::None), V8DOMConfiguration::kOnPrototype, V8DOMConfiguration::kCheckHolder, V8DOMConfiguration::kAllWorlds } - , + { "partialSecureContextWindowExposedRuntimeEnabledAttribute", V8TestInterface::partialSecureContextWindowExposedRuntimeEnabledAttributeAttributeGetterCallback, V8TestInterface::partialSecureContextWindowExposedRuntimeEnabledAttributeAttributeSetterCallback, V8PrivateProperty::kNoCachedAccessor, static_cast<v8::PropertyAttribute>(v8::None), V8DOMConfiguration::kOnPrototype, V8DOMConfiguration::kCheckHolder, V8DOMConfiguration::kAllWorlds }, + { "secureContextWindowExposedRuntimeEnabledAttribute", V8TestInterface::secureContextWindowExposedRuntimeEnabledAttributeAttributeGetterCallback, V8TestInterface::secureContextWindowExposedRuntimeEnabledAttributeAttributeSetterCallback, V8PrivateProperty::kNoCachedAccessor, static_cast<v8::PropertyAttribute>(v8::None), V8DOMConfiguration::kOnPrototype, V8DOMConfiguration::kCheckHolder, V8DOMConfiguration::kAllWorlds }, }; V8DOMConfiguration::InstallAccessors( isolate, world, instanceObject, prototypeObject, interfaceObject, @@ -3977,8 +3882,7 @@ } if (executionContext && (executionContext->IsWorkerGlobalScope())) { static const V8DOMConfiguration::AccessorConfiguration accessor_configurations[] = { - { "workerExposedAttribute", V8TestInterface::workerExposedAttributeAttributeGetterCallback, V8TestInterface::workerExposedAttributeAttributeSetterCallback, V8PrivateProperty::kNoCachedAccessor, static_cast<v8::PropertyAttribute>(v8::None), V8DOMConfiguration::kOnPrototype, V8DOMConfiguration::kCheckHolder, V8DOMConfiguration::kAllWorlds } - , + { "workerExposedAttribute", V8TestInterface::workerExposedAttributeAttributeGetterCallback, V8TestInterface::workerExposedAttributeAttributeSetterCallback, V8PrivateProperty::kNoCachedAccessor, static_cast<v8::PropertyAttribute>(v8::None), V8DOMConfiguration::kOnPrototype, V8DOMConfiguration::kCheckHolder, V8DOMConfiguration::kAllWorlds }, }; V8DOMConfiguration::InstallAccessors( isolate, world, instanceObject, prototypeObject, interfaceObject, @@ -3986,11 +3890,8 @@ WTF_ARRAY_LENGTH(accessor_configurations)); if (isSecureContext) { static const V8DOMConfiguration::AccessorConfiguration accessor_configurations[] = { - { "partialSecureContextWorkerExposedAttribute", V8TestInterface::partialSecureContextWorkerExposedAttributeAttributeGetterCallback, V8TestInterface::partialSecureContextWorkerExposedAttributeAttributeSetterCallback, V8PrivateProperty::kNoCachedAccessor, static_cast<v8::PropertyAttribute>(v8::None), V8DOMConfiguration::kOnPrototype, V8DOMConfiguration::kCheckHolder, V8DOMConfiguration::kAllWorlds } - , - - { "secureContextWorkerExposedAttribute", V8TestInterface::secureContextWorkerExposedAttributeAttributeGetterCallback, V8TestInterface::secureContextWorkerExposedAttributeAttributeSetterCallback, V8PrivateProperty::kNoCachedAccessor, static_cast<v8::PropertyAttribute>(v8::None), V8DOMConfiguration::kOnPrototype, V8DOMConfiguration::kCheckHolder, V8DOMConfiguration::kAllWorlds } - , + { "partialSecureContextWorkerExposedAttribute", V8TestInterface::partialSecureContextWorkerExposedAttributeAttributeGetterCallback, V8TestInterface::partialSecureContextWorkerExposedAttributeAttributeSetterCallback, V8PrivateProperty::kNoCachedAccessor, static_cast<v8::PropertyAttribute>(v8::None), V8DOMConfiguration::kOnPrototype, V8DOMConfiguration::kCheckHolder, V8DOMConfiguration::kAllWorlds }, + { "secureContextWorkerExposedAttribute", V8TestInterface::secureContextWorkerExposedAttributeAttributeGetterCallback, V8TestInterface::secureContextWorkerExposedAttributeAttributeSetterCallback, V8PrivateProperty::kNoCachedAccessor, static_cast<v8::PropertyAttribute>(v8::None), V8DOMConfiguration::kOnPrototype, V8DOMConfiguration::kCheckHolder, V8DOMConfiguration::kAllWorlds }, }; V8DOMConfiguration::InstallAccessors( isolate, world, instanceObject, prototypeObject, interfaceObject, @@ -3998,11 +3899,8 @@ WTF_ARRAY_LENGTH(accessor_configurations)); if (RuntimeEnabledFeatures::SecureFeatureEnabled()) { static const V8DOMConfiguration::AccessorConfiguration accessor_configurations[] = { - { "partialSecureContextWorkerExposedRuntimeEnabledAttribute", V8TestInterface::partialSecureContextWorkerExposedRuntimeEnabledAttributeAttributeGetterCallback, V8TestInterface::partialSecureContextWorkerExposedRuntimeEnabledAttributeAttributeSetterCallback, V8PrivateProperty::kNoCachedAccessor, static_cast<v8::PropertyAttribute>(v8::None), V8DOMConfiguration::kOnPrototype, V8DOMConfiguration::kCheckHolder, V8DOMConfiguration::kAllWorlds } - , - - { "secureContextWorkerExposedRuntimeEnabledAttribute", V8TestInterface::secureContextWorkerExposedRuntimeEnabledAttributeAttributeGetterCallback, V8TestInterface::secureContextWorkerExposedRuntimeEnabledAttributeAttributeSetterCallback, V8PrivateProperty::kNoCachedAccessor, static_cast<v8::PropertyAttribute>(v8::None), V8DOMConfiguration::kOnPrototype, V8DOMConfiguration::kCheckHolder, V8DOMConfiguration::kAllWorlds } - , + { "partialSecureContextWorkerExposedRuntimeEnabledAttribute", V8TestInterface::partialSecureContextWorkerExposedRuntimeEnabledAttributeAttributeGetterCallback, V8TestInterface::partialSecureContextWorkerExposedRuntimeEnabledAttributeAttributeSetterCallback, V8PrivateProperty::kNoCachedAccessor, static_cast<v8::PropertyAttribute>(v8::None), V8DOMConfiguration::kOnPrototype, V8DOMConfiguration::kCheckHolder, V8DOMConfiguration::kAllWorlds }, + { "secureContextWorkerExposedRuntimeEnabledAttribute", V8TestInterface::secureContextWorkerExposedRuntimeEnabledAttributeAttributeGetterCallback, V8TestInterface::secureContextWorkerExposedRuntimeEnabledAttributeAttributeSetterCallback, V8PrivateProperty::kNoCachedAccessor, static_cast<v8::PropertyAttribute>(v8::None), V8DOMConfiguration::kOnPrototype, V8DOMConfiguration::kCheckHolder, V8DOMConfiguration::kAllWorlds }, }; V8DOMConfiguration::InstallAccessors( isolate, world, instanceObject, prototypeObject, interfaceObject, @@ -4011,7 +3909,6 @@ } } } - if (executionContext && (executionContext->IsWorkerGlobalScope())) { const V8DOMConfiguration::MethodConfiguration workerExposedMethodMethodConfiguration[] = { {"workerExposedMethod", V8TestInterface::workerExposedMethodMethodCallback, 0, v8::None, V8DOMConfiguration::kOnPrototype, V8DOMConfiguration::kCheckHolder, V8DOMConfiguration::kDoNotCheckAccess, V8DOMConfiguration::kAllWorlds}
diff --git a/third_party/WebKit/Source/bindings/tests/results/core/V8TestInterface2.cpp b/third_party/WebKit/Source/bindings/tests/results/core/V8TestInterface2.cpp index da4ef0a..3dabf7b 100644 --- a/third_party/WebKit/Source/bindings/tests/results/core/V8TestInterface2.cpp +++ b/third_party/WebKit/Source/bindings/tests/results/core/V8TestInterface2.cpp
@@ -653,8 +653,7 @@ } static const V8DOMConfiguration::AccessorConfiguration V8TestInterface2Accessors[] = { - { "size", V8TestInterface2::sizeAttributeGetterCallback, nullptr, V8PrivateProperty::kNoCachedAccessor, static_cast<v8::PropertyAttribute>(v8::DontEnum | v8::ReadOnly), V8DOMConfiguration::kOnPrototype, V8DOMConfiguration::kCheckHolder, V8DOMConfiguration::kAllWorlds } -, + { "size", V8TestInterface2::sizeAttributeGetterCallback, nullptr, V8PrivateProperty::kNoCachedAccessor, static_cast<v8::PropertyAttribute>(v8::DontEnum | v8::ReadOnly), V8DOMConfiguration::kOnPrototype, V8DOMConfiguration::kCheckHolder, V8DOMConfiguration::kAllWorlds }, }; static const V8DOMConfiguration::MethodConfiguration V8TestInterface2Methods[] = { @@ -706,7 +705,6 @@ // Register IDL constants, attributes and operations. static_assert(1 == TestInterface2::kConstValue1, "the value of TestInterface2_kConstValue1 does not match with implementation"); - V8DOMConfiguration::InstallAccessors( isolate, world, instanceTemplate, prototypeTemplate, interfaceTemplate, signature, V8TestInterface2Accessors, WTF_ARRAY_LENGTH(V8TestInterface2Accessors));
diff --git a/third_party/WebKit/Source/bindings/tests/results/core/V8TestInterface3.cpp b/third_party/WebKit/Source/bindings/tests/results/core/V8TestInterface3.cpp index 87315362..f0ac764f 100644 --- a/third_party/WebKit/Source/bindings/tests/results/core/V8TestInterface3.cpp +++ b/third_party/WebKit/Source/bindings/tests/results/core/V8TestInterface3.cpp
@@ -236,11 +236,8 @@ } static const V8DOMConfiguration::AccessorConfiguration V8TestInterface3Accessors[] = { - { "length", V8TestInterface3::lengthAttributeGetterCallback, nullptr, V8PrivateProperty::kNoCachedAccessor, static_cast<v8::PropertyAttribute>(v8::ReadOnly), V8DOMConfiguration::kOnPrototype, V8DOMConfiguration::kCheckHolder, V8DOMConfiguration::kAllWorlds } -, - - { "readonlyStringifierAttribute", V8TestInterface3::readonlyStringifierAttributeAttributeGetterCallback, nullptr, V8PrivateProperty::kNoCachedAccessor, static_cast<v8::PropertyAttribute>(v8::ReadOnly), V8DOMConfiguration::kOnPrototype, V8DOMConfiguration::kCheckHolder, V8DOMConfiguration::kAllWorlds } -, + { "length", V8TestInterface3::lengthAttributeGetterCallback, nullptr, V8PrivateProperty::kNoCachedAccessor, static_cast<v8::PropertyAttribute>(v8::ReadOnly), V8DOMConfiguration::kOnPrototype, V8DOMConfiguration::kCheckHolder, V8DOMConfiguration::kAllWorlds }, + { "readonlyStringifierAttribute", V8TestInterface3::readonlyStringifierAttributeAttributeGetterCallback, nullptr, V8PrivateProperty::kNoCachedAccessor, static_cast<v8::PropertyAttribute>(v8::ReadOnly), V8DOMConfiguration::kOnPrototype, V8DOMConfiguration::kCheckHolder, V8DOMConfiguration::kAllWorlds }, }; static const V8DOMConfiguration::MethodConfiguration V8TestInterface3Methods[] = {
diff --git a/third_party/WebKit/Source/bindings/tests/results/core/V8TestInterfaceCheckSecurity.cpp b/third_party/WebKit/Source/bindings/tests/results/core/V8TestInterfaceCheckSecurity.cpp index 28b1433..7e3e407 100644 --- a/third_party/WebKit/Source/bindings/tests/results/core/V8TestInterfaceCheckSecurity.cpp +++ b/third_party/WebKit/Source/bindings/tests/results/core/V8TestInterfaceCheckSecurity.cpp
@@ -545,28 +545,18 @@ #pragma clang diagnostic ignored "-Wglobal-constructors" #endif static const V8DOMConfiguration::AttributeConfiguration V8TestInterfaceCheckSecurityAttributes[] = { - { "doNotCheckSecurityLongAttribute", V8TestInterfaceCheckSecurity::doNotCheckSecurityLongAttributeAttributeGetterCallback, V8TestInterfaceCheckSecurity::doNotCheckSecurityLongAttributeAttributeSetterCallback, static_cast<v8::PropertyAttribute>(v8::None), V8DOMConfiguration::kOnInstance, V8DOMConfiguration::kCheckHolder, V8DOMConfiguration::kAllWorlds } -, - - { "doNotCheckSecurityReadonlyLongAttribute", V8TestInterfaceCheckSecurity::doNotCheckSecurityReadonlyLongAttributeAttributeGetterCallback, nullptr, static_cast<v8::PropertyAttribute>(v8::ReadOnly), V8DOMConfiguration::kOnInstance, V8DOMConfiguration::kCheckHolder, V8DOMConfiguration::kAllWorlds } -, - - { "doNotCheckSecurityOnSetterLongAttribute", V8TestInterfaceCheckSecurity::doNotCheckSecurityOnSetterLongAttributeAttributeGetterCallback, V8TestInterfaceCheckSecurity::doNotCheckSecurityOnSetterLongAttributeAttributeSetterCallback, static_cast<v8::PropertyAttribute>(v8::None), V8DOMConfiguration::kOnInstance, V8DOMConfiguration::kCheckHolder, V8DOMConfiguration::kAllWorlds } -, - - { "doNotCheckSecurityReplaceableReadonlyLongAttribute", V8TestInterfaceCheckSecurity::doNotCheckSecurityReplaceableReadonlyLongAttributeAttributeGetterCallback, nullptr, static_cast<v8::PropertyAttribute>(v8::None), V8DOMConfiguration::kOnInstance, V8DOMConfiguration::kCheckHolder, V8DOMConfiguration::kAllWorlds } -, + { "doNotCheckSecurityLongAttribute", V8TestInterfaceCheckSecurity::doNotCheckSecurityLongAttributeAttributeGetterCallback, V8TestInterfaceCheckSecurity::doNotCheckSecurityLongAttributeAttributeSetterCallback, static_cast<v8::PropertyAttribute>(v8::None), V8DOMConfiguration::kOnInstance, V8DOMConfiguration::kCheckHolder, V8DOMConfiguration::kAllWorlds }, + { "doNotCheckSecurityReadonlyLongAttribute", V8TestInterfaceCheckSecurity::doNotCheckSecurityReadonlyLongAttributeAttributeGetterCallback, nullptr, static_cast<v8::PropertyAttribute>(v8::ReadOnly), V8DOMConfiguration::kOnInstance, V8DOMConfiguration::kCheckHolder, V8DOMConfiguration::kAllWorlds }, + { "doNotCheckSecurityOnSetterLongAttribute", V8TestInterfaceCheckSecurity::doNotCheckSecurityOnSetterLongAttributeAttributeGetterCallback, V8TestInterfaceCheckSecurity::doNotCheckSecurityOnSetterLongAttributeAttributeSetterCallback, static_cast<v8::PropertyAttribute>(v8::None), V8DOMConfiguration::kOnInstance, V8DOMConfiguration::kCheckHolder, V8DOMConfiguration::kAllWorlds }, + { "doNotCheckSecurityReplaceableReadonlyLongAttribute", V8TestInterfaceCheckSecurity::doNotCheckSecurityReplaceableReadonlyLongAttributeAttributeGetterCallback, nullptr, static_cast<v8::PropertyAttribute>(v8::None), V8DOMConfiguration::kOnInstance, V8DOMConfiguration::kCheckHolder, V8DOMConfiguration::kAllWorlds }, }; #if defined(COMPONENT_BUILD) && defined(WIN32) && defined(__clang__) #pragma clang diagnostic pop #endif static const V8DOMConfiguration::AccessorConfiguration V8TestInterfaceCheckSecurityAccessors[] = { - { "readonlyLongAttribute", V8TestInterfaceCheckSecurity::readonlyLongAttributeAttributeGetterCallback, nullptr, V8PrivateProperty::kNoCachedAccessor, static_cast<v8::PropertyAttribute>(v8::ReadOnly), V8DOMConfiguration::kOnInstance, V8DOMConfiguration::kCheckHolder, V8DOMConfiguration::kAllWorlds } -, - - { "longAttribute", V8TestInterfaceCheckSecurity::longAttributeAttributeGetterCallback, V8TestInterfaceCheckSecurity::longAttributeAttributeSetterCallback, V8PrivateProperty::kNoCachedAccessor, static_cast<v8::PropertyAttribute>(v8::None), V8DOMConfiguration::kOnInstance, V8DOMConfiguration::kCheckHolder, V8DOMConfiguration::kAllWorlds } -, + { "readonlyLongAttribute", V8TestInterfaceCheckSecurity::readonlyLongAttributeAttributeGetterCallback, nullptr, V8PrivateProperty::kNoCachedAccessor, static_cast<v8::PropertyAttribute>(v8::ReadOnly), V8DOMConfiguration::kOnInstance, V8DOMConfiguration::kCheckHolder, V8DOMConfiguration::kAllWorlds }, + { "longAttribute", V8TestInterfaceCheckSecurity::longAttributeAttributeGetterCallback, V8TestInterfaceCheckSecurity::longAttributeAttributeSetterCallback, V8PrivateProperty::kNoCachedAccessor, static_cast<v8::PropertyAttribute>(v8::None), V8DOMConfiguration::kOnInstance, V8DOMConfiguration::kCheckHolder, V8DOMConfiguration::kAllWorlds }, }; static const V8DOMConfiguration::MethodConfiguration V8TestInterfaceCheckSecurityMethods[] = {
diff --git a/third_party/WebKit/Source/bindings/tests/results/core/V8TestInterfaceConstructor.cpp b/third_party/WebKit/Source/bindings/tests/results/core/V8TestInterfaceConstructor.cpp index af65d0ca..c8d64342 100644 --- a/third_party/WebKit/Source/bindings/tests/results/core/V8TestInterfaceConstructor.cpp +++ b/third_party/WebKit/Source/bindings/tests/results/core/V8TestInterfaceConstructor.cpp
@@ -157,7 +157,6 @@ v8::Local<v8::Object> wrapper = info.Holder(); wrapper = impl->AssociateWithWrapper(info.GetIsolate(), &V8TestInterfaceConstructor::wrapperTypeInfo, wrapper); V8SetReturnValue(info, wrapper); - return; } optionalUSVStringArg = NativeValueTraits<IDLUSVStringBase<kTreatNullAndUndefinedAsNullString>>::NativeValue(info.GetIsolate(), info[7], exceptionState); @@ -222,7 +221,6 @@ v8::Local<v8::Object> wrapper = info.Holder(); wrapper = impl->AssociateWithWrapper(info.GetIsolate(), &V8TestInterfaceConstructor::wrapperTypeInfo, wrapper); V8SetReturnValue(info, wrapper); - return; } optArg = info[1]; @@ -407,7 +405,6 @@ v8::Local<v8::Object> wrapper = info.Holder(); wrapper = impl->AssociateWithWrapper(info.GetIsolate(), &V8TestInterfaceConstructorConstructor::wrapperTypeInfo, wrapper); V8SetReturnValue(info, wrapper); - return; } optArg = info[1];
diff --git a/third_party/WebKit/Source/bindings/tests/results/core/V8TestInterfaceConstructor2.cpp b/third_party/WebKit/Source/bindings/tests/results/core/V8TestInterfaceConstructor2.cpp index b376b51..bc9e04c 100644 --- a/third_party/WebKit/Source/bindings/tests/results/core/V8TestInterfaceConstructor2.cpp +++ b/third_party/WebKit/Source/bindings/tests/results/core/V8TestInterfaceConstructor2.cpp
@@ -165,7 +165,6 @@ v8::Local<v8::Object> wrapper = info.Holder(); wrapper = impl->AssociateWithWrapper(info.GetIsolate(), &V8TestInterfaceConstructor2::wrapperTypeInfo, wrapper); V8SetReturnValue(info, wrapper); - return; } optionalStringArg = info[5];
diff --git a/third_party/WebKit/Source/bindings/tests/results/core/V8TestInterfaceDocument.cpp b/third_party/WebKit/Source/bindings/tests/results/core/V8TestInterfaceDocument.cpp index e9a3dbf..6d63e64 100644 --- a/third_party/WebKit/Source/bindings/tests/results/core/V8TestInterfaceDocument.cpp +++ b/third_party/WebKit/Source/bindings/tests/results/core/V8TestInterfaceDocument.cpp
@@ -113,8 +113,7 @@ } static const V8DOMConfiguration::AccessorConfiguration V8TestInterfaceDocumentAccessors[] = { - { "location", V8TestInterfaceDocument::locationAttributeGetterCallback, V8TestInterfaceDocument::locationAttributeSetterCallback, V8PrivateProperty::kNoCachedAccessor, static_cast<v8::PropertyAttribute>(v8::DontDelete), V8DOMConfiguration::kOnInstance, V8DOMConfiguration::kCheckHolder, V8DOMConfiguration::kAllWorlds } -, + { "location", V8TestInterfaceDocument::locationAttributeGetterCallback, V8TestInterfaceDocument::locationAttributeSetterCallback, V8PrivateProperty::kNoCachedAccessor, static_cast<v8::PropertyAttribute>(v8::DontDelete), V8DOMConfiguration::kOnInstance, V8DOMConfiguration::kCheckHolder, V8DOMConfiguration::kAllWorlds }, }; static void installV8TestInterfaceDocumentTemplate(
diff --git a/third_party/WebKit/Source/bindings/tests/results/core/V8TestInterfaceEventInitConstructor.cpp b/third_party/WebKit/Source/bindings/tests/results/core/V8TestInterfaceEventInitConstructor.cpp index 2b5874d..bd839e8 100644 --- a/third_party/WebKit/Source/bindings/tests/results/core/V8TestInterfaceEventInitConstructor.cpp +++ b/third_party/WebKit/Source/bindings/tests/results/core/V8TestInterfaceEventInitConstructor.cpp
@@ -125,11 +125,8 @@ } static const V8DOMConfiguration::AccessorConfiguration V8TestInterfaceEventInitConstructorAccessors[] = { - { "readonlyStringAttribute", V8TestInterfaceEventInitConstructor::readonlyStringAttributeAttributeGetterCallback, nullptr, V8PrivateProperty::kNoCachedAccessor, static_cast<v8::PropertyAttribute>(v8::ReadOnly), V8DOMConfiguration::kOnPrototype, V8DOMConfiguration::kCheckHolder, V8DOMConfiguration::kAllWorlds } -, - - { "isTrusted", V8TestInterfaceEventInitConstructor::isTrustedAttributeGetterCallback, nullptr, V8PrivateProperty::kNoCachedAccessor, static_cast<v8::PropertyAttribute>(v8::DontDelete | v8::ReadOnly), V8DOMConfiguration::kOnInstance, V8DOMConfiguration::kCheckHolder, V8DOMConfiguration::kAllWorlds } -, + { "readonlyStringAttribute", V8TestInterfaceEventInitConstructor::readonlyStringAttributeAttributeGetterCallback, nullptr, V8PrivateProperty::kNoCachedAccessor, static_cast<v8::PropertyAttribute>(v8::ReadOnly), V8DOMConfiguration::kOnPrototype, V8DOMConfiguration::kCheckHolder, V8DOMConfiguration::kAllWorlds }, + { "isTrusted", V8TestInterfaceEventInitConstructor::isTrustedAttributeGetterCallback, nullptr, V8PrivateProperty::kNoCachedAccessor, static_cast<v8::PropertyAttribute>(v8::DontDelete | v8::ReadOnly), V8DOMConfiguration::kOnInstance, V8DOMConfiguration::kCheckHolder, V8DOMConfiguration::kAllWorlds }, }; void V8TestInterfaceEventInitConstructor::constructorCallback(const v8::FunctionCallbackInfo<v8::Value>& info) {
diff --git a/third_party/WebKit/Source/bindings/tests/results/core/V8TestInterfaceGarbageCollected.cpp b/third_party/WebKit/Source/bindings/tests/results/core/V8TestInterfaceGarbageCollected.cpp index b5d2cf95..487c8f7 100644 --- a/third_party/WebKit/Source/bindings/tests/results/core/V8TestInterfaceGarbageCollected.cpp +++ b/third_party/WebKit/Source/bindings/tests/results/core/V8TestInterfaceGarbageCollected.cpp
@@ -376,11 +376,8 @@ } static const V8DOMConfiguration::AccessorConfiguration V8TestInterfaceGarbageCollectedAccessors[] = { - { "attr1", V8TestInterfaceGarbageCollected::attr1AttributeGetterCallback, V8TestInterfaceGarbageCollected::attr1AttributeSetterCallback, V8PrivateProperty::kNoCachedAccessor, static_cast<v8::PropertyAttribute>(v8::None), V8DOMConfiguration::kOnPrototype, V8DOMConfiguration::kCheckHolder, V8DOMConfiguration::kAllWorlds } -, - - { "size", V8TestInterfaceGarbageCollected::sizeAttributeGetterCallback, nullptr, V8PrivateProperty::kNoCachedAccessor, static_cast<v8::PropertyAttribute>(v8::DontEnum | v8::ReadOnly), V8DOMConfiguration::kOnPrototype, V8DOMConfiguration::kCheckHolder, V8DOMConfiguration::kAllWorlds } -, + { "attr1", V8TestInterfaceGarbageCollected::attr1AttributeGetterCallback, V8TestInterfaceGarbageCollected::attr1AttributeSetterCallback, V8PrivateProperty::kNoCachedAccessor, static_cast<v8::PropertyAttribute>(v8::None), V8DOMConfiguration::kOnPrototype, V8DOMConfiguration::kCheckHolder, V8DOMConfiguration::kAllWorlds }, + { "size", V8TestInterfaceGarbageCollected::sizeAttributeGetterCallback, nullptr, V8PrivateProperty::kNoCachedAccessor, static_cast<v8::PropertyAttribute>(v8::DontEnum | v8::ReadOnly), V8DOMConfiguration::kOnPrototype, V8DOMConfiguration::kCheckHolder, V8DOMConfiguration::kAllWorlds }, }; static const V8DOMConfiguration::MethodConfiguration V8TestInterfaceGarbageCollectedMethods[] = {
diff --git a/third_party/WebKit/Source/bindings/tests/results/core/V8TestInterfaceNamedConstructor.cpp b/third_party/WebKit/Source/bindings/tests/results/core/V8TestInterfaceNamedConstructor.cpp index 2bd321be..2877213b 100644 --- a/third_party/WebKit/Source/bindings/tests/results/core/V8TestInterfaceNamedConstructor.cpp +++ b/third_party/WebKit/Source/bindings/tests/results/core/V8TestInterfaceNamedConstructor.cpp
@@ -80,8 +80,7 @@ #pragma clang diagnostic ignored "-Wglobal-constructors" #endif static const V8DOMConfiguration::AttributeConfiguration V8TestInterfaceNamedConstructorLazyDataAttributes[] = { - { "testNamedConstructorConstructorAttribute", V8TestInterfaceNamedConstructor::testNamedConstructorConstructorAttributeConstructorGetterCallback, nullptr, static_cast<v8::PropertyAttribute>(v8::DontEnum), V8DOMConfiguration::kOnInstance, V8DOMConfiguration::kCheckHolder, V8DOMConfiguration::kAllWorlds } -, + { "testNamedConstructorConstructorAttribute", V8TestInterfaceNamedConstructor::testNamedConstructorConstructorAttributeConstructorGetterCallback, nullptr, static_cast<v8::PropertyAttribute>(v8::DontEnum), V8DOMConfiguration::kOnInstance, V8DOMConfiguration::kCheckHolder, V8DOMConfiguration::kAllWorlds }, }; #if defined(COMPONENT_BUILD) && defined(WIN32) && defined(__clang__) #pragma clang diagnostic pop @@ -172,7 +171,6 @@ v8::Local<v8::Object> wrapper = info.Holder(); wrapper = impl->AssociateWithWrapper(info.GetIsolate(), &V8TestInterfaceNamedConstructorConstructor::wrapperTypeInfo, wrapper); V8SetReturnValue(info, wrapper); - return; } optionalStringArg = info[5];
diff --git a/third_party/WebKit/Source/bindings/tests/results/core/V8TestInterfaceNode.cpp b/third_party/WebKit/Source/bindings/tests/results/core/V8TestInterfaceNode.cpp index bd052f5b..ac7d755 100644 --- a/third_party/WebKit/Source/bindings/tests/results/core/V8TestInterfaceNode.cpp +++ b/third_party/WebKit/Source/bindings/tests/results/core/V8TestInterfaceNode.cpp
@@ -251,7 +251,6 @@ } if (UNLIKELY(numArgsPassed <= 0)) { V8SetReturnValueFast(info, impl->perWorldBindingsTestInterfaceEmptyMethodOptionalBooleanArg(), impl); - return; } optionalBooleanArgument = NativeValueTraits<IDLBoolean>::NativeValue(info.GetIsolate(), info[0], exceptionState); @@ -275,7 +274,6 @@ } if (UNLIKELY(numArgsPassed <= 0)) { V8SetReturnValueForMainWorld(info, impl->perWorldBindingsTestInterfaceEmptyMethodOptionalBooleanArg()); - return; } optionalBooleanArgument = NativeValueTraits<IDLBoolean>::NativeValue(info.GetIsolate(), info[0], exceptionState); @@ -406,27 +404,14 @@ } static const V8DOMConfiguration::AccessorConfiguration V8TestInterfaceNodeAccessors[] = { - { "nodeName", V8TestInterfaceNode::nodeNameAttributeGetterCallback, V8TestInterfaceNode::nodeNameAttributeSetterCallback, V8PrivateProperty::kNoCachedAccessor, static_cast<v8::PropertyAttribute>(v8::None), V8DOMConfiguration::kOnPrototype, V8DOMConfiguration::kCheckHolder, V8DOMConfiguration::kAllWorlds } -, - - { "stringAttribute", V8TestInterfaceNode::stringAttributeAttributeGetterCallback, V8TestInterfaceNode::stringAttributeAttributeSetterCallback, V8PrivateProperty::kNoCachedAccessor, static_cast<v8::PropertyAttribute>(v8::None), V8DOMConfiguration::kOnPrototype, V8DOMConfiguration::kCheckHolder, V8DOMConfiguration::kAllWorlds } -, - - { "readonlyTestInterfaceEmptyAttribute", V8TestInterfaceNode::readonlyTestInterfaceEmptyAttributeAttributeGetterCallback, nullptr, V8PrivateProperty::kNoCachedAccessor, static_cast<v8::PropertyAttribute>(v8::ReadOnly), V8DOMConfiguration::kOnPrototype, V8DOMConfiguration::kCheckHolder, V8DOMConfiguration::kAllWorlds } -, - - { "eventHandlerAttribute", V8TestInterfaceNode::eventHandlerAttributeAttributeGetterCallback, V8TestInterfaceNode::eventHandlerAttributeAttributeSetterCallback, V8PrivateProperty::kNoCachedAccessor, static_cast<v8::PropertyAttribute>(v8::None), V8DOMConfiguration::kOnPrototype, V8DOMConfiguration::kCheckHolder, V8DOMConfiguration::kAllWorlds } -, - + { "nodeName", V8TestInterfaceNode::nodeNameAttributeGetterCallback, V8TestInterfaceNode::nodeNameAttributeSetterCallback, V8PrivateProperty::kNoCachedAccessor, static_cast<v8::PropertyAttribute>(v8::None), V8DOMConfiguration::kOnPrototype, V8DOMConfiguration::kCheckHolder, V8DOMConfiguration::kAllWorlds }, + { "stringAttribute", V8TestInterfaceNode::stringAttributeAttributeGetterCallback, V8TestInterfaceNode::stringAttributeAttributeSetterCallback, V8PrivateProperty::kNoCachedAccessor, static_cast<v8::PropertyAttribute>(v8::None), V8DOMConfiguration::kOnPrototype, V8DOMConfiguration::kCheckHolder, V8DOMConfiguration::kAllWorlds }, + { "readonlyTestInterfaceEmptyAttribute", V8TestInterfaceNode::readonlyTestInterfaceEmptyAttributeAttributeGetterCallback, nullptr, V8PrivateProperty::kNoCachedAccessor, static_cast<v8::PropertyAttribute>(v8::ReadOnly), V8DOMConfiguration::kOnPrototype, V8DOMConfiguration::kCheckHolder, V8DOMConfiguration::kAllWorlds }, + { "eventHandlerAttribute", V8TestInterfaceNode::eventHandlerAttributeAttributeGetterCallback, V8TestInterfaceNode::eventHandlerAttributeAttributeSetterCallback, V8PrivateProperty::kNoCachedAccessor, static_cast<v8::PropertyAttribute>(v8::None), V8DOMConfiguration::kOnPrototype, V8DOMConfiguration::kCheckHolder, V8DOMConfiguration::kAllWorlds }, { "perWorldBindingsReadonlyTestInterfaceEmptyAttribute", V8TestInterfaceNode::perWorldBindingsReadonlyTestInterfaceEmptyAttributeAttributeGetterCallbackForMainWorld, nullptr, V8PrivateProperty::kNoCachedAccessor, static_cast<v8::PropertyAttribute>(v8::ReadOnly), V8DOMConfiguration::kOnPrototype, V8DOMConfiguration::kCheckHolder, V8DOMConfiguration::kMainWorld }, - { "perWorldBindingsReadonlyTestInterfaceEmptyAttribute", V8TestInterfaceNode::perWorldBindingsReadonlyTestInterfaceEmptyAttributeAttributeGetterCallback, nullptr, V8PrivateProperty::kNoCachedAccessor, static_cast<v8::PropertyAttribute>(v8::ReadOnly), V8DOMConfiguration::kOnPrototype, V8DOMConfiguration::kCheckHolder, V8DOMConfiguration::kNonMainWorlds } -, - - { "reflectStringAttribute", V8TestInterfaceNode::reflectStringAttributeAttributeGetterCallback, V8TestInterfaceNode::reflectStringAttributeAttributeSetterCallback, V8PrivateProperty::kNoCachedAccessor, static_cast<v8::PropertyAttribute>(v8::None), V8DOMConfiguration::kOnPrototype, V8DOMConfiguration::kCheckHolder, V8DOMConfiguration::kAllWorlds } -, - - { "reflectUrlStringAttribute", V8TestInterfaceNode::reflectUrlStringAttributeAttributeGetterCallback, V8TestInterfaceNode::reflectUrlStringAttributeAttributeSetterCallback, V8PrivateProperty::kNoCachedAccessor, static_cast<v8::PropertyAttribute>(v8::None), V8DOMConfiguration::kOnPrototype, V8DOMConfiguration::kCheckHolder, V8DOMConfiguration::kAllWorlds } -, + { "perWorldBindingsReadonlyTestInterfaceEmptyAttribute", V8TestInterfaceNode::perWorldBindingsReadonlyTestInterfaceEmptyAttributeAttributeGetterCallback, nullptr, V8PrivateProperty::kNoCachedAccessor, static_cast<v8::PropertyAttribute>(v8::ReadOnly), V8DOMConfiguration::kOnPrototype, V8DOMConfiguration::kCheckHolder, V8DOMConfiguration::kNonMainWorlds }, + { "reflectStringAttribute", V8TestInterfaceNode::reflectStringAttributeAttributeGetterCallback, V8TestInterfaceNode::reflectStringAttributeAttributeSetterCallback, V8PrivateProperty::kNoCachedAccessor, static_cast<v8::PropertyAttribute>(v8::None), V8DOMConfiguration::kOnPrototype, V8DOMConfiguration::kCheckHolder, V8DOMConfiguration::kAllWorlds }, + { "reflectUrlStringAttribute", V8TestInterfaceNode::reflectUrlStringAttributeAttributeGetterCallback, V8TestInterfaceNode::reflectUrlStringAttributeAttributeSetterCallback, V8PrivateProperty::kNoCachedAccessor, static_cast<v8::PropertyAttribute>(v8::None), V8DOMConfiguration::kOnPrototype, V8DOMConfiguration::kCheckHolder, V8DOMConfiguration::kAllWorlds }, }; static const V8DOMConfiguration::MethodConfiguration V8TestInterfaceNodeMethods[] = {
diff --git a/third_party/WebKit/Source/bindings/tests/results/core/V8TestInterfaceOriginTrialEnabled.cpp b/third_party/WebKit/Source/bindings/tests/results/core/V8TestInterfaceOriginTrialEnabled.cpp index 0781d52..2f17713 100644 --- a/third_party/WebKit/Source/bindings/tests/results/core/V8TestInterfaceOriginTrialEnabled.cpp +++ b/third_party/WebKit/Source/bindings/tests/results/core/V8TestInterfaceOriginTrialEnabled.cpp
@@ -285,11 +285,8 @@ } static const V8DOMConfiguration::AccessorConfiguration V8TestInterfaceOriginTrialEnabledAccessors[] = { - { "doubleAttribute", V8TestInterfaceOriginTrialEnabled::doubleAttributeAttributeGetterCallback, V8TestInterfaceOriginTrialEnabled::doubleAttributeAttributeSetterCallback, V8PrivateProperty::kNoCachedAccessor, static_cast<v8::PropertyAttribute>(v8::None), V8DOMConfiguration::kOnPrototype, V8DOMConfiguration::kCheckHolder, V8DOMConfiguration::kAllWorlds } -, - - { "staticStringAttribute", V8TestInterfaceOriginTrialEnabled::staticStringAttributeAttributeGetterCallback, V8TestInterfaceOriginTrialEnabled::staticStringAttributeAttributeSetterCallback, V8PrivateProperty::kNoCachedAccessor, static_cast<v8::PropertyAttribute>(v8::None), V8DOMConfiguration::kOnInterface, V8DOMConfiguration::kCheckHolder, V8DOMConfiguration::kAllWorlds } -, + { "doubleAttribute", V8TestInterfaceOriginTrialEnabled::doubleAttributeAttributeGetterCallback, V8TestInterfaceOriginTrialEnabled::doubleAttributeAttributeSetterCallback, V8PrivateProperty::kNoCachedAccessor, static_cast<v8::PropertyAttribute>(v8::None), V8DOMConfiguration::kOnPrototype, V8DOMConfiguration::kCheckHolder, V8DOMConfiguration::kAllWorlds }, + { "staticStringAttribute", V8TestInterfaceOriginTrialEnabled::staticStringAttributeAttributeGetterCallback, V8TestInterfaceOriginTrialEnabled::staticStringAttributeAttributeSetterCallback, V8PrivateProperty::kNoCachedAccessor, static_cast<v8::PropertyAttribute>(v8::None), V8DOMConfiguration::kOnInterface, V8DOMConfiguration::kCheckHolder, V8DOMConfiguration::kAllWorlds }, }; static const V8DOMConfiguration::MethodConfiguration V8TestInterfaceOriginTrialEnabledMethods[] = { @@ -321,7 +318,6 @@ V8TestInterfaceOriginTrialEnabledConstants, WTF_ARRAY_LENGTH(V8TestInterfaceOriginTrialEnabledConstants)); static_assert(0 == TestInterfaceOriginTrialEnabled::kUnsignedLong, "the value of TestInterfaceOriginTrialEnabled_kUnsignedLong does not match with implementation"); static_assert(1 == TestInterfaceOriginTrialEnabled::kConstJavascript, "the value of TestInterfaceOriginTrialEnabled_kConstJavascript does not match with implementation"); - V8DOMConfiguration::InstallAccessors( isolate, world, instanceTemplate, prototypeTemplate, interfaceTemplate, signature, V8TestInterfaceOriginTrialEnabledAccessors, WTF_ARRAY_LENGTH(V8TestInterfaceOriginTrialEnabledAccessors)); @@ -350,14 +346,9 @@ if (RuntimeEnabledFeatures::FeatureNameEnabled()) { static const V8DOMConfiguration::AccessorConfiguration accessor_configurations[] = { - { "conditionalReadOnlyLongAttribute", V8TestInterfaceOriginTrialEnabled::conditionalReadOnlyLongAttributeAttributeGetterCallback, nullptr, V8PrivateProperty::kNoCachedAccessor, static_cast<v8::PropertyAttribute>(v8::ReadOnly), V8DOMConfiguration::kOnPrototype, V8DOMConfiguration::kCheckHolder, V8DOMConfiguration::kAllWorlds } - , - - { "staticConditionalReadOnlyLongAttribute", V8TestInterfaceOriginTrialEnabled::staticConditionalReadOnlyLongAttributeAttributeGetterCallback, nullptr, V8PrivateProperty::kNoCachedAccessor, static_cast<v8::PropertyAttribute>(v8::ReadOnly), V8DOMConfiguration::kOnInterface, V8DOMConfiguration::kCheckHolder, V8DOMConfiguration::kAllWorlds } - , - - { "conditionalLongAttribute", V8TestInterfaceOriginTrialEnabled::conditionalLongAttributeAttributeGetterCallback, V8TestInterfaceOriginTrialEnabled::conditionalLongAttributeAttributeSetterCallback, V8PrivateProperty::kNoCachedAccessor, static_cast<v8::PropertyAttribute>(v8::None), V8DOMConfiguration::kOnPrototype, V8DOMConfiguration::kCheckHolder, V8DOMConfiguration::kAllWorlds } - , + { "conditionalReadOnlyLongAttribute", V8TestInterfaceOriginTrialEnabled::conditionalReadOnlyLongAttributeAttributeGetterCallback, nullptr, V8PrivateProperty::kNoCachedAccessor, static_cast<v8::PropertyAttribute>(v8::ReadOnly), V8DOMConfiguration::kOnPrototype, V8DOMConfiguration::kCheckHolder, V8DOMConfiguration::kAllWorlds }, + { "staticConditionalReadOnlyLongAttribute", V8TestInterfaceOriginTrialEnabled::staticConditionalReadOnlyLongAttributeAttributeGetterCallback, nullptr, V8PrivateProperty::kNoCachedAccessor, static_cast<v8::PropertyAttribute>(v8::ReadOnly), V8DOMConfiguration::kOnInterface, V8DOMConfiguration::kCheckHolder, V8DOMConfiguration::kAllWorlds }, + { "conditionalLongAttribute", V8TestInterfaceOriginTrialEnabled::conditionalLongAttributeAttributeGetterCallback, V8TestInterfaceOriginTrialEnabled::conditionalLongAttributeAttributeSetterCallback, V8PrivateProperty::kNoCachedAccessor, static_cast<v8::PropertyAttribute>(v8::None), V8DOMConfiguration::kOnPrototype, V8DOMConfiguration::kCheckHolder, V8DOMConfiguration::kAllWorlds }, }; V8DOMConfiguration::InstallAccessors( isolate, world, instance_template, prototype_template, interface_template,
diff --git a/third_party/WebKit/Source/bindings/tests/results/core/V8TestInterfaceSecureContext.cpp b/third_party/WebKit/Source/bindings/tests/results/core/V8TestInterfaceSecureContext.cpp index fb77ce8..8558dcd 100644 --- a/third_party/WebKit/Source/bindings/tests/results/core/V8TestInterfaceSecureContext.cpp +++ b/third_party/WebKit/Source/bindings/tests/results/core/V8TestInterfaceSecureContext.cpp
@@ -467,8 +467,7 @@ if (!prototypeObject.IsEmpty() || !interfaceObject.IsEmpty()) { if (isSecureContext) { static const V8DOMConfiguration::AccessorConfiguration accessor_configurations[] = { - { "secureContextAttribute", V8TestInterfaceSecureContext::secureContextAttributeAttributeGetterCallback, V8TestInterfaceSecureContext::secureContextAttributeAttributeSetterCallback, V8PrivateProperty::kNoCachedAccessor, static_cast<v8::PropertyAttribute>(v8::None), V8DOMConfiguration::kOnPrototype, V8DOMConfiguration::kCheckHolder, V8DOMConfiguration::kAllWorlds } - , + { "secureContextAttribute", V8TestInterfaceSecureContext::secureContextAttributeAttributeGetterCallback, V8TestInterfaceSecureContext::secureContextAttributeAttributeSetterCallback, V8PrivateProperty::kNoCachedAccessor, static_cast<v8::PropertyAttribute>(v8::None), V8DOMConfiguration::kOnPrototype, V8DOMConfiguration::kCheckHolder, V8DOMConfiguration::kAllWorlds }, }; V8DOMConfiguration::InstallAccessors( isolate, world, instanceObject, prototypeObject, interfaceObject, @@ -476,8 +475,7 @@ WTF_ARRAY_LENGTH(accessor_configurations)); if (RuntimeEnabledFeatures::SecureFeatureEnabled()) { static const V8DOMConfiguration::AccessorConfiguration accessor_configurations[] = { - { "secureContextRuntimeEnabledAttribute", V8TestInterfaceSecureContext::secureContextRuntimeEnabledAttributeAttributeGetterCallback, V8TestInterfaceSecureContext::secureContextRuntimeEnabledAttributeAttributeSetterCallback, V8PrivateProperty::kNoCachedAccessor, static_cast<v8::PropertyAttribute>(v8::None), V8DOMConfiguration::kOnPrototype, V8DOMConfiguration::kCheckHolder, V8DOMConfiguration::kAllWorlds } - , + { "secureContextRuntimeEnabledAttribute", V8TestInterfaceSecureContext::secureContextRuntimeEnabledAttributeAttributeGetterCallback, V8TestInterfaceSecureContext::secureContextRuntimeEnabledAttributeAttributeSetterCallback, V8PrivateProperty::kNoCachedAccessor, static_cast<v8::PropertyAttribute>(v8::None), V8DOMConfiguration::kOnPrototype, V8DOMConfiguration::kCheckHolder, V8DOMConfiguration::kAllWorlds }, }; V8DOMConfiguration::InstallAccessors( isolate, world, instanceObject, prototypeObject, interfaceObject, @@ -488,8 +486,7 @@ if (executionContext && (executionContext->IsDocument())) { if (isSecureContext) { static const V8DOMConfiguration::AccessorConfiguration accessor_configurations[] = { - { "secureContextWindowExposedAttribute", V8TestInterfaceSecureContext::secureContextWindowExposedAttributeAttributeGetterCallback, V8TestInterfaceSecureContext::secureContextWindowExposedAttributeAttributeSetterCallback, V8PrivateProperty::kNoCachedAccessor, static_cast<v8::PropertyAttribute>(v8::None), V8DOMConfiguration::kOnPrototype, V8DOMConfiguration::kCheckHolder, V8DOMConfiguration::kAllWorlds } - , + { "secureContextWindowExposedAttribute", V8TestInterfaceSecureContext::secureContextWindowExposedAttributeAttributeGetterCallback, V8TestInterfaceSecureContext::secureContextWindowExposedAttributeAttributeSetterCallback, V8PrivateProperty::kNoCachedAccessor, static_cast<v8::PropertyAttribute>(v8::None), V8DOMConfiguration::kOnPrototype, V8DOMConfiguration::kCheckHolder, V8DOMConfiguration::kAllWorlds }, }; V8DOMConfiguration::InstallAccessors( isolate, world, instanceObject, prototypeObject, interfaceObject, @@ -497,8 +494,7 @@ WTF_ARRAY_LENGTH(accessor_configurations)); if (RuntimeEnabledFeatures::SecureFeatureEnabled()) { static const V8DOMConfiguration::AccessorConfiguration accessor_configurations[] = { - { "secureContextWindowExposedRuntimeEnabledAttribute", V8TestInterfaceSecureContext::secureContextWindowExposedRuntimeEnabledAttributeAttributeGetterCallback, V8TestInterfaceSecureContext::secureContextWindowExposedRuntimeEnabledAttributeAttributeSetterCallback, V8PrivateProperty::kNoCachedAccessor, static_cast<v8::PropertyAttribute>(v8::None), V8DOMConfiguration::kOnPrototype, V8DOMConfiguration::kCheckHolder, V8DOMConfiguration::kAllWorlds } - , + { "secureContextWindowExposedRuntimeEnabledAttribute", V8TestInterfaceSecureContext::secureContextWindowExposedRuntimeEnabledAttributeAttributeGetterCallback, V8TestInterfaceSecureContext::secureContextWindowExposedRuntimeEnabledAttributeAttributeSetterCallback, V8PrivateProperty::kNoCachedAccessor, static_cast<v8::PropertyAttribute>(v8::None), V8DOMConfiguration::kOnPrototype, V8DOMConfiguration::kCheckHolder, V8DOMConfiguration::kAllWorlds }, }; V8DOMConfiguration::InstallAccessors( isolate, world, instanceObject, prototypeObject, interfaceObject, @@ -510,8 +506,7 @@ if (executionContext && (executionContext->IsWorkerGlobalScope())) { if (isSecureContext) { static const V8DOMConfiguration::AccessorConfiguration accessor_configurations[] = { - { "secureContextWorkerExposedAttribute", V8TestInterfaceSecureContext::secureContextWorkerExposedAttributeAttributeGetterCallback, V8TestInterfaceSecureContext::secureContextWorkerExposedAttributeAttributeSetterCallback, V8PrivateProperty::kNoCachedAccessor, static_cast<v8::PropertyAttribute>(v8::None), V8DOMConfiguration::kOnPrototype, V8DOMConfiguration::kCheckHolder, V8DOMConfiguration::kAllWorlds } - , + { "secureContextWorkerExposedAttribute", V8TestInterfaceSecureContext::secureContextWorkerExposedAttributeAttributeGetterCallback, V8TestInterfaceSecureContext::secureContextWorkerExposedAttributeAttributeSetterCallback, V8PrivateProperty::kNoCachedAccessor, static_cast<v8::PropertyAttribute>(v8::None), V8DOMConfiguration::kOnPrototype, V8DOMConfiguration::kCheckHolder, V8DOMConfiguration::kAllWorlds }, }; V8DOMConfiguration::InstallAccessors( isolate, world, instanceObject, prototypeObject, interfaceObject, @@ -519,8 +514,7 @@ WTF_ARRAY_LENGTH(accessor_configurations)); if (RuntimeEnabledFeatures::SecureFeatureEnabled()) { static const V8DOMConfiguration::AccessorConfiguration accessor_configurations[] = { - { "secureContextWorkerExposedRuntimeEnabledAttribute", V8TestInterfaceSecureContext::secureContextWorkerExposedRuntimeEnabledAttributeAttributeGetterCallback, V8TestInterfaceSecureContext::secureContextWorkerExposedRuntimeEnabledAttributeAttributeSetterCallback, V8PrivateProperty::kNoCachedAccessor, static_cast<v8::PropertyAttribute>(v8::None), V8DOMConfiguration::kOnPrototype, V8DOMConfiguration::kCheckHolder, V8DOMConfiguration::kAllWorlds } - , + { "secureContextWorkerExposedRuntimeEnabledAttribute", V8TestInterfaceSecureContext::secureContextWorkerExposedRuntimeEnabledAttributeAttributeGetterCallback, V8TestInterfaceSecureContext::secureContextWorkerExposedRuntimeEnabledAttributeAttributeSetterCallback, V8PrivateProperty::kNoCachedAccessor, static_cast<v8::PropertyAttribute>(v8::None), V8DOMConfiguration::kOnPrototype, V8DOMConfiguration::kCheckHolder, V8DOMConfiguration::kAllWorlds }, }; V8DOMConfiguration::InstallAccessors( isolate, world, instanceObject, prototypeObject, interfaceObject, @@ -529,7 +523,6 @@ } } } - if (isSecureContext) { const V8DOMConfiguration::MethodConfiguration secureContextMethodMethodConfiguration[] = { {"secureContextMethod", V8TestInterfaceSecureContext::secureContextMethodMethodCallback, 0, v8::None, V8DOMConfiguration::kOnPrototype, V8DOMConfiguration::kCheckHolder, V8DOMConfiguration::kDoNotCheckAccess, V8DOMConfiguration::kAllWorlds}
diff --git a/third_party/WebKit/Source/bindings/tests/results/core/V8TestNode.cpp b/third_party/WebKit/Source/bindings/tests/results/core/V8TestNode.cpp index 23cf147..73dba87 100644 --- a/third_party/WebKit/Source/bindings/tests/results/core/V8TestNode.cpp +++ b/third_party/WebKit/Source/bindings/tests/results/core/V8TestNode.cpp
@@ -237,17 +237,10 @@ } static const V8DOMConfiguration::AccessorConfiguration V8TestNodeAccessors[] = { - { "href", V8TestNode::hrefAttributeGetterCallback, V8TestNode::hrefAttributeSetterCallback, V8PrivateProperty::kNoCachedAccessor, static_cast<v8::PropertyAttribute>(v8::None), V8DOMConfiguration::kOnPrototype, V8DOMConfiguration::kCheckHolder, V8DOMConfiguration::kAllWorlds } -, - - { "hrefThrows", V8TestNode::hrefThrowsAttributeGetterCallback, V8TestNode::hrefThrowsAttributeSetterCallback, V8PrivateProperty::kNoCachedAccessor, static_cast<v8::PropertyAttribute>(v8::None), V8DOMConfiguration::kOnPrototype, V8DOMConfiguration::kCheckHolder, V8DOMConfiguration::kAllWorlds } -, - - { "hrefCallWith", V8TestNode::hrefCallWithAttributeGetterCallback, V8TestNode::hrefCallWithAttributeSetterCallback, V8PrivateProperty::kNoCachedAccessor, static_cast<v8::PropertyAttribute>(v8::None), V8DOMConfiguration::kOnPrototype, V8DOMConfiguration::kCheckHolder, V8DOMConfiguration::kAllWorlds } -, - - { "hrefByteString", V8TestNode::hrefByteStringAttributeGetterCallback, V8TestNode::hrefByteStringAttributeSetterCallback, V8PrivateProperty::kNoCachedAccessor, static_cast<v8::PropertyAttribute>(v8::None), V8DOMConfiguration::kOnPrototype, V8DOMConfiguration::kCheckHolder, V8DOMConfiguration::kAllWorlds } -, + { "href", V8TestNode::hrefAttributeGetterCallback, V8TestNode::hrefAttributeSetterCallback, V8PrivateProperty::kNoCachedAccessor, static_cast<v8::PropertyAttribute>(v8::None), V8DOMConfiguration::kOnPrototype, V8DOMConfiguration::kCheckHolder, V8DOMConfiguration::kAllWorlds }, + { "hrefThrows", V8TestNode::hrefThrowsAttributeGetterCallback, V8TestNode::hrefThrowsAttributeSetterCallback, V8PrivateProperty::kNoCachedAccessor, static_cast<v8::PropertyAttribute>(v8::None), V8DOMConfiguration::kOnPrototype, V8DOMConfiguration::kCheckHolder, V8DOMConfiguration::kAllWorlds }, + { "hrefCallWith", V8TestNode::hrefCallWithAttributeGetterCallback, V8TestNode::hrefCallWithAttributeSetterCallback, V8PrivateProperty::kNoCachedAccessor, static_cast<v8::PropertyAttribute>(v8::None), V8DOMConfiguration::kOnPrototype, V8DOMConfiguration::kCheckHolder, V8DOMConfiguration::kAllWorlds }, + { "hrefByteString", V8TestNode::hrefByteStringAttributeGetterCallback, V8TestNode::hrefByteStringAttributeSetterCallback, V8PrivateProperty::kNoCachedAccessor, static_cast<v8::PropertyAttribute>(v8::None), V8DOMConfiguration::kOnPrototype, V8DOMConfiguration::kCheckHolder, V8DOMConfiguration::kAllWorlds }, }; void V8TestNode::constructorCallback(const v8::FunctionCallbackInfo<v8::Value>& info) {
diff --git a/third_party/WebKit/Source/bindings/tests/results/core/V8TestObject.cpp b/third_party/WebKit/Source/bindings/tests/results/core/V8TestObject.cpp index 879939b..cfa7473 100644 --- a/third_party/WebKit/Source/bindings/tests/results/core/V8TestObject.cpp +++ b/third_party/WebKit/Source/bindings/tests/results/core/V8TestObject.cpp
@@ -5999,7 +5999,6 @@ if (UNLIKELY(numArgsPassed <= 1)) { impl->voidMethodByteStringOrNullOptionalUSVStringArg(byteStringArg); - return; } usvStringArg = NativeValueTraits<IDLUSVString>::NativeValue(info.GetIsolate(), info[1], exceptionState); @@ -6021,7 +6020,6 @@ } if (UNLIKELY(numArgsPassed <= 0)) { impl->voidMethodOptionalStringArg(); - return; } optionalStringArg = info[0]; @@ -6043,7 +6041,6 @@ } if (UNLIKELY(numArgsPassed <= 0)) { impl->voidMethodOptionalTestInterfaceEmptyArg(); - return; } optionalTestInterfaceEmptyArg = V8TestInterfaceEmpty::ToImplWithTypeCheck(info.GetIsolate(), info[0]); @@ -6069,7 +6066,6 @@ } if (UNLIKELY(numArgsPassed <= 0)) { impl->voidMethodOptionalLongArg(); - return; } optionalLongArg = NativeValueTraits<IDLLong>::NativeValue(info.GetIsolate(), info[0], exceptionState, kNormalConversion); @@ -6093,7 +6089,6 @@ } if (UNLIKELY(numArgsPassed <= 0)) { V8SetReturnValueString(info, impl->stringMethodOptionalLongArg(), info.GetIsolate()); - return; } optionalLongArg = NativeValueTraits<IDLLong>::NativeValue(info.GetIsolate(), info[0], exceptionState, kNormalConversion); @@ -6117,7 +6112,6 @@ } if (UNLIKELY(numArgsPassed <= 0)) { V8SetReturnValue(info, impl->testInterfaceEmptyMethodOptionalLongArg()); - return; } optionalLongArg = NativeValueTraits<IDLLong>::NativeValue(info.GetIsolate(), info[0], exceptionState, kNormalConversion); @@ -6141,7 +6135,6 @@ } if (UNLIKELY(numArgsPassed <= 0)) { V8SetReturnValueInt(info, impl->longMethodOptionalLongArg()); - return; } optionalLongArg = NativeValueTraits<IDLLong>::NativeValue(info.GetIsolate(), info[0], exceptionState, kNormalConversion); @@ -6175,7 +6168,6 @@ if (UNLIKELY(numArgsPassed <= 1)) { impl->voidMethodLongArgOptionalLongArg(longArg); - return; } optionalLongArg = NativeValueTraits<IDLLong>::NativeValue(info.GetIsolate(), info[1], exceptionState, kNormalConversion); @@ -6210,7 +6202,6 @@ if (UNLIKELY(numArgsPassed <= 1)) { impl->voidMethodLongArgOptionalLongArgOptionalLongArg(longArg); - return; } optionalLongArg1 = NativeValueTraits<IDLLong>::NativeValue(info.GetIsolate(), info[1], exceptionState, kNormalConversion); @@ -6219,7 +6210,6 @@ if (UNLIKELY(numArgsPassed <= 2)) { impl->voidMethodLongArgOptionalLongArgOptionalLongArg(longArg, optionalLongArg1); - return; } optionalLongArg2 = NativeValueTraits<IDLLong>::NativeValue(info.GetIsolate(), info[2], exceptionState, kNormalConversion); @@ -6253,7 +6243,6 @@ if (UNLIKELY(numArgsPassed <= 1)) { impl->voidMethodLongArgOptionalTestInterfaceEmptyArg(longArg); - return; } optionalTestInterfaceEmpty = V8TestInterfaceEmpty::ToImplWithTypeCheck(info.GetIsolate(), info[1]); @@ -6291,7 +6280,6 @@ if (UNLIKELY(numArgsPassed <= 1)) { impl->voidMethodTestInterfaceEmptyArgOptionalLongArg(optionalTestInterfaceEmpty); - return; } longArg = NativeValueTraits<IDLLong>::NativeValue(info.GetIsolate(), info[1], exceptionState, kNormalConversion); @@ -6725,7 +6713,6 @@ if (UNLIKELY(numArgsPassed <= 1)) { impl->overloadedMethodB(stringArg); - return; } longArg = NativeValueTraits<IDLLong>::NativeValue(info.GetIsolate(), info[1], exceptionState, kNormalConversion); @@ -6951,7 +6938,6 @@ } if (UNLIKELY(numArgsPassed <= 0)) { impl->overloadedMethodF(); - return; } stringArg = info[0]; @@ -7922,7 +7908,6 @@ if (UNLIKELY(numArgsPassed <= 0)) { ScriptArguments* scriptArguments(ScriptArguments::Create(scriptState, info, 1)); impl->callWithScriptStateScriptArgumentsVoidMethodOptionalBooleanArg(scriptState, scriptArguments); - return; } optionalBooleanArg = NativeValueTraits<IDLBoolean>::NativeValue(info.GetIsolate(), info[0], exceptionState); @@ -8645,7 +8630,6 @@ if (exceptionState.HadException()) { return; } - return; } optionalLongArg = NativeValueTraits<IDLLong>::NativeValue(info.GetIsolate(), info[0], exceptionState, kNormalConversion); @@ -9008,7 +8992,6 @@ if (UNLIKELY(numArgsPassed <= 1)) { impl->useToImpl4ArgumentsCheckingIfPossibleWithOptionalArg(node1); - return; } node2 = V8Node::ToImplWithTypeCheck(info.GetIsolate(), info[1]); @@ -13039,7 +13022,6 @@ void V8TestObject::RuntimeCallStatsCounterMethodMethodCallback(const v8::FunctionCallbackInfo<v8::Value>& info) { RUNTIME_CALL_TIMER_SCOPE(info.GetIsolate(), RuntimeCallStats::CounterId::kRuntimeCallStatsCounterMethod); - TestObjectV8Internal::RuntimeCallStatsCounterMethodMethod(info); } @@ -13198,11 +13180,8 @@ #pragma clang diagnostic ignored "-Wglobal-constructors" #endif static const V8DOMConfiguration::AttributeConfiguration V8TestObjectAttributes[] = { - { "testInterfaceEmptyConstructorAttribute", V8TestObject::testInterfaceEmptyConstructorAttributeConstructorGetterCallback, nullptr, static_cast<v8::PropertyAttribute>(v8::DontEnum), V8DOMConfiguration::kOnInstance, V8DOMConfiguration::kCheckHolder, V8DOMConfiguration::kAllWorlds } -, - - { "measureAsFeatureNameTestInterfaceEmptyConstructorAttribute", V8TestObject::measureAsFeatureNameTestInterfaceEmptyConstructorAttributeConstructorGetterCallback, nullptr, static_cast<v8::PropertyAttribute>(v8::DontEnum), V8DOMConfiguration::kOnInstance, V8DOMConfiguration::kCheckHolder, V8DOMConfiguration::kAllWorlds } -, + { "testInterfaceEmptyConstructorAttribute", V8TestObject::testInterfaceEmptyConstructorAttributeConstructorGetterCallback, nullptr, static_cast<v8::PropertyAttribute>(v8::DontEnum), V8DOMConfiguration::kOnInstance, V8DOMConfiguration::kCheckHolder, V8DOMConfiguration::kAllWorlds }, + { "measureAsFeatureNameTestInterfaceEmptyConstructorAttribute", V8TestObject::measureAsFeatureNameTestInterfaceEmptyConstructorAttributeConstructorGetterCallback, nullptr, static_cast<v8::PropertyAttribute>(v8::DontEnum), V8DOMConfiguration::kOnInstance, V8DOMConfiguration::kCheckHolder, V8DOMConfiguration::kAllWorlds }, }; #if defined(COMPONENT_BUILD) && defined(WIN32) && defined(__clang__) #pragma clang diagnostic pop @@ -13215,460 +13194,166 @@ #pragma clang diagnostic ignored "-Wglobal-constructors" #endif static const V8DOMConfiguration::AttributeConfiguration V8TestObjectLazyDataAttributes[] = { - { "testInterfaceEmptyConstructorAttribute", V8TestObject::testInterfaceEmptyConstructorAttributeConstructorGetterCallback, nullptr, static_cast<v8::PropertyAttribute>(v8::DontEnum), V8DOMConfiguration::kOnInstance, V8DOMConfiguration::kCheckHolder, V8DOMConfiguration::kAllWorlds } -, + { "testInterfaceEmptyConstructorAttribute", V8TestObject::testInterfaceEmptyConstructorAttributeConstructorGetterCallback, nullptr, static_cast<v8::PropertyAttribute>(v8::DontEnum), V8DOMConfiguration::kOnInstance, V8DOMConfiguration::kCheckHolder, V8DOMConfiguration::kAllWorlds }, }; #if defined(COMPONENT_BUILD) && defined(WIN32) && defined(__clang__) #pragma clang diagnostic pop #endif static const V8DOMConfiguration::AccessorConfiguration V8TestObjectAccessors[] = { - { "stringifierAttribute", V8TestObject::stringifierAttributeAttributeGetterCallback, V8TestObject::stringifierAttributeAttributeSetterCallback, V8PrivateProperty::kNoCachedAccessor, static_cast<v8::PropertyAttribute>(v8::None), V8DOMConfiguration::kOnPrototype, V8DOMConfiguration::kCheckHolder, V8DOMConfiguration::kAllWorlds } -, - - { "readonlyStringAttribute", V8TestObject::readonlyStringAttributeAttributeGetterCallback, nullptr, V8PrivateProperty::kNoCachedAccessor, static_cast<v8::PropertyAttribute>(v8::ReadOnly), V8DOMConfiguration::kOnPrototype, V8DOMConfiguration::kCheckHolder, V8DOMConfiguration::kAllWorlds } -, - - { "readonlyTestInterfaceEmptyAttribute", V8TestObject::readonlyTestInterfaceEmptyAttributeAttributeGetterCallback, nullptr, V8PrivateProperty::kNoCachedAccessor, static_cast<v8::PropertyAttribute>(v8::ReadOnly), V8DOMConfiguration::kOnPrototype, V8DOMConfiguration::kCheckHolder, V8DOMConfiguration::kAllWorlds } -, - - { "readonlyLongAttribute", V8TestObject::readonlyLongAttributeAttributeGetterCallback, nullptr, V8PrivateProperty::kNoCachedAccessor, static_cast<v8::PropertyAttribute>(v8::ReadOnly), V8DOMConfiguration::kOnPrototype, V8DOMConfiguration::kCheckHolder, V8DOMConfiguration::kAllWorlds } -, - - { "dateAttribute", V8TestObject::dateAttributeAttributeGetterCallback, V8TestObject::dateAttributeAttributeSetterCallback, V8PrivateProperty::kNoCachedAccessor, static_cast<v8::PropertyAttribute>(v8::None), V8DOMConfiguration::kOnPrototype, V8DOMConfiguration::kCheckHolder, V8DOMConfiguration::kAllWorlds } -, - - { "stringAttribute", V8TestObject::stringAttributeAttributeGetterCallback, V8TestObject::stringAttributeAttributeSetterCallback, V8PrivateProperty::kNoCachedAccessor, static_cast<v8::PropertyAttribute>(v8::None), V8DOMConfiguration::kOnPrototype, V8DOMConfiguration::kCheckHolder, V8DOMConfiguration::kAllWorlds } -, - - { "byteStringAttribute", V8TestObject::byteStringAttributeAttributeGetterCallback, V8TestObject::byteStringAttributeAttributeSetterCallback, V8PrivateProperty::kNoCachedAccessor, static_cast<v8::PropertyAttribute>(v8::None), V8DOMConfiguration::kOnPrototype, V8DOMConfiguration::kCheckHolder, V8DOMConfiguration::kAllWorlds } -, - - { "usvStringAttribute", V8TestObject::usvStringAttributeAttributeGetterCallback, V8TestObject::usvStringAttributeAttributeSetterCallback, V8PrivateProperty::kNoCachedAccessor, static_cast<v8::PropertyAttribute>(v8::None), V8DOMConfiguration::kOnPrototype, V8DOMConfiguration::kCheckHolder, V8DOMConfiguration::kAllWorlds } -, - - { "domTimeStampAttribute", V8TestObject::domTimeStampAttributeAttributeGetterCallback, V8TestObject::domTimeStampAttributeAttributeSetterCallback, V8PrivateProperty::kNoCachedAccessor, static_cast<v8::PropertyAttribute>(v8::None), V8DOMConfiguration::kOnPrototype, V8DOMConfiguration::kCheckHolder, V8DOMConfiguration::kAllWorlds } -, - - { "booleanAttribute", V8TestObject::booleanAttributeAttributeGetterCallback, V8TestObject::booleanAttributeAttributeSetterCallback, V8PrivateProperty::kNoCachedAccessor, static_cast<v8::PropertyAttribute>(v8::None), V8DOMConfiguration::kOnPrototype, V8DOMConfiguration::kCheckHolder, V8DOMConfiguration::kAllWorlds } -, - - { "byteAttribute", V8TestObject::byteAttributeAttributeGetterCallback, V8TestObject::byteAttributeAttributeSetterCallback, V8PrivateProperty::kNoCachedAccessor, static_cast<v8::PropertyAttribute>(v8::None), V8DOMConfiguration::kOnPrototype, V8DOMConfiguration::kCheckHolder, V8DOMConfiguration::kAllWorlds } -, - - { "doubleAttribute", V8TestObject::doubleAttributeAttributeGetterCallback, V8TestObject::doubleAttributeAttributeSetterCallback, V8PrivateProperty::kNoCachedAccessor, static_cast<v8::PropertyAttribute>(v8::None), V8DOMConfiguration::kOnPrototype, V8DOMConfiguration::kCheckHolder, V8DOMConfiguration::kAllWorlds } -, - - { "floatAttribute", V8TestObject::floatAttributeAttributeGetterCallback, V8TestObject::floatAttributeAttributeSetterCallback, V8PrivateProperty::kNoCachedAccessor, static_cast<v8::PropertyAttribute>(v8::None), V8DOMConfiguration::kOnPrototype, V8DOMConfiguration::kCheckHolder, V8DOMConfiguration::kAllWorlds } -, - - { "longAttribute", V8TestObject::longAttributeAttributeGetterCallback, V8TestObject::longAttributeAttributeSetterCallback, V8PrivateProperty::kNoCachedAccessor, static_cast<v8::PropertyAttribute>(v8::None), V8DOMConfiguration::kOnPrototype, V8DOMConfiguration::kCheckHolder, V8DOMConfiguration::kAllWorlds } -, - - { "longLongAttribute", V8TestObject::longLongAttributeAttributeGetterCallback, V8TestObject::longLongAttributeAttributeSetterCallback, V8PrivateProperty::kNoCachedAccessor, static_cast<v8::PropertyAttribute>(v8::None), V8DOMConfiguration::kOnPrototype, V8DOMConfiguration::kCheckHolder, V8DOMConfiguration::kAllWorlds } -, - - { "octetAttribute", V8TestObject::octetAttributeAttributeGetterCallback, V8TestObject::octetAttributeAttributeSetterCallback, V8PrivateProperty::kNoCachedAccessor, static_cast<v8::PropertyAttribute>(v8::None), V8DOMConfiguration::kOnPrototype, V8DOMConfiguration::kCheckHolder, V8DOMConfiguration::kAllWorlds } -, - - { "shortAttribute", V8TestObject::shortAttributeAttributeGetterCallback, V8TestObject::shortAttributeAttributeSetterCallback, V8PrivateProperty::kNoCachedAccessor, static_cast<v8::PropertyAttribute>(v8::None), V8DOMConfiguration::kOnPrototype, V8DOMConfiguration::kCheckHolder, V8DOMConfiguration::kAllWorlds } -, - - { "unrestrictedDoubleAttribute", V8TestObject::unrestrictedDoubleAttributeAttributeGetterCallback, V8TestObject::unrestrictedDoubleAttributeAttributeSetterCallback, V8PrivateProperty::kNoCachedAccessor, static_cast<v8::PropertyAttribute>(v8::None), V8DOMConfiguration::kOnPrototype, V8DOMConfiguration::kCheckHolder, V8DOMConfiguration::kAllWorlds } -, - - { "unrestrictedFloatAttribute", V8TestObject::unrestrictedFloatAttributeAttributeGetterCallback, V8TestObject::unrestrictedFloatAttributeAttributeSetterCallback, V8PrivateProperty::kNoCachedAccessor, static_cast<v8::PropertyAttribute>(v8::None), V8DOMConfiguration::kOnPrototype, V8DOMConfiguration::kCheckHolder, V8DOMConfiguration::kAllWorlds } -, - - { "unsignedLongAttribute", V8TestObject::unsignedLongAttributeAttributeGetterCallback, V8TestObject::unsignedLongAttributeAttributeSetterCallback, V8PrivateProperty::kNoCachedAccessor, static_cast<v8::PropertyAttribute>(v8::None), V8DOMConfiguration::kOnPrototype, V8DOMConfiguration::kCheckHolder, V8DOMConfiguration::kAllWorlds } -, - - { "unsignedLongLongAttribute", V8TestObject::unsignedLongLongAttributeAttributeGetterCallback, V8TestObject::unsignedLongLongAttributeAttributeSetterCallback, V8PrivateProperty::kNoCachedAccessor, static_cast<v8::PropertyAttribute>(v8::None), V8DOMConfiguration::kOnPrototype, V8DOMConfiguration::kCheckHolder, V8DOMConfiguration::kAllWorlds } -, - - { "unsignedShortAttribute", V8TestObject::unsignedShortAttributeAttributeGetterCallback, V8TestObject::unsignedShortAttributeAttributeSetterCallback, V8PrivateProperty::kNoCachedAccessor, static_cast<v8::PropertyAttribute>(v8::None), V8DOMConfiguration::kOnPrototype, V8DOMConfiguration::kCheckHolder, V8DOMConfiguration::kAllWorlds } -, - - { "testInterfaceEmptyAttribute", V8TestObject::testInterfaceEmptyAttributeAttributeGetterCallback, V8TestObject::testInterfaceEmptyAttributeAttributeSetterCallback, V8PrivateProperty::kNoCachedAccessor, static_cast<v8::PropertyAttribute>(v8::None), V8DOMConfiguration::kOnPrototype, V8DOMConfiguration::kCheckHolder, V8DOMConfiguration::kAllWorlds } -, - - { "testObjectAttribute", V8TestObject::testObjectAttributeAttributeGetterCallback, V8TestObject::testObjectAttributeAttributeSetterCallback, V8PrivateProperty::kNoCachedAccessor, static_cast<v8::PropertyAttribute>(v8::None), V8DOMConfiguration::kOnPrototype, V8DOMConfiguration::kCheckHolder, V8DOMConfiguration::kAllWorlds } -, - - { "cssAttribute", V8TestObject::cssAttributeAttributeGetterCallback, V8TestObject::cssAttributeAttributeSetterCallback, V8PrivateProperty::kNoCachedAccessor, static_cast<v8::PropertyAttribute>(v8::None), V8DOMConfiguration::kOnPrototype, V8DOMConfiguration::kCheckHolder, V8DOMConfiguration::kAllWorlds } -, - - { "imeAttribute", V8TestObject::imeAttributeAttributeGetterCallback, V8TestObject::imeAttributeAttributeSetterCallback, V8PrivateProperty::kNoCachedAccessor, static_cast<v8::PropertyAttribute>(v8::None), V8DOMConfiguration::kOnPrototype, V8DOMConfiguration::kCheckHolder, V8DOMConfiguration::kAllWorlds } -, - - { "svgAttribute", V8TestObject::svgAttributeAttributeGetterCallback, V8TestObject::svgAttributeAttributeSetterCallback, V8PrivateProperty::kNoCachedAccessor, static_cast<v8::PropertyAttribute>(v8::None), V8DOMConfiguration::kOnPrototype, V8DOMConfiguration::kCheckHolder, V8DOMConfiguration::kAllWorlds } -, - - { "xmlAttribute", V8TestObject::xmlAttributeAttributeGetterCallback, V8TestObject::xmlAttributeAttributeSetterCallback, V8PrivateProperty::kNoCachedAccessor, static_cast<v8::PropertyAttribute>(v8::None), V8DOMConfiguration::kOnPrototype, V8DOMConfiguration::kCheckHolder, V8DOMConfiguration::kAllWorlds } -, - - { "nodeFilterAttribute", V8TestObject::nodeFilterAttributeAttributeGetterCallback, V8TestObject::nodeFilterAttributeAttributeSetterCallback, V8PrivateProperty::kNoCachedAccessor, static_cast<v8::PropertyAttribute>(v8::None), V8DOMConfiguration::kOnPrototype, V8DOMConfiguration::kCheckHolder, V8DOMConfiguration::kAllWorlds } -, - - { "serializedScriptValueAttribute", V8TestObject::serializedScriptValueAttributeAttributeGetterCallback, V8TestObject::serializedScriptValueAttributeAttributeSetterCallback, V8PrivateProperty::kNoCachedAccessor, static_cast<v8::PropertyAttribute>(v8::None), V8DOMConfiguration::kOnPrototype, V8DOMConfiguration::kCheckHolder, V8DOMConfiguration::kAllWorlds } -, - - { "anyAttribute", V8TestObject::anyAttributeAttributeGetterCallback, V8TestObject::anyAttributeAttributeSetterCallback, V8PrivateProperty::kNoCachedAccessor, static_cast<v8::PropertyAttribute>(v8::None), V8DOMConfiguration::kOnPrototype, V8DOMConfiguration::kCheckHolder, V8DOMConfiguration::kAllWorlds } -, - - { "promiseAttribute", V8TestObject::promiseAttributeAttributeGetterCallback, V8TestObject::promiseAttributeAttributeSetterCallback, V8PrivateProperty::kNoCachedAccessor, static_cast<v8::PropertyAttribute>(v8::None), V8DOMConfiguration::kOnPrototype, V8DOMConfiguration::kDoNotCheckHolder, V8DOMConfiguration::kAllWorlds } -, - - { "windowAttribute", V8TestObject::windowAttributeAttributeGetterCallback, V8TestObject::windowAttributeAttributeSetterCallback, V8PrivateProperty::kNoCachedAccessor, static_cast<v8::PropertyAttribute>(v8::None), V8DOMConfiguration::kOnPrototype, V8DOMConfiguration::kCheckHolder, V8DOMConfiguration::kAllWorlds } -, - - { "documentAttribute", V8TestObject::documentAttributeAttributeGetterCallback, V8TestObject::documentAttributeAttributeSetterCallback, V8PrivateProperty::kNoCachedAccessor, static_cast<v8::PropertyAttribute>(v8::None), V8DOMConfiguration::kOnPrototype, V8DOMConfiguration::kCheckHolder, V8DOMConfiguration::kAllWorlds } -, - - { "documentFragmentAttribute", V8TestObject::documentFragmentAttributeAttributeGetterCallback, V8TestObject::documentFragmentAttributeAttributeSetterCallback, V8PrivateProperty::kNoCachedAccessor, static_cast<v8::PropertyAttribute>(v8::None), V8DOMConfiguration::kOnPrototype, V8DOMConfiguration::kCheckHolder, V8DOMConfiguration::kAllWorlds } -, - - { "documentTypeAttribute", V8TestObject::documentTypeAttributeAttributeGetterCallback, V8TestObject::documentTypeAttributeAttributeSetterCallback, V8PrivateProperty::kNoCachedAccessor, static_cast<v8::PropertyAttribute>(v8::None), V8DOMConfiguration::kOnPrototype, V8DOMConfiguration::kCheckHolder, V8DOMConfiguration::kAllWorlds } -, - - { "elementAttribute", V8TestObject::elementAttributeAttributeGetterCallback, V8TestObject::elementAttributeAttributeSetterCallback, V8PrivateProperty::kNoCachedAccessor, static_cast<v8::PropertyAttribute>(v8::None), V8DOMConfiguration::kOnPrototype, V8DOMConfiguration::kCheckHolder, V8DOMConfiguration::kAllWorlds } -, - - { "nodeAttribute", V8TestObject::nodeAttributeAttributeGetterCallback, V8TestObject::nodeAttributeAttributeSetterCallback, V8PrivateProperty::kNoCachedAccessor, static_cast<v8::PropertyAttribute>(v8::None), V8DOMConfiguration::kOnPrototype, V8DOMConfiguration::kCheckHolder, V8DOMConfiguration::kAllWorlds } -, - - { "shadowRootAttribute", V8TestObject::shadowRootAttributeAttributeGetterCallback, V8TestObject::shadowRootAttributeAttributeSetterCallback, V8PrivateProperty::kNoCachedAccessor, static_cast<v8::PropertyAttribute>(v8::None), V8DOMConfiguration::kOnPrototype, V8DOMConfiguration::kCheckHolder, V8DOMConfiguration::kAllWorlds } -, - - { "arrayBufferAttribute", V8TestObject::arrayBufferAttributeAttributeGetterCallback, V8TestObject::arrayBufferAttributeAttributeSetterCallback, V8PrivateProperty::kNoCachedAccessor, static_cast<v8::PropertyAttribute>(v8::None), V8DOMConfiguration::kOnPrototype, V8DOMConfiguration::kCheckHolder, V8DOMConfiguration::kAllWorlds } -, - - { "float32ArrayAttribute", V8TestObject::float32ArrayAttributeAttributeGetterCallback, V8TestObject::float32ArrayAttributeAttributeSetterCallback, V8PrivateProperty::kNoCachedAccessor, static_cast<v8::PropertyAttribute>(v8::None), V8DOMConfiguration::kOnPrototype, V8DOMConfiguration::kCheckHolder, V8DOMConfiguration::kAllWorlds } -, - - { "uint8ArrayAttribute", V8TestObject::uint8ArrayAttributeAttributeGetterCallback, V8TestObject::uint8ArrayAttributeAttributeSetterCallback, V8PrivateProperty::kNoCachedAccessor, static_cast<v8::PropertyAttribute>(v8::None), V8DOMConfiguration::kOnPrototype, V8DOMConfiguration::kCheckHolder, V8DOMConfiguration::kAllWorlds } -, - - { "self", V8TestObject::selfAttributeGetterCallback, nullptr, V8PrivateProperty::kNoCachedAccessor, static_cast<v8::PropertyAttribute>(v8::ReadOnly), V8DOMConfiguration::kOnPrototype, V8DOMConfiguration::kCheckHolder, V8DOMConfiguration::kAllWorlds } -, - - { "readonlyEventTargetAttribute", V8TestObject::readonlyEventTargetAttributeAttributeGetterCallback, nullptr, V8PrivateProperty::kNoCachedAccessor, static_cast<v8::PropertyAttribute>(v8::ReadOnly), V8DOMConfiguration::kOnPrototype, V8DOMConfiguration::kCheckHolder, V8DOMConfiguration::kAllWorlds } -, - - { "readonlyEventTargetOrNullAttribute", V8TestObject::readonlyEventTargetOrNullAttributeAttributeGetterCallback, nullptr, V8PrivateProperty::kNoCachedAccessor, static_cast<v8::PropertyAttribute>(v8::ReadOnly), V8DOMConfiguration::kOnPrototype, V8DOMConfiguration::kCheckHolder, V8DOMConfiguration::kAllWorlds } -, - - { "readonlyWindowAttribute", V8TestObject::readonlyWindowAttributeAttributeGetterCallback, nullptr, V8PrivateProperty::kNoCachedAccessor, static_cast<v8::PropertyAttribute>(v8::ReadOnly), V8DOMConfiguration::kOnPrototype, V8DOMConfiguration::kCheckHolder, V8DOMConfiguration::kAllWorlds } -, - - { "htmlCollectionAttribute", V8TestObject::htmlCollectionAttributeAttributeGetterCallback, nullptr, V8PrivateProperty::kNoCachedAccessor, static_cast<v8::PropertyAttribute>(v8::ReadOnly), V8DOMConfiguration::kOnPrototype, V8DOMConfiguration::kCheckHolder, V8DOMConfiguration::kAllWorlds } -, - - { "htmlElementAttribute", V8TestObject::htmlElementAttributeAttributeGetterCallback, nullptr, V8PrivateProperty::kNoCachedAccessor, static_cast<v8::PropertyAttribute>(v8::ReadOnly), V8DOMConfiguration::kOnPrototype, V8DOMConfiguration::kCheckHolder, V8DOMConfiguration::kAllWorlds } -, - - { "stringFrozenArrayAttribute", V8TestObject::stringFrozenArrayAttributeAttributeGetterCallback, V8TestObject::stringFrozenArrayAttributeAttributeSetterCallback, V8PrivateProperty::kNoCachedAccessor, static_cast<v8::PropertyAttribute>(v8::None), V8DOMConfiguration::kOnPrototype, V8DOMConfiguration::kCheckHolder, V8DOMConfiguration::kAllWorlds } -, - - { "testInterfaceEmptyFrozenArrayAttribute", V8TestObject::testInterfaceEmptyFrozenArrayAttributeAttributeGetterCallback, V8TestObject::testInterfaceEmptyFrozenArrayAttributeAttributeSetterCallback, V8PrivateProperty::kNoCachedAccessor, static_cast<v8::PropertyAttribute>(v8::None), V8DOMConfiguration::kOnPrototype, V8DOMConfiguration::kCheckHolder, V8DOMConfiguration::kAllWorlds } -, - - { "booleanOrNullAttribute", V8TestObject::booleanOrNullAttributeAttributeGetterCallback, V8TestObject::booleanOrNullAttributeAttributeSetterCallback, V8PrivateProperty::kNoCachedAccessor, static_cast<v8::PropertyAttribute>(v8::None), V8DOMConfiguration::kOnPrototype, V8DOMConfiguration::kCheckHolder, V8DOMConfiguration::kAllWorlds } -, - - { "stringOrNullAttribute", V8TestObject::stringOrNullAttributeAttributeGetterCallback, V8TestObject::stringOrNullAttributeAttributeSetterCallback, V8PrivateProperty::kNoCachedAccessor, static_cast<v8::PropertyAttribute>(v8::None), V8DOMConfiguration::kOnPrototype, V8DOMConfiguration::kCheckHolder, V8DOMConfiguration::kAllWorlds } -, - - { "longOrNullAttribute", V8TestObject::longOrNullAttributeAttributeGetterCallback, V8TestObject::longOrNullAttributeAttributeSetterCallback, V8PrivateProperty::kNoCachedAccessor, static_cast<v8::PropertyAttribute>(v8::None), V8DOMConfiguration::kOnPrototype, V8DOMConfiguration::kCheckHolder, V8DOMConfiguration::kAllWorlds } -, - - { "testInterfaceOrNullAttribute", V8TestObject::testInterfaceOrNullAttributeAttributeGetterCallback, V8TestObject::testInterfaceOrNullAttributeAttributeSetterCallback, V8PrivateProperty::kNoCachedAccessor, static_cast<v8::PropertyAttribute>(v8::None), V8DOMConfiguration::kOnPrototype, V8DOMConfiguration::kCheckHolder, V8DOMConfiguration::kAllWorlds } -, - - { "testEnumAttribute", V8TestObject::testEnumAttributeAttributeGetterCallback, V8TestObject::testEnumAttributeAttributeSetterCallback, V8PrivateProperty::kNoCachedAccessor, static_cast<v8::PropertyAttribute>(v8::None), V8DOMConfiguration::kOnPrototype, V8DOMConfiguration::kCheckHolder, V8DOMConfiguration::kAllWorlds } -, - - { "testEnumOrNullAttribute", V8TestObject::testEnumOrNullAttributeAttributeGetterCallback, V8TestObject::testEnumOrNullAttributeAttributeSetterCallback, V8PrivateProperty::kNoCachedAccessor, static_cast<v8::PropertyAttribute>(v8::None), V8DOMConfiguration::kOnPrototype, V8DOMConfiguration::kCheckHolder, V8DOMConfiguration::kAllWorlds } -, - - { "staticStringAttribute", V8TestObject::staticStringAttributeAttributeGetterCallback, V8TestObject::staticStringAttributeAttributeSetterCallback, V8PrivateProperty::kNoCachedAccessor, static_cast<v8::PropertyAttribute>(v8::None), V8DOMConfiguration::kOnInterface, V8DOMConfiguration::kCheckHolder, V8DOMConfiguration::kAllWorlds } -, - - { "staticLongAttribute", V8TestObject::staticLongAttributeAttributeGetterCallback, V8TestObject::staticLongAttributeAttributeSetterCallback, V8PrivateProperty::kNoCachedAccessor, static_cast<v8::PropertyAttribute>(v8::None), V8DOMConfiguration::kOnInterface, V8DOMConfiguration::kCheckHolder, V8DOMConfiguration::kAllWorlds } -, - - { "eventHandlerAttribute", V8TestObject::eventHandlerAttributeAttributeGetterCallback, V8TestObject::eventHandlerAttributeAttributeSetterCallback, V8PrivateProperty::kNoCachedAccessor, static_cast<v8::PropertyAttribute>(v8::None), V8DOMConfiguration::kOnPrototype, V8DOMConfiguration::kCheckHolder, V8DOMConfiguration::kAllWorlds } -, - - { "doubleOrStringAttribute", V8TestObject::doubleOrStringAttributeAttributeGetterCallback, V8TestObject::doubleOrStringAttributeAttributeSetterCallback, V8PrivateProperty::kNoCachedAccessor, static_cast<v8::PropertyAttribute>(v8::None), V8DOMConfiguration::kOnPrototype, V8DOMConfiguration::kCheckHolder, V8DOMConfiguration::kAllWorlds } -, - - { "doubleOrStringOrNullAttribute", V8TestObject::doubleOrStringOrNullAttributeAttributeGetterCallback, V8TestObject::doubleOrStringOrNullAttributeAttributeSetterCallback, V8PrivateProperty::kNoCachedAccessor, static_cast<v8::PropertyAttribute>(v8::None), V8DOMConfiguration::kOnPrototype, V8DOMConfiguration::kCheckHolder, V8DOMConfiguration::kAllWorlds } -, - - { "doubleOrNullStringAttribute", V8TestObject::doubleOrNullStringAttributeAttributeGetterCallback, V8TestObject::doubleOrNullStringAttributeAttributeSetterCallback, V8PrivateProperty::kNoCachedAccessor, static_cast<v8::PropertyAttribute>(v8::None), V8DOMConfiguration::kOnPrototype, V8DOMConfiguration::kCheckHolder, V8DOMConfiguration::kAllWorlds } -, - - { "stringOrStringSequenceAttribute", V8TestObject::stringOrStringSequenceAttributeAttributeGetterCallback, V8TestObject::stringOrStringSequenceAttributeAttributeSetterCallback, V8PrivateProperty::kNoCachedAccessor, static_cast<v8::PropertyAttribute>(v8::None), V8DOMConfiguration::kOnPrototype, V8DOMConfiguration::kCheckHolder, V8DOMConfiguration::kAllWorlds } -, - - { "testEnumOrDoubleAttribute", V8TestObject::testEnumOrDoubleAttributeAttributeGetterCallback, V8TestObject::testEnumOrDoubleAttributeAttributeSetterCallback, V8PrivateProperty::kNoCachedAccessor, static_cast<v8::PropertyAttribute>(v8::None), V8DOMConfiguration::kOnPrototype, V8DOMConfiguration::kCheckHolder, V8DOMConfiguration::kAllWorlds } -, - - { "unrestrictedDoubleOrStringAttribute", V8TestObject::unrestrictedDoubleOrStringAttributeAttributeGetterCallback, V8TestObject::unrestrictedDoubleOrStringAttributeAttributeSetterCallback, V8PrivateProperty::kNoCachedAccessor, static_cast<v8::PropertyAttribute>(v8::None), V8DOMConfiguration::kOnPrototype, V8DOMConfiguration::kCheckHolder, V8DOMConfiguration::kAllWorlds } -, - - { "nestedUnionAtribute", V8TestObject::nestedUnionAtributeAttributeGetterCallback, V8TestObject::nestedUnionAtributeAttributeSetterCallback, V8PrivateProperty::kNoCachedAccessor, static_cast<v8::PropertyAttribute>(v8::None), V8DOMConfiguration::kOnPrototype, V8DOMConfiguration::kCheckHolder, V8DOMConfiguration::kAllWorlds } -, - - { "activityLoggingAccessForAllWorldsLongAttribute", V8TestObject::activityLoggingAccessForAllWorldsLongAttributeAttributeGetterCallback, V8TestObject::activityLoggingAccessForAllWorldsLongAttributeAttributeSetterCallback, V8PrivateProperty::kNoCachedAccessor, static_cast<v8::PropertyAttribute>(v8::None), V8DOMConfiguration::kOnPrototype, V8DOMConfiguration::kCheckHolder, V8DOMConfiguration::kAllWorlds } -, - - { "activityLoggingGetterForAllWorldsLongAttribute", V8TestObject::activityLoggingGetterForAllWorldsLongAttributeAttributeGetterCallback, V8TestObject::activityLoggingGetterForAllWorldsLongAttributeAttributeSetterCallback, V8PrivateProperty::kNoCachedAccessor, static_cast<v8::PropertyAttribute>(v8::None), V8DOMConfiguration::kOnPrototype, V8DOMConfiguration::kCheckHolder, V8DOMConfiguration::kAllWorlds } -, - - { "activityLoggingSetterForAllWorldsLongAttribute", V8TestObject::activityLoggingSetterForAllWorldsLongAttributeAttributeGetterCallback, V8TestObject::activityLoggingSetterForAllWorldsLongAttributeAttributeSetterCallback, V8PrivateProperty::kNoCachedAccessor, static_cast<v8::PropertyAttribute>(v8::None), V8DOMConfiguration::kOnPrototype, V8DOMConfiguration::kCheckHolder, V8DOMConfiguration::kAllWorlds } -, - - { "cachedAttributeAnyAttribute", V8TestObject::cachedAttributeAnyAttributeAttributeGetterCallback, V8TestObject::cachedAttributeAnyAttributeAttributeSetterCallback, V8PrivateProperty::kNoCachedAccessor, static_cast<v8::PropertyAttribute>(v8::None), V8DOMConfiguration::kOnPrototype, V8DOMConfiguration::kCheckHolder, V8DOMConfiguration::kAllWorlds } -, - - { "cachedArrayAttribute", V8TestObject::cachedArrayAttributeAttributeGetterCallback, V8TestObject::cachedArrayAttributeAttributeSetterCallback, V8PrivateProperty::kNoCachedAccessor, static_cast<v8::PropertyAttribute>(v8::None), V8DOMConfiguration::kOnPrototype, V8DOMConfiguration::kCheckHolder, V8DOMConfiguration::kAllWorlds } -, - - { "cachedStringOrNoneAttribute", V8TestObject::cachedStringOrNoneAttributeAttributeGetterCallback, V8TestObject::cachedStringOrNoneAttributeAttributeSetterCallback, V8PrivateProperty::kNoCachedAccessor, static_cast<v8::PropertyAttribute>(v8::None), V8DOMConfiguration::kOnPrototype, V8DOMConfiguration::kCheckHolder, V8DOMConfiguration::kAllWorlds } -, - - { "callWithExecutionContextAnyAttribute", V8TestObject::callWithExecutionContextAnyAttributeAttributeGetterCallback, V8TestObject::callWithExecutionContextAnyAttributeAttributeSetterCallback, V8PrivateProperty::kNoCachedAccessor, static_cast<v8::PropertyAttribute>(v8::None), V8DOMConfiguration::kOnPrototype, V8DOMConfiguration::kCheckHolder, V8DOMConfiguration::kAllWorlds } -, - - { "callWithScriptStateAnyAttribute", V8TestObject::callWithScriptStateAnyAttributeAttributeGetterCallback, V8TestObject::callWithScriptStateAnyAttributeAttributeSetterCallback, V8PrivateProperty::kNoCachedAccessor, static_cast<v8::PropertyAttribute>(v8::None), V8DOMConfiguration::kOnPrototype, V8DOMConfiguration::kCheckHolder, V8DOMConfiguration::kAllWorlds } -, - - { "callWithExecutionContextAndScriptStateAnyAttribute", V8TestObject::callWithExecutionContextAndScriptStateAnyAttributeAttributeGetterCallback, V8TestObject::callWithExecutionContextAndScriptStateAnyAttributeAttributeSetterCallback, V8PrivateProperty::kNoCachedAccessor, static_cast<v8::PropertyAttribute>(v8::None), V8DOMConfiguration::kOnPrototype, V8DOMConfiguration::kCheckHolder, V8DOMConfiguration::kAllWorlds } -, - - { "checkSecurityForNodeReadonlyDocumentAttribute", V8TestObject::checkSecurityForNodeReadonlyDocumentAttributeAttributeGetterCallback, nullptr, V8PrivateProperty::kNoCachedAccessor, static_cast<v8::PropertyAttribute>(v8::ReadOnly), V8DOMConfiguration::kOnPrototype, V8DOMConfiguration::kCheckHolder, V8DOMConfiguration::kAllWorlds } -, - - { "customObjectAttribute", V8TestObject::customObjectAttributeAttributeGetterCallback, V8TestObject::customObjectAttributeAttributeSetterCallback, V8PrivateProperty::kNoCachedAccessor, static_cast<v8::PropertyAttribute>(v8::None), V8DOMConfiguration::kOnPrototype, V8DOMConfiguration::kCheckHolder, V8DOMConfiguration::kAllWorlds } -, - - { "customGetterLongAttribute", V8TestObject::customGetterLongAttributeAttributeGetterCallback, V8TestObject::customGetterLongAttributeAttributeSetterCallback, V8PrivateProperty::kNoCachedAccessor, static_cast<v8::PropertyAttribute>(v8::None), V8DOMConfiguration::kOnPrototype, V8DOMConfiguration::kCheckHolder, V8DOMConfiguration::kAllWorlds } -, - - { "customGetterReadonlyObjectAttribute", V8TestObject::customGetterReadonlyObjectAttributeAttributeGetterCallback, nullptr, V8PrivateProperty::kNoCachedAccessor, static_cast<v8::PropertyAttribute>(v8::ReadOnly), V8DOMConfiguration::kOnPrototype, V8DOMConfiguration::kCheckHolder, V8DOMConfiguration::kAllWorlds } -, - - { "customSetterLongAttribute", V8TestObject::customSetterLongAttributeAttributeGetterCallback, V8TestObject::customSetterLongAttributeAttributeSetterCallback, V8PrivateProperty::kNoCachedAccessor, static_cast<v8::PropertyAttribute>(v8::None), V8DOMConfiguration::kOnPrototype, V8DOMConfiguration::kCheckHolder, V8DOMConfiguration::kAllWorlds } -, - - { "deprecatedLongAttribute", V8TestObject::deprecatedLongAttributeAttributeGetterCallback, V8TestObject::deprecatedLongAttributeAttributeSetterCallback, V8PrivateProperty::kNoCachedAccessor, static_cast<v8::PropertyAttribute>(v8::None), V8DOMConfiguration::kOnPrototype, V8DOMConfiguration::kCheckHolder, V8DOMConfiguration::kAllWorlds } -, - - { "enforceRangeLongAttribute", V8TestObject::enforceRangeLongAttributeAttributeGetterCallback, V8TestObject::enforceRangeLongAttributeAttributeSetterCallback, V8PrivateProperty::kNoCachedAccessor, static_cast<v8::PropertyAttribute>(v8::None), V8DOMConfiguration::kOnPrototype, V8DOMConfiguration::kCheckHolder, V8DOMConfiguration::kAllWorlds } -, - - { "implementedAsLongAttribute", V8TestObject::implementedAsLongAttributeAttributeGetterCallback, V8TestObject::implementedAsLongAttributeAttributeSetterCallback, V8PrivateProperty::kNoCachedAccessor, static_cast<v8::PropertyAttribute>(v8::None), V8DOMConfiguration::kOnPrototype, V8DOMConfiguration::kCheckHolder, V8DOMConfiguration::kAllWorlds } -, - - { "customImplementedAsLongAttribute", V8TestObject::customImplementedAsLongAttributeAttributeGetterCallback, V8TestObject::customImplementedAsLongAttributeAttributeSetterCallback, V8PrivateProperty::kNoCachedAccessor, static_cast<v8::PropertyAttribute>(v8::None), V8DOMConfiguration::kOnPrototype, V8DOMConfiguration::kCheckHolder, V8DOMConfiguration::kAllWorlds } -, - - { "customGetterImplementedAsLongAttribute", V8TestObject::customGetterImplementedAsLongAttributeAttributeGetterCallback, V8TestObject::customGetterImplementedAsLongAttributeAttributeSetterCallback, V8PrivateProperty::kNoCachedAccessor, static_cast<v8::PropertyAttribute>(v8::None), V8DOMConfiguration::kOnPrototype, V8DOMConfiguration::kCheckHolder, V8DOMConfiguration::kAllWorlds } -, - - { "customSetterImplementedAsLongAttribute", V8TestObject::customSetterImplementedAsLongAttributeAttributeGetterCallback, V8TestObject::customSetterImplementedAsLongAttributeAttributeSetterCallback, V8PrivateProperty::kNoCachedAccessor, static_cast<v8::PropertyAttribute>(v8::None), V8DOMConfiguration::kOnPrototype, V8DOMConfiguration::kCheckHolder, V8DOMConfiguration::kAllWorlds } -, - - { "measureAsLongAttribute", V8TestObject::measureAsLongAttributeAttributeGetterCallback, V8TestObject::measureAsLongAttributeAttributeSetterCallback, V8PrivateProperty::kNoCachedAccessor, static_cast<v8::PropertyAttribute>(v8::None), V8DOMConfiguration::kOnPrototype, V8DOMConfiguration::kCheckHolder, V8DOMConfiguration::kAllWorlds } -, - - { "notEnumerableLongAttribute", V8TestObject::notEnumerableLongAttributeAttributeGetterCallback, V8TestObject::notEnumerableLongAttributeAttributeSetterCallback, V8PrivateProperty::kNoCachedAccessor, static_cast<v8::PropertyAttribute>(v8::DontEnum), V8DOMConfiguration::kOnPrototype, V8DOMConfiguration::kCheckHolder, V8DOMConfiguration::kAllWorlds } -, - + { "stringifierAttribute", V8TestObject::stringifierAttributeAttributeGetterCallback, V8TestObject::stringifierAttributeAttributeSetterCallback, V8PrivateProperty::kNoCachedAccessor, static_cast<v8::PropertyAttribute>(v8::None), V8DOMConfiguration::kOnPrototype, V8DOMConfiguration::kCheckHolder, V8DOMConfiguration::kAllWorlds }, + { "readonlyStringAttribute", V8TestObject::readonlyStringAttributeAttributeGetterCallback, nullptr, V8PrivateProperty::kNoCachedAccessor, static_cast<v8::PropertyAttribute>(v8::ReadOnly), V8DOMConfiguration::kOnPrototype, V8DOMConfiguration::kCheckHolder, V8DOMConfiguration::kAllWorlds }, + { "readonlyTestInterfaceEmptyAttribute", V8TestObject::readonlyTestInterfaceEmptyAttributeAttributeGetterCallback, nullptr, V8PrivateProperty::kNoCachedAccessor, static_cast<v8::PropertyAttribute>(v8::ReadOnly), V8DOMConfiguration::kOnPrototype, V8DOMConfiguration::kCheckHolder, V8DOMConfiguration::kAllWorlds }, + { "readonlyLongAttribute", V8TestObject::readonlyLongAttributeAttributeGetterCallback, nullptr, V8PrivateProperty::kNoCachedAccessor, static_cast<v8::PropertyAttribute>(v8::ReadOnly), V8DOMConfiguration::kOnPrototype, V8DOMConfiguration::kCheckHolder, V8DOMConfiguration::kAllWorlds }, + { "dateAttribute", V8TestObject::dateAttributeAttributeGetterCallback, V8TestObject::dateAttributeAttributeSetterCallback, V8PrivateProperty::kNoCachedAccessor, static_cast<v8::PropertyAttribute>(v8::None), V8DOMConfiguration::kOnPrototype, V8DOMConfiguration::kCheckHolder, V8DOMConfiguration::kAllWorlds }, + { "stringAttribute", V8TestObject::stringAttributeAttributeGetterCallback, V8TestObject::stringAttributeAttributeSetterCallback, V8PrivateProperty::kNoCachedAccessor, static_cast<v8::PropertyAttribute>(v8::None), V8DOMConfiguration::kOnPrototype, V8DOMConfiguration::kCheckHolder, V8DOMConfiguration::kAllWorlds }, + { "byteStringAttribute", V8TestObject::byteStringAttributeAttributeGetterCallback, V8TestObject::byteStringAttributeAttributeSetterCallback, V8PrivateProperty::kNoCachedAccessor, static_cast<v8::PropertyAttribute>(v8::None), V8DOMConfiguration::kOnPrototype, V8DOMConfiguration::kCheckHolder, V8DOMConfiguration::kAllWorlds }, + { "usvStringAttribute", V8TestObject::usvStringAttributeAttributeGetterCallback, V8TestObject::usvStringAttributeAttributeSetterCallback, V8PrivateProperty::kNoCachedAccessor, static_cast<v8::PropertyAttribute>(v8::None), V8DOMConfiguration::kOnPrototype, V8DOMConfiguration::kCheckHolder, V8DOMConfiguration::kAllWorlds }, + { "domTimeStampAttribute", V8TestObject::domTimeStampAttributeAttributeGetterCallback, V8TestObject::domTimeStampAttributeAttributeSetterCallback, V8PrivateProperty::kNoCachedAccessor, static_cast<v8::PropertyAttribute>(v8::None), V8DOMConfiguration::kOnPrototype, V8DOMConfiguration::kCheckHolder, V8DOMConfiguration::kAllWorlds }, + { "booleanAttribute", V8TestObject::booleanAttributeAttributeGetterCallback, V8TestObject::booleanAttributeAttributeSetterCallback, V8PrivateProperty::kNoCachedAccessor, static_cast<v8::PropertyAttribute>(v8::None), V8DOMConfiguration::kOnPrototype, V8DOMConfiguration::kCheckHolder, V8DOMConfiguration::kAllWorlds }, + { "byteAttribute", V8TestObject::byteAttributeAttributeGetterCallback, V8TestObject::byteAttributeAttributeSetterCallback, V8PrivateProperty::kNoCachedAccessor, static_cast<v8::PropertyAttribute>(v8::None), V8DOMConfiguration::kOnPrototype, V8DOMConfiguration::kCheckHolder, V8DOMConfiguration::kAllWorlds }, + { "doubleAttribute", V8TestObject::doubleAttributeAttributeGetterCallback, V8TestObject::doubleAttributeAttributeSetterCallback, V8PrivateProperty::kNoCachedAccessor, static_cast<v8::PropertyAttribute>(v8::None), V8DOMConfiguration::kOnPrototype, V8DOMConfiguration::kCheckHolder, V8DOMConfiguration::kAllWorlds }, + { "floatAttribute", V8TestObject::floatAttributeAttributeGetterCallback, V8TestObject::floatAttributeAttributeSetterCallback, V8PrivateProperty::kNoCachedAccessor, static_cast<v8::PropertyAttribute>(v8::None), V8DOMConfiguration::kOnPrototype, V8DOMConfiguration::kCheckHolder, V8DOMConfiguration::kAllWorlds }, + { "longAttribute", V8TestObject::longAttributeAttributeGetterCallback, V8TestObject::longAttributeAttributeSetterCallback, V8PrivateProperty::kNoCachedAccessor, static_cast<v8::PropertyAttribute>(v8::None), V8DOMConfiguration::kOnPrototype, V8DOMConfiguration::kCheckHolder, V8DOMConfiguration::kAllWorlds }, + { "longLongAttribute", V8TestObject::longLongAttributeAttributeGetterCallback, V8TestObject::longLongAttributeAttributeSetterCallback, V8PrivateProperty::kNoCachedAccessor, static_cast<v8::PropertyAttribute>(v8::None), V8DOMConfiguration::kOnPrototype, V8DOMConfiguration::kCheckHolder, V8DOMConfiguration::kAllWorlds }, + { "octetAttribute", V8TestObject::octetAttributeAttributeGetterCallback, V8TestObject::octetAttributeAttributeSetterCallback, V8PrivateProperty::kNoCachedAccessor, static_cast<v8::PropertyAttribute>(v8::None), V8DOMConfiguration::kOnPrototype, V8DOMConfiguration::kCheckHolder, V8DOMConfiguration::kAllWorlds }, + { "shortAttribute", V8TestObject::shortAttributeAttributeGetterCallback, V8TestObject::shortAttributeAttributeSetterCallback, V8PrivateProperty::kNoCachedAccessor, static_cast<v8::PropertyAttribute>(v8::None), V8DOMConfiguration::kOnPrototype, V8DOMConfiguration::kCheckHolder, V8DOMConfiguration::kAllWorlds }, + { "unrestrictedDoubleAttribute", V8TestObject::unrestrictedDoubleAttributeAttributeGetterCallback, V8TestObject::unrestrictedDoubleAttributeAttributeSetterCallback, V8PrivateProperty::kNoCachedAccessor, static_cast<v8::PropertyAttribute>(v8::None), V8DOMConfiguration::kOnPrototype, V8DOMConfiguration::kCheckHolder, V8DOMConfiguration::kAllWorlds }, + { "unrestrictedFloatAttribute", V8TestObject::unrestrictedFloatAttributeAttributeGetterCallback, V8TestObject::unrestrictedFloatAttributeAttributeSetterCallback, V8PrivateProperty::kNoCachedAccessor, static_cast<v8::PropertyAttribute>(v8::None), V8DOMConfiguration::kOnPrototype, V8DOMConfiguration::kCheckHolder, V8DOMConfiguration::kAllWorlds }, + { "unsignedLongAttribute", V8TestObject::unsignedLongAttributeAttributeGetterCallback, V8TestObject::unsignedLongAttributeAttributeSetterCallback, V8PrivateProperty::kNoCachedAccessor, static_cast<v8::PropertyAttribute>(v8::None), V8DOMConfiguration::kOnPrototype, V8DOMConfiguration::kCheckHolder, V8DOMConfiguration::kAllWorlds }, + { "unsignedLongLongAttribute", V8TestObject::unsignedLongLongAttributeAttributeGetterCallback, V8TestObject::unsignedLongLongAttributeAttributeSetterCallback, V8PrivateProperty::kNoCachedAccessor, static_cast<v8::PropertyAttribute>(v8::None), V8DOMConfiguration::kOnPrototype, V8DOMConfiguration::kCheckHolder, V8DOMConfiguration::kAllWorlds }, + { "unsignedShortAttribute", V8TestObject::unsignedShortAttributeAttributeGetterCallback, V8TestObject::unsignedShortAttributeAttributeSetterCallback, V8PrivateProperty::kNoCachedAccessor, static_cast<v8::PropertyAttribute>(v8::None), V8DOMConfiguration::kOnPrototype, V8DOMConfiguration::kCheckHolder, V8DOMConfiguration::kAllWorlds }, + { "testInterfaceEmptyAttribute", V8TestObject::testInterfaceEmptyAttributeAttributeGetterCallback, V8TestObject::testInterfaceEmptyAttributeAttributeSetterCallback, V8PrivateProperty::kNoCachedAccessor, static_cast<v8::PropertyAttribute>(v8::None), V8DOMConfiguration::kOnPrototype, V8DOMConfiguration::kCheckHolder, V8DOMConfiguration::kAllWorlds }, + { "testObjectAttribute", V8TestObject::testObjectAttributeAttributeGetterCallback, V8TestObject::testObjectAttributeAttributeSetterCallback, V8PrivateProperty::kNoCachedAccessor, static_cast<v8::PropertyAttribute>(v8::None), V8DOMConfiguration::kOnPrototype, V8DOMConfiguration::kCheckHolder, V8DOMConfiguration::kAllWorlds }, + { "cssAttribute", V8TestObject::cssAttributeAttributeGetterCallback, V8TestObject::cssAttributeAttributeSetterCallback, V8PrivateProperty::kNoCachedAccessor, static_cast<v8::PropertyAttribute>(v8::None), V8DOMConfiguration::kOnPrototype, V8DOMConfiguration::kCheckHolder, V8DOMConfiguration::kAllWorlds }, + { "imeAttribute", V8TestObject::imeAttributeAttributeGetterCallback, V8TestObject::imeAttributeAttributeSetterCallback, V8PrivateProperty::kNoCachedAccessor, static_cast<v8::PropertyAttribute>(v8::None), V8DOMConfiguration::kOnPrototype, V8DOMConfiguration::kCheckHolder, V8DOMConfiguration::kAllWorlds }, + { "svgAttribute", V8TestObject::svgAttributeAttributeGetterCallback, V8TestObject::svgAttributeAttributeSetterCallback, V8PrivateProperty::kNoCachedAccessor, static_cast<v8::PropertyAttribute>(v8::None), V8DOMConfiguration::kOnPrototype, V8DOMConfiguration::kCheckHolder, V8DOMConfiguration::kAllWorlds }, + { "xmlAttribute", V8TestObject::xmlAttributeAttributeGetterCallback, V8TestObject::xmlAttributeAttributeSetterCallback, V8PrivateProperty::kNoCachedAccessor, static_cast<v8::PropertyAttribute>(v8::None), V8DOMConfiguration::kOnPrototype, V8DOMConfiguration::kCheckHolder, V8DOMConfiguration::kAllWorlds }, + { "nodeFilterAttribute", V8TestObject::nodeFilterAttributeAttributeGetterCallback, V8TestObject::nodeFilterAttributeAttributeSetterCallback, V8PrivateProperty::kNoCachedAccessor, static_cast<v8::PropertyAttribute>(v8::None), V8DOMConfiguration::kOnPrototype, V8DOMConfiguration::kCheckHolder, V8DOMConfiguration::kAllWorlds }, + { "serializedScriptValueAttribute", V8TestObject::serializedScriptValueAttributeAttributeGetterCallback, V8TestObject::serializedScriptValueAttributeAttributeSetterCallback, V8PrivateProperty::kNoCachedAccessor, static_cast<v8::PropertyAttribute>(v8::None), V8DOMConfiguration::kOnPrototype, V8DOMConfiguration::kCheckHolder, V8DOMConfiguration::kAllWorlds }, + { "anyAttribute", V8TestObject::anyAttributeAttributeGetterCallback, V8TestObject::anyAttributeAttributeSetterCallback, V8PrivateProperty::kNoCachedAccessor, static_cast<v8::PropertyAttribute>(v8::None), V8DOMConfiguration::kOnPrototype, V8DOMConfiguration::kCheckHolder, V8DOMConfiguration::kAllWorlds }, + { "promiseAttribute", V8TestObject::promiseAttributeAttributeGetterCallback, V8TestObject::promiseAttributeAttributeSetterCallback, V8PrivateProperty::kNoCachedAccessor, static_cast<v8::PropertyAttribute>(v8::None), V8DOMConfiguration::kOnPrototype, V8DOMConfiguration::kDoNotCheckHolder, V8DOMConfiguration::kAllWorlds }, + { "windowAttribute", V8TestObject::windowAttributeAttributeGetterCallback, V8TestObject::windowAttributeAttributeSetterCallback, V8PrivateProperty::kNoCachedAccessor, static_cast<v8::PropertyAttribute>(v8::None), V8DOMConfiguration::kOnPrototype, V8DOMConfiguration::kCheckHolder, V8DOMConfiguration::kAllWorlds }, + { "documentAttribute", V8TestObject::documentAttributeAttributeGetterCallback, V8TestObject::documentAttributeAttributeSetterCallback, V8PrivateProperty::kNoCachedAccessor, static_cast<v8::PropertyAttribute>(v8::None), V8DOMConfiguration::kOnPrototype, V8DOMConfiguration::kCheckHolder, V8DOMConfiguration::kAllWorlds }, + { "documentFragmentAttribute", V8TestObject::documentFragmentAttributeAttributeGetterCallback, V8TestObject::documentFragmentAttributeAttributeSetterCallback, V8PrivateProperty::kNoCachedAccessor, static_cast<v8::PropertyAttribute>(v8::None), V8DOMConfiguration::kOnPrototype, V8DOMConfiguration::kCheckHolder, V8DOMConfiguration::kAllWorlds }, + { "documentTypeAttribute", V8TestObject::documentTypeAttributeAttributeGetterCallback, V8TestObject::documentTypeAttributeAttributeSetterCallback, V8PrivateProperty::kNoCachedAccessor, static_cast<v8::PropertyAttribute>(v8::None), V8DOMConfiguration::kOnPrototype, V8DOMConfiguration::kCheckHolder, V8DOMConfiguration::kAllWorlds }, + { "elementAttribute", V8TestObject::elementAttributeAttributeGetterCallback, V8TestObject::elementAttributeAttributeSetterCallback, V8PrivateProperty::kNoCachedAccessor, static_cast<v8::PropertyAttribute>(v8::None), V8DOMConfiguration::kOnPrototype, V8DOMConfiguration::kCheckHolder, V8DOMConfiguration::kAllWorlds }, + { "nodeAttribute", V8TestObject::nodeAttributeAttributeGetterCallback, V8TestObject::nodeAttributeAttributeSetterCallback, V8PrivateProperty::kNoCachedAccessor, static_cast<v8::PropertyAttribute>(v8::None), V8DOMConfiguration::kOnPrototype, V8DOMConfiguration::kCheckHolder, V8DOMConfiguration::kAllWorlds }, + { "shadowRootAttribute", V8TestObject::shadowRootAttributeAttributeGetterCallback, V8TestObject::shadowRootAttributeAttributeSetterCallback, V8PrivateProperty::kNoCachedAccessor, static_cast<v8::PropertyAttribute>(v8::None), V8DOMConfiguration::kOnPrototype, V8DOMConfiguration::kCheckHolder, V8DOMConfiguration::kAllWorlds }, + { "arrayBufferAttribute", V8TestObject::arrayBufferAttributeAttributeGetterCallback, V8TestObject::arrayBufferAttributeAttributeSetterCallback, V8PrivateProperty::kNoCachedAccessor, static_cast<v8::PropertyAttribute>(v8::None), V8DOMConfiguration::kOnPrototype, V8DOMConfiguration::kCheckHolder, V8DOMConfiguration::kAllWorlds }, + { "float32ArrayAttribute", V8TestObject::float32ArrayAttributeAttributeGetterCallback, V8TestObject::float32ArrayAttributeAttributeSetterCallback, V8PrivateProperty::kNoCachedAccessor, static_cast<v8::PropertyAttribute>(v8::None), V8DOMConfiguration::kOnPrototype, V8DOMConfiguration::kCheckHolder, V8DOMConfiguration::kAllWorlds }, + { "uint8ArrayAttribute", V8TestObject::uint8ArrayAttributeAttributeGetterCallback, V8TestObject::uint8ArrayAttributeAttributeSetterCallback, V8PrivateProperty::kNoCachedAccessor, static_cast<v8::PropertyAttribute>(v8::None), V8DOMConfiguration::kOnPrototype, V8DOMConfiguration::kCheckHolder, V8DOMConfiguration::kAllWorlds }, + { "self", V8TestObject::selfAttributeGetterCallback, nullptr, V8PrivateProperty::kNoCachedAccessor, static_cast<v8::PropertyAttribute>(v8::ReadOnly), V8DOMConfiguration::kOnPrototype, V8DOMConfiguration::kCheckHolder, V8DOMConfiguration::kAllWorlds }, + { "readonlyEventTargetAttribute", V8TestObject::readonlyEventTargetAttributeAttributeGetterCallback, nullptr, V8PrivateProperty::kNoCachedAccessor, static_cast<v8::PropertyAttribute>(v8::ReadOnly), V8DOMConfiguration::kOnPrototype, V8DOMConfiguration::kCheckHolder, V8DOMConfiguration::kAllWorlds }, + { "readonlyEventTargetOrNullAttribute", V8TestObject::readonlyEventTargetOrNullAttributeAttributeGetterCallback, nullptr, V8PrivateProperty::kNoCachedAccessor, static_cast<v8::PropertyAttribute>(v8::ReadOnly), V8DOMConfiguration::kOnPrototype, V8DOMConfiguration::kCheckHolder, V8DOMConfiguration::kAllWorlds }, + { "readonlyWindowAttribute", V8TestObject::readonlyWindowAttributeAttributeGetterCallback, nullptr, V8PrivateProperty::kNoCachedAccessor, static_cast<v8::PropertyAttribute>(v8::ReadOnly), V8DOMConfiguration::kOnPrototype, V8DOMConfiguration::kCheckHolder, V8DOMConfiguration::kAllWorlds }, + { "htmlCollectionAttribute", V8TestObject::htmlCollectionAttributeAttributeGetterCallback, nullptr, V8PrivateProperty::kNoCachedAccessor, static_cast<v8::PropertyAttribute>(v8::ReadOnly), V8DOMConfiguration::kOnPrototype, V8DOMConfiguration::kCheckHolder, V8DOMConfiguration::kAllWorlds }, + { "htmlElementAttribute", V8TestObject::htmlElementAttributeAttributeGetterCallback, nullptr, V8PrivateProperty::kNoCachedAccessor, static_cast<v8::PropertyAttribute>(v8::ReadOnly), V8DOMConfiguration::kOnPrototype, V8DOMConfiguration::kCheckHolder, V8DOMConfiguration::kAllWorlds }, + { "stringFrozenArrayAttribute", V8TestObject::stringFrozenArrayAttributeAttributeGetterCallback, V8TestObject::stringFrozenArrayAttributeAttributeSetterCallback, V8PrivateProperty::kNoCachedAccessor, static_cast<v8::PropertyAttribute>(v8::None), V8DOMConfiguration::kOnPrototype, V8DOMConfiguration::kCheckHolder, V8DOMConfiguration::kAllWorlds }, + { "testInterfaceEmptyFrozenArrayAttribute", V8TestObject::testInterfaceEmptyFrozenArrayAttributeAttributeGetterCallback, V8TestObject::testInterfaceEmptyFrozenArrayAttributeAttributeSetterCallback, V8PrivateProperty::kNoCachedAccessor, static_cast<v8::PropertyAttribute>(v8::None), V8DOMConfiguration::kOnPrototype, V8DOMConfiguration::kCheckHolder, V8DOMConfiguration::kAllWorlds }, + { "booleanOrNullAttribute", V8TestObject::booleanOrNullAttributeAttributeGetterCallback, V8TestObject::booleanOrNullAttributeAttributeSetterCallback, V8PrivateProperty::kNoCachedAccessor, static_cast<v8::PropertyAttribute>(v8::None), V8DOMConfiguration::kOnPrototype, V8DOMConfiguration::kCheckHolder, V8DOMConfiguration::kAllWorlds }, + { "stringOrNullAttribute", V8TestObject::stringOrNullAttributeAttributeGetterCallback, V8TestObject::stringOrNullAttributeAttributeSetterCallback, V8PrivateProperty::kNoCachedAccessor, static_cast<v8::PropertyAttribute>(v8::None), V8DOMConfiguration::kOnPrototype, V8DOMConfiguration::kCheckHolder, V8DOMConfiguration::kAllWorlds }, + { "longOrNullAttribute", V8TestObject::longOrNullAttributeAttributeGetterCallback, V8TestObject::longOrNullAttributeAttributeSetterCallback, V8PrivateProperty::kNoCachedAccessor, static_cast<v8::PropertyAttribute>(v8::None), V8DOMConfiguration::kOnPrototype, V8DOMConfiguration::kCheckHolder, V8DOMConfiguration::kAllWorlds }, + { "testInterfaceOrNullAttribute", V8TestObject::testInterfaceOrNullAttributeAttributeGetterCallback, V8TestObject::testInterfaceOrNullAttributeAttributeSetterCallback, V8PrivateProperty::kNoCachedAccessor, static_cast<v8::PropertyAttribute>(v8::None), V8DOMConfiguration::kOnPrototype, V8DOMConfiguration::kCheckHolder, V8DOMConfiguration::kAllWorlds }, + { "testEnumAttribute", V8TestObject::testEnumAttributeAttributeGetterCallback, V8TestObject::testEnumAttributeAttributeSetterCallback, V8PrivateProperty::kNoCachedAccessor, static_cast<v8::PropertyAttribute>(v8::None), V8DOMConfiguration::kOnPrototype, V8DOMConfiguration::kCheckHolder, V8DOMConfiguration::kAllWorlds }, + { "testEnumOrNullAttribute", V8TestObject::testEnumOrNullAttributeAttributeGetterCallback, V8TestObject::testEnumOrNullAttributeAttributeSetterCallback, V8PrivateProperty::kNoCachedAccessor, static_cast<v8::PropertyAttribute>(v8::None), V8DOMConfiguration::kOnPrototype, V8DOMConfiguration::kCheckHolder, V8DOMConfiguration::kAllWorlds }, + { "staticStringAttribute", V8TestObject::staticStringAttributeAttributeGetterCallback, V8TestObject::staticStringAttributeAttributeSetterCallback, V8PrivateProperty::kNoCachedAccessor, static_cast<v8::PropertyAttribute>(v8::None), V8DOMConfiguration::kOnInterface, V8DOMConfiguration::kCheckHolder, V8DOMConfiguration::kAllWorlds }, + { "staticLongAttribute", V8TestObject::staticLongAttributeAttributeGetterCallback, V8TestObject::staticLongAttributeAttributeSetterCallback, V8PrivateProperty::kNoCachedAccessor, static_cast<v8::PropertyAttribute>(v8::None), V8DOMConfiguration::kOnInterface, V8DOMConfiguration::kCheckHolder, V8DOMConfiguration::kAllWorlds }, + { "eventHandlerAttribute", V8TestObject::eventHandlerAttributeAttributeGetterCallback, V8TestObject::eventHandlerAttributeAttributeSetterCallback, V8PrivateProperty::kNoCachedAccessor, static_cast<v8::PropertyAttribute>(v8::None), V8DOMConfiguration::kOnPrototype, V8DOMConfiguration::kCheckHolder, V8DOMConfiguration::kAllWorlds }, + { "doubleOrStringAttribute", V8TestObject::doubleOrStringAttributeAttributeGetterCallback, V8TestObject::doubleOrStringAttributeAttributeSetterCallback, V8PrivateProperty::kNoCachedAccessor, static_cast<v8::PropertyAttribute>(v8::None), V8DOMConfiguration::kOnPrototype, V8DOMConfiguration::kCheckHolder, V8DOMConfiguration::kAllWorlds }, + { "doubleOrStringOrNullAttribute", V8TestObject::doubleOrStringOrNullAttributeAttributeGetterCallback, V8TestObject::doubleOrStringOrNullAttributeAttributeSetterCallback, V8PrivateProperty::kNoCachedAccessor, static_cast<v8::PropertyAttribute>(v8::None), V8DOMConfiguration::kOnPrototype, V8DOMConfiguration::kCheckHolder, V8DOMConfiguration::kAllWorlds }, + { "doubleOrNullStringAttribute", V8TestObject::doubleOrNullStringAttributeAttributeGetterCallback, V8TestObject::doubleOrNullStringAttributeAttributeSetterCallback, V8PrivateProperty::kNoCachedAccessor, static_cast<v8::PropertyAttribute>(v8::None), V8DOMConfiguration::kOnPrototype, V8DOMConfiguration::kCheckHolder, V8DOMConfiguration::kAllWorlds }, + { "stringOrStringSequenceAttribute", V8TestObject::stringOrStringSequenceAttributeAttributeGetterCallback, V8TestObject::stringOrStringSequenceAttributeAttributeSetterCallback, V8PrivateProperty::kNoCachedAccessor, static_cast<v8::PropertyAttribute>(v8::None), V8DOMConfiguration::kOnPrototype, V8DOMConfiguration::kCheckHolder, V8DOMConfiguration::kAllWorlds }, + { "testEnumOrDoubleAttribute", V8TestObject::testEnumOrDoubleAttributeAttributeGetterCallback, V8TestObject::testEnumOrDoubleAttributeAttributeSetterCallback, V8PrivateProperty::kNoCachedAccessor, static_cast<v8::PropertyAttribute>(v8::None), V8DOMConfiguration::kOnPrototype, V8DOMConfiguration::kCheckHolder, V8DOMConfiguration::kAllWorlds }, + { "unrestrictedDoubleOrStringAttribute", V8TestObject::unrestrictedDoubleOrStringAttributeAttributeGetterCallback, V8TestObject::unrestrictedDoubleOrStringAttributeAttributeSetterCallback, V8PrivateProperty::kNoCachedAccessor, static_cast<v8::PropertyAttribute>(v8::None), V8DOMConfiguration::kOnPrototype, V8DOMConfiguration::kCheckHolder, V8DOMConfiguration::kAllWorlds }, + { "nestedUnionAtribute", V8TestObject::nestedUnionAtributeAttributeGetterCallback, V8TestObject::nestedUnionAtributeAttributeSetterCallback, V8PrivateProperty::kNoCachedAccessor, static_cast<v8::PropertyAttribute>(v8::None), V8DOMConfiguration::kOnPrototype, V8DOMConfiguration::kCheckHolder, V8DOMConfiguration::kAllWorlds }, + { "activityLoggingAccessForAllWorldsLongAttribute", V8TestObject::activityLoggingAccessForAllWorldsLongAttributeAttributeGetterCallback, V8TestObject::activityLoggingAccessForAllWorldsLongAttributeAttributeSetterCallback, V8PrivateProperty::kNoCachedAccessor, static_cast<v8::PropertyAttribute>(v8::None), V8DOMConfiguration::kOnPrototype, V8DOMConfiguration::kCheckHolder, V8DOMConfiguration::kAllWorlds }, + { "activityLoggingGetterForAllWorldsLongAttribute", V8TestObject::activityLoggingGetterForAllWorldsLongAttributeAttributeGetterCallback, V8TestObject::activityLoggingGetterForAllWorldsLongAttributeAttributeSetterCallback, V8PrivateProperty::kNoCachedAccessor, static_cast<v8::PropertyAttribute>(v8::None), V8DOMConfiguration::kOnPrototype, V8DOMConfiguration::kCheckHolder, V8DOMConfiguration::kAllWorlds }, + { "activityLoggingSetterForAllWorldsLongAttribute", V8TestObject::activityLoggingSetterForAllWorldsLongAttributeAttributeGetterCallback, V8TestObject::activityLoggingSetterForAllWorldsLongAttributeAttributeSetterCallback, V8PrivateProperty::kNoCachedAccessor, static_cast<v8::PropertyAttribute>(v8::None), V8DOMConfiguration::kOnPrototype, V8DOMConfiguration::kCheckHolder, V8DOMConfiguration::kAllWorlds }, + { "cachedAttributeAnyAttribute", V8TestObject::cachedAttributeAnyAttributeAttributeGetterCallback, V8TestObject::cachedAttributeAnyAttributeAttributeSetterCallback, V8PrivateProperty::kNoCachedAccessor, static_cast<v8::PropertyAttribute>(v8::None), V8DOMConfiguration::kOnPrototype, V8DOMConfiguration::kCheckHolder, V8DOMConfiguration::kAllWorlds }, + { "cachedArrayAttribute", V8TestObject::cachedArrayAttributeAttributeGetterCallback, V8TestObject::cachedArrayAttributeAttributeSetterCallback, V8PrivateProperty::kNoCachedAccessor, static_cast<v8::PropertyAttribute>(v8::None), V8DOMConfiguration::kOnPrototype, V8DOMConfiguration::kCheckHolder, V8DOMConfiguration::kAllWorlds }, + { "cachedStringOrNoneAttribute", V8TestObject::cachedStringOrNoneAttributeAttributeGetterCallback, V8TestObject::cachedStringOrNoneAttributeAttributeSetterCallback, V8PrivateProperty::kNoCachedAccessor, static_cast<v8::PropertyAttribute>(v8::None), V8DOMConfiguration::kOnPrototype, V8DOMConfiguration::kCheckHolder, V8DOMConfiguration::kAllWorlds }, + { "callWithExecutionContextAnyAttribute", V8TestObject::callWithExecutionContextAnyAttributeAttributeGetterCallback, V8TestObject::callWithExecutionContextAnyAttributeAttributeSetterCallback, V8PrivateProperty::kNoCachedAccessor, static_cast<v8::PropertyAttribute>(v8::None), V8DOMConfiguration::kOnPrototype, V8DOMConfiguration::kCheckHolder, V8DOMConfiguration::kAllWorlds }, + { "callWithScriptStateAnyAttribute", V8TestObject::callWithScriptStateAnyAttributeAttributeGetterCallback, V8TestObject::callWithScriptStateAnyAttributeAttributeSetterCallback, V8PrivateProperty::kNoCachedAccessor, static_cast<v8::PropertyAttribute>(v8::None), V8DOMConfiguration::kOnPrototype, V8DOMConfiguration::kCheckHolder, V8DOMConfiguration::kAllWorlds }, + { "callWithExecutionContextAndScriptStateAnyAttribute", V8TestObject::callWithExecutionContextAndScriptStateAnyAttributeAttributeGetterCallback, V8TestObject::callWithExecutionContextAndScriptStateAnyAttributeAttributeSetterCallback, V8PrivateProperty::kNoCachedAccessor, static_cast<v8::PropertyAttribute>(v8::None), V8DOMConfiguration::kOnPrototype, V8DOMConfiguration::kCheckHolder, V8DOMConfiguration::kAllWorlds }, + { "checkSecurityForNodeReadonlyDocumentAttribute", V8TestObject::checkSecurityForNodeReadonlyDocumentAttributeAttributeGetterCallback, nullptr, V8PrivateProperty::kNoCachedAccessor, static_cast<v8::PropertyAttribute>(v8::ReadOnly), V8DOMConfiguration::kOnPrototype, V8DOMConfiguration::kCheckHolder, V8DOMConfiguration::kAllWorlds }, + { "customObjectAttribute", V8TestObject::customObjectAttributeAttributeGetterCallback, V8TestObject::customObjectAttributeAttributeSetterCallback, V8PrivateProperty::kNoCachedAccessor, static_cast<v8::PropertyAttribute>(v8::None), V8DOMConfiguration::kOnPrototype, V8DOMConfiguration::kCheckHolder, V8DOMConfiguration::kAllWorlds }, + { "customGetterLongAttribute", V8TestObject::customGetterLongAttributeAttributeGetterCallback, V8TestObject::customGetterLongAttributeAttributeSetterCallback, V8PrivateProperty::kNoCachedAccessor, static_cast<v8::PropertyAttribute>(v8::None), V8DOMConfiguration::kOnPrototype, V8DOMConfiguration::kCheckHolder, V8DOMConfiguration::kAllWorlds }, + { "customGetterReadonlyObjectAttribute", V8TestObject::customGetterReadonlyObjectAttributeAttributeGetterCallback, nullptr, V8PrivateProperty::kNoCachedAccessor, static_cast<v8::PropertyAttribute>(v8::ReadOnly), V8DOMConfiguration::kOnPrototype, V8DOMConfiguration::kCheckHolder, V8DOMConfiguration::kAllWorlds }, + { "customSetterLongAttribute", V8TestObject::customSetterLongAttributeAttributeGetterCallback, V8TestObject::customSetterLongAttributeAttributeSetterCallback, V8PrivateProperty::kNoCachedAccessor, static_cast<v8::PropertyAttribute>(v8::None), V8DOMConfiguration::kOnPrototype, V8DOMConfiguration::kCheckHolder, V8DOMConfiguration::kAllWorlds }, + { "deprecatedLongAttribute", V8TestObject::deprecatedLongAttributeAttributeGetterCallback, V8TestObject::deprecatedLongAttributeAttributeSetterCallback, V8PrivateProperty::kNoCachedAccessor, static_cast<v8::PropertyAttribute>(v8::None), V8DOMConfiguration::kOnPrototype, V8DOMConfiguration::kCheckHolder, V8DOMConfiguration::kAllWorlds }, + { "enforceRangeLongAttribute", V8TestObject::enforceRangeLongAttributeAttributeGetterCallback, V8TestObject::enforceRangeLongAttributeAttributeSetterCallback, V8PrivateProperty::kNoCachedAccessor, static_cast<v8::PropertyAttribute>(v8::None), V8DOMConfiguration::kOnPrototype, V8DOMConfiguration::kCheckHolder, V8DOMConfiguration::kAllWorlds }, + { "implementedAsLongAttribute", V8TestObject::implementedAsLongAttributeAttributeGetterCallback, V8TestObject::implementedAsLongAttributeAttributeSetterCallback, V8PrivateProperty::kNoCachedAccessor, static_cast<v8::PropertyAttribute>(v8::None), V8DOMConfiguration::kOnPrototype, V8DOMConfiguration::kCheckHolder, V8DOMConfiguration::kAllWorlds }, + { "customImplementedAsLongAttribute", V8TestObject::customImplementedAsLongAttributeAttributeGetterCallback, V8TestObject::customImplementedAsLongAttributeAttributeSetterCallback, V8PrivateProperty::kNoCachedAccessor, static_cast<v8::PropertyAttribute>(v8::None), V8DOMConfiguration::kOnPrototype, V8DOMConfiguration::kCheckHolder, V8DOMConfiguration::kAllWorlds }, + { "customGetterImplementedAsLongAttribute", V8TestObject::customGetterImplementedAsLongAttributeAttributeGetterCallback, V8TestObject::customGetterImplementedAsLongAttributeAttributeSetterCallback, V8PrivateProperty::kNoCachedAccessor, static_cast<v8::PropertyAttribute>(v8::None), V8DOMConfiguration::kOnPrototype, V8DOMConfiguration::kCheckHolder, V8DOMConfiguration::kAllWorlds }, + { "customSetterImplementedAsLongAttribute", V8TestObject::customSetterImplementedAsLongAttributeAttributeGetterCallback, V8TestObject::customSetterImplementedAsLongAttributeAttributeSetterCallback, V8PrivateProperty::kNoCachedAccessor, static_cast<v8::PropertyAttribute>(v8::None), V8DOMConfiguration::kOnPrototype, V8DOMConfiguration::kCheckHolder, V8DOMConfiguration::kAllWorlds }, + { "measureAsLongAttribute", V8TestObject::measureAsLongAttributeAttributeGetterCallback, V8TestObject::measureAsLongAttributeAttributeSetterCallback, V8PrivateProperty::kNoCachedAccessor, static_cast<v8::PropertyAttribute>(v8::None), V8DOMConfiguration::kOnPrototype, V8DOMConfiguration::kCheckHolder, V8DOMConfiguration::kAllWorlds }, + { "notEnumerableLongAttribute", V8TestObject::notEnumerableLongAttributeAttributeGetterCallback, V8TestObject::notEnumerableLongAttributeAttributeSetterCallback, V8PrivateProperty::kNoCachedAccessor, static_cast<v8::PropertyAttribute>(v8::DontEnum), V8DOMConfiguration::kOnPrototype, V8DOMConfiguration::kCheckHolder, V8DOMConfiguration::kAllWorlds }, { "perWorldBindingsReadonlyTestInterfaceEmptyAttribute", V8TestObject::perWorldBindingsReadonlyTestInterfaceEmptyAttributeAttributeGetterCallbackForMainWorld, nullptr, V8PrivateProperty::kNoCachedAccessor, static_cast<v8::PropertyAttribute>(v8::ReadOnly), V8DOMConfiguration::kOnPrototype, V8DOMConfiguration::kCheckHolder, V8DOMConfiguration::kMainWorld }, - { "perWorldBindingsReadonlyTestInterfaceEmptyAttribute", V8TestObject::perWorldBindingsReadonlyTestInterfaceEmptyAttributeAttributeGetterCallback, nullptr, V8PrivateProperty::kNoCachedAccessor, static_cast<v8::PropertyAttribute>(v8::ReadOnly), V8DOMConfiguration::kOnPrototype, V8DOMConfiguration::kCheckHolder, V8DOMConfiguration::kNonMainWorlds } -, - + { "perWorldBindingsReadonlyTestInterfaceEmptyAttribute", V8TestObject::perWorldBindingsReadonlyTestInterfaceEmptyAttributeAttributeGetterCallback, nullptr, V8PrivateProperty::kNoCachedAccessor, static_cast<v8::PropertyAttribute>(v8::ReadOnly), V8DOMConfiguration::kOnPrototype, V8DOMConfiguration::kCheckHolder, V8DOMConfiguration::kNonMainWorlds }, { "activityLoggingAccessPerWorldBindingsLongAttribute", V8TestObject::activityLoggingAccessPerWorldBindingsLongAttributeAttributeGetterCallbackForMainWorld, V8TestObject::activityLoggingAccessPerWorldBindingsLongAttributeAttributeSetterCallbackForMainWorld, V8PrivateProperty::kNoCachedAccessor, static_cast<v8::PropertyAttribute>(v8::None), V8DOMConfiguration::kOnPrototype, V8DOMConfiguration::kCheckHolder, V8DOMConfiguration::kMainWorld }, - { "activityLoggingAccessPerWorldBindingsLongAttribute", V8TestObject::activityLoggingAccessPerWorldBindingsLongAttributeAttributeGetterCallback, V8TestObject::activityLoggingAccessPerWorldBindingsLongAttributeAttributeSetterCallback, V8PrivateProperty::kNoCachedAccessor, static_cast<v8::PropertyAttribute>(v8::None), V8DOMConfiguration::kOnPrototype, V8DOMConfiguration::kCheckHolder, V8DOMConfiguration::kNonMainWorlds } -, - + { "activityLoggingAccessPerWorldBindingsLongAttribute", V8TestObject::activityLoggingAccessPerWorldBindingsLongAttributeAttributeGetterCallback, V8TestObject::activityLoggingAccessPerWorldBindingsLongAttributeAttributeSetterCallback, V8PrivateProperty::kNoCachedAccessor, static_cast<v8::PropertyAttribute>(v8::None), V8DOMConfiguration::kOnPrototype, V8DOMConfiguration::kCheckHolder, V8DOMConfiguration::kNonMainWorlds }, { "activityLoggingAccessForIsolatedWorldsPerWorldBindingsLongAttribute", V8TestObject::activityLoggingAccessForIsolatedWorldsPerWorldBindingsLongAttributeAttributeGetterCallbackForMainWorld, V8TestObject::activityLoggingAccessForIsolatedWorldsPerWorldBindingsLongAttributeAttributeSetterCallbackForMainWorld, V8PrivateProperty::kNoCachedAccessor, static_cast<v8::PropertyAttribute>(v8::None), V8DOMConfiguration::kOnPrototype, V8DOMConfiguration::kCheckHolder, V8DOMConfiguration::kMainWorld }, - { "activityLoggingAccessForIsolatedWorldsPerWorldBindingsLongAttribute", V8TestObject::activityLoggingAccessForIsolatedWorldsPerWorldBindingsLongAttributeAttributeGetterCallback, V8TestObject::activityLoggingAccessForIsolatedWorldsPerWorldBindingsLongAttributeAttributeSetterCallback, V8PrivateProperty::kNoCachedAccessor, static_cast<v8::PropertyAttribute>(v8::None), V8DOMConfiguration::kOnPrototype, V8DOMConfiguration::kCheckHolder, V8DOMConfiguration::kNonMainWorlds } -, - + { "activityLoggingAccessForIsolatedWorldsPerWorldBindingsLongAttribute", V8TestObject::activityLoggingAccessForIsolatedWorldsPerWorldBindingsLongAttributeAttributeGetterCallback, V8TestObject::activityLoggingAccessForIsolatedWorldsPerWorldBindingsLongAttributeAttributeSetterCallback, V8PrivateProperty::kNoCachedAccessor, static_cast<v8::PropertyAttribute>(v8::None), V8DOMConfiguration::kOnPrototype, V8DOMConfiguration::kCheckHolder, V8DOMConfiguration::kNonMainWorlds }, { "activityLoggingGetterPerWorldBindingsLongAttribute", V8TestObject::activityLoggingGetterPerWorldBindingsLongAttributeAttributeGetterCallbackForMainWorld, V8TestObject::activityLoggingGetterPerWorldBindingsLongAttributeAttributeSetterCallbackForMainWorld, V8PrivateProperty::kNoCachedAccessor, static_cast<v8::PropertyAttribute>(v8::None), V8DOMConfiguration::kOnPrototype, V8DOMConfiguration::kCheckHolder, V8DOMConfiguration::kMainWorld }, - { "activityLoggingGetterPerWorldBindingsLongAttribute", V8TestObject::activityLoggingGetterPerWorldBindingsLongAttributeAttributeGetterCallback, V8TestObject::activityLoggingGetterPerWorldBindingsLongAttributeAttributeSetterCallback, V8PrivateProperty::kNoCachedAccessor, static_cast<v8::PropertyAttribute>(v8::None), V8DOMConfiguration::kOnPrototype, V8DOMConfiguration::kCheckHolder, V8DOMConfiguration::kNonMainWorlds } -, - + { "activityLoggingGetterPerWorldBindingsLongAttribute", V8TestObject::activityLoggingGetterPerWorldBindingsLongAttributeAttributeGetterCallback, V8TestObject::activityLoggingGetterPerWorldBindingsLongAttributeAttributeSetterCallback, V8PrivateProperty::kNoCachedAccessor, static_cast<v8::PropertyAttribute>(v8::None), V8DOMConfiguration::kOnPrototype, V8DOMConfiguration::kCheckHolder, V8DOMConfiguration::kNonMainWorlds }, { "activityLoggingGetterForIsolatedWorldsPerWorldBindingsLongAttribute", V8TestObject::activityLoggingGetterForIsolatedWorldsPerWorldBindingsLongAttributeAttributeGetterCallbackForMainWorld, V8TestObject::activityLoggingGetterForIsolatedWorldsPerWorldBindingsLongAttributeAttributeSetterCallbackForMainWorld, V8PrivateProperty::kNoCachedAccessor, static_cast<v8::PropertyAttribute>(v8::None), V8DOMConfiguration::kOnPrototype, V8DOMConfiguration::kCheckHolder, V8DOMConfiguration::kMainWorld }, - { "activityLoggingGetterForIsolatedWorldsPerWorldBindingsLongAttribute", V8TestObject::activityLoggingGetterForIsolatedWorldsPerWorldBindingsLongAttributeAttributeGetterCallback, V8TestObject::activityLoggingGetterForIsolatedWorldsPerWorldBindingsLongAttributeAttributeSetterCallback, V8PrivateProperty::kNoCachedAccessor, static_cast<v8::PropertyAttribute>(v8::None), V8DOMConfiguration::kOnPrototype, V8DOMConfiguration::kCheckHolder, V8DOMConfiguration::kNonMainWorlds } -, - - { "location", V8TestObject::locationAttributeGetterCallback, V8TestObject::locationAttributeSetterCallback, V8PrivateProperty::kNoCachedAccessor, static_cast<v8::PropertyAttribute>(v8::None), V8DOMConfiguration::kOnPrototype, V8DOMConfiguration::kCheckHolder, V8DOMConfiguration::kAllWorlds } -, - - { "locationWithException", V8TestObject::locationWithExceptionAttributeGetterCallback, V8TestObject::locationWithExceptionAttributeSetterCallback, V8PrivateProperty::kNoCachedAccessor, static_cast<v8::PropertyAttribute>(v8::None), V8DOMConfiguration::kOnPrototype, V8DOMConfiguration::kCheckHolder, V8DOMConfiguration::kAllWorlds } -, - - { "locationWithCallWith", V8TestObject::locationWithCallWithAttributeGetterCallback, V8TestObject::locationWithCallWithAttributeSetterCallback, V8PrivateProperty::kNoCachedAccessor, static_cast<v8::PropertyAttribute>(v8::None), V8DOMConfiguration::kOnPrototype, V8DOMConfiguration::kCheckHolder, V8DOMConfiguration::kAllWorlds } -, - - { "locationByteString", V8TestObject::locationByteStringAttributeGetterCallback, V8TestObject::locationByteStringAttributeSetterCallback, V8PrivateProperty::kNoCachedAccessor, static_cast<v8::PropertyAttribute>(v8::None), V8DOMConfiguration::kOnPrototype, V8DOMConfiguration::kCheckHolder, V8DOMConfiguration::kAllWorlds } -, - + { "activityLoggingGetterForIsolatedWorldsPerWorldBindingsLongAttribute", V8TestObject::activityLoggingGetterForIsolatedWorldsPerWorldBindingsLongAttributeAttributeGetterCallback, V8TestObject::activityLoggingGetterForIsolatedWorldsPerWorldBindingsLongAttributeAttributeSetterCallback, V8PrivateProperty::kNoCachedAccessor, static_cast<v8::PropertyAttribute>(v8::None), V8DOMConfiguration::kOnPrototype, V8DOMConfiguration::kCheckHolder, V8DOMConfiguration::kNonMainWorlds }, + { "location", V8TestObject::locationAttributeGetterCallback, V8TestObject::locationAttributeSetterCallback, V8PrivateProperty::kNoCachedAccessor, static_cast<v8::PropertyAttribute>(v8::None), V8DOMConfiguration::kOnPrototype, V8DOMConfiguration::kCheckHolder, V8DOMConfiguration::kAllWorlds }, + { "locationWithException", V8TestObject::locationWithExceptionAttributeGetterCallback, V8TestObject::locationWithExceptionAttributeSetterCallback, V8PrivateProperty::kNoCachedAccessor, static_cast<v8::PropertyAttribute>(v8::None), V8DOMConfiguration::kOnPrototype, V8DOMConfiguration::kCheckHolder, V8DOMConfiguration::kAllWorlds }, + { "locationWithCallWith", V8TestObject::locationWithCallWithAttributeGetterCallback, V8TestObject::locationWithCallWithAttributeSetterCallback, V8PrivateProperty::kNoCachedAccessor, static_cast<v8::PropertyAttribute>(v8::None), V8DOMConfiguration::kOnPrototype, V8DOMConfiguration::kCheckHolder, V8DOMConfiguration::kAllWorlds }, + { "locationByteString", V8TestObject::locationByteStringAttributeGetterCallback, V8TestObject::locationByteStringAttributeSetterCallback, V8PrivateProperty::kNoCachedAccessor, static_cast<v8::PropertyAttribute>(v8::None), V8DOMConfiguration::kOnPrototype, V8DOMConfiguration::kCheckHolder, V8DOMConfiguration::kAllWorlds }, { "locationWithPerWorldBindings", V8TestObject::locationWithPerWorldBindingsAttributeGetterCallbackForMainWorld, V8TestObject::locationWithPerWorldBindingsAttributeSetterCallbackForMainWorld, V8PrivateProperty::kNoCachedAccessor, static_cast<v8::PropertyAttribute>(v8::None), V8DOMConfiguration::kOnPrototype, V8DOMConfiguration::kCheckHolder, V8DOMConfiguration::kMainWorld }, - { "locationWithPerWorldBindings", V8TestObject::locationWithPerWorldBindingsAttributeGetterCallback, V8TestObject::locationWithPerWorldBindingsAttributeSetterCallback, V8PrivateProperty::kNoCachedAccessor, static_cast<v8::PropertyAttribute>(v8::None), V8DOMConfiguration::kOnPrototype, V8DOMConfiguration::kCheckHolder, V8DOMConfiguration::kNonMainWorlds } -, - - { "locationLegacyInterfaceTypeChecking", V8TestObject::locationLegacyInterfaceTypeCheckingAttributeGetterCallback, V8TestObject::locationLegacyInterfaceTypeCheckingAttributeSetterCallback, V8PrivateProperty::kNoCachedAccessor, static_cast<v8::PropertyAttribute>(v8::None), V8DOMConfiguration::kOnPrototype, V8DOMConfiguration::kCheckHolder, V8DOMConfiguration::kAllWorlds } -, - - { "locationGarbageCollected", V8TestObject::locationGarbageCollectedAttributeGetterCallback, V8TestObject::locationGarbageCollectedAttributeSetterCallback, V8PrivateProperty::kNoCachedAccessor, static_cast<v8::PropertyAttribute>(v8::None), V8DOMConfiguration::kOnPrototype, V8DOMConfiguration::kCheckHolder, V8DOMConfiguration::kAllWorlds } -, - - { "raisesExceptionLongAttribute", V8TestObject::raisesExceptionLongAttributeAttributeGetterCallback, V8TestObject::raisesExceptionLongAttributeAttributeSetterCallback, V8PrivateProperty::kNoCachedAccessor, static_cast<v8::PropertyAttribute>(v8::None), V8DOMConfiguration::kOnPrototype, V8DOMConfiguration::kCheckHolder, V8DOMConfiguration::kAllWorlds } -, - - { "raisesExceptionGetterLongAttribute", V8TestObject::raisesExceptionGetterLongAttributeAttributeGetterCallback, V8TestObject::raisesExceptionGetterLongAttributeAttributeSetterCallback, V8PrivateProperty::kNoCachedAccessor, static_cast<v8::PropertyAttribute>(v8::None), V8DOMConfiguration::kOnPrototype, V8DOMConfiguration::kCheckHolder, V8DOMConfiguration::kAllWorlds } -, - - { "setterRaisesExceptionLongAttribute", V8TestObject::setterRaisesExceptionLongAttributeAttributeGetterCallback, V8TestObject::setterRaisesExceptionLongAttributeAttributeSetterCallback, V8PrivateProperty::kNoCachedAccessor, static_cast<v8::PropertyAttribute>(v8::None), V8DOMConfiguration::kOnPrototype, V8DOMConfiguration::kCheckHolder, V8DOMConfiguration::kAllWorlds } -, - - { "raisesExceptionTestInterfaceEmptyAttribute", V8TestObject::raisesExceptionTestInterfaceEmptyAttributeAttributeGetterCallback, V8TestObject::raisesExceptionTestInterfaceEmptyAttributeAttributeSetterCallback, V8PrivateProperty::kNoCachedAccessor, static_cast<v8::PropertyAttribute>(v8::None), V8DOMConfiguration::kOnPrototype, V8DOMConfiguration::kCheckHolder, V8DOMConfiguration::kAllWorlds } -, - - { "cachedAttributeRaisesExceptionGetterAnyAttribute", V8TestObject::cachedAttributeRaisesExceptionGetterAnyAttributeAttributeGetterCallback, V8TestObject::cachedAttributeRaisesExceptionGetterAnyAttributeAttributeSetterCallback, V8PrivateProperty::kNoCachedAccessor, static_cast<v8::PropertyAttribute>(v8::None), V8DOMConfiguration::kOnPrototype, V8DOMConfiguration::kCheckHolder, V8DOMConfiguration::kAllWorlds } -, - - { "reflectTestInterfaceAttribute", V8TestObject::reflectTestInterfaceAttributeAttributeGetterCallback, V8TestObject::reflectTestInterfaceAttributeAttributeSetterCallback, V8PrivateProperty::kNoCachedAccessor, static_cast<v8::PropertyAttribute>(v8::None), V8DOMConfiguration::kOnPrototype, V8DOMConfiguration::kCheckHolder, V8DOMConfiguration::kAllWorlds } -, - - { "reflectReflectedNameAttributeTestAttribute", V8TestObject::reflectReflectedNameAttributeTestAttributeAttributeGetterCallback, V8TestObject::reflectReflectedNameAttributeTestAttributeAttributeSetterCallback, V8PrivateProperty::kNoCachedAccessor, static_cast<v8::PropertyAttribute>(v8::None), V8DOMConfiguration::kOnPrototype, V8DOMConfiguration::kCheckHolder, V8DOMConfiguration::kAllWorlds } -, - - { "reflectBooleanAttribute", V8TestObject::reflectBooleanAttributeAttributeGetterCallback, V8TestObject::reflectBooleanAttributeAttributeSetterCallback, V8PrivateProperty::kNoCachedAccessor, static_cast<v8::PropertyAttribute>(v8::None), V8DOMConfiguration::kOnPrototype, V8DOMConfiguration::kCheckHolder, V8DOMConfiguration::kAllWorlds } -, - - { "reflectLongAttribute", V8TestObject::reflectLongAttributeAttributeGetterCallback, V8TestObject::reflectLongAttributeAttributeSetterCallback, V8PrivateProperty::kNoCachedAccessor, static_cast<v8::PropertyAttribute>(v8::None), V8DOMConfiguration::kOnPrototype, V8DOMConfiguration::kCheckHolder, V8DOMConfiguration::kAllWorlds } -, - - { "reflectUnsignedShortAttribute", V8TestObject::reflectUnsignedShortAttributeAttributeGetterCallback, V8TestObject::reflectUnsignedShortAttributeAttributeSetterCallback, V8PrivateProperty::kNoCachedAccessor, static_cast<v8::PropertyAttribute>(v8::None), V8DOMConfiguration::kOnPrototype, V8DOMConfiguration::kCheckHolder, V8DOMConfiguration::kAllWorlds } -, - - { "reflectUnsignedLongAttribute", V8TestObject::reflectUnsignedLongAttributeAttributeGetterCallback, V8TestObject::reflectUnsignedLongAttributeAttributeSetterCallback, V8PrivateProperty::kNoCachedAccessor, static_cast<v8::PropertyAttribute>(v8::None), V8DOMConfiguration::kOnPrototype, V8DOMConfiguration::kCheckHolder, V8DOMConfiguration::kAllWorlds } -, - - { "id", V8TestObject::idAttributeGetterCallback, V8TestObject::idAttributeSetterCallback, V8PrivateProperty::kNoCachedAccessor, static_cast<v8::PropertyAttribute>(v8::None), V8DOMConfiguration::kOnPrototype, V8DOMConfiguration::kCheckHolder, V8DOMConfiguration::kAllWorlds } -, - - { "name", V8TestObject::nameAttributeGetterCallback, V8TestObject::nameAttributeSetterCallback, V8PrivateProperty::kNoCachedAccessor, static_cast<v8::PropertyAttribute>(v8::None), V8DOMConfiguration::kOnPrototype, V8DOMConfiguration::kCheckHolder, V8DOMConfiguration::kAllWorlds } -, - - { "class", V8TestObject::classAttributeGetterCallback, V8TestObject::classAttributeSetterCallback, V8PrivateProperty::kNoCachedAccessor, static_cast<v8::PropertyAttribute>(v8::None), V8DOMConfiguration::kOnPrototype, V8DOMConfiguration::kCheckHolder, V8DOMConfiguration::kAllWorlds } -, - - { "reflectedId", V8TestObject::reflectedIdAttributeGetterCallback, V8TestObject::reflectedIdAttributeSetterCallback, V8PrivateProperty::kNoCachedAccessor, static_cast<v8::PropertyAttribute>(v8::None), V8DOMConfiguration::kOnPrototype, V8DOMConfiguration::kCheckHolder, V8DOMConfiguration::kAllWorlds } -, - - { "reflectedName", V8TestObject::reflectedNameAttributeGetterCallback, V8TestObject::reflectedNameAttributeSetterCallback, V8PrivateProperty::kNoCachedAccessor, static_cast<v8::PropertyAttribute>(v8::None), V8DOMConfiguration::kOnPrototype, V8DOMConfiguration::kCheckHolder, V8DOMConfiguration::kAllWorlds } -, - - { "reflectedClass", V8TestObject::reflectedClassAttributeGetterCallback, V8TestObject::reflectedClassAttributeSetterCallback, V8PrivateProperty::kNoCachedAccessor, static_cast<v8::PropertyAttribute>(v8::None), V8DOMConfiguration::kOnPrototype, V8DOMConfiguration::kCheckHolder, V8DOMConfiguration::kAllWorlds } -, - - { "limitedToOnlyOneAttribute", V8TestObject::limitedToOnlyOneAttributeAttributeGetterCallback, V8TestObject::limitedToOnlyOneAttributeAttributeSetterCallback, V8PrivateProperty::kNoCachedAccessor, static_cast<v8::PropertyAttribute>(v8::None), V8DOMConfiguration::kOnPrototype, V8DOMConfiguration::kCheckHolder, V8DOMConfiguration::kAllWorlds } -, - - { "limitedToOnlyAttribute", V8TestObject::limitedToOnlyAttributeAttributeGetterCallback, V8TestObject::limitedToOnlyAttributeAttributeSetterCallback, V8PrivateProperty::kNoCachedAccessor, static_cast<v8::PropertyAttribute>(v8::None), V8DOMConfiguration::kOnPrototype, V8DOMConfiguration::kCheckHolder, V8DOMConfiguration::kAllWorlds } -, - - { "limitedToOnlyOtherAttribute", V8TestObject::limitedToOnlyOtherAttributeAttributeGetterCallback, V8TestObject::limitedToOnlyOtherAttributeAttributeSetterCallback, V8PrivateProperty::kNoCachedAccessor, static_cast<v8::PropertyAttribute>(v8::None), V8DOMConfiguration::kOnPrototype, V8DOMConfiguration::kCheckHolder, V8DOMConfiguration::kAllWorlds } -, - - { "limitedWithMissingDefaultAttribute", V8TestObject::limitedWithMissingDefaultAttributeAttributeGetterCallback, V8TestObject::limitedWithMissingDefaultAttributeAttributeSetterCallback, V8PrivateProperty::kNoCachedAccessor, static_cast<v8::PropertyAttribute>(v8::None), V8DOMConfiguration::kOnPrototype, V8DOMConfiguration::kCheckHolder, V8DOMConfiguration::kAllWorlds } -, - - { "limitedWithInvalidMissingDefaultAttribute", V8TestObject::limitedWithInvalidMissingDefaultAttributeAttributeGetterCallback, V8TestObject::limitedWithInvalidMissingDefaultAttributeAttributeSetterCallback, V8PrivateProperty::kNoCachedAccessor, static_cast<v8::PropertyAttribute>(v8::None), V8DOMConfiguration::kOnPrototype, V8DOMConfiguration::kCheckHolder, V8DOMConfiguration::kAllWorlds } -, - - { "corsSettingAttribute", V8TestObject::corsSettingAttributeAttributeGetterCallback, nullptr, V8PrivateProperty::kNoCachedAccessor, static_cast<v8::PropertyAttribute>(v8::ReadOnly), V8DOMConfiguration::kOnPrototype, V8DOMConfiguration::kCheckHolder, V8DOMConfiguration::kAllWorlds } -, - - { "limitedWithEmptyMissingInvalidAttribute", V8TestObject::limitedWithEmptyMissingInvalidAttributeAttributeGetterCallback, nullptr, V8PrivateProperty::kNoCachedAccessor, static_cast<v8::PropertyAttribute>(v8::ReadOnly), V8DOMConfiguration::kOnPrototype, V8DOMConfiguration::kCheckHolder, V8DOMConfiguration::kAllWorlds } -, - - { "RuntimeCallStatsCounterAttribute", V8TestObject::RuntimeCallStatsCounterAttributeAttributeGetterCallback, V8TestObject::RuntimeCallStatsCounterAttributeAttributeSetterCallback, V8PrivateProperty::kNoCachedAccessor, static_cast<v8::PropertyAttribute>(v8::None), V8DOMConfiguration::kOnPrototype, V8DOMConfiguration::kCheckHolder, V8DOMConfiguration::kAllWorlds } -, - - { "RuntimeCallStatsCounterReadOnlyAttribute", V8TestObject::RuntimeCallStatsCounterReadOnlyAttributeAttributeGetterCallback, nullptr, V8PrivateProperty::kNoCachedAccessor, static_cast<v8::PropertyAttribute>(v8::ReadOnly), V8DOMConfiguration::kOnPrototype, V8DOMConfiguration::kCheckHolder, V8DOMConfiguration::kAllWorlds } -, - - { "replaceableReadonlyLongAttribute", V8TestObject::replaceableReadonlyLongAttributeAttributeGetterCallback, V8TestObject::replaceableReadonlyLongAttributeAttributeSetterCallback, V8PrivateProperty::kNoCachedAccessor, static_cast<v8::PropertyAttribute>(v8::None), V8DOMConfiguration::kOnPrototype, V8DOMConfiguration::kCheckHolder, V8DOMConfiguration::kAllWorlds } -, - - { "locationPutForwards", V8TestObject::locationPutForwardsAttributeGetterCallback, V8TestObject::locationPutForwardsAttributeSetterCallback, V8PrivateProperty::kNoCachedAccessor, static_cast<v8::PropertyAttribute>(v8::None), V8DOMConfiguration::kOnPrototype, V8DOMConfiguration::kCheckHolder, V8DOMConfiguration::kAllWorlds } -, - - { "setterCallWithCurrentWindowAndEnteredWindowStringAttribute", V8TestObject::setterCallWithCurrentWindowAndEnteredWindowStringAttributeAttributeGetterCallback, V8TestObject::setterCallWithCurrentWindowAndEnteredWindowStringAttributeAttributeSetterCallback, V8PrivateProperty::kNoCachedAccessor, static_cast<v8::PropertyAttribute>(v8::None), V8DOMConfiguration::kOnPrototype, V8DOMConfiguration::kCheckHolder, V8DOMConfiguration::kAllWorlds } -, - - { "setterCallWithExecutionContextStringAttribute", V8TestObject::setterCallWithExecutionContextStringAttributeAttributeGetterCallback, V8TestObject::setterCallWithExecutionContextStringAttributeAttributeSetterCallback, V8PrivateProperty::kNoCachedAccessor, static_cast<v8::PropertyAttribute>(v8::None), V8DOMConfiguration::kOnPrototype, V8DOMConfiguration::kCheckHolder, V8DOMConfiguration::kAllWorlds } -, - - { "treatNullAsEmptyStringStringAttribute", V8TestObject::treatNullAsEmptyStringStringAttributeAttributeGetterCallback, V8TestObject::treatNullAsEmptyStringStringAttributeAttributeSetterCallback, V8PrivateProperty::kNoCachedAccessor, static_cast<v8::PropertyAttribute>(v8::None), V8DOMConfiguration::kOnPrototype, V8DOMConfiguration::kCheckHolder, V8DOMConfiguration::kAllWorlds } -, - - { "treatNullAsNullStringStringAttribute", V8TestObject::treatNullAsNullStringStringAttributeAttributeGetterCallback, V8TestObject::treatNullAsNullStringStringAttributeAttributeSetterCallback, V8PrivateProperty::kNoCachedAccessor, static_cast<v8::PropertyAttribute>(v8::None), V8DOMConfiguration::kOnPrototype, V8DOMConfiguration::kCheckHolder, V8DOMConfiguration::kAllWorlds } -, - - { "legacyInterfaceTypeCheckingFloatAttribute", V8TestObject::legacyInterfaceTypeCheckingFloatAttributeAttributeGetterCallback, V8TestObject::legacyInterfaceTypeCheckingFloatAttributeAttributeSetterCallback, V8PrivateProperty::kNoCachedAccessor, static_cast<v8::PropertyAttribute>(v8::None), V8DOMConfiguration::kOnPrototype, V8DOMConfiguration::kCheckHolder, V8DOMConfiguration::kAllWorlds } -, - - { "legacyInterfaceTypeCheckingTestInterfaceAttribute", V8TestObject::legacyInterfaceTypeCheckingTestInterfaceAttributeAttributeGetterCallback, V8TestObject::legacyInterfaceTypeCheckingTestInterfaceAttributeAttributeSetterCallback, V8PrivateProperty::kNoCachedAccessor, static_cast<v8::PropertyAttribute>(v8::None), V8DOMConfiguration::kOnPrototype, V8DOMConfiguration::kCheckHolder, V8DOMConfiguration::kAllWorlds } -, - - { "legacyInterfaceTypeCheckingTestInterfaceOrNullAttribute", V8TestObject::legacyInterfaceTypeCheckingTestInterfaceOrNullAttributeAttributeGetterCallback, V8TestObject::legacyInterfaceTypeCheckingTestInterfaceOrNullAttributeAttributeSetterCallback, V8PrivateProperty::kNoCachedAccessor, static_cast<v8::PropertyAttribute>(v8::None), V8DOMConfiguration::kOnPrototype, V8DOMConfiguration::kCheckHolder, V8DOMConfiguration::kAllWorlds } -, - - { "urlStringAttribute", V8TestObject::urlStringAttributeAttributeGetterCallback, V8TestObject::urlStringAttributeAttributeSetterCallback, V8PrivateProperty::kNoCachedAccessor, static_cast<v8::PropertyAttribute>(v8::None), V8DOMConfiguration::kOnPrototype, V8DOMConfiguration::kCheckHolder, V8DOMConfiguration::kAllWorlds } -, - - { "urlStringAttribute", V8TestObject::urlStringAttributeAttributeGetterCallback, V8TestObject::urlStringAttributeAttributeSetterCallback, V8PrivateProperty::kNoCachedAccessor, static_cast<v8::PropertyAttribute>(v8::None), V8DOMConfiguration::kOnPrototype, V8DOMConfiguration::kCheckHolder, V8DOMConfiguration::kAllWorlds } -, - - { "unforgeableLongAttribute", V8TestObject::unforgeableLongAttributeAttributeGetterCallback, V8TestObject::unforgeableLongAttributeAttributeSetterCallback, V8PrivateProperty::kNoCachedAccessor, static_cast<v8::PropertyAttribute>(v8::DontDelete), V8DOMConfiguration::kOnInstance, V8DOMConfiguration::kCheckHolder, V8DOMConfiguration::kAllWorlds } -, - - { "measuredLongAttribute", V8TestObject::measuredLongAttributeAttributeGetterCallback, V8TestObject::measuredLongAttributeAttributeSetterCallback, V8PrivateProperty::kNoCachedAccessor, static_cast<v8::PropertyAttribute>(v8::None), V8DOMConfiguration::kOnPrototype, V8DOMConfiguration::kCheckHolder, V8DOMConfiguration::kAllWorlds } -, - - { "sameObjectAttribute", V8TestObject::sameObjectAttributeAttributeGetterCallback, nullptr, V8PrivateProperty::kNoCachedAccessor, static_cast<v8::PropertyAttribute>(v8::ReadOnly), V8DOMConfiguration::kOnPrototype, V8DOMConfiguration::kCheckHolder, V8DOMConfiguration::kAllWorlds } -, - - { "saveSameObjectAttribute", V8TestObject::saveSameObjectAttributeAttributeGetterCallback, nullptr, V8PrivateProperty::kNoCachedAccessor, static_cast<v8::PropertyAttribute>(v8::ReadOnly), V8DOMConfiguration::kOnPrototype, V8DOMConfiguration::kCheckHolder, V8DOMConfiguration::kAllWorlds } -, - - { "staticSaveSameObjectAttribute", V8TestObject::staticSaveSameObjectAttributeAttributeGetterCallback, nullptr, V8PrivateProperty::kNoCachedAccessor, static_cast<v8::PropertyAttribute>(v8::ReadOnly), V8DOMConfiguration::kOnInterface, V8DOMConfiguration::kCheckHolder, V8DOMConfiguration::kAllWorlds } -, - - { "unscopableLongAttribute", V8TestObject::unscopableLongAttributeAttributeGetterCallback, V8TestObject::unscopableLongAttributeAttributeSetterCallback, V8PrivateProperty::kNoCachedAccessor, static_cast<v8::PropertyAttribute>(v8::None), V8DOMConfiguration::kOnPrototype, V8DOMConfiguration::kCheckHolder, V8DOMConfiguration::kAllWorlds } -, - - { "testInterfaceAttribute", V8TestObject::testInterfaceAttributeAttributeGetterCallback, V8TestObject::testInterfaceAttributeAttributeSetterCallback, V8PrivateProperty::kNoCachedAccessor, static_cast<v8::PropertyAttribute>(v8::None), V8DOMConfiguration::kOnPrototype, V8DOMConfiguration::kCheckHolder, V8DOMConfiguration::kAllWorlds } -, - - { "testInterfaceGarbageCollectedAttribute", V8TestObject::testInterfaceGarbageCollectedAttributeAttributeGetterCallback, V8TestObject::testInterfaceGarbageCollectedAttributeAttributeSetterCallback, V8PrivateProperty::kNoCachedAccessor, static_cast<v8::PropertyAttribute>(v8::None), V8DOMConfiguration::kOnPrototype, V8DOMConfiguration::kCheckHolder, V8DOMConfiguration::kAllWorlds } -, - - { "testInterfaceGarbageCollectedOrNullAttribute", V8TestObject::testInterfaceGarbageCollectedOrNullAttributeAttributeGetterCallback, V8TestObject::testInterfaceGarbageCollectedOrNullAttributeAttributeSetterCallback, V8PrivateProperty::kNoCachedAccessor, static_cast<v8::PropertyAttribute>(v8::None), V8DOMConfiguration::kOnPrototype, V8DOMConfiguration::kCheckHolder, V8DOMConfiguration::kAllWorlds } -, - - { "size", V8TestObject::sizeAttributeGetterCallback, nullptr, V8PrivateProperty::kNoCachedAccessor, static_cast<v8::PropertyAttribute>(v8::DontEnum | v8::ReadOnly), V8DOMConfiguration::kOnPrototype, V8DOMConfiguration::kCheckHolder, V8DOMConfiguration::kAllWorlds } -, + { "locationWithPerWorldBindings", V8TestObject::locationWithPerWorldBindingsAttributeGetterCallback, V8TestObject::locationWithPerWorldBindingsAttributeSetterCallback, V8PrivateProperty::kNoCachedAccessor, static_cast<v8::PropertyAttribute>(v8::None), V8DOMConfiguration::kOnPrototype, V8DOMConfiguration::kCheckHolder, V8DOMConfiguration::kNonMainWorlds }, + { "locationLegacyInterfaceTypeChecking", V8TestObject::locationLegacyInterfaceTypeCheckingAttributeGetterCallback, V8TestObject::locationLegacyInterfaceTypeCheckingAttributeSetterCallback, V8PrivateProperty::kNoCachedAccessor, static_cast<v8::PropertyAttribute>(v8::None), V8DOMConfiguration::kOnPrototype, V8DOMConfiguration::kCheckHolder, V8DOMConfiguration::kAllWorlds }, + { "locationGarbageCollected", V8TestObject::locationGarbageCollectedAttributeGetterCallback, V8TestObject::locationGarbageCollectedAttributeSetterCallback, V8PrivateProperty::kNoCachedAccessor, static_cast<v8::PropertyAttribute>(v8::None), V8DOMConfiguration::kOnPrototype, V8DOMConfiguration::kCheckHolder, V8DOMConfiguration::kAllWorlds }, + { "raisesExceptionLongAttribute", V8TestObject::raisesExceptionLongAttributeAttributeGetterCallback, V8TestObject::raisesExceptionLongAttributeAttributeSetterCallback, V8PrivateProperty::kNoCachedAccessor, static_cast<v8::PropertyAttribute>(v8::None), V8DOMConfiguration::kOnPrototype, V8DOMConfiguration::kCheckHolder, V8DOMConfiguration::kAllWorlds }, + { "raisesExceptionGetterLongAttribute", V8TestObject::raisesExceptionGetterLongAttributeAttributeGetterCallback, V8TestObject::raisesExceptionGetterLongAttributeAttributeSetterCallback, V8PrivateProperty::kNoCachedAccessor, static_cast<v8::PropertyAttribute>(v8::None), V8DOMConfiguration::kOnPrototype, V8DOMConfiguration::kCheckHolder, V8DOMConfiguration::kAllWorlds }, + { "setterRaisesExceptionLongAttribute", V8TestObject::setterRaisesExceptionLongAttributeAttributeGetterCallback, V8TestObject::setterRaisesExceptionLongAttributeAttributeSetterCallback, V8PrivateProperty::kNoCachedAccessor, static_cast<v8::PropertyAttribute>(v8::None), V8DOMConfiguration::kOnPrototype, V8DOMConfiguration::kCheckHolder, V8DOMConfiguration::kAllWorlds }, + { "raisesExceptionTestInterfaceEmptyAttribute", V8TestObject::raisesExceptionTestInterfaceEmptyAttributeAttributeGetterCallback, V8TestObject::raisesExceptionTestInterfaceEmptyAttributeAttributeSetterCallback, V8PrivateProperty::kNoCachedAccessor, static_cast<v8::PropertyAttribute>(v8::None), V8DOMConfiguration::kOnPrototype, V8DOMConfiguration::kCheckHolder, V8DOMConfiguration::kAllWorlds }, + { "cachedAttributeRaisesExceptionGetterAnyAttribute", V8TestObject::cachedAttributeRaisesExceptionGetterAnyAttributeAttributeGetterCallback, V8TestObject::cachedAttributeRaisesExceptionGetterAnyAttributeAttributeSetterCallback, V8PrivateProperty::kNoCachedAccessor, static_cast<v8::PropertyAttribute>(v8::None), V8DOMConfiguration::kOnPrototype, V8DOMConfiguration::kCheckHolder, V8DOMConfiguration::kAllWorlds }, + { "reflectTestInterfaceAttribute", V8TestObject::reflectTestInterfaceAttributeAttributeGetterCallback, V8TestObject::reflectTestInterfaceAttributeAttributeSetterCallback, V8PrivateProperty::kNoCachedAccessor, static_cast<v8::PropertyAttribute>(v8::None), V8DOMConfiguration::kOnPrototype, V8DOMConfiguration::kCheckHolder, V8DOMConfiguration::kAllWorlds }, + { "reflectReflectedNameAttributeTestAttribute", V8TestObject::reflectReflectedNameAttributeTestAttributeAttributeGetterCallback, V8TestObject::reflectReflectedNameAttributeTestAttributeAttributeSetterCallback, V8PrivateProperty::kNoCachedAccessor, static_cast<v8::PropertyAttribute>(v8::None), V8DOMConfiguration::kOnPrototype, V8DOMConfiguration::kCheckHolder, V8DOMConfiguration::kAllWorlds }, + { "reflectBooleanAttribute", V8TestObject::reflectBooleanAttributeAttributeGetterCallback, V8TestObject::reflectBooleanAttributeAttributeSetterCallback, V8PrivateProperty::kNoCachedAccessor, static_cast<v8::PropertyAttribute>(v8::None), V8DOMConfiguration::kOnPrototype, V8DOMConfiguration::kCheckHolder, V8DOMConfiguration::kAllWorlds }, + { "reflectLongAttribute", V8TestObject::reflectLongAttributeAttributeGetterCallback, V8TestObject::reflectLongAttributeAttributeSetterCallback, V8PrivateProperty::kNoCachedAccessor, static_cast<v8::PropertyAttribute>(v8::None), V8DOMConfiguration::kOnPrototype, V8DOMConfiguration::kCheckHolder, V8DOMConfiguration::kAllWorlds }, + { "reflectUnsignedShortAttribute", V8TestObject::reflectUnsignedShortAttributeAttributeGetterCallback, V8TestObject::reflectUnsignedShortAttributeAttributeSetterCallback, V8PrivateProperty::kNoCachedAccessor, static_cast<v8::PropertyAttribute>(v8::None), V8DOMConfiguration::kOnPrototype, V8DOMConfiguration::kCheckHolder, V8DOMConfiguration::kAllWorlds }, + { "reflectUnsignedLongAttribute", V8TestObject::reflectUnsignedLongAttributeAttributeGetterCallback, V8TestObject::reflectUnsignedLongAttributeAttributeSetterCallback, V8PrivateProperty::kNoCachedAccessor, static_cast<v8::PropertyAttribute>(v8::None), V8DOMConfiguration::kOnPrototype, V8DOMConfiguration::kCheckHolder, V8DOMConfiguration::kAllWorlds }, + { "id", V8TestObject::idAttributeGetterCallback, V8TestObject::idAttributeSetterCallback, V8PrivateProperty::kNoCachedAccessor, static_cast<v8::PropertyAttribute>(v8::None), V8DOMConfiguration::kOnPrototype, V8DOMConfiguration::kCheckHolder, V8DOMConfiguration::kAllWorlds }, + { "name", V8TestObject::nameAttributeGetterCallback, V8TestObject::nameAttributeSetterCallback, V8PrivateProperty::kNoCachedAccessor, static_cast<v8::PropertyAttribute>(v8::None), V8DOMConfiguration::kOnPrototype, V8DOMConfiguration::kCheckHolder, V8DOMConfiguration::kAllWorlds }, + { "class", V8TestObject::classAttributeGetterCallback, V8TestObject::classAttributeSetterCallback, V8PrivateProperty::kNoCachedAccessor, static_cast<v8::PropertyAttribute>(v8::None), V8DOMConfiguration::kOnPrototype, V8DOMConfiguration::kCheckHolder, V8DOMConfiguration::kAllWorlds }, + { "reflectedId", V8TestObject::reflectedIdAttributeGetterCallback, V8TestObject::reflectedIdAttributeSetterCallback, V8PrivateProperty::kNoCachedAccessor, static_cast<v8::PropertyAttribute>(v8::None), V8DOMConfiguration::kOnPrototype, V8DOMConfiguration::kCheckHolder, V8DOMConfiguration::kAllWorlds }, + { "reflectedName", V8TestObject::reflectedNameAttributeGetterCallback, V8TestObject::reflectedNameAttributeSetterCallback, V8PrivateProperty::kNoCachedAccessor, static_cast<v8::PropertyAttribute>(v8::None), V8DOMConfiguration::kOnPrototype, V8DOMConfiguration::kCheckHolder, V8DOMConfiguration::kAllWorlds }, + { "reflectedClass", V8TestObject::reflectedClassAttributeGetterCallback, V8TestObject::reflectedClassAttributeSetterCallback, V8PrivateProperty::kNoCachedAccessor, static_cast<v8::PropertyAttribute>(v8::None), V8DOMConfiguration::kOnPrototype, V8DOMConfiguration::kCheckHolder, V8DOMConfiguration::kAllWorlds }, + { "limitedToOnlyOneAttribute", V8TestObject::limitedToOnlyOneAttributeAttributeGetterCallback, V8TestObject::limitedToOnlyOneAttributeAttributeSetterCallback, V8PrivateProperty::kNoCachedAccessor, static_cast<v8::PropertyAttribute>(v8::None), V8DOMConfiguration::kOnPrototype, V8DOMConfiguration::kCheckHolder, V8DOMConfiguration::kAllWorlds }, + { "limitedToOnlyAttribute", V8TestObject::limitedToOnlyAttributeAttributeGetterCallback, V8TestObject::limitedToOnlyAttributeAttributeSetterCallback, V8PrivateProperty::kNoCachedAccessor, static_cast<v8::PropertyAttribute>(v8::None), V8DOMConfiguration::kOnPrototype, V8DOMConfiguration::kCheckHolder, V8DOMConfiguration::kAllWorlds }, + { "limitedToOnlyOtherAttribute", V8TestObject::limitedToOnlyOtherAttributeAttributeGetterCallback, V8TestObject::limitedToOnlyOtherAttributeAttributeSetterCallback, V8PrivateProperty::kNoCachedAccessor, static_cast<v8::PropertyAttribute>(v8::None), V8DOMConfiguration::kOnPrototype, V8DOMConfiguration::kCheckHolder, V8DOMConfiguration::kAllWorlds }, + { "limitedWithMissingDefaultAttribute", V8TestObject::limitedWithMissingDefaultAttributeAttributeGetterCallback, V8TestObject::limitedWithMissingDefaultAttributeAttributeSetterCallback, V8PrivateProperty::kNoCachedAccessor, static_cast<v8::PropertyAttribute>(v8::None), V8DOMConfiguration::kOnPrototype, V8DOMConfiguration::kCheckHolder, V8DOMConfiguration::kAllWorlds }, + { "limitedWithInvalidMissingDefaultAttribute", V8TestObject::limitedWithInvalidMissingDefaultAttributeAttributeGetterCallback, V8TestObject::limitedWithInvalidMissingDefaultAttributeAttributeSetterCallback, V8PrivateProperty::kNoCachedAccessor, static_cast<v8::PropertyAttribute>(v8::None), V8DOMConfiguration::kOnPrototype, V8DOMConfiguration::kCheckHolder, V8DOMConfiguration::kAllWorlds }, + { "corsSettingAttribute", V8TestObject::corsSettingAttributeAttributeGetterCallback, nullptr, V8PrivateProperty::kNoCachedAccessor, static_cast<v8::PropertyAttribute>(v8::ReadOnly), V8DOMConfiguration::kOnPrototype, V8DOMConfiguration::kCheckHolder, V8DOMConfiguration::kAllWorlds }, + { "limitedWithEmptyMissingInvalidAttribute", V8TestObject::limitedWithEmptyMissingInvalidAttributeAttributeGetterCallback, nullptr, V8PrivateProperty::kNoCachedAccessor, static_cast<v8::PropertyAttribute>(v8::ReadOnly), V8DOMConfiguration::kOnPrototype, V8DOMConfiguration::kCheckHolder, V8DOMConfiguration::kAllWorlds }, + { "RuntimeCallStatsCounterAttribute", V8TestObject::RuntimeCallStatsCounterAttributeAttributeGetterCallback, V8TestObject::RuntimeCallStatsCounterAttributeAttributeSetterCallback, V8PrivateProperty::kNoCachedAccessor, static_cast<v8::PropertyAttribute>(v8::None), V8DOMConfiguration::kOnPrototype, V8DOMConfiguration::kCheckHolder, V8DOMConfiguration::kAllWorlds }, + { "RuntimeCallStatsCounterReadOnlyAttribute", V8TestObject::RuntimeCallStatsCounterReadOnlyAttributeAttributeGetterCallback, nullptr, V8PrivateProperty::kNoCachedAccessor, static_cast<v8::PropertyAttribute>(v8::ReadOnly), V8DOMConfiguration::kOnPrototype, V8DOMConfiguration::kCheckHolder, V8DOMConfiguration::kAllWorlds }, + { "replaceableReadonlyLongAttribute", V8TestObject::replaceableReadonlyLongAttributeAttributeGetterCallback, V8TestObject::replaceableReadonlyLongAttributeAttributeSetterCallback, V8PrivateProperty::kNoCachedAccessor, static_cast<v8::PropertyAttribute>(v8::None), V8DOMConfiguration::kOnPrototype, V8DOMConfiguration::kCheckHolder, V8DOMConfiguration::kAllWorlds }, + { "locationPutForwards", V8TestObject::locationPutForwardsAttributeGetterCallback, V8TestObject::locationPutForwardsAttributeSetterCallback, V8PrivateProperty::kNoCachedAccessor, static_cast<v8::PropertyAttribute>(v8::None), V8DOMConfiguration::kOnPrototype, V8DOMConfiguration::kCheckHolder, V8DOMConfiguration::kAllWorlds }, + { "setterCallWithCurrentWindowAndEnteredWindowStringAttribute", V8TestObject::setterCallWithCurrentWindowAndEnteredWindowStringAttributeAttributeGetterCallback, V8TestObject::setterCallWithCurrentWindowAndEnteredWindowStringAttributeAttributeSetterCallback, V8PrivateProperty::kNoCachedAccessor, static_cast<v8::PropertyAttribute>(v8::None), V8DOMConfiguration::kOnPrototype, V8DOMConfiguration::kCheckHolder, V8DOMConfiguration::kAllWorlds }, + { "setterCallWithExecutionContextStringAttribute", V8TestObject::setterCallWithExecutionContextStringAttributeAttributeGetterCallback, V8TestObject::setterCallWithExecutionContextStringAttributeAttributeSetterCallback, V8PrivateProperty::kNoCachedAccessor, static_cast<v8::PropertyAttribute>(v8::None), V8DOMConfiguration::kOnPrototype, V8DOMConfiguration::kCheckHolder, V8DOMConfiguration::kAllWorlds }, + { "treatNullAsEmptyStringStringAttribute", V8TestObject::treatNullAsEmptyStringStringAttributeAttributeGetterCallback, V8TestObject::treatNullAsEmptyStringStringAttributeAttributeSetterCallback, V8PrivateProperty::kNoCachedAccessor, static_cast<v8::PropertyAttribute>(v8::None), V8DOMConfiguration::kOnPrototype, V8DOMConfiguration::kCheckHolder, V8DOMConfiguration::kAllWorlds }, + { "treatNullAsNullStringStringAttribute", V8TestObject::treatNullAsNullStringStringAttributeAttributeGetterCallback, V8TestObject::treatNullAsNullStringStringAttributeAttributeSetterCallback, V8PrivateProperty::kNoCachedAccessor, static_cast<v8::PropertyAttribute>(v8::None), V8DOMConfiguration::kOnPrototype, V8DOMConfiguration::kCheckHolder, V8DOMConfiguration::kAllWorlds }, + { "legacyInterfaceTypeCheckingFloatAttribute", V8TestObject::legacyInterfaceTypeCheckingFloatAttributeAttributeGetterCallback, V8TestObject::legacyInterfaceTypeCheckingFloatAttributeAttributeSetterCallback, V8PrivateProperty::kNoCachedAccessor, static_cast<v8::PropertyAttribute>(v8::None), V8DOMConfiguration::kOnPrototype, V8DOMConfiguration::kCheckHolder, V8DOMConfiguration::kAllWorlds }, + { "legacyInterfaceTypeCheckingTestInterfaceAttribute", V8TestObject::legacyInterfaceTypeCheckingTestInterfaceAttributeAttributeGetterCallback, V8TestObject::legacyInterfaceTypeCheckingTestInterfaceAttributeAttributeSetterCallback, V8PrivateProperty::kNoCachedAccessor, static_cast<v8::PropertyAttribute>(v8::None), V8DOMConfiguration::kOnPrototype, V8DOMConfiguration::kCheckHolder, V8DOMConfiguration::kAllWorlds }, + { "legacyInterfaceTypeCheckingTestInterfaceOrNullAttribute", V8TestObject::legacyInterfaceTypeCheckingTestInterfaceOrNullAttributeAttributeGetterCallback, V8TestObject::legacyInterfaceTypeCheckingTestInterfaceOrNullAttributeAttributeSetterCallback, V8PrivateProperty::kNoCachedAccessor, static_cast<v8::PropertyAttribute>(v8::None), V8DOMConfiguration::kOnPrototype, V8DOMConfiguration::kCheckHolder, V8DOMConfiguration::kAllWorlds }, + { "urlStringAttribute", V8TestObject::urlStringAttributeAttributeGetterCallback, V8TestObject::urlStringAttributeAttributeSetterCallback, V8PrivateProperty::kNoCachedAccessor, static_cast<v8::PropertyAttribute>(v8::None), V8DOMConfiguration::kOnPrototype, V8DOMConfiguration::kCheckHolder, V8DOMConfiguration::kAllWorlds }, + { "urlStringAttribute", V8TestObject::urlStringAttributeAttributeGetterCallback, V8TestObject::urlStringAttributeAttributeSetterCallback, V8PrivateProperty::kNoCachedAccessor, static_cast<v8::PropertyAttribute>(v8::None), V8DOMConfiguration::kOnPrototype, V8DOMConfiguration::kCheckHolder, V8DOMConfiguration::kAllWorlds }, + { "unforgeableLongAttribute", V8TestObject::unforgeableLongAttributeAttributeGetterCallback, V8TestObject::unforgeableLongAttributeAttributeSetterCallback, V8PrivateProperty::kNoCachedAccessor, static_cast<v8::PropertyAttribute>(v8::DontDelete), V8DOMConfiguration::kOnInstance, V8DOMConfiguration::kCheckHolder, V8DOMConfiguration::kAllWorlds }, + { "measuredLongAttribute", V8TestObject::measuredLongAttributeAttributeGetterCallback, V8TestObject::measuredLongAttributeAttributeSetterCallback, V8PrivateProperty::kNoCachedAccessor, static_cast<v8::PropertyAttribute>(v8::None), V8DOMConfiguration::kOnPrototype, V8DOMConfiguration::kCheckHolder, V8DOMConfiguration::kAllWorlds }, + { "sameObjectAttribute", V8TestObject::sameObjectAttributeAttributeGetterCallback, nullptr, V8PrivateProperty::kNoCachedAccessor, static_cast<v8::PropertyAttribute>(v8::ReadOnly), V8DOMConfiguration::kOnPrototype, V8DOMConfiguration::kCheckHolder, V8DOMConfiguration::kAllWorlds }, + { "saveSameObjectAttribute", V8TestObject::saveSameObjectAttributeAttributeGetterCallback, nullptr, V8PrivateProperty::kNoCachedAccessor, static_cast<v8::PropertyAttribute>(v8::ReadOnly), V8DOMConfiguration::kOnPrototype, V8DOMConfiguration::kCheckHolder, V8DOMConfiguration::kAllWorlds }, + { "staticSaveSameObjectAttribute", V8TestObject::staticSaveSameObjectAttributeAttributeGetterCallback, nullptr, V8PrivateProperty::kNoCachedAccessor, static_cast<v8::PropertyAttribute>(v8::ReadOnly), V8DOMConfiguration::kOnInterface, V8DOMConfiguration::kCheckHolder, V8DOMConfiguration::kAllWorlds }, + { "unscopableLongAttribute", V8TestObject::unscopableLongAttributeAttributeGetterCallback, V8TestObject::unscopableLongAttributeAttributeSetterCallback, V8PrivateProperty::kNoCachedAccessor, static_cast<v8::PropertyAttribute>(v8::None), V8DOMConfiguration::kOnPrototype, V8DOMConfiguration::kCheckHolder, V8DOMConfiguration::kAllWorlds }, + { "testInterfaceAttribute", V8TestObject::testInterfaceAttributeAttributeGetterCallback, V8TestObject::testInterfaceAttributeAttributeSetterCallback, V8PrivateProperty::kNoCachedAccessor, static_cast<v8::PropertyAttribute>(v8::None), V8DOMConfiguration::kOnPrototype, V8DOMConfiguration::kCheckHolder, V8DOMConfiguration::kAllWorlds }, + { "testInterfaceGarbageCollectedAttribute", V8TestObject::testInterfaceGarbageCollectedAttributeAttributeGetterCallback, V8TestObject::testInterfaceGarbageCollectedAttributeAttributeSetterCallback, V8PrivateProperty::kNoCachedAccessor, static_cast<v8::PropertyAttribute>(v8::None), V8DOMConfiguration::kOnPrototype, V8DOMConfiguration::kCheckHolder, V8DOMConfiguration::kAllWorlds }, + { "testInterfaceGarbageCollectedOrNullAttribute", V8TestObject::testInterfaceGarbageCollectedOrNullAttributeAttributeGetterCallback, V8TestObject::testInterfaceGarbageCollectedOrNullAttributeAttributeSetterCallback, V8PrivateProperty::kNoCachedAccessor, static_cast<v8::PropertyAttribute>(v8::None), V8DOMConfiguration::kOnPrototype, V8DOMConfiguration::kCheckHolder, V8DOMConfiguration::kAllWorlds }, + { "size", V8TestObject::sizeAttributeGetterCallback, nullptr, V8PrivateProperty::kNoCachedAccessor, static_cast<v8::PropertyAttribute>(v8::DontEnum | v8::ReadOnly), V8DOMConfiguration::kOnPrototype, V8DOMConfiguration::kCheckHolder, V8DOMConfiguration::kAllWorlds }, }; static const V8DOMConfiguration::MethodConfiguration V8TestObjectMethods[] = { @@ -13992,11 +13677,8 @@ if (RuntimeEnabledFeatures::FeatureNameEnabled()) { static const V8DOMConfiguration::AccessorConfiguration accessor_configurations[] = { - { "runtimeEnabledLongAttribute", V8TestObject::runtimeEnabledLongAttributeAttributeGetterCallback, V8TestObject::runtimeEnabledLongAttributeAttributeSetterCallback, V8PrivateProperty::kNoCachedAccessor, static_cast<v8::PropertyAttribute>(v8::None), V8DOMConfiguration::kOnPrototype, V8DOMConfiguration::kCheckHolder, V8DOMConfiguration::kAllWorlds } - , - - { "unscopableRuntimeEnabledLongAttribute", V8TestObject::unscopableRuntimeEnabledLongAttributeAttributeGetterCallback, V8TestObject::unscopableRuntimeEnabledLongAttributeAttributeSetterCallback, V8PrivateProperty::kNoCachedAccessor, static_cast<v8::PropertyAttribute>(v8::None), V8DOMConfiguration::kOnPrototype, V8DOMConfiguration::kCheckHolder, V8DOMConfiguration::kAllWorlds } - , + { "runtimeEnabledLongAttribute", V8TestObject::runtimeEnabledLongAttributeAttributeGetterCallback, V8TestObject::runtimeEnabledLongAttributeAttributeSetterCallback, V8PrivateProperty::kNoCachedAccessor, static_cast<v8::PropertyAttribute>(v8::None), V8DOMConfiguration::kOnPrototype, V8DOMConfiguration::kCheckHolder, V8DOMConfiguration::kAllWorlds }, + { "unscopableRuntimeEnabledLongAttribute", V8TestObject::unscopableRuntimeEnabledLongAttributeAttributeGetterCallback, V8TestObject::unscopableRuntimeEnabledLongAttributeAttributeSetterCallback, V8PrivateProperty::kNoCachedAccessor, static_cast<v8::PropertyAttribute>(v8::None), V8DOMConfiguration::kOnPrototype, V8DOMConfiguration::kCheckHolder, V8DOMConfiguration::kAllWorlds }, }; V8DOMConfiguration::InstallAccessors( isolate, world, instance_template, prototype_template, interface_template, @@ -14048,12 +13730,12 @@ v8::Local<v8::Signature> signature = v8::Signature::New(isolate, interfaceTemplate); ALLOW_UNUSED_LOCAL(signature); static const V8DOMConfiguration::AccessorConfiguration accessororiginTrialEnabledLongAttributeConfiguration[] = { - { "originTrialEnabledLongAttribute", V8TestObject::originTrialEnabledLongAttributeAttributeGetterCallback, V8TestObject::originTrialEnabledLongAttributeAttributeSetterCallback, V8PrivateProperty::kNoCachedAccessor, static_cast<v8::PropertyAttribute>(v8::None), V8DOMConfiguration::kOnPrototype, V8DOMConfiguration::kCheckHolder, V8DOMConfiguration::kAllWorlds } + { "originTrialEnabledLongAttribute", V8TestObject::originTrialEnabledLongAttributeAttributeGetterCallback, V8TestObject::originTrialEnabledLongAttributeAttributeSetterCallback, V8PrivateProperty::kNoCachedAccessor, static_cast<v8::PropertyAttribute>(v8::None), V8DOMConfiguration::kOnPrototype, V8DOMConfiguration::kCheckHolder, V8DOMConfiguration::kAllWorlds } }; for (const auto& accessorConfig : accessororiginTrialEnabledLongAttributeConfiguration) V8DOMConfiguration::InstallAccessor(isolate, world, instance, prototype, interface, signature, accessorConfig); static const V8DOMConfiguration::AccessorConfiguration accessorunscopableOriginTrialEnabledLongAttributeConfiguration[] = { - { "unscopableOriginTrialEnabledLongAttribute", V8TestObject::unscopableOriginTrialEnabledLongAttributeAttributeGetterCallback, V8TestObject::unscopableOriginTrialEnabledLongAttributeAttributeSetterCallback, V8PrivateProperty::kNoCachedAccessor, static_cast<v8::PropertyAttribute>(v8::None), V8DOMConfiguration::kOnPrototype, V8DOMConfiguration::kCheckHolder, V8DOMConfiguration::kAllWorlds } + { "unscopableOriginTrialEnabledLongAttribute", V8TestObject::unscopableOriginTrialEnabledLongAttributeAttributeGetterCallback, V8TestObject::unscopableOriginTrialEnabledLongAttributeAttributeSetterCallback, V8PrivateProperty::kNoCachedAccessor, static_cast<v8::PropertyAttribute>(v8::None), V8DOMConfiguration::kOnPrototype, V8DOMConfiguration::kCheckHolder, V8DOMConfiguration::kAllWorlds } }; for (const auto& accessorConfig : accessorunscopableOriginTrialEnabledLongAttributeConfiguration) V8DOMConfiguration::InstallAccessor(isolate, world, instance, prototype, interface, signature, accessorConfig);
diff --git a/third_party/WebKit/Source/bindings/tests/results/core/V8TestTypedefs.cpp b/third_party/WebKit/Source/bindings/tests/results/core/V8TestTypedefs.cpp index 1c9b744..ca9ddcc 100644 --- a/third_party/WebKit/Source/bindings/tests/results/core/V8TestTypedefs.cpp +++ b/third_party/WebKit/Source/bindings/tests/results/core/V8TestTypedefs.cpp
@@ -174,7 +174,6 @@ } if (UNLIKELY(numArgsPassed <= 0)) { impl->voidMethodLongSequenceArg(); - return; } longSequenceArg = NativeValueTraits<IDLSequence<IDLLong>>::NativeValue(info.GetIsolate(), info[0], exceptionState); @@ -528,22 +527,16 @@ #pragma clang diagnostic ignored "-Wglobal-constructors" #endif static const V8DOMConfiguration::AttributeConfiguration V8TestTypedefsLazyDataAttributes[] = { - { "tAttribute", V8TestTypedefs::tAttributeConstructorGetterCallback, nullptr, static_cast<v8::PropertyAttribute>(v8::DontEnum), V8DOMConfiguration::kOnInstance, V8DOMConfiguration::kCheckHolder, V8DOMConfiguration::kAllWorlds } -, + { "tAttribute", V8TestTypedefs::tAttributeConstructorGetterCallback, nullptr, static_cast<v8::PropertyAttribute>(v8::DontEnum), V8DOMConfiguration::kOnInstance, V8DOMConfiguration::kCheckHolder, V8DOMConfiguration::kAllWorlds }, }; #if defined(COMPONENT_BUILD) && defined(WIN32) && defined(__clang__) #pragma clang diagnostic pop #endif static const V8DOMConfiguration::AccessorConfiguration V8TestTypedefsAccessors[] = { - { "uLongLongAttribute", V8TestTypedefs::uLongLongAttributeAttributeGetterCallback, V8TestTypedefs::uLongLongAttributeAttributeSetterCallback, V8PrivateProperty::kNoCachedAccessor, static_cast<v8::PropertyAttribute>(v8::None), V8DOMConfiguration::kOnPrototype, V8DOMConfiguration::kCheckHolder, V8DOMConfiguration::kAllWorlds } -, - - { "longWithClampAttribute", V8TestTypedefs::longWithClampAttributeAttributeGetterCallback, V8TestTypedefs::longWithClampAttributeAttributeSetterCallback, V8PrivateProperty::kNoCachedAccessor, static_cast<v8::PropertyAttribute>(v8::None), V8DOMConfiguration::kOnPrototype, V8DOMConfiguration::kCheckHolder, V8DOMConfiguration::kAllWorlds } -, - - { "domStringOrDoubleOrNullAttribute", V8TestTypedefs::domStringOrDoubleOrNullAttributeAttributeGetterCallback, V8TestTypedefs::domStringOrDoubleOrNullAttributeAttributeSetterCallback, V8PrivateProperty::kNoCachedAccessor, static_cast<v8::PropertyAttribute>(v8::None), V8DOMConfiguration::kOnPrototype, V8DOMConfiguration::kCheckHolder, V8DOMConfiguration::kAllWorlds } -, + { "uLongLongAttribute", V8TestTypedefs::uLongLongAttributeAttributeGetterCallback, V8TestTypedefs::uLongLongAttributeAttributeSetterCallback, V8PrivateProperty::kNoCachedAccessor, static_cast<v8::PropertyAttribute>(v8::None), V8DOMConfiguration::kOnPrototype, V8DOMConfiguration::kCheckHolder, V8DOMConfiguration::kAllWorlds }, + { "longWithClampAttribute", V8TestTypedefs::longWithClampAttributeAttributeGetterCallback, V8TestTypedefs::longWithClampAttributeAttributeSetterCallback, V8PrivateProperty::kNoCachedAccessor, static_cast<v8::PropertyAttribute>(v8::None), V8DOMConfiguration::kOnPrototype, V8DOMConfiguration::kCheckHolder, V8DOMConfiguration::kAllWorlds }, + { "domStringOrDoubleOrNullAttribute", V8TestTypedefs::domStringOrDoubleOrNullAttributeAttributeGetterCallback, V8TestTypedefs::domStringOrDoubleOrNullAttributeAttributeSetterCallback, V8PrivateProperty::kNoCachedAccessor, static_cast<v8::PropertyAttribute>(v8::None), V8DOMConfiguration::kOnPrototype, V8DOMConfiguration::kCheckHolder, V8DOMConfiguration::kAllWorlds }, }; static const V8DOMConfiguration::MethodConfiguration V8TestTypedefsMethods[] = {
diff --git a/third_party/WebKit/Source/bindings/tests/results/modules/V8TestInheritedLegacyUnenumerableNamedProperties.cpp b/third_party/WebKit/Source/bindings/tests/results/modules/V8TestInheritedLegacyUnenumerableNamedProperties.cpp index bae3342..c46d7cc 100644 --- a/third_party/WebKit/Source/bindings/tests/results/modules/V8TestInheritedLegacyUnenumerableNamedProperties.cpp +++ b/third_party/WebKit/Source/bindings/tests/results/modules/V8TestInheritedLegacyUnenumerableNamedProperties.cpp
@@ -183,8 +183,7 @@ } static const V8DOMConfiguration::AccessorConfiguration V8TestInheritedLegacyUnenumerableNamedPropertiesAccessors[] = { - { "longAttribute", V8TestInheritedLegacyUnenumerableNamedProperties::longAttributeAttributeGetterCallback, nullptr, V8PrivateProperty::kNoCachedAccessor, static_cast<v8::PropertyAttribute>(v8::ReadOnly), V8DOMConfiguration::kOnPrototype, V8DOMConfiguration::kCheckHolder, V8DOMConfiguration::kAllWorlds } -, + { "longAttribute", V8TestInheritedLegacyUnenumerableNamedProperties::longAttributeAttributeGetterCallback, nullptr, V8PrivateProperty::kNoCachedAccessor, static_cast<v8::PropertyAttribute>(v8::ReadOnly), V8DOMConfiguration::kOnPrototype, V8DOMConfiguration::kCheckHolder, V8DOMConfiguration::kAllWorlds }, }; static void installV8TestInheritedLegacyUnenumerableNamedPropertiesTemplate(
diff --git a/third_party/WebKit/Source/bindings/tests/results/modules/V8TestInterface5.cpp b/third_party/WebKit/Source/bindings/tests/results/modules/V8TestInterface5.cpp index 8c4e86b7..117a361 100644 --- a/third_party/WebKit/Source/bindings/tests/results/modules/V8TestInterface5.cpp +++ b/third_party/WebKit/Source/bindings/tests/results/modules/V8TestInterface5.cpp
@@ -913,37 +913,21 @@ #pragma clang diagnostic ignored "-Wglobal-constructors" #endif static const V8DOMConfiguration::AttributeConfiguration V8TestInterface5LazyDataAttributes[] = { - { "testInterfaceConstructorAttribute", V8TestInterface5::testInterfaceConstructorAttributeConstructorGetterCallback, nullptr, static_cast<v8::PropertyAttribute>(v8::DontEnum), V8DOMConfiguration::kOnInstance, V8DOMConfiguration::kCheckHolder, V8DOMConfiguration::kAllWorlds } -, + { "testInterfaceConstructorAttribute", V8TestInterface5::testInterfaceConstructorAttributeConstructorGetterCallback, nullptr, static_cast<v8::PropertyAttribute>(v8::DontEnum), V8DOMConfiguration::kOnInstance, V8DOMConfiguration::kCheckHolder, V8DOMConfiguration::kAllWorlds }, }; #if defined(COMPONENT_BUILD) && defined(WIN32) && defined(__clang__) #pragma clang diagnostic pop #endif static const V8DOMConfiguration::AccessorConfiguration V8TestInterface5Accessors[] = { - { "testInterfaceAttribute", V8TestInterface5::testInterfaceAttributeAttributeGetterCallback, V8TestInterface5::testInterfaceAttributeAttributeSetterCallback, V8PrivateProperty::kNoCachedAccessor, static_cast<v8::PropertyAttribute>(v8::None), V8DOMConfiguration::kOnPrototype, V8DOMConfiguration::kCheckHolder, V8DOMConfiguration::kAllWorlds } -, - - { "doubleAttribute", V8TestInterface5::doubleAttributeAttributeGetterCallback, V8TestInterface5::doubleAttributeAttributeSetterCallback, V8PrivateProperty::kNoCachedAccessor, static_cast<v8::PropertyAttribute>(v8::None), V8DOMConfiguration::kOnPrototype, V8DOMConfiguration::kCheckHolder, V8DOMConfiguration::kAllWorlds } -, - - { "floatAttribute", V8TestInterface5::floatAttributeAttributeGetterCallback, V8TestInterface5::floatAttributeAttributeSetterCallback, V8PrivateProperty::kNoCachedAccessor, static_cast<v8::PropertyAttribute>(v8::None), V8DOMConfiguration::kOnPrototype, V8DOMConfiguration::kCheckHolder, V8DOMConfiguration::kAllWorlds } -, - - { "unrestrictedDoubleAttribute", V8TestInterface5::unrestrictedDoubleAttributeAttributeGetterCallback, V8TestInterface5::unrestrictedDoubleAttributeAttributeSetterCallback, V8PrivateProperty::kNoCachedAccessor, static_cast<v8::PropertyAttribute>(v8::None), V8DOMConfiguration::kOnPrototype, V8DOMConfiguration::kCheckHolder, V8DOMConfiguration::kAllWorlds } -, - - { "unrestrictedFloatAttribute", V8TestInterface5::unrestrictedFloatAttributeAttributeGetterCallback, V8TestInterface5::unrestrictedFloatAttributeAttributeSetterCallback, V8PrivateProperty::kNoCachedAccessor, static_cast<v8::PropertyAttribute>(v8::None), V8DOMConfiguration::kOnPrototype, V8DOMConfiguration::kCheckHolder, V8DOMConfiguration::kAllWorlds } -, - - { "staticStringAttribute", V8TestInterface5::staticStringAttributeAttributeGetterCallback, V8TestInterface5::staticStringAttributeAttributeSetterCallback, V8PrivateProperty::kNoCachedAccessor, static_cast<v8::PropertyAttribute>(v8::None), V8DOMConfiguration::kOnInterface, V8DOMConfiguration::kCheckHolder, V8DOMConfiguration::kAllWorlds } -, - - { "length", V8TestInterface5::lengthAttributeGetterCallback, nullptr, V8PrivateProperty::kNoCachedAccessor, static_cast<v8::PropertyAttribute>(v8::ReadOnly), V8DOMConfiguration::kOnPrototype, V8DOMConfiguration::kCheckHolder, V8DOMConfiguration::kAllWorlds } -, - - { "alwaysExposedAttribute", V8TestInterface5::alwaysExposedAttributeAttributeGetterCallback, V8TestInterface5::alwaysExposedAttributeAttributeSetterCallback, V8PrivateProperty::kNoCachedAccessor, static_cast<v8::PropertyAttribute>(v8::None), V8DOMConfiguration::kOnPrototype, V8DOMConfiguration::kCheckHolder, V8DOMConfiguration::kAllWorlds } -, + { "testInterfaceAttribute", V8TestInterface5::testInterfaceAttributeAttributeGetterCallback, V8TestInterface5::testInterfaceAttributeAttributeSetterCallback, V8PrivateProperty::kNoCachedAccessor, static_cast<v8::PropertyAttribute>(v8::None), V8DOMConfiguration::kOnPrototype, V8DOMConfiguration::kCheckHolder, V8DOMConfiguration::kAllWorlds }, + { "doubleAttribute", V8TestInterface5::doubleAttributeAttributeGetterCallback, V8TestInterface5::doubleAttributeAttributeSetterCallback, V8PrivateProperty::kNoCachedAccessor, static_cast<v8::PropertyAttribute>(v8::None), V8DOMConfiguration::kOnPrototype, V8DOMConfiguration::kCheckHolder, V8DOMConfiguration::kAllWorlds }, + { "floatAttribute", V8TestInterface5::floatAttributeAttributeGetterCallback, V8TestInterface5::floatAttributeAttributeSetterCallback, V8PrivateProperty::kNoCachedAccessor, static_cast<v8::PropertyAttribute>(v8::None), V8DOMConfiguration::kOnPrototype, V8DOMConfiguration::kCheckHolder, V8DOMConfiguration::kAllWorlds }, + { "unrestrictedDoubleAttribute", V8TestInterface5::unrestrictedDoubleAttributeAttributeGetterCallback, V8TestInterface5::unrestrictedDoubleAttributeAttributeSetterCallback, V8PrivateProperty::kNoCachedAccessor, static_cast<v8::PropertyAttribute>(v8::None), V8DOMConfiguration::kOnPrototype, V8DOMConfiguration::kCheckHolder, V8DOMConfiguration::kAllWorlds }, + { "unrestrictedFloatAttribute", V8TestInterface5::unrestrictedFloatAttributeAttributeGetterCallback, V8TestInterface5::unrestrictedFloatAttributeAttributeSetterCallback, V8PrivateProperty::kNoCachedAccessor, static_cast<v8::PropertyAttribute>(v8::None), V8DOMConfiguration::kOnPrototype, V8DOMConfiguration::kCheckHolder, V8DOMConfiguration::kAllWorlds }, + { "staticStringAttribute", V8TestInterface5::staticStringAttributeAttributeGetterCallback, V8TestInterface5::staticStringAttributeAttributeSetterCallback, V8PrivateProperty::kNoCachedAccessor, static_cast<v8::PropertyAttribute>(v8::None), V8DOMConfiguration::kOnInterface, V8DOMConfiguration::kCheckHolder, V8DOMConfiguration::kAllWorlds }, + { "length", V8TestInterface5::lengthAttributeGetterCallback, nullptr, V8PrivateProperty::kNoCachedAccessor, static_cast<v8::PropertyAttribute>(v8::ReadOnly), V8DOMConfiguration::kOnPrototype, V8DOMConfiguration::kCheckHolder, V8DOMConfiguration::kAllWorlds }, + { "alwaysExposedAttribute", V8TestInterface5::alwaysExposedAttributeAttributeGetterCallback, V8TestInterface5::alwaysExposedAttributeAttributeSetterCallback, V8PrivateProperty::kNoCachedAccessor, static_cast<v8::PropertyAttribute>(v8::None), V8DOMConfiguration::kOnPrototype, V8DOMConfiguration::kCheckHolder, V8DOMConfiguration::kAllWorlds }, }; static const V8DOMConfiguration::MethodConfiguration V8TestInterface5Methods[] = { @@ -987,7 +971,6 @@ V8DOMConfiguration::InstallConstants( isolate, interfaceTemplate, prototypeTemplate, V8TestInterface5Constants, WTF_ARRAY_LENGTH(V8TestInterface5Constants)); - V8DOMConfiguration::InstallLazyDataAttributes( isolate, world, instanceTemplate, prototypeTemplate, V8TestInterface5LazyDataAttributes, WTF_ARRAY_LENGTH(V8TestInterface5LazyDataAttributes)); @@ -1095,8 +1078,7 @@ if (!prototypeObject.IsEmpty() || !interfaceObject.IsEmpty()) { if (executionContext && (executionContext->IsDocument())) { static const V8DOMConfiguration::AccessorConfiguration accessor_configurations[] = { - { "windowExposedAttribute", V8TestInterface5::windowExposedAttributeAttributeGetterCallback, V8TestInterface5::windowExposedAttributeAttributeSetterCallback, V8PrivateProperty::kNoCachedAccessor, static_cast<v8::PropertyAttribute>(v8::None), V8DOMConfiguration::kOnPrototype, V8DOMConfiguration::kCheckHolder, V8DOMConfiguration::kAllWorlds } - , + { "windowExposedAttribute", V8TestInterface5::windowExposedAttributeAttributeGetterCallback, V8TestInterface5::windowExposedAttributeAttributeSetterCallback, V8PrivateProperty::kNoCachedAccessor, static_cast<v8::PropertyAttribute>(v8::None), V8DOMConfiguration::kOnPrototype, V8DOMConfiguration::kCheckHolder, V8DOMConfiguration::kAllWorlds }, }; V8DOMConfiguration::InstallAccessors( isolate, world, instanceObject, prototypeObject, interfaceObject, @@ -1105,15 +1087,13 @@ } if (executionContext && (executionContext->IsWorkerGlobalScope())) { static const V8DOMConfiguration::AccessorConfiguration accessor_configurations[] = { - { "workerExposedAttribute", V8TestInterface5::workerExposedAttributeAttributeGetterCallback, V8TestInterface5::workerExposedAttributeAttributeSetterCallback, V8PrivateProperty::kNoCachedAccessor, static_cast<v8::PropertyAttribute>(v8::None), V8DOMConfiguration::kOnPrototype, V8DOMConfiguration::kCheckHolder, V8DOMConfiguration::kAllWorlds } - , + { "workerExposedAttribute", V8TestInterface5::workerExposedAttributeAttributeGetterCallback, V8TestInterface5::workerExposedAttributeAttributeSetterCallback, V8PrivateProperty::kNoCachedAccessor, static_cast<v8::PropertyAttribute>(v8::None), V8DOMConfiguration::kOnPrototype, V8DOMConfiguration::kCheckHolder, V8DOMConfiguration::kAllWorlds }, }; V8DOMConfiguration::InstallAccessors( isolate, world, instanceObject, prototypeObject, interfaceObject, signature, accessor_configurations, WTF_ARRAY_LENGTH(accessor_configurations)); } - if (executionContext && (executionContext->IsWorkerGlobalScope())) { const V8DOMConfiguration::MethodConfiguration workerExposedMethodMethodConfiguration[] = { {"workerExposedMethod", V8TestInterface5::workerExposedMethodMethodCallback, 0, v8::None, V8DOMConfiguration::kOnPrototype, V8DOMConfiguration::kCheckHolder, V8DOMConfiguration::kDoNotCheckAccess, V8DOMConfiguration::kAllWorlds}
diff --git a/third_party/WebKit/Source/bindings/tests/results/modules/V8TestInterfacePartial.cpp b/third_party/WebKit/Source/bindings/tests/results/modules/V8TestInterfacePartial.cpp index 22f7f41..35bca78 100644 --- a/third_party/WebKit/Source/bindings/tests/results/modules/V8TestInterfacePartial.cpp +++ b/third_party/WebKit/Source/bindings/tests/results/modules/V8TestInterfacePartial.cpp
@@ -468,7 +468,6 @@ V8DOMConfiguration::InstallConstants( isolate, interfaceTemplate, prototypeTemplate, V8TestInterfaceConstants, WTF_ARRAY_LENGTH(V8TestInterfaceConstants)); - V8DOMConfiguration::InstallMethods( isolate, world, instanceTemplate, prototypeTemplate, interfaceTemplate, signature, V8TestInterfaceMethods, WTF_ARRAY_LENGTH(V8TestInterfaceMethods)); @@ -505,14 +504,14 @@ bool isSecureContext = (executionContext && executionContext->IsSecureContext()); if (isSecureContext) { static const V8DOMConfiguration::AccessorConfiguration accessorpartial4LongAttributeConfiguration[] = { - { "partial4LongAttribute", V8TestInterfacePartial::partial4LongAttributeAttributeGetterCallback, V8TestInterfacePartial::partial4LongAttributeAttributeSetterCallback, V8PrivateProperty::kNoCachedAccessor, static_cast<v8::PropertyAttribute>(v8::None), V8DOMConfiguration::kOnPrototype, V8DOMConfiguration::kCheckHolder, V8DOMConfiguration::kAllWorlds } + { "partial4LongAttribute", V8TestInterfacePartial::partial4LongAttributeAttributeGetterCallback, V8TestInterfacePartial::partial4LongAttributeAttributeSetterCallback, V8PrivateProperty::kNoCachedAccessor, static_cast<v8::PropertyAttribute>(v8::None), V8DOMConfiguration::kOnPrototype, V8DOMConfiguration::kCheckHolder, V8DOMConfiguration::kAllWorlds } }; for (const auto& accessorConfig : accessorpartial4LongAttributeConfiguration) V8DOMConfiguration::InstallAccessor(isolate, world, instance, prototype, interface, signature, accessorConfig); } if (isSecureContext) { static const V8DOMConfiguration::AccessorConfiguration accessorpartial4StaticLongAttributeConfiguration[] = { - { "partial4StaticLongAttribute", V8TestInterfacePartial::partial4StaticLongAttributeAttributeGetterCallback, V8TestInterfacePartial::partial4StaticLongAttributeAttributeSetterCallback, V8PrivateProperty::kNoCachedAccessor, static_cast<v8::PropertyAttribute>(v8::None), V8DOMConfiguration::kOnInterface, V8DOMConfiguration::kCheckHolder, V8DOMConfiguration::kAllWorlds } + { "partial4StaticLongAttribute", V8TestInterfacePartial::partial4StaticLongAttributeAttributeGetterCallback, V8TestInterfacePartial::partial4StaticLongAttributeAttributeSetterCallback, V8PrivateProperty::kNoCachedAccessor, static_cast<v8::PropertyAttribute>(v8::None), V8DOMConfiguration::kOnInterface, V8DOMConfiguration::kCheckHolder, V8DOMConfiguration::kAllWorlds } }; for (const auto& accessorConfig : accessorpartial4StaticLongAttributeConfiguration) V8DOMConfiguration::InstallAccessor(isolate, world, instance, prototype, interface, signature, accessorConfig);
diff --git a/third_party/WebKit/Source/bindings/tests/results/modules/V8TestSubObject.cpp b/third_party/WebKit/Source/bindings/tests/results/modules/V8TestSubObject.cpp index 27cc22d..07b29dd 100644 --- a/third_party/WebKit/Source/bindings/tests/results/modules/V8TestSubObject.cpp +++ b/third_party/WebKit/Source/bindings/tests/results/modules/V8TestSubObject.cpp
@@ -145,11 +145,8 @@ } static const V8DOMConfiguration::AccessorConfiguration V8TestSubObjectAccessors[] = { - { "unforgeableStringAttribute", V8TestSubObject::unforgeableStringAttributeAttributeGetterCallback, V8TestSubObject::unforgeableStringAttributeAttributeSetterCallback, V8PrivateProperty::kNoCachedAccessor, static_cast<v8::PropertyAttribute>(v8::DontDelete), V8DOMConfiguration::kOnInstance, V8DOMConfiguration::kCheckHolder, V8DOMConfiguration::kAllWorlds } -, - - { "unforgeableLongAttribute", V8TestSubObject::unforgeableLongAttributeAttributeGetterCallback, V8TestSubObject::unforgeableLongAttributeAttributeSetterCallback, V8PrivateProperty::kNoCachedAccessor, static_cast<v8::PropertyAttribute>(v8::DontDelete), V8DOMConfiguration::kOnInstance, V8DOMConfiguration::kCheckHolder, V8DOMConfiguration::kAllWorlds } -, + { "unforgeableStringAttribute", V8TestSubObject::unforgeableStringAttributeAttributeGetterCallback, V8TestSubObject::unforgeableStringAttributeAttributeSetterCallback, V8PrivateProperty::kNoCachedAccessor, static_cast<v8::PropertyAttribute>(v8::DontDelete), V8DOMConfiguration::kOnInstance, V8DOMConfiguration::kCheckHolder, V8DOMConfiguration::kAllWorlds }, + { "unforgeableLongAttribute", V8TestSubObject::unforgeableLongAttributeAttributeGetterCallback, V8TestSubObject::unforgeableLongAttributeAttributeSetterCallback, V8PrivateProperty::kNoCachedAccessor, static_cast<v8::PropertyAttribute>(v8::DontDelete), V8DOMConfiguration::kOnInstance, V8DOMConfiguration::kCheckHolder, V8DOMConfiguration::kAllWorlds }, }; static void installV8TestSubObjectTemplate(
diff --git a/third_party/WebKit/Source/core/editing/InlineBoxPosition.cpp b/third_party/WebKit/Source/core/editing/InlineBoxPosition.cpp index b3b70e1d..2813755b 100644 --- a/third_party/WebKit/Source/core/editing/InlineBoxPosition.cpp +++ b/third_party/WebKit/Source/core/editing/InlineBoxPosition.cpp
@@ -183,11 +183,8 @@ return InlineBoxPosition(result_box, result_box->CaretLeftmostOffset()); } - if (unicode_bidi == UnicodeBidi::kPlaintext) { - if (inline_box->BidiLevel() < level) - return InlineBoxPosition(inline_box, inline_box->CaretLeftmostOffset()); + if (unicode_bidi == UnicodeBidi::kPlaintext) return InlineBoxPosition(inline_box, inline_box->CaretRightmostOffset()); - } InlineBox* const next_box = inline_box->NextLeafChildIgnoringLineBreak(); if (!next_box || next_box->BidiLevel() < level) {
diff --git a/third_party/WebKit/Source/core/events/TouchEvent.cpp b/third_party/WebKit/Source/core/events/TouchEvent.cpp index 28fe1503..818d213cd 100644 --- a/third_party/WebKit/Source/core/events/TouchEvent.cpp +++ b/third_party/WebKit/Source/core/events/TouchEvent.cpp
@@ -261,9 +261,9 @@ UIEventWithKeyState::preventDefault(); // A common developer error is to wait too long before attempting to stop - // scrolling by consuming a touchmove event. Generate a warning if this + // scrolling by consuming a touchmove event. Generate an error if this // event is uncancelable. - String warning_message; + String message; switch (HandlingPassive()) { case PassiveMode::kNotPassive: case PassiveMode::kNotPassiveDefault: @@ -285,17 +285,17 @@ WebFeature:: kUncancelableTouchEventDueToMainThreadResponsivenessPreventDefaulted); } - warning_message = + message = "Ignored attempt to cancel a " + type() + " event with cancelable=false. This event was forced to be " "non-cancellable because the page was too busy to handle the " "event promptly."; } else { // Non blocking for any other reason. - warning_message = "Ignored attempt to cancel a " + type() + - " event with cancelable=false, for example " - "because scrolling is in progress and " - "cannot be interrupted."; + message = "Ignored attempt to cancel a " + type() + + " event with cancelable=false, for example " + "because scrolling is in progress and " + "cannot be interrupted."; } } break; @@ -304,7 +304,7 @@ // an author may use touch action but call preventDefault for interop with // browsers that don't support touch-action. if (current_touch_action_ == TouchAction::kTouchActionAuto) { - warning_message = + message = "Unable to preventDefault inside passive event listener due to " "target being treated as passive. See " "https://www.chromestatus.com/features/5093566007214080"; @@ -314,10 +314,9 @@ break; } - if (!warning_message.IsEmpty() && view() && view()->IsLocalDOMWindow() && + if (!message.IsEmpty() && view() && view()->IsLocalDOMWindow() && view()->GetFrame()) { - Intervention::GenerateReport(ToLocalDOMWindow(view())->GetFrame(), - warning_message); + Intervention::GenerateReport(ToLocalDOMWindow(view())->GetFrame(), message); } if ((type() == EventTypeNames::touchstart ||
diff --git a/third_party/WebKit/Source/core/exported/LocalFrameClientImpl.cpp b/third_party/WebKit/Source/core/exported/LocalFrameClientImpl.cpp index af49c64f..836f371d 100644 --- a/third_party/WebKit/Source/core/exported/LocalFrameClientImpl.cpp +++ b/third_party/WebKit/Source/core/exported/LocalFrameClientImpl.cpp
@@ -521,7 +521,8 @@ WebTriggeringEventInfo triggering_event_info, HTMLFormElement* form, ContentSecurityPolicyDisposition - should_check_main_world_content_security_policy) { + should_check_main_world_content_security_policy, + mojom::blink::BlobURLTokenPtr blob_url_token) { if (!web_frame_->Client()) return kNavigationPolicyIgnore; @@ -548,6 +549,7 @@ kCheckContentSecurityPolicy ? kWebContentSecurityPolicyDispositionCheck : kWebContentSecurityPolicyDispositionDoNotCheck; + navigation_info.blob_url_token = blob_url_token.PassInterface().PassHandle(); // Can be null. LocalFrame* local_parent_frame = GetLocalParentFrame(web_frame_);
diff --git a/third_party/WebKit/Source/core/exported/LocalFrameClientImpl.h b/third_party/WebKit/Source/core/exported/LocalFrameClientImpl.h index e481c11..113f440b 100644 --- a/third_party/WebKit/Source/core/exported/LocalFrameClientImpl.h +++ b/third_party/WebKit/Source/core/exported/LocalFrameClientImpl.h
@@ -122,7 +122,8 @@ bool is_client_redirect, WebTriggeringEventInfo, HTMLFormElement*, - ContentSecurityPolicyDisposition should_bypass_main_world_csp) override; + ContentSecurityPolicyDisposition should_bypass_main_world_csp, + mojom::blink::BlobURLTokenPtr) override; void DispatchWillSendSubmitEvent(HTMLFormElement*) override; void DispatchWillSubmitForm(HTMLFormElement*) override; void DidStartLoading(LoadStartType) override;
diff --git a/third_party/WebKit/Source/core/exported/WebDocumentLoaderImpl.cpp b/third_party/WebKit/Source/core/exported/WebDocumentLoaderImpl.cpp index 025b62a..db76473 100644 --- a/third_party/WebKit/Source/core/exported/WebDocumentLoaderImpl.cpp +++ b/third_party/WebKit/Source/core/exported/WebDocumentLoaderImpl.cpp
@@ -37,6 +37,9 @@ #include "core/dom/Document.h" #include "core/frame/LocalFrame.h" #include "core/loader/SubresourceFilter.h" +#include "platform/loader/fetch/ResourceFetcher.h" +#include "platform/mhtml/ArchiveResource.h" +#include "platform/mhtml/MHTMLArchive.h" #include "public/platform/WebDocumentSubresourceFilter.h" #include "public/platform/WebURL.h" #include "public/platform/WebURLError.h" @@ -214,6 +217,15 @@ DocumentLoader::ResumeParser(); } +bool WebDocumentLoaderImpl::IsArchive() const { + return Fetcher()->Archive(); +} + +WebArchiveInfo WebDocumentLoaderImpl::GetArchiveInfo() const { + const MHTMLArchive* archive = Fetcher()->Archive(); + return {archive->MainResource()->Url(), archive->Date()}; +} + void WebDocumentLoaderImpl::Trace(blink::Visitor* visitor) { DocumentLoader::Trace(visitor); }
diff --git a/third_party/WebKit/Source/core/exported/WebDocumentLoaderImpl.h b/third_party/WebKit/Source/core/exported/WebDocumentLoaderImpl.h index 4785077..1760af687 100644 --- a/third_party/WebKit/Source/core/exported/WebDocumentLoaderImpl.h +++ b/third_party/WebKit/Source/core/exported/WebDocumentLoaderImpl.h
@@ -88,6 +88,8 @@ bool GetIsAdSubframe() const override; void BlockParser() override; void ResumeParser() override; + bool IsArchive() const override; + WebArchiveInfo GetArchiveInfo() const override; static WebNavigationType ToWebNavigationType(NavigationType);
diff --git a/third_party/WebKit/Source/core/exported/WebFrameContentDumper.cpp b/third_party/WebKit/Source/core/exported/WebFrameContentDumper.cpp index ae0b3c8..5545e17 100644 --- a/third_party/WebKit/Source/core/exported/WebFrameContentDumper.cpp +++ b/third_party/WebKit/Source/core/exported/WebFrameContentDumper.cpp
@@ -306,18 +306,9 @@ size_t max_chars) { if (!frame) return WebString(); - LocalFrame* local_frame = ToWebLocalFrameImpl(frame)->GetFrame(); - // TODO(crbug.com/586241): We shoulndn't reach here with dirty layout as the - // function is called in DidMeaningfulLayout(); However, we still see this in - // the wild. As a workaround, we dump |textContent| instead when layout is - // dirty. We should always dump |innerText| when the bug is fixed. - bool needs_layout = local_frame->View()->NeedsLayout() || - local_frame->GetDocument()->NeedsLayoutTreeUpdate(); StringBuilder text; - FrameContentAsPlainText(max_chars, local_frame, - needs_layout ? TextDumpOption::kDumpTextContent - : TextDumpOption::kDumpInnerText, - text); + FrameContentAsPlainText(max_chars, ToWebLocalFrameImpl(frame)->GetFrame(), + TextDumpOption::kDumpTextContent, text); return text.ToString(); }
diff --git a/third_party/WebKit/Source/core/exported/WebFrameSerializer.cpp b/third_party/WebKit/Source/core/exported/WebFrameSerializer.cpp index 651e41d..846697a 100644 --- a/third_party/WebKit/Source/core/exported/WebFrameSerializer.cpp +++ b/third_party/WebKit/Source/core/exported/WebFrameSerializer.cpp
@@ -67,6 +67,7 @@ #include "platform/wtf/Deque.h" #include "platform/wtf/HashMap.h" #include "platform/wtf/HashSet.h" +#include "platform/wtf/Time.h" #include "platform/wtf/Vector.h" #include "platform/wtf/text/StringConcatenate.h" #include "public/platform/WebString.h" @@ -457,7 +458,7 @@ scoped_refptr<RawData> buffer = RawData::Create(); MHTMLArchive::GenerateMHTMLHeader( boundary, document->Url(), document->title(), - document->SuggestedMIMEType(), *buffer->MutableData()); + document->SuggestedMIMEType(), WTF::Time::Now(), *buffer->MutableData()); return WebThreadSafeData(buffer); }
diff --git a/third_party/WebKit/Source/core/exported/WebPluginContainerImpl.cpp b/third_party/WebKit/Source/core/exported/WebPluginContainerImpl.cpp index 98d3d11c..5d52ec9 100644 --- a/third_party/WebKit/Source/core/exported/WebPluginContainerImpl.cpp +++ b/third_party/WebKit/Source/core/exported/WebPluginContainerImpl.cpp
@@ -936,11 +936,9 @@ // Translate the root frame position to content coordinates. absolute_location = parent.RootFrameToContents(absolute_location); - IntPoint local_point = - RoundedIntPoint(element_->GetLayoutObject()->AbsoluteToLocal( - absolute_location, kUseTransforms)); - transformed_event.touches[i].SetPositionInWidget(local_point.X(), - local_point.Y()); + FloatPoint local_point = element_->GetLayoutObject()->AbsoluteToLocal( + absolute_location, kUseTransforms); + transformed_event.touches[i].SetPositionInWidget(local_point); } return transformed_event; }
diff --git a/third_party/WebKit/Source/core/fileapi/PublicURLManager.cpp b/third_party/WebKit/Source/core/fileapi/PublicURLManager.cpp index 38d5113a..8a65267 100644 --- a/third_party/WebKit/Source/core/fileapi/PublicURLManager.cpp +++ b/third_party/WebKit/Source/core/fileapi/PublicURLManager.cpp
@@ -168,6 +168,18 @@ url_store_->ResolveAsURLLoaderFactory(url, std::move(factory_request)); } +void PublicURLManager::Resolve( + const KURL& url, + mojom::blink::BlobURLTokenRequest token_request) { + DCHECK(RuntimeEnabledFeatures::MojoBlobURLsEnabled()); + DCHECK(url.ProtocolIs("blob")); + if (!url_store_) { + BlobDataHandle::GetBlobRegistry()->URLStoreForOrigin( + GetExecutionContext()->GetSecurityOrigin(), MakeRequest(&url_store_)); + } + url_store_->ResolveForNavigation(url, std::move(token_request)); +} + void PublicURLManager::ContextDestroyed(ExecutionContext*) { if (is_stopped_) return;
diff --git a/third_party/WebKit/Source/core/fileapi/PublicURLManager.h b/third_party/WebKit/Source/core/fileapi/PublicURLManager.h index 23584e98..1f8c4a19 100644 --- a/third_party/WebKit/Source/core/fileapi/PublicURLManager.h +++ b/third_party/WebKit/Source/core/fileapi/PublicURLManager.h
@@ -59,6 +59,11 @@ // When mojo Blob URLs are enabled this resolves the provided URL to a // factory capable of creating loaders for the specific URL. void Resolve(const KURL&, network::mojom::blink::URLLoaderFactoryRequest); + // When mojo Blob URLs are enabled this resolves the provided URL to a mojom + // BlobURLToken. This token can be used by the browser process to securely + // lookup what blob a URL used to refer to, even after the URL is revoked. + // If the URL fails to resolve the request will simply be disconnected. + void Resolve(const KURL&, mojom::blink::BlobURLTokenRequest); // ContextLifecycleObserver interface. void ContextDestroyed(ExecutionContext*) override;
diff --git a/third_party/WebKit/Source/core/frame/Intervention.cpp b/third_party/WebKit/Source/core/frame/Intervention.cpp index 089eb6a..482f234 100644 --- a/third_party/WebKit/Source/core/frame/Intervention.cpp +++ b/third_party/WebKit/Source/core/frame/Intervention.cpp
@@ -25,7 +25,7 @@ // Send the message to the console. frame->Console().AddMessage(ConsoleMessage::Create( - kInterventionMessageSource, kWarningMessageLevel, message)); + kInterventionMessageSource, kErrorMessageLevel, message)); if (!frame->Client()) return;
diff --git a/third_party/WebKit/Source/core/frame/LocalFrameClient.h b/third_party/WebKit/Source/core/frame/LocalFrameClient.h index afc7080..94fe9d6 100644 --- a/third_party/WebKit/Source/core/frame/LocalFrameClient.h +++ b/third_party/WebKit/Source/core/frame/LocalFrameClient.h
@@ -149,7 +149,8 @@ WebTriggeringEventInfo, HTMLFormElement*, ContentSecurityPolicyDisposition - should_check_main_world_content_security_policy) = 0; + should_check_main_world_content_security_policy, + mojom::blink::BlobURLTokenPtr) = 0; virtual void DispatchWillSendSubmitEvent(HTMLFormElement*) = 0; virtual void DispatchWillSubmitForm(HTMLFormElement*) = 0;
diff --git a/third_party/WebKit/Source/core/frame/MHTMLArchiveTest.cpp b/third_party/WebKit/Source/core/frame/MHTMLArchiveTest.cpp index 8598791..e005650 100644 --- a/third_party/WebKit/Source/core/frame/MHTMLArchiveTest.cpp +++ b/third_party/WebKit/Source/core/frame/MHTMLArchiveTest.cpp
@@ -31,6 +31,7 @@ #include <map> #include "build/build_config.h" +#include "platform/DateComponents.h" #include "platform/SerializedResource.h" #include "platform/SharedBuffer.h" #include "platform/mhtml/MHTMLArchive.h" @@ -40,6 +41,7 @@ #include "platform/testing/UnitTestHelpers.h" #include "platform/weborigin/KURL.h" #include "platform/weborigin/SchemeRegistry.h" +#include "platform/wtf/Time.h" #include "testing/gtest/include/gtest/gtest.h" using blink::URLTestHelpers::ToKURL; @@ -58,6 +60,8 @@ public: MHTMLArchiveTest() { file_path_ = test::CoreTestDataPath("frameserializer/css/"); + mhtml_date_ = WTF::Time::FromJsTime(1520551829000); + mhtml_date_header_ = String::FromUTF8("Fri, 8 Mar 2018 23:30:29 -0000"); } protected: @@ -146,7 +150,7 @@ String boundary = String::FromUTF8("boundary-example"); MHTMLArchive::GenerateMHTMLHeader(boundary, url, title, mime_type, - mhtml_data_); + mhtml_date_, mhtml_data_); for (const auto& resource : resources) { MHTMLArchive::GenerateMHTMLPart(boundary, String(), encoding_policy, resource, mhtml_data_); @@ -169,6 +173,9 @@ Vector<char>& mhtml_data() { return mhtml_data_; } + WTF::Time mhtml_date() const { return mhtml_date_; } + const String& mhtml_date_header() const { return mhtml_date_header_; } + private: scoped_refptr<SharedBuffer> ReadFile(const char* file_name) { String file_path = file_path_ + file_name; @@ -178,6 +185,8 @@ String file_path_; Vector<SerializedResource> resources_; Vector<char> mhtml_data_; + WTF::Time mhtml_date_; + String mhtml_date_header_; }; TEST_F(MHTMLArchiveTest, @@ -342,5 +351,27 @@ EXPECT_NE(nullptr, MHTMLArchive::Create(special_scheme_url, data.get())); } +TEST_F(MHTMLArchiveTest, MHTMLDate) { + const char kURL[] = "http://www.example.com"; + AddTestMainResource(); + Serialize(ToKURL(kURL), "Test Serialization", "text/html", + MHTMLArchive::kUseDefaultEncoding); + // The serialization process should have added a date header corresponding to + // mhtml_date(). + std::map<std::string, std::string> mhtml_headers = ExtractMHTMLHeaders(); + ASSERT_EQ(mhtml_date_header(), + String::FromUTF8(mhtml_headers["Date"].c_str())); + + scoped_refptr<SharedBuffer> data = + SharedBuffer::Create(mhtml_data().data(), mhtml_data().size()); + KURL http_url = ToKURL("http://www.example.com"); + MHTMLArchive* archive = MHTMLArchive::Create(http_url, data.get()); + ASSERT_NE(nullptr, archive); + + // The deserialization process should have parsed the header into a Date. + EXPECT_EQ(mhtml_date(), archive->Date()); +} + } // namespace test + } // namespace blink
diff --git a/third_party/WebKit/Source/core/input/GestureManager.cpp b/third_party/WebKit/Source/core/input/GestureManager.cpp index 87728986..044c337 100644 --- a/third_party/WebKit/Source/core/input/GestureManager.cpp +++ b/third_party/WebKit/Source/core/input/GestureManager.cpp
@@ -350,6 +350,12 @@ mouse_event_manager_->FocusDocumentView(); } + if (frame_->GetSettings() && + frame_->GetSettings()->GetShowContextMenuOnMouseUp()) { + long_tap_should_invoke_context_menu_ = true; + return WebInputEventResult::kNotHandled; + } + return SendContextMenuEventForGesture(targeted_event); } @@ -358,9 +364,6 @@ #if !defined(OS_ANDROID) if (long_tap_should_invoke_context_menu_) { long_tap_should_invoke_context_menu_ = false; - Node* inner_node = targeted_event.GetHitTestResult().InnerNode(); - if (inner_node && inner_node->GetLayoutObject()) - selection_controller_->HandleGestureLongTap(targeted_event); return SendContextMenuEventForGesture(targeted_event); } #endif
diff --git a/third_party/WebKit/Source/core/inspector/InspectorPageAgent.cpp b/third_party/WebKit/Source/core/inspector/InspectorPageAgent.cpp index b239fed..337816c0 100644 --- a/third_party/WebKit/Source/core/inspector/InspectorPageAgent.cpp +++ b/third_party/WebKit/Source/core/inspector/InspectorPageAgent.cpp
@@ -937,15 +937,13 @@ .setSecurityOrigin(SecurityOrigin::Create(url)->ToRawString()) .build(); Frame* parent_frame = frame->Tree().Parent(); - if (parent_frame) + if (parent_frame) { frame_object->setParentId(IdentifiersFactory::FrameId(parent_frame)); - if (frame->DeprecatedLocalOwner()) { - AtomicString name = frame->DeprecatedLocalOwner()->GetNameAttribute(); - if (name.IsEmpty()) + AtomicString name = frame->Tree().GetName(); + if (name.IsEmpty() && frame->DeprecatedLocalOwner()) name = frame->DeprecatedLocalOwner()->getAttribute(HTMLNames::idAttr); frame_object->setName(name); } - if (loader && !loader->UnreachableURL().IsEmpty()) frame_object->setUnreachableUrl(loader->UnreachableURL().GetString()); return frame_object;
diff --git a/third_party/WebKit/Source/core/layout/ng/inline/ng_line_breaker.cc b/third_party/WebKit/Source/core/layout/ng/inline/ng_line_breaker.cc index 34f300e..2eb1f5ed 100644 --- a/third_party/WebKit/Source/core/layout/ng/inline/ng_line_breaker.cc +++ b/third_party/WebKit/Source/core/layout/ng/inline/ng_line_breaker.cc
@@ -329,10 +329,9 @@ if (!is_overflow || state == LineBreakState::kTrailing) { if (item_result->end_offset < item.EndOffset()) { - // The break point found, and text follows. Break here. - HandleTrailingSpaces(item, line_info); - line_info->SetIsLastLine(false); - return LineBreakState::kDone; + // The break point found, and text follows. Break here, after trailing + // spaces. + return HandleTrailingSpaces(item, line_info); } // The break point found, but items that prohibit breaking before them may
diff --git a/third_party/WebKit/Source/core/loader/EmptyClients.cpp b/third_party/WebKit/Source/core/loader/EmptyClients.cpp index 1544926..71d786bb 100644 --- a/third_party/WebKit/Source/core/loader/EmptyClients.cpp +++ b/third_party/WebKit/Source/core/loader/EmptyClients.cpp
@@ -102,7 +102,8 @@ bool, WebTriggeringEventInfo, HTMLFormElement*, - ContentSecurityPolicyDisposition) { + ContentSecurityPolicyDisposition, + mojom::blink::BlobURLTokenPtr) { return kNavigationPolicyIgnore; }
diff --git a/third_party/WebKit/Source/core/loader/EmptyClients.h b/third_party/WebKit/Source/core/loader/EmptyClients.h index 37e2da7..e672edd6 100644 --- a/third_party/WebKit/Source/core/loader/EmptyClients.h +++ b/third_party/WebKit/Source/core/loader/EmptyClients.h
@@ -275,7 +275,8 @@ bool, WebTriggeringEventInfo, HTMLFormElement*, - ContentSecurityPolicyDisposition) override; + ContentSecurityPolicyDisposition, + mojom::blink::BlobURLTokenPtr) override; void DispatchWillSendSubmitEvent(HTMLFormElement*) override; void DispatchWillSubmitForm(HTMLFormElement*) override;
diff --git a/third_party/WebKit/Source/core/loader/FrameLoadRequest.cpp b/third_party/WebKit/Source/core/loader/FrameLoadRequest.cpp index a39b4a8..1b68112 100644 --- a/third_party/WebKit/Source/core/loader/FrameLoadRequest.cpp +++ b/third_party/WebKit/Source/core/loader/FrameLoadRequest.cpp
@@ -4,6 +4,7 @@ #include "core/loader/FrameLoadRequest.h" +#include "core/fileapi/PublicURLManager.h" #include "platform/loader/fetch/ResourceRequest.h" #include "platform/wtf/text/AtomicString.h" #include "public/platform/WebURLRequest.h" @@ -93,6 +94,14 @@ DCHECK(!resource_request_.RequestorOrigin()); resource_request_.SetRequestorOrigin( SecurityOrigin::Create(origin_document->Url())); + + if (resource_request.Url().ProtocolIs("blob") && + RuntimeEnabledFeatures::MojoBlobURLsEnabled()) { + blob_url_token_ = base::MakeRefCounted< + base::RefCountedData<mojom::blink::BlobURLTokenPtr>>(); + origin_document->GetPublicURLManager().Resolve( + resource_request.Url(), MakeRequest(&blob_url_token_->data)); + } } }
diff --git a/third_party/WebKit/Source/core/loader/FrameLoadRequest.h b/third_party/WebKit/Source/core/loader/FrameLoadRequest.h index 03ac014..257cfa3a 100644 --- a/third_party/WebKit/Source/core/loader/FrameLoadRequest.h +++ b/third_party/WebKit/Source/core/loader/FrameLoadRequest.h
@@ -115,6 +115,30 @@ return devtools_navigation_token_; } + // Sets the BlobURLToken that should be used when fetching the resource. This + // is needed for blob URLs, because the blob URL might be revoked before the + // actual fetch happens, which would result in incorrect failures to fetch. + // The token lets the browser process securely resolves the blob URL even + // after the url has been revoked. + // FrameFetchRequest initializes this in its constructor, but in some cases + // FrameFetchRequest is created asynchronously rather than when a navigation + // is scheduled, so in those cases NavigationScheduler needs to override the + // blob FrameLoadRequest might have found. + void SetBlobURLToken(mojom::blink::BlobURLTokenPtr blob_url_token) { + DCHECK(blob_url_token); + blob_url_token_ = base::MakeRefCounted< + base::RefCountedData<mojom::blink::BlobURLTokenPtr>>( + std::move(blob_url_token)); + } + + mojom::blink::BlobURLTokenPtr GetBlobURLToken() const { + if (!blob_url_token_) + return nullptr; + mojom::blink::BlobURLTokenPtr result; + blob_url_token_->data->Clone(MakeRequest(&result)); + return result; + } + private: FrameLoadRequest(Document* origin_document, const ResourceRequest&, @@ -136,6 +160,8 @@ ContentSecurityPolicyDisposition should_check_main_world_content_security_policy_; base::UnguessableToken devtools_navigation_token_; + scoped_refptr<base::RefCountedData<mojom::blink::BlobURLTokenPtr>> + blob_url_token_; }; } // namespace blink
diff --git a/third_party/WebKit/Source/core/loader/FrameLoader.cpp b/third_party/WebKit/Source/core/loader/FrameLoader.cpp index 3f556b9..74d334bd 100644 --- a/third_party/WebKit/Source/core/loader/FrameLoader.cpp +++ b/third_party/WebKit/Source/core/loader/FrameLoader.cpp
@@ -1413,7 +1413,8 @@ FrameLoadType frame_load_type, bool is_client_redirect, WebTriggeringEventInfo triggering_event_info, - HTMLFormElement* form) { + HTMLFormElement* form, + mojom::blink::BlobURLTokenPtr blob_url_token) { // Don't ask if we are loading an empty URL. if (request.Url().IsEmpty() || substitute_data.IsValid()) return kNavigationPolicyCurrentTab; @@ -1442,7 +1443,8 @@ policy = Client()->DecidePolicyForNavigation( request, origin_document, loader, type, policy, replaces_current_history_item, is_client_redirect, triggering_event_info, - form, should_check_main_world_content_security_policy); + form, should_check_main_world_content_security_policy, + std::move(blob_url_token)); DCHECK(policy == kNavigationPolicyCurrentTab || policy == kNavigationPolicyIgnore || policy == kNavigationPolicyHandledByClient || @@ -1479,7 +1481,8 @@ nullptr, // origin_document substitute_data, loader, should_check_main_world_content_security_policy, type, policy, frame_load_type, is_client_redirect, - WebTriggeringEventInfo::kNotFromEvent, form); + WebTriggeringEventInfo::kNotFromEvent, form, + nullptr /* blob_url_token */); } void FrameLoader::ClientDroppedNavigation() { @@ -1528,7 +1531,8 @@ navigation_type, navigation_policy, type, frame_load_request.ClientRedirect() == ClientRedirectPolicy::kClientRedirect, - triggering_event_info, frame_load_request.Form()); + triggering_event_info, frame_load_request.Form(), + frame_load_request.GetBlobURLToken()); } void FrameLoader::StartLoad(FrameLoadRequest& frame_load_request,
diff --git a/third_party/WebKit/Source/core/loader/FrameLoader.h b/third_party/WebKit/Source/core/loader/FrameLoader.h index 3397190..37404b6b 100644 --- a/third_party/WebKit/Source/core/loader/FrameLoader.h +++ b/third_party/WebKit/Source/core/loader/FrameLoader.h
@@ -52,6 +52,7 @@ #include "public/platform/WebInsecureRequestPolicy.h" #include "public/web/WebTriggeringEventInfo.h" #include "public/web/commit_result.mojom-shared.h" +#include "third_party/WebKit/public/mojom/blob/blob_url_store.mojom-blink.h" #include <memory> @@ -207,7 +208,8 @@ FrameLoadType, bool is_client_redirect, WebTriggeringEventInfo, - HTMLFormElement*); + HTMLFormElement*, + mojom::blink::BlobURLTokenPtr); // Like ShouldContinueForNavigationPolicy, but should be used when following // redirects.
diff --git a/third_party/WebKit/Source/core/loader/NavigationScheduler.cpp b/third_party/WebKit/Source/core/loader/NavigationScheduler.cpp index e943c95..b215571 100644 --- a/third_party/WebKit/Source/core/loader/NavigationScheduler.cpp +++ b/third_party/WebKit/Source/core/loader/NavigationScheduler.cpp
@@ -36,6 +36,7 @@ #include "bindings/core/v8/ScriptController.h" #include "core/dom/UserGestureIndicator.h" #include "core/dom/events/Event.h" +#include "core/fileapi/PublicURLManager.h" #include "core/frame/Deprecation.h" #include "core/frame/LocalFrame.h" #include "core/frame/LocalFrameClient.h" @@ -129,6 +130,12 @@ should_check_main_world_content_security_policy_ = kDoNotCheckContentSecurityPolicy; } + + if (origin_document && url.ProtocolIs("blob") && + RuntimeEnabledFeatures::MojoBlobURLsEnabled()) { + origin_document->GetPublicURLManager().Resolve( + url_, MakeRequest(&blob_url_token_)); + } } void Fire(LocalFrame* frame) override { @@ -139,6 +146,12 @@ request.SetReplacesCurrentItem(ReplacesCurrentItem()); request.SetClientRedirect(ClientRedirectPolicy::kClientRedirect); + if (blob_url_token_) { + mojom::blink::BlobURLTokenPtr token_clone; + blob_url_token_->Clone(MakeRequest(&token_clone)); + request.SetBlobURLToken(std::move(token_clone)); + } + ScheduledNavigationType type = IsLocationChange() ? ScheduledNavigationType::kScheduledFrameNavigation : ScheduledNavigationType::kScheduledURLNavigation; @@ -150,6 +163,7 @@ private: KURL url_; + mojom::blink::BlobURLTokenPtr blob_url_token_; ContentSecurityPolicyDisposition should_check_main_world_content_security_policy_; };
diff --git a/third_party/WebKit/Source/core/paint/PaintInvalidationTest.cpp b/third_party/WebKit/Source/core/paint/PaintInvalidationTest.cpp index bd9fbd7..38d1284 100644 --- a/third_party/WebKit/Source/core/paint/PaintInvalidationTest.cpp +++ b/third_party/WebKit/Source/core/paint/PaintInvalidationTest.cpp
@@ -303,6 +303,45 @@ GetDocument().View()->SetTracksPaintInvalidations(false); } +TEST_P(PaintInvalidationTest, UpdateVisualRectWhenPrinting) { + SetBodyInnerHTML(R"HTML( + <style> + * { margin: 0;} + span { + display: inline-block; + width: 150px; + height: 20px; + background: rebeccapurple; + } + </style> + <div><span id="a"></span><span id="b"></span><span id="c"></div> + )HTML"); + + auto* a = GetDocument().getElementById("a")->GetLayoutObject(); + EXPECT_EQ(LayoutRect(0, 0, 150, 20), a->FirstFragment().VisualRect()); + auto* b = GetDocument().getElementById("b")->GetLayoutObject(); + EXPECT_EQ(LayoutRect(150, 0, 150, 20), b->FirstFragment().VisualRect()); + auto* c = GetDocument().getElementById("c")->GetLayoutObject(); + EXPECT_EQ(LayoutRect(300, 0, 150, 20), c->FirstFragment().VisualRect()); + + // Print the page with a width of 400px which will require wrapping 'c'. + FloatSize page_size(400, 200); + GetFrame().StartPrinting(page_size, page_size, 1); + GetDocument().View()->UpdateLifecyclePhasesForPrinting(); + + EXPECT_EQ(LayoutRect(0, 0, 150, 20), a->FirstFragment().VisualRect()); + EXPECT_EQ(LayoutRect(150, 0, 150, 20), b->FirstFragment().VisualRect()); + // 'c' should be on the next line. + EXPECT_EQ(LayoutRect(0, 20, 150, 20), c->FirstFragment().VisualRect()); + + GetFrame().EndPrinting(); + GetDocument().View()->UpdateLifecyclePhasesForPrinting(); + + EXPECT_EQ(LayoutRect(0, 0, 150, 20), a->FirstFragment().VisualRect()); + EXPECT_EQ(LayoutRect(150, 0, 150, 20), b->FirstFragment().VisualRect()); + EXPECT_EQ(LayoutRect(300, 0, 150, 20), c->FirstFragment().VisualRect()); +}; + } // namespace } // namespace blink
diff --git a/third_party/WebKit/Source/core/paint/PaintInvalidator.cpp b/third_party/WebKit/Source/core/paint/PaintInvalidator.cpp index 910013b..d40d440 100644 --- a/third_party/WebKit/Source/core/paint/PaintInvalidator.cpp +++ b/third_party/WebKit/Source/core/paint/PaintInvalidator.cpp
@@ -559,9 +559,6 @@ UpdatePaintingLayer(object, context); - if (document_printing_ && !RuntimeEnabledFeatures::PrintBrowserEnabled()) - return; // Don't invalidate paints if we're printing. - // TODO(chrishtr): refactor to remove these slow paths by expanding their // LocalVisualRect to include repeated locations. if (object.IsTableSection()) {
diff --git a/third_party/WebKit/Source/core/paint/PaintInvalidator.h b/third_party/WebKit/Source/core/paint/PaintInvalidator.h index e5f50dc..0ef102ba 100644 --- a/third_party/WebKit/Source/core/paint/PaintInvalidator.h +++ b/third_party/WebKit/Source/core/paint/PaintInvalidator.h
@@ -182,7 +182,6 @@ PaintInvalidatorContext&); Vector<const LayoutObject*> pending_delayed_paint_invalidations_; - bool document_printing_ = false; }; } // namespace blink
diff --git a/third_party/WebKit/Source/core/paint/PrePaintTreeWalk.cpp b/third_party/WebKit/Source/core/paint/PrePaintTreeWalk.cpp index b5ed32b7..39f9975 100644 --- a/third_party/WebKit/Source/core/paint/PrePaintTreeWalk.cpp +++ b/third_party/WebKit/Source/core/paint/PrePaintTreeWalk.cpp
@@ -90,9 +90,6 @@ auto context = [this]() -> PrePaintTreeWalkContext& { return context_storage_.back(); }; - AutoReset<bool> printing_reset( - &paint_invalidator_.document_printing_, - frame_view.GetFrame().GetDocument()->Printing()); // ancestorOverflowLayer does not cross frame boundaries. context().ancestor_overflow_paint_layer = nullptr;
diff --git a/third_party/WebKit/Source/core/paint/SVGMaskPainter.cpp b/third_party/WebKit/Source/core/paint/SVGMaskPainter.cpp index 6f5f8a99..cf96c71 100644 --- a/third_party/WebKit/Source/core/paint/SVGMaskPainter.cpp +++ b/third_party/WebKit/Source/core/paint/SVGMaskPainter.cpp
@@ -50,10 +50,14 @@ Optional<ScopedPaintChunkProperties> scoped_paint_chunk_properties; if (RuntimeEnabledFeatures::SlimmingPaintV175Enabled()) { const auto* properties = object.FirstFragment().PaintProperties(); - DCHECK(properties && properties->Mask()); - scoped_paint_chunk_properties.emplace(context.GetPaintController(), - properties->Mask(), object, - DisplayItem::kSVGMask); + // TODO(crbug.com/814815): This condition should be a DCHECK, but for now + // we may paint the object for filters during PrePaint before the + // properties are ready. + if (properties && properties->Mask()) { + scoped_paint_chunk_properties.emplace(context.GetPaintController(), + properties->Mask(), object, + DisplayItem::kSVGMask); + } } DrawMaskForLayoutObject(context, object, object.ObjectBoundingBox());
diff --git a/third_party/WebKit/Source/devtools/front_end/elements/StylePropertyTreeElement.js b/third_party/WebKit/Source/devtools/front_end/elements/StylePropertyTreeElement.js index 206e5d1..167949b 100644 --- a/third_party/WebKit/Source/devtools/front_end/elements/StylePropertyTreeElement.js +++ b/third_party/WebKit/Source/devtools/front_end/elements/StylePropertyTreeElement.js
@@ -34,6 +34,7 @@ this._originalPropertyText = ''; this._prompt = null; this._propertyHasBeenEditedIncrementally = false; + this._lastComputedValue = null; } /** @@ -280,7 +281,7 @@ _updatePane() { const section = this.section(); if (section) - section.refreshUpdate(); + section.refreshUpdate(this); } /** @@ -378,7 +379,20 @@ this._expandElement.setIconType('smallicon-triangle-right'); } + updateTitleIfComputedValueChanged() { + const computedValue = this._matchedStyles.computeValue(this.property.ownerStyle, this.property.value); + if (computedValue === this._lastComputedValue) + return; + this._lastComputedValue = computedValue; + this._innerUpdateTitle(); + } + updateTitle() { + this._lastComputedValue = this._matchedStyles.computeValue(this.property.ownerStyle, this.property.value); + this._innerUpdateTitle(); + } + + _innerUpdateTitle() { this._updateState(); if (this.isExpandable()) this._expandElement = UI.Icon.create('smallicon-triangle-right', 'expand-icon');
diff --git a/third_party/WebKit/Source/devtools/front_end/elements/StylesSidebarPane.js b/third_party/WebKit/Source/devtools/front_end/elements/StylesSidebarPane.js index 487f5ca..7e03c2f0 100644 --- a/third_party/WebKit/Source/devtools/front_end/elements/StylesSidebarPane.js +++ b/third_party/WebKit/Source/devtools/front_end/elements/StylesSidebarPane.js
@@ -297,9 +297,18 @@ } /** - * @param {!Elements.StylePropertiesSection=} editedSection + * @param {!Elements.StylePropertiesSection} editedSection + * @param {!Elements.StylePropertyTreeElement=} editedTreeElement */ - _refreshUpdate(editedSection) { + _refreshUpdate(editedSection, editedTreeElement) { + if (editedTreeElement) { + for (const section of this.allSections()) { + if (section.isBlank) + continue; + section._updateVarFunctions(editedTreeElement); + } + } + if (this._isEditingStyle) return; const node = this.node(); @@ -1276,8 +1285,23 @@ return (curSection && curSection.editable) ? curSection : null; } - refreshUpdate() { - this._parentPane._refreshUpdate(this); + /** + * @param {!Elements.StylePropertyTreeElement} editedTreeElement + */ + refreshUpdate(editedTreeElement) { + this._parentPane._refreshUpdate(this, editedTreeElement); + } + + /** + * @param {!Elements.StylePropertyTreeElement} editedTreeElement + */ + _updateVarFunctions(editedTreeElement) { + let child = this.propertiesTreeOutline.firstChild(); + while (child) { + if (child !== editedTreeElement) + child.updateTitleIfComputedValueChanged(); + child = child.traverseNextTreeElement(false /* skipUnrevealed */, null /* stayWithin */, true /* dontPopulate */); + } } /** @@ -1292,7 +1316,8 @@ let child = this.propertiesTreeOutline.firstChild(); while (child) { child.setOverloaded(this._isPropertyOverloaded(child.property)); - child = child.traverseNextTreeElement(false, null, true); + child = + child.traverseNextTreeElement(false /* skipUnrevealed */, null /* stayWithin */, true /* dontPopulate */); } } }
diff --git a/third_party/WebKit/Source/devtools/front_end/elements_test_runner/ElementsTestRunner.js b/third_party/WebKit/Source/devtools/front_end/elements_test_runner/ElementsTestRunner.js index 68d6aac..d84c10f 100644 --- a/third_party/WebKit/Source/devtools/front_end/elements_test_runner/ElementsTestRunner.js +++ b/third_party/WebKit/Source/devtools/front_end/elements_test_runner/ElementsTestRunner.js
@@ -276,6 +276,10 @@ TestRunner.addSniffer(Elements.StylePropertyTreeElement.prototype, 'styleTextAppliedForTest', callback); }; +ElementsTestRunner.waitForStyleAppliedPromise = function() { + return new Promise(resolve => ElementsTestRunner.waitForStyleApplied(resolve)); +}; + ElementsTestRunner.selectNodeAndWaitForStyles = function(idValue, callback) { callback = TestRunner.safeWrap(callback); let targetNode;
diff --git a/third_party/WebKit/Source/devtools/front_end/host/InspectorFrontendHost.js b/third_party/WebKit/Source/devtools/front_end/host/InspectorFrontendHost.js index e45874162..22139d7 100644 --- a/third_party/WebKit/Source/devtools/front_end/host/InspectorFrontendHost.js +++ b/third_party/WebKit/Source/devtools/front_end/host/InspectorFrontendHost.js
@@ -151,7 +151,7 @@ * @suppressGlobalPropertiesCheck */ inspectedURLChanged(url) { - document.title = Common.UIString('Developer Tools - %s', url); + document.title = Common.UIString('DevTools - %s', url.replace(/^https?:\/\//, '')); } /**
diff --git a/third_party/WebKit/Source/devtools/front_end/inline_editor/cssShadowEditor.css b/third_party/WebKit/Source/devtools/front_end/inline_editor/cssShadowEditor.css index 712146b..1c849b8a 100644 --- a/third_party/WebKit/Source/devtools/front_end/inline_editor/cssShadowEditor.css +++ b/third_party/WebKit/Source/devtools/front_end/inline_editor/cssShadowEditor.css
@@ -9,10 +9,15 @@ padding: 4px 12px 12px 12px; } +.shadow-editor-field:last-of-type { + margin-bottom: 8px; +} + .shadow-editor-field { height: 24px; margin-top: 8px; font-size: 12px; + flex-shrink: 0; } .shadow-editor-flex-field {
diff --git a/third_party/WebKit/Source/devtools/front_end/quick_open/filteredListWidget.css b/third_party/WebKit/Source/devtools/front_end/quick_open/filteredListWidget.css index d8f4458..9e83438 100644 --- a/third_party/WebKit/Source/devtools/front_end/quick_open/filteredListWidget.css +++ b/third_party/WebKit/Source/devtools/front_end/quick_open/filteredListWidget.css
@@ -66,6 +66,10 @@ background-color: #f0f0f0; } +:host-context(.-theme-with-dark-background) .filtered-list-widget-item.selected { + background-color: #333333; +} + .filtered-list-widget-item span.highlight { color: #222; font-weight: bold;
diff --git a/third_party/WebKit/Source/devtools/front_end/sources/sourcesView.css b/third_party/WebKit/Source/devtools/front_end/sources/sourcesView.css index a0a5334..6b27b3e 100644 --- a/third_party/WebKit/Source/devtools/front_end/sources/sourcesView.css +++ b/third_party/WebKit/Source/devtools/front_end/sources/sourcesView.css
@@ -62,9 +62,9 @@ .source-frame-breakpoint-condition { z-index: 30; padding: 4px; - background-color: rgb(203, 226, 255); + background-color: #e6e6e6; border-radius: 7px; - border: 2px solid rgb(169, 172, 203); + border: 2px solid #bababa; width: 90%; pointer-events: auto; }
diff --git a/third_party/WebKit/Source/devtools/front_end/text_editor/cmdevtools.css b/third_party/WebKit/Source/devtools/front_end/text_editor/cmdevtools.css index 84ea5ca..5ff40d8 100644 --- a/third_party/WebKit/Source/devtools/front_end/text_editor/cmdevtools.css +++ b/third_party/WebKit/Source/devtools/front_end/text_editor/cmdevtools.css
@@ -53,6 +53,15 @@ background-color: rgb(171, 191, 254); } +.-theme-with-dark-background .CodeMirror .source-frame-continue-to-location { + background-color: #14522b; +} + +.-theme-with-dark-background .CodeMirror .source-frame-continue-to-location:hover { + border: 1px solid #33cc6b; + background-color: #14522b; +} + .CodeMirror .source-frame-continue-to-location-start { border-left-width: 1px; margin-left: -1px; @@ -123,7 +132,6 @@ .cm-readonly-highlight { background-color: rgb(255, 255, 120); } - .-theme-with-dark-background .cm-readonly-highlight { background-color: hsla(133, 100%, 30%, 0.5); } @@ -131,10 +139,18 @@ .cm-highlight.cm-execution-line { -webkit-animation: fadeout-execution-line 1s 0s; } +.-theme-with-dark-background .cm-highlight.cm-execution-line { + -webkit-animation: fadeout-execution-line-dark 1s 0s; +} + @-webkit-keyframes fadeout-execution-line { from {background-color: rgb(121, 141, 254); } to { background-color: rgb(171, 191, 254); } } +@-webkit-keyframes fadeout-execution-line-dark { + from {background-color: #208043; } + to { background-color: #14522b; } +} .cm-breakpoint .CodeMirror-gutter-wrapper .CodeMirror-linenumber, -theme-preserve { color: white; @@ -165,6 +181,10 @@ } } /* media */ +.-theme-with-dark-background .cm-breakpoint:not(.cm-breakpoint-conditional) .CodeMirror-gutter-wrapper .CodeMirror-linenumber { + filter: hue-rotate(-139deg); +} + .cm-breakpoint-disabled .CodeMirror-linenumber { opacity: 0.5; } @@ -285,11 +305,15 @@ } .-theme-with-dark-background .cm-execution-line { - outline: 1px solid var(--selection-color); + background-color: #14522b; +} + +.-theme-with-dark-background .cm-execution-line-outline { + outline: 1px solid #33cc6b; } .-theme-with-dark-background .cm-execution-line-tail { - background-color: var(--selection-color); + background-color: #347132; } .cm-token-highlight {
diff --git a/third_party/WebKit/Source/devtools/front_end/ui/inspectorStyle.css b/third_party/WebKit/Source/devtools/front_end/ui/inspectorStyle.css index 2ce98ce..fa7b26b3 100644 --- a/third_party/WebKit/Source/devtools/front_end/ui/inspectorStyle.css +++ b/third_party/WebKit/Source/devtools/front_end/ui/inspectorStyle.css
@@ -51,7 +51,7 @@ .-theme-with-dark-background { --accent-color: #32699f; - --accent-color-b: #264f78; + --accent-color-b: #2f84da; --accent-color-c: #1f4061; --toolbar-bg-color: #333333; --toolbar-hover-bg-color: #202020;
diff --git a/third_party/WebKit/Source/devtools/front_end/ui/searchableView.css b/third_party/WebKit/Source/devtools/front_end/ui/searchableView.css index 246b67ef..6ea9c1a 100644 --- a/third_party/WebKit/Source/devtools/front_end/ui/searchableView.css +++ b/third_party/WebKit/Source/devtools/front_end/ui/searchableView.css
@@ -5,7 +5,7 @@ */ .search-bar { - flex: 0 0 29px; + flex: 0 0 31px; background-color: #eee; border-top: 1px solid #ccc; display: flex; @@ -14,7 +14,7 @@ } .search-bar.replaceable { - flex: 0 0 55px; + flex: 0 0 57px; } .search-replace { @@ -35,7 +35,7 @@ } .toolbar-search > div { - margin: 0px 2px; + margin: 2px 2px; flex-shrink: 0; } @@ -134,7 +134,7 @@ } .toolbar-search > .replace-toggle-toolbar { - margin: 0 -3px 0 0; + margin: 2px -2px 0 0; } .toolbar-search-options {
diff --git a/third_party/WebKit/Source/modules/media_controls/elements/MediaControlLoadingPanelElement.cpp b/third_party/WebKit/Source/modules/media_controls/elements/MediaControlLoadingPanelElement.cpp index 3702ba10..b95bcdc7 100644 --- a/third_party/WebKit/Source/modules/media_controls/elements/MediaControlLoadingPanelElement.cpp +++ b/third_party/WebKit/Source/modules/media_controls/elements/MediaControlLoadingPanelElement.cpp
@@ -149,6 +149,14 @@ } void MediaControlLoadingPanelElement::UpdateDisplayState() { + // If the media consols are playing then we should hide the element as + // soon as possible since we are obscuring the video. + if (GetMediaControls().State() == MediaControlsImpl::kPlaying && + state_ != State::kHidden) { + HideAnimation(); + return; + } + switch (state_) { case State::kHidden: // If the media controls are loading metadata then we should show the @@ -162,9 +170,8 @@ } break; case State::kPlaying: - // If the media controls are either stopped or playing then we should - // hide the loading panel, but not until the current cycle of animations - // is complete. + // If the media controls are stopped then we should hide the loading + // panel, but not until the current cycle of animations is complete. if (GetMediaControls().State() != MediaControlsImpl::kLoadingMetadata) { SetAnimationIterationCount(WTF::String::Number(animation_count_ + 1)); state_ = State::kCoolingDown;
diff --git a/third_party/WebKit/Source/modules/media_controls/elements/MediaControlLoadingPanelElementTest.cpp b/third_party/WebKit/Source/modules/media_controls/elements/MediaControlLoadingPanelElementTest.cpp index ba90b581..b9ba336 100644 --- a/third_party/WebKit/Source/modules/media_controls/elements/MediaControlLoadingPanelElementTest.cpp +++ b/third_party/WebKit/Source/modules/media_controls/elements/MediaControlLoadingPanelElementTest.cpp
@@ -114,13 +114,8 @@ ExpectAnimationIterationInfinite(); // Transition the media controls to a playing state and expect the loading - // panel to start cooling down. + // panel to hide immediately. SimulatePlaying(); - ExpectStateIsCoolingDown(); - ExpectAnimationIterationCount("4"); - - // Simulate the animations ending. - SimulateAnimationEnd(); // Make sure the loading panel is hidden now. ExpectStateIsHidden(); @@ -217,7 +212,6 @@ // Now move to playing. SimulatePlaying(); - SimulateAnimationEnd(); ExpectStateIsHidden(); }
diff --git a/third_party/WebKit/Source/modules/payments/PaymentRequest.cpp b/third_party/WebKit/Source/modules/payments/PaymentRequest.cpp index 2483dc7..fc2ef5f 100644 --- a/third_party/WebKit/Source/modules/payments/PaymentRequest.cpp +++ b/third_party/WebKit/Source/modules/payments/PaymentRequest.cpp
@@ -817,7 +817,8 @@ // TODO(crbug.com/825270): Reject with SecurityError DOMException if triggered // without user activation. - if (!Frame::HasTransientUserActivation(GetFrame())) { + bool is_user_gesture = Frame::HasTransientUserActivation(GetFrame()); + if (!is_user_gesture) { UseCounter::Count(GetExecutionContext(), WebFeature::kPaymentRequestShowWithoutGesture); } @@ -830,7 +831,7 @@ DOMException::Create(kInvalidStateError, "Page popups are suppressed")); } - payment_provider_->Show(); + payment_provider_->Show(is_user_gesture); show_resolver_ = ScriptPromiseResolver::Create(script_state); return show_resolver_->Promise();
diff --git a/third_party/WebKit/Source/platform/blob/testing/FakeBlobURLStore.cpp b/third_party/WebKit/Source/platform/blob/testing/FakeBlobURLStore.cpp index 9dc69246..eedff71 100644 --- a/third_party/WebKit/Source/platform/blob/testing/FakeBlobURLStore.cpp +++ b/third_party/WebKit/Source/platform/blob/testing/FakeBlobURLStore.cpp
@@ -35,4 +35,9 @@ NOTREACHED(); } +void FakeBlobURLStore::ResolveForNavigation(const KURL&, + mojom::blink::BlobURLTokenRequest) { + NOTREACHED(); +} + } // namespace blink
diff --git a/third_party/WebKit/Source/platform/blob/testing/FakeBlobURLStore.h b/third_party/WebKit/Source/platform/blob/testing/FakeBlobURLStore.h index 588409a9..d4a7925 100644 --- a/third_party/WebKit/Source/platform/blob/testing/FakeBlobURLStore.h +++ b/third_party/WebKit/Source/platform/blob/testing/FakeBlobURLStore.h
@@ -23,6 +23,8 @@ void ResolveAsURLLoaderFactory( const KURL&, network::mojom::blink::URLLoaderFactoryRequest) override; + void ResolveForNavigation(const KURL&, + mojom::blink::BlobURLTokenRequest) override; HashMap<KURL, mojom::blink::BlobPtr> registrations; Vector<KURL> revocations;
diff --git a/third_party/WebKit/Source/platform/loader/fetch/SourceKeyedCachedMetadataHandlerTest.cpp b/third_party/WebKit/Source/platform/loader/fetch/SourceKeyedCachedMetadataHandlerTest.cpp index 7192009..b26cbf5 100644 --- a/third_party/WebKit/Source/platform/loader/fetch/SourceKeyedCachedMetadataHandlerTest.cpp +++ b/third_party/WebKit/Source/platform/loader/fetch/SourceKeyedCachedMetadataHandlerTest.cpp
@@ -79,10 +79,11 @@ }; // Mock Platform implementation that provides basic crypto and caching. -class MockPlatform final : public TestingPlatformSupportWithMockScheduler { +class SourceKeyedCachedMetadataHandlerMockPlatform final + : public TestingPlatformSupportWithMockScheduler { public: - MockPlatform() {} - ~MockPlatform() override = default; + SourceKeyedCachedMetadataHandlerMockPlatform() {} + ~SourceKeyedCachedMetadataHandlerMockPlatform() override = default; WebCrypto* Crypto() override { return &mock_web_crypto_; } @@ -196,7 +197,8 @@ TEST(SourceKeyedCachedMetadataHandlerTest, HandlerForSource_InitiallyNonNullHandlersWithNullData) { - ScopedTestingPlatformSupport<MockPlatform> platform; + ScopedTestingPlatformSupport<SourceKeyedCachedMetadataHandlerMockPlatform> + platform; KURL url("http://SourceKeyedCachedMetadataHandlerTest.com"); SourceKeyedCachedMetadataHandler* handler = @@ -219,7 +221,8 @@ TEST(SourceKeyedCachedMetadataHandlerTest, HandlerForSource_OneHandlerSetOtherNull) { - ScopedTestingPlatformSupport<MockPlatform> platform; + ScopedTestingPlatformSupport<SourceKeyedCachedMetadataHandlerMockPlatform> + platform; KURL url("http://SourceKeyedCachedMetadataHandlerTest.com"); SourceKeyedCachedMetadataHandler* handler = @@ -245,7 +248,8 @@ } TEST(SourceKeyedCachedMetadataHandlerTest, HandlerForSource_BothHandlersSet) { - ScopedTestingPlatformSupport<MockPlatform> platform; + ScopedTestingPlatformSupport<SourceKeyedCachedMetadataHandlerMockPlatform> + platform; KURL url("http://SourceKeyedCachedMetadataHandlerTest.com"); SourceKeyedCachedMetadataHandler* handler = @@ -274,7 +278,8 @@ } TEST(SourceKeyedCachedMetadataHandlerTest, Serialize_EmptyClearDoesSend) { - ScopedTestingPlatformSupport<MockPlatform> platform; + ScopedTestingPlatformSupport<SourceKeyedCachedMetadataHandlerMockPlatform> + platform; KURL url("http://SourceKeyedCachedMetadataHandlerTest.com"); SourceKeyedCachedMetadataHandler* handler = @@ -292,7 +297,8 @@ } TEST(SourceKeyedCachedMetadataHandlerTest, Serialize_EachSetDoesSend) { - ScopedTestingPlatformSupport<MockPlatform> platform; + ScopedTestingPlatformSupport<SourceKeyedCachedMetadataHandlerMockPlatform> + platform; KURL url("http://SourceKeyedCachedMetadataHandlerTest.com"); SourceKeyedCachedMetadataHandler* handler = @@ -321,7 +327,8 @@ } TEST(SourceKeyedCachedMetadataHandlerTest, Serialize_SetWithNoSendDoesNotSend) { - ScopedTestingPlatformSupport<MockPlatform> platform; + ScopedTestingPlatformSupport<SourceKeyedCachedMetadataHandlerMockPlatform> + platform; KURL url("http://SourceKeyedCachedMetadataHandlerTest.com"); SourceKeyedCachedMetadataHandler* handler = @@ -352,7 +359,8 @@ TEST(SourceKeyedCachedMetadataHandlerTest, SerializeAndDeserialize_NoHandlersSet) { - ScopedTestingPlatformSupport<MockPlatform> platform; + ScopedTestingPlatformSupport<SourceKeyedCachedMetadataHandlerMockPlatform> + platform; KURL url("http://SourceKeyedCachedMetadataHandlerTest.com"); WTF::String source1("source1"); @@ -397,7 +405,8 @@ TEST(SourceKeyedCachedMetadataHandlerTest, SerializeAndDeserialize_BothHandlersSet) { - ScopedTestingPlatformSupport<MockPlatform> platform; + ScopedTestingPlatformSupport<SourceKeyedCachedMetadataHandlerMockPlatform> + platform; KURL url("http://SourceKeyedCachedMetadataHandlerTest.com"); WTF::String source1("source1");
diff --git a/third_party/WebKit/Source/platform/mhtml/MHTMLArchive.cpp b/third_party/WebKit/Source/platform/mhtml/MHTMLArchive.cpp index e65b10a..d869436d 100644 --- a/third_party/WebKit/Source/platform/mhtml/MHTMLArchive.cpp +++ b/third_party/WebKit/Source/platform/mhtml/MHTMLArchive.cpp
@@ -161,6 +161,7 @@ return nullptr; // Invalid MHTML file. MHTMLArchive* archive = new MHTMLArchive; + archive->date_ = parser.CreationDate(); size_t resources_count = resources.size(); // The first document suitable resource is the main resource of the top frame. @@ -212,16 +213,19 @@ const KURL& url, const String& title, const String& mime_type, + WTF::Time date, Vector<char>& output_buffer) { DCHECK(!boundary.IsEmpty()); DCHECK(!mime_type.IsEmpty()); - DateComponents now; - now.SetMillisecondsSinceEpochForDateTime(CurrentTimeMS()); // TODO(lukasza): Passing individual date/time components seems fragile. + base::Time::Exploded date_components; + date.UTCExplode(&date_components); String date_string = MakeRFC2822DateString( - now.WeekDay(), now.MonthDay(), now.Month(), now.FullYear(), now.Hour(), - now.Minute(), now.Second(), 0); + date_components.day_of_week, date_components.day_of_month, + // |month| is 1-based in Exploded, but 0-based in MakeRFC2822DateString. + date_components.month - 1, date_components.year, date_components.hour, + date_components.minute, date_components.second, 0); StringBuilder string_builder; string_builder.Append("From: <Saved by Blink>\r\n");
diff --git a/third_party/WebKit/Source/platform/mhtml/MHTMLArchive.h b/third_party/WebKit/Source/platform/mhtml/MHTMLArchive.h index 4774c92..501c8881 100644 --- a/third_party/WebKit/Source/platform/mhtml/MHTMLArchive.h +++ b/third_party/WebKit/Source/platform/mhtml/MHTMLArchive.h
@@ -33,6 +33,7 @@ #include "platform/heap/Handle.h" #include "platform/wtf/HashMap.h" +#include "platform/wtf/Time.h" #include "platform/wtf/Vector.h" #include "platform/wtf/text/StringHash.h" @@ -67,6 +68,7 @@ const KURL&, const String& title, const String& mime_type, + WTF::Time date, Vector<char>& output_buffer); // Serializes SerializedResource as an MHTML part and appends it in @@ -95,9 +97,12 @@ typedef HeapHashMap<String, Member<ArchiveResource>> SubArchiveResources; - ArchiveResource* MainResource() { return main_resource_.Get(); } + ArchiveResource* MainResource() const { return main_resource_.Get(); } ArchiveResource* SubresourceForURL(const KURL&) const; + // The purported creation date (as expressed by the Date: header). + WTF::Time Date() const { return date_; } + void Trace(blink::Visitor*); private: @@ -107,6 +112,7 @@ void AddSubresource(ArchiveResource*); static bool CanLoadArchive(const KURL&); + WTF::Time date_; Member<ArchiveResource> main_resource_; SubArchiveResources subresources_; };
diff --git a/third_party/WebKit/Source/platform/mhtml/MHTMLParser.cpp b/third_party/WebKit/Source/platform/mhtml/MHTMLParser.cpp index 0868f7b6..3cd2b12 100644 --- a/third_party/WebKit/Source/platform/mhtml/MHTMLParser.cpp +++ b/third_party/WebKit/Source/platform/mhtml/MHTMLParser.cpp
@@ -31,6 +31,7 @@ #include "platform/mhtml/MHTMLParser.h" #include "platform/mhtml/ArchiveResource.h" +#include "platform/network/HTTPParsers.h" #include "platform/network/ParsedContentType.h" #include "platform/text/QuotedPrintable.h" #include "platform/wtf/HashMap.h" @@ -70,6 +71,7 @@ } String ContentLocation() const { return content_location_; } String ContentID() const { return content_id_; } + WTF::Time Date() const { return date_; } // Multi-part type and boundaries are only valid for multipart MIME headers. String MultiPartType() const { return multipart_type_; } @@ -88,6 +90,7 @@ Encoding content_transfer_encoding_; String content_location_; String content_id_; + WTF::Time date_; String multipart_type_; String end_of_part_boundary_; String end_of_document_boundary_; @@ -172,6 +175,13 @@ if (mime_parameters_iterator != key_value_pairs.end()) mime_header->content_id_ = mime_parameters_iterator->value; + mime_parameters_iterator = key_value_pairs.find("date"); + if (mime_parameters_iterator != key_value_pairs.end()) { + double ms_since_epoch = ParseDate(mime_parameters_iterator->value); + if (!std::isnan(ms_since_epoch)) + mime_header->date_ = WTF::Time::FromDoubleT(ms_since_epoch / 1000); + } + return mime_header; } @@ -213,9 +223,14 @@ HeapVector<Member<ArchiveResource>> resources; if (!ParseArchiveWithHeader(header, resources)) resources.clear(); + creation_date_ = header->Date(); return resources; } +WTF::Time MHTMLParser::CreationDate() const { + return creation_date_; +} + bool MHTMLParser::ParseArchiveWithHeader( MIMEHeader* header, HeapVector<Member<ArchiveResource>>& resources) {
diff --git a/third_party/WebKit/Source/platform/mhtml/MHTMLParser.h b/third_party/WebKit/Source/platform/mhtml/MHTMLParser.h index 732ba5c..9553e86 100644 --- a/third_party/WebKit/Source/platform/mhtml/MHTMLParser.h +++ b/third_party/WebKit/Source/platform/mhtml/MHTMLParser.h
@@ -34,7 +34,9 @@ #include "base/memory/scoped_refptr.h" #include "platform/SharedBufferChunkReader.h" #include "platform/heap/Handle.h" +#include "platform/heap/Member.h" #include "platform/weborigin/KURL.h" +#include "platform/wtf/Time.h" #include "platform/wtf/Vector.h" namespace WTF { @@ -54,6 +56,7 @@ explicit MHTMLParser(scoped_refptr<const SharedBuffer>); HeapVector<Member<ArchiveResource>> ParseArchive(); + WTF::Time CreationDate() const; // Translates |contentIDFromMimeHeader| (of the form "<foo@bar.com>") // into a cid-scheme URI (of the form "cid:foo@bar.com"). @@ -71,6 +74,7 @@ const String& end_of_document_boundary, bool& end_of_archive_reached); + WTF::Time creation_date_; SharedBufferChunkReader line_reader_; };
diff --git a/third_party/WebKit/Source/platform/mhtml/MHTMLParserTest.cpp b/third_party/WebKit/Source/platform/mhtml/MHTMLParserTest.cpp index dbef880e..37f2b1f 100644 --- a/third_party/WebKit/Source/platform/mhtml/MHTMLParserTest.cpp +++ b/third_party/WebKit/Source/platform/mhtml/MHTMLParserTest.cpp
@@ -6,6 +6,7 @@ #include "platform/SharedBuffer.h" #include "platform/mhtml/ArchiveResource.h" +#include "platform/wtf/Time.h" #include "testing/gtest/include/gtest/gtest.h" namespace blink { @@ -31,6 +32,13 @@ MHTMLParser parser(buf); return parser.ParseArchive(); } + + WTF::Time ParseArchiveTime(const char* mhtml_data, size_t size) { + scoped_refptr<SharedBuffer> buf = SharedBuffer::Create(mhtml_data, size); + MHTMLParser parser(buf); + EXPECT_GT(parser.ParseArchive().size(), 0U); + return parser.CreationDate(); + } }; TEST_F(MHTMLParserTest, MHTMLPartHeaders) { @@ -330,4 +338,81 @@ EXPECT_EQ("", GetResourceData(resources, 2)); } +TEST_F(MHTMLParserTest, DateParsing_EmptyDate) { + // Missing date is ignored. + const char mhtml_data[] = + "From: <Saved by Blink>\r\n" + "Subject: Test Subject\r\n" + "MIME-Version: 1.0\r\n" + "Content-Type: multipart/related;\r\n" + "\ttype=\"text/html\";\r\n" + "\tboundary=\"BoUnDaRy\"\r\n" + "\r\n" + "\r\n" + "--BoUnDaRy\r\n" + "Content-Location: http://www.example.com/page1\r\n" + "Content-Type: binary/octet-stream\r\n" + "\r\n" + "bin\0ary\r\n" + "--BoUnDaRy--\r\n"; + + WTF::Time creation_time = ParseArchiveTime(mhtml_data, sizeof(mhtml_data)); + + // No header should produce an invalid time. + EXPECT_EQ(WTF::Time(), creation_time); +} + +TEST_F(MHTMLParserTest, DateParsing_InvalidDate) { + // Invalid date is ignored. Also, Date header within a part should not be + // used. + const char mhtml_data[] = + "From: <Saved by Blink>\r\n" + "Subject: Test Subject\r\n" + "Date: 123xyz\r\n" + "MIME-Version: 1.0\r\n" + "Content-Type: multipart/related;\r\n" + "\ttype=\"text/html\";\r\n" + "\tboundary=\"BoUnDaRy\"\r\n" + "\r\n" + "\r\n" + "--BoUnDaRy\r\n" + "Content-Location: http://www.example.com/page1\r\n" + "Content-Type: binary/octet-stream\r\n" + "Date: Fri, 1 Mar 2017 22:44:17 -0000\r\n" + "\r\n" + "bin\0ary\r\n" + "--BoUnDaRy--\r\n"; + + WTF::Time creation_time = ParseArchiveTime(mhtml_data, sizeof(mhtml_data)); + + // Invalid header should produce an invalid time. + EXPECT_EQ(WTF::Time(), creation_time); +} + +TEST_F(MHTMLParserTest, DateParsing_ValidDate) { + // Missing encoding is treated as binary. + const char mhtml_data[] = + "From: <Saved by Blink>\r\n" + "Subject: Test Subject\r\n" + "Date: Fri, 1 Mar 2017 22:44:17 -0000\r\n" + "MIME-Version: 1.0\r\n" + "Content-Type: multipart/related;\r\n" + "\ttype=\"text/html\";\r\n" + "\tboundary=\"BoUnDaRy\"\r\n" + "\r\n" + "\r\n" + "--BoUnDaRy\r\n" + "Content-Location: http://www.example.com/page1\r\n" + "Content-Type: binary/octet-stream\r\n" + "\r\n" + "bin\0ary\r\n" + "--BoUnDaRy--\r\n"; + + WTF::Time creation_time = ParseArchiveTime(mhtml_data, sizeof(mhtml_data)); + WTF::Time expected_time; + ASSERT_TRUE(WTF::Time::FromUTCExploded( + {2017, 3 /* March */, 5 /* Friday */, 1, 22, 44, 17, 0}, &expected_time)); + EXPECT_EQ(expected_time, creation_time); +} + } // namespace blink
diff --git a/third_party/WebKit/public/mojom/blob/blob_url_store.mojom b/third_party/WebKit/public/mojom/blob/blob_url_store.mojom index 54f154d..33ae3e8e 100644 --- a/third_party/WebKit/public/mojom/blob/blob_url_store.mojom +++ b/third_party/WebKit/public/mojom/blob/blob_url_store.mojom
@@ -3,6 +3,7 @@ // found in the LICENSE file. module blink.mojom; +import "mojo/public/mojom/base/unguessable_token.mojom"; import "services/network/public/mojom/url_loader_factory.mojom"; import "third_party/WebKit/public/mojom/blob/blob.mojom"; import "url/mojom/url.mojom"; @@ -32,4 +33,18 @@ // both the blob URL and all other references to the blob have been dropped. ResolveAsURLLoaderFactory(url.mojom.Url url, network.mojom.URLLoaderFactory& factory); + + // Resolves a public Blob URL into a BlobURLToken. The BlobURLToken can be + // used by the browser process to securely look up the blob a URL used to + // refer to, even after the URL is revoked. + // As long as the token is alive, the resolved blob will also be kept alive. + ResolveForNavigation(url.mojom.Url url, BlobURLToken& token); +}; + +// A token representing a Blob URL. The browser process can use this to look up +// the blob URL and blob it referred to, even after the blob URL itself is +// revoked. For the renderer this is just an opaque token without any meaning. +interface BlobURLToken { + Clone(BlobURLToken& token); + GetToken() => (mojo_base.mojom.UnguessableToken token); };
diff --git a/third_party/WebKit/public/platform/WebArchiveInfo.h b/third_party/WebKit/public/platform/WebArchiveInfo.h new file mode 100644 index 0000000..33d16f8 --- /dev/null +++ b/third_party/WebKit/public/platform/WebArchiveInfo.h
@@ -0,0 +1,27 @@ +// Copyright 2018 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 WebArchiveInfo_h +#define WebArchiveInfo_h + +#include "base/time/time.h" +#include "public/platform/WebURL.h" + +namespace blink { + +// Basic attributes of an archive resource that are derived from the parsed +// headers and content contained within. +struct WebArchiveInfo { + // Main resource URL, the parser chooses the first appropriate resource from + // within the MTHML file. This is the Content-Location header from that + // resource. + WebURL url; + + // Date as reported in the Date: header from the MHTML header section + base::Time date; +}; + +} // namespace blink + +#endif
diff --git a/third_party/WebKit/public/platform/modules/payments/payment_request.mojom b/third_party/WebKit/public/platform/modules/payments/payment_request.mojom index 4977531..c7e358d0 100644 --- a/third_party/WebKit/public/platform/modules/payments/payment_request.mojom +++ b/third_party/WebKit/public/platform/modules/payments/payment_request.mojom
@@ -188,7 +188,7 @@ PaymentOptions options); // Shows the user interface with the payment details. - Show(); + Show(bool is_user_gesture); // Updates the payment details in response to new shipping address or shipping // option.
diff --git a/third_party/WebKit/public/web/WebDocumentLoader.h b/third_party/WebKit/public/web/WebDocumentLoader.h index cc48de6..1326b3d 100644 --- a/third_party/WebKit/public/web/WebDocumentLoader.h +++ b/third_party/WebKit/public/web/WebDocumentLoader.h
@@ -36,6 +36,7 @@ #include "WebNavigationType.h" #include "WebTextDirection.h" #include "base/time/time.h" +#include "public/platform/WebArchiveInfo.h" #include "public/platform/WebCommon.h" #include "public/platform/WebSourceLocation.h" @@ -152,6 +153,12 @@ virtual void BlockParser() = 0; virtual void ResumeParser() = 0; + // Returns info about whether the document is an MHTML archive. + virtual bool IsArchive() const = 0; + // Returns archive info for the archive. Should never be called if + // IsArchive returns false. + virtual WebArchiveInfo GetArchiveInfo() const = 0; + protected: ~WebDocumentLoader() = default; };
diff --git a/third_party/WebKit/public/web/WebFrameClient.h b/third_party/WebKit/public/web/WebFrameClient.h index ca7c1e3..ef6f635 100644 --- a/third_party/WebKit/public/web/WebFrameClient.h +++ b/third_party/WebKit/public/web/WebFrameClient.h
@@ -349,6 +349,7 @@ WebString devtools_initiator_info; WebContentSecurityPolicyDisposition should_check_main_world_content_security_policy; + mojo::ScopedMessagePipeHandle blob_url_token; // Specify whether or not a MHTML Archive can be used to load a subframe // resource instead of doing a network request.
diff --git a/third_party/closure_compiler/externs/developer_private.js b/third_party/closure_compiler/externs/developer_private.js index 78643ba..ea674b4 100644 --- a/third_party/closure_compiler/externs/developer_private.js +++ b/third_party/closure_compiler/externs/developer_private.js
@@ -1,4 +1,4 @@ -// Copyright 2017 The Chromium Authors. All rights reserved. +// Copyright 2018 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. @@ -680,6 +680,13 @@ chrome.developerPrivate.loadUnpacked = function(options, callback) {}; /** + * Installs the file that was dragged and dropped onto the associated page. + * @param {function():void=} callback + * @see https://developer.chrome.com/extensions/developerPrivate#method-installDroppedFile + */ +chrome.developerPrivate.installDroppedFile = function(callback) {}; + +/** * Notifies the browser that a user began a drag in order to install an * extension. * @see https://developer.chrome.com/extensions/developerPrivate#method-notifyDragInstallInProgress
diff --git a/third_party/wayland-protocols/unstable/remote-shell/remote-shell-unstable-v1.xml b/third_party/wayland-protocols/unstable/remote-shell/remote-shell-unstable-v1.xml index 111d6d0..64b1208 100644 --- a/third_party/wayland-protocols/unstable/remote-shell/remote-shell-unstable-v1.xml +++ b/third_party/wayland-protocols/unstable/remote-shell/remote-shell-unstable-v1.xml
@@ -468,6 +468,7 @@ </request> <!-- Version 3 additions --> + <request name="set_systemui_visibility" since="3"> <description summary="requests the system ui visibility behavior for the surface"> Requests how the surface will change the visibility of the system UI when it is made active. @@ -624,6 +625,7 @@ </event> <!-- Version 10 additions --> + <enum name="bounds_change_reason"> <description summary="bounds_change_reason"> Specifies the cause of the window bounds change event. @@ -761,6 +763,7 @@ </request> <!-- Version 11 additions --> + <request name="set_snapped_to_left" since="11"> <description summary="set the surface to left snapped"> Request that surface is snapped to left.
diff --git a/tools/chrome_proxy/webdriver/emulation_server.py b/tools/chrome_proxy/webdriver/emulation_server.py index 06b647d..748d922 100644 --- a/tools/chrome_proxy/webdriver/emulation_server.py +++ b/tools/chrome_proxy/webdriver/emulation_server.py
@@ -82,12 +82,15 @@ self._server_class = server_class self._server = None - def StartAndReturn(self): + def StartAndReturn(self, timeout=30): """Start the server in a new thread and return once the server is running. A new server of the given server_class at init is started with the given handler. The server will listen forever in a new thread unless Shutdown() is called. + + Args: + timeout: The timeout to start the server. """ self._server = self._server_class(("0.0.0.0", self._port), self._handler_class) @@ -98,7 +101,8 @@ thread = threading.Thread(target=WaitForRunning, args=[event]) thread.daemon = True thread.start() - event.wait() + if not event.wait(timeout=timeout): + raise Exception("Emulation server didn't start in %d seconds" % timeout) def Shutdown(self): """Shutdown a running server.
diff --git a/tools/gn/bootstrap/bootstrap.py b/tools/gn/bootstrap/bootstrap.py index 83f5838c..8f32161 100755 --- a/tools/gn/bootstrap/bootstrap.py +++ b/tools/gn/bootstrap/bootstrap.py
@@ -39,12 +39,13 @@ def check_call(cmd, **kwargs): logging.debug('Running: %s', ' '.join(cmd)) - # With shell=False, subprocess expects an executable on Windows - if is_win and cmd and cmd[0].endswith('.py'): - cmd.insert(0, sys.executable) - subprocess.check_call(cmd, cwd=GN_ROOT, **kwargs) +def check_output(cmd, cwd=GN_ROOT, **kwargs): + logging.debug('Running: %s', ' '.join(cmd)) + + return subprocess.check_output(cmd, cwd=cwd, **kwargs) + def mkdir_p(path): try: os.makedirs(path) @@ -71,8 +72,13 @@ build_rel = os.path.join('out', 'Release') build_root = os.path.join(SRC_ROOT, build_rel) + windows_x64_toolchain = None + if is_win: + windows_x64_toolchain = windows_prepare_toolchain(tempdir) + os.environ["PATH"] = windows_x64_toolchain["paths"] + print 'Building gn manually in a temporary directory for bootstrapping...' - build_gn_with_ninja_manually(tempdir, options) + build_gn_with_ninja_manually(tempdir, options, windows_x64_toolchain) temp_gn = os.path.join(tempdir, 'gn') out_gn = os.path.join(build_root, 'gn') @@ -99,6 +105,37 @@ if platform.machine().lower() in ['x86_64', 'amd64']: return 'x64' return 'x86' +def windows_prepare_toolchain(tempdir): + + def CallPythonScopeScript(command, **kwargs): + response = check_output(command, **kwargs) + + _globals = {"__builtins__":None} + _locals = {} + exec(response, _globals, _locals) + + return _locals + + toolchain_paths = CallPythonScopeScript( + [sys.executable, + os.path.join(SRC_ROOT, "build", "vs_toolchain.py"), + "get_toolchain_dir"], + cwd=tempdir) + + windows_x64_toolchain = CallPythonScopeScript( + [sys.executable, + os.path.join(SRC_ROOT, "build", "toolchain", + "win", "setup_toolchain.py"), + toolchain_paths["vs_path"], + toolchain_paths["sdk_path"], + toolchain_paths["runtime_dirs"], + "x64", + "true" + ], + cwd=tempdir) + + return windows_x64_toolchain + def main(argv): parser = optparse.OptionParser(description=sys.modules[__name__].__doc__) parser.add_option('-d', '--debug', action='store_true', @@ -112,7 +149,9 @@ 'temporary location each time') parser.add_option('--gn-gen-args', help='Args to pass to gn gen --args') parser.add_option('--build-path', help='The directory in which to build gn, ' - 'relative to the src directory. (eg. out/Release)') + 'relative to the src directory. (eg. out/Release)' + 'In the no-clean mode an absolute path will also force ' + 'the out_bootstrap to be located in the parent directory') parser.add_option('-v', '--verbose', action='store_true', help='Log more details') options, args = parser.parse_args(argv) @@ -124,7 +163,10 @@ try: if options.no_clean: - build_dir = os.path.join(SRC_ROOT, 'out_bootstrap') + out_bootstrap_dir = SRC_ROOT + if options.build_path and os.path.isabs(options.build_path): + out_bootstrap_dir = os.path.dirname(options.build_path) + build_dir = os.path.join(out_bootstrap_dir, 'out_bootstrap') if not os.path.exists(build_dir): os.makedirs(build_dir) return run_build(build_dir, options) @@ -159,6 +201,7 @@ f.write(' ' + name + '=' + value) check_call([ + sys.executable, os.path.join(SRC_ROOT, 'build', 'write_buildflag_header.py'), '--output', header, '--gen-dir', root_gen_dir, @@ -169,12 +212,13 @@ def write_build_date_header(root_gen_dir): check_call([ + sys.executable, os.path.join(SRC_ROOT, 'build', 'write_build_date_header.py'), os.path.join(root_gen_dir, 'base/generated_build_date.h'), 'default', ]) -def build_gn_with_ninja_manually(tempdir, options): +def build_gn_with_ninja_manually(tempdir, options, windows_x64_toolchain): root_gen_dir = os.path.join(tempdir, 'gen') mkdir_p(root_gen_dir) @@ -215,6 +259,7 @@ # and this file is only included for Mac builds. mkdir_p(os.path.join(root_gen_dir, 'base')) check_call([ + sys.executable, os.path.join(SRC_ROOT, 'build', 'write_build_date_header.py'), os.path.join(root_gen_dir, 'base', 'generated_build_date.h'), 'default' @@ -233,7 +278,7 @@ {'USE_LLD': 'false', 'SUPPORTS_CODE_ORDERING': 'false'}) write_gn_ninja(os.path.join(tempdir, 'build.ninja'), - root_gen_dir, options) + root_gen_dir, options, windows_x64_toolchain) cmd = ['ninja', '-C', tempdir, '-w', 'dupbuild=err'] if options.verbose: cmd.append('-v') @@ -332,12 +377,14 @@ f.write(ninja_template) f.write('\n'.join(ninja_lines)) -def write_gn_ninja(path, root_gen_dir, options): +def write_gn_ninja(path, root_gen_dir, options, windows_x64_toolchain): if is_win: - cc = os.environ.get('CC', 'cl.exe') - cxx = os.environ.get('CXX', 'cl.exe') - ld = os.environ.get('LD', 'link.exe') - ar = os.environ.get('AR', 'lib.exe') + CCPATH = windows_x64_toolchain["vc_bin_dir"] + + cc = os.environ.get('CC', os.path.join(CCPATH, 'cl.exe')) + cxx = os.environ.get('CXX', os.path.join(CCPATH, 'cl.exe')) + ld = os.environ.get('LD', os.path.join(CCPATH, 'link.exe')) + ar = os.environ.get('AR', os.path.join(CCPATH, 'lib.exe')) elif is_aix: cc = os.environ.get('CC', 'gcc') cxx = os.environ.get('CXX', 'c++') @@ -835,6 +882,9 @@ if is_win: static_libraries['base']['sources'].extend([ + "base/allocator/partition_allocator/address_space_randomization.cc", + 'base/allocator/partition_allocator/page_allocator.cc', + "base/allocator/partition_allocator/spin_lock.cc", 'base/base_paths_win.cc', 'base/cpu.cc', 'base/debug/close_handle_hook_win.cc', @@ -871,17 +921,16 @@ 'base/sync_socket_win.cc', 'base/synchronization/condition_variable_win.cc', 'base/synchronization/lock_impl_win.cc', - 'base/synchronization/read_write_lock_win.cc', 'base/synchronization/waitable_event_watcher_win.cc', 'base/synchronization/waitable_event_win.cc', 'base/sys_info_win.cc', 'base/threading/platform_thread_win.cc', 'base/threading/thread_local_storage_win.cc', - 'base/threading/worker_pool_win.cc', 'base/time/time_win.cc', 'base/timer/hi_res_timer_manager_win.cc', 'base/trace_event/heap_profiler_allocation_register_win.cc', 'base/trace_event/trace_event_etw_export_win.cc', + 'base/win/core_winrt_util.cc', 'base/win/enum_variant.cc', 'base/win/event_trace_controller.cc', 'base/win/event_trace_provider.cc', @@ -895,9 +944,12 @@ 'base/win/registry.cc', 'base/win/resource_util.cc', 'base/win/scoped_bstr.cc', + 'base/win/scoped_com_initializer.cc', 'base/win/scoped_handle.cc', + 'base/win/scoped_handle_verifier.cc', 'base/win/scoped_process_information.cc', 'base/win/scoped_variant.cc', + 'base/win/scoped_winrt_initializer.cc', 'base/win/shortcut.cc', 'base/win/startup_information.cc', 'base/win/wait_chain.cc', @@ -930,7 +982,9 @@ gn_gen_args = options.gn_gen_args or '' if not options.debug: gn_gen_args += ' is_debug=false' - cmd = [temp_gn, 'gen', build_dir, '--args=%s' % gn_gen_args] + cmd = [temp_gn, 'gen', build_dir, '--args=%s' % gn_gen_args, + "--root="+SRC_ROOT + ] check_call(cmd) cmd = ['ninja', '-C', build_dir, '-w', 'dupbuild=err']
diff --git a/tools/gn/bootstrap/build_vs.ninja.template b/tools/gn/bootstrap/build_vs.ninja.template index 6e98575..88bba37 100644 --- a/tools/gn/bootstrap/build_vs.ninja.template +++ b/tools/gn/bootstrap/build_vs.ninja.template
@@ -1,25 +1,28 @@ + +arch = environment.x64 + rule cc - command = $cc /nologo /showIncludes /FC @${out}.rsp /c ${in} /Fo${out} + command = ninja -t msvc -e $arch -- $cc /nologo /showIncludes /FC @${out}.rsp /c ${in} /Fo${out} description = CC ${out} rspfile = ${out}.rsp rspfile_content = ${defines} ${includes} ${cflags} ${cflags_c} deps = msvc rule cxx - command = $cxx /nologo /showIncludes /FC @${out}.rsp /c ${in} /Fo${out} + command = ninja -t msvc -e $arch -- $cxx /nologo /showIncludes /FC @${out}.rsp /c ${in} /Fo${out} description = CXX ${out} rspfile = ${out}.rsp rspfile_content = ${defines} ${includes} ${cflags} ${cflags_cc} deps = msvc rule alink_thin - command = $ar /nologo /ignore:4221 /OUT:${out} @${out}.rsp + command = ninja -t msvc -e $arch -- $ar /nologo /ignore:4221 /OUT:${out} @${out}.rsp description = LIB ${out} rspfile = ${out}.rsp rspfile_content = ${in_newline} rule link - command = $ld /nologo /OUT:${out} /PDB:${out}.pdb @${out}.rsp + command = ninja -t msvc -e $arch -- $ld /nologo /OUT:${out} /PDB:${out}.pdb @${out}.rsp description = LINK ${out} rspfile = ${out}.rsp rspfile_content = ${in_newline} ${libs} ${solibs} ${ldflags}
diff --git a/tools/gn/command_args.cc b/tools/gn/command_args.cc index bb40a6e..237aa0d 100644 --- a/tools/gn/command_args.cc +++ b/tools/gn/command_args.cc
@@ -12,6 +12,7 @@ #include "base/command_line.h" #include "base/environment.h" #include "base/files/file_util.h" +#include "base/json/json_writer.h" #include "base/process/launch.h" #include "base/strings/string_number_conversions.h" #include "base/strings/string_util.h" @@ -37,6 +38,7 @@ const char kSwitchList[] = "list"; const char kSwitchShort[] = "short"; const char kSwitchOverridesOnly[] = "overrides-only"; +const char kSwitchJson[] = "json"; bool DoesLineBeginWithComment(const base::StringPiece& line) { // Skip whitespace. @@ -76,14 +78,15 @@ // Tries to find the comment before the setting of the given value. void GetContextForValue(const Value& value, std::string* location_str, + int* line_no, std::string* comment) { Location location = value.origin()->GetRange().begin(); const InputFile* file = location.file(); if (!file) return; - *location_str = file->name().value() + ":" + - base::IntToString(location.line_number()); + *location_str = file->name().value(); + *line_no = location.line_number(); const std::string& data = file->contents(); size_t line_off = @@ -112,9 +115,11 @@ void PrintDefaultValueInfo(base::StringPiece name, const Value& value) { OutputString(value.ToString(true) + "\n"); if (value.origin()) { + int line_no; std::string location, comment; - GetContextForValue(value, &location, &comment); - OutputString(" From " + location + "\n"); + GetContextForValue(value, &location, &line_no, &comment); + OutputString(" From " + location + ":" + base::IntToString(line_no) + + "\n"); if (!comment.empty()) OutputString("\n" + comment); } else { @@ -134,9 +139,11 @@ OutputString(" Current value = " + val.override_value.ToString(true) + "\n"); if (val.override_value.origin()) { + int line_no; std::string location, comment; - GetContextForValue(val.override_value, &location, &comment); - OutputString(" From " + location + "\n"); + GetContextForValue(val.override_value, &location, &line_no, &comment); + OutputString(" From " + location + ":" + base::IntToString(line_no) + + "\n"); } OutputString(" Overridden from the default = "); PrintDefaultValueInfo(name, val.default_value); @@ -147,6 +154,57 @@ } } +void BuildArgJson(base::Value& dict, + const base::StringPiece& name, + const Args::ValueWithOverride& arg, + bool short_only) { + assert(dict.is_dict()); + + // Fetch argument name. + dict.SetKey("name", base::Value(name)); + + // Fetch overridden value inforrmation (if present). + if (arg.has_override) { + base::DictionaryValue override_dict; + override_dict.SetKey("value", + base::Value(arg.override_value.ToString(true))); + if (arg.override_value.origin() && !short_only) { + int line_no; + std::string location, comment; + GetContextForValue(arg.override_value, &location, &line_no, &comment); + // Omit file and line if set with --args (i.e. no file) + if (!location.empty()) { + override_dict.SetKey("file", base::Value(location)); + override_dict.SetKey("line", base::Value(line_no)); + } + } + dict.SetKey("current", std::move(override_dict)); + } + + // Fetch default value information, and comment (if present). + base::DictionaryValue default_dict; + std::string comment; + default_dict.SetKey("value", base::Value(arg.default_value.ToString(true))); + if (arg.default_value.origin() && !short_only) { + int line_no; + std::string location; + GetContextForValue(arg.default_value, &location, &line_no, &comment); + // Only emit file and line if the value is overridden. + if (arg.has_override) { + default_dict.SetKey("file", base::Value(location)); + default_dict.SetKey("line", base::Value(line_no)); + } + } + dict.SetKey("default", std::move(default_dict)); + if (!comment.empty() && !short_only) + dict.SetKey("comment", base::Value(comment)); + + std::string s; + base::JSONWriter::WriteWithOptions( + dict, base::JSONWriter::OPTIONS_PRETTY_PRINT, &s); + OutputString(s); +} + int ListArgs(const std::string& build_dir) { Setup* setup = new Setup; if (!setup->DoSetup(build_dir, false) || !setup->Run()) @@ -175,8 +233,26 @@ // Cache this to avoid looking it up for each |arg| in the loops below. const bool overrides_only = base::CommandLine::ForCurrentProcess()->HasSwitch(kSwitchOverridesOnly); + const bool short_only = + base::CommandLine::ForCurrentProcess()->HasSwitch(kSwitchShort); - if (base::CommandLine::ForCurrentProcess()->HasSwitch(kSwitchShort)) { + if (base::CommandLine::ForCurrentProcess()->HasSwitch(kSwitchJson)) { + // Convert all args to JSON, serialize and print them + auto list = std::make_unique<base::ListValue>(); + for (const auto& arg : args) { + if (overrides_only && !arg.second.has_override) + continue; + list->GetList().emplace_back(base::DictionaryValue()); + BuildArgJson(list->GetList().back(), arg.first, arg.second, short_only); + } + std::string s; + base::JSONWriter::WriteWithOptions( + *list.get(), base::JSONWriter::OPTIONS_PRETTY_PRINT, &s); + OutputString(s); + return 0; + } + + if (short_only) { // Short <key>=<current_value> output. for (const auto& arg : args) { if (overrides_only && !arg.second.has_override) @@ -354,7 +430,7 @@ Note: you can edit the build args manually by editing the file "args.gn" in the build directory and then running "gn gen <out_dir>". - gn args <out_dir> --list[=<exact_arg>] [--short] [--overrides-only] + gn args <out_dir> --list[=<exact_arg>] [--short] [--overrides-only] [--json] Lists all build arguments available in the current configuration, or, if an exact_arg is specified for the list flag, just that one build argument. @@ -370,6 +446,25 @@ arguments that have been overridden (i.e. non-default arguments) will be printed. Overrides come from the <out_dir>/args.gn file and //.gn + If --json is specified, the output will be emitted in json format. + JSON schema for output: + [ + { + "name": variable_name, + "current": { + "value": overridden_value, + "file": file_name, + "line": line_no + }, + "default": { + "value": default_value, + "file": file_name, + "line": line_no + }, + "comment": comment_string + }, + ... + ] Examples
diff --git a/tools/mb/mb_config.pyl b/tools/mb/mb_config.pyl index afe2fa9..cf607e5 100644 --- a/tools/mb/mb_config.pyl +++ b/tools/mb/mb_config.pyl
@@ -335,6 +335,7 @@ 'Cast Android (dbg)': 'android_cast_debug_static_bot', 'Cast Linux': 'cast_release_bot', 'Cast Audio Linux': 'cast_audio_release_bot', + 'Jumbo Linux x64': 'jumbo_release_bot_minimal_symbols', 'Leak Detection Linux': 'release_bot', 'Linux Builder (dbg)': 'debug_bot', 'Linux Builder (dbg)(32)': 'debug_bot_x86', @@ -392,27 +393,27 @@ }, 'chromium.perf': { - 'Android Builder': 'official_goma_minimal_symbols_android', - 'Android arm64 Builder': 'official_goma_minimal_symbols_android_arm64', - 'Android Compile': 'official_goma_minimal_symbols_android', - 'Android arm64 Compile': 'official_goma_minimal_symbols_android_arm64', - 'Linux Builder': 'official_goma_perf', - 'Mac Builder': 'official_goma', - 'Win Builder': 'official_goma_x86', - 'Win x64 Builder': 'official_goma', + 'Android Builder Perf': 'official_goma_minimal_symbols_android', + 'Android arm64 Builder Perf': 'official_goma_minimal_symbols_android_arm64', + 'Android Compile Perf': 'official_goma_minimal_symbols_android', + 'Android arm64 Compile Perf': 'official_goma_minimal_symbols_android_arm64', + 'Linux Builder Perf': 'official_goma_perf', + 'Mac Builder Perf': 'official_goma', + 'Win Builder Perf': 'official_goma_x86', + 'Win x64 Builder Perf': 'official_goma', }, 'chromium.perf.fyi': { - 'Linux Compile FYI': 'official_goma_perf', - 'Android Builder FYI': 'official_goma_minimal_symbols_android', - 'Android arm64 Builder FYI': 'official_goma_minimal_symbols_android_arm64', - 'Android CFI Builder FYI': 'official_goma_minimal_symbols_android_cfi', - 'Android CFI arm64 Builder FYI': 'official_goma_minimal_symbols_android_cfi_arm64', + 'Linux Compile Perf FYI': 'official_goma_perf', + 'Android Builder Perf FYI': 'official_goma_minimal_symbols_android', + 'Android arm64 Builder Perf FYI': 'official_goma_minimal_symbols_android_arm64', + 'Android CFI Builder Perf FYI': 'official_goma_minimal_symbols_android_cfi', + 'Android CFI arm64 Builder Perf FYI': 'official_goma_minimal_symbols_android_cfi_arm64', 'Battor Agent Linux': 'release_bot', 'Battor Agent Mac': 'release_bot', 'Battor Agent Win': 'release_bot', - 'Mac Builder FYI': 'official_goma', - 'Win Builder FYI': 'official_goma_x86', + 'Mac Builder Perf FYI': 'official_goma', + 'Win Builder Perf FYI': 'official_goma_x86', }, 'chromium.swarm': { @@ -678,8 +679,8 @@ }, 'tryserver.chromium.perf': { - 'Android Compile': 'official_goma_minimal_symbols_android', - 'Android arm64 Compile': 'official_goma_minimal_symbols_android_arm64', + 'Android Compile Perf': 'official_goma_minimal_symbols_android', + 'Android arm64 Compile Perf': 'official_goma_minimal_symbols_android_arm64', 'android_arm64_perf_bisect_builder': 'official_goma_minimal_symbols_android_arm64', 'android_fyi_perf_bisect': 'official_goma_minimal_symbols_android', 'android_nexus5X_perf_bisect': 'official_goma_minimal_symbols_android', @@ -691,12 +692,12 @@ 'android_perf_bisect_builder': 'official_goma_minimal_symbols_android', 'android_s5_perf_bisect': 'official_goma_minimal_symbols_android', 'android_webview_arm64_aosp_perf_bisect': 'official_goma_minimal_symbols_android', - 'Linux Builder': 'official_goma_perf', + 'Linux Builder Perf': 'official_goma_perf', 'linux_fyi_perf_bisect': 'official_goma', 'linux_perf_bisect': 'official_goma', 'linux_perf_bisect_builder': 'official_goma', 'linux_perf_cq': 'official_goma', - 'Mac Builder': 'official_goma', + 'Mac Builder Perf': 'official_goma', 'mac_10_10_perf_bisect': 'official_goma', 'mac_10_11_perf_bisect': 'official_goma', 'mac_fyi_perf_bisect': 'official_goma', @@ -705,8 +706,8 @@ 'mac_retina_perf_bisect': 'official_goma', 'mac_retina_perf_cq': 'official_goma', 'obbs_fyi': 'official_goma_perf', - 'Win Builder': 'official_goma_x86', - 'Win x64 Builder': 'official_goma', + 'Win Builder Perf': 'official_goma_x86', + 'Win x64 Builder Perf': 'official_goma', 'win_8_perf_bisect': 'official_goma_x86', 'win_fyi_perf_bisect': 'official_goma_x86', 'win_perf_bisect': 'official_goma_x86',
diff --git a/tools/metrics/histograms/enums.xml b/tools/metrics/histograms/enums.xml index d0bbe2e7..5653ffa3 100644 --- a/tools/metrics/histograms/enums.xml +++ b/tools/metrics/histograms/enums.xml
@@ -14882,6 +14882,7 @@ <int value="1231" label="DECLARATIVENETREQUEST_ADDWHITELISTEDPAGES"/> <int value="1232" label="DECLARATIVENETREQUEST_REMOVEWHITELISTEDPAGES"/> <int value="1233" label="DECLARATIVENETREQUEST_GETWHITELISTEDPAGES"/> + <int value="1234" label="DEVELOPERPRIVATE_INSTALLDROPPEDFILE"/> </enum> <enum name="ExtensionIconState"> @@ -26283,6 +26284,7 @@ <int value="-881054479" label="WebAssemblyStreaming:disabled"/> <int value="-879055117" label="ClipboardContentSetting:enabled"/> <int value="-879031960" label="FetchKeepaliveTimeoutSetting:disabled"/> + <int value="-876773752" label="enable-tablet-splitview"/> <int value="-876148583" label="ArcBootCompletedBroadcast:disabled"/> <int value="-872764392" label="ContextualSuggestionsBottomSheet:disabled"/> <int value="-867087281" label="enable-virtual-keyboard"/> @@ -27075,7 +27077,6 @@ <int value="1070449228" label="ContextualSuggestionsCarousel:enabled"/> <int value="1072010558" label="NTPModernLayout:disabled"/> <int value="1074359194" label="UseSuggestionsEvenIfFew:enabled"/> - <int value="1075637651" label="disable-tablet-splitview"/> <int value="1079032226" label="ParallelDownloading:enabled"/> <int value="1081546525" label="ash-enable-docked-windows"/> <int value="1082054180" label="PersistentWindowBounds:disabled"/> @@ -31523,6 +31524,10 @@ label="282fb5cfbaf01518d9704de7884d7a25ff01cf882e994290d5995d5eb6c44988"/> <int value="490" label="fd371bea9755ff60c8828c849b8e5215de532d61b009855fa0ad630d90eef82e"/> + <int value="491" + label="d49c6f289cd056519492480f192f00a6fc7c1862dab2e7b5d8e05f6678fae141"/> + <int value="492" + label="cbad7b1d384849df0946b7ee8e7f5f7ce3aed876fda7bc9d30d8b16f29ff2c53"/> </enum> <enum name="Network3GGobiError">
diff --git a/tools/metrics/histograms/histograms.xml b/tools/metrics/histograms/histograms.xml index 0d380d94..61fc5bd 100644 --- a/tools/metrics/histograms/histograms.xml +++ b/tools/metrics/histograms/histograms.xml
@@ -64177,6 +64177,11 @@ </summary> </histogram> +<histogram name="PDF.FileSizeInKB" units="KB"> + <owner>thestig@chromium.org</owner> + <summary>The size of PDF documents opened in the PDF viewer.</summary> +</histogram> + <histogram name="PDF.FormType" enum="PDFFormTypes"> <owner>rharrison@chromium.org</owner> <summary> @@ -106841,6 +106846,9 @@ </histogram_suffixes> <histogram_suffixes name="DataReductionProxy.WithValidOCL.LoFiOn" separator="."> + <obsolete> + Deprecated 04/2018. + </obsolete> <suffix name="LoFiOn" label="Only page loads through the data reduction proxy with Lo-Fi On are considered."/>
diff --git a/ui/android/delegated_frame_host_android.cc b/ui/android/delegated_frame_host_android.cc index 6bbbd4c..7afe8c8 100644 --- a/ui/android/delegated_frame_host_android.cc +++ b/ui/android/delegated_frame_host_android.cc
@@ -112,6 +112,8 @@ const gfx::Rect& src_subrect, const gfx::Size& output_size, base::OnceCallback<void(const SkBitmap&)> callback) { + // TODO(vmpstr): We should defer this request until such time that this + // returns true. https://crbug.com/826097. if (!CanCopyFromCompositingSurface()) { std::move(callback).Run(SkBitmap()); return; @@ -148,7 +150,7 @@ gfx::Vector2d(output_size.width(), output_size.height())); } - support_->RequestCopyOfOutput(std::move(request)); + support_->RequestCopyOfOutput(local_surface_id_, std::move(request)); } bool DelegatedFrameHostAndroid::CanCopyFromCompositingSurface() const {
diff --git a/ui/views/controls/menu/menu_config_mac.mm b/ui/views/controls/menu/menu_config_mac.mm index 8a03829..e941661 100644 --- a/ui/views/controls/menu/menu_config_mac.mm +++ b/ui/views/controls/menu/menu_config_mac.mm
@@ -13,6 +13,7 @@ void MenuConfig::Init() { font_list = gfx::FontList(gfx::Font([NSFont menuFontOfSize:0.0])); menu_vertical_border_size = 4; + menu_horizontal_border_size = 0; item_top_margin = item_no_icon_top_margin = 1; item_bottom_margin = item_no_icon_bottom_margin = 1; item_left_margin = 2;
diff --git a/ui/views/widget/desktop_aura/desktop_screen_x11.cc b/ui/views/widget/desktop_aura/desktop_screen_x11.cc index 17464aaf..a982faa3 100644 --- a/ui/views/widget/desktop_aura/desktop_screen_x11.cc +++ b/ui/views/widget/desktop_aura/desktop_screen_x11.cc
@@ -6,6 +6,7 @@ #include "base/command_line.h" #include "base/logging.h" +#include "base/strings/stringprintf.h" #include "base/threading/thread_task_runner_handle.h" #include "base/trace_event/trace_event.h" #include "ui/aura/window.h" @@ -33,14 +34,22 @@ #include "ui/views/widget/desktop_aura/desktop_window_tree_host_x11.h" #include "ui/views/widget/desktop_aura/x11_topmost_window_finder.h" +#include <dlfcn.h> + namespace { // static -gfx::ICCProfile GetICCProfileFromBestMonitor() { +gfx::ICCProfile GetICCProfileForMonitor(int monitor) { gfx::ICCProfile icc_profile; if (base::CommandLine::ForCurrentProcess()->HasSwitch(switches::kHeadless)) return icc_profile; - Atom property = gfx::GetAtom("_ICC_PROFILE"); + std::string atom_name; + if (monitor == 0) { + atom_name = "_ICC_PROFILE"; + } else { + atom_name = base::StringPrintf("_ICC_PROFILE_%d", monitor); + } + Atom property = gfx::GetAtom(atom_name.c_str()); if (property != x11::None) { Atom prop_type = x11::None; int prop_format = 0; @@ -108,7 +117,7 @@ DesktopScreenX11::DesktopScreenX11() : xdisplay_(gfx::GetXDisplay()), x_root_window_(DefaultRootWindow(xdisplay_)), - has_xrandr_(false), + xrandr_version_(0), xrandr_event_base_(0), primary_display_index_(0), weak_factory_(this) { @@ -118,12 +127,11 @@ // use the new interface instead of the 1.2 one. int randr_version_major = 0; int randr_version_minor = 0; - has_xrandr_ = XRRQueryVersion( - xdisplay_, &randr_version_major, &randr_version_minor) && - randr_version_major == 1 && - randr_version_minor >= 3; - - if (has_xrandr_) { + if (XRRQueryVersion(xdisplay_, &randr_version_major, &randr_version_minor)) { + xrandr_version_ = randr_version_major * 100 + randr_version_minor; + } + // Need at least xrandr version 1.3. + if (xrandr_version_ >= 103) { int error_base_ignored = 0; XRRQueryExtension(xdisplay_, &xrandr_event_base_, &error_base_ignored); @@ -144,7 +152,7 @@ DesktopScreenX11::~DesktopScreenX11() { if (views::LinuxUI::instance()) views::LinuxUI::instance()->AddDeviceScaleFactorObserver(this); - if (has_xrandr_ && ui::PlatformEventSource::GetInstance()) + if (xrandr_version_ >= 103 && ui::PlatformEventSource::GetInstance()) ui::PlatformEventSource::GetInstance()->RemovePlatformEventDispatcher(this); } @@ -297,7 +305,7 @@ const std::vector<display::Display>& test_displays) : xdisplay_(gfx::GetXDisplay()), x_root_window_(DefaultRootWindow(xdisplay_)), - has_xrandr_(false), + xrandr_version_(0), xrandr_event_base_(0), displays_(test_displays), primary_display_index_(0), @@ -307,7 +315,7 @@ } std::vector<display::Display> DesktopScreenX11::BuildDisplaysFromXRandRInfo() { - DCHECK(has_xrandr_); + DCHECK(xrandr_version_ >= 103); std::vector<display::Display> displays; gfx::XScopedPtr< XRRScreenResources, @@ -318,6 +326,31 @@ return GetFallbackDisplayList(); } + std::map<RROutput, int> output_to_monitor; + if (xrandr_version_ >= 105) { + void* xrandr_lib = dlopen(NULL, RTLD_NOW); + if (xrandr_lib) { + typedef XRRMonitorInfo* (*XRRGetMonitors_type)(Display*, Window, bool, + int*); + typedef void (*XRRFreeMonitors_type)(XRRMonitorInfo*); + XRRGetMonitors_type XRRGetMonitors_ptr = + (XRRGetMonitors_type)dlsym(xrandr_lib, "XRRGetMonitors"); + XRRFreeMonitors_type XRRFreeMonitors_ptr = + (XRRFreeMonitors_type)dlsym(xrandr_lib, "XRRFreeMonitors"); + if (XRRGetMonitors_ptr && XRRFreeMonitors_ptr) { + int nmonitors = 0; + XRRMonitorInfo* monitors = + XRRGetMonitors_ptr(xdisplay_, x_root_window_, false, &nmonitors); + for (int monitor = 0; monitor < nmonitors; monitor++) { + for (int j = 0; j < monitors[monitor].noutput; j++) { + output_to_monitor[monitors[monitor].outputs[j]] = monitor; + } + } + XRRFreeMonitors_ptr(monitors); + } + } + } + primary_display_index_ = 0; RROutput primary_display_id = XRRGetOutputPrimary(xdisplay_, x_root_window_); @@ -397,10 +430,10 @@ if (is_primary_display) primary_display_index_ = displays.size(); - // TODO(ccameron): Populate this based on this specific display. - // http://crbug.com/735613 if (!display::Display::HasForceColorProfile()) { - gfx::ICCProfile icc_profile = GetICCProfileFromBestMonitor(); + auto monitor_iter = output_to_monitor.find(output_id); + gfx::ICCProfile icc_profile = GetICCProfileForMonitor( + monitor_iter == output_to_monitor.end() ? 0 : monitor_iter->second); icc_profile.HistogramDisplay(display.id()); display.set_color_space(icc_profile.GetColorSpace()); } @@ -424,7 +457,7 @@ void DesktopScreenX11::UpdateDisplays() { std::vector<display::Display> old_displays = displays_; - if (has_xrandr_) + if (xrandr_version_ > 103) SetDisplaysInternal(BuildDisplaysFromXRandRInfo()); else SetDisplaysInternal(GetFallbackDisplayList());
diff --git a/ui/views/widget/desktop_aura/desktop_screen_x11.h b/ui/views/widget/desktop_aura/desktop_screen_x11.h index 842eb01..6b7cb73 100644 --- a/ui/views/widget/desktop_aura/desktop_screen_x11.h +++ b/ui/views/widget/desktop_aura/desktop_screen_x11.h
@@ -87,8 +87,8 @@ ::Display* xdisplay_; ::Window x_root_window_; - // Whether the x server supports the XRandR extension. - bool has_xrandr_; + // XRandR version. MAJOR * 100 + MINOR. Zero if no xrandr is present. + int xrandr_version_; // The base of the event numbers used to represent XRandr events used in // decoding events regarding output add/remove.
diff --git a/ui/views/widget/root_view.cc b/ui/views/widget/root_view.cc index 5d0dddf..d07c9ba5 100644 --- a/ui/views/widget/root_view.cc +++ b/ui/views/widget/root_view.cc
@@ -9,6 +9,7 @@ #include "base/logging.h" #include "base/macros.h" #include "base/message_loop/message_loop.h" +#include "build/build_config.h" #include "ui/accessibility/ax_node_data.h" #include "ui/base/cursor/cursor.h" #include "ui/base/dragdrop/drag_drop_types.h" @@ -73,7 +74,8 @@ View* v = NULL; if (owner_->GetFocusManager()) // Can be NULL in unittests. v = owner_->GetFocusManager()->GetFocusedView(); - +// macOS doesn't have keyboard-triggered context menus. +#if !defined(OS_MACOSX) // Special case to handle keyboard-triggered context menus. if (v && v->enabled() && ((event->key_code() == ui::VKEY_APPS) || (event->key_code() == ui::VKEY_F10 && event->IsShiftDown()))) { @@ -88,6 +90,7 @@ v->ShowContextMenu(location, ui::MENU_SOURCE_KEYBOARD); event->StopPropagation(); } +#endif } View* owner_;
diff --git a/ui/views/widget/root_view_unittest.cc b/ui/views/widget/root_view_unittest.cc index 9f0cd55..8295917 100644 --- a/ui/views/widget/root_view_unittest.cc +++ b/ui/views/widget/root_view_unittest.cc
@@ -6,6 +6,7 @@ #include "base/macros.h" #include "base/memory/ptr_util.h" +#include "build/build_config.h" #include "ui/events/event_utils.h" #include "ui/views/context_menu_controller.h" #include "ui/views/test/views_test_base.h" @@ -111,6 +112,10 @@ // Tests that context menus are shown for certain key events (Shift+F10 // and VKEY_APPS) by the pre-target handler installed on RootView. TEST_F(RootViewTest, ContextMenuFromKeyEvent) { +#if defined(OS_MACOSX) + // This behavior is intentionally unsupported on macOS. + return; +#endif Widget widget; Widget::InitParams init_params = CreateParams(Widget::InitParams::TYPE_POPUP);
diff --git a/ui/webui/resources/cr_components/certificate_manager/ca_trust_edit_dialog.html b/ui/webui/resources/cr_components/certificate_manager/ca_trust_edit_dialog.html index 16e035e..388faf5d 100644 --- a/ui/webui/resources/cr_components/certificate_manager/ca_trust_edit_dialog.html +++ b/ui/webui/resources/cr_components/certificate_manager/ca_trust_edit_dialog.html
@@ -23,7 +23,7 @@ } </style> - <dialog is="cr-dialog" id="dialog" close-text="[[i18n('close')]]"> + <cr-dialog id="dialog" close-text="[[i18n('close')]]"> <div slot="title"> [[i18n('certificateManagerCaTrustEditDialogTitle')]] </div> @@ -51,7 +51,7 @@ [[i18n('ok')]] </paper-button> </div> - </dialog> + </cr-dialog> </template> <script src="ca_trust_edit_dialog.js"></script> </dom-module>
diff --git a/ui/webui/resources/cr_components/certificate_manager/certificate_delete_confirmation_dialog.html b/ui/webui/resources/cr_components/certificate_manager/certificate_delete_confirmation_dialog.html index fbf253c..73d8209 100644 --- a/ui/webui/resources/cr_components/certificate_manager/certificate_delete_confirmation_dialog.html +++ b/ui/webui/resources/cr_components/certificate_manager/certificate_delete_confirmation_dialog.html
@@ -9,7 +9,7 @@ <dom-module id="certificate-delete-confirmation-dialog"> <template> <style include="certificate-shared"></style> - <dialog is="cr-dialog" id="dialog" close-text="[[i18n('close')]]"> + <cr-dialog id="dialog" close-text="[[i18n('close')]]"> <div slot="title"> [[getTitleText_(model, certificateType)]] </div> @@ -24,7 +24,7 @@ [[i18n('ok')]] </paper-button> </div> - </dialog> + </cr-dialog> </template> <script src="certificate_delete_confirmation_dialog.js"></script> </dom-module>
diff --git a/ui/webui/resources/cr_components/certificate_manager/certificate_password_decryption_dialog.html b/ui/webui/resources/cr_components/certificate_manager/certificate_password_decryption_dialog.html index 850da130..664a410d 100644 --- a/ui/webui/resources/cr_components/certificate_manager/certificate_password_decryption_dialog.html +++ b/ui/webui/resources/cr_components/certificate_manager/certificate_password_decryption_dialog.html
@@ -10,7 +10,7 @@ <dom-module id="certificate-password-decryption-dialog"> <template> <style include="certificate-shared"></style> - <dialog is="cr-dialog" id="dialog" close-text="[[i18n('close')]]"> + <cr-dialog id="dialog" close-text="[[i18n('close')]]"> <div slot="title"> [[i18n('certificateManagerDecryptPasswordTitle')]] </div> @@ -28,7 +28,7 @@ [[i18n('ok')]] </paper-button> </div> - </dialog> + </cr-dialog> </template> <script src="certificate_password_decryption_dialog.js"></script> </dom-module>
diff --git a/ui/webui/resources/cr_components/certificate_manager/certificate_password_encryption_dialog.html b/ui/webui/resources/cr_components/certificate_manager/certificate_password_encryption_dialog.html index f17b282..a3ad6fd2 100644 --- a/ui/webui/resources/cr_components/certificate_manager/certificate_password_encryption_dialog.html +++ b/ui/webui/resources/cr_components/certificate_manager/certificate_password_encryption_dialog.html
@@ -14,7 +14,7 @@ margin-bottom: 20px; } </style> - <dialog is="cr-dialog" id="dialog" close-text="[[i18n('close')]]"> + <cr-dialog id="dialog" close-text="[[i18n('close')]]"> <div slot="title"> [[i18n('certificateManagerEncryptPasswordTitle')]] </div> @@ -38,7 +38,7 @@ [[i18n('ok')]] </paper-button> </div> - </dialog> + </cr-dialog> </template> <script src="certificate_password_encryption_dialog.js"></script> </dom-module>
diff --git a/ui/webui/resources/cr_components/certificate_manager/certificates_error_dialog.html b/ui/webui/resources/cr_components/certificate_manager/certificates_error_dialog.html index 2c0bb746..ae1d5c5 100644 --- a/ui/webui/resources/cr_components/certificate_manager/certificates_error_dialog.html +++ b/ui/webui/resources/cr_components/certificate_manager/certificates_error_dialog.html
@@ -8,7 +8,7 @@ <dom-module id="certificates-error-dialog"> <template> <style include="certificate-shared"></style> - <dialog is="cr-dialog" id="dialog" close-text="[[i18n('close')]]"> + <cr-dialog id="dialog" close-text="[[i18n('close')]]"> <div slot="title">[[model.title]]</div> <div slot="body"> <div>[[model.description]]</div> @@ -23,7 +23,7 @@ [[i18n('ok')]] </paper-button> </div> - </dialog> + </cr-dialog> </template> <script src="certificates_error_dialog.js"></script> </dom-module>
diff --git a/ui/webui/resources/cr_components/chromeos/bluetooth_dialog.html b/ui/webui/resources/cr_components/chromeos/bluetooth_dialog.html index a71d029..e42cfe1e 100644 --- a/ui/webui/resources/cr_components/chromeos/bluetooth_dialog.html +++ b/ui/webui/resources/cr_components/chromeos/bluetooth_dialog.html
@@ -12,8 +12,8 @@ <dom-module id="bluetooth-dialog"> <template> <style include="cr-hidden-style iron-flex"> - dialog { - @apply --bluetooth-dialog-style; + cr-dialog { + --cr-dialog-native: var(--bluetooth-dialog-style); } #pairing { @@ -73,7 +73,7 @@ } </style> <!-- TODO(stevenjb/dschuyler): Find a solution to support i18n{} here --> - <dialog is="cr-dialog" id="dialog" no-cancel="[[noCancel]]" + <cr-dialog id="dialog" no-cancel="[[noCancel]]" close-text="[[i18n('close')]]" on-cancel="onDialogCanceled_" on-closed="onDialogCanceled_"> <div slot="title">[[dialogTitle]]</div> @@ -136,7 +136,7 @@ <paper-button on-tap="close">[[i18n('ok')]]</paper-button> </template> </div> - </dialog> + </cr-dialog> </template> <script src="bluetooth_dialog.js"></script> </dom-module>
diff --git a/ui/webui/resources/cr_components/chromeos/network/network_siminfo.html b/ui/webui/resources/cr_components/chromeos/network/network_siminfo.html index 50c300e56..0cff8dd8 100644 --- a/ui/webui/resources/cr_components/chromeos/network/network_siminfo.html +++ b/ui/webui/resources/cr_components/chromeos/network/network_siminfo.html
@@ -90,7 +90,7 @@ </div> <!-- Enter PIN dialog --> - <dialog is="cr-dialog" id="enterPinDialog" close-text="[[i18n('close')]]" + <cr-dialog id="enterPinDialog" close-text="[[i18n('close')]]" on-cancel="onEnterPinDialogCancel_" on-close="onEnterPinDialogClose_"> <div slot="title">[[i18n('networkSimEnterPinTitle')]]</div> @@ -109,10 +109,10 @@ [[i18n('networkSimEnter')]] </paper-button> </div> - </dialog> + </cr-dialog> <!-- Change PIN dialog --> - <dialog is="cr-dialog" id="changePinDialog" close-text="[[i18n('close')]]" + <cr-dialog id="changePinDialog" close-text="[[i18n('close')]]" on-close="onChangePinDialogClose_"> <div slot="title">[[i18n('networkSimChangePinTitle')]]</div> <div slot="body"> @@ -136,10 +136,10 @@ [[i18n('networkSimChange')]] </paper-button> </div> - </dialog> + </cr-dialog> <!-- Unlock PIN dialog --> - <dialog is="cr-dialog" id="unlockPinDialog" close-text="[[i18n('close')]]" + <cr-dialog id="unlockPinDialog" close-text="[[i18n('close')]]" on-close="onUnlockPinDialogClose_"> <div slot="title">[[i18n('networkSimLockedTitle')]]</div> <div slot="body"> @@ -157,10 +157,10 @@ [[i18n('networkSimUnlock')]] </paper-button> </div> - </dialog> + </cr-dialog> <!-- Unlock PUK dialog --> - <dialog is="cr-dialog" id="unlockPukDialog" close-text="[[i18n('close')]]" + <cr-dialog id="unlockPukDialog" close-text="[[i18n('close')]]" on-close="onUnlockPinDialogClose_"> <div slot="title">[[i18n('networkSimLockedTitle')]]</div> <div slot="body"> @@ -190,7 +190,7 @@ [[i18n('networkSimUnlock')]] </paper-button> </div> - </dialog> + </cr-dialog> </template> <script src="network_siminfo.js"></script> </dom-module>
diff --git a/ui/webui/resources/cr_elements/cr_dialog/cr_dialog.html b/ui/webui/resources/cr_elements/cr_dialog/cr_dialog.html index ab6bc62a..78c091b 100644 --- a/ui/webui/resources/cr_elements/cr_dialog/cr_dialog.html +++ b/ui/webui/resources/cr_elements/cr_dialog/cr_dialog.html
@@ -9,7 +9,7 @@ <dom-module id="cr-dialog"> <template> <style include="cr-hidden-style cr-icons"> - :host { + dialog { --scroll-border: 1px solid var(--paper-grey-300); border: 0; border-radius: 2px; @@ -21,9 +21,10 @@ padding: 0; top: 50%; width: 512px; + @apply --cr-dialog-native; } - :host([open]) #content-wrapper { + dialog[open] #content-wrapper { /* Keep max-height within viewport, and flex content accordingly. */ display: flex; flex-direction: column; @@ -39,7 +40,7 @@ flex-shrink: 0; } - :host::backdrop { + dialog::backdrop { background-color: rgba(0, 0, 0, 0.6); bottom: 0; left: 0; @@ -128,29 +129,31 @@ @apply --cr-dialog-close-image-active; } </style> - <!-- This wrapper is necessary, such that the "pulse" animation is not - erroneously played when the user clicks on the outer-most scrollbar. --> - <div id="content-wrapper"> - <div class="top-container"> - <div class="title-container" tabindex="-1"> - <slot name="title"></slot> + <dialog id="dialog"> + <!-- This wrapper is necessary, such that the "pulse" animation is not + erroneously played when the user clicks on the outer-most scrollbar. --> + <div id="content-wrapper"> + <div class="top-container"> + <div class="title-container" tabindex="-1"> + <slot name="title"></slot> + </div> + <paper-icon-button-light id="closeContainer" class="icon-clear" + hidden$="[[noCancel]]"> + <button id="close" aria-label$="[[closeText]]" + on-tap="cancel" on-keypress="onCloseKeypress_"> + </button> + </paper-icon-button-light> </div> - <paper-icon-button-light id="closeContainer" class="icon-clear" - hidden$="[[noCancel]]"> - <button id="close" aria-label$="[[closeText]]" - on-tap="cancel" on-keypress="onCloseKeypress_"> - </button> - </paper-icon-button-light> + <slot name="header"></slot> + <div class="body-container"> + <span id="bodyTopMarker"></span> + <slot name="body"></slot> + <span id="bodyBottomMarker"></span> + </div> + <slot name="button-container"></slot> + <slot name="footer"></slot> </div> - <slot name="header"></slot> - <div class="body-container"> - <span id="bodyTopMarker"></span> - <slot name="body"></slot> - <span id="bodyBottomMarker"></span> - </div> - <slot name="button-container"></slot> - <slot name="footer"></slot> - </div> + </dialog> </template> <script src="cr_dialog.js"></script> </dom-module>
diff --git a/ui/webui/resources/cr_elements/cr_dialog/cr_dialog.js b/ui/webui/resources/cr_elements/cr_dialog/cr_dialog.js index 59ee2f6..554d8463 100644 --- a/ui/webui/resources/cr_elements/cr_dialog/cr_dialog.js +++ b/ui/webui/resources/cr_elements/cr_dialog/cr_dialog.js
@@ -6,16 +6,29 @@ * @fileoverview 'cr-dialog' is a component for showing a modal dialog. If the * dialog is closed via close(), a 'close' event is fired. If the dialog is * canceled via cancel(), a 'cancel' event is fired followed by a 'close' event. - * Additionally clients can inspect the dialog's |returnValue| property inside + * + * Additionally clients can get a reference to the internal native <dialog> via + * calling getNative() and inspecting the |returnValue| property inside * the 'close' event listener to determine whether it was canceled or just * closed, where a truthy value means success, and a falsy value means it was * canceled. + * + * Note that <cr-dialog> wrapper itself always has 0x0 dimensions, and + * specifying width/height on <cr-dialog> directly will have no effect on the + * internal native <dialog>. Instead use the --cr-dialog-native mixin to specify + * width/height (as well as other available mixins to style other parts of the + * dialog contents). */ Polymer({ is: 'cr-dialog', - extends: 'dialog', properties: { + open: { + type: Boolean, + value: false, + reflectToAttribute: true, + }, + /** * Alt-text for the dialog close button. */ @@ -63,7 +76,7 @@ // If the active history entry changes (i.e. user clicks back button), // all open dialogs should be cancelled. window.addEventListener('popstate', function() { - if (!this.ignorePopstate && this.open) + if (!this.ignorePopstate && this.$.dialog.open) this.cancel(); }.bind(this)); @@ -77,7 +90,7 @@ /** @override */ attached: function() { var mutationObserverCallback = function() { - if (this.open) + if (this.$.dialog.open) this.addIntersectionObserver_(); else this.removeIntersectionObserver_(); @@ -85,7 +98,7 @@ this.mutationObserver_ = new MutationObserver(mutationObserverCallback); - this.mutationObserver_.observe(this, { + this.mutationObserver_.observe(this.$.dialog, { attributes: true, attributeFilter: ['open'], }); @@ -146,17 +159,20 @@ } }, - cancel: function() { - this.fire('cancel'); - HTMLDialogElement.prototype.close.call(this, ''); + showModal: function() { + this.$.dialog.showModal(); + this.open = this.$.dialog.open; }, - /** - * @param {string=} opt_returnValue - * @override - */ - close: function(opt_returnValue) { - HTMLDialogElement.prototype.close.call(this, 'success'); + cancel: function() { + this.fire('cancel'); + this.$.dialog.close(); + this.open = this.$.dialog.open; + }, + + close: function() { + this.$.dialog.close('success'); + this.open = this.$.dialog.open; }, /** @@ -169,6 +185,16 @@ e.stopPropagation(); }, + /** + * Expose the inner native <dialog> for some rare cases where it needs to be + * directly accessed (for example to programmatically setheight/width, which + * would not work on the wrapper). + * @return {!HTMLDialogElement} + */ + getNative: function() { + return this.$.dialog; + }, + /** @return {!PaperIconButtonElement} */ getCloseButton: function() { return this.$.close; @@ -210,7 +236,7 @@ if (e.button != 0 || e.composedPath()[0].tagName !== 'DIALOG') return; - this.animate( + this.$.dialog.animate( [ {transform: 'scale(1)', offset: 0}, {transform: 'scale(1.02)', offset: 0.4},
diff --git a/url/gurl_unittest.cc b/url/gurl_unittest.cc index 95e71f23..517c83c 100644 --- a/url/gurl_unittest.cc +++ b/url/gurl_unittest.cc
@@ -197,7 +197,7 @@ GURL url2(url); EXPECT_TRUE(url2.is_valid()); - EXPECT_EQ("filesystem:https://user:pass@google.com:99/t/foo;bar?q=a#ref", url2.spec()); + EXPECT_EQ("filesystem:https://google.com:99/t/foo;bar?q=a#ref", url2.spec()); EXPECT_EQ("filesystem", url2.scheme()); EXPECT_EQ("", url2.username()); EXPECT_EQ("", url2.password()); @@ -211,8 +211,8 @@ const GURL* inner = url2.inner_url(); ASSERT_TRUE(inner); EXPECT_EQ("https", inner->scheme()); - EXPECT_EQ("user", inner->username()); - EXPECT_EQ("pass", inner->password()); + EXPECT_EQ("", inner->username()); + EXPECT_EQ("", inner->password()); EXPECT_EQ("google.com", inner->host()); EXPECT_EQ("99", inner->port()); EXPECT_EQ(99, inner->IntPort());
diff --git a/url/scheme_host_port.cc b/url/scheme_host_port.cc index c30a142..c4f0ba5d 100644 --- a/url/scheme_host_port.cc +++ b/url/scheme_host_port.cc
@@ -60,6 +60,7 @@ return false; switch (scheme_type) { + case SCHEME_WITH_HOST_AND_PORT: case SCHEME_WITH_HOST_PORT_AND_USER_INFORMATION: // A URL with |scheme| is required to have the host and port (may be // omitted in a serialization if it's the same as the default value).
diff --git a/url/url_canon.h b/url/url_canon.h index ede62d3..618ff7b9 100644 --- a/url/url_canon.h +++ b/url/url_canon.h
@@ -220,6 +220,31 @@ CanonOutput* output) = 0; }; +// Schemes -------------------------------------------------------------------- + +// Types of a scheme representing the requirements on the data represented by +// the authority component of a URL with the scheme. +enum SchemeType { + // The authority component of a URL with the scheme has the form + // "username:password@host:port". The username and password entries are + // optional; the host may not be empty. The default value of the port can be + // omitted in serialization. This type occurs with network schemes like http, + // https, and ftp. + SCHEME_WITH_HOST_PORT_AND_USER_INFORMATION, + // The authority component of a URL with the scheme has the form "host:port", + // and does not include username or password. The default value of the port + // can be omitted in serialization. Used by inner URLs of filesystem URLs of + // origins with network hosts, from which the username and password are + // stripped. + SCHEME_WITH_HOST_AND_PORT, + // The authority component of an URL with the scheme has the form "host", and + // does not include port, username, or password. Used when the hosts are not + // network addresses; for example, schemes used internally by the browser. + SCHEME_WITH_HOST, + // A URL with the scheme doesn't have the authority component. + SCHEME_WITHOUT_AUTHORITY, +}; + // Whitespace ----------------------------------------------------------------- // Searches for whitespace that should be removed from the middle of URLs, and @@ -549,12 +574,14 @@ URL_EXPORT bool CanonicalizeStandardURL(const char* spec, int spec_len, const Parsed& parsed, + SchemeType scheme_type, CharsetConverter* query_converter, CanonOutput* output, Parsed* new_parsed); URL_EXPORT bool CanonicalizeStandardURL(const base::char16* spec, int spec_len, const Parsed& parsed, + SchemeType scheme_type, CharsetConverter* query_converter, CanonOutput* output, Parsed* new_parsed); @@ -802,6 +829,7 @@ URL_EXPORT bool ReplaceStandardURL(const char* base, const Parsed& base_parsed, const Replacements<char>& replacements, + SchemeType scheme_type, CharsetConverter* query_converter, CanonOutput* output, Parsed* new_parsed); @@ -809,6 +837,7 @@ const char* base, const Parsed& base_parsed, const Replacements<base::char16>& replacements, + SchemeType scheme_type, CharsetConverter* query_converter, CanonOutput* output, Parsed* new_parsed);
diff --git a/url/url_canon_filesystemurl.cc b/url/url_canon_filesystemurl.cc index 18e90552..e9f5b22 100644 --- a/url/url_canon_filesystemurl.cc +++ b/url/url_canon_filesystemurl.cc
@@ -43,16 +43,22 @@ return false; bool success = true; + SchemeType inner_scheme_type = SCHEME_WITH_HOST_PORT_AND_USER_INFORMATION; if (CompareSchemeComponent(spec, inner_parsed->scheme, url::kFileScheme)) { new_inner_parsed.scheme.begin = output->length(); output->Append("file://", 7); new_inner_parsed.scheme.len = 4; success &= CanonicalizePath(spec, inner_parsed->path, output, &new_inner_parsed.path); - } else if (IsStandard(spec, inner_parsed->scheme)) { - success = CanonicalizeStandardURL(spec, parsed.inner_parsed()->Length(), - *parsed.inner_parsed(), charset_converter, - output, &new_inner_parsed); + } else if (GetStandardSchemeType(spec, inner_parsed->scheme, + &inner_scheme_type)) { + if (inner_scheme_type == SCHEME_WITH_HOST_PORT_AND_USER_INFORMATION) { + // Strip out the user information from the inner URL, if any. + inner_scheme_type = SCHEME_WITH_HOST_AND_PORT; + } + success = CanonicalizeStandardURL( + spec, parsed.inner_parsed()->Length(), *parsed.inner_parsed(), + inner_scheme_type, charset_converter, output, &new_inner_parsed); } else { // TODO(ericu): The URL is wrong, but should we try to output more of what // we were given? Echoing back filesystem:mailto etc. doesn't seem all that
diff --git a/url/url_canon_relative.cc b/url/url_canon_relative.cc index 659aca7f..7ef5ee3d 100644 --- a/url/url_canon_relative.cc +++ b/url/url_canon_relative.cc
@@ -12,6 +12,7 @@ #include "url/url_constants.h" #include "url/url_file.h" #include "url/url_parse_internal.h" +#include "url/url_util.h" #include "url/url_util_internal.h" namespace url { @@ -407,7 +408,13 @@ output->ReserveSizeIfNeeded( replacements.components().Length() + base_parsed.CountCharactersBefore(Parsed::USERNAME, false)); - return ReplaceStandardURL(base_url, base_parsed, replacements, + SchemeType scheme_type = SCHEME_WITH_HOST_PORT_AND_USER_INFORMATION; + if (!GetStandardSchemeType(base_url, base_parsed.scheme, &scheme_type)) { + // A path with an authority section gets canonicalized under standard URL + // rules, even though the base was not known to be standard. + scheme_type = SCHEME_WITH_HOST_PORT_AND_USER_INFORMATION; + } + return ReplaceStandardURL(base_url, base_parsed, replacements, scheme_type, query_converter, output, out_parsed); }
diff --git a/url/url_canon_stdurl.cc b/url/url_canon_stdurl.cc index 7d1758b..c619322 100644 --- a/url/url_canon_stdurl.cc +++ b/url/url_canon_stdurl.cc
@@ -13,9 +13,10 @@ namespace { -template<typename CHAR, typename UCHAR> +template <typename CHAR, typename UCHAR> bool DoCanonicalizeStandardURL(const URLComponentSource<CHAR>& source, const Parsed& parsed, + SchemeType scheme_type, CharsetConverter* query_converter, CanonOutput* output, Parsed* new_parsed) { @@ -23,10 +24,18 @@ bool success = CanonicalizeScheme(source.scheme, parsed.scheme, output, &new_parsed->scheme); + bool scheme_supports_user_info = + (scheme_type == SCHEME_WITH_HOST_PORT_AND_USER_INFORMATION); + bool scheme_supports_ports = + (scheme_type == SCHEME_WITH_HOST_PORT_AND_USER_INFORMATION || + scheme_type == SCHEME_WITH_HOST_AND_PORT); + // Authority (username, password, host, port) bool have_authority; - if (parsed.username.is_valid() || parsed.password.is_valid() || - parsed.host.is_nonempty() || parsed.port.is_valid()) { + if ((scheme_supports_user_info && + (parsed.username.is_valid() || parsed.password.is_valid())) || + parsed.host.is_nonempty() || + (scheme_supports_ports && parsed.port.is_valid())) { have_authority = true; // Only write the authority separators when we have a scheme. @@ -36,11 +45,14 @@ } // User info: the canonicalizer will handle the : and @. - success &= CanonicalizeUserInfo(source.username, parsed.username, - source.password, parsed.password, - output, - &new_parsed->username, - &new_parsed->password); + if (scheme_supports_user_info) { + success &= CanonicalizeUserInfo( + source.username, parsed.username, source.password, parsed.password, + output, &new_parsed->username, &new_parsed->password); + } else { + new_parsed->username.reset(); + new_parsed->password.reset(); + } success &= CanonicalizeHost(source.host, parsed.host, output, &new_parsed->host); @@ -50,10 +62,14 @@ success = false; // Port: the port canonicalizer will handle the colon. - int default_port = DefaultPortForScheme( - &output->data()[new_parsed->scheme.begin], new_parsed->scheme.len); - success &= CanonicalizePort(source.port, parsed.port, default_port, - output, &new_parsed->port); + if (scheme_supports_ports) { + int default_port = DefaultPortForScheme( + &output->data()[new_parsed->scheme.begin], new_parsed->scheme.len); + success &= CanonicalizePort(source.port, parsed.port, default_port, + output, &new_parsed->port); + } else { + new_parsed->port.reset(); + } } else { // No authority, clear the components. have_authority = false; @@ -127,23 +143,25 @@ bool CanonicalizeStandardURL(const char* spec, int spec_len, const Parsed& parsed, + SchemeType scheme_type, CharsetConverter* query_converter, CanonOutput* output, Parsed* new_parsed) { return DoCanonicalizeStandardURL<char, unsigned char>( - URLComponentSource<char>(spec), parsed, query_converter, + URLComponentSource<char>(spec), parsed, scheme_type, query_converter, output, new_parsed); } bool CanonicalizeStandardURL(const base::char16* spec, int spec_len, const Parsed& parsed, + SchemeType scheme_type, CharsetConverter* query_converter, CanonOutput* output, Parsed* new_parsed) { return DoCanonicalizeStandardURL<base::char16, base::char16>( - URLComponentSource<base::char16>(spec), parsed, query_converter, - output, new_parsed); + URLComponentSource<base::char16>(spec), parsed, scheme_type, + query_converter, output, new_parsed); } // It might be nice in the future to optimize this so unchanged components don't @@ -158,6 +176,7 @@ bool ReplaceStandardURL(const char* base, const Parsed& base_parsed, const Replacements<char>& replacements, + SchemeType scheme_type, CharsetConverter* query_converter, CanonOutput* output, Parsed* new_parsed) { @@ -165,7 +184,7 @@ Parsed parsed(base_parsed); SetupOverrideComponents(base, replacements, &source, &parsed); return DoCanonicalizeStandardURL<char, unsigned char>( - source, parsed, query_converter, output, new_parsed); + source, parsed, scheme_type, query_converter, output, new_parsed); } // For 16-bit replacements, we turn all the replacements into UTF-8 so the @@ -173,6 +192,7 @@ bool ReplaceStandardURL(const char* base, const Parsed& base_parsed, const Replacements<base::char16>& replacements, + SchemeType scheme_type, CharsetConverter* query_converter, CanonOutput* output, Parsed* new_parsed) { @@ -181,7 +201,7 @@ Parsed parsed(base_parsed); SetupUTF16OverrideComponents(base, replacements, &utf8, &source, &parsed); return DoCanonicalizeStandardURL<char, unsigned char>( - source, parsed, query_converter, output, new_parsed); + source, parsed, scheme_type, query_converter, output, new_parsed); } } // namespace url
diff --git a/url/url_canon_unittest.cc b/url/url_canon_unittest.cc index b4dd9d43..a29db7f9 100644 --- a/url/url_canon_unittest.cc +++ b/url/url_canon_unittest.cc
@@ -1433,7 +1433,8 @@ std::string out_str; StdStringCanonOutput output(&out_str); bool success = CanonicalizeStandardURL( - cases[i].input, url_len, parsed, NULL, &output, &out_parsed); + cases[i].input, url_len, parsed, + SCHEME_WITH_HOST_PORT_AND_USER_INFORMATION, NULL, &output, &out_parsed); output.Complete(); EXPECT_EQ(cases[i].expected_success, success); @@ -1479,8 +1480,9 @@ std::string out_str; StdStringCanonOutput output(&out_str); Parsed out_parsed; - ReplaceStandardURL(replace_cases[i].base, parsed, r, NULL, &output, - &out_parsed); + ReplaceStandardURL(replace_cases[i].base, parsed, r, + SCHEME_WITH_HOST_PORT_AND_USER_INFORMATION, NULL, + &output, &out_parsed); output.Complete(); EXPECT_EQ(replace_cases[i].expected, out_str); @@ -1501,7 +1503,9 @@ std::string out_str1; StdStringCanonOutput output1(&out_str1); Parsed new_parsed; - ReplaceStandardURL(src, parsed, r, NULL, &output1, &new_parsed); + ReplaceStandardURL(src, parsed, r, + SCHEME_WITH_HOST_PORT_AND_USER_INFORMATION, NULL, + &output1, &new_parsed); output1.Complete(); EXPECT_STREQ("http://www.google.com/", out_str1.c_str()); @@ -1509,7 +1513,9 @@ r.SetPath(reinterpret_cast<char*>(0x00000001), Component()); std::string out_str2; StdStringCanonOutput output2(&out_str2); - ReplaceStandardURL(src, parsed, r, NULL, &output2, &new_parsed); + ReplaceStandardURL(src, parsed, r, + SCHEME_WITH_HOST_PORT_AND_USER_INFORMATION, NULL, + &output2, &new_parsed); output2.Complete(); EXPECT_STREQ("http://www.google.com/", out_str2.c_str()); } @@ -1564,24 +1570,39 @@ TEST(URLCanonTest, ReplaceFileSystemURL) { ReplaceCase replace_cases[] = { // Replace everything in the outer URL. - {"filesystem:file:///temporary/gaba?query#ref", NULL, NULL, NULL, NULL, NULL, "/foo", "b", "c", "filesystem:file:///temporary/foo?b#c"}, + {"filesystem:file:///temporary/gaba?query#ref", NULL, NULL, NULL, NULL, + NULL, "/foo", "b", "c", "filesystem:file:///temporary/foo?b#c"}, // Replace nothing - {"filesystem:file:///temporary/gaba?query#ref", NULL, NULL, NULL, NULL, NULL, NULL, NULL, NULL, "filesystem:file:///temporary/gaba?query#ref"}, + {"filesystem:file:///temporary/gaba?query#ref", NULL, NULL, NULL, NULL, + NULL, NULL, NULL, NULL, "filesystem:file:///temporary/gaba?query#ref"}, // Clear non-path components (common) - {"filesystem:file:///temporary/gaba?query#ref", NULL, NULL, NULL, NULL, NULL, NULL, kDeleteComp, kDeleteComp, "filesystem:file:///temporary/gaba"}, + {"filesystem:file:///temporary/gaba?query#ref", NULL, NULL, NULL, NULL, + NULL, NULL, kDeleteComp, kDeleteComp, + "filesystem:file:///temporary/gaba"}, // Replace path with something that doesn't begin with a slash and make // sure it gets added properly. - {"filesystem:file:///temporary/gaba?query#ref", NULL, NULL, NULL, NULL, NULL, "interesting/", NULL, NULL, "filesystem:file:///temporary/interesting/?query#ref"}, - // Replace scheme -- shouldn't do anything. - {"filesystem:http://u:p@bar.com/t/gaba?query#ref", "http", NULL, NULL, NULL, NULL, NULL, NULL, NULL, "filesystem:http://u:p@bar.com/t/gaba?query#ref"}, - // Replace username -- shouldn't do anything. - {"filesystem:http://u:p@bar.com/t/gaba?query#ref", NULL, "u2", NULL, NULL, NULL, NULL, NULL, NULL, "filesystem:http://u:p@bar.com/t/gaba?query#ref"}, - // Replace password -- shouldn't do anything. - {"filesystem:http://u:p@bar.com/t/gaba?query#ref", NULL, NULL, "pw2", NULL, NULL, NULL, NULL, NULL, "filesystem:http://u:p@bar.com/t/gaba?query#ref"}, - // Replace host -- shouldn't do anything. - {"filesystem:http://u:p@bar.com/t/gaba?query#ref", NULL, NULL, NULL, "foo.com", NULL, NULL, NULL, NULL, "filesystem:http://u:p@bar.com/t/gaba?query#ref"}, - // Replace port -- shouldn't do anything. - {"filesystem:http://u:p@bar.com:40/t/gaba?query#ref", NULL, NULL, NULL, NULL, "41", NULL, NULL, NULL, "filesystem:http://u:p@bar.com:40/t/gaba?query#ref"}, + {"filesystem:file:///temporary/gaba?query#ref", NULL, NULL, NULL, NULL, + NULL, "interesting/", NULL, NULL, + "filesystem:file:///temporary/interesting/?query#ref"}, + // Replace scheme -- shouldn't do anything except canonicalize. + {"filesystem:http://u:p@bar.com/t/gaba?query#ref", "http", NULL, NULL, + NULL, NULL, NULL, NULL, NULL, + "filesystem:http://bar.com/t/gaba?query#ref"}, + // Replace username -- shouldn't do anything except canonicalize. + {"filesystem:http://u:p@bar.com/t/gaba?query#ref", NULL, "u2", NULL, NULL, + NULL, NULL, NULL, NULL, "filesystem:http://bar.com/t/gaba?query#ref"}, + // Replace password -- shouldn't do anything except canonicalize. + {"filesystem:http://u:p@bar.com/t/gaba?query#ref", NULL, NULL, "pw2", + NULL, NULL, NULL, NULL, NULL, + "filesystem:http://bar.com/t/gaba?query#ref"}, + // Replace host -- shouldn't do anything except canonicalize. + {"filesystem:http://u:p@bar.com:80/t/gaba?query#ref", NULL, NULL, NULL, + "foo.com", NULL, NULL, NULL, NULL, + "filesystem:http://bar.com/t/gaba?query#ref"}, + // Replace port -- shouldn't do anything except canonicalize. + {"filesystem:http://u:p@bar.com:40/t/gaba?query#ref", NULL, NULL, NULL, + NULL, "41", NULL, NULL, NULL, + "filesystem:http://bar.com:40/t/gaba?query#ref"}, }; for (size_t i = 0; i < arraysize(replace_cases); i++) {
diff --git a/url/url_util.cc b/url/url_util.cc index 8cfaa63..dd4e914 100644 --- a/url/url_util.cc +++ b/url/url_util.cc
@@ -31,7 +31,7 @@ {kHttpScheme, SCHEME_WITH_HOST_PORT_AND_USER_INFORMATION}, // Yes, file URLs can have a hostname, so file URLs should be handled as // "standard". File URLs never have a port as specified by the SchemeType - // field. Unlike other SCHEME_WITH_HOST schemes, the 'host' in a file + // field. Unlike other SCHEME_WITH_HOST schemes, the 'host' in a file // URL may be empty, a behavior which is special-cased during // canonicalization. {kFileScheme, SCHEME_WITH_HOST}, @@ -244,7 +244,7 @@ // This is the parsed version of the input URL, we have to canonicalize it // before storing it in our object. bool success; - SchemeType unused_scheme_type = SCHEME_WITH_HOST_PORT_AND_USER_INFORMATION; + SchemeType scheme_type = SCHEME_WITH_HOST_PORT_AND_USER_INFORMATION; if (DoCompareSchemeComponent(spec, scheme, url::kFileScheme)) { // File URLs are special. ParseFileURL(spec, spec_len, &parsed_input); @@ -257,10 +257,10 @@ charset_converter, output, output_parsed); - } else if (DoIsStandard(spec, scheme, &unused_scheme_type)) { + } else if (DoIsStandard(spec, scheme, &scheme_type)) { // All "normal" URLs. ParseStandardURL(spec, spec_len, &parsed_input); - success = CanonicalizeStandardURL(spec, spec_len, parsed_input, + success = CanonicalizeStandardURL(spec, spec_len, parsed_input, scheme_type, charset_converter, output, output_parsed); } else if (DoCompareSchemeComponent(spec, scheme, url::kMailToScheme)) { @@ -442,10 +442,10 @@ return ReplaceFileSystemURL(spec, parsed, replacements, charset_converter, output, out_parsed); } - SchemeType unused_scheme_type = SCHEME_WITH_HOST_PORT_AND_USER_INFORMATION; - if (DoIsStandard(spec, parsed.scheme, &unused_scheme_type)) { - return ReplaceStandardURL(spec, parsed, replacements, charset_converter, - output, out_parsed); + SchemeType scheme_type = SCHEME_WITH_HOST_PORT_AND_USER_INFORMATION; + if (DoIsStandard(spec, parsed.scheme, &scheme_type)) { + return ReplaceStandardURL(spec, parsed, replacements, scheme_type, + charset_converter, output, out_parsed); } if (DoCompareSchemeComponent(spec, parsed.scheme, url::kMailToScheme)) { return ReplaceMailtoURL(spec, parsed, replacements, output, out_parsed); @@ -646,6 +646,12 @@ return DoIsStandard(spec, scheme, type); } +bool GetStandardSchemeType(const base::char16* spec, + const Component& scheme, + SchemeType* type) { + return DoIsStandard(spec, scheme, type); +} + bool IsStandard(const base::char16* spec, const Component& scheme) { SchemeType unused_scheme_type; return DoIsStandard(spec, scheme, &unused_scheme_type);
diff --git a/url/url_util.h b/url/url_util.h index eca0f29..20b2344 100644 --- a/url/url_util.h +++ b/url/url_util.h
@@ -39,24 +39,6 @@ // Schemes --------------------------------------------------------------------- -// Types of a scheme representing the requirements on the data represented by -// the authority component of a URL with the scheme. -enum SchemeType { - // The authority component of a URL with the scheme, if any, has the form - // "username:password@host:port". The username and password entries are - // optional; the host may not be empty. The default value of the port - // can be omitted in serialization. This type occurs with network schemes - // like http, https, and ftp. - SCHEME_WITH_HOST_PORT_AND_USER_INFORMATION, - // The authority component of a URL with this scheme, if any, consists only - // of a host. It does not contain port, username, or password. Schemes used - // internally by browser features usually work this way, as hostnames do not - // correspond to network hosts. - SCHEME_WITH_HOST, - // A URL with the scheme doesn't have the authority component. - SCHEME_WITHOUT_AUTHORITY, -}; - // A pair for representing a standard scheme name and the SchemeType for it. struct URL_EXPORT SchemeWithType { const char* scheme; @@ -175,6 +157,9 @@ URL_EXPORT bool GetStandardSchemeType(const char* spec, const Component& scheme, SchemeType* type); +URL_EXPORT bool GetStandardSchemeType(const base::char16* spec, + const Component& scheme, + SchemeType* type); // Hosts ----------------------------------------------------------------------
diff --git a/url/url_util_unittest.cc b/url/url_util_unittest.cc index ae380f1..526d63fb 100644 --- a/url/url_util_unittest.cc +++ b/url/url_util_unittest.cc
@@ -309,50 +309,54 @@ const char* out; } resolve_non_standard_cases[] = { // Resolving a relative path against a non-hierarchical URL should fail. - {"scheme:opaque_data", "/path", false, ""}, + {"scheme:opaque_data", "/path", false, ""}, // Resolving a relative path against a non-standard authority-based base // URL doesn't alter the authority section. - {"scheme://Authority/", "../path", true, "scheme://Authority/path"}, + {"scheme://Authority/", "../path", true, "scheme://Authority/path"}, // A non-standard hierarchical base is resolved with path URL // canonicalization rules. - {"data:/Blah:Blah/", "file.html", true, "data:/Blah:Blah/file.html"}, - {"data:/Path/../part/part2", "file.html", true, - "data:/Path/../part/file.html"}, + {"data:/Blah:Blah/", "file.html", true, "data:/Blah:Blah/file.html"}, + {"data:/Path/../part/part2", "file.html", true, + "data:/Path/../part/file.html"}, + {"data://text/html,payload", "//user:pass@host:33////payload22", true, + "data://user:pass@host:33////payload22"}, // Path URL canonicalization rules also apply to non-standard authority- // based URLs. - {"custom://Authority/", "file.html", true, - "custom://Authority/file.html"}, - {"custom://Authority/", "other://Auth/", true, "other://Auth/"}, - {"custom://Authority/", "../../file.html", true, - "custom://Authority/file.html"}, - {"custom://Authority/path/", "file.html", true, - "custom://Authority/path/file.html"}, - {"custom://Authority:NoCanon/path/", "file.html", true, - "custom://Authority:NoCanon/path/file.html"}, + {"custom://Authority/", "file.html", true, + "custom://Authority/file.html"}, + {"custom://Authority/", "other://Auth/", true, "other://Auth/"}, + {"custom://Authority/", "../../file.html", true, + "custom://Authority/file.html"}, + {"custom://Authority/path/", "file.html", true, + "custom://Authority/path/file.html"}, + {"custom://Authority:NoCanon/path/", "file.html", true, + "custom://Authority:NoCanon/path/file.html"}, // It's still possible to get an invalid path URL. - {"custom://Invalid:!#Auth/", "file.html", false, ""}, + {"custom://Invalid:!#Auth/", "file.html", false, ""}, // A path with an authority section gets canonicalized under standard URL // rules, even though the base was non-standard. - {"content://content.Provider/", "//other.Provider", true, - "content://other.provider/"}, + {"content://content.Provider/", "//other.Provider", true, + "content://other.provider/"}, + // Resolving an absolute URL doesn't cause canonicalization of the // result. - {"about:blank", "custom://Authority", true, "custom://Authority"}, + {"about:blank", "custom://Authority", true, "custom://Authority"}, // Fragment URLs can be resolved against a non-standard base. - {"scheme://Authority/path", "#fragment", true, - "scheme://Authority/path#fragment"}, - {"scheme://Authority/", "#fragment", true, "scheme://Authority/#fragment"}, + {"scheme://Authority/path", "#fragment", true, + "scheme://Authority/path#fragment"}, + {"scheme://Authority/", "#fragment", true, + "scheme://Authority/#fragment"}, // Resolving should fail if the base URL is authority-based but is // missing a path component (the '/' at the end). - {"scheme://Authority", "path", false, ""}, + {"scheme://Authority", "path", false, ""}, // Test resolving a fragment (only) against any kind of base-URL. - {"about:blank", "#id42", true, "about:blank#id42" }, - {"about:blank", " #id42", true, "about:blank#id42" }, - {"about:blank#oldfrag", "#newfrag", true, "about:blank#newfrag" }, + {"about:blank", "#id42", true, "about:blank#id42"}, + {"about:blank", " #id42", true, "about:blank#id42"}, + {"about:blank#oldfrag", "#newfrag", true, "about:blank#newfrag"}, // A surprising side effect of allowing fragments to resolve against // any URL scheme is we might break javascript: URLs by doing so... - {"javascript:alert('foo#bar')", "#badfrag", true, - "javascript:alert('foo#badfrag" }, + {"javascript:alert('foo#bar')", "#badfrag", true, + "javascript:alert('foo#badfrag"}, // In this case, the backslashes will not be canonicalized because it's a // non-standard URL, but they will be treated as a path separators, // giving the base URL here a path of "\". @@ -361,8 +365,7 @@ // either "aaa://a\" or "aaa://a/" since the path is being replaced with // the "current directory". But in the context of resolving on data URLs, // adding the requested dot doesn't seem wrong either. - {"aaa://a\\", "aaa:.", true, "aaa://a\\." } - }; + {"aaa://a\\", "aaa:.", true, "aaa://a\\."}}; for (size_t i = 0; i < arraysize(resolve_non_standard_cases); i++) { const ResolveRelativeCase& test_data = resolve_non_standard_cases[i];