mirror of
https://github.com/bitcoin/bitcoin.git
synced 2026-02-10 23:51:29 +00:00
qt: Use GUIUtil::bringToFront where possible
Github-Pull: #14123 Rebased-From: 6fc21aca6d5e16c3ece104fec8e5b3df116893b4
This commit is contained in:
parent
ac73c7d433
commit
c470bbd19d
@ -663,10 +663,7 @@ void BitcoinGUI::aboutClicked()
|
||||
|
||||
void BitcoinGUI::showDebugWindow()
|
||||
{
|
||||
rpcConsole->showNormal();
|
||||
rpcConsole->show();
|
||||
rpcConsole->raise();
|
||||
rpcConsole->activateWindow();
|
||||
GUIUtil::bringToFront(rpcConsole);
|
||||
}
|
||||
|
||||
void BitcoinGUI::showDebugWindowActivateConsole()
|
||||
@ -1137,24 +1134,11 @@ void BitcoinGUI::showNormalIfMinimized(bool fToggleHidden)
|
||||
if(!clientModel)
|
||||
return;
|
||||
|
||||
// activateWindow() (sometimes) helps with keyboard focus on Windows
|
||||
if (isHidden())
|
||||
{
|
||||
show();
|
||||
activateWindow();
|
||||
}
|
||||
else if (isMinimized())
|
||||
{
|
||||
showNormal();
|
||||
activateWindow();
|
||||
}
|
||||
else if (GUIUtil::isObscured(this))
|
||||
{
|
||||
raise();
|
||||
activateWindow();
|
||||
}
|
||||
else if(fToggleHidden)
|
||||
if (!isHidden() && !isMinimized() && !GUIUtil::isObscured(this) && fToggleHidden) {
|
||||
hide();
|
||||
} else {
|
||||
GUIUtil::bringToFront(this);
|
||||
}
|
||||
}
|
||||
|
||||
void BitcoinGUI::toggleHidden()
|
||||
|
||||
@ -293,9 +293,7 @@ void WalletView::usedSendingAddresses()
|
||||
if(!walletModel)
|
||||
return;
|
||||
|
||||
usedSendingAddressesPage->show();
|
||||
usedSendingAddressesPage->raise();
|
||||
usedSendingAddressesPage->activateWindow();
|
||||
GUIUtil::bringToFront(usedSendingAddressesPage);
|
||||
}
|
||||
|
||||
void WalletView::usedReceivingAddresses()
|
||||
@ -303,9 +301,7 @@ void WalletView::usedReceivingAddresses()
|
||||
if(!walletModel)
|
||||
return;
|
||||
|
||||
usedReceivingAddressesPage->show();
|
||||
usedReceivingAddressesPage->raise();
|
||||
usedReceivingAddressesPage->activateWindow();
|
||||
GUIUtil::bringToFront(usedReceivingAddressesPage);
|
||||
}
|
||||
|
||||
void WalletView::showProgress(const QString &title, int nProgress)
|
||||
|
||||
Loading…
x
Reference in New Issue
Block a user