| OLD | NEW |
| 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 "chrome/browser/tab_contents/render_view_context_menu.h" | 5 #include "chrome/browser/tab_contents/render_view_context_menu.h" |
| 6 | 6 |
| 7 #include <algorithm> | 7 #include <algorithm> |
| 8 #include <set> | 8 #include <set> |
| 9 #include <utility> | 9 #include <utility> |
| 10 | 10 |
| (...skipping 515 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
| 526 if (params_.is_editable) | 526 if (params_.is_editable) |
| 527 AppendEditableItems(); | 527 AppendEditableItems(); |
| 528 else if (has_selection) | 528 else if (has_selection) |
| 529 AppendCopyItem(); | 529 AppendCopyItem(); |
| 530 | 530 |
| 531 int index = 0; | 531 int index = 0; |
| 532 extension_items_.AppendExtensionItems(platform_app->id(), | 532 extension_items_.AppendExtensionItems(platform_app->id(), |
| 533 PrintableSelectionText(), &index); | 533 PrintableSelectionText(), &index); |
| 534 | 534 |
| 535 // Add dev tools for unpacked extensions. | 535 // Add dev tools for unpacked extensions. |
| 536 if (platform_app->location() == Extension::LOAD || | 536 if (platform_app->location() == extensions::Manifest::LOAD || |
| 537 CommandLine::ForCurrentProcess()->HasSwitch( | 537 CommandLine::ForCurrentProcess()->HasSwitch( |
| 538 switches::kDebugPackedApps)) { | 538 switches::kDebugPackedApps)) { |
| 539 // Add a separator if there are any items already in the menu. | 539 // Add a separator if there are any items already in the menu. |
| 540 if (menu_model_.GetItemCount() && | 540 if (menu_model_.GetItemCount() && |
| 541 menu_model_.GetTypeAt(menu_model_.GetItemCount() - 1) != | 541 menu_model_.GetTypeAt(menu_model_.GetItemCount() - 1) != |
| 542 ui::MenuModel::TYPE_SEPARATOR) | 542 ui::MenuModel::TYPE_SEPARATOR) |
| 543 menu_model_.AddSeparator(ui::NORMAL_SEPARATOR); | 543 menu_model_.AddSeparator(ui::NORMAL_SEPARATOR); |
| 544 | 544 |
| 545 menu_model_.AddItemWithStringId(IDC_CONTENT_CONTEXT_RELOAD_PACKAGED_APP, | 545 menu_model_.AddItemWithStringId(IDC_CONTENT_CONTEXT_RELOAD_PACKAGED_APP, |
| 546 IDS_CONTENT_CONTEXT_RELOAD_PACKAGED_APP); | 546 IDS_CONTENT_CONTEXT_RELOAD_PACKAGED_APP); |
| (...skipping 1310 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
| 1857 source_web_contents_->GetRenderViewHost()-> | 1857 source_web_contents_->GetRenderViewHost()-> |
| 1858 ExecuteMediaPlayerActionAtLocation(location, action); | 1858 ExecuteMediaPlayerActionAtLocation(location, action); |
| 1859 } | 1859 } |
| 1860 | 1860 |
| 1861 void RenderViewContextMenu::PluginActionAt( | 1861 void RenderViewContextMenu::PluginActionAt( |
| 1862 const gfx::Point& location, | 1862 const gfx::Point& location, |
| 1863 const WebPluginAction& action) { | 1863 const WebPluginAction& action) { |
| 1864 source_web_contents_->GetRenderViewHost()-> | 1864 source_web_contents_->GetRenderViewHost()-> |
| 1865 ExecutePluginActionAtLocation(location, action); | 1865 ExecutePluginActionAtLocation(location, action); |
| 1866 } | 1866 } |
| OLD | NEW |