mirror of
https://github.com/swift-project/pilotclient.git
synced 2026-04-03 15:45:46 +08:00
Improved context sensitive help
- create utilty function CGuiApplication::triggerShowHelp - this function also uses "QWhatsThis::leaveWhatsThisMode" which solves the problem that the help was not properly called a 2nd time - adjusted using classes
This commit is contained in:
@@ -56,9 +56,8 @@ namespace BlackGui
|
||||
|
||||
bool CUpdateInfoDialog::event(QEvent *event)
|
||||
{
|
||||
if (event->type() != QEvent::EnterWhatsThisMode) { return QDialog::event(event); }
|
||||
QTimer::singleShot(0, this, &CUpdateInfoDialog::requestHelp);
|
||||
return true;
|
||||
if (CGuiApplication::triggerShowHelp(this, event)) { return true; }
|
||||
return QDialog::event(event);
|
||||
}
|
||||
|
||||
void CUpdateInfoDialog::onDontShowAgain(bool dontShowAgain)
|
||||
@@ -71,10 +70,5 @@ namespace BlackGui
|
||||
const bool nv = ui->comp_UpdateInfo->isNewPilotClientVersionAvailable();
|
||||
ui->bb_UpdateInfolDialog->button(QDialogButtonBox::Ok)->setVisible(nv);
|
||||
}
|
||||
|
||||
void CUpdateInfoDialog::requestHelp()
|
||||
{
|
||||
if (sGui) { sGui->showHelp(this); }
|
||||
}
|
||||
} // ns
|
||||
} // ns
|
||||
|
||||
Reference in New Issue
Block a user