-
Notifications
You must be signed in to change notification settings - Fork 338
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
How can I get specific eventView without any gesture? #329
Comments
No, there is no currently support for such a functionality. If you wish to implement it yourself, please add the following API to the DayView: func eventViewFor(eventDescriptor: EventDescriptor) -> EventView {
/// Ask a lower layer for the EventView:
/// DayView -> TimelinePager -> Timeline -> Implement the algorithm on the Timeline class
} |
Hi @richardtop , after checking it, i dont really get it. After implement the func in |
Hi, yes, you'll need to propagate the the call from the So, add this functionality to the Then you just return the result back up the chain. Please, submit a pull request to the library, I'm interested in having this functionality integrated. |
Hi @richardtop , thanks a lot!! I'd like to submit a pull request, but I fork this project from last Octobor and I have modified a lot. Thank you again, you save my day! |
I've looked at your implementation, I see a few issues:
This might not always work. I suggest you changing the code to the following:
Why the 1st way is preferred? Because the So, the descriptor is not a value type but actually a direct reference used & edited by the library. |
I just tried to modify the code like in below and it always return nil, did I get it wrong?
|
No, the code is OK. but are you returning the same descriptor as you've used in the |
Hi,
I'd like to know is there anyway to get specific eventview without any gesture such as tap or longpress?
The scerino will be I get a data from server, then i want to find the event match the data, and show a popover with the eventview's source rect. So the whole workaround will not have any user interaction.
The text was updated successfully, but these errors were encountered: