Accelerometer Support

Building api for unified accelerometer control in Flambe framework.

Signed-off-by: Bradley Baysinger <bradley@seven2.com>
Updated accelerometer

Getting ready to fork flambé. Tidied up, refined, made disposal, reworked logic for orientation, removed motion stuff for now.

Signed-off-by: Bradley Baysinger <bradley@seven2.com>
Updates for incorporation into Flambe

Changed orientationChange to orientationUpdate. Removed disposal of accelerometer, and made instance persistent. Removed properties that allowed direct access to motion and orientation instances.

Signed-off-by: Bradley Baysinger <bradley@seven2.com>
More accelerometer updates to fit into Flambe

Separated EventGroups so they are independent. Added private NotifyingSignal1, so Accelerometer can stop when it is not in use.

Signed-off-by: Bradley Baysinger <bradley@seven2.com>
More accelerometer updates to fit into Flambe

Separated EventGroups so they are independent. Added private NotifyingSignal1, so Accelerometer can stop when it is not in use.

Signed-off-by: Bradley Baysinger <bradley@seven2.com>
Merge branch 'accelerometer' of https://github.com/braddelcat/flambe into accelerometer

Signed-off-by: Bradley Baysinger <bradley@seven2.com>

Conflicts:
	src/flambe/platform/html/HtmlAccelerometer.hx
Converted accelerometer values to Float

Orientation and motion objects now have values of type float. Also renamed their update functions to indicate internal usage.

Signed-off-by: Bradley Baysinger <bradley@seven2.com>
Bugfix

Fixed issue with last signal disposal.

Signed-off-by: Bradley Baysinger <bradley@seven2.com>
Wired up various Playback classes to watch System.hidden, and pause while in the background.

Signed-off-by: Kipp Ashford <kipp@seven2.net>
Remember if the Playback was already paused when hiding.

Signed-off-by: Kipp Ashford <kipp@seven2.net>
Fix to pause sounds when iOS device is locked or when Safari goes into the background.

Signed-off-by: Kipp Ashford <kipp@seven2.net>
Merge pull request #114 from volkipp/pause_sound_bg

Playback classes now wired to watch System.hidden, and pause while in the background
Minor tweaks.
Return the right prefix for unprefixed APIs.

Fixes System.hidden in the latest Firefox (and other browsers with an
unprefixed Page Visibility API).
Prevent all calls to update() while hidden.

Some browsers (Firefox) seem to call the requestAnimationFrame callback
once even when hidden. That was causing sounds to sometimes not unpause
correctly when coming back from hidden.
Merge pull request #113 from braddelcat/accelerometer

Accelerometer for HTML
NotifyingSignal1 is generally useful, hoist it up into flambe.platform.

Also renamed it to HeavySignal1, it might get extra features later.
It sounds like FlashAccelerometer isn't ready yet, disable for now.
Always initialize the orientationUpdate signal.

It's handy to be able to stick a listener on orientationUpdate without
explicitly having to check orientationSupported (touch and keyboard
signals are like this too).
Accelerometer documentation and cleanup.