├── ReadMEImages
└── 1.gif
├── JhtShopCarAnimation
├── Assets.xcassets
│ ├── Contents.json
│ ├── deleteIcon.imageset
│ │ ├── 项目删除.png
│ │ ├── 项目删除@2x.png
│ │ ├── 项目删除@3x.png
│ │ └── Contents.json
│ └── AppIcon.appiconset
│ │ ├── ios-template-120.png
│ │ ├── ios-template-121.png
│ │ ├── ios-template-180.png
│ │ ├── ios-template-58.png
│ │ ├── ios-template-80.png
│ │ ├── ios-template-87.png
│ │ └── Contents.json
├── JhtTemp
│ └── JhtShopCarAnimationImages.bundle
│ │ ├── 0@2x.png
│ │ ├── 0@3x.png
│ │ ├── 10@2x.png
│ │ ├── 10@3x.png
│ │ ├── 11@2x.png
│ │ ├── 11@3x.png
│ │ ├── 12@2x.png
│ │ ├── 12@3x.png
│ │ ├── 13@2x.png
│ │ ├── 13@3x.png
│ │ ├── 14@2x.png
│ │ ├── 14@3x.png
│ │ ├── 15@2x.png
│ │ ├── 15@3x.png
│ │ ├── 16@2x.png
│ │ ├── 16@3x.png
│ │ ├── 1@2x.png
│ │ ├── 1@3x.png
│ │ ├── 2@2x.png
│ │ ├── 2@3x.png
│ │ ├── 3@2x.png
│ │ ├── 3@3x.png
│ │ ├── 4@2x.png
│ │ ├── 4@3x.png
│ │ ├── 5@2x.png
│ │ ├── 5@3x.png
│ │ ├── 6@2x.png
│ │ ├── 6@3x.png
│ │ ├── 7@2x.png
│ │ ├── 7@3x.png
│ │ ├── 8@2x.png
│ │ ├── 8@3x.png
│ │ ├── 9@2x.png
│ │ └── 9@3x.png
├── AnimationViewController
│ ├── AnimationViewController.h
│ └── AnimationViewController.m
├── AppDelegate.h
├── main.m
├── AnimationRecordCell
│ ├── AnimationRecordCell.h
│ └── AnimationRecordCell.m
├── Info.plist
├── Base.lproj
│ ├── Main.storyboard
│ └── LaunchScreen.storyboard
└── AppDelegate.m
├── JhtShopCarAnimation.xcodeproj
├── xcuserdata
│ ├── zl.xcuserdatad
│ │ ├── xcdebugger
│ │ │ └── Breakpoints_v2.xcbkptlist
│ │ └── xcschemes
│ │ │ ├── xcschememanagement.plist
│ │ │ └── JhtShopCarAnimation.xcscheme
│ └── Jht.xcuserdatad
│ │ ├── xcschemes
│ │ ├── xcschememanagement.plist
│ │ └── JhtShopCarAnimation.xcscheme
│ │ └── xcdebugger
│ │ └── Breakpoints_v2.xcbkptlist
├── project.xcworkspace
│ └── contents.xcworkspacedata
└── project.pbxproj
├── .gitignore
├── JhtAnimationTools.podspec
├── LICENSE
├── JhtAnimationTools
├── JhtAnimationTools.h
└── JhtAnimationTools.m
└── README.md
/ReadMEImages/1.gif:
--------------------------------------------------------------------------------
https://raw.githubusercontent.com/jinht/ShopCarAnimation/HEAD/ReadMEImages/1.gif
--------------------------------------------------------------------------------
/JhtShopCarAnimation/Assets.xcassets/Contents.json:
--------------------------------------------------------------------------------
1 | {
2 | "info" : {
3 | "version" : 1,
4 | "author" : "xcode"
5 | }
6 | }
--------------------------------------------------------------------------------
/JhtShopCarAnimation/Assets.xcassets/deleteIcon.imageset/项目删除.png:
--------------------------------------------------------------------------------
https://raw.githubusercontent.com/jinht/ShopCarAnimation/HEAD/JhtShopCarAnimation/Assets.xcassets/deleteIcon.imageset/项目删除.png
--------------------------------------------------------------------------------
/JhtShopCarAnimation/Assets.xcassets/deleteIcon.imageset/项目删除@2x.png:
--------------------------------------------------------------------------------
https://raw.githubusercontent.com/jinht/ShopCarAnimation/HEAD/JhtShopCarAnimation/Assets.xcassets/deleteIcon.imageset/项目删除@2x.png
--------------------------------------------------------------------------------
/JhtShopCarAnimation/Assets.xcassets/deleteIcon.imageset/项目删除@3x.png:
--------------------------------------------------------------------------------
https://raw.githubusercontent.com/jinht/ShopCarAnimation/HEAD/JhtShopCarAnimation/Assets.xcassets/deleteIcon.imageset/项目删除@3x.png
--------------------------------------------------------------------------------
/JhtShopCarAnimation/JhtTemp/JhtShopCarAnimationImages.bundle/0@2x.png:
--------------------------------------------------------------------------------
https://raw.githubusercontent.com/jinht/ShopCarAnimation/HEAD/JhtShopCarAnimation/JhtTemp/JhtShopCarAnimationImages.bundle/0@2x.png
--------------------------------------------------------------------------------
/JhtShopCarAnimation/JhtTemp/JhtShopCarAnimationImages.bundle/0@3x.png:
--------------------------------------------------------------------------------
https://raw.githubusercontent.com/jinht/ShopCarAnimation/HEAD/JhtShopCarAnimation/JhtTemp/JhtShopCarAnimationImages.bundle/0@3x.png
--------------------------------------------------------------------------------
/JhtShopCarAnimation/JhtTemp/JhtShopCarAnimationImages.bundle/10@2x.png:
--------------------------------------------------------------------------------
https://raw.githubusercontent.com/jinht/ShopCarAnimation/HEAD/JhtShopCarAnimation/JhtTemp/JhtShopCarAnimationImages.bundle/10@2x.png
--------------------------------------------------------------------------------
/JhtShopCarAnimation/JhtTemp/JhtShopCarAnimationImages.bundle/10@3x.png:
--------------------------------------------------------------------------------
https://raw.githubusercontent.com/jinht/ShopCarAnimation/HEAD/JhtShopCarAnimation/JhtTemp/JhtShopCarAnimationImages.bundle/10@3x.png
--------------------------------------------------------------------------------
/JhtShopCarAnimation/JhtTemp/JhtShopCarAnimationImages.bundle/11@2x.png:
--------------------------------------------------------------------------------
https://raw.githubusercontent.com/jinht/ShopCarAnimation/HEAD/JhtShopCarAnimation/JhtTemp/JhtShopCarAnimationImages.bundle/11@2x.png
--------------------------------------------------------------------------------
/JhtShopCarAnimation/JhtTemp/JhtShopCarAnimationImages.bundle/11@3x.png:
--------------------------------------------------------------------------------
https://raw.githubusercontent.com/jinht/ShopCarAnimation/HEAD/JhtShopCarAnimation/JhtTemp/JhtShopCarAnimationImages.bundle/11@3x.png
--------------------------------------------------------------------------------
/JhtShopCarAnimation/JhtTemp/JhtShopCarAnimationImages.bundle/12@2x.png:
--------------------------------------------------------------------------------
https://raw.githubusercontent.com/jinht/ShopCarAnimation/HEAD/JhtShopCarAnimation/JhtTemp/JhtShopCarAnimationImages.bundle/12@2x.png
--------------------------------------------------------------------------------
/JhtShopCarAnimation/JhtTemp/JhtShopCarAnimationImages.bundle/12@3x.png:
--------------------------------------------------------------------------------
https://raw.githubusercontent.com/jinht/ShopCarAnimation/HEAD/JhtShopCarAnimation/JhtTemp/JhtShopCarAnimationImages.bundle/12@3x.png
--------------------------------------------------------------------------------
/JhtShopCarAnimation/JhtTemp/JhtShopCarAnimationImages.bundle/13@2x.png:
--------------------------------------------------------------------------------
https://raw.githubusercontent.com/jinht/ShopCarAnimation/HEAD/JhtShopCarAnimation/JhtTemp/JhtShopCarAnimationImages.bundle/13@2x.png
--------------------------------------------------------------------------------
/JhtShopCarAnimation/JhtTemp/JhtShopCarAnimationImages.bundle/13@3x.png:
--------------------------------------------------------------------------------
https://raw.githubusercontent.com/jinht/ShopCarAnimation/HEAD/JhtShopCarAnimation/JhtTemp/JhtShopCarAnimationImages.bundle/13@3x.png
--------------------------------------------------------------------------------
/JhtShopCarAnimation/JhtTemp/JhtShopCarAnimationImages.bundle/14@2x.png:
--------------------------------------------------------------------------------
https://raw.githubusercontent.com/jinht/ShopCarAnimation/HEAD/JhtShopCarAnimation/JhtTemp/JhtShopCarAnimationImages.bundle/14@2x.png
--------------------------------------------------------------------------------
/JhtShopCarAnimation/JhtTemp/JhtShopCarAnimationImages.bundle/14@3x.png:
--------------------------------------------------------------------------------
https://raw.githubusercontent.com/jinht/ShopCarAnimation/HEAD/JhtShopCarAnimation/JhtTemp/JhtShopCarAnimationImages.bundle/14@3x.png
--------------------------------------------------------------------------------
/JhtShopCarAnimation/JhtTemp/JhtShopCarAnimationImages.bundle/15@2x.png:
--------------------------------------------------------------------------------
https://raw.githubusercontent.com/jinht/ShopCarAnimation/HEAD/JhtShopCarAnimation/JhtTemp/JhtShopCarAnimationImages.bundle/15@2x.png
--------------------------------------------------------------------------------
/JhtShopCarAnimation/JhtTemp/JhtShopCarAnimationImages.bundle/15@3x.png:
--------------------------------------------------------------------------------
https://raw.githubusercontent.com/jinht/ShopCarAnimation/HEAD/JhtShopCarAnimation/JhtTemp/JhtShopCarAnimationImages.bundle/15@3x.png
--------------------------------------------------------------------------------
/JhtShopCarAnimation/JhtTemp/JhtShopCarAnimationImages.bundle/16@2x.png:
--------------------------------------------------------------------------------
https://raw.githubusercontent.com/jinht/ShopCarAnimation/HEAD/JhtShopCarAnimation/JhtTemp/JhtShopCarAnimationImages.bundle/16@2x.png
--------------------------------------------------------------------------------
/JhtShopCarAnimation/JhtTemp/JhtShopCarAnimationImages.bundle/16@3x.png:
--------------------------------------------------------------------------------
https://raw.githubusercontent.com/jinht/ShopCarAnimation/HEAD/JhtShopCarAnimation/JhtTemp/JhtShopCarAnimationImages.bundle/16@3x.png
--------------------------------------------------------------------------------
/JhtShopCarAnimation/JhtTemp/JhtShopCarAnimationImages.bundle/1@2x.png:
--------------------------------------------------------------------------------
https://raw.githubusercontent.com/jinht/ShopCarAnimation/HEAD/JhtShopCarAnimation/JhtTemp/JhtShopCarAnimationImages.bundle/1@2x.png
--------------------------------------------------------------------------------
/JhtShopCarAnimation/JhtTemp/JhtShopCarAnimationImages.bundle/1@3x.png:
--------------------------------------------------------------------------------
https://raw.githubusercontent.com/jinht/ShopCarAnimation/HEAD/JhtShopCarAnimation/JhtTemp/JhtShopCarAnimationImages.bundle/1@3x.png
--------------------------------------------------------------------------------
/JhtShopCarAnimation/JhtTemp/JhtShopCarAnimationImages.bundle/2@2x.png:
--------------------------------------------------------------------------------
https://raw.githubusercontent.com/jinht/ShopCarAnimation/HEAD/JhtShopCarAnimation/JhtTemp/JhtShopCarAnimationImages.bundle/2@2x.png
--------------------------------------------------------------------------------
/JhtShopCarAnimation/JhtTemp/JhtShopCarAnimationImages.bundle/2@3x.png:
--------------------------------------------------------------------------------
https://raw.githubusercontent.com/jinht/ShopCarAnimation/HEAD/JhtShopCarAnimation/JhtTemp/JhtShopCarAnimationImages.bundle/2@3x.png
--------------------------------------------------------------------------------
/JhtShopCarAnimation/JhtTemp/JhtShopCarAnimationImages.bundle/3@2x.png:
--------------------------------------------------------------------------------
https://raw.githubusercontent.com/jinht/ShopCarAnimation/HEAD/JhtShopCarAnimation/JhtTemp/JhtShopCarAnimationImages.bundle/3@2x.png
--------------------------------------------------------------------------------
/JhtShopCarAnimation/JhtTemp/JhtShopCarAnimationImages.bundle/3@3x.png:
--------------------------------------------------------------------------------
https://raw.githubusercontent.com/jinht/ShopCarAnimation/HEAD/JhtShopCarAnimation/JhtTemp/JhtShopCarAnimationImages.bundle/3@3x.png
--------------------------------------------------------------------------------
/JhtShopCarAnimation/JhtTemp/JhtShopCarAnimationImages.bundle/4@2x.png:
--------------------------------------------------------------------------------
https://raw.githubusercontent.com/jinht/ShopCarAnimation/HEAD/JhtShopCarAnimation/JhtTemp/JhtShopCarAnimationImages.bundle/4@2x.png
--------------------------------------------------------------------------------
/JhtShopCarAnimation/JhtTemp/JhtShopCarAnimationImages.bundle/4@3x.png:
--------------------------------------------------------------------------------
https://raw.githubusercontent.com/jinht/ShopCarAnimation/HEAD/JhtShopCarAnimation/JhtTemp/JhtShopCarAnimationImages.bundle/4@3x.png
--------------------------------------------------------------------------------
/JhtShopCarAnimation/JhtTemp/JhtShopCarAnimationImages.bundle/5@2x.png:
--------------------------------------------------------------------------------
https://raw.githubusercontent.com/jinht/ShopCarAnimation/HEAD/JhtShopCarAnimation/JhtTemp/JhtShopCarAnimationImages.bundle/5@2x.png
--------------------------------------------------------------------------------
/JhtShopCarAnimation/JhtTemp/JhtShopCarAnimationImages.bundle/5@3x.png:
--------------------------------------------------------------------------------
https://raw.githubusercontent.com/jinht/ShopCarAnimation/HEAD/JhtShopCarAnimation/JhtTemp/JhtShopCarAnimationImages.bundle/5@3x.png
--------------------------------------------------------------------------------
/JhtShopCarAnimation/JhtTemp/JhtShopCarAnimationImages.bundle/6@2x.png:
--------------------------------------------------------------------------------
https://raw.githubusercontent.com/jinht/ShopCarAnimation/HEAD/JhtShopCarAnimation/JhtTemp/JhtShopCarAnimationImages.bundle/6@2x.png
--------------------------------------------------------------------------------
/JhtShopCarAnimation/JhtTemp/JhtShopCarAnimationImages.bundle/6@3x.png:
--------------------------------------------------------------------------------
https://raw.githubusercontent.com/jinht/ShopCarAnimation/HEAD/JhtShopCarAnimation/JhtTemp/JhtShopCarAnimationImages.bundle/6@3x.png
--------------------------------------------------------------------------------
/JhtShopCarAnimation/JhtTemp/JhtShopCarAnimationImages.bundle/7@2x.png:
--------------------------------------------------------------------------------
https://raw.githubusercontent.com/jinht/ShopCarAnimation/HEAD/JhtShopCarAnimation/JhtTemp/JhtShopCarAnimationImages.bundle/7@2x.png
--------------------------------------------------------------------------------
/JhtShopCarAnimation/JhtTemp/JhtShopCarAnimationImages.bundle/7@3x.png:
--------------------------------------------------------------------------------
https://raw.githubusercontent.com/jinht/ShopCarAnimation/HEAD/JhtShopCarAnimation/JhtTemp/JhtShopCarAnimationImages.bundle/7@3x.png
--------------------------------------------------------------------------------
/JhtShopCarAnimation/JhtTemp/JhtShopCarAnimationImages.bundle/8@2x.png:
--------------------------------------------------------------------------------
https://raw.githubusercontent.com/jinht/ShopCarAnimation/HEAD/JhtShopCarAnimation/JhtTemp/JhtShopCarAnimationImages.bundle/8@2x.png
--------------------------------------------------------------------------------
/JhtShopCarAnimation/JhtTemp/JhtShopCarAnimationImages.bundle/8@3x.png:
--------------------------------------------------------------------------------
https://raw.githubusercontent.com/jinht/ShopCarAnimation/HEAD/JhtShopCarAnimation/JhtTemp/JhtShopCarAnimationImages.bundle/8@3x.png
--------------------------------------------------------------------------------
/JhtShopCarAnimation/JhtTemp/JhtShopCarAnimationImages.bundle/9@2x.png:
--------------------------------------------------------------------------------
https://raw.githubusercontent.com/jinht/ShopCarAnimation/HEAD/JhtShopCarAnimation/JhtTemp/JhtShopCarAnimationImages.bundle/9@2x.png
--------------------------------------------------------------------------------
/JhtShopCarAnimation/JhtTemp/JhtShopCarAnimationImages.bundle/9@3x.png:
--------------------------------------------------------------------------------
https://raw.githubusercontent.com/jinht/ShopCarAnimation/HEAD/JhtShopCarAnimation/JhtTemp/JhtShopCarAnimationImages.bundle/9@3x.png
--------------------------------------------------------------------------------
/JhtShopCarAnimation.xcodeproj/xcuserdata/zl.xcuserdatad/xcdebugger/Breakpoints_v2.xcbkptlist:
--------------------------------------------------------------------------------
1 |
2 |
5 |
6 |
--------------------------------------------------------------------------------
/JhtShopCarAnimation/Assets.xcassets/AppIcon.appiconset/ios-template-120.png:
--------------------------------------------------------------------------------
https://raw.githubusercontent.com/jinht/ShopCarAnimation/HEAD/JhtShopCarAnimation/Assets.xcassets/AppIcon.appiconset/ios-template-120.png
--------------------------------------------------------------------------------
/JhtShopCarAnimation/Assets.xcassets/AppIcon.appiconset/ios-template-121.png:
--------------------------------------------------------------------------------
https://raw.githubusercontent.com/jinht/ShopCarAnimation/HEAD/JhtShopCarAnimation/Assets.xcassets/AppIcon.appiconset/ios-template-121.png
--------------------------------------------------------------------------------
/JhtShopCarAnimation/Assets.xcassets/AppIcon.appiconset/ios-template-180.png:
--------------------------------------------------------------------------------
https://raw.githubusercontent.com/jinht/ShopCarAnimation/HEAD/JhtShopCarAnimation/Assets.xcassets/AppIcon.appiconset/ios-template-180.png
--------------------------------------------------------------------------------
/JhtShopCarAnimation/Assets.xcassets/AppIcon.appiconset/ios-template-58.png:
--------------------------------------------------------------------------------
https://raw.githubusercontent.com/jinht/ShopCarAnimation/HEAD/JhtShopCarAnimation/Assets.xcassets/AppIcon.appiconset/ios-template-58.png
--------------------------------------------------------------------------------
/JhtShopCarAnimation/Assets.xcassets/AppIcon.appiconset/ios-template-80.png:
--------------------------------------------------------------------------------
https://raw.githubusercontent.com/jinht/ShopCarAnimation/HEAD/JhtShopCarAnimation/Assets.xcassets/AppIcon.appiconset/ios-template-80.png
--------------------------------------------------------------------------------
/JhtShopCarAnimation/Assets.xcassets/AppIcon.appiconset/ios-template-87.png:
--------------------------------------------------------------------------------
https://raw.githubusercontent.com/jinht/ShopCarAnimation/HEAD/JhtShopCarAnimation/Assets.xcassets/AppIcon.appiconset/ios-template-87.png
--------------------------------------------------------------------------------
/JhtShopCarAnimation.xcodeproj/project.xcworkspace/contents.xcworkspacedata:
--------------------------------------------------------------------------------
1 |
2 |
4 |
6 |
7 |
8 |
--------------------------------------------------------------------------------
/.gitignore:
--------------------------------------------------------------------------------
1 | # Xcode
2 | .DS_Store
3 | build
4 | /*.pbxuser
5 | !default.pbxuser
6 | *.mode1v3
7 | !default.mode1v3
8 | *.mode2v3
9 | !default.mode2v3
10 | *.perspectivev3
11 | !default.perspectivev3
12 | !default.xcworkspace
13 | xcuserdata
14 | *.moved-aside
15 | *.mobileprovision
16 | DerivedData
17 | .idea/
18 | # Pods - for those of you who use CocoaPods
19 | Pods
20 | Podfile.lock
21 | Podfile
22 | *.xcworkspace
--------------------------------------------------------------------------------
/JhtShopCarAnimation/AnimationViewController/AnimationViewController.h:
--------------------------------------------------------------------------------
1 | //
2 | // ViewController.h
3 | // JhtShopCarAnimation
4 | //
5 | // GitHub主页: https://github.com/jinht
6 | // CSDN博客: http://blog.csdn.net/anticipate91
7 | //
8 | // Created by Jht on 16/5/17.
9 | // Copyright © 2016年 JhtShopCarAnimation. All rights reserved.
10 | //
11 |
12 | #import
13 |
14 | @interface AnimationViewController : UIViewController
15 |
16 |
17 | @end
18 |
19 |
--------------------------------------------------------------------------------
/JhtShopCarAnimation/AppDelegate.h:
--------------------------------------------------------------------------------
1 | //
2 | // AppDelegate.h
3 | // JhtShopCarAnimation
4 | //
5 | // GitHub主页: https://github.com/jinht
6 | // CSDN博客: http://blog.csdn.net/anticipate91
7 | //
8 | // Created by Jht on 16/7/28.
9 | // Copyright © 2016年 Jinht. All rights reserved.
10 | //
11 |
12 | #import
13 |
14 | @interface AppDelegate : UIResponder
15 |
16 | @property (strong, nonatomic) UIWindow *window;
17 |
18 |
19 | @end
20 |
21 |
--------------------------------------------------------------------------------
/JhtShopCarAnimation/Assets.xcassets/deleteIcon.imageset/Contents.json:
--------------------------------------------------------------------------------
1 | {
2 | "images" : [
3 | {
4 | "idiom" : "universal",
5 | "filename" : "项目删除.png",
6 | "scale" : "1x"
7 | },
8 | {
9 | "idiom" : "universal",
10 | "filename" : "项目删除@2x.png",
11 | "scale" : "2x"
12 | },
13 | {
14 | "idiom" : "universal",
15 | "filename" : "项目删除@3x.png",
16 | "scale" : "3x"
17 | }
18 | ],
19 | "info" : {
20 | "version" : 1,
21 | "author" : "xcode"
22 | }
23 | }
--------------------------------------------------------------------------------
/JhtShopCarAnimation/main.m:
--------------------------------------------------------------------------------
1 | //
2 | // main.m
3 | // JhtShopCarAnimation
4 | //
5 | // GitHub主页: https://github.com/jinht
6 | // CSDN博客: http://blog.csdn.net/anticipate91
7 | //
8 | // Created by Jht on 16/7/28.
9 | // Copyright © 2016年 JhtShopCarAnimation. All rights reserved.
10 | //
11 |
12 | #import
13 | #import "AppDelegate.h"
14 |
15 | int main(int argc, char * argv[]) {
16 | @autoreleasepool {
17 | return UIApplicationMain(argc, argv, nil, NSStringFromClass([AppDelegate class]));
18 | }
19 | }
20 |
--------------------------------------------------------------------------------
/JhtAnimationTools.podspec:
--------------------------------------------------------------------------------
1 | Pod::Spec.new do |s|
2 |
3 | s.name = 'JhtAnimationTools'
4 | s.version = '1.0.7'
5 | s.summary = '购物车类的抛物线动画 && 阻尼动画'
6 | s.homepage = 'https://github.com/jinht/ShopCarAnimation'
7 | s.license = { :type => 'MIT', :file => 'LICENSE' }
8 | s.author = { 'Jinht' => 'jinjob@icloud.com' }
9 | s.social_media_url = 'https://blog.csdn.net/Anticipate91'
10 | s.platform = :ios
11 | s.ios.deployment_target = '8.0'
12 | s.source = { :git => 'https://github.com/jinht/ShopCarAnimation.git', :tag => s.version }
13 | s.source_files = 'JhtAnimationTools/*.{h,m}'
14 | s.frameworks = 'UIKit'
15 |
16 | end
17 |
--------------------------------------------------------------------------------
/JhtShopCarAnimation.xcodeproj/xcuserdata/Jht.xcuserdatad/xcschemes/xcschememanagement.plist:
--------------------------------------------------------------------------------
1 |
2 |
3 |
4 |
5 | SchemeUserState
6 |
7 | JhtShopCarAnimation.xcscheme
8 |
9 | orderHint
10 | 0
11 |
12 |
13 | SuppressBuildableAutocreation
14 |
15 | A5EA2EEB1D49EBAA007217DE
16 |
17 | primary
18 |
19 |
20 | A5EA2F041D49EBAA007217DE
21 |
22 | primary
23 |
24 |
25 | A5EA2F0F1D49EBAA007217DE
26 |
27 | primary
28 |
29 |
30 |
31 |
32 |
33 |
--------------------------------------------------------------------------------
/JhtShopCarAnimation.xcodeproj/xcuserdata/zl.xcuserdatad/xcschemes/xcschememanagement.plist:
--------------------------------------------------------------------------------
1 |
2 |
3 |
4 |
5 | SchemeUserState
6 |
7 | JhtShopCarAnimation.xcscheme
8 |
9 | orderHint
10 | 0
11 |
12 |
13 | SuppressBuildableAutocreation
14 |
15 | A5EA2EEB1D49EBAA007217DE
16 |
17 | primary
18 |
19 |
20 | A5EA2F041D49EBAA007217DE
21 |
22 | primary
23 |
24 |
25 | A5EA2F0F1D49EBAA007217DE
26 |
27 | primary
28 |
29 |
30 |
31 |
32 |
33 |
--------------------------------------------------------------------------------
/LICENSE:
--------------------------------------------------------------------------------
1 | MIT License
2 |
3 | Copyright (c) 2016 Jinht
4 |
5 | Permission is hereby granted, free of charge, to any person obtaining a copy
6 | of this software and associated documentation files (the "Software"), to deal
7 | in the Software without restriction, including without limitation the rights
8 | to use, copy, modify, merge, publish, distribute, sublicense, and/or sell
9 | copies of the Software, and to permit persons to whom the Software is
10 | furnished to do so, subject to the following conditions:
11 |
12 | The above copyright notice and this permission notice shall be included in all
13 | copies or substantial portions of the Software.
14 |
15 | THE SOFTWARE IS PROVIDED "AS IS", WITHOUT WARRANTY OF ANY KIND, EXPRESS OR
16 | IMPLIED, INCLUDING BUT NOT LIMITED TO THE WARRANTIES OF MERCHANTABILITY,
17 | FITNESS FOR A PARTICULAR PURPOSE AND NONINFRINGEMENT. IN NO EVENT SHALL THE
18 | AUTHORS OR COPYRIGHT HOLDERS BE LIABLE FOR ANY CLAIM, DAMAGES OR OTHER
19 | LIABILITY, WHETHER IN AN ACTION OF CONTRACT, TORT OR OTHERWISE, ARISING FROM,
20 | OUT OF OR IN CONNECTION WITH THE SOFTWARE OR THE USE OR OTHER DEALINGS IN THE
21 | SOFTWARE.
22 |
--------------------------------------------------------------------------------
/JhtShopCarAnimation/AnimationRecordCell/AnimationRecordCell.h:
--------------------------------------------------------------------------------
1 | //
2 | // AnimationRecordCell.h
3 | // JhtShopCarAnimation
4 | //
5 | // GitHub主页: https://github.com/jinht
6 | // CSDN博客: http://blog.csdn.net/anticipate91
7 | //
8 | // Created by Jht on 15/10/9.
9 | // Copyright © 2016年 JhtShopCarAnimation. All rights reserved.
10 | //
11 |
12 | #import
13 |
14 | #define UIColorFromRGB(rgbValue) [UIColor \
15 | colorWithRed:((float)((rgbValue & 0xFF0000) >> 16))/255.0 \
16 | green:((float)((rgbValue & 0xFF00) >> 8))/255.0 \
17 | blue:((float)(rgbValue & 0xFF))/255.0 alpha:1.0]
18 |
19 | /** Cell */
20 | @interface AnimationRecordCell : UITableViewCell
21 |
22 | #pragma mark - property
23 | @property (nonatomic, strong) UIImageView *formerIcon;
24 | @property (nonatomic, strong) UILabel *descLabel;
25 |
26 | @property (nonatomic, strong) UIImageView *deleteIcon;
27 | @property (nonatomic, strong) UIButton *deleteBtn;
28 |
29 | @property (nonatomic, strong) UILabel *lowLine;
30 |
31 |
32 | @end
33 |
34 |
35 |
36 | /** Model */
37 | @interface AnimationRecordModel : NSObject
38 |
39 | #pragma mark - property
40 | @property (nonatomic, strong) NSString *record_icon;
41 | @property (nonatomic, strong) NSString *record_name;
42 |
43 |
44 | @end
45 |
46 |
--------------------------------------------------------------------------------
/JhtShopCarAnimation.xcodeproj/xcuserdata/Jht.xcuserdatad/xcdebugger/Breakpoints_v2.xcbkptlist:
--------------------------------------------------------------------------------
1 |
2 |
5 |
6 |
8 |
14 |
15 |
16 |
18 |
30 |
31 |
32 |
33 |
34 |
--------------------------------------------------------------------------------
/JhtShopCarAnimation/Info.plist:
--------------------------------------------------------------------------------
1 |
2 |
3 |
4 |
5 | CFBundleDevelopmentRegion
6 | en
7 | CFBundleExecutable
8 | $(EXECUTABLE_NAME)
9 | CFBundleIdentifier
10 | $(PRODUCT_BUNDLE_IDENTIFIER)
11 | CFBundleInfoDictionaryVersion
12 | 6.0
13 | CFBundleName
14 | $(PRODUCT_NAME)
15 | CFBundlePackageType
16 | APPL
17 | CFBundleShortVersionString
18 | 1.0
19 | CFBundleSignature
20 | ????
21 | CFBundleVersion
22 | 1
23 | LSRequiresIPhoneOS
24 |
25 | NSAppTransportSecurity
26 |
27 | NSAllowsArbitraryLoads
28 |
29 |
30 | UILaunchStoryboardName
31 | LaunchScreen
32 | UIMainStoryboardFile
33 | Main
34 | UIRequiredDeviceCapabilities
35 |
36 | armv7
37 |
38 | UISupportedInterfaceOrientations
39 |
40 | UIInterfaceOrientationPortrait
41 |
42 |
43 |
44 |
--------------------------------------------------------------------------------
/JhtShopCarAnimation/Assets.xcassets/AppIcon.appiconset/Contents.json:
--------------------------------------------------------------------------------
1 | {
2 | "images" : [
3 | {
4 | "idiom" : "iphone",
5 | "size" : "20x20",
6 | "scale" : "2x"
7 | },
8 | {
9 | "idiom" : "iphone",
10 | "size" : "20x20",
11 | "scale" : "3x"
12 | },
13 | {
14 | "size" : "29x29",
15 | "idiom" : "iphone",
16 | "filename" : "ios-template-58.png",
17 | "scale" : "2x"
18 | },
19 | {
20 | "size" : "29x29",
21 | "idiom" : "iphone",
22 | "filename" : "ios-template-87.png",
23 | "scale" : "3x"
24 | },
25 | {
26 | "size" : "40x40",
27 | "idiom" : "iphone",
28 | "filename" : "ios-template-80.png",
29 | "scale" : "2x"
30 | },
31 | {
32 | "size" : "40x40",
33 | "idiom" : "iphone",
34 | "filename" : "ios-template-120.png",
35 | "scale" : "3x"
36 | },
37 | {
38 | "size" : "60x60",
39 | "idiom" : "iphone",
40 | "filename" : "ios-template-121.png",
41 | "scale" : "2x"
42 | },
43 | {
44 | "size" : "60x60",
45 | "idiom" : "iphone",
46 | "filename" : "ios-template-180.png",
47 | "scale" : "3x"
48 | },
49 | {
50 | "idiom" : "ios-marketing",
51 | "size" : "1024x1024",
52 | "scale" : "1x"
53 | }
54 | ],
55 | "info" : {
56 | "version" : 1,
57 | "author" : "xcode"
58 | }
59 | }
--------------------------------------------------------------------------------
/JhtShopCarAnimation/Base.lproj/Main.storyboard:
--------------------------------------------------------------------------------
1 |
2 |
3 |
4 |
5 |
6 |
7 |
8 |
9 |
10 |
11 |
12 |
13 |
14 |
15 |
16 |
17 |
18 |
19 |
20 |
21 |
22 |
23 |
24 |
25 |
26 |
--------------------------------------------------------------------------------
/JhtShopCarAnimation/Base.lproj/LaunchScreen.storyboard:
--------------------------------------------------------------------------------
1 |
2 |
3 |
4 |
5 |
6 |
7 |
8 |
9 |
10 |
11 |
12 |
13 |
14 |
15 |
16 |
17 |
18 |
19 |
20 |
21 |
22 |
23 |
24 |
25 |
26 |
27 |
28 |
--------------------------------------------------------------------------------
/JhtShopCarAnimation/AppDelegate.m:
--------------------------------------------------------------------------------
1 | //
2 | // AppDelegate.m
3 | // JhtShopCarAnimation
4 | //
5 | // GitHub主页: https://github.com/jinht
6 | // CSDN博客: http://blog.csdn.net/anticipate91
7 | //
8 | // Created by Jht on 16/7/28.
9 | // Copyright © 2016年 Jinht. All rights reserved.
10 | //
11 |
12 | #import "AppDelegate.h"
13 | #import "AnimationViewController.h"
14 |
15 | @interface AppDelegate ()
16 |
17 | @end
18 |
19 |
20 | @implementation AppDelegate
21 |
22 | - (BOOL)application:(UIApplication *)application didFinishLaunchingWithOptions:(NSDictionary *)launchOptions {
23 | self.window.rootViewController = [[UINavigationController alloc] initWithRootViewController:[[AnimationViewController alloc] init]];
24 | return YES;
25 | }
26 |
27 | - (void)applicationWillResignActive:(UIApplication *)application {
28 | // Sent when the application is about to move from active to inactive state. This can occur for certain types of temporary interruptions (such as an incoming phone call or SMS message) or when the user quits the application and it begins the transition to the background state.
29 | // Use this method to pause ongoing tasks, disable timers, and throttle down OpenGL ES frame rates. Games should use this method to pause the game.
30 | }
31 |
32 | - (void)applicationDidEnterBackground:(UIApplication *)application {
33 | // Use this method to release shared resources, save user data, invalidate timers, and store enough application state information to restore your application to its current state in case it is terminated later.
34 | // If your application supports background execution, this method is called instead of applicationWillTerminate: when the user quits.
35 | }
36 |
37 | - (void)applicationWillEnterForeground:(UIApplication *)application {
38 | // Called as part of the transition from the background to the inactive state; here you can undo many of the changes made on entering the background.
39 | }
40 |
41 | - (void)applicationDidBecomeActive:(UIApplication *)application {
42 | // Restart any tasks that were paused (or not yet started) while the application was inactive. If the application was previously in the background, optionally refresh the user interface.
43 | }
44 |
45 | - (void)applicationWillTerminate:(UIApplication *)application {
46 | // Called when the application is about to terminate. Save data if appropriate. See also applicationDidEnterBackground:.
47 | }
48 |
49 | @end
50 |
--------------------------------------------------------------------------------
/JhtAnimationTools/JhtAnimationTools.h:
--------------------------------------------------------------------------------
1 | //
2 | // JhtAnimationTools.h
3 | // JhtShopCarAnimation
4 | //
5 | // GitHub主页: https://github.com/jinht
6 | // CSDN博客: http://blog.csdn.net/anticipate91
7 | //
8 | // Created by Jht on 16/5/17.
9 | // Copyright © 2016年 JhtAnimationTools. All rights reserved.
10 | //
11 |
12 | #import
13 |
14 | @protocol JhtAnimationToolsDelegate
15 | /** 委托
16 | * type == 0 购物车 动画 type == 1 阻尼动画
17 | * isStop: YES 动画结束,NO 动画过程中
18 | */
19 | - (void)JhtAnimationWithType:(NSInteger)type isDidStop:(BOOL)isStop;
20 |
21 | @end
22 |
23 |
24 | /** 黑色背景 tag值 */
25 | extern NSInteger const ATBlackViewTag;
26 |
27 | /** 动画工具类 */
28 | @interface JhtAnimationTools : NSObject
29 |
30 | #pragma mark - property
31 | /** 动画层 */
32 | @property (strong, nonatomic) CALayer *shopLayer;
33 |
34 | @property (assign, nonatomic) id toolsDelegate;
35 |
36 |
37 |
38 | #pragma mark - Public Method
39 | + (instancetype)sharedInstance;
40 |
41 |
42 | #pragma mark 购物车上抛动画
43 | /** 购物车上抛动画
44 | * rect: 动画开始的坐标;rect为CGRectZero => 使用默认初始坐标
45 | * imageView: 动画对应的imageView
46 | * view: 在哪个view上显示(一般传self.view)
47 | * lastPoint: 动画结束 点
48 | * controlPoint: 动画过程中抛物线的中间转折点
49 | * per: 决定控制点,起点和终点X坐标之间距离 1/per;注: 如果per <= 0,则控制点由controlPoint决定,否则控制点由per决定
50 | * expandAnimationTime: 动画变大 时间
51 | * narrowAnimationTime: 动画变小 时间
52 | * animationValue: 动画变大过程中,变为原来的几倍大
53 | * 注: 如果动画过程中,你不想让图片变大变小,保持原来的大小运动,传值如下
54 | * expandAnimationTime: 0.0f
55 | * narrowAnimationTime: 动画总 时间
56 | * animationValue: 1.0f
57 | */
58 | - (void)aniStartShopCarAnimationWithStartRect:(CGRect)rect imageView:(UIImageView *)imageView superView:(UIView *)view endPoint:(CGPoint)lastPoint controlPoint:(CGPoint)controlPoint startToEndSpacePercentage:(NSInteger)per expandAnimationTime:(CFTimeInterval)expandAnimationTime narrowAnimationTime:(CFTimeInterval)narrowAnimationTime animationValue:(CGFloat)animationValue;
59 |
60 |
61 | #pragma mark 阻尼动画
62 | /** 阻尼动画的View
63 | * view: 黑色背景View 父view(eg: self.view)
64 | * frame: 阻尼View 坐标
65 | * isBlack: YES 需要出现黑色背景,NO 不需要出现黑色背景
66 | * bgColor: 背景颜色
67 | */
68 | - (UIView *)aniDampingAnimationWithSuperView:(UIView *)view frame:(CGRect)frame backgroundColor:(UIColor *)bgColor haveBlackView:(BOOL)haveBlackView;
69 |
70 | /** 开始阻尼动画 */
71 | - (void)aniStartDampingAnimation;
72 | /** 关闭阻尼动画 */
73 | - (void)aniCloseDampingAnimation;
74 |
75 | /** 获取阻尼动画 黑色背景 */
76 | - (UIView *)aniGetDampingBlackView;
77 |
78 |
79 | @end
80 |
--------------------------------------------------------------------------------
/JhtShopCarAnimation/AnimationRecordCell/AnimationRecordCell.m:
--------------------------------------------------------------------------------
1 | //
2 | // AnimationRecordCell.m
3 | // JhtShopCarAnimation
4 | //
5 | // GitHub主页: https://github.com/jinht
6 | // CSDN博客: http://blog.csdn.net/anticipate91
7 | //
8 | // Created by Jht on 15/10/9.
9 | // Copyright © 2016年 JhtShopCarAnimation. All rights reserved.
10 | //
11 |
12 | #import "AnimationRecordCell.h"
13 |
14 | @implementation AnimationRecordCell
15 |
16 | - (instancetype)initWithStyle:(UITableViewCellStyle)style reuseIdentifier:(NSString *)reuseIdentifier {
17 | self = [super initWithStyle:style reuseIdentifier:reuseIdentifier];
18 |
19 | if (self) {
20 | self.selectionStyle = UITableViewCellSeparatorStyleNone;
21 |
22 | [self.contentView addSubview:self.formerIcon];
23 | [self.contentView addSubview:self.descLabel];
24 |
25 | [self.contentView addSubview:self.deleteIcon];
26 | [self.contentView addSubview:self.deleteBtn];
27 |
28 | [self.contentView addSubview:self.lowLine];
29 | }
30 |
31 | return self;
32 | }
33 |
34 |
35 |
36 | #pragma mark - Get
37 | - (UIImageView *)formerIcon {
38 | if (!_formerIcon) {
39 | _formerIcon = [[UIImageView alloc] initWithFrame:CGRectMake(10, 5, 30, 30)];
40 | }
41 |
42 | return _formerIcon;
43 | }
44 |
45 | - (UILabel *)descLabel {
46 | if (!_descLabel) {
47 | _descLabel = [[UILabel alloc] initWithFrame:CGRectMake(50, 0, 120, 40)];
48 | _descLabel.textAlignment = NSTextAlignmentLeft;
49 | _descLabel.font = [UIFont systemFontOfSize:15];
50 | }
51 |
52 | return _descLabel;
53 | }
54 |
55 | - (UIImageView *)deleteIcon {
56 | if (!_deleteIcon) {
57 | _deleteIcon = [[UIImageView alloc] initWithFrame:CGRectMake([UIScreen mainScreen].bounds.size.width - 13 - 22, 9, 22, 22)];
58 | [_deleteIcon setImage:[UIImage imageNamed:@"deleteIcon"]];
59 | }
60 |
61 | return _deleteIcon;
62 | }
63 |
64 | - (UIButton *)deleteBtn {
65 | if (!_deleteBtn) {
66 | _deleteBtn = [[UIButton alloc] initWithFrame:CGRectMake([UIScreen mainScreen].bounds.size.width - 50, 0, 50, 40)];
67 | }
68 |
69 | return _deleteBtn;
70 | }
71 |
72 | - (UILabel *)lowLine {
73 | if (!_lowLine) {
74 | _lowLine = [[UILabel alloc] init];
75 | _lowLine.backgroundColor = UIColorFromRGB(0xCCCCCC);
76 | }
77 |
78 | return _lowLine;
79 | }
80 |
81 |
82 | @end
83 |
84 |
85 |
86 | @implementation AnimationRecordModel
87 |
88 |
89 | @end
90 |
--------------------------------------------------------------------------------
/README.md:
--------------------------------------------------------------------------------
1 | ## JhtShopCarAnimation
2 |
3 | ## Contents
4 | #### 购物车抛物线动画
5 | #### 阻尼动画
6 |
7 |
8 | ## needed to pay attention.
9 | ### 1. podfile
10 | ```oc
11 | platform:ios, '8.0'
12 |
13 | target '*****' do
14 |
15 | pod 'JhtAnimationTools'
16 |
17 | end
18 | ```
19 |
20 |
21 | ### 2.这是一个轻量级的动画文件,可以实现购物车的上抛 && 下抛动画;此外我还写了一个简单的阻尼动画,供大家交流使用
22 |
23 |
24 |
25 | ### 3.使用起来比较方便,只需导入 JhtAnimationTools.h 头文件即可
26 | (1) 购物车动画
27 | ```oc
28 | /**
29 | * rect: 动画开始的坐标; 如果rect传CGRectZero,则用默认开始坐标;
30 | * imageView: 动画对应的imageView;
31 | * view : 在哪个view上显示 (一般传self.view);
32 | * lastPoint: 动画结束的坐标点;
33 | * controlPoint: 动画过程中抛物线的中间转折点;
34 | * per: 决定控制点,起点和终点X坐标之间距离 1/per; 注:如果per <= 0, 则控制点由controlPoint决定,否则控制点由per决定;
35 | * expandAnimationTime: 动画变大的时间
36 | * narrowAnimationTime: 动画变小的时间
37 | * animationValue: 动画变大过程中,变为原来的几倍大
38 | * 注意 : 如果动画过程中,你不想让图片变大变小,保持原来的大小运动,传值如下:
39 | expandAnimationTime:0.0f
40 | narrowAnimationTime : 动画总共的时间;
41 | animationValue:1.0f
42 | */
43 | - (void)aniStartShopCarAnimationWithStartRect:(CGRect)rect withImageView:(UIImageView *)imageView withView:(UIView *)view withEndPoint:(CGPoint)lastPoint withControlPoint:(CGPoint)controlPoint withStartToEndSpacePercentage:(NSInteger)per withExpandAnimationTime:(CFTimeInterval)expandAnimationTime withNarrowAnimationTime:(CFTimeInterval)narrowAnimationTime withAnimationValue:(CGFloat)animationValue;
44 | ```
45 | (2) 阻尼动画
46 | * 创建阻尼动画的View
47 | ```oc
48 | /** 获得的阻尼动画的View
49 | * view:黑色背景View的父view(例如:self.view);
50 | * frame:是这个阻尼View的坐标
51 | * isBlack:yes 需要出现黑色背景, no不需要
52 | * bgColor:背景颜色
53 | */
54 | - (UIView *)aniDampingAnimationWithFView:(UIView *)view withFrame:(CGRect)frame withBackgroundColor:(UIColor *)bgColor isNeedBlackView:(BOOL)isBlack;
55 | ```
56 | * 阻尼动画相关使用方法
57 | ```oc
58 | /** 开始动画阻尼动画 */
59 | - (void)aniStartDampingAnimation;
60 | /** 关闭阻尼动画 */
61 | - (void)aniCloseDampingAnimation;
62 | /** 获得阻尼动画的黑色背景 */
63 | - (UIView *)aniGetDampingBlackView;
64 | ```
65 |
66 | (3) 动画的代理方法
67 | ```oc
68 | /**
69 | * type == 0 购物车的动画
70 | * type == 1 阻尼动画
71 | * isStop: Yes动画结束, No动画过程中
72 | */
73 | - (void)JhtAnimationWithType:(NSInteger)type isDidStop:(BOOL)isStop;
74 | ```
75 |
76 | ### Remind
77 | * ARC
78 | * iOS >= 8.0
79 | * iPhone \ iPad
80 |
81 | ## Hope
82 | * If you find bug when used,Hope you can Issues me,Thank you or try to download the latest code of this framework to see the BUG has been fixed or not
83 | * If you find the function is not enough when used,Hope you can Issues me,I very much to add more useful function to this framework ,Thank you !
84 |
85 |
--------------------------------------------------------------------------------
/JhtShopCarAnimation.xcodeproj/xcuserdata/Jht.xcuserdatad/xcschemes/JhtShopCarAnimation.xcscheme:
--------------------------------------------------------------------------------
1 |
2 |
5 |
8 |
9 |
15 |
21 |
22 |
23 |
24 |
25 |
30 |
31 |
33 |
39 |
40 |
41 |
43 |
49 |
50 |
51 |
52 |
53 |
59 |
60 |
61 |
62 |
63 |
64 |
74 |
76 |
82 |
83 |
84 |
85 |
86 |
87 |
93 |
95 |
101 |
102 |
103 |
104 |
106 |
107 |
110 |
111 |
112 |
--------------------------------------------------------------------------------
/JhtShopCarAnimation.xcodeproj/xcuserdata/zl.xcuserdatad/xcschemes/JhtShopCarAnimation.xcscheme:
--------------------------------------------------------------------------------
1 |
2 |
5 |
8 |
9 |
15 |
21 |
22 |
23 |
24 |
25 |
30 |
31 |
33 |
39 |
40 |
41 |
43 |
49 |
50 |
51 |
52 |
53 |
59 |
60 |
61 |
62 |
63 |
64 |
74 |
76 |
82 |
83 |
84 |
85 |
86 |
87 |
93 |
95 |
101 |
102 |
103 |
104 |
106 |
107 |
110 |
111 |
112 |
--------------------------------------------------------------------------------
/JhtAnimationTools/JhtAnimationTools.m:
--------------------------------------------------------------------------------
1 | //
2 | // JhtAnimationTools.m
3 | // JhtShopCarAnimation
4 | //
5 | // GitHub主页: https://github.com/jinht
6 | // CSDN博客: http://blog.csdn.net/anticipate91
7 | //
8 | // Created by Jht on 16/5/17.
9 | // Copyright © 2016年 JhtAnimationTools. All rights reserved.
10 | //
11 |
12 | #import "JhtAnimationTools.h"
13 | #import
14 |
15 | @interface JhtAnimationTools () {
16 | // 矢量路径
17 | UIBezierPath *_shopPath;
18 |
19 | UIView *_superView;
20 | UIView *_dampingView;
21 | }
22 |
23 | @end
24 |
25 |
26 | NSInteger const ATBlackViewTag = 222;
27 |
28 | static NSString *const ATAnmationKey = @"ATAnmationKey";
29 |
30 | @implementation JhtAnimationTools
31 |
32 | #pragma mark - Public Method
33 | + (instancetype)sharedInstance {
34 | static JhtAnimationTools *jhtAnimationTools = nil;
35 | static dispatch_once_t onceToken;
36 |
37 | dispatch_once(&onceToken, ^{
38 | if (jhtAnimationTools == nil) {
39 | jhtAnimationTools = [[self alloc] init];
40 | }
41 | });
42 |
43 | return jhtAnimationTools;
44 | }
45 |
46 |
47 |
48 | #pragma mark - 购物车上抛动画
49 | - (void)aniStartShopCarAnimationWithStartRect:(CGRect)rect imageView:(UIImageView *)imageView superView:(UIView *)view endPoint:(CGPoint)lastPoint controlPoint:(CGPoint)controlPoint startToEndSpacePercentage:(NSInteger)per expandAnimationTime:(CFTimeInterval)expandAnimationTime narrowAnimationTime:(CFTimeInterval)narrowAnimationTime animationValue:(CGFloat)animationValue {
50 | if (!_shopLayer) {
51 | _shopLayer = [CALayer layer];
52 | _shopLayer.contents = (id)imageView.layer.contents;
53 | _shopLayer.contentsGravity = kCAGravityResizeAspectFill;
54 |
55 | if (rect.size.height == 0) {
56 | // 动画开始坐标(相对于view )
57 | rect = [imageView.superview convertRect:imageView.frame toView:view];
58 | }
59 | _shopLayer.bounds = rect;
60 | _shopLayer.masksToBounds = YES;
61 | _shopLayer.position = CGPointMake(rect.origin.x, rect.origin.y);
62 | [view.layer addSublayer:_shopLayer];
63 |
64 | _shopPath = [UIBezierPath bezierPath];
65 | [_shopPath moveToPoint:_shopLayer.position];
66 |
67 | // 不根据controlPoint判断: 如果控制点巧合是(0,0)将无法CGPointZero判断,所以根据per判断
68 | if (per > 0) {
69 | // 上-->下 ? 下-->上
70 | NSInteger a = lastPoint.x - rect.origin.x;
71 |
72 | NSInteger lastPointToStartPoint = a > 0 ? a : -a;
73 |
74 | NSInteger b = lastPoint.x < rect.origin.x ? lastPoint.x : rect.origin.x;
75 |
76 | controlPoint = CGPointMake(b + lastPointToStartPoint / per, (CGRectGetHeight([[UIApplication sharedApplication] statusBarFrame]) + 44));
77 | }
78 |
79 | [_shopPath addQuadCurveToPoint:lastPoint controlPoint:controlPoint];
80 | }
81 | [self shopCarGroupAnimationWithExpandAnimationTime:expandAnimationTime narrowAnimationTime:narrowAnimationTime animationValue:animationValue];
82 | }
83 |
84 | /** 组合动画 */
85 | - (void)shopCarGroupAnimationWithExpandAnimationTime:(CFTimeInterval)expandAnimationTime narrowAnimationTime:(CFTimeInterval)narrowAnimationTime animationValue:(CGFloat)animationValue {
86 | CAKeyframeAnimation *animation = [CAKeyframeAnimation animationWithKeyPath:@"position"];
87 | animation.path = _shopPath.CGPath;
88 |
89 | CABasicAnimation *expandAnimation = [CABasicAnimation animationWithKeyPath:@"transform.scale"];
90 | expandAnimation.duration = expandAnimationTime;
91 | expandAnimation.fromValue = [NSNumber numberWithFloat:1];
92 | expandAnimation.toValue = [NSNumber numberWithFloat:animationValue];
93 | expandAnimation.timingFunction = [CAMediaTimingFunction functionWithName:kCAMediaTimingFunctionEaseIn];
94 |
95 | CABasicAnimation *narrowAnimation = [CABasicAnimation animationWithKeyPath:@"transform.scale"];
96 | narrowAnimation.beginTime = expandAnimationTime;
97 | narrowAnimation.fromValue = [NSNumber numberWithFloat:animationValue];
98 | narrowAnimation.duration = narrowAnimationTime;
99 | narrowAnimation.toValue = [NSNumber numberWithFloat:1];
100 |
101 | narrowAnimation.timingFunction = [CAMediaTimingFunction functionWithName:kCAMediaTimingFunctionEaseOut];
102 |
103 | CAAnimationGroup *groups = [CAAnimationGroup animation];
104 | groups.animations = @[animation, expandAnimation, narrowAnimation];
105 | groups.duration = narrowAnimationTime + expandAnimationTime;
106 | groups.removedOnCompletion = NO;
107 | groups.fillMode = kCAFillModeForwards;
108 | groups.delegate = self;
109 | [_shopLayer addAnimation:groups forKey:ATAnmationKey];
110 | }
111 |
112 |
113 | #pragma mark CAAnimationDelegate(购物车动画代理)
114 | - (void)animationDidStop:(CAAnimation *)anim finished:(BOOL)flag {
115 | if (anim == [_shopLayer animationForKey:ATAnmationKey]) {
116 | [_shopLayer removeFromSuperlayer];
117 | _shopLayer = nil;
118 | if ([self.toolsDelegate respondsToSelector:@selector(JhtAnimationWithType:isDidStop:)]) {
119 | [self.toolsDelegate JhtAnimationWithType:0 isDidStop:YES];
120 | }
121 | }
122 | }
123 |
124 |
125 |
126 | #pragma mark - 阻尼动画
127 | - (UIView *)aniDampingAnimationWithSuperView:(UIView *)view frame:(CGRect)frame backgroundColor:(UIColor *)bgColor haveBlackView:(BOOL)haveBlackView {
128 | _superView = view;
129 | UIView *downView = [[UIView alloc] initWithFrame:frame];
130 | downView.backgroundColor = bgColor;
131 | downView.layer.masksToBounds = YES;
132 | downView.layer.cornerRadius = 5;
133 | downView.hidden = NO;
134 | _dampingView = downView;
135 |
136 | if (haveBlackView) {
137 | UIView *allView = [[UIView alloc] initWithFrame:CGRectMake(0, 0, CGRectGetWidth([UIScreen mainScreen].bounds), CGRectGetHeight([UIScreen mainScreen].bounds))];
138 | allView.backgroundColor = [UIColor blackColor];
139 | allView.alpha = 0;
140 | allView.tag = ATBlackViewTag;
141 | [view addSubview:allView];
142 | UITapGestureRecognizer *tap = [[UITapGestureRecognizer alloc] initWithTarget:self action:@selector(aniCloseDampingAnimation)];
143 | [allView addGestureRecognizer:tap];
144 | }
145 |
146 | return downView;
147 | }
148 |
149 | - (UIView *)aniGetDampingBlackView {
150 | return [_superView viewWithTag:ATBlackViewTag];
151 | }
152 |
153 | - (void)aniStartDampingAnimation {
154 | [UIView animateWithDuration:1 delay:0 usingSpringWithDamping:0.4 initialSpringVelocity:0.4 options:UIViewAnimationOptionCurveEaseIn animations:^{
155 | UIView *bgView = [self aniGetDampingBlackView];
156 | if (bgView) {
157 | bgView.alpha = 0.6;
158 | }
159 |
160 | if ([self.toolsDelegate respondsToSelector:@selector(JhtAnimationWithType:isDidStop:)]) {
161 | [self.toolsDelegate JhtAnimationWithType:1 isDidStop:NO];
162 | }
163 |
164 | } completion:^(BOOL finished) {
165 | if ([self.toolsDelegate respondsToSelector:@selector(JhtAnimationWithType:isDidStop:)]) {
166 | [self.toolsDelegate JhtAnimationWithType:1 isDidStop:YES];
167 | }
168 | }];
169 | }
170 |
171 | - (void)aniCloseDampingAnimation {
172 | CGFloat height = CGRectGetHeight(_dampingView.frame);
173 | [UIView animateWithDuration:1 delay:0 usingSpringWithDamping:0.4 initialSpringVelocity:0.4 options:UIViewAnimationOptionCurveEaseIn animations:^{
174 | _dampingView.frame = CGRectMake(0, -height - 20, CGRectGetWidth([UIScreen mainScreen].bounds), height);
175 | [self aniGetDampingBlackView].alpha = 0;
176 |
177 | } completion:^(BOOL finished) {
178 |
179 | }];
180 | }
181 |
182 |
183 | @end
184 |
--------------------------------------------------------------------------------
/JhtShopCarAnimation/AnimationViewController/AnimationViewController.m:
--------------------------------------------------------------------------------
1 | //
2 | // ViewController.m
3 | // JhtShopCarAnimation
4 | //
5 | // GitHub主页: https://github.com/jinht
6 | // CSDN博客: http://blog.csdn.net/anticipate91
7 | //
8 | // Created by Jht on 16/5/17.
9 | // Copyright © 2016年 JhtShopCarAnimation. All rights reserved.
10 | //
11 |
12 | #import "AnimationViewController.h"
13 | #import "JhtAnimationTools.h"
14 | #import "AnimationRecordCell.h"
15 |
16 | @interface AnimationViewController () {
17 | NSMutableArray *_sourceArray;
18 | NSMutableArray *_tableFooterViewDataArray;
19 |
20 | AnimationRecordModel *_selectedModel;
21 |
22 | UIView *_downView;
23 | }
24 |
25 | @property (nonatomic, strong) UILabel *navBarLabel;
26 |
27 | @property (nonatomic, strong) UITableView *insideTableView;
28 | @property (nonatomic, strong) UIScrollView *tableFooterViewSC;
29 |
30 | @property (nonatomic, strong) JhtAnimationTools *animationTools;
31 |
32 | @end
33 |
34 |
35 | #define UIColorFromRGB(rgbValue) [UIColor \
36 | colorWithRed:((float)((rgbValue & 0xFF0000) >> 16))/255.0 \
37 | green:((float)((rgbValue & 0xFF00) >> 8))/255.0 \
38 | blue:((float)(rgbValue & 0xFF))/255.0 alpha:1.0]
39 |
40 | #define FrameW [UIScreen mainScreen].bounds.size.width
41 | #define FrameH [UIScreen mainScreen].bounds.size.height
42 |
43 | @implementation AnimationViewController
44 |
45 | - (void)viewWillAppear:(BOOL)animated {
46 | [super viewWillAppear:animated];
47 |
48 | UIButton *btn = [[UIButton alloc] initWithFrame:CGRectMake(80, 0, FrameW - 80, 64)];
49 | btn.tag = 123;
50 | [btn addTarget:self action:@selector(starDampingAnimation) forControlEvents:UIControlEventTouchUpInside];
51 | [self.navigationController.view addSubview:btn];
52 | }
53 |
54 | - (void)viewWillDisappear:(BOOL)animated {
55 | [super viewWillDisappear:animated];
56 |
57 | [[JhtAnimationTools sharedInstance] aniCloseDampingAnimation];
58 |
59 | UIButton *btn = (UIButton *)[self.navigationController.view viewWithTag:123];
60 | [btn removeFromSuperview];
61 | }
62 |
63 | - (void)viewDidLoad {
64 | [super viewDidLoad];
65 |
66 | self.automaticallyAdjustsScrollViewInsets = NO;
67 | self.navigationController.navigationBar.translucent = NO;
68 | self.view.backgroundColor = UIColorFromRGB(0xFAFAFA);
69 |
70 | self.navigationItem.titleView = self.navBarLabel;
71 |
72 | [self animationInit];
73 |
74 | [self.view addSubview:self.insideTableView];
75 | self.insideTableView.tableFooterView = self.tableFooterViewSC;
76 |
77 | [self aniCreateDampingUI];
78 | }
79 |
80 |
81 |
82 | #pragma mark - init param
83 | /** 初始化相关控件和参数 */
84 | - (void)animationInit {
85 | _sourceArray = [[NSMutableArray alloc] init];
86 | _tableFooterViewDataArray = [[NSMutableArray alloc] init];
87 |
88 | NSArray *titleArray = @[@"滑板", @"击剑", @"课间操", @"篮球", @"爬山", @"跑步", @"乒乓球", @"散步", @"跆拳道", @"踢毽子", @"跳绳", @"跳舞", @"网球", @"游泳", @"体操", @"自行车", @"足球"];
89 | for (NSInteger i = 0; i < titleArray.count; i ++) {
90 | NSString *loadImageDic = [[[NSBundle mainBundle] resourcePath] stringByAppendingPathComponent:@"JhtShopCarAnimationImages.bundle"];
91 | NSString *loadImagePath = [loadImageDic stringByAppendingPathComponent:[NSString stringWithFormat:@"%ld", (long)i]];
92 | AnimationRecordModel *model = [[AnimationRecordModel alloc] init];
93 | model.record_icon = loadImagePath;
94 | model.record_name = titleArray[i];
95 | [_tableFooterViewDataArray addObject:model];
96 | }
97 | }
98 |
99 |
100 |
101 | #pragma mark - Get
102 | - (UILabel *)navBarLabel {
103 | if (!_navBarLabel) {
104 | _navBarLabel = [[UILabel alloc] initWithFrame:CGRectMake(0, 0, 44, 80)];
105 | _navBarLabel.text = @"点我有惊喜哟!";
106 | _navBarLabel.font = [UIFont boldSystemFontOfSize:18];
107 | _navBarLabel.textAlignment = NSTextAlignmentCenter;
108 | _navBarLabel.textColor = UIColorFromRGB(0x55AABB);
109 | }
110 |
111 | return _navBarLabel;
112 | }
113 |
114 | - (UITableView *)insideTableView {
115 | if (!_insideTableView) {
116 | _insideTableView = [[UITableView alloc] initWithFrame:CGRectMake(0, 0, FrameW, FrameH - 64) style:UITableViewStylePlain];
117 | _insideTableView.delegate = self;
118 | _insideTableView.dataSource = self;
119 | _insideTableView.showsVerticalScrollIndicator = NO;
120 | _insideTableView.showsHorizontalScrollIndicator = NO;
121 | _insideTableView.separatorStyle = UITableViewCellSeparatorStyleNone;
122 | _insideTableView.scrollEnabled = NO;
123 | _insideTableView.contentSize = CGSizeMake(FrameW, _tableFooterViewDataArray.count * 40);
124 | }
125 |
126 | return _insideTableView;
127 | }
128 |
129 | - (UIScrollView *)tableFooterViewSC {
130 | if (!_tableFooterViewSC) {
131 | CGFloat space = ((FrameW - 45 - 60 / 2 * 5) / 4);
132 | CGFloat height = 0;
133 |
134 | if (_sourceArray.count != 0) {
135 | height = FrameH - 64 - _sourceArray.count * 40;
136 | } else {
137 | height = FrameH - 64 - 40;
138 | }
139 | _tableFooterViewSC = [[UIScrollView alloc] initWithFrame:CGRectMake(0, 0, FrameW, height)];
140 | _tableFooterViewSC.delegate = self;
141 | _tableFooterViewSC.backgroundColor = UIColorFromRGB(0xFAFAFA);
142 | _tableFooterViewSC.showsHorizontalScrollIndicator = NO;
143 |
144 | for (NSInteger i = 0; i < _tableFooterViewDataArray.count; i ++) {
145 | AnimationRecordModel *model = [_tableFooterViewDataArray objectAtIndex:i];
146 | UIView *smallView = [[UIView alloc] initWithFrame:CGRectMake(45 / 2 + i % 5 * (30 + space), 15 + i / 5 * (95 / 2 + 17), (30 + space), 95 / 2)];
147 | smallView.tag = 100 + i;
148 |
149 | UIImageView *imageView = [[UIImageView alloc] initWithFrame:CGRectMake(0, 0, 30, 30)];
150 | imageView.tag = 200 + i;
151 | imageView.userInteractionEnabled = YES;
152 | imageView.image = [UIImage imageWithContentsOfFile:model.record_icon];
153 | [smallView addSubview:imageView];
154 |
155 | UILabel *label = [[UILabel alloc] initWithFrame:CGRectMake(-12, 68 / 2, CGRectGetWidth(imageView.frame) + 24, (95 - 68) / 2)];
156 | label.text = model.record_name;
157 | label.font = [UIFont systemFontOfSize:12];
158 | label.textColor = UIColorFromRGB(0x666666);
159 | label.backgroundColor = [UIColor clearColor];
160 | label.textAlignment = NSTextAlignmentCenter;
161 | label.tag = 300 + i;
162 | [smallView addSubview:label];
163 |
164 | UIButton *btn = [[UIButton alloc] initWithFrame:CGRectMake(0, 0, imageView.frame.size.width, 95/2)];
165 | btn.tag = 400 + i;
166 | [btn addTarget:self action:@selector(aniFootViewBtnClick:) forControlEvents:UIControlEventTouchUpInside];
167 | [smallView addSubview:btn];
168 | [_tableFooterViewSC addSubview:smallView];
169 | _tableFooterViewSC.frame = CGRectMake(0, 0, FrameW, height);
170 | _tableFooterViewSC.contentSize = CGSizeMake(FrameW, 15 + (_tableFooterViewDataArray.count - 1) / 5 * (95 / 2.0 + 34 / 2.0) + 95 / 2.0);
171 | }
172 | }
173 |
174 | return _tableFooterViewSC;
175 | }
176 |
177 | - (JhtAnimationTools *)animationTools {
178 | if (!_animationTools) {
179 | _animationTools = [JhtAnimationTools sharedInstance];
180 | _animationTools.toolsDelegate = self;
181 | }
182 |
183 | return _animationTools;
184 | }
185 |
186 |
187 | #pragma mark Get Method
188 | - (void)aniFootViewBtnClick:(UIButton *)btn {
189 | if (_sourceArray.count >= 11) {
190 | [self.view endEditing:YES];
191 | UIAlertView *alertView = [[UIAlertView alloc] initWithTitle:@"" message:@"可以上传11个以下项目!" delegate:self cancelButtonTitle:@"确定" otherButtonTitles:nil, nil];
192 | [alertView show];
193 |
194 | return;
195 | }
196 |
197 | NSInteger index = btn.tag - 400;
198 | UIView *smallView = btn.superview;
199 |
200 | // model change
201 | AnimationRecordModel *model = [_tableFooterViewDataArray objectAtIndex:index];
202 | _selectedModel = [[AnimationRecordModel alloc] init];
203 | _selectedModel.record_icon = model.record_icon;
204 | _selectedModel.record_name = model.record_name;
205 |
206 | // 判断是否重复添加
207 | BOOL isContain = NO;
208 | for (AnimationRecordModel *subModel in _sourceArray) {
209 | if ([subModel.record_name isEqualToString:_selectedModel.record_name]) {
210 | isContain = YES;
211 | break;
212 | }
213 | }
214 |
215 | if (isContain) {
216 | [self.view endEditing:YES];
217 | UIAlertView *alertView = [[UIAlertView alloc] initWithTitle:@"" message:@"您已选择此项目!" delegate:self cancelButtonTitle:@"确定" otherButtonTitles:nil, nil];
218 | [alertView show];
219 |
220 | return;
221 | }
222 |
223 | UIImageView *imageView = (UIImageView *)[smallView viewWithTag:200 + index];
224 | CGRect frame = [imageView.superview convertRect:imageView.frame toView:self.view];
225 |
226 | self.view.userInteractionEnabled = NO;
227 |
228 | [self anistartShopCarAnimationWithRect:frame ImageView:imageView];
229 | }
230 |
231 | /** 购物车动画 */
232 | - (void)anistartShopCarAnimationWithRect:(CGRect)rect ImageView:(UIImageView *)imageView {
233 | CGPoint lastPoint = CGPointMake(10 + 30 / 2, 5 + 30 / 2);
234 | /********** 用默认的时候这些都不用写 ************/
235 | // 我找个中间控制点,但是我想判断是从上向下抛物线 还是 从下向上抛物线
236 | NSInteger a = lastPoint.x - imageView.frame.origin.x;
237 | // 取起点和终点的距离
238 | NSInteger lastPointToStartPoint = a > 0 ? a : -a;
239 | // 取.x最小的
240 | NSInteger b = lastPoint.x < imageView.frame.origin.x ? lastPoint.x : imageView.frame.origin.x;
241 | // 控制点
242 | CGPoint controlPoint = CGPointMake(b + lastPointToStartPoint / 3, 0);
243 | /********** 用默认的时候这些都不用写 ************/
244 |
245 | // 使用 默认控制点
246 | [self.animationTools aniStartShopCarAnimationWithStartRect:rect imageView:imageView superView:self.view endPoint:lastPoint controlPoint:CGPointZero startToEndSpacePercentage:4 expandAnimationTime:0.5f narrowAnimationTime:0.5f animationValue:2.0f];
247 | }
248 |
249 |
250 |
251 | #pragma mark - DampingAnimation
252 | /** 创建阻尼动画 */
253 | - (void)aniCreateDampingUI {
254 | _downView = [self.animationTools aniDampingAnimationWithSuperView:self.view frame:CGRectMake(0, -250, FrameW, 250) backgroundColor:UIColorFromRGB(0xfd4444) haveBlackView:YES];
255 | [self.navigationController.view addSubview:_downView];
256 | [self.view bringSubviewToFront:_downView];
257 |
258 | // 黑色背景的tag值
259 | extern NSInteger const ATBlackViewTag;
260 | UIView *vv = [self.view viewWithTag:ATBlackViewTag];
261 | // NSLog(@"%lf~~~~~%lf", vv.frame.size.width, vv.frame.origin.y);
262 |
263 | UILabel *showLabel = [[UILabel alloc] initWithFrame:CGRectMake(0, (CGRectGetHeight(_downView.frame) - CGRectGetHeight(_downView.frame) / 2) / 2 + 50, CGRectGetWidth(_downView.frame), CGRectGetHeight(_downView.frame) / 2)];
264 | showLabel.text = @"Wow,这你都试出来啦!" ;
265 | showLabel.font = [UIFont boldSystemFontOfSize:18];
266 | showLabel.textColor = [UIColor whiteColor];
267 | showLabel.numberOfLines = 0;
268 | showLabel.layer.masksToBounds = YES;
269 | showLabel.backgroundColor = [UIColor clearColor];
270 | showLabel.textAlignment = NSTextAlignmentCenter;
271 | [_downView addSubview:showLabel];
272 | }
273 |
274 | /** 开始阻尼动画 */
275 | - (void)starDampingAnimation {
276 | [[JhtAnimationTools sharedInstance] aniStartDampingAnimation];
277 | }
278 |
279 |
280 |
281 | #pragma mark - UITableViewDelegate
282 | - (NSInteger)tableView:(UITableView *)tableView numberOfRowsInSection:(NSInteger)section {
283 | if (_sourceArray.count != 0) {
284 | return _sourceArray.count;
285 | } else {
286 | return 1;
287 | }
288 | }
289 |
290 | - (CGFloat)tableView:(UITableView *)tableView heightForRowAtIndexPath:(NSIndexPath *)indexPath {
291 | return 40;
292 | }
293 |
294 | - (UITableViewCell *)tableView:(UITableView *)tableView cellForRowAtIndexPath:(NSIndexPath *)indexPath {
295 | if (_sourceArray.count != 0) {
296 | // 有数据
297 | AnimationRecordCell *cell = [tableView dequeueReusableCellWithIdentifier:@"cell"];
298 | if (!cell) {
299 | cell = [[AnimationRecordCell alloc] initWithStyle:UITableViewCellStyleDefault reuseIdentifier:@"cell"];
300 | }
301 |
302 | AnimationRecordModel *model = [_sourceArray objectAtIndex:indexPath.row];
303 | cell.formerIcon.image = [UIImage imageWithContentsOfFile:model.record_icon];
304 | cell.descLabel.text = model.record_name;
305 |
306 | if (indexPath.row != _sourceArray.count - 1) {
307 | cell.lowLine.frame = CGRectMake(100 / 2, 40 - 0.6, FrameW - 100 / 2, 0.6);
308 | } else {
309 | cell.lowLine.frame = CGRectMake(0, 40 - 0.6, FrameW, 0.6);
310 | }
311 |
312 | // 尾部删除按钮
313 | cell.deleteBtn.tag = 300 + indexPath.row;
314 | [cell.deleteBtn addTarget:self action:@selector(aniDeleteCellBtn:) forControlEvents:UIControlEventTouchUpInside];
315 | return cell;
316 |
317 | } else {
318 | // 无数据
319 | UITableViewCell *cell = [tableView dequeueReusableCellWithIdentifier:@"kong"];
320 | if (!cell) {
321 | cell = [[UITableViewCell alloc] initWithStyle:UITableViewCellStyleDefault reuseIdentifier:@"kong"];
322 |
323 | UILabel *lineLabel = [[UILabel alloc] initWithFrame:CGRectMake(0, 40 - 0.6, FrameW, 0.6)];
324 | lineLabel.backgroundColor = [UIColor colorWithRed:0.90 green:0.90 blue:0.90 alpha:1.00];
325 | [cell.contentView addSubview:lineLabel];
326 | }
327 | cell.selectionStyle = UITableViewCellSelectionStyleNone;
328 | cell.textLabel.text = @"点击图标能飞哟!";
329 | cell.textLabel.textColor = UIColorFromRGB(0x666666);
330 | cell.textLabel.textAlignment = NSTextAlignmentCenter;
331 | cell.textLabel.font = [UIFont boldSystemFontOfSize:14];
332 | return cell;
333 | }
334 | }
335 |
336 |
337 | #pragma mark UITableViewDelegate Method
338 | - (void)aniDeleteCellBtn:(UIButton *)btn {
339 | NSInteger index = btn.tag - 300;
340 | [_sourceArray removeObjectAtIndex:index];
341 | [self.insideTableView reloadData];
342 |
343 | [self animationUpdateSCFrame];
344 | }
345 |
346 | /** 更新sc坐标 */
347 | - (void)animationUpdateSCFrame {
348 | _tableFooterViewSC.contentOffset = CGPointZero;
349 | CGFloat height = 0;
350 | if (_sourceArray.count != 0) {
351 | height = FrameH - 64 - _sourceArray.count * 40;
352 | } else {
353 | height = FrameH - 64 - 40;
354 | }
355 | _tableFooterViewSC.frame = CGRectMake(0, 0, FrameW, height);
356 | self.insideTableView.tableFooterView = _tableFooterViewSC;
357 | }
358 |
359 |
360 |
361 | #pragma mark - JhtAnimationToolsDelegate
362 | /** 委托
363 | * type == 0 购物车的动画
364 | * type == 1 阻尼动画
365 | * isStop: Yes动画结束,No动画过程中
366 | */
367 | - (void)JhtAnimationWithType:(NSInteger)type isDidStop:(BOOL)isStop {
368 | // 动画结束的代理
369 | if (isStop) {
370 | if (type == 0) {
371 | self.view.userInteractionEnabled = YES;
372 |
373 | [_sourceArray insertObject:_selectedModel atIndex:0];
374 | [self.insideTableView reloadData];
375 | [self animationUpdateSCFrame];
376 | [self.animationTools.shopLayer removeFromSuperlayer];
377 | self.animationTools.shopLayer = nil;
378 | } else if (type == 1) {
379 | NSLog(@"阻尼动画结束了");
380 | }
381 |
382 | } else {
383 | if (type == 1) {
384 | _downView.frame = CGRectMake(0, -100, FrameW, 250);
385 | }
386 | }
387 | }
388 |
389 |
390 | @end
391 |
--------------------------------------------------------------------------------
/JhtShopCarAnimation.xcodeproj/project.pbxproj:
--------------------------------------------------------------------------------
1 | // !$*UTF8*$!
2 | {
3 | archiveVersion = 1;
4 | classes = {
5 | };
6 | objectVersion = 46;
7 | objects = {
8 |
9 | /* Begin PBXBuildFile section */
10 | 8E6354A621C295AE002859E4 /* JhtAnimationTools.m in Sources */ = {isa = PBXBuildFile; fileRef = 8E6354A221C295AD002859E4 /* JhtAnimationTools.m */; };
11 | A5227E0E1E8CF4740072AF69 /* AnimationViewController.m in Sources */ = {isa = PBXBuildFile; fileRef = A5227E0D1E8CF4740072AF69 /* AnimationViewController.m */; };
12 | A5227E161E8CF4970072AF69 /* AnimationRecordCell.m in Sources */ = {isa = PBXBuildFile; fileRef = A5227E151E8CF4970072AF69 /* AnimationRecordCell.m */; };
13 | A5EA2EF11D49EBAA007217DE /* main.m in Sources */ = {isa = PBXBuildFile; fileRef = A5EA2EF01D49EBAA007217DE /* main.m */; };
14 | A5EA2EF41D49EBAA007217DE /* AppDelegate.m in Sources */ = {isa = PBXBuildFile; fileRef = A5EA2EF31D49EBAA007217DE /* AppDelegate.m */; };
15 | A5EA2EFA1D49EBAA007217DE /* Main.storyboard in Resources */ = {isa = PBXBuildFile; fileRef = A5EA2EF81D49EBAA007217DE /* Main.storyboard */; };
16 | A5EA2EFC1D49EBAA007217DE /* Assets.xcassets in Resources */ = {isa = PBXBuildFile; fileRef = A5EA2EFB1D49EBAA007217DE /* Assets.xcassets */; };
17 | A5EA2EFF1D49EBAA007217DE /* LaunchScreen.storyboard in Resources */ = {isa = PBXBuildFile; fileRef = A5EA2EFD1D49EBAA007217DE /* LaunchScreen.storyboard */; };
18 | A5EA2F2E1D49F5B1007217DE /* JhtShopCarAnimationImages.bundle in Resources */ = {isa = PBXBuildFile; fileRef = A5EA2F2D1D49F5B1007217DE /* JhtShopCarAnimationImages.bundle */; };
19 | /* End PBXBuildFile section */
20 |
21 | /* Begin PBXContainerItemProxy section */
22 | A5EA2F061D49EBAA007217DE /* PBXContainerItemProxy */ = {
23 | isa = PBXContainerItemProxy;
24 | containerPortal = A5EA2EE41D49EBAA007217DE /* Project object */;
25 | proxyType = 1;
26 | remoteGlobalIDString = A5EA2EEB1D49EBAA007217DE;
27 | remoteInfo = JhtShopCarAnimation;
28 | };
29 | A5EA2F111D49EBAA007217DE /* PBXContainerItemProxy */ = {
30 | isa = PBXContainerItemProxy;
31 | containerPortal = A5EA2EE41D49EBAA007217DE /* Project object */;
32 | proxyType = 1;
33 | remoteGlobalIDString = A5EA2EEB1D49EBAA007217DE;
34 | remoteInfo = JhtShopCarAnimation;
35 | };
36 | /* End PBXContainerItemProxy section */
37 |
38 | /* Begin PBXFileReference section */
39 | 8E6354A221C295AD002859E4 /* JhtAnimationTools.m */ = {isa = PBXFileReference; fileEncoding = 4; lastKnownFileType = sourcecode.c.objc; path = JhtAnimationTools.m; sourceTree = ""; };
40 | 8E6354A421C295AD002859E4 /* JhtAnimationTools.h */ = {isa = PBXFileReference; fileEncoding = 4; lastKnownFileType = sourcecode.c.h; path = JhtAnimationTools.h; sourceTree = ""; };
41 | A5227E0C1E8CF4740072AF69 /* AnimationViewController.h */ = {isa = PBXFileReference; fileEncoding = 4; lastKnownFileType = sourcecode.c.h; path = AnimationViewController.h; sourceTree = ""; };
42 | A5227E0D1E8CF4740072AF69 /* AnimationViewController.m */ = {isa = PBXFileReference; fileEncoding = 4; lastKnownFileType = sourcecode.c.objc; path = AnimationViewController.m; sourceTree = ""; };
43 | A5227E141E8CF4970072AF69 /* AnimationRecordCell.h */ = {isa = PBXFileReference; fileEncoding = 4; lastKnownFileType = sourcecode.c.h; path = AnimationRecordCell.h; sourceTree = ""; };
44 | A5227E151E8CF4970072AF69 /* AnimationRecordCell.m */ = {isa = PBXFileReference; fileEncoding = 4; lastKnownFileType = sourcecode.c.objc; path = AnimationRecordCell.m; sourceTree = ""; };
45 | A5EA2EEC1D49EBAA007217DE /* JhtShopCarAnimation.app */ = {isa = PBXFileReference; explicitFileType = wrapper.application; includeInIndex = 0; path = JhtShopCarAnimation.app; sourceTree = BUILT_PRODUCTS_DIR; };
46 | A5EA2EF01D49EBAA007217DE /* main.m */ = {isa = PBXFileReference; lastKnownFileType = sourcecode.c.objc; path = main.m; sourceTree = ""; };
47 | A5EA2EF21D49EBAA007217DE /* AppDelegate.h */ = {isa = PBXFileReference; lastKnownFileType = sourcecode.c.h; path = AppDelegate.h; sourceTree = ""; };
48 | A5EA2EF31D49EBAA007217DE /* AppDelegate.m */ = {isa = PBXFileReference; lastKnownFileType = sourcecode.c.objc; path = AppDelegate.m; sourceTree = ""; };
49 | A5EA2EF91D49EBAA007217DE /* Base */ = {isa = PBXFileReference; lastKnownFileType = file.storyboard; name = Base; path = Base.lproj/Main.storyboard; sourceTree = ""; };
50 | A5EA2EFB1D49EBAA007217DE /* Assets.xcassets */ = {isa = PBXFileReference; lastKnownFileType = folder.assetcatalog; path = Assets.xcassets; sourceTree = ""; };
51 | A5EA2EFE1D49EBAA007217DE /* Base */ = {isa = PBXFileReference; lastKnownFileType = file.storyboard; name = Base; path = Base.lproj/LaunchScreen.storyboard; sourceTree = ""; };
52 | A5EA2F001D49EBAA007217DE /* Info.plist */ = {isa = PBXFileReference; lastKnownFileType = text.plist.xml; path = Info.plist; sourceTree = ""; };
53 | A5EA2F051D49EBAA007217DE /* JhtShopCarAnimationTests.xctest */ = {isa = PBXFileReference; explicitFileType = wrapper.cfbundle; includeInIndex = 0; path = JhtShopCarAnimationTests.xctest; sourceTree = BUILT_PRODUCTS_DIR; };
54 | A5EA2F101D49EBAA007217DE /* JhtShopCarAnimationUITests.xctest */ = {isa = PBXFileReference; explicitFileType = wrapper.cfbundle; includeInIndex = 0; path = JhtShopCarAnimationUITests.xctest; sourceTree = BUILT_PRODUCTS_DIR; };
55 | A5EA2F2D1D49F5B1007217DE /* JhtShopCarAnimationImages.bundle */ = {isa = PBXFileReference; lastKnownFileType = "wrapper.plug-in"; path = JhtShopCarAnimationImages.bundle; sourceTree = ""; };
56 | /* End PBXFileReference section */
57 |
58 | /* Begin PBXFrameworksBuildPhase section */
59 | A5EA2EE91D49EBAA007217DE /* Frameworks */ = {
60 | isa = PBXFrameworksBuildPhase;
61 | buildActionMask = 2147483647;
62 | files = (
63 | );
64 | runOnlyForDeploymentPostprocessing = 0;
65 | };
66 | A5EA2F021D49EBAA007217DE /* Frameworks */ = {
67 | isa = PBXFrameworksBuildPhase;
68 | buildActionMask = 2147483647;
69 | files = (
70 | );
71 | runOnlyForDeploymentPostprocessing = 0;
72 | };
73 | A5EA2F0D1D49EBAA007217DE /* Frameworks */ = {
74 | isa = PBXFrameworksBuildPhase;
75 | buildActionMask = 2147483647;
76 | files = (
77 | );
78 | runOnlyForDeploymentPostprocessing = 0;
79 | };
80 | /* End PBXFrameworksBuildPhase section */
81 |
82 | /* Begin PBXGroup section */
83 | 8E6354A021C295AD002859E4 /* JhtAnimationTools */ = {
84 | isa = PBXGroup;
85 | children = (
86 | 8E6354A421C295AD002859E4 /* JhtAnimationTools.h */,
87 | 8E6354A221C295AD002859E4 /* JhtAnimationTools.m */,
88 | );
89 | path = JhtAnimationTools;
90 | sourceTree = "";
91 | };
92 | A5227E0B1E8CF4740072AF69 /* AnimationViewController */ = {
93 | isa = PBXGroup;
94 | children = (
95 | A5227E0C1E8CF4740072AF69 /* AnimationViewController.h */,
96 | A5227E0D1E8CF4740072AF69 /* AnimationViewController.m */,
97 | );
98 | path = AnimationViewController;
99 | sourceTree = "";
100 | };
101 | A5227E131E8CF4970072AF69 /* AnimationRecordCell */ = {
102 | isa = PBXGroup;
103 | children = (
104 | A5227E141E8CF4970072AF69 /* AnimationRecordCell.h */,
105 | A5227E151E8CF4970072AF69 /* AnimationRecordCell.m */,
106 | );
107 | path = AnimationRecordCell;
108 | sourceTree = "";
109 | };
110 | A5EA2EE31D49EBAA007217DE = {
111 | isa = PBXGroup;
112 | children = (
113 | 8E6354A021C295AD002859E4 /* JhtAnimationTools */,
114 | A5EA2EEE1D49EBAA007217DE /* JhtShopCarAnimation */,
115 | A5EA2EED1D49EBAA007217DE /* Products */,
116 | );
117 | sourceTree = "";
118 | };
119 | A5EA2EED1D49EBAA007217DE /* Products */ = {
120 | isa = PBXGroup;
121 | children = (
122 | A5EA2EEC1D49EBAA007217DE /* JhtShopCarAnimation.app */,
123 | A5EA2F051D49EBAA007217DE /* JhtShopCarAnimationTests.xctest */,
124 | A5EA2F101D49EBAA007217DE /* JhtShopCarAnimationUITests.xctest */,
125 | );
126 | name = Products;
127 | sourceTree = "";
128 | };
129 | A5EA2EEE1D49EBAA007217DE /* JhtShopCarAnimation */ = {
130 | isa = PBXGroup;
131 | children = (
132 | A5EA2EF21D49EBAA007217DE /* AppDelegate.h */,
133 | A5EA2EF31D49EBAA007217DE /* AppDelegate.m */,
134 | A5227E0B1E8CF4740072AF69 /* AnimationViewController */,
135 | A5227E131E8CF4970072AF69 /* AnimationRecordCell */,
136 | A5EA2F2C1D49F5B1007217DE /* JhtTemp */,
137 | A5EA2EF81D49EBAA007217DE /* Main.storyboard */,
138 | A5EA2EFB1D49EBAA007217DE /* Assets.xcassets */,
139 | A5EA2EFD1D49EBAA007217DE /* LaunchScreen.storyboard */,
140 | A5EA2F001D49EBAA007217DE /* Info.plist */,
141 | A5EA2EEF1D49EBAA007217DE /* Supporting Files */,
142 | );
143 | path = JhtShopCarAnimation;
144 | sourceTree = "";
145 | };
146 | A5EA2EEF1D49EBAA007217DE /* Supporting Files */ = {
147 | isa = PBXGroup;
148 | children = (
149 | A5EA2EF01D49EBAA007217DE /* main.m */,
150 | );
151 | name = "Supporting Files";
152 | sourceTree = "";
153 | };
154 | A5EA2F2C1D49F5B1007217DE /* JhtTemp */ = {
155 | isa = PBXGroup;
156 | children = (
157 | A5EA2F2D1D49F5B1007217DE /* JhtShopCarAnimationImages.bundle */,
158 | );
159 | path = JhtTemp;
160 | sourceTree = "";
161 | };
162 | /* End PBXGroup section */
163 |
164 | /* Begin PBXNativeTarget section */
165 | A5EA2EEB1D49EBAA007217DE /* JhtShopCarAnimation */ = {
166 | isa = PBXNativeTarget;
167 | buildConfigurationList = A5EA2F191D49EBAA007217DE /* Build configuration list for PBXNativeTarget "JhtShopCarAnimation" */;
168 | buildPhases = (
169 | A5EA2EE81D49EBAA007217DE /* Sources */,
170 | A5EA2EE91D49EBAA007217DE /* Frameworks */,
171 | A5EA2EEA1D49EBAA007217DE /* Resources */,
172 | );
173 | buildRules = (
174 | );
175 | dependencies = (
176 | );
177 | name = JhtShopCarAnimation;
178 | productName = JhtShopCarAnimation;
179 | productReference = A5EA2EEC1D49EBAA007217DE /* JhtShopCarAnimation.app */;
180 | productType = "com.apple.product-type.application";
181 | };
182 | A5EA2F041D49EBAA007217DE /* JhtShopCarAnimationTests */ = {
183 | isa = PBXNativeTarget;
184 | buildConfigurationList = A5EA2F1C1D49EBAA007217DE /* Build configuration list for PBXNativeTarget "JhtShopCarAnimationTests" */;
185 | buildPhases = (
186 | A5EA2F011D49EBAA007217DE /* Sources */,
187 | A5EA2F021D49EBAA007217DE /* Frameworks */,
188 | A5EA2F031D49EBAA007217DE /* Resources */,
189 | );
190 | buildRules = (
191 | );
192 | dependencies = (
193 | A5EA2F071D49EBAA007217DE /* PBXTargetDependency */,
194 | );
195 | name = JhtShopCarAnimationTests;
196 | productName = JhtShopCarAnimationTests;
197 | productReference = A5EA2F051D49EBAA007217DE /* JhtShopCarAnimationTests.xctest */;
198 | productType = "com.apple.product-type.bundle.unit-test";
199 | };
200 | A5EA2F0F1D49EBAA007217DE /* JhtShopCarAnimationUITests */ = {
201 | isa = PBXNativeTarget;
202 | buildConfigurationList = A5EA2F1F1D49EBAA007217DE /* Build configuration list for PBXNativeTarget "JhtShopCarAnimationUITests" */;
203 | buildPhases = (
204 | A5EA2F0C1D49EBAA007217DE /* Sources */,
205 | A5EA2F0D1D49EBAA007217DE /* Frameworks */,
206 | A5EA2F0E1D49EBAA007217DE /* Resources */,
207 | );
208 | buildRules = (
209 | );
210 | dependencies = (
211 | A5EA2F121D49EBAA007217DE /* PBXTargetDependency */,
212 | );
213 | name = JhtShopCarAnimationUITests;
214 | productName = JhtShopCarAnimationUITests;
215 | productReference = A5EA2F101D49EBAA007217DE /* JhtShopCarAnimationUITests.xctest */;
216 | productType = "com.apple.product-type.bundle.ui-testing";
217 | };
218 | /* End PBXNativeTarget section */
219 |
220 | /* Begin PBXProject section */
221 | A5EA2EE41D49EBAA007217DE /* Project object */ = {
222 | isa = PBXProject;
223 | attributes = {
224 | LastUpgradeCheck = 0730;
225 | ORGANIZATIONNAME = JhtShopCarAnimation;
226 | TargetAttributes = {
227 | A5EA2EEB1D49EBAA007217DE = {
228 | CreatedOnToolsVersion = 7.3.1;
229 | DevelopmentTeam = 8C4D9692Z4;
230 | };
231 | A5EA2F041D49EBAA007217DE = {
232 | CreatedOnToolsVersion = 7.3.1;
233 | TestTargetID = A5EA2EEB1D49EBAA007217DE;
234 | };
235 | A5EA2F0F1D49EBAA007217DE = {
236 | CreatedOnToolsVersion = 7.3.1;
237 | TestTargetID = A5EA2EEB1D49EBAA007217DE;
238 | };
239 | };
240 | };
241 | buildConfigurationList = A5EA2EE71D49EBAA007217DE /* Build configuration list for PBXProject "JhtShopCarAnimation" */;
242 | compatibilityVersion = "Xcode 3.2";
243 | developmentRegion = English;
244 | hasScannedForEncodings = 0;
245 | knownRegions = (
246 | en,
247 | Base,
248 | );
249 | mainGroup = A5EA2EE31D49EBAA007217DE;
250 | productRefGroup = A5EA2EED1D49EBAA007217DE /* Products */;
251 | projectDirPath = "";
252 | projectRoot = "";
253 | targets = (
254 | A5EA2EEB1D49EBAA007217DE /* JhtShopCarAnimation */,
255 | A5EA2F041D49EBAA007217DE /* JhtShopCarAnimationTests */,
256 | A5EA2F0F1D49EBAA007217DE /* JhtShopCarAnimationUITests */,
257 | );
258 | };
259 | /* End PBXProject section */
260 |
261 | /* Begin PBXResourcesBuildPhase section */
262 | A5EA2EEA1D49EBAA007217DE /* Resources */ = {
263 | isa = PBXResourcesBuildPhase;
264 | buildActionMask = 2147483647;
265 | files = (
266 | A5EA2F2E1D49F5B1007217DE /* JhtShopCarAnimationImages.bundle in Resources */,
267 | A5EA2EFF1D49EBAA007217DE /* LaunchScreen.storyboard in Resources */,
268 | A5EA2EFC1D49EBAA007217DE /* Assets.xcassets in Resources */,
269 | A5EA2EFA1D49EBAA007217DE /* Main.storyboard in Resources */,
270 | );
271 | runOnlyForDeploymentPostprocessing = 0;
272 | };
273 | A5EA2F031D49EBAA007217DE /* Resources */ = {
274 | isa = PBXResourcesBuildPhase;
275 | buildActionMask = 2147483647;
276 | files = (
277 | );
278 | runOnlyForDeploymentPostprocessing = 0;
279 | };
280 | A5EA2F0E1D49EBAA007217DE /* Resources */ = {
281 | isa = PBXResourcesBuildPhase;
282 | buildActionMask = 2147483647;
283 | files = (
284 | );
285 | runOnlyForDeploymentPostprocessing = 0;
286 | };
287 | /* End PBXResourcesBuildPhase section */
288 |
289 | /* Begin PBXSourcesBuildPhase section */
290 | A5EA2EE81D49EBAA007217DE /* Sources */ = {
291 | isa = PBXSourcesBuildPhase;
292 | buildActionMask = 2147483647;
293 | files = (
294 | A5EA2EF41D49EBAA007217DE /* AppDelegate.m in Sources */,
295 | A5EA2EF11D49EBAA007217DE /* main.m in Sources */,
296 | 8E6354A621C295AE002859E4 /* JhtAnimationTools.m in Sources */,
297 | A5227E0E1E8CF4740072AF69 /* AnimationViewController.m in Sources */,
298 | A5227E161E8CF4970072AF69 /* AnimationRecordCell.m in Sources */,
299 | );
300 | runOnlyForDeploymentPostprocessing = 0;
301 | };
302 | A5EA2F011D49EBAA007217DE /* Sources */ = {
303 | isa = PBXSourcesBuildPhase;
304 | buildActionMask = 2147483647;
305 | files = (
306 | );
307 | runOnlyForDeploymentPostprocessing = 0;
308 | };
309 | A5EA2F0C1D49EBAA007217DE /* Sources */ = {
310 | isa = PBXSourcesBuildPhase;
311 | buildActionMask = 2147483647;
312 | files = (
313 | );
314 | runOnlyForDeploymentPostprocessing = 0;
315 | };
316 | /* End PBXSourcesBuildPhase section */
317 |
318 | /* Begin PBXTargetDependency section */
319 | A5EA2F071D49EBAA007217DE /* PBXTargetDependency */ = {
320 | isa = PBXTargetDependency;
321 | target = A5EA2EEB1D49EBAA007217DE /* JhtShopCarAnimation */;
322 | targetProxy = A5EA2F061D49EBAA007217DE /* PBXContainerItemProxy */;
323 | };
324 | A5EA2F121D49EBAA007217DE /* PBXTargetDependency */ = {
325 | isa = PBXTargetDependency;
326 | target = A5EA2EEB1D49EBAA007217DE /* JhtShopCarAnimation */;
327 | targetProxy = A5EA2F111D49EBAA007217DE /* PBXContainerItemProxy */;
328 | };
329 | /* End PBXTargetDependency section */
330 |
331 | /* Begin PBXVariantGroup section */
332 | A5EA2EF81D49EBAA007217DE /* Main.storyboard */ = {
333 | isa = PBXVariantGroup;
334 | children = (
335 | A5EA2EF91D49EBAA007217DE /* Base */,
336 | );
337 | name = Main.storyboard;
338 | sourceTree = "";
339 | };
340 | A5EA2EFD1D49EBAA007217DE /* LaunchScreen.storyboard */ = {
341 | isa = PBXVariantGroup;
342 | children = (
343 | A5EA2EFE1D49EBAA007217DE /* Base */,
344 | );
345 | name = LaunchScreen.storyboard;
346 | sourceTree = "";
347 | };
348 | /* End PBXVariantGroup section */
349 |
350 | /* Begin XCBuildConfiguration section */
351 | A5EA2F171D49EBAA007217DE /* Debug */ = {
352 | isa = XCBuildConfiguration;
353 | buildSettings = {
354 | ALWAYS_SEARCH_USER_PATHS = NO;
355 | CLANG_ANALYZER_NONNULL = YES;
356 | CLANG_CXX_LANGUAGE_STANDARD = "gnu++0x";
357 | CLANG_CXX_LIBRARY = "libc++";
358 | CLANG_ENABLE_MODULES = YES;
359 | CLANG_ENABLE_OBJC_ARC = YES;
360 | CLANG_WARN_BOOL_CONVERSION = YES;
361 | CLANG_WARN_CONSTANT_CONVERSION = YES;
362 | CLANG_WARN_DIRECT_OBJC_ISA_USAGE = YES_ERROR;
363 | CLANG_WARN_EMPTY_BODY = YES;
364 | CLANG_WARN_ENUM_CONVERSION = YES;
365 | CLANG_WARN_INT_CONVERSION = YES;
366 | CLANG_WARN_OBJC_ROOT_CLASS = YES_ERROR;
367 | CLANG_WARN_UNREACHABLE_CODE = YES;
368 | CLANG_WARN__DUPLICATE_METHOD_MATCH = YES;
369 | "CODE_SIGN_IDENTITY[sdk=iphoneos*]" = "iPhone Developer";
370 | COPY_PHASE_STRIP = NO;
371 | DEBUG_INFORMATION_FORMAT = dwarf;
372 | ENABLE_STRICT_OBJC_MSGSEND = YES;
373 | ENABLE_TESTABILITY = YES;
374 | GCC_C_LANGUAGE_STANDARD = gnu99;
375 | GCC_DYNAMIC_NO_PIC = NO;
376 | GCC_NO_COMMON_BLOCKS = YES;
377 | GCC_OPTIMIZATION_LEVEL = 0;
378 | GCC_PREPROCESSOR_DEFINITIONS = (
379 | "DEBUG=1",
380 | "$(inherited)",
381 | );
382 | GCC_WARN_64_TO_32_BIT_CONVERSION = YES;
383 | GCC_WARN_ABOUT_RETURN_TYPE = YES_ERROR;
384 | GCC_WARN_UNDECLARED_SELECTOR = YES;
385 | GCC_WARN_UNINITIALIZED_AUTOS = YES_AGGRESSIVE;
386 | GCC_WARN_UNUSED_FUNCTION = YES;
387 | GCC_WARN_UNUSED_VARIABLE = YES;
388 | IPHONEOS_DEPLOYMENT_TARGET = 9.3;
389 | MTL_ENABLE_DEBUG_INFO = YES;
390 | ONLY_ACTIVE_ARCH = YES;
391 | SDKROOT = iphoneos;
392 | };
393 | name = Debug;
394 | };
395 | A5EA2F181D49EBAA007217DE /* Release */ = {
396 | isa = XCBuildConfiguration;
397 | buildSettings = {
398 | ALWAYS_SEARCH_USER_PATHS = NO;
399 | CLANG_ANALYZER_NONNULL = YES;
400 | CLANG_CXX_LANGUAGE_STANDARD = "gnu++0x";
401 | CLANG_CXX_LIBRARY = "libc++";
402 | CLANG_ENABLE_MODULES = YES;
403 | CLANG_ENABLE_OBJC_ARC = YES;
404 | CLANG_WARN_BOOL_CONVERSION = YES;
405 | CLANG_WARN_CONSTANT_CONVERSION = YES;
406 | CLANG_WARN_DIRECT_OBJC_ISA_USAGE = YES_ERROR;
407 | CLANG_WARN_EMPTY_BODY = YES;
408 | CLANG_WARN_ENUM_CONVERSION = YES;
409 | CLANG_WARN_INT_CONVERSION = YES;
410 | CLANG_WARN_OBJC_ROOT_CLASS = YES_ERROR;
411 | CLANG_WARN_UNREACHABLE_CODE = YES;
412 | CLANG_WARN__DUPLICATE_METHOD_MATCH = YES;
413 | "CODE_SIGN_IDENTITY[sdk=iphoneos*]" = "iPhone Developer";
414 | COPY_PHASE_STRIP = NO;
415 | DEBUG_INFORMATION_FORMAT = "dwarf-with-dsym";
416 | ENABLE_NS_ASSERTIONS = NO;
417 | ENABLE_STRICT_OBJC_MSGSEND = YES;
418 | GCC_C_LANGUAGE_STANDARD = gnu99;
419 | GCC_NO_COMMON_BLOCKS = YES;
420 | GCC_WARN_64_TO_32_BIT_CONVERSION = YES;
421 | GCC_WARN_ABOUT_RETURN_TYPE = YES_ERROR;
422 | GCC_WARN_UNDECLARED_SELECTOR = YES;
423 | GCC_WARN_UNINITIALIZED_AUTOS = YES_AGGRESSIVE;
424 | GCC_WARN_UNUSED_FUNCTION = YES;
425 | GCC_WARN_UNUSED_VARIABLE = YES;
426 | IPHONEOS_DEPLOYMENT_TARGET = 9.3;
427 | MTL_ENABLE_DEBUG_INFO = NO;
428 | SDKROOT = iphoneos;
429 | VALIDATE_PRODUCT = YES;
430 | };
431 | name = Release;
432 | };
433 | A5EA2F1A1D49EBAA007217DE /* Debug */ = {
434 | isa = XCBuildConfiguration;
435 | buildSettings = {
436 | ASSETCATALOG_COMPILER_APPICON_NAME = AppIcon;
437 | CODE_SIGN_IDENTITY = "iPhone Developer";
438 | DEVELOPMENT_TEAM = 8C4D9692Z4;
439 | INFOPLIST_FILE = JhtShopCarAnimation/Info.plist;
440 | IPHONEOS_DEPLOYMENT_TARGET = 8.0;
441 | LD_RUNPATH_SEARCH_PATHS = "$(inherited) @executable_path/Frameworks";
442 | PRODUCT_BUNDLE_IDENTIFIER = com.JhtShopCarAnimation;
443 | PRODUCT_NAME = "$(TARGET_NAME)";
444 | TARGETED_DEVICE_FAMILY = 1;
445 | };
446 | name = Debug;
447 | };
448 | A5EA2F1B1D49EBAA007217DE /* Release */ = {
449 | isa = XCBuildConfiguration;
450 | buildSettings = {
451 | ASSETCATALOG_COMPILER_APPICON_NAME = AppIcon;
452 | CODE_SIGN_IDENTITY = "iPhone Developer";
453 | DEVELOPMENT_TEAM = 8C4D9692Z4;
454 | INFOPLIST_FILE = JhtShopCarAnimation/Info.plist;
455 | IPHONEOS_DEPLOYMENT_TARGET = 8.0;
456 | LD_RUNPATH_SEARCH_PATHS = "$(inherited) @executable_path/Frameworks";
457 | PRODUCT_BUNDLE_IDENTIFIER = com.JhtShopCarAnimation;
458 | PRODUCT_NAME = "$(TARGET_NAME)";
459 | TARGETED_DEVICE_FAMILY = 1;
460 | };
461 | name = Release;
462 | };
463 | A5EA2F1D1D49EBAA007217DE /* Debug */ = {
464 | isa = XCBuildConfiguration;
465 | buildSettings = {
466 | BUNDLE_LOADER = "$(TEST_HOST)";
467 | INFOPLIST_FILE = JhtShopCarAnimationTests/Info.plist;
468 | LD_RUNPATH_SEARCH_PATHS = "$(inherited) @executable_path/Frameworks @loader_path/Frameworks";
469 | PRODUCT_BUNDLE_IDENTIFIER = com.jht.JhtShopCarAnimationTests;
470 | PRODUCT_NAME = "$(TARGET_NAME)";
471 | TEST_HOST = "$(BUILT_PRODUCTS_DIR)/JhtShopCarAnimation.app/JhtShopCarAnimation";
472 | };
473 | name = Debug;
474 | };
475 | A5EA2F1E1D49EBAA007217DE /* Release */ = {
476 | isa = XCBuildConfiguration;
477 | buildSettings = {
478 | BUNDLE_LOADER = "$(TEST_HOST)";
479 | INFOPLIST_FILE = JhtShopCarAnimationTests/Info.plist;
480 | LD_RUNPATH_SEARCH_PATHS = "$(inherited) @executable_path/Frameworks @loader_path/Frameworks";
481 | PRODUCT_BUNDLE_IDENTIFIER = com.jht.JhtShopCarAnimationTests;
482 | PRODUCT_NAME = "$(TARGET_NAME)";
483 | TEST_HOST = "$(BUILT_PRODUCTS_DIR)/JhtShopCarAnimation.app/JhtShopCarAnimation";
484 | };
485 | name = Release;
486 | };
487 | A5EA2F201D49EBAA007217DE /* Debug */ = {
488 | isa = XCBuildConfiguration;
489 | buildSettings = {
490 | INFOPLIST_FILE = JhtShopCarAnimationUITests/Info.plist;
491 | LD_RUNPATH_SEARCH_PATHS = "$(inherited) @executable_path/Frameworks @loader_path/Frameworks";
492 | PRODUCT_BUNDLE_IDENTIFIER = com.jht.JhtShopCarAnimationUITests;
493 | PRODUCT_NAME = "$(TARGET_NAME)";
494 | TEST_TARGET_NAME = JhtShopCarAnimation;
495 | };
496 | name = Debug;
497 | };
498 | A5EA2F211D49EBAA007217DE /* Release */ = {
499 | isa = XCBuildConfiguration;
500 | buildSettings = {
501 | INFOPLIST_FILE = JhtShopCarAnimationUITests/Info.plist;
502 | LD_RUNPATH_SEARCH_PATHS = "$(inherited) @executable_path/Frameworks @loader_path/Frameworks";
503 | PRODUCT_BUNDLE_IDENTIFIER = com.jht.JhtShopCarAnimationUITests;
504 | PRODUCT_NAME = "$(TARGET_NAME)";
505 | TEST_TARGET_NAME = JhtShopCarAnimation;
506 | };
507 | name = Release;
508 | };
509 | /* End XCBuildConfiguration section */
510 |
511 | /* Begin XCConfigurationList section */
512 | A5EA2EE71D49EBAA007217DE /* Build configuration list for PBXProject "JhtShopCarAnimation" */ = {
513 | isa = XCConfigurationList;
514 | buildConfigurations = (
515 | A5EA2F171D49EBAA007217DE /* Debug */,
516 | A5EA2F181D49EBAA007217DE /* Release */,
517 | );
518 | defaultConfigurationIsVisible = 0;
519 | defaultConfigurationName = Release;
520 | };
521 | A5EA2F191D49EBAA007217DE /* Build configuration list for PBXNativeTarget "JhtShopCarAnimation" */ = {
522 | isa = XCConfigurationList;
523 | buildConfigurations = (
524 | A5EA2F1A1D49EBAA007217DE /* Debug */,
525 | A5EA2F1B1D49EBAA007217DE /* Release */,
526 | );
527 | defaultConfigurationIsVisible = 0;
528 | defaultConfigurationName = Release;
529 | };
530 | A5EA2F1C1D49EBAA007217DE /* Build configuration list for PBXNativeTarget "JhtShopCarAnimationTests" */ = {
531 | isa = XCConfigurationList;
532 | buildConfigurations = (
533 | A5EA2F1D1D49EBAA007217DE /* Debug */,
534 | A5EA2F1E1D49EBAA007217DE /* Release */,
535 | );
536 | defaultConfigurationIsVisible = 0;
537 | defaultConfigurationName = Release;
538 | };
539 | A5EA2F1F1D49EBAA007217DE /* Build configuration list for PBXNativeTarget "JhtShopCarAnimationUITests" */ = {
540 | isa = XCConfigurationList;
541 | buildConfigurations = (
542 | A5EA2F201D49EBAA007217DE /* Debug */,
543 | A5EA2F211D49EBAA007217DE /* Release */,
544 | );
545 | defaultConfigurationIsVisible = 0;
546 | defaultConfigurationName = Release;
547 | };
548 | /* End XCConfigurationList section */
549 | };
550 | rootObject = A5EA2EE41D49EBAA007217DE /* Project object */;
551 | }
552 |
--------------------------------------------------------------------------------