[misc] minor optimization
[qt5] handle widget == NULL in PE_Widget