Fix to save the entered text on an input dialog, when rotating the device