Class: Toybox.WatchUi.ViewLoopFactory
- Inherits:
-
Toybox.Lang.Object
Overview
A factory object for view/delegate instances, used by ViewLoop
Typedef Summary collapse
-
Delegates as WatchUi.BehaviorDelegate or WatchUi.Menu2InputDelegate
Delegate types that can be provided by a ViewLoopFactory.
-
Views as WatchUi.View
View types that can be provided by a ViewLoopFactory.
Instance Method Summary collapse
-
getSize() as Lang.Number
Return the number of view/delegate pairs that are managed by this factory.
-
getView(page as Lang.Number) as [ ViewLoopFactory.Views ] or [ ViewLoopFactory.Views, ViewLoopFactory.Delegates ]
This function will be called by the system to retrieve a view/delegate pair for the page at the given index.
Typedef Details
Delegates as WatchUi.BehaviorDelegate or WatchUi.Menu2InputDelegate
Delegate types that can be provided by a ViewLoopFactory
Views as WatchUi.View
View types that can be provided by a ViewLoopFactory
Instance Method Details
getSize() as Lang.Number
Return the number of view/delegate pairs that are managed by this factory
getView(page as Lang.Number) as [ ViewLoopFactory.Views ] or [ ViewLoopFactory.Views, ViewLoopFactory.Delegates ]
This function will be called by the system to retrieve a view/delegate pair for the page at the given index
This method must be overridden in derived classes. If called, this function will cause the application to crash.
Menu2 and Menu2InputDelegate support added for API version 5.1.0.