Commit 7bbdac3 1 parent 97460ce commit 7bbdac3 Copy full SHA for 7bbdac3
File tree 1 file changed +5
-5
lines changed
1 file changed +5
-5
lines changed Original file line number Diff line number Diff line change @@ -3169,12 +3169,12 @@ void Phototonic::reloadThumbs() {
3169
3169
void Phototonic::setImageViewerWindowTitle () {
3170
3170
QStandardItemModel *thumbModel = static_cast <QStandardItemModel*>(thumbsViewer->model ());
3171
3171
const int currentRow = thumbsViewer->currentIndex ().row ();
3172
+ if (currentRow < 0 ) { // model is still loading, yay threads
3173
+ setWindowTitle (QFileInfo (imageViewer->fullImagePath ).fileName ());
3174
+ return ;
3175
+ }
3172
3176
QString title = thumbModel->item (currentRow)->data (Qt::DisplayRole).toString ()
3173
- + " - ["
3174
- + QString::number (currentRow + 1 )
3175
- + " /"
3176
- + QString::number (thumbModel->rowCount ())
3177
- + " ] - Phototonic" ;
3177
+ + QString::fromLatin1 (" - [ %1 / %2 ] - Phototonic" ).arg (currentRow + 1 ).arg (thumbModel->rowCount ());
3178
3178
3179
3179
setWindowTitle (title);
3180
3180
}
You can’t perform that action at this time.
0 commit comments