fix many bugs
create Save Dialog