History

more work on authentication, show login window when domain asks

Stephen Birarda committed 12 years ago

Commit 8a0136e1 parent c762b9213 files · +165 −35Browse files

Showing the changes to interface/src/Menu.cpp (1 of 13 files). Show all

Unified · Split

interface/src/Menu.cpp+6−2
@@ -89,7 +89,7 @@ Menu::Menu() : · 88 unmodified lines
8989 MenuOption::Login,
9090 0,
9191 this,
92− SLOT(login())));
92+ SLOT(loginForCurrentDomain())));
9393
9494 addDisabledActionAndSeparator(fileMenu, "Scripts");
9595 addActionToQMenuAndActionHash(fileMenu, MenuOption::LoadScript, Qt::CTRL | Qt::Key_O, appInstance, SLOT(loadDialog()));
@@ -737,7 +737,11 @@ void sendFakeEnterEvent() { · 641 unmodified lines
737737 const int QLINE_MINIMUM_WIDTH = 400;
738738 const float DIALOG_RATIO_OF_WINDOW = 0.30f;
739739
740−void Menu::login() {
740+void Menu::loginForCurrentDomain() {
741+ showLoginForRootURL(NodeList::getInstance()->getDomainInfo().getRootAuthenticationURL());
742+}
743+
744+void Menu::showLoginForRootURL(const QUrl& rootURL) {
741745 QInputDialog loginDialog(Application::getInstance()->getWindow());
742746 loginDialog.setWindowTitle("Login");
743747 loginDialog.setLabelText("Username:");