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

Side by Side Diff: ui/views/widget/desktop_aura/desktop_drag_drop_client_aurax11.cc

Issue 72503002: Remove some pass-thrus on RootWindow API in favor of exposing the RootWindowHost again. (Closed) Base URL: svn://svn.chromium.org/chrome/trunk/src
Patch Set: . Created 7 years, 1 month 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
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/views/widget/desktop_aura/desktop_drag_drop_client_aurax11.h" 5 #include "ui/views/widget/desktop_aura/desktop_drag_drop_client_aurax11.h"
6 6
7 #include <X11/Xatom.h> 7 #include <X11/Xatom.h>
8 8
9 #include "base/event_types.h" 9 #include "base/event_types.h"
10 #include "base/lazy_instance.h" 10 #include "base/lazy_instance.h"
(...skipping 666 matching lines...) Expand 10 before | Expand all | Expand 10 after
677 void DesktopDragDropClientAuraX11::OnMoveLoopEnded() { 677 void DesktopDragDropClientAuraX11::OnMoveLoopEnded() {
678 target_current_context_.reset(); 678 target_current_context_.reset();
679 } 679 }
680 680
681 void DesktopDragDropClientAuraX11::DragTranslate( 681 void DesktopDragDropClientAuraX11::DragTranslate(
682 const gfx::Point& root_window_location, 682 const gfx::Point& root_window_location,
683 scoped_ptr<ui::OSExchangeData>* data, 683 scoped_ptr<ui::OSExchangeData>* data,
684 scoped_ptr<ui::DropTargetEvent>* event, 684 scoped_ptr<ui::DropTargetEvent>* event,
685 aura::client::DragDropDelegate** delegate) { 685 aura::client::DragDropDelegate** delegate) {
686 gfx::Point root_location = root_window_location; 686 gfx::Point root_location = root_window_location;
687 root_window_->GetDispatcher()->ConvertPointFromNativeScreen(&root_location); 687 root_window_->GetDispatcher()->host()->ConvertPointFromNativeScreen(
688 &root_location);
688 aura::Window* target_window = 689 aura::Window* target_window =
689 root_window_->GetEventHandlerForPoint(root_location); 690 root_window_->GetEventHandlerForPoint(root_location);
690 bool target_window_changed = false; 691 bool target_window_changed = false;
691 if (target_window != target_window_) { 692 if (target_window != target_window_) {
692 if (target_window_) 693 if (target_window_)
693 NotifyDragLeave(); 694 NotifyDragLeave();
694 target_window_ = target_window; 695 target_window_ = target_window;
695 if (target_window_) 696 if (target_window_)
696 target_window_->AddObserver(this); 697 target_window_->AddObserver(this);
697 target_window_changed = true; 698 target_window_changed = true;
(...skipping 219 matching lines...) Expand 10 before | Expand all | Expand 10 after
917 // GdkEvent about the failed drag. (And sending this message doesn't appear 918 // GdkEvent about the failed drag. (And sending this message doesn't appear
918 // to go through normal xlib machinery, but instead passes through the low 919 // to go through normal xlib machinery, but instead passes through the low
919 // level xProto (the x11 wire format) that I don't understand. 920 // level xProto (the x11 wire format) that I don't understand.
920 // 921 //
921 // I'm unsure if I have to jump through those hoops, or if XSendEvent is 922 // I'm unsure if I have to jump through those hoops, or if XSendEvent is
922 // sufficient. 923 // sufficient.
923 XSendEvent(xdisplay_, xid, False, 0, xev); 924 XSendEvent(xdisplay_, xid, False, 0, xev);
924 } 925 }
925 926
926 } // namespace views 927 } // namespace views
OLDNEW
« no previous file with comments | « ui/views/test/ui_controls_factory_desktop_aurax11.cc ('k') | ui/views/widget/desktop_aura/desktop_drop_target_win.cc » ('j') | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698