Commit ac9cc1e151b32d8e06a852f1954ee5240d16c6a1
1 parent
6cbde3a598
Exists in
master
活动sdk增加活动类型参数
Showing 6 changed files with 12 additions and 13 deletions Side-by-side Diff
- ios/GameActivitySDK.framework/Versions/A/GameActivitySDK
- ios/GameActivitySDK.framework/Versions/A/Headers/LetsGameActivityAPI.h
- ios/GameSDK.zip
- ios/GameSDKDemo/GameSDKDemo.xcodeproj/project.xcworkspace/xcuserdata/yanglele.xcuserdatad/UserInterfaceState.xcuserstate
- ios/GameSDKDemo/letsgameDemo/LSGAppDelegate.m
- ios/GameSDKDemo/letsgameDemo/LSGMainViewController.m
ios/GameActivitySDK.framework/Versions/A/GameActivitySDK
No preview for this file type
ios/GameActivitySDK.framework/Versions/A/Headers/LetsGameActivityAPI.h
... | ... | @@ -14,8 +14,6 @@ static NSString *actVersion = @"1.0.2"; |
14 | 14 | @interface LetsGameActivityAPI : NSObject<UIApplicationDelegate> |
15 | 15 | |
16 | 16 | @property(nonatomic, assign) int isDebug; |
17 | -@property(nonatomic, assign) int allowRotate; | |
18 | -@property(nonatomic, assign) BOOL supportLandscape; | |
19 | 17 | |
20 | 18 | +(instancetype)instance; |
21 | 19 | |
... | ... | @@ -23,8 +21,6 @@ static NSString *actVersion = @"1.0.2"; |
23 | 21 | |
24 | 22 | -(void)decideIsDebug:(int)isDebug; |
25 | 23 | |
26 | --(void)decideAllowRotate:(int)allowRotate; | |
27 | - | |
28 | 24 | -(void)GameActivityWithParaDictory:(NSDictionary *)paraDictory handleCallBackL:(void(^)(void))accomplistCallBack; |
29 | 25 | |
30 | 26 | @end |
ios/GameSDK.zip
No preview for this file type
ios/GameSDKDemo/GameSDKDemo.xcodeproj/project.xcworkspace/xcuserdata/yanglele.xcuserdatad/UserInterfaceState.xcuserstate
No preview for this file type
ios/GameSDKDemo/letsgameDemo/LSGAppDelegate.m
... | ... | @@ -65,12 +65,5 @@ |
65 | 65 | |
66 | 66 | } |
67 | 67 | |
68 | -//-(UIInterfaceOrientationMask)application:(UIApplication *)application supportedInterfaceOrientationsForWindow:(UIWindow *)window{ | |
69 | -// if([LetsGameActivityAPI instance].supportLandscape == YES){ | |
70 | -// return UIInterfaceOrientationMaskPortrait; | |
71 | -// }else{ | |
72 | -// return UIInterfaceOrientationMaskLandscape; | |
73 | -// } | |
74 | -//} | |
75 | 68 | |
76 | 69 | @end |
ios/GameSDKDemo/letsgameDemo/LSGMainViewController.m
... | ... | @@ -16,6 +16,9 @@ |
16 | 16 | @property (nonatomic, strong) UILabel *resultLabel; |
17 | 17 | |
18 | 18 | @property(nonatomic,copy) NSString *sessionKey; |
19 | + | |
20 | +@property(nonatomic, strong) UITextField *activityTextField; | |
21 | + | |
19 | 22 | @end |
20 | 23 | |
21 | 24 | @implementation LSGMainViewController |
... | ... | @@ -67,6 +70,14 @@ |
67 | 70 | activityBtn.titleLabel.font = [UIFont systemFontOfSize:15]; |
68 | 71 | [activityBtn addTarget:self action:@selector(onActivity) forControlEvents:UIControlEventTouchUpInside]; |
69 | 72 | [self.view addSubview:activityBtn]; |
73 | + | |
74 | + UITextField *activityField = [[UITextField alloc] initWithFrame:CGRectMake(220, 320, 100, 30)]; | |
75 | + activityField.placeholder = @"活动类型"; | |
76 | + activityField.backgroundColor = [UIColor whiteColor]; | |
77 | + self.activityTextField = activityField; | |
78 | + [self.view addSubview:self.activityTextField]; | |
79 | + | |
80 | + | |
70 | 81 | |
71 | 82 | } |
72 | 83 | |
... | ... | @@ -168,8 +179,6 @@ |
168 | 179 | -(void)onActivity{ |
169 | 180 | |
170 | 181 | [[LetsGameActivityAPI instance] decideIsDebug:1]; |
171 | -// [LetsGameActivityAPI instance].supportLandscape = YES; | |
172 | -// [[LetsGameActivityAPI instance] decideAllowRotate:1]; | |
173 | 182 | NSMutableDictionary *activityInfo = [NSMutableDictionary dictionary]; |
174 | 183 | [activityInfo setValue:@"100" forKey:@"appId"]; |
175 | 184 | [activityInfo setValue:@"f899139df5e1059396431415e770c6dd" forKey:@"appKey"]; |
... | ... | @@ -179,6 +188,7 @@ |
179 | 188 | [activityInfo setValue:@"222" forKey:@"roleId"]; |
180 | 189 | [activityInfo setValue:@"ccc" forKey:@"roleName"]; |
181 | 190 | [activityInfo setValue:@"888" forKey:@"diamond"]; |
191 | + [activityInfo setValue:self.activityTextField.text forKey:@"campaignType"]; | |
182 | 192 | [[LetsGameActivityAPI instance] GameActivityWithParaDictory:activityInfo handleCallBackL:^{ |
183 | 193 | NSLog(@"activity finish!"); |
184 | 194 | }]; |