IOS-137 add multiple accounts option with the new login
authorXavier Algarra <xavier@pep-project.org>
Tue, 06 Jun 2017 07:49:23 +0200
changeset 224875013a586bfd
parent 2247 2a30849f01c0
child 2249 bfc467d9e41e
IOS-137 add multiple accounts option with the new login
pEpForiOS/Base.lproj/Main.storyboard
pEpForiOS/UI/AccountsAndFolders/LoginTableViewController.swift
pEpForiOS/UI/EmailDisplay/EmailListViewController.swift
pEpForiOS/UI/Folder/FolderTableViewController.swift
pEpForiOS/UI/FolderViews.storyboard
     1.1 --- a/pEpForiOS/Base.lproj/Main.storyboard	Fri Jun 02 17:33:49 2017 +0200
     1.2 +++ b/pEpForiOS/Base.lproj/Main.storyboard	Tue Jun 06 07:49:23 2017 +0200
     1.3 @@ -153,7 +153,7 @@
     1.4                      <navigationItem key="navigationItem" title="Inbox" id="bgm-ua-A0f">
     1.5                          <barButtonItem key="rightBarButtonItem" title="Folders" id="QCE-EG-qmM">
     1.6                              <connections>
     1.7 -                                <segue destination="zK6-Pe-MeR" kind="show" id="cCK-Ah-mG1"/>
     1.8 +                                <segue destination="zK6-Pe-MeR" kind="show" identifier="segueFolderViews" id="cCK-Ah-mG1"/>
     1.9                              </connections>
    1.10                          </barButtonItem>
    1.11                      </navigationItem>
     2.1 --- a/pEpForiOS/UI/AccountsAndFolders/LoginTableViewController.swift	Fri Jun 02 17:33:49 2017 +0200
     2.2 +++ b/pEpForiOS/UI/AccountsAndFolders/LoginTableViewController.swift	Tue Jun 06 07:49:23 2017 +0200
     2.3 @@ -67,6 +67,7 @@
     2.4  
     2.5      override func viewWillAppear(_ animated: Bool) {
     2.6          updateView()
     2.7 +
     2.8      }
     2.9  
    2.10      func configureView(){
     3.1 --- a/pEpForiOS/UI/EmailDisplay/EmailListViewController.swift	Fri Jun 02 17:33:49 2017 +0200
     3.2 +++ b/pEpForiOS/UI/EmailDisplay/EmailListViewController.swift	Tue Jun 06 07:49:23 2017 +0200
     3.3 @@ -349,6 +349,7 @@
     3.4          case segueReplyAll
     3.5          case segueForward
     3.6          case segueFilter
     3.7 +        case segueFolderViews
     3.8          case noSegue
     3.9      }
    3.10  
    3.11 @@ -397,6 +398,10 @@
    3.12                  let vc = navVC.topViewController as? LoginTableViewController {
    3.13                  vc.appConfig = config?.appConfig
    3.14              }
    3.15 +        case .segueFolderViews:
    3.16 +            if let vC = segue.destination as? FolderTableViewController {
    3.17 +                vC.appConfig = config?.appConfig
    3.18 +            }
    3.19          case .segueEditAccounts, .segueCompose, .noSegue:
    3.20              break
    3.21          }
     4.1 --- a/pEpForiOS/UI/Folder/FolderTableViewController.swift	Fri Jun 02 17:33:49 2017 +0200
     4.2 +++ b/pEpForiOS/UI/Folder/FolderTableViewController.swift	Tue Jun 06 07:49:23 2017 +0200
     4.3 @@ -101,6 +101,15 @@
     4.4          }
     4.5      }
     4.6  
     4.7 +    override func prepare(for segue: UIStoryboardSegue, sender: Any?) {
     4.8 +        if segue.identifier == "newAccount" {
     4.9 +            if let navVC = segue.destination as? UINavigationController,
    4.10 +                let vc = navVC.topViewController as? LoginTableViewController {
    4.11 +                vc.appConfig = self.appConfig
    4.12 +            }
    4.13 +        }
    4.14 +    }
    4.15 +
    4.16      @IBAction func addAccount(_ sender: Any) {
    4.17          //add account action tbi
    4.18      }
     5.1 --- a/pEpForiOS/UI/FolderViews.storyboard	Fri Jun 02 17:33:49 2017 +0200
     5.2 +++ b/pEpForiOS/UI/FolderViews.storyboard	Tue Jun 06 07:49:23 2017 +0200
     5.3 @@ -30,7 +30,7 @@
     5.4                                      <state key="normal" image="button-add"/>
     5.5                                      <connections>
     5.6                                          <action selector="addAccount:" destination="6ra-tc-Aiv" eventType="touchUpInside" id="kwV-sP-A4A"/>
     5.7 -                                        <segue destination="uKb-Ku-Cng" kind="show" id="aKb-z0-Qyn"/>
     5.8 +                                        <segue destination="uKb-Ku-Cng" kind="show" identifier="newAccount" id="aKb-z0-Qyn"/>
     5.9                                      </connections>
    5.10                                  </button>
    5.11                                  <button opaque="NO" contentMode="scaleToFill" contentHorizontalAlignment="center" contentVerticalAlignment="center" buttonType="roundedRect" lineBreakMode="middleTruncation" translatesAutoresizingMaskIntoConstraints="NO" id="iQ7-gl-OPN">
    5.12 @@ -83,10 +83,10 @@
    5.13              </objects>
    5.14              <point key="canvasLocation" x="9633" y="-1187"/>
    5.15          </scene>
    5.16 -        <!--UINavigationController-Efv-29-FEv-->
    5.17 +        <!--AccountCreation-->
    5.18          <scene sceneID="rdR-gU-SsC">
    5.19              <objects>
    5.20 -                <viewControllerPlaceholder storyboardName="AccountCreation" referencedIdentifier="UINavigationController-Efv-29-FEv" id="uKb-Ku-Cng" sceneMemberID="viewController"/>
    5.21 +                <viewControllerPlaceholder storyboardName="AccountCreation" id="uKb-Ku-Cng" sceneMemberID="viewController"/>
    5.22                  <placeholder placeholderIdentifier="IBFirstResponder" id="7bq-Lz-J44" userLabel="First Responder" sceneMemberID="firstResponder"/>
    5.23              </objects>
    5.24              <point key="canvasLocation" x="9674" y="-1142"/>