| OLD | NEW |
| 1 // Copyright (c) 2006-2008 The Chromium Authors. All rights reserved. | 1 // Copyright (c) 2006-2008 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/native_ui_contents.h" | 5 #include "chrome/browser/native_ui_contents.h" |
| 6 | 6 |
| 7 #include "chrome/browser/browser.h" | 7 #include "chrome/browser/browser.h" |
| 8 #include "chrome/browser/history_tab_ui.h" | 8 #include "chrome/browser/history_tab_ui.h" |
| 9 #include "chrome/browser/navigation_entry.h" | 9 #include "chrome/browser/navigation_entry.h" |
| 10 #include "chrome/browser/views/download_tab_view.h" | 10 #include "chrome/browser/views/download_tab_view.h" |
| (...skipping 78 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
| 89 if (event.GetSourceOperations() & DragDropTypes::DRAG_LINK) | 89 if (event.GetSourceOperations() & DragDropTypes::DRAG_LINK) |
| 90 return DragDropTypes::DRAG_LINK; | 90 return DragDropTypes::DRAG_LINK; |
| 91 return DragDropTypes::DRAG_NONE; | 91 return DragDropTypes::DRAG_NONE; |
| 92 } | 92 } |
| 93 | 93 |
| 94 virtual int OnPerformDrop(const views::DropTargetEvent& event) { | 94 virtual int OnPerformDrop(const views::DropTargetEvent& event) { |
| 95 GURL url; | 95 GURL url; |
| 96 std::wstring title; | 96 std::wstring title; |
| 97 if (!event.GetData().GetURLAndTitle(&url, &title) || !url.is_valid()) | 97 if (!event.GetData().GetURLAndTitle(&url, &title) || !url.is_valid()) |
| 98 return DragDropTypes::DRAG_NONE; | 98 return DragDropTypes::DRAG_NONE; |
| 99 host_->controller()->LoadURL(url, PageTransition::GENERATED); | 99 host_->controller()->LoadURL(url, GURL(), PageTransition::GENERATED); |
| 100 return OnDragUpdated(event); | 100 return OnDragUpdated(event); |
| 101 } | 101 } |
| 102 | 102 |
| 103 private: | 103 private: |
| 104 NativeUIContents* host_; | 104 NativeUIContents* host_; |
| 105 | 105 |
| 106 DISALLOW_EVIL_CONSTRUCTORS(NativeRootView); | 106 DISALLOW_EVIL_CONSTRUCTORS(NativeRootView); |
| 107 }; | 107 }; |
| 108 | 108 |
| 109 } // namespace | 109 } // namespace |
| (...skipping 554 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
| 664 DoSearch(); | 664 DoSearch(); |
| 665 } | 665 } |
| 666 | 666 |
| 667 void SearchableUIContainer::DoSearch() { | 667 void SearchableUIContainer::DoSearch() { |
| 668 if (delegate_) | 668 if (delegate_) |
| 669 delegate_->DoSearch(search_field_->GetText()); | 669 delegate_->DoSearch(search_field_->GetText()); |
| 670 | 670 |
| 671 scroll_view_->ScrollToPosition(scroll_view_->vertical_scroll_bar(), 0); | 671 scroll_view_->ScrollToPosition(scroll_view_->vertical_scroll_bar(), 0); |
| 672 } | 672 } |
| 673 | 673 |
| OLD | NEW |