mirror of
https://projects.vdr-developer.org/git/vdr-plugin-skindesigner.git
synced 2023-10-19 17:58:31 +02:00
fixed hiding of viewelemments when shifting
This commit is contained in:
parent
aec88498ff
commit
92553a8134
@ -325,6 +325,7 @@ void cAnimation::Shift(void) {
|
||||
|
||||
shiftable->SetStartShifting();
|
||||
uint64_t start = cTimeMs::Now();
|
||||
bool finished = false;
|
||||
while (Running() || !modeIn) {
|
||||
uint64_t now = cTimeMs::Now();
|
||||
if (Running() || !modeIn)
|
||||
@ -336,6 +337,7 @@ void cAnimation::Shift(void) {
|
||||
cCondWait::SleepMs(frametime - delta);
|
||||
}
|
||||
if ((int)(now - start) > shifttime) {
|
||||
finished = true;
|
||||
if ((Running() && modeIn) && pos != shiftend) {
|
||||
shiftable->SetPosition(shiftend, shiftend);
|
||||
shiftable->Flush();
|
||||
@ -354,6 +356,9 @@ void cAnimation::Shift(void) {
|
||||
pos.Set(pos.X() - stepX, pos.Y() - stepY);
|
||||
}
|
||||
}
|
||||
if (!finished) {
|
||||
shiftable->SetPosition(shiftend, shiftend);
|
||||
}
|
||||
shiftable->SetEndShifting();
|
||||
}
|
||||
|
||||
|
@ -283,6 +283,10 @@ void cViewElement::Clear(bool forceClearBackground) {
|
||||
}
|
||||
|
||||
void cViewElement::Hide(void) {
|
||||
delete shifter;
|
||||
shifter = NULL;
|
||||
delete fader;
|
||||
fader = NULL;
|
||||
for (cAreaNode *node = areaNodes.First(); node; node = areaNodes.Next(node)) {
|
||||
sdOsd->Lock();
|
||||
node->Hide();
|
||||
|
Loading…
x
Reference in New Issue
Block a user