VooCalendarController class
Calendar controller
- Inheritance
-
- Object
- ChangeNotifier
- VooCalendarController
Constructors
- VooCalendarController({DateTime? initialDate, VooCalendarView initialView = VooCalendarView.month, VooCalendarSelectionMode selectionMode = VooCalendarSelectionMode.single})
Properties
- currentView → VooCalendarView
-
no setter
- dayViewScrollController → ScrollController?
-
no setter
-
events
→ List<
VooCalendarEvent> -
no setter
- focusedDate → DateTime
-
no setter
- hashCode → int
-
The hash code for this object.
no setterinherited
- hasListeners → bool
-
Whether any listeners are currently registered.
no setterinherited
- monthViewScrollController → ScrollController?
-
no setter
- rangeEnd → DateTime?
-
no setter
- rangeStart → DateTime?
-
no setter
- runtimeType → Type
-
A representation of the runtime type of the object.
no setterinherited
- scheduleViewScrollController → ScrollController?
-
no setter
- selectedDate → DateTime
-
no setter
-
selectedDates
→ Set<
DateTime> -
no setter
- selectionMode → VooCalendarSelectionMode
-
no setter
- weekViewScrollController → ScrollController?
-
no setter
- yearViewScrollController → ScrollController?
-
no setter
Methods
-
addEvent(
VooCalendarEvent event) → void -
addListener(
VoidCallback listener) → void -
Register a closure to be called when the object changes.
inherited
-
attachDayViewScrollController(
ScrollController controller) → void - Attach scroll controllers to this calendar controller This allows you to control scrolling programmatically
-
attachMonthViewScrollController(
ScrollController controller) → void -
attachScheduleViewScrollController(
ScrollController controller) → void -
attachWeekViewScrollController(
ScrollController controller) → void -
attachYearViewScrollController(
ScrollController controller) → void -
detachDayViewScrollController(
) → void - Detach scroll controllers
-
detachMonthViewScrollController(
) → void -
detachScheduleViewScrollController(
) → void -
detachWeekViewScrollController(
) → void -
detachYearViewScrollController(
) → void -
dispose(
) → void -
Discards any resources used by the object.
override
-
endDragSelection(
) → void -
getEventsForDate(
DateTime date) → List< VooCalendarEvent> -
goToToday(
) → void -
isDateInRange(
DateTime date) → bool -
isDateSelected(
DateTime date) → bool -
isDragSelecting(
DateTime date) → bool -
isRangeEnd(
DateTime date) → bool -
isRangeStart(
DateTime date) → bool -
nextPeriod(
) → void -
noSuchMethod(
Invocation invocation) → dynamic -
Invoked when a nonexistent method or property is accessed.
inherited
-
notifyListeners(
) → void -
Call all the registered listeners.
inherited
-
previousPeriod(
) → void -
removeEvent(
String eventId) → void -
removeListener(
VoidCallback listener) → void -
Remove a previously registered closure from the list of closures that are
notified when the object changes.
inherited
-
scrollToDateInScheduleView(
{required DateTime date, bool animated = true, Duration duration = const Duration(milliseconds: 300), Curve curve = Curves.easeOutCubic}) → void -
Scroll to a specific date in schedule view
date- The date to scroll toanimated- Whether to animate the scroll (default: true)duration- Duration of animation (default: 300ms)curve- Animation curve (default: Curves.easeOutCubic) -
scrollToEventInDayView(
{required VooCalendarEvent event, double hourHeight = 60.0, bool animated = true, Duration duration = const Duration(milliseconds: 300), Curve curve = Curves.easeOutCubic}) → void -
Scroll to a specific event in day view
Calculates the scroll position based on the event's start time
event- The event to scroll tohourHeight- Height of each hour in pixels (default: 60.0)animated- Whether to animate the scroll (default: true)duration- Duration of animation (default: 300ms)curve- Animation curve (default: Curves.easeOutCubic) -
scrollToEventInScheduleView(
{required VooCalendarEvent event, bool animated = true, Duration duration = const Duration(milliseconds: 300), Curve curve = Curves.easeOutCubic}) → void -
Scroll to a specific event in schedule view
event- The event to scroll toanimated- Whether to animate the scroll (default: true)duration- Duration of animation (default: 300ms)curve- Animation curve (default: Curves.easeOutCubic) -
scrollToHourInDayView(
{required int hour, double hourHeight = 60.0, bool animated = true, Duration duration = const Duration(milliseconds: 300), Curve curve = Curves.easeOutCubic}) → void -
Scroll to a specific hour in day view
hour- The hour to scroll to (0-23)hourHeight- Height of each hour in pixels (default: 60.0)animated- Whether to animate the scroll (default: true)duration- Duration of animation (default: 300ms)curve- Animation curve (default: Curves.easeOutCubic) -
selectDate(
DateTime date) → void -
setEvents(
List< VooCalendarEvent> events) → void -
setFocusedDate(
DateTime date) → void -
setSelectionMode(
VooCalendarSelectionMode mode) → void -
setView(
VooCalendarView view) → void -
startDragSelection(
DateTime date) → void -
toString(
) → String -
A string representation of this object.
inherited
-
updateDragSelection(
DateTime date) → void
Operators
-
operator ==(
Object other) → bool -
The equality operator.
inherited