Author: bklaas
Date: Thu May  5 13:59:58 2011
New Revision: 9439

URL: http://svn.slimdevices.com/jive?rev=9439&view=rev
Log:
Bug: 17155
Description: support for localservice handler on the go action to allow 
client-side service calls driven from the server-side

Modified:
    
7.6/trunk/squeezeplay/src/squeezeplay/share/applets/SlimBrowser/SlimBrowserApplet.lua

Modified: 
7.6/trunk/squeezeplay/src/squeezeplay/share/applets/SlimBrowser/SlimBrowserApplet.lua
URL: 
http://svn.slimdevices.com/jive/7.6/trunk/squeezeplay/src/squeezeplay/share/applets/SlimBrowser/SlimBrowserApplet.lua?rev=9439&r1=9438&r2=9439&view=diff
==============================================================================
--- 
7.6/trunk/squeezeplay/src/squeezeplay/share/applets/SlimBrowser/SlimBrowserApplet.lua
 (original)
+++ 
7.6/trunk/squeezeplay/src/squeezeplay/share/applets/SlimBrowser/SlimBrowserApplet.lua
 Thu May  5 13:59:58 2011
@@ -786,7 +786,7 @@
        end
 
        -- it's very helpful at times to dump the request table here to see 
what command is being issued
-       -- debug.dump(request)
+        debug.dump(request)
 
        -- there's an existing network or server error, so trap this request 
and push to a diags troubleshooting window
        -- Bug 15662: don't push a diags window when tinySC is available on the 
system and running
@@ -1863,6 +1863,17 @@
                                return EVENT_CONSUME
                        end
                        
+
+                       -- call local service which has previously been 
registered with applet manager
+                       -- this allows SlimBrowser menus to link to local 
applets
+                       if item.actions and item.actions.go and 
item.actions.go.localservice then
+                               log:debug("_actionHandler calling ", 
item.actions.go.localservice)
+                               menuItem:playSound("WINDOWSHOW")
+                               
appletManager:callService(item.actions.go.localservice, { text = item.text })
+                               return EVENT_CONSUME
+                       end
+       
+
                        -- check for a 'do' action (overrides a straight 'go')
                        -- actionName is corrected below!!
                        bAction = _safeDeref(chunk, 'base', 'actions', 'do')

_______________________________________________
Jive-checkins mailing list
[email protected]
http://lists.slimdevices.com/mailman/listinfo/jive-checkins

Reply via email to