Chromium Code Reviews
chromiumcodereview-hr@appspot.gserviceaccount.com (chromiumcodereview-hr) | Please choose your nickname with Settings | Help | Chromium Project | Gerrit Changes | Sign out
(601)

Side by Side Diff: ui/base/dragdrop/os_exchange_data_provider_aurax11.cc

Issue 23460052: Move XID, XDisplay, GetXDisplay and a few other types to ui/gfx/x/x11_types.h (Closed) Base URL: https://chromium.googlesource.com/chromium/src.git@master
Patch Set: sdf Created 7 years, 3 months ago
Use n/p to move between diff chunks; N/P to move between comments. Draft comments are only viewable by you.
Jump to:
View unified diff | Download patch
« no previous file with comments | « ui/base/cursor/cursor_loader_x11.cc ('k') | ui/base/ime/character_composer.cc » ('j') | no next file with comments »
Toggle Intra-line Diffs ('i') | Expand Comments ('e') | Collapse Comments ('c') | Show Comments Hide Comments ('s')
OLDNEW
1 // Copyright (c) 2012 The Chromium Authors. All rights reserved. 1 // Copyright (c) 2012 The Chromium Authors. All rights reserved.
2 // Use of this source code is governed by a BSD-style license that can be 2 // Use of this source code is governed by a BSD-style license that can be
3 // found in the LICENSE file. 3 // found in the LICENSE file.
4 4
5 #include "ui/base/dragdrop/os_exchange_data_provider_aurax11.h" 5 #include "ui/base/dragdrop/os_exchange_data_provider_aurax11.h"
6 6
7 #include "base/logging.h" 7 #include "base/logging.h"
8 #include "base/memory/ref_counted_memory.h" 8 #include "base/memory/ref_counted_memory.h"
9 #include "base/message_loop/message_pump_x11.h" 9 #include "base/message_loop/message_pump_x11.h"
10 #include "base/strings/string_util.h" 10 #include "base/strings/string_util.h"
(...skipping 24 matching lines...) Expand all
35 kMimeTypeMozillaURL, 35 kMimeTypeMozillaURL,
36 Clipboard::kMimeTypeText, 36 Clipboard::kMimeTypeText,
37 NULL 37 NULL
38 }; 38 };
39 39
40 } // namespace 40 } // namespace
41 41
42 OSExchangeDataProviderAuraX11::OSExchangeDataProviderAuraX11( 42 OSExchangeDataProviderAuraX11::OSExchangeDataProviderAuraX11(
43 ::Window x_window, 43 ::Window x_window,
44 const SelectionFormatMap& selection) 44 const SelectionFormatMap& selection)
45 : x_display_(GetXDisplay()), 45 : x_display_(gfx::GetXDisplay()),
46 x_root_window_(DefaultRootWindow(x_display_)), 46 x_root_window_(DefaultRootWindow(x_display_)),
47 own_window_(false), 47 own_window_(false),
48 x_window_(x_window), 48 x_window_(x_window),
49 atom_cache_(x_display_, kAtomsToCache), 49 atom_cache_(x_display_, kAtomsToCache),
50 format_map_(selection), 50 format_map_(selection),
51 selection_owner_(x_display_, x_window_, 51 selection_owner_(x_display_, x_window_,
52 atom_cache_.GetAtom(kDndSelection)) { 52 atom_cache_.GetAtom(kDndSelection)) {
53 // We don't know all possible MIME types at compile time. 53 // We don't know all possible MIME types at compile time.
54 atom_cache_.allow_uncached_atoms(); 54 atom_cache_.allow_uncached_atoms();
55 } 55 }
56 56
57 OSExchangeDataProviderAuraX11::OSExchangeDataProviderAuraX11() 57 OSExchangeDataProviderAuraX11::OSExchangeDataProviderAuraX11()
58 : x_display_(GetXDisplay()), 58 : x_display_(gfx::GetXDisplay()),
59 x_root_window_(DefaultRootWindow(x_display_)), 59 x_root_window_(DefaultRootWindow(x_display_)),
60 own_window_(true), 60 own_window_(true),
61 x_window_(XCreateWindow( 61 x_window_(XCreateWindow(
62 x_display_, 62 x_display_,
63 x_root_window_, 63 x_root_window_,
64 -100, -100, 10, 10, // x, y, width, height 64 -100, -100, 10, 10, // x, y, width, height
65 0, // border width 65 0, // border width
66 CopyFromParent, // depth 66 CopyFromParent, // depth
67 InputOnly, 67 InputOnly,
68 CopyFromParent, // visual 68 CopyFromParent, // visual
(...skipping 304 matching lines...) Expand 10 before | Expand all | Expand 10 after
373 373
374 /////////////////////////////////////////////////////////////////////////////// 374 ///////////////////////////////////////////////////////////////////////////////
375 // OSExchangeData, public: 375 // OSExchangeData, public:
376 376
377 // static 377 // static
378 OSExchangeData::Provider* OSExchangeData::CreateProvider() { 378 OSExchangeData::Provider* OSExchangeData::CreateProvider() {
379 return new OSExchangeDataProviderAuraX11(); 379 return new OSExchangeDataProviderAuraX11();
380 } 380 }
381 381
382 } // namespace ui 382 } // namespace ui
OLDNEW
« no previous file with comments | « ui/base/cursor/cursor_loader_x11.cc ('k') | ui/base/ime/character_composer.cc » ('j') | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698