redesigned animations

This commit is contained in:
louis 2016-07-22 15:21:09 +02:00
parent 4f3c24df7b
commit a79af20c34
70 changed files with 1484 additions and 827 deletions

View File

@ -21,6 +21,8 @@ cDesignerConfig::cDesignerConfig() {
rerunMaxChannel = 0; rerunMaxChannel = 0;
//max number of custom int and string tokens //max number of custom int and string tokens
numCustomTokens = 10; numCustomTokens = 10;
//Frames per Second to display animations
FPS = 50;
//remember current skin and theme, osd size and osd fonts //remember current skin and theme, osd size and osd fonts
SetSkin(); SetSkin();
SetOSDSize(); SetOSDSize();
@ -512,6 +514,7 @@ bool cDesignerConfig::SetupParse(const char *Name, const char *Value) {
else if (!strcasecmp(Name, "RerunDistance")) rerunDistance = atoi(Value); else if (!strcasecmp(Name, "RerunDistance")) rerunDistance = atoi(Value);
else if (!strcasecmp(Name, "RerunMaxChannel")) rerunMaxChannel = atoi(Value); else if (!strcasecmp(Name, "RerunMaxChannel")) rerunMaxChannel = atoi(Value);
else if (!strcasecmp(Name, "NumCustomTokens")) numCustomTokens = atoi(Value); else if (!strcasecmp(Name, "NumCustomTokens")) numCustomTokens = atoi(Value);
else if (!strcasecmp(Name, "FPS")) FPS = atoi(Value);
else pluginSetupParam = false; else pluginSetupParam = false;
if (!pluginSetupParam) { if (!pluginSetupParam) {

View File

@ -114,6 +114,7 @@ public:
int rerunDistance; int rerunDistance;
int rerunMaxChannel; int rerunMaxChannel;
int numCustomTokens; int numCustomTokens;
int FPS;
//TemplateReload on Setup Close //TemplateReload on Setup Close
bool setupCloseDoReload; bool setupCloseDoReload;
}; };

View File

@ -1,220 +1,40 @@
#include "../config.h"
#include "animation.h" #include "animation.h"
#include <math.h> #include <math.h>
/****************************************************************** /******************************************************************
* cAnimation * cDetacher
******************************************************************/ ******************************************************************/
cAnimation::cAnimation(cScrollable *scrollable) : cThread("scroller") { cDetacher::cDetacher(cDetachable *detachable, bool wait, bool animation) : cThread("detacher thread") {
this->scrollable = scrollable;
this->detachable = NULL;
this->fadable = NULL;
this->shiftable = NULL;
this->blinkable = NULL;
waitOnWakeup = false;
keepSleeping = false;
doAnimation = true;
modeIn = false;
blinkFunc = -1;
}
cAnimation::cAnimation(cDetachable *detachable, bool wait, bool animation) : cThread("detached") {
this->scrollable = NULL;
this->detachable = detachable; this->detachable = detachable;
this->fadable = NULL;
this->shiftable = NULL;
this->blinkable = NULL;
waitOnWakeup = wait; waitOnWakeup = wait;
keepSleeping = false; keepSleeping = false;
doAnimation = animation; doAnimation = animation;
modeIn = false;
blinkFunc = -1;
} }
cAnimation::cAnimation(cFadable *fadable, bool fadein) : cThread("fadable") { cDetacher::~cDetacher(void) {
this->scrollable = NULL;
this->detachable = NULL;
this->fadable = fadable;
this->shiftable = NULL;
this->blinkable = NULL;
waitOnWakeup = false;
keepSleeping = false;
doAnimation = true;
modeIn = fadein;
blinkFunc = -1;
}
cAnimation::cAnimation(cShiftable *shiftable, cPoint &start, cPoint &end, bool shiftin) : cThread("shiftable") {
this->scrollable = NULL;
this->detachable = NULL;
this->fadable = NULL;
this->shiftable = shiftable;
this->blinkable = NULL;
waitOnWakeup = false;
keepSleeping = false;
doAnimation = true;
modeIn = shiftin;
shiftstart = start;
shiftend = end;
blinkFunc = -1;
}
cAnimation::cAnimation(cBlinkable *blinkable, int func) : cThread("blinking") {
this->scrollable = NULL;
this->detachable = NULL;
this->fadable = NULL;
this->shiftable = NULL;
this->blinkable = blinkable;
waitOnWakeup = false;
keepSleeping = false;
doAnimation = true;
modeIn = false;
blinkFunc = func;
}
cAnimation::~cAnimation(void) {
sleepWait.Signal(); sleepWait.Signal();
Cancel(2); Cancel(2);
} }
void cAnimation::WakeUp(void) { void cDetacher::WakeUp(void) {
sleepWait.Signal(); sleepWait.Signal();
} }
void cAnimation::ResetSleep(void) { void cDetacher::ResetSleep(void) {
keepSleeping = true; keepSleeping = true;
sleepWait.Signal(); sleepWait.Signal();
} }
void cAnimation::Stop(bool deletePixmaps) { void cDetacher::Stop(bool deletePixmaps) {
sleepWait.Signal(); sleepWait.Signal();
Cancel(2); Cancel(2);
if (scrollable && deletePixmaps)
scrollable->StopScrolling();
} }
void cAnimation::Action(void) { void cDetacher::Action(void) {
if (scrollable) { if (!detachable) {
Scroll();
scrollable->UnregisterAnimation();
} else if (detachable) {
Detach();
} else if (fadable) {
Fade();
fadable->UnregisterAnimation();
} else if (shiftable) {
Shift();
shiftable->UnregisterAnimation();
} else if (blinkable) {
blinkable->RegisterAnimation();
Blink();
blinkable->UnregisterAnimation();
}
}
void cAnimation::Sleep(int duration) {
//sleep should wake up itself, so no infinit wait allowed
if (duration <= 0)
return; return;
do {
keepSleeping = false;
sleepWait.Wait(duration);
} while (keepSleeping);
} }
void cAnimation::Wait(void) {
//wait has to be waked up from outside
sleepWait.Wait(0);
}
void cAnimation::Scroll(void) {
int delay = scrollable->ScrollDelay();
Sleep(delay);
scrollable->RegisterAnimation();
if (!Running()) return;
eOrientation orientation = scrollable->ScrollOrientation();
int scrollTotal = 0;
if (orientation == eOrientation::horizontal) {
scrollTotal = scrollable->ScrollWidth();
} else if (orientation == eOrientation::vertical) {
scrollTotal = scrollable->ScrollHeight();
}
eScrollMode mode = scrollable->ScrollMode();
bool carriageReturn = (mode == eScrollMode::carriagereturn) ? true : false;
eScrollSpeed speed = scrollable->ScrollSpeed();
int frameTime = 30;
if (speed == eScrollSpeed::slow)
frameTime = 50;
else if (speed == eScrollSpeed::medium)
frameTime = 30;
else if (speed == eScrollSpeed::fast)
frameTime = 15;
if (!Running()) return;
scrollable->StartScrolling();
int drawPortX = 0;
int drawPortY = 0;
int scrollDelta = 1;
bool doSleep = false;
while (Running()) {
if (doSleep) {
Sleep(delay);
doSleep = false;
}
if (!Running()) return;
uint64_t now = cTimeMs::Now();
cPoint drawPortPoint(0,0);
if (orientation == eOrientation::horizontal) {
drawPortX -= scrollDelta;
if (abs(drawPortX) > scrollTotal) {
Sleep(delay);
if (carriageReturn) {
drawPortX = 0;
doSleep = true;
} else {
scrollDelta *= -1;
drawPortX -= scrollDelta;
}
}
drawPortPoint.SetX(drawPortX);
} else if (orientation == eOrientation::vertical) {
drawPortY -= scrollDelta;
if (abs(drawPortY) > scrollTotal) {
Sleep(delay);
drawPortY = 0;
doSleep = true;
}
drawPortPoint.SetY(drawPortY);
}
if (!Running()) return;
scrollable->SetDrawPort(drawPortPoint);
if (!Running()) return;
scrollable->Flush(true);
if (orientation == eOrientation::horizontal && !carriageReturn && (drawPortX == 0)) {
scrollDelta *= -1;
doSleep = true;
}
int delta = cTimeMs::Now() - now;
if (delta < frameTime)
Sleep(frameTime - delta);
}
}
void cAnimation::Detach(void) {
if (waitOnWakeup) { if (waitOnWakeup) {
Wait(); Wait();
int delay = 50 + detachable->Delay(); int delay = 50 + detachable->Delay();
@ -224,155 +44,625 @@ void cAnimation::Detach(void) {
if (delay > 0) if (delay > 0)
Sleep(delay); Sleep(delay);
} }
//if (!Running()) return;
detachable->ParseDetached(); detachable->ParseDetached();
//if (!Running()) return;
detachable->RenderDetached(); detachable->RenderDetached();
//if (!Running()) return;
if (!doAnimation) if (!doAnimation)
detachable->Flush(false); detachable->Flush();
if (!Running()) return; if (!Running()) return;
if (doAnimation) { if (doAnimation) {
detachable->StartAnimation(); detachable->StartAnimation();
} }
} }
void cAnimation::Fade(void) { void cDetacher::Sleep(int duration) {
int fadetime = fadable->FadeTime(); if (duration <= 0)
int frametime = 1000 / FPS; return;
int step = 100.0f / ((double)fadetime / (double)frametime); do {
uint64_t start = cTimeMs::Now(); keepSleeping = false;
int transparency = 0; sleepWait.Wait(duration);
if (modeIn) { } while (keepSleeping);
transparency = 100 - step; }
void cDetacher::Wait(void) {
//wait has to be waked up from outside
sleepWait.Wait(0);
}
/******************************************************************
* cAnimaton
******************************************************************/
cAnimation::cAnimation(void) {
started = 0;
finished = false;
persistent = false;
frametime = 1000 / config.FPS;
}
cAnimation::~cAnimation(void) {
}
/******************************************************************
* cScroller
******************************************************************/
cScroller::cScroller(cScrollable *scrollable) {
this->scrollable = scrollable;
paused = true;
pauseTime = 0;
scrollingStarted = false;
secondDelay = false;
delScrollPix = true;
Init();
}
cScroller::~cScroller(void) {
}
void cScroller::Init(void) {
delay = scrollable->ScrollDelay();
orientation = scrollable->ScrollOrientation();
if (orientation == eOrientation::horizontal) {
scrollLength = scrollable->ScrollWidth();
} else if (orientation == eOrientation::vertical) {
scrollLength = scrollable->ScrollHeight();
}
eScrollMode mode = scrollable->ScrollMode();
carriageReturn = (mode == eScrollMode::carriagereturn) ? true : false;
drawPortX = 0.0f;
drawPortY = 0.0f;
eScrollSpeed speed = scrollable->ScrollSpeed();
if (speed == eScrollSpeed::slow)
scrollDelta = 0.5f;
else if (speed == eScrollSpeed::fast)
scrollDelta = 2.0f;
else
scrollDelta = 1.0f;
}
void cScroller::Reactivate(void) {}
void cScroller::SetInitial(void) {}
bool cScroller::Pause(void) {
if (!paused)
return false;
if ((pauseTime + frametime) > delay) {
paused = false;
pauseTime = 0;
return false;
}
pauseTime += frametime;
return true;
}
bool cScroller::Overflow(void) {
if (orientation == eOrientation::horizontal) {
if (!carriageReturn && (drawPortX >= 1)) {
drawPortX = 0;
scrollDelta *= -1;
paused = true;
return true;
}
if (carriageReturn && (drawPortX >= 0) && secondDelay) {
cPoint drawPortPoint(drawPortX,0);
scrollable->SetDrawPort(drawPortPoint);
drawPortX = -1;
paused = true;
secondDelay = false;
return true;
}
if (abs(drawPortX) < scrollLength)
return false;
if (carriageReturn) {
drawPortX = 0;
secondDelay = true;
} else { } else {
transparency = step; scrollDelta *= -1;
drawPortX -= scrollDelta;
} }
//wait configured delay if not already done by detacher } else if (orientation == eOrientation::vertical) {
if (!fadable->Detached()) { if ((drawPortY >= 0) && secondDelay) {
int delay = fadable->Delay(); cPoint drawPortPoint(0, drawPortY);
if (delay > 0) scrollable->SetDrawPort(drawPortPoint);
Sleep(delay); drawPortY = -1;
paused = true;
secondDelay = false;
return true;
} }
fadable->RegisterAnimation(); if (abs(drawPortY) < scrollLength)
while (Running() || !modeIn) { return false;
uint64_t now = cTimeMs::Now(); secondDelay = true;
if (Running() || !modeIn) drawPortY = 0;
fadable->SetTransparency(transparency, !modeIn);
if (Running() || !modeIn)
fadable->Flush(true);
int delta = cTimeMs::Now() - now;
if ((Running() || !modeIn) && (delta < frametime)) {
Sleep(frametime - delta);
} }
if ((int)(now - start) > fadetime) { paused = true;
if ((Running() && modeIn) && transparency > 0) { return true;
fadable->SetTransparency(0);
fadable->Flush(true);
} else if (!modeIn && transparency < 100) {
fadable->SetTransparency(100, true);
fadable->Flush(true);
} }
break;
void cScroller::SetFinished(void) {
finished = true;
if (delScrollPix) {
scrollable->StopScrolling();
} }
if (modeIn) { }
transparency -= step;
if (transparency < 0) bool cScroller::Tick(void) {
if (finished) {
return false;
}
if (Pause())
return true;
if (!scrollingStarted) {
scrollable->StartScrolling();
scrollingStarted = true;
}
if (Overflow())
return true;
cPoint drawPortPoint(0,0);
if (orientation == eOrientation::horizontal) {
drawPortX -= scrollDelta;
drawPortPoint.SetX(drawPortX);
} else if (orientation == eOrientation::vertical) {
drawPortY -= scrollDelta;
drawPortPoint.SetY(drawPortY);
}
scrollable->SetDrawPort(drawPortPoint);
return true;
};
/******************************************************************
* cFader
******************************************************************/
cFader::cFader(cFadable *fadable) {
this->fadable = fadable;
fadein = true;
fadetime = fadable->FadeTime();
step = 100.0f / ((double)fadetime / (double)frametime);
transparency = 100;
hideWhenFinished = false;
}
cFader::~cFader(void) {
}
void cFader::Reactivate(void) {
started = 0;
finished = false;
fadein = false;
}
void cFader::SetInitial(void) {
fadable->SetTransparency(transparency);
}
void cFader::SetFadeOut(void) {
fadein = false;
transparency = 0; transparency = 0;
}
void cFader::SetFinished(void) {
finished = true;
if (hideWhenFinished)
fadable->SetTransparency(100);
}
bool cFader::Tick(void) {
if (finished) {
if (fadein)
fadable->SetTransparency(0);
else
fadable->SetTransparency(100);
return false;
}
if (!started) {
started = cTimeMs::Now();
}
if ((int)(cTimeMs::Now() - started) > fadetime) {
if (fadein)
fadable->SetTransparency(0);
else
fadable->SetTransparency(100);
finished = true;
return false;
}
fadable->SetTransparency(transparency);
if (fadein) {
transparency -= step;
} else { } else {
transparency += step; transparency += step;
if (transparency > 100)
transparency = 100;
}
} }
return true;
};
/******************************************************************
* cShifter
******************************************************************/
cShifter::cShifter(cShiftable *shiftable) {
this->shiftable = shiftable;
step = 0;
shiftin = true;
shifttime = 0;
x = 0.0f;
y = 0.0f;
stepXLinear = 0;
stepYLinear = 0;
stepsFast = 0;
stepXFast = 0;
stepXSlow = 0;
stepYFast = 0;
stepYSlow = 0;
Init();
} }
void cAnimation::Shift(void) { cShifter::~cShifter(void) {
int shifttime = shiftable->ShiftTime(); }
eShiftMode mode = (eShiftMode)shiftable->ShiftMode();
//in shiftmode slowedDown shifting is done starting with slowratio % faster
//at start. Then speed reduces linear to (100 - slowratio)% at end
//for me 60 is a nice value :-)
int slowRatio = 60;
int frametime = 1000 / FPS; void cShifter::Init(void) {
shifttime = shiftable->ShiftTime();
mode = (eShiftMode)shiftable->ShiftMode();
shiftable->ShiftPositions(&start, &end);
int steps = (double)shifttime / (double)frametime; int steps = (double)shifttime / (double)frametime;
if (steps < 2) float percentFast = 33.3f;
return; float distanceFast = 85.0f;
int stepXLinear = 0; stepsFast = (float)steps * percentFast / 100.0f;
int stepYLinear = 0; if (start.X() == end.X()) {
if (shiftstart.X() == shiftend.X()) { stepYLinear = (float)(end.Y() - start.Y()) / (float)steps;
stepYLinear = (shiftend.Y() - shiftstart.Y()) / steps; stepYFast = (float)(end.Y() - start.Y()) * distanceFast / 100.0f / (float)stepsFast;
} else if (shiftstart.Y() == shiftend.Y()) { stepYSlow = (float)(end.Y() - start.Y()) * (100.0f - distanceFast) / 100.0f / (float)(steps-stepsFast);
stepXLinear = (shiftend.X() - shiftstart.X()) / steps; } else if (start.Y() == end.Y()) {
stepXLinear = (end.X() - start.X()) / steps;
stepXFast = (float)(end.X() - start.X()) * distanceFast / 100.0f / (float)stepsFast;
stepXSlow = (float)(end.X() - start.X()) * (100.0f - distanceFast) / 100.0f / (float)(steps-stepsFast);
} else { } else {
stepXLinear = (shiftend.X() - shiftstart.X()) / steps; stepXLinear = (end.X() - start.X()) / steps;
stepYLinear = (shiftend.Y() - shiftstart.Y()) / steps; stepXFast = (float)(end.X() - start.X()) * distanceFast / 100.0f / (float)stepsFast;
stepXSlow = (float)(end.X() - start.X()) * (100.0f - distanceFast) / 100.0f / (float)(steps-stepsFast);
stepYLinear = (end.Y() - start.Y()) / steps;
stepYFast = (float)(end.Y() - start.Y()) * distanceFast / 100.0f / (float)stepsFast;
stepYSlow = (float)(end.Y() - start.Y()) * (100.0f - distanceFast) / 100.0f / (float)(steps-stepsFast);
}
x = start.X();
y = start.Y();
} }
int stepX = stepXLinear;
int stepY = stepYLinear;
cPoint pos; void cShifter::Reactivate(void) {
if (modeIn) started = 0;
pos = shiftstart; finished = false;
shiftin = false;
step = 0;
}
void cShifter::SetInitial(void) {
cPoint pos(x, y);
shiftable->SetPosition(pos, end);
}
void cShifter::NextPosition(void) {
if (mode == eShiftMode::linear) {
if (shiftin) {
x += stepXLinear;
y += stepYLinear;
} else {
x -= stepXLinear;
y -= stepYLinear;
}
} else if (mode == eShiftMode::slowedDown) {
if (shiftin) {
if (step <= stepsFast) {
x += stepXFast;
y += stepYFast;
} else {
x += stepXSlow;
y += stepYSlow;
}
} else {
if (step <= stepsFast) {
x -= stepXFast;
y -= stepYFast;
} else {
x -= stepXSlow;
y -= stepYSlow;
}
}
}
}
bool cShifter::Tick(void) {
if (finished)
return false;
if (!started) {
started = cTimeMs::Now();
}
if ((int)(cTimeMs::Now() - started) > shifttime) {
if (shiftin)
shiftable->SetPosition(end, end);
else else
pos = shiftend; shiftable->SetPosition(start, end);
//wait configured delay if not already done by detacher
if (!shiftable->Detached()) {
int delay = shiftable->Delay();
if (delay > 0)
Sleep(delay);
}
shiftable->RegisterAnimation();
shiftable->SetStartShifting();
uint64_t start = cTimeMs::Now();
bool finished = false;
while (Running() || !modeIn) {
uint64_t now = cTimeMs::Now();
if (Running() || !modeIn)
shiftable->SetPosition(pos, shiftend);
if (Running() || !modeIn)
shiftable->Flush(true);
int delta = cTimeMs::Now() - now;
if ((Running() || !modeIn) && (delta < frametime)) {
cCondWait::SleepMs(frametime - delta);
}
if ((int)(now - start) > shifttime) {
finished = true; finished = true;
if ((Running() && modeIn) && pos != shiftend) { return false;
shiftable->SetPosition(shiftend, shiftend);
shiftable->Flush(true);
} }
cPoint pos(x, y);
shiftable->SetPosition(pos, end);
step++;
NextPosition();
return true;
};
/******************************************************************
* cListShifter
******************************************************************/
cListShifter::cListShifter(cListShiftable *shiftable) {
this->shiftable = shiftable;
shifttime = shiftable->ListShiftTime();
distance = shiftable->ShiftDistance();
orientation = shiftable->ShiftOrientation();
int steps = (double)shifttime / (double)frametime;
step = distance / steps;
shiftin = true;
fromtop = true;
}
cListShifter::~cListShifter(void) {
}
void cListShifter::Reactivate(void) {}
void cListShifter::SetInitial(void) {
if (shiftin) {
if (orientation == eOrientation::horizontal) {
if (fromtop) {
pos.SetX(-1 * distance);
pos.SetY(0);
} else {
pos.SetX(distance);
pos.SetY(0);
}
} else {
if (fromtop) {
pos.SetX(0);
pos.SetY(-1 * distance);
} else {
pos.SetX(0);
pos.SetY(distance);
}
}
}
shiftable->SetIndicatorPosition(pos);
}
void cListShifter::NextPosition(void) {
int x = pos.X();
int y = pos.Y();
if (orientation == eOrientation::horizontal) {
if (fromtop) {
pos.SetX(x+step);
} else {
pos.SetX(x-step);
}
} else {
if (fromtop) {
pos.SetY(y+step);
} else {
pos.SetY(y-step);
}
}
}
void cListShifter::EndPosition(void) {
if (shiftin) {
pos.SetX(0);
pos.SetY(0);
} else {
if (orientation == eOrientation::horizontal) {
pos.SetX(distance);
} else {
pos.SetY(distance);
}
}
shiftable->SetIndicatorPosition(pos);
}
bool cListShifter::Tick(void) {
if (finished) {
EndPosition();
return false;
}
if (!started) {
started = cTimeMs::Now();
}
if ((int)(cTimeMs::Now() - started) > shifttime) {
EndPosition();
finished = true;
return false;
}
shiftable->SetIndicatorPosition(pos);
NextPosition();
return true;
};
/******************************************************************
* cBlinker
******************************************************************/
cBlinker::cBlinker(cBlinkable *blinkable, int blinkFunc) {
this->blinkable = blinkable;
this->blinkFunc = blinkFunc;
freq = blinkable->BlinkFreq(blinkFunc);
blinkOn = false;
paused = true;
pauseTime = 0;
}
cBlinker::~cBlinker(void) {
}
void cBlinker::Reactivate(void) {}
void cBlinker::SetInitial(void) {}
bool cBlinker::Pause(void) {
if (!paused)
return false;
if ((pauseTime + frametime) > freq) {
paused = false;
pauseTime = 0;
return false;
}
pauseTime += frametime;
return true;
}
bool cBlinker::Tick(void) {
if (finished)
return false;
if (Pause())
return true;
blinkable->DoBlink(blinkFunc, blinkOn);
blinkOn = !blinkOn;
paused = true;
pauseTime = 0;
return true;
};
/******************************************************************
* cAnimator
******************************************************************/
cAnimator::cAnimator(cSdOsd *osd) : cThread("animator thread") {
this->osd = osd;
timeneeded = 0;
timeslice = 1000 / config.FPS;
}
cAnimator::~cAnimator(void) {
Stop();
}
void cAnimator::Sleep(uint64_t start) {
timeneeded = cTimeMs::Now() - start;
int sleepTime = (timeslice - timeneeded) > 0 ? timeslice - timeneeded : 0;
if (sleepTime)
sleepWait.Wait(sleepTime);
}
void cAnimator::DoTick(bool &animActive) {
animLock.Lock();
for (cAnimation *animation = animations.First(); animation; animation = animations.Next(animation)) {
if (Running()) {
bool currentAnimActive = animation->Tick();
animActive = animActive || currentAnimActive;
}
}
animLock.Unlock();
}
/*****************************************************************************************
* Cleanup Anims
* removes finished anims
* remembers persistent anims
*****************************************************************************************/
void cAnimator::CleanupAnims(void) {
bool found;
animLock.Lock();
do {
found = false;
for (cAnimation *animation = animations.First(); animation; animation = animations.Next(animation)) {
if (!animation->Finished())
continue;
if (animation->Persistent()) {
animations.Del(animation, false);
animationsPersistent.Add(animation);
} else {
animations.Del(animation);
}
found = true;
break; break;
} }
if (mode == eShiftMode::slowedDown) { } while (found);
double t = (double)(now - start) / (double)shifttime; animLock.Unlock();
double factor = 1.0f + (double)slowRatio / 100.0f - 2.0f * ((double)slowRatio / 100.0f) * t;
stepX = stepXLinear * factor;
stepY = stepYLinear * factor;
}
if (modeIn) {
pos.Set(pos.X() + stepX, pos.Y() + stepY);
} else {
pos.Set(pos.X() - stepX, pos.Y() - stepY);
}
}
if (!finished) {
shiftable->SetPosition(shiftend, shiftend);
}
shiftable->SetEndShifting();
} }
void cAnimation::Blink(void) { /*****************************************************************************************
int freq = blinkable->BlinkFreq(blinkFunc); * Main Loop
bool blinkOn = false; *****************************************************************************************/
void cAnimator::Action(void) {
while(Running()) { while(Running()) {
Sleep(freq); bool animActive = false;
if (Running()) uint64_t start = cTimeMs::Now();
blinkable->DoBlink(blinkFunc, blinkOn); DoTick(animActive); if (!Running()) break;
if (Running()) osd->Flush(); if (!Running()) break;
blinkable->Flush(true); CleanupAnims(); if (!Running()) break;
blinkOn = !blinkOn; if (!animActive) {
pauseWait.Wait();
} else {
Sleep(start);
}
}
}
/*****************************************************************************************
* Add Animation
* if startAnim is set to true, main loop gets waked up
*****************************************************************************************/
void cAnimator::AddAnimation(cAnimation *animation, bool startAnim) {
animation->SetInitial();
animLock.Lock();
animations.Ins(animation);
animLock.Unlock();
if (startAnim)
pauseWait.Signal();
}
/*****************************************************************************************
* Remove Animation
* animation will be set to finished and removed later by Cleanup()
*****************************************************************************************/
void cAnimator::RemoveAnimation(cAnimation *remove) {
animLock.Lock();
for (cAnimation *animation = animations.First(); animation; animation = animations.Next(animation)) {
if (animation == remove) {
animation->SetFinished();
break;
}
}
animLock.Unlock();
}
/*****************************************************************************************
* Finish Main Loop
*****************************************************************************************/
void cAnimator::Stop(void) {
if (!Running())
return;
Cancel(-1);
pauseWait.Signal();
sleepWait.Signal();
Cancel(2);
}
/*****************************************************************************************
* shift or fade out persistent animations
*****************************************************************************************/
void cAnimator::Finish(void) {
bool animActive = true;
bool reactivate = true;
while(animActive) {
animActive = false;
uint64_t start = cTimeMs::Now();
animLock.Lock();
for (cAnimation *animation = animationsPersistent.First(); animation; animation = animationsPersistent.Next(animation)) {
if (reactivate)
animation->Reactivate();
bool currentAnimActive = animation->Tick();
animActive = animActive || currentAnimActive;
}
animLock.Unlock();
reactivate = false;
osd->Flush();
if (!animActive)
break;
Sleep(start);
} }
} }

View File

@ -4,11 +4,64 @@
#include <vdr/skins.h> #include <vdr/skins.h>
#include <vdr/thread.h> #include <vdr/thread.h>
#include "definitions.h" #include "definitions.h"
#include "osdwrapper.h"
#define FPS 50
/****************************************************************** /******************************************************************
* cScrollable * Detaching
******************************************************************/
class cDetachable {
protected:
cDetachable(void) {};
~cDetachable(void) {};
public:
virtual int Delay(void) = 0;
virtual void StartAnimation(void) = 0;
virtual void ParseDetached(void) = 0;
virtual void RenderDetached(void) = 0;
virtual void Flush(void) = 0;
};
class cDetacher : public cThread, public cListObject {
private:
cCondWait sleepWait;
cDetachable *detachable;
bool waitOnWakeup;
bool keepSleeping;
bool doAnimation;
void Sleep(int duration);
void Wait(void);
virtual void Action(void);
public:
cDetacher(cDetachable *detachable, bool wait, bool animation);
~cDetacher(void);
void WakeUp(void);
void ResetSleep(void);
void Stop(bool deletePixmaps);
};
/******************************************************************
* cAnimation
******************************************************************/
class cAnimation : public cListObject {
protected:
uint64_t started;
bool finished;
bool persistent;
int frametime;
public:
cAnimation(void);
virtual ~cAnimation(void);
virtual void SetInitial(void) = 0;
virtual void Reactivate(void) = 0;
virtual bool Tick(void) = 0;
bool Finished(void) { return finished; };
virtual void SetFinished(void) { finished = true; };
void SetPersistent(void) { persistent = true; };
bool Persistent(void) { return persistent; };
};
/******************************************************************
* Scrolling
******************************************************************/ ******************************************************************/
class cScrollable { class cScrollable {
protected: protected:
@ -24,67 +77,140 @@ public:
virtual void StartScrolling(void) = 0; virtual void StartScrolling(void) = 0;
virtual void StopScrolling(void) = 0; virtual void StopScrolling(void) = 0;
virtual void SetDrawPort(cPoint &point) = 0; virtual void SetDrawPort(cPoint &point) = 0;
virtual void RegisterAnimation(void) = 0;
virtual void UnregisterAnimation(void) = 0;
virtual void Flush(bool animFlush) = 0;
}; };
/****************************************************************** class cScroller : public cAnimation {
* cDetachable private:
******************************************************************/ cScrollable *scrollable;
class cDetachable { int delay;
protected: bool paused;
cDetachable(void) {}; int pauseTime;
~cDetachable(void) {}; bool scrollingStarted;
bool secondDelay;
eOrientation orientation;
int scrollLength;
bool carriageReturn;
float drawPortX;
float drawPortY;
float scrollDelta;
bool delScrollPix;
void Init(void);
bool Pause(void);
bool Overflow(void);
public: public:
virtual int Delay(void) = 0; cScroller(cScrollable *scrollable);
virtual void ParseDetached(void) = 0; ~cScroller(void);
virtual void RenderDetached(void) = 0; void SetInitial(void);
virtual void StartAnimation(void) = 0; void Reactivate(void);
virtual void RegisterAnimation(void) = 0; void SetFinished(void);
virtual void UnregisterAnimation(void) = 0; void UnsetDelScrollPix(void) { delScrollPix = false; };
virtual void Flush(bool animFlush) = 0; bool Tick(void);
}; };
/****************************************************************** /******************************************************************
* cFadable * Fading
******************************************************************/ ******************************************************************/
class cFadable { class cFadable {
protected: protected:
cFadable(void) {}; cFadable(void) {};
~cFadable(void) {}; ~cFadable(void) {};
public: public:
virtual bool Detached(void) = 0;
virtual int Delay(void) = 0; virtual int Delay(void) = 0;
virtual int FadeTime(void) = 0; virtual int FadeTime(void) = 0;
virtual void SetTransparency(int transparency, bool force = false) = 0; virtual void SetTransparency(int transparency, bool force = false) = 0;
virtual void RegisterAnimation(void) = 0;
virtual void UnregisterAnimation(void) = 0;
virtual void Flush(bool animFlush) = 0;
}; };
class cFader : public cAnimation {
private:
cFadable *fadable;
bool fadein;
int fadetime;
int step;
int transparency;
bool hideWhenFinished;
public:
cFader(cFadable *fadable);
~cFader(void);
void SetInitial(void);
void Reactivate(void);
void SetFadeOut(void);
void SetFinished(void);
void SetHideWhenFinished(void) { hideWhenFinished = true; };
bool Tick(void);
};
/****************************************************************** /******************************************************************
* cShiftable * Shifting
******************************************************************/ ******************************************************************/
class cShiftable { class cShiftable {
protected: protected:
cShiftable(void) {}; cShiftable(void) {};
~cShiftable(void) {}; ~cShiftable(void) {};
public: public:
virtual bool Detached(void) = 0;
virtual int Delay(void) = 0; virtual int Delay(void) = 0;
virtual int ShiftTime(void) = 0; virtual int ShiftTime(void) = 0;
virtual int ShiftMode(void) = 0; virtual int ShiftMode(void) = 0;
virtual void ShiftPositions(cPoint *start, cPoint *end) = 0;
virtual void SetPosition(cPoint &position, cPoint &reference, bool force = false) = 0; virtual void SetPosition(cPoint &position, cPoint &reference, bool force = false) = 0;
virtual void SetStartShifting(void) = 0; };
virtual void SetEndShifting(void) = 0;
virtual void RegisterAnimation(void) = 0; class cListShiftable {
virtual void UnregisterAnimation(void) = 0; protected:
virtual void Flush(bool animFlush) = 0; cListShiftable(void) {};
~cListShiftable(void) {};
public:
virtual int ListShiftTime(void) = 0;
virtual int ShiftDistance(void) = 0;
virtual eOrientation ShiftOrientation(void) = 0;
virtual void SetIndicatorPosition(cPoint &position) = 0;
};
class cShifter : public cAnimation {
private:
cShiftable *shiftable;
bool shiftin;
cPoint start, end;
int shifttime;
eShiftMode mode;
int step;
float stepXLinear, stepYLinear;
int stepsFast;
float stepXFast, stepXSlow;
float stepYFast, stepYSlow;
float x, y;
void Init(void);
void NextPosition(void);
public:
cShifter(cShiftable *shiftable);
~cShifter(void);
void SetInitial(void);
void Reactivate(void);
bool Tick(void);
};
class cListShifter : public cAnimation {
private:
cListShiftable *shiftable;
bool shiftin;
bool fromtop;
int distance;
eOrientation orientation;
int shifttime;
int step;
cPoint pos;
void NextPosition(void);
void EndPosition(void);
public:
cListShifter(cListShiftable *shiftable);
~cListShifter(void);
void SetInitial(void);
void Reactivate(void);
void SetShiftOut(void) { shiftin = false; };
void SetDirection(bool fromTop) { fromtop = fromTop; };
bool Tick(void);
}; };
/****************************************************************** /******************************************************************
* cBlinkable * Blinking
******************************************************************/ ******************************************************************/
class cBlinkable { class cBlinkable {
protected: protected:
@ -93,48 +219,49 @@ protected:
public: public:
virtual int BlinkFreq(int func) = 0; virtual int BlinkFreq(int func) = 0;
virtual void DoBlink(int func, bool on) = 0; virtual void DoBlink(int func, bool on) = 0;
virtual void RegisterAnimation(void) = 0; };
virtual void UnregisterAnimation(void) = 0;
virtual void Flush(bool animFlush) = 0; class cBlinker : public cAnimation {
private:
cBlinkable *blinkable;
int blinkFunc;
int freq;
bool blinkOn;
bool paused;
int pauseTime;
bool Pause(void);
public:
cBlinker(cBlinkable *blinkable, int blinkFunc);
~cBlinker(void);
void SetInitial(void);
void Reactivate(void);
bool Tick(void);
}; };
/****************************************************************** /******************************************************************
* cAnimation * cAnimator
******************************************************************/ ******************************************************************/
class cAnimation : public cThread, public cListObject { class cAnimator : public cThread {
private: private:
cSdOsd *osd;
cCondWait sleepWait; cCondWait sleepWait;
cScrollable *scrollable; cCondWait pauseWait;
cDetachable *detachable; int timeslice;
cFadable *fadable; int timeneeded;
cShiftable *shiftable; cMutex animLock;
cBlinkable *blinkable; cList<cAnimation> animations;
bool waitOnWakeup; cList<cAnimation> animationsPersistent;
bool keepSleeping; void Sleep(uint64_t start);
bool doAnimation; void DoTick(bool &animActive);
bool modeIn; void CleanupAnims(void);
int blinkFunc;
cPoint shiftstart;
cPoint shiftend;
void Sleep(int duration);
void Wait(void);
void Scroll(void);
void Detach(void);
void Blink(void);
protected:
virtual void Action(void); virtual void Action(void);
public: public:
cAnimation(cScrollable *scrollable); cAnimator(cSdOsd *osd);
cAnimation(cDetachable *detachable, bool wait, bool animation); ~cAnimator(void);
cAnimation(cFadable *fadable, bool fadein); void AddAnimation(cAnimation *animation, bool startAnim = true);
cAnimation(cShiftable *shiftable, cPoint &start, cPoint &end, bool shiftin); void RemoveAnimation(cAnimation *remove);
cAnimation(cBlinkable *blinkable, int func); void Stop(void);
~cAnimation(void); void Finish(void);
void WakeUp(void);
void ResetSleep(void);
void Fade(void);
void Shift(void);
void Stop(bool deletePixmaps);
}; };
#endif //__ANIMATION_H #endif //__ANIMATION_H

View File

@ -251,6 +251,17 @@ void cArea::Clear(bool forceClearBackground) {
return; return;
} }
StopBlinkers(); StopBlinkers();
if (pix) {
pix->SetDrawPortPoint(cPoint(0,0));
pix->Fill(clrTransparent);
}
}
void cArea::ClearWithoutIndicators(void) {
if (attribs->IndicatorArea()) {
return;
}
StopBlinkers();
if (pix) { if (pix) {
pix->Fill(clrTransparent); pix->Fill(clrTransparent);
} }
@ -335,6 +346,23 @@ void cArea::SetTransparency(int transparency, bool absolute) {
} }
} }
void cArea::SetIndicatorTransparency(int transparency) {
if (!attribs->IndicatorArea())
return;
if (transparency < 0 || transparency > 100)
return;
int alpha = (100 - transparency)*255/100;
if (pix) {
pix->SetAlpha(alpha);
}
}
void cArea::SetIndicatorPosition(cPoint &pos) {
if (!attribs->IndicatorArea())
return;
SetDrawPort(pos);
}
bool cArea::Scrolling(void) { bool cArea::Scrolling(void) {
if (!scrolling) if (!scrolling)
return false; return false;
@ -497,12 +525,6 @@ void cArea::Debug(bool full) {
} }
} }
void cArea::Flush(bool animFlush) {
if (animFlush)
sdOsd->AnimatedFlush();
else
sdOsd->Flush();
}
/****************************************************************** /******************************************************************
* Private Functions * Private Functions
******************************************************************/ ******************************************************************/
@ -565,9 +587,9 @@ void cArea::StartBlinkers(void) {
continue; continue;
} }
if (f->Blinking()) { if (f->Blinking()) {
cAnimation *blink = new cAnimation((cBlinkable*)this, func); cBlinker *blinker = new cBlinker((cBlinkable*)this, func);
blinkers.Add(blink); blinkers.push_back(blinker);
blink->Start(); cView::AddAnimation(blinker);
} }
func++; func++;
} }
@ -575,15 +597,10 @@ void cArea::StartBlinkers(void) {
void cArea::StopBlinkers(void) { void cArea::StopBlinkers(void) {
blinking = false; blinking = false;
blinkers.Clear(); for (list<cBlinker*>::iterator it = blinkers.begin(); it != blinkers.end(); it++) {
cView::RemoveAnimation(*it);
} }
blinkers.clear();
void cArea::RegisterAnimation(void) {
sdOsd->AddAnimation();
}
void cArea::UnregisterAnimation(void) {
sdOsd->RemoveAnimation();
} }
/****************************************************************** /******************************************************************
@ -707,6 +724,12 @@ void cAreaContainer::Clear(bool forceClearBackground) {
} }
} }
void cAreaContainer::ClearWithoutIndicators(void) {
for (cArea *area = areas.First(); area; area = areas.Next(area)) {
area->ClearWithoutIndicators();
}
}
void cAreaContainer::Hide(void) { void cAreaContainer::Hide(void) {
for (cArea *area = areas.First(); area; area = areas.Next(area)) { for (cArea *area = areas.First(); area; area = areas.Next(area)) {
area->Hide(); area->Hide();
@ -736,6 +759,18 @@ void cAreaContainer::SetTransparency(int transparency, bool absolute) {
} }
} }
void cAreaContainer::SetIndicatorTransparency(int transparency) {
for (cArea *area = areas.First(); area; area = areas.Next(area)) {
area->SetIndicatorTransparency(transparency);
}
}
void cAreaContainer::SetIndicatorPosition(cPoint &pos) {
for (cArea *area = areas.First(); area; area = areas.Next(area)) {
area->SetIndicatorPosition(pos);
}
}
void cAreaContainer::SetViewPort(cRect &vp) { void cAreaContainer::SetViewPort(cRect &vp) {
for (cArea *area = areas.First(); area; area = areas.Next(area)) { for (cArea *area = areas.First(); area; area = areas.Next(area)) {
area->SetViewPort(vp); area->SetViewPort(vp);

View File

@ -5,6 +5,7 @@
#include <stdio.h> #include <stdio.h>
#include <stdlib.h> #include <stdlib.h>
#include <stdint.h> #include <stdint.h>
#include <list>
#include "osdwrapper.h" #include "osdwrapper.h"
#include "definitions.h" #include "definitions.h"
@ -45,13 +46,16 @@ public:
virtual void Close(void) {}; virtual void Close(void) {};
virtual void StopBlinkers(void) {}; virtual void StopBlinkers(void) {};
virtual void Clear(bool forceClearBackground = false) {}; virtual void Clear(bool forceClearBackground = false) {};
virtual void ClearWithoutIndicators(void) {};
virtual void Hide(void) {}; virtual void Hide(void) {};
virtual void Show(void) {}; virtual void Show(void) {};
virtual void Render(void) {}; virtual void Render(void) {};
virtual bool Execute(void) { return true; }; virtual bool Execute(void) { return true; };
virtual void SetTransparency(int transparency, bool absolute = false) {}; virtual void SetTransparency(int transparency, bool absolute = false) {};
virtual void SetIndicatorTransparency(int transparency) {};
virtual void SetViewPort(cRect &vp) {}; virtual void SetViewPort(cRect &vp) {};
virtual void SetPosition(cPoint &pos, cPoint &ref) {}; virtual void SetPosition(cPoint &pos, cPoint &ref) {};
virtual void SetIndicatorPosition(cPoint &pos) {};
virtual cRect CoveringArea(void) { return cRect::Null; }; virtual cRect CoveringArea(void) { return cRect::Null; };
virtual bool Scrolling(void) { return false; }; virtual bool Scrolling(void) { return false; };
virtual cArea *ScrollingArea(void) { return NULL; }; virtual cArea *ScrollingArea(void) { return NULL; };
@ -77,7 +81,7 @@ private:
bool scrolling; bool scrolling;
bool isScrolling; bool isScrolling;
cFunction *scrollFunc; cFunction *scrollFunc;
cList<cAnimation> blinkers; list<cBlinker*> blinkers;
bool blinking; bool blinking;
void InitFunctions(void); void InitFunctions(void);
void CreatePixmap(cRect drawPort = cRect::Null); void CreatePixmap(cRect drawPort = cRect::Null);
@ -105,11 +109,15 @@ public:
int GetWidth(void) { return attribs->Width(); }; int GetWidth(void) { return attribs->Width(); };
void Close(void); void Close(void);
void Clear(bool forceClearBackground = false); void Clear(bool forceClearBackground = false);
void ClearWithoutIndicators(void);
void Hide(void); void Hide(void);
void Show(void); void Show(void);
void Render(void); void Render(void);
bool Execute(void); bool Execute(void);
bool IsIndicatorArea(void) { return attribs->IndicatorArea(); };
void SetTransparency(int transparency, bool absolute = false); void SetTransparency(int transparency, bool absolute = false);
void SetIndicatorTransparency(int transparency);
void SetIndicatorPosition(cPoint &pos);
cRect CoveringArea(void); cRect CoveringArea(void);
//Scrollable //Scrollable
bool Scrolling(void); bool Scrolling(void);
@ -133,11 +141,8 @@ public:
void DoBlink(int func, bool on); void DoBlink(int func, bool on);
void StopBlinkers(void); void StopBlinkers(void);
//Common //Common
void RegisterAnimation(void);
void UnregisterAnimation(void);
const char *Name(void) { return attribs->Name(); }; const char *Name(void) { return attribs->Name(); };
bool BackgroundArea(void) { return attribs->BackgroundArea(); }; bool BackgroundArea(void) { return attribs->BackgroundArea(); };
void Flush(bool animFlush);
void Debug(bool full = false); void Debug(bool full = false);
}; };
@ -165,11 +170,14 @@ public:
void Cache(void); void Cache(void);
void Close(void); void Close(void);
void Clear(bool forceClearBackground = false); void Clear(bool forceClearBackground = false);
void ClearWithoutIndicators(void);
void Hide(void); void Hide(void);
void Show(void); void Show(void);
void Render(void); void Render(void);
bool Execute(void); bool Execute(void);
void SetTransparency(int transparency, bool absolute = false); void SetTransparency(int transparency, bool absolute = false);
void SetIndicatorTransparency(int transparency);
void SetIndicatorPosition(cPoint &pos);
void SetViewPort(cRect &vp); void SetViewPort(cRect &vp);
void SetPosition(cPoint &pos, cPoint &ref); void SetPosition(cPoint &pos, cPoint &ref);
cRect CoveringArea(void); cRect CoveringArea(void);

View File

@ -359,6 +359,8 @@ void cAreaAttribs::Set(vector<stringpair> &attributes) {
SetScrollSpeed(id, attVal); SetScrollSpeed(id, attVal);
} else if (IdEqual(id, (int)eAreaAttribs::background)) { } else if (IdEqual(id, (int)eAreaAttribs::background)) {
SetBool(id, attVal); SetBool(id, attVal);
} else if (IdEqual(id, (int)eAreaAttribs::indicator)) {
SetBool(id, attVal);
} else if (IdEqual(id, (int)eAreaAttribs::name)) { } else if (IdEqual(id, (int)eAreaAttribs::name)) {
name = new cTextExpr(attVal); name = new cTextExpr(attVal);
} else { } else {
@ -381,6 +383,13 @@ bool cAreaAttribs::BackgroundArea(void) {
return false; return false;
} }
bool cAreaAttribs::IndicatorArea(void) {
int isIndicator = GetValue((int)eAreaAttribs::indicator);
if (isIndicator == 1)
return true;
return false;
}
void cAreaAttribs::CheckDynamic(void) { void cAreaAttribs::CheckDynamic(void) {
for (int i = (int)eCommonAttribs::x; i <= (int)eCommonAttribs::height; ++i ) { for (int i = (int)eCommonAttribs::x; i <= (int)eCommonAttribs::height; ++i ) {
if (attribCtors[i] && attribCtors[i]->Dynamic()) { if (attribCtors[i] && attribCtors[i]->Dynamic()) {
@ -405,6 +414,7 @@ void cAreaAttribs::SetAttributesDefs(void) {
attribIDs.insert(pair<string, int>("scrollspeed", (int)eAreaAttribs::scrollspeed)); attribIDs.insert(pair<string, int>("scrollspeed", (int)eAreaAttribs::scrollspeed));
attribIDs.insert(pair<string, int>("delay", (int)eAreaAttribs::delay)); attribIDs.insert(pair<string, int>("delay", (int)eAreaAttribs::delay));
attribIDs.insert(pair<string, int>("background", (int)eAreaAttribs::background)); attribIDs.insert(pair<string, int>("background", (int)eAreaAttribs::background));
attribIDs.insert(pair<string, int>("indicator", (int)eAreaAttribs::indicator));
attribIDs.insert(pair<string, int>("name", (int)eAreaAttribs::name)); attribIDs.insert(pair<string, int>("name", (int)eAreaAttribs::name));
attribIDs.insert(pair<string, int>("scrollheight", (int)eAreaAttribs::scrollheight)); attribIDs.insert(pair<string, int>("scrollheight", (int)eAreaAttribs::scrollheight));
attribNames.insert(pair<int, string>((int)eAreaAttribs::layer, "layer")); attribNames.insert(pair<int, string>((int)eAreaAttribs::layer, "layer"));

View File

@ -96,6 +96,7 @@ public:
int Layer(void); int Layer(void);
int ScrollStep(void) { return GetValue((int)eAreaAttribs::scrollheight); }; int ScrollStep(void) { return GetValue((int)eAreaAttribs::scrollheight); };
bool BackgroundArea(void); bool BackgroundArea(void);
bool IndicatorArea(void);
const char *Name(void); const char *Name(void);
void CheckDynamic(void); void CheckDynamic(void);
bool Dynamic(void) {return dynamic; }; bool Dynamic(void) {return dynamic; };

View File

@ -1677,6 +1677,7 @@ enum class eAreaAttribs {
scrollspeed, scrollspeed,
delay, delay,
background, background,
indicator,
name, name,
scrollheight, scrollheight,
count count

View File

@ -13,15 +13,24 @@ cListElement::cListElement(void) {
current = false; current = false;
wasCurrent = false; wasCurrent = false;
selectable = false; selectable = false;
selectedFromTop = true;
suppressAnimation = false;
listShifter = NULL;
currentElement = NULL; currentElement = NULL;
menuCat = mcUndefined; menuCat = mcUndefined;
orientation = eOrientation::vertical;
}; };
cListElement::cListElement(const cListElement &other) : cViewElement(other) { cListElement::cListElement(const cListElement &other) : cViewElement(other) {
num = -1; num = -1;
current = false; current = false;
wasCurrent = false;
selectable = false; selectable = false;
selectedFromTop = true;
suppressAnimation = false;
listShifter = NULL;
currentElement = NULL; currentElement = NULL;
orientation = eOrientation::vertical;
} }
void cListElement::SetCurrent(bool cur) { void cListElement::SetCurrent(bool cur) {
@ -54,6 +63,80 @@ void cListElement::WakeCurrent(void) {
} }
} }
void cListElement::Render(void) {
if (!dirty || blocked)
return;
if (attribs->DoDebug())
Debug();
bool animated = Fading() || Shifting();
for (cAreaNode *node = areaNodes.First(); node; node = areaNodes.Next(node)) {
//Check redraw of already scrolling list element
if (drawn && scrollingStarted && node->Scrolling()) {
if (DoScroll()) {
//current list element
continue;
} else {
//not current list element anymore
scrollingStarted = false;
}
}
//don't clear animated list element if it was current
//and animation was not suppressed because of cleared list
sdOsd->Lock();
if (animated && wasCurrent && !suppressAnimation) {
node->ClearWithoutIndicators();
} else {
node->Clear();
}
sdOsd->Unlock();
if (!node->Execute())
continue;
sdOsd->Lock();
node->Render();
sdOsd->Unlock();
if (DoScroll() && node->Scrolling()) {
cArea *scrollArea = node->ScrollingArea();
if (scrollArea) {
scrollingStarted = true;
cScroller *scroller = new cScroller(scrollArea);
scrollers.push_back(scroller);
cView::AddAnimation(scroller);
}
}
}
dirty = false;
drawn = true;
StartListAnimation();
}
int cListElement::ShiftDistance(void) {
if (orientation == eOrientation::horizontal)
return container.Width();
return container.Height();
}
eOrientation cListElement::ShiftOrientation(void) {
return orientation;
}
void cListElement::SetIndicatorPosition(cPoint &position) {
for (cAreaNode *node = areaNodes.First(); node; node = areaNodes.Next(node)) {
sdOsd->Lock();
node->SetIndicatorPosition(position);
sdOsd->Unlock();
}
}
void cListElement::SetTransparency(int transparency, bool force) {
for (cAreaNode *node = areaNodes.First(); node; node = areaNodes.Next(node)) {
sdOsd->Lock();
node->SetIndicatorTransparency(transparency);
sdOsd->Unlock();
}
}
char *cListElement::ParseSeparator(const char *text) { char *cListElement::ParseSeparator(const char *text) {
const char *start = text; const char *start = text;
@ -71,6 +154,49 @@ char *cListElement::ParseSeparator(const char *text) {
return ret; return ret;
} }
void cListElement::StopListAnimation(void) {
if (listShifter) {
cView::RemoveAnimation(listShifter);
listShifter = NULL;
}
if (fader) {
cView::RemoveAnimation(fader);
fader = NULL;
}
}
void cListElement::StartListAnimation(void) {
if (suppressAnimation)
return;
if (!Fading() && !Shifting())
return;
listShifter = NULL;
fader = NULL;
if (current) {
if (ShiftTime() > 0) {
listShifter = new cListShifter((cListShiftable*)this);
listShifter->SetDirection(selectedFromTop);
cView::AddAnimation(listShifter, true);
} else if (FadeTime() > 0) {
fader = new cFader((cFadable*)this);
cView::AddAnimation(fader, true);
}
}
if (wasCurrent) {
if (ShiftTime() > 0) {
listShifter = new cListShifter((cListShiftable*)this);
listShifter->SetDirection(selectedFromTop);
listShifter->SetShiftOut();
cView::AddAnimation(listShifter, false);
} else if (FadeTime() > 0) {
fader = new cFader((cFadable*)this);
fader->SetFadeOut();
fader->SetHideWhenFinished();
cView::AddAnimation(fader, false);
}
}
}
/****************************************************************** /******************************************************************
* cCurrentElement * cCurrentElement
******************************************************************/ ******************************************************************/

View File

@ -8,28 +8,45 @@
/****************************************************************** /******************************************************************
* cListElement * cListElement
******************************************************************/ ******************************************************************/
class cListElement : public cViewElement { class cListElement : public cViewElement , public cListShiftable {
protected: protected:
eMenuCategory menuCat; eMenuCategory menuCat;
eOrientation orientation;
int num; int num;
bool current; bool current;
bool wasCurrent; bool wasCurrent;
bool selectable; bool selectable;
bool selectedFromTop;
bool suppressAnimation;
cListShifter *listShifter;
cViewElement *currentElement; cViewElement *currentElement;
char *ParseSeparator(const char *text); char *ParseSeparator(const char *text);
void StartListAnimation(void);
public: public:
cListElement(void); cListElement(void);
cListElement(const cListElement &other); cListElement(const cListElement &other);
virtual ~cListElement(void) {}; virtual ~cListElement(void) {};
void SetMenuCategory(eMenuCategory menuCat) { this->menuCat = menuCat; }; void SetMenuCategory(eMenuCategory menuCat) { this->menuCat = menuCat; };
void SetOrientation(eOrientation orientation) { this->orientation = orientation; };
void SetNumber(int number) { num = number; }; void SetNumber(int number) { num = number; };
void SetCurrent(bool cur); void SetCurrent(bool cur);
bool Current(void) { return current; }; bool Current(void) { return current; };
bool WasCurrent(void) { return wasCurrent; };
void WakeCurrent(void); void WakeCurrent(void);
void SetSelectable(bool sel) { selectable = sel; }; void SetSelectable(bool sel) { selectable = sel; };
void SetSelectedFromTop(void) { selectedFromTop = true; };
void SetSelectedFromBottom(void) { selectedFromTop = false; };
void SetSuppressAnimation(bool suppress) { suppressAnimation = suppress; };
bool DoScroll(void) { return current; }; bool DoScroll(void) { return current; };
void Render(void);
virtual void RenderCurrent(void) { }; virtual void RenderCurrent(void) { };
void Close(void); void Close(void);
int ListShiftTime(void) { return ShiftTime(); };
int ShiftDistance(void);
eOrientation ShiftOrientation(void);
void SetIndicatorPosition(cPoint &position);
void SetTransparency(int transparency, bool force = false);
void StopListAnimation(void);
virtual void Clear(bool forceClearBackground = false); virtual void Clear(bool forceClearBackground = false);
}; };

View File

@ -2,9 +2,6 @@
cSdOsd::cSdOsd(void) { cSdOsd::cSdOsd(void) {
osd = NULL; osd = NULL;
flushLocked = false;
animsRunning = 0;
animsFlushed = 0;
} }
cSdOsd::~cSdOsd(void) { cSdOsd::~cSdOsd(void) {
@ -19,18 +16,6 @@ void cSdOsd::Unlock(void) {
mutex.Unlock(); mutex.Unlock();
} }
void cSdOsd::LockFlush(void) {
Lock();
flushLocked = true;
Unlock();
}
void cSdOsd::UnlockFlush(void) {
Lock();
flushLocked = false;
Unlock();
}
bool cSdOsd::CreateOsd(int x, int y, int width, int height) { bool cSdOsd::CreateOsd(int x, int y, int width, int height) {
cOsd *newOsd = cOsdProvider::NewOsd(cOsd::OsdLeft() + x, cOsd::OsdTop() + y); cOsd *newOsd = cOsdProvider::NewOsd(cOsd::OsdLeft() + x, cOsd::OsdTop() + y);
if (newOsd) { if (newOsd) {
@ -50,10 +35,6 @@ void cSdOsd::DeleteOsd(void) {
delete osd; delete osd;
osd = NULL; osd = NULL;
Unlock(); Unlock();
animsRunningMutex.Lock();
animsRunning = 0;
animsFlushed = 0;
animsRunningMutex.Unlock();
} }
cPixmap *cSdOsd::CreatePixmap(int layer, cRect &viewPort, cRect &drawPort) { cPixmap *cSdOsd::CreatePixmap(int layer, cRect &viewPort, cRect &drawPort) {
@ -69,33 +50,8 @@ void cSdOsd::DestroyPixmap(cPixmap *pix) {
} }
} }
void cSdOsd::AddAnimation(void) {
animsRunningMutex.Lock();
animsRunning++;
animsRunningMutex.Unlock();
}
void cSdOsd::RemoveAnimation(void) {
animsRunningMutex.Lock();
animsRunning--;
animsRunningMutex.Unlock();
}
void cSdOsd::AnimatedFlush(void) {
if (osd && !flushLocked) {
animsRunningMutex.Lock();
if (animsFlushed + 1 >= animsRunning) {
animsFlushed = 0;
osd->Flush();
} else {
animsFlushed++;
}
animsRunningMutex.Unlock();
}
}
void cSdOsd::Flush(void) { void cSdOsd::Flush(void) {
if (osd && !flushLocked) { if (osd) {
osd->Flush(); osd->Flush();
} }
} }

View File

@ -8,24 +8,15 @@ class cSdOsd {
private: private:
cOsd *osd; cOsd *osd;
cMutex mutex; cMutex mutex;
bool flushLocked;
int animsRunning;
int animsFlushed;
cMutex animsRunningMutex;
public: public:
cSdOsd(void); cSdOsd(void);
virtual ~cSdOsd(void); virtual ~cSdOsd(void);
void Lock(void); void Lock(void);
void Unlock(void); void Unlock(void);
void LockFlush(void);
void UnlockFlush(void);
bool CreateOsd(int x, int y, int width, int height); bool CreateOsd(int x, int y, int width, int height);
void DeleteOsd(void); void DeleteOsd(void);
cPixmap *CreatePixmap(int layer, cRect &viewPort, cRect &drawPort); cPixmap *CreatePixmap(int layer, cRect &viewPort, cRect &drawPort);
void DestroyPixmap(cPixmap *pix); void DestroyPixmap(cPixmap *pix);
void AddAnimation(void);
void RemoveAnimation(void);
void AnimatedFlush(void);
void Flush(void); void Flush(void);
}; };

View File

@ -3,6 +3,8 @@
// --- cView ------------------------------------------------------------- // --- cView -------------------------------------------------------------
cAnimator* cView::animator = NULL;
cView::cView(void) { cView::cView(void) {
globals = NULL; globals = NULL;
viewName = NULL; viewName = NULL;
@ -10,8 +12,6 @@ cView::cView(void) {
numViewElements = 0; numViewElements = 0;
viewElements = NULL; viewElements = NULL;
viewElementsHorizontal = NULL; viewElementsHorizontal = NULL;
fader = NULL;
shifter = NULL;
shifting = false; shifting = false;
currentTvFrame = NULL; currentTvFrame = NULL;
newTvFrame = NULL; newTvFrame = NULL;
@ -29,8 +29,8 @@ cView::~cView() {
} }
delete attribs; delete attribs;
free(viewName); free(viewName);
delete fader; delete animator;
delete shifter; animator = NULL;
shifting = false; shifting = false;
sdOsd.DeleteOsd(); sdOsd.DeleteOsd();
} }
@ -203,11 +203,24 @@ void cView::PreCache(void) {
SetViewElementObjects(); SetViewElementObjects();
} }
void cView::AddAnimation(cAnimation *animation, bool startAnimation) {
if (!animator)
return;
animator->AddAnimation(animation, startAnimation);
}
void cView::RemoveAnimation(cAnimation *animation) {
if (!animator)
return;
animator->RemoveAnimation(animation);
}
bool cView::Init(void) { bool cView::Init(void) {
int osdX = attribs->X(); int osdX = attribs->X();
int osdY = attribs->Y(); int osdY = attribs->Y();
int osdWidth = attribs->Width(); int osdWidth = attribs->Width();
int osdHeight = attribs->Height(); int osdHeight = attribs->Height();
animator = new cAnimator(&sdOsd);
return sdOsd.CreateOsd(osdX, osdY, osdWidth, osdHeight); return sdOsd.CreateOsd(osdX, osdY, osdWidth, osdHeight);
} }
@ -243,24 +256,19 @@ void cView::Show(int ve) {
viewElements[ve]->Show(); viewElements[ve]->Show();
} }
void cView::SetViewelementsAnimOut(void) {
for (int i=0; i< numViewElements; i++)
if (viewElements[i]) {
viewElements[i]->SetAnimOut();
}
}
void cView::Close(void) { void cView::Close(void) {
delete fader; if (animator) {
fader = NULL; animator->Stop();
delete shifter; animator->Finish();
shifter = NULL; delete animator;
if (initFinished && ShiftTime() > 0) { animator = NULL;
cRect shiftbox = CoveredArea();
cPoint ref = cPoint(shiftbox.X(), shiftbox.Y());
cPoint end = ShiftStart(shiftbox);
shifter = new cAnimation((cShiftable*)this, end, ref, false);
shifter->Shift();
delete shifter;
shifter = NULL;
} else if (initFinished && FadeTime() > 0) {
fader = new cAnimation((cFadable*)this, false);
fader->Fade();
delete fader;
fader = NULL;
} }
UnScaleTv(); UnScaleTv();
ClearVariables(); ClearVariables();
@ -293,6 +301,13 @@ int cView::ShiftMode(void) {
return attribs->ShiftMode(); return attribs->ShiftMode();
} }
void cView::ShiftPositions(cPoint *start, cPoint *end) {
cRect shiftbox = CoveredArea();
cPoint startPoint = ShiftStart(shiftbox);
start->Set(startPoint);
end->Set(shiftbox.X(), shiftbox.Y());
}
void cView::SetPosition(cPoint &position, cPoint &reference, bool force) { void cView::SetPosition(cPoint &position, cPoint &reference, bool force) {
for (int i = 0; i < numViewElements; i++) { for (int i = 0; i < numViewElements; i++) {
if (viewElements[i] && (!viewElements[i]->Shifting() || force)) { if (viewElements[i] && (!viewElements[i]->Shifting() || force)) {
@ -301,31 +316,17 @@ void cView::SetPosition(cPoint &position, cPoint &reference, bool force) {
} }
} }
void cView::RegisterAnimation(void) { void cView::Flush(void) {
sdOsd.AddAnimation();
}
void cView::UnregisterAnimation(void) {
sdOsd.RemoveAnimation();
}
void cView::Flush(bool animFlush) {
if (init) { if (init) {
init = false; init = false;
StartAnimation(); StartAnimation();
menuInit = true; menuInit = true;
//LockFlush was set at startup of view to avoid display
//of not positioned pixmaps for shifting and fading
sdOsd.UnlockFlush();
} }
if (menuInit) { if (menuInit) {
ScaleTv(); ScaleTv();
WakeViewElements(); WakeViewElements();
menuInit = false; menuInit = false;
} }
if (animFlush)
sdOsd.AnimatedFlush();
else
sdOsd.Flush(); sdOsd.Flush();
} }
@ -345,7 +346,6 @@ void cView::Debug(void) {
*******************************************************************/ *******************************************************************/
void cView::ClearVariables(void) { void cView::ClearVariables(void) {
init = true; init = true;
initFinished = false;
newTvFrame = NULL; newTvFrame = NULL;
currentTvFrame = NULL; currentTvFrame = NULL;
menuInit = false; menuInit = false;
@ -359,22 +359,19 @@ int cView::ViewElementId(const char *name) {
} }
void cView::StartAnimation(void) { void cView::StartAnimation(void) {
if (viewId != eViewType::DisplayMenu &&
viewId != eViewType::DisplayPlugin) {
if (ShiftTime() > 0) { if (ShiftTime() > 0) {
cRect shiftbox = CoveredArea(); cShifter *shifter = new cShifter((cShiftable*)this);
cPoint ref = cPoint(shiftbox.X(), shiftbox.Y()); shifter->SetPersistent();
cPoint start = ShiftStart(shiftbox); cView::AddAnimation(shifter);
SetPosition(start, ref);
shifter = new cAnimation((cShiftable*)this, start, ref, true);
shifter->Start();
} else if (FadeTime() > 0) { } else if (FadeTime() > 0) {
if (fader) cFader *fader = new cFader((cFadable*)this);
return; fader->SetPersistent();
SetTransparency(100); cView::AddAnimation(fader);
sdOsd.Flush();
fader = new cAnimation((cFadable*)this, true);
fader->Start();
} }
initFinished = true; }
animator->Start();
} }
void cView::WakeViewElements(void) { void cView::WakeViewElements(void) {

View File

@ -29,10 +29,10 @@ private:
void SetClearOnDisplay(int ve, const char *clearOnDisplay); void SetClearOnDisplay(int ve, const char *clearOnDisplay);
protected: protected:
cSdOsd sdOsd; cSdOsd sdOsd;
static cAnimator *animator;
cViewAttribs *attribs; cViewAttribs *attribs;
cRect container; cRect container;
bool init; bool init;
bool initFinished;
eViewType viewId; eViewType viewId;
cGlobals *globals; cGlobals *globals;
char *viewName; char *viewName;
@ -40,8 +40,6 @@ protected:
cViewElement **viewElements; cViewElement **viewElements;
cViewElement **viewElementsHorizontal; cViewElement **viewElementsHorizontal;
map<string,int> viewElementNames; map<string,int> viewElementNames;
cAnimation *fader;
cAnimation *shifter;
bool shifting; bool shifting;
cRect tvFrame; cRect tvFrame;
cRect *currentTvFrame; cRect *currentTvFrame;
@ -74,6 +72,8 @@ public:
virtual const cFont *GetTextAreaFont(void) { return NULL; }; virtual const cFont *GetTextAreaFont(void) { return NULL; };
virtual int GetTextAreaWidth(void) { return 0; }; virtual int GetTextAreaWidth(void) { return 0; };
virtual int GetListWidth(void) { return 0; }; virtual int GetListWidth(void) { return 0; };
static void AddAnimation(cAnimation *animation, bool startAnimation = true);
static void RemoveAnimation(cAnimation *animation);
//View API //View API
virtual bool Init(void); virtual bool Init(void);
void Clear(int ve, bool forceClearBackground = false); void Clear(int ve, bool forceClearBackground = false);
@ -82,21 +82,20 @@ public:
void Hide(int ve); void Hide(int ve);
void Show(int ve); void Show(int ve);
virtual void Close(void); virtual void Close(void);
virtual void Flush(bool animFlush); virtual void Flush(void);
virtual void Debug(void); virtual void Debug(void);
void SetViewelementsAnimOut(void);
//Fadable //Fadable
bool Detached(void) { return false; };
int Delay(void) { return 0; }; int Delay(void) { return 0; };
int FadeTime(void); int FadeTime(void);
virtual void SetTransparency(int transparency, bool force = false); virtual void SetTransparency(int transparency, bool force = false);
//Shiftable //Shiftable
int ShiftTime(void); int ShiftTime(void);
int ShiftMode(void); int ShiftMode(void);
void ShiftPositions(cPoint *start, cPoint *end);
virtual void SetPosition(cPoint &position, cPoint &reference, bool force = false); virtual void SetPosition(cPoint &position, cPoint &reference, bool force = false);
void SetStartShifting(void) { shifting = true; }; void SetStartShifting(void) { shifting = true; };
void SetEndShifting(void) { shifting = false; }; void SetEndShifting(void) { shifting = false; };
void RegisterAnimation(void);
void UnregisterAnimation(void);
}; };
#endif //__VIEW_H #endif //__VIEW_H

View File

@ -71,6 +71,13 @@ void cViewChannel::PreCache(void) {
groupChannelList->PreCache(); groupChannelList->PreCache();
} }
#endif #endif
if (viewElements[(int)eVeDisplayChannel::channellistback])
viewElements[(int)eVeDisplayChannel::channellistback]->UnsetStartAnim();
if (viewElements[(int)eVeDisplayChannel::grouplistback])
viewElements[(int)eVeDisplayChannel::grouplistback]->UnsetStartAnim();
if (viewElements[(int)eVeDisplayChannel::groupchannellistback])
viewElements[(int)eVeDisplayChannel::groupchannellistback]->UnsetStartAnim();
SetViewelementsAnimOut();
} }
void cViewChannel::AddChannelViewList(const char *listName, cViewList *viewList) { void cViewChannel::AddChannelViewList(const char *listName, cViewList *viewList) {
@ -363,29 +370,17 @@ void cViewChannel::SetChannelHint(const cChannel *channel) {
#endif //USE_ZAPCOCKPIT #endif //USE_ZAPCOCKPIT
void cViewChannel::Close(void) { void cViewChannel::Close(void) {
delete fader;
fader = NULL;
delete shifter;
shifter = NULL;
bool doAnim = true; bool doAnim = true;
#ifdef USE_ZAPCOCKPIT #ifdef USE_ZAPCOCKPIT
if (viewType != dcDefault) if (viewType != dcDefault)
doAnim = false; doAnim = false;
#endif #endif
if (initFinished && doAnim && ShiftTime() > 0) { if (doAnim) {
cRect shiftbox = CoveredArea(); animator->Stop();
cPoint ref = cPoint(shiftbox.X(), shiftbox.Y()); animator->Finish();
cPoint end = ShiftStart(shiftbox);
shifter = new cAnimation((cShiftable*)this, end, ref, false);
shifter->Shift();
delete shifter;
shifter = NULL;
} else if (initFinished && doAnim && FadeTime() > 0) {
fader = new cAnimation((cFadable*)this, false);
fader->Fade();
delete fader;
fader = NULL;
} }
delete animator;
animator = NULL;
UnScaleTv(); UnScaleTv();
ClearVariables(); ClearVariables();
for (int i=0; i < numViewElements; i++) { for (int i=0; i < numViewElements; i++) {
@ -557,8 +552,6 @@ void cViewChannel::DrawExtended(void) {
ClearOnDisplay(); ClearOnDisplay();
initExtended = false; initExtended = false;
} }
if (!init && initList)
sdOsd.LockFlush();
if (viewType == dcChannelList && channelList) { if (viewType == dcChannelList && channelList) {
Render((int)eVeDisplayChannel::channellistback); Render((int)eVeDisplayChannel::channellistback);
channelList->Draw(mcUndefined); channelList->Draw(mcUndefined);
@ -575,27 +568,22 @@ void cViewChannel::DrawExtended(void) {
if (initList) if (initList)
groupChannelList->StartAnimation(); groupChannelList->StartAnimation();
} }
if (!init && initList)
sdOsd.UnlockFlush();
displayList = false; displayList = false;
initList = false; initList = false;
#endif #endif
} }
void cViewChannel::Flush(bool animFlush) { void cViewChannel::Flush(void) {
if (init) {
sdOsd.LockFlush();
}
#ifdef USE_ZAPCOCKPIT #ifdef USE_ZAPCOCKPIT
ClearExtended(); ClearExtended();
#endif #endif
#ifdef USE_ZAPCOCKPIT
if (viewType < dcChannelList) {
#endif
//Basic Display Handling //Basic Display Handling
if (mode == dmDefault) { if (mode == dmDefault) {
if (!shifting) {
DrawBasic(init); DrawBasic(init);
}
} else if (mode == dmChannelGroups) { } else if (mode == dmChannelGroups) {
if (init) { if (init) {
Render((int)eVeDisplayChannel::background); Render((int)eVeDisplayChannel::background);
@ -603,15 +591,16 @@ void cViewChannel::Flush(bool animFlush) {
} }
Render((int)eVeDisplayChannel::channelgroup); Render((int)eVeDisplayChannel::channelgroup);
} }
if (!shifting) {
Render((int)eVeDisplayChannel::datetime); Render((int)eVeDisplayChannel::datetime);
Render((int)eVeDisplayChannel::time); Render((int)eVeDisplayChannel::time);
#ifdef USE_ZAPCOCKPIT
} }
#endif
channelChange = false; channelChange = false;
#ifdef USE_ZAPCOCKPIT #ifdef USE_ZAPCOCKPIT
DrawExtended(); DrawExtended();
#endif #endif
cView::Flush(animFlush); cView::Flush();
} }

View File

@ -71,7 +71,7 @@ public:
void SetChannelHint(const cChannel *channel); void SetChannelHint(const cChannel *channel);
#endif #endif
void Close(void); void Close(void);
void Flush(bool animFlush); void Flush(void);
}; };
#endif //__VIEWDISPLAYCHANNEL_H #endif //__VIEWDISPLAYCHANNEL_H

View File

@ -535,14 +535,10 @@ bool cViewMenu::Init(void) {
} }
void cViewMenu::Close(void) { void cViewMenu::Close(void) {
delete fader; animator->Stop();
fader = NULL; animator->Finish();
if (FadeTime() > 0) { delete animator;
fader = new cAnimation((cFadable*)this, false); animator = NULL;
fader->Fade();
delete fader;
fader = NULL;
}
for (int i=0; i < numSubviews; i++) { for (int i=0; i < numSubviews; i++) {
if (subViews[i]) { if (subViews[i]) {
subViews[i]->Close(); subViews[i]->Close();
@ -566,10 +562,7 @@ void cViewMenu::Clear(void) {
activeSubview->ClearViewList(); activeSubview->ClearViewList();
} }
void cViewMenu::Flush(bool animFlush) { void cViewMenu::Flush(void) {
if (init) {
sdOsd.LockFlush();
}
bool staticInitiated = false; bool staticInitiated = false;
if (menuChange) { if (menuChange) {
newTvFrame = activeSubview->GetTvFrame(); newTvFrame = activeSubview->GetTvFrame();
@ -591,7 +584,7 @@ void cViewMenu::Flush(bool animFlush) {
detailViewInit = false; detailViewInit = false;
} }
activeSubview->DrawDynamicVEs(); activeSubview->DrawDynamicVEs();
cView::Flush(animFlush); cView::Flush();
} }
void cViewMenu::SetTransparency(int transparency, bool forceDetached) { void cViewMenu::SetTransparency(int transparency, bool forceDetached) {
@ -912,6 +905,7 @@ void cSubView::DrawDynamicVEs(void) {
void cSubView::DrawList(void) { void cSubView::DrawList(void) {
if (viewList) { if (viewList) {
viewList->Draw(menuCat); viewList->Draw(menuCat);
viewList->ResetItemCount();
} }
} }

View File

@ -101,7 +101,7 @@ public:
bool Init(void); bool Init(void);
void Close(void); void Close(void);
void Clear(void); void Clear(void);
void Flush(bool animFlush); void Flush(void);
void SetTransparency(int transparency, bool forceDetached = false); void SetTransparency(int transparency, bool forceDetached = false);
void Debug(void); void Debug(void);
}; };

View File

@ -43,12 +43,11 @@ void cViewMessage::SetMessage(eMessageType type, const char *text) {
veMessage->Set(type, text); veMessage->Set(type, text);
} }
void cViewMessage::Flush(bool animFlush) { void cViewMessage::Flush(void) {
if (init) { if (init) {
sdOsd.LockFlush();
Render((int)eVeDisplayMessage::background); Render((int)eVeDisplayMessage::background);
} }
Render((int)eVeDisplayMessage::message); Render((int)eVeDisplayMessage::message);
cView::Flush(animFlush); cView::Flush();
} }

View File

@ -13,7 +13,7 @@ public:
cViewMessage(void); cViewMessage(void);
virtual ~cViewMessage(void); virtual ~cViewMessage(void);
void SetMessage(eMessageType type, const char *text); void SetMessage(eMessageType type, const char *text);
void Flush(bool animFlush); void Flush(void);
}; };
#endif //__VIEWDISPLAYMESSAGE_H #endif //__VIEWDISPLAYMESSAGE_H

View File

@ -352,13 +352,13 @@ void cViewPlugin::ClearTab(int viewId) {
tab->Clear(); tab->Clear();
} }
void cViewPlugin::Flush(bool animFlush) { void cViewPlugin::Flush(void) {
if (viewChanged) { if (viewChanged) {
viewChanged = false; viewChanged = false;
newTvFrame = views[newViewId]->GetTvFrame(); newTvFrame = views[newViewId]->GetTvFrame();
menuInit = true; menuInit = true;
} }
cView::Flush(animFlush); cView::Flush();
} }
bool cViewPlugin::ChannelLogoExists(string channelId) { bool cViewPlugin::ChannelLogoExists(string channelId) {

View File

@ -64,7 +64,7 @@ public:
void TabDown(int viewId); void TabDown(int viewId);
void DisplayTabs(int viewId); void DisplayTabs(int viewId);
void ClearTab(int viewId); void ClearTab(int viewId);
void Flush(bool animFlush); void Flush(void);
bool ChannelLogoExists(string channelId); bool ChannelLogoExists(string channelId);
string GetEpgImagePath(void); string GetEpgImagePath(void);
}; };

View File

@ -135,6 +135,11 @@ void cViewReplay::SetViewElementObjects(void) {
} }
} }
void cViewReplay::PreCache(void) {
cView::PreCache();
SetViewelementsAnimOut();
}
void cViewReplay::ClearVariables(void) { void cViewReplay::ClearVariables(void) {
cView::ClearVariables(); cView::ClearVariables();
modeOnly = false; modeOnly = false;
@ -276,9 +281,8 @@ void cViewReplay::DelayOnPause(void) {
veOnPause->ResetSleep(); veOnPause->ResetSleep();
} }
void cViewReplay::Flush(bool animFlush) { void cViewReplay::Flush(void) {
if (init) { if (init) {
sdOsd.LockFlush();
if (!modeOnly) { if (!modeOnly) {
Render((int)eVeDisplayReplay::background); Render((int)eVeDisplayReplay::background);
Render((int)eVeDisplayReplay::rectitle); Render((int)eVeDisplayReplay::rectitle);
@ -303,7 +307,7 @@ void cViewReplay::Flush(bool animFlush) {
SetProgressModeOnly(); SetProgressModeOnly();
} }
cView::Flush(animFlush); cView::Flush();
} }
void cViewReplay::SetProgressModeOnly(void) { void cViewReplay::SetProgressModeOnly(void) {

View File

@ -37,6 +37,7 @@ private:
public: public:
cViewReplay(void); cViewReplay(void);
virtual ~cViewReplay(void); virtual ~cViewReplay(void);
void PreCache(void);
void SetModeOnly(bool modeOnly) { this->modeOnly = modeOnly; }; void SetModeOnly(bool modeOnly) { this->modeOnly = modeOnly; };
void SetRecordingLength(int length) { reclength = length; }; void SetRecordingLength(int length) { reclength = length; };
void SetTimeShift(int framesTotal, int timeShiftLength); void SetTimeShift(int framesTotal, int timeShiftLength);
@ -53,7 +54,7 @@ public:
void StartOnPause(const char *recfilename); void StartOnPause(const char *recfilename);
void ClearOnPause(void); void ClearOnPause(void);
void DelayOnPause(void); void DelayOnPause(void);
void Flush(bool animFlush); void Flush(void);
}; };
#endif //__VIEWDISPLAYREPLAY_H1 #endif //__VIEWDISPLAYREPLAY_H1

View File

@ -41,14 +41,10 @@ void cViewTracks::ClearVariables(void) {
} }
void cViewTracks::Close(void) { void cViewTracks::Close(void) {
delete fader; animator->Stop();
fader = NULL; animator->Finish();
if (FadeTime() > 0) { delete animator;
fader = new cAnimation((cFadable*)this, false); animator = NULL;
fader->Fade();
delete fader;
fader = NULL;
}
for (int i=0; i < numViewElements; i++) { for (int i=0; i < numViewElements; i++) {
if (viewElements[i]) { if (viewElements[i]) {
viewElements[i]->Close(); viewElements[i]->Close();
@ -107,14 +103,13 @@ void cViewTracks::SetCurrentTrack(int index) {
change = true; change = true;
} }
void cViewTracks::Flush(bool animFlush) { void cViewTracks::Flush(void) {
if (init) { if (init) {
sdOsd.LockFlush(); Render((int)eVeDisplayTracks::background);
if (viewList) { if (viewList) {
viewList->Draw(); viewList->Draw();
viewList->StartAnimation(); viewList->StartAnimation(true);
} }
Render((int)eVeDisplayTracks::background);
} }
if (change) { if (change) {
Render((int)eVeDisplayTracks::header); Render((int)eVeDisplayTracks::header);
@ -122,5 +117,5 @@ void cViewTracks::Flush(bool animFlush) {
viewList->Draw(); viewList->Draw();
change = false; change = false;
} }
cView::Flush(animFlush); cView::Flush();
} }

View File

@ -23,7 +23,7 @@ public:
void SetTracks(const char * const *tracks); void SetTracks(const char * const *tracks);
void SetAudiochannel(int audioChannel); void SetAudiochannel(int audioChannel);
void SetCurrentTrack(int index); void SetCurrentTrack(int index);
void Flush(bool animFlush); void Flush(void);
}; };
#endif //__VIEWDISPLAYTRACKS_H #endif //__VIEWDISPLAYTRACKS_H

View File

@ -40,13 +40,12 @@ void cViewVolume::SetVolume(int current, int total, bool mute) {
veVolume->Set(current, total, mute); veVolume->Set(current, total, mute);
} }
void cViewVolume::Flush(bool animFlush) { void cViewVolume::Flush(void) {
if (init) { if (init) {
sdOsd.LockFlush();
Render((int)eVeDisplayVolume::background); Render((int)eVeDisplayVolume::background);
} }
Render((int)eVeDisplayVolume::volume); Render((int)eVeDisplayVolume::volume);
cView::Flush(animFlush); cView::Flush();
} }

View File

@ -13,7 +13,7 @@ public:
cViewVolume(void); cViewVolume(void);
virtual ~cViewVolume(void); virtual ~cViewVolume(void);
void SetVolume(int current, int total, bool mute); void SetVolume(int current, int total, bool mute);
void Flush(bool animFlush); void Flush(void);
}; };
#endif //__VIEWDISPLAYVOLUME_H #endif //__VIEWDISPLAYVOLUME_H

View File

@ -13,6 +13,8 @@ cViewElement::cViewElement(void) {
scrollingStarted = false; scrollingStarted = false;
blocked = false; blocked = false;
detached = false; detached = false;
doAnimOut = false;
doStartAnim = true;
waitOnWakeup = true; waitOnWakeup = true;
startAnimation = true; startAnimation = true;
restartAnimation = false; restartAnimation = false;
@ -21,8 +23,8 @@ cViewElement::cViewElement(void) {
attribs = new cViewElementAttribs((int)eViewElementAttribs::count); attribs = new cViewElementAttribs((int)eViewElementAttribs::count);
clearAll = false; clearAll = false;
detacher = NULL; detacher = NULL;
fader = NULL;
shifter = NULL; shifter = NULL;
fader = NULL;
} }
cViewElement::cViewElement(const cViewElement &other) { cViewElement::cViewElement(const cViewElement &other) {
@ -34,6 +36,8 @@ cViewElement::cViewElement(const cViewElement &other) {
scrollingStarted = false; scrollingStarted = false;
blocked = false; blocked = false;
detached = false; detached = false;
doAnimOut = other.doAnimOut;
doStartAnim = other.doStartAnim;
waitOnWakeup = true; waitOnWakeup = true;
startAnimation = true; startAnimation = true;
restartAnimation = false; restartAnimation = false;
@ -52,15 +56,13 @@ cViewElement::cViewElement(const cViewElement &other) {
} }
detacher = NULL; detacher = NULL;
fader = NULL;
shifter = NULL; shifter = NULL;
fader = NULL;
} }
cViewElement::~cViewElement(void) { cViewElement::~cViewElement(void) {
delete attribs; delete attribs;
delete detacher; delete detacher;
delete fader;
delete shifter;
delete tokenContainer; delete tokenContainer;
} }
@ -381,9 +383,9 @@ void cViewElement::Render(void) {
cArea *scrollArea = node->ScrollingArea(); cArea *scrollArea = node->ScrollingArea();
if (scrollArea) { if (scrollArea) {
scrollingStarted = true; scrollingStarted = true;
cAnimation *scroller = new cAnimation(scrollArea); cScroller *scroller = new cScroller(scrollArea);
scrollers.Add(scroller); scrollers.push_back(scroller);
scroller->Start(); cView::AddAnimation(scroller);
} }
} }
} }
@ -397,10 +399,10 @@ void cViewElement::Render(void) {
} }
void cViewElement::StopScrolling(bool deletePixmaps) { void cViewElement::StopScrolling(bool deletePixmaps) {
for (cAnimation *scroller = scrollers.First(); scroller; scroller = scrollers.Next(scroller)) { for (list<cScroller*>::iterator it = scrollers.begin(); it != scrollers.end(); it++) {
scroller->Stop(deletePixmaps); cView::RemoveAnimation(*it);
} }
scrollers.Clear(); scrollers.clear();
} }
void cViewElement::ParseDetached(void) { void cViewElement::ParseDetached(void) {
@ -413,14 +415,14 @@ void cViewElement::RenderDetached(void) {
} }
bool cViewElement::Shifting(void) { bool cViewElement::Shifting(void) {
if (attribs->ShiftTime() >= 0) { if (attribs->ShiftTime() > 0) {
return true; return true;
} }
return false; return false;
} }
bool cViewElement::Fading(void) { bool cViewElement::Fading(void) {
if (attribs->FadeTime() >= 0) { if (attribs->FadeTime() > 0) {
return true; return true;
} }
return false; return false;
@ -438,22 +440,26 @@ int cViewElement::ShiftMode(void) {
return attribs->ShiftMode(); return attribs->ShiftMode();
} }
void cViewElement::StartAnimation(void) { void cViewElement::ShiftPositions(cPoint *start, cPoint *end) {
if (ShiftTime() > 0) {
cRect shiftbox = CoveredArea(); cRect shiftbox = CoveredArea();
cPoint ref = cPoint(shiftbox.X(), shiftbox.Y()); cPoint startPoint = ShiftStart(shiftbox);
cPoint start = ShiftStart(shiftbox); start->Set(startPoint);
SetPosition(start, ref); end->Set(shiftbox.X(), shiftbox.Y());
sdOsd->Flush(); }
delete shifter;
shifter = new cAnimation((cShiftable*)this, start, ref, true); void cViewElement::StartAnimation(void) {
shifter->Start(); shifter = NULL;
fader = NULL;
if (ShiftTime() > 0) {
shifter = new cShifter((cShiftable*)this);
if (doAnimOut)
shifter->SetPersistent();
cView::AddAnimation(shifter, doStartAnim);
} else if (FadeTime() > 0) { } else if (FadeTime() > 0) {
SetTransparency(100); fader = new cFader((cFadable*)this);
sdOsd->Flush(); if (doAnimOut)
delete fader; fader->SetPersistent();
fader = new cAnimation((cFadable*)this, true); cView::AddAnimation(fader, doStartAnim);
fader->Start();
} }
} }
@ -481,18 +487,7 @@ cRect cViewElement::CoveredArea(void) {
return unionArea; return unionArea;
} }
void cViewElement::RegisterAnimation(void) { void cViewElement::Flush(void) {
sdOsd->AddAnimation();
}
void cViewElement::UnregisterAnimation(void) {
sdOsd->RemoveAnimation();
}
void cViewElement::Flush(bool animFlush) {
if (animFlush)
sdOsd->AnimatedFlush();
else
sdOsd->Flush(); sdOsd->Flush();
} }
@ -505,7 +500,7 @@ bool cViewElement::Parse(bool forced) {
} }
delete detacher; delete detacher;
bool isAnimated = (FadeTime() > 0) || (ShiftTime() > 0); bool isAnimated = (FadeTime() > 0) || (ShiftTime() > 0);
detacher = new cAnimation((cDetachable*)this, waitOnWakeup, startAnimation && isAnimated); detacher = new cDetacher((cDetachable*)this, waitOnWakeup, startAnimation && isAnimated);
detacher->Start(); detacher->Start();
startAnimation = false; startAnimation = false;
init = false; init = false;
@ -576,8 +571,8 @@ cPoint cViewElement::ShiftStart(cRect &shiftbox) {
void cViewElement::StopAnimation(void) { void cViewElement::StopAnimation(void) {
delete detacher; delete detacher;
detacher = NULL; detacher = NULL;
delete shifter; if (shifter)
shifter = NULL; cView::RemoveAnimation(shifter);
delete fader; if (fader)
fader = NULL; cView::RemoveAnimation(fader);
} }

View File

@ -5,6 +5,7 @@
#include <stdio.h> #include <stdio.h>
#include <stdlib.h> #include <stdlib.h>
#include <stdint.h> #include <stdint.h>
#include <list>
#include <vdr/tools.h> #include <vdr/tools.h>
#include "osdwrapper.h" #include "osdwrapper.h"
#include "globals.h" #include "globals.h"
@ -24,6 +25,8 @@ protected:
bool dirty; bool dirty;
bool blocked; bool blocked;
bool detached; bool detached;
bool doAnimOut;
bool doStartAnim;
bool waitOnWakeup; bool waitOnWakeup;
bool scrollingStarted; bool scrollingStarted;
bool startAnimation; bool startAnimation;
@ -35,10 +38,10 @@ protected:
bool clearAll; bool clearAll;
cList<cAreaNode> areaNodes; cList<cAreaNode> areaNodes;
skindesignerapi::cTokenContainer *tokenContainer; skindesignerapi::cTokenContainer *tokenContainer;
cList<cAnimation> scrollers; list<cScroller*> scrollers;
cAnimation *detacher; cDetacher *detacher;
cAnimation *fader; cShifter *shifter;
cAnimation *shifter; cFader *fader;
void InheritTokenContainer(void); void InheritTokenContainer(void);
void InheritTokenContainerDeep(void); void InheritTokenContainerDeep(void);
virtual bool DoScroll(void) { return true; }; virtual bool DoScroll(void) { return true; };
@ -54,6 +57,8 @@ public:
void SetGlobals(cGlobals *globals); void SetGlobals(cGlobals *globals);
virtual void SetTokenContainer(void); virtual void SetTokenContainer(void);
void SetDetached(void) { detached = true; }; void SetDetached(void) { detached = true; };
void SetAnimOut(void) { doAnimOut = true; };
void UnsetStartAnim(void) { doStartAnim = false; };
void UnsetWaitOnWakeup(void) { waitOnWakeup = false; }; void UnsetWaitOnWakeup(void) { waitOnWakeup = false; };
bool Detached(void); bool Detached(void);
void SetContainer(int x, int y, int width, int height); void SetContainer(int x, int y, int width, int height);
@ -90,16 +95,15 @@ public:
int FadeTime(void); int FadeTime(void);
int ShiftTime(void); int ShiftTime(void);
int ShiftMode(void); int ShiftMode(void);
void ShiftPositions(cPoint *start, cPoint *end);
void StartAnimation(void); void StartAnimation(void);
void SetRestartAnimation(void) { restartAnimation = true; }; void SetRestartAnimation(void) { restartAnimation = true; };
virtual void SetTransparency(int transparency, bool force = false); virtual void SetTransparency(int transparency, bool force = false);
virtual void SetPosition(cPoint &position, cPoint &reference, bool force = false); virtual void SetPosition(cPoint &position, cPoint &reference, bool force = false);
void SetStartShifting(void) { }; void SetStartShifting(void) { };
void SetEndShifting(void) { }; void SetEndShifting(void) { };
void RegisterAnimation(void);
void UnregisterAnimation(void);
cRect CoveredArea(void); cRect CoveredArea(void);
void Flush(bool animFlush); void Flush(void);
virtual bool Parse(bool forced = false); virtual bool Parse(bool forced = false);
cFunction *GetFunction(const char *name); cFunction *GetFunction(const char *name);
virtual void Debug(bool full = false); virtual void Debug(bool full = false);

View File

@ -1,9 +1,13 @@
#include "viewlist.h" #include "viewlist.h"
#include "view.h"
cViewList::cViewList(void) { cViewList::cViewList(void) {
globals = NULL; globals = NULL;
attribs = new cViewListAttribs((int)eViewListAttribs::count); attribs = new cViewListAttribs((int)eViewListAttribs::count);
numElements = 0; numElements = 0;
orientation = eOrientation::vertical;
cleared = true;
itemCount = 0;
listElement = NULL; listElement = NULL;
currentElement = NULL; currentElement = NULL;
listElements = NULL; listElements = NULL;
@ -27,8 +31,6 @@ cViewList::~cViewList(void) {
} }
delete[] listElements; delete[] listElements;
delete tokenContainer; delete tokenContainer;
delete fader;
delete shifter;
} }
void cViewList::SetGlobals(cGlobals *globals) { void cViewList::SetGlobals(cGlobals *globals) {
@ -194,9 +196,15 @@ eOrientation cViewList::Orientation(void) {
void cViewList::Draw(eMenuCategory menuCat) { void cViewList::Draw(eMenuCategory menuCat) {
int current = -1; int current = -1;
int numCalls = 0;
for (int i = 0; i < numElements; i++) { for (int i = 0; i < numElements; i++) {
listElements[i]->SetMenuCategory(menuCat); listElements[i]->SetMenuCategory(menuCat);
if (listElements[i]->Parse()) { if (listElements[i]->Parse()) {
if (listElements[i]->Shifting())
SetShiftParameters(i, numCalls);
if (listElements[i]->Fading() && itemCount == 1) {
listElements[i]->SetSuppressAnimation(true);
}
listElements[i]->Render(); listElements[i]->Render();
if (listElements[i]->Current()) { if (listElements[i]->Current()) {
listElements[i]->RenderCurrent(); listElements[i]->RenderCurrent();
@ -207,10 +215,11 @@ void cViewList::Draw(eMenuCategory menuCat) {
if (current >= 0 && listElements[current]) { if (current >= 0 && listElements[current]) {
listElements[current]->WakeCurrent(); listElements[current]->WakeCurrent();
} }
cleared = false;
} }
void cViewList::Clear(void) { void cViewList::Clear(void) {
cleared = true;
if (!listElements) if (!listElements)
return; return;
for (int i = 0; i < numElements; i++) { for (int i = 0; i < numElements; i++) {
@ -223,10 +232,10 @@ void cViewList::Clear(void) {
} }
void cViewList::Close(void) { void cViewList::Close(void) {
delete fader; if (shifter)
fader = NULL; cView::RemoveAnimation(shifter);
delete shifter; if (fader)
shifter = NULL; cView::RemoveAnimation(fader);
if (!listElements) if (!listElements)
return; return;
for (int i = 0; i < numElements; i++) { for (int i = 0; i < numElements; i++) {
@ -260,49 +269,26 @@ void cViewList::SetPosition(cPoint &position, cPoint &reference, bool force) {
} }
} }
void cViewList::RegisterAnimation(void) { void cViewList::ShiftPositions(cPoint *start, cPoint *end) {
for (int i = 0; i < numElements; i++) {
if (listElements[i]) {
listElements[i]->RegisterAnimation();
break;
}
}
}
void cViewList::UnregisterAnimation(void) {
for (int i = 0; i < numElements; i++) {
if (listElements[i]) {
listElements[i]->UnregisterAnimation();
break;
}
}
}
void cViewList::StartAnimation(void) {
if (ShiftTime() > 0) {
cRect shiftbox = CoveredArea(); cRect shiftbox = CoveredArea();
cPoint ref = cPoint(shiftbox.X(), shiftbox.Y()); cPoint startPoint = ShiftStart(shiftbox);
cPoint start = ShiftStart(shiftbox); start->Set(startPoint);
SetPosition(start, ref); end->Set(shiftbox.X(), shiftbox.Y());
Flush(false);
delete shifter;
shifter = new cAnimation((cShiftable*)this, start, ref, true);
shifter->Start();
} else if (FadeTime() > 0) {
SetTransparency(100);
Flush(false);
delete fader;
fader = new cAnimation((cFadable*)this, true);
fader->Start();
}
} }
void cViewList::Flush(bool animFlush) { void cViewList::StartAnimation(bool animOut) {
for (int i = 0; i < numElements; i++) { shifter = NULL;
if (listElements[i]) { fader = NULL;
listElements[i]->Flush(animFlush); if (ShiftTime() > 0) {
break; shifter = new cShifter((cShiftable*)this);
} if (animOut)
shifter->SetPersistent();
cView::AddAnimation(shifter);
} else if (FadeTime() > 0) {
fader = new cFader((cFadable*)this);
if (animOut)
fader->SetPersistent();
cView::AddAnimation(fader);
} }
} }
@ -332,6 +318,37 @@ cPoint cViewList::ShiftStart(cRect &shiftbox) {
return start; return start;
} }
void cViewList::SetShiftParameters(int index, int &call) {
if (itemCount == 1) {
listElements[index]->SetSuppressAnimation(true);
return;
}
listElements[index]->SetSuppressAnimation(cleared);
if (listElements[index]->WasCurrent()) {
if (call == 0) {
call++;
listElements[index]->SetSelectedFromTop();
} else if (call == 1) {
call++;
listElements[index]->SetSelectedFromBottom();
}
} else if (listElements[index]->Current()) {
if (call == 0) {
call++;
listElements[index]->SetSelectedFromBottom();
} else if (call == 1) {
call++;
listElements[index]->SetSelectedFromTop();
}
}
}
void cViewList::CheckListAnimation(int index) {
itemCount++;
if (listElements[index])
listElements[index]->StopListAnimation();
}
/****************************************************************** /******************************************************************
* cViewListDefault * cViewListDefault
******************************************************************/ ******************************************************************/
@ -364,6 +381,7 @@ void cViewListDefault::Prepare(int start, int step) {
listDefault[i] = new cLeMenuDefault(*tpl); listDefault[i] = new cLeMenuDefault(*tpl);
listElements[i] = listDefault[i]; listElements[i] = listDefault[i];
listDefault[i]->SetNumber(i); listDefault[i]->SetNumber(i);
listDefault[i]->SetOrientation(orientation);
listDefault[i]->SetTokenContainer(); listDefault[i]->SetTokenContainer();
int x, y, width, height; int x, y, width, height;
if (orientation == eOrientation::vertical) { if (orientation == eOrientation::vertical) {
@ -446,6 +464,7 @@ void cViewListDefault::SetTabs(int tab1, int tab2, int tab3, int tab4, int tab5)
void cViewListDefault::Set(const char *text, int index, bool current, bool selectable) { void cViewListDefault::Set(const char *text, int index, bool current, bool selectable) {
if (index < 0 || index >= numElements) if (index < 0 || index >= numElements)
return; return;
CheckListAnimation(index);
if (!current) if (!current)
listDefault[index]->StopScrolling(); listDefault[index]->StopScrolling();
listDefault[index]->SetCurrent(current); listDefault[index]->SetCurrent(current);
@ -489,6 +508,7 @@ void cViewListMain::Prepare(int start, int step) {
listMain[i] = new cLeMenuMain(*tpl); listMain[i] = new cLeMenuMain(*tpl);
listElements[i] = listMain[i]; listElements[i] = listMain[i];
listMain[i]->SetNumber(i); listMain[i]->SetNumber(i);
listMain[i]->SetOrientation(orientation);
listMain[i]->SetTokenContainer(); listMain[i]->SetTokenContainer();
int x, y, width, height; int x, y, width, height;
if (orientation == eOrientation::vertical) { if (orientation == eOrientation::vertical) {
@ -524,6 +544,7 @@ void cViewListMain::Prepare(int start, int step) {
void cViewListMain::Set(const char *text, int index, bool current, bool selectable) { void cViewListMain::Set(const char *text, int index, bool current, bool selectable) {
if (index < 0 || index >= numElements) if (index < 0 || index >= numElements)
return; return;
CheckListAnimation(index);
if (!current) if (!current)
listMain[index]->StopScrolling(); listMain[index]->StopScrolling();
listMain[index]->SetCurrent(current); listMain[index]->SetCurrent(current);
@ -568,6 +589,7 @@ void cViewListSchedules::Prepare(int start, int step) {
listSchedules[i] = new cLeMenuSchedules(*tpl); listSchedules[i] = new cLeMenuSchedules(*tpl);
listElements[i] = listSchedules[i]; listElements[i] = listSchedules[i];
listSchedules[i]->SetNumber(i); listSchedules[i]->SetNumber(i);
listSchedules[i]->SetOrientation(orientation);
listSchedules[i]->SetTokenContainer(); listSchedules[i]->SetTokenContainer();
int x, y, width, height; int x, y, width, height;
if (orientation == eOrientation::vertical) { if (orientation == eOrientation::vertical) {
@ -604,6 +626,7 @@ void cViewListSchedules::Set(const cEvent *event, int index, bool current, bool
const cChannel *channel, bool withDate, eTimerMatch timerMatch) { const cChannel *channel, bool withDate, eTimerMatch timerMatch) {
if (index < 0 || index >= numElements) if (index < 0 || index >= numElements)
return; return;
CheckListAnimation(index);
if (!current) if (!current)
listSchedules[index]->StopScrolling(); listSchedules[index]->StopScrolling();
listSchedules[index]->SetCurrent(current); listSchedules[index]->SetCurrent(current);
@ -640,6 +663,7 @@ void cViewListTimers::Prepare(int start, int step) {
listTimers[i] = new cLeMenuTimers(*tpl); listTimers[i] = new cLeMenuTimers(*tpl);
listElements[i] = listTimers[i]; listElements[i] = listTimers[i];
listTimers[i]->SetNumber(i); listTimers[i]->SetNumber(i);
listTimers[i]->SetOrientation(orientation);
listTimers[i]->SetTokenContainer(); listTimers[i]->SetTokenContainer();
int x, y, width, height; int x, y, width, height;
if (orientation == eOrientation::vertical) { if (orientation == eOrientation::vertical) {
@ -675,6 +699,7 @@ void cViewListTimers::Prepare(int start, int step) {
void cViewListTimers::Set(const cTimer *timer, int index, bool current, bool selectable) { void cViewListTimers::Set(const cTimer *timer, int index, bool current, bool selectable) {
if (index < 0 || index >= numElements) if (index < 0 || index >= numElements)
return; return;
CheckListAnimation(index);
if (!current) if (!current)
listTimers[index]->StopScrolling(); listTimers[index]->StopScrolling();
listTimers[index]->SetCurrent(current); listTimers[index]->SetCurrent(current);
@ -710,6 +735,7 @@ void cViewListChannels::Prepare(int start, int step) {
listChannels[i] = new cLeMenuChannels(*tpl); listChannels[i] = new cLeMenuChannels(*tpl);
listElements[i] = listChannels[i]; listElements[i] = listChannels[i];
listChannels[i]->SetNumber(i); listChannels[i]->SetNumber(i);
listChannels[i]->SetOrientation(orientation);
listChannels[i]->SetTokenContainer(); listChannels[i]->SetTokenContainer();
int x, y, width, height; int x, y, width, height;
if (orientation == eOrientation::vertical) { if (orientation == eOrientation::vertical) {
@ -745,6 +771,7 @@ void cViewListChannels::Prepare(int start, int step) {
void cViewListChannels::Set(const cChannel *channel, int index, bool current, bool selectable, bool withProvider) { void cViewListChannels::Set(const cChannel *channel, int index, bool current, bool selectable, bool withProvider) {
if (index < 0 || index >= numElements) if (index < 0 || index >= numElements)
return; return;
CheckListAnimation(index);
if (!current) if (!current)
listChannels[index]->StopScrolling(); listChannels[index]->StopScrolling();
listChannels[index]->SetCurrent(current); listChannels[index]->SetCurrent(current);
@ -780,6 +807,7 @@ void cViewListRecordings::Prepare(int start, int step) {
listRecordings[i] = new cLeMenuRecordings(*tpl); listRecordings[i] = new cLeMenuRecordings(*tpl);
listElements[i] = listRecordings[i]; listElements[i] = listRecordings[i];
listRecordings[i]->SetNumber(i); listRecordings[i]->SetNumber(i);
listRecordings[i]->SetOrientation(orientation);
listRecordings[i]->SetTokenContainer(); listRecordings[i]->SetTokenContainer();
int x, y, width, height; int x, y, width, height;
if (orientation == eOrientation::vertical) { if (orientation == eOrientation::vertical) {
@ -815,6 +843,7 @@ void cViewListRecordings::Prepare(int start, int step) {
void cViewListRecordings::Set(const cRecording *recording, int index, bool current, bool selectable, int level, int total, int New) { void cViewListRecordings::Set(const cRecording *recording, int index, bool current, bool selectable, int level, int total, int New) {
if (index < 0 || index >= numElements) if (index < 0 || index >= numElements)
return; return;
CheckListAnimation(index);
if (!current) if (!current)
listRecordings[index]->StopScrolling(); listRecordings[index]->StopScrolling();
listRecordings[index]->SetCurrent(current); listRecordings[index]->SetCurrent(current);
@ -853,6 +882,7 @@ void cViewListPlugin::Prepare(int start, int step) {
listPlugin[i] = new cLeMenuPlugin(*tpl); listPlugin[i] = new cLeMenuPlugin(*tpl);
listElements[i] = listPlugin[i]; listElements[i] = listPlugin[i];
listPlugin[i]->SetNumber(i); listPlugin[i]->SetNumber(i);
listPlugin[i]->SetOrientation(orientation);
listPlugin[i]->SetPlugId(plugId); listPlugin[i]->SetPlugId(plugId);
listPlugin[i]->SetPlugMenuId(plugMenuId); listPlugin[i]->SetPlugMenuId(plugMenuId);
listPlugin[i]->SetTokenContainer(); listPlugin[i]->SetTokenContainer();
@ -893,6 +923,7 @@ void cViewListPlugin::Prepare(int start, int step) {
void cViewListPlugin::Set(skindesignerapi::cTokenContainer *tk, int index, bool current, bool selectable) { void cViewListPlugin::Set(skindesignerapi::cTokenContainer *tk, int index, bool current, bool selectable) {
if (index < 0 || index >= numElements) if (index < 0 || index >= numElements)
return; return;
CheckListAnimation(index);
if (!current) if (!current)
listPlugin[index]->StopScrolling(); listPlugin[index]->StopScrolling();
listPlugin[index]->SetCurrent(current); listPlugin[index]->SetCurrent(current);
@ -1056,6 +1087,7 @@ void cViewListChannelList::Prepare(int start, int step) {
listChannelList[i] = new cLeChannelList(*tpl); listChannelList[i] = new cLeChannelList(*tpl);
listElements[i] = listChannelList[i]; listElements[i] = listChannelList[i];
listChannelList[i]->SetNumber(i); listChannelList[i]->SetNumber(i);
listChannelList[i]->SetOrientation(orientation);
listChannelList[i]->SetTokenContainer(); listChannelList[i]->SetTokenContainer();
int x, y, width, height; int x, y, width, height;
if (orientation == eOrientation::vertical) { if (orientation == eOrientation::vertical) {
@ -1080,6 +1112,7 @@ void cViewListChannelList::Prepare(int start, int step) {
void cViewListChannelList::Set(const cChannel *channel, int index, bool current) { void cViewListChannelList::Set(const cChannel *channel, int index, bool current) {
if (index < 0 || index >= numElements) if (index < 0 || index >= numElements)
return; return;
itemCount++;
if (!current) if (!current)
listChannelList[index]->StopScrolling(); listChannelList[index]->StopScrolling();
listChannelList[index]->SetCurrent(current); listChannelList[index]->SetCurrent(current);
@ -1113,6 +1146,7 @@ void cViewListGroupList::Prepare(int start, int step) {
listGroupList[i] = new cLeGroupList(*tpl); listGroupList[i] = new cLeGroupList(*tpl);
listElements[i] = listGroupList[i]; listElements[i] = listGroupList[i];
listGroupList[i]->SetNumber(i); listGroupList[i]->SetNumber(i);
listGroupList[i]->SetOrientation(orientation);
listGroupList[i]->SetTokenContainer(); listGroupList[i]->SetTokenContainer();
int x, y, width, height; int x, y, width, height;
if (orientation == eOrientation::vertical) { if (orientation == eOrientation::vertical) {
@ -1137,6 +1171,7 @@ void cViewListGroupList::Prepare(int start, int step) {
void cViewListGroupList::Set(const char *group, int numChannels, int index, bool current) { void cViewListGroupList::Set(const char *group, int numChannels, int index, bool current) {
if (index < 0 || index >= numElements) if (index < 0 || index >= numElements)
return; return;
CheckListAnimation(index);
if (!current) if (!current)
listGroupList[index]->StopScrolling(); listGroupList[index]->StopScrolling();
listGroupList[index]->SetCurrent(current); listGroupList[index]->SetCurrent(current);

View File

@ -16,13 +16,17 @@ protected:
skindesignerapi::cTokenContainer *tokenContainer; skindesignerapi::cTokenContainer *tokenContainer;
int numElements; int numElements;
eOrientation orientation; eOrientation orientation;
bool cleared;
int itemCount;
cViewElement *listElement; cViewElement *listElement;
cViewElement *currentElement; cViewElement *currentElement;
cListElement **listElements; cListElement **listElements;
cAnimation *fader; cFader *fader;
cAnimation *shifter; cShifter *shifter;
virtual void Prepare(int start, int step) {}; virtual void Prepare(int start, int step) {};
cPoint ShiftStart(cRect &shiftbox); cPoint ShiftStart(cRect &shiftbox);
void SetShiftParameters(int index, int &call);
void CheckListAnimation(int index);
public: public:
cViewList(void); cViewList(void);
virtual ~cViewList(void); virtual ~cViewList(void);
@ -42,6 +46,7 @@ public:
eOrientation Orientation(void); eOrientation Orientation(void);
void Draw(eMenuCategory menuCat); void Draw(eMenuCategory menuCat);
void Clear(void); void Clear(void);
void ResetItemCount(void) { itemCount = 0; };
virtual void Close(void); virtual void Close(void);
eButtonType Button(void) { return attribs->Button(); }; eButtonType Button(void) { return attribs->Button(); };
//Fadable //Fadable
@ -52,14 +57,12 @@ public:
//Shiftable //Shiftable
int ShiftTime(void) { return attribs->ShiftTime(); }; int ShiftTime(void) { return attribs->ShiftTime(); };
int ShiftMode(void) { return attribs->ShiftMode(); }; int ShiftMode(void) { return attribs->ShiftMode(); };
void ShiftPositions(cPoint *start, cPoint *end);
void SetPosition(cPoint &position, cPoint &reference, bool force = false); void SetPosition(cPoint &position, cPoint &reference, bool force = false);
void SetStartShifting(void) { }; void SetStartShifting(void) { };
void SetEndShifting(void) { }; void SetEndShifting(void) { };
void RegisterAnimation(void);
void UnregisterAnimation(void);
cRect CoveredArea(void); cRect CoveredArea(void);
void StartAnimation(void); void StartAnimation(bool animOut = false);
void Flush(bool animFlush);
void Debug(void); void Debug(void);
}; };

View File

@ -95,5 +95,5 @@ void cSDDisplayChannel::SetChannelHint(const cChannel *Channel) {
void cSDDisplayChannel::Flush(void) { void cSDDisplayChannel::Flush(void) {
if (!ok) if (!ok)
return; return;
view->Flush(false); view->Flush();
} }

View File

@ -165,7 +165,7 @@ bool cSDDisplayMenu::SetPluginText(skindesignerapi::cTokenContainer *tk) {
void cSDDisplayMenu::Flush(void) { void cSDDisplayMenu::Flush(void) {
if (view) if (view)
view->Flush(false); view->Flush();
} }
void cSDDisplayMenu::SetCurrentRecording(void) { void cSDDisplayMenu::SetCurrentRecording(void) {

View File

@ -21,5 +21,5 @@ void cSDDisplayMessage::SetMessage(eMessageType Type, const char *Text) {
void cSDDisplayMessage::Flush(void) { void cSDDisplayMessage::Flush(void) {
if (!ok) if (!ok)
return; return;
view->Flush(false); view->Flush();
} }

View File

@ -78,7 +78,7 @@ void cSDDisplayReplay::SetMessage(eMessageType Type, const char *Text) {
void cSDDisplayReplay::Flush(void) { void cSDDisplayReplay::Flush(void) {
if (!ok) if (!ok)
return; return;
view->Flush(false); view->Flush();
} }
void cSDDisplayReplay::SetTimeShiftValues(const cRecording *recording) { void cSDDisplayReplay::SetTimeShiftValues(const cRecording *recording) {

View File

@ -27,5 +27,5 @@ void cSDDisplayTracks::SetAudioChannel(int AudioChannel) {
void cSDDisplayTracks::Flush(void) { void cSDDisplayTracks::Flush(void) {
if (!ok) if (!ok)
return; return;
view->Flush(false); view->Flush();
} }

View File

@ -22,5 +22,5 @@ void cSDDisplayVolume::SetVolume(int Current, int Total, bool Mute) {
void cSDDisplayVolume::Flush(void) { void cSDDisplayVolume::Flush(void) {
if (!ok) if (!ok)
return; return;
view->Flush(false); view->Flush();
} }

View File

@ -349,6 +349,8 @@
<!ELEMENT listelement (areacontainer|area|areascroll)*> <!ELEMENT listelement (areacontainer|area|areascroll)*>
<!ATTLIST listelement <!ATTLIST listelement
fadetime CDATA #IMPLIED
shifttime CDATA #IMPLIED
debug CDATA #IMPLIED debug CDATA #IMPLIED
> >

View File

@ -468,6 +468,8 @@
<!ELEMENT listelement (areacontainer|area|areascroll)*> <!ELEMENT listelement (areacontainer|area|areascroll)*>
<!ATTLIST listelement <!ATTLIST listelement
fadetime CDATA #IMPLIED
shifttime CDATA #IMPLIED
debug CDATA #IMPLIED debug CDATA #IMPLIED
> >

View File

@ -117,6 +117,8 @@
<!ELEMENT listelement (areacontainer|area|areascroll)*> <!ELEMENT listelement (areacontainer|area|areascroll)*>
<!ATTLIST listelement <!ATTLIST listelement
fadetime CDATA #IMPLIED
shifttime CDATA #IMPLIED
debug CDATA #IMPLIED debug CDATA #IMPLIED
> >
@ -125,6 +127,11 @@
condition CDATA #IMPLIED condition CDATA #IMPLIED
delay CDATA #IMPLIED delay CDATA #IMPLIED
fadetime CDATA #IMPLIED fadetime CDATA #IMPLIED
shifttime CDATA #IMPLIED
shifttype CDATA #IMPLIED
shiftmode CDATA #IMPLIED
startx CDATA #IMPLIED
starty CDATA #IMPLIED
debug CDATA #IMPLIED debug CDATA #IMPLIED
> >

View File

@ -18,6 +18,7 @@
transparency CDATA #IMPLIED transparency CDATA #IMPLIED
condition CDATA #IMPLIED condition CDATA #IMPLIED
background (true|false) #IMPLIED background (true|false) #IMPLIED
indicator (true|false) #IMPLIED
debug (true|false) #IMPLIED debug (true|false) #IMPLIED
> >

View File

@ -3,7 +3,7 @@
NAME = skindesignerapi NAME = skindesignerapi
LIBNAME = lib$(NAME) LIBNAME = lib$(NAME)
MAJOR = 0 MAJOR = 0
MINOR = 1.1 MINOR = 1.2
VERSION = $(MAJOR).$(MINOR) VERSION = $(MAJOR).$(MINOR)
SONAME = $(LIBNAME).so.$(MAJOR) SONAME = $(LIBNAME).so.$(MAJOR)

View File

@ -198,5 +198,5 @@ skindesignerapi::cViewTab *skindesignerapi::cOsdView::GetViewTabs(void) {
void skindesignerapi::cOsdView::Display(void) { void skindesignerapi::cOsdView::Display(void) {
if (displayPlugin) if (displayPlugin)
displayPlugin->Flush(false); displayPlugin->Flush();
} }

View File

@ -47,7 +47,7 @@ public:
virtual void TabDown(int viewId) = 0; virtual void TabDown(int viewId) = 0;
virtual void DisplayTabs(int viewId) = 0; virtual void DisplayTabs(int viewId) = 0;
virtual void ClearTab(int viewId) = 0; virtual void ClearTab(int viewId) = 0;
virtual void Flush(bool animFlush) = 0; virtual void Flush(void) = 0;
virtual bool ChannelLogoExists(string channelId) = 0; virtual bool ChannelLogoExists(string channelId) = 0;
virtual string GetEpgImagePath(void) = 0; virtual string GetEpgImagePath(void) = 0;
}; };

View File

@ -6,7 +6,7 @@ msgid ""
msgstr "" msgstr ""
"Project-Id-Version: vdr-skindesigner 0.0.1\n" "Project-Id-Version: vdr-skindesigner 0.0.1\n"
"Report-Msgid-Bugs-To: <see README>\n" "Report-Msgid-Bugs-To: <see README>\n"
"POT-Creation-Date: 2016-06-18 13:23+0200\n" "POT-Creation-Date: 2016-07-03 07:31+0200\n"
"PO-Revision-Date: 2014-09-27 11:02+0200\n" "PO-Revision-Date: 2014-09-27 11:02+0200\n"
"Last-Translator: Louis Braun <louis.braun@gmx.de>\n" "Last-Translator: Louis Braun <louis.braun@gmx.de>\n"
"Language-Team: \n" "Language-Team: \n"
@ -87,6 +87,9 @@ msgstr "Skin gelöscht"
msgid "Plugin Setup" msgid "Plugin Setup"
msgstr "" msgstr ""
msgid "Frames per Second to display animations"
msgstr "Frames pro Sekunde für Animationen"
msgid "Maximum number of custom tokens" msgid "Maximum number of custom tokens"
msgstr "Maximale Anzahl Custom Tokens" msgstr "Maximale Anzahl Custom Tokens"

View File

@ -6,7 +6,7 @@ msgid ""
msgstr "" msgstr ""
"Project-Id-Version: vdr-skindesigner 0.2.0\n" "Project-Id-Version: vdr-skindesigner 0.2.0\n"
"Report-Msgid-Bugs-To: <see README>\n" "Report-Msgid-Bugs-To: <see README>\n"
"POT-Creation-Date: 2016-06-18 13:23+0200\n" "POT-Creation-Date: 2016-07-03 07:31+0200\n"
"PO-Revision-Date: 2015-01-25 01:25+0200\n" "PO-Revision-Date: 2015-01-25 01:25+0200\n"
"Last-Translator: Rolf Ahrenberg\n" "Last-Translator: Rolf Ahrenberg\n"
"Language-Team: Finnish\n" "Language-Team: Finnish\n"
@ -87,6 +87,9 @@ msgstr "Ulkoasu poistettu"
msgid "Plugin Setup" msgid "Plugin Setup"
msgstr "Yleiset" msgstr "Yleiset"
msgid "Frames per Second to display animations"
msgstr ""
msgid "Maximum number of custom tokens" msgid "Maximum number of custom tokens"
msgstr "Mukautettujen tokenien maksimimäärä" msgstr "Mukautettujen tokenien maksimimäärä"

View File

@ -6,7 +6,7 @@ msgid ""
msgstr "" msgstr ""
"Project-Id-Version: vdr-skindesigner 0.0.1\n" "Project-Id-Version: vdr-skindesigner 0.0.1\n"
"Report-Msgid-Bugs-To: <see README>\n" "Report-Msgid-Bugs-To: <see README>\n"
"POT-Creation-Date: 2016-06-18 13:23+0200\n" "POT-Creation-Date: 2016-07-03 07:31+0200\n"
"PO-Revision-Date: 2015-08-09 11:02+0200\n" "PO-Revision-Date: 2015-08-09 11:02+0200\n"
"Last-Translator: fiveten_59\n" "Last-Translator: fiveten_59\n"
"Language-Team: Italian\n" "Language-Team: Italian\n"
@ -87,6 +87,9 @@ msgstr "Skin eliminata"
msgid "Plugin Setup" msgid "Plugin Setup"
msgstr "Plugin Setup" msgstr "Plugin Setup"
msgid "Frames per Second to display animations"
msgstr ""
msgid "Maximum number of custom tokens" msgid "Maximum number of custom tokens"
msgstr "Numero massimo di token personalizzati" msgstr "Numero massimo di token personalizzati"

View File

@ -132,6 +132,7 @@ cSkinDesignerSetup::cSkinDesignerSetup(skindesignerapi::cPluginStructure *skinPr
rerunDistance = config.rerunDistance; rerunDistance = config.rerunDistance;
rerunMaxChannel = config.rerunMaxChannel; rerunMaxChannel = config.rerunMaxChannel;
numCustomTokens = config.numCustomTokens; numCustomTokens = config.numCustomTokens;
FPS = config.FPS;
menuDisplayStyle[0] = tr("after one another"); menuDisplayStyle[0] = tr("after one another");
menuDisplayStyle[1] = tr("at one go"); menuDisplayStyle[1] = tr("at one go");
#ifndef DO_NOT_USE_SKININSTALLER #ifndef DO_NOT_USE_SKININSTALLER
@ -272,6 +273,7 @@ void cSkinDesignerSetup::Store(void) {
config.rerunDistance = rerunDistance; config.rerunDistance = rerunDistance;
config.rerunMaxChannel = rerunMaxChannel; config.rerunMaxChannel = rerunMaxChannel;
config.numCustomTokens = numCustomTokens; config.numCustomTokens = numCustomTokens;
config.FPS = FPS;
config.InitSetupIterator(); config.InitSetupIterator();
cSkinSetup *skinSetup = NULL; cSkinSetup *skinSetup = NULL;
@ -296,6 +298,7 @@ void cSkinDesignerSetup::Store(void) {
SetupStore("RerunDistance", rerunDistance); SetupStore("RerunDistance", rerunDistance);
SetupStore("RerunMaxChannel", rerunMaxChannel); SetupStore("RerunMaxChannel", rerunMaxChannel);
SetupStore("NumCustomTokens", numCustomTokens); SetupStore("NumCustomTokens", numCustomTokens);
SetupStore("FPS", FPS);
} }
cOsdItem *cSkinDesignerSetup::InfoItem(const char *label) { cOsdItem *cSkinDesignerSetup::InfoItem(const char *label) {
@ -308,6 +311,7 @@ cOsdItem *cSkinDesignerSetup::InfoItem(const char *label) {
void cSkinDesignerSetup::PluginSetup(void) { void cSkinDesignerSetup::PluginSetup(void) {
Add(InfoItem(tr("Plugin Setup"))); Add(InfoItem(tr("Plugin Setup")));
Add(new cMenuEditIntItem(tr("Frames per Second to display animations"), &FPS, 10, 60));
Add(new cMenuEditIntItem(tr("Maximum number of custom tokens"), &numCustomTokens, 0, 100)); Add(new cMenuEditIntItem(tr("Maximum number of custom tokens"), &numCustomTokens, 0, 100));
Add(InfoItem(tr("Reruns"))); Add(InfoItem(tr("Reruns")));

View File

@ -49,6 +49,7 @@ private:
int rerunDistance; int rerunDistance;
int rerunMaxChannel; int rerunMaxChannel;
int numCustomTokens; int numCustomTokens;
int FPS;
const char *menuDisplayStyle[2]; const char *menuDisplayStyle[2];
void Setup(void); void Setup(void);
virtual void Store(void); virtual void Store(void);

View File

@ -5,6 +5,8 @@
<menu> <menu>
<parameter type="int" name="fadetime" min="0" max="1000" displaytext="{tr(fadetext)}" helptext="{tr(helpfade)}">0</parameter> <parameter type="int" name="fadetime" min="0" max="1000" displaytext="{tr(fadetext)}" helptext="{tr(helpfade)}">0</parameter>
<parameter type="int" name="shifttime" min="0" max="1000" displaytext="{tr(shifttext)}" helptext="{tr(helpshift)}">300</parameter> <parameter type="int" name="shifttime" min="0" max="1000" displaytext="{tr(shifttext)}" helptext="{tr(helpshift)}">300</parameter>
<parameter type="int" name="listfadetime" min="0" max="1000" displaytext="{tr(listfadetimetext)}" helptext="{tr(helplistfadetime)}">100</parameter>
<parameter type="int" name="listshifttime" min="0" max="1000" displaytext="{tr(listshifttimetext)}" helptext="{tr(helplistshifttime)}">0</parameter>
<submenu name="subdisplaychannel" displaytext="{tr(subdisplaychannel)}"> <submenu name="subdisplaychannel" displaytext="{tr(subdisplaychannel)}">
<parameter type="int" name="epgtextposy" min="0" max="100" displaytext="{tr(epgtextposy)}">5</parameter> <parameter type="int" name="epgtextposy" min="0" max="100" displaytext="{tr(epgtextposy)}">5</parameter>
<parameter type="int" name="epgtextfontsize" min="0" max="100" displaytext="{tr(epgtextfontsize)}">50</parameter> <parameter type="int" name="epgtextfontsize" min="0" max="100" displaytext="{tr(epgtextfontsize)}">50</parameter>
@ -305,6 +307,22 @@
<trans lang="hu_HU">Késleltetés idő ms-ben. Ha ez be van állítva, hogy az érték > 0, az összes OSD elemek mellett a VDR menü eltolódik, és ki a képernyő alján. Ha fadetime is ennek az értéke nagyobb 0, mindig eltolásával végezzük.</trans> <trans lang="hu_HU">Késleltetés idő ms-ben. Ha ez be van állítva, hogy az érték > 0, az összes OSD elemek mellett a VDR menü eltolódik, és ki a képernyő alján. Ha fadetime is ennek az értéke nagyobb 0, mindig eltolásával végezzük.</trans>
<trans lang="it_IT">Tempo di cambio in ms. Se questo è settato ad un valore maggiore di 0 tutti gli elementi OSD dietro al menù Vdr cambiano dalla parte bassa dello schermo. Se il tempo di cambio fosse settato anche ad un valore maggiore di zero, comunque il cambio viene effettuato</trans> <trans lang="it_IT">Tempo di cambio in ms. Se questo è settato ad un valore maggiore di 0 tutti gli elementi OSD dietro al menù Vdr cambiano dalla parte bassa dello schermo. Se il tempo di cambio fosse settato anche ad un valore maggiore di zero, comunque il cambio viene effettuato</trans>
</token> </token>
<token name="tr(listfadetimetext)">
<trans lang="en_EN">Fade time menus [ms]</trans>
<trans lang="de_DE">Überblendungszeit Menüs [ms]</trans>
</token>
<token name="tr(listshifttimetext)">
<trans lang="en_EN">Shift time menus [ms]</trans>
<trans lang="de_DE">Übergangszeit Menüelemente [ms]</trans>
</token>
<token name="tr(helplistfadetime)">
<trans lang="en_EN">Fade time of menu elements when scrolling through the menus. If set to 0, this effect is disabled.</trans>
<trans lang="de_DE">Überblendungszeit der Menüelemente beim Bewegen durch die Menüs. Steht dieser Wert auf 0, ist dieser Effekt deaktiviert.</trans>
</token>
<token name="tr(helplistshifttime)">
<trans lang="en_EN">Shift time of menu elements when scrolling through the menus. If set to 0, this effect is disabled.</trans>
<trans lang="de_DE">Übergangszeit der Menüelemente beim Bewegen durch die Menüs. Steht dieser Wert auf 0, ist dieser Effekt deaktiviert.</trans>
</token>
<!-- displaychannel --> <!-- displaychannel -->
<token name="tr(epgtextposy)"> <token name="tr(epgtextposy)">
<trans lang="en_EN">Vertical position EPG titel</trans> <trans lang="en_EN">Vertical position EPG titel</trans>

View File

@ -1,11 +1,13 @@
<menuchannels x="0" y="0" width="100%" height="100%" fadetime="0" scaletvx="39%" scaletvy="8%" scaletvwidth="60%" scaletvheight="60%"> <menuchannels x="0" y="0" width="100%" height="100%" fadetime="0" scaletvx="39%" scaletvy="8%" scaletvwidth="60%" scaletvheight="60%">
<menuitems x="2%" y="9%" orientation="vertical" width="98%" height="82%" align="center" numlistelements="{numitemschannels}"> <menuitems x="2%" y="9%" orientation="vertical" width="98%" height="82%" align="center" numlistelements="{numitemschannels}">
<listelement> <listelement fadetime="{listfadetime}" shifttime="{listshifttime}">
<area x="0" y="0" width="{areawidth}*0.305" height="100%" layer="2"> <area condition="{current}" indicator="true" x="0" y="0" width="{areawidth}*0.305" height="100%" layer="2">
<drawrectangle condition="not{current}" x="0" y="0" width="100%" height="100%" color="{menuback}" /> <drawrectangle x="0" y="0" width="100%" height="100%" color="{menubackactive}" />
<drawrectangle condition="not{current}" x="0" y="{areaheight}-1" width="100%" height="1" color="{menubackline}" /> </area>
<drawrectangle condition="{current}" x="0" y="0" width="100%" height="100%" color="{menubackactive}" /> <area condition="not{current}" x="0" y="0" width="{areawidth}*0.305" height="100%" layer="2">
<drawrectangle x="0" y="0" width="100%" height="100%" color="{menuback}" />
<drawrectangle x="0" y="{areaheight}-1" width="100%" height="1" color="{menubackline}" />
</area> </area>
<area condition="not{separator}" x="1%" y="0" width="5%" height="100%" layer="3"> <area condition="not{separator}" x="1%" y="0" width="5%" height="100%" layer="3">
<drawimage name="logo" imagetype="channellogo" path="{channelid}" x="0" width="100%" height="100%" valign="center" /> <drawimage name="logo" imagetype="channellogo" path="{channelid}" x="0" width="100%" height="100%" valign="center" />

View File

@ -13,12 +13,14 @@
</scrollbar> </scrollbar>
<menuitems x="2%" y="10%" orientation="vertical" width="96%" height="80%" align="center" menuitemwidth="94%" determinatefont="column1" numlistelements="{numitemsdefault}"> <menuitems x="2%" y="10%" orientation="vertical" width="96%" height="80%" align="center" menuitemwidth="94%" determinatefont="column1" numlistelements="{numitemsdefault}">
<listelement> <listelement fadetime="{listfadetime}" shifttime="{listshifttime}">
<!-- Background --> <!-- Background -->
<area x="0" y="0" width="100%" layer="2"> <area condition="{current}" indicator="true" x="0" y="0" width="100%" layer="2">
<drawrectangle condition="not{current}" x="0" y="0" width="100%" height="100%" color="{menuback}" /> <drawrectangle x="0" y="0" width="100%" height="100%" color="{menubackactive}" />
<drawrectangle condition="not{current}" x="0" y="{areaheight}-1" width="100%" height="1" color="{menubackline}" /> </area>
<drawrectangle condition="{current}" x="0" y="0" width="100%" height="100%" color="{menubackactive}" /> <area condition="not{current}" x="0" y="0" width="100%" layer="2">
<drawrectangle x="0" y="0" width="100%" height="100%" color="{menuback}" />
<drawrectangle x="0" y="{areaheight}-1" width="100%" height="1" color="{menubackline}" />
</area> </area>
<!-- Separators --> <!-- Separators -->
<area x="1%" condition="{separator}" width="98%" layer="3"> <area x="1%" condition="{separator}" width="98%" layer="3">

View File

@ -99,22 +99,24 @@
</temperatures> </temperatures>
<menuitems x="2%" y="9%" orientation="vertical" width="30%" height="60%" align="center" numlistelements="{numitemsmain}"> <menuitems x="2%" y="9%" orientation="vertical" width="30%" height="60%" align="center" numlistelements="{numitemsmain}">
<listelement> <listelement fadetime="{listfadetime}" shifttime="{listshifttime}">
<area x="0" y="0" width="100%" height="100%" layer="3"> <area condition="{current}" indicator="true" x="0" y="0" width="100%" height="100%" layer="3">
<drawrectangle condition="not{current}" x="0" y="0" width="100%" height="100%" color="{menuback}" /> <drawrectangle x="0" y="0" width="15%" height="100%" color="{menubackactivedark}" />
<drawrectangle condition="not{current}" x="0" y="{areaheight}-1" width="100%" height="1" color="{menubackline}" /> <drawrectangle x="15%" y="0" width="85%" height="100%" color="{menubackactive}" />
<drawrectangle condition="{current}" x="0" y="0" width="15%" height="100%" color="{menubackactivedark}" />
<drawrectangle condition="{current}" x="15%" y="0" width="85%" height="100%" color="{menubackactive}" />
</area> </area>
<area x="0" y="0" width="15%" height="100%" layer="3"> <area condition="not{current}" x="0" y="0" width="100%" height="100%" layer="3">
<drawrectangle x="0" y="0" width="100%" height="100%" color="{menuback}" />
<drawrectangle x="0" y="{areaheight}-1" width="100%" height="1" color="{menubackline}" />
</area>
<area x="0" y="0" width="15%" height="100%" layer="4">
<drawimage condition="not{current}" imagetype="menuicon" path="{icon}" align="center" valign="center" width="{areaheight}*{mainiconsize}/100" height="{areaheight}*{mainiconsize}/100"/> <drawimage condition="not{current}" imagetype="menuicon" path="{icon}" align="center" valign="center" width="{areaheight}*{mainiconsize}/100" height="{areaheight}*{mainiconsize}/100"/>
<drawimage condition="{current}" imagetype="menuicon" path="{icon}_active" align="center" valign="center" width="{areaheight}*{mainiconsize}/100" height="{areaheight}*{mainiconsize}/100"/> <drawimage condition="{current}" imagetype="menuicon" path="{icon}_active" align="center" valign="center" width="{areaheight}*{mainiconsize}/100" height="{areaheight}*{mainiconsize}/100"/>
</area> </area>
<areascroll condition="{showlistnumbers}" scrollelement="menutext" mode="forthandback" orientation="horizontal" delay="1000" scrollspeed="medium" x="20%" width="79%" layer="3"> <areascroll condition="{showlistnumbers}" scrollelement="menutext" mode="forthandback" orientation="horizontal" delay="1000" scrollspeed="medium" x="20%" width="79%" layer="4">
<drawtext condition="not{current}" x="0" valign="center" font="{regular}" fontsize="{areaheight}*{mainfontsize}/100" color="{fontdefault}" text="{number} {label}" /> <drawtext condition="not{current}" x="0" valign="center" font="{regular}" fontsize="{areaheight}*{mainfontsize}/100" color="{fontdefault}" text="{number} {label}" />
<drawtext condition="{current}" name="menutext" x="0" valign="center" font="{regular}" fontsize="{areaheight}*{mainfontsize}/100" color="{fontmenuactive}" text="{number} {label}" /> <drawtext condition="{current}" name="menutext" x="0" valign="center" font="{regular}" fontsize="{areaheight}*{mainfontsize}/100" color="{fontmenuactive}" text="{number} {label}" />
</areascroll> </areascroll>
<areascroll condition="not{showlistnumbers}" scrollelement="menutext" mode="forthandback" orientation="horizontal" delay="1000" scrollspeed="medium" x="20%" width="79%" layer="3"> <areascroll condition="not{showlistnumbers}" scrollelement="menutext" mode="forthandback" orientation="horizontal" delay="1000" scrollspeed="medium" x="20%" width="79%" layer="4">
<drawtext condition="not{current}" x="0" valign="center" font="{regular}" fontsize="{areaheight}*{mainfontsize}/100" color="{fontdefault}" text="{label}" /> <drawtext condition="not{current}" x="0" valign="center" font="{regular}" fontsize="{areaheight}*{mainfontsize}/100" color="{fontdefault}" text="{label}" />
<drawtext condition="{current}" name="menutext" x="0" valign="center" font="{regular}" fontsize="{areaheight}*{mainfontsize}/100" color="{fontmenuactive}" text="{label}" /> <drawtext condition="{current}" name="menutext" x="0" valign="center" font="{regular}" fontsize="{areaheight}*{mainfontsize}/100" color="{fontmenuactive}" text="{label}" />
</areascroll> </areascroll>

View File

@ -26,11 +26,13 @@
</scrollbar> </scrollbar>
<menuitems x="2%" y="9%" condition="eq({indexrecmenustyle}, 0)" orientation="vertical" width="98%" height="82%" align="center" numlistelements="{numitemsrecnarrow}"> <menuitems x="2%" y="9%" condition="eq({indexrecmenustyle}, 0)" orientation="vertical" width="98%" height="82%" align="center" numlistelements="{numitemsrecnarrow}">
<listelement> <listelement fadetime="{listfadetime}" shifttime="{listshifttime}">
<area x="0" y="0" width="{areawidth}*0.305" height="100%" layer="2"> <area condition="{current}" indicator="true" x="0" y="0" width="{areawidth}*0.305" height="100%" layer="2">
<drawrectangle condition="not{current}" x="0" y="0" width="100%" height="100%" color="{menuback}" /> <drawrectangle x="0" y="0" width="100%" height="100%" color="{menubackactive}" />
<drawrectangle condition="not{current}" x="0" y="{areaheight}-1" width="100%" height="1" color="{menubackline}" /> </area>
<drawrectangle condition="{current}" x="0" y="0" width="100%" height="100%" color="{menubackactive}" /> <area condition="not{current}" x="0" y="0" width="{areawidth}*0.305" height="100%" layer="2">
<drawrectangle x="0" y="0" width="100%" height="100%" color="{menuback}" />
<drawrectangle x="0" y="{areaheight}-1" width="100%" height="1" color="{menubackline}" />
</area> </area>
<!-- recording folder --> <!-- recording folder -->
<area condition="{folder}" x="1%" width="6%" layer="3"> <area condition="{folder}" x="1%" width="6%" layer="3">
@ -86,11 +88,13 @@
</menuitems> </menuitems>
<menuitems x="2%" y="9%" condition="eq({indexrecmenustyle}, 1)" orientation="vertical" width="95%" height="82%" align="center" numlistelements="{numitemsrecwide}"> <menuitems x="2%" y="9%" condition="eq({indexrecmenustyle}, 1)" orientation="vertical" width="95%" height="82%" align="center" numlistelements="{numitemsrecwide}">
<listelement> <listelement fadetime="{listfadetime}" shifttime="{listshifttime}">
<area x="0" y="0" width="100%" height="100%" layer="2"> <area condition="{current}" indicator="true" x="0" y="0" width="100%" height="100%" layer="2">
<drawrectangle condition="not{current}" x="0" y="0" width="100%" height="100%" color="{menuback}" /> <drawrectangle x="0" y="0" width="100%" height="100%" color="{menubackactive}" />
<drawrectangle condition="not{current}" x="0" y="{areaheight}-1" width="100%" height="1" color="{menubackline}" /> </area>
<drawrectangle condition="{current}" x="0" y="0" width="100%" height="100%" color="{menubackactive}" /> <area condition="not{current}" x="0" y="0" width="100%" height="100%" layer="2">
<drawrectangle x="0" y="0" width="100%" height="100%" color="{menuback}" />
<drawrectangle x="0" y="{areaheight}-1" width="100%" height="1" color="{menubackline}" />
</area> </area>
<!-- recording folder --> <!-- recording folder -->
<areacontainer condition="{folder}"> <areacontainer condition="{folder}">

View File

@ -34,12 +34,14 @@
</scrollbar> </scrollbar>
<menuitems condition="eq({indexschedulesmenustyle}, 0)" x="2%" y="9%" orientation="vertical" width="98%" height="82%" align="center" numlistelements="{numitemsscheduelesnarrow}"> <menuitems condition="eq({indexschedulesmenustyle}, 0)" x="2%" y="9%" orientation="vertical" width="98%" height="82%" align="center" numlistelements="{numitemsscheduelesnarrow}">
<listelement> <listelement fadetime="{listfadetime}" shifttime="{listshifttime}">
<!-- background and progressbar --> <!-- background and progressbar -->
<area condition="{current}" indicator="true" x="0" y="0" width="{areawidth}*0.305" height="100%" layer="2">
<drawrectangle x="0" y="0" width="100%" height="100%" color="{menubackactive}" />
</area>
<area x="0" y="0" width="{areawidth}*0.305" height="100%" layer="2"> <area x="0" y="0" width="{areawidth}*0.305" height="100%" layer="2">
<drawrectangle condition="not{current}" x="0" y="0" width="100%" height="100%" color="{menuback}" /> <drawrectangle condition="not{current}" x="0" y="0" width="100%" height="100%" color="{menuback}" />
<drawrectangle condition="not{current}" x="0" y="{areaheight}-1" width="100%" height="1" color="{menubackline}" /> <drawrectangle condition="not{current}" x="0" y="{areaheight}-1" width="100%" height="1" color="{menubackline}" />
<drawrectangle condition="{current}" x="0" y="0" width="100%" height="100%" color="{menubackactive}" />
<drawrectangle condition="{running}" x="65%" y="{areaheight}*0.1" width="{areawidth}*0.34" height="{areaheight}*0.12" color="{progressbarback}" /> <drawrectangle condition="{running}" x="65%" y="{areaheight}*0.1" width="{areawidth}*0.34" height="{areaheight}*0.12" color="{progressbarback}" />
<drawrectangle condition="{running}" x="65%" y="{areaheight}*0.1 + 1" width="{areawidth}*0.34*{elapsed}/{duration} - {elapsed}/{duration}" height="{areaheight}*0.12 - 3" color="{progressbar}" /> <drawrectangle condition="{running}" x="65%" y="{areaheight}*0.1 + 1" width="{areawidth}*0.34*{elapsed}/{duration} - {elapsed}/{duration}" height="{areaheight}*0.12 - 3" color="{progressbar}" />
</area> </area>
@ -140,12 +142,14 @@
</menuitems> </menuitems>
<menuitems condition="eq({indexschedulesmenustyle}, 1)" x="2%" y="9%" orientation="vertical" width="95%" height="82%" align="center" numlistelements="{numitemsscheduleswide}"> <menuitems condition="eq({indexschedulesmenustyle}, 1)" x="2%" y="9%" orientation="vertical" width="95%" height="82%" align="center" numlistelements="{numitemsscheduleswide}">
<listelement> <listelement fadetime="{listfadetime}" shifttime="{listshifttime}">
<!-- background and progressbar --> <!-- background and progressbar -->
<area condition="{current}" indicator="true" x="0" y="0" width="100%" height="100%" layer="2">
<drawrectangle x="0" y="0" width="100%" height="100%" color="{menubackactive}" />
</area>
<area x="0" y="0" width="100%" height="100%" layer="2"> <area x="0" y="0" width="100%" height="100%" layer="2">
<drawrectangle condition="not{current}" x="0" y="0" width="100%" height="100%" color="{menuback}" /> <drawrectangle condition="not{current}" x="0" y="0" width="100%" height="100%" color="{menuback}" />
<drawrectangle condition="not{current}" x="0" y="{areaheight}-1" width="100%" height="1" color="{menubackline}" /> <drawrectangle condition="not{current}" x="0" y="{areaheight}-1" width="100%" height="1" color="{menubackline}" />
<drawrectangle condition="{current}" x="0" y="0" width="100%" height="100%" color="{menubackactive}" />
<drawrectangle condition="{running}" x="30%" y="20%" width="10%" height="60%" color="{progressbarback}" /> <drawrectangle condition="{running}" x="30%" y="20%" width="10%" height="60%" color="{progressbarback}" />
<drawrectangle condition="{running}" x="{areawidth}*0.3 + 1" y="{areaheight}*0.2 + 1" width="{areawidth}*0.1*{elapsed}/{duration} - {elapsed}/{duration} - 1" height="{areaheight}*0.6 - 3" color="{progressbar}" /> <drawrectangle condition="{running}" x="{areawidth}*0.3 + 1" y="{areaheight}*0.2 + 1" width="{areawidth}*0.1*{elapsed}/{duration} - {elapsed}/{duration} - 1" height="{areaheight}*0.6 - 3" color="{progressbar}" />
</area> </area>

View File

@ -1,12 +1,14 @@
<menusetup x="0" y="0" width="100%" height="100%" fadetime="0" scaletvx="39%" scaletvy="8%" scaletvwidth="60%" scaletvheight="60%"> <menusetup x="0" y="0" width="100%" height="100%" fadetime="0" scaletvx="39%" scaletvy="8%" scaletvwidth="60%" scaletvheight="60%">
<menuitems x="2%" y="9%" orientation="vertical" width="98%" height="82%" align="center" numlistelements="10"> <menuitems x="2%" y="9%" orientation="vertical" width="98%" height="82%" align="center" numlistelements="10">
<listelement> <listelement fadetime="{listfadetime}" shifttime="{listshifttime}">
<area x="0" y="0" width="31%" height="100%" layer="2"> <area condition="{current}" indicator="true" x="0" y="0" width="31%" height="100%" layer="2">
<drawrectangle condition="not{current}" x="0" y="0" width="100%" height="100%" color="{menuback}" /> <drawrectangle x="0" y="0" width="15%" height="100%" color="{menubackactivedark}" />
<drawrectangle condition="not{current}" x="0" y="{areaheight}-1" width="100%" height="1" color="{menubackline}" /> <drawrectangle x="15%" y="0" width="85%" height="100%" color="{menubackactive}" />
<drawrectangle condition="{current}" x="0" y="0" width="15%" height="100%" color="{menubackactivedark}" /> </area>
<drawrectangle condition="{current}" x="15%" y="0" width="85%" height="100%" color="{menubackactive}" /> <area condition="not{current}" x="0" y="0" width="31%" height="100%" layer="2">
<drawrectangle x="0" y="0" width="100%" height="100%" color="{menuback}" />
<drawrectangle x="0" y="{areaheight}-1" width="100%" height="1" color="{menubackline}" />
</area> </area>
<area x="0" y="0" width="5%" height="100%" layer="3"> <area x="0" y="0" width="5%" height="100%" layer="3">
<drawimage condition="not{current}" imagetype="menuicon" path="{icon}" align="center" valign="center" width="{areaheight}*{mainiconsize}/100" height="{areaheight}*{mainiconsize}/100"/> <drawimage condition="not{current}" imagetype="menuicon" path="{icon}" align="center" valign="center" width="{areaheight}*{mainiconsize}/100" height="{areaheight}*{mainiconsize}/100"/>

View File

@ -1,11 +1,13 @@
<menutimers x="0" y="0" width="100%" height="100%" fadetime="0" scaletvx="39%" scaletvy="8%" scaletvwidth="60%" scaletvheight="60%"> <menutimers x="0" y="0" width="100%" height="100%" fadetime="0" scaletvx="39%" scaletvy="8%" scaletvwidth="60%" scaletvheight="60%">
<menuitems x="2%" y="9%" orientation="vertical" width="98%" height="82%" align="center" numlistelements="{numitemstimers}"> <menuitems x="2%" y="9%" orientation="vertical" width="98%" height="82%" align="center" numlistelements="{numitemstimers}">
<listelement> <listelement fadetime="{listfadetime}" shifttime="{listshifttime}">
<area x="0" y="0" width="{areawidth}*0.305" height="100%" layer="2"> <area condition="{current}" indicator="true" x="0" y="0" width="{areawidth}*0.305" height="100%" layer="2">
<drawrectangle condition="not{current}" x="0" y="0" width="100%" height="100%" color="{menuback}" /> <drawrectangle x="0" y="0" width="100%" height="100%" color="{menubackactive}" />
<drawrectangle condition="not{current}" x="0" y="{areaheight}-1" width="100%" height="1" color="{menubackline}" /> </area>
<drawrectangle condition="{current}" x="0" y="0" width="100%" height="100%" color="{menubackactive}" /> <area condition="not{current}" x="0" y="0" width="{areawidth}*0.305" height="100%" layer="2">
<drawrectangle x="0" y="0" width="100%" height="100%" color="{menuback}" />
<drawrectangle x="0" y="{areaheight}-1" width="100%" height="1" color="{menubackline}" />
</area> </area>
<area x="1%" y="0" width="5%" height="100%" layer="3"> <area x="1%" y="0" width="5%" height="100%" layer="3">
<drawimage name="logo" imagetype="channellogo" path="{channelid}" x="0" width="100%" height="100%" valign="center" /> <drawimage name="logo" imagetype="channellogo" path="{channelid}" x="0" width="100%" height="100%" valign="center" />

View File

@ -19,11 +19,13 @@
</scrollbar> </scrollbar>
<menuitems x="2%" y="10%" orientation="horizontal" width="96%" height="80%" align="center" numlistelements="3"> <menuitems x="2%" y="10%" orientation="horizontal" width="96%" height="80%" align="center" numlistelements="3">
<listelement> <listelement fadetime="{listfadetime}" shifttime="{listshifttime}">
<!-- Background --> <!-- Background -->
<area y="90%" height="10%" layer="2"> <area condition="{current}" indicator="true" y="90%" height="10%" layer="2">
<fill condition="not{current}" color="{menuback}" /> <fill color="{menubackactive}" />
<fill condition="{current}" color="{menubackactive}" /> </area>
<area condition="not{current}" y="90%" height="10%" layer="2">
<fill color="{menuback}" />
<drawrectangle x="{areawidth}-1" y="0" width="1" height="100%" color="{menubackline}"/> <drawrectangle x="{areawidth}-1" y="0" width="1" height="100%" color="{menubackline}"/>
</area> </area>
<area y="90%" height="10%" layer="3"> <area y="90%" height="10%" layer="3">

View File

@ -8,6 +8,8 @@
<parameter type="int" name="fadetimecurrent" min="0" max="1000" displaytext="{tr(fadecurrenttext)}" helptext="{tr(helpfadecurrent)}">50</parameter> <parameter type="int" name="fadetimecurrent" min="0" max="1000" displaytext="{tr(fadecurrenttext)}" helptext="{tr(helpfadecurrent)}">50</parameter>
<parameter type="int" name="shifttimechannel" min="0" max="1000" displaytext="{tr(shifttimechanneltext)}" helptext="{tr(helpshifttimechannel)}">0</parameter> <parameter type="int" name="shifttimechannel" min="0" max="1000" displaytext="{tr(shifttimechanneltext)}" helptext="{tr(helpshifttimechannel)}">0</parameter>
<parameter type="int" name="shifttimedatetime" min="0" max="1000" displaytext="{tr(shifttimedatetimetext)}" helptext="{tr(helpshifttimedatetime)}">200</parameter> <parameter type="int" name="shifttimedatetime" min="0" max="1000" displaytext="{tr(shifttimedatetimetext)}" helptext="{tr(helpshifttimedatetime)}">200</parameter>
<parameter type="int" name="listfadetime" min="0" max="1000" displaytext="{tr(listfadetimetext)}" helptext="{tr(helplistfadetime)}">0</parameter>
<parameter type="int" name="listshifttime" min="0" max="1000" displaytext="{tr(listshifttimetext)}" helptext="{tr(helplistshifttime)}">100</parameter>
<parameter type="string" name="showdevices" displaytext="{tr(showdevices)}" helptext="{tr(helpshowdevices)}" options="no,menu,yes">0</parameter> <parameter type="string" name="showdevices" displaytext="{tr(showdevices)}" helptext="{tr(helpshowdevices)}" options="no,menu,yes">0</parameter>
<parameter type="string" name="showweather" displaytext="{tr(showweather)}" helptext="{tr(helpshowweather)}" options="no,menu,yes">1</parameter> <parameter type="string" name="showweather" displaytext="{tr(showweather)}" helptext="{tr(helpshowweather)}" options="no,menu,yes">1</parameter>
<parameter type="string" name="recmenuorientation" displaytext="{tr(recmenuorientation)}" options="horizontal,vertical">1</parameter> <parameter type="string" name="recmenuorientation" displaytext="{tr(recmenuorientation)}" options="horizontal,vertical">1</parameter>
@ -196,6 +198,22 @@
<trans lang="fi_FI">Liukuman kesto millisekunteina. Nollasta eriävä arvo aktivoi transitioefektit päävalikon ajastimille.</trans> <trans lang="fi_FI">Liukuman kesto millisekunteina. Nollasta eriävä arvo aktivoi transitioefektit päävalikon ajastimille.</trans>
<trans lang="it_IT">Tempi di cambio del display dei Timer nel menù principale in ms. Se impostati a 0, i timers sono mostrati immediatamente.</trans> <trans lang="it_IT">Tempi di cambio del display dei Timer nel menù principale in ms. Se impostati a 0, i timers sono mostrati immediatamente.</trans>
</token> </token>
<token name="tr(listfadetimetext)">
<trans lang="en_EN">Fade time menus [ms]</trans>
<trans lang="de_DE">Überblendungszeit Menüs [ms]</trans>
</token>
<token name="tr(listshifttimetext)">
<trans lang="en_EN">Shift time menus [ms]</trans>
<trans lang="de_DE">Übergangszeit Menüelemente [ms]</trans>
</token>
<token name="tr(helplistfadetime)">
<trans lang="en_EN">Fade time of menu elements when scrolling through the menus. If set to 0, this effect is disabled.</trans>
<trans lang="de_DE">Überblendungszeit der Menüelemente beim Bewegen durch die Menüs. Steht dieser Wert auf 0, ist dieser Effekt deaktiviert.</trans>
</token>
<token name="tr(helplistshifttime)">
<trans lang="en_EN">Shift time of menu elements when scrolling through the menus. If set to 0, this effect is disabled.</trans>
<trans lang="de_DE">Übergangszeit der Menüelemente beim Bewegen durch die Menüs. Steht dieser Wert auf 0, ist dieser Effekt deaktiviert.</trans>
</token>
<token name="tr(showdevices)"> <token name="tr(showdevices)">
<trans lang="en_EN">Show DVB device info</trans> <trans lang="en_EN">Show DVB device info</trans>
<trans lang="de_DE">DVB Karten Info anzeigen</trans> <trans lang="de_DE">DVB Karten Info anzeigen</trans>

View File

@ -176,7 +176,6 @@
</area> </area>
</scrapercontent> </scrapercontent>
<channelhints> <channelhints>
<area background="true" x="0" y="{areaheight}*0.75 - {numhints}*{areaheight}*{zapchannelhintsheight}/1000 + 1" width="{zapchannelhintswidth}*{areawidth}/100" height="{numhints}*{areaheight}*{zapchannelhintsheight}/1000" layer="1"> <area background="true" x="0" y="{areaheight}*0.75 - {numhints}*{areaheight}*{zapchannelhintsheight}/1000 + 1" width="{zapchannelhintswidth}*{areawidth}/100" height="{numhints}*{areaheight}*{zapchannelhintsheight}/1000" layer="1">
<fill color="{menuback}" /> <fill color="{menuback}" />
@ -239,11 +238,13 @@
</channellistback> </channellistback>
<channellist x="0" y="0" orientation="vertical" width="30%" height="100%" align="center" numlistelements="{listitemsmax}" fadetime="{fadetimezapcockpit}" shifttime="{shifttimezapcockpit}" shiftmode="slowed" shifttype="left"> <channellist x="0" y="0" orientation="vertical" width="30%" height="100%" align="center" numlistelements="{listitemsmax}" fadetime="{fadetimezapcockpit}" shifttime="{shifttimezapcockpit}" shiftmode="slowed" shifttype="left">
<listelement> <listelement fadetime="{listfadetime}" shifttime="{listshifttime}">
<area x="0" width="100%" layer="4"> <area indicator="true" condition="{current}" x="0" width="100%" layer="4">
<drawrectangle condition="not{current}" x="0" y="0" width="100%" height="100%" color="{menuback}" /> <drawrectangle x="0" y="0" width="100%" height="100%" color="{menuactive}" />
<drawrectangle condition="not{current}" x="0" y="{areaheight}-1" width="100%" height="1" color="{menubackline}" /> </area>
<drawrectangle condition="{current}" x="0" y="0" width="100%" height="100%" color="{menuactive}" /> <area condition="not{current}" x="0" width="100%" layer="4">
<drawrectangle x="0" y="0" width="100%" height="100%" color="{menuback}" />
<drawrectangle x="0" y="{areaheight}-1" width="100%" height="1" color="{menubackline}" />
</area> </area>
<area x="1%" width="25%" layer="5"> <area x="1%" width="25%" layer="5">
<drawimage condition="{channellogoexists}" name="logo" imagetype="channellogo" path="{channelid}" align="center" width="80%" height="80%" valign="center" /> <drawimage condition="{channellogoexists}" name="logo" imagetype="channellogo" path="{channelid}" align="center" width="80%" height="80%" valign="center" />
@ -287,11 +288,13 @@
</grouplistback> </grouplistback>
<grouplist x="70%" y="0" orientation="vertical" width="30%" height="100%" align="center" numlistelements="{listitemsmax}-2" fadetime="{fadetimezapcockpit}" shifttime="{shifttimezapcockpit}" shiftmode="slowed" shifttype="right"> <grouplist x="70%" y="0" orientation="vertical" width="30%" height="100%" align="center" numlistelements="{listitemsmax}-2" fadetime="{fadetimezapcockpit}" shifttime="{shifttimezapcockpit}" shiftmode="slowed" shifttype="right">
<listelement> <listelement fadetime="{listfadetime}" shifttime="{listshifttime}">
<area x="0" width="100%" layer="5"> <area indicator="true" condition="{current}" x="0" width="100%" layer="5">
<drawrectangle condition="not{current}" x="0" y="0" width="100%" height="100%" color="{menuback}" /> <drawrectangle x="0" y="0" width="100%" height="100%" color="{menuactive}" />
<drawrectangle condition="not{current}" x="0" y="{areaheight}-1" width="100%" height="1" color="{menubackline}" /> </area>
<drawrectangle condition="{current}" x="0" y="0" width="100%" height="100%" color="{menuactive}" /> <area condition="not{current}" x="0" width="100%" layer="5">
<drawrectangle x="0" y="0" width="100%" height="100%" color="{menuback}" />
<drawrectangle x="0" y="{areaheight}-1" width="100%" height="1" color="{menubackline}" />
</area> </area>
<area x="0" width="24%" layer="5"> <area x="0" width="24%" layer="5">
<drawimage condition="not{current}" imagetype="icon" path="folder" align="center" valign="center" width="90%" height="90%" /> <drawimage condition="not{current}" imagetype="icon" path="folder" align="center" valign="center" width="90%" height="90%" />
@ -317,11 +320,13 @@
</groupchannellistback> </groupchannellistback>
<groupchannellist x="40%" y="3%" orientation="vertical" width="30%" height="94%" align="center" numlistelements="{listitemsmax}" fadetime="{fadetimezapcockpit}" shifttime="{shifttimezapcockpit}" shiftmode="slowed" startx="70%" starty="3%"> <groupchannellist x="40%" y="3%" orientation="vertical" width="30%" height="94%" align="center" numlistelements="{listitemsmax}" fadetime="{fadetimezapcockpit}" shifttime="{shifttimezapcockpit}" shiftmode="slowed" startx="70%" starty="3%">
<listelement> <listelement fadetime="{listfadetime}" shifttime="{listshifttime}">
<area x="0" width="100%" layer="2"> <area indicator="true" condition="{current}" x="0" width="100%" layer="2">
<drawrectangle condition="not{current}" x="0" y="0" width="100%" height="100%" color="{menuback}" /> <drawrectangle x="0" y="0" width="100%" height="100%" color="{menuactive}" />
<drawrectangle condition="not{current}" x="0" y="{areaheight}-1" width="100%" height="1" color="{menubackline}" /> </area>
<drawrectangle condition="{current}" x="0" y="0" width="100%" height="100%" color="{menuactive}" /> <area condition="not{current}" x="0" width="100%" layer="2">
<drawrectangle x="0" y="0" width="100%" height="100%" color="{menuback}" />
<drawrectangle x="0" y="{areaheight}-1" width="100%" height="1" color="{menubackline}" />
</area> </area>
<area x="1%" width="25%" layer="5"> <area x="1%" width="25%" layer="5">
<drawimage condition="{channellogoexists}" name="logo" imagetype="channellogo" path="{channelid}" align="center" width="80%" height="80%" valign="center" /> <drawimage condition="{channellogoexists}" name="logo" imagetype="channellogo" path="{channelid}" align="center" width="80%" height="80%" valign="center" />

View File

@ -1,6 +1,6 @@
<menuchannels x="0" y="0" width="100%" height="100%" fadetime="0"> <menuchannels x="0" y="0" width="100%" height="100%" fadetime="0">
<menuitems x="0" y="10%" orientation="vertical" width="100%" height="82%" align="center" numlistelements="{chlistitemsmax}"> <menuitems x="0" y="10%" orientation="vertical" width="100%" height="82%" align="center" numlistelements="{chlistitemsmax}">
<listelement> <listelement fadetime="{listfadetime}" shifttime="{listshifttime}">
<areacontainer condition="not{current}"> <areacontainer condition="not{current}">
<!-- Background --> <!-- Background -->
<area x="1%" width="58%" layer="2"> <area x="1%" width="58%" layer="2">
@ -24,7 +24,7 @@
</areacontainer> </areacontainer>
<areacontainer condition="{current}"> <areacontainer condition="{current}">
<!-- Background --> <!-- Background -->
<area x="1%" width="58%" layer="2"> <area indicator="true" x="1%" width="58%" layer="2">
<fill condition="{current}" color="{menuactive}" /> <fill condition="{current}" color="{menuactive}" />
<fill condition="{separator}" color="{menuseparator}" /> <fill condition="{separator}" color="{menuseparator}" />
</area> </area>

View File

@ -82,12 +82,10 @@
</scrollbar> </scrollbar>
<menuitems x="0" y="10%" orientation="vertical" width="94%" height="82%" align="center" menuitemwidth="94%" determinatefont="column1" numlistelements="{listitemsmax}"> <menuitems x="0" y="10%" orientation="vertical" width="94%" height="82%" align="center" menuitemwidth="94%" determinatefont="column1" numlistelements="{listitemsmax}">
<listelement> <listelement fadetime="{listfadetime}" shifttime="{listshifttime}">
<area x="0" condition="not{separator}" width="100%" layer="2"> <area indicator="true" condition="{current}++not{separator}" x="0" width="100%" layer="2">
<fill condition="not{current}" color="{clrTransparent}" /> <fill color="{menuactive}" />
<fill condition="{current}" color="{menuactive}" />
</area> </area>
<!-- Separators --> <!-- Separators -->
<area x="0" condition="{separator}" width="100%" layer="2"> <area x="0" condition="{separator}" width="100%" layer="2">
<fill color="{menualternate}" /> <fill color="{menualternate}" />

View File

@ -121,7 +121,7 @@
</areacontainer> </areacontainer>
</header> </header>
<datetime> <datetime shifttime="400" shifttype="right">
<area x="75%" y="0" width="12%" height="10%" layer="2"> <area x="75%" y="0" width="12%" height="10%" layer="2">
<drawtext align="right" y="0%" font="{light}" fontsize="55%" color="{fontactive}" text="{dayname}" /> <drawtext align="right" y="0%" font="{light}" fontsize="55%" color="{fontactive}" text="{dayname}" />
<drawtext align="right" y="45%" font="{light}" fontsize="55%" color="{fontactive}" text="{day}. {monthnameshort}" /> <drawtext align="right" y="45%" font="{light}" fontsize="55%" color="{fontactive}" text="{day}. {monthnameshort}" />
@ -131,7 +131,7 @@
</area> </area>
</datetime> </datetime>
<currentweather condition="gt({indexshowweather},0)"> <currentweather condition="gt({indexshowweather},0)" shifttime="400" shifttype="right">
<areacontainer condition="not{mainmenusmall}++eq({indexmainmenuorientation},0)"> <areacontainer condition="not{mainmenusmall}++eq({indexmainmenuorientation},0)">
<area x="50%" y="0" width="14%" height="10%" layer="3"> <area x="50%" y="0" width="14%" height="10%" layer="3">
<drawimage imagetype="icon" path="{icon}" align="center" valign="center" width="{areaheight}*0.9" height="{areaheight}*0.9"/> <drawimage imagetype="icon" path="{icon}" align="center" valign="center" width="{areaheight}*0.9" height="{areaheight}*0.9"/>
@ -455,23 +455,21 @@
</temperatures> </temperatures>
<menuitems x="0" y="7%" orientation="vertical" width="70%" height="57%" align="center" numlistelements="{menuitemsmax}"> <menuitems x="0" y="7%" orientation="vertical" width="70%" height="57%" align="center" numlistelements="{menuitemsmax}">
<listelement> <listelement fadetime="{listfadetime}" shifttime="{listshifttime}">
<areacontainer x="0" width="57%" condition="not{mainmenusmall}"> <areacontainer x="0" width="57%" condition="not{mainmenusmall}">
<area layer="2"> <area indicator="true" condition="{current}" layer="2">
<fill condition="not{current}" color="{clrTransparent}" /> <fill color="{menuactive}" />
<fill condition="{current}" color="{menuactive}" />
</area> </area>
<areascroll condition="{current}" scrollelement="menutext" mode="forthandback" orientation="horizontal" delay="2000" scrollspeed="medium" x="0" width="99%" layer="3"> <areascroll condition="{current}" scrollelement="menutext" mode="forthandback" orientation="horizontal" delay="2000" scrollspeed="medium" x="0" width="99%" layer="3">
<drawtext name="menutext" x="20" valign="center" font="{light}" fontsize="85%" color="{fontactive}" text="{number} {label}" /> <drawtext name="menutext" x="20" valign="center" font="{light}" fontsize="85%" color="{fontactive}" text="{number} {label}" />
</areascroll> </areascroll>
<areascroll condition="not{current}" scrollelement="menutext" mode="forthandback" orientation="horizontal" delay="2000" scrollspeed="medium" x="0" width="99%" layer="3"> <areascroll condition="not{current}" scrollelement="menutext" mode="forthandback" orientation="horizontal" delay="2000" scrollspeed="medium" x="0" width="99%" layer="4">
<drawtext name="menutext" x="20" valign="center" font="{light}" fontsize="85%" color="{fontdefault}" text="{number} {label}" /> <drawtext name="menutext" x="20" valign="center" font="{light}" fontsize="85%" color="{fontdefault}" text="{number} {label}" />
</areascroll> </areascroll>
</areacontainer> </areacontainer>
<areacontainer x="0" width="41%" condition="{mainmenusmall}"> <areacontainer x="0" width="41%" condition="{mainmenusmall}">
<area layer="2"> <area indicator="true" condition="{current}" layer="2">
<fill condition="not{current}" color="{clrTransparent}" /> <fill color="{menuactive}" />
<fill condition="{current}" color="{menuactive}" />
</area> </area>
<areascroll condition="{current}" scrollelement="menutext" mode="forthandback" orientation="horizontal" delay="2000" scrollspeed="medium" x="0" width="99%" layer="3"> <areascroll condition="{current}" scrollelement="menutext" mode="forthandback" orientation="horizontal" delay="2000" scrollspeed="medium" x="0" width="99%" layer="3">
<drawtext name="menutext" x="20" valign="center" font="{light}" fontsize="85%" color="{fontactive}" text="{number} {label}" /> <drawtext name="menutext" x="20" valign="center" font="{light}" fontsize="85%" color="{fontactive}" text="{number} {label}" />
@ -493,7 +491,7 @@
</menuitems> </menuitems>
<menuitems orientation="horizontal" condition="not{mainmenusmall}" x="2%" y="10%" width="96%" height="50%" align="center" numlistelements="{menuitemsmax}"> <menuitems orientation="horizontal" condition="not{mainmenusmall}" x="2%" y="10%" width="96%" height="50%" align="center" numlistelements="{menuitemsmax}">
<listelement> <listelement fadetime="{listfadetime}" shifttime="{listshifttime}">
<areacontainer condition="not{current}"> <areacontainer condition="not{current}">
<area x="0" width="100%" y="10%" height="80%" layer="3"> <area x="0" width="100%" y="10%" height="80%" layer="3">
<drawimage imagetype="menuicon" path="{icon}" align="center" valign="center" width="{areaheight}*0.4" height="{areaheight}*0.4"/> <drawimage imagetype="menuicon" path="{icon}" align="center" valign="center" width="{areaheight}*0.4" height="{areaheight}*0.4"/>
@ -503,7 +501,7 @@
</areascroll> </areascroll>
</areacontainer> </areacontainer>
<areacontainer condition="{current}"> <areacontainer condition="{current}">
<area x="0" y="15%" width="100%" height="75%" layer="2"> <area indicator="true" x="0" y="15%" width="100%" height="75%" layer="2">
<fill color="{menuactive}" /> <fill color="{menuactive}" />
</area> </area>
<area x="0" width="100%" y="10%" height="80%" layer="3"> <area x="0" width="100%" y="10%" height="80%" layer="3">
@ -516,14 +514,14 @@
</listelement> </listelement>
</menuitems> </menuitems>
<menuitems orientation="horizontal" condition="{mainmenusmall}" x="0" y="7%" width="44%" height="56%" align="center" numlistelements="{menuitemsmax}"> <menuitems orientation="horizontal" condition="{mainmenusmall}" x="0" y="7%" width="44%" height="56%" align="center" numlistelements="{menuitemsmax}">
<listelement> <listelement fadetime="{listfadetime}" shifttime="{listshifttime}">
<areacontainer condition="not{current}"> <areacontainer condition="not{current}">
<area x="0" width="100%" y="10%" height="60%" layer="3"> <area x="0" width="100%" y="10%" height="60%" layer="3">
<drawimage imagetype="menuicon" path="{icon}" valign="center" align="center" x="0" y="10%" width="{areawidth}*0.7" height="{areawidth}*0.7"/> <drawimage imagetype="menuicon" path="{icon}" valign="center" align="center" x="0" y="10%" width="{areawidth}*0.7" height="{areawidth}*0.7"/>
</area> </area>
</areacontainer> </areacontainer>
<areacontainer condition="{current}"> <areacontainer condition="{current}">
<area x="0" y="10%" width="100%" height="60%" layer="2"> <area indicator="true" x="0" y="10%" width="100%" height="60%" layer="2">
<fill color="{menuactive}" /> <fill color="{menuactive}" />
</area> </area>
<area x="0" width="100%" y="10%" height="60%" layer="3"> <area x="0" width="100%" y="10%" height="60%" layer="3">

View File

@ -44,10 +44,9 @@
</sortmode> </sortmode>
<menuitems x="0" y="10%" orientation="vertical" width="100%" height="82%" align="center" numlistelements="{listitemsmax}"> <menuitems x="0" y="10%" orientation="vertical" width="100%" height="82%" align="center" numlistelements="{listitemsmax}">
<listelement> <listelement fadetime="{listfadetime}" shifttime="{listshifttime}">
<!-- Background --> <!-- Background -->
<area x="1%" width="58%" layer="2"> <area indicator="true" x="1%" width="58%" layer="2">
<fill condition="not{current}" color="{clrTransparent}" />
<fill condition="{folder}" color="{menuseparator}" /> <fill condition="{folder}" color="{menuseparator}" />
<fill condition="{current}" color="{menuactive}" /> <fill condition="{current}" color="{menuactive}" />
</area> </area>
@ -99,10 +98,9 @@
</menuitems> </menuitems>
<menuitems x="0" y="10%" orientation="horizontal" width="100%" height="82%" align="center" numlistelements="10"> <menuitems x="0" y="10%" orientation="horizontal" width="100%" height="82%" align="center" numlistelements="10">
<listelement> <listelement fadetime="{listfadetime}" shifttime="{listshifttime}">
<!-- Background --> <!-- Background -->
<area y="64%" height="36%" layer="2"> <area indicator="true" y="64%" height="36%" layer="2">
<fill condition="not{current}" color="{clrTransparent}" />
<fill condition="{folder}" color="{menuseparator}" /> <fill condition="{folder}" color="{menuseparator}" />
<fill condition="{current}" color="{menuactive}" /> <fill condition="{current}" color="{menuactive}" />
</area> </area>

View File

@ -9,16 +9,16 @@
</header> </header>
<menuitems x="0" y="10%" orientation="vertical" width="100%" height="82%" align="center" numlistelements="{listitemsmax}"> <menuitems x="0" y="10%" orientation="vertical" width="100%" height="82%" align="center" numlistelements="{listitemsmax}">
<listelement> <listelement fadetime="{listfadetime}" shifttime="{listshifttime}">
<!-- Background --> <!-- Background -->
<area x="1%" width="58%" layer="2"> <area indicator="true" condition="{current}||{separator}" x="1%" width="58%" layer="2">
<fill condition="not{current}" color="{clrTransparent}" />
<fill condition="{current}" color="{menuactive}" /> <fill condition="{current}" color="{menuactive}" />
<fill condition="{separator}" color="{menuseparator}" /> <fill condition="{separator}" color="{menuseparator}" />
</area> </area>
<!-- WHATSON --> <!-- WHATSON -->
<areacontainer x="1%" width="58%" condition="not{separator}++{whatson}++not{current}"> <areacontainer x="1%" width="58%" condition="not{separator}++{whatson}++not{current}">
<area condition="not{running}" x="0" width="93%" layer="3"> <area condition="not{running}" width="93%" layer="3">
<drawtext name="menutext" x="20" valign="center" font="{light}" fontsize="90%" color="{fontdefault}" text="{start} {title}" /> <drawtext name="menutext" x="20" valign="center" font="{light}" fontsize="90%" color="{fontdefault}" text="{start} {title}" />
</area> </area>
<area condition="{running}" layer="3"> <area condition="{running}" layer="3">

View File

@ -46,10 +46,9 @@
</colorbuttons> </colorbuttons>
<menuitems x="0" y="10%" orientation="vertical" width="98%" height="80%" align="center" numlistelements="10"> <menuitems x="0" y="10%" orientation="vertical" width="98%" height="80%" align="center" numlistelements="10">
<listelement> <listelement fadetime="{listfadetime}" shifttime="{listshifttime}">
<area x="0" width="60%" layer="2"> <area indicator="true" condition="{current}" x="0" width="60%" layer="2">
<fill condition="not{current}" color="{clrTransparent}" /> <fill color="{menuactive}" />
<fill condition="{current}" color="{menuactive}" />
</area> </area>
<area condition="not{current}" x="0" width="60%" layer="3"> <area condition="not{current}" x="0" width="60%" layer="3">
<drawtext x="20" valign="center" font="{light}" fontsize="85%" color="{fontdefault}" text="{number} {label}" /> <drawtext x="20" valign="center" font="{light}" fontsize="85%" color="{fontdefault}" text="{number} {label}" />

View File

@ -1,10 +1,9 @@
<menutimers x="0" y="0" width="100%" height="100%" fadetime="0"> <menutimers x="0" y="0" width="100%" height="100%" fadetime="0">
<menuitems x="0" y="10%" orientation="vertical" width="100%" height="82%" align="center" numlistelements="{listitemsmax}"> <menuitems x="0" y="10%" orientation="vertical" width="100%" height="82%" align="center" numlistelements="{listitemsmax}">
<listelement> <listelement fadetime="{listfadetime}" shifttime="{listshifttime}">
<!-- Background --> <!-- Background -->
<area x="1%" width="58%" layer="2"> <area indicator="true" condition="{current}" x="1%" width="58%" layer="2">
<fill condition="not{current}" color="{clrTransparent}" /> <fill color="{menuactive}" />
<fill condition="{current}" color="{menuactive}" />
</area> </area>
<!-- Element --> <!-- Element -->
<areacontainer condition="not{current}"> <areacontainer condition="not{current}">

View File

@ -49,11 +49,10 @@
</scrollbar> </scrollbar>
<menuitems x="0" y="10%" orientation="vertical" width="100%" height="82%" align="center" numlistelements="10"> <menuitems x="0" y="10%" orientation="vertical" width="100%" height="82%" align="center" numlistelements="10">
<listelement> <listelement fadetime="{listfadetime}" shifttime="{listshifttime}">
<!-- Background --> <!-- Background -->
<area x="1%" width="46%" layer="2"> <area indicator="true" condition="{current}" x="1%" width="46%" layer="2">
<fill condition="not{current}" color="{clrTransparent}" /> <fill color="{menuactive}" />
<fill condition="{current}" color="{menuactive}" />
</area> </area>
<area x="1%" width="46%" layer="3"> <area x="1%" width="46%" layer="3">
<drawtext condition="not{current}" x="10" valign="center" font="{light}" fontsize="90%" color="{fontdefault}" text="{menuitemtext}" /> <drawtext condition="not{current}" x="10" valign="center" font="{light}" fontsize="90%" color="{fontdefault}" text="{menuitemtext}" />
@ -96,11 +95,10 @@
</currentelement> </currentelement>
</menuitems> </menuitems>
<menuitems x="0" y="10%" orientation="horizontal" width="100%" height="90%" align="center" numlistelements="3"> <menuitems x="0" y="10%" orientation="horizontal" width="100%" height="90%" align="center" numlistelements="3">
<listelement> <listelement fadetime="{listfadetime}" shifttime="{listshifttime}">
<!-- Background --> <!-- Background -->
<area y="80%" height="20%" layer="2"> <area indicator="true" condition="{current}" y="80%" height="20%" layer="2">
<fill condition="not{current}" color="{clrTransparent}" /> <fill color="{menuactive}" />
<fill condition="{current}" color="{menuactive}" />
</area> </area>
<area y="80%" height="20%" layer="3"> <area y="80%" height="20%" layer="3">
<drawtextbox condition="not{current}" x="0" y="0" width="100%" height="100%" align="center" valign="center" font="{light}" fontsize="40%" color="{fontdefault}" text="{menuitemtext}" /> <drawtextbox condition="not{current}" x="0" y="0" width="100%" height="100%" align="center" valign="center" font="{light}" fontsize="40%" color="{fontdefault}" text="{menuitemtext}" />