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

Unified Diff: chrome/browser/tab_contents/render_view_context_menu.cc

Issue 11048045: Allow settings dialog to be opened via the app launcher, as a packaged app. (Closed) Base URL: http://git.chromium.org/chromium/src.git@master
Patch Set: license stanza Created 8 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 side-by-side diff with in-line comments
Download patch
« no previous file with comments | « chrome/browser/resources/settings_app/settings_app.js ('k') | chrome/browser/ui/extensions/shell_window.h » ('j') | no next file with comments »
Expand Comments ('e') | Collapse Comments ('c') | Show Comments Hide Comments ('s')
Index: chrome/browser/tab_contents/render_view_context_menu.cc
diff --git a/chrome/browser/tab_contents/render_view_context_menu.cc b/chrome/browser/tab_contents/render_view_context_menu.cc
index 1cff6df1aeec448330f4d791cb3e9a28d9f456ef..d4c8b15fb41833fc5d051d86a3bb6231eb394258 100644
--- a/chrome/browser/tab_contents/render_view_context_menu.cc
+++ b/chrome/browser/tab_contents/render_view_context_menu.cc
@@ -501,7 +501,11 @@ const Extension* RenderViewContextMenu::GetExtension() const {
void RenderViewContextMenu::AppendPlatformAppItems() {
const Extension* platform_app = GetExtension();
- DCHECK(platform_app);
+
+ // The RVH might be for a process sandboxed from the extension.
+ if (!platform_app)
+ return;
+
DCHECK(platform_app->is_platform_app());
bool has_selection = !params_.selection_text.empty();
« no previous file with comments | « chrome/browser/resources/settings_app/settings_app.js ('k') | chrome/browser/ui/extensions/shell_window.h » ('j') | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698