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

Side by Side Diff: Source/core/dom/MainThreadTaskRunnerTest.cpp

Issue 68593002: Remove wrong overload. (Closed) Base URL: svn://svn.chromium.org/blink/trunk
Patch Set: Created 7 years, 1 month 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 | no next file » | no next file with comments »
Toggle Intra-line Diffs ('i') | Expand Comments ('e') | Collapse Comments ('c') | Show Comments Hide Comments ('s')
OLDNEW
1 /* 1 /*
2 * Copyright (C) 2008 Apple Inc. All Rights Reserved. 2 * Copyright (C) 2008 Apple Inc. All Rights Reserved.
3 * Copyright (C) 2013 Google Inc. All Rights Reserved. 3 * Copyright (C) 2013 Google Inc. All Rights Reserved.
4 * 4 *
5 * Redistribution and use in source and binary forms, with or without 5 * Redistribution and use in source and binary forms, with or without
6 * modification, are permitted provided that the following conditions 6 * modification, are permitted provided that the following conditions
7 * are met: 7 * are met:
8 * 1. Redistributions of source code must retain the above copyright 8 * 1. Redistributions of source code must retain the above copyright
9 * notice, this list of conditions and the following disclaimer. 9 * notice, this list of conditions and the following disclaimer.
10 * 2. Redistributions in binary form must reproduce the above copyright 10 * 2. Redistributions in binary form must reproduce the above copyright
(...skipping 34 matching lines...) Expand 10 before | Expand all | Expand 10 after
45 virtual bool enqueueEvent(PassRefPtr<Event>) OVERRIDE { return true; } 45 virtual bool enqueueEvent(PassRefPtr<Event>) OVERRIDE { return true; }
46 virtual bool cancelEvent(Event*) OVERRIDE { return true; } 46 virtual bool cancelEvent(Event*) OVERRIDE { return true; }
47 virtual void close() OVERRIDE { } 47 virtual void close() OVERRIDE { }
48 }; 48 };
49 49
50 class NullExecutionContext : public ExecutionContext, public RefCounted<NullExec utionContext> { 50 class NullExecutionContext : public ExecutionContext, public RefCounted<NullExec utionContext> {
51 public: 51 public:
52 using RefCounted<NullExecutionContext>::ref; 52 using RefCounted<NullExecutionContext>::ref;
53 using RefCounted<NullExecutionContext>::deref; 53 using RefCounted<NullExecutionContext>::deref;
54 54
55 virtual void refExecutionContext() OVERRIDE { ref(); }
56 virtual void derefExecutionContext() OVERRIDE { deref(); }
57 virtual EventQueue* eventQueue() const OVERRIDE { return m_queue.get(); } 55 virtual EventQueue* eventQueue() const OVERRIDE { return m_queue.get(); }
58 virtual bool tasksNeedSuspension() { return m_tasksNeedSuspension; } 56 virtual bool tasksNeedSuspension() { return m_tasksNeedSuspension; }
59 57
60 void setTasksNeedSuspention(bool flag) { m_tasksNeedSuspension = flag; } 58 void setTasksNeedSuspention(bool flag) { m_tasksNeedSuspension = flag; }
61 59
62 NullExecutionContext(); 60 NullExecutionContext();
63 61
64 private: 62 private:
65 bool m_tasksNeedSuspension; 63 bool m_tasksNeedSuspension;
66 OwnPtr<EventQueue> m_queue; 64 OwnPtr<EventQueue> m_queue;
(...skipping 63 matching lines...) Expand 10 before | Expand all | Expand 10 after
130 bool isMarked = false; 128 bool isMarked = false;
131 129
132 context->setTasksNeedSuspention(true); 130 context->setTasksNeedSuspention(true);
133 runner->postTask(MarkingBooleanTask::create(&isMarked)); 131 runner->postTask(MarkingBooleanTask::create(&isMarked));
134 runner.clear(); 132 runner.clear();
135 WebCore::testing::runPendingTasks(); 133 WebCore::testing::runPendingTasks();
136 EXPECT_FALSE(isMarked); 134 EXPECT_FALSE(isMarked);
137 } 135 }
138 136
139 } 137 }
OLDNEW
« no previous file with comments | « no previous file | no next file » | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698