mirror of
https://projects.vdr-developer.org/git/vdr-plugin-skindesigner.git
synced 2023-10-19 17:58:31 +02:00
fixed bug that tokens in image pathes are not replaced correctly
This commit is contained in:
parent
4fe74f8439
commit
563a0485ee
1
HISTORY
1
HISTORY
@ -304,5 +304,6 @@ Version 0.4.3
|
||||
in displaychannel
|
||||
- added cardsystem name to ecm info
|
||||
- added correct menucategory for skin setups
|
||||
- fixed bug that tokens in image pathes are not replaced correctly
|
||||
|
||||
|
||||
|
@ -1292,6 +1292,12 @@ void cTemplateFunction::ParseStringParameters(void) {
|
||||
for (map < string, string >::iterator it = stringTokens->begin(); it != stringTokens->end(); it++) {
|
||||
size_t found = path.find(it->first);
|
||||
if (found != string::npos) {
|
||||
size_t posEndBracket = found + (it->first).size();
|
||||
if (posEndBracket < path.size()) {
|
||||
string endChar = path.substr(posEndBracket, 1);
|
||||
if (endChar.compare("}"))
|
||||
continue;
|
||||
}
|
||||
updated = true;
|
||||
imgPath = path;
|
||||
if (found > 0 && ((it->first).size() + 2 <= imgPath.size()))
|
||||
@ -1302,6 +1308,12 @@ void cTemplateFunction::ParseStringParameters(void) {
|
||||
for (map < string, int >::iterator it = intTokens->begin(); it != intTokens->end(); it++) {
|
||||
size_t found = path.find(it->first);
|
||||
if (found != string::npos) {
|
||||
size_t posEndBracket = found + (it->first).size();
|
||||
if (posEndBracket < path.size()) {
|
||||
string endChar = path.substr(posEndBracket, 1);
|
||||
if (endChar.compare("}"))
|
||||
continue;
|
||||
}
|
||||
updated = true;
|
||||
imgPath = path;
|
||||
if (found > 0 && ((it->first).size() + 2 <= imgPath.size())) {
|
||||
|
Loading…
Reference in New Issue
Block a user