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

Side by Side Diff: third_party/WebKit/Source/core/dom/ActiveDOMObject.cpp

Issue 1133713008: [WIP] Migrate hasPendingActivity from ActiveDOMObject to ScriptWrappable. Base URL: https://chromium.googlesource.com/chromium/blink.git@master
Patch Set: Review Comments Created 5 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
OLDNEW
1 /* 1 /*
2 * Copyright (C) 2008 Apple Inc. All Rights Reserved. 2 * Copyright (C) 2008 Apple Inc. All Rights Reserved.
3 * 3 *
4 * Redistribution and use in source and binary forms, with or without 4 * Redistribution and use in source and binary forms, with or without
5 * modification, are permitted provided that the following conditions 5 * modification, are permitted provided that the following conditions
6 * are met: 6 * are met:
7 * 1. Redistributions of source code must retain the above copyright 7 * 1. Redistributions of source code must retain the above copyright
8 * notice, this list of conditions and the following disclaimer. 8 * notice, this list of conditions and the following disclaimer.
9 * 2. Redistributions in binary form must reproduce the above copyright 9 * 2. Redistributions in binary form must reproduce the above copyright
10 * notice, this list of conditions and the following disclaimer in the 10 * notice, this list of conditions and the following disclaimer in the
(...skipping 51 matching lines...) Expand 10 before | Expand all | Expand 10 after
62 void ActiveDOMObject::suspendIfNeeded() 62 void ActiveDOMObject::suspendIfNeeded()
63 { 63 {
64 #if ENABLE(ASSERT) 64 #if ENABLE(ASSERT)
65 ASSERT(!m_suspendIfNeededCalled); 65 ASSERT(!m_suspendIfNeededCalled);
66 m_suspendIfNeededCalled = true; 66 m_suspendIfNeededCalled = true;
67 #endif 67 #endif
68 if (ExecutionContext* context = executionContext()) 68 if (ExecutionContext* context = executionContext())
69 context->suspendActiveDOMObjectIfNeeded(this); 69 context->suspendActiveDOMObjectIfNeeded(this);
70 } 70 }
71 71
72 bool ActiveDOMObject::hasPendingActivity() const
73 {
74 return false;
75 }
76
77 void ActiveDOMObject::suspend() 72 void ActiveDOMObject::suspend()
78 { 73 {
79 } 74 }
80 75
81 void ActiveDOMObject::resume() 76 void ActiveDOMObject::resume()
82 { 77 {
83 } 78 }
84 79
85 void ActiveDOMObject::stop() 80 void ActiveDOMObject::stop()
86 { 81 {
(...skipping 10 matching lines...) Expand all
97 92
98 if (context->activeDOMObjectsAreSuspended()) { 93 if (context->activeDOMObjectsAreSuspended()) {
99 suspend(); 94 suspend();
100 return; 95 return;
101 } 96 }
102 97
103 resume(); 98 resume();
104 } 99 }
105 100
106 } // namespace blink 101 } // namespace blink
OLDNEW

Powered by Google App Engine
This is Rietveld 408576698