aboutsummaryrefslogtreecommitdiff
path: root/src/MenuCreator.cc
diff options
context:
space:
mode:
authorakir <akir>2004-08-26 18:26:39 (GMT)
committerakir <akir>2004-08-26 18:26:39 (GMT)
commit6ce5a31ea8bb6dbf6f64260c62d9af153e9d7f30 (patch)
treebd4551de51a6c58e9eac351759e488bc74febc8d /src/MenuCreator.cc
parent0f83e449727a16c178b47262f170e879a22c0981 (diff)
downloadfluxbox-6ce5a31ea8bb6dbf6f64260c62d9af153e9d7f30.zip
fluxbox-6ce5a31ea8bb6dbf6f64260c62d9af153e9d7f30.tar.bz2
unification for themes.cfg/styles.cfg and the same for menuentries:
[stylesmenu] and [themesmenu] [stylesdir] and [themesdir]
Diffstat (limited to 'src/MenuCreator.cc')
-rw-r--r--src/MenuCreator.cc10
1 files changed, 8 insertions, 2 deletions
diff --git a/src/MenuCreator.cc b/src/MenuCreator.cc
index 57ef32c..374411d 100644
--- a/src/MenuCreator.cc
+++ b/src/MenuCreator.cc
@@ -20,7 +20,7 @@
20// FROM, OUT OF OR IN CONNECTION WITH THE SOFTWARE OR THE USE OR OTHER 20// FROM, OUT OF OR IN CONNECTION WITH THE SOFTWARE OR THE USE OR OTHER
21// DEALINGS IN THE SOFTWARE. 21// DEALINGS IN THE SOFTWARE.
22 22
23// $Id: MenuCreator.cc,v 1.10 2004/07/05 09:27:04 fluxgen Exp $ 23// $Id: MenuCreator.cc,v 1.11 2004/08/26 18:26:39 akir Exp $
24 24
25#include "MenuCreator.hh" 25#include "MenuCreator.hh"
26 26
@@ -83,7 +83,8 @@ static void createStyleMenu(FbTk::Menu &parent, const std::string &label,
83 if ((FbTk::Directory::isRegularFile(style) && 83 if ((FbTk::Directory::isRegularFile(style) &&
84 (filelist[file_index][0] != '.') && 84 (filelist[file_index][0] != '.') &&
85 (style[style.length() - 1] != '~')) || 85 (style[style.length() - 1] != '~')) ||
86 FbTk::Directory::isRegularFile(style + "/theme.cfg")) 86 FbTk::Directory::isRegularFile(style + "/theme.cfg") ||
87 FbTk::Directory::isRegularFile(style + "/style.cfg"))
87 parent.insert(new StyleMenuItem(filelist[file_index], style)); 88 parent.insert(new StyleMenuItem(filelist[file_index], style));
88 } 89 }
89 // update menu graphics 90 // update menu graphics
@@ -219,6 +220,11 @@ static void translateMenuItem(Parser &parse, ParseItem &pitem) {
219 createStyleMenu(menu, str_label, 220 createStyleMenu(menu, str_label,
220 str_key == "stylesmenu" ? str_cmd : str_label); 221 str_key == "stylesmenu" ? str_cmd : str_label);
221 } // end of stylesdir 222 } // end of stylesdir
223 else if (str_key == "themesdir" || str_key == "themesmenu") {
224 createStyleMenu(menu, str_label,
225 str_key == "themesmenu" ? str_cmd : str_label);
226 } // end of themesdir
227
222 else if (str_key == "workspaces") { 228 else if (str_key == "workspaces") {
223 BScreen *screen = Fluxbox::instance()->findScreen(screen_number); 229 BScreen *screen = Fluxbox::instance()->findScreen(screen_number);
224 if (screen != 0) { 230 if (screen != 0) {