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

Side by Side Diff: content/child/child_thread_impl.h

Issue 1133143003: [Android] Suspend shared timers for hidden renderers (Closed) Base URL: https://chromium.googlesource.com/chromium/src.git@input_remove_suspend
Patch Set: Move logic to the scheduler Created 5 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
OLDNEW
1 // Copyright (c) 2012 The Chromium Authors. All rights reserved. 1 // Copyright (c) 2012 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 #ifndef CONTENT_CHILD_CHILD_THREAD_IMPL_H_ 5 #ifndef CONTENT_CHILD_CHILD_THREAD_IMPL_H_
6 #define CONTENT_CHILD_CHILD_THREAD_IMPL_H_ 6 #define CONTENT_CHILD_CHILD_THREAD_IMPL_H_
7 7
8 #include <string> 8 #include <string>
9 9
10 #include "base/basictypes.h" 10 #include "base/basictypes.h"
(...skipping 173 matching lines...) Expand 10 before | Expand all | Expand 10 after
184 return mojo_application_->service_registry(); 184 return mojo_application_->service_registry();
185 } 185 }
186 186
187 protected: 187 protected:
188 friend class ChildProcess; 188 friend class ChildProcess;
189 189
190 // Called when the process refcount is 0. 190 // Called when the process refcount is 0.
191 void OnProcessFinalRelease(); 191 void OnProcessFinalRelease();
192 192
193 virtual bool OnControlMessageReceived(const IPC::Message& msg); 193 virtual bool OnControlMessageReceived(const IPC::Message& msg);
194 virtual void OnProcessBackgrounded(bool backgrounded);
194 195
195 void set_on_channel_error_called(bool on_channel_error_called) { 196 void set_on_channel_error_called(bool on_channel_error_called) {
196 on_channel_error_called_ = on_channel_error_called; 197 on_channel_error_called_ = on_channel_error_called;
197 } 198 }
198 199
199 // IPC::Listener implementation: 200 // IPC::Listener implementation:
200 bool OnMessageReceived(const IPC::Message& msg) override; 201 bool OnMessageReceived(const IPC::Message& msg) override;
201 void OnChannelConnected(int32 peer_pid) override; 202 void OnChannelConnected(int32 peer_pid) override;
202 void OnChannelError() override; 203 void OnChannelError() override;
203 204
(...skipping 15 matching lines...) Expand all
219 220
220 // We create the channel first without connecting it so we can add filters 221 // We create the channel first without connecting it so we can add filters
221 // prior to any messages being received, then connect it afterwards. 222 // prior to any messages being received, then connect it afterwards.
222 void ConnectChannel(bool use_mojo_channel); 223 void ConnectChannel(bool use_mojo_channel);
223 224
224 // IPC message handlers. 225 // IPC message handlers.
225 void OnShutdown(); 226 void OnShutdown();
226 void OnSetProfilerStatus(tracked_objects::ThreadData::Status status); 227 void OnSetProfilerStatus(tracked_objects::ThreadData::Status status);
227 void OnGetChildProfilerData(int sequence_number, int current_profiling_phase); 228 void OnGetChildProfilerData(int sequence_number, int current_profiling_phase);
228 void OnProfilingPhaseCompleted(int profiling_phase); 229 void OnProfilingPhaseCompleted(int profiling_phase);
229 void OnProcessBackgrounded(bool background);
230 #ifdef IPC_MESSAGE_LOG_ENABLED 230 #ifdef IPC_MESSAGE_LOG_ENABLED
231 void OnSetIPCLoggingEnabled(bool enable); 231 void OnSetIPCLoggingEnabled(bool enable);
232 #endif 232 #endif
233 #if defined(USE_TCMALLOC) 233 #if defined(USE_TCMALLOC)
234 void OnGetTcmallocStats(); 234 void OnGetTcmallocStats();
235 #endif 235 #endif
236 236
237 void EnsureConnected(); 237 void EnsureConnected();
238 238
239 scoped_ptr<MojoApplication> mojo_application_; 239 scoped_ptr<MojoApplication> mojo_application_;
(...skipping 87 matching lines...) Expand 10 before | Expand all | Expand 10 after
327 327
328 private: 328 private:
329 struct Options options_; 329 struct Options options_;
330 330
331 DISALLOW_COPY_AND_ASSIGN(Builder); 331 DISALLOW_COPY_AND_ASSIGN(Builder);
332 }; 332 };
333 333
334 } // namespace content 334 } // namespace content
335 335
336 #endif // CONTENT_CHILD_CHILD_THREAD_IMPL_H_ 336 #endif // CONTENT_CHILD_CHILD_THREAD_IMPL_H_
OLDNEW

Powered by Google App Engine
This is Rietveld 408576698