LiquidProvider class
Internal Class
A ChangeNotifierProvider
to manage LiquidSwipe State.
Every Change is notified from it.
Methods Included :
- animateToPage
_animateDirectlyToPage
- jumpToPage
- updateData
- some more, soon.
- Inheritance
-
- Object
- ChangeNotifier
- LiquidProvider
Constructors
-
LiquidProvider({required int initialPage, required bool loop, required int length, required TickerProviderStateMixin<
StatefulWidget> vsync, required double slideIcon, required OnPageChangeCallback? onPageChangeCallback, required CurrentUpdateTypeCallback? currentUpdateTypeCallback, required SlidePercentCallback? slidePercentCallback, required bool disableGesture, required bool enableSideReveal}) -
Constructor
Contains Default value or Developer desired Values
initialPage
- Initial Page of the LiquidSwipe (0 - n)loop
- Should Enable Loop between Pageslength
- Total Number of Pages
Properties
- activePageIndex ↔ int
-
Storing ActivePage Index
default = 0
getter/setter pair
- animatedPageDragger ↔ AnimatedPageDragger
-
AnimatedPageDragger required for completing the animation when UpdateType is UpdateType.doneAnimating
getter/setter pair
- enableLoop ↔ bool
-
user manageable bool to make Enable and Disable loop within the Pages
getter/setter pair
- enableSideReveal ↔ bool
-
getter/setter pair
- hashCode → int
-
The hash code for this object.
no setterinherited
- hasListeners → bool
-
Whether any listeners are currently registered.
no setterinherited
- iconSize ↔ Size
-
getter/setter pair
- isAnimating ↔ bool
-
Getter for
_isAnimating
getter/setter pair - isInProgress ↔ bool
-
bool variable to set if Liquid Swipe is currently in Progress
getter/setter pair
- isUserGestureDisabled → bool
-
Setter for isUserGestureDisabled
no setter
- nextPageIndex ↔ int
-
Storing next Page Index
default = 0
getter/setter pair
- pagesLength ↔ int
-
Number of Page.
getter/setter pair
- positionSlideIcon ↔ double
-
SlideIcon position, always Horizontal, used in PageDragger
getter/setter pair
- prevUpdate ↔ UpdateType?
-
Storing Previous UpdateType
getter/setter pair
- runtimeType → Type
-
A representation of the runtime type of the object.
no setterinherited
- setUserGesture ← bool
-
Setter for isUserGestureDisabled
no getter
- shouldDisableUserGesture ↔ bool
-
A user handled value if user want, just only to use programmatic pages changes
default = false
getter/setter pair
-
singleTickerProviderStateMixin
↔ TickerProviderStateMixin<
StatefulWidget> -
Ticker Provider from LiquidSwipe, cause need to use it in AnimatedPageDragger
getter/setter pair
- slideDirection ↔ SlideDirection
-
Storing the Swipe Direction using SlideDirection
getter/setter pair
- slidePercentHor ↔ double
-
percentage of slide both Horizontal and Vertical, during touch
getter/setter pair
- slidePercentVer ↔ double
-
getter/setter pair
- slideUpdate ↔ SlideUpdate?
-
A SlideUpdate type for storing the current Slide Update.
getter/setter pair
Methods
-
addListener(
VoidCallback listener) → void -
Register a closure to be called when the object changes.
inherited
-
animateToPage(
int page, int duration) → dynamic - Animating page to the mentioned page
-
dispose(
) → void -
Discards any resources used by the object. After this is called, the
object is not in a usable state and should be discarded (calls to
addListener will throw after the object is disposed).
override
-
jumpToPage(
int page) → dynamic -
Directly Jump to the mentioned
page
without any animation -
noSuchMethod(
Invocation invocation) → dynamic -
Invoked when a nonexistent method or property is accessed.
inherited
-
notifyListeners(
) → void -
Call all the registered listeners.
inherited
-
removeListener(
VoidCallback listener) → void -
Remove a previously registered closure from the list of closures that are
notified when the object changes.
inherited
-
setIconSize(
Size size) → dynamic - Method to set iconSize
-
toString(
) → String -
A string representation of this object.
inherited
-
updateData(
SlideUpdate event) → dynamic - updating data using SlideUpdate, generally we are handling and managing the Animation UpdateType in this methods, All callbacks and factors are also managed by this method.
-
updateSlide(
SlideUpdate slidUpdate) → dynamic - Method to update the slideUpdate and it directly calls updateData
Operators
-
operator ==(
Object other) → bool -
The equality operator.
inherited