-
Notifications
You must be signed in to change notification settings - Fork 1.9k
New issue
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
Change scope and scroll to selected date #79
Comments
Why did you select a date which had already been selected? |
Well, after the user selects the date, I want the scope to change and then scroll to the selected date, so I hoped I could force the week mode to scroll there. |
OK, I'll take a look at it tomorrow. |
The problem mentioned above isn't solely happening when selecting a date, but switching the scope of the calendar causes this error a lot of times for me. The crash happens on the first line of:
Switching to a Week scope, probably causes the |
Hi @depl0y - (void)calendar:(FSCalendar *)calendar didSelectDate:(NSDate *)date
{
if (calendar.scope == FSCalendarScopeMonth) {
[calendar setScope:FSCalendarScopeWeek animated:YES];
dispatch_after(dispatch_time(DISPATCH_TIME_NOW, (int64_t)(0.3 * NSEC_PER_SEC)), dispatch_get_main_queue(), ^{
calendar.currentPage = date;
});
}
} You should translate it to swift. |
The issue also puzzle me a lot.. |
Fixed |
I am trying out your component and after a couple of issues, I got most of it working.
What I am trying to achieve is the following:
.Month
scopeStep 1 to 3 works, animated, so that looks great, but I can't seem to be able to scroll the
.Week
scope to the right page.I implemented my code like this:
The problem with this method is that it crashes with the following error message:
Any tips?
The text was updated successfully, but these errors were encountered: