Commit d244ec2e2904a46f63b0a362752a5b43a885b778

  • avatar
  • dBsooner's Stuff <dbsooner @del…ge.vision5.com>
  • Sun Feb 28 04:56:47 CET 2010
4 new, 1 updated patches.
  
11--- .orig/media/cryptofs/apps/usr/palm/applications/com.palm.pandora/app/core/device_service.js
22+++ /media/cryptofs/apps/usr/palm/applications/com.palm.pandora/app/core/device_service.js
3@@ -51,7 +51,7 @@
3@@ -51,8 +51,8 @@
44 },
55
66 registerForMediaEvents: function() {
77- this.mediaServiceRef = new Mojo.Service.Request('palm://com.palm.keys/media', {
8+/* this.mediaServiceRef = new Mojo.Service.Request('palm://com.palm.keys/media', {
9 method: 'status',
8- method: 'status',
9+ this.mediaServiceRef = new Mojo.Service.Request('palm://com.palm.mediaevents', {
10+ method: 'mediaEvents',
1011 onSuccess: this.mediaCallback,
1112 parameters: {subscribe: true}
12@@ -55,6 +55,11 @@
13 });
14@@ -54,7 +54,7 @@
15 this.mediaServiceRef = new Mojo.Service.Request('palm://com.palm.keys/media', {
1316 method: 'status',
1417 onSuccess: this.mediaCallback,
15 parameters: {subscribe: true}
16+ });*/
17+ this.mediaServiceRef = new Mojo.Service.Request('palm://com.palm.mediaevents', {
18+ method: 'mediaEvents',
19+ onSuccess: this.mediaCallback,
18- parameters: {subscribe: true}
2019+ parameters: {appName: AppConstants.appId, subscribe: true}
2120 });
2221 },
2322
24@@ -118,7 +123,7 @@
23@@ -118,17 +118,28 @@
2524 return;
2625 }
2726
2827- if (event.key == "pause" && event.state == "down") {
29+/* if (event.key == "pause" && event.state == "down") {
30 AppGlobals.station.pause();
31 } else if (event.key == "play" && event.state == "down") {
32 AppGlobals.station.pause();
33@@ -129,6 +134,6 @@
34 } else if (event.key == "stop" && event.state == "down") {
35 AppGlobals.station.pauseIfPlaying();
36 }
37- }
38+ }*/
39
40 });
41@@ -131,4 +136,34 @@
42 }
43 }
44
28- AppGlobals.station.pause();
29- } else if (event.key == "play" && event.state == "down") {
30- AppGlobals.station.pause();
31- } else if (event.key == "next" && event.state == "down") {
32- AppGlobals.station.skip();
33- } else if (event.key == "togglePausePlay" && event.state == "down") {
34- AppGlobals.station.pause();
35- } else if (event.key == "stop" && event.state == "down") {
36- AppGlobals.station.pauseIfPlaying();
37- }
4538+ Util.log("media event: " + event.key);
4639+ switch (event.key) {
4740+ case "next":
4841+ AppGlobals.station.skip();
4942+ break;
5043+
51+ case "nextAndPlay":
52+ this.serviceRequest = new Mojo.Service.Request("palm://com.palm.vibrate", {
53+ method: 'vibrate', parameters: { 'period': 0,'duration': 750 }
54+ });
55+ AppGlobals.station.skip();
56+ break;
57+
5844+ case "pause":
5945+ AppGlobals.station.pause();
6046+ break;
5757+ AppGlobals.station.pauseIfPlaying();
5858+ break;
5959+ }
60+ }
60 }
61
6162 });
6263\ No newline at end of file
  
1Name: Top Bar Ringer Switch
2Version: 1.3.5.2-4
3Author: frause
4Description: Adds icon to top bar when ringer switch is activated. If my Top Bar Icon And Percent Small White patch is installed, the percent value is removed when the mute icon is displayed to reduce witdh of the icon row. (MIT license)
5
6
7--- /usr/lib/luna/system/luna-systemui/app/controllers/bar-assistant.js.orig Fri Jan 15 23:04:41 2010
8+++ /usr/lib/luna/system/luna-systemui/app/controllers/bar-assistant.js Fri Jan 15 23:30:12 2010
9@@ -2870,7 +2871,15 @@
1diff --git a/usr/lib/luna/system/luna-systemui/app/controllers/bar-assistant.js b/usr/lib/luna/system/luna-systemui/app/controllers/bar-assistant.js
2index 6fdbb39..edcecee 100644
3--- a/usr/lib/luna/system/luna-systemui/app/controllers/bar-assistant.js
4+++ b/usr/lib/luna/system/luna-systemui/app/controllers/bar-assistant.js
5@@ -60,6 +60,9 @@ var BarAssistant = Class.create({
6 //Initialize and Subscribe for Storage / Media Mode Notification.
7 this.storageInit();
8
9+ // Initialize and Subscribe for Ringer Switch Status
10+ this.initOnServerStart("com.palm.keys", this.ringerStatus.bind(this));
11+
12 //Initialize and Subscribe for Power Off Notification.
13 this.powerOffInit();
14
15@@ -2999,6 +3002,32 @@ showAudioAlert: function(volume,showringer,audioTarget) {
16 }
1017 },
1118
12 audioInit: function() {
13-
14+
15+ this.controller.serviceRequest('palm://com.palm.audio/ringtone', {
19+ringerStatus: function() {
20+ this.controller.serviceRequest('palm://com.palm.keys/switches', {
1621+ method:'status',
17+ parameters: {subscribe:true},
18+ onSuccess: function(response) {
19+ this.displayMutedIcon(!response['ringer switch']);
22+ parameters: {"subscribe":true},
23+ onSuccess: function(payload) {
24+ this.controller.serviceRequest('palm://com.palm.audio/media', {
25+ method:'status',
26+ onSuccess: function(response) {
27+ this.displayMutedIcon(!response['ringer switch']);
28+ }.bind(this)
29+ });
2030+ }.bind(this)
2131+ });
22+
23 //Subscribe to Audio Manager for Phone status Notifications.
24 this.audioPhoneNotificationSession = new Mojo.Service.Request('palm://com.palm.audio/phone', {
25 method: 'status',
26@@ -2902,6 +2911,17 @@
27 return;
28
29 this.handleAudioNotifications(payload,'phone');
3032+},
3133+
3234+displayMutedIcon: function(mute) {
4040+ $('ringer').className = 'on';
4141+ $('batpercent').className = 'show';
4242+ }
43 },
44
45 handleMediaAudioNotifications: function(payload) {
46--- /usr/lib/luna/system/luna-systemui/app/views/bar/bar-scene.html.orig Fri Jan 15 23:17:58 2010
47+++ /usr/lib/luna/system/luna-systemui/app/views/bar/bar-scene.html Fri Jan 15 22:57:11 2010
43+},
44+
45 dataImportInit: function() {
46 //Subscribe to Data Srevice status Notifications.
47 this.dataImportNotificationSession = new Mojo.Service.Request('palm://com.palm.dataimport/', {
48diff --git a/usr/lib/luna/system/luna-systemui/app/views/bar/bar-scene.html b/usr/lib/luna/system/luna-systemui/app/views/bar/bar-scene.html
49index c1daf79..4b574ae 100644
50--- a/usr/lib/luna/system/luna-systemui/app/views/bar/bar-scene.html
51+++ b/usr/lib/luna/system/luna-systemui/app/views/bar/bar-scene.html
4852@@ -19,6 +19,8 @@
4953 <div id="devicemenu">
5054 <div id="power">
5858 <div id="rssi">
5959 </div>
6060 <div id="roaming">
61--- /usr/lib/luna/system/luna-systemui/stylesheets/systemui.css.orig Fri Jan 15 23:20:50 2010
62+++ /usr/lib/luna/system/luna-systemui/stylesheets/systemui.css Fri Jan 15 23:31:21 2010
63@@ -122,6 +122,7 @@
61diff --git a/usr/lib/luna/system/luna-systemui/stylesheets/systemui.css b/usr/lib/luna/system/luna-systemui/stylesheets/systemui.css
62index 0917ee7..7a0cd64 100644
63--- a/usr/lib/luna/system/luna-systemui/stylesheets/systemui.css
64+++ b/usr/lib/luna/system/luna-systemui/stylesheets/systemui.css
65@@ -122,6 +122,7 @@ body.palm-default {
6466 #tty,
6567 #hac,
6668 #callforward,
7070 #gps {
7171 float: right;
7272 height: 20px;
73@@ -217,6 +218,21 @@
73@@ -217,6 +218,21 @@ body.palm-default {
7474 background: url(../images/battery-charged.png) center center no-repeat;
7575 }
7676
7979+ margin-left: 2px;
8080+}
8181+#ringer.off {
82+ background: url(../../../../../palm/applications/com.palm.app.clock/images/prefs-mute.png) center left no-repeat;
82+ background: url(../../../../../palm/applications/com.palm.app.soundsandalerts/images/prefs-mute.png) center left no-repeat;
8383+}
8484+#ringer.on {
8585+ display: none;