key event + saving img locall