Commit Graph

84 Commits

Author SHA1 Message Date
Edward Lee
9d76d3dc30 Bug 553402 - New pages in a tab aren't synced [r=mconnor]
Trace pageshow events to indicate that new tab data should be uploaded. Because scores must be integers, still increment the score by 1, but only do that 10% of the time for pageshows.
2010-04-21 16:35:51 -07:00
Edward Lee
3b4aa0220d Bug 550627 - Default reconciliation to server wins for older changed items [r=mconnor]
Save the time the tracker adds a new changed id and use that to compare the age of the record on the server vs the age of the local change to decide if it's server wins or client wins. Fix up various direct uses of changedIDs to use the API and make the save-to-disk lazy to avoid excessive writes. Add a test to make sure addChangedID only increases in time.
2010-04-01 15:54:53 -07:00
Edward Lee
05af24a32c Bug 535326 - Need to rethink tab sync limit of 25 [r=mconnor]
Fit as many tabs as possible in 20000 characters by linearly estimating how many will fit then remove extras one by one.

--HG--
extra : rebase_source : 1ef3700a9cddd7e3cb0f96b9affada15e98ea672
2010-02-17 18:24:22 -08:00
Edward Lee
21f7747109 Bug 548066 - JavaScript strict warning: clientData.js, line 194: reference to undefined property this.clients[id] [r=mconnor]
Get rid of get/setInfo on ClientEngine and ClientStore and expose functions to read/modify client data: stats, clearCommands, sendCommand. Also expose the local client information as local[ID,Name,Type,Commands] and rework the storage to use these instead of trying to keep the JS object clients entry in sync with prefs, etc. Update users of the old interface (service/tabs/chrome) to use the new local*. Set the client type based on app id instead of from each app's overlay.
2010-03-16 16:39:08 -07:00
Paul O’Shannessy
59471f450c Bug 548939 - Use SessionStore in tab engine [r=Mardak]
Created a fake SessionStore service for Fennec that imitates the parts of Firefox's SessionStore API that we need. Then used the now "consistent" SessionStore service in the Tabs engine.
2010-03-16 15:14:32 -07:00
Edward Lee
1ce05d4603 Bug 549633 - Standardize record creation so all SyncEngines encrypt data [r=mconnor]
Always add the id and encryption value so client and delete records can be encrypted.
2010-03-05 14:46:48 -08:00
Edward Lee
1ad29052b7 Bug 545767 - Clean up various names/strings needed for each set of engines/stores/trackers
Pass the engine name when constructing a subclass engine and construct the store/tracker with the same name.
2010-02-11 15:29:15 -08:00
Edward Lee
b8de893593 Bug 545764 - Convert constructor -> _init pattern to just use constructor
Inline various _init calls and do super's init with <Super>.call(this, args..). Add various get/set sugar to those missing e.g., meta.keyring. Also simplify crypto record creation by setting cleartext in the parent.

--HG--
extra : rebase_source : 6c9a9f210f8f46ac338adb84188538e7353c9673
2010-02-11 15:25:31 -08:00
Paul O’Shannessy
a3f801887c Bug 545487 - Cleanup TabTracker_observe [r=Mardak]
Remove the "load" event listener and don't QI since we don't need to.
2010-02-11 15:08:28 -08:00
Edward Lee
4cbaa75427 Lower tab logging to trace when wrapping tabs. 2010-01-21 09:59:27 -08:00
Edward Lee
48b1cf979f Bug 537954 - Some tabs don't get synced
Listen for load before adding the unload listener (and the Tab listeners).
2010-01-06 09:54:15 -08:00
Edward Lee
d3218dee1f Bug 535479 - Be smarter in getting rid of the "remote tabs" notification
Add a tri-state pref that is unset, 0, or a number (modified time in seconds) and don't show the notification if it's in the "0" state. Unset pref means no modified time has been saved, and a non-0 state is the modified time of the last synced tab. So when tabs arrive with a different modified time, switch to the 0 state. Additionally, still remember if the user ever dismissed the notification and never show it again.
2009-12-17 12:20:07 -08:00
Edward Lee
6f16e5f19c Bug 532770 - Allow tab sync's filtered urls to be set by pref
Expose engine.tabs.filteredUrls as a string to be used as regex and filter case insensitively.
2009-12-03 14:54:23 -08:00
Edward Lee
bef67b3db3 Bug 532173 - Don't sync tabs of some pages (weave firstrun, about:blank)
Ignore certain filtered urls when creating a list of tabs for remote machines.
2009-12-02 14:46:02 -08:00
Edward Lee
c5bc7653dd Bug 531239 - clear out duplicate/old machines from Clients record
Get rid of persistent storage for clients and tabs to always fetch fresh records.
2009-12-02 14:44:17 -08:00
Edward Lee
a46e202447 Share tab-gathering code for both createRecord and locallyOpenTabMatches. 2009-12-01 11:36:56 -08:00
Edward Lee
d4295ef8e9 Remove unused prefs and imports. (Bug 524916)
--HG--
extra : rebase_source : 074e542f63ee840b61db7fe63a6c3540c13a31a5
2009-11-25 17:49:15 -08:00
Edward Lee
df947df75e Bug 531177 - Tabs don't sync from firefox (when there's lots of tabs)
Simplify tab record to just use deferGetSet like the other records and sort tabs based on their last usage to pick out a subset.
2009-11-25 15:22:45 -08:00
Edward Lee
dd2f688ee2 Bug 531171 - Tabs don't always update
Only expose that the tab engine knows about the current client's tabs, so always create/apply incoming and only create records tabs for local.
2009-11-25 15:17:39 -08:00
Edward Lee
877e53a9da Bug 531170 - Tabs don't sync from fennec
Add listeners for Fennec tab events the same way we do it for Firefox and share listener logic for various event types.

--HG--
extra : rebase_source : 685e45c16052db3d285c25c68db47680b7d15f72
2009-11-25 15:14:56 -08:00
Edward Lee
8b8ea72a82 Bug 528343 - Tabs don't sync
Set the current client on any tab change for tracker.changedIDs and reset that when sync finishes.

--HG--
extra : rebase_source : 3100141bc1fdfaaa959b5f990a9538527761aace
2009-11-12 14:48:54 -08:00
Mike Connor
14acb12656 bug 518075 - tweak original patch and item values 2009-11-09 12:57:58 -05:00
Mike Connor
bcb7b750cb bug 485108 - drop status dialog, show status including engines on statusbar, remove dead status bits 2009-10-28 03:42:35 -04:00
Edward Lee
51a7e2fb0b Bug 518958 - Only sync tabs if there has been tab activity
Check the score, which gets bumped up on tab open/close/select, to decide if tabs should be marked as changed.
2009-09-25 16:14:26 -07:00
Edward Lee
666d0373fe Land about-weave on weave. Bug 516350 - about:weave round 3 followup fixes. r=thunder 2009-09-17 14:51:00 -07:00
Edward Lee
0611761d74 Use trace logging for reporting GUIDs. 2009-09-17 14:41:24 -07:00
Dan Mills
5094a04f3d initial patch
--HG--
extra : rebase_source : 250c8f0d85483300147a6f0d691e0214db6d837b
2009-09-15 21:54:05 -04:00
Edward Lee
7f9b6c7f87 Be less chatty when showing GUIDs and ignore cases. 2009-09-11 14:39:48 -07:00
Edward Lee
551f097468 Convert various debug messages to trace. 2009-07-22 21:40:18 -07:00
Edward Lee
68d361380a Bug 504230 - Use Engine's logging level for Store and Tracker
Use the log.logger.engine.* prefs to determine what the Store and Tracker should log with. This requires putting the same engine name on each Store/Tracker object, so there's some duplicate string values right now.
2009-07-14 18:34:03 -07:00
Edward Lee
5c482eea0d merge weave. resolve comments added to resource.js. 2009-07-09 11:21:20 -07:00
Edward Lee
39f333a78e Bug 500598 - Undefined item in tabContainer.childNodes after closing tabs
The childNodes NodeList keeps its indices even after removal, so it's safer to convert the array-like thing into an actual array. Condense the QueryInterface code to the instanceof magic.
2009-06-25 22:46:14 -07:00
Edward Lee
84c52a6411 merge weave. resolve addition of kSpecialIds to bookmarks.js near removal of Async.sugar. 2009-06-23 22:34:57 -07:00
Edward Lee
eeef9a8201 Bug 487282 - "browser is null" error in tabs.js
Share browser detection code for register and unregister tab listeners and better check for tabbrowser windows.
2009-06-22 15:53:42 -07:00
Edward Lee
6bc0e717ec Clean up various engines to remove Async.sugar and random self/yields. 2009-06-05 15:34:40 -07:00
Wladimir Palant
8f33b68063 Bug 495924 - TabTracker wrongly assumes that "this" pointer will be set correctly for event handlers 2009-06-02 11:25:37 +02:00
Edward Lee
ba7af5037c Bug 486230 - Share json disk caching with Utils.json{Load,Save} 2009-03-31 19:52:16 -05:00
Edward Lee
4f6ebe6be5 Bug 481741 - Switch to JSON from nsIJSON 2009-03-31 14:09:38 -05:00
Dan Mills
9df4203349 remove dump() debugging from tabs engine 2009-03-30 15:18:20 -07:00
jonathandicarlo@jonathan-dicarlos-macbook-pro.local
53fa9e5846 Bug 485539 - added guard to the tab engine to handle the case where there are undefined items in tabContainer.childNodes. 2009-03-27 11:06:43 -07:00
jonathandicarlo@jonathan-dicarlos-macbook-pro.local
b690a2858d Fixed name of TabStore.changeItemID so that it correctly overrides the abstract base class method. Whoops. 2009-03-25 17:36:11 -07:00
jonathandicarlo@jonathan-dicarlos-macbook-pro.local
6555e1e1ef Experimenting with getting tab last-used-time data on Fennec 2009-03-18 12:40:27 -07:00
jonathandicarlo@jonathan-dicarlos-macbook-pro.local
0f809c8372 Removed unused code from tab tracker. 2009-03-17 18:02:13 -07:00
jonathandicarlo@jonathan-dicarlos-macbook-pro.local
a6e05ab37a TabTracker now keeps track of when each tab was most recently used; tabStore wraps this data for sync, and fennec UI uses it to sort incoming tabs by most-recently-used date. This fixes 481326. 2009-03-17 17:57:53 -07:00
jonathandicarlo@jonathan-dicarlos-macbook-pro.local
95ae06e497 If you click the button to show synced tabs before Weave has been configured, it will now take you straight to the sign-in screen. Fixes bug 482818. 2009-03-16 16:49:56 -07:00
jonathandicarlo@jonathan-dicarlos-macbook-pro.local
859e51e20b The remote-tabs menu (on both firefox and fennec) no longer shows tabs you already have open locally. Fixes bug 480405. 2009-03-12 15:54:26 -07:00
Dan Mills
2e61ae02f3 remove dump() debug statements 2009-03-10 01:20:50 -07:00
Edward Lee
edda1db597 Bug 480457 - Expose a resetClient API for weave service and engines. r=thunder 2009-02-26 22:36:14 -08:00
jonathandicarlo@jonathan-dicarlos-macbook-pro.local
ff833098f5 Resource.js now always validates the cache (VALIDATE_ALWAYS) when downloading stuff. This seems to fix bug 480270 on Firefox but not on Fennec. 2009-02-27 18:28:26 -08:00
jonathandicarlo@jonathan-dicarlos-macbook-pro.local
85f96743c6 Changed how firefox populates tabs-from-other-computers menu and how it opens a tab picked from that menu, so that it can restore the history of the tab and not just the latest URL. 2009-02-25 00:56:46 -08:00