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

Side by Side Diff: webkit/glue/chrome_client_impl.cc

Issue 276059: Kill WebViewDelegate::WasOpenedByUserGesture, and instead have... (Closed) Base URL: svn://svn.chromium.org/chrome/trunk/src/
Patch Set: Created 11 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 unified diff | Download patch | Annotate | Revision Log
« no previous file with comments | « chrome/renderer/render_view.cc ('k') | webkit/glue/webview_delegate.h » ('j') | no next file with comments »
Toggle Intra-line Diffs ('i') | Expand Comments ('e') | Collapse Comments ('c') | Show Comments Hide Comments ('s')
OLDNEW
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 "config.h" 5 #include "config.h"
6 6
7 #include "AccessibilityObject.h" 7 #include "AccessibilityObject.h"
8 #include "AXObjectCache.h" 8 #include "AXObjectCache.h"
9 #include "CharacterNames.h" 9 #include "CharacterNames.h"
10 #include "Console.h" 10 #include "Console.h"
(...skipping 238 matching lines...) Expand 10 before | Expand all | Expand 10 after
249 if (delegate) { 249 if (delegate) {
250 // If our default configuration was modified by a script or wasn't 250 // If our default configuration was modified by a script or wasn't
251 // created by a user gesture, then show as a popup. Else, let this 251 // created by a user gesture, then show as a popup. Else, let this
252 // new window be opened as a toplevel window. 252 // new window be opened as a toplevel window.
253 // 253 //
254 bool as_popup = 254 bool as_popup =
255 !toolbars_visible_ || 255 !toolbars_visible_ ||
256 !statusbar_visible_ || 256 !statusbar_visible_ ||
257 !scrollbars_visible_ || 257 !scrollbars_visible_ ||
258 !menubar_visible_ || 258 !menubar_visible_ ||
259 !resizable_ || 259 !resizable_;
260 !delegate->WasOpenedByUserGesture();
261 260
262 WebNavigationPolicy policy = WebKit::WebNavigationPolicyNewForegroundTab; 261 WebNavigationPolicy policy = WebKit::WebNavigationPolicyNewForegroundTab;
263 if (as_popup) 262 if (as_popup)
264 policy = WebKit::WebNavigationPolicyNewPopup; 263 policy = WebKit::WebNavigationPolicyNewPopup;
265 if (CurrentEventShouldCauseBackgroundTab( 264 if (CurrentEventShouldCauseBackgroundTab(
266 WebViewImpl::current_input_event())) 265 WebViewImpl::current_input_event()))
267 policy = WebKit::WebNavigationPolicyNewBackgroundTab; 266 policy = WebKit::WebNavigationPolicyNewBackgroundTab;
268 267
269 delegate->show(policy); 268 delegate->show(policy);
270 } 269 }
(...skipping 350 matching lines...) Expand 10 before | Expand all | Expand 10 after
621 info->itemHeight = popup_container->menuItemHeight(); 620 info->itemHeight = popup_container->menuItemHeight();
622 info->selectedIndex = popup_container->selectedIndex(); 621 info->selectedIndex = popup_container->selectedIndex();
623 info->items.swap(output_items); 622 info->items.swap(output_items);
624 } 623 }
625 624
626 #if ENABLE(NOTIFICATIONS) 625 #if ENABLE(NOTIFICATIONS)
627 WebCore::NotificationPresenter* ChromeClientImpl::notificationPresenter() const { 626 WebCore::NotificationPresenter* ChromeClientImpl::notificationPresenter() const {
628 return webview_->GetNotificationPresenter(); 627 return webview_->GetNotificationPresenter();
629 } 628 }
630 #endif 629 #endif
OLDNEW
« no previous file with comments | « chrome/renderer/render_view.cc ('k') | webkit/glue/webview_delegate.h » ('j') | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698