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

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

Issue 667823002: PlatformEventDispatcher::DispatchEvent() should return a PostDispatchAction (Closed) Base URL: https://chromium.googlesource.com/chromium/src.git@ui_enums
Patch Set: Fix platform_event_source_unittest.cc Created 6 years, 2 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
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 494 matching lines...) Expand 10 before | Expand all | Expand 10 after
505 505
506 const gfx::Vector2d& OSExchangeDataProviderAuraX11::GetDragImageOffset() const { 506 const gfx::Vector2d& OSExchangeDataProviderAuraX11::GetDragImageOffset() const {
507 return drag_image_offset_; 507 return drag_image_offset_;
508 } 508 }
509 509
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 ui::PostDispatchAction 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); 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;
(...skipping 18 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/dragdrop/os_exchange_data_provider_aurax11.h ('k') | ui/display/chromeos/x11/native_display_event_dispatcher_x11.h » ('j') | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698