OLD | NEW |
(Empty) | |
| 1 <script> |
| 2 (function() { |
| 3 function onLoad() { |
| 4 // TODO(akalin): Do something with these notifications. |
| 5 chrome.sync.onChangesApplied.addListener(function (modelType, changes) { |
| 6 console.log('onChangesApplied: ' + modelType + ': ' + |
| 7 JSON.stringify(changes)); |
| 8 }); |
| 9 |
| 10 chrome.sync.onChangesComplete.addListener(function (modelType) { |
| 11 console.log('onChangesComplete: ' + modelType); |
| 12 }); |
| 13 |
| 14 chrome.sync.onSyncCycleCompleted.addListener(function (snapshot) { |
| 15 console.log('onSyncCycleCompleted: ' + JSON.stringify(snapshot)); |
| 16 }); |
| 17 |
| 18 chrome.sync.onAuthError.addListener(function (authError) { |
| 19 console.log('onAuthError: ' + JSON.stringify(authError)); |
| 20 }); |
| 21 |
| 22 chrome.sync.onUpdatedToken.addListener(function (token) { |
| 23 console.log('onUpdatedToken: ' + token); |
| 24 }); |
| 25 |
| 26 chrome.sync.onPassphraseRequired.addListener(function (forDecryption) { |
| 27 console.log('onPassphraseRequired: ' + forDecryption); |
| 28 }); |
| 29 |
| 30 chrome.sync.onPassphraseAccepted.addListener(function (bootstrapToken) { |
| 31 console.log('onPassphraseAccepted: ' + bootstrapToken); |
| 32 }); |
| 33 |
| 34 chrome.sync.onInitializationComplete.addListener(function () { |
| 35 console.log('onInitializationComplete'); |
| 36 }); |
| 37 |
| 38 chrome.sync.onPaused.addListener(function () { |
| 39 console.log('onPaused'); |
| 40 }); |
| 41 |
| 42 chrome.sync.onResumed.addListener(function () { |
| 43 console.log('onResumed'); |
| 44 }); |
| 45 |
| 46 chrome.sync.onStopSyncingPermanently.addListener(function () { |
| 47 console.log('onStopSyncingPermanently'); |
| 48 }); |
| 49 |
| 50 chrome.sync.onClearServerDataSucceeded.addListener(function () { |
| 51 console.log('onClearServerDataSucceeded'); |
| 52 }); |
| 53 |
| 54 chrome.sync.onClearServerDataFailed.addListener(function () { |
| 55 console.log('onClearServerDataFailed'); |
| 56 }); |
| 57 } |
| 58 |
| 59 document.addEventListener("DOMContentLoaded", onLoad, false); |
| 60 })(); |
| 61 </script> |
OLD | NEW |