git.iko.soy/dashared/GDproject
on master help sign in
previous changes. coordinator improved. good version with card in news. will be removed soon...
1520ef7Darya Rednikina
Cartfile+2−1
@@ -5,4 +5,5 @@ github "macteo/Marklight"
5github "Alamofire/Alamofire" "5.0.0-beta.2"
5github "Alamofire/Alamofire" "5.0.0-beta.2"
6github "whitesmith/WSTagsField"
6github "whitesmith/WSTagsField"
7github "ReactiveCocoa/ReactiveCocoa" ~> 8.0
7github "ReactiveCocoa/ReactiveCocoa" ~> 8.0
8−github "52inc/Pulley"
8+github "52inc/Pulley"
9+github "HeroTransitions/Hero"
GDproject.xcodeproj/project.pbxproj+6
@@ -22,6 +22,8 @@
22 1291BE2D2221312D009D3F23 /* ChannelsCoordinator.swift in Sources */ = {isa = PBXBuildFile; fileRef = 1291BE2C2221312C009D3F23 /* ChannelsCoordinator.swift */; };
22 1291BE2D2221312D009D3F23 /* ChannelsCoordinator.swift in Sources */ = {isa = PBXBuildFile; fileRef = 1291BE2C2221312C009D3F23 /* ChannelsCoordinator.swift */; };
23 1291BE342221569B009D3F23 /* TabbarCoordinator.swift in Sources */ = {isa = PBXBuildFile; fileRef = 1291BE332221569B009D3F23 /* TabbarCoordinator.swift */; };
23 1291BE342221569B009D3F23 /* TabbarCoordinator.swift in Sources */ = {isa = PBXBuildFile; fileRef = 1291BE332221569B009D3F23 /* TabbarCoordinator.swift */; };
24 1291BE3622218DBF009D3F23 /* LogInCoordinator1.swift in Sources */ = {isa = PBXBuildFile; fileRef = 1291BE3522218DBF009D3F23 /* LogInCoordinator1.swift */; };
24 1291BE3622218DBF009D3F23 /* LogInCoordinator1.swift in Sources */ = {isa = PBXBuildFile; fileRef = 1291BE3522218DBF009D3F23 /* LogInCoordinator1.swift */; };
25+ 12924BD6224401D4003813B9 /* Hero.framework in Frameworks */ = {isa = PBXBuildFile; fileRef = 12924BD5224401D4003813B9 /* Hero.framework */; };
26+ 12924BD8224401DC003813B9 /* Hero.framework in Embed Frameworks */ = {isa = PBXBuildFile; fileRef = 12924BD5224401D4003813B9 /* Hero.framework */; settings = {ATTRIBUTES = (CodeSignOnCopy, RemoveHeadersOnCopy, ); }; };
25 12BA4B9B224101A400DF93D7 /* ApplicationCoordinator.swift in Sources */ = {isa = PBXBuildFile; fileRef = 12BA4B9A224101A400DF93D7 /* ApplicationCoordinator.swift */; };
27 12BA4B9B224101A400DF93D7 /* ApplicationCoordinator.swift in Sources */ = {isa = PBXBuildFile; fileRef = 12BA4B9A224101A400DF93D7 /* ApplicationCoordinator.swift */; };
26 12BA4B9D224101E700DF93D7 /* BaseCoordinator.swift in Sources */ = {isa = PBXBuildFile; fileRef = 12BA4B9C224101E700DF93D7 /* BaseCoordinator.swift */; };
28 12BA4B9D224101E700DF93D7 /* BaseCoordinator.swift in Sources */ = {isa = PBXBuildFile; fileRef = 12BA4B9C224101E700DF93D7 /* BaseCoordinator.swift */; };
27 12BA4B9F224102B700DF93D7 /* LogInCoordinator.swift in Sources */ = {isa = PBXBuildFile; fileRef = 12BA4B9E224102B700DF93D7 /* LogInCoordinator.swift */; };
29 12BA4B9F224102B700DF93D7 /* LogInCoordinator.swift in Sources */ = {isa = PBXBuildFile; fileRef = 12BA4B9E224102B700DF93D7 /* LogInCoordinator.swift */; };
@@ -82,6 +84,7 @@
82 12E36DBD221441D5006FCDD7 /* TinyConstraints.framework in Embed Frameworks */,
84 12E36DBD221441D5006FCDD7 /* TinyConstraints.framework in Embed Frameworks */,
83 12F3D6C02241130200A69214 /* ReactiveSwift.framework in Embed Frameworks */,
85 12F3D6C02241130200A69214 /* ReactiveSwift.framework in Embed Frameworks */,
84 12F3D6BC224112FD00A69214 /* ReactiveCocoa.framework in Embed Frameworks */,
86 12F3D6BC224112FD00A69214 /* ReactiveCocoa.framework in Embed Frameworks */,
87+ 12924BD8224401DC003813B9 /* Hero.framework in Embed Frameworks */,
85 123AD0E5223C1C4300326173 /* WSTagsField.framework in Embed Frameworks */,
88 123AD0E5223C1C4300326173 /* WSTagsField.framework in Embed Frameworks */,
86 12F3D6CA2242645800A69214 /* Pulley.framework in Embed Frameworks */,
89 12F3D6CA2242645800A69214 /* Pulley.framework in Embed Frameworks */,
87 12E36DC2221441E1006FCDD7 /* MarkdownKit.framework in Embed Frameworks */,
90 12E36DC2221441E1006FCDD7 /* MarkdownKit.framework in Embed Frameworks */,
@@ -105,6 +108,7 @@
105 1291BE2C2221312C009D3F23 /* ChannelsCoordinator.swift */ = {isa = PBXFileReference; lastKnownFileType = sourcecode.swift; path = ChannelsCoordinator.swift; sourceTree = "<group>"; };
108 1291BE2C2221312C009D3F23 /* ChannelsCoordinator.swift */ = {isa = PBXFileReference; lastKnownFileType = sourcecode.swift; path = ChannelsCoordinator.swift; sourceTree = "<group>"; };
106 1291BE332221569B009D3F23 /* TabbarCoordinator.swift */ = {isa = PBXFileReference; lastKnownFileType = sourcecode.swift; path = TabbarCoordinator.swift; sourceTree = "<group>"; };
109 1291BE332221569B009D3F23 /* TabbarCoordinator.swift */ = {isa = PBXFileReference; lastKnownFileType = sourcecode.swift; path = TabbarCoordinator.swift; sourceTree = "<group>"; };
107 1291BE3522218DBF009D3F23 /* LogInCoordinator1.swift */ = {isa = PBXFileReference; lastKnownFileType = sourcecode.swift; path = LogInCoordinator1.swift; sourceTree = "<group>"; };
110 1291BE3522218DBF009D3F23 /* LogInCoordinator1.swift */ = {isa = PBXFileReference; lastKnownFileType = sourcecode.swift; path = LogInCoordinator1.swift; sourceTree = "<group>"; };
111+ 12924BD5224401D4003813B9 /* Hero.framework */ = {isa = PBXFileReference; lastKnownFileType = wrapper.framework; name = Hero.framework; path = Carthage/Build/iOS/Hero.framework; sourceTree = "<group>"; };
108 12BA4B9A224101A400DF93D7 /* ApplicationCoordinator.swift */ = {isa = PBXFileReference; lastKnownFileType = sourcecode.swift; path = ApplicationCoordinator.swift; sourceTree = "<group>"; };
112 12BA4B9A224101A400DF93D7 /* ApplicationCoordinator.swift */ = {isa = PBXFileReference; lastKnownFileType = sourcecode.swift; path = ApplicationCoordinator.swift; sourceTree = "<group>"; };
109 12BA4B9C224101E700DF93D7 /* BaseCoordinator.swift */ = {isa = PBXFileReference; lastKnownFileType = sourcecode.swift; path = BaseCoordinator.swift; sourceTree = "<group>"; };
113 12BA4B9C224101E700DF93D7 /* BaseCoordinator.swift */ = {isa = PBXFileReference; lastKnownFileType = sourcecode.swift; path = BaseCoordinator.swift; sourceTree = "<group>"; };
110 12BA4B9E224102B700DF93D7 /* LogInCoordinator.swift */ = {isa = PBXFileReference; lastKnownFileType = sourcecode.swift; path = LogInCoordinator.swift; sourceTree = "<group>"; };
114 12BA4B9E224102B700DF93D7 /* LogInCoordinator.swift */ = {isa = PBXFileReference; lastKnownFileType = sourcecode.swift; path = LogInCoordinator.swift; sourceTree = "<group>"; };
@@ -156,6 +160,7 @@
156 12F3D6B8224112E900A69214 /* Result.framework in Frameworks */,
160 12F3D6B8224112E900A69214 /* Result.framework in Frameworks */,
157 12F3D6B6224112E100A69214 /* ReactiveSwift.framework in Frameworks */,
161 12F3D6B6224112E100A69214 /* ReactiveSwift.framework in Frameworks */,
158 12E36DDB221594B1006FCDD7 /* MarkdownKit.framework in Frameworks */,
162 12E36DDB221594B1006FCDD7 /* MarkdownKit.framework in Frameworks */,
163+ 12924BD6224401D4003813B9 /* Hero.framework in Frameworks */,
159 12E36DAF22143D40006FCDD7 /* Cartography.framework in Frameworks */,
164 12E36DAF22143D40006FCDD7 /* Cartography.framework in Frameworks */,
160 123AD0E3223C1C3900326173 /* WSTagsField.framework in Frameworks */,
165 123AD0E3223C1C3900326173 /* WSTagsField.framework in Frameworks */,
161 12E36DB322143D4E006FCDD7 /* Marklight.framework in Frameworks */,
166 12E36DB322143D4E006FCDD7 /* Marklight.framework in Frameworks */,
@@ -204,6 +209,7 @@
204 12E36D8F221424EA006FCDD7 = {
209 12E36D8F221424EA006FCDD7 = {
205 isa = PBXGroup;
210 isa = PBXGroup;
206 children = (
211 children = (
212+ 12924BD5224401D4003813B9 /* Hero.framework */,
207 12F3D6C72242644D00A69214 /* Pulley.framework */,
213 12F3D6C72242644D00A69214 /* Pulley.framework */,
208 12F3D6B9224112F500A69214 /* ReactiveCocoa.framework */,
214 12F3D6B9224112F500A69214 /* ReactiveCocoa.framework */,
209 12F3D6B7224112E800A69214 /* Result.framework */,
215 12F3D6B7224112E800A69214 /* Result.framework */,
GDproject.xcodeproj/xcshareddata/xcschemes/GDproject.xcscheme+2−2
@@ -43,8 +43,8 @@
43 </TestAction>
43 </TestAction>
44 <LaunchAction
44 <LaunchAction
45 buildConfiguration = "Debug"
45 buildConfiguration = "Debug"
46− selectedDebuggerIdentifier = "Xcode.DebuggerFoundation.Debugger.LLDB"
46+ selectedDebuggerIdentifier = ""
47− selectedLauncherIdentifier = "Xcode.DebuggerFoundation.Launcher.LLDB"
47+ selectedLauncherIdentifier = "Xcode.IDEFoundation.Launcher.PosixSpawn"
48 launchStyle = "0"
48 launchStyle = "0"
49 useCustomWorkingDirectory = "NO"
49 useCustomWorkingDirectory = "NO"
50 ignoresPersistentStateOnLaunch = "NO"
50 ignoresPersistentStateOnLaunch = "NO"
GDproject/Controller/ News and channels/NewsVC.swift+9
@@ -98,6 +98,15 @@ class NewsVC: UIViewController, UITableViewDelegate, UITableViewDataSource{
98 }
98 }
99}
99}
100
100
101+//extension NewsVC {
102+// override func prepare(for segue: UIStoryboardSegue, sender: Any?)
103+// {
104+// if let currentCell = sender as? PostViewCell,
105+// let vc = segue.destination as? FullPostController {
106+//
107+// }
108+// }
109+//}
101
110
102enum HeaderType {
111enum HeaderType {
103 case NONE
112 case NONE
GDproject/Controller/Coordinators/BaseCoordinator.swift+1−1
@@ -23,7 +23,7 @@ class BaseCoordinator: Coordinator {
23
23
24 // add only unique object
24 // add only unique object
25 func addDependency(_ coordinator: Coordinator) {
25 func addDependency(_ coordinator: Coordinator) {
26− guard !childCoordinators.contains(where: { $0 === coordinator }) else { return }
26+ guard !childCoordinators.contains(where: { $0 === coordinator }) else { return }
27 childCoordinators.append(coordinator)
27 childCoordinators.append(coordinator)
28 }
28 }
29
29
GDproject/Controller/Coordinators/TabbarCoordinator.swift+1−1
@@ -15,7 +15,7 @@ class TabBarCoordinator: BaseCoordinator {
15 var didEndFlow: (()->())?
15 var didEndFlow: (()->())?
16
16
17 private let tabbarView: TabbarView
17 private let tabbarView: TabbarView
18− private let window: UIWindow?
18+ private weak var window: UIWindow?
19
19
20 init(tabbarView: TabbarView, window: UIWindow) {
20 init(tabbarView: TabbarView, window: UIWindow) {
21 self.tabbarView = tabbarView
21 self.tabbarView = tabbarView
GDproject/Controller/Profile/ProfileViewController.swift+1−1
@@ -81,7 +81,7 @@ class ProfileViewController: UIViewController
81 override func viewDidLoad()
81 override func viewDidLoad()
82 {
82 {
83 super.viewDidLoad()
83 super.viewDidLoad()
84−
84+ print("hell")
85 posts.viewController = self
85 posts.viewController = self
86 posts.type = .NONE
86 posts.type = .NONE
87
87
GDproject/Simple model/Model.swift+2
@@ -7,6 +7,7 @@
7//
7//
8
8
9import Foundation
9import Foundation
10+import UIKit
10import Alamofire
11import Alamofire
11
12
12class Model{
13class Model{
@@ -17,6 +18,7 @@ class Model{
17 print(responce)
18 print(responce)
18 if responce == invalidTocken {
19 if responce == invalidTocken {
19 DataStorage.standard.setIsLoggedIn(value: false, with: 0)
20 DataStorage.standard.setIsLoggedIn(value: false, with: 0)
21+ (UIApplication.shared.delegate as! AppDelegate).relaunch()
20 }
22 }
21 }
23 }
22
24
GDproject/Supporting files/AppDelegate.swift+4
@@ -28,5 +28,9 @@ class AppDelegate: UIResponder, UIApplicationDelegate {
28
28
29 return true
29 return true
30 }
30 }
31+
32+ func relaunch(){
33+ appCoordinator.start()
34+ }
31}
35}
32
36