llaske / cordova-plugin-sugarizeros

Cordova plugin for SugarizerOS
0 stars 1 forks source link

Add Android app as favorite by default #8

Open llaske opened 4 years ago

llaske commented 4 years ago

It's possible to add an Android app as favorite so it could appear in the Sugarizer home view activity circle. But it's possible only when the user is connected by clicking on favorite icon in the Sugarizer activity list view.

Is there a way to define an Android app as favorite by default (in activities.json file)? So it could appear by default in the Sugarizer home view for all users.

llaske commented 4 years ago

It's possible starting in Sugarizer commit https://github.com/llaske/sugarizer/commit/a7f4dbd18733c6c2bff6acf500ff3f39d5cd7e62.

To do that, add a new line in activities.json like explain here. But because it's not a Sugarizer activities, you should:

At end, you should have something like that:

{"id": "com.android.chrome", "name": "Chrome", "version": "83.0.4103.106", "type":"native", "icon": "/data/user/0/org.olpc_france.sugarizeros/cache/com.android.chrome.png", "favorite": true, "activityId": null},