class BasicMonthViewUI extends MonthViewUI {

    @Override
    public Date getDayAtLocation(int x, int y) {
        Point dayInGrid = getDayGridPositionAtLocation(x, y);
        // The day header is not clickable, therefore we can't query it.
        if ((dayInGrid == null) || (dayInGrid.y == DAY_HEADER_ROW))
            return null;
        if (dayInGrid.x == WEEK_HEADER_COLUMN) {
            Date month = getMonthAtLocation(x, y);
            return getLastDayInWeek(month, dayInGrid.y, dayInGrid.x);
        }
        Date month = getMonthAtLocation(x, y);
        return getDayInMonth(month, dayInGrid.y, dayInGrid.x);
    }

}