-
Notifications
You must be signed in to change notification settings - Fork 3.6k
New issue
Have a question about this project? # for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “#”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? # to your account
Clock stop event #7066
Clock stop event #7066
Conversation
Thank you so much for the pull request @dwastberg! I noticed this is your first pull request and I wanted to say welcome to the Cesium community! The Pull Request Guidelines is a handy reference for making sure your PR gets accepted quickly, so make sure to skim that.
Reviewers, don't forget to make sure that:
I am a bot who helps you make Cesium awesome! Contributions to my configuration are welcome. 🌍 🌎 🌏 |
CLA has been sent |
Thanks again for the contribution, @dwastberg. We received your CLA. |
Thanks @dwastberg! This PR looks fine to me. Can you please explain a scenario where this event is useful? |
I'm using the clock to control a looping simulation and at the end of each loop I want to clean up some objects placed in the scene and make some changes to my GUI. |
Specs/Core/ClockSpec.js
Outdated
clock.onStop.addEventListener(onStopSpy); | ||
clock.tick(); | ||
expect(onStopSpy).toHaveBeenCalled(); | ||
|
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
remove this whitespace
Thanks @dwastberg! Just that one comment. And please add a note under the |
Just wondering if there is anything else needed to merger this? |
Thanks for the reminder @dwastberg! We don't get notifications when you add more commits, so it's a good idea to make a comment to let us know when a PR is ready for another look. This all looks good to me. |
Thanks again @dwastberg! |
Add an onStop Event to the Clock which is called when the clock reaches its stopTime.