Diffstat (limited to 'core/launcher/mediummountgui.cpp') (more/less context) (show whitespace changes)
-rw-r--r-- | core/launcher/mediummountgui.cpp | 24 |
1 files changed, 24 insertions, 0 deletions
diff --git a/core/launcher/mediummountgui.cpp b/core/launcher/mediummountgui.cpp index 2454efa..8307eb6 100644 --- a/core/launcher/mediummountgui.cpp +++ b/core/launcher/mediummountgui.cpp | |||
@@ -52,12 +52,16 @@ void MediumMountGui::readConfig(){ | |||
52 | } | 52 | } |
53 | 53 | ||
54 | bool MediumMountGui::check() { | 54 | bool MediumMountGui::check() { |
55 | return checkagain; | 55 | return checkagain; |
56 | } | 56 | } |
57 | 57 | ||
58 | QStringList MediumMountGui::dirs() { | ||
59 | QStringList list = QStringList::split(",", limittodirs ); | ||
60 | return list; | ||
61 | } | ||
58 | 62 | ||
59 | void MediumMountGui::writeConfig() { | 63 | void MediumMountGui::writeConfig() { |
60 | 64 | ||
61 | OConfig cfg (mediumPath +"/.opiestorage.cf"); | 65 | OConfig cfg (mediumPath +"/.opiestorage.cf"); |
62 | cfg.setGroup("main"); | 66 | cfg.setGroup("main"); |
63 | cfg.writeEntry("check", AskBox->isChecked() ); | 67 | cfg.writeEntry("check", AskBox->isChecked() ); |
@@ -67,12 +71,27 @@ void MediumMountGui::writeConfig() { | |||
67 | cfg.writeEntry("image",CheckBoxImage->isChecked() ); | 71 | cfg.writeEntry("image",CheckBoxImage->isChecked() ); |
68 | cfg.writeEntry("text",CheckBoxImage->isChecked() ); | 72 | cfg.writeEntry("text",CheckBoxImage->isChecked() ); |
69 | cfg.writeEntry("video",CheckBoxVideo->isChecked() ); | 73 | cfg.writeEntry("video",CheckBoxVideo->isChecked() ); |
70 | 74 | ||
71 | cfg.setGroup("dirs"); | 75 | cfg.setGroup("dirs"); |
72 | cfg.writeEntry("dirs", "/"); | 76 | cfg.writeEntry("dirs", "/"); |
77 | |||
78 | |||
79 | if (checkmimeaudio) { | ||
80 | mimeTypeList += ("audio//*"); | ||
81 | } | ||
82 | if (checkmimetext) { | ||
83 | mimeTypeList += ("text//*"); | ||
84 | } | ||
85 | if (checkmimeaudio) { | ||
86 | mimeTypeList += ("video//*"); | ||
87 | } | ||
88 | if (checkmimeaudio) { | ||
89 | mimeTypeList += ("image//*"); | ||
90 | } | ||
91 | |||
73 | } | 92 | } |
74 | 93 | ||
75 | void MediumMountGui::startGui() { | 94 | void MediumMountGui::startGui() { |
76 | 95 | ||
77 | QPixmap image = Resource::loadPixmap( "HelpBrowser"); | 96 | QPixmap image = Resource::loadPixmap( "HelpBrowser"); |
78 | 97 | ||
@@ -154,12 +173,17 @@ void MediumMountGui::startGui() { | |||
154 | 173 | ||
155 | void MediumMountGui::yesPressed() { | 174 | void MediumMountGui::yesPressed() { |
156 | writeConfig(); | 175 | writeConfig(); |
157 | // and do something | 176 | // and do something |
158 | } | 177 | } |
159 | 178 | ||
179 | |||
180 | QStringList MediumMountGui::mimeTypes(){ | ||
181 | return mimeTypeList; | ||
182 | } | ||
183 | |||
160 | void MediumMountGui::noPressed() { | 184 | void MediumMountGui::noPressed() { |
161 | close(); | 185 | close(); |
162 | } | 186 | } |
163 | 187 | ||
164 | MediumMountGui::~MediumMountGui(){ | 188 | MediumMountGui::~MediumMountGui(){ |
165 | } | 189 | } |