/** * <p> * This method restricts the weekdays that are shown. This affects both the * monthly and the weekly view. The general contract is that <b>firstDay < * lastDay</b>. * </p> * * <p> * Note that this only affects the rendering process. Events are still * requested by the dates set by {@link #setStartDate(Date)} and * {@link #setEndDate(Date)}. * </p> * * @param lastDay * the first day of the week to show, between 1 and 7 */ public void setLastVisibleDayOfWeek(int lastDay) { if (this.lastDay != lastDay && lastDay >= 1 && lastDay <= 7 && getFirstVisibleDayOfWeek() <= lastDay) { this.lastDay = lastDay; getState().lastVisibleDayOfWeek = lastDay; } }
int firstDay = event.getComponent().getFirstVisibleDayOfWeek(); int lastDay = event.getComponent().getLastVisibleDayOfWeek(); int dayOfWeek = javaCalendar.get(Calendar.DAY_OF_WEEK);
int firstDay = event.getComponent().getFirstVisibleDayOfWeek(); int lastDay = event.getComponent().getLastVisibleDayOfWeek(); int dayOfWeek = javaCalendar.get(Calendar.DAY_OF_WEEK);