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

Side by Side Diff: Source/WebKit/chromium/src/WebViewImpl.cpp

Issue 14185003: Use ContextMenu code path that was guarded by CROSS_PLATFORM_CONTEXT_MENU (Closed) Base URL: https://chromium.googlesource.com/chromium/blink.git@master
Patch Set: Use ContextMenu code path that was guarded by CROSS_PLATFORM_CONTEXT_MENU Created 7 years, 8 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 /* 1 /*
2 * Copyright (C) 2011, 2012 Google Inc. All rights reserved. 2 * Copyright (C) 2011, 2012 Google Inc. All rights reserved.
3 * 3 *
4 * Redistribution and use in source and binary forms, with or without 4 * Redistribution and use in source and binary forms, with or without
5 * modification, are permitted provided that the following conditions are 5 * modification, are permitted provided that the following conditions are
6 * met: 6 * met:
7 * 7 *
8 * * Redistributions of source code must retain the above copyright 8 * * Redistributions of source code must retain the above copyright
9 * notice, this list of conditions and the following disclaimer. 9 * notice, this list of conditions and the following disclaimer.
10 * * Redistributions in binary form must reproduce the above 10 * * Redistributions in binary form must reproduce the above
(...skipping 3498 matching lines...) Expand 10 before | Expand all | Expand 10 after
3509 #endif 3509 #endif
3510 } 3510 }
3511 3511
3512 void WebViewImpl::performCustomContextMenuAction(unsigned action) 3512 void WebViewImpl::performCustomContextMenuAction(unsigned action)
3513 { 3513 {
3514 if (!m_page) 3514 if (!m_page)
3515 return; 3515 return;
3516 ContextMenu* menu = m_page->contextMenuController()->contextMenu(); 3516 ContextMenu* menu = m_page->contextMenuController()->contextMenu();
3517 if (!menu) 3517 if (!menu)
3518 return; 3518 return;
3519 ContextMenuItem* item = menu->itemWithAction(static_cast<ContextMenuAction>( ContextMenuItemBaseCustomTag + action)); 3519 const ContextMenuItem* item = menu->itemWithAction(static_cast<ContextMenuAc tion>(ContextMenuItemBaseCustomTag + action));
3520 if (item) 3520 if (item)
3521 m_page->contextMenuController()->contextMenuItemSelected(item); 3521 m_page->contextMenuController()->contextMenuItemSelected(item);
3522 m_page->contextMenuController()->clearContextMenu(); 3522 m_page->contextMenuController()->clearContextMenu();
3523 } 3523 }
3524 3524
3525 void WebViewImpl::showContextMenu() 3525 void WebViewImpl::showContextMenu()
3526 { 3526 {
3527 if (!page()) 3527 if (!page())
3528 return; 3528 return;
3529 3529
(...skipping 661 matching lines...) Expand 10 before | Expand all | Expand 10 after
4191 } 4191 }
4192 4192
4193 bool WebViewImpl::shouldDisableDesktopWorkarounds() 4193 bool WebViewImpl::shouldDisableDesktopWorkarounds()
4194 { 4194 {
4195 ViewportArguments arguments = mainFrameImpl()->frame()->document()->viewport Arguments(); 4195 ViewportArguments arguments = mainFrameImpl()->frame()->document()->viewport Arguments();
4196 return arguments.width == ViewportArguments::ValueDeviceWidth || !arguments. userZoom 4196 return arguments.width == ViewportArguments::ValueDeviceWidth || !arguments. userZoom
4197 || (arguments.minZoom == arguments.maxZoom && arguments.minZoom != Viewp ortArguments::ValueAuto); 4197 || (arguments.minZoom == arguments.maxZoom && arguments.minZoom != Viewp ortArguments::ValueAuto);
4198 } 4198 }
4199 4199
4200 } // namespace WebKit 4200 } // namespace WebKit
OLDNEW
« no previous file with comments | « Source/WebKit/chromium/src/ContextMenuClientImpl.cpp ('k') | Source/bindings/v8/custom/V8InspectorFrontendHostCustom.cpp » ('j') | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698