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

Side by Side Diff: views/widget/native_widget_gtk.cc

Issue 8343023: rename Run in MessageLoopForUI to RunWithDispatcher (Closed) Base URL: svn://svn.chromium.org/chrome/trunk/src
Patch Set: sync Created 9 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 | Annotate | Revision Log
« no previous file with comments | « views/focus/focus_manager_unittest.cc ('k') | no next file » | 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) 2011 The Chromium Authors. All rights reserved. 1 // Copyright (c) 2011 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 "views/widget/native_widget_gtk.h" 5 #include "views/widget/native_widget_gtk.h"
6 6
7 #include <gdk/gdk.h> 7 #include <gdk/gdk.h>
8 #include <gdk/gdkx.h> 8 #include <gdk/gdkx.h>
9 #include <X11/extensions/shape.h> 9 #include <X11/extensions/shape.h>
10 #include <X11/Xatom.h> 10 #include <X11/Xatom.h>
(...skipping 510 matching lines...) Expand 10 before | Expand all | Expand 10 after
521 } 521 }
522 } 522 }
523 523
524 if (current_event) 524 if (current_event)
525 gdk_event_free(current_event); 525 gdk_event_free(current_event);
526 gtk_target_list_unref(targets); 526 gtk_target_list_unref(targets);
527 527
528 drag_data_ = &data_provider; 528 drag_data_ = &data_provider;
529 529
530 // Block the caller until drag is done by running a nested message loop. 530 // Block the caller until drag is done by running a nested message loop.
531 MessageLoopForUI::current()->Run(NULL); 531 MessageLoopForUI::current()->RunWithDispatcher(NULL);
532 532
533 drag_data_ = NULL; 533 drag_data_ = NULL;
534 534
535 if (drag_icon_widget) { 535 if (drag_icon_widget) {
536 gtk_widget_destroy(drag_icon_widget); 536 gtk_widget_destroy(drag_icon_widget);
537 g_object_unref(provider.drag_image()); 537 g_object_unref(provider.drag_image());
538 } 538 }
539 } 539 }
540 540
541 void NativeWidgetGtk::OnActiveChanged() { 541 void NativeWidgetGtk::OnActiveChanged() {
(...skipping 1764 matching lines...) Expand 10 before | Expand all | Expand 10 after
2306 button_pressed = event->type == GDK_BUTTON_PRESS || 2306 button_pressed = event->type == GDK_BUTTON_PRESS ||
2307 event->type == GDK_2BUTTON_PRESS || 2307 event->type == GDK_2BUTTON_PRESS ||
2308 event->type == GDK_3BUTTON_PRESS; 2308 event->type == GDK_3BUTTON_PRESS;
2309 gdk_event_free(event); 2309 gdk_event_free(event);
2310 } 2310 }
2311 return button_pressed; 2311 return button_pressed;
2312 } 2312 }
2313 2313
2314 } // namespace internal 2314 } // namespace internal
2315 } // namespace views 2315 } // namespace views
OLDNEW
« no previous file with comments | « views/focus/focus_manager_unittest.cc ('k') | no next file » | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698