surface: add filter parameter to UIElement.waitforEvent