Add window refresh callback - #1133
Conversation
Expose GLFW window refresh events through Window::on_refresh in both the native and Python APIs. Track the Python callback during garbage collection and include it in the generated API documentation.
📝 WalkthroughWalkthroughChangesWindow refresh events now flow from GLFW through the native Window refresh callbacks
Merge Risk: 🟠 High · up to The new refresh callback can terminate the application if user callback code throws during event processing. Exception handling at the GLFW boundary should be added before merge. 🚥 Pre-merge checks | ✅ 4 | ❌ 1❌ Failed checks (1 warning)
✅ Passed checks (4 passed)
Full details: Docstring CoverageExplanation Docstring coverage is 7.14% which is insufficient. The required threshold is 80.00%. Docstring coverage is scoped to functions touched by this diff. Analyzed 14 functions across 3 files. (1 skipped: 1 too large.)
Warning Some tools did not complete. Review the errors below. 🔧 ast-grep (0.45.2)src/slangpy_ext/py_doc.hast-grep timed out on this file Thanks for using CodeRabbit! It's free for OSS, and your support helps us grow. If you like it, consider giving us a shout-out. Comment |
There was a problem hiding this comment.
Actionable comments posted: 1
ℹ️ Review info
⚙️ Run configuration
Configuration used: Path: .coderabbit.yaml
Review profile: ASSERTIVE
Plan: Team
Run ID: 01c32cf1-6be8-41f0-8124-25123365eb3e
📒 Files selected for processing (4)
src/sgl/core/window.cppsrc/sgl/core/window.hsrc/slangpy_ext/core/window.cppsrc/slangpy_ext/py_doc.h
Included review availability: Your plan provides up to 2 included reviews per hour; 1 remains after this review.
Summary
Add an
on_refreshcallback toWindow, invoked when GLFW reports that the window contents need to be redrawn.