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

Side by Side Diff: chrome/renderer/render_view.cc

Issue 6546080: Initialize the minimum timer interval upon RenderView construction,... (Closed) Base URL: svn://svn.chromium.org/chrome/trunk/src/
Patch Set: Created 9 years, 10 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 | « no previous file | webkit/glue/webpreferences.cc » ('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) 2011 The Chromium Authors. All rights reserved. 1 // Copyright (c) 2011 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/renderer/render_view.h" 5 #include "chrome/renderer/render_view.h"
6 6
7 #include <algorithm> 7 #include <algorithm>
8 #include <cmath> 8 #include <cmath>
9 #include <string> 9 #include <string>
10 #include <vector> 10 #include <vector>
(...skipping 608 matching lines...) Expand 10 before | Expand all | Expand 10 after
619 new PasswordAutoFillManager(this); 619 new PasswordAutoFillManager(this);
620 AutoFillAgent* autofill_agent = new AutoFillAgent(this, 620 AutoFillAgent* autofill_agent = new AutoFillAgent(this,
621 password_autofill_manager); 621 password_autofill_manager);
622 622
623 webwidget_ = WebView::create(this, devtools_agent_, autofill_agent); 623 webwidget_ = WebView::create(this, devtools_agent_, autofill_agent);
624 g_view_map.Get().insert(std::make_pair(webview(), this)); 624 g_view_map.Get().insert(std::make_pair(webview(), this));
625 webkit_preferences_.Apply(webview()); 625 webkit_preferences_.Apply(webview());
626 webview()->initializeMainFrame(this); 626 webview()->initializeMainFrame(this);
627 if (!frame_name.empty()) 627 if (!frame_name.empty())
628 webview()->mainFrame()->setName(frame_name); 628 webview()->mainFrame()->setName(frame_name);
629 webview()->settings()->setMinimumTimerInterval(
630 is_hidden() ? webkit_glue::kBackgroundTabTimerInterval :
631 webkit_glue::kForegroundTabTimerInterval);
darin (slow to review) 2011/02/23 01:00:12 nit: it is more common to indent this line so that
629 632
630 OnSetRendererPrefs(renderer_prefs); 633 OnSetRendererPrefs(renderer_prefs);
631 634
632 render_thread_->AddRoute(routing_id_, this); 635 render_thread_->AddRoute(routing_id_, this);
633 // Take a reference on behalf of the RenderThread. This will be balanced 636 // Take a reference on behalf of the RenderThread. This will be balanced
634 // when we receive ViewMsg_Close. 637 // when we receive ViewMsg_Close.
635 AddRef(); 638 AddRef();
636 639
637 // If this is a popup, we must wait for the CreatingNew_ACK message before 640 // If this is a popup, we must wait for the CreatingNew_ACK message before
638 // completing initialization. Otherwise, we can finish it now. 641 // completing initialization. Otherwise, we can finish it now.
(...skipping 5068 matching lines...) Expand 10 before | Expand all | Expand 10 after
5707 } 5710 }
5708 } 5711 }
5709 5712
5710 void RenderView::OnContextMenuClosed( 5713 void RenderView::OnContextMenuClosed(
5711 const webkit_glue::CustomContextMenuContext& custom_context) { 5714 const webkit_glue::CustomContextMenuContext& custom_context) {
5712 if (custom_context.is_pepper_menu) 5715 if (custom_context.is_pepper_menu)
5713 pepper_delegate_.OnContextMenuClosed(custom_context); 5716 pepper_delegate_.OnContextMenuClosed(custom_context);
5714 else 5717 else
5715 context_menu_node_.reset(); 5718 context_menu_node_.reset();
5716 } 5719 }
OLDNEW
« no previous file with comments | « no previous file | webkit/glue/webpreferences.cc » ('j') | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698