Hi,
I am making a widget with multi-pages. Now my getInitialView is like below
function getInitialView(){ var lastSelectedIndex = $.globalCode.loadStorage("LAST_PAGE_INDEX"); var multiQrViewDelegate = new MultiQrViewDelegate( codeUrls, codeUrls.size(), lastSelectedIndex ); return [multiQrViewDelegate.createScreenPickerView(),multiQrViewDelegate]; }
The delegate implements onNextPage and onPreviousPage defined by BehaviorDelegate.
However, if I press up/down button when it was launched on a real device, the page will be next or previous system widget rather than the view as expected.
I saw the preisntalled Training Status widget, which is my goal.
Some facts in my mind now.
1. Training Status and other pre-installed apps are writen in native code. So third party apps cannot implement that. (Probably not)
2. In SDK 4.x and later, widgets are compiled to super apps. I am also aware of the absense of widgets in GDVC2022(actually since 2020). If my app is launching on a SDK4.x, it will look like what I am expecting