Mercurial > fife-parpg
diff clients/editor/scripts/editor.py @ 374:1115f7cae9a3
Editor:
* The editor will now force filenames to be lowercase, as VFS does not like uppercase path names.
* If a map filename does not have a .xml extension on save, it will be automatically added.
* Log modules set to "all" by default. Only new users will be affected by this without having to modify or remove their configuration file.
* Log level set to LOGLEVEL_WARN
author | cheesesucker@33b003aa-7bff-0310-803a-e67f0ece8222 |
---|---|
date | Sat, 21 Nov 2009 13:11:56 +0000 |
parents | 20fa29f376c7 |
children |
line wrap: on
line diff
--- a/clients/editor/scripts/editor.py Fri Nov 20 02:04:39 2009 +0000 +++ b/clients/editor/scripts/editor.py Sat Nov 21 13:11:56 2009 +0000 @@ -129,9 +129,21 @@ import fifelog logModules = self._settings.get("FIFE", "LogModules") + loglevel = self._settings.get("FIFE", "LogLevel", "Warn"); + self.log = fifelog.LogManager(self.engine, self._settings.get("FIFE", "LogToPrompt"), self._settings.get("FIFE", "LogToFile")) if logModules: self.log.setVisibleModules(*logModules) + + if loglevel == "Debug": + loglevel = fife.LogManager.LEVEL_DEBUG + elif loglevel == "Log": + loglevel = fife.LogManager.LEVEL_LOG + elif loglevel == "Error": + loglevel = fife.LogManager.LEVEL_ERROR + else: + loglevel = fife.LogManager.LEVEL_WARN + self.log.lm.setLevelFilter(loglevel) def _initTools(self): """ Initializes tools """ @@ -402,7 +414,7 @@ if path in self._open_files: # Map is already open, ask user if he wants to reload the map mapview = self.getMapviewByPath(path) - YesNoDialog("Map is already open. Do you want to reload it?", cbwa(self.reloadMapview, mapview=mapview)) + YesNoDialog(u"Map is already open. Do you want to reload it?", cbwa(self.reloadMapview, mapview=mapview)) return """ Opens a file """