def afteropenfile(self, filename): if filename == "": # if user cancel select return if current_config["Output path"] != "" and current_config[ "osu! path"] != "": logging.info("entering output") self.main_window.delete_popup() self.main_window.popup_bool = False self.main_window.check_replay_map() self.main_window.resizeEvent(True) self.main_window.skin_dropdown.set_skin_osu() self.main_window.skin_dropdown.get_skins() logging.info(configpath) self.main_window.settingspage.load_settings() osusettings = get_config_info(current_config["osu! path"]) self.set_settings(osusettings) save() self.main_window.osrbutton.browsepath = os.path.join( current_config["osu! path"], "Replays/") self.main_window.mapsetbutton.browsepath = os.path.join( current_config["osu! path"], "Songs/")
def mouseclicked(self): filename = loadname(current_config) save(filename) if self.proc is None or self.proc.poll() is not None: outputfile = open(Log.runosupath, "w") self.proc = subprocess.Popen([sys.executable, os.path.join(abspath, "run_osu.py"), self.main_window.execpath], stdout=outputfile, stderr=outputfile) self.main_window.progressbar.show()
def hidesettings(self): if self.settingspage.isVisible(): self.settingspage.hide() self.settingspage.settingsarea.scrollArea.hide() save() if self.customwindow.isVisible(): self.customwindow.hide()
def check_osu_path(self): if os.path.isfile(configpath): self.skin_dropdown.get_skins() if current_config["Output path"] != "" and current_config["osu! path"] != "": self.delete_popup() self.popup_bool = False if current_config[".osr path"] == "auto": current_settings["Custom mods"] = "" save() if not self.popup_bool: self.settingspage.load_settings() else: self.settingspage.settingsarea.scrollArea.hide()
def activated_(self, index): current_config["Language"] = self.itemText(index) self.main_window.hidesettings() self.main_window.popup_window.reload_popupwindow() self.main_window.settingspage.reload_settings() save()
def activated_(self, index): current_config["Skin path"] = os.path.join(current_config["osu! path"], "Skins", self.itemText(index)) save() logging.info(current_config["Skin path"])