qt: fix non-win32 status message when no mouse

This commit is contained in:
ts-korhonen
2022-01-15 01:39:22 +02:00
parent 188f1a1b7e
commit 07446719a4

View File

@@ -93,7 +93,10 @@ MainWindow::MainWindow(QWidget *parent) :
{
/* get the percentage and mouse message, TODO: refactor ui_window_title() */
auto parts = title.split(" - ");
toolbar_label->setText(QString("%1 - %2").arg(parts[1],parts.last()));
if (parts.size() < 5)
toolbar_label->setText(parts[1]);
else
toolbar_label->setText(QString("%1 - %2").arg(parts[1], parts.last()));
}
#endif
});