updates and additions
[webos-internals:jeffrotulls-modifications.git] / camera / camera-simple-shutter-sound-off.patch
1 diff --git a/usr/palm/applications/com.palm.app.camera/app/controllers/capture-assistant.js b/usr/palm/applications/com.palm.app.camera/app/controllers/capture-assistant.js
2 index d38dff5..654ab69 100644
3 --- a/usr/palm/applications/com.palm.app.camera/app/controllers/capture-assistant.js
4 +++ b/usr/palm/applications/com.palm.app.camera/app/controllers/capture-assistant.js
5 @@ -984,6 +984,7 @@ CaptureAssistant.prototype = {
6  
7                 this._idleCheckTimer = setTimeout(this._triggerIdleHandler,  this.cameraControl.prefs[CameraControl.PREFS.IDLEMAX]);
8                 this._powerService.stopScreenDim();
9 +               this.sysVolMute(true);
10         },
11         /**
12          * Stop checking for capture activity and re-enable the screen dim.
13 @@ -999,6 +1000,7 @@ CaptureAssistant.prototype = {
14                         clearTimeout(this._idleCheckTimer);
15                         delete this._idleCheckTimer;
16                 }
17 +               this.sysVolMute(false);
18         },
19         /**
20          * Indicate that an event has occured and reset the screen-off check time.
21 @@ -1009,6 +1011,7 @@ CaptureAssistant.prototype = {
22                         clearTimeout(this._idleCheckTimer);
23                         this._idleCheckTimer = setTimeout(this._triggerIdleHandler,  this.cameraControl.prefs[CameraControl.PREFS.IDLEMAX]);
24  
25 +               this.sysVolMute(true);
26                 }
27                 else{
28                         this.startIdleCheck();
29 @@ -1026,6 +1029,13 @@ CaptureAssistant.prototype = {
30  
31                 this._powerService.allowScreenDim();
32         },
33 +
34 +       sysVolMute: function(mute){
35 +               this.controller.serviceRequest('palm://com.palm.audio/system', {
36 +                       method:'setMuted',
37 +                       parameters:{muted:mute}
38 +               });
39 +       },
40                         
41  
42         /**