forked from len0rd/rockbox
Fix wrong theme base path when loading a wps.
When loading a wps in the Theme Editor without having a theme cfg loaded the base path derived from it would be wrong. Make sure to start from the wps files folder when deriving it. Still assumes the wps file to be in the standard layout, i.e. in a folder called wps/. git-svn-id: svn://svn.rockbox.org/rockbox/trunk@29545 a1c6a512-1295-4272-9138-f99709370657
This commit is contained in:
parent
4e42cd712c
commit
cc6cc53737
1 changed files with 2 additions and 1 deletions
|
|
@ -289,7 +289,8 @@ RBScene* ParseTreeModel::render(ProjectModel* project,
|
|||
/* Setting themebase if it can't be derived from the project */
|
||||
if(settings.value("themebase", "") == "" && file && QFile::exists(*file))
|
||||
{
|
||||
QDir base(*file);
|
||||
QFileInfo wpsfile(*file);
|
||||
QDir base(wpsfile.canonicalPath());
|
||||
base.cdUp();
|
||||
settings.insert("themebase", base.canonicalPath());
|
||||
}
|
||||
|
|
|
|||
Loading…
Add table
Add a link
Reference in a new issue