          """ Refresh recent menu on save/load of files """
          self.recent_menu.delete(0, "end")
          self.build_recent_menu()
  
      def build_edit_menu(self):
          """ Add the edit menu to the menu bar """
          logger.debug("Building Edit menu")
          configs = self.scan_for_configs()
          for name in sorted(list(configs.keys())):
              label = "Configure {} Plugins...".format(name.title())
              config = configs[name]
              self.edit_menu.add_command(
                  label=label,
                  underline=10,
                  command=lambda conf=(name, config), root=self.root: popup_config(conf, root))
          self.add_cascade(label="Edit", menu=self.edit_menu, underline=0)
          logger.debug("Built Edit menu")
  
      def scan_for_configs(self):
          """ Scan for config.ini file locations """
          root_path = os.path.abspath(os.path.dirname(sys.argv[0]))
          plugins_path = os.path.join(root_path, "plugins")
          logger.debug("Scanning path: '%s'", plugins_path)
          configs = dict()
          for dirpath, _, filenames in os.walk(plugins_path):
              if "_config.py" in filenames:
                  plugin_type = os.path.split(dirpath)[-1]
                  config = self.load_config(plugin_type)
                  configs[plugin_type] = config
          logger.debug("Configs loaded: %s", sorted(list(configs.keys())))
          return configs
  
      @staticmethod
      def load_config(plugin_type):
          """ Load the config to generate config file if it doesn't exist and get filename """
          # Load config to generate default if doesn't exist
 
</s> remove     def build_file_menu(self):
 </s> add     def build_edit_menu(self):
        """ Add the edit menu to the menu bar """
        logger.debug("Building Edit menu")
        configs = self.scan_for_configs()
        for name in sorted(list(configs.keys())):
            label = "Configure {} Plugins...".format(name.title())
            config = configs[name]
            self.edit_menu.add_command(
                label=label,
                underline=10,
                command=lambda conf=(name, config), root=self.root: popup_config(conf, root))
        self.add_cascade(label="Edit", menu=self.edit_menu, underline=0)
        logger.debug("Built Edit menu")

    def scan_for_configs(self):
        """ Scan for config.ini file locations """
        root_path = os.path.abspath(os.path.dirname(sys.argv[0]))
        plugins_path = os.path.join(root_path, "plugins")
        logger.debug("Scanning path: '%s'", plugins_path)
        configs = dict()
        for dirpath, _, filenames in os.walk(plugins_path):
            if "_config.py" in filenames:
                plugin_type = os.path.split(dirpath)[-1]
                config = self.load_config(plugin_type)
                configs[plugin_type] = config
        logger.debug("Configs loaded: %s", sorted(list(configs.keys())))
        return configs

    @staticmethod
    def load_config(plugin_type):
        """ Load the config to generate config file if it doesn't exist and get filename """
        # Load config to generate default if doesn't exist
        mod = ".".join(("plugins", plugin_type, "_config"))
        module = import_module(mod)
        config = module.Config(None)
        logger.debug("Found '%s' config at '%s'", plugin_type, config.configfile)
        return config


class FileMenu(tk.Menu):  # pylint:disable=too-many-ancestors
    """ File menu items and functions """
    def __init__(self, parent):
        logger.debug("Initializing %s", self.__class__.__name__)
        super().__init__(parent, tearoff=0)
        self.root = parent.root
        self.config = get_config()
        self.recent_menu = tk.Menu(self, tearoff=0, postcommand=self.refresh_recent_menu)
        self.build()
        logger.debug("Initialized %s", self.__class__.__name__)

    def build(self): </s> remove     @staticmethod
    def load_config(plugin_type):
        """ Load the config to generate config file if it doesn't exist and get filename """
        # Load config to generate default if doesn't exist
        mod = ".".join(("plugins", plugin_type, "_config"))
        module = import_module(mod)
        config = module.Config(None)
        logger.debug("Found '%s' config at '%s'", plugin_type, config.configfile)
        return config
 </s> add class ToolsMenu(tk.Menu):  # pylint:disable=too-many-ancestors
    """ Tools menu items and functions """
    def __init__(self, parent):
        logger.debug("Initializing %s", self.__class__.__name__)
        super().__init__(parent, tearoff=0)
        self.root = parent.root
        self.build()
        logger.debug("Initialized %s", self.__class__.__name__) </s> remove     def build_tools_menu(self):
        """ Add the file menu to the menu bar """
 </s> add     def build(self):
        """ Build the tools menu """ </s> remove         self.build_tools_menu()
 </s> add         self.add_cascade(label="Tools", menu=self.tools_menu, underline=0) </s> remove         self.tools_menu.add_command(
            label="Check for updates...", underline=0, command=self.check_updates)
        self.tools_menu.add_command(
            label="Output System Information", underline=0, command=self.output_sysinfo)
        self.add_cascade(label="Tools", menu=self.tools_menu, underline=0)
 </s> add         self.add_command(label="Check for updates...",
                         underline=0,
                         command=lambda action="update": self.in_thread(action))
        self.add_command(label="Output System Information",
                         underline=0,
                         command=lambda action="output_sysinfo": self.in_thread(action))
          """ Refresh recent menu on save/load of files """
          self.recent_menu.delete(0, "end")
          self.build_recent_menu()
  



























  
      @staticmethod
      def load_config(plugin_type):
          """ Load the config to generate config file if it doesn't exist and get filename """
          # Load config to generate default if doesn't exist
keep keep keep keep replace replace replace replace replace replace replace replace replace replace replace replace replace replace replace replace replace replace replace replace replace replace replace replace replace replace replace keep keep keep keep keep
 More responsive FaceSwap update code 
lib/gui/menu.py