New issue
Advanced search Search tips

Issue 623690 link

Starred by 3 users

Issue metadata

Status: Fixed
Owner:
Closed: Sep 2016
Cc:
Components:
EstimatedDays: ----
NextAction: ----
OS: Mac
Pri: 3
Type: Bug

Blocking:
issue 639716



Sign in to add a comment

Show Feedback button on sad tab (Aw Snap) page on Mac

Project Member Reported by mark@chromium.org, Jun 27 2016

Issue description

On Views platforms, the first crash (in a tab, I think) shows a Reload button on the sad tab page, but subsequent crashes turn the Reload button into a Feedback button.

On Mac, we only show the Reload button. We should achieve parity by showing the Feedback button on successive crashes.

Notes: For non-Mac, it’s in chrome/browser/ui/views/sad_tab_view.h and .cc. For Mac, it’s chrome/browser/ui/cocoa/tab_contents/sad_tab_view_cocoa.h and .mm as well as sad_tab_controller_cocoa.h and .mm in the same directory. One level up, the platform-independent interface is chrome/browser/ui/sad_tab.h and .cc, with additional bits in sad_tab_helper.h and cc, and sad_tab_types.h, all in the same directory.
 

Comment 1 by sdy@chromium.org, Jun 27 2016

Cc: -sidneym@google.com sdy@chromium.org
sidneym@ is dead, long live sdy@{google.com,chromium.org}.
Hi there Sidney, any progress on this?

Comment 3 by sdy@chromium.org, Jul 18 2016

Cc: -sdy@chromium.org
Owner: sdy@chromium.org
Status: Assigned (was: Untriaged)
Hi yyushkina@, and sorry for the lag! I was planning to get to this in the next week or two. Is that OK? If it's urgent, I'd be happy to do it sooner.
Next week or two is fine - thanks!

Comment 5 by sdy@chromium.org, Aug 9 2016

Status: Started (was: Assigned)
Project Member

Comment 6 by bugdroid1@chromium.org, Aug 15 2016

The following revision refers to this bug:
  https://chromium.googlesource.com/chromium/src.git/+/7c635ed1edb8cbcb68fe5a0646cb554b8dd32b8a

commit 7c635ed1edb8cbcb68fe5a0646cb554b8dd32b8a
Author: sdy <sdy@chromium.org>
Date: Mon Aug 15 01:52:10 2016

[Mac] Clean up SadTabView and let SadTabController provide its content

Prep for making the sad tab's content more dynamic, plus some touch-up
and shuffling of responsibilities.

- Adds methods to `SadTabView` to set the text of each interface element
  and the help URL, and makes `SadTabController` responsible for setting
  them. `SadTabView` still controls appearance and layout.

- Gives `SadTabView` a delegate to signal clicks. The button is now
  private, and tests now use a `WebContentsDelegate` to detect a click
  on the help link instead of extending `NSApplication`.

- Removes some uses of `scoped_nsobject` for instance variables that
  just need to be weak references.

BUG= 623690 

Review-Url: https://codereview.chromium.org/2247493003
Cr-Commit-Position: refs/heads/master@{#411932}

[modify] https://crrev.com/7c635ed1edb8cbcb68fe5a0646cb554b8dd32b8a/chrome/browser/ui/cocoa/tab_contents/sad_tab_controller.h
[modify] https://crrev.com/7c635ed1edb8cbcb68fe5a0646cb554b8dd32b8a/chrome/browser/ui/cocoa/tab_contents/sad_tab_controller.mm
[modify] https://crrev.com/7c635ed1edb8cbcb68fe5a0646cb554b8dd32b8a/chrome/browser/ui/cocoa/tab_contents/sad_tab_controller_unittest.mm
[modify] https://crrev.com/7c635ed1edb8cbcb68fe5a0646cb554b8dd32b8a/chrome/browser/ui/cocoa/tab_contents/sad_tab_view_cocoa.h
[modify] https://crrev.com/7c635ed1edb8cbcb68fe5a0646cb554b8dd32b8a/chrome/browser/ui/cocoa/tab_contents/sad_tab_view_cocoa.mm
[modify] https://crrev.com/7c635ed1edb8cbcb68fe5a0646cb554b8dd32b8a/ui/gfx/test/ui_cocoa_test_helper.h

Comment 7 by sdy@chromium.org, Aug 22 2016

Blocking: 639716
Project Member

Comment 8 by bugdroid1@chromium.org, Sep 9 2016

The following revision refers to this bug:
  https://chromium.googlesource.com/chromium/src.git/+/26cabf35396e65533b30062b89aee46cbf55b862

commit 26cabf35396e65533b30062b89aee46cbf55b862
Author: sdy <sdy@chromium.org>
Date: Fri Sep 09 16:52:24 2016

Bring the feedback button to the Mac sad tab

The Views implementation of SadTab supports two big things that were
missing in the Mac implementation:

1. The reload button turns into a feedback button on repeated crashes.
2. Histograms for tracking different kinds of crashes.

This moves that logic up into the base SadTab, so that both
implementations can use it.

It also adds new histograms to count when a sad tab with a reload button
or feedback button is displayed, and clicks on the button or help link.

Other changes:

- HISTOGRAM_ENUMERATION_WITH_FLAG uses a new base::underlying_value()
  function to cast scoped enums to their underlying integral values.
  (Unlike classic enums, they don't implicitly convert).

- The Show() and Close() methods of SadTab are gone. Show() was always
  called right after construction, and Close() was always called right
  before destruction, so I merged them with the ctor+dtor.

- SadTabController is gone.

- SadTabView no longer gets a reference to the WebContents; SadTabCocoa
  is now responsible for sizing it and adding it to the view hierarchy.

- The help link text no longer selects when you right click it.

BUG= 623690 
TEST=Trigger sad tabs on each platform either with chrome://crash or by
killing processes in the task manager. Check that the first sad tab
shows a reload button and subsequent sad tabs show a feedback button.
Otherwise, the look and behavior of the sad tab should be the same.

Review-Url: https://codereview.chromium.org/2261793002
Cr-Commit-Position: refs/heads/master@{#417606}

[modify] https://crrev.com/26cabf35396e65533b30062b89aee46cbf55b862/chrome/browser/ui/BUILD.gn
[delete] https://crrev.com/7212ed1dbe75a59b2d8694b483554b3d3098eca6/chrome/browser/ui/cocoa/tab_contents/sad_tab_controller.h
[delete] https://crrev.com/7212ed1dbe75a59b2d8694b483554b3d3098eca6/chrome/browser/ui/cocoa/tab_contents/sad_tab_controller.mm
[delete] https://crrev.com/7212ed1dbe75a59b2d8694b483554b3d3098eca6/chrome/browser/ui/cocoa/tab_contents/sad_tab_controller_unittest.mm
[add] https://crrev.com/26cabf35396e65533b30062b89aee46cbf55b862/chrome/browser/ui/cocoa/tab_contents/sad_tab_mac.mm
[add] https://crrev.com/26cabf35396e65533b30062b89aee46cbf55b862/chrome/browser/ui/cocoa/tab_contents/sad_tab_mac_unittest.mm
[modify] https://crrev.com/26cabf35396e65533b30062b89aee46cbf55b862/chrome/browser/ui/cocoa/tab_contents/sad_tab_view_cocoa.h
[modify] https://crrev.com/26cabf35396e65533b30062b89aee46cbf55b862/chrome/browser/ui/cocoa/tab_contents/sad_tab_view_cocoa.mm
[delete] https://crrev.com/7212ed1dbe75a59b2d8694b483554b3d3098eca6/chrome/browser/ui/cocoa/tab_contents/sad_tab_view_cocoa_unittest.mm
[modify] https://crrev.com/26cabf35396e65533b30062b89aee46cbf55b862/chrome/browser/ui/sad_tab.cc
[modify] https://crrev.com/26cabf35396e65533b30062b89aee46cbf55b862/chrome/browser/ui/sad_tab.h
[modify] https://crrev.com/26cabf35396e65533b30062b89aee46cbf55b862/chrome/browser/ui/sad_tab_helper.cc
[modify] https://crrev.com/26cabf35396e65533b30062b89aee46cbf55b862/chrome/browser/ui/views/sad_tab_view.cc
[modify] https://crrev.com/26cabf35396e65533b30062b89aee46cbf55b862/chrome/browser/ui/views/sad_tab_view.h
[modify] https://crrev.com/26cabf35396e65533b30062b89aee46cbf55b862/chrome/test/BUILD.gn
[modify] https://crrev.com/26cabf35396e65533b30062b89aee46cbf55b862/tools/metrics/histograms/histograms.xml

Comment 9 by sdy@chromium.org, Sep 9 2016

Status: Fixed (was: Started)

Comment 10 by sdy@chromium.org, Sep 9 2016

Note for testers: the feedback button should only show up in branded Chrome builds. Chromium builds' sad tab behavior shouldn't change.

Comment 11 Deleted

Sign in to add a comment