summaryrefslogtreecommitdiff
path: root/glcdskin
diff options
context:
space:
mode:
authorManuel Reimer <manuel.reimer@gmx.de>2016-10-29 09:22:14 +0200
committerManuel Reimer <manuel.reimer@gmx.de>2016-10-29 09:22:14 +0200
commit32effce985e7e9df08af7c80da35fec572648c4a (patch)
tree8c9d56fd8285d6c5a2ed80d300a5110f13b944a6 /glcdskin
parentc3faeb5adac3f38d5941d7918c22cfde068b9ead (diff)
downloadgraphlcd-base-32effce985e7e9df08af7c80da35fec572648c4a.tar.gz
graphlcd-base-32effce985e7e9df08af7c80da35fec572648c4a.tar.bz2
Pass tag name when requesting the scroll tag values
Diffstat (limited to 'glcdskin')
-rw-r--r--glcdskin/object.c31
1 files changed, 19 insertions, 12 deletions
diff --git a/glcdskin/object.c b/glcdskin/object.c
index 8af94f9..586251a 100644
--- a/glcdskin/object.c
+++ b/glcdskin/object.c
@@ -717,19 +717,23 @@ void cSkinObject::Render(GLCD::cBitmap * screen)
int currScrollTime = 500;
// get default values from derived config-class if available
- tSkinToken token = tSkinToken();
- token.Id = mSkin->Config().GetTokenId("ScrollMode");
- if (token.Id >= 0) {
+ int tokenid;
+ tSkinToken token;
+ tokenid = mSkin->Config().GetTokenId("ScrollMode");
+ if (tokenid >= 0) {
+ token = tSkinToken(tokenid, "ScrollMode", 0, "");
cType t = mSkin->Config().GetToken(token);
currScrollLoopMode = (int)(t);
}
- token.Id = mSkin->Config().GetTokenId("ScrollSpeed");
- if (token.Id >= 0) {
+ tokenid = mSkin->Config().GetTokenId("ScrollSpeed");
+ if (tokenid >= 0) {
+ token = tSkinToken(tokenid, "ScrollSpeed", 0, "");
cType t = mSkin->Config().GetToken(token);
currScrollSpeed = (int)(t);
}
- token.Id = mSkin->Config().GetTokenId("ScrollTime");
- if (token.Id >= 0) {
+ tokenid = mSkin->Config().GetTokenId("ScrollTime");
+ if (tokenid >= 0) {
+ token = tSkinToken(tokenid, "ScrollTime", 0, "");
cType t = mSkin->Config().GetToken(token);
currScrollTime = (int)(t);
}
@@ -1142,14 +1146,17 @@ bool cSkinObject::NeedsUpdate(uint64_t CurrentTime)
}
// get default values from derived config-class if available
- tSkinToken token = tSkinToken();
- token.Id = mSkin->Config().GetTokenId("ScrollMode");
- if (token.Id >= 0) {
+ int tokenid;
+ tSkinToken token;
+ tokenid = mSkin->Config().GetTokenId("ScrollMode");
+ if (tokenid >= 0) {
+ token = tSkinToken(tokenid, "ScrollMode", 0, "");
cType t = mSkin->Config().GetToken(token);
currScrollLoopMode = (int)(t);
}
- token.Id = mSkin->Config().GetTokenId("ScrollTime");
- if (token.Id >= 0) {
+ tokenid = mSkin->Config().GetTokenId("ScrollTime");
+ if (tokenid >= 0) {
+ token = tSkinToken(tokenid, "ScrollTime", 0, "");
cType t = mSkin->Config().GetToken(token);
currScrollTime = (int)(t);
}