1 Commits

Author SHA1 Message Date
Artem Kislitsyn 5e227d71bd minor 2014-10-21 16:13:14 +04:00
99 changed files with 4953 additions and 3966 deletions
+21
View File
@@ -0,0 +1,21 @@
Pod::Spec.new do |s|
s.name = 'AdaptiveController'
s.version = '0.0.1'
s.summary = 'AdaptiveController is a Progressive Reduction Swift module for adding custom states to Native or Custom UI elements.'
s.license = {"type"=>"MIT"}
s.authors = {"Artem Kislitsyn, Yuri Vasilenko"=>"juri.v@ramotion.com"}
s.homepage = 'https://github.com/Ramotion/adaptive-tab-bar'
s.frameworks = ["UIKit"]
s.requires_arc = true
s.source = {}
s.osx.platform = :osx, ''
s.osx.preserve_paths = 'AdaptiveController-0.0.1/osx/AdaptiveController.framework'
s.osx.public_header_files = 'AdaptiveController-0.0.1/osx/AdaptiveController.framework/Versions/A/Headers/*.h'
s.osx.vendored_frameworks = 'AdaptiveController-0.0.1/osx/AdaptiveController.framework'
s.ios.platform = :ios, "7.0"
s.ios.preserve_paths = 'AdaptiveController-0.0.1/ios/AdaptiveController.framework'
s.ios.public_header_files = 'AdaptiveController-0.0.1/ios/AdaptiveController.framework/Versions/A/Headers/*.h'
s.ios.vendored_frameworks = 'AdaptiveController-0.0.1/ios/AdaptiveController.framework'
end
@@ -0,0 +1,21 @@
Pod::Spec.new do |s|
s.name = 'AdaptiveController'
s.version = '0.0.1'
s.summary = 'AdaptiveController is a Progressive Reduction Swift module for adding custom states to Native or Custom UI elements.'
s.license = {"type"=>"MIT"}
s.authors = {"Artem Kislitsyn, Yuri Vasilenko"=>"juri.v@ramotion.com"}
s.homepage = 'https://github.com/Ramotion/adaptive-tab-bar'
s.frameworks = ["UIKit"]
s.requires_arc = true
s.source = {}
s.osx.platform = :osx, ''
s.osx.preserve_paths = 'AdaptiveController-0.0.1/osx/AdaptiveController.framework'
s.osx.public_header_files = 'AdaptiveController-0.0.1/osx/AdaptiveController.framework/Versions/A/Headers/*.h'
s.osx.vendored_frameworks = 'AdaptiveController-0.0.1/osx/AdaptiveController.framework'
s.ios.platform = :ios, "7.0"
s.ios.preserve_paths = 'AdaptiveController-0.0.1/ios/AdaptiveController.framework'
s.ios.public_header_files = 'AdaptiveController-0.0.1/ios/AdaptiveController.framework/Versions/A/Headers/*.h'
s.ios.vendored_frameworks = 'AdaptiveController-0.0.1/ios/AdaptiveController.framework'
end
@@ -0,0 +1 @@
Versions/Current/AdaptiveController
@@ -0,0 +1 @@
Versions/Current/Headers
@@ -0,0 +1,19 @@
//
// AdaptiveController.h
// AdaptiveController
//
// Created by Arcilite on 24.09.14.
// Copyright (c) 2014 Ramotion. All rights reserved.
//
#import <UIKit/UIKit.h>
//! Project version number for AdaptiveController.
FOUNDATION_EXPORT double AdaptiveControllerVersionNumber;
//! Project version string for AdaptiveController.
FOUNDATION_EXPORT const unsigned char AdaptiveControllerVersionString[];
// In this header, you should import all the public headers of your framework using statements like #import <AdaptiveController/PublicHeader.h>
@@ -0,0 +1 @@
A
@@ -0,0 +1 @@
Versions/Current/AdaptiveController
@@ -0,0 +1 @@
Versions/Current/Headers
@@ -0,0 +1,19 @@
//
// AdaptiveController.h
// AdaptiveController
//
// Created by Arcilite on 24.09.14.
// Copyright (c) 2014 Ramotion. All rights reserved.
//
#import <UIKit/UIKit.h>
//! Project version number for AdaptiveController.
FOUNDATION_EXPORT double AdaptiveControllerVersionNumber;
//! Project version string for AdaptiveController.
FOUNDATION_EXPORT const unsigned char AdaptiveControllerVersionString[];
// In this header, you should import all the public headers of your framework using statements like #import <AdaptiveController/PublicHeader.h>
@@ -0,0 +1 @@
A
+33 -9
View File
@@ -1,12 +1,36 @@
Pod::Spec.new do |s|
s.name = 'AdaptiveController'
s.version = '0.0.1'
s.license = { :type => 'MIT' }
s.name = 'AdaptiveController'
s.version = '0.0.8'
s.summary = 'AdaptiveController is a Progressive Reduction Swift module for adding custom states to Native or Custom UI elements.'
s.license = {"type"=>"MIT"}
s.authors = {"Artem Kislitsyn, Yuri Vasilenko"=>"juri.v@ramotion.com"}
s.homepage = 'https://github.com/Ramotion/adaptive-tab-bar'
s.authors = { 'Artem Kislitsyn, Yuri Vasilenko' => 'yuri.v@ramotion.com' }
s.summary = 'AdaptiveController is a Progressive Reduction Swift module for adding custom states to Native or Custom UI elements.'
s.source = { :git => 'https://github.com/Ramotion/adaptive-tab-bar.git', :tag => "#{s.version}" }
s.source_files = 'AdaptiveController/AdaptiveController/*.{h,swift}'
s.frameworks = 'Swift'
#s.frameworks = ["UIKit"]
s.frameworks = 'Foundation','UIKit'
#,'AdaptiveController'
s.requires_arc = true
end
s.source = { :git => 'https://github.com/Ramotion/adaptive-tab-bar.git', :tag => "#{s.version}" }
#s.source_files = 'AdaptiveController/AdaptiveController/*.{h}'
# Crashes here - Source_file imports MyFramework.h. If I take this out, it passes spec lint validation
s.osx.platform = :osx, ''
s.osx.preserve_paths = 'AdaptiveController-0.0.1/osx/AdaptiveController.framework'
s.osx.public_header_files = 'AdaptiveController-0.0.1/osx/AdaptiveController.framework/Versions/A/Headers/*.h'
s.osx.vendored_frameworks = 'AdaptiveController-0.0.1/osx/AdaptiveController.framework'
s.ios.platform = :ios, "7.0"
s.ios.preserve_paths = 'AdaptiveController-0.0.1/ios/AdaptiveController.framework'
s.ios.public_header_files = 'AdaptiveController-0.0.1/ios/AdaptiveController.framework/Versions/A/Headers/*.h','AdaptiveController/AdaptiveController/*.{h,swift}'
s.ios.vendored_frameworks = 'AdaptiveController-0.0.1/ios/AdaptiveController.framework'
#s.ios.resource = 'AdaptiveController-0.0.1/ios/AdaptiveController.framework/Versions/A/Resources/**/*'
#s.xcconfig = { 'OTHER_LDFLAGS' => '-framework AdaptiveController' }
end
Binary file not shown.
Binary file not shown.
+32
View File
@@ -0,0 +1,32 @@
Pod::Spec.new do |s|
s.name = 'AdaptiveController'
s.version = '0.0.2'
s.summary = 'AdaptiveController is a Progressive Reduction Swift module for adding custom states to Native or Custom UI elements.'
s.license = {"type"=>"MIT"}
s.authors = {"Artem Kislitsyn, Yuri Vasilenko"=>"juri.v@ramotion.com"}
s.homepage = 'https://github.com/Ramotion/adaptive-tab-bar'
s.frameworks = ["UIKit"]
#s.frameworks = 'Foundation', 'AdaptiveController','UIKit'
s.requires_arc = true
s.source = { :git => 'https://github.com/Ramotion/adaptive-tab-bar.git', :tag => "#{s.version}" }
s.source_files = 'AdaptiveController/AdaptiveController/*.{h,swift}'
# Crashes here - Source_file imports MyFramework.h. If I take this out, it passes spec lint validation
s.osx.platform = :osx, ''
#s.osx.preserve_paths = 'AdaptiveController-0.0.1/osx/AdaptiveController.framework'
s.osx.public_header_files = 'AdaptiveController-0.0.1/osx/AdaptiveController.framework/Versions/A/Headers/*.h', 'AdaptiveController/AdaptiveController/*.{h,swift}'
#s.osx.vendored_frameworks = 'AdaptiveController-0.0.1/osx/AdaptiveController.framework'
s.ios.platform = :ios, "7.0"
#s.ios.preserve_paths = 'AdaptiveController-0.0.1/ios/AdaptiveController.framework'
s.ios.public_header_files = 'AdaptiveController-0.0.1/ios/AdaptiveController.framework/Versions/A/Headers/*.h', 'AdaptiveController/AdaptiveController/*.{h,swift}'
#s.ios.vendored_frameworks = 'AdaptiveController-0.0.1/ios/AdaptiveController.framework'
end
+13
View File
@@ -0,0 +1,13 @@
Pod::Spec.new do |s|
s.name = 'AdaptiveController'
s.version = '0.0.1'
s.license = { :type => 'MIT' }
s.homepage = 'https://github.com/Ramotion/adaptive-tab-bar'
s.authors = { 'Artem Kislitsyn, Yuri Vasilenko' => 'yuri.v@ramotion.com' }
s.summary = 'AdaptiveController is a Progressive Reduction Swift module for adding custom states to Native or Custom UI elements.'
s.source = { :git => 'https://github.com/Ramotion/adaptive-tab-bar.git', :tag => "#{s.version}" }
s.ios.platform = :ios, '7.0'
s.source_files = 'AdaptiveController/AdaptiveController/*.{h,swift}'
s.frameworks = 'Swift','UIKit'
s.requires_arc = true
end
Binary file not shown.
@@ -7,60 +7,35 @@
objects = {
/* Begin PBXBuildFile section */
6A156E3E1A08B38E002A69AD /* DictioanarySerializer.swift in Sources */ = {isa = PBXBuildFile; fileRef = 6A156E3D1A08B38E002A69AD /* DictioanarySerializer.swift */; };
6A36BD4219FFDEDA00C19F61 /* ControlStateValueTest.swift in Sources */ = {isa = PBXBuildFile; fileRef = 6A36BD4119FFDEDA00C19F61 /* ControlStateValueTest.swift */; };
6A3E3A1C19E05E5B00C7504B /* AdaptiveLaunchesState.swift in Sources */ = {isa = PBXBuildFile; fileRef = 6A3E3A1B19E05E5B00C7504B /* AdaptiveLaunchesState.swift */; };
6A3ED0CA19ED02DA006F06DD /* DateExtension.swift in Sources */ = {isa = PBXBuildFile; fileRef = 6A3ED0C919ED02DA006F06DD /* DateExtension.swift */; };
6A3ED0CC19ED058F006F06DD /* AdaptiveDateStateTest.swift in Sources */ = {isa = PBXBuildFile; fileRef = 6A3ED0CB19ED058F006F06DD /* AdaptiveDateStateTest.swift */; };
6A3ED0CE19ED05D8006F06DD /* AdaptiveLaunchesStateTest.swift in Sources */ = {isa = PBXBuildFile; fileRef = 6A3ED0CD19ED05D8006F06DD /* AdaptiveLaunchesStateTest.swift */; };
6A6270A619F1653900D02B1A /* watch@2x.png in Resources */ = {isa = PBXBuildFile; fileRef = 6A6270A519F1653900D02B1A /* watch@2x.png */; };
6AAE857719D329C6005672CA /* AdaptiveButtonAppearance.swift in Sources */ = {isa = PBXBuildFile; fileRef = 6AAE857319D329C6005672CA /* AdaptiveButtonAppearance.swift */; };
6AAE857819D329C6005672CA /* AdaptiveButtonsStateManager.swift in Sources */ = {isa = PBXBuildFile; fileRef = 6AAE857419D329C6005672CA /* AdaptiveButtonsStateManager.swift */; };
6AAE857919D329C6005672CA /* AdaptiveDateState.swift in Sources */ = {isa = PBXBuildFile; fileRef = 6AAE857519D329C6005672CA /* AdaptiveDateState.swift */; };
6AAE857A19D329C6005672CA /* AdaptiveState.swift in Sources */ = {isa = PBXBuildFile; fileRef = 6AAE857619D329C6005672CA /* AdaptiveState.swift */; };
6ACDAABA1A1508BA0027A658 /* AppearenceSettingManager.swift in Sources */ = {isa = PBXBuildFile; fileRef = 6ACDAAB91A1508BA0027A658 /* AppearenceSettingManager.swift */; };
6AD1EC2619EFA9BA003F36A4 /* ControlStateValue.swift in Sources */ = {isa = PBXBuildFile; fileRef = 6AD1EC2519EFA9BA003F36A4 /* ControlStateValue.swift */; };
6AD1EC2919EFB8E2003F36A4 /* ControlStateProtocol.swift in Sources */ = {isa = PBXBuildFile; fileRef = 6AD1EC2819EFB8E2003F36A4 /* ControlStateProtocol.swift */; };
6AD1EC2B19F1165E003F36A4 /* TestTabBarItem.swift in Sources */ = {isa = PBXBuildFile; fileRef = 6AD1EC2A19F1165E003F36A4 /* TestTabBarItem.swift */; };
6AD4002919F792FA00630034 /* ControlStateAppearance.swift in Sources */ = {isa = PBXBuildFile; fileRef = 6AD4002819F792FA00630034 /* ControlStateAppearance.swift */; };
6AD4002B19F7A0B800630034 /* AppearanceSerializationProtocol.swift in Sources */ = {isa = PBXBuildFile; fileRef = 6AD4002A19F7A0B800630034 /* AppearanceSerializationProtocol.swift */; };
6AE723351A04EE6F003416B6 /* ControlStateAppearanceTest.swift in Sources */ = {isa = PBXBuildFile; fileRef = 6AE723341A04EE6F003416B6 /* ControlStateAppearanceTest.swift */; };
6AE723381A04F7AE003416B6 /* AdaptiveDateState.swift in Sources */ = {isa = PBXBuildFile; fileRef = 6AAE857519D329C6005672CA /* AdaptiveDateState.swift */; };
6AE723391A04F7B1003416B6 /* AdaptiveLaunchesState.swift in Sources */ = {isa = PBXBuildFile; fileRef = 6A3E3A1B19E05E5B00C7504B /* AdaptiveLaunchesState.swift */; };
6AE7233A1A04F7B4003416B6 /* AdaptiveButtonsStateManager.swift in Sources */ = {isa = PBXBuildFile; fileRef = 6AAE857419D329C6005672CA /* AdaptiveButtonsStateManager.swift */; };
6AE7233B1A04F7B6003416B6 /* AdaptiveButtonAppearance.swift in Sources */ = {isa = PBXBuildFile; fileRef = 6AAE857319D329C6005672CA /* AdaptiveButtonAppearance.swift */; };
6AE7233C1A04F7BA003416B6 /* ControlStateProtocol.swift in Sources */ = {isa = PBXBuildFile; fileRef = 6AD1EC2819EFB8E2003F36A4 /* ControlStateProtocol.swift */; };
6AE7233E1A04F7BF003416B6 /* AppearanceSerializationProtocol.swift in Sources */ = {isa = PBXBuildFile; fileRef = 6AD4002A19F7A0B800630034 /* AppearanceSerializationProtocol.swift */; };
6AE7233F1A04F7C3003416B6 /* ControlStateValue.swift in Sources */ = {isa = PBXBuildFile; fileRef = 6AD1EC2519EFA9BA003F36A4 /* ControlStateValue.swift */; };
6AE723401A04F7E5003416B6 /* AdaptiveState.swift in Sources */ = {isa = PBXBuildFile; fileRef = 6AAE857619D329C6005672CA /* AdaptiveState.swift */; };
6AE723411A04F7ED003416B6 /* ControlStateAppearance.swift in Sources */ = {isa = PBXBuildFile; fileRef = 6AD4002819F792FA00630034 /* ControlStateAppearance.swift */; };
6AE723451A07C8E1003416B6 /* AdaptiveButtonAppearanceTest.swift in Sources */ = {isa = PBXBuildFile; fileRef = 6AE723441A07C8E1003416B6 /* AdaptiveButtonAppearanceTest.swift */; };
6AF450671A10F99A00AC30A4 /* Constants.swift in Sources */ = {isa = PBXBuildFile; fileRef = 6AF450661A10F99A00AC30A4 /* Constants.swift */; };
6AFB70291A19F53E00221E66 /* AppearenceSettingManager.swift in Sources */ = {isa = PBXBuildFile; fileRef = 6ACDAAB91A1508BA0027A658 /* AppearenceSettingManager.swift */; };
6AFB702A1A19F54C00221E66 /* DictioanarySerializer.swift in Sources */ = {isa = PBXBuildFile; fileRef = 6A156E3D1A08B38E002A69AD /* DictioanarySerializer.swift */; };
6AFBC6D719D313D600D42578 /* AdaptiveController.h in Headers */ = {isa = PBXBuildFile; fileRef = 6AFBC6D619D313D600D42578 /* AdaptiveController.h */; settings = {ATTRIBUTES = (Public, ); }; };
6AFBC6E119D313D600D42578 /* AdaptiveControllerTests.swift in Sources */ = {isa = PBXBuildFile; fileRef = 6AFBC6E019D313D600D42578 /* AdaptiveControllerTests.swift */; };
/* End PBXBuildFile section */
/* Begin PBXFileReference section */
6A156E3D1A08B38E002A69AD /* DictioanarySerializer.swift */ = {isa = PBXFileReference; fileEncoding = 4; lastKnownFileType = sourcecode.swift; path = DictioanarySerializer.swift; sourceTree = "<group>"; };
6A36BD4119FFDEDA00C19F61 /* ControlStateValueTest.swift */ = {isa = PBXFileReference; fileEncoding = 4; lastKnownFileType = sourcecode.swift; path = ControlStateValueTest.swift; sourceTree = "<group>"; };
6A3E3A1B19E05E5B00C7504B /* AdaptiveLaunchesState.swift */ = {isa = PBXFileReference; fileEncoding = 4; lastKnownFileType = sourcecode.swift; path = AdaptiveLaunchesState.swift; sourceTree = "<group>"; };
6A3ED0C919ED02DA006F06DD /* DateExtension.swift */ = {isa = PBXFileReference; lastKnownFileType = sourcecode.swift; name = DateExtension.swift; path = "../../Samples/adaptive-dates-tabbar/adaptive-tab-bar/DateExtension.swift"; sourceTree = "<group>"; };
6A3ED0CB19ED058F006F06DD /* AdaptiveDateStateTest.swift */ = {isa = PBXFileReference; fileEncoding = 4; lastKnownFileType = sourcecode.swift; path = AdaptiveDateStateTest.swift; sourceTree = "<group>"; };
6A3ED0CD19ED05D8006F06DD /* AdaptiveLaunchesStateTest.swift */ = {isa = PBXFileReference; fileEncoding = 4; lastKnownFileType = sourcecode.swift; path = AdaptiveLaunchesStateTest.swift; sourceTree = "<group>"; };
6A6270A519F1653900D02B1A /* watch@2x.png */ = {isa = PBXFileReference; lastKnownFileType = image.png; path = "watch@2x.png"; sourceTree = "<group>"; };
6AAE857319D329C6005672CA /* AdaptiveButtonAppearance.swift */ = {isa = PBXFileReference; fileEncoding = 4; lastKnownFileType = sourcecode.swift; path = AdaptiveButtonAppearance.swift; sourceTree = "<group>"; };
6AAE857419D329C6005672CA /* AdaptiveButtonsStateManager.swift */ = {isa = PBXFileReference; fileEncoding = 4; lastKnownFileType = sourcecode.swift; path = AdaptiveButtonsStateManager.swift; sourceTree = "<group>"; };
6AAE857519D329C6005672CA /* AdaptiveDateState.swift */ = {isa = PBXFileReference; fileEncoding = 4; lastKnownFileType = sourcecode.swift; path = AdaptiveDateState.swift; sourceTree = "<group>"; };
6AAE857619D329C6005672CA /* AdaptiveState.swift */ = {isa = PBXFileReference; fileEncoding = 4; lastKnownFileType = sourcecode.swift; path = AdaptiveState.swift; sourceTree = "<group>"; };
6ACDAAB91A1508BA0027A658 /* AppearenceSettingManager.swift */ = {isa = PBXFileReference; fileEncoding = 4; lastKnownFileType = sourcecode.swift; path = AppearenceSettingManager.swift; sourceTree = "<group>"; };
6AD1EC2519EFA9BA003F36A4 /* ControlStateValue.swift */ = {isa = PBXFileReference; fileEncoding = 4; lastKnownFileType = sourcecode.swift; path = ControlStateValue.swift; sourceTree = "<group>"; };
6AD1EC2819EFB8E2003F36A4 /* ControlStateProtocol.swift */ = {isa = PBXFileReference; fileEncoding = 4; lastKnownFileType = sourcecode.swift; path = ControlStateProtocol.swift; sourceTree = "<group>"; };
6AD1EC2A19F1165E003F36A4 /* TestTabBarItem.swift */ = {isa = PBXFileReference; fileEncoding = 4; lastKnownFileType = sourcecode.swift; path = TestTabBarItem.swift; sourceTree = "<group>"; };
6AD4002819F792FA00630034 /* ControlStateAppearance.swift */ = {isa = PBXFileReference; fileEncoding = 4; lastKnownFileType = sourcecode.swift; path = ControlStateAppearance.swift; sourceTree = "<group>"; };
6AD4002A19F7A0B800630034 /* AppearanceSerializationProtocol.swift */ = {isa = PBXFileReference; fileEncoding = 4; lastKnownFileType = sourcecode.swift; path = AppearanceSerializationProtocol.swift; sourceTree = "<group>"; };
6AE723341A04EE6F003416B6 /* ControlStateAppearanceTest.swift */ = {isa = PBXFileReference; fileEncoding = 4; lastKnownFileType = sourcecode.swift; path = ControlStateAppearanceTest.swift; sourceTree = "<group>"; };
6AE723441A07C8E1003416B6 /* AdaptiveButtonAppearanceTest.swift */ = {isa = PBXFileReference; fileEncoding = 4; lastKnownFileType = sourcecode.swift; path = AdaptiveButtonAppearanceTest.swift; sourceTree = "<group>"; };
6AF450661A10F99A00AC30A4 /* Constants.swift */ = {isa = PBXFileReference; fileEncoding = 4; lastKnownFileType = sourcecode.swift; path = Constants.swift; sourceTree = "<group>"; };
6AFBC6D119D313D600D42578 /* AdaptiveController.framework */ = {isa = PBXFileReference; explicitFileType = wrapper.framework; includeInIndex = 0; path = AdaptiveController.framework; sourceTree = BUILT_PRODUCTS_DIR; };
6AFBC6D519D313D600D42578 /* Info.plist */ = {isa = PBXFileReference; lastKnownFileType = text.plist.xml; path = Info.plist; sourceTree = "<group>"; };
6AFBC6D619D313D600D42578 /* AdaptiveController.h */ = {isa = PBXFileReference; lastKnownFileType = sourcecode.c.h; path = AdaptiveController.h; sourceTree = "<group>"; };
@@ -87,14 +62,6 @@
/* End PBXFrameworksBuildPhase section */
/* Begin PBXGroup section */
6A156E3C1A08B322002A69AD /* Serializator */ = {
isa = PBXGroup;
children = (
6A156E3D1A08B38E002A69AD /* DictioanarySerializer.swift */,
);
name = Serializator;
sourceTree = "<group>";
};
6AAE857B19D329E0005672CA /* CustomAdaptiveStates */ = {
isa = PBXGroup;
children = (
@@ -117,7 +84,6 @@
children = (
6AAE857319D329C6005672CA /* AdaptiveButtonAppearance.swift */,
6AAE857419D329C6005672CA /* AdaptiveButtonsStateManager.swift */,
6ACDAAB91A1508BA0027A658 /* AppearenceSettingManager.swift */,
);
name = Appearance;
sourceTree = "<group>";
@@ -125,21 +91,12 @@
6AD1EC2719EFB521003F36A4 /* ControlStates */ = {
isa = PBXGroup;
children = (
6AD1EC2819EFB8E2003F36A4 /* ControlStateProtocol.swift */,
6AD1EC2519EFA9BA003F36A4 /* ControlStateValue.swift */,
6AD4002819F792FA00630034 /* ControlStateAppearance.swift */,
);
name = ControlStates;
sourceTree = "<group>";
};
6AD4002C19F7A12200630034 /* Protocols */ = {
isa = PBXGroup;
children = (
6AD4002A19F7A0B800630034 /* AppearanceSerializationProtocol.swift */,
6AD1EC2819EFB8E2003F36A4 /* ControlStateProtocol.swift */,
);
name = Protocols;
sourceTree = "<group>";
};
6AFBC6C719D313D600D42578 = {
isa = PBXGroup;
children = (
@@ -161,9 +118,6 @@
6AFBC6D319D313D600D42578 /* AdaptiveController */ = {
isa = PBXGroup;
children = (
6AF450661A10F99A00AC30A4 /* Constants.swift */,
6A156E3C1A08B322002A69AD /* Serializator */,
6AD4002C19F7A12200630034 /* Protocols */,
6AD1EC2719EFB521003F36A4 /* ControlStates */,
6AD1EC2319EFA903003F36A4 /* Appearance */,
6AAE857C19D32A14005672CA /* AdaptiveStates */,
@@ -185,14 +139,12 @@
6AFBC6DD19D313D600D42578 /* AdaptiveControllerTests */ = {
isa = PBXGroup;
children = (
6AE723441A07C8E1003416B6 /* AdaptiveButtonAppearanceTest.swift */,
6AE723341A04EE6F003416B6 /* ControlStateAppearanceTest.swift */,
6A6270A519F1653900D02B1A /* watch@2x.png */,
6A3ED0C919ED02DA006F06DD /* DateExtension.swift */,
6AFBC6E019D313D600D42578 /* AdaptiveControllerTests.swift */,
6A3ED0CB19ED058F006F06DD /* AdaptiveDateStateTest.swift */,
6A3ED0CD19ED05D8006F06DD /* AdaptiveLaunchesStateTest.swift */,
6AD1EC2A19F1165E003F36A4 /* TestTabBarItem.swift */,
6A36BD4119FFDEDA00C19F61 /* ControlStateValueTest.swift */,
6AFBC6DE19D313D600D42578 /* Supporting Files */,
);
path = AdaptiveControllerTests;
@@ -302,6 +254,7 @@
isa = PBXResourcesBuildPhase;
buildActionMask = 2147483647;
files = (
6A6270A619F1653900D02B1A /* watch@2x.png in Resources */,
);
runOnlyForDeploymentPostprocessing = 0;
};
@@ -312,17 +265,12 @@
isa = PBXSourcesBuildPhase;
buildActionMask = 2147483647;
files = (
6ACDAABA1A1508BA0027A658 /* AppearenceSettingManager.swift in Sources */,
6AAE857819D329C6005672CA /* AdaptiveButtonsStateManager.swift in Sources */,
6AD4002919F792FA00630034 /* ControlStateAppearance.swift in Sources */,
6A3E3A1C19E05E5B00C7504B /* AdaptiveLaunchesState.swift in Sources */,
6AAE857719D329C6005672CA /* AdaptiveButtonAppearance.swift in Sources */,
6AD4002B19F7A0B800630034 /* AppearanceSerializationProtocol.swift in Sources */,
6AD1EC2619EFA9BA003F36A4 /* ControlStateValue.swift in Sources */,
6AAE857919D329C6005672CA /* AdaptiveDateState.swift in Sources */,
6AF450671A10F99A00AC30A4 /* Constants.swift in Sources */,
6AD1EC2919EFB8E2003F36A4 /* ControlStateProtocol.swift in Sources */,
6A156E3E1A08B38E002A69AD /* DictioanarySerializer.swift in Sources */,
6AAE857A19D329C6005672CA /* AdaptiveState.swift in Sources */,
);
runOnlyForDeploymentPostprocessing = 0;
@@ -331,25 +279,11 @@
isa = PBXSourcesBuildPhase;
buildActionMask = 2147483647;
files = (
6AE723411A04F7ED003416B6 /* ControlStateAppearance.swift in Sources */,
6AE723351A04EE6F003416B6 /* ControlStateAppearanceTest.swift in Sources */,
6AE7233B1A04F7B6003416B6 /* AdaptiveButtonAppearance.swift in Sources */,
6AD1EC2B19F1165E003F36A4 /* TestTabBarItem.swift in Sources */,
6AE723391A04F7B1003416B6 /* AdaptiveLaunchesState.swift in Sources */,
6A3ED0CE19ED05D8006F06DD /* AdaptiveLaunchesStateTest.swift in Sources */,
6AE7233F1A04F7C3003416B6 /* ControlStateValue.swift in Sources */,
6AFB70291A19F53E00221E66 /* AppearenceSettingManager.swift in Sources */,
6AE7233E1A04F7BF003416B6 /* AppearanceSerializationProtocol.swift in Sources */,
6AE723451A07C8E1003416B6 /* AdaptiveButtonAppearanceTest.swift in Sources */,
6AFB702A1A19F54C00221E66 /* DictioanarySerializer.swift in Sources */,
6A3ED0CA19ED02DA006F06DD /* DateExtension.swift in Sources */,
6A3ED0CC19ED058F006F06DD /* AdaptiveDateStateTest.swift in Sources */,
6AFBC6E119D313D600D42578 /* AdaptiveControllerTests.swift in Sources */,
6A36BD4219FFDEDA00C19F61 /* ControlStateValueTest.swift in Sources */,
6AE7233C1A04F7BA003416B6 /* ControlStateProtocol.swift in Sources */,
6AE723401A04F7E5003416B6 /* AdaptiveState.swift in Sources */,
6AE723381A04F7AE003416B6 /* AdaptiveDateState.swift in Sources */,
6AE7233A1A04F7B4003416B6 /* AdaptiveButtonsStateManager.swift in Sources */,
);
runOnlyForDeploymentPostprocessing = 0;
};
@@ -461,7 +395,6 @@
INFOPLIST_FILE = AdaptiveController/Info.plist;
INSTALL_PATH = "$(LOCAL_LIBRARY_DIR)/Frameworks";
LD_RUNPATH_SEARCH_PATHS = "$(inherited) @executable_path/Frameworks @loader_path/Frameworks";
OTHER_SWIFT_FLAGS = "";
PRODUCT_NAME = "$(TARGET_NAME)";
SKIP_INSTALL = YES;
SWIFT_INCLUDE_PATHS = "";
@@ -482,7 +415,6 @@
INFOPLIST_FILE = AdaptiveController/Info.plist;
INSTALL_PATH = "$(LOCAL_LIBRARY_DIR)/Frameworks";
LD_RUNPATH_SEARCH_PATHS = "$(inherited) @executable_path/Frameworks @loader_path/Frameworks";
OTHER_SWIFT_FLAGS = "";
PRODUCT_NAME = "$(TARGET_NAME)";
SKIP_INSTALL = YES;
SWIFT_INCLUDE_PATHS = "";
@@ -4,12 +4,12 @@
<dict>
<key>SchemeUserState</key>
<dict>
<key>AdaptiveController.xcscheme_^#shared#^_</key>
<key>AdaptiveController.xcscheme</key>
<dict>
<key>orderHint</key>
<integer>0</integer>
</dict>
<key>AdaptiveControllerTests.xcscheme_^#shared#^_</key>
<key>AdaptiveControllerTests.xcscheme</key>
<dict>
<key>orderHint</key>
<integer>1</integer>
@@ -8,56 +8,171 @@
import UIKit
public class AdaptiveButtonAppearance: AppearanceSerializationProtocol{
public let defaultFont = UIFont(name: "Helvetica", size: 14.0)
public let kNotTitle = ""
public class AdaptiveButtonAppearance: NSObject {
public typealias StateObject = ControlStateValue
public typealias DictionaryObject = Dictionary <String,AnyObject>
public var stateDictionary:Dictionary <StateKey,ControlStateValue> = Dictionary <StateKey,ControlStateValue>()
private var butonsTitleForStateDictionary:Dictionary <String,String> = Dictionary<String,String>()
private var butonsTitleFontForStateDictionary:Dictionary <String,UIFont> = Dictionary<String,UIFont>()
private var buttonsImageForStateDictionary:Dictionary <String,UIImage> = Dictionary<String,UIImage>()
private var buttonsBackgroundImageForStateDictionary:Dictionary <String,UIImage> = Dictionary<String,UIImage>()
public init(){
private var buttonsImageInsetsForStateDictionary:Dictionary <String,UIEdgeInsets> = Dictionary<String,UIEdgeInsets>()
private var buttonsTitleInsetsForStateDictionary:Dictionary <String,UIOffset> = Dictionary<String,UIOffset>()
private var buttonsTitleColorsForStateDictionary:Dictionary <String,UIColor> = Dictionary<String,UIColor>()
func setInsetsFromAdaptiveButtonApperance(adaptiveButtonApperance:AdaptiveButtonAppearance){
self.buttonsImageInsetsForStateDictionary = adaptiveButtonApperance.buttonsImageInsetsForStateDictionary
self.buttonsTitleInsetsForStateDictionary = adaptiveButtonApperance.buttonsTitleInsetsForStateDictionary
}
public init (values:Dictionary<StateKey,ControlStateValue>) {
stateDictionary = values
public func setFontsFromAdaptiveButtonApperance(adaptiveButtonApperance:AdaptiveButtonAppearance){
self.butonsTitleFontForStateDictionary = adaptiveButtonApperance.butonsTitleFontForStateDictionary
}
public convenience init(states:Dictionary<StateKey,ControlStateValue>) {
self.init(values:states)
public func setAllCommonApperanceFrom(adaptiveButtonApperance:AdaptiveButtonAppearance){
self.setInsetsFromAdaptiveButtonApperance(adaptiveButtonApperance)
self.setFontsFromAdaptiveButtonApperance(adaptiveButtonApperance)
self.buttonsTitleColorsForStateDictionary = adaptiveButtonApperance.buttonsTitleColorsForStateDictionary
}
public func setObjectDictionary(dictionary:Dictionary <String,DictionaryObject>){
var controlStatesDictionary = Dictionary<StateKey,ControlStateValue>()
for (key,object ) in dictionary{
let appearanceDictionary = object as Dictionary <String,DictionaryObject>
let appearanceObject = ControlStateValue()
appearanceObject.setObjectDictionary(appearanceDictionary)
controlStatesDictionary.updateValue(appearanceObject, forKey: StateKey(rawValue: key)!)
}
stateDictionary = controlStatesDictionary
}
public func getObjectDictionary() -> Dictionary<String,DictionaryObject>{
public func setImageNamesForStatesImageExtesions(imageName :String ,imageExtensionsForState:Dictionary <String,String>){
var controlStatesDictionary = Dictionary<String,DictionaryObject>()
for (key,object ) in stateDictionary{
let appearance = object as ControlStateValue
let appearanceDictionary = appearance.getObjectDictionary()
controlStatesDictionary.updateValue(appearanceDictionary, forKey: key.rawValue)
self.setButtonImage(UIImage(named: imageName), state: kDefaultAdaptiveState)
for (state,imageExtension) in imageExtensionsForState {
self.setButtonImage(UIImage(named: imageName+imageExtension), state: state)
}
return controlStatesDictionary
}
public func setButonTitle(title:NSString, state:String){
println(title)
println(state)
butonsTitleForStateDictionary.updateValue(title, forKey:state)
}
public func getButonTitleForState(state:NSString)->String!{
if let title = butonsTitleForStateDictionary[state] {
return title
}else{
if let title = butonsTitleForStateDictionary[kDefaultAdaptiveState] {
return title
}else{
return kNotTitle
}
}
}
public func setButonTitleFontForState(font:UIFont, state:String){
butonsTitleFontForStateDictionary.updateValue(font, forKey:state)
}
public func getButonTitleFontForState(state:NSString)->UIFont{
var font:UIFont? = butonsTitleFontForStateDictionary[state]
if let font = butonsTitleFontForStateDictionary[state] {
return font
}else{
if let font = butonsTitleFontForStateDictionary[kDefaultAdaptiveState] {
return font
}else{
return defaultFont
}
}
}
public func setButtonImage(image:UIImage, state:String){
buttonsImageForStateDictionary.updateValue(image, forKey:state)
print("set State \(state)")
}
public func getButonImageForState(state:NSString)->UIImage!{
print("get State \(state)")
if let image = buttonsImageForStateDictionary[state] {
return image
}else{
return buttonsImageForStateDictionary[kDefaultAdaptiveState]
}
}
public func setBackgroundButonImage(image:UIImage, state:String){
buttonsImageForStateDictionary.updateValue(image, forKey:state)
}
public func getBackgroundImageForState(state:NSString)->UIImage?{
if let image = buttonsBackgroundImageForStateDictionary[state] {
return image
}else{
return buttonsBackgroundImageForStateDictionary[kDefaultAdaptiveState]
}
}
public func setImageInsets(insets:UIEdgeInsets, state:String){
buttonsImageInsetsForStateDictionary.updateValue(insets, forKey:state)
}
public func getImageInsetsForState(state:NSString)->UIEdgeInsets!{
if let insets = buttonsImageInsetsForStateDictionary[state] {
return buttonsImageInsetsForStateDictionary[state]!
}else{
return buttonsImageInsetsForStateDictionary[kDefaultAdaptiveState]
}
}
public func setTitleOffset(insets:UIOffset, state:String){
buttonsTitleInsetsForStateDictionary.updateValue(insets, forKey:state)
}
public func getTitleOffsetForState(state:NSString)->UIOffset!{
var offset:UIOffset? = buttonsTitleInsetsForStateDictionary[state]
if(offset == nil){
offset = buttonsTitleInsetsForStateDictionary[kDefaultAdaptiveState]?
}
return offset!
}
public func setTitleColor(color:UIColor, state:String){
buttonsTitleColorsForStateDictionary.updateValue(color, forKey:state)
}
public func getTitleColorForState(state:NSString)->UIColor!{
var offset:UIColor? = buttonsTitleColorsForStateDictionary[state]
if(offset == nil){
offset = buttonsTitleColorsForStateDictionary[kDefaultAdaptiveState]?
}
return offset!
}
}
@@ -8,10 +8,21 @@
import UIKit
public let countDaysToSmallTextState = 14
public let countDaysToImageState = 30
public let defaultInsets = UIEdgeInsetsMake(0, 0,0, 0)
public let defaultSmallTitleModeFont = UIFont(name: "Helvetica", size: 10.0)
public let defaultSmallTitleModeImageInsets = UIEdgeInsetsMake(0, 0, 0, 0)
public let defaultImageModeInsets = UIEdgeInsetsMake(6, 0, -6, 0)
public let defaultSmallTitleModeOffset = UIOffsetMake(0, 20)
public let defaultOffset = UIOffsetMake(0, 00)
public let tabColor = UIColor(red: 169/255, green: 79/255, blue: 152/255, alpha: 1.0)
@objc public protocol AdaptiveApperanceProtocol {
func setFontToAdaptiveButton(font: UIFont , controlState:UIControlState)
//optional func setFontToAdaptiveButton(font: UIFont)
optional func setFontToAdaptiveButton(font: UIFont)
optional func setTitleToAdaptiveButton(text: NSString)
optional func setImageToAdaptiveButton(image: UIImage?)
optional func setHighlightedToAdaptiveButton(image: UIImage?)
@@ -19,68 +30,69 @@ import UIKit
optional func setSelectedImageToAdaptiveButton(image: UIImage?)
optional func setImageInsetsToAdaptiveButton(insets: UIEdgeInsets)
optional func setTitleOffsetToAdaptiveButton(offset: UIOffset)
//optional func setTitleColorToAdaptiveButton(titleColor: UIColor)
optional func setTitleColorToAdaptiveButton(color: UIColor, controlState:UIControlState)
optional func setTitleColorToAdaptiveButton(titleColor: UIColor)
}
public let selected = "Selected"
public let highlighted = "Higlihted"
public class AdaptiveButtonsStateManager <AdaptiveStateClass: AdaptiveState> {
public class AdaptiveButtonsStateManager: NSObject {
public class func setupButtonsAppearanceFromState(adaptiveState:AdaptiveStateClass,buttonsAray:[AdaptiveApperanceProtocol],buttonsAppearances:[AdaptiveButtonAppearance]){
public convenience init (state:AdaptiveState,buttonsAray:[AdaptiveApperanceProtocol],buttonsAppearance:[AdaptiveButtonAppearance]){
self.init()
self.setButtonsState(state, buttonsAray: buttonsAray, buttonsAppearance: buttonsAppearance)
}
public func setButtonsState(state:AdaptiveState,buttonsAray:[AdaptiveApperanceProtocol],buttonsAppearance:[AdaptiveButtonAppearance]){
var state = adaptiveState.currentItemState
var countElements = buttonsAray.count > buttonsAppearances.count ? buttonsAppearances.count : buttonsAray.count
var state:String = state.currentItemState!
var countElements = buttonsAray.count > buttonsAppearance.count ? buttonsAppearance.count : buttonsAray.count
for var index = 0; index < countElements; ++index {
println("index is \(index)")
println("buttons count array is \(buttonsAray.count)")
var button :AdaptiveApperanceProtocol = buttonsAray[index]
var buttonApperance = buttonsAppearances[index]
if let controlStateValue = buttonApperance.stateDictionary[state!] {
let normalStateAppearenceObject = controlStateValue.controlStates[UIControlState.Normal.rawValue]
var buttonApperance = buttonsAppearance[index]
let title = buttonApperance.getButonTitleForState(state)
println("title: /(title)")
println(NSString(format:"title %@",title))
button.setTitleToAdaptiveButton!(title)
if let title = normalStateAppearenceObject?.title {
button.setTitleToAdaptiveButton?(title)
}
button.setFontToAdaptiveButton!(buttonApperance.getButonTitleFontForState(state))
if let image = buttonApperance.getButonImageForState(state) {
button.setImageToAdaptiveButton?(image)
}else{
if let imageName = normalStateAppearenceObject?.imageName?{
if let image = UIImage(named: imageName) {
button.setImageToAdaptiveButton?(image)
}
}
if let selectedImage = buttonApperance.getButonImageForState(state+selected) {
button.setSelectedImageToAdaptiveButton?(selectedImage)
}
if let highlightedImage = buttonApperance.getButonImageForState(state+highlighted) {
button.setHighlightedToAdaptiveButton?(highlightedImage)
}
if let backgroundImage = normalStateAppearenceObject?.backgroundImage {
if let backgroundImage = buttonApperance.getButonImageForState(state) {
button.setBackgroundImageToAdaptiveButton?(backgroundImage)
}
if let imageInset = normalStateAppearenceObject?.imageInsets{
if let imageInset = buttonApperance.getImageInsetsForState(state) {
button.setImageInsetsToAdaptiveButton?(imageInset)
}
if let titleOffset = normalStateAppearenceObject?.titleOffset {
if let titleOffset = buttonApperance.getTitleOffsetForState(state) {
button.setTitleOffsetToAdaptiveButton?(titleOffset)
}
for (key, controlStateValue) in controlStateValue.controlStates{
if let titleFont = controlStateValue.font{
button.setFontToAdaptiveButton(titleFont , controlState:UIControlState(key))
}
if let titleColor = controlStateValue.titleColor{
button.setTitleColorToAdaptiveButton?(titleColor, controlState:UIControlState(key) )
}
}
if let titleColor = buttonApperance.getTitleColorForState(state) {
button.setTitleColorToAdaptiveButton?(titleColor)
}
}
@@ -8,18 +8,23 @@
import UIKit
public let kSmallTitleAdaptiveState = "kSmallTitleAdaptiveState"
public let kImageAdaptiveState = "kImageAdaptiveState"
public let kSmallTitleAdaptiveState = "kImageAdaptiveState"
public let kImageAdaptiveState = "kNormalImageAdaptiveState"
public class AdaptiveDateState: AdaptiveState {
public override init(){
super.init()
super.addNewCustomAdaptiveStates([kSmallTitleAdaptiveState,kImageAdaptiveState])
}
public convenience init(installDate:NSDate, currentDate:NSDate,countDaysToSmallTextState:Int,countDaysToImageState:Int) {
self.init()
var remainsDays = self.daysBetweenDates(installDate,currentDate: currentDate)
self.currentItemState = self.stateRemainDays(remainsDays,countDaysToSmallTextState:countDaysToSmallTextState,countDaysToImageState:countDaysToImageState)
print(currentItemState)
}
@@ -34,19 +39,16 @@ public class AdaptiveDateState: AdaptiveState {
return components.day+1;
}
func stateRemainDays (remainDays:Int,countDaysToSmallTextState:Int,countDaysToImageState:Int)->StateType{
var mode:StateType = .DefaultAdaptiveState
func stateRemainDays (remainDays:Int,countDaysToSmallTextState:Int,countDaysToImageState:Int)->String{
var mode:String = kDefaultAdaptiveState
print(" DAYS \(remainDays) ")
if remainDays > countDaysToSmallTextState && remainDays < countDaysToImageState{
mode = .SmallTitleAdaptiveState
mode = kSmallTitleAdaptiveState
}else if remainDays > countDaysToImageState {
mode = .ImageAdaptiveState
mode = kImageAdaptiveState
}
print(mode)
return mode
}
}
@@ -5,37 +5,35 @@
// Created by Arcilite on 04.10.14.
// Copyright (c) 2014 Ramotion. All rights reserved.
//
public let countDaysForSmaltextState = 3
public let countDaysForImageModeState = 7
import UIKit
typealias StateType = AdaptiveStateEnum
public class AdaptiveLaunchesState : AdaptiveState {
typealias StateType = AdaptiveStateEnum
override init(){
public override init(){
super.init()
super.addNewCustomAdaptiveStates([kSmallTitleAdaptiveState,kImageAdaptiveState])
}
public convenience init(curentCountLaunches:Int,countLaunchesToSmallTextState:Int,countLaunchesToImageState:Int){
public convenience init(curentCountLaunches:Int,countLaunchesToSmallTextState:Int,countLaunchesToImageState:Int) {
self.init()
self.currentItemState = stateRemainDays(curentCountLaunches,countLaunchesToSmallTextState: countLaunchesToSmallTextState,countLaunchesToImageState: countLaunchesToImageState);
//print(currentItemState)
}
internal func stateRemainDays (curentCountLaunches:Int,countLaunchesToSmallTextState:Int,countLaunchesToImageState:Int)->StateType{
var mode:StateType = .DefaultAdaptiveState
internal func stateRemainDays (curentCountLaunches:Int,countLaunchesToSmallTextState:Int,countLaunchesToImageState:Int)->String{
var mode:String = kDefaultAdaptiveState
if curentCountLaunches > countLaunchesToSmallTextState && curentCountLaunches < countLaunchesToImageState{
mode = .SmallTitleAdaptiveState
mode = kSmallTitleAdaptiveState
}else if curentCountLaunches > countLaunchesToImageState {
mode = .ImageAdaptiveState
mode = kImageAdaptiveState
}
return mode;
@@ -9,25 +9,30 @@
import UIKit
public let kDefaultAdaptiveState:String = "kDefaultAdaptiveState"
public let kDefaultAdaptiveState:String = "DefaultAdaptiveState"
public enum AdaptiveStateEnum:String{
case DefaultAdaptiveState = "kDefaultAdaptiveState"
case SmallTitleAdaptiveState = "kSmallTitleAdaptiveState"
case ImageAdaptiveState = "kImageAdaptiveState"
}
public typealias StateKey = AdaptiveStateEnum
public class AdaptiveState: NSObject {
var currentItemState:NSString?
public class AdaptiveState {
var buttonStates:[String] = [String]()
public typealias StateType = AdaptiveStateEnum
var currentItemState:StateType?
init(){
public override init(){
super.init()
self.currentItemState = kDefaultAdaptiveState
self.addNewCustomAdaptiveStates([kDefaultAdaptiveState])
}
internal func addNewCustomAdaptiveStates(customAdaptiveStates:Array<String>){
self.buttonStates+customAdaptiveStates
}
}
@@ -1,17 +0,0 @@
//
// AppearanceSerializationProtocol.swift
// AdaptiveController
//
// Created by Arcilite on 22.10.14.
// Copyright (c) 2014 Ramotion. All rights reserved.
//
import Foundation
protocol AppearanceSerializationProtocol {
typealias DictionaryObject
func getObjectDictionary() -> Dictionary<String,DictionaryObject>
func setObjectDictionary(dictionary:Dictionary<String,DictionaryObject>)
}
@@ -1,51 +0,0 @@
//
// AppearenceSettingManager.swift
// AdaptiveController
//
// Created by Arcilite on 13.11.14.
// Copyright (c) 2014 Ramotion. All rights reserved.
//
import Foundation
import UIKit
public class AppearenceSettingManager{
private var defaultAppearencesStyles:Dictionary<StateKey,ControlStateValue>
public init(){
defaultAppearencesStyles = Dictionary<StateKey,ControlStateValue>()
}
public init(stylesAppearances:Dictionary<StateKey,ControlStateValue>){
defaultAppearencesStyles = stylesAppearances
}
public func defaultStyleSettingsForNormalState(state:StateKey, titleOffset:UIOffset, imageInsets:UIEdgeInsets, titleColor:UIColor, font:UIFont, backgroundColor:UIColor ){
var controlDefaultStyleStateAppearence = ControlStateAppearance()
controlDefaultStyleStateAppearence.titleColor = titleColor
controlDefaultStyleStateAppearence.imageInsets = imageInsets
controlDefaultStyleStateAppearence.font = font
controlDefaultStyleStateAppearence.backgroundColor = backgroundColor
controlDefaultStyleStateAppearence.titleOffset = titleOffset
let controlStatesValues = [UIControlState.Normal.rawValue:controlDefaultStyleStateAppearence]
let controlStateValue = ControlStateValue(values: controlStatesValues)
defaultAppearencesStyles.updateValue(controlStateValue,forKey:state)
}
public func defaultStyleValuesForNormalState(state:StateKey, title:String, imageName:String) -> ControlStateValue {
var defaultStateValue = defaultAppearencesStyles[state] as ControlStateValue?
var normalDefaultAppearance = defaultStateValue?.controlStates[UIControlState.Normal.rawValue]
var controlSmallTitleStyleStateAppearence = ControlStateAppearance(appearanceStyle:normalDefaultAppearance)
controlSmallTitleStyleStateAppearence.imageName = imageName
controlSmallTitleStyleStateAppearence.title = title
let controSmallTitleStatesValues = [UIControlState.Normal.rawValue:controlSmallTitleStyleStateAppearence]
let controlSmallTitleStateValue = ControlStateValue(values: controSmallTitleStatesValues)
return controlSmallTitleStateValue
}
}
@@ -1,25 +0,0 @@
//
// Constants.swift
// AdaptiveController
//
// Created by Arcilite on 10.11.14.
// Copyright (c) 2014 Ramotion. All rights reserved.
//
import Foundation
import UIKit
//Default apearence settings
public let countDaysForSmaltextState = 3
public let countDaysForImageModeState = 7
public let countDaysToSmallTextState = 14
public let countDaysToImageState = 30
public let defaultInsets = UIEdgeInsetsMake(0, 0,0, 0)
public let defaultSmallTitleModeFont = UIFont(name: "Helvetica", size: 10.0)
public let defaultSmallTitleModeImageInsets = UIEdgeInsetsMake(0, 0, 0, 0)
public let defaultImageModeInsets = UIEdgeInsetsMake(6, 0, -6, 0)
public let defaultSmallTitleModeOffset = UIOffsetMake(0, 20)
public let defaultOffset = UIOffsetMake(0, 00)
public let tabColor = UIColor(red: 169/255, green: 79/255, blue: 152/255, alpha: 1.0)
public let defaultFont = UIFont(name: "Helvetica", size: 14.0)
@@ -1,263 +0,0 @@
//
// ControlStateAppearance.swift
// AdaptiveController
//
// Created by Arcilite on 22.10.14.
// Copyright (c) 2014 Ramotion. All rights reserved.
//
import UIKit
let titleKey = "title"
let fontKey = "font"
let imageNameKey = "imageName"
let backgroundImageNameKey = "backgroundImageName"
let titleOffsetKey = "titleOffset"
let imageInsetsKey = "imageInsets"
let colorKey = "color"
let backgroundColorKey = "backgroundColor"
let horizontalKey = "horizontal"
let verticalKey = "vertical"
let heightKey = "height"
let widthKey = "width"
let leftKey = "left"
let topKey = "top"
let rightKey = "right"
let bottomKey = "bottom"
let fontNameKey = "fontName"
let fontSizeKey = "fontSize"
let redColor = "red"
let greenColor = "green"
let blueColor = "blue"
let alphaColor = "alpha"
public class ControlStateAppearance: AppearanceSerializationProtocol{
typealias DictionaryObject = AnyObject
typealias StateObject = AnyObject
public var title: String?
public var font: UIFont?
public var imageName: String?
public var image: UIImage?
public var backgroundImageName:String?
public var backgroundImage: UIImage?
public var titleOffset:UIOffset?
public var imageInsets:UIEdgeInsets?
public var titleColor:UIColor?
public var backgroundColor:UIColor?
public var enabled:Bool?
public init(){
title = ""
//font = defaultFont
// titleOffset = defaultOffset
//imageInsets = defaultImageModeInsets
titleColor = UIColor.whiteColor()
backgroundColor = UIColor.clearColor()
}
public convenience init(appearanceFullStyle:ControlStateAppearance?){
self.init()
font = appearanceFullStyle?.font
titleOffset = appearanceFullStyle?.titleOffset
imageInsets = appearanceFullStyle?.imageInsets
titleColor = appearanceFullStyle?.titleColor
backgroundColor = appearanceFullStyle?.backgroundColor
imageName = appearanceFullStyle?.imageName
backgroundImageName = appearanceFullStyle?.backgroundImageName
image = appearanceFullStyle?.image
backgroundImage = appearanceFullStyle?.backgroundImage
}
public convenience init(appearanceStyle:ControlStateAppearance?){
self.init()
font = appearanceStyle?.font
titleOffset = appearanceStyle?.titleOffset
imageInsets = appearanceStyle?.imageInsets
titleColor = appearanceStyle?.titleColor
backgroundColor = appearanceStyle?.backgroundColor
title = appearanceStyle?.title
}
func colorToDctionary(color:UIColor) -> Dictionary<String,AnyObject>{
var components = CGColorGetComponents(color.CGColor)
var colorDictionary = Dictionary<String,AnyObject>()
if CGColorGetNumberOfComponents(color.CGColor) == 2{
colorDictionary[redColor] = components[0]
colorDictionary[greenColor] = components[0]
colorDictionary[blueColor] = components[0]
colorDictionary[alphaColor] = components[1]
}else{
colorDictionary[redColor] = components[0]
colorDictionary[greenColor] = components[1]
colorDictionary[blueColor] = components[2]
colorDictionary[alphaColor] = components[3]
}
return colorDictionary
}
func dictionaryToColor(colorDictionary: Dictionary<String,CGFloat>?) -> UIColor{
if let colorValueDictioanary = colorDictionary {
var red:CGFloat = 0
if let redValue = colorValueDictioanary [redColor]{
red = redValue
}
var green:CGFloat = 0
if let greenValue = colorValueDictioanary [greenColor]{
green = greenValue
}
var blue:CGFloat = 0
if let blueValue = colorValueDictioanary [blueColor]{
blue = blueValue
}
var alpha:CGFloat = 0
if let alphaValue = colorValueDictioanary [alphaColor]{
alpha = alphaValue
}
return UIColor(red: red, green: green, blue: blue, alpha: alpha)
}else{
return UIColor.clearColor()
}
}
func dictionaryToInsets(insetsDictionary: Dictionary<String,CGFloat>?) -> UIEdgeInsets!{
if let insetsDictionary = insetsDictionary{
var left:CGFloat = 0
if let leftDictioanaryValue = insetsDictionary [leftKey]{
left = leftDictioanaryValue
}
var top:CGFloat = 0
if let topDictioanaryValue = insetsDictionary [topKey]{
top = topDictioanaryValue
}
var right:CGFloat = 0
if let rightDictionary = insetsDictionary[rightKey]{
right = rightDictionary
}
var bottom:CGFloat = 0
if let bottomDictionaryValue = insetsDictionary[bottomKey]{
bottom = bottomDictionaryValue
}
return UIEdgeInsetsMake(top, left, bottom, right)
}else{
return UIEdgeInsetsZero
}
}
func dictionaryToOffset(offsetDictionary: Dictionary<String,CGFloat>?) -> UIOffset{
var horizontal:CGFloat = 0
if let horizontalFromDictionary = offsetDictionary![horizontalKey]{
horizontal = horizontalFromDictionary
}
var vertical:CGFloat = 0
if let verticalFromDictionary = offsetDictionary![verticalKey]{
vertical = verticalFromDictionary
}
return UIOffsetMake(horizontal, vertical)
}
func dictionaryToFont(fontDictionary: Dictionary<String,AnyObject>) -> UIFont{
var fontName:String = fontDictionary [fontNameKey]! as String
var fontSize:CGFloat = fontDictionary [fontSizeKey]! as CGFloat
return UIFont( name: fontName, size:fontSize )!
}
func setObjectDictionary(dictionary:Dictionary<String,DictionaryObject>){
title = dictionary[titleKey] as? String
font = dictionaryToFont(dictionary[fontKey] as Dictionary <String, AnyObject>)
titleOffset = dictionaryToOffset(dictionary[titleOffsetKey] as? Dictionary <String, CGFloat>)
imageInsets = dictionaryToInsets(dictionary[imageInsetsKey] as? Dictionary <String, CGFloat>)
titleColor = dictionaryToColor(dictionary[colorKey]! as? Dictionary <String, CGFloat>)
backgroundColor = dictionaryToColor(dictionary[backgroundColorKey]! as? Dictionary <String, CGFloat>)
if let imageName = dictionary[imageNameKey] as? String{
image = UIImage(named:imageName)
self.imageName = imageName
}
if let backgroundImageName = dictionary[backgroundImageNameKey] as? String{
backgroundImage = UIImage(named:backgroundImageName)
}
}
func getObjectDictionary() -> Dictionary<String,DictionaryObject>{
var controlStateDictionary = Dictionary<String,AnyObject>()
if title != nil {
controlStateDictionary[titleKey] = title!
}else{
controlStateDictionary[titleKey] = ""
}
var fontDictionary = Dictionary<String,AnyObject>()
fontDictionary[fontNameKey] = font?.fontName
fontDictionary[fontSizeKey] = font?.pointSize
controlStateDictionary[fontKey] = fontDictionary
var offsetDictionary = Dictionary<String,AnyObject>()
offsetDictionary[horizontalKey] = titleOffset?.horizontal
offsetDictionary[verticalKey] = titleOffset?.vertical
controlStateDictionary[titleOffsetKey] = offsetDictionary
var insetsDictionary = Dictionary<String,AnyObject>()
insetsDictionary[bottomKey] = imageInsets?.bottom
insetsDictionary[topKey] = imageInsets?.top
insetsDictionary[leftKey] = imageInsets?.left
insetsDictionary[rightKey] = imageInsets?.right
controlStateDictionary[imageInsetsKey] = insetsDictionary
if titleColor != nil{
controlStateDictionary[colorKey] = colorToDctionary(titleColor!)
}else{
controlStateDictionary[colorKey] = UIColor(red: 0, green: 0, blue: 0, alpha: 0)
}
controlStateDictionary[backgroundColorKey] = colorToDctionary(backgroundColor!)
controlStateDictionary[imageNameKey] = imageName
controlStateDictionary[backgroundImageNameKey] = backgroundImageName
return controlStateDictionary
}
}
@@ -8,11 +8,12 @@
import Foundation
protocol ControlStateProtocol:AppearanceSerializationProtocol {
protocol ControlStateProtocol {
typealias StateObject
typealias ControlStateType:Hashable
typealias StateEnum
var controlStates: Dictionary <ControlStateType, StateObject>{get }
var normalState: StateEnum?{get set}
var selectedState: StateEnum?{get set}
var highlightedState: StateEnum?{get set}
}
@@ -8,95 +8,28 @@
import UIKit
extension UIControlState {
init(string:StringLiteralType){
switch(string){
case "UIControlStateNormal" :
self = UIControlState.Normal
case "UIControlStateHighlighted":
self = UIControlState.Highlighted
case"UIControlStateHighlighted":
self = UIControlState.Selected
default:
self = UIControlState.Disabled
}
}
func getStringKey()->String{
switch(self){
case UIControlState.Normal: return "UIControlStateNormal"
case UIControlState.Highlighted: return "UIControlStateHighlighted"
case UIControlState.Selected: return "UIControlStateSelected"
default: return "None"
}
}
public enum ControlStateEnum {
case ControlStateFont(UIFont), ControlStateImage(UIImage),ControlStateTitle(String),ControlStateInsets(UIEdgeInsets),ControlStateColor(UIColor),UIControlState(UIOffset)
}
public class ControlStateValue:ControlStateProtocol{
public typealias ControlStateType = UInt
public typealias StateObject = ControlStateAppearance
public typealias DictionaryObject = Dictionary <String,AnyObject>
public var controlStates :Dictionary <ControlStateType,ControlStateAppearance>
public init(){
self.controlStates = Dictionary<ControlStateType,ControlStateAppearance>()
}
public convenience init(values:Dictionary<ControlStateType,ControlStateAppearance>) {
self.init()
controlStates = values
}
public convenience init(styleValueStates:ControlStateValue) {
self.init()
for (state, object) in styleValueStates.controlStates {
self.controlStates.updateValue( ControlStateAppearance(appearanceStyle: object), forKey: state)
}
}
public func getObjectDictionary() -> Dictionary<String,DictionaryObject>{
var controlStatesDictionary = Dictionary<String,DictionaryObject>()
for (key,object ) in controlStates{
var appearance = object as ControlStateAppearance
var appearanceDictionary = appearance.getObjectDictionary()
let controlKey = UIControlState(key).getStringKey()
controlStatesDictionary.updateValue(appearanceDictionary, forKey:controlKey )
}
return controlStatesDictionary
}
public func setObjectDictionary(dictionary:Dictionary <String,DictionaryObject>){
var controlStatesDictionary = Dictionary<ControlStateType,ControlStateAppearance>()
for (key,object ) in dictionary{
var appearanceDictionary = object as Dictionary <String,AnyObject>
var appearanceObject = ControlStateAppearance()
appearanceObject.setObjectDictionary(appearanceDictionary)
controlStatesDictionary.updateValue(appearanceObject, forKey: UIControlState(string:key).rawValue)
}
self.controlStates = controlStatesDictionary
}
public typealias StateEnum = ControlStateEnum
public var normalState: StateEnum?
public var selectedState: StateEnum?
public var highlightedState: StateEnum?
public convenience init(valueForNormalState:ControlStateEnum?) {
self.init()
self.normalState = valueForNormalState
self.selectedState = valueForNormalState
self.highlightedState = valueForNormalState
}
}
@@ -1,59 +0,0 @@
//
// DictioanarySeriliazator.swift
// AdaptiveController
//
// Created by Arcilite on 04.11.14.
// Copyright (c) 2014 Ramotion. All rights reserved.
//
import UIKit
public class DictioanarySerializer: NSObject {
public typealias DictionaryObject = Dictionary <String,AnyObject>
public func buttonApperancesToArrayDictionary(buttonApearances:[AdaptiveButtonAppearance]) -> Array<Dictionary<String, AnyObject>>{
var buttonsApearancesDictionaryArray = Array<Dictionary<String, AnyObject>>()
for appeareance in buttonApearances{
buttonsApearancesDictionaryArray.append(appeareance.getObjectDictionary())
}
return buttonsApearancesDictionaryArray
}
public func saveStateDictionary(buttonApearances:[AdaptiveButtonAppearance],filePath:String){
var dataArray = buttonApperancesToArrayDictionary(buttonApearances)
var data : NSArray = dataArray as NSArray
data.writeToFile(filePath, atomically: true)
}
public func dictionaryAppearancesToArrayApperances(buttonApearancesDictionary:Array<Dictionary<String, DictionaryObject>>) -> [AdaptiveButtonAppearance]{
var buttonsApearancesDictionaryArray = [AdaptiveButtonAppearance]()
for appeareanceDictionary in buttonApearancesDictionary{
var appearance = AdaptiveButtonAppearance()
appearance.setObjectDictionary(appeareanceDictionary)
buttonsApearancesDictionaryArray.append(appearance)
}
return buttonsApearancesDictionaryArray
}
public func parseFromPlistToButtonAppearances(filePath:String)->[AdaptiveButtonAppearance] {
if countElements(filePath) > 0 {
// The file saved previously
// Check for existence of the file
if NSFileManager.defaultManager().fileExistsAtPath(filePath){
let resultArray = NSArray(contentsOfFile: filePath)
var appearancesDictionaryArray = resultArray as Array<Dictionary<String, DictionaryObject>>
return dictionaryAppearancesToArrayApperances(appearancesDictionaryArray)
}
}
return [AdaptiveButtonAppearance]()
}
}
@@ -1,72 +0,0 @@
//
// AdaptiveButtonAppearanceTest.swift
// AdaptiveController
//
// Created by Arcilite on 03.11.14.
// Copyright (c) 2014 Ramotion. All rights reserved.
//
import XCTest
import UIKit
import AdaptiveController
class AdaptiveButtonAppearanceTest: XCTestCase {
func testAppearanceSetup() {
var settingsManager = AppearenceSettingManager()
//
settingsManager.defaultStyleSettingsForNormalState(AdaptiveStateEnum.DefaultAdaptiveState,titleOffset:defaultOffset, imageInsets:defaultInsets, titleColor:UIColor(red: 1, green: 1, blue: 1, alpha: 1), font:defaultFont!, backgroundColor:UIColor.clearColor())
settingsManager.defaultStyleSettingsForNormalState(AdaptiveStateEnum.SmallTitleAdaptiveState,titleOffset:defaultOffset, imageInsets:defaultSmallTitleModeImageInsets, titleColor:UIColor.whiteColor(), font:defaultSmallTitleModeFont!, backgroundColor:UIColor.clearColor())
settingsManager.defaultStyleSettingsForNormalState(AdaptiveStateEnum.ImageAdaptiveState,titleOffset:defaultOffset, imageInsets:defaultImageModeInsets, titleColor:UIColor.whiteColor(), font:defaultFont!, backgroundColor:UIColor.clearColor())
var watchControlDefaultStateValue = settingsManager.defaultStyleValuesForNormalState(AdaptiveStateEnum.DefaultAdaptiveState, title:"watch", imageName:"watch")
var watchControlSmallTitleStateValue = settingsManager.defaultStyleValuesForNormalState(AdaptiveStateEnum.SmallTitleAdaptiveState, title:"watch", imageName:"watch_smalltitle")
var watchControlImageStateValue = settingsManager.defaultStyleValuesForNormalState(AdaptiveStateEnum.ImageAdaptiveState, title:"", imageName:"watch_bigimage")
let watchAppearanceStates = [AdaptiveStateEnum.DefaultAdaptiveState:watchControlDefaultStateValue,
AdaptiveStateEnum.SmallTitleAdaptiveState:watchControlSmallTitleStateValue,
AdaptiveStateEnum.ImageAdaptiveState:watchControlImageStateValue]
var watchAppearance = AdaptiveButtonAppearance(states:watchAppearanceStates)
var appearanceDictionary = watchAppearance.getObjectDictionary()
var testAppearance = AdaptiveButtonAppearance()
testAppearance.setObjectDictionary(appearanceDictionary)
if let controlStateValue = testAppearance.stateDictionary[AdaptiveStateEnum.DefaultAdaptiveState]{
if let normalStateAppearenceObject = controlStateValue.controlStates[UIControlState.Normal.rawValue]{
XCTAssert(normalStateAppearenceObject.titleColor == UIColor(red: 1, green: 1, blue: 1, alpha: 1), "Fail color")
XCTAssert(UIOffsetEqualToOffset(normalStateAppearenceObject.titleOffset!,defaultOffset), "Fail offset")
XCTAssert(UIEdgeInsetsEqualToEdgeInsets(defaultInsets, normalStateAppearenceObject.imageInsets!), "Fail insets")
}
}
}
}
@@ -46,7 +46,7 @@ class AdaptiveControllerTests: XCTestCase {
var arrayButtons = [tabBarItem]
AdaptiveButtonsStateManager.setupButtonsAppearanceFromState(adaptiveDateState,buttonsAray:arrayButtons ,buttonsAppearances: buttonsAppearances)
AdaptiveButtonsStateManager(state: adaptiveDateState,buttonsAray:arrayButtons ,buttonsAppearance: buttonsAppearances)
//assert
@@ -54,8 +54,8 @@ class AdaptiveControllerTests: XCTestCase {
XCTAssert(UIOffsetEqualToOffset(tabBarItem.offset!,defaultOffset), "Fail offset")
XCTAssert(UIEdgeInsetsEqualToEdgeInsets(defaultInsets, tabBarItem.insets!), "Fail insets")
let bundle = NSBundle(forClass: AdaptiveButtonAppearance.self)
// var image:MockUIImage = tabBarItem.image as MockUIImage
//XCTAssert(image.checkImageString!.isEqual("default Image"), "Fail image")
var image:MockUIImage = tabBarItem.image as MockUIImage
XCTAssert(image.checkImageString!.isEqual("default Image"), "Fail image")
XCTAssert(tabBarItem.text!.isEqualToString("watch"), "Fail text")
XCTAssert(tabBarItem.font!.isEqual(defaultFont), "Fail font")
}
@@ -67,7 +67,7 @@ class AdaptiveControllerTests: XCTestCase {
var adaptiveDateState = AdaptiveDateState(installDate: installDate,currentDate:currentDate,countDaysToSmallTextState:countDaysToSmallTextState,countDaysToImageState:countDaysToImageState)
// XCTAssert(!adaptiveDateState.isEqual(kSmallTitleAdaptiveState), "Fail SmallTitleState")
XCTAssert(!adaptiveDateState.isEqual(kSmallTitleAdaptiveState), "Fail SmallTitleState")
var buttonsAppearances = buttonsAppearancesGenerate()
var tabBarItem = TestTabBarItem()
@@ -75,14 +75,13 @@ class AdaptiveControllerTests: XCTestCase {
var arrayButtons = [tabBarItem]
// AdaptiveButtonsStateManager(state: adaptiveDateState,buttonsAray:arrayButtons ,buttonsAppearance: buttonsAppearances)
AdaptiveButtonsStateManager.setupButtonsAppearanceFromState(adaptiveDateState,buttonsAray:arrayButtons ,buttonsAppearances: buttonsAppearances)
AdaptiveButtonsStateManager(state: adaptiveDateState,buttonsAray:arrayButtons ,buttonsAppearance: buttonsAppearances)
XCTAssert(tabBarItem.color!.isEqual(UIColor.whiteColor()), "Fail color")
XCTAssert(UIOffsetEqualToOffset(tabBarItem.offset!,defaultOffset), "Fail offset")
XCTAssert(UIEdgeInsetsEqualToEdgeInsets(defaultInsets, tabBarItem.insets!), "Fail insets")
//var image:MockUIImage = tabBarItem.image as MockUIImage
//XCTAssert(image.checkImageString!.isEqual("smalltitle Image"), "Fail image")
var image:MockUIImage = tabBarItem.image as MockUIImage
XCTAssert(image.checkImageString!.isEqual("smalltitle Image"), "Fail image")
XCTAssert(tabBarItem.font!.isEqual(defaultSmallTitleModeFont), "Fail font")
}
@@ -94,7 +93,7 @@ class AdaptiveControllerTests: XCTestCase {
var adaptiveDateState = AdaptiveDateState(installDate: installDate,currentDate:currentDate,countDaysToSmallTextState:countDaysToSmallTextState,countDaysToImageState:countDaysToImageState)
//XCTAssert(!adaptiveDateState.isEqual(kImageAdaptiveState), "Fail ImageAdaptiveState")
XCTAssert(!adaptiveDateState.isEqual(kImageAdaptiveState), "Fail ImageAdaptiveState")
var buttonsAppearances = buttonsAppearancesGenerate()
var tabBarItem = TestTabBarItem()
@@ -102,14 +101,14 @@ class AdaptiveControllerTests: XCTestCase {
var arrayButtons = [tabBarItem]
// AdaptiveButtonsStateManager(state: adaptiveDateState,buttonsAray:arrayButtons ,buttonsAppearance: buttonsAppearances)
AdaptiveButtonsStateManager.setupButtonsAppearanceFromState(adaptiveDateState,buttonsAray:arrayButtons ,buttonsAppearances: buttonsAppearances)
AdaptiveButtonsStateManager(state: adaptiveDateState,buttonsAray:arrayButtons ,buttonsAppearance: buttonsAppearances)
XCTAssert(tabBarItem.color!.isEqual(UIColor.whiteColor()), "Fail color")
XCTAssert(UIOffsetEqualToOffset(tabBarItem.offset!,defaultOffset), "Fail offset")
XCTAssert(UIEdgeInsetsEqualToEdgeInsets(defaultImageModeInsets, tabBarItem.insets!), "Fail insets")
// var image:MockUIImage = tabBarItem.image as MockUIImage
// XCTAssert(image.checkImageString!.isEqual("big Image"), "Fail image")
var image:MockUIImage = tabBarItem.image as MockUIImage
XCTAssert(image.checkImageString!.isEqual("big Image"), "Fail image")
XCTAssert(tabBarItem.text!.isEqualToString(""), "Fail text")
XCTAssert(tabBarItem.font!.isEqual(defaultFont), "Fail font")
}
@@ -118,28 +117,48 @@ class AdaptiveControllerTests: XCTestCase {
func buttonsAppearancesGenerate() -> [AdaptiveButtonAppearance]{
var settingsManager = AppearenceSettingManager()
//
settingsManager.defaultStyleSettingsForNormalState(AdaptiveStateEnum.DefaultAdaptiveState,titleOffset:defaultOffset, imageInsets:defaultInsets, titleColor:UIColor.whiteColor(), font:defaultFont!, backgroundColor:UIColor.clearColor())
settingsManager.defaultStyleSettingsForNormalState(AdaptiveStateEnum.SmallTitleAdaptiveState,titleOffset:defaultOffset, imageInsets:defaultSmallTitleModeImageInsets, titleColor:UIColor.whiteColor(), font:defaultSmallTitleModeFont!, backgroundColor:UIColor.clearColor())
settingsManager.defaultStyleSettingsForNormalState(AdaptiveStateEnum.ImageAdaptiveState,titleOffset:defaultOffset, imageInsets:defaultImageModeInsets, titleColor:UIColor.whiteColor(), font:defaultFont!, backgroundColor:UIColor.clearColor())
var imageExtensionsForStates:Dictionary = [ kSmallTitleAdaptiveState:"_smalltitle",
kImageAdaptiveState:"_bigimage",
kSmallTitleAdaptiveState+selected :"_smalltitle",
kImageAdaptiveState+selected:"_bigimage" ]
var watchAppearance = AdaptiveButtonAppearance();
watchAppearance.setButonTitle("watch", state: kDefaultAdaptiveState)
watchAppearance.setButonTitle("watch2", state: kSmallTitleAdaptiveState)
watchAppearance.setButonTitle("", state: kImageAdaptiveState)
watchAppearance.setTitleColor(UIColor.whiteColor(), state: kDefaultAdaptiveState)
watchAppearance.setButonTitleFontForState(defaultFont, state: kDefaultAdaptiveState)
watchAppearance.setButonTitleFontForState(defaultSmallTitleModeFont, state: kSmallTitleAdaptiveState)
var watchControlDefaultStateValue = settingsManager.defaultStyleValuesForNormalState(AdaptiveStateEnum.DefaultAdaptiveState, title:"watch", imageName:"watch")
//watchAppearance.setImageNamesForStatesImageExtesions("watch", imageExtensionsForState:imageExtensionsForStates)
var watchControlSmallTitleStateValue = settingsManager.defaultStyleValuesForNormalState(AdaptiveStateEnum.SmallTitleAdaptiveState, title:"watch", imageName:"watch_smalltitle")
var watchControlImageStateValue = settingsManager.defaultStyleValuesForNormalState(AdaptiveStateEnum.ImageAdaptiveState, title:"", imageName:"watch_bigimage")
let mockImage = MockUIImage()
mockImage.checkImageString = "default Image"
let watchAppearanceStates = [AdaptiveStateEnum.DefaultAdaptiveState:watchControlDefaultStateValue,
AdaptiveStateEnum.SmallTitleAdaptiveState:watchControlSmallTitleStateValue,
AdaptiveStateEnum.ImageAdaptiveState:watchControlImageStateValue]
watchAppearance.setButtonImage(mockImage, state: kDefaultAdaptiveState)
let mockSmallTitleImage = MockUIImage()
mockSmallTitleImage.checkImageString = "smalltitle Image"
var watchAppearance = AdaptiveButtonAppearance(states:watchAppearanceStates)
watchAppearance.setButtonImage(mockSmallTitleImage, state: kSmallTitleAdaptiveState)
let mockBigImageStateImage = MockUIImage()
mockBigImageStateImage.checkImageString = "big Image"
watchAppearance.setButtonImage(mockBigImageStateImage, state: kImageAdaptiveState)
watchAppearance.setImageInsets(defaultInsets, state: kDefaultAdaptiveState);
watchAppearance.setImageInsets(defaultSmallTitleModeImageInsets, state: kSmallTitleAdaptiveState)
watchAppearance.setTitleOffset(defaultOffset, state: kDefaultAdaptiveState)
watchAppearance.setImageInsets(defaultImageModeInsets, state: kImageAdaptiveState);
return [watchAppearance]
@@ -20,9 +20,9 @@ class AdaptiveDateStateTest: XCTestCase {
super.setUp()
installDate = NSDate(dateString:"2014-07-7")
var currentDate = NSDate(dateString:"2014-07-8")
var currentDate = NSDate(dateString:"2014-07-7")
adaptiveDateState = AdaptiveDateState(installDate: installDate!,currentDate:currentDate,countDaysToSmallTextState:countDaysToSmallTextState,countDaysToImageState:countDaysToImageState)
adaptiveDateState = AdaptiveDateState(installDate: installDate!,currentDate:NSDate(),countDaysToSmallTextState:countDaysToSmallTextState,countDaysToImageState:countDaysToImageState)
// Put setup code here. This method is called before the invocation of each test method in the class.
}
@@ -34,16 +34,16 @@ class AdaptiveDateStateTest: XCTestCase {
func testDefaultState() {
// This is an example of a functional test case.
XCTAssert(adaptiveDateState?.currentItemState?.rawValue == AdaptiveStateEnum.DefaultAdaptiveState.rawValue, "Fail DefaultState")
XCTAssert(!adaptiveDateState!.isEqual(kDefaultAdaptiveState), "Fail DefaultState")
}
func testSmallTextState() {
// This is an example of a functional test case.
var currentDate = NSDate(dateString:"2014-07-21")
adaptiveDateState = AdaptiveDateState(installDate: installDate!,currentDate:currentDate,countDaysToSmallTextState:countDaysToSmallTextState,countDaysToImageState:countDaysToImageState)
adaptiveDateState = AdaptiveDateState(installDate: installDate!,currentDate:NSDate(),countDaysToSmallTextState:countDaysToSmallTextState,countDaysToImageState:countDaysToImageState)
XCTAssert(adaptiveDateState?.currentItemState?.rawValue == AdaptiveStateEnum.SmallTitleAdaptiveState.rawValue, "Fail SmallTitleState")
XCTAssert(!adaptiveDateState!.isEqual(kSmallTitleAdaptiveState), "Fail SmallTitleState")
}
func testImageState() {
@@ -52,7 +52,7 @@ class AdaptiveDateStateTest: XCTestCase {
adaptiveDateState = AdaptiveDateState(installDate: installDate!,currentDate:NSDate(),countDaysToSmallTextState:countDaysToSmallTextState,countDaysToImageState:countDaysToImageState)
XCTAssert(adaptiveDateState?.currentItemState?.rawValue == AdaptiveStateEnum.ImageAdaptiveState.rawValue, "Fail ImageAdaptiveState")
XCTAssert(!adaptiveDateState!.isEqual(kImageAdaptiveState), "Fail ImageAdaptiveState")
}
@@ -29,8 +29,7 @@ class AdaptiveLaunchesStateTest: XCTestCase {
adaptiveLaunchState = AdaptiveLaunchesState(curentCountLaunches:curentCountLaunches,countLaunchesToSmallTextState:countDaysForSmaltextState,countLaunchesToImageState:countDaysForImageModeState)
// This is an example of a functional test case.
// This is an example of a functional test case.
XCTAssert(adaptiveLaunchState?.currentItemState?.rawValue == AdaptiveStateEnum.DefaultAdaptiveState.rawValue, "Fail DefaultState")
XCTAssert(!adaptiveLaunchState!.isEqual(kDefaultAdaptiveState), "Fail DefaultState")
}
func testSmallTextState() {
@@ -39,17 +38,18 @@ class AdaptiveLaunchesStateTest: XCTestCase {
adaptiveLaunchState = AdaptiveLaunchesState(curentCountLaunches:curentCountLaunches,countLaunchesToSmallTextState:countDaysForSmaltextState,countLaunchesToImageState:countDaysForImageModeState)
XCTAssert(adaptiveLaunchState?.currentItemState?.rawValue == AdaptiveStateEnum.SmallTitleAdaptiveState.rawValue, "Fail SmaltitleState")
XCTAssert(!adaptiveLaunchState!.isEqual(kSmallTitleAdaptiveState), "Fail SmallTitleState")
}
func testImageState() {
// This is an example of a functional test case.
var curentCountLaunches = 10
var curentCountLaunches = 7
adaptiveLaunchState = AdaptiveLaunchesState(curentCountLaunches:curentCountLaunches,countLaunchesToSmallTextState:countDaysForSmaltextState,countLaunchesToImageState:countDaysForImageModeState)
XCTAssert(adaptiveLaunchState?.currentItemState?.rawValue == AdaptiveStateEnum.ImageAdaptiveState.rawValue, "Fail ImageAdaptiveState")
XCTAssert(!adaptiveLaunchState!.isEqual(kImageAdaptiveState), "Fail ImageAdaptiveState")
}
@@ -1,69 +0,0 @@
//
// ControlStateAppearanceTest.swift
// AdaptiveController
//
// Created by Arcilite on 01.11.14.
// Copyright (c) 2014 Ramotion. All rights reserved.
//
import UIKit
import XCTest
import AdaptiveController
//extension ControlStateAppearance{
//
// public func getObjectDictionary() -> Dictionary<String,AnyObject>{
// return getObjectDictionary()
// }
// public func setObjectDictionary(dictionary:Dictionary<String,AnyObject>){
// setObjectDictionary(dictionary)
// }
//}
class ControlStateAppearanceTest: XCTestCase {
override func setUp() {
super.setUp()
// Put setup code here. This method is called before the invocation of each test method in the class.
}
override func tearDown() {
// Put teardown code here. This method is called after the invocation of each test method in the class.
super.tearDown()
}
func testControlstateAppearance() {
var appearance = ControlStateAppearance();
appearance.font = UIFont(name: "Arial", size: 12)
appearance.title = "2"
appearance.imageInsets = UIEdgeInsetsMake(2, 2, 2, 2)
appearance.titleOffset = UIOffsetMake(2, 2)
appearance.titleColor = UIColor(red: 0, green: 0, blue: 0, alpha: 1)
appearance.backgroundColor = UIColor(red: 0, green: 7, blue: 0, alpha: 1)
var appearance1 = ControlStateAppearance();
appearance1.setObjectDictionary( appearance.getObjectDictionary())
XCTAssert(appearance.titleColor == appearance1.titleColor, "Fail color")
XCTAssert(appearance.backgroundColor == appearance1.backgroundColor, "Fail color")
XCTAssert(appearance1.titleColor == appearance.titleColor, "Fail color")
XCTAssert(UIOffsetEqualToOffset(appearance1.titleOffset!,appearance.titleOffset!), "Fail offset")
XCTAssert(UIEdgeInsetsEqualToEdgeInsets(appearance.imageInsets!, appearance1.imageInsets!), "Fail insets")
}
func testPerformanceExample() {
// This is an example of a performance test case.
self.measureBlock() {
// Put the code you want to measure the time of here.
}
}
}
@@ -1,88 +0,0 @@
//
// ControlStateValueTest.swift
// AdaptiveController
//
// Created by Arcilite on 28.10.14.
// Copyright (c) 2014 Ramotion. All rights reserved.
//
import UIKit
import XCTest
import AdaptiveController
class ControlStateValueTest: XCTestCase {
override func setUp() {
super.setUp()
// Put setup code here. This method is called before the invocation of each test method in the class.
}
override func tearDown() {
// Put teardown code here. This method is called after the invocation of each test method in the class.
super.tearDown()
}
func testControlStateAppearance() {
var appearance = ControlStateAppearance()
appearance.font = UIFont(name: "Arial", size: 12)
appearance.title = "2"
appearance.imageInsets = UIEdgeInsetsMake(2, 2, 2, 2)
appearance.titleOffset = UIOffsetMake(2, 2)
appearance.titleColor = UIColor(red: 0, green: 0, blue: 0, alpha: 1)
appearance.backgroundColor = UIColor(red: 0, green: 7, blue: 0, alpha: 1)
var value = ControlStateValue(values: [UIControlState.Normal.rawValue:appearance])
// value.setControlApearence(appearance,state:UIControlState.Normal)
var object:ControlStateAppearance = value.controlStates[UIControlState.Normal.rawValue]!
XCTAssert(object.title! == appearance.title , "Pass")
}
func testControlStateAppearanceSerialization() {
var appearance = ControlStateAppearance()
appearance.font = UIFont(name: "Arial", size: 12)
appearance.title = "2"
appearance.imageInsets = UIEdgeInsetsMake(2, 2, 2, 2)
appearance.titleOffset = UIOffsetMake(2, 2)
appearance.titleColor = UIColor(red: 0, green: 0, blue: 0, alpha: 1)
appearance.backgroundColor = UIColor(red: 0, green: 7, blue: 0, alpha: 1)
//
var value = ControlStateValue(values: [UIControlState.Normal.rawValue:appearance])
var object:ControlStateAppearance = value.controlStates[UIControlState.Normal.rawValue]!
XCTAssert(object.title! == appearance.title , "Pass")
var value1 = ControlStateValue()
value1.setObjectDictionary(value.getObjectDictionary())
var object1:ControlStateAppearance = value.controlStates[UIControlState.Normal.rawValue]!
XCTAssert(object1.title! == appearance.title , "Pass")
XCTAssert(appearance.titleColor == object1.titleColor, "Fail color")
XCTAssert(appearance.backgroundColor == object1.backgroundColor, "Fail color")
XCTAssert(appearance.titleColor == object1.titleColor, "Fail color")
XCTAssert(UIOffsetEqualToOffset(appearance.titleOffset!,object1.titleOffset!), "Fail offset")
XCTAssert(UIEdgeInsetsEqualToEdgeInsets(appearance.imageInsets!, object1.imageInsets!), "Fail insets")
}
func testPerformanceExample() {
// This is an example of a performance test case.
self.measureBlock() {
// Put the code you want to measure the time of here.
}
}
}
@@ -11,7 +11,7 @@ import UIKit
import AdaptiveController
import XCTest
public class TestTabBarItem: AdaptiveApperanceProtocol {
class TestTabBarItem: AdaptiveApperanceProtocol {
var font:UIFont?
var text:NSString?
@@ -30,13 +30,13 @@ public class TestTabBarItem: AdaptiveApperanceProtocol {
self.font = font
}
public func setTitleToAdaptiveButton(text: NSString){
func setTitleToAdaptiveButton(text: NSString){
self.text = text;
}
public func setImageToAdaptiveButton(image: UIImage?){
func setImageToAdaptiveButton(image: UIImage?){
// XCTAssertNotNil(image)
self.image = image
@@ -47,12 +47,12 @@ public class TestTabBarItem: AdaptiveApperanceProtocol {
}
public func setImageInsetsToAdaptiveButton(insets: UIEdgeInsets){
func setImageInsetsToAdaptiveButton(insets: UIEdgeInsets){
self.insets = insets
}
public func setTitleOffsetToAdaptiveButton(offset: UIOffset){
func setTitleOffsetToAdaptiveButton(offset: UIOffset){
self.offset = offset;
@@ -64,14 +64,5 @@ public class TestTabBarItem: AdaptiveApperanceProtocol {
}
public func setFontToAdaptiveButton(font: UIFont , controlState:UIControlState){
self.font = font
}
public func setTitleColorToAdaptiveButton(color: UIColor, controlState:UIControlState){
self.color = color;
}
}
+45
View File
@@ -0,0 +1,45 @@
platform :ios, "7.0"
source 'https://github.com/CocoaPods/Specs.git'
workspace 'SamplesAdaptiveController.xcworkspace'
xcodeproj 'Samples/adaptive-dates-tabbar/example-date-adaptive-tab-bar.xcodeproj'
xcodeproj 'Samples/adaptive-launches-tabbar/example-count-launches-adaptive-tabbar.xcodeproj'
link_with ['example-count-launches-adaptive-tabbar', 'example-date-adaptive-tab-bar']
target 'example-date-adaptive-tab-bar' , :exclusive => true do
xcodeproj 'Samples/adaptive-dates-tabbar/example-date-adaptive-tab-bar.xcodeproj'
pod "AdaptiveController", :path => "./AdaptiveController-0.0.1"
end
target 'example-count-launches-adaptive-tabbar' , :exclusive => true do
xcodeproj 'Samples/adaptive-launches-tabbar/example-count-launches-adaptive-tabbar.xcodeproj'
pod "AdaptiveController", :path => "./AdaptiveController-0.0.1"
end
post_install do |installer|
installer.project.targets.each do |target|
puts "#{target.name}"
end
end
#post_install do |installer|
# settings = Xcodeproj::Project.send(:build_settings, Pod::Platform.new(:ios), :debug)
# configs = installer.project.build_configurations
# configs.new('name' => 'Spec', 'buildSettings' => settings.merge('CONFIGURATION_BUILD_DIR' => '$(BUILD_DIR)/Debug$(EFFECTIVE_PLATFORM_NAME)'))
#end
#post_install do |installer_representation|
# workDir = Dir.pwd
# xcconfigFilename = "#{workDir}/Pods/Target Support Files/Pods-AdaptiveController/Pods-AdaptiveController.xcconfig"
# xcconfig = File.read(xcconfigFilename)
# newXcconfig = xcconfig.gsub(/HEADER_SEARCH_PATHS = "/, "HEADER_SEARCH_PATHS = $(inherited) \"")
# File.open(xcconfigFilename, "w") { |file| file << newXcconfig }
#end
+14
View File
@@ -0,0 +1,14 @@
PODS:
- AdaptiveController (0.0.1)
DEPENDENCIES:
- AdaptiveController (from `./AdaptiveController-0.0.1`)
EXTERNAL SOURCES:
AdaptiveController:
:path: ./AdaptiveController-0.0.1
SPEC CHECKSUMS:
AdaptiveController: f21b5cff66a025b30addf870a593a3350a44d8e3
COCOAPODS: 0.34.4
+21
View File
@@ -0,0 +1,21 @@
Pod::Spec.new do |s|
s.name = 'AdaptiveController'
s.version = '0.0.1'
s.summary = 'AdaptiveController is a Progressive Reduction Swift module for adding custom states to Native or Custom UI elements.'
s.license = {"type"=>"MIT"}
s.authors = {"Artem Kislitsyn, Yuri Vasilenko"=>"juri.v@ramotion.com"}
s.homepage = 'https://github.com/Ramotion/adaptive-tab-bar'
s.frameworks = ["UIKit"]
s.requires_arc = true
s.source = {}
s.osx.platform = :osx, ''
s.osx.preserve_paths = 'AdaptiveController-0.0.1/osx/AdaptiveController.framework'
s.osx.public_header_files = 'AdaptiveController-0.0.1/osx/AdaptiveController.framework/Versions/A/Headers/*.h'
s.osx.vendored_frameworks = 'AdaptiveController-0.0.1/osx/AdaptiveController.framework'
s.ios.platform = :ios, "7.0"
s.ios.preserve_paths = 'AdaptiveController-0.0.1/ios/AdaptiveController.framework'
s.ios.public_header_files = 'AdaptiveController-0.0.1/ios/AdaptiveController.framework/Versions/A/Headers/*.h'
s.ios.vendored_frameworks = 'AdaptiveController-0.0.1/ios/AdaptiveController.framework'
end
+14
View File
@@ -0,0 +1,14 @@
PODS:
- AdaptiveController (0.0.1)
DEPENDENCIES:
- AdaptiveController (from `./AdaptiveController-0.0.1`)
EXTERNAL SOURCES:
AdaptiveController:
:path: ./AdaptiveController-0.0.1
SPEC CHECKSUMS:
AdaptiveController: f21b5cff66a025b30addf870a593a3350a44d8e3
COCOAPODS: 0.34.4
+1516
View File
File diff suppressed because it is too large Load Diff
@@ -0,0 +1,59 @@
<?xml version="1.0" encoding="UTF-8"?>
<Scheme
LastUpgradeVersion = "0510"
version = "1.3">
<BuildAction
parallelizeBuildables = "YES"
buildImplicitDependencies = "YES">
<BuildActionEntries>
<BuildActionEntry
buildForTesting = "YES"
buildForRunning = "YES"
buildForProfiling = "YES"
buildForArchiving = "YES"
buildForAnalyzing = "YES">
<BuildableReference
BuildableIdentifier = "primary"
BlueprintIdentifier = "1423353DF53052B8F07C16F9"
BuildableName = "libPods-example-count-launches-adaptive-tabbar-AdaptiveController.a"
BlueprintName = "Pods-example-count-launches-adaptive-tabbar-AdaptiveController"
ReferencedContainer = "container:Pods.xcodeproj">
</BuildableReference>
</BuildActionEntry>
</BuildActionEntries>
</BuildAction>
<TestAction
selectedDebuggerIdentifier = "Xcode.DebuggerFoundation.Debugger.LLDB"
selectedLauncherIdentifier = "Xcode.DebuggerFoundation.Launcher.LLDB"
shouldUseLaunchSchemeArgsEnv = "YES"
buildConfiguration = "Debug">
<Testables>
</Testables>
</TestAction>
<LaunchAction
selectedDebuggerIdentifier = "Xcode.DebuggerFoundation.Debugger.LLDB"
selectedLauncherIdentifier = "Xcode.DebuggerFoundation.Launcher.LLDB"
launchStyle = "0"
useCustomWorkingDirectory = "NO"
buildConfiguration = "Debug"
ignoresPersistentStateOnLaunch = "NO"
debugDocumentVersioning = "YES"
allowLocationSimulation = "YES">
<AdditionalOptions>
</AdditionalOptions>
</LaunchAction>
<ProfileAction
shouldUseLaunchSchemeArgsEnv = "YES"
savedToolIdentifier = ""
useCustomWorkingDirectory = "NO"
buildConfiguration = "Release"
debugDocumentVersioning = "YES">
</ProfileAction>
<AnalyzeAction
buildConfiguration = "Debug">
</AnalyzeAction>
<ArchiveAction
buildConfiguration = "Release"
revealArchiveInOrganizer = "YES">
</ArchiveAction>
</Scheme>
@@ -0,0 +1,59 @@
<?xml version="1.0" encoding="UTF-8"?>
<Scheme
LastUpgradeVersion = "0510"
version = "1.3">
<BuildAction
parallelizeBuildables = "YES"
buildImplicitDependencies = "YES">
<BuildActionEntries>
<BuildActionEntry
buildForTesting = "YES"
buildForRunning = "YES"
buildForProfiling = "YES"
buildForArchiving = "YES"
buildForAnalyzing = "YES">
<BuildableReference
BuildableIdentifier = "primary"
BlueprintIdentifier = "0B7C5653EC4A060676944D1F"
BuildableName = "libPods-example-count-launches-adaptive-tabbar.a"
BlueprintName = "Pods-example-count-launches-adaptive-tabbar"
ReferencedContainer = "container:Pods.xcodeproj">
</BuildableReference>
</BuildActionEntry>
</BuildActionEntries>
</BuildAction>
<TestAction
selectedDebuggerIdentifier = "Xcode.DebuggerFoundation.Debugger.LLDB"
selectedLauncherIdentifier = "Xcode.DebuggerFoundation.Launcher.LLDB"
shouldUseLaunchSchemeArgsEnv = "YES"
buildConfiguration = "Debug">
<Testables>
</Testables>
</TestAction>
<LaunchAction
selectedDebuggerIdentifier = "Xcode.DebuggerFoundation.Debugger.LLDB"
selectedLauncherIdentifier = "Xcode.DebuggerFoundation.Launcher.LLDB"
launchStyle = "0"
useCustomWorkingDirectory = "NO"
buildConfiguration = "Debug"
ignoresPersistentStateOnLaunch = "NO"
debugDocumentVersioning = "YES"
allowLocationSimulation = "YES">
<AdditionalOptions>
</AdditionalOptions>
</LaunchAction>
<ProfileAction
shouldUseLaunchSchemeArgsEnv = "YES"
savedToolIdentifier = ""
useCustomWorkingDirectory = "NO"
buildConfiguration = "Release"
debugDocumentVersioning = "YES">
</ProfileAction>
<AnalyzeAction
buildConfiguration = "Debug">
</AnalyzeAction>
<ArchiveAction
buildConfiguration = "Release"
revealArchiveInOrganizer = "YES">
</ArchiveAction>
</Scheme>
@@ -0,0 +1,59 @@
<?xml version="1.0" encoding="UTF-8"?>
<Scheme
LastUpgradeVersion = "0510"
version = "1.3">
<BuildAction
parallelizeBuildables = "YES"
buildImplicitDependencies = "YES">
<BuildActionEntries>
<BuildActionEntry
buildForTesting = "YES"
buildForRunning = "YES"
buildForProfiling = "YES"
buildForArchiving = "YES"
buildForAnalyzing = "YES">
<BuildableReference
BuildableIdentifier = "primary"
BlueprintIdentifier = "F41A6FEB8764D6BD888F406D"
BuildableName = "libPods-example-date-adaptive-tab-bar-AdaptiveController.a"
BlueprintName = "Pods-example-date-adaptive-tab-bar-AdaptiveController"
ReferencedContainer = "container:Pods.xcodeproj">
</BuildableReference>
</BuildActionEntry>
</BuildActionEntries>
</BuildAction>
<TestAction
selectedDebuggerIdentifier = "Xcode.DebuggerFoundation.Debugger.LLDB"
selectedLauncherIdentifier = "Xcode.DebuggerFoundation.Launcher.LLDB"
shouldUseLaunchSchemeArgsEnv = "YES"
buildConfiguration = "Debug">
<Testables>
</Testables>
</TestAction>
<LaunchAction
selectedDebuggerIdentifier = "Xcode.DebuggerFoundation.Debugger.LLDB"
selectedLauncherIdentifier = "Xcode.DebuggerFoundation.Launcher.LLDB"
launchStyle = "0"
useCustomWorkingDirectory = "NO"
buildConfiguration = "Debug"
ignoresPersistentStateOnLaunch = "NO"
debugDocumentVersioning = "YES"
allowLocationSimulation = "YES">
<AdditionalOptions>
</AdditionalOptions>
</LaunchAction>
<ProfileAction
shouldUseLaunchSchemeArgsEnv = "YES"
savedToolIdentifier = ""
useCustomWorkingDirectory = "NO"
buildConfiguration = "Release"
debugDocumentVersioning = "YES">
</ProfileAction>
<AnalyzeAction
buildConfiguration = "Debug">
</AnalyzeAction>
<ArchiveAction
buildConfiguration = "Release"
revealArchiveInOrganizer = "YES">
</ArchiveAction>
</Scheme>
@@ -0,0 +1,59 @@
<?xml version="1.0" encoding="UTF-8"?>
<Scheme
LastUpgradeVersion = "0510"
version = "1.3">
<BuildAction
parallelizeBuildables = "YES"
buildImplicitDependencies = "YES">
<BuildActionEntries>
<BuildActionEntry
buildForTesting = "YES"
buildForRunning = "YES"
buildForProfiling = "YES"
buildForArchiving = "YES"
buildForAnalyzing = "YES">
<BuildableReference
BuildableIdentifier = "primary"
BlueprintIdentifier = "DBDBD67BBDD08CE8E4AB6D9F"
BuildableName = "libPods-example-date-adaptive-tab-bar.a"
BlueprintName = "Pods-example-date-adaptive-tab-bar"
ReferencedContainer = "container:Pods.xcodeproj">
</BuildableReference>
</BuildActionEntry>
</BuildActionEntries>
</BuildAction>
<TestAction
selectedDebuggerIdentifier = "Xcode.DebuggerFoundation.Debugger.LLDB"
selectedLauncherIdentifier = "Xcode.DebuggerFoundation.Launcher.LLDB"
shouldUseLaunchSchemeArgsEnv = "YES"
buildConfiguration = "Debug">
<Testables>
</Testables>
</TestAction>
<LaunchAction
selectedDebuggerIdentifier = "Xcode.DebuggerFoundation.Debugger.LLDB"
selectedLauncherIdentifier = "Xcode.DebuggerFoundation.Launcher.LLDB"
launchStyle = "0"
useCustomWorkingDirectory = "NO"
buildConfiguration = "Debug"
ignoresPersistentStateOnLaunch = "NO"
debugDocumentVersioning = "YES"
allowLocationSimulation = "YES">
<AdditionalOptions>
</AdditionalOptions>
</LaunchAction>
<ProfileAction
shouldUseLaunchSchemeArgsEnv = "YES"
savedToolIdentifier = ""
useCustomWorkingDirectory = "NO"
buildConfiguration = "Release"
debugDocumentVersioning = "YES">
</ProfileAction>
<AnalyzeAction
buildConfiguration = "Debug">
</AnalyzeAction>
<ArchiveAction
buildConfiguration = "Release"
revealArchiveInOrganizer = "YES">
</ArchiveAction>
</Scheme>
@@ -0,0 +1,52 @@
<?xml version="1.0" encoding="UTF-8"?>
<!DOCTYPE plist PUBLIC "-//Apple//DTD PLIST 1.0//EN" "http://www.apple.com/DTDs/PropertyList-1.0.dtd">
<plist version="1.0">
<dict>
<key>SchemeUserState</key>
<dict>
<key>Pods-example-count-launches-adaptive-tabbar-AdaptiveController.xcscheme</key>
<dict>
<key>isShown</key>
<false/>
</dict>
<key>Pods-example-count-launches-adaptive-tabbar.xcscheme</key>
<dict>
<key>isShown</key>
<false/>
</dict>
<key>Pods-example-date-adaptive-tab-bar-AdaptiveController.xcscheme</key>
<dict>
<key>isShown</key>
<false/>
</dict>
<key>Pods-example-date-adaptive-tab-bar.xcscheme</key>
<dict>
<key>isShown</key>
<false/>
</dict>
</dict>
<key>SuppressBuildableAutocreation</key>
<dict>
<key>0B7C5653EC4A060676944D1F</key>
<dict>
<key>primary</key>
<true/>
</dict>
<key>1423353DF53052B8F07C16F9</key>
<dict>
<key>primary</key>
<true/>
</dict>
<key>DBDBD67BBDD08CE8E4AB6D9F</key>
<dict>
<key>primary</key>
<true/>
</dict>
<key>F41A6FEB8764D6BD888F406D</key>
<dict>
<key>primary</key>
<true/>
</dict>
</dict>
</dict>
</plist>
@@ -0,0 +1,5 @@
#include "Pods-example-count-launches-adaptive-tabbar-AdaptiveController.xcconfig"
GCC_PREPROCESSOR_DEFINITIONS = $(inherited) COCOAPODS=1
HEADER_SEARCH_PATHS = "${PODS_ROOT}/Headers/Build" "${PODS_ROOT}/Headers/Build/AdaptiveController" "${PODS_ROOT}/Headers/Public" "${PODS_ROOT}/Headers/Public/AdaptiveController"
OTHER_LDFLAGS = ${PODS_EXAMPLE_COUNT_LAUNCHES_ADAPTIVE_TABBAR_ADAPTIVECONTROLLER_OTHER_LDFLAGS} -ObjC
PODS_ROOT = ${SRCROOT}
@@ -0,0 +1,5 @@
#import <Foundation/Foundation.h>
@interface PodsDummy_Pods_example_count_launches_adaptive_tabbar_AdaptiveController : NSObject
@end
@implementation PodsDummy_Pods_example_count_launches_adaptive_tabbar_AdaptiveController
@end
@@ -0,0 +1,5 @@
#ifdef __OBJC__
#import <UIKit/UIKit.h>
#endif
#import "Pods-example-count-launches-adaptive-tabbar-environment.h"
@@ -0,0 +1 @@
PODS_EXAMPLE_COUNT_LAUNCHES_ADAPTIVE_TABBAR_ADAPTIVECONTROLLER_OTHER_LDFLAGS = -framework "UIKit"
@@ -0,0 +1,3 @@
# Acknowledgements
This application makes use of the following third party libraries:
Generated by CocoaPods - http://cocoapods.org
@@ -0,0 +1,29 @@
<?xml version="1.0" encoding="UTF-8"?>
<!DOCTYPE plist PUBLIC "-//Apple//DTD PLIST 1.0//EN" "http://www.apple.com/DTDs/PropertyList-1.0.dtd">
<plist version="1.0">
<dict>
<key>PreferenceSpecifiers</key>
<array>
<dict>
<key>FooterText</key>
<string>This application makes use of the following third party libraries:</string>
<key>Title</key>
<string>Acknowledgements</string>
<key>Type</key>
<string>PSGroupSpecifier</string>
</dict>
<dict>
<key>FooterText</key>
<string>Generated by CocoaPods - http://cocoapods.org</string>
<key>Title</key>
<string></string>
<key>Type</key>
<string>PSGroupSpecifier</string>
</dict>
</array>
<key>StringsTable</key>
<string>Acknowledgements</string>
<key>Title</key>
<string>Acknowledgements</string>
</dict>
</plist>
@@ -0,0 +1,5 @@
#import <Foundation/Foundation.h>
@interface PodsDummy_Pods_example_count_launches_adaptive_tabbar : NSObject
@end
@implementation PodsDummy_Pods_example_count_launches_adaptive_tabbar
@end
@@ -0,0 +1,14 @@
// To check if a library is compiled with CocoaPods you
// can use the `COCOAPODS` macro definition which is
// defined in the xcconfigs so it is available in
// headers also when they are imported in the client
// project.
// AdaptiveController
#define COCOAPODS_POD_AVAILABLE_AdaptiveController
#define COCOAPODS_VERSION_MAJOR_AdaptiveController 0
#define COCOAPODS_VERSION_MINOR_AdaptiveController 0
#define COCOAPODS_VERSION_PATCH_AdaptiveController 1
@@ -0,0 +1,70 @@
#!/bin/sh
set -e
mkdir -p "${CONFIGURATION_BUILD_DIR}/${UNLOCALIZED_RESOURCES_FOLDER_PATH}"
RESOURCES_TO_COPY=${PODS_ROOT}/resources-to-copy-${TARGETNAME}.txt
> "$RESOURCES_TO_COPY"
install_resource()
{
case $1 in
*.storyboard)
echo "ibtool --reference-external-strings-file --errors --warnings --notices --output-format human-readable-text --compile ${CONFIGURATION_BUILD_DIR}/${UNLOCALIZED_RESOURCES_FOLDER_PATH}/`basename \"$1\" .storyboard`.storyboardc ${PODS_ROOT}/$1 --sdk ${SDKROOT}"
ibtool --reference-external-strings-file --errors --warnings --notices --output-format human-readable-text --compile "${CONFIGURATION_BUILD_DIR}/${UNLOCALIZED_RESOURCES_FOLDER_PATH}/`basename \"$1\" .storyboard`.storyboardc" "${PODS_ROOT}/$1" --sdk "${SDKROOT}"
;;
*.xib)
echo "ibtool --reference-external-strings-file --errors --warnings --notices --output-format human-readable-text --compile ${CONFIGURATION_BUILD_DIR}/${UNLOCALIZED_RESOURCES_FOLDER_PATH}/`basename \"$1\" .xib`.nib ${PODS_ROOT}/$1 --sdk ${SDKROOT}"
ibtool --reference-external-strings-file --errors --warnings --notices --output-format human-readable-text --compile "${CONFIGURATION_BUILD_DIR}/${UNLOCALIZED_RESOURCES_FOLDER_PATH}/`basename \"$1\" .xib`.nib" "${PODS_ROOT}/$1" --sdk "${SDKROOT}"
;;
*.framework)
echo "mkdir -p ${CONFIGURATION_BUILD_DIR}/${FRAMEWORKS_FOLDER_PATH}"
mkdir -p "${CONFIGURATION_BUILD_DIR}/${FRAMEWORKS_FOLDER_PATH}"
echo "rsync -av ${PODS_ROOT}/$1 ${CONFIGURATION_BUILD_DIR}/${FRAMEWORKS_FOLDER_PATH}"
rsync -av "${PODS_ROOT}/$1" "${CONFIGURATION_BUILD_DIR}/${FRAMEWORKS_FOLDER_PATH}"
;;
*.xcdatamodel)
echo "xcrun momc \"${PODS_ROOT}/$1\" \"${CONFIGURATION_BUILD_DIR}/${UNLOCALIZED_RESOURCES_FOLDER_PATH}/`basename "$1"`.mom\""
xcrun momc "${PODS_ROOT}/$1" "${CONFIGURATION_BUILD_DIR}/${UNLOCALIZED_RESOURCES_FOLDER_PATH}/`basename "$1" .xcdatamodel`.mom"
;;
*.xcdatamodeld)
echo "xcrun momc \"${PODS_ROOT}/$1\" \"${CONFIGURATION_BUILD_DIR}/${UNLOCALIZED_RESOURCES_FOLDER_PATH}/`basename "$1" .xcdatamodeld`.momd\""
xcrun momc "${PODS_ROOT}/$1" "${CONFIGURATION_BUILD_DIR}/${UNLOCALIZED_RESOURCES_FOLDER_PATH}/`basename "$1" .xcdatamodeld`.momd"
;;
*.xcassets)
;;
/*)
echo "$1"
echo "$1" >> "$RESOURCES_TO_COPY"
;;
*)
echo "${PODS_ROOT}/$1"
echo "${PODS_ROOT}/$1" >> "$RESOURCES_TO_COPY"
;;
esac
}
rsync -avr --copy-links --no-relative --exclude '*/.svn/*' --files-from="$RESOURCES_TO_COPY" / "${CONFIGURATION_BUILD_DIR}/${UNLOCALIZED_RESOURCES_FOLDER_PATH}"
if [[ "${ACTION}" == "install" ]]; then
rsync -avr --copy-links --no-relative --exclude '*/.svn/*' --files-from="$RESOURCES_TO_COPY" / "${INSTALL_DIR}/${UNLOCALIZED_RESOURCES_FOLDER_PATH}"
fi
rm -f "$RESOURCES_TO_COPY"
if [[ -n "${WRAPPER_EXTENSION}" ]] && [ "`xcrun --find actool`" ] && [ `find . -name '*.xcassets' | wc -l` -ne 0 ]
then
case "${TARGETED_DEVICE_FAMILY}" in
1,2)
TARGET_DEVICE_ARGS="--target-device ipad --target-device iphone"
;;
1)
TARGET_DEVICE_ARGS="--target-device iphone"
;;
2)
TARGET_DEVICE_ARGS="--target-device ipad"
;;
*)
TARGET_DEVICE_ARGS="--target-device mac"
;;
esac
find "${PWD}" -name "*.xcassets" -print0 | xargs -0 actool --output-format human-readable-text --notices --warnings --platform "${PLATFORM_NAME}" --minimum-deployment-target "${IPHONEOS_DEPLOYMENT_TARGET}" ${TARGET_DEVICE_ARGS} --compress-pngs --compile "${BUILT_PRODUCTS_DIR}/${UNLOCALIZED_RESOURCES_FOLDER_PATH}"
fi
@@ -0,0 +1,6 @@
GCC_PREPROCESSOR_DEFINITIONS = $(inherited) COCOAPODS=1
HEADER_SEARCH_PATHS = "${PODS_ROOT}/Headers/Public" "${PODS_ROOT}/Headers/Public/AdaptiveController"
OTHER_CFLAGS = $(inherited) -isystem "${PODS_ROOT}/Headers/Public" -isystem "${PODS_ROOT}/Headers/Public/AdaptiveController"
OTHER_LDFLAGS = -ObjC -l"Pods-example-count-launches-adaptive-tabbar-AdaptiveController" -framework "UIKit"
OTHER_LIBTOOLFLAGS = $(OTHER_LDFLAGS)
PODS_ROOT = ${SRCROOT}/../../Pods
@@ -0,0 +1,6 @@
GCC_PREPROCESSOR_DEFINITIONS = $(inherited) COCOAPODS=1
HEADER_SEARCH_PATHS = "${PODS_ROOT}/Headers/Public" "${PODS_ROOT}/Headers/Public/AdaptiveController"
OTHER_CFLAGS = $(inherited) -isystem "${PODS_ROOT}/Headers/Public" -isystem "${PODS_ROOT}/Headers/Public/AdaptiveController"
OTHER_LDFLAGS = -ObjC -l"Pods-example-count-launches-adaptive-tabbar-AdaptiveController" -framework "UIKit"
OTHER_LIBTOOLFLAGS = $(OTHER_LDFLAGS)
PODS_ROOT = ${SRCROOT}/../../Pods
@@ -0,0 +1,5 @@
#include "Pods-example-date-adaptive-tab-bar-AdaptiveController.xcconfig"
GCC_PREPROCESSOR_DEFINITIONS = $(inherited) COCOAPODS=1
HEADER_SEARCH_PATHS = "${PODS_ROOT}/Headers/Build" "${PODS_ROOT}/Headers/Build/AdaptiveController" "${PODS_ROOT}/Headers/Public" "${PODS_ROOT}/Headers/Public/AdaptiveController"
OTHER_LDFLAGS = ${PODS_EXAMPLE_DATE_ADAPTIVE_TAB_BAR_ADAPTIVECONTROLLER_OTHER_LDFLAGS} -ObjC
PODS_ROOT = ${SRCROOT}
@@ -0,0 +1,5 @@
#import <Foundation/Foundation.h>
@interface PodsDummy_Pods_example_date_adaptive_tab_bar_AdaptiveController : NSObject
@end
@implementation PodsDummy_Pods_example_date_adaptive_tab_bar_AdaptiveController
@end
@@ -0,0 +1,5 @@
#ifdef __OBJC__
#import <UIKit/UIKit.h>
#endif
#import "Pods-example-date-adaptive-tab-bar-environment.h"
@@ -0,0 +1 @@
PODS_EXAMPLE_DATE_ADAPTIVE_TAB_BAR_ADAPTIVECONTROLLER_OTHER_LDFLAGS = -framework "UIKit"
@@ -0,0 +1,3 @@
# Acknowledgements
This application makes use of the following third party libraries:
Generated by CocoaPods - http://cocoapods.org
@@ -0,0 +1,29 @@
<?xml version="1.0" encoding="UTF-8"?>
<!DOCTYPE plist PUBLIC "-//Apple//DTD PLIST 1.0//EN" "http://www.apple.com/DTDs/PropertyList-1.0.dtd">
<plist version="1.0">
<dict>
<key>PreferenceSpecifiers</key>
<array>
<dict>
<key>FooterText</key>
<string>This application makes use of the following third party libraries:</string>
<key>Title</key>
<string>Acknowledgements</string>
<key>Type</key>
<string>PSGroupSpecifier</string>
</dict>
<dict>
<key>FooterText</key>
<string>Generated by CocoaPods - http://cocoapods.org</string>
<key>Title</key>
<string></string>
<key>Type</key>
<string>PSGroupSpecifier</string>
</dict>
</array>
<key>StringsTable</key>
<string>Acknowledgements</string>
<key>Title</key>
<string>Acknowledgements</string>
</dict>
</plist>
@@ -0,0 +1,5 @@
#import <Foundation/Foundation.h>
@interface PodsDummy_Pods_example_date_adaptive_tab_bar : NSObject
@end
@implementation PodsDummy_Pods_example_date_adaptive_tab_bar
@end
@@ -0,0 +1,14 @@
// To check if a library is compiled with CocoaPods you
// can use the `COCOAPODS` macro definition which is
// defined in the xcconfigs so it is available in
// headers also when they are imported in the client
// project.
// AdaptiveController
#define COCOAPODS_POD_AVAILABLE_AdaptiveController
#define COCOAPODS_VERSION_MAJOR_AdaptiveController 0
#define COCOAPODS_VERSION_MINOR_AdaptiveController 0
#define COCOAPODS_VERSION_PATCH_AdaptiveController 1
@@ -0,0 +1,70 @@
#!/bin/sh
set -e
mkdir -p "${CONFIGURATION_BUILD_DIR}/${UNLOCALIZED_RESOURCES_FOLDER_PATH}"
RESOURCES_TO_COPY=${PODS_ROOT}/resources-to-copy-${TARGETNAME}.txt
> "$RESOURCES_TO_COPY"
install_resource()
{
case $1 in
*.storyboard)
echo "ibtool --reference-external-strings-file --errors --warnings --notices --output-format human-readable-text --compile ${CONFIGURATION_BUILD_DIR}/${UNLOCALIZED_RESOURCES_FOLDER_PATH}/`basename \"$1\" .storyboard`.storyboardc ${PODS_ROOT}/$1 --sdk ${SDKROOT}"
ibtool --reference-external-strings-file --errors --warnings --notices --output-format human-readable-text --compile "${CONFIGURATION_BUILD_DIR}/${UNLOCALIZED_RESOURCES_FOLDER_PATH}/`basename \"$1\" .storyboard`.storyboardc" "${PODS_ROOT}/$1" --sdk "${SDKROOT}"
;;
*.xib)
echo "ibtool --reference-external-strings-file --errors --warnings --notices --output-format human-readable-text --compile ${CONFIGURATION_BUILD_DIR}/${UNLOCALIZED_RESOURCES_FOLDER_PATH}/`basename \"$1\" .xib`.nib ${PODS_ROOT}/$1 --sdk ${SDKROOT}"
ibtool --reference-external-strings-file --errors --warnings --notices --output-format human-readable-text --compile "${CONFIGURATION_BUILD_DIR}/${UNLOCALIZED_RESOURCES_FOLDER_PATH}/`basename \"$1\" .xib`.nib" "${PODS_ROOT}/$1" --sdk "${SDKROOT}"
;;
*.framework)
echo "mkdir -p ${CONFIGURATION_BUILD_DIR}/${FRAMEWORKS_FOLDER_PATH}"
mkdir -p "${CONFIGURATION_BUILD_DIR}/${FRAMEWORKS_FOLDER_PATH}"
echo "rsync -av ${PODS_ROOT}/$1 ${CONFIGURATION_BUILD_DIR}/${FRAMEWORKS_FOLDER_PATH}"
rsync -av "${PODS_ROOT}/$1" "${CONFIGURATION_BUILD_DIR}/${FRAMEWORKS_FOLDER_PATH}"
;;
*.xcdatamodel)
echo "xcrun momc \"${PODS_ROOT}/$1\" \"${CONFIGURATION_BUILD_DIR}/${UNLOCALIZED_RESOURCES_FOLDER_PATH}/`basename "$1"`.mom\""
xcrun momc "${PODS_ROOT}/$1" "${CONFIGURATION_BUILD_DIR}/${UNLOCALIZED_RESOURCES_FOLDER_PATH}/`basename "$1" .xcdatamodel`.mom"
;;
*.xcdatamodeld)
echo "xcrun momc \"${PODS_ROOT}/$1\" \"${CONFIGURATION_BUILD_DIR}/${UNLOCALIZED_RESOURCES_FOLDER_PATH}/`basename "$1" .xcdatamodeld`.momd\""
xcrun momc "${PODS_ROOT}/$1" "${CONFIGURATION_BUILD_DIR}/${UNLOCALIZED_RESOURCES_FOLDER_PATH}/`basename "$1" .xcdatamodeld`.momd"
;;
*.xcassets)
;;
/*)
echo "$1"
echo "$1" >> "$RESOURCES_TO_COPY"
;;
*)
echo "${PODS_ROOT}/$1"
echo "${PODS_ROOT}/$1" >> "$RESOURCES_TO_COPY"
;;
esac
}
rsync -avr --copy-links --no-relative --exclude '*/.svn/*' --files-from="$RESOURCES_TO_COPY" / "${CONFIGURATION_BUILD_DIR}/${UNLOCALIZED_RESOURCES_FOLDER_PATH}"
if [[ "${ACTION}" == "install" ]]; then
rsync -avr --copy-links --no-relative --exclude '*/.svn/*' --files-from="$RESOURCES_TO_COPY" / "${INSTALL_DIR}/${UNLOCALIZED_RESOURCES_FOLDER_PATH}"
fi
rm -f "$RESOURCES_TO_COPY"
if [[ -n "${WRAPPER_EXTENSION}" ]] && [ "`xcrun --find actool`" ] && [ `find . -name '*.xcassets' | wc -l` -ne 0 ]
then
case "${TARGETED_DEVICE_FAMILY}" in
1,2)
TARGET_DEVICE_ARGS="--target-device ipad --target-device iphone"
;;
1)
TARGET_DEVICE_ARGS="--target-device iphone"
;;
2)
TARGET_DEVICE_ARGS="--target-device ipad"
;;
*)
TARGET_DEVICE_ARGS="--target-device mac"
;;
esac
find "${PWD}" -name "*.xcassets" -print0 | xargs -0 actool --output-format human-readable-text --notices --warnings --platform "${PLATFORM_NAME}" --minimum-deployment-target "${IPHONEOS_DEPLOYMENT_TARGET}" ${TARGET_DEVICE_ARGS} --compress-pngs --compile "${BUILT_PRODUCTS_DIR}/${UNLOCALIZED_RESOURCES_FOLDER_PATH}"
fi
@@ -0,0 +1,6 @@
GCC_PREPROCESSOR_DEFINITIONS = $(inherited) COCOAPODS=1
HEADER_SEARCH_PATHS = "${PODS_ROOT}/Headers/Public" "${PODS_ROOT}/Headers/Public/AdaptiveController"
OTHER_CFLAGS = $(inherited) -isystem "${PODS_ROOT}/Headers/Public" -isystem "${PODS_ROOT}/Headers/Public/AdaptiveController"
OTHER_LDFLAGS = -ObjC -l"Pods-example-date-adaptive-tab-bar-AdaptiveController" -framework "UIKit"
OTHER_LIBTOOLFLAGS = $(OTHER_LDFLAGS)
PODS_ROOT = ${SRCROOT}/../../Pods
@@ -0,0 +1,6 @@
GCC_PREPROCESSOR_DEFINITIONS = $(inherited) COCOAPODS=1
HEADER_SEARCH_PATHS = "${PODS_ROOT}/Headers/Public" "${PODS_ROOT}/Headers/Public/AdaptiveController"
OTHER_CFLAGS = $(inherited) -isystem "${PODS_ROOT}/Headers/Public" -isystem "${PODS_ROOT}/Headers/Public/AdaptiveController"
OTHER_LDFLAGS = -ObjC -l"Pods-example-date-adaptive-tab-bar-AdaptiveController" -framework "UIKit"
OTHER_LIBTOOLFLAGS = $(OTHER_LDFLAGS)
PODS_ROOT = ${SRCROOT}/../../Pods
+25 -35
View File
@@ -49,54 +49,44 @@ And then you should setup an array of appearances. You should setup button image
And then you should setup an array of items Appearance object. You should set the button's image for each state for each appearance object.
First, you should setup a style for each UI state:
First, you should setup a dictionary for the extension of the image for each UI state:
```swift
var settingsManager = AppearenceSettingManager()
settingsManager.defaultStyleSettingsForNormalState(AdaptiveStateEnum.DefaultAdaptiveState,titleOffset:defaultOffset, imageInsets:defaultInsets, titleColor:UIColor.whiteColor(), font:defaultFont!, backgroundColor:UIColor.clearColor())
settingsManager.defaultStyleSettingsForNormalState(AdaptiveStateEnum.SmallTitleAdaptiveState,titleOffset:defaultOffset, imageInsets:defaultSmallTitleModeImageInsets, titleColor:UIColor.whiteColor(), font:defaultSmallTitleModeFont!, backgroundColor:UIColor.clearColor())
settingsManager.defaultStyleSettingsForNormalState(AdaptiveStateEnum.ImageAdaptiveState,titleOffset:defaultOffset, imageInsets:defaultImageModeInsets, titleColor:UIColor.whiteColor(), font:defaultFont!, backgroundColor:UIColor.clearColor())
```swift
var imageExtensionsForStates:Dictionary = [ kSmallTitleAdaptiveState:"_smalltitle", kImageAdaptiveState:"_bigimage", kSmallTitleAdaptiveState+selected :"_smalltitle", kImageAdaptiveState+selected:"_bigimage" ]
```
Then you should set the Appearance for each UITabBarItem title for each state and image for each state
Then you should set the Appearance for each UITabBarItem title for each state, fonts for each state, a default image if you describe an extension for each state, or if you do not describe an extension, you should setup each image for each state.
First, init the appearance values with title and image with presetes appearances style :
First, init the appearance object and setup the text for each state. If the text is the same for each state, you can set text for the default state:
```swift
var messageСontrolDefaultStateValue = settingsManager.defaultStyleValuesForNormalState(AdaptiveStateEnum.DefaultAdaptiveState, title:"messages", imageName:"messages")
var messageControlSmallTitleStateValue = settingsManager.defaultStyleValuesForNormalState(AdaptiveStateEnum.SmallTitleAdaptiveState, title:"messages", imageName:"messages_smalltitle")
var messageControlImageStateValue = settingsManager.defaultStyleValuesForNormalState(AdaptiveStateEnum.ImageAdaptiveState, title:"", imageName:"messages_bigimage")
```swift
var watchAppearance = AdaptiveButtonAppearance();
watchAppearance.setButonTitle("watch", state: kDefaultAdaptiveState)
watchAppearance.setButonTitle("watch", state: kSmallTitleAdaptiveState)
watchAppearance.setButonTitle("", state: kImageAdaptiveState)
```
then init appearace opject with aprerance object for each state
Then you should setup your fonts for each state:
```swift
let messageAppearanceStates = [AdaptiveStateEnum.DefaultAdaptiveState:messageСontrolDefaultStateValue,
AdaptiveStateEnum.SmallTitleAdaptiveState:messageControlSmallTitleStateValue,
AdaptiveStateEnum.ImageAdaptiveState:messageControlImageStateValue]
var messageAperance = AdaptiveButtonAppearance(states:messageAppearanceStates)
es)
watchAppearance.setButonTitleFontForState(yourDefaultFont, state: kDefaultAdaptiveState)
watchAppearance.setButonTitleFontForState(yourDefaultSmallTitleModeFont, state: kSmallTitleAdaptiveState)
```
In alternative way you can setup all appearances settings in plist like on image
Then you should set the default image and extensions for each state a function which automaticaly sets images for each state:
![Mou icon](http://i.imgur.com/zLP8zHF.png)
sample of plist you can find in example-date-adaptive-tab-bar project file named appearances.plist
for setuping button appearences from plist you can use this code:
```swift
var seriliazator = DictioanarySeriliazator()
var butonsApperances = seriliazator.getButtonApperances(path!)
```swift
watchAppearance.setImageNamesForStatesImageExtesions("watch", imageExtensionsForState:imageExtensionsForStates)
```
for debugging button appearences you can save your aperances in plist for this you can use next code:
Then you should setup the appearance insets for each state:
```swift
watchAppearance.setImageInsets(defaultInsets, state: kDefaultAdaptiveState);
watchAppearance.setImageInsets(defaultSmallTitleModeImageInsets, state: kSmallTitleAdaptiveState)
watchAppearance.setTitleOffset(defaultOffset, state: kDefaultAdaptiveState)
watchAppearance.setImageInsets(defaultImageModeInsets, state: kImageAdaptiveState);
```
```swift
var paths = NSSearchPathForDirectoriesInDomains(.DocumentDirectory, .UserDomainMask, true)[0] as String
paths = paths.stringByAppendingPathComponent("appearances.plist")
seriliazator.saveStateDictionary(butonsApperances,filePath:paths)
```
Then you should setup сustom UITabBarItems which conform to the AdaptiveButtonsProtocol:
```swift
@@ -37,31 +37,106 @@ class AppDelegate: UIResponder, UIApplicationDelegate {
tabBar.barTintColor = tabColor
tabBar.clipsToBounds = true
var installDate = NSDate(dateString:"2014-10-22")
var installDate = NSDate(dateString:"2014-07-7")
var adaptiveState = AdaptiveDateState(installDate: installDate,currentDate:NSDate(),countDaysToSmallTextState:countDaysToSmallTextState,countDaysToImageState:countDaysToImageState)
let path = NSBundle.mainBundle().pathForResource("appearances", ofType: "plist")
var serializer = DictioanarySerializer()
var butonsApperances = serializer.parseFromPlistToButtonAppearances(path!)
var butonsApperances = buttonsAppearancesGenerate()
var arrayButtons = tabBar.items as [UITabBarItem]
AdaptiveButtonsStateManager.setupButtonsAppearanceFromState(adaptiveState,buttonsAray:arrayButtons ,buttonsAppearances: butonsApperances)
var arrayButtons = tabBar.items as [AdaptiveTabBarItem]
AdaptiveButtonsStateManager(state: adaptiveState,buttonsAray:arrayButtons ,buttonsAppearance: butonsApperances)
return true
}
func buttonsAppearancesGenerate() -> [AdaptiveButtonAppearance]{
var imageExtensionsForStates:Dictionary = [ kDefaultAdaptiveState:"",
kSmallTitleAdaptiveState:"_smalltitle",
kImageAdaptiveState:"_bigimage",
kSmallTitleAdaptiveState+selected :"_smalltitle",
kImageAdaptiveState+selected:"_bigimage" ]
var watchAperance = AdaptiveButtonAppearance();
watchAperance.setButonTitle("watch", state: kDefaultAdaptiveState)
watchAperance.setButonTitle("watch", state: kSmallTitleAdaptiveState)
watchAperance.setButonTitle("", state: kImageAdaptiveState)
watchAperance.setTitleColor(UIColor.whiteColor(), state: kDefaultAdaptiveState)
watchAperance.setButonTitleFontForState(defaultFont, state: kDefaultAdaptiveState)
watchAperance.setButonTitleFontForState(defaultSmallTitleModeFont, state: kSmallTitleAdaptiveState)
watchAperance.setImageNamesForStatesImageExtesions("watch", imageExtensionsForState:imageExtensionsForStates)
watchAperance.setImageInsets(defaultInsets, state: kDefaultAdaptiveState);
watchAperance.setImageInsets(defaultSmallTitleModeImageInsets, state: kSmallTitleAdaptiveState)
watchAperance.setTitleOffset(defaultOffset, state: kDefaultAdaptiveState)
watchAperance.setImageInsets(defaultImageModeInsets, state: kImageAdaptiveState);
var userAperance = AdaptiveButtonAppearance();
userAperance.setAllCommonApperanceFrom(watchAperance)
userAperance.setButonTitle("user", state: kDefaultAdaptiveState)
userAperance.setButonTitle("", state: kImageAdaptiveState)
userAperance.setImageNamesForStatesImageExtesions("man", imageExtensionsForState:imageExtensionsForStates)
var messageAperance = AdaptiveButtonAppearance();
messageAperance.setAllCommonApperanceFrom((watchAperance))
messageAperance.setButonTitle("message", state: kDefaultAdaptiveState)
messageAperance.setButonTitle("", state: kImageAdaptiveState)
messageAperance.setImageNamesForStatesImageExtesions("messages", imageExtensionsForState:imageExtensionsForStates)
var menuAperance = AdaptiveButtonAppearance();
menuAperance.setAllCommonApperanceFrom((watchAperance))
menuAperance.setButonTitle("dial", state: kDefaultAdaptiveState)
menuAperance.setButonTitle("", state: kImageAdaptiveState)
menuAperance.setImageNamesForStatesImageExtesions("menu", imageExtensionsForState:imageExtensionsForStates)
var moreAperance = AdaptiveButtonAppearance();
moreAperance.setAllCommonApperanceFrom((watchAperance))
moreAperance.setButonTitle("more", state: kDefaultAdaptiveState)
moreAperance.setButonTitle("", state: kImageAdaptiveState)
moreAperance.setImageNamesForStatesImageExtesions("more", imageExtensionsForState:imageExtensionsForStates)
return [watchAperance ,messageAperance,userAperance,menuAperance,moreAperance]
}
}
@@ -1,7 +1,7 @@
<?xml version="1.0" encoding="UTF-8" standalone="no"?>
<document type="com.apple.InterfaceBuilder3.CocoaTouch.XIB" version="3.0" toolsVersion="6250" systemVersion="14A389" targetRuntime="iOS.CocoaTouch" propertyAccessControl="none" useAutolayout="YES" launchScreen="YES" useTraitCollections="YES">
<document type="com.apple.InterfaceBuilder3.CocoaTouch.XIB" version="3.0" toolsVersion="6245" systemVersion="13F34" targetRuntime="iOS.CocoaTouch" propertyAccessControl="none" useAutolayout="YES" launchScreen="YES" useTraitCollections="YES">
<dependencies>
<plugIn identifier="com.apple.InterfaceBuilder.IBCocoaTouchPlugin" version="6244"/>
<plugIn identifier="com.apple.InterfaceBuilder.IBCocoaTouchPlugin" version="6238"/>
<capability name="Constraints with non-1.0 multipliers" minToolsVersion="5.1"/>
</dependencies>
<objects>
@@ -1,14 +1,13 @@
<?xml version="1.0" encoding="UTF-8" standalone="no"?>
<document type="com.apple.InterfaceBuilder3.CocoaTouch.Storyboard.XIB" version="3.0" toolsVersion="6250" systemVersion="14A389" targetRuntime="iOS.CocoaTouch" propertyAccessControl="none" useAutolayout="YES" useTraitCollections="YES" initialViewController="49e-Tb-3d3">
<document type="com.apple.InterfaceBuilder3.CocoaTouch.Storyboard.XIB" version="3.0" toolsVersion="6245" systemVersion="13F34" targetRuntime="iOS.CocoaTouch" propertyAccessControl="none" useAutolayout="YES" useTraitCollections="YES" initialViewController="49e-Tb-3d3">
<dependencies>
<plugIn identifier="com.apple.InterfaceBuilder.IBCocoaTouchPlugin" version="6244"/>
<capability name="Constraints to layout margins" minToolsVersion="6.0"/>
<plugIn identifier="com.apple.InterfaceBuilder.IBCocoaTouchPlugin" version="6238"/>
</dependencies>
<scenes>
<!--First-->
<scene sceneID="hNz-n2-bh7">
<objects>
<viewController id="9pv-A4-QxB" customClass="WatchViewController" customModule="example_date_adaptive_tab_bar" customModuleProvider="target" sceneMemberID="viewController">
<viewController id="9pv-A4-QxB" customClass="WatchViewController" customModule="adaptive_tab_bar" customModuleProvider="target" sceneMemberID="viewController">
<layoutGuides>
<viewControllerLayoutGuide type="top" id="Ia1-K6-d13"/>
<viewControllerLayoutGuide type="bottom" id="4ug-Mw-9AY"/>
@@ -30,23 +29,19 @@
<color key="textColor" cocoaTouchSystemColor="darkTextColor"/>
<nil key="highlightedColor"/>
</label>
<imageView userInteractionEnabled="NO" contentMode="scaleToFill" horizontalHuggingPriority="251" verticalHuggingPriority="251" image="background" translatesAutoresizingMaskIntoConstraints="NO" id="bTY-b5-lYl">
<rect key="frame" x="0.0" y="0.0" width="640" height="551"/>
<imageView userInteractionEnabled="NO" contentMode="scaleToFill" horizontalHuggingPriority="251" verticalHuggingPriority="251" fixedFrame="YES" image="background" translatesAutoresizingMaskIntoConstraints="NO" id="bTY-b5-lYl">
<rect key="frame" x="0.0" y="0.0" width="640" height="550"/>
</imageView>
</subviews>
<color key="backgroundColor" white="1" alpha="1" colorSpace="custom" customColorSpace="calibratedWhite"/>
<constraints>
<constraint firstItem="4ug-Mw-9AY" firstAttribute="top" secondItem="bTY-b5-lYl" secondAttribute="bottom" id="57C-0I-UhP"/>
<constraint firstAttribute="centerX" secondItem="KQZ-1w-vlD" secondAttribute="centerX" id="6BV-lF-sBN"/>
<constraint firstItem="A5M-7J-77L" firstAttribute="top" secondItem="KQZ-1w-vlD" secondAttribute="bottom" constant="8" symbolic="YES" id="cfb-er-3JN"/>
<constraint firstItem="A5M-7J-77L" firstAttribute="centerX" secondItem="KQZ-1w-vlD" secondAttribute="centerX" id="e1l-AV-tCB"/>
<constraint firstAttribute="centerY" secondItem="KQZ-1w-vlD" secondAttribute="centerY" id="exm-UA-ej4"/>
<constraint firstItem="bTY-b5-lYl" firstAttribute="top" secondItem="tsR-hK-woN" secondAttribute="top" id="kWQ-y6-H6g"/>
<constraint firstAttribute="trailing" secondItem="bTY-b5-lYl" secondAttribute="trailing" constant="-40" id="sYy-Hj-V1a"/>
<constraint firstItem="bTY-b5-lYl" firstAttribute="leading" secondItem="tsR-hK-woN" secondAttribute="leading" id="ueh-EO-Puf"/>
</constraints>
</view>
<tabBarItem key="tabBarItem" title="First" id="acW-dT-cKf" customClass="AdaptiveTabBarItem" customModule="example_date_adaptive_tab_bar" customModuleProvider="target"/>
<tabBarItem key="tabBarItem" title="First" id="acW-dT-cKf" customClass="AdaptiveTabBarItem" customModule="adaptive_tab_bar" customModuleProvider="target"/>
</viewController>
<placeholder placeholderIdentifier="IBFirstResponder" id="W5J-7L-Pyd" sceneMemberID="firstResponder"/>
</objects>
@@ -55,7 +50,7 @@
<!--Second-->
<scene sceneID="wg7-f3-ORb">
<objects>
<viewController id="8rJ-Kc-sve" customClass="MessageViewController" customModule="example_date_adaptive_tab_bar" customModuleProvider="target" sceneMemberID="viewController">
<viewController id="8rJ-Kc-sve" customClass="MessageViewController" customModule="adaptive_tab_bar" customModuleProvider="target" sceneMemberID="viewController">
<layoutGuides>
<viewControllerLayoutGuide type="top" id="L7p-HK-0SC"/>
<viewControllerLayoutGuide type="bottom" id="Djb-ko-YwX"/>
@@ -77,23 +72,19 @@
<color key="textColor" cocoaTouchSystemColor="darkTextColor"/>
<nil key="highlightedColor"/>
</label>
<imageView userInteractionEnabled="NO" contentMode="scaleToFill" horizontalHuggingPriority="251" verticalHuggingPriority="251" image="background" translatesAutoresizingMaskIntoConstraints="NO" id="d3m-k5-qah">
<rect key="frame" x="0.0" y="0.0" width="640" height="551"/>
<imageView userInteractionEnabled="NO" contentMode="scaleToFill" horizontalHuggingPriority="251" verticalHuggingPriority="251" fixedFrame="YES" image="background" translatesAutoresizingMaskIntoConstraints="NO" id="d3m-k5-qah">
<rect key="frame" x="0.0" y="0.0" width="640" height="550"/>
</imageView>
</subviews>
<color key="backgroundColor" white="1" alpha="1" colorSpace="custom" customColorSpace="calibratedWhite"/>
<constraints>
<constraint firstAttribute="trailing" secondItem="d3m-k5-qah" secondAttribute="trailing" constant="-40" id="8KS-iG-8XT"/>
<constraint firstItem="NDk-cv-Gan" firstAttribute="top" secondItem="zEq-FU-wV5" secondAttribute="bottom" constant="8" symbolic="YES" id="Day-4N-Vmt"/>
<constraint firstItem="NDk-cv-Gan" firstAttribute="centerX" secondItem="zEq-FU-wV5" secondAttribute="centerX" id="JgO-Fn-dHn"/>
<constraint firstItem="d3m-k5-qah" firstAttribute="leading" secondItem="QS5-Rx-YEW" secondAttribute="leading" id="X9o-k0-h62"/>
<constraint firstAttribute="centerX" secondItem="zEq-FU-wV5" secondAttribute="centerX" id="qqM-NS-xev"/>
<constraint firstAttribute="centerY" secondItem="zEq-FU-wV5" secondAttribute="centerY" id="qzY-Ky-pLD"/>
<constraint firstItem="d3m-k5-qah" firstAttribute="top" secondItem="QS5-Rx-YEW" secondAttribute="top" id="tA2-Eh-fSb"/>
<constraint firstItem="Djb-ko-YwX" firstAttribute="top" secondItem="d3m-k5-qah" secondAttribute="bottom" id="zws-Zn-RsZ"/>
</constraints>
</view>
<tabBarItem key="tabBarItem" title="Second" image="second" id="cPa-gy-q4n" customClass="AdaptiveTabBarItem" customModule="example_count_launches_adaptive_tabbar"/>
<tabBarItem key="tabBarItem" title="Second" image="second" id="cPa-gy-q4n" customClass="AdaptiveTabBarItem" customModule="adaptive_tab_bar" customModuleProvider="target"/>
</viewController>
<placeholder placeholderIdentifier="IBFirstResponder" id="4Nw-L8-lE0" sceneMemberID="firstResponder"/>
</objects>
@@ -102,7 +93,7 @@
<!--Tab Bar View Controller-->
<scene sceneID="yl2-sM-qoP">
<objects>
<tabBarController id="49e-Tb-3d3" customClass="TabBarViewController" customModule="example_date_adaptive_tab_bar" customModuleProvider="target" sceneMemberID="viewController">
<tabBarController id="49e-Tb-3d3" customClass="TabBarViewController" customModule="adaptive_tab_bar" customModuleProvider="target" sceneMemberID="viewController">
<nil key="simulatedBottomBarMetrics"/>
<tabBar key="tabBar" contentMode="scaleToFill" id="W28-zg-YXA">
<rect key="frame" x="0.0" y="975" width="768" height="49"/>
@@ -124,7 +115,7 @@
<!--Item-->
<scene sceneID="60i-zg-cAx">
<objects>
<viewController id="BiK-DX-JK5" customClass="UserViewController" customModule="example_date_adaptive_tab_bar" customModuleProvider="target" sceneMemberID="viewController">
<viewController id="BiK-DX-JK5" customClass="UserViewController" customModule="adaptive_tab_bar" customModuleProvider="target" sceneMemberID="viewController">
<layoutGuides>
<viewControllerLayoutGuide type="top" id="oSS-7K-rER"/>
<viewControllerLayoutGuide type="bottom" id="Ba7-rp-yUE"/>
@@ -133,19 +124,13 @@
<rect key="frame" x="0.0" y="0.0" width="600" height="600"/>
<autoresizingMask key="autoresizingMask" widthSizable="YES" heightSizable="YES"/>
<subviews>
<imageView userInteractionEnabled="NO" contentMode="scaleToFill" horizontalHuggingPriority="251" verticalHuggingPriority="251" image="background" translatesAutoresizingMaskIntoConstraints="NO" id="jtr-dW-8XE">
<imageView userInteractionEnabled="NO" contentMode="scaleToFill" horizontalHuggingPriority="251" verticalHuggingPriority="251" fixedFrame="YES" image="background" translatesAutoresizingMaskIntoConstraints="NO" id="jtr-dW-8XE">
<rect key="frame" x="0.0" y="0.0" width="640" height="555"/>
</imageView>
</subviews>
<color key="backgroundColor" white="1" alpha="1" colorSpace="calibratedWhite"/>
<constraints>
<constraint firstAttribute="trailing" secondItem="jtr-dW-8XE" secondAttribute="trailing" constant="-40" id="68Q-YE-GnZ"/>
<constraint firstItem="jtr-dW-8XE" firstAttribute="leading" secondItem="Z9a-At-6Ll" secondAttribute="leading" id="9Lc-1F-lVY"/>
<constraint firstAttribute="bottom" secondItem="jtr-dW-8XE" secondAttribute="bottom" constant="45" id="iHg-vq-ehR"/>
<constraint firstItem="jtr-dW-8XE" firstAttribute="top" secondItem="Z9a-At-6Ll" secondAttribute="top" id="zds-Uy-hOW"/>
</constraints>
</view>
<tabBarItem key="tabBarItem" title="Item" id="g86-Lf-lWF" customClass="AdaptiveTabBarItem" customModule="example_date_adaptive_tab_bar" customModuleProvider="target"/>
<tabBarItem key="tabBarItem" title="Item" id="g86-Lf-lWF" customClass="AdaptiveTabBarItem" customModule="adaptive_tab_bar" customModuleProvider="target"/>
</viewController>
<placeholder placeholderIdentifier="IBFirstResponder" id="Ds1-lP-WuT" userLabel="First Responder" sceneMemberID="firstResponder"/>
</objects>
@@ -154,7 +139,7 @@
<!--Item-->
<scene sceneID="RUI-wr-KlE">
<objects>
<viewController id="aXk-96-nwf" customClass="MenuViewController" customModule="example_date_adaptive_tab_bar" customModuleProvider="target" sceneMemberID="viewController">
<viewController id="aXk-96-nwf" customClass="MenuViewController" customModule="adaptive_tab_bar" customModuleProvider="target" sceneMemberID="viewController">
<layoutGuides>
<viewControllerLayoutGuide type="top" id="Aha-rh-ib6"/>
<viewControllerLayoutGuide type="bottom" id="aNR-L8-QaD"/>
@@ -163,20 +148,13 @@
<rect key="frame" x="0.0" y="0.0" width="600" height="600"/>
<autoresizingMask key="autoresizingMask" widthSizable="YES" heightSizable="YES"/>
<subviews>
<imageView userInteractionEnabled="NO" contentMode="scaleToFill" horizontalHuggingPriority="251" verticalHuggingPriority="251" image="background" translatesAutoresizingMaskIntoConstraints="NO" id="GGw-pn-6CX">
<rect key="frame" x="0.0" y="0.0" width="640" height="551"/>
<imageView userInteractionEnabled="NO" contentMode="scaleToFill" horizontalHuggingPriority="251" verticalHuggingPriority="251" fixedFrame="YES" image="background" translatesAutoresizingMaskIntoConstraints="NO" id="GGw-pn-6CX">
<rect key="frame" x="0.0" y="0.0" width="640" height="550"/>
</imageView>
</subviews>
<color key="backgroundColor" white="1" alpha="1" colorSpace="calibratedWhite"/>
<constraints>
<constraint firstItem="GGw-pn-6CX" firstAttribute="top" secondItem="UyR-nf-sp6" secondAttribute="topMargin" id="JNr-AP-tWr"/>
<constraint firstItem="GGw-pn-6CX" firstAttribute="top" secondItem="UyR-nf-sp6" secondAttribute="topMargin" id="MSj-7q-ac7"/>
<constraint firstItem="GGw-pn-6CX" firstAttribute="leading" secondItem="UyR-nf-sp6" secondAttribute="leading" id="SZF-JG-V57"/>
<constraint firstItem="aNR-L8-QaD" firstAttribute="top" secondItem="GGw-pn-6CX" secondAttribute="bottom" id="YDT-AA-Wjy"/>
<constraint firstItem="aNR-L8-QaD" firstAttribute="top" secondItem="GGw-pn-6CX" secondAttribute="bottom" id="nys-sX-kRN"/>
</constraints>
</view>
<tabBarItem key="tabBarItem" title="Item" id="RnB-fU-3RS" customClass="AdaptiveTabBarItem" customModule="example_date_adaptive_tab_bar" customModuleProvider="target"/>
<tabBarItem key="tabBarItem" title="Item" id="RnB-fU-3RS" customClass="AdaptiveTabBarItem" customModule="adaptive_tab_bar" customModuleProvider="target"/>
</viewController>
<placeholder placeholderIdentifier="IBFirstResponder" id="Hsc-p3-elF" userLabel="First Responder" sceneMemberID="firstResponder"/>
</objects>
@@ -185,7 +163,7 @@
<!--Item-->
<scene sceneID="B98-FR-Rjt">
<objects>
<viewController id="BgE-dr-gW8" customClass="MoreViewController" customModule="example_date_adaptive_tab_bar" customModuleProvider="target" sceneMemberID="viewController">
<viewController id="BgE-dr-gW8" customClass="MoreViewController" customModule="adaptive_tab_bar" customModuleProvider="target" sceneMemberID="viewController">
<layoutGuides>
<viewControllerLayoutGuide type="top" id="r9s-DG-v8Y"/>
<viewControllerLayoutGuide type="bottom" id="mju-qR-F4m"/>
@@ -194,19 +172,13 @@
<rect key="frame" x="0.0" y="0.0" width="600" height="600"/>
<autoresizingMask key="autoresizingMask" widthSizable="YES" heightSizable="YES"/>
<subviews>
<imageView userInteractionEnabled="NO" contentMode="scaleToFill" horizontalHuggingPriority="251" verticalHuggingPriority="251" image="background" translatesAutoresizingMaskIntoConstraints="NO" id="fel-JW-y8K">
<rect key="frame" x="16" y="0.0" width="568" height="551"/>
<imageView userInteractionEnabled="NO" contentMode="scaleToFill" horizontalHuggingPriority="251" verticalHuggingPriority="251" fixedFrame="YES" image="background" translatesAutoresizingMaskIntoConstraints="NO" id="fel-JW-y8K">
<rect key="frame" x="0.0" y="0.0" width="640" height="550"/>
</imageView>
</subviews>
<color key="backgroundColor" white="1" alpha="1" colorSpace="calibratedWhite"/>
<constraints>
<constraint firstItem="mju-qR-F4m" firstAttribute="top" secondItem="fel-JW-y8K" secondAttribute="bottom" id="czL-kW-Gi5"/>
<constraint firstItem="fel-JW-y8K" firstAttribute="top" secondItem="dgq-yB-Neb" secondAttribute="top" id="h6H-Nt-0EU"/>
<constraint firstItem="fel-JW-y8K" firstAttribute="leading" secondItem="dgq-yB-Neb" secondAttribute="leading" constant="16" id="lvq-kK-shl"/>
<constraint firstAttribute="trailing" secondItem="fel-JW-y8K" secondAttribute="trailing" constant="16" id="mnN-oR-w60"/>
</constraints>
</view>
<tabBarItem key="tabBarItem" title="Item" id="uWZ-JL-cND" customClass="AdaptiveTabBarItem" customModule="example_date_adaptive_tab_bar" customModuleProvider="target"/>
<tabBarItem key="tabBarItem" title="Item" id="uWZ-JL-cND" customClass="AdaptiveTabBarItem" customModule="adaptive_tab_bar" customModuleProvider="target"/>
</viewController>
<placeholder placeholderIdentifier="IBFirstResponder" id="xAq-zT-Wnn" userLabel="First Responder" sceneMemberID="firstResponder"/>
</objects>
@@ -9,19 +9,21 @@
import UIKit
import AdaptiveController
extension UITabBarItem : AdaptiveApperanceProtocol {
class AdaptiveTabBarItem: UITabBarItem , AdaptiveApperanceProtocol {
// override init(){
// super.init()
//
// }
override init(){
super.init()
}
func setFontToAdaptiveButton(font: UIFont){
self.setTitleTextAttributes(NSDictionary(objects: [font], forKeys: [NSFontAttributeName]), forState: UIControlState.Normal)
}
public func setTitleToAdaptiveButton(text: NSString){
func setTitleToAdaptiveButton(text: NSString){
self.title = text
}
@@ -29,41 +31,24 @@ extension UITabBarItem : AdaptiveApperanceProtocol {
self.image = image
}
public func setSelectedImageToAdaptiveButton(image: UIImage?){
func setSelectedImageToAdaptiveButton(image: UIImage?){
self.selectedImage = image
}
public func setImageInsetsToAdaptiveButton(insets: UIEdgeInsets){
func setImageInsetsToAdaptiveButton(insets: UIEdgeInsets){
self.imageInsets = insets
}
public func setTitleOffsetToAdaptiveButton(offset: UIOffset){
func setTitleOffsetToAdaptiveButton(offset: UIOffset){
self.setTitlePositionAdjustment(offset)
}
// public func setTitleColorToAdaptiveButton(color: UIColor){
// var dictionary = self.titleTextAttributesForState(UIControlState.Normal)
// dictionary.updateValue(color, forKey: NSForegroundColorAttributeName)
// self.setTitleTextAttributes(dictionary, forState: UIControlState.Normal)
// }
//
// public func setFontToAdaptiveButton(font: UIFont){
//
// self.setTitleTextAttributes(NSDictionary(objects: [font], forKeys: [NSFontAttributeName]), forState: UIControlState.Normal)
//
// }
//
public func setFontToAdaptiveButton(font: UIFont , controlState:UIControlState){
self.setTitleTextAttributes(NSDictionary(objects: [font], forKeys: [NSFontAttributeName]), forState: controlState)
}
public func setTitleColorToAdaptiveButton(color: UIColor, controlState:UIControlState){
var dictionary = self.titleTextAttributesForState(controlState)
func setTitleColorToAdaptiveButton(color: UIColor){
var dictionary = self.titleTextAttributesForState(UIControlState.Normal)
dictionary.updateValue(color, forKey: NSForegroundColorAttributeName)
self.setTitleTextAttributes(dictionary, forState: controlState)
self.setTitleTextAttributes(dictionary, forState: UIControlState.Normal)
}
}
@@ -9,8 +9,9 @@
import UIKit
extension NSDate{
convenience
convenience init(dateString:String) {
init(dateString:String) {
let dateStringFormatter = NSDateFormatter()
dateStringFormatter.dateFormat = "yyyy-MM-dd"
dateStringFormatter.locale = NSLocale(localeIdentifier: "en_US_POSIX")
@@ -1,871 +0,0 @@
<?xml version="1.0" encoding="UTF-8"?>
<!DOCTYPE plist PUBLIC "-//Apple//DTD PLIST 1.0//EN" "http://www.apple.com/DTDs/PropertyList-1.0.dtd">
<plist version="1.0">
<array>
<dict>
<key>kDefaultAdaptiveState</key>
<dict>
<key>UIControlStateNormal</key>
<dict>
<key>backgroundColor</key>
<dict>
<key>alpha</key>
<real>0</real>
<key>blue</key>
<real>0</real>
<key>green</key>
<real>0</real>
<key>red</key>
<real>0</real>
</dict>
<key>color</key>
<dict>
<key>alpha</key>
<real>1</real>
<key>blue</key>
<real>1</real>
<key>green</key>
<real>1</real>
<key>red</key>
<real>1</real>
</dict>
<key>font</key>
<dict>
<key>fontName</key>
<string>Helvetica</string>
<key>fontSize</key>
<real>14</real>
</dict>
<key>imageInsets</key>
<dict>
<key>bottom</key>
<real>0</real>
<key>left</key>
<real>0</real>
<key>right</key>
<real>0</real>
<key>top</key>
<real>0</real>
</dict>
<key>imageName</key>
<string>watch</string>
<key>title</key>
<string>watch</string>
<key>titleOffset</key>
<dict>
<key>horizontal</key>
<real>0</real>
<key>vertical</key>
<real>0</real>
</dict>
</dict>
</dict>
<key>kImageAdaptiveState</key>
<dict>
<key>UIControlStateNormal</key>
<dict>
<key>backgroundColor</key>
<dict>
<key>alpha</key>
<real>0</real>
<key>blue</key>
<real>0</real>
<key>green</key>
<real>0</real>
<key>red</key>
<real>0</real>
</dict>
<key>color</key>
<dict>
<key>alpha</key>
<real>1</real>
<key>blue</key>
<real>0</real>
<key>green</key>
<real>0</real>
<key>red</key>
<real>0</real>
</dict>
<key>font</key>
<dict>
<key>fontName</key>
<string>Helvetica</string>
<key>fontSize</key>
<real>14</real>
</dict>
<key>imageInsets</key>
<dict>
<key>bottom</key>
<real>-6</real>
<key>left</key>
<real>0</real>
<key>right</key>
<real>0</real>
<key>top</key>
<real>6</real>
</dict>
<key>imageName</key>
<string>watch_bigimage</string>
<key>title</key>
<string></string>
<key>titleOffset</key>
<dict>
<key>horizontal</key>
<real>0</real>
<key>vertical</key>
<real>0</real>
</dict>
</dict>
</dict>
<key>kSmallTitleAdaptiveState</key>
<dict>
<key>UIControlStateNormal</key>
<dict>
<key>backgroundColor</key>
<dict>
<key>alpha</key>
<real>0</real>
<key>blue</key>
<real>0</real>
<key>green</key>
<real>0</real>
<key>red</key>
<real>0</real>
</dict>
<key>color</key>
<dict>
<key>alpha</key>
<real>1</real>
<key>blue</key>
<real>1</real>
<key>green</key>
<real>1</real>
<key>red</key>
<real>1</real>
</dict>
<key>font</key>
<dict>
<key>fontName</key>
<string>Helvetica</string>
<key>fontSize</key>
<real>10</real>
</dict>
<key>imageInsets</key>
<dict>
<key>bottom</key>
<real>0</real>
<key>left</key>
<real>0</real>
<key>right</key>
<real>0</real>
<key>top</key>
<real>0</real>
</dict>
<key>imageName</key>
<string>watch_smalltitle</string>
<key>title</key>
<string>watch</string>
<key>titleOffset</key>
<dict>
<key>horizontal</key>
<real>0</real>
<key>vertical</key>
<real>0</real>
</dict>
</dict>
</dict>
</dict>
<dict>
<key>kDefaultAdaptiveState</key>
<dict>
<key>UIControlStateNormal</key>
<dict>
<key>backgroundColor</key>
<dict>
<key>alpha</key>
<real>0</real>
<key>blue</key>
<real>0</real>
<key>green</key>
<real>0</real>
<key>red</key>
<real>0</real>
</dict>
<key>color</key>
<dict>
<key>alpha</key>
<real>1</real>
<key>blue</key>
<real>1</real>
<key>green</key>
<real>1</real>
<key>red</key>
<real>1</real>
</dict>
<key>font</key>
<dict>
<key>fontName</key>
<string>Helvetica</string>
<key>fontSize</key>
<real>14</real>
</dict>
<key>imageInsets</key>
<dict>
<key>bottom</key>
<real>0</real>
<key>left</key>
<real>0</real>
<key>right</key>
<real>0</real>
<key>top</key>
<real>0</real>
</dict>
<key>imageName</key>
<string>messages</string>
<key>title</key>
<string>message</string>
<key>titleOffset</key>
<dict>
<key>horizontal</key>
<real>0</real>
<key>vertical</key>
<real>0</real>
</dict>
</dict>
</dict>
<key>kImageAdaptiveState</key>
<dict>
<key>UIControlStateNormal</key>
<dict>
<key>backgroundColor</key>
<dict>
<key>alpha</key>
<real>0</real>
<key>blue</key>
<real>0</real>
<key>green</key>
<real>0</real>
<key>red</key>
<real>0</real>
</dict>
<key>color</key>
<dict>
<key>alpha</key>
<real>1</real>
<key>blue</key>
<real>0</real>
<key>green</key>
<real>0</real>
<key>red</key>
<real>0</real>
</dict>
<key>font</key>
<dict>
<key>fontName</key>
<string>Helvetica</string>
<key>fontSize</key>
<real>14</real>
</dict>
<key>imageInsets</key>
<dict>
<key>bottom</key>
<real>-6</real>
<key>left</key>
<real>0</real>
<key>right</key>
<real>0</real>
<key>top</key>
<real>6</real>
</dict>
<key>imageName</key>
<string>messages_bigimage</string>
<key>title</key>
<string></string>
<key>titleOffset</key>
<dict>
<key>horizontal</key>
<real>0</real>
<key>vertical</key>
<real>0</real>
</dict>
</dict>
</dict>
<key>kSmallTitleAdaptiveState</key>
<dict>
<key>UIControlStateNormal</key>
<dict>
<key>backgroundColor</key>
<dict>
<key>alpha</key>
<real>0</real>
<key>blue</key>
<real>0</real>
<key>green</key>
<real>0</real>
<key>red</key>
<real>0</real>
</dict>
<key>color</key>
<dict>
<key>alpha</key>
<real>1</real>
<key>blue</key>
<real>1</real>
<key>green</key>
<real>1</real>
<key>red</key>
<real>1</real>
</dict>
<key>font</key>
<dict>
<key>fontName</key>
<string>Helvetica</string>
<key>fontSize</key>
<real>10</real>
</dict>
<key>imageInsets</key>
<dict>
<key>bottom</key>
<real>0</real>
<key>left</key>
<real>0</real>
<key>right</key>
<real>0</real>
<key>top</key>
<real>0</real>
</dict>
<key>imageName</key>
<string>messages_smalltitle</string>
<key>title</key>
<string>message</string>
<key>titleOffset</key>
<dict>
<key>horizontal</key>
<real>0</real>
<key>vertical</key>
<real>0</real>
</dict>
</dict>
</dict>
</dict>
<dict>
<key>kDefaultAdaptiveState</key>
<dict>
<key>UIControlStateNormal</key>
<dict>
<key>backgroundColor</key>
<dict>
<key>alpha</key>
<real>0</real>
<key>blue</key>
<real>0</real>
<key>green</key>
<real>0</real>
<key>red</key>
<real>0</real>
</dict>
<key>color</key>
<dict>
<key>alpha</key>
<real>1</real>
<key>blue</key>
<real>1</real>
<key>green</key>
<real>1</real>
<key>red</key>
<real>1</real>
</dict>
<key>font</key>
<dict>
<key>fontName</key>
<string>Helvetica</string>
<key>fontSize</key>
<real>14</real>
</dict>
<key>imageInsets</key>
<dict>
<key>bottom</key>
<real>0</real>
<key>left</key>
<real>0</real>
<key>right</key>
<real>0</real>
<key>top</key>
<real>0</real>
</dict>
<key>imageName</key>
<string>man</string>
<key>title</key>
<string>user</string>
<key>titleOffset</key>
<dict>
<key>horizontal</key>
<real>0</real>
<key>vertical</key>
<real>0</real>
</dict>
</dict>
</dict>
<key>kImageAdaptiveState</key>
<dict>
<key>UIControlStateNormal</key>
<dict>
<key>backgroundColor</key>
<dict>
<key>alpha</key>
<real>0</real>
<key>blue</key>
<real>0</real>
<key>green</key>
<real>0</real>
<key>red</key>
<real>0</real>
</dict>
<key>color</key>
<dict>
<key>alpha</key>
<real>1</real>
<key>blue</key>
<real>0</real>
<key>green</key>
<real>0</real>
<key>red</key>
<real>0</real>
</dict>
<key>font</key>
<dict>
<key>fontName</key>
<string>Helvetica</string>
<key>fontSize</key>
<real>14</real>
</dict>
<key>imageInsets</key>
<dict>
<key>bottom</key>
<real>-6</real>
<key>left</key>
<real>0</real>
<key>right</key>
<real>0</real>
<key>top</key>
<real>6</real>
</dict>
<key>imageName</key>
<string>man_bigimage</string>
<key>title</key>
<string></string>
<key>titleOffset</key>
<dict>
<key>horizontal</key>
<real>0</real>
<key>vertical</key>
<real>0</real>
</dict>
</dict>
</dict>
<key>kSmallTitleAdaptiveState</key>
<dict>
<key>UIControlStateNormal</key>
<dict>
<key>backgroundColor</key>
<dict>
<key>alpha</key>
<real>0</real>
<key>blue</key>
<real>0</real>
<key>green</key>
<real>0</real>
<key>red</key>
<real>0</real>
</dict>
<key>color</key>
<dict>
<key>alpha</key>
<real>1</real>
<key>blue</key>
<real>1</real>
<key>green</key>
<real>1</real>
<key>red</key>
<real>1</real>
</dict>
<key>font</key>
<dict>
<key>fontName</key>
<string>Helvetica</string>
<key>fontSize</key>
<real>10</real>
</dict>
<key>imageInsets</key>
<dict>
<key>bottom</key>
<real>0</real>
<key>left</key>
<real>0</real>
<key>right</key>
<real>0</real>
<key>top</key>
<real>0</real>
</dict>
<key>imageName</key>
<string>man_smalltitle</string>
<key>title</key>
<string>user</string>
<key>titleOffset</key>
<dict>
<key>horizontal</key>
<real>0</real>
<key>vertical</key>
<real>0</real>
</dict>
</dict>
</dict>
</dict>
<dict>
<key>kDefaultAdaptiveState</key>
<dict>
<key>UIControlStateNormal</key>
<dict>
<key>backgroundColor</key>
<dict>
<key>alpha</key>
<real>0</real>
<key>blue</key>
<real>0</real>
<key>green</key>
<real>0</real>
<key>red</key>
<real>0</real>
</dict>
<key>color</key>
<dict>
<key>alpha</key>
<real>1</real>
<key>blue</key>
<real>1</real>
<key>green</key>
<real>1</real>
<key>red</key>
<real>1</real>
</dict>
<key>font</key>
<dict>
<key>fontName</key>
<string>Helvetica</string>
<key>fontSize</key>
<real>14</real>
</dict>
<key>imageInsets</key>
<dict>
<key>bottom</key>
<real>0</real>
<key>left</key>
<real>0</real>
<key>right</key>
<real>0</real>
<key>top</key>
<real>0</real>
</dict>
<key>imageName</key>
<string>menu</string>
<key>title</key>
<string>dial</string>
<key>titleOffset</key>
<dict>
<key>horizontal</key>
<real>0</real>
<key>vertical</key>
<real>0</real>
</dict>
</dict>
</dict>
<key>kImageAdaptiveState</key>
<dict>
<key>UIControlStateNormal</key>
<dict>
<key>backgroundColor</key>
<dict>
<key>alpha</key>
<real>0</real>
<key>blue</key>
<real>0</real>
<key>green</key>
<real>0</real>
<key>red</key>
<real>0</real>
</dict>
<key>color</key>
<dict>
<key>alpha</key>
<real>1</real>
<key>blue</key>
<real>0</real>
<key>green</key>
<real>0</real>
<key>red</key>
<real>0</real>
</dict>
<key>font</key>
<dict>
<key>fontName</key>
<string>Helvetica</string>
<key>fontSize</key>
<real>14</real>
</dict>
<key>imageInsets</key>
<dict>
<key>bottom</key>
<real>-6</real>
<key>left</key>
<real>0</real>
<key>right</key>
<real>0</real>
<key>top</key>
<real>6</real>
</dict>
<key>imageName</key>
<string>menu_bigimage</string>
<key>title</key>
<string></string>
<key>titleOffset</key>
<dict>
<key>horizontal</key>
<real>0</real>
<key>vertical</key>
<real>0</real>
</dict>
</dict>
</dict>
<key>kSmallTitleAdaptiveState</key>
<dict>
<key>UIControlStateNormal</key>
<dict>
<key>backgroundColor</key>
<dict>
<key>alpha</key>
<real>0</real>
<key>blue</key>
<real>0</real>
<key>green</key>
<real>0</real>
<key>red</key>
<real>0</real>
</dict>
<key>color</key>
<dict>
<key>alpha</key>
<real>1</real>
<key>blue</key>
<real>1</real>
<key>green</key>
<real>1</real>
<key>red</key>
<real>1</real>
</dict>
<key>font</key>
<dict>
<key>fontName</key>
<string>Helvetica</string>
<key>fontSize</key>
<real>10</real>
</dict>
<key>imageInsets</key>
<dict>
<key>bottom</key>
<real>0</real>
<key>left</key>
<real>0</real>
<key>right</key>
<real>0</real>
<key>top</key>
<real>0</real>
</dict>
<key>imageName</key>
<string>menu_smalltitle</string>
<key>title</key>
<string>dial</string>
<key>titleOffset</key>
<dict>
<key>horizontal</key>
<real>0</real>
<key>vertical</key>
<real>0</real>
</dict>
</dict>
</dict>
</dict>
<dict>
<key>kDefaultAdaptiveState</key>
<dict>
<key>UIControlStateNormal</key>
<dict>
<key>backgroundColor</key>
<dict>
<key>alpha</key>
<real>0</real>
<key>blue</key>
<real>0</real>
<key>green</key>
<real>0</real>
<key>red</key>
<real>0</real>
</dict>
<key>color</key>
<dict>
<key>alpha</key>
<real>1</real>
<key>blue</key>
<real>1</real>
<key>green</key>
<real>1</real>
<key>red</key>
<real>1</real>
</dict>
<key>font</key>
<dict>
<key>fontName</key>
<string>Helvetica</string>
<key>fontSize</key>
<real>14</real>
</dict>
<key>imageInsets</key>
<dict>
<key>bottom</key>
<real>0</real>
<key>left</key>
<real>0</real>
<key>right</key>
<real>0</real>
<key>top</key>
<real>0</real>
</dict>
<key>imageName</key>
<string>more</string>
<key>title</key>
<string>more</string>
<key>titleOffset</key>
<dict>
<key>horizontal</key>
<real>0</real>
<key>vertical</key>
<real>0</real>
</dict>
</dict>
</dict>
<key>kImageAdaptiveState</key>
<dict>
<key>UIControlStateNormal</key>
<dict>
<key>backgroundColor</key>
<dict>
<key>alpha</key>
<real>0</real>
<key>blue</key>
<real>0</real>
<key>green</key>
<real>0</real>
<key>red</key>
<real>0</real>
</dict>
<key>color</key>
<dict>
<key>alpha</key>
<real>1</real>
<key>blue</key>
<real>0</real>
<key>green</key>
<real>0</real>
<key>red</key>
<real>0</real>
</dict>
<key>font</key>
<dict>
<key>fontName</key>
<string>Helvetica</string>
<key>fontSize</key>
<real>14</real>
</dict>
<key>imageInsets</key>
<dict>
<key>bottom</key>
<real>-6</real>
<key>left</key>
<real>0</real>
<key>right</key>
<real>0</real>
<key>top</key>
<real>6</real>
</dict>
<key>imageName</key>
<string>more_bigimage</string>
<key>title</key>
<string></string>
<key>titleOffset</key>
<dict>
<key>horizontal</key>
<real>0</real>
<key>vertical</key>
<real>0</real>
</dict>
</dict>
</dict>
<key>kSmallTitleAdaptiveState</key>
<dict>
<key>UIControlStateNormal</key>
<dict>
<key>backgroundColor</key>
<dict>
<key>alpha</key>
<real>0</real>
<key>blue</key>
<real>0</real>
<key>green</key>
<real>0</real>
<key>red</key>
<real>0</real>
</dict>
<key>color</key>
<dict>
<key>alpha</key>
<real>1</real>
<key>blue</key>
<real>1</real>
<key>green</key>
<real>1</real>
<key>red</key>
<real>1</real>
</dict>
<key>font</key>
<dict>
<key>fontName</key>
<string>Helvetica</string>
<key>fontSize</key>
<real>10</real>
</dict>
<key>imageInsets</key>
<dict>
<key>bottom</key>
<real>0</real>
<key>left</key>
<real>0</real>
<key>right</key>
<real>0</real>
<key>top</key>
<real>0</real>
</dict>
<key>imageName</key>
<string>more_smalltitle</string>
<key>title</key>
<string>more</string>
<key>titleOffset</key>
<dict>
<key>horizontal</key>
<real>0</real>
<key>vertical</key>
<real>0</real>
</dict>
</dict>
</dict>
</dict>
</array>
</plist>
@@ -1,901 +0,0 @@
<?xml version="1.0" encoding="UTF-8"?>
<!DOCTYPE plist PUBLIC "-//Apple//DTD PLIST 1.0//EN" "http://www.apple.com/DTDs/PropertyList-1.0.dtd">
<plist version="1.0">
<array>
<dict>
<key>DefaultAdaptiveState</key>
<dict>
<key>UIControlState.Normal</key>
<dict>
<key>backgroundColorKey</key>
<dict>
<key>alphaColor</key>
<real>0</real>
<key>blueColor</key>
<real>0</real>
<key>greenColor</key>
<real>0</real>
<key>redColor</key>
<real>0</real>
</dict>
<key>backgroundImageNameKey</key>
<string></string>
<key>colorKey</key>
<dict>
<key>alphaColor</key>
<real>1</real>
<key>blueColor</key>
<real>1</real>
<key>greenColor</key>
<real>1</real>
<key>redColor</key>
<real>1</real>
</dict>
<key>fontKey</key>
<dict>
<key>fontNameKey</key>
<string>Helvetica</string>
<key>fontSizeKey</key>
<real>14</real>
</dict>
<key>imageInsetsKey</key>
<dict>
<key>bottomKey</key>
<real>0</real>
<key>leftKey</key>
<real>0</real>
<key>rightKey</key>
<real>0</real>
<key>topKey</key>
<real>0</real>
</dict>
<key>imageNameKey</key>
<string>watch</string>
<key>title</key>
<string>watch</string>
<key>titleOffsetKey</key>
<dict>
<key>xKey</key>
<real>0</real>
<key>yKey</key>
<real>0</real>
</dict>
</dict>
</dict>
<key>kImageAdaptiveState</key>
<dict>
<key>UIControlState.Normal</key>
<dict>
<key>backgroundColorKey</key>
<dict>
<key>alphaColor</key>
<real>0</real>
<key>blueColor</key>
<real>0</real>
<key>greenColor</key>
<real>0</real>
<key>redColor</key>
<real>0</real>
</dict>
<key>backgroundImageNameKey</key>
<string></string>
<key>colorKey</key>
<dict>
<key>alphaColor</key>
<real>1</real>
<key>blueColor</key>
<real>0</real>
<key>greenColor</key>
<real>0</real>
<key>redColor</key>
<real>0</real>
</dict>
<key>fontKey</key>
<dict>
<key>fontNameKey</key>
<string>Helvetica</string>
<key>fontSizeKey</key>
<real>14</real>
</dict>
<key>imageInsetsKey</key>
<dict>
<key>bottomKey</key>
<integer>-6</integer>
<key>leftKey</key>
<integer>0</integer>
<key>rightKey</key>
<integer>0</integer>
<key>topKey</key>
<integer>6</integer>
</dict>
<key>imageNameKey</key>
<string>watch_bigimage</string>
<key>title</key>
<string></string>
<key>titleOffsetKey</key>
<dict>
<key>xKey</key>
<real>0</real>
<key>yKey</key>
<real>0</real>
</dict>
</dict>
</dict>
<key>kSmallTitleAdaptiveState</key>
<dict>
<key>UIControlState.Normal</key>
<dict>
<key>backgroundColorKey</key>
<dict>
<key>alphaColor</key>
<real>0</real>
<key>blueColor</key>
<real>0</real>
<key>greenColor</key>
<real>0</real>
<key>redColor</key>
<real>0</real>
</dict>
<key>backgroundImageNameKey</key>
<string></string>
<key>colorKey</key>
<dict>
<key>alphaColor</key>
<real>1</real>
<key>blueColor</key>
<real>1</real>
<key>greenColor</key>
<real>1</real>
<key>redColor</key>
<real>1</real>
</dict>
<key>fontKey</key>
<dict>
<key>fontNameKey</key>
<string>Helvetica</string>
<key>fontSizeKey</key>
<real>10</real>
</dict>
<key>imageInsetsKey</key>
<dict>
<key>bottomKey</key>
<real>0</real>
<key>leftKey</key>
<real>0</real>
<key>rightKey</key>
<real>0</real>
<key>topKey</key>
<real>0</real>
</dict>
<key>imageNameKey</key>
<string>watch_smalltitle</string>
<key>title</key>
<string>watch</string>
<key>titleOffsetKey</key>
<dict>
<key>xKey</key>
<real>0</real>
<key>yKey</key>
<real>0</real>
</dict>
</dict>
</dict>
</dict>
<dict>
<key>DefaultAdaptiveState</key>
<dict>
<key>UIControlState.Normal</key>
<dict>
<key>backgroundColorKey</key>
<dict>
<key>alphaColor</key>
<real>0</real>
<key>blueColor</key>
<real>0</real>
<key>greenColor</key>
<real>0</real>
<key>redColor</key>
<real>0</real>
</dict>
<key>backgroundImageNameKey</key>
<string></string>
<key>colorKey</key>
<dict>
<key>alphaColor</key>
<real>1</real>
<key>blueColor</key>
<real>1</real>
<key>greenColor</key>
<real>1</real>
<key>redColor</key>
<real>1</real>
</dict>
<key>fontKey</key>
<dict>
<key>fontNameKey</key>
<string>Helvetica</string>
<key>fontSizeKey</key>
<real>14</real>
</dict>
<key>imageInsetsKey</key>
<dict>
<key>bottomKey</key>
<real>0</real>
<key>leftKey</key>
<real>0</real>
<key>rightKey</key>
<real>0</real>
<key>topKey</key>
<real>0</real>
</dict>
<key>imageNameKey</key>
<string>messages</string>
<key>title</key>
<string>message</string>
<key>titleOffsetKey</key>
<dict>
<key>xKey</key>
<real>0</real>
<key>yKey</key>
<real>0</real>
</dict>
</dict>
</dict>
<key>kImageAdaptiveState</key>
<dict>
<key>UIControlState.Normal</key>
<dict>
<key>backgroundColorKey</key>
<dict>
<key>alphaColor</key>
<real>0</real>
<key>blueColor</key>
<real>0</real>
<key>greenColor</key>
<real>0</real>
<key>redColor</key>
<real>0</real>
</dict>
<key>backgroundImageNameKey</key>
<string></string>
<key>colorKey</key>
<dict>
<key>alphaColor</key>
<real>1</real>
<key>blueColor</key>
<real>0</real>
<key>greenColor</key>
<real>0</real>
<key>redColor</key>
<real>0</real>
</dict>
<key>fontKey</key>
<dict>
<key>fontNameKey</key>
<string>Helvetica</string>
<key>fontSizeKey</key>
<real>14</real>
</dict>
<key>imageInsetsKey</key>
<dict>
<key>bottomKey</key>
<real>-6</real>
<key>leftKey</key>
<real>0</real>
<key>rightKey</key>
<integer>0</integer>
<key>topKey</key>
<real>6</real>
</dict>
<key>imageNameKey</key>
<string>messages_bigimage</string>
<key>title</key>
<string></string>
<key>titleOffsetKey</key>
<dict>
<key>xKey</key>
<real>0</real>
<key>yKey</key>
<real>0</real>
</dict>
</dict>
</dict>
<key>kSmallTitleAdaptiveState</key>
<dict>
<key>UIControlState.Normal</key>
<dict>
<key>backgroundColorKey</key>
<dict>
<key>alphaColor</key>
<real>0</real>
<key>blueColor</key>
<real>0</real>
<key>greenColor</key>
<real>0</real>
<key>redColor</key>
<real>0</real>
</dict>
<key>backgroundImageNameKey</key>
<string></string>
<key>colorKey</key>
<dict>
<key>alphaColor</key>
<real>1</real>
<key>blueColor</key>
<real>1</real>
<key>greenColor</key>
<real>1</real>
<key>redColor</key>
<real>1</real>
</dict>
<key>fontKey</key>
<dict>
<key>fontNameKey</key>
<string>Helvetica</string>
<key>fontSizeKey</key>
<real>10</real>
</dict>
<key>imageInsetsKey</key>
<dict>
<key>bottomKey</key>
<real>0</real>
<key>leftKey</key>
<real>0</real>
<key>rightKey</key>
<real>0</real>
<key>topKey</key>
<real>0</real>
</dict>
<key>imageNameKey</key>
<string>messages_smalltitle</string>
<key>title</key>
<string>message</string>
<key>titleOffsetKey</key>
<dict>
<key>xKey</key>
<real>0</real>
<key>yKey</key>
<real>0</real>
</dict>
</dict>
</dict>
</dict>
<dict>
<key>DefaultAdaptiveState</key>
<dict>
<key>UIControlState.Normal</key>
<dict>
<key>backgroundColorKey</key>
<dict>
<key>alphaColor</key>
<real>0</real>
<key>blueColor</key>
<real>0</real>
<key>greenColor</key>
<real>0</real>
<key>redColor</key>
<real>0</real>
</dict>
<key>backgroundImageNameKey</key>
<string></string>
<key>colorKey</key>
<dict>
<key>alphaColor</key>
<real>1</real>
<key>blueColor</key>
<real>1</real>
<key>greenColor</key>
<real>1</real>
<key>redColor</key>
<real>1</real>
</dict>
<key>fontKey</key>
<dict>
<key>fontNameKey</key>
<string>Helvetica</string>
<key>fontSizeKey</key>
<real>14</real>
</dict>
<key>imageInsetsKey</key>
<dict>
<key>bottomKey</key>
<real>0</real>
<key>leftKey</key>
<real>0</real>
<key>rightKey</key>
<real>0</real>
<key>topKey</key>
<real>0</real>
</dict>
<key>imageNameKey</key>
<string>man</string>
<key>title</key>
<string>user</string>
<key>titleOffsetKey</key>
<dict>
<key>xKey</key>
<real>0</real>
<key>yKey</key>
<real>0</real>
</dict>
</dict>
</dict>
<key>kImageAdaptiveState</key>
<dict>
<key>UIControlState.Normal</key>
<dict>
<key>backgroundColorKey</key>
<dict>
<key>alphaColor</key>
<real>0</real>
<key>blueColor</key>
<real>0</real>
<key>greenColor</key>
<real>0</real>
<key>redColor</key>
<real>0</real>
</dict>
<key>backgroundImageNameKey</key>
<string></string>
<key>colorKey</key>
<dict>
<key>alphaColor</key>
<real>1</real>
<key>blueColor</key>
<real>0</real>
<key>greenColor</key>
<real>0</real>
<key>redColor</key>
<real>0</real>
</dict>
<key>fontKey</key>
<dict>
<key>fontNameKey</key>
<string>Helvetica</string>
<key>fontSizeKey</key>
<real>14</real>
</dict>
<key>imageInsetsKey</key>
<dict>
<key>bottomKey</key>
<real>-6</real>
<key>leftKey</key>
<real>0</real>
<key>rightKey</key>
<integer>0</integer>
<key>topKey</key>
<real>6</real>
</dict>
<key>imageNameKey</key>
<string>man_bigimage</string>
<key>title</key>
<string></string>
<key>titleOffsetKey</key>
<dict>
<key>xKey</key>
<real>0</real>
<key>yKey</key>
<real>0</real>
</dict>
</dict>
</dict>
<key>kSmallTitleAdaptiveState</key>
<dict>
<key>UIControlState.Normal</key>
<dict>
<key>backgroundColorKey</key>
<dict>
<key>alphaColor</key>
<real>0</real>
<key>blueColor</key>
<real>0</real>
<key>greenColor</key>
<real>0</real>
<key>redColor</key>
<real>0</real>
</dict>
<key>backgroundImageNameKey</key>
<string></string>
<key>colorKey</key>
<dict>
<key>alphaColor</key>
<real>1</real>
<key>blueColor</key>
<real>1</real>
<key>greenColor</key>
<real>1</real>
<key>redColor</key>
<real>1</real>
</dict>
<key>fontKey</key>
<dict>
<key>fontNameKey</key>
<string>Helvetica</string>
<key>fontSizeKey</key>
<real>10</real>
</dict>
<key>imageInsetsKey</key>
<dict>
<key>bottomKey</key>
<real>0</real>
<key>leftKey</key>
<real>0</real>
<key>rightKey</key>
<real>0</real>
<key>topKey</key>
<real>0</real>
</dict>
<key>imageNameKey</key>
<string>man_smalltitle</string>
<key>title</key>
<string>user</string>
<key>titleOffsetKey</key>
<dict>
<key>xKey</key>
<real>0</real>
<key>yKey</key>
<real>0</real>
</dict>
</dict>
</dict>
</dict>
<dict>
<key>DefaultAdaptiveState</key>
<dict>
<key>UIControlState.Normal</key>
<dict>
<key>backgroundColorKey</key>
<dict>
<key>alphaColor</key>
<real>0</real>
<key>blueColor</key>
<real>0</real>
<key>greenColor</key>
<real>0</real>
<key>redColor</key>
<real>0</real>
</dict>
<key>backgroundImageNameKey</key>
<string></string>
<key>colorKey</key>
<dict>
<key>alphaColor</key>
<real>1</real>
<key>blueColor</key>
<real>1</real>
<key>greenColor</key>
<real>1</real>
<key>redColor</key>
<real>1</real>
</dict>
<key>fontKey</key>
<dict>
<key>fontNameKey</key>
<string>Helvetica</string>
<key>fontSizeKey</key>
<real>14</real>
</dict>
<key>imageInsetsKey</key>
<dict>
<key>bottomKey</key>
<real>0</real>
<key>leftKey</key>
<real>0</real>
<key>rightKey</key>
<real>0</real>
<key>topKey</key>
<real>0</real>
</dict>
<key>imageNameKey</key>
<string>menu</string>
<key>title</key>
<string>dial</string>
<key>titleOffsetKey</key>
<dict>
<key>xKey</key>
<real>0</real>
<key>yKey</key>
<real>0</real>
</dict>
</dict>
</dict>
<key>kImageAdaptiveState</key>
<dict>
<key>UIControlState.Normal</key>
<dict>
<key>backgroundColorKey</key>
<dict>
<key>alphaColor</key>
<real>0</real>
<key>blueColor</key>
<real>0</real>
<key>greenColor</key>
<real>0</real>
<key>redColor</key>
<real>0</real>
</dict>
<key>backgroundImageNameKey</key>
<string></string>
<key>colorKey</key>
<dict>
<key>alphaColor</key>
<real>1</real>
<key>blueColor</key>
<real>0</real>
<key>greenColor</key>
<real>0</real>
<key>redColor</key>
<real>0</real>
</dict>
<key>fontKey</key>
<dict>
<key>fontNameKey</key>
<string>Helvetica</string>
<key>fontSizeKey</key>
<real>14</real>
</dict>
<key>imageInsetsKey</key>
<dict>
<key>bottomKey</key>
<real>-6</real>
<key>leftKey</key>
<real>0</real>
<key>rightKey</key>
<integer>0</integer>
<key>topKey</key>
<integer>6</integer>
</dict>
<key>imageNameKey</key>
<string>menu_bigimage</string>
<key>title</key>
<string></string>
<key>titleOffsetKey</key>
<dict>
<key>xKey</key>
<real>0</real>
<key>yKey</key>
<real>0</real>
</dict>
</dict>
</dict>
<key>kSmallTitleAdaptiveState</key>
<dict>
<key>UIControlState.Normal</key>
<dict>
<key>backgroundColorKey</key>
<dict>
<key>alphaColor</key>
<real>0</real>
<key>blueColor</key>
<real>0</real>
<key>greenColor</key>
<real>0</real>
<key>redColor</key>
<real>0</real>
</dict>
<key>backgroundImageNameKey</key>
<string></string>
<key>colorKey</key>
<dict>
<key>alphaColor</key>
<real>1</real>
<key>blueColor</key>
<real>1</real>
<key>greenColor</key>
<real>1</real>
<key>redColor</key>
<real>1</real>
</dict>
<key>fontKey</key>
<dict>
<key>fontNameKey</key>
<string>Helvetica</string>
<key>fontSizeKey</key>
<real>10</real>
</dict>
<key>imageInsetsKey</key>
<dict>
<key>bottomKey</key>
<real>0</real>
<key>leftKey</key>
<real>0</real>
<key>rightKey</key>
<real>0</real>
<key>topKey</key>
<real>0</real>
</dict>
<key>imageNameKey</key>
<string>menu_smalltitle</string>
<key>title</key>
<string>dial</string>
<key>titleOffsetKey</key>
<dict>
<key>xKey</key>
<real>0</real>
<key>yKey</key>
<real>0</real>
</dict>
</dict>
</dict>
</dict>
<dict>
<key>DefaultAdaptiveState</key>
<dict>
<key>UIControlState.Normal</key>
<dict>
<key>backgroundColorKey</key>
<dict>
<key>alphaColor</key>
<real>0</real>
<key>blueColor</key>
<real>0</real>
<key>greenColor</key>
<real>0</real>
<key>redColor</key>
<real>0</real>
</dict>
<key>backgroundImageNameKey</key>
<string></string>
<key>colorKey</key>
<dict>
<key>alphaColor</key>
<real>1</real>
<key>blueColor</key>
<real>1</real>
<key>greenColor</key>
<real>1</real>
<key>redColor</key>
<real>1</real>
</dict>
<key>fontKey</key>
<dict>
<key>fontNameKey</key>
<string>Helvetica</string>
<key>fontSizeKey</key>
<real>14</real>
</dict>
<key>imageInsetsKey</key>
<dict>
<key>bottomKey</key>
<real>0</real>
<key>leftKey</key>
<real>0</real>
<key>rightKey</key>
<real>0</real>
<key>topKey</key>
<real>0</real>
</dict>
<key>imageNameKey</key>
<string>more</string>
<key>title</key>
<string>more</string>
<key>titleOffsetKey</key>
<dict>
<key>xKey</key>
<real>0</real>
<key>yKey</key>
<real>0</real>
</dict>
</dict>
</dict>
<key>kImageAdaptiveState</key>
<dict>
<key>UIControlState.Normal</key>
<dict>
<key>backgroundColorKey</key>
<dict>
<key>alphaColor</key>
<real>0</real>
<key>blueColor</key>
<real>0</real>
<key>greenColor</key>
<real>0</real>
<key>redColor</key>
<real>0</real>
</dict>
<key>backgroundImageNameKey</key>
<string></string>
<key>colorKey</key>
<dict>
<key>alphaColor</key>
<real>1</real>
<key>blueColor</key>
<real>0</real>
<key>greenColor</key>
<real>0</real>
<key>redColor</key>
<real>0</real>
</dict>
<key>fontKey</key>
<dict>
<key>fontNameKey</key>
<string>Helvetica</string>
<key>fontSizeKey</key>
<real>14</real>
</dict>
<key>imageInsetsKey</key>
<dict>
<key>bottomKey</key>
<real>-6</real>
<key>leftKey</key>
<real>0</real>
<key>rightKey</key>
<integer>0</integer>
<key>topKey</key>
<real>6</real>
</dict>
<key>imageNameKey</key>
<string>more_bigimage</string>
<key>title</key>
<string></string>
<key>titleOffsetKey</key>
<dict>
<key>xKey</key>
<real>0</real>
<key>yKey</key>
<real>0</real>
</dict>
</dict>
</dict>
<key>kSmallTitleAdaptiveState</key>
<dict>
<key>UIControlState.Normal</key>
<dict>
<key>backgroundColorKey</key>
<dict>
<key>alphaColor</key>
<real>0</real>
<key>blueColor</key>
<real>0</real>
<key>greenColor</key>
<real>0</real>
<key>redColor</key>
<real>0</real>
</dict>
<key>backgroundImageNameKey</key>
<string></string>
<key>colorKey</key>
<dict>
<key>alphaColor</key>
<real>1</real>
<key>blueColor</key>
<real>1</real>
<key>greenColor</key>
<real>1</real>
<key>redColor</key>
<real>1</real>
</dict>
<key>fontKey</key>
<dict>
<key>fontNameKey</key>
<string>Helvetica</string>
<key>fontSizeKey</key>
<real>10</real>
</dict>
<key>imageInsetsKey</key>
<dict>
<key>bottomKey</key>
<real>0</real>
<key>leftKey</key>
<real>0</real>
<key>rightKey</key>
<real>0</real>
<key>topKey</key>
<real>0</real>
</dict>
<key>imageNameKey</key>
<string>more_smalltitle</string>
<key>title</key>
<string>more</string>
<key>titleOffsetKey</key>
<dict>
<key>xKey</key>
<real>0</real>
<key>yKey</key>
<real>0</real>
</dict>
</dict>
</dict>
</dict>
</array>
</plist>
@@ -7,7 +7,7 @@
objects = {
/* Begin PBXBuildFile section */
6A156E401A091169002A69AD /* appearances.plist in Resources */ = {isa = PBXBuildFile; fileRef = 6A156E3F1A091169002A69AD /* appearances.plist */; };
574F3DB2FD6508BE949F063F /* libPods-example-date-adaptive-tab-bar.a in Frameworks */ = {isa = PBXBuildFile; fileRef = 89F848F3A0A725A7FC9A61BF /* libPods-example-date-adaptive-tab-bar.a */; };
6A3ED0C819ED0236006F06DD /* DateExtension.swift in Sources */ = {isa = PBXBuildFile; fileRef = 6A87F54B19C8532500E8F31B /* DateExtension.swift */; };
6A55590219E2C20900ED3B5C /* AdaptiveController.framework in Frameworks */ = {isa = PBXBuildFile; fileRef = 6A55590119E2C20900ED3B5C /* AdaptiveController.framework */; };
6A55590819E2CF7200ED3B5C /* MenuViewController.swift in Sources */ = {isa = PBXBuildFile; fileRef = 6A55590319E2CF7200ED3B5C /* MenuViewController.swift */; };
@@ -50,7 +50,8 @@
/* End PBXCopyFilesBuildPhase section */
/* Begin PBXFileReference section */
6A156E3F1A091169002A69AD /* appearances.plist */ = {isa = PBXFileReference; fileEncoding = 4; lastKnownFileType = text.plist.xml; path = appearances.plist; sourceTree = "<group>"; };
1B048FE6297EDD8A3A112D2F /* Pods-example-date-adaptive-tab-bar.debug.xcconfig */ = {isa = PBXFileReference; includeInIndex = 1; lastKnownFileType = text.xcconfig; name = "Pods-example-date-adaptive-tab-bar.debug.xcconfig"; path = "../../Pods/Target Support Files/Pods-example-date-adaptive-tab-bar/Pods-example-date-adaptive-tab-bar.debug.xcconfig"; sourceTree = "<group>"; };
1D11CE47BCAEC5ADF299A3B4 /* Pods-example-date-adaptive-tab-bar.release.xcconfig */ = {isa = PBXFileReference; includeInIndex = 1; lastKnownFileType = text.xcconfig; name = "Pods-example-date-adaptive-tab-bar.release.xcconfig"; path = "../../Pods/Target Support Files/Pods-example-date-adaptive-tab-bar/Pods-example-date-adaptive-tab-bar.release.xcconfig"; sourceTree = "<group>"; };
6A55590119E2C20900ED3B5C /* AdaptiveController.framework */ = {isa = PBXFileReference; lastKnownFileType = wrapper.framework; name = AdaptiveController.framework; path = "../../AdaptiveController/build/Debug-iphoneos/AdaptiveController.framework"; sourceTree = "<group>"; };
6A55590319E2CF7200ED3B5C /* MenuViewController.swift */ = {isa = PBXFileReference; fileEncoding = 4; lastKnownFileType = sourcecode.swift; name = MenuViewController.swift; path = UIControllers/MenuViewController.swift; sourceTree = "<group>"; };
6A55590419E2CF7200ED3B5C /* MessageViewController.swift */ = {isa = PBXFileReference; fileEncoding = 4; lastKnownFileType = sourcecode.swift; name = MessageViewController.swift; path = UIControllers/MessageViewController.swift; sourceTree = "<group>"; };
@@ -71,6 +72,7 @@
6AD5A30A19C6C95E00606826 /* example-date-adaptive-tab-barTests.xctest */ = {isa = PBXFileReference; explicitFileType = wrapper.cfbundle; includeInIndex = 0; path = "example-date-adaptive-tab-barTests.xctest"; sourceTree = BUILT_PRODUCTS_DIR; };
6AD5A30F19C6C95E00606826 /* Info.plist */ = {isa = PBXFileReference; lastKnownFileType = text.plist.xml; path = Info.plist; sourceTree = "<group>"; };
6AD5A31019C6C95E00606826 /* adaptive_tab_barTests.swift */ = {isa = PBXFileReference; lastKnownFileType = sourcecode.swift; path = adaptive_tab_barTests.swift; sourceTree = "<group>"; };
89F848F3A0A725A7FC9A61BF /* libPods-example-date-adaptive-tab-bar.a */ = {isa = PBXFileReference; explicitFileType = archive.ar; includeInIndex = 0; path = "libPods-example-date-adaptive-tab-bar.a"; sourceTree = BUILT_PRODUCTS_DIR; };
/* End PBXFileReference section */
/* Begin PBXFrameworksBuildPhase section */
@@ -80,6 +82,7 @@
files = (
6A55590219E2C20900ED3B5C /* AdaptiveController.framework in Frameworks */,
6ACC309E19C741E7006B6DF6 /* QuartzCore.framework in Frameworks */,
574F3DB2FD6508BE949F063F /* libPods-example-date-adaptive-tab-bar.a in Frameworks */,
);
runOnlyForDeploymentPostprocessing = 0;
};
@@ -113,6 +116,8 @@
6AD5A2F519C6C95E00606826 /* adaptive-tab-bar */,
6AD5A30D19C6C95E00606826 /* adaptive-tab-barTests */,
6AD5A2F419C6C95E00606826 /* Products */,
F7E136C5B9D3D92E649EF188 /* Pods */,
8E9A25BBDD719D0E0256107E /* Frameworks */,
);
sourceTree = "<group>";
};
@@ -144,7 +149,6 @@
6AD5A2F619C6C95E00606826 /* Supporting Files */ = {
isa = PBXGroup;
children = (
6A156E3F1A091169002A69AD /* appearances.plist */,
6AD5A2F719C6C95E00606826 /* Info.plist */,
);
name = "Supporting Files";
@@ -176,6 +180,23 @@
name = CustomTabBar;
sourceTree = "<group>";
};
8E9A25BBDD719D0E0256107E /* Frameworks */ = {
isa = PBXGroup;
children = (
89F848F3A0A725A7FC9A61BF /* libPods-example-date-adaptive-tab-bar.a */,
);
name = Frameworks;
sourceTree = "<group>";
};
F7E136C5B9D3D92E649EF188 /* Pods */ = {
isa = PBXGroup;
children = (
1B048FE6297EDD8A3A112D2F /* Pods-example-date-adaptive-tab-bar.debug.xcconfig */,
1D11CE47BCAEC5ADF299A3B4 /* Pods-example-date-adaptive-tab-bar.release.xcconfig */,
);
name = Pods;
sourceTree = "<group>";
};
/* End PBXGroup section */
/* Begin PBXNativeTarget section */
@@ -183,10 +204,12 @@
isa = PBXNativeTarget;
buildConfigurationList = 6AD5A31419C6C95E00606826 /* Build configuration list for PBXNativeTarget "example-date-adaptive-tab-bar" */;
buildPhases = (
1EDAC7BEEC43832EF13018A5 /* Check Pods Manifest.lock */,
6AD5A2EF19C6C95E00606826 /* Sources */,
6AD5A2F019C6C95E00606826 /* Frameworks */,
6AD5A2F119C6C95E00606826 /* Resources */,
6A9D84CC19CAB231006EA201 /* Embed Frameworks */,
950C0C88E60497EE42624290 /* Copy Pods Resources */,
);
buildRules = (
);
@@ -259,7 +282,6 @@
files = (
6AD5A30019C6C95E00606826 /* Main.storyboard in Resources */,
6AD5A30519C6C95E00606826 /* LaunchScreen.xib in Resources */,
6A156E401A091169002A69AD /* appearances.plist in Resources */,
6AD5A30219C6C95E00606826 /* Images.xcassets in Resources */,
);
runOnlyForDeploymentPostprocessing = 0;
@@ -273,6 +295,39 @@
};
/* End PBXResourcesBuildPhase section */
/* Begin PBXShellScriptBuildPhase section */
1EDAC7BEEC43832EF13018A5 /* Check Pods Manifest.lock */ = {
isa = PBXShellScriptBuildPhase;
buildActionMask = 2147483647;
files = (
);
inputPaths = (
);
name = "Check Pods Manifest.lock";
outputPaths = (
);
runOnlyForDeploymentPostprocessing = 0;
shellPath = /bin/sh;
shellScript = "diff \"${PODS_ROOT}/../Podfile.lock\" \"${PODS_ROOT}/Manifest.lock\" > /dev/null\nif [[ $? != 0 ]] ; then\n cat << EOM\nerror: The sandbox is not in sync with the Podfile.lock. Run 'pod install' or update your CocoaPods installation.\nEOM\n exit 1\nfi\n";
showEnvVarsInLog = 0;
};
950C0C88E60497EE42624290 /* Copy Pods Resources */ = {
isa = PBXShellScriptBuildPhase;
buildActionMask = 2147483647;
files = (
);
inputPaths = (
);
name = "Copy Pods Resources";
outputPaths = (
);
runOnlyForDeploymentPostprocessing = 0;
shellPath = /bin/sh;
shellScript = "\"${SRCROOT}/../../Pods/Target Support Files/Pods-example-date-adaptive-tab-bar/Pods-example-date-adaptive-tab-bar-resources.sh\"\n";
showEnvVarsInLog = 0;
};
/* End PBXShellScriptBuildPhase section */
/* Begin PBXSourcesBuildPhase section */
6AD5A2EF19C6C95E00606826 /* Sources */ = {
isa = PBXSourcesBuildPhase;
@@ -331,6 +386,7 @@
/* Begin XCBuildConfiguration section */
6AD5A31219C6C95E00606826 /* Debug */ = {
isa = XCBuildConfiguration;
baseConfigurationReference = 1B048FE6297EDD8A3A112D2F /* Pods-example-date-adaptive-tab-bar.debug.xcconfig */;
buildSettings = {
ALWAYS_SEARCH_USER_PATHS = NO;
CLANG_CXX_LANGUAGE_STANDARD = "gnu++0x";
@@ -371,43 +427,9 @@
};
name = Debug;
};
6AD5A31319C6C95E00606826 /* Release */ = {
isa = XCBuildConfiguration;
buildSettings = {
ALWAYS_SEARCH_USER_PATHS = NO;
CLANG_CXX_LANGUAGE_STANDARD = "gnu++0x";
CLANG_CXX_LIBRARY = "libc++";
CLANG_ENABLE_MODULES = YES;
CLANG_ENABLE_OBJC_ARC = YES;
CLANG_WARN_BOOL_CONVERSION = YES;
CLANG_WARN_CONSTANT_CONVERSION = YES;
CLANG_WARN_DIRECT_OBJC_ISA_USAGE = YES_ERROR;
CLANG_WARN_EMPTY_BODY = YES;
CLANG_WARN_ENUM_CONVERSION = YES;
CLANG_WARN_INT_CONVERSION = YES;
CLANG_WARN_OBJC_ROOT_CLASS = YES_ERROR;
CLANG_WARN_UNREACHABLE_CODE = YES;
CLANG_WARN__DUPLICATE_METHOD_MATCH = YES;
"CODE_SIGN_IDENTITY[sdk=iphoneos*]" = "iPhone Developer";
COPY_PHASE_STRIP = YES;
ENABLE_NS_ASSERTIONS = NO;
ENABLE_STRICT_OBJC_MSGSEND = YES;
GCC_C_LANGUAGE_STANDARD = gnu99;
GCC_WARN_64_TO_32_BIT_CONVERSION = YES;
GCC_WARN_ABOUT_RETURN_TYPE = YES_ERROR;
GCC_WARN_UNDECLARED_SELECTOR = YES;
GCC_WARN_UNINITIALIZED_AUTOS = YES_AGGRESSIVE;
GCC_WARN_UNUSED_FUNCTION = YES;
GCC_WARN_UNUSED_VARIABLE = YES;
IPHONEOS_DEPLOYMENT_TARGET = 8.0;
MTL_ENABLE_DEBUG_INFO = NO;
SDKROOT = iphoneos;
VALIDATE_PRODUCT = YES;
};
name = Release;
};
6AD5A31519C6C95E00606826 /* Debug */ = {
isa = XCBuildConfiguration;
baseConfigurationReference = 1B048FE6297EDD8A3A112D2F /* Pods-example-date-adaptive-tab-bar.debug.xcconfig */;
buildSettings = {
ASSETCATALOG_COMPILER_APPICON_NAME = AppIcon;
CLANG_ENABLE_MODULES = YES;
@@ -421,22 +443,9 @@
};
name = Debug;
};
6AD5A31619C6C95E00606826 /* Release */ = {
isa = XCBuildConfiguration;
buildSettings = {
ASSETCATALOG_COMPILER_APPICON_NAME = AppIcon;
CLANG_ENABLE_MODULES = YES;
DEFINES_MODULE = YES;
EMBEDDED_CONTENT_CONTAINS_SWIFT = YES;
INFOPLIST_FILE = "adaptive-tab-bar/Info.plist";
LD_RUNPATH_SEARCH_PATHS = "$(inherited) @executable_path/Frameworks";
PRODUCT_NAME = "example-date-adaptive-tab-bar";
SWIFT_OBJC_BRIDGING_HEADER = "adaptive-tab-bar-Bridging-Header.h";
};
name = Release;
};
6AD5A31819C6C95E00606826 /* Debug */ = {
isa = XCBuildConfiguration;
baseConfigurationReference = 1B048FE6297EDD8A3A112D2F /* Pods-example-date-adaptive-tab-bar.debug.xcconfig */;
buildSettings = {
BUNDLE_LOADER = "$(TEST_HOST)";
FRAMEWORK_SEARCH_PATHS = (
@@ -454,21 +463,6 @@
};
name = Debug;
};
6AD5A31919C6C95E00606826 /* Release */ = {
isa = XCBuildConfiguration;
buildSettings = {
BUNDLE_LOADER = "$(TEST_HOST)";
FRAMEWORK_SEARCH_PATHS = (
"$(SDKROOT)/Developer/Library/Frameworks",
"$(inherited)",
);
INFOPLIST_FILE = "adaptive-tab-barTests/Info.plist";
LD_RUNPATH_SEARCH_PATHS = "$(inherited) @executable_path/Frameworks @loader_path/Frameworks";
PRODUCT_NAME = "example-date-adaptive-tab-barTests";
TEST_HOST = "$(BUILT_PRODUCTS_DIR)/adaptive-tab-bar.app/adaptive-tab-bar";
};
name = Release;
};
/* End XCBuildConfiguration section */
/* Begin XCConfigurationList section */
@@ -476,28 +470,25 @@
isa = XCConfigurationList;
buildConfigurations = (
6AD5A31219C6C95E00606826 /* Debug */,
6AD5A31319C6C95E00606826 /* Release */,
);
defaultConfigurationIsVisible = 0;
defaultConfigurationName = Release;
defaultConfigurationName = Debug;
};
6AD5A31419C6C95E00606826 /* Build configuration list for PBXNativeTarget "example-date-adaptive-tab-bar" */ = {
isa = XCConfigurationList;
buildConfigurations = (
6AD5A31519C6C95E00606826 /* Debug */,
6AD5A31619C6C95E00606826 /* Release */,
);
defaultConfigurationIsVisible = 0;
defaultConfigurationName = Release;
defaultConfigurationName = Debug;
};
6AD5A31719C6C95E00606826 /* Build configuration list for PBXNativeTarget "example-date-adaptive-tab-barTests" */ = {
isa = XCConfigurationList;
buildConfigurations = (
6AD5A31819C6C95E00606826 /* Debug */,
6AD5A31919C6C95E00606826 /* Release */,
);
defaultConfigurationIsVisible = 0;
defaultConfigurationName = Release;
defaultConfigurationName = Debug;
};
/* End XCConfigurationList section */
};
@@ -2,4 +2,262 @@
<Bucket
type = "1"
version = "2.0">
<Breakpoints>
<BreakpointProxy
BreakpointExtensionID = "Xcode.Breakpoint.FileBreakpoint">
<BreakpointContent
shouldBeEnabled = "No"
ignoreCount = "0"
continueAfterRunningActions = "No"
filePath = "adaptive-tab-bar/AppDelegate.swift"
timestampString = "434293473.185451"
startingColumnNumber = "9223372036854775807"
endingColumnNumber = "9223372036854775807"
startingLineNumber = "50"
endingLineNumber = "50"
landmarkName = "application(_:didFinishLaunchingWithOptions:)"
landmarkType = "5">
</BreakpointContent>
</BreakpointProxy>
<BreakpointProxy
BreakpointExtensionID = "Xcode.Breakpoint.FileBreakpoint">
<BreakpointContent
shouldBeEnabled = "No"
ignoreCount = "0"
continueAfterRunningActions = "No"
filePath = "adaptive-tab-bar/AdaptiveTabBarItem.swift"
timestampString = "433270026.544751"
startingColumnNumber = "9223372036854775807"
endingColumnNumber = "9223372036854775807"
startingLineNumber = "22"
endingLineNumber = "22"
landmarkName = "setFontToAdaptiveButton(_:)"
landmarkType = "5">
</BreakpointContent>
</BreakpointProxy>
<BreakpointProxy
BreakpointExtensionID = "Xcode.Breakpoint.FileBreakpoint">
<BreakpointContent
shouldBeEnabled = "No"
ignoreCount = "0"
continueAfterRunningActions = "No"
filePath = "adaptive-tab-bar/AdaptiveTabBarItem.swift"
timestampString = "433270026.544751"
startingColumnNumber = "9223372036854775807"
endingColumnNumber = "9223372036854775807"
startingLineNumber = "27"
endingLineNumber = "27"
landmarkName = "setTitleToAdaptiveButton(_:)"
landmarkType = "5">
</BreakpointContent>
</BreakpointProxy>
<BreakpointProxy
BreakpointExtensionID = "Xcode.Breakpoint.FileBreakpoint">
<BreakpointContent
shouldBeEnabled = "No"
ignoreCount = "0"
continueAfterRunningActions = "No"
filePath = "adaptive-tab-bar/AdaptiveTabBarItem.swift"
timestampString = "433270026.544751"
startingColumnNumber = "9223372036854775807"
endingColumnNumber = "9223372036854775807"
startingLineNumber = "31"
endingLineNumber = "31"
landmarkName = "setImageToAdaptiveButton(_:)"
landmarkType = "5">
</BreakpointContent>
</BreakpointProxy>
<BreakpointProxy
BreakpointExtensionID = "Xcode.Breakpoint.FileBreakpoint">
<BreakpointContent
shouldBeEnabled = "No"
ignoreCount = "0"
continueAfterRunningActions = "No"
filePath = "adaptive-tab-bar/AdaptiveTabBarItem.swift"
timestampString = "433270026.544751"
startingColumnNumber = "9223372036854775807"
endingColumnNumber = "9223372036854775807"
startingLineNumber = "39"
endingLineNumber = "39"
landmarkName = "setImageInsetsToAdaptiveButton(_:)"
landmarkType = "5">
</BreakpointContent>
</BreakpointProxy>
<BreakpointProxy
BreakpointExtensionID = "Xcode.Breakpoint.FileBreakpoint">
<BreakpointContent
shouldBeEnabled = "No"
ignoreCount = "0"
continueAfterRunningActions = "No"
filePath = "adaptive-tab-bar/AdaptiveTabBarItem.swift"
timestampString = "433270026.544751"
startingColumnNumber = "9223372036854775807"
endingColumnNumber = "9223372036854775807"
startingLineNumber = "43"
endingLineNumber = "43"
landmarkName = "setTitleOffsetToAdaptiveButton(_:)"
landmarkType = "5">
</BreakpointContent>
</BreakpointProxy>
<BreakpointProxy
BreakpointExtensionID = "Xcode.Breakpoint.FileBreakpoint">
<BreakpointContent
shouldBeEnabled = "No"
ignoreCount = "0"
continueAfterRunningActions = "No"
filePath = "adaptive-tab-bar/AdaptiveTabBarItem.swift"
timestampString = "433270026.544751"
startingColumnNumber = "9223372036854775807"
endingColumnNumber = "9223372036854775807"
startingLineNumber = "30"
endingLineNumber = "30"
landmarkName = "setImageToAdaptiveButton(_:)"
landmarkType = "5">
</BreakpointContent>
</BreakpointProxy>
<BreakpointProxy
BreakpointExtensionID = "Xcode.Breakpoint.FileBreakpoint">
<BreakpointContent
shouldBeEnabled = "No"
ignoreCount = "0"
continueAfterRunningActions = "No"
filePath = "adaptive-tab-bar/AdaptiveController/AdaptiveButtonsStateManager.swift"
timestampString = "433094882.479065"
startingColumnNumber = "9223372036854775807"
endingColumnNumber = "9223372036854775807"
startingLineNumber = "53"
endingLineNumber = "53"
landmarkName = "setButtonsState(_:buttonsAray:buttonsApperance:)"
landmarkType = "5">
</BreakpointContent>
</BreakpointProxy>
<BreakpointProxy
BreakpointExtensionID = "Xcode.Breakpoint.FileBreakpoint">
<BreakpointContent
shouldBeEnabled = "No"
ignoreCount = "0"
continueAfterRunningActions = "No"
filePath = "adaptive-tab-bar/AdaptiveController/AdaptiveButtonApperance.swift"
timestampString = "433165373.973683"
startingColumnNumber = "9223372036854775807"
endingColumnNumber = "9223372036854775807"
startingLineNumber = "111"
endingLineNumber = "111"
landmarkName = "getButonImageForState(_:)"
landmarkType = "5">
</BreakpointContent>
</BreakpointProxy>
<BreakpointProxy
BreakpointExtensionID = "Xcode.Breakpoint.FileBreakpoint">
<BreakpointContent
shouldBeEnabled = "No"
ignoreCount = "0"
continueAfterRunningActions = "No"
filePath = "adaptive-tab-bar/AdaptiveTabBarItem.swift"
timestampString = "433270026.544751"
startingColumnNumber = "9223372036854775807"
endingColumnNumber = "9223372036854775807"
startingLineNumber = "35"
endingLineNumber = "35"
landmarkName = "setSelectedImageToAdaptiveButton(_:)"
landmarkType = "5">
</BreakpointContent>
</BreakpointProxy>
<BreakpointProxy
BreakpointExtensionID = "Xcode.Breakpoint.FileBreakpoint">
<BreakpointContent
shouldBeEnabled = "No"
ignoreCount = "0"
continueAfterRunningActions = "No"
filePath = "adaptive-tab-bar/AdaptiveController/AdaptiveDateState.swift"
timestampString = "432824522.988969"
startingColumnNumber = "9223372036854775807"
endingColumnNumber = "9223372036854775807"
startingLineNumber = "25"
endingLineNumber = "25"
landmarkName = "init(installDate:currentDate:countDaysToSmallTextState:countDaysToImageState:)"
landmarkType = "5">
</BreakpointContent>
</BreakpointProxy>
<BreakpointProxy
BreakpointExtensionID = "Xcode.Breakpoint.FileBreakpoint">
<BreakpointContent
shouldBeEnabled = "No"
ignoreCount = "0"
continueAfterRunningActions = "No"
filePath = "adaptive-tab-bar/AdaptiveController/AdaptiveDateState.swift"
timestampString = "432824525.591121"
startingColumnNumber = "9223372036854775807"
endingColumnNumber = "9223372036854775807"
startingLineNumber = "24"
endingLineNumber = "24"
landmarkName = "init(installDate:currentDate:countDaysToSmallTextState:countDaysToImageState:)"
landmarkType = "5">
</BreakpointContent>
</BreakpointProxy>
<BreakpointProxy
BreakpointExtensionID = "Xcode.Breakpoint.FileBreakpoint">
<BreakpointContent
shouldBeEnabled = "No"
ignoreCount = "0"
continueAfterRunningActions = "No"
filePath = "adaptive-tab-bar/AdaptiveController/AdaptiveDateState.swift"
timestampString = "432828574.023887"
startingColumnNumber = "9223372036854775807"
endingColumnNumber = "9223372036854775807"
startingLineNumber = "48"
endingLineNumber = "48"
landmarkName = "stateRemainDays(_:countDaysToSmallTextState:countDaysToImageState:)"
landmarkType = "5">
</BreakpointContent>
</BreakpointProxy>
<BreakpointProxy
BreakpointExtensionID = "Xcode.Breakpoint.FileBreakpoint">
<BreakpointContent
shouldBeEnabled = "No"
ignoreCount = "0"
continueAfterRunningActions = "No"
filePath = "adaptive-tab-bar/AdaptiveController/AdaptiveDateState.swift"
timestampString = "432828592.270449"
startingColumnNumber = "9223372036854775807"
endingColumnNumber = "9223372036854775807"
startingLineNumber = "46"
endingLineNumber = "46"
landmarkName = "stateRemainDays(_:countDaysToSmallTextState:countDaysToImageState:)"
landmarkType = "5">
</BreakpointContent>
</BreakpointProxy>
<BreakpointProxy
BreakpointExtensionID = "Xcode.Breakpoint.FileBreakpoint">
<BreakpointContent
shouldBeEnabled = "No"
ignoreCount = "0"
continueAfterRunningActions = "No"
filePath = "adaptive-tab-bar/AdaptiveTabBarItem.swift"
timestampString = "433270026.544751"
startingColumnNumber = "9223372036854775807"
endingColumnNumber = "9223372036854775807"
startingLineNumber = "48"
endingLineNumber = "48"
landmarkName = "setTitleColorToAdaptiveButton(_:)"
landmarkType = "5">
</BreakpointContent>
</BreakpointProxy>
<BreakpointProxy
BreakpointExtensionID = "Xcode.Breakpoint.FileBreakpoint">
<BreakpointContent
shouldBeEnabled = "No"
ignoreCount = "0"
continueAfterRunningActions = "No"
filePath = "adaptive-tab-bar/AppDelegate.swift"
timestampString = "434465681.065848"
startingColumnNumber = "9223372036854775807"
endingColumnNumber = "9223372036854775807"
startingLineNumber = "119"
endingLineNumber = "119"
landmarkName = "buttonsAppearancesGenerate()"
landmarkType = "5">
</BreakpointContent>
</BreakpointProxy>
</Breakpoints>
</Bucket>
@@ -4,7 +4,7 @@
<dict>
<key>SchemeUserState</key>
<dict>
<key>example-date-adaptive-tab-bar.xcscheme_^#shared#^_</key>
<key>example-date-adaptive-tab-bar.xcscheme</key>
<dict>
<key>orderHint</key>
<integer>3</integer>
+11
View File
@@ -0,0 +1,11 @@
source 'https://github.com/CocoaPods/Specs.git'
target 'example-count-launches-adaptive-tabbar', :exclusive => true do
pod "AdaptiveController", :path => "../.."
end
target 'example-count-launches-adaptive-tabbarTests', :exclusive => true do
pod "AdaptiveController", :path => "../.."
end
@@ -39,121 +39,100 @@ class AppDelegate: UIResponder, UIApplicationDelegate {
tabBar.barTintColor = tabColor
tabBar.clipsToBounds = true
var curentCountLaunches = 6
var curentCountLaunches = 10
var adaptiveState = AdaptiveLaunchesState(curentCountLaunches:curentCountLaunches,countLaunchesToSmallTextState:countDaysForSmaltextState,countLaunchesToImageState:countDaysForImageModeState)
var buttonsAppearances = buttonsAppearancesGenerate()
var buttonsAppearances = buttonsAppearancesGenerate() //func butonsApprencesGenerate() -> [AdaptiveButtonApperance]
var arrayButtons = tabBar.items as [AdaptiveTabBarItem]
AdaptiveButtonsStateManager.setupButtonsAppearanceFromState(adaptiveState,buttonsAray:arrayButtons ,buttonsAppearances: buttonsAppearances)
AdaptiveButtonsStateManager(state: adaptiveState,buttonsAray:arrayButtons ,buttonsAppearance: buttonsAppearances)
return true
}
func buttonsAppearancesGenerate() -> [AdaptiveButtonAppearance]{
var settingsManager = AppearenceSettingManager()
//
settingsManager.defaultStyleSettingsForNormalState(AdaptiveStateEnum.DefaultAdaptiveState,titleOffset:defaultOffset, imageInsets:defaultInsets, titleColor:UIColor.whiteColor(), font:defaultFont!, backgroundColor:UIColor.clearColor())
settingsManager.defaultStyleSettingsForNormalState(AdaptiveStateEnum.SmallTitleAdaptiveState,titleOffset:defaultOffset, imageInsets:defaultSmallTitleModeImageInsets, titleColor:UIColor.whiteColor(), font:defaultSmallTitleModeFont!, backgroundColor:UIColor.clearColor())
settingsManager.defaultStyleSettingsForNormalState(AdaptiveStateEnum.ImageAdaptiveState,titleOffset:defaultOffset, imageInsets:defaultImageModeInsets, titleColor:UIColor.whiteColor(), font:defaultFont!, backgroundColor:UIColor.clearColor())
var imageExtensionsForStates:Dictionary = [ kSmallTitleAdaptiveState:"_smalltitle",
kImageAdaptiveState:"_bigimage",
kSmallTitleAdaptiveState+selected :"_smalltitle",
kImageAdaptiveState+selected:"_bigimage" ]
var watchAppearance = AdaptiveButtonAppearance();
var watchControlDefaultStateValue = settingsManager.defaultStyleValuesForNormalState(AdaptiveStateEnum.DefaultAdaptiveState, title:"watch", imageName:"watch")
watchAppearance.setButonTitle("watch", state: kDefaultAdaptiveState)
watchAppearance.setButonTitle("watch", state: kSmallTitleAdaptiveState)
watchAppearance.setButonTitle("", state: kImageAdaptiveState)
watchAppearance.setTitleColor(UIColor.whiteColor(), state: kDefaultAdaptiveState)
var watchControlSmallTitleStateValue = settingsManager.defaultStyleValuesForNormalState(AdaptiveStateEnum.SmallTitleAdaptiveState, title:"watch", imageName:"watch_smalltitle")
var watchControlImageStateValue = settingsManager.defaultStyleValuesForNormalState(AdaptiveStateEnum.ImageAdaptiveState, title:"", imageName:"watch_bigimage")
watchAppearance.setButonTitleFontForState(defaultFont, state: kDefaultAdaptiveState)
let watchAppearanceStates = [AdaptiveStateEnum.DefaultAdaptiveState:watchControlDefaultStateValue,
AdaptiveStateEnum.SmallTitleAdaptiveState:watchControlSmallTitleStateValue,
AdaptiveStateEnum.ImageAdaptiveState:watchControlImageStateValue]
watchAppearance.setButonTitleFontForState(defaultSmallTitleModeFont, state: kSmallTitleAdaptiveState)
watchAppearance.setImageNamesForStatesImageExtesions("watch", imageExtensionsForState:imageExtensionsForStates)
watchAppearance.setImageInsets(defaultInsets, state: kDefaultAdaptiveState);
watchAppearance.setImageInsets(defaultSmallTitleModeImageInsets, state: kSmallTitleAdaptiveState)
watchAppearance.setTitleOffset(defaultOffset, state: kDefaultAdaptiveState)
watchAppearance.setImageInsets(defaultImageModeInsets, state: kImageAdaptiveState);
var userAperance = AdaptiveButtonAppearance();
var watchAppearance = AdaptiveButtonAppearance(states:watchAppearanceStates)
userAperance.setAllCommonApperanceFrom(watchAppearance)
userAperance.setButonTitle("user", state: kDefaultAdaptiveState)
userAperance.setButonTitle("", state: kImageAdaptiveState)
userAperance.setImageNamesForStatesImageExtesions("man", imageExtensionsForState:imageExtensionsForStates)
var messageAperance = AdaptiveButtonAppearance();
var userСontrolDefaultStateValue = settingsManager.defaultStyleValuesForNormalState(AdaptiveStateEnum.DefaultAdaptiveState, title:"user", imageName:"man")
messageAperance.setAllCommonApperanceFrom((watchAppearance))
messageAperance.setButonTitle("message", state: kDefaultAdaptiveState)
messageAperance.setButonTitle("", state: kImageAdaptiveState)
var userControlSmallTitleStateValue = settingsManager.defaultStyleValuesForNormalState(AdaptiveStateEnum.SmallTitleAdaptiveState, title:"user", imageName:"man_smalltitle")
messageAperance.setImageNamesForStatesImageExtesions("messages", imageExtensionsForState:imageExtensionsForStates)
var menuAperance = AdaptiveButtonAppearance();
menuAperance.setAllCommonApperanceFrom((watchAppearance))
menuAperance.setButonTitle("dial", state: kDefaultAdaptiveState)
menuAperance.setButonTitle("", state: kImageAdaptiveState)
menuAperance.setImageNamesForStatesImageExtesions("menu", imageExtensionsForState:imageExtensionsForStates)
var moreAperance = AdaptiveButtonAppearance();
moreAperance.setAllCommonApperanceFrom((watchAppearance))
moreAperance.setButonTitle("more", state: kDefaultAdaptiveState)
moreAperance.setButonTitle("", state: kImageAdaptiveState)
moreAperance.setImageNamesForStatesImageExtesions("more", imageExtensionsForState:imageExtensionsForStates)
var userControlImageStateValue = settingsManager.defaultStyleValuesForNormalState(AdaptiveStateEnum.ImageAdaptiveState, title:"", imageName:"man_bigimage")
let userappearanceStates = [AdaptiveStateEnum.DefaultAdaptiveState:watchControlDefaultStateValue,
AdaptiveStateEnum.SmallTitleAdaptiveState:watchControlSmallTitleStateValue,
AdaptiveStateEnum.ImageAdaptiveState:watchControlImageStateValue]
let userAppearanceStates = [AdaptiveStateEnum.DefaultAdaptiveState:userСontrolDefaultStateValue,
AdaptiveStateEnum.SmallTitleAdaptiveState:userControlSmallTitleStateValue,
AdaptiveStateEnum.ImageAdaptiveState:userControlImageStateValue]
var userAperance = AdaptiveButtonAppearance(states:userAppearanceStates)
var messageСontrolDefaultStateValue = settingsManager.defaultStyleValuesForNormalState(AdaptiveStateEnum.DefaultAdaptiveState, title:"messages", imageName:"messages")
var messageControlSmallTitleStateValue = settingsManager.defaultStyleValuesForNormalState(AdaptiveStateEnum.SmallTitleAdaptiveState, title:"messages", imageName:"messages_smalltitle")
var messageControlImageStateValue = settingsManager.defaultStyleValuesForNormalState(AdaptiveStateEnum.ImageAdaptiveState, title:"", imageName:"messages_bigimage")
let messageAppearanceStates = [AdaptiveStateEnum.DefaultAdaptiveState:messageСontrolDefaultStateValue,
AdaptiveStateEnum.SmallTitleAdaptiveState:messageControlSmallTitleStateValue,
AdaptiveStateEnum.ImageAdaptiveState:messageControlImageStateValue]
var messageAperance = AdaptiveButtonAppearance(states:messageAppearanceStates)
var menuСontrolDefaultStateValue = settingsManager.defaultStyleValuesForNormalState(AdaptiveStateEnum.DefaultAdaptiveState, title:"dial", imageName:"menu")
var menuControlSmallTitleStateValue = settingsManager.defaultStyleValuesForNormalState(AdaptiveStateEnum.SmallTitleAdaptiveState, title:"dial", imageName:"menu_smalltitle")
var menuControlImageStateValue = settingsManager.defaultStyleValuesForNormalState(AdaptiveStateEnum.ImageAdaptiveState, title:"", imageName:"menu_bigimage")
let menuAppearanceStates = [AdaptiveStateEnum.DefaultAdaptiveState:menuСontrolDefaultStateValue,
AdaptiveStateEnum.SmallTitleAdaptiveState:menuControlSmallTitleStateValue,
AdaptiveStateEnum.ImageAdaptiveState:menuControlImageStateValue]
var menuAperance = AdaptiveButtonAppearance(states:menuAppearanceStates)
var moreСontrolDefaultStateValue = settingsManager.defaultStyleValuesForNormalState(AdaptiveStateEnum.DefaultAdaptiveState, title:"more", imageName:"more")
var moreControlSmallTitleStateValue = settingsManager.defaultStyleValuesForNormalState(AdaptiveStateEnum.SmallTitleAdaptiveState, title:"more", imageName:"more_smalltitle")
var moreControlImageStateValue = settingsManager.defaultStyleValuesForNormalState(AdaptiveStateEnum.ImageAdaptiveState, title:"", imageName:"more_bigimage")
let moreAppearanceStates = [AdaptiveStateEnum.DefaultAdaptiveState:moreСontrolDefaultStateValue,
AdaptiveStateEnum.SmallTitleAdaptiveState:moreControlSmallTitleStateValue,
AdaptiveStateEnum.ImageAdaptiveState:moreControlImageStateValue]
var moreAperance = AdaptiveButtonAppearance(states:moreAppearanceStates)
return [watchAppearance ,messageAperance,userAperance,menuAperance,moreAperance]
}
@@ -1,14 +1,13 @@
<?xml version="1.0" encoding="UTF-8" standalone="no"?>
<document type="com.apple.InterfaceBuilder3.CocoaTouch.Storyboard.XIB" version="3.0" toolsVersion="6250" systemVersion="14A389" targetRuntime="iOS.CocoaTouch" propertyAccessControl="none" useAutolayout="YES" useTraitCollections="YES" initialViewController="49e-Tb-3d3">
<document type="com.apple.InterfaceBuilder3.CocoaTouch.Storyboard.XIB" version="3.0" toolsVersion="6245" systemVersion="13F34" targetRuntime="iOS.CocoaTouch" propertyAccessControl="none" useAutolayout="YES" useTraitCollections="YES" initialViewController="49e-Tb-3d3">
<dependencies>
<plugIn identifier="com.apple.InterfaceBuilder.IBCocoaTouchPlugin" version="6244"/>
<capability name="Constraints to layout margins" minToolsVersion="6.0"/>
<plugIn identifier="com.apple.InterfaceBuilder.IBCocoaTouchPlugin" version="6238"/>
</dependencies>
<scenes>
<!--First-->
<scene sceneID="hNz-n2-bh7">
<objects>
<viewController id="9pv-A4-QxB" customClass="WatchViewController" customModule="example_count_launches_adaptive_tabbar" customModuleProvider="target" sceneMemberID="viewController">
<viewController id="9pv-A4-QxB" customClass="WatchViewController" customModule="adaptive_tab_bar" customModuleProvider="target" sceneMemberID="viewController">
<layoutGuides>
<viewControllerLayoutGuide type="top" id="Ia1-K6-d13"/>
<viewControllerLayoutGuide type="bottom" id="4ug-Mw-9AY"/>
@@ -30,23 +29,19 @@
<color key="textColor" cocoaTouchSystemColor="darkTextColor"/>
<nil key="highlightedColor"/>
</label>
<imageView userInteractionEnabled="NO" contentMode="scaleToFill" horizontalHuggingPriority="251" verticalHuggingPriority="251" image="background" translatesAutoresizingMaskIntoConstraints="NO" id="bTY-b5-lYl">
<rect key="frame" x="0.0" y="0.0" width="640" height="551"/>
<imageView userInteractionEnabled="NO" contentMode="scaleToFill" horizontalHuggingPriority="251" verticalHuggingPriority="251" fixedFrame="YES" image="background" translatesAutoresizingMaskIntoConstraints="NO" id="bTY-b5-lYl">
<rect key="frame" x="0.0" y="0.0" width="640" height="550"/>
</imageView>
</subviews>
<color key="backgroundColor" white="1" alpha="1" colorSpace="custom" customColorSpace="calibratedWhite"/>
<constraints>
<constraint firstItem="4ug-Mw-9AY" firstAttribute="top" secondItem="bTY-b5-lYl" secondAttribute="bottom" id="57C-0I-UhP"/>
<constraint firstAttribute="centerX" secondItem="KQZ-1w-vlD" secondAttribute="centerX" id="6BV-lF-sBN"/>
<constraint firstItem="A5M-7J-77L" firstAttribute="top" secondItem="KQZ-1w-vlD" secondAttribute="bottom" constant="8" symbolic="YES" id="cfb-er-3JN"/>
<constraint firstItem="A5M-7J-77L" firstAttribute="centerX" secondItem="KQZ-1w-vlD" secondAttribute="centerX" id="e1l-AV-tCB"/>
<constraint firstAttribute="centerY" secondItem="KQZ-1w-vlD" secondAttribute="centerY" id="exm-UA-ej4"/>
<constraint firstItem="bTY-b5-lYl" firstAttribute="top" secondItem="tsR-hK-woN" secondAttribute="top" id="kWQ-y6-H6g"/>
<constraint firstAttribute="trailing" secondItem="bTY-b5-lYl" secondAttribute="trailing" constant="-40" id="sYy-Hj-V1a"/>
<constraint firstItem="bTY-b5-lYl" firstAttribute="leading" secondItem="tsR-hK-woN" secondAttribute="leading" id="ueh-EO-Puf"/>
</constraints>
</view>
<tabBarItem key="tabBarItem" title="First" id="acW-dT-cKf" customClass="AdaptiveTabBarItem" customModule="example_count_launches_adaptive_tabbar" customModuleProvider="target"/>
<tabBarItem key="tabBarItem" title="First" id="acW-dT-cKf" customClass="AdaptiveTabBarItem" customModule="adaptive_tab_bar" customModuleProvider="target"/>
</viewController>
<placeholder placeholderIdentifier="IBFirstResponder" id="W5J-7L-Pyd" sceneMemberID="firstResponder"/>
</objects>
@@ -55,7 +50,7 @@
<!--Second-->
<scene sceneID="wg7-f3-ORb">
<objects>
<viewController id="8rJ-Kc-sve" customClass="MessageViewController" customModule="example_count_launches_adaptive_tabbar" customModuleProvider="target" sceneMemberID="viewController">
<viewController id="8rJ-Kc-sve" customClass="MessageViewController" customModule="adaptive_tab_bar" customModuleProvider="target" sceneMemberID="viewController">
<layoutGuides>
<viewControllerLayoutGuide type="top" id="L7p-HK-0SC"/>
<viewControllerLayoutGuide type="bottom" id="Djb-ko-YwX"/>
@@ -77,23 +72,19 @@
<color key="textColor" cocoaTouchSystemColor="darkTextColor"/>
<nil key="highlightedColor"/>
</label>
<imageView userInteractionEnabled="NO" contentMode="scaleToFill" horizontalHuggingPriority="251" verticalHuggingPriority="251" image="background" translatesAutoresizingMaskIntoConstraints="NO" id="d3m-k5-qah">
<rect key="frame" x="0.0" y="0.0" width="640" height="551"/>
<imageView userInteractionEnabled="NO" contentMode="scaleToFill" horizontalHuggingPriority="251" verticalHuggingPriority="251" fixedFrame="YES" image="background" translatesAutoresizingMaskIntoConstraints="NO" id="d3m-k5-qah">
<rect key="frame" x="0.0" y="0.0" width="640" height="550"/>
</imageView>
</subviews>
<color key="backgroundColor" white="1" alpha="1" colorSpace="custom" customColorSpace="calibratedWhite"/>
<constraints>
<constraint firstAttribute="trailing" secondItem="d3m-k5-qah" secondAttribute="trailing" constant="-40" id="8KS-iG-8XT"/>
<constraint firstItem="NDk-cv-Gan" firstAttribute="top" secondItem="zEq-FU-wV5" secondAttribute="bottom" constant="8" symbolic="YES" id="Day-4N-Vmt"/>
<constraint firstItem="NDk-cv-Gan" firstAttribute="centerX" secondItem="zEq-FU-wV5" secondAttribute="centerX" id="JgO-Fn-dHn"/>
<constraint firstItem="d3m-k5-qah" firstAttribute="leading" secondItem="QS5-Rx-YEW" secondAttribute="leading" id="X9o-k0-h62"/>
<constraint firstAttribute="centerX" secondItem="zEq-FU-wV5" secondAttribute="centerX" id="qqM-NS-xev"/>
<constraint firstAttribute="centerY" secondItem="zEq-FU-wV5" secondAttribute="centerY" id="qzY-Ky-pLD"/>
<constraint firstItem="d3m-k5-qah" firstAttribute="top" secondItem="QS5-Rx-YEW" secondAttribute="top" id="tA2-Eh-fSb"/>
<constraint firstItem="Djb-ko-YwX" firstAttribute="top" secondItem="d3m-k5-qah" secondAttribute="bottom" id="zws-Zn-RsZ"/>
</constraints>
</view>
<tabBarItem key="tabBarItem" title="Second" id="cPa-gy-q4n" customClass="AdaptiveTabBarItem" customModule="example_count_launches_adaptive_tabbar"/>
<tabBarItem key="tabBarItem" title="Second" image="second" id="cPa-gy-q4n" customClass="AdaptiveTabBarItem" customModule="adaptive_tab_bar" customModuleProvider="target"/>
</viewController>
<placeholder placeholderIdentifier="IBFirstResponder" id="4Nw-L8-lE0" sceneMemberID="firstResponder"/>
</objects>
@@ -102,7 +93,7 @@
<!--Tab Bar View Controller-->
<scene sceneID="yl2-sM-qoP">
<objects>
<tabBarController id="49e-Tb-3d3" customClass="TabBarViewController" customModule="example_count_launches_adaptive_tabbar" customModuleProvider="target" sceneMemberID="viewController">
<tabBarController id="49e-Tb-3d3" customClass="TabBarViewController" customModule="adaptive_tab_bar" customModuleProvider="target" sceneMemberID="viewController">
<nil key="simulatedBottomBarMetrics"/>
<tabBar key="tabBar" contentMode="scaleToFill" id="W28-zg-YXA">
<rect key="frame" x="0.0" y="975" width="768" height="49"/>
@@ -124,7 +115,7 @@
<!--Item-->
<scene sceneID="60i-zg-cAx">
<objects>
<viewController id="BiK-DX-JK5" customClass="UserViewController" customModule="example_count_launches_adaptive_tabbar" customModuleProvider="target" sceneMemberID="viewController">
<viewController id="BiK-DX-JK5" customClass="UserViewController" customModule="adaptive_tab_bar" customModuleProvider="target" sceneMemberID="viewController">
<layoutGuides>
<viewControllerLayoutGuide type="top" id="oSS-7K-rER"/>
<viewControllerLayoutGuide type="bottom" id="Ba7-rp-yUE"/>
@@ -133,19 +124,13 @@
<rect key="frame" x="0.0" y="0.0" width="600" height="600"/>
<autoresizingMask key="autoresizingMask" widthSizable="YES" heightSizable="YES"/>
<subviews>
<imageView userInteractionEnabled="NO" contentMode="scaleToFill" horizontalHuggingPriority="251" verticalHuggingPriority="251" image="background" translatesAutoresizingMaskIntoConstraints="NO" id="jtr-dW-8XE">
<imageView userInteractionEnabled="NO" contentMode="scaleToFill" horizontalHuggingPriority="251" verticalHuggingPriority="251" fixedFrame="YES" image="background" translatesAutoresizingMaskIntoConstraints="NO" id="jtr-dW-8XE">
<rect key="frame" x="0.0" y="0.0" width="640" height="555"/>
</imageView>
</subviews>
<color key="backgroundColor" white="1" alpha="1" colorSpace="calibratedWhite"/>
<constraints>
<constraint firstAttribute="trailing" secondItem="jtr-dW-8XE" secondAttribute="trailing" constant="-40" id="68Q-YE-GnZ"/>
<constraint firstItem="jtr-dW-8XE" firstAttribute="leading" secondItem="Z9a-At-6Ll" secondAttribute="leading" id="9Lc-1F-lVY"/>
<constraint firstAttribute="bottom" secondItem="jtr-dW-8XE" secondAttribute="bottom" constant="45" id="iHg-vq-ehR"/>
<constraint firstItem="jtr-dW-8XE" firstAttribute="top" secondItem="Z9a-At-6Ll" secondAttribute="top" id="zds-Uy-hOW"/>
</constraints>
</view>
<tabBarItem key="tabBarItem" title="Item" id="g86-Lf-lWF" customClass="AdaptiveTabBarItem" customModule="example_count_launches_adaptive_tabbar" customModuleProvider="target"/>
<tabBarItem key="tabBarItem" title="Item" id="g86-Lf-lWF" customClass="AdaptiveTabBarItem" customModule="adaptive_tab_bar" customModuleProvider="target"/>
</viewController>
<placeholder placeholderIdentifier="IBFirstResponder" id="Ds1-lP-WuT" userLabel="First Responder" sceneMemberID="firstResponder"/>
</objects>
@@ -154,7 +139,7 @@
<!--Item-->
<scene sceneID="RUI-wr-KlE">
<objects>
<viewController id="aXk-96-nwf" customClass="MenuViewController" customModule="example_count_launches_adaptive_tabbar" customModuleProvider="target" sceneMemberID="viewController">
<viewController id="aXk-96-nwf" customClass="MenuViewController" customModule="adaptive_tab_bar" customModuleProvider="target" sceneMemberID="viewController">
<layoutGuides>
<viewControllerLayoutGuide type="top" id="Aha-rh-ib6"/>
<viewControllerLayoutGuide type="bottom" id="aNR-L8-QaD"/>
@@ -163,20 +148,13 @@
<rect key="frame" x="0.0" y="0.0" width="600" height="600"/>
<autoresizingMask key="autoresizingMask" widthSizable="YES" heightSizable="YES"/>
<subviews>
<imageView userInteractionEnabled="NO" contentMode="scaleToFill" horizontalHuggingPriority="251" verticalHuggingPriority="251" image="background" translatesAutoresizingMaskIntoConstraints="NO" id="GGw-pn-6CX">
<rect key="frame" x="0.0" y="0.0" width="640" height="551"/>
<imageView userInteractionEnabled="NO" contentMode="scaleToFill" horizontalHuggingPriority="251" verticalHuggingPriority="251" fixedFrame="YES" image="background" translatesAutoresizingMaskIntoConstraints="NO" id="GGw-pn-6CX">
<rect key="frame" x="0.0" y="0.0" width="640" height="550"/>
</imageView>
</subviews>
<color key="backgroundColor" white="1" alpha="1" colorSpace="calibratedWhite"/>
<constraints>
<constraint firstItem="GGw-pn-6CX" firstAttribute="top" secondItem="UyR-nf-sp6" secondAttribute="topMargin" id="JNr-AP-tWr"/>
<constraint firstItem="GGw-pn-6CX" firstAttribute="top" secondItem="UyR-nf-sp6" secondAttribute="topMargin" id="MSj-7q-ac7"/>
<constraint firstItem="GGw-pn-6CX" firstAttribute="leading" secondItem="UyR-nf-sp6" secondAttribute="leading" id="SZF-JG-V57"/>
<constraint firstItem="aNR-L8-QaD" firstAttribute="top" secondItem="GGw-pn-6CX" secondAttribute="bottom" id="YDT-AA-Wjy"/>
<constraint firstItem="aNR-L8-QaD" firstAttribute="top" secondItem="GGw-pn-6CX" secondAttribute="bottom" id="nys-sX-kRN"/>
</constraints>
</view>
<tabBarItem key="tabBarItem" title="Item" id="RnB-fU-3RS" customClass="AdaptiveTabBarItem" customModule="example_count_launches_adaptive_tabbar" customModuleProvider="target"/>
<tabBarItem key="tabBarItem" title="Item" id="RnB-fU-3RS" customClass="AdaptiveTabBarItem" customModule="adaptive_tab_bar" customModuleProvider="target"/>
</viewController>
<placeholder placeholderIdentifier="IBFirstResponder" id="Hsc-p3-elF" userLabel="First Responder" sceneMemberID="firstResponder"/>
</objects>
@@ -185,7 +163,7 @@
<!--Item-->
<scene sceneID="B98-FR-Rjt">
<objects>
<viewController id="BgE-dr-gW8" customClass="MoreViewController" customModule="example_count_launches_adaptive_tabbar" customModuleProvider="target" sceneMemberID="viewController">
<viewController id="BgE-dr-gW8" customClass="MoreViewController" customModule="adaptive_tab_bar" customModuleProvider="target" sceneMemberID="viewController">
<layoutGuides>
<viewControllerLayoutGuide type="top" id="r9s-DG-v8Y"/>
<viewControllerLayoutGuide type="bottom" id="mju-qR-F4m"/>
@@ -194,19 +172,13 @@
<rect key="frame" x="0.0" y="0.0" width="600" height="600"/>
<autoresizingMask key="autoresizingMask" widthSizable="YES" heightSizable="YES"/>
<subviews>
<imageView userInteractionEnabled="NO" contentMode="scaleToFill" horizontalHuggingPriority="251" verticalHuggingPriority="251" image="background" translatesAutoresizingMaskIntoConstraints="NO" id="fel-JW-y8K">
<rect key="frame" x="0.0" y="0.0" width="600" height="551"/>
<imageView userInteractionEnabled="NO" contentMode="scaleToFill" horizontalHuggingPriority="251" verticalHuggingPriority="251" fixedFrame="YES" image="background" translatesAutoresizingMaskIntoConstraints="NO" id="fel-JW-y8K">
<rect key="frame" x="0.0" y="0.0" width="640" height="550"/>
</imageView>
</subviews>
<color key="backgroundColor" white="1" alpha="1" colorSpace="calibratedWhite"/>
<constraints>
<constraint firstItem="mju-qR-F4m" firstAttribute="top" secondItem="fel-JW-y8K" secondAttribute="bottom" id="czL-kW-Gi5"/>
<constraint firstItem="fel-JW-y8K" firstAttribute="top" secondItem="dgq-yB-Neb" secondAttribute="top" id="h6H-Nt-0EU"/>
<constraint firstItem="fel-JW-y8K" firstAttribute="leading" secondItem="dgq-yB-Neb" secondAttribute="leading" id="lvq-kK-shl"/>
<constraint firstAttribute="trailing" secondItem="fel-JW-y8K" secondAttribute="trailing" id="mnN-oR-w60"/>
</constraints>
</view>
<tabBarItem key="tabBarItem" title="Item" id="uWZ-JL-cND" customClass="AdaptiveTabBarItem" customModule="example_count_launches_adaptive_tabbar" customModuleProvider="target"/>
<tabBarItem key="tabBarItem" title="Item" id="uWZ-JL-cND" customClass="AdaptiveTabBarItem" customModule="adaptive_tab_bar" customModuleProvider="target"/>
</viewController>
<placeholder placeholderIdentifier="IBFirstResponder" id="xAq-zT-Wnn" userLabel="First Responder" sceneMemberID="firstResponder"/>
</objects>
@@ -215,5 +187,6 @@
</scenes>
<resources>
<image name="background" width="640" height="1136"/>
<image name="second" width="30" height="30"/>
</resources>
</document>
@@ -17,19 +17,12 @@ class AdaptiveTabBarItem: UITabBarItem , AdaptiveApperanceProtocol {
}
func setFontToAdaptiveButton(font: UIFont , controlState:UIControlState){
func setFontToAdaptiveButton(font: UIFont){
self.setTitleTextAttributes(NSDictionary(objects: [font], forKeys: [NSFontAttributeName]), forState: controlState)
self.setTitleTextAttributes(NSDictionary(objects: [font], forKeys: [NSFontAttributeName]), forState: UIControlState.Normal)
}
func setTitleColorToAdaptiveButton(color: UIColor, controlState:UIControlState){
var dictionary = self.titleTextAttributesForState(UIControlState.Normal)
dictionary.updateValue(color, forKey: NSForegroundColorAttributeName)
self.setTitleTextAttributes(dictionary, forState: controlState)
}
func setTitleToAdaptiveButton(text: NSString){
self.title = text
}
@@ -50,7 +43,11 @@ class AdaptiveTabBarItem: UITabBarItem , AdaptiveApperanceProtocol {
self.setTitlePositionAdjustment(offset)
}
func setTitleColorToAdaptiveButton(color: UIColor){
var dictionary = self.titleTextAttributesForState(UIControlState.Normal)
dictionary.updateValue(color, forKey: NSForegroundColorAttributeName)
self.setTitleTextAttributes(dictionary, forState: UIControlState.Normal)
}
@@ -0,0 +1,96 @@
<?xml version="1.0" encoding="UTF-8"?>
<Scheme
LastUpgradeVersion = "0600"
version = "1.3">
<BuildAction
parallelizeBuildables = "YES"
buildImplicitDependencies = "YES">
<BuildActionEntries>
<BuildActionEntry
buildForTesting = "YES"
buildForRunning = "YES"
buildForProfiling = "NO"
buildForArchiving = "NO"
buildForAnalyzing = "YES">
<BuildableReference
BuildableIdentifier = "primary"
BlueprintIdentifier = "6A5558C919E2BAB100ED3B5C"
BuildableName = "example-count-launches-adaptive-tabbarTests.xctest"
BlueprintName = "example-count-launches-adaptive-tabbarTests"
ReferencedContainer = "container:example-count-launches-adaptive-tabbar.xcodeproj">
</BuildableReference>
</BuildActionEntry>
</BuildActionEntries>
</BuildAction>
<TestAction
selectedDebuggerIdentifier = "Xcode.DebuggerFoundation.Debugger.LLDB"
selectedLauncherIdentifier = "Xcode.DebuggerFoundation.Launcher.LLDB"
shouldUseLaunchSchemeArgsEnv = "YES"
buildConfiguration = "Debug">
<Testables>
<TestableReference
skipped = "NO">
<BuildableReference
BuildableIdentifier = "primary"
BlueprintIdentifier = "6A5558C919E2BAB100ED3B5C"
BuildableName = "example-count-launches-adaptive-tabbarTests.xctest"
BlueprintName = "example-count-launches-adaptive-tabbarTests"
ReferencedContainer = "container:example-count-launches-adaptive-tabbar.xcodeproj">
</BuildableReference>
</TestableReference>
</Testables>
<MacroExpansion>
<BuildableReference
BuildableIdentifier = "primary"
BlueprintIdentifier = "6A5558C919E2BAB100ED3B5C"
BuildableName = "example-count-launches-adaptive-tabbarTests.xctest"
BlueprintName = "example-count-launches-adaptive-tabbarTests"
ReferencedContainer = "container:example-count-launches-adaptive-tabbar.xcodeproj">
</BuildableReference>
</MacroExpansion>
</TestAction>
<LaunchAction
selectedDebuggerIdentifier = "Xcode.DebuggerFoundation.Debugger.LLDB"
selectedLauncherIdentifier = "Xcode.DebuggerFoundation.Launcher.LLDB"
launchStyle = "0"
useCustomWorkingDirectory = "NO"
buildConfiguration = "Debug"
ignoresPersistentStateOnLaunch = "NO"
debugDocumentVersioning = "YES"
allowLocationSimulation = "YES">
<MacroExpansion>
<BuildableReference
BuildableIdentifier = "primary"
BlueprintIdentifier = "6A5558C919E2BAB100ED3B5C"
BuildableName = "example-count-launches-adaptive-tabbarTests.xctest"
BlueprintName = "example-count-launches-adaptive-tabbarTests"
ReferencedContainer = "container:example-count-launches-adaptive-tabbar.xcodeproj">
</BuildableReference>
</MacroExpansion>
<AdditionalOptions>
</AdditionalOptions>
</LaunchAction>
<ProfileAction
shouldUseLaunchSchemeArgsEnv = "YES"
savedToolIdentifier = ""
useCustomWorkingDirectory = "NO"
buildConfiguration = "Release"
debugDocumentVersioning = "YES">
<MacroExpansion>
<BuildableReference
BuildableIdentifier = "primary"
BlueprintIdentifier = "6A5558C919E2BAB100ED3B5C"
BuildableName = "example-count-launches-adaptive-tabbarTests.xctest"
BlueprintName = "example-count-launches-adaptive-tabbarTests"
ReferencedContainer = "container:example-count-launches-adaptive-tabbar.xcodeproj">
</BuildableReference>
</MacroExpansion>
</ProfileAction>
<AnalyzeAction
buildConfiguration = "Debug">
</AnalyzeAction>
<ArchiveAction
buildConfiguration = "Release"
revealArchiveInOrganizer = "YES">
</ArchiveAction>
</Scheme>
@@ -7,7 +7,12 @@
<key>example-count-launches-adaptive-tabbar.xcscheme_^#shared#^_</key>
<dict>
<key>orderHint</key>
<integer>2</integer>
<integer>0</integer>
</dict>
<key>example-count-launches-adaptive-tabbarTests.xcscheme</key>
<dict>
<key>orderHint</key>
<integer>1</integer>
</dict>
</dict>
<key>SuppressBuildableAutocreation</key>
@@ -8,6 +8,6 @@
location = "group:Samples/adaptive-launches-tabbar/example-count-launches-adaptive-tabbar.xcodeproj">
</FileRef>
<FileRef
location = "group:AdaptiveController/AdaptiveController.xcodeproj">
location = "group:Pods/Pods.xcodeproj">
</FileRef>
</Workspace>
@@ -14,11 +14,11 @@
<string>https://github.com/Ramotion/adaptive-tab-bar.git</string>
</dict>
<key>IDESourceControlProjectPath</key>
<string>SamplesAdaptiveController.xcworkspace</string>
<string>adaptive-tab-bar/SamplesAdaptiveController.xcworkspace</string>
<key>IDESourceControlProjectRelativeInstallPathDictionary</key>
<dict>
<key>552AF48197B9D7FDBD86FA325146F289549818B8</key>
<string>..</string>
<string>../..</string>
</dict>
<key>IDESourceControlProjectURL</key>
<string>https://github.com/Ramotion/adaptive-tab-bar.git</string>
@@ -2,23 +2,9 @@
<!DOCTYPE plist PUBLIC "-//Apple//DTD PLIST 1.0//EN" "http://www.apple.com/DTDs/PropertyList-1.0.dtd">
<plist version="1.0">
<dict>
<key>BuildLocationStyle</key>
<string>UseAppPreferences</string>
<key>CustomBuildLocationType</key>
<string>RelativeToDerivedData</string>
<key>DerivedDataCustomLocation</key>
<string>DerivedData</string>
<key>DerivedDataLocationStyle</key>
<string>WorkspaceRelativePath</string>
<key>HasAskedToTakeAutomaticSnapshotBeforeSignificantChanges</key>
<true/>
<key>IssueFilterStyle</key>
<string>ShowActiveSchemeOnly</string>
<key>LiveSourceIssuesEnabled</key>
<true/>
<key>SnapshotAutomaticallyBeforeSignificantChanges</key>
<true/>
<key>SnapshotLocationStyle</key>
<string>Default</string>
</dict>
</plist>
@@ -3,302 +3,6 @@
type = "0"
version = "2.0">
<Breakpoints>
<BreakpointProxy
BreakpointExtensionID = "Xcode.Breakpoint.FileBreakpoint">
<BreakpointContent
shouldBeEnabled = "No"
ignoreCount = "0"
continueAfterRunningActions = "No"
filePath = "AdaptiveController/AdaptiveController/AdaptiveButtonsStateManager.swift"
timestampString = "437574364.516451"
startingColumnNumber = "9223372036854775807"
endingColumnNumber = "9223372036854775807"
startingLineNumber = "54"
endingLineNumber = "54"
landmarkName = "setupButtonsAppearanceFromState(_:buttonsAray:buttonsAppearances:)"
landmarkType = "5">
<Locations>
<Location
shouldBeEnabled = "No"
ignoreCount = "0"
continueAfterRunningActions = "No"
symbolName = "AdaptiveController.AdaptiveButtonsStateManager.setupButtonsAppearanceFromState &lt;A&gt;(AdaptiveController.AdaptiveButtonsStateManager&lt;A&gt;.Type)(A, buttonsAray : Swift.Array&lt;AdaptiveController.AdaptiveApperanceProtocol&gt;, buttonsAppearances : Swift.Array&lt;AdaptiveController.AdaptiveButtonAppearance&gt;) -&gt; ()"
moduleName = "AdaptiveController"
urlString = "file:///Users/arcilite/adaptive-tab-bar/AdaptiveController/AdaptiveController/AdaptiveButtonsStateManager.swift"
timestampString = "437511910.467646"
startingColumnNumber = "9223372036854775807"
endingColumnNumber = "9223372036854775807"
startingLineNumber = "62"
endingLineNumber = "62"
offsetFromSymbolStart = "6790">
</Location>
<Location
shouldBeEnabled = "No"
ignoreCount = "0"
continueAfterRunningActions = "No"
symbolName = "reabstraction thunk helper &lt;T_0_0 where T_0_0: AdaptiveController.AdaptiveState&gt; from @callee_owned (@unowned Swift.Optional&lt;ObjectiveC.UIImage&gt;) -&gt; (@unowned ()) to @callee_owned (@owned Swift.Optional&lt;ObjectiveC.UIImage&gt;) -&gt; (@unowned ())"
moduleName = "AdaptiveController"
urlString = "file:///Users/arcilite/adaptive-tab-bar/AdaptiveController/AdaptiveController/AdaptiveButtonsStateManager.swift"
timestampString = "437511910.467845"
startingColumnNumber = "9223372036854775807"
endingColumnNumber = "9223372036854775807"
startingLineNumber = "62"
endingLineNumber = "62"
offsetFromSymbolStart = "15">
</Location>
<Location
shouldBeEnabled = "No"
ignoreCount = "0"
continueAfterRunningActions = "No"
symbolName = "reabstraction thunk helper &lt;T_0_0 where T_0_0: AdaptiveController.AdaptiveState&gt; from @callee_owned (@owned Swift.Optional&lt;ObjectiveC.UIImage&gt;) -&gt; (@unowned ()) to @callee_owned (@in Swift.Optional&lt;ObjectiveC.UIImage&gt;) -&gt; (@out ())"
moduleName = "AdaptiveController"
urlString = "file:///Users/arcilite/adaptive-tab-bar/AdaptiveController/AdaptiveController/AdaptiveButtonsStateManager.swift"
timestampString = "437511910.468033"
startingColumnNumber = "9223372036854775807"
endingColumnNumber = "9223372036854775807"
startingLineNumber = "62"
endingLineNumber = "62"
offsetFromSymbolStart = "22">
</Location>
<Location
shouldBeEnabled = "No"
ignoreCount = "0"
continueAfterRunningActions = "No"
symbolName = "reabstraction thunk helper &lt;T_0_0 where T_0_0: AdaptiveController.AdaptiveState&gt; from @callee_owned (@in Swift.Optional&lt;ObjectiveC.UIImage&gt;) -&gt; (@out ()) to @callee_owned (@owned Swift.Optional&lt;ObjectiveC.UIImage&gt;) -&gt; (@unowned ())"
moduleName = "AdaptiveController"
urlString = "file:///Users/arcilite/adaptive-tab-bar/AdaptiveController/AdaptiveController/AdaptiveButtonsStateManager.swift"
timestampString = "437511910.468154"
startingColumnNumber = "9223372036854775807"
endingColumnNumber = "9223372036854775807"
startingLineNumber = "62"
endingLineNumber = "62"
offsetFromSymbolStart = "27">
</Location>
</Locations>
</BreakpointContent>
</BreakpointProxy>
<BreakpointProxy
BreakpointExtensionID = "Xcode.Breakpoint.FileBreakpoint">
<BreakpointContent
shouldBeEnabled = "No"
ignoreCount = "0"
continueAfterRunningActions = "No"
filePath = "Samples/adaptive-launches-tabbar/adaptive-launches-tabbar/CustomTabBar/AdaptiveTabBarItem.swift"
timestampString = "437511146.16835"
startingColumnNumber = "9223372036854775807"
endingColumnNumber = "9223372036854775807"
startingLineNumber = "38"
endingLineNumber = "38"
landmarkName = "setImageToAdaptiveButton(_:)"
landmarkType = "5">
</BreakpointContent>
</BreakpointProxy>
<BreakpointProxy
BreakpointExtensionID = "Xcode.Breakpoint.FileBreakpoint">
<BreakpointContent
shouldBeEnabled = "No"
ignoreCount = "0"
continueAfterRunningActions = "No"
filePath = "Samples/adaptive-launches-tabbar/adaptive-launches-tabbar/CustomTabBar/AdaptiveTabBarItem.swift"
timestampString = "437556805.775899"
startingColumnNumber = "9223372036854775807"
endingColumnNumber = "9223372036854775807"
startingLineNumber = "22"
endingLineNumber = "22"
landmarkName = "setFontToAdaptiveButton(_:controlState:)"
landmarkType = "5">
</BreakpointContent>
</BreakpointProxy>
<BreakpointProxy
BreakpointExtensionID = "Xcode.Breakpoint.FileBreakpoint">
<BreakpointContent
shouldBeEnabled = "No"
ignoreCount = "0"
continueAfterRunningActions = "No"
filePath = "Samples/adaptive-launches-tabbar/adaptive-launches-tabbar/CustomTabBar/AdaptiveTabBarItem.swift"
timestampString = "437556819.298386"
startingColumnNumber = "9223372036854775807"
endingColumnNumber = "9223372036854775807"
startingLineNumber = "21"
endingLineNumber = "21"
landmarkName = "setFontToAdaptiveButton(_:controlState:)"
landmarkType = "5">
</BreakpointContent>
</BreakpointProxy>
<BreakpointProxy
BreakpointExtensionID = "Xcode.Breakpoint.FileBreakpoint">
<BreakpointContent
shouldBeEnabled = "No"
ignoreCount = "0"
continueAfterRunningActions = "No"
filePath = "Samples/adaptive-launches-tabbar/adaptive-launches-tabbar/CustomTabBar/AdaptiveTabBarItem.swift"
timestampString = "437556837.150922"
startingColumnNumber = "9223372036854775807"
endingColumnNumber = "9223372036854775807"
startingLineNumber = "29"
endingLineNumber = "29"
landmarkName = "setTitleColorToAdaptiveButton(_:controlState:)"
landmarkType = "5">
</BreakpointContent>
</BreakpointProxy>
<BreakpointProxy
BreakpointExtensionID = "Xcode.Breakpoint.FileBreakpoint">
<BreakpointContent
shouldBeEnabled = "No"
ignoreCount = "0"
continueAfterRunningActions = "No"
filePath = "Samples/adaptive-launches-tabbar/adaptive-launches-tabbar/CustomTabBar/AdaptiveTabBarItem.swift"
timestampString = "437556844.951962"
startingColumnNumber = "9223372036854775807"
endingColumnNumber = "9223372036854775807"
startingLineNumber = "27"
endingLineNumber = "27"
landmarkName = "setTitleColorToAdaptiveButton(_:controlState:)"
landmarkType = "5">
</BreakpointContent>
</BreakpointProxy>
<BreakpointProxy
BreakpointExtensionID = "Xcode.Breakpoint.FileBreakpoint">
<BreakpointContent
shouldBeEnabled = "No"
ignoreCount = "0"
continueAfterRunningActions = "No"
filePath = "AdaptiveController/AdaptiveController/ControlStateAppearance.swift"
timestampString = "437572295.023066"
startingColumnNumber = "9223372036854775807"
endingColumnNumber = "9223372036854775807"
startingLineNumber = "209"
endingLineNumber = "209"
landmarkName = "setObjectDictionary(_:)"
landmarkType = "5">
</BreakpointContent>
</BreakpointProxy>
<BreakpointProxy
BreakpointExtensionID = "Xcode.Breakpoint.FileBreakpoint">
<BreakpointContent
shouldBeEnabled = "No"
ignoreCount = "0"
continueAfterRunningActions = "No"
filePath = "AdaptiveController/AdaptiveController/AdaptiveButtonsStateManager.swift"
timestampString = "437573877.33263"
startingColumnNumber = "9223372036854775807"
endingColumnNumber = "9223372036854775807"
startingLineNumber = "33"
endingLineNumber = "33"
landmarkName = "setupButtonsAppearanceFromState(_:buttonsAray:buttonsAppearances:)"
landmarkType = "5">
</BreakpointContent>
</BreakpointProxy>
<BreakpointProxy
BreakpointExtensionID = "Xcode.Breakpoint.FileBreakpoint">
<BreakpointContent
shouldBeEnabled = "No"
ignoreCount = "0"
continueAfterRunningActions = "No"
filePath = "AdaptiveController/AdaptiveController/AdaptiveDateState.swift"
timestampString = "437573962.85138"
startingColumnNumber = "9223372036854775807"
endingColumnNumber = "9223372036854775807"
startingLineNumber = "43"
endingLineNumber = "43"
landmarkName = "stateRemainDays(_:countDaysToSmallTextState:countDaysToImageState:)"
landmarkType = "5">
</BreakpointContent>
</BreakpointProxy>
<BreakpointProxy
BreakpointExtensionID = "Xcode.Breakpoint.FileBreakpoint">
<BreakpointContent
shouldBeEnabled = "No"
ignoreCount = "0"
continueAfterRunningActions = "No"
filePath = "AdaptiveController/AdaptiveController/AdaptiveDateState.swift"
timestampString = "437573964.596475"
startingColumnNumber = "9223372036854775807"
endingColumnNumber = "9223372036854775807"
startingLineNumber = "46"
endingLineNumber = "46"
landmarkName = "stateRemainDays(_:countDaysToSmallTextState:countDaysToImageState:)"
landmarkType = "5">
</BreakpointContent>
</BreakpointProxy>
<BreakpointProxy
BreakpointExtensionID = "Xcode.Breakpoint.FileBreakpoint">
<BreakpointContent
shouldBeEnabled = "No"
ignoreCount = "0"
continueAfterRunningActions = "No"
filePath = "AdaptiveController/AdaptiveController/AdaptiveDateState.swift"
timestampString = "437573967.947855"
startingColumnNumber = "9223372036854775807"
endingColumnNumber = "9223372036854775807"
startingLineNumber = "22"
endingLineNumber = "22"
landmarkName = "init(installDate:currentDate:countDaysToSmallTextState:countDaysToImageState:)"
landmarkType = "5">
<Locations>
<Location
shouldBeEnabled = "No"
ignoreCount = "0"
continueAfterRunningActions = "No"
symbolName = "AdaptiveController.AdaptiveDateState.init (AdaptiveController.AdaptiveDateState.Type)(installDate : ObjectiveC.NSDate, currentDate : ObjectiveC.NSDate, countDaysToSmallTextState : Swift.Int, countDaysToImageState : Swift.Int) -&gt; AdaptiveController.AdaptiveDateState"
moduleName = "AdaptiveController"
urlString = "file:///Users/arcilite/adaptive-tab-bar/AdaptiveController/AdaptiveController/AdaptiveDateState.swift"
timestampString = "437574130.940246"
startingColumnNumber = "9223372036854775807"
endingColumnNumber = "9223372036854775807"
startingLineNumber = "23"
endingLineNumber = "23"
offsetFromSymbolStart = "261">
</Location>
<Location
shouldBeEnabled = "No"
ignoreCount = "0"
continueAfterRunningActions = "No"
symbolName = "AdaptiveController.AdaptiveDateState.init (AdaptiveController.AdaptiveDateState.Type)(installDate : ObjectiveC.NSDate, currentDate : ObjectiveC.NSDate, countDaysToSmallTextState : Swift.Int, countDaysToImageState : Swift.Int) -&gt; AdaptiveController.AdaptiveDateState"
moduleName = "AdaptiveController"
urlString = "file:///Users/arcilite/adaptive-tab-bar/AdaptiveController/AdaptiveController/AdaptiveDateState.swift"
timestampString = "437574130.940351"
startingColumnNumber = "9223372036854775807"
endingColumnNumber = "9223372036854775807"
startingLineNumber = "23"
endingLineNumber = "23"
offsetFromSymbolStart = "283">
</Location>
</Locations>
</BreakpointContent>
</BreakpointProxy>
<BreakpointProxy
BreakpointExtensionID = "Xcode.Breakpoint.FileBreakpoint">
<BreakpointContent
shouldBeEnabled = "No"
ignoreCount = "0"
continueAfterRunningActions = "No"
filePath = "AdaptiveController/AdaptiveController/AdaptiveButtonsStateManager.swift"
timestampString = "437574364.516451"
startingColumnNumber = "9223372036854775807"
endingColumnNumber = "9223372036854775807"
startingLineNumber = "41"
endingLineNumber = "41"
landmarkName = "setupButtonsAppearanceFromState(_:buttonsAray:buttonsAppearances:)"
landmarkType = "5">
</BreakpointContent>
</BreakpointProxy>
<BreakpointProxy
BreakpointExtensionID = "Xcode.Breakpoint.FileBreakpoint">
<BreakpointContent
shouldBeEnabled = "No"
ignoreCount = "0"
continueAfterRunningActions = "No"
filePath = "AdaptiveController/AdaptiveController/AdaptiveButtonsStateManager.swift"
timestampString = "437574360.622633"
startingColumnNumber = "9223372036854775807"
endingColumnNumber = "9223372036854775807"
startingLineNumber = "40"
endingLineNumber = "40"
landmarkName = "setupButtonsAppearanceFromState(_:buttonsAray:buttonsAppearances:)"
landmarkType = "5">
</BreakpointContent>
</BreakpointProxy>
<BreakpointProxy
BreakpointExtensionID = "Xcode.Breakpoint.FileBreakpoint">
<BreakpointContent
@@ -306,44 +10,12 @@
ignoreCount = "0"
continueAfterRunningActions = "No"
filePath = "AdaptiveController/AdaptiveController/AdaptiveButtonAppearance.swift"
timestampString = "437574477.784606"
timestampString = "434471100.953196"
startingColumnNumber = "9223372036854775807"
endingColumnNumber = "9223372036854775807"
startingLineNumber = "46"
endingLineNumber = "46"
landmarkName = "setObjectDictionary(_:)"
landmarkType = "5">
</BreakpointContent>
</BreakpointProxy>
<BreakpointProxy
BreakpointExtensionID = "Xcode.Breakpoint.FileBreakpoint">
<BreakpointContent
shouldBeEnabled = "Yes"
ignoreCount = "0"
continueAfterRunningActions = "No"
filePath = "Samples/adaptive-dates-tabbar/adaptive-tab-bar/CustomTabBar/AdaptiveTabBarItem.swift"
timestampString = "437677746.631783"
startingColumnNumber = "9223372036854775807"
endingColumnNumber = "9223372036854775807"
startingLineNumber = "29"
endingLineNumber = "29"
landmarkName = "setImageToAdaptiveButton(_:)"
landmarkType = "5">
</BreakpointContent>
</BreakpointProxy>
<BreakpointProxy
BreakpointExtensionID = "Xcode.Breakpoint.FileBreakpoint">
<BreakpointContent
shouldBeEnabled = "No"
ignoreCount = "0"
continueAfterRunningActions = "No"
filePath = "AdaptiveController/AdaptiveControllerTests/AdaptiveButtonAppearanceTest.swift"
timestampString = "438276611.63638"
startingColumnNumber = "9223372036854775807"
endingColumnNumber = "9223372036854775807"
startingLineNumber = "21"
endingLineNumber = "21"
landmarkName = "testAppearanceSetup()"
startingLineNumber = "52"
endingLineNumber = "52"
landmarkName = "setImageNamesForStatesImageExtesions(_:imageExtensionsForState:)"
landmarkType = "5">
</BreakpointContent>
</BreakpointProxy>
@@ -354,41 +26,137 @@
ignoreCount = "0"
continueAfterRunningActions = "No"
filePath = "AdaptiveController/AdaptiveControllerTests/AdaptiveDateStateTest.swift"
timestampString = "437905449.96838"
timestampString = "434966468.950239"
startingColumnNumber = "9223372036854775807"
endingColumnNumber = "9223372036854775807"
startingLineNumber = "37"
endingLineNumber = "37"
landmarkName = "testDefaultState()"
startingLineNumber = "33"
endingLineNumber = "33"
landmarkName = "tearDown()"
landmarkType = "5">
</BreakpointContent>
</BreakpointProxy>
<BreakpointProxy
BreakpointExtensionID = "Xcode.Breakpoint.FileBreakpoint">
<BreakpointContent
shouldBeEnabled = "No"
ignoreCount = "0"
continueAfterRunningActions = "No"
filePath = "AdaptiveController/AdaptiveController/AdaptiveButtonAppearance.swift"
timestampString = "435240731.057037"
startingColumnNumber = "9223372036854775807"
endingColumnNumber = "9223372036854775807"
startingLineNumber = "60"
endingLineNumber = "60"
landmarkName = "setButonTitle(_:state:)"
landmarkType = "5">
</BreakpointContent>
</BreakpointProxy>
<BreakpointProxy
BreakpointExtensionID = "Xcode.Breakpoint.FileBreakpoint">
<BreakpointContent
shouldBeEnabled = "No"
ignoreCount = "0"
continueAfterRunningActions = "No"
filePath = "AdaptiveController/AdaptiveController/AdaptiveButtonAppearance.swift"
timestampString = "435241015.75753"
startingColumnNumber = "9223372036854775807"
endingColumnNumber = "9223372036854775807"
startingLineNumber = "68"
endingLineNumber = "68"
landmarkName = "getButonTitleForState(_:)"
landmarkType = "5">
</BreakpointContent>
</BreakpointProxy>
<BreakpointProxy
BreakpointExtensionID = "Xcode.Breakpoint.FileBreakpoint">
<BreakpointContent
shouldBeEnabled = "No"
ignoreCount = "0"
continueAfterRunningActions = "No"
filePath = "AdaptiveController/AdaptiveController/AdaptiveButtonAppearance.swift"
timestampString = "435241018.694539"
startingColumnNumber = "9223372036854775807"
endingColumnNumber = "9223372036854775807"
startingLineNumber = "71"
endingLineNumber = "71"
landmarkName = "getButonTitleForState(_:)"
landmarkType = "5">
</BreakpointContent>
</BreakpointProxy>
<BreakpointProxy
BreakpointExtensionID = "Xcode.Breakpoint.FileBreakpoint">
<BreakpointContent
shouldBeEnabled = "No"
ignoreCount = "0"
continueAfterRunningActions = "No"
filePath = "AdaptiveController/AdaptiveController/AdaptiveButtonAppearance.swift"
timestampString = "435241020.267833"
startingColumnNumber = "9223372036854775807"
endingColumnNumber = "9223372036854775807"
startingLineNumber = "73"
endingLineNumber = "73"
landmarkName = "getButonTitleForState(_:)"
landmarkType = "5">
</BreakpointContent>
</BreakpointProxy>
<BreakpointProxy
BreakpointExtensionID = "Xcode.Breakpoint.FileBreakpoint">
<BreakpointContent
shouldBeEnabled = "No"
ignoreCount = "0"
continueAfterRunningActions = "No"
filePath = "AdaptiveController/AdaptiveController/AdaptiveButtonAppearance.swift"
timestampString = "435241219.58597"
startingColumnNumber = "9223372036854775807"
endingColumnNumber = "9223372036854775807"
startingLineNumber = "67"
endingLineNumber = "67"
landmarkName = "getButonTitleForState(_:)"
landmarkType = "5">
</BreakpointContent>
</BreakpointProxy>
<BreakpointProxy
BreakpointExtensionID = "Xcode.Breakpoint.FileBreakpoint">
<BreakpointContent
shouldBeEnabled = "No"
ignoreCount = "0"
continueAfterRunningActions = "No"
filePath = "AdaptiveController/AdaptiveControllerTests/TestTabBarItem.swift"
timestampString = "435310351.588265"
startingColumnNumber = "9223372036854775807"
endingColumnNumber = "9223372036854775807"
startingLineNumber = "63"
endingLineNumber = "63"
landmarkName = "setTitleColorToAdaptiveButton(_:)"
landmarkType = "5">
<Locations>
<Location
shouldBeEnabled = "No"
ignoreCount = "0"
continueAfterRunningActions = "No"
symbolName = "AdaptiveControllerTests.AdaptiveDateStateTest.testDefaultState (AdaptiveControllerTests.AdaptiveDateStateTest)() -&gt; ()"
symbolName = "AdaptiveControllerTests.TestTabBarItem.setTitleColorToAdaptiveButton (AdaptiveControllerTests.TestTabBarItem)(ObjectiveC.UIColor) -&gt; ()"
moduleName = "AdaptiveControllerTests"
urlString = "file:///Users/arcilite/adaptive-tab-bar/AdaptiveController/AdaptiveControllerTests/AdaptiveDateStateTest.swift"
timestampString = "437915565.762825"
urlString = "file:///Users/arcilite/adaptive-tab-bar/adaptive-tab-bar/AdaptiveController/AdaptiveControllerTests/TestTabBarItem.swift"
timestampString = "435241968.974153"
startingColumnNumber = "9223372036854775807"
endingColumnNumber = "9223372036854775807"
startingLineNumber = "37"
endingLineNumber = "37"
offsetFromSymbolStart = "46">
startingLineNumber = "59"
endingLineNumber = "59"
offsetFromSymbolStart = "27">
</Location>
<Location
shouldBeEnabled = "No"
ignoreCount = "0"
continueAfterRunningActions = "No"
symbolName = "AdaptiveControllerTests.AdaptiveDateStateTest.(testDefaultState (AdaptiveControllerTests.AdaptiveDateStateTest) -&gt; () -&gt; ()).(implicit closure #1)"
symbolName = "AdaptiveControllerTests.TestTabBarItem.(setTitleColorToAdaptiveButton (AdaptiveControllerTests.TestTabBarItem) -&gt; (ObjectiveC.UIColor) -&gt; ()).(implicit closure #1)"
moduleName = "AdaptiveControllerTests"
urlString = "file:///Users/arcilite/adaptive-tab-bar/AdaptiveController/AdaptiveControllerTests/AdaptiveDateStateTest.swift"
timestampString = "437915565.763012"
urlString = "file:///Users/arcilite/adaptive-tab-bar/adaptive-tab-bar/AdaptiveController/AdaptiveControllerTests/TestTabBarItem.swift"
timestampString = "435241968.974291"
startingColumnNumber = "9223372036854775807"
endingColumnNumber = "9223372036854775807"
startingLineNumber = "37"
endingLineNumber = "37"
offsetFromSymbolStart = "45">
startingLineNumber = "59"
endingLineNumber = "59"
offsetFromSymbolStart = "48">
</Location>
</Locations>
</BreakpointContent>
@@ -399,13 +167,59 @@
shouldBeEnabled = "No"
ignoreCount = "0"
continueAfterRunningActions = "No"
filePath = "AdaptiveController/AdaptiveControllerTests/AdaptiveLaunchesStateTest.swift"
timestampString = "437915542.065597"
filePath = "AdaptiveController/AdaptiveControllerTests/TestTabBarItem.swift"
timestampString = "435310351.588265"
startingColumnNumber = "9223372036854775807"
endingColumnNumber = "9223372036854775807"
startingLineNumber = "52"
endingLineNumber = "52"
landmarkName = "testImageState()"
startingLineNumber = "42"
endingLineNumber = "42"
landmarkName = "setImageToAdaptiveButton(_:)"
landmarkType = "5">
<Locations>
<Location
shouldBeEnabled = "No"
ignoreCount = "0"
continueAfterRunningActions = "No"
symbolName = "AdaptiveControllerTests.TestTabBarItem.setImageToAdaptiveButton (AdaptiveControllerTests.TestTabBarItem)(ObjectiveC.UIImage) -&gt; ()"
moduleName = "AdaptiveControllerTests"
urlString = "file:///Users/arcilite/adaptive-tab-bar/adaptive-tab-bar/AdaptiveController/AdaptiveControllerTests/TestTabBarItem.swift"
timestampString = "435241968.97443"
startingColumnNumber = "9223372036854775807"
endingColumnNumber = "9223372036854775807"
startingLineNumber = "41"
endingLineNumber = "41"
offsetFromSymbolStart = "27">
</Location>
<Location
shouldBeEnabled = "No"
ignoreCount = "0"
continueAfterRunningActions = "No"
symbolName = "AdaptiveControllerTests.TestTabBarItem.(setImageToAdaptiveButton (AdaptiveControllerTests.TestTabBarItem) -&gt; (ObjectiveC.UIImage) -&gt; ()).(implicit closure #1)"
moduleName = "AdaptiveControllerTests"
urlString = "file:///Users/arcilite/adaptive-tab-bar/adaptive-tab-bar/AdaptiveController/AdaptiveControllerTests/TestTabBarItem.swift"
timestampString = "435241968.974569"
startingColumnNumber = "9223372036854775807"
endingColumnNumber = "9223372036854775807"
startingLineNumber = "41"
endingLineNumber = "41"
offsetFromSymbolStart = "48">
</Location>
</Locations>
</BreakpointContent>
</BreakpointProxy>
<BreakpointProxy
BreakpointExtensionID = "Xcode.Breakpoint.FileBreakpoint">
<BreakpointContent
shouldBeEnabled = "Yes"
ignoreCount = "0"
continueAfterRunningActions = "No"
filePath = "AdaptiveController/AdaptiveControllerTests/TestTabBarItem.swift"
timestampString = "435310351.588265"
startingColumnNumber = "9223372036854775807"
endingColumnNumber = "9223372036854775807"
startingLineNumber = "47"
endingLineNumber = "47"
landmarkName = "setSelectedImageToAdaptiveButton(_:)"
landmarkType = "5">
</BreakpointContent>
</BreakpointProxy>
@@ -415,42 +229,270 @@
shouldBeEnabled = "No"
ignoreCount = "0"
continueAfterRunningActions = "No"
filePath = "AdaptiveController/AdaptiveControllerTests/AdaptiveButtonAppearanceTest.swift"
timestampString = "438277726.218459"
filePath = "AdaptiveController/AdaptiveControllerTests/TestTabBarItem.swift"
timestampString = "435246058.504401"
startingColumnNumber = "9223372036854775807"
endingColumnNumber = "9223372036854775807"
startingLineNumber = "55"
endingLineNumber = "55"
landmarkName = "testAppearanceSetup()"
startingLineNumber = "29"
endingLineNumber = "29"
landmarkName = "setFontToAdaptiveButton(_:)"
landmarkType = "5">
<Locations>
<Location
shouldBeEnabled = "No"
ignoreCount = "0"
continueAfterRunningActions = "No"
symbolName = "AdaptiveControllerTests.AdaptiveButtonAppearanceTest.testAppearanceSetup (AdaptiveControllerTests.AdaptiveButtonAppearanceTest)() -&gt; ()"
symbolName = "AdaptiveControllerTests.TestTabBarItem.setFontToAdaptiveButton (AdaptiveControllerTests.TestTabBarItem)(ObjectiveC.UIFont) -&gt; ()"
moduleName = "AdaptiveControllerTests"
urlString = "file:///Users/arcilite/adaptive-tab-bar/AdaptiveController/AdaptiveControllerTests/AdaptiveButtonAppearanceTest.swift"
timestampString = "438277726.876122"
urlString = "file:///Users/arcilite/adaptive-tab-bar/adaptive-tab-bar/AdaptiveController/AdaptiveControllerTests/TestTabBarItem.swift"
timestampString = "435244047.515732"
startingColumnNumber = "9223372036854775807"
endingColumnNumber = "9223372036854775807"
startingLineNumber = "55"
endingLineNumber = "55"
offsetFromSymbolStart = "4712">
startingLineNumber = "30"
endingLineNumber = "30"
offsetFromSymbolStart = "237">
</Location>
<Location
shouldBeEnabled = "No"
ignoreCount = "0"
continueAfterRunningActions = "No"
symbolName = "AdaptiveControllerTests.AdaptiveButtonAppearanceTest.(testAppearanceSetup (AdaptiveControllerTests.AdaptiveButtonAppearanceTest) -&gt; () -&gt; ()).(implicit closure #2)"
symbolName = "AdaptiveControllerTests.TestTabBarItem.(setFontToAdaptiveButton (AdaptiveControllerTests.TestTabBarItem) -&gt; (ObjectiveC.UIFont) -&gt; ()).(implicit closure #2)"
moduleName = "AdaptiveControllerTests"
urlString = "file:///Users/arcilite/adaptive-tab-bar/AdaptiveController/AdaptiveControllerTests/AdaptiveButtonAppearanceTest.swift"
timestampString = "438277726.876251"
urlString = "file:///Users/arcilite/adaptive-tab-bar/adaptive-tab-bar/AdaptiveController/AdaptiveControllerTests/TestTabBarItem.swift"
timestampString = "435244047.516049"
startingColumnNumber = "9223372036854775807"
endingColumnNumber = "9223372036854775807"
startingLineNumber = "55"
endingLineNumber = "55"
offsetFromSymbolStart = "24">
startingLineNumber = "30"
endingLineNumber = "30"
offsetFromSymbolStart = "48">
</Location>
</Locations>
</BreakpointContent>
</BreakpointProxy>
<BreakpointProxy
BreakpointExtensionID = "Xcode.Breakpoint.FileBreakpoint">
<BreakpointContent
shouldBeEnabled = "No"
ignoreCount = "0"
continueAfterRunningActions = "No"
filePath = "AdaptiveController/AdaptiveControllerTests/TestTabBarItem.swift"
timestampString = "435246058.504401"
startingColumnNumber = "9223372036854775807"
endingColumnNumber = "9223372036854775807"
startingLineNumber = "35"
endingLineNumber = "35"
landmarkName = "setTitleToAdaptiveButton(_:)"
landmarkType = "5">
</BreakpointContent>
</BreakpointProxy>
<BreakpointProxy
BreakpointExtensionID = "Xcode.Breakpoint.FileBreakpoint">
<BreakpointContent
shouldBeEnabled = "No"
ignoreCount = "0"
continueAfterRunningActions = "No"
filePath = "AdaptiveController/AdaptiveControllerTests/TestTabBarItem.swift"
timestampString = "435242969.357178"
startingColumnNumber = "9223372036854775807"
endingColumnNumber = "9223372036854775807"
startingLineNumber = "29"
endingLineNumber = "29"
landmarkName = "setFontToAdaptiveButton(_:)"
landmarkType = "5">
<Locations>
<Location
shouldBeEnabled = "No"
ignoreCount = "0"
continueAfterRunningActions = "No"
symbolName = "AdaptiveControllerTests.TestTabBarItem.setFontToAdaptiveButton (AdaptiveControllerTests.TestTabBarItem)(ObjectiveC.UIFont) -&gt; ()"
moduleName = "AdaptiveControllerTests"
urlString = "file:///Users/arcilite/adaptive-tab-bar/adaptive-tab-bar/AdaptiveController/AdaptiveControllerTests/TestTabBarItem.swift"
timestampString = "435243036.196487"
startingColumnNumber = "9223372036854775807"
endingColumnNumber = "9223372036854775807"
startingLineNumber = "29"
endingLineNumber = "29"
offsetFromSymbolStart = "52">
</Location>
<Location
shouldBeEnabled = "No"
ignoreCount = "0"
continueAfterRunningActions = "No"
symbolName = "AdaptiveControllerTests.TestTabBarItem.(setFontToAdaptiveButton (AdaptiveControllerTests.TestTabBarItem) -&gt; (ObjectiveC.UIFont) -&gt; ()).(implicit closure #1)"
moduleName = "AdaptiveControllerTests"
urlString = "file:///Users/arcilite/adaptive-tab-bar/adaptive-tab-bar/AdaptiveController/AdaptiveControllerTests/TestTabBarItem.swift"
timestampString = "435243036.196689"
startingColumnNumber = "9223372036854775807"
endingColumnNumber = "9223372036854775807"
startingLineNumber = "29"
endingLineNumber = "29"
offsetFromSymbolStart = "15">
</Location>
</Locations>
</BreakpointContent>
</BreakpointProxy>
<BreakpointProxy
BreakpointExtensionID = "Xcode.Breakpoint.FileBreakpoint">
<BreakpointContent
shouldBeEnabled = "No"
ignoreCount = "0"
continueAfterRunningActions = "No"
filePath = "AdaptiveController/AdaptiveController/AdaptiveButtonsStateManager.swift"
timestampString = "435309147.908624"
startingColumnNumber = "9223372036854775807"
endingColumnNumber = "9223372036854775807"
startingLineNumber = "69"
endingLineNumber = "69"
landmarkName = "setButtonsState(_:buttonsAray:buttonsAppearance:)"
landmarkType = "5">
<Locations>
<Location
shouldBeEnabled = "No"
ignoreCount = "0"
continueAfterRunningActions = "No"
symbolName = "AdaptiveController.AdaptiveButtonsStateManager.setButtonsState (AdaptiveController.AdaptiveButtonsStateManager)(AdaptiveController.AdaptiveState, buttonsAray : Swift.Array&lt;AdaptiveController.AdaptiveApperanceProtocol&gt;, buttonsAppearance : Swift.Array&lt;AdaptiveController.AdaptiveButtonAppearance&gt;) -&gt; ()"
moduleName = "AdaptiveController"
urlString = "file:///Users/arcilite/adaptive-tab-bar/adaptive-tab-bar/AdaptiveController/AdaptiveController/AdaptiveButtonsStateManager.swift"
timestampString = "435309261.958128"
startingColumnNumber = "9223372036854775807"
endingColumnNumber = "9223372036854775807"
startingLineNumber = "70"
endingLineNumber = "70"
offsetFromSymbolStart = "4991">
</Location>
<Location
shouldBeEnabled = "No"
ignoreCount = "0"
continueAfterRunningActions = "No"
symbolName = "AdaptiveController.AdaptiveButtonsStateManager.setButtonsState (AdaptiveController.AdaptiveButtonsStateManager)(AdaptiveController.AdaptiveState, buttonsAray : Swift.Array&lt;AdaptiveController.AdaptiveApperanceProtocol&gt;, buttonsAppearance : Swift.Array&lt;AdaptiveController.AdaptiveButtonAppearance&gt;) -&gt; ()"
moduleName = "AdaptiveController"
urlString = "file:///Users/arcilite/adaptive-tab-bar/adaptive-tab-bar/AdaptiveController/AdaptiveController/AdaptiveButtonsStateManager.swift"
timestampString = "435309261.958306"
startingColumnNumber = "9223372036854775807"
endingColumnNumber = "9223372036854775807"
startingLineNumber = "70"
endingLineNumber = "70"
offsetFromSymbolStart = "5343">
</Location>
</Locations>
</BreakpointContent>
</BreakpointProxy>
<BreakpointProxy
BreakpointExtensionID = "Xcode.Breakpoint.FileBreakpoint">
<BreakpointContent
shouldBeEnabled = "No"
ignoreCount = "0"
continueAfterRunningActions = "No"
filePath = "AdaptiveController/AdaptiveController/AdaptiveButtonsStateManager.swift"
timestampString = "435309161.63493"
startingColumnNumber = "9223372036854775807"
endingColumnNumber = "9223372036854775807"
startingLineNumber = "67"
endingLineNumber = "67"
landmarkName = "setButtonsState(_:buttonsAray:buttonsAppearance:)"
landmarkType = "5">
<Locations>
<Location
shouldBeEnabled = "No"
ignoreCount = "0"
continueAfterRunningActions = "No"
symbolName = "AdaptiveController.AdaptiveButtonsStateManager.setButtonsState (AdaptiveController.AdaptiveButtonsStateManager)(AdaptiveController.AdaptiveState, buttonsAray : Swift.Array&lt;AdaptiveController.AdaptiveApperanceProtocol&gt;, buttonsAppearance : Swift.Array&lt;AdaptiveController.AdaptiveButtonAppearance&gt;) -&gt; ()"
moduleName = "AdaptiveController"
urlString = "file:///Users/arcilite/adaptive-tab-bar/adaptive-tab-bar/AdaptiveController/AdaptiveController/AdaptiveButtonsStateManager.swift"
timestampString = "435309261.958489"
startingColumnNumber = "9223372036854775807"
endingColumnNumber = "9223372036854775807"
startingLineNumber = "67"
endingLineNumber = "67"
offsetFromSymbolStart = "3885">
</Location>
<Location
shouldBeEnabled = "No"
ignoreCount = "0"
continueAfterRunningActions = "No"
symbolName = "reabstraction thunk helper from @callee_owned (@unowned Swift.Optional&lt;ObjectiveC.UIImage&gt;) -&gt; (@unowned ()) to @callee_owned (@owned Swift.Optional&lt;ObjectiveC.UIImage&gt;) -&gt; (@unowned ())"
moduleName = "AdaptiveController"
urlString = "file:///Users/arcilite/adaptive-tab-bar/adaptive-tab-bar/AdaptiveController/AdaptiveController/AdaptiveButtonsStateManager.swift"
timestampString = "435309261.958655"
startingColumnNumber = "9223372036854775807"
endingColumnNumber = "9223372036854775807"
startingLineNumber = "67"
endingLineNumber = "67"
offsetFromSymbolStart = "15">
</Location>
<Location
shouldBeEnabled = "No"
ignoreCount = "0"
continueAfterRunningActions = "No"
symbolName = "reabstraction thunk helper from @callee_owned (@owned Swift.Optional&lt;ObjectiveC.UIImage&gt;) -&gt; (@unowned ()) to @callee_owned (@in Swift.Optional&lt;ObjectiveC.UIImage&gt;) -&gt; (@out ())"
moduleName = "AdaptiveController"
urlString = "file:///Users/arcilite/adaptive-tab-bar/adaptive-tab-bar/AdaptiveController/AdaptiveController/AdaptiveButtonsStateManager.swift"
timestampString = "435309261.958823"
startingColumnNumber = "9223372036854775807"
endingColumnNumber = "9223372036854775807"
startingLineNumber = "67"
endingLineNumber = "67"
offsetFromSymbolStart = "16">
</Location>
<Location
shouldBeEnabled = "No"
ignoreCount = "0"
continueAfterRunningActions = "No"
symbolName = "reabstraction thunk helper from @callee_owned (@in Swift.Optional&lt;ObjectiveC.UIImage&gt;) -&gt; (@out ()) to @callee_owned (@owned Swift.Optional&lt;ObjectiveC.UIImage&gt;) -&gt; (@unowned ())"
moduleName = "AdaptiveController"
urlString = "file:///Users/arcilite/adaptive-tab-bar/adaptive-tab-bar/AdaptiveController/AdaptiveController/AdaptiveButtonsStateManager.swift"
timestampString = "435309261.959034"
startingColumnNumber = "9223372036854775807"
endingColumnNumber = "9223372036854775807"
startingLineNumber = "67"
endingLineNumber = "67"
offsetFromSymbolStart = "20">
</Location>
</Locations>
</BreakpointContent>
</BreakpointProxy>
<BreakpointProxy
BreakpointExtensionID = "Xcode.Breakpoint.FileBreakpoint">
<BreakpointContent
shouldBeEnabled = "No"
ignoreCount = "0"
continueAfterRunningActions = "No"
filePath = "AdaptiveController/AdaptiveController/AdaptiveButtonsStateManager.swift"
timestampString = "435309265.926216"
startingColumnNumber = "9223372036854775807"
endingColumnNumber = "9223372036854775807"
startingLineNumber = "68"
endingLineNumber = "68"
landmarkName = "setButtonsState(_:buttonsAray:buttonsAppearance:)"
landmarkType = "5">
<Locations>
<Location
shouldBeEnabled = "No"
ignoreCount = "0"
continueAfterRunningActions = "No"
symbolName = "AdaptiveController.AdaptiveButtonsStateManager.setButtonsState (AdaptiveController.AdaptiveButtonsStateManager)(AdaptiveController.AdaptiveState, buttonsAray : Swift.Array&lt;AdaptiveController.AdaptiveApperanceProtocol&gt;, buttonsAppearance : Swift.Array&lt;AdaptiveController.AdaptiveButtonAppearance&gt;) -&gt; ()"
moduleName = "AdaptiveController"
urlString = "file:///Users/arcilite/adaptive-tab-bar/adaptive-tab-bar/AdaptiveController/AdaptiveController/AdaptiveButtonsStateManager.swift"
timestampString = "435309265.927959"
startingColumnNumber = "9223372036854775807"
endingColumnNumber = "9223372036854775807"
startingLineNumber = "70"
endingLineNumber = "70"
offsetFromSymbolStart = "4991">
</Location>
<Location
shouldBeEnabled = "No"
ignoreCount = "0"
continueAfterRunningActions = "No"
symbolName = "AdaptiveController.AdaptiveButtonsStateManager.setButtonsState (AdaptiveController.AdaptiveButtonsStateManager)(AdaptiveController.AdaptiveState, buttonsAray : Swift.Array&lt;AdaptiveController.AdaptiveApperanceProtocol&gt;, buttonsAppearance : Swift.Array&lt;AdaptiveController.AdaptiveButtonAppearance&gt;) -&gt; ()"
moduleName = "AdaptiveController"
urlString = "file:///Users/arcilite/adaptive-tab-bar/adaptive-tab-bar/AdaptiveController/AdaptiveController/AdaptiveButtonsStateManager.swift"
timestampString = "435309265.928192"
startingColumnNumber = "9223372036854775807"
endingColumnNumber = "9223372036854775807"
startingLineNumber = "70"
endingLineNumber = "70"
offsetFromSymbolStart = "5343">
</Location>
</Locations>
</BreakpointContent>