| 1182 | } |
| 1183 | |
| 1184 | void Viewer::animateHideGoToFlow() |
| 1185 | { |
| 1186 | if (goToFlow->isVisible() && showGoToFlowAnimation->state() != QPropertyAnimation::Running) { |
| 1187 | connect(showGoToFlowAnimation, &QAbstractAnimation::finished, goToFlow, &QWidget::hide); |
| 1188 | disconnect(showGoToFlowAnimation, &QAbstractAnimation::finished, this, &Viewer::moveCursoToGoToFlow); |
| 1189 | showGoToFlowAnimation->setStartValue(QPoint((width() - goToFlow->width()) / 2, height() - goToFlow->height())); |
| 1190 | showGoToFlowAnimation->setEndValue(QPoint((width() - goToFlow->width()) / 2, height())); |
| 1191 | showGoToFlowAnimation->start(); |
| 1192 | goToFlow->centerSlide(render->getIndex()); |
| 1193 | goToFlow->setPageNumber(render->getIndex()); |
| 1194 | this->setFocus(Qt::OtherFocusReason); |
| 1195 | } |
| 1196 | } |
| 1197 | |
| 1198 | void Viewer::moveCursoToGoToFlow() |
| 1199 | { |
no test coverage detected