Context menu and app menu won't disappear when clicked outside of the window. Other places in other windows can still be clicked when these two menus are showing on the screen.
The following revision refers to this bug: https://chromium.googlesource.com/chromium/src.git/+/e75f053a801b6a6322a57a9417582f14ebc3f161 commit e75f053a801b6a6322a57a9417582f14ebc3f161 Author: riajiang <riajiang@chromium.org> Date: Wed Feb 01 21:59:30 2017 Change CaptureSynchronizer and PointerWatcherEventRouter to support multiple CaptureClients. DesktopNativeWidgetAura was using DesktopCaptureClient but CaptureSynchronizer was only supporting one CaptureClient, which is a CaptureController. Therefore made the following changes: 1. We have one CaptureController for ash and multiple DesktopCaptureClients for all mus clients. This CL changes CaptureSynchronizer and PointerWatcherEventRouter to support multiple CaptureClients. When a root window's capture client is set, MusClient will be notified by DesktopWindowTreeHostMus if it's a DesktopCaptureClient, and WindowManager will take care of CaptureController. We then add CaptureSynchronizer and PointerWatcherEventRouter to be the observer for that CaptureClient. 2. Update DesktopCaptureClient to notify its observers when capture has changed. BUG= 676002 , 678057 TEST=aura_unittests views_mus_unittests Review-Url: https://codereview.chromium.org/2626013005 Cr-Commit-Position: refs/heads/master@{#447621} [modify] https://crrev.com/e75f053a801b6a6322a57a9417582f14ebc3f161/ash/mus/window_manager.cc [modify] https://crrev.com/e75f053a801b6a6322a57a9417582f14ebc3f161/ui/aura/mus/capture_synchronizer.cc [modify] https://crrev.com/e75f053a801b6a6322a57a9417582f14ebc3f161/ui/aura/mus/capture_synchronizer.h [modify] https://crrev.com/e75f053a801b6a6322a57a9417582f14ebc3f161/ui/aura/mus/window_tree_client.cc [modify] https://crrev.com/e75f053a801b6a6322a57a9417582f14ebc3f161/ui/aura/mus/window_tree_client.h [modify] https://crrev.com/e75f053a801b6a6322a57a9417582f14ebc3f161/ui/aura/mus/window_tree_client_unittest.cc [modify] https://crrev.com/e75f053a801b6a6322a57a9417582f14ebc3f161/ui/aura/test/aura_test_helper.cc [modify] https://crrev.com/e75f053a801b6a6322a57a9417582f14ebc3f161/ui/views/mus/desktop_window_tree_host_mus.cc [modify] https://crrev.com/e75f053a801b6a6322a57a9417582f14ebc3f161/ui/views/mus/desktop_window_tree_host_mus_unittest.cc [modify] https://crrev.com/e75f053a801b6a6322a57a9417582f14ebc3f161/ui/views/mus/mus_client.cc [modify] https://crrev.com/e75f053a801b6a6322a57a9417582f14ebc3f161/ui/views/mus/mus_client.h [modify] https://crrev.com/e75f053a801b6a6322a57a9417582f14ebc3f161/ui/views/mus/pointer_watcher_event_router.cc [modify] https://crrev.com/e75f053a801b6a6322a57a9417582f14ebc3f161/ui/views/mus/pointer_watcher_event_router.h [modify] https://crrev.com/e75f053a801b6a6322a57a9417582f14ebc3f161/ui/views/widget/desktop_aura/desktop_capture_client.cc [modify] https://crrev.com/e75f053a801b6a6322a57a9417582f14ebc3f161/ui/views/widget/desktop_aura/desktop_capture_client.h
The following revision refers to this bug: https://chromium.googlesource.com/chromium/src.git/+/6c8ec587ec4cf305eafb23d136dd4a34fd825730 commit 6c8ec587ec4cf305eafb23d136dd4a34fd825730 Author: riajiang <riajiang@chromium.org> Date: Thu Feb 02 01:50:31 2017 Remove virtual function WindowTreeClientDelegate::GetCaptureClient() and WindowTreeClient::GetCaptureClient(). This CL is separated out from https://codereview.chromium.org/2626013005 BUG= 676002 , 678057 Review-Url: https://codereview.chromium.org/2657873006 Cr-Commit-Position: refs/heads/master@{#447680} [modify] https://crrev.com/6c8ec587ec4cf305eafb23d136dd4a34fd825730/ash/mus/window_manager.cc [modify] https://crrev.com/6c8ec587ec4cf305eafb23d136dd4a34fd825730/ash/mus/window_manager.h [modify] https://crrev.com/6c8ec587ec4cf305eafb23d136dd4a34fd825730/ash/mus/window_manager_unittest.cc [modify] https://crrev.com/6c8ec587ec4cf305eafb23d136dd4a34fd825730/mash/simple_wm/simple_wm.cc [modify] https://crrev.com/6c8ec587ec4cf305eafb23d136dd4a34fd825730/mash/simple_wm/simple_wm.h [modify] https://crrev.com/6c8ec587ec4cf305eafb23d136dd4a34fd825730/services/navigation/view_impl.cc [modify] https://crrev.com/6c8ec587ec4cf305eafb23d136dd4a34fd825730/services/navigation/view_impl.h [modify] https://crrev.com/6c8ec587ec4cf305eafb23d136dd4a34fd825730/services/ui/demo/mus_demo.cc [modify] https://crrev.com/6c8ec587ec4cf305eafb23d136dd4a34fd825730/services/ui/demo/mus_demo.h [modify] https://crrev.com/6c8ec587ec4cf305eafb23d136dd4a34fd825730/services/ui/test_wm/test_wm.cc [modify] https://crrev.com/6c8ec587ec4cf305eafb23d136dd4a34fd825730/services/ui/ws/window_server_test_base.cc [modify] https://crrev.com/6c8ec587ec4cf305eafb23d136dd4a34fd825730/services/ui/ws/window_server_test_base.h [modify] https://crrev.com/6c8ec587ec4cf305eafb23d136dd4a34fd825730/ui/aura/mus/window_tree_client.cc [modify] https://crrev.com/6c8ec587ec4cf305eafb23d136dd4a34fd825730/ui/aura/mus/window_tree_client.h [modify] https://crrev.com/6c8ec587ec4cf305eafb23d136dd4a34fd825730/ui/aura/mus/window_tree_client_delegate.h [modify] https://crrev.com/6c8ec587ec4cf305eafb23d136dd4a34fd825730/ui/aura/test/aura_test_base.cc [modify] https://crrev.com/6c8ec587ec4cf305eafb23d136dd4a34fd825730/ui/aura/test/aura_test_base.h [modify] https://crrev.com/6c8ec587ec4cf305eafb23d136dd4a34fd825730/ui/views/mus/mus_client.cc [modify] https://crrev.com/6c8ec587ec4cf305eafb23d136dd4a34fd825730/ui/views/mus/mus_client.h
The following revision refers to this bug: https://chromium.googlesource.com/chromium/src.git/+/f5a30c08e753738a71894ed1f43c07a6d0421dc6 commit f5a30c08e753738a71894ed1f43c07a6d0421dc6 Author: johnme <johnme@chromium.org> Date: Thu Feb 02 13:00:14 2017 Revert of Change CaptureSynchronizer and PointerWatcherEventRouter to support multiple CaptureClients. (patchset #9 id:240001 of https://codereview.chromium.org/2626013005/ ) Reason for revert: Caused aura_unittests WindowTreeClientClientTest.TwoWindowTreesRequestCapture to fail consistently on https://build.chromium.org/p/chromium.memory/builders/Linux%20Chromium%20OS%20ASan%20LSan%20Tests%20%281%29/builds/19320 since LSan detects a leak: Direct leak of 64 byte(s) in 1 object(s) allocated from: #0 0x52fcfb in operator new(unsigned long) (/b/s/w/irdxqiGi/out/Release/aura_unittests+0x52fcfb) #1 0x729983 in aura::WindowTreeClientClientTest_TwoWindowTreesRequestCapture_Test::TestBody() ui/aura/mus/window_tree_client_unittest.cc:1376:7 Original issue's description: > Change CaptureSynchronizer and PointerWatcherEventRouter to support > multiple CaptureClients. > > DesktopNativeWidgetAura was using DesktopCaptureClient but > CaptureSynchronizer was only supporting one CaptureClient, which is > a CaptureController. Therefore made the following changes: > > 1. We have one CaptureController for ash and multiple > DesktopCaptureClients for all mus clients. This CL changes > CaptureSynchronizer and PointerWatcherEventRouter to support multiple > CaptureClients. When a root window's capture client is set, MusClient > will be notified by DesktopWindowTreeHostMus if it's a > DesktopCaptureClient, and WindowManager will take care of > CaptureController. We then add CaptureSynchronizer and > PointerWatcherEventRouter to be the observer for that CaptureClient. > > 2. Update DesktopCaptureClient to notify its observers when capture > has changed. > > BUG= 676002 , 678057 > TEST=aura_unittests views_mus_unittests > > Review-Url: https://codereview.chromium.org/2626013005 > Cr-Commit-Position: refs/heads/master@{#447621} > Committed: https://chromium.googlesource.com/chromium/src/+/e75f053a801b6a6322a57a9417582f14ebc3f161 TBR=sadrul@chromium.org,sky@chromium.org,riajiang@chromium.org # Skipping CQ checks because original CL landed less than 1 days ago. NOPRESUBMIT=true NOTREECHECKS=true NOTRY=true BUG= 676002 , 678057 Review-Url: https://codereview.chromium.org/2674683002 Cr-Commit-Position: refs/heads/master@{#447753} [modify] https://crrev.com/f5a30c08e753738a71894ed1f43c07a6d0421dc6/ash/mus/window_manager.cc [modify] https://crrev.com/f5a30c08e753738a71894ed1f43c07a6d0421dc6/ui/aura/mus/capture_synchronizer.cc [modify] https://crrev.com/f5a30c08e753738a71894ed1f43c07a6d0421dc6/ui/aura/mus/capture_synchronizer.h [modify] https://crrev.com/f5a30c08e753738a71894ed1f43c07a6d0421dc6/ui/aura/mus/window_tree_client.cc [modify] https://crrev.com/f5a30c08e753738a71894ed1f43c07a6d0421dc6/ui/aura/mus/window_tree_client.h [modify] https://crrev.com/f5a30c08e753738a71894ed1f43c07a6d0421dc6/ui/aura/mus/window_tree_client_unittest.cc [modify] https://crrev.com/f5a30c08e753738a71894ed1f43c07a6d0421dc6/ui/aura/test/aura_test_helper.cc [modify] https://crrev.com/f5a30c08e753738a71894ed1f43c07a6d0421dc6/ui/views/mus/desktop_window_tree_host_mus.cc [modify] https://crrev.com/f5a30c08e753738a71894ed1f43c07a6d0421dc6/ui/views/mus/desktop_window_tree_host_mus_unittest.cc [modify] https://crrev.com/f5a30c08e753738a71894ed1f43c07a6d0421dc6/ui/views/mus/mus_client.cc [modify] https://crrev.com/f5a30c08e753738a71894ed1f43c07a6d0421dc6/ui/views/mus/mus_client.h [modify] https://crrev.com/f5a30c08e753738a71894ed1f43c07a6d0421dc6/ui/views/mus/pointer_watcher_event_router.cc [modify] https://crrev.com/f5a30c08e753738a71894ed1f43c07a6d0421dc6/ui/views/mus/pointer_watcher_event_router.h [modify] https://crrev.com/f5a30c08e753738a71894ed1f43c07a6d0421dc6/ui/views/widget/desktop_aura/desktop_capture_client.cc [modify] https://crrev.com/f5a30c08e753738a71894ed1f43c07a6d0421dc6/ui/views/widget/desktop_aura/desktop_capture_client.h
The following revision refers to this bug: https://chromium.googlesource.com/chromium/src.git/+/7c809220a7efcf0c26793f7357ad7e69f2804638 commit 7c809220a7efcf0c26793f7357ad7e69f2804638 Author: johnme <johnme@chromium.org> Date: Thu Feb 02 13:19:24 2017 Revert of Remove WindowTreeClientDelegate::GetCaptureClient() and WindowTreeClient::GetCaptureClient(). (patchset #3 id:40001 of https://codereview.chromium.org/2657873006/ ) Reason for revert: Prevents reverting https://codereview.chromium.org/2674683002 Original issue's description: > Remove virtual function WindowTreeClientDelegate::GetCaptureClient() and > WindowTreeClient::GetCaptureClient(). > > This CL is separated out from https://codereview.chromium.org/2626013005 > > BUG= 676002 , 678057 > > Review-Url: https://codereview.chromium.org/2657873006 > Cr-Commit-Position: refs/heads/master@{#447680} > Committed: https://chromium.googlesource.com/chromium/src/+/6c8ec587ec4cf305eafb23d136dd4a34fd825730 TBR=rockot@chromium.org,sadrul@chromium.org,sky@chromium.org,riajiang@chromium.org # Skipping CQ checks because original CL landed less than 1 days ago. NOPRESUBMIT=true NOTREECHECKS=true NOTRY=true BUG= 676002 , 678057 Review-Url: https://codereview.chromium.org/2669203002 Cr-Commit-Position: refs/heads/master@{#447755} [modify] https://crrev.com/7c809220a7efcf0c26793f7357ad7e69f2804638/ash/mus/window_manager.cc [modify] https://crrev.com/7c809220a7efcf0c26793f7357ad7e69f2804638/ash/mus/window_manager.h [modify] https://crrev.com/7c809220a7efcf0c26793f7357ad7e69f2804638/ash/mus/window_manager_unittest.cc [modify] https://crrev.com/7c809220a7efcf0c26793f7357ad7e69f2804638/mash/simple_wm/simple_wm.cc [modify] https://crrev.com/7c809220a7efcf0c26793f7357ad7e69f2804638/mash/simple_wm/simple_wm.h [modify] https://crrev.com/7c809220a7efcf0c26793f7357ad7e69f2804638/services/navigation/view_impl.cc [modify] https://crrev.com/7c809220a7efcf0c26793f7357ad7e69f2804638/services/navigation/view_impl.h [modify] https://crrev.com/7c809220a7efcf0c26793f7357ad7e69f2804638/services/ui/demo/mus_demo.cc [modify] https://crrev.com/7c809220a7efcf0c26793f7357ad7e69f2804638/services/ui/demo/mus_demo.h [modify] https://crrev.com/7c809220a7efcf0c26793f7357ad7e69f2804638/services/ui/test_wm/test_wm.cc [modify] https://crrev.com/7c809220a7efcf0c26793f7357ad7e69f2804638/services/ui/ws/window_server_test_base.cc [modify] https://crrev.com/7c809220a7efcf0c26793f7357ad7e69f2804638/services/ui/ws/window_server_test_base.h [modify] https://crrev.com/7c809220a7efcf0c26793f7357ad7e69f2804638/ui/aura/mus/window_tree_client.cc [modify] https://crrev.com/7c809220a7efcf0c26793f7357ad7e69f2804638/ui/aura/mus/window_tree_client.h [modify] https://crrev.com/7c809220a7efcf0c26793f7357ad7e69f2804638/ui/aura/mus/window_tree_client_delegate.h [modify] https://crrev.com/7c809220a7efcf0c26793f7357ad7e69f2804638/ui/aura/test/aura_test_base.cc [modify] https://crrev.com/7c809220a7efcf0c26793f7357ad7e69f2804638/ui/aura/test/aura_test_base.h [modify] https://crrev.com/7c809220a7efcf0c26793f7357ad7e69f2804638/ui/views/mus/mus_client.cc [modify] https://crrev.com/7c809220a7efcf0c26793f7357ad7e69f2804638/ui/views/mus/mus_client.h
The following revision refers to this bug: https://chromium.googlesource.com/chromium/src.git/+/f6a5c39ae29d703bb4ecc6663477de3f9d3284a6 commit f6a5c39ae29d703bb4ecc6663477de3f9d3284a6 Author: riajiang <riajiang@chromium.org> Date: Thu Feb 02 17:37:48 2017 Change CaptureSynchronizer and PointerWatcherEventRouter to support multiple CaptureClients. DesktopNativeWidgetAura was using DesktopCaptureClient but CaptureSynchronizer was only supporting one CaptureClient, which is a CaptureController. Therefore made the following changes: 1. We have one CaptureController for ash and multiple DesktopCaptureClients for all mus clients. This CL changes CaptureSynchronizer and PointerWatcherEventRouter to support multiple CaptureClients. When a root window's capture client is set, MusClient will be notified by DesktopWindowTreeHostMus if it's a DesktopCaptureClient, and WindowManager will take care of CaptureController. We then add CaptureSynchronizer and PointerWatcherEventRouter to be the observer for that CaptureClient. 2. Update DesktopCaptureClient to notify its observers when capture has changed. BUG= 676002 , 678057 TEST=aura_unittests views_mus_unittests Review-Url: https://codereview.chromium.org/2626013005 Cr-Original-Commit-Position: refs/heads/master@{#447621} Committed: https://chromium.googlesource.com/chromium/src/+/e75f053a801b6a6322a57a9417582f14ebc3f161 Review-Url: https://codereview.chromium.org/2626013005 Cr-Commit-Position: refs/heads/master@{#447790} [modify] https://crrev.com/f6a5c39ae29d703bb4ecc6663477de3f9d3284a6/ash/mus/window_manager.cc [modify] https://crrev.com/f6a5c39ae29d703bb4ecc6663477de3f9d3284a6/ui/aura/mus/capture_synchronizer.cc [modify] https://crrev.com/f6a5c39ae29d703bb4ecc6663477de3f9d3284a6/ui/aura/mus/capture_synchronizer.h [modify] https://crrev.com/f6a5c39ae29d703bb4ecc6663477de3f9d3284a6/ui/aura/mus/window_tree_client.cc [modify] https://crrev.com/f6a5c39ae29d703bb4ecc6663477de3f9d3284a6/ui/aura/mus/window_tree_client.h [modify] https://crrev.com/f6a5c39ae29d703bb4ecc6663477de3f9d3284a6/ui/aura/mus/window_tree_client_unittest.cc [modify] https://crrev.com/f6a5c39ae29d703bb4ecc6663477de3f9d3284a6/ui/aura/test/aura_test_helper.cc [modify] https://crrev.com/f6a5c39ae29d703bb4ecc6663477de3f9d3284a6/ui/views/mus/desktop_window_tree_host_mus.cc [modify] https://crrev.com/f6a5c39ae29d703bb4ecc6663477de3f9d3284a6/ui/views/mus/desktop_window_tree_host_mus_unittest.cc [modify] https://crrev.com/f6a5c39ae29d703bb4ecc6663477de3f9d3284a6/ui/views/mus/mus_client.cc [modify] https://crrev.com/f6a5c39ae29d703bb4ecc6663477de3f9d3284a6/ui/views/mus/mus_client.h [modify] https://crrev.com/f6a5c39ae29d703bb4ecc6663477de3f9d3284a6/ui/views/mus/pointer_watcher_event_router.cc [modify] https://crrev.com/f6a5c39ae29d703bb4ecc6663477de3f9d3284a6/ui/views/mus/pointer_watcher_event_router.h [modify] https://crrev.com/f6a5c39ae29d703bb4ecc6663477de3f9d3284a6/ui/views/widget/desktop_aura/desktop_capture_client.cc [modify] https://crrev.com/f6a5c39ae29d703bb4ecc6663477de3f9d3284a6/ui/views/widget/desktop_aura/desktop_capture_client.h
The following revision refers to this bug: https://chromium.googlesource.com/chromium/src.git/+/f1238c589d9d22d51fe24c0744e28389e594267f commit f1238c589d9d22d51fe24c0744e28389e594267f Author: riajiang <riajiang@chromium.org> Date: Thu Feb 02 21:23:25 2017 Remove virtual function WindowTreeClientDelegate::GetCaptureClient() and WindowTreeClient::GetCaptureClient(). This CL is separated out from https://codereview.chromium.org/2626013005 BUG= 676002 , 678057 Review-Url: https://codereview.chromium.org/2657873006 Cr-Original-Commit-Position: refs/heads/master@{#447680} Committed: https://chromium.googlesource.com/chromium/src/+/6c8ec587ec4cf305eafb23d136dd4a34fd825730 Review-Url: https://codereview.chromium.org/2657873006 Cr-Commit-Position: refs/heads/master@{#447843} [modify] https://crrev.com/f1238c589d9d22d51fe24c0744e28389e594267f/ash/mus/window_manager.cc [modify] https://crrev.com/f1238c589d9d22d51fe24c0744e28389e594267f/ash/mus/window_manager.h [modify] https://crrev.com/f1238c589d9d22d51fe24c0744e28389e594267f/ash/mus/window_manager_unittest.cc [modify] https://crrev.com/f1238c589d9d22d51fe24c0744e28389e594267f/mash/simple_wm/simple_wm.cc [modify] https://crrev.com/f1238c589d9d22d51fe24c0744e28389e594267f/mash/simple_wm/simple_wm.h [modify] https://crrev.com/f1238c589d9d22d51fe24c0744e28389e594267f/services/navigation/view_impl.cc [modify] https://crrev.com/f1238c589d9d22d51fe24c0744e28389e594267f/services/navigation/view_impl.h [modify] https://crrev.com/f1238c589d9d22d51fe24c0744e28389e594267f/services/ui/demo/mus_demo.cc [modify] https://crrev.com/f1238c589d9d22d51fe24c0744e28389e594267f/services/ui/demo/mus_demo.h [modify] https://crrev.com/f1238c589d9d22d51fe24c0744e28389e594267f/services/ui/test_wm/test_wm.cc [modify] https://crrev.com/f1238c589d9d22d51fe24c0744e28389e594267f/services/ui/ws/window_server_test_base.cc [modify] https://crrev.com/f1238c589d9d22d51fe24c0744e28389e594267f/services/ui/ws/window_server_test_base.h [modify] https://crrev.com/f1238c589d9d22d51fe24c0744e28389e594267f/ui/aura/mus/window_tree_client.cc [modify] https://crrev.com/f1238c589d9d22d51fe24c0744e28389e594267f/ui/aura/mus/window_tree_client.h [modify] https://crrev.com/f1238c589d9d22d51fe24c0744e28389e594267f/ui/aura/mus/window_tree_client_delegate.h [modify] https://crrev.com/f1238c589d9d22d51fe24c0744e28389e594267f/ui/aura/test/aura_test_base.cc [modify] https://crrev.com/f1238c589d9d22d51fe24c0744e28389e594267f/ui/aura/test/aura_test_base.h [modify] https://crrev.com/f1238c589d9d22d51fe24c0744e28389e594267f/ui/views/mus/mus_client.cc [modify] https://crrev.com/f1238c589d9d22d51fe24c0744e28389e594267f/ui/views/mus/mus_client.h
Comment 1 by riajiang@chromium.org
, Dec 20 2016