Opened 13 years ago

Closed 13 years ago

#1921 closed enhancement (fixed)

Create way to use Dojo Storage without having to pull in Dojo Event

Reported by: bradneuberg Owned by: bradneuberg
Priority: high Milestone: 0.9
Component: Storage/Flash Version: 0.4
Keywords: Cc:
Blocked By: Blocking:

Description

Right now using Dojo Storage requires Dojo Event, to know when the storage manager is loaded and ready -- create an entry point to know when this has happened without Dojo Event, so that size-conscious folks can create a build of Dojo Storage with the event system.

Change History (4)

comment:1 Changed 13 years ago by bradneuberg

Resolution: fixed
Status: newclosed

Done; added the following method to dojo.storage:

addOnLoad = function(func){ /* void */
		// summary:
		//	Adds an onload listener to know when
		//	Dojo Offline can be used.
		// description:
		//	Adds a listener to know when Dojo Offline
		//	can be used. This ensures that the Dojo
		//	Offline framework is loaded, that the
		//	local Dojo Storage system is ready to
		//	be used, and that the page is finished
		//	loading. 
		// func: Function
		//	A function to call when Dojo Offline
		//	is ready to go
		
                // ... implementation follows
}

comment:2 Changed 13 years ago by bradneuberg

Note: This was needed for Dojo Offline.

comment:3 Changed 13 years ago by bradneuberg

Resolution: fixed
Status: closedreopened

Reopening -- I'd like to have the addOnLoad event function not only wait until the storage system is loaded, but also wait until the page is loaded -- modify it to do this.

comment:4 Changed 13 years ago by bradneuberg

Resolution: fixed
Status: reopenedclosed

On second thought, it might not be good tieing these two events together -- reclosing.

Note: See TracTickets for help on using tickets.