[prev in list] [next in list] [prev in thread] [next in thread] 

List:       kde-commits
Subject:    [kaccounts-providers] /: Save the found server into a member variable
From:       Alex Fiestas <afiestas () kde ! org>
Date:       2015-10-15 21:01:19
Message-ID: E1ZmpeJ-0000yK-3S () scm ! kde ! org
[Download RAW message or body]

Git commit 1e8acd75f3abfd0733ee5a94bd2b8fb3d4046f58 by Alex Fiestas.
Committed on 17/04/2012 at 15:20.
Pushed by mklapetek into branch 'master'.

Save the found server into a member variable

M  +11   -1    basicinfo.cpp
M  +1    -0    basicinfo.h

http://commits.kde.org/kaccounts-providers/1e8acd75f3abfd0733ee5a94bd2b8fb3d4046f58

diff --git a/basicinfo.cpp b/basicinfo.cpp
index 440af6e..23a8060 100644
--- a/basicinfo.cpp
+++ b/basicinfo.cpp
@@ -54,7 +54,15 @@ bool BasicInfo::validatePage()
         return false;
     }
 
-    return m_validServer;
+    if (!m_validServer) {
+        return false;
+    }
+
+    m_wizard->setUsername(username->text());
+    m_wizard->setPassword(password->text());
+    m_wizard->setServer(m_server);
+
+    return true;
 }
 
 void BasicInfo::checkServer()
@@ -130,6 +138,8 @@ void BasicInfo::fileChecked(KJob* job)
         return;
     }
 
+    m_server = kJob->url();
+    m_server.setFileName("");
     setResult(true);
 }
 
diff --git a/basicinfo.h b/basicinfo.h
index 11aab16..c936866 100644
--- a/basicinfo.h
+++ b/basicinfo.h
@@ -54,6 +54,7 @@ class BasicInfo : public QWizardPage, Ui_Owncloud
         void setResult(bool result);
 
     private:
+        KUrl m_server;
         bool m_validServer;
         QByteArray m_json;
         KPixmapSequenceOverlayPainter *m_painter;

[prev in list] [next in list] [prev in thread] [next in thread] 

Configure | About | News | Add a list | Sponsored by KoreLogic