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

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

Issue 396813004: Make selection_owner.h not include Xlib.h for consistency. (Closed) Base URL: svn://svn.chromium.org/chrome/trunk/src
Patch Set: Created 6 years, 5 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 | Annotate | Revision Log
« no previous file with comments | « ui/base/clipboard/clipboard_aurax11.cc ('k') | ui/base/x/selection_owner.h » ('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/strings/string_util.h" 9 #include "base/strings/string_util.h"
10 #include "base/strings/utf_string_conversions.h" 10 #include "base/strings/utf_string_conversions.h"
(...skipping 499 matching lines...) Expand 10 before | Expand all | Expand 10 after
510 bool OSExchangeDataProviderAuraX11::CanDispatchEvent( 510 bool OSExchangeDataProviderAuraX11::CanDispatchEvent(
511 const PlatformEvent& event) { 511 const PlatformEvent& event) {
512 return event->xany.window == x_window_; 512 return event->xany.window == x_window_;
513 } 513 }
514 514
515 uint32_t OSExchangeDataProviderAuraX11::DispatchEvent( 515 uint32_t OSExchangeDataProviderAuraX11::DispatchEvent(
516 const PlatformEvent& event) { 516 const PlatformEvent& event) {
517 XEvent* xev = event; 517 XEvent* xev = event;
518 switch (xev->type) { 518 switch (xev->type) {
519 case SelectionRequest: 519 case SelectionRequest:
520 selection_owner_.OnSelectionRequest(xev->xselectionrequest); 520 selection_owner_.OnSelectionRequest(*xev);
521 return ui::POST_DISPATCH_STOP_PROPAGATION; 521 return ui::POST_DISPATCH_STOP_PROPAGATION;
522 default: 522 default:
523 NOTIMPLEMENTED(); 523 NOTIMPLEMENTED();
524 } 524 }
525 return ui::POST_DISPATCH_NONE; 525 return ui::POST_DISPATCH_NONE;
526 } 526 }
527 527
528 bool OSExchangeDataProviderAuraX11::GetPlainTextURL(GURL* url) const { 528 bool OSExchangeDataProviderAuraX11::GetPlainTextURL(GURL* url) const {
529 base::string16 text; 529 base::string16 text;
530 if (GetString(&text)) { 530 if (GetString(&text)) {
(...skipping 13 matching lines...) Expand all
544 544
545 /////////////////////////////////////////////////////////////////////////////// 545 ///////////////////////////////////////////////////////////////////////////////
546 // OSExchangeData, public: 546 // OSExchangeData, public:
547 547
548 // static 548 // static
549 OSExchangeData::Provider* OSExchangeData::CreateProvider() { 549 OSExchangeData::Provider* OSExchangeData::CreateProvider() {
550 return new OSExchangeDataProviderAuraX11(); 550 return new OSExchangeDataProviderAuraX11();
551 } 551 }
552 552
553 } // namespace ui 553 } // namespace ui
OLDNEW
« no previous file with comments | « ui/base/clipboard/clipboard_aurax11.cc ('k') | ui/base/x/selection_owner.h » ('j') | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698