Closed Bug 526777 Opened 16 years ago Closed 16 years ago

Livemark and Tagging services could better use XPCOMUtils

Categories

(Toolkit :: Places, defect)

defect
Not set
normal

Tracking

()

RESOLVED FIXED
mozilla1.9.3a1

People

(Reporter: mak, Assigned: mak)

References

Details

Attachments

(1 file, 1 obsolete file)

no reasons to not doing that, and also error-prone, see Bug 526709
Attached patch patch v1.0 (obsolete) — Splinter Review
So, this moves mostly of livemarkService and taggingService to XPCOMUtils. I also removed Livemark Service dependencies from url-classifier helpers, that could be cool, but are really unneeded in this small context, indeed the code is practically same size without them, and i don't think is sane to depend on unofficial libraries from another component. If they are sane should be moved to an Util file. Replaced getters with lazyGetters cleaned up some const removed some unused code
Attachment #410570 - Flags: review?(dietrich)
Comment on attachment 410570 [details] [diff] [review] patch v1.0 > function LivemarkLoadListener(aLivemark) { > this._livemark = aLivemark; > this._processor = null; > this._isAborted = false; > this._ttl = gExpiration; >+ >+ XPCOMUtils.defineLazyServiceGetter(this, "_bms", >+ BMS_CONTRACTID, >+ "nsINavBookmarksService"); >+ XPCOMUtils.defineLazyServiceGetter(this, "_ans", >+ AS_CONTRACTID, >+ "nsIAnnotationService"); also used by the service. any reason to not just make these lazy getters global in this file? that way there's 1 service getter *ever* in all of this code.
Attachment #410570 - Flags: review?(dietrich) → review+
Summary: Livemark Service could use XPCOMUtils → Livemark and Tagging services could better use XPCOMUtils
Attached patch patch v1.1Splinter Review
Attachment #410570 - Attachment is obsolete: true
Status: NEW → RESOLVED
Closed: 16 years ago
Resolution: --- → FIXED
Target Milestone: --- → mozilla1.9.3a1
Depends on: 527431
Depends on: 527638
You need to log in before you can comment on or make changes to this bug.

Attachment

General

Created:
Updated:
Size: