I'm looking to add folder functionality into the manual media center plugin. Ideally, when I click on an item that I've added into the media center, that item would then open up to a folder plugin. How should I combine the code of both plugins to accomplish this?
Asked
Active
Viewed 24 times
1 Answers
0
Context:
You want to Fork the Media Center Manual repo https://github.com/BuildFire/pluginMediaCenterManualEntries
And functionality similar to the Folder Plugin https://github.com/BuildFire/folderPlugin
You would need two parts to change:
- The Control side of the plugin needs to configure which plugin to navigate to when an item is clicked. For you to accomplish this you will need to call the Plugin Instances Dialog using
buildfire.pluginInstance.showDialog(options, callback)
Once you have the save that object in the DataStore alongside the rest of your configuration data.
- On the Widget side of your plugin you then want to:
- Pull the configuration data using Dynamic Data since the name and icon of the selected plugin may change and you will have a stale version of the data. ref: https://github.com/BuildFire/sdk/wiki/How-to-use-the-Datastore-Dynamic-Data
- Navigate to the plugin when an onclick / ontouchstart event is triggered using
buildfire.navigation.navigateTo (pluginData)
ref: https://github.com/BuildFire/sdk/wiki/How-to-use-Navigation#buildfirenavigationnavigateto-plugindata
Note: You can see all api's mentioned above in action in the Folder Plugin. I'd spend time understanding that plugin first before making changes.
I hope this helps :)

Daniel_Madain
- 491
- 4
- 9