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

Side by Side Diff: components/renderer_context_menu/render_view_context_menu_base.cc

Issue 2177023002: Remove spellchecker feedback. (Closed) Base URL: https://chromium.googlesource.com/chromium/src.git@master
Patch Set: Fix compile Created 4 years, 4 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
OLDNEW
1 // Copyright 2014 The Chromium Authors. All rights reserved. 1 // Copyright 2014 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 "components/renderer_context_menu/render_view_context_menu_base.h" 5 #include "components/renderer_context_menu/render_view_context_menu_base.h"
6 6
7 #include <algorithm> 7 #include <algorithm>
8 #include <utility> 8 #include <utility>
9 #include <vector> 9 #include <vector>
10 10
(...skipping 341 matching lines...) Expand 10 before | Expand all | Expand 10 after
352 void RenderViewContextMenuBase::MenuClosed(ui::SimpleMenuModel* source) { 352 void RenderViewContextMenuBase::MenuClosed(ui::SimpleMenuModel* source) {
353 // Ignore notifications from submenus. 353 // Ignore notifications from submenus.
354 if (source != &menu_model_) 354 if (source != &menu_model_)
355 return; 355 return;
356 356
357 content::RenderWidgetHostView* view = 357 content::RenderWidgetHostView* view =
358 source_web_contents_->GetRenderWidgetHostView(); 358 source_web_contents_->GetRenderWidgetHostView();
359 if (view) 359 if (view)
360 view->SetShowingContextMenu(false); 360 view->SetShowingContextMenu(false);
361 source_web_contents_->NotifyContextMenuClosed(params_.custom_context); 361 source_web_contents_->NotifyContextMenuClosed(params_.custom_context);
362
363 if (!command_executed_) {
364 FOR_EACH_OBSERVER(RenderViewContextMenuObserver,
365 observers_,
366 OnMenuCancel());
367 }
368 } 362 }
369 363
370 RenderFrameHost* RenderViewContextMenuBase::GetRenderFrameHost() { 364 RenderFrameHost* RenderViewContextMenuBase::GetRenderFrameHost() {
371 return RenderFrameHost::FromID(render_process_id_, render_frame_id_); 365 return RenderFrameHost::FromID(render_process_id_, render_frame_id_);
372 } 366 }
373 367
374 // Controller functions -------------------------------------------------------- 368 // Controller functions --------------------------------------------------------
375 369
376 void RenderViewContextMenuBase::OpenURL( 370 void RenderViewContextMenuBase::OpenURL(
377 const GURL& url, const GURL& referring_url, 371 const GURL& url, const GURL& referring_url,
(...skipping 27 matching lines...) Expand all
405 NotifyURLOpened(url, new_contents); 399 NotifyURLOpened(url, new_contents);
406 } 400 }
407 401
408 bool RenderViewContextMenuBase::IsCustomItemChecked(int id) const { 402 bool RenderViewContextMenuBase::IsCustomItemChecked(int id) const {
409 return IsCustomItemCheckedInternal(params_.custom_items, id); 403 return IsCustomItemCheckedInternal(params_.custom_items, id);
410 } 404 }
411 405
412 bool RenderViewContextMenuBase::IsCustomItemEnabled(int id) const { 406 bool RenderViewContextMenuBase::IsCustomItemEnabled(int id) const {
413 return IsCustomItemEnabledInternal(params_.custom_items, id); 407 return IsCustomItemEnabledInternal(params_.custom_items, id);
414 } 408 }
OLDNEW

Powered by Google App Engine
This is Rietveld 408576698