我是在Activated事件中
不过要定义一个全局的bool变量
初始值设为false
登陆后设为true
在Activated事件中先判断该变量是否为true
是则不调登陆窗口