• Patrik Höglund's avatar
    Revert "Fix a crash when switching to tablet mode in Unified Desktop mode" · 9f547d17
    Patrik Höglund authored
    This reverts commit dcb55ce2.
    
    Reason for revert: Appears to cause crashes in LoginCursorTest.CursorHidden. See https://chromium-swarm.appspot.com/task?id=410f91874d359810&refresh=10&show_raw=1:
    BrowserTestBase received signal: Segmentation fault. Backtrace:
    #0 0x55c75309100f base::debug::StackTrace::StackTrace()
    #1 0x55c752aa8075 content::(anonymous namespace)::DumpStackTraceSignalHandler()
    #2 0x7f17e8b21cb0 <unknown>
    #3 0x55c751991a1d chromeos::OobeUIDialogDelegate::~OobeUIDialogDelegate()
    #4 0x55c751991c8e chromeos::OobeUIDialogDelegate::~OobeUIDialogDelegate()
    #5 0x55c7553a6063 views::WebDialogView::OnDialogClosed()
    #6 0x55c7553a5d92 views::WebDialogView::WindowClosing()
    #7 0x55c752f81eb0 views::Widget::OnNativeWidgetDestroying()
    #8 0x55c7548080ff views::DesktopWindowTreeHostMus::CloseNow()
    
    Original change's description:
    > Fix a crash when switching to tablet mode in Unified Desktop mode
    > 
    > 1) The Home Launcher used to use the wrong display ID when in
    >    Unified Desktop mode.
    > 2) If (1) is fixed, we hit https://crbug.com/902601. The captive
    >    portal dialog widget used to be leaked and never destroyed.
    > 3) If (2) is fixed, we crash on the first attempt to press the
    >    app list button. The reason is tablet mode triggers a switch
    >    to mirror mode. This switch happens asynchronously after the
    >    Home Launcher had already been created. Switching from Unified
    >    to mirror mode destroys the Unified host and the Home Launcher.
    >    That's why we need to ensure that the Home Launcher is
    >    recreated.
    > 
    > BUG=900956, 902601
    > TEST=Added a test that crashes without the fix.
    > 
    > Change-Id: If6eb9c2255dfa9d442aa115a3274db2d8a4110d7
    > Reviewed-on: https://chromium-review.googlesource.com/c/1325389
    > Commit-Queue: Ahmed Fakhry <afakhry@chromium.org>
    > Reviewed-by: Weidong Guo <weidongg@chromium.org>
    > Reviewed-by: Xiyuan Xia <xiyuan@chromium.org>
    > Reviewed-by: Jacob Dufault <jdufault@chromium.org>
    > Reviewed-by: Mitsuru Oshima <oshima@chromium.org>
    > Cr-Commit-Position: refs/heads/master@{#606687}
    
    TBR=xiyuan@chromium.org,oshima@chromium.org,afakhry@chromium.org,jdufault@chromium.org,weidongg@chromium.org
    
    Change-Id: I2e0cacc2c29bbc44e8e8c9dfcb86fd8106c008ff
    No-Presubmit: true
    No-Tree-Checks: true
    No-Try: true
    Bug: 900956, 902601
    Reviewed-on: https://chromium-review.googlesource.com/c/1329004Reviewed-by: default avatarPatrik Höglund <phoglund@chromium.org>
    Commit-Queue: Patrik Höglund <phoglund@chromium.org>
    Cr-Commit-Position: refs/heads/master@{#606808}
    9f547d17
display_configuration_observer.cc 3.24 KB