prevent problem about closing widget just added.