Publish Vulpes Preview 15 sources for desktop, Android and Tundra
Share Gaia assets and adapters, keep private profiles and development documents local, and update both public READMEs.
This commit is contained in:
parent
93e3a48004
commit
b38dea0597
25901 changed files with 9982925 additions and 369 deletions
35
assets/webapps/system.gaiamobile.org/js/camera_trigger.js
Normal file
35
assets/webapps/system.gaiamobile.org/js/camera_trigger.js
Normal file
|
|
@ -0,0 +1,35 @@
|
|||
/* globals BaseModule, MozActivity, Service */
|
||||
|
||||
'use strict';
|
||||
|
||||
(function(exports) {
|
||||
var CameraTrigger = function() {};
|
||||
|
||||
CameraTrigger.EVENTS = [
|
||||
'holdcamera'
|
||||
];
|
||||
|
||||
BaseModule.create(CameraTrigger, {
|
||||
name: 'CameraTrigger',
|
||||
DEBUG: false,
|
||||
TRACE: false,
|
||||
|
||||
_handle_holdcamera: function(event) {
|
||||
// Avoid triggering the Camera app multiple times if the lockscreen is
|
||||
// locked, and prevent bailing during FTU
|
||||
if (Service.query('locked') || Service.query('isFtuRunning')) {
|
||||
return;
|
||||
}
|
||||
|
||||
this.debug('Received holdcamera');
|
||||
/* jshint unused:false */
|
||||
var activity = new MozActivity({
|
||||
name: 'record',
|
||||
data: {
|
||||
type: 'photos'
|
||||
}
|
||||
});
|
||||
}
|
||||
|
||||
});
|
||||
}());
|
||||
Loading…
Reference in a new issue