WebAPI/Inter App Communication Alt proposal: Difference between revisions

(→‎MessagePort: +start() +close())
Line 115: Line 115:
     'connections': {
     'connections': {
       'musictrack': {
       'musictrack': {
        'handler_path': 'musicmanager.html',
         'description': 'Show the currently played music track information in the lockscreen'
         'description': 'Show the currently played music track information in the lockscreen'
       }
       }
Line 120: Line 121:
  }
  }


where it advertises itself as able to receive connection requests through the 'musictrack' keyword.
where it advertises itself as able to receive connections through the 'musictrack' keyword, requested by (at least) privileged apps and handled within the ''musicmanager.html'' page.


On the other side, music apps (lets say the Gaia Music app and a fictitious Songbirdy privileged app installed from the Firefox Marketplace and an also fictitious iTunos unprivileged app installed from an unknown source) that wants to be controlled from the lockscreen should add the following 'connect' field to its manifest:
On the other side, music apps (lets say the Gaia Music app and a fictitious Songbirdy privileged app installed from the Firefox Marketplace and an also fictitious iTunos unprivileged app installed from an unknown source) that wants to be controlled from the lockscreen should add the following 'connect' field to its manifest:
Line 128: Line 129:
     'connections': {
     'connections': {
       'musicremotecontrol': {
       'musicremotecontrol': {
         'description': 'Play, pause and stop music tracks'
         'description': 'Play, pause and stop music tracks',
        'rules': {
        }
       }
       }
     }
     }
Confirmed users
483

edits