          if (tk_vars["runningtask"].get()
                  and not confirm("Close", confirmtxt)):
              logger.debug("Close Cancelled")
              return
          if tk_vars["runningtask"].get():
              self.wrapper.task.terminate()
          get_images().delete_preview()
          self.quit()
          logger.debug("Closed GUI")
          exit()
 
</s> remove         confirm = messagebox.askokcancel
        confirmtxt = "Processes are still running. Are you sure...?"
        tk_vars = get_config().tk_vars
        if (tk_vars["runningtask"].get()
                and not confirm("Close", confirmtxt)):
            logger.debug("Close Cancelled")
 </s> add         if not self._confirm_close_on_running_task():
            return
        if not self._config.project.confirm_close(): </s> remove     def close_app(self):
 </s> add     def rebuild(self):
        """ Rebuild the GUI on config change """
        logger.debug("Redrawing GUI")
        session_state = self._last_session.to_dict()
        self._config.refresh_config()
        get_images().__init__()
        self.set_fonts()
        self.build_gui(rebuild=True)
        if session_state is not None:
            self._last_session.from_dict(session_state)
        logger.debug("GUI Redrawn")

    def close_app(self, *args):  # pylint: disable=unused-argument </s> remove         self.title("Faceswap.py")
        self.tk.call('wm', 'iconphoto', self._w, get_images().icons["favicon"])
        self.configure(menu=MainMenuBar(self))
 </s> add         if not rebuild:
            self.tk.call('wm', 'iconphoto', self._w, get_images().icons["favicon"])
            self.configure(menu=MainMenuBar(self))
        if self._config.tk_vars["runningtask"].get():
          if (tk_vars["runningtask"].get()
                  and not confirm("Close", confirmtxt)):
              logger.debug("Close Cancelled")
              return
        if self._config.tk_vars["runningtask"].get():
              self.wrapper.task.terminate()
          get_images().delete_preview()
          self.quit()
          logger.debug("Closed GUI")
          exit()
keep keep keep keep replace keep keep keep keep keep
 GUI Updates (#940)

* lib.gui: Update icons
* tools.cli: Add video filetype flag to mask input
* lib.gui.popup_configure: Refresh GUI on config save
* lib.gui._config: Add Icon size and load last session options
* lib.gui.control_helper - Add control modification tracking
* lib.gui - Add Projects and Last Session
- Main root title handled by projects
- Add Hotkeys
- Create projects module
- split fsw and fst filetypes
- Add last_session saving

* lib.project
- Documentation
- Ask confirm on closing unsaved project
-Fixups

* Track model folder changes
- Shuffle some globals
- Activate System Verbosity for GUI

* lib.gui.utils - Documentation and clean up
- lib.gui.custom_widgets - Create and document

* Add GUI config option to disable auto loading model stats 
scripts/gui.py