Hi, I’m looking for a way to programmatically dismiss a RolloverModifier from a chart. I’ve been tasked with creating a user experience that does two things: 1. when a user stops scrubbing on the chart, the rollover modifier should persist, and 2. when the user taps outside of the chart the rollover modifier should disappear.
I’ve accomplished the first part of the problem by implementing a subclass of SCIRolloverModifier and overriding the onEvent(args:)
function, but I cannot figure out how to dismiss the rollover modifier when the user taps outside the chart surface.
Is there a way to accomplish this?
- Tyler Williamson asked 4 months ago
- You must login to post comments
Simply set the isEnabled property and this will enable or disable the rollover on the chart
We have a demo of how to achieve the persistence in the SciTrader app SDK.
- Download the app here https://scitrader.Io
- Go to the chart screen
- Click on the crosshair icon
- Tap and move on the chart
- Tap crosshair again
The source code for this sdk is open source. You can see exactly how we implemented the modifiers at http://github.com/abtsoftware/finance.ios
Best regards
Andrew
- Andrew Burnett-Thompson answered 4 months ago
- You must login to post comments
Please login first to submit.