Skip to content

Commit

Permalink
[M103] Disable tab capture blue border on lacros
Browse files Browse the repository at this point in the history
Tab capture blur border is causing crashes on lacros. Disable it given
that it was already disabled on Ash since 2019 (crbug.com/1030925).

(cherry picked from commit 81aefa8)

Bug: 1320262
Change-Id: Ib60aa2c8ffc38bb4ad628c009225933ad8a3aee1
Reviewed-on: https://chromium-review.googlesource.com/c/chromium/src/+/3648064
Reviewed-by: Elad Alon <eladalon@chromium.org>
Auto-Submit: Keren Zhu <kerenzhu@chromium.org>
Commit-Queue: Keren Zhu <kerenzhu@chromium.org>
Cr-Original-Commit-Position: refs/heads/main@{#1003767}
Reviewed-on: https://chromium-review.googlesource.com/c/chromium/src/+/3650852
Commit-Queue: Elad Alon <eladalon@chromium.org>
Cr-Commit-Position: refs/branch-heads/5060@{#115}
Cr-Branched-From: b83393d-refs/heads/main@{#1002911}
  • Loading branch information
naeioi authored and Chromium LUCI CQ committed May 19, 2022
1 parent 0e59333 commit 20cbc14
Show file tree
Hide file tree
Showing 2 changed files with 6 additions and 6 deletions.
Original file line number Diff line number Diff line change
Expand Up @@ -23,7 +23,7 @@ constexpr int kMinContentsBorderWidth = 20;
constexpr int kMinContentsBorderHeight = 20;

// TODO(https://crbug.com/1030925): Fix contents border on ChromeOS.
#if !BUILDFLAG(IS_CHROMEOS_ASH)
#if !BUILDFLAG(IS_CHROMEOS)
class BorderView : public views::View {
public:
BorderView() = default;
Expand Down Expand Up @@ -84,7 +84,7 @@ void InitContentsBorderWidget(content::WebContents* web_contents) {
// After this fix, capturing a given tab X twice will still yield one widget.
browser_view->set_contents_border_widget(widget);
}
#endif // !BUILDFLAG(IS_CHROMEOS_ASH)
#endif // !BUILDFLAG(IS_CHROMEOS)

} // namespace

Expand Down Expand Up @@ -142,7 +142,7 @@ void TabCaptureContentsBorderHelper::OnRegionCaptureRectChanged(

void TabCaptureContentsBorderHelper::Update() {
// TODO(https://crbug.com/1030925): Fix contents border on ChromeOS.
#if !BUILDFLAG(IS_CHROMEOS_ASH)
#if !BUILDFLAG(IS_CHROMEOS)
DCHECK_CURRENTLY_ON(content::BrowserThread::UI);

content::WebContents* const web_contents = &GetWebContents();
Expand Down Expand Up @@ -179,7 +179,7 @@ void TabCaptureContentsBorderHelper::Update() {
} else {
contents_border_widget->Hide();
}
#endif // !BUILDFLAG(IS_CHROMEOS_ASH)
#endif // !BUILDFLAG(IS_CHROMEOS)
}

void TabCaptureContentsBorderHelper::UpdateBlueBorderLocation() {
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -193,7 +193,7 @@ class TabSharingUIViewsBrowserTest
DCHECK((capturing_tab != kNullTabIndex && captured_tab != kNullTabIndex) ||
(capturing_tab == kNullTabIndex && captured_tab == kNullTabIndex));

#if BUILDFLAG(IS_CHROMEOS_ASH)
#if BUILDFLAG(IS_CHROMEOS)
// TODO(https://crbug.com/1030925) fix contents border on ChromeOS.
has_border = false;
#endif
Expand Down Expand Up @@ -669,7 +669,7 @@ IN_PROC_BROWSER_TEST_F(MultipleTabSharingUIViewsBrowserTest, VerifyUi) {
capture_indicator->IsBeingMirrored(GetWebContents(browser(), i)));

views::Widget* contents_border = GetContentsBorder(browser());
#if BUILDFLAG(IS_CHROMEOS_ASH)
#if BUILDFLAG(IS_CHROMEOS)
// TODO(https://crbug.com/1030925) fix contents border on ChromeOS.
EXPECT_EQ(nullptr, contents_border);
#else
Expand Down

0 comments on commit 20cbc14

Please sign in to comment.