alarmui/group/alarmui_silence.rul
branchRCL_3
changeset 30 d68a4b5d5885
--- /dev/null	Thu Jan 01 00:00:00 1970 +0000
+++ b/alarmui/group/alarmui_silence.rul	Tue May 25 12:41:10 2010 +0300
@@ -0,0 +1,23 @@
+<script xmlns="http://www.nokia.com/ns/cep/script/1.0/" xmlns:cep="http://www.nokia.com/ns/cep/1.0/">
+    <!-- If alarm is not active, nothing needs to be done -->
+    <if>
+        <equals>
+            <contextRef source='Alarm' type='Status.Active' value='false'/>
+        </equals>
+        <actions>
+            <!-- Do nothing -->
+        </actions>        
+    </if>
+    
+    <!-- Silence alarm if 'silence' command is received -->
+    <elseIf>
+        <!-- ...and we got a new stop command -->
+        <contextUpdated>
+            <contextRef source='AlarmUI' type='Command' value='Silence'/>
+        </contextUpdated>
+        <actions>
+           <!-- silence the alarm -->
+            <AlarmUI.Silence/>
+        </actions>
+    </elseIf>
+</script>
\ No newline at end of file