Initial implementation of UI saving code