Skip to content

Commit

Permalink
Browse files Browse the repository at this point in the history
… into master.lion
  • Loading branch information
bluebox authored and bluebox committed Jul 1, 2021
2 parents 771e345 + 486cec4 commit 04c92e3
Show file tree
Hide file tree
Showing 1,475 changed files with 18,695 additions and 8,192 deletions.
37 changes: 24 additions & 13 deletions DEPS
Original file line number Diff line number Diff line change
Expand Up @@ -222,11 +222,11 @@ vars = {
# Three lines of non-changing comments so that
# the commit queue can handle CLs rolling Skia
# and whatever else without interference from each other.
'skia_revision': '76e45134b8a797c0da4b4f998442e3ce3c29cf44',
'skia_revision': '9e583bfa3f4573dd1894c04d5720d5165496b37e',
# Three lines of non-changing comments so that
# the commit queue can handle CLs rolling V8
# and whatever else without interference from each other.
'v8_revision': '9117b13ab099c26a8cd041a7a821dd2f0adb9adf',
'v8_revision': '49a432187c8e5393824dda086f270acb170fed3e',
# Three lines of non-changing comments so that
# the commit queue can handle CLs rolling swarming_client
# and whatever else without interference from each other.
Expand Down Expand Up @@ -257,7 +257,7 @@ vars = {
# Three lines of non-changing comments so that
# the commit queue can handle CLs rolling googletest
# and whatever else without interference from each other.
'googletest_revision': '355d57d90d9744c41ac7c99f1e960778f1c63040',
'googletest_revision': '255323cf092e46b2a9f0ded173bb4b91dd52486e',
# Three lines of non-changing comments so that
# the commit queue can handle CLs rolling lighttpd
# and whatever else without interference from each other.
Expand All @@ -273,7 +273,7 @@ vars = {
# Three lines of non-changing comments so that
# the commit queue can handle CLs rolling freetype
# and whatever else without interference from each other.
'freetype_revision': '7be47010e9b1298c5f59c2501cab3d156ab3256f',
'freetype_revision': 'f27b4834b7dcf9d667fd5173106be0cddb0ec1c2',
# Three lines of non-changing comments so that
# the commit queue can handle CLs rolling freetype
# and whatever else without interference from each other.
Expand All @@ -293,7 +293,7 @@ vars = {
# 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': '2bc697bc6493861561954a0ac4c4725a2b9f9fd5',
'catapult_revision': '949bca87e0115972190f91dfb947137620c64b26',
# Three lines of non-changing comments so that
# the commit queue can handle CLs rolling libFuzzer
# and whatever else without interference from each other.
Expand Down Expand Up @@ -341,7 +341,7 @@ vars = {
# Three lines of non-changing comments so that
# the commit queue can handle CLs rolling feed
# and whatever else without interference from each other.
'dawn_revision': '0ecfece609ec769acd3da4f4fde55ab1f0a12769',
'dawn_revision': '211b4aae7efe11e8e75deb3dc68799890fa04900',
# Three lines of non-changing comments so that
# the commit queue can handle CLs rolling feed
# and whatever else without interference from each other.
Expand Down Expand Up @@ -738,7 +738,7 @@ deps = {
'packages': [
{
'package': 'chromium/third_party/androidx',
'version': 'dtfyPV4tOjhVFrZr8pKio2O2hf9OFOgegMyeX-PCfuMC',
'version': 'AlTbbwQ2U9bjcopxvW9Irf4uWn5RNcCLQi1zN7Hc5oAC',
},
],
'condition': 'checkout_android',
Expand Down Expand Up @@ -954,7 +954,7 @@ deps = {
# Tools used when building Chrome for Chrome OS. This affects both the Simple
# Chrome workflow, as well as the chromeos-chrome ebuild.
'src/third_party/chromite': {
'url': Var('chromium_git') + '/chromiumos/chromite.git' + '@' + '4a31dcd877cca9ccda0605e8f362e3d4daa380a0',
'url': Var('chromium_git') + '/chromiumos/chromite.git' + '@' + '7fd52b673157edc4b173f8974924284c1af778e7',
'condition': 'checkout_chromeos',
},

Expand Down Expand Up @@ -1343,7 +1343,7 @@ deps = {
Var('chromium_git') + '/external/github.com/cisco/openh264' + '@' + '3dd5b80bc4f172dd82925bb259cb7c82348409c5',

'src/third_party/openscreen/src':
Var('chromium_git') + '/openscreen' + '@' + '082e0e3df7fcaeed60e49ac212e180b4dac6a39d',
Var('chromium_git') + '/openscreen' + '@' + '29efcb654d85ac926666aabdc489f8084fd3b172',

'src/third_party/openxr/src': {
'url': Var('chromium_git') + '/external/github.com/KhronosGroup/OpenXR-SDK' + '@' + 'bf21ccb1007bb531b45d9978919a56ea5059c245',
Expand Down Expand Up @@ -1589,7 +1589,7 @@ deps = {
Var('chromium_git') + '/external/khronosgroup/webgl.git' + '@' + '827cad9e402b63bbe38787456115bcb681a8a152',

'src/third_party/webgpu-cts/src':
Var('chromium_git') + '/external/github.com/gpuweb/cts.git' + '@' + '91c93fc84869bc5c2fda0f35600de61dc52ab3f6',
Var('chromium_git') + '/external/github.com/gpuweb/cts.git' + '@' + '25731d21f45dcac622baff416f1423f5c18afa49',

'src/third_party/webrtc':
Var('webrtc_git') + '/src.git' + '@' + 'fbdd778891198ca1768d25abd14821203e6d0782',
Expand Down Expand Up @@ -1653,7 +1653,7 @@ deps = {
Var('chromium_git') + '/v8/v8.git' + '@' + Var('v8_revision'),

'src-internal': {
'url': 'https://chrome-internal.googlesource.com/chrome/src-internal.git@9322072ce30b1d283db2d09dc8bea08f2f9f4f6b',
'url': 'https://chrome-internal.googlesource.com/chrome/src-internal.git@f04c0b4185896886fb965aa3c5a82102f00ce98c',
'condition': 'checkout_src_internal',
},

Expand All @@ -1672,7 +1672,7 @@ deps = {
'packages': [
{
'package': 'chromeos_internal/apps/help_app/app',
'version': 'Z7hWm7TA04dRywJLmmldHQclBiwVdjKyUYXv45fBb3sC',
'version': 'RNBWnNHLFhQ6Q7EBKGIaOT_zkBS7lp6jf1JciSIZYxUC',
},
],
'condition': 'checkout_chromeos and checkout_src_internal',
Expand All @@ -1683,7 +1683,7 @@ deps = {
'packages': [
{
'package': 'chromeos_internal/apps/media_app/app',
'version': 'yJPwvojcycj0Aw6vVh9gnDjqmqMKmFlFbAvzqBbLzXkC',
'version': 'hUugr3xaZS2wT9xO--8mH4KilkGjiKGmpDHjs1ndickC',
},
],
'condition': 'checkout_chromeos and checkout_src_internal',
Expand Down Expand Up @@ -2503,6 +2503,17 @@ deps = {
'dep_type': 'cipd',
},

'src/third_party/android_deps/libs/com_google_android_play_core': {
'packages': [
{
'package': 'chromium/third_party/android_deps/libs/com_google_android_play_core',
'version': 'version:[email protected]',
},
],
'condition': 'checkout_android',
'dep_type': 'cipd',
},

'src/third_party/android_deps/libs/com_google_auto_auto_common': {
'packages': [
{
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -4,6 +4,9 @@
"""Presubmit tests for ProductionSupportedFlagList.java
"""

USE_PYTHON3 = True


import os
import sys

Expand Down
4 changes: 2 additions & 2 deletions android_webview/tools/generate_flag_labels.py
Original file line number Diff line number Diff line change
@@ -1,4 +1,4 @@
#!/usr/bin/env vpython
#!/usr/bin/env vpython3
#
# Copyright 2020 The Chromium Authors. All rights reserved.
# Use of this source code is governed by a BSD-style license that can be
Expand Down Expand Up @@ -53,7 +53,7 @@

def GetSwitchId(label):
"""Generate a hash consistent with flags_ui::GetSwitchUMAId()."""
digest = hashlib.md5(label).hexdigest()
digest = hashlib.md5(label.encode('utf-8')).hexdigest()
first_eight_bytes = digest[:16]
long_value = int(first_eight_bytes, 16)
signed_32bit = ctypes.c_int(long_value).value
Expand Down
2 changes: 2 additions & 0 deletions android_webview/tools/generate_flag_labels_test.py
100644 → 100755
Original file line number Diff line number Diff line change
@@ -1,3 +1,5 @@
#!/usr/bin/env vpython3
#
# Copyright 2020 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.
Expand Down
1 change: 1 addition & 0 deletions ash/app_list/app_list_controller_impl.cc
Original file line number Diff line number Diff line change
Expand Up @@ -57,6 +57,7 @@
#include "base/bind.h"
#include "base/callback_helpers.h"
#include "base/containers/contains.h"
#include "base/containers/cxx20_erase.h"
#include "base/logging.h"
#include "base/metrics/histogram_macros.h"
#include "base/metrics/user_metrics.h"
Expand Down
2 changes: 1 addition & 1 deletion ash/app_list/views/app_list_item_view.cc
Original file line number Diff line number Diff line change
Expand Up @@ -696,7 +696,7 @@ void AppListItemView::Layout() {
return;

const gfx::Rect icon_bounds = GetIconBoundsForTargetViewBounds(
GetAppListConfig(), rect, icon_->GetImage().size(), icon_scale_);
GetAppListConfig(), rect, icon_->GetImageBounds().size(), icon_scale_);
icon_->SetBoundsRect(icon_bounds);

gfx::Rect title_bounds = GetTitleBoundsForTargetViewBounds(
Expand Down
3 changes: 3 additions & 0 deletions ash/ash_strings.grd
Original file line number Diff line number Diff line change
Expand Up @@ -1107,6 +1107,9 @@ This file contains the strings for ash.
<message name="IDS_ASH_HOLDING_SPACE_IN_PROGRESS_DOWNLOAD_SIZE_INFO" desc="Text displayed in a holding space download chip to indicate the number of bytes received and total bytes expected of the underlying download.">
<ph name="RECEIVED_BYTES">$1<ex>10</ex></ph>/<ph name="TOTAL_BYTES">$2<ex>100 MB</ex></ph>
</message>
<message name="IDS_ASH_HOLDING_SPACE_IN_PROGRESS_DOWNLOAD_OPEN_WHEN_COMPLETE" desc="Text displayed in a holding space download chip to indicate that the downloaded file will be opened when complete.">
Open when complete
</message>

<!-- Phone Hub tray-->
<message name="IDS_ASH_PHONE_HUB_TRAY_ACCESSIBLE_NAME" desc="The accessible name of the Phone Hub tray bubble for screen readers.">
Expand Down
Original file line number Diff line number Diff line change
@@ -0,0 +1 @@
73926bb03ac632d721e37883fe47750775ea8766
2 changes: 1 addition & 1 deletion ash/assistant/assistant_suggestions_controller_impl.cc
Original file line number Diff line number Diff line change
Expand Up @@ -19,8 +19,8 @@
#include "ash/shell.h"
#include "ash/strings/grit/ash_strings.h"
#include "base/bind.h"
#include "base/containers/cxx20_erase.h"
#include "base/rand_util.h"
#include "base/stl_util.h"
#include "base/unguessable_token.h"
#include "chromeos/services/assistant/public/cpp/assistant_prefs.h"
#include "chromeos/services/assistant/public/cpp/features.h"
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -36,6 +36,7 @@
#include "ui/views/controls/image_view.h"
#include "ui/views/controls/label.h"
#include "ui/views/view_utils.h"
#include "ui/views/widget/widget.h"

namespace ash {

Expand Down Expand Up @@ -447,7 +448,9 @@ TEST_F(AssistantOnboardingViewTest, ShouldHandleRemoteIcons) {
EXPECT_CALL(delegate, GetPrimaryUserGivenName)
.WillOnce(testing::Return("Primary User Given Name"));

AssistantOnboardingView onboarding_view(&delegate);
auto widget = CreateFramelessTestWidget();
auto* onboarding_view = widget->SetContentsView(
std::make_unique<AssistantOnboardingView>(&delegate));
EXPECT_CALL(delegate, DownloadImage)
.WillOnce(testing::Invoke(
[&](const GURL& url, ImageDownloader::DownloadCallback callback) {
Expand All @@ -458,7 +461,7 @@ TEST_F(AssistantOnboardingViewTest, ShouldHandleRemoteIcons) {
"https://www.gstatic.com/images/branding/product/2x/googleg_48dp.png")});

AssistantOnboardingSuggestionView* suggestion_view = nullptr;
FindDescendentByClassName(&onboarding_view, &suggestion_view);
FindDescendentByClassName(onboarding_view, &suggestion_view);
ASSERT_NE(nullptr, suggestion_view);

const auto& actual = suggestion_view->GetIcon();
Expand Down
27 changes: 16 additions & 11 deletions ash/assistant/ui/main_stage/suggestion_chip_view_unittest.cc
Original file line number Diff line number Diff line change
Expand Up @@ -13,6 +13,7 @@
#include "testing/gtest/include/gtest/gtest.h"
#include "ui/gfx/image/image_unittest_util.h"
#include "ui/gfx/paint_vector_icon.h"
#include "ui/views/widget/widget.h"

namespace ash {

Expand All @@ -35,12 +36,14 @@ AssistantSuggestion CreateSuggestionWithIconUrl(const std::string& icon_url) {
using SuggestionChipViewTest = AshTestBase;

TEST_F(SuggestionChipViewTest, ShouldHandleLocalIcons) {
SuggestionChipView suggestion_chip_view(
/*delegate=*/nullptr,
CreateSuggestionWithIconUrl(
"googleassistant://resource?type=icon&name=assistant"));

const auto& actual = suggestion_chip_view.GetIcon();
auto widget = CreateFramelessTestWidget();
auto* suggestion_chip_view =
widget->SetContentsView(std::make_unique<SuggestionChipView>(
/*delegate=*/nullptr,
CreateSuggestionWithIconUrl(
"googleassistant://resource?type=icon&name=assistant")));

const auto& actual = suggestion_chip_view->GetIcon();
gfx::ImageSkia expected = gfx::CreateVectorIcon(
gfx::IconDescription(chromeos::kAssistantIcon, /*size=*/16));

Expand All @@ -58,12 +61,14 @@ TEST_F(SuggestionChipViewTest, ShouldHandleRemoteIcons) {
std::move(callback).Run(expected);
}));

SuggestionChipView suggestion_chip_view(
&delegate,
CreateSuggestionWithIconUrl("https://www.gstatic.com/images/branding/"
"product/2x/googleg_48dp.png"));
auto widget = CreateFramelessTestWidget();
auto* suggestion_chip_view =
widget->SetContentsView(std::make_unique<SuggestionChipView>(
&delegate,
CreateSuggestionWithIconUrl("https://www.gstatic.com/images/branding/"
"product/2x/googleg_48dp.png")));

const auto& actual = suggestion_chip_view.GetIcon();
const auto& actual = suggestion_chip_view->GetIcon();
EXPECT_TRUE(actual.BackedBySameObjectAs(expected));
}

Expand Down
6 changes: 4 additions & 2 deletions ash/capture_mode/capture_label_view.cc
Original file line number Diff line number Diff line change
Expand Up @@ -240,8 +240,10 @@ void CaptureLabelView::UpdateIconAndText() {
if (!icon.isNull()) {
label_->SetVisible(false);
label_button_->SetVisible(true);
// Update the icon only if it has changed to reduce repainting.
if (!icon.BackedBySameObjectAs(
// Update the icon only if one is not already present or it has changed to
// reduce repainting.
if (!label_button_->HasImage(views::Button::STATE_NORMAL) ||
!icon.BackedBySameObjectAs(
label_button_->GetImage(views::Button::STATE_NORMAL))) {
label_button_->SetImage(views::Button::STATE_NORMAL, icon);
}
Expand Down
12 changes: 4 additions & 8 deletions ash/child_accounts/parent_access_controller_impl.cc
Original file line number Diff line number Diff line change
Expand Up @@ -260,18 +260,14 @@ void ParentAccessControllerImpl::OnBack() {
ParentAccessControllerImpl::UMAAction::kCanceledByUser);
}

void ParentAccessControllerImpl::OnHelp(gfx::NativeWindow parent_window) {
void ParentAccessControllerImpl::OnHelp() {
RecordParentAccessAction(ParentAccessControllerImpl::UMAAction::kGetHelp);
// TODO(https://crbug.com/999387): Remove this when handling touch
// cancellation is fixed for system modal windows.
base::ThreadTaskRunnerHandle::Get()->PostTask(
FROM_HERE,
base::BindOnce(
[](gfx::NativeWindow parent_window) {
Shell::Get()->login_screen_controller()->ShowParentAccessHelpApp(
parent_window);
},
parent_window));
FROM_HERE, base::BindOnce([]() {
Shell::Get()->login_screen_controller()->ShowParentAccessHelpApp();
}));
}

bool ParentAccessControllerImpl::ShowWidget(
Expand Down
2 changes: 1 addition & 1 deletion ash/child_accounts/parent_access_controller_impl.h
Original file line number Diff line number Diff line change
Expand Up @@ -82,7 +82,7 @@ class ASH_EXPORT ParentAccessControllerImpl : public ParentAccessController,
PinRequestView::SubmissionResult OnPinSubmitted(
const std::string& pin) override;
void OnBack() override;
void OnHelp(gfx::NativeWindow parent_window) override;
void OnHelp() override;

// ParentAccessController:
bool ShowWidget(const AccountId& child_account_id,
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -281,7 +281,7 @@ TEST_F(ParentAccessControllerImplTest, ParentAccessUnsuccessfulValidation) {
ParentAccessControllerImpl::UMAValidationResult::kInvalid,
SupervisedAction::kUnlockTimeLimits, 1, 1);

EXPECT_CALL(*login_client_, ShowParentAccessHelpApp(_)).Times(1);
EXPECT_CALL(*login_client_, ShowParentAccessHelpApp()).Times(1);
SimulateButtonPress(PinRequestView::TestApi(view_).help_button());
ExpectUMAActionReported(ParentAccessControllerImpl::UMAAction::kGetHelp, 1,
2);
Expand Down
1 change: 1 addition & 0 deletions ash/clipboard/clipboard_history_resource_manager.cc
Original file line number Diff line number Diff line change
Expand Up @@ -13,6 +13,7 @@
#include "ash/resources/vector_icons/vector_icons.h"
#include "base/bind.h"
#include "base/containers/contains.h"
#include "base/containers/cxx20_erase.h"
#include "base/metrics/histogram_functions.h"
#include "base/notreached.h"
#include "base/stl_util.h"
Expand Down
Loading

0 comments on commit 04c92e3

Please sign in to comment.