Proper event loop for XRecord
Add notification