| OLD | NEW | 
|    1 /* |    1 /* | 
|    2  * Copyright (C) 2013 Google Inc. All Rights Reserved. |    2  * Copyright (C) 2013 Google 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 81 matching lines...) Expand 10 before | Expand all | Expand 10 after  Loading... | 
|   92 { |   92 { | 
|   93     ASSERT(!m_suspended); |   93     ASSERT(!m_suspended); | 
|   94     m_pendingTasksTimer.stop(); |   94     m_pendingTasksTimer.stop(); | 
|   95     m_suspended = true; |   95     m_suspended = true; | 
|   96 } |   96 } | 
|   97  |   97  | 
|   98 void MainThreadTaskRunner::resume() |   98 void MainThreadTaskRunner::resume() | 
|   99 { |   99 { | 
|  100     ASSERT(m_suspended); |  100     ASSERT(m_suspended); | 
|  101     if (!m_pendingTasks.isEmpty()) |  101     if (!m_pendingTasks.isEmpty()) | 
|  102         m_pendingTasksTimer.startOneShot(0); |  102         m_pendingTasksTimer.startOneShot(0, FROM_HERE); | 
|  103  |  103  | 
|  104     m_suspended = false; |  104     m_suspended = false; | 
|  105 } |  105 } | 
|  106  |  106  | 
|  107 void MainThreadTaskRunner::pendingTasksTimerFired(Timer<MainThreadTaskRunner>*) |  107 void MainThreadTaskRunner::pendingTasksTimerFired(Timer<MainThreadTaskRunner>*) | 
|  108 { |  108 { | 
|  109     while (!m_pendingTasks.isEmpty()) { |  109     while (!m_pendingTasks.isEmpty()) { | 
|  110         OwnPtr<ExecutionContextTask> task = m_pendingTasks[0].release(); |  110         OwnPtr<ExecutionContextTask> task = m_pendingTasks[0].release(); | 
|  111         m_pendingTasks.remove(0); |  111         m_pendingTasks.remove(0); | 
|  112         task->performTask(m_context); |  112         task->performTask(m_context); | 
|  113     } |  113     } | 
|  114 } |  114 } | 
|  115  |  115  | 
|  116 } // namespace |  116 } // namespace | 
| OLD | NEW |