remove sip dependence and fix a bug while switching display type