Diffstat (limited to 'noncore/games/backgammon/themedialog.cpp') (more/less context) (show whitespace changes)
-rw-r--r-- | noncore/games/backgammon/themedialog.cpp | 2 |
1 files changed, 1 insertions, 1 deletions
diff --git a/noncore/games/backgammon/themedialog.cpp b/noncore/games/backgammon/themedialog.cpp index afd6a1b..9bdb6a9 100644 --- a/noncore/games/backgammon/themedialog.cpp +++ b/noncore/games/backgammon/themedialog.cpp | |||
@@ -98,64 +98,64 @@ void ThemeDialog::setCurrent(const ImageNames& current) | |||
98 | break; | 98 | break; |
99 | } | 99 | } |
100 | } | 100 | } |
101 | for(a=0;a<boxpiecesB->count();a++) | 101 | for(a=0;a<boxpiecesB->count();a++) |
102 | { | 102 | { |
103 | if(boxpiecesB->text(a)==current.pieces2) | 103 | if(boxpiecesB->text(a)==current.pieces2) |
104 | { | 104 | { |
105 | boxpiecesB->setCurrentItem(a); | 105 | boxpiecesB->setCurrentItem(a); |
106 | break; | 106 | break; |
107 | } | 107 | } |
108 | } | 108 | } |
109 | for(a=0;a<boxdiceA->count();a++) | 109 | for(a=0;a<boxdiceA->count();a++) |
110 | { | 110 | { |
111 | if(boxdiceA->text(a)==current.dice1) | 111 | if(boxdiceA->text(a)==current.dice1) |
112 | { | 112 | { |
113 | boxdiceA->setCurrentItem(a); | 113 | boxdiceA->setCurrentItem(a); |
114 | break; | 114 | break; |
115 | } | 115 | } |
116 | } | 116 | } |
117 | for(a=0;a<boxdiceB->count();a++) | 117 | for(a=0;a<boxdiceB->count();a++) |
118 | { | 118 | { |
119 | if(boxdiceB->text(a)==current.dice2) | 119 | if(boxdiceB->text(a)==current.dice2) |
120 | { | 120 | { |
121 | boxdiceB->setCurrentItem(a); | 121 | boxdiceB->setCurrentItem(a); |
122 | break; | 122 | break; |
123 | } | 123 | } |
124 | } | 124 | } |
125 | for(a=0;a<boxodds->count();a++) | 125 | for(a=0;a<boxodds->count();a++) |
126 | { | 126 | { |
127 | if(boxodds->text(a)==current.odds) | 127 | if(boxodds->text(a)==current.odds) |
128 | { | 128 | { |
129 | boxodds->setCurrentItem(a); | 129 | boxodds->setCurrentItem(a); |
130 | break; | 130 | break; |
131 | } | 131 | } |
132 | } | 132 | } |
133 | for(a=0;a<boxtable->count();a++) | 133 | for(a=0;a<boxtable->count();a++) |
134 | { | 134 | { |
135 | if(boxtable->text(a)==current.table) | 135 | if(boxtable->text(a)==current.table) |
136 | { | 136 | { |
137 | boxtable->setCurrentItem(a); | 137 | boxtable->setCurrentItem(a); |
138 | break; | 138 | break; |
139 | } | 139 | } |
140 | } | 140 | } |
141 | } | 141 | } |
142 | 142 | ||
143 | void ThemeDialog::fillBox(QString dirname,QComboBox* thebox) | 143 | void ThemeDialog::fillBox(QString dirname,QComboBox* thebox) |
144 | { | 144 | { |
145 | thebox->clear(); | 145 | thebox->clear(); |
146 | QDir dir(QPEApplication::qpeDir()+"/pics/backgammon/"+dirname); | 146 | QDir dir(QPEApplication::qpeDir()+"pics/backgammon/"+dirname); |
147 | dir.setFilter(QDir::Dirs | QDir::Files); | 147 | dir.setFilter(QDir::Dirs | QDir::Files); |
148 | QFileInfoListIterator it(*(dir.entryInfoList())); | 148 | QFileInfoListIterator it(*(dir.entryInfoList())); |
149 | QFileInfo* fi; | 149 | QFileInfo* fi; |
150 | 150 | ||
151 | while((fi=it.current())) // go through all file and subdirs | 151 | while((fi=it.current())) // go through all file and subdirs |
152 | { | 152 | { |
153 | QString file=fi->fileName(); | 153 | QString file=fi->fileName(); |
154 | if(file.right(4)==".png") | 154 | if(file.right(4)==".png") |
155 | { | 155 | { |
156 | thebox->insertItem(file.left(file.find(".png"))); | 156 | thebox->insertItem(file.left(file.find(".png"))); |
157 | } | 157 | } |
158 | ++it; | 158 | ++it; |
159 | } | 159 | } |
160 | delete fi; | 160 | delete fi; |
161 | } | 161 | } |