com.prolificinteractive.materialcalendarview.OnDateSelectedListener Java Examples

The following examples show how to use com.prolificinteractive.materialcalendarview.OnDateSelectedListener. You can vote up the ones you like or vote down the ones you don't like, and go to the original project or source file by following the links above each example. You may check out the related API usage on the sidebar.
Example #1
Source File: CalendarManager.java    From ReactNativeCalendarAndroid with MIT License 5 votes vote down vote up
@Override
protected void addEventEmitters(final ThemedReactContext reactContext, final Calendar view) {
    view.setOnDateChangedListener(new OnDateSelectedListener() {
        @Override
        public void onDateSelected(MaterialCalendarView widget, CalendarDay date, boolean selected) {
            reactContext.getNativeModule(UIManagerModule.class).getEventDispatcher()
                    .dispatchEvent(new CalendarEvent(
                            view.getId(),
                            date,
                            selected));
        }
    });
}