| OLD | NEW |
| 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 "chrome/browser/ui/gtk/location_bar_view_gtk.h" | 5 #include "chrome/browser/ui/gtk/location_bar_view_gtk.h" |
| 6 | 6 |
| 7 #include <algorithm> | 7 #include <algorithm> |
| 8 #include <string> | 8 #include <string> |
| 9 #include <vector> | 9 #include <vector> |
| 10 | 10 |
| (...skipping 1037 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
| 1048 if (!gtk_util::WidgetBounds(sender).Contains( | 1048 if (!gtk_util::WidgetBounds(sender).Contains( |
| 1049 gfx::Point(event->x, event->y))) { | 1049 gfx::Point(event->x, event->y))) { |
| 1050 return FALSE; | 1050 return FALSE; |
| 1051 } | 1051 } |
| 1052 | 1052 |
| 1053 GURL url; | 1053 GURL url; |
| 1054 if (!gtk_util::URLFromPrimarySelection(browser_->profile(), &url)) | 1054 if (!gtk_util::URLFromPrimarySelection(browser_->profile(), &url)) |
| 1055 return FALSE; | 1055 return FALSE; |
| 1056 | 1056 |
| 1057 tab->OpenURL(OpenURLParams( | 1057 tab->OpenURL(OpenURLParams( |
| 1058 url, GURL(), CURRENT_TAB, content::PAGE_TRANSITION_TYPED)); | 1058 url, GURL(), CURRENT_TAB, content::PAGE_TRANSITION_TYPED, false)); |
| 1059 return TRUE; | 1059 return TRUE; |
| 1060 } | 1060 } |
| 1061 | 1061 |
| 1062 return FALSE; | 1062 return FALSE; |
| 1063 } | 1063 } |
| 1064 | 1064 |
| 1065 void LocationBarViewGtk::OnIconDragData(GtkWidget* sender, | 1065 void LocationBarViewGtk::OnIconDragData(GtkWidget* sender, |
| 1066 GdkDragContext* context, | 1066 GdkDragContext* context, |
| 1067 GtkSelectionData* data, | 1067 GtkSelectionData* data, |
| 1068 guint info, guint time) { | 1068 guint info, guint time) { |
| (...skipping 561 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
| 1630 | 1630 |
| 1631 std::string badge_text = page_action_->GetBadgeText(tab_id); | 1631 std::string badge_text = page_action_->GetBadgeText(tab_id); |
| 1632 if (badge_text.empty()) | 1632 if (badge_text.empty()) |
| 1633 return FALSE; | 1633 return FALSE; |
| 1634 | 1634 |
| 1635 gfx::CanvasSkiaPaint canvas(event, false); | 1635 gfx::CanvasSkiaPaint canvas(event, false); |
| 1636 gfx::Rect bounding_rect(widget->allocation); | 1636 gfx::Rect bounding_rect(widget->allocation); |
| 1637 page_action_->PaintBadge(&canvas, bounding_rect, tab_id); | 1637 page_action_->PaintBadge(&canvas, bounding_rect, tab_id); |
| 1638 return FALSE; | 1638 return FALSE; |
| 1639 } | 1639 } |
| OLD | NEW |