fix crash when disabling an element that's selected, fix crash when using tpt.el.xxxx.enabled