mirror of
https://github.com/swift-project/pilotclient.git
synced 2026-05-05 01:35:45 +08:00
Issue #115 Main connect button only opens the login view
This commit is contained in:
@@ -244,15 +244,7 @@ bool SwiftGuiStd::isMainPageSelected(SwiftGuiStd::MainPageIndex mainPage) const
|
|||||||
void SwiftGuiStd::loginRequested()
|
void SwiftGuiStd::loginRequested()
|
||||||
{
|
{
|
||||||
if (!sGui || sGui->isShuttingDown() || !sGui->getIContextNetwork()) { return; }
|
if (!sGui || sGui->isShuttingDown() || !sGui->getIContextNetwork()) { return; }
|
||||||
if (ui->sw_MainMiddle->currentIndex() == static_cast<int>(MainPageLogin))
|
|
||||||
{
|
|
||||||
// already main page, we fake a re-trigger here
|
|
||||||
// emit this->currentMainInfoAreaChanged(ui->sw_MainMiddle->currentWidget());
|
|
||||||
ui->comp_Login->toggleNetworkConnection();
|
|
||||||
}
|
|
||||||
else
|
|
||||||
{
|
|
||||||
// const bool connected = sGui->getIContextNetwork()->isConnected();
|
|
||||||
const bool shift = QApplication::keyboardModifiers() & Qt::ShiftModifier;
|
const bool shift = QApplication::keyboardModifiers() & Qt::ShiftModifier;
|
||||||
if (shift)
|
if (shift)
|
||||||
{
|
{
|
||||||
@@ -269,7 +261,6 @@ void SwiftGuiStd::loginRequested()
|
|||||||
this->setMainPage(MainPageLogin);
|
this->setMainPage(MainPageLogin);
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
}
|
|
||||||
|
|
||||||
void SwiftGuiStd::onKickedFromNetwork(const QString &kickMessage)
|
void SwiftGuiStd::onKickedFromNetwork(const QString &kickMessage)
|
||||||
{
|
{
|
||||||
|
|||||||
Reference in New Issue
Block a user