MCPcopy Create free account
hub / github.com/YACReader/yacreader / updateInformation

Method updateInformation

YACReader/viewer.cpp:1129–1150  ·  view source on GitHub ↗

Source from the content-addressed store, hash-verified

1127}
1128
1129void Viewer::updateInformation()
1130{
1131 if (render->hasLoadedComic()) {
1132 QString pagesInformation;
1133 if (continuousScroll && continuousViewModel->numPages() > 0) {
1134 pagesInformation = QString::number(continuousViewModel->readingProgressPage() + 1) + "/" + QString::number(continuousViewModel->numPages());
1135 } else {
1136 pagesInformation = render->getCurrentPagesInformation();
1137 }
1138
1139 auto displayTime = Configuration::getConfiguration().getShowTimeInInformation();
1140 if (displayTime) {
1141 informationLabel->setText(pagesInformation + " - " + QTime::currentTime().toString("HH:mm"));
1142 } else {
1143 informationLabel->setText(pagesInformation);
1144 }
1145
1146 informationLabel->adjustSize();
1147 informationLabel->update(); // TODO it shouldn't be neccesary
1148 informationLabel->updatePosition();
1149 }
1150}
1151
1152void Viewer::goToFlowSwitch()
1153{

Callers

nothing calls this directly

Calls 9

hasLoadedComicMethod · 0.80
readingProgressPageMethod · 0.80
toStringMethod · 0.80
numPagesMethod · 0.45
setTextMethod · 0.45
updateMethod · 0.45
updatePositionMethod · 0.45

Tested by

no test coverage detected