Added the border of screen when moving windows, fixed some bugs