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

Side by Side Diff: content/renderer/render_thread.cc

Issue 7825026: Revert "Currently, base/timer.cc calls PostTask with FROM_HERE as the Location, (Closed) Base URL: svn://svn.chromium.org/chrome/trunk/src
Patch Set: Created 9 years, 3 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 | « content/renderer/render_process_impl.cc ('k') | content/renderer/render_view.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 "content/renderer/render_thread.h" 5 #include "content/renderer/render_thread.h"
6 6
7 #include <algorithm> 7 #include <algorithm>
8 #include <limits> 8 #include <limits>
9 #include <map> 9 #include <map>
10 #include <vector> 10 #include <vector>
(...skipping 670 matching lines...) Expand 10 before | Expand all | Expand 10 after
681 // kInitialIdleHandlerDelayS in RenderThread::WidgetHidden. 681 // kInitialIdleHandlerDelayS in RenderThread::WidgetHidden.
682 ScheduleIdleHandler(idle_notification_delay_in_s_ + 682 ScheduleIdleHandler(idle_notification_delay_in_s_ +
683 1.0 / (idle_notification_delay_in_s_ + 2.0)); 683 1.0 / (idle_notification_delay_in_s_ + 2.0));
684 684
685 FOR_EACH_OBSERVER(RenderProcessObserver, observers_, IdleNotification()); 685 FOR_EACH_OBSERVER(RenderProcessObserver, observers_, IdleNotification());
686 } 686 }
687 687
688 void RenderThread::ScheduleIdleHandler(double initial_delay_s) { 688 void RenderThread::ScheduleIdleHandler(double initial_delay_s) {
689 idle_notification_delay_in_s_ = initial_delay_s; 689 idle_notification_delay_in_s_ = initial_delay_s;
690 idle_timer_.Stop(); 690 idle_timer_.Stop();
691 idle_timer_.Start(FROM_HERE, 691 idle_timer_.Start(
692 base::TimeDelta::FromSeconds(static_cast<int64>(initial_delay_s)), 692 base::TimeDelta::FromSeconds(static_cast<int64>(initial_delay_s)),
693 this, &RenderThread::IdleHandler); 693 this, &RenderThread::IdleHandler);
694 } 694 }
695 695
696 void RenderThread::OnPurgePluginListCache(bool reload_pages) { 696 void RenderThread::OnPurgePluginListCache(bool reload_pages) {
697 EnsureWebKitInitialized(); 697 EnsureWebKitInitialized();
698 // The call below will cause a GetPlugins call with refresh=true, but at this 698 // The call below will cause a GetPlugins call with refresh=true, but at this
699 // point we already know that the browser has refreshed its list, so disable 699 // point we already know that the browser has refreshed its list, so disable
700 // refresh temporarily to prevent each renderer process causing the list to be 700 // refresh temporarily to prevent each renderer process causing the list to be
701 // regenerated. 701 // regenerated.
(...skipping 19 matching lines...) Expand all
721 721
722 void RenderThread::RegisterExtension(v8::Extension* extension) { 722 void RenderThread::RegisterExtension(v8::Extension* extension) {
723 WebScriptController::registerExtension(extension); 723 WebScriptController::registerExtension(extension);
724 v8_extensions_.insert(extension->name()); 724 v8_extensions_.insert(extension->name());
725 } 725 }
726 726
727 bool RenderThread::IsRegisteredExtension( 727 bool RenderThread::IsRegisteredExtension(
728 const std::string& v8_extension_name) const { 728 const std::string& v8_extension_name) const {
729 return v8_extensions_.find(v8_extension_name) != v8_extensions_.end(); 729 return v8_extensions_.find(v8_extension_name) != v8_extensions_.end();
730 } 730 }
OLDNEW
« no previous file with comments | « content/renderer/render_process_impl.cc ('k') | content/renderer/render_view.cc » ('j') | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698