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

Side by Side Diff: third_party/WebKit/Source/core/loader/EmptyClients.cpp

Issue 2754673002: [scheduler] Split suspendable tq from unthrottled tq. (Closed)
Patch Set: For the moment make only database access tasks suspendable Created 3 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) 2006 Eric Seidel <eric@webkit.org> 2 * Copyright (C) 2006 Eric Seidel <eric@webkit.org>
3 * Copyright (C) 2008, 2009, 2012 Apple Inc. All rights reserved. 3 * Copyright (C) 2008, 2009, 2012 Apple Inc. All rights reserved.
4 * Copyright (C) Research In Motion Limited 2011. All rights reserved. 4 * Copyright (C) Research In Motion Limited 2011. All rights reserved.
5 * 5 *
6 * Redistribution and use in source and binary forms, with or without 6 * Redistribution and use in source and binary forms, with or without
7 * modification, are permitted provided that the following conditions 7 * modification, are permitted provided that the following conditions
8 * are met: 8 * are met:
9 * 1. Redistributions of source code must retain the above copyright 9 * 1. Redistributions of source code must retain the above copyright
10 * notice, this list of conditions and the following disclaimer. 10 * notice, this list of conditions and the following disclaimer.
(...skipping 57 matching lines...) Expand 10 before | Expand all | Expand 10 after
68 void disconnectClient() override {} 68 void disconnectClient() override {}
69 }; 69 };
70 70
71 class EmptyFrameScheduler : public WebFrameScheduler { 71 class EmptyFrameScheduler : public WebFrameScheduler {
72 public: 72 public:
73 EmptyFrameScheduler() { DCHECK(isMainThread()); } 73 EmptyFrameScheduler() { DCHECK(isMainThread()); }
74 void setFrameVisible(bool) override {} 74 void setFrameVisible(bool) override {}
75 RefPtr<WebTaskRunner> loadingTaskRunner() override; 75 RefPtr<WebTaskRunner> loadingTaskRunner() override;
76 RefPtr<WebTaskRunner> timerTaskRunner() override; 76 RefPtr<WebTaskRunner> timerTaskRunner() override;
77 RefPtr<WebTaskRunner> unthrottledTaskRunner() override; 77 RefPtr<WebTaskRunner> unthrottledTaskRunner() override;
78 RefPtr<WebTaskRunner> suspendableTaskRunner() override;
78 }; 79 };
79 80
80 RefPtr<WebTaskRunner> EmptyFrameScheduler::loadingTaskRunner() { 81 RefPtr<WebTaskRunner> EmptyFrameScheduler::loadingTaskRunner() {
81 return Platform::current()->mainThread()->getWebTaskRunner(); 82 return Platform::current()->mainThread()->getWebTaskRunner();
82 } 83 }
83 84
84 RefPtr<WebTaskRunner> EmptyFrameScheduler::timerTaskRunner() { 85 RefPtr<WebTaskRunner> EmptyFrameScheduler::timerTaskRunner() {
85 return Platform::current()->mainThread()->getWebTaskRunner(); 86 return Platform::current()->mainThread()->getWebTaskRunner();
86 } 87 }
87 88
88 RefPtr<WebTaskRunner> EmptyFrameScheduler::unthrottledTaskRunner() { 89 RefPtr<WebTaskRunner> EmptyFrameScheduler::unthrottledTaskRunner() {
89 return Platform::current()->mainThread()->getWebTaskRunner(); 90 return Platform::current()->mainThread()->getWebTaskRunner();
90 } 91 }
91 92
93 RefPtr<WebTaskRunner> EmptyFrameScheduler::suspendableTaskRunner() {
94 return Platform::current()->mainThread()->getWebTaskRunner();
95 }
96
92 PopupMenu* EmptyChromeClient::openPopupMenu(LocalFrame&, HTMLSelectElement&) { 97 PopupMenu* EmptyChromeClient::openPopupMenu(LocalFrame&, HTMLSelectElement&) {
93 return new EmptyPopupMenu(); 98 return new EmptyPopupMenu();
94 } 99 }
95 100
96 ColorChooser* EmptyChromeClient::openColorChooser(LocalFrame*, 101 ColorChooser* EmptyChromeClient::openColorChooser(LocalFrame*,
97 ColorChooserClient*, 102 ColorChooserClient*,
98 const Color&) { 103 const Color&) {
99 return nullptr; 104 return nullptr;
100 } 105 }
101 106
(...skipping 90 matching lines...) Expand 10 before | Expand all | Expand 10 after
192 197
193 std::unique_ptr<WebApplicationCacheHost> 198 std::unique_ptr<WebApplicationCacheHost>
194 EmptyLocalFrameClient::createApplicationCacheHost( 199 EmptyLocalFrameClient::createApplicationCacheHost(
195 WebApplicationCacheHostClient*) { 200 WebApplicationCacheHostClient*) {
196 return nullptr; 201 return nullptr;
197 } 202 }
198 203
199 EmptyRemoteFrameClient::EmptyRemoteFrameClient() = default; 204 EmptyRemoteFrameClient::EmptyRemoteFrameClient() = default;
200 205
201 } // namespace blink 206 } // namespace blink
OLDNEW
« no previous file with comments | « third_party/WebKit/Source/core/dom/TaskRunnerHelper.cpp ('k') | third_party/WebKit/Source/platform/WebFrameScheduler.h » ('j') | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698