mirror of
https://github.com/GerbilSoft/rvthtool.git
synced 2025-06-18 19:45:35 -04:00
[qrvthtool] QRvtHToolWindow: Call d->updateActionEnableStatus() when necessary.
Otherwise, the actions don't get enabled/disabled properly. Among other things, the "Close" action remains enabled on startup with no device loaded, and remains enabled after closing a device in some cases.
This commit is contained in:
parent
c853e94705
commit
624a4a4c35
@ -562,9 +562,10 @@ QRvtHToolWindow::QRvtHToolWindow(QWidget *parent)
|
||||
//d->ui.lstBankList->sortByColumn(RvtHModel::COL_BANKNUM, Qt::AscendingOrder);
|
||||
|
||||
// Initialize the UI.
|
||||
d->updateLstBankList();
|
||||
d->initToolbar();
|
||||
d->updateLstBankList();
|
||||
d->updateWindowTitle();
|
||||
d->updateActionEnableStatus();
|
||||
|
||||
/** Progress bar widgets **/
|
||||
d->lblMessage = new QLabel();
|
||||
@ -706,6 +707,7 @@ void QRvtHToolWindow::openRvtH(const QString &filename)
|
||||
// Update the UI.
|
||||
d->updateLstBankList();
|
||||
d->updateWindowTitle();
|
||||
d->updateActionEnableStatus();
|
||||
|
||||
// FIXME: If a file is opened from the command line,
|
||||
// QTreeView sort-of selects the first file.
|
||||
@ -735,6 +737,7 @@ void QRvtHToolWindow::closeRvtH(void)
|
||||
// Update the UI.
|
||||
d->updateLstBankList();
|
||||
d->updateWindowTitle();
|
||||
d->updateActionEnableStatus();
|
||||
}
|
||||
|
||||
/**
|
||||
|
Loading…
Reference in New Issue
Block a user