[qt] use qximinputcontext logical to implement per window ic
[qt] fix crash and some problem on restart