NavbarNotifier class

Inheritance

Constructors

factory

Properties

hashCode int
The hash code for this object.
no setterinherited
hasListeners bool
Whether any listeners are currently registered.
no setterinherited
runtimeType Type
A representation of the runtime type of the object.
no setterinherited

Methods

addListener(VoidCallback listener) → void
Register a closure to be called when the object changes.
inherited
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).
inherited
noSuchMethod(Invocation invocation) → dynamic
Invoked when a nonexistent method or property is accessed.
inherited
notify() → void
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
toString() String
A string representation of this object.
inherited

Operators

operator ==(Object other) bool
The equality operator.
inherited

Static Properties

badges List<NavbarBadge>
List of badges of the navbar
no setter
currentIndex int
no setter
hideBadgeOnPageChanged bool
Set to true will hide the badges when the tap on the navbar icon.
getter/setter pair
hideBottomNavBar bool
no getter
index int
no getter
isNavbarHidden bool
no setter
keys List<GlobalKey<NavigatorState>>
no setter
length int
getter/setter pair
setStackHistory List<int>
no getter
stackHistory List<int>
no setter

Static Methods

addIndexChangeListener(dynamic listener(int)) → void
clear() → void
hideSnackBar(dynamic context) → void
makeBadgeVisible(int index, bool visible) → void
Use to set the visibility of a badge using its index.
onBackButtonPressed({BackButtonBehavior behavior = BackButtonBehavior.rememberHistory}) FutureOr<bool>
popAllRoutes(int index) → void
pops all routes except first, if there are more than 1 route in each navigator stack
popRoute(int index) → void
pops the current route from a specific navigator stack by passing the index of the navigator stack to pop from.
pushNamed(String route, int x) → void
Use this method to programmatically push a route to a specific navigator stack by passing the route name and the index of the navigator stack
removeAllListeners() → void
removeLastListener() → void
setBadges(List<NavbarBadge>? badgeList) → void
The only place that init the badges.
setKeys(List<GlobalKey<NavigatorState>> value) → void
showSnackBar(BuildContext context, String message, {double? bottom, String? actionLabel, bool showCloseIcon = true, Duration duration = const Duration(seconds: 3), Function? onActionPressed, Function? onClosed}) → void
updateBadge(int index, NavbarBadge badge) → void
Use to update a badge using its index, e.g: update the number, text...