|
Remove usages of XInternAtom
Previously, there were multiple places in Chrome where ui::GetAtom or
XInternAtom was used without caching. This requires a blocking
round-trip to the X server for each of these. Other code used
X11AtomCache. However, there were multiple separate caches which each
require a round-trip on construction. This CL makes X11AtomCache a
singleton. There will be only a single round-trip to get all atoms on
browser startup.
This CL:
* Replaces most usage of XInternAtom(s) with ui::GetAtom or
ui::X11AtomCache::GetAtom()
* Makes ui::GetAtom use X11AtomCache
* Makes X11AtomCache a singleton
* Previously there were separate caches, many of which had duplicate
atoms. This change consolidates them into one place.
* Adds a PRESUBMIT warning to prevent usage of XInternAtom
CQ_INCLUDE_TRYBOTS=master.tryserver.chromium.android:android_optional_gpu_tests_rel;master.tryserver.chromium.linux:linux_optional_gpu_tests_rel;master.tryserver.chromium.mac:mac_optional_gpu_tests_rel;master.tryserver.chromium.win:win_optional_gpu_tests_rel
BUG= 730889
Review-Url: https://codereview.chromium.org/2914103002
Cr-Commit-Position: refs/heads/master@{#477836}
Committed: https://chromium.googlesource.com/chromium/src/+/e043e3ceedef5d2ab6eb984d8f0a627989abad3e
Total comments: 17
|
Unified diffs |
Side-by-side diffs |
Delta from patch set |
Stats (+461 lines, -707 lines) |
Patch |
|
M |
PRESUBMIT.py
|
View
|
1
|
1 chunk |
+11 lines, -0 lines |
0 comments
|
Download
|
|
M |
ash/host/ash_window_tree_host_x11.cc
|
View
|
|
2 chunks |
+2 lines, -1 line |
0 comments
|
Download
|
|
M |
chrome/browser/media/webrtc/window_icon_util_x11.cc
|
View
|
|
2 chunks |
+2 lines, -1 line |
0 comments
|
Download
|
|
M |
ui/aura/test/ui_controls_factory_aurax11.cc
|
View
|
|
1 chunk |
+1 line, -1 line |
0 comments
|
Download
|
|
M |
ui/aura/window_tree_host_x11.h
|
View
|
|
3 chunks |
+0 lines, -4 lines |
0 comments
|
Download
|
|
M |
ui/aura/window_tree_host_x11.cc
|
View
|
|
5 chunks |
+8 lines, -23 lines |
0 comments
|
Download
|
|
M |
ui/base/clipboard/clipboard_aurax11.cc
|
View
|
1
|
15 chunks |
+16 lines, -47 lines |
0 comments
|
Download
|
|
M |
ui/base/dragdrop/os_exchange_data_provider_aurax11.h
|
View
|
|
2 chunks |
+0 lines, -3 lines |
0 comments
|
Download
|
|
M |
ui/base/dragdrop/os_exchange_data_provider_aurax11.cc
|
View
|
|
23 chunks |
+44 lines, -68 lines |
0 comments
|
Download
|
|
M |
ui/base/dragdrop/os_exchange_data_provider_aurax11_unittest.cc
|
View
|
|
2 chunks |
+2 lines, -3 lines |
0 comments
|
Download
|
|
M |
ui/base/x/selection_owner.h
|
View
|
|
2 chunks |
+0 lines, -3 lines |
0 comments
|
Download
|
|
M |
ui/base/x/selection_owner.cc
|
View
|
|
6 chunks |
+9 lines, -23 lines |
0 comments
|
Download
|
|
M |
ui/base/x/selection_requestor.h
|
View
|
|
2 chunks |
+0 lines, -3 lines |
0 comments
|
Download
|
|
M |
ui/base/x/selection_requestor.cc
|
View
|
|
3 chunks |
+3 lines, -10 lines |
0 comments
|
Download
|
|
M |
ui/base/x/selection_requestor_unittest.cc
|
View
|
|
7 chunks |
+11 lines, -31 lines |
0 comments
|
Download
|
|
M |
ui/base/x/selection_utils.h
|
View
|
|
2 chunks |
+3 lines, -10 lines |
0 comments
|
Download
|
|
M |
ui/base/x/selection_utils.cc
|
View
|
|
5 chunks |
+18 lines, -40 lines |
0 comments
|
Download
|
|
M |
ui/base/x/x11_util.cc
|
View
|
|
3 chunks |
+3 lines, -3 lines |
0 comments
|
Download
|
|
M |
ui/display/manager/chromeos/x11/native_display_delegate_x11.cc
|
View
|
|
5 chunks |
+10 lines, -12 lines |
0 comments
|
Download
|
|
M |
ui/display/util/x11/edid_parser_x11.cc
|
View
|
|
2 chunks |
+3 lines, -3 lines |
0 comments
|
Download
|
|
M |
ui/events/devices/x11/device_data_manager_x11.h
|
View
|
|
2 chunks |
+0 lines, -4 lines |
0 comments
|
Download
|
|
M |
ui/events/devices/x11/device_data_manager_x11.cc
|
View
|
|
4 chunks |
+4 lines, -3 lines |
0 comments
|
Download
|
|
M |
ui/events/platform/x11/x11_event_source.cc
|
View
|
|
2 chunks |
+2 lines, -1 line |
0 comments
|
Download
|
|
M |
ui/events/platform/x11/x11_hotplug_event_handler.h
|
View
|
|
2 chunks |
+0 lines, -3 lines |
0 comments
|
Download
|
|
M |
ui/events/platform/x11/x11_hotplug_event_handler.cc
|
View
|
|
7 chunks |
+12 lines, -24 lines |
0 comments
|
Download
|
|
M |
ui/gfx/icc_profile_x11.cc
|
View
|
|
2 chunks |
+2 lines, -1 line |
0 comments
|
Download
|
|
M |
ui/gfx/x/x11_atom_cache.h
|
View
|
|
2 chunks |
+11 lines, -9 lines |
0 comments
|
Download
|
|
M |
ui/gfx/x/x11_atom_cache.cc
|
View
|
1
|
2 chunks |
+154 lines, -9 lines |
0 comments
|
Download
|
|
M |
ui/platform_window/x11/x11_window_base.h
|
View
|
|
2 chunks |
+0 lines, -2 lines |
0 comments
|
Download
|
|
M |
ui/platform_window/x11/x11_window_base.cc
|
View
|
|
7 chunks |
+9 lines, -14 lines |
0 comments
|
Download
|
|
M |
ui/views/test/ui_controls_factory_desktop_aurax11.cc
|
View
|
|
1 chunk |
+1 line, -1 line |
0 comments
|
Download
|
|
M |
ui/views/test/x11_property_change_waiter.h
|
View
|
|
2 chunks |
+0 lines, -3 lines |
0 comments
|
Download
|
|
M |
ui/views/test/x11_property_change_waiter.cc
|
View
|
|
2 chunks |
+3 lines, -9 lines |
0 comments
|
Download
|
|
M |
ui/views/widget/desktop_aura/desktop_drag_drop_client_aurax11.h
|
View
|
|
2 chunks |
+0 lines, -3 lines |
0 comments
|
Download
|
|
M |
ui/views/widget/desktop_aura/desktop_drag_drop_client_aurax11.cc
|
View
|
|
23 chunks |
+38 lines, -83 lines |
0 comments
|
Download
|
|
M |
ui/views/widget/desktop_aura/desktop_drag_drop_client_aurax11_unittest.cc
|
View
|
|
6 chunks |
+5 lines, -22 lines |
0 comments
|
Download
|
|
M |
ui/views/widget/desktop_aura/desktop_screen_x11.h
|
View
|
|
2 chunks |
+0 lines, -3 lines |
0 comments
|
Download
|
|
M |
ui/views/widget/desktop_aura/desktop_screen_x11.cc
|
View
|
|
5 chunks |
+4 lines, -11 lines |
0 comments
|
Download
|
|
M |
ui/views/widget/desktop_aura/desktop_window_tree_host_x11.h
|
View
|
|
2 chunks |
+0 lines, -3 lines |
0 comments
|
Download
|
|
M |
ui/views/widget/desktop_aura/desktop_window_tree_host_x11.cc
|
View
|
|
24 chunks |
+53 lines, -131 lines |
0 comments
|
Download
|
|
M |
ui/views/widget/desktop_aura/desktop_window_tree_host_x11_unittest.cc
|
View
|
|
8 chunks |
+9 lines, -43 lines |
0 comments
|
Download
|
|
M |
ui/views/widget/desktop_aura/x11_desktop_handler.h
|
View
|
|
2 chunks |
+0 lines, -3 lines |
0 comments
|
Download
|
|
M |
ui/views/widget/desktop_aura/x11_desktop_handler.cc
|
View
|
|
3 chunks |
+2 lines, -9 lines |
0 comments
|
Download
|
|
M |
ui/views/widget/desktop_aura/x11_topmost_window_finder_interactive_uitest.cc
|
View
|
|
4 chunks |
+4 lines, -14 lines |
0 comments
|
Download
|
|
M |
ui/views/widget/desktop_aura/x11_window_event_filter.h
|
View
|
|
2 chunks |
+0 lines, -3 lines |
0 comments
|
Download
|
|
M |
ui/views/widget/desktop_aura/x11_window_event_filter.cc
|
View
|
|
4 chunks |
+2 lines, -7 lines |
0 comments
|
Download
|
Total messages: 71 (58 generated)
|