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

Side by Side Diff: chrome/browser/resources/sync_internals/chrome_sync.js

Issue 8741001: Remove sync OnTransaction{Start,End} notification (Closed) Base URL: svn://svn.chromium.org/chrome/trunk/src
Patch Set: Created 9 years 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 | chrome/browser/sync/js/js_mutation_event_observer.h » ('j') | no next file with comments »
Toggle Intra-line Diffs ('i') | Expand Comments ('e') | Collapse Comments ('c') | Show Comments Hide Comments ('s')
OLDNEW
1 // Copyright (c) 2011 The Chromium Authors. All rights reserved. 1 // Copyright (c) 2011 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 var chrome = chrome || {}; 5 var chrome = chrome || {};
6 // TODO(akalin): Add mocking code for e.g. chrome.send() so that we 6 // TODO(akalin): Add mocking code for e.g. chrome.send() so that we
7 // can test this without rebuilding chrome. 7 // can test this without rebuilding chrome.
8 chrome.sync = chrome.sync || {}; 8 chrome.sync = chrome.sync || {};
9 (function () { 9 (function () {
10 10
(...skipping 73 matching lines...) Expand 10 before | Expand all | Expand 10 after
84 'onInitializationComplete', 84 'onInitializationComplete',
85 'onStopSyncingPermanently', 85 'onStopSyncingPermanently',
86 'onClearServerDataSucceeded', 86 'onClearServerDataSucceeded',
87 'onClearServerDataFailed', 87 'onClearServerDataFailed',
88 'onEncryptedTypesChanged', 88 'onEncryptedTypesChanged',
89 'onEncryptionComplete', 89 'onEncryptionComplete',
90 'onActionableError' 90 'onActionableError'
91 ], 91 ],
92 92
93 'transaction': [ 93 'transaction': [
94 'onTransactionStart',
95 'onTransactionWrite', 94 'onTransactionWrite',
96 'onTransactionEnd'
97 ] 95 ]
98 }; 96 };
99 97
100 for (var eventType in chrome.sync.events) { 98 for (var eventType in chrome.sync.events) {
101 var events = chrome.sync.events[eventType]; 99 var events = chrome.sync.events[eventType];
102 for (var i = 0; i < events.length; ++i) { 100 for (var i = 0; i < events.length; ++i) {
103 var event = events[i]; 101 var event = events[i];
104 chrome.sync[event] = new Event(); 102 chrome.sync[event] = new Event();
105 } 103 }
106 } 104 }
(...skipping 56 matching lines...) Expand 10 before | Expand all | Expand 10 after
163 * @return {number} The number of seconds since the timer was 161 * @return {number} The number of seconds since the timer was
164 * created. 162 * created.
165 */ 163 */
166 get elapsedSeconds() { 164 get elapsedSeconds() {
167 return ((new Date()).getTime() - start.getTime()) / 1000.0; 165 return ((new Date()).getTime() - start.getTime()) / 1000.0;
168 } 166 }
169 }; 167 };
170 }; 168 };
171 169
172 })(); 170 })();
OLDNEW
« no previous file with comments | « no previous file | chrome/browser/sync/js/js_mutation_event_observer.h » ('j') | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698