summaryrefslogtreecommitdiffstats
path: root/utils/themeeditor
diff options
context:
space:
mode:
authorRobert Bieber <robby@bieberphoto.com>2010-08-02 22:32:37 +0000
committerRobert Bieber <robby@bieberphoto.com>2010-08-02 22:32:37 +0000
commit436ed78b6facdf52136c6ae78bf200c12d5fef42 (patch)
treef089387371079ddc0d43de72b3128fa0087c9b06 /utils/themeeditor
parent7cd57a9671882e7803bee00c8569f926c98d65ab (diff)
downloadrockbox-436ed78b6facdf52136c6ae78bf200c12d5fef42.tar.gz
rockbox-436ed78b6facdf52136c6ae78bf200c12d5fef42.tar.bz2
rockbox-436ed78b6facdf52136c6ae78bf200c12d5fef42.zip
Theme Editor: SkinDocument class now checks file extension when loading a document and sets the cs device setting accordingly
git-svn-id: svn://svn.rockbox.org/rockbox/trunk@27673 a1c6a512-1295-4272-9138-f99709370657
Diffstat (limited to 'utils/themeeditor')
-rw-r--r--utils/themeeditor/gui/skindocument.cpp15
1 files changed, 15 insertions, 0 deletions
diff --git a/utils/themeeditor/gui/skindocument.cpp b/utils/themeeditor/gui/skindocument.cpp
index 18877d14ee..15111cbed8 100644
--- a/utils/themeeditor/gui/skindocument.cpp
+++ b/utils/themeeditor/gui/skindocument.cpp
@@ -73,6 +73,21 @@ SkinDocument::SkinDocument(QLabel* statusLabel, QString file,
QStringList decomposed = fileName.split('/');
titleText = decomposed.last();
+ /* Setting the current screen device setting */
+ QString extension = titleText.split(".").last().toLower().right(3);
+ if(extension == "wps")
+ {
+ device->setData("cs", "WPS");
+ }
+ else if(extension == "sbs")
+ {
+ device->setData("cs", "Menus");
+ }
+ else if(extension == "fms")
+ {
+ device->setData("cs", "FM Radio Screen");
+ }
+
lastUpdate = QTime::currentTime();
}