Commit e8af7574172ea1934a233bfe357ded4e4c25c098

Authored by alexYang
1 parent 51fd2d6b45
Exists in master and in 1 other branch dev

wechat login add

Showing 15 changed files with 283 additions and 58 deletions Side-by-side Diff

... ... @@ -2,7 +2,7 @@
2 2  
3 3  
4 4 接入手册
5   -V 3.4.8
  5 +V 3.4.9
6 6 2017年6月13日
7 7  
8 8 ## 概述
... ... @@ -14,6 +14,8 @@ V 3.4.8
14 14 MobileCoreServices.framework、SystemConfiguration.framework、libz.dylib、CFNetwork.framework、GameSDK.framework、StoreKit.framework、GameSDKResources.bundle
15 15 + 以下为可选,若接入vk登录则需要添加以下framework和bundle,其中VKSdk.framework和VKSDKResources.bundle请自行从vk.com下载,使用1.3版本
16 16 VKSdk.framework、VKBridge.framework、VKSDKResources.bundle
  17 ++ 以下可选,若接入微信登陆则需要添加如下的framework:
  18 +libsqlite3.0.dylib, libc++.dylib, Security.framework, CoreTelephony.framework, CFNetwork.framework
17 19  
18 20  
19 21 ### 2、引入头文件,设置build setting
... ... @@ -32,6 +34,9 @@ Xcode 5: Open your application settings then select the Info tab. In the URL Typ
32 34 ![](images/vk1.jpg)
33 35 Xcode 4: Open your Info.plist then add a new row URL Types. Set the URL identifier to vk+APP_ID
34 36 ![](images/vk2.jpg)
  37 +3)配置UIL-schema(weChat专用,不接入可以忽略)
  38 +选中“TARGETS”一栏,在“info”标签栏的“URL type“添加“URL scheme”为你所注册的应用程序id
  39 +选中“TARGETS”一栏,在“info”标签栏的“LSApplicationQueriesSchemes“添加weixin和wechat
35 40  
36 41 ### 4、在工程里添加SDK登录代码
37 42  
... ... @@ -142,4 +147,12 @@ FB登录之后会产生token并自动登录,需要如果需要token的话,
142 147 }
143 148 }];
144 149  
  150 +### 11、微信登陆
145 151  
  152 + 首先在- (BOOL)application:(UIApplication *)application didFinishLaunchingWithOptions:(NSDictionary *)launchOptions;方法中向微信注册应用
  153 + //微信登陆
  154 + [[LetsGameAPI instance] registerAppWeChatWithAppId:@"appId" appKey:@"appKey" Success:^{
  155 + NSLog(@"注册成功");
  156 + } failure:^{
  157 + NSLog(@"注册失败");
  158 + }];
ios/GameSDK.framework/Versions/A/GameSDK
No preview for this file type
ios/GameSDK.framework/Versions/A/Headers/LSGAccount.h
... ... @@ -6,10 +6,11 @@ typedef NS_ENUM(NSInteger, LSGAccountType) {
6 6 LSGAccountTypeQuickRegist = 4,
7 7 LSGAccountTypeVKRegist = 8,
8 8 LSGAccountTypeGoogleRegist = 16,
  9 + LSGAccountTypeWeChatRegist = 32,
9 10 };
10 11  
11 12 //判断是不是自动登录情况
12   -#define LSGAccountTypeBaseLogin 32
  13 +#define LSGAccountTypeBaseLogin 64
13 14  
14 15 @interface LSGAccount : NSObject
15 16  
ios/GameSDK.framework/Versions/A/Headers/LetsGameAPI.h
... ... @@ -11,11 +11,13 @@ static BOOL isDisableFB = NO;
11 11  
12 12 static BOOL isEnableVK = NO;
13 13  
  14 +static BOOL isEnableWeChat = YES;
  15 +
14 16 static BOOL isDisableGoogle = NO;
15 17  
16 18 static BOOL hiddenLogo = NO;
17 19  
18   -static NSString *version = @"3.4.8";
  20 +static NSString *version = @"3.4.9";
19 21  
20 22 @interface LetsGameAPI : NSObject<UIApplicationDelegate>
21 23  
... ... @@ -39,6 +41,7 @@ static NSString *version = @&quot;3.4.8&quot;;
39 41 +(void)disableGoogle:(BOOL)isDisable;
40 42 +(BOOL)isFBDisable;
41 43 +(BOOL)isVKEnable;
  44 ++(BOOL)isWeChatEnable;
42 45 +(BOOL)isGoogleDisable;
43 46 +(void)hiddenLogo:(BOOL)isHidden;
44 47 +(BOOL)isHiddenLogo;
... ... @@ -46,6 +49,13 @@ static NSString *version = @&quot;3.4.8&quot;;
46 49 - (void)logout;
47 50  
48 51 - (void)hide;
  52 +//是否安装微信
  53 +-(BOOL)isWeChatInstall;
  54 +//向微信注册应用
  55 +-(void)registerAppWeChatWithAppId:(NSString *)appId
  56 + appKey:(NSString *)appKey
  57 + Success:(void (^)())success
  58 + failure:(void (^)())failure;
49 59  
50 60 - (BOOL)handleOpenURL:(NSURL *)url
51 61 sourceApplication:(NSString *)sourceApplication;
No preview for this file type
ios/GameSDKDemo/GameSDKDemo.xcodeproj/project.pbxproj
... ... @@ -15,6 +15,10 @@
15 15 3CD53D9D1B81F37900E1B01A /* VKSdkResources.bundle in Resources */ = {isa = PBXBuildFile; fileRef = 3CD53D9C1B81F37900E1B01A /* VKSdkResources.bundle */; };
16 16 752A5F421CDC826A00C36131 /* GameSDKResources.bundle in Resources */ = {isa = PBXBuildFile; fileRef = 752A5F411CDC826A00C36131 /* GameSDKResources.bundle */; };
17 17 752A5F4A1CDC8B3200C36131 /* GameSDK.framework in Frameworks */ = {isa = PBXBuildFile; fileRef = 752A5F491CDC8B3200C36131 /* GameSDK.framework */; };
  18 + 75864D631FF35A22002C9012 /* libsqlite3.tbd in Frameworks */ = {isa = PBXBuildFile; fileRef = 75864D601FF35A22002C9012 /* libsqlite3.tbd */; };
  19 + 75864D651FF35A3A002C9012 /* CoreTelephony.framework in Frameworks */ = {isa = PBXBuildFile; fileRef = 75864D641FF35A3A002C9012 /* CoreTelephony.framework */; };
  20 + 75864D671FF35A48002C9012 /* libz.tbd in Frameworks */ = {isa = PBXBuildFile; fileRef = 75864D661FF35A48002C9012 /* libz.tbd */; };
  21 + 75864D691FF35A58002C9012 /* libc++.tbd in Frameworks */ = {isa = PBXBuildFile; fileRef = 75864D681FF35A57002C9012 /* libc++.tbd */; };
18 22 9934F1B219303DC6005EF4AB /* Foundation.framework in Frameworks */ = {isa = PBXBuildFile; fileRef = 9934F1B119303DC6005EF4AB /* Foundation.framework */; };
19 23 9934F1B619303DC6005EF4AB /* UIKit.framework in Frameworks */ = {isa = PBXBuildFile; fileRef = 9934F1B519303DC6005EF4AB /* UIKit.framework */; };
20 24 9934F1BE19303DC6005EF4AB /* main.m in Sources */ = {isa = PBXBuildFile; fileRef = 9934F1BD19303DC6005EF4AB /* main.m */; };
... ... @@ -26,9 +30,9 @@
26 30 /* End PBXBuildFile section */
27 31  
28 32 /* Begin PBXContainerItemProxy section */
29   - 75F818A01EEAA3EE0088B62F /* PBXContainerItemProxy */ = {
  33 + 75864D6F1FF368D9002C9012 /* PBXContainerItemProxy */ = {
30 34 isa = PBXContainerItemProxy;
31   - containerPortal = 75F8189B1EEAA3EE0088B62F /* GameSDK.xcodeproj */;
  35 + containerPortal = 75864D6A1FF368D9002C9012 /* GameSDK.xcodeproj */;
32 36 proxyType = 2;
33 37 remoteGlobalIDString = 99626194192D9649004FF2E3;
34 38 remoteInfo = GameSDK;
... ... @@ -46,7 +50,11 @@
46 50 3CD53D9C1B81F37900E1B01A /* VKSdkResources.bundle */ = {isa = PBXFileReference; lastKnownFileType = "wrapper.plug-in"; path = VKSdkResources.bundle; sourceTree = "<group>"; };
47 51 752A5F411CDC826A00C36131 /* GameSDKResources.bundle */ = {isa = PBXFileReference; lastKnownFileType = "wrapper.plug-in"; name = GameSDKResources.bundle; path = ../../GameSDKResources.bundle; sourceTree = "<group>"; };
48 52 752A5F491CDC8B3200C36131 /* GameSDK.framework */ = {isa = PBXFileReference; lastKnownFileType = wrapper.framework; name = GameSDK.framework; path = ../GameSDK.framework; sourceTree = "<group>"; };
49   - 75F8189B1EEAA3EE0088B62F /* GameSDK.xcodeproj */ = {isa = PBXFileReference; lastKnownFileType = "wrapper.pb-project"; name = GameSDK.xcodeproj; path = ../../../iosgamesdk/GameSDK/GameSDK.xcodeproj; sourceTree = "<group>"; };
  53 + 75864D601FF35A22002C9012 /* libsqlite3.tbd */ = {isa = PBXFileReference; lastKnownFileType = "sourcecode.text-based-dylib-definition"; name = libsqlite3.tbd; path = usr/lib/libsqlite3.tbd; sourceTree = SDKROOT; };
  54 + 75864D641FF35A3A002C9012 /* CoreTelephony.framework */ = {isa = PBXFileReference; lastKnownFileType = wrapper.framework; name = CoreTelephony.framework; path = System/Library/Frameworks/CoreTelephony.framework; sourceTree = SDKROOT; };
  55 + 75864D661FF35A48002C9012 /* libz.tbd */ = {isa = PBXFileReference; lastKnownFileType = "sourcecode.text-based-dylib-definition"; name = libz.tbd; path = usr/lib/libz.tbd; sourceTree = SDKROOT; };
  56 + 75864D681FF35A57002C9012 /* libc++.tbd */ = {isa = PBXFileReference; lastKnownFileType = "sourcecode.text-based-dylib-definition"; name = "libc++.tbd"; path = "usr/lib/libc++.tbd"; sourceTree = SDKROOT; };
  57 + 75864D6A1FF368D9002C9012 /* GameSDK.xcodeproj */ = {isa = PBXFileReference; lastKnownFileType = "wrapper.pb-project"; name = GameSDK.xcodeproj; path = ../../../iosgamesdk/GameSDK/GameSDK.xcodeproj; sourceTree = "<group>"; };
50 58 9934F1AE19303DC6005EF4AB /* GameSDKDemo.app */ = {isa = PBXFileReference; explicitFileType = wrapper.application; includeInIndex = 0; path = GameSDKDemo.app; sourceTree = BUILT_PRODUCTS_DIR; };
51 59 9934F1B119303DC6005EF4AB /* Foundation.framework */ = {isa = PBXFileReference; lastKnownFileType = wrapper.framework; name = Foundation.framework; path = System/Library/Frameworks/Foundation.framework; sourceTree = SDKROOT; };
52 60 9934F1B319303DC6005EF4AB /* CoreGraphics.framework */ = {isa = PBXFileReference; lastKnownFileType = wrapper.framework; name = CoreGraphics.framework; path = System/Library/Frameworks/CoreGraphics.framework; sourceTree = SDKROOT; };
... ... @@ -68,6 +76,10 @@
68 76 isa = PBXFrameworksBuildPhase;
69 77 buildActionMask = 2147483647;
70 78 files = (
  79 + 75864D691FF35A58002C9012 /* libc++.tbd in Frameworks */,
  80 + 75864D671FF35A48002C9012 /* libz.tbd in Frameworks */,
  81 + 75864D651FF35A3A002C9012 /* CoreTelephony.framework in Frameworks */,
  82 + 75864D631FF35A22002C9012 /* libsqlite3.tbd in Frameworks */,
71 83 331262371C50B56800B1B435 /* VKBridge.framework in Frameworks */,
72 84 3309D9791C438A5E00534E33 /* libz.1.2.5.tbd in Frameworks */,
73 85 3309D8551C312F6500534E33 /* QuartzCore.framework in Frameworks */,
... ... @@ -96,15 +108,15 @@
96 108 27019DCE1A208B2300DA560D /* Dependencies */ = {
97 109 isa = PBXGroup;
98 110 children = (
99   - 75F8189B1EEAA3EE0088B62F /* GameSDK.xcodeproj */,
  111 + 75864D6A1FF368D9002C9012 /* GameSDK.xcodeproj */,
100 112 );
101 113 name = Dependencies;
102 114 sourceTree = "<group>";
103 115 };
104   - 75F8189C1EEAA3EE0088B62F /* Products */ = {
  116 + 75864D6B1FF368D9002C9012 /* Products */ = {
105 117 isa = PBXGroup;
106 118 children = (
107   - 75F818A11EEAA3EE0088B62F /* libGameSDK.a */,
  119 + 75864D701FF368D9002C9012 /* libGameSDK.a */,
108 120 );
109 121 name = Products;
110 122 sourceTree = "<group>";
... ... @@ -131,6 +143,10 @@
131 143 9934F1B019303DC6005EF4AB /* Frameworks */ = {
132 144 isa = PBXGroup;
133 145 children = (
  146 + 75864D681FF35A57002C9012 /* libc++.tbd */,
  147 + 75864D661FF35A48002C9012 /* libz.tbd */,
  148 + 75864D641FF35A3A002C9012 /* CoreTelephony.framework */,
  149 + 75864D601FF35A22002C9012 /* libsqlite3.tbd */,
134 150 752A5F491CDC8B3200C36131 /* GameSDK.framework */,
135 151 331262361C50B56800B1B435 /* VKBridge.framework */,
136 152 3309D97E1C4394C800534E33 /* VKSdk.framework */,
... ... @@ -217,8 +233,8 @@
217 233 projectDirPath = "";
218 234 projectReferences = (
219 235 {
220   - ProductGroup = 75F8189C1EEAA3EE0088B62F /* Products */;
221   - ProjectRef = 75F8189B1EEAA3EE0088B62F /* GameSDK.xcodeproj */;
  236 + ProductGroup = 75864D6B1FF368D9002C9012 /* Products */;
  237 + ProjectRef = 75864D6A1FF368D9002C9012 /* GameSDK.xcodeproj */;
222 238 },
223 239 );
224 240 projectRoot = "";
... ... @@ -229,11 +245,11 @@
229 245 /* End PBXProject section */
230 246  
231 247 /* Begin PBXReferenceProxy section */
232   - 75F818A11EEAA3EE0088B62F /* libGameSDK.a */ = {
  248 + 75864D701FF368D9002C9012 /* libGameSDK.a */ = {
233 249 isa = PBXReferenceProxy;
234 250 fileType = archive.ar;
235 251 path = libGameSDK.a;
236   - remoteRef = 75F818A01EEAA3EE0088B62F /* PBXContainerItemProxy */;
  252 + remoteRef = 75864D6F1FF368D9002C9012 /* PBXContainerItemProxy */;
237 253 sourceTree = BUILT_PRODUCTS_DIR;
238 254 };
239 255 /* End PBXReferenceProxy section */
... ... @@ -366,6 +382,7 @@
366 382 IPHONEOS_DEPLOYMENT_TARGET = 7.0;
367 383 LIBRARY_SEARCH_PATHS = "";
368 384 ONLY_ACTIVE_ARCH = YES;
  385 + OTHER_LDFLAGS = "-ObjC";
369 386 PRIVATE_HEADERS_FOLDER_PATH = "";
370 387 PRODUCT_BUNDLE_IDENTIFIER = test.kang.purchase;
371 388 PRODUCT_NAME = GameSDKDemo;
... ... @@ -403,6 +420,7 @@
403 420 IPHONEOS_DEPLOYMENT_TARGET = 7.0;
404 421 LIBRARY_SEARCH_PATHS = "";
405 422 ONLY_ACTIVE_ARCH = YES;
  423 + OTHER_LDFLAGS = "-ObjC";
406 424 PRIVATE_HEADERS_FOLDER_PATH = "";
407 425 PRODUCT_BUNDLE_IDENTIFIER = test.kang.purchase;
408 426 PRODUCT_NAME = GameSDKDemo;
ios/GameSDKDemo/GameSDKDemo.xcodeproj/project.xcworkspace/xcuserdata/yanglele.xcuserdatad/UserInterfaceState.xcuserstate
No preview for this file type
ios/GameSDKDemo/GameSDKDemo.xcodeproj/xcuserdata/yanglele.xcuserdatad/xcdebugger/Breakpoints_v2.xcbkptlist
... ... @@ -2,4 +2,198 @@
2 2 <Bucket
3 3 type = "1"
4 4 version = "2.0">
  5 + <Breakpoints>
  6 + <BreakpointProxy
  7 + BreakpointExtensionID = "Xcode.Breakpoint.FileBreakpoint">
  8 + <BreakpointContent
  9 + shouldBeEnabled = "Yes"
  10 + ignoreCount = "0"
  11 + continueAfterRunningActions = "No"
  12 + filePath = "../../../iosgamesdk/GameSDK/letsgame/service/httpService/LSGUserService.m"
  13 + timestampString = "536050010.070926"
  14 + startingColumnNumber = "9223372036854775807"
  15 + endingColumnNumber = "9223372036854775807"
  16 + startingLineNumber = "594"
  17 + endingLineNumber = "594"
  18 + landmarkName = "-appObtainWeCharAppIDWithAppId:appKey:result:"
  19 + landmarkType = "7">
  20 + </BreakpointContent>
  21 + </BreakpointProxy>
  22 + <BreakpointProxy
  23 + BreakpointExtensionID = "Xcode.Breakpoint.FileBreakpoint">
  24 + <BreakpointContent
  25 + shouldBeEnabled = "Yes"
  26 + ignoreCount = "0"
  27 + continueAfterRunningActions = "No"
  28 + filePath = "../../../iosgamesdk/GameSDK/letsgame/registAndLogin/LSGUserBaseViewController.m"
  29 + timestampString = "536046478.994249"
  30 + startingColumnNumber = "9223372036854775807"
  31 + endingColumnNumber = "9223372036854775807"
  32 + startingLineNumber = "295"
  33 + endingLineNumber = "295"
  34 + landmarkName = "-onClickWeChatLogin"
  35 + landmarkType = "7">
  36 + </BreakpointContent>
  37 + </BreakpointProxy>
  38 + <BreakpointProxy
  39 + BreakpointExtensionID = "Xcode.Breakpoint.FileBreakpoint">
  40 + <BreakpointContent
  41 + shouldBeEnabled = "Yes"
  42 + ignoreCount = "0"
  43 + continueAfterRunningActions = "No"
  44 + filePath = "../../../iosgamesdk/GameSDK/letsgame/LetsGameAPI.m"
  45 + timestampString = "536050715.666746"
  46 + startingColumnNumber = "9223372036854775807"
  47 + endingColumnNumber = "9223372036854775807"
  48 + startingLineNumber = "269"
  49 + endingLineNumber = "269"
  50 + landmarkName = "-registerAppWeChatWithAppId:appKey:Success:failure:"
  51 + landmarkType = "7">
  52 + <Locations>
  53 + <Location
  54 + shouldBeEnabled = "Yes"
  55 + ignoreCount = "0"
  56 + continueAfterRunningActions = "No"
  57 + symbolName = "-[LetsGameAPI registerAppWeChatWithAppId:appKey:Success:failure:]"
  58 + moduleName = "GameSDKDemo"
  59 + usesParentBreakpointCondition = "Yes"
  60 + urlString = "file:///Users/yanglele/workproject/project/GumpSDK/iosgamesdk/GameSDK/letsgame/LetsGameAPI.m"
  61 + timestampString = "536048775.543027"
  62 + startingColumnNumber = "9223372036854775807"
  63 + endingColumnNumber = "9223372036854775807"
  64 + startingLineNumber = "269"
  65 + endingLineNumber = "269"
  66 + offsetFromSymbolStart = "164">
  67 + </Location>
  68 + <Location
  69 + shouldBeEnabled = "Yes"
  70 + ignoreCount = "0"
  71 + continueAfterRunningActions = "No"
  72 + symbolName = "__65-[LetsGameAPI registerAppWeChatWithAppId:appKey:Success:failure:]_block_invoke"
  73 + moduleName = "GameSDKDemo"
  74 + usesParentBreakpointCondition = "Yes"
  75 + urlString = "file:///Users/yanglele/workproject/project/GumpSDK/iosgamesdk/GameSDK/letsgame/LetsGameAPI.m"
  76 + timestampString = "536048775.545047"
  77 + startingColumnNumber = "9223372036854775807"
  78 + endingColumnNumber = "9223372036854775807"
  79 + startingLineNumber = "269"
  80 + endingLineNumber = "269"
  81 + offsetFromSymbolStart = "16">
  82 + </Location>
  83 + </Locations>
  84 + </BreakpointContent>
  85 + </BreakpointProxy>
  86 + <BreakpointProxy
  87 + BreakpointExtensionID = "Xcode.Breakpoint.FileBreakpoint">
  88 + <BreakpointContent
  89 + shouldBeEnabled = "Yes"
  90 + ignoreCount = "0"
  91 + continueAfterRunningActions = "No"
  92 + filePath = "../../../iosgamesdk/GameSDK/letsgame/registAndLogin/LSGWeChatViewController.m"
  93 + timestampString = "536048532.37555"
  94 + startingColumnNumber = "9223372036854775807"
  95 + endingColumnNumber = "9223372036854775807"
  96 + startingLineNumber = "51"
  97 + endingLineNumber = "51"
  98 + landmarkName = "-registerAppWeChatAppIDWithAppId:appKey:success:failure:"
  99 + landmarkType = "7">
  100 + <Locations>
  101 + <Location
  102 + shouldBeEnabled = "Yes"
  103 + ignoreCount = "0"
  104 + continueAfterRunningActions = "No"
  105 + symbolName = "-[LSGWeChatViewController registerAppWeChatAppIDWithAppId:appKey:success:failure:]"
  106 + moduleName = "GameSDKDemo"
  107 + usesParentBreakpointCondition = "Yes"
  108 + urlString = "file:///Users/yanglele/workproject/project/GumpSDK/iosgamesdk/GameSDK/letsgame/registAndLogin/LSGWeChatViewController.m"
  109 + timestampString = "536048775.551058"
  110 + startingColumnNumber = "9223372036854775807"
  111 + endingColumnNumber = "9223372036854775807"
  112 + startingLineNumber = "51"
  113 + endingLineNumber = "51"
  114 + offsetFromSymbolStart = "224">
  115 + </Location>
  116 + <Location
  117 + shouldBeEnabled = "Yes"
  118 + ignoreCount = "0"
  119 + continueAfterRunningActions = "No"
  120 + symbolName = "__82-[LSGWeChatViewController registerAppWeChatAppIDWithAppId:appKey:success:failure:]_block_invoke"
  121 + moduleName = "GameSDKDemo"
  122 + usesParentBreakpointCondition = "Yes"
  123 + urlString = "file:///Users/yanglele/workproject/project/GumpSDK/iosgamesdk/GameSDK/letsgame/registAndLogin/LSGWeChatViewController.m"
  124 + timestampString = "536048775.553805"
  125 + startingColumnNumber = "9223372036854775807"
  126 + endingColumnNumber = "9223372036854775807"
  127 + startingLineNumber = "52"
  128 + endingLineNumber = "52"
  129 + offsetFromSymbolStart = "64">
  130 + </Location>
  131 + </Locations>
  132 + </BreakpointContent>
  133 + </BreakpointProxy>
  134 + <BreakpointProxy
  135 + BreakpointExtensionID = "Xcode.Breakpoint.FileBreakpoint">
  136 + <BreakpointContent
  137 + shouldBeEnabled = "Yes"
  138 + ignoreCount = "0"
  139 + continueAfterRunningActions = "No"
  140 + filePath = "../../../iosgamesdk/GameSDK/letsgame/registAndLogin/LSGWeChatViewController.m"
  141 + timestampString = "536048532.37562"
  142 + startingColumnNumber = "9223372036854775807"
  143 + endingColumnNumber = "9223372036854775807"
  144 + startingLineNumber = "34"
  145 + endingLineNumber = "34"
  146 + landmarkName = "+isWeChatInstall"
  147 + landmarkType = "7">
  148 + </BreakpointContent>
  149 + </BreakpointProxy>
  150 + <BreakpointProxy
  151 + BreakpointExtensionID = "Xcode.Breakpoint.FileBreakpoint">
  152 + <BreakpointContent
  153 + shouldBeEnabled = "Yes"
  154 + ignoreCount = "0"
  155 + continueAfterRunningActions = "No"
  156 + filePath = "letsgameDemo/LSGAppDelegate.m"
  157 + timestampString = "536050715.667074"
  158 + startingColumnNumber = "9223372036854775807"
  159 + endingColumnNumber = "9223372036854775807"
  160 + startingLineNumber = "38"
  161 + endingLineNumber = "38"
  162 + landmarkName = "-application:didFinishLaunchingWithOptions:"
  163 + landmarkType = "7">
  164 + <Locations>
  165 + <Location
  166 + shouldBeEnabled = "Yes"
  167 + ignoreCount = "0"
  168 + continueAfterRunningActions = "No"
  169 + symbolName = "-[LSGAppDelegate application:didFinishLaunchingWithOptions:]"
  170 + moduleName = "GameSDKDemo"
  171 + usesParentBreakpointCondition = "Yes"
  172 + urlString = "file:///Users/yanglele/workproject/project/GumpSDK/gamesdkNew/ios/GameSDKDemo/letsgameDemo/LSGAppDelegate.m"
  173 + timestampString = "536048775.5657"
  174 + startingColumnNumber = "9223372036854775807"
  175 + endingColumnNumber = "9223372036854775807"
  176 + startingLineNumber = "38"
  177 + endingLineNumber = "38"
  178 + offsetFromSymbolStart = "848">
  179 + </Location>
  180 + <Location
  181 + shouldBeEnabled = "Yes"
  182 + ignoreCount = "0"
  183 + continueAfterRunningActions = "No"
  184 + symbolName = "__60-[LSGAppDelegate application:didFinishLaunchingWithOptions:]_block_invoke"
  185 + moduleName = "GameSDKDemo"
  186 + usesParentBreakpointCondition = "Yes"
  187 + urlString = "file:///Users/yanglele/workproject/project/GumpSDK/gamesdkNew/ios/GameSDKDemo/letsgameDemo/LSGAppDelegate.m"
  188 + timestampString = "536048775.567968"
  189 + startingColumnNumber = "9223372036854775807"
  190 + endingColumnNumber = "9223372036854775807"
  191 + startingLineNumber = "39"
  192 + endingLineNumber = "39"
  193 + offsetFromSymbolStart = "20">
  194 + </Location>
  195 + </Locations>
  196 + </BreakpointContent>
  197 + </BreakpointProxy>
  198 + </Breakpoints>
5 199 </Bucket>
ios/GameSDKDemo/GameSDKDemo.xcodeproj/xcuserdata/yanglele.xcuserdatad/xcschemes/GameSDKDemo.xcscheme
... ... @@ -26,6 +26,7 @@
26 26 buildConfiguration = "Debug"
27 27 selectedDebuggerIdentifier = "Xcode.DebuggerFoundation.Debugger.LLDB"
28 28 selectedLauncherIdentifier = "Xcode.DebuggerFoundation.Launcher.LLDB"
  29 + language = ""
29 30 shouldUseLaunchSchemeArgsEnv = "YES">
30 31 <Testables>
31 32 </Testables>
... ... @@ -45,6 +46,7 @@
45 46 buildConfiguration = "Debug"
46 47 selectedDebuggerIdentifier = "Xcode.DebuggerFoundation.Debugger.LLDB"
47 48 selectedLauncherIdentifier = "Xcode.DebuggerFoundation.Launcher.LLDB"
  49 + language = ""
48 50 launchStyle = "0"
49 51 useCustomWorkingDirectory = "NO"
50 52 ignoresPersistentStateOnLaunch = "NO"
ios/GameSDKDemo/letsgameDemo/LSGAppDelegate.m
... ... @@ -23,6 +23,8 @@
23 23 self.window.backgroundColor = [UIColor whiteColor];
24 24 [self.window makeKeyAndVisible];
25 25  
  26 + [[LetsGameAPI instance] decideIsDebug:1];
  27 +
26 28 //显示是否侵权的接口
27 29 // [[LetsGameAPI instance] gameObtainSafeSetInfoWithAppId:@"10056" ChannelId:@"1000" handleCallBack:^(BOOL resultStatus) {
28 30 // if (resultStatus) {
... ... @@ -32,6 +34,13 @@
32 34 // }
33 35 // }];
34 36  
  37 + //微信登陆
  38 + [[LetsGameAPI instance] registerAppWeChatWithAppId:@"100" appKey:@"f899139df5e1059396431415e770c6dd" Success:^{
  39 + NSLog(@"注册成功");
  40 + } failure:^{
  41 + NSLog(@"注册失败");
  42 + }];
  43 +
35 44 [[UIApplication sharedApplication] setStatusBarHidden:YES];
36 45 [[LetsGameAPI instance] registeIapObserver];
37 46  
ios/GameSDKDemo/letsgameDemo/LSGMainViewController.m
... ... @@ -85,7 +85,8 @@
85 85 [LetsGameAPI instance].appId = @"10056";//10047
86 86 [LetsGameAPI instance].appKey = @"b59c21a078fde074a6750e91ed19fb21";//eccd9f7dc92858b741132fda313130cf
87 87 [LetsGameAPI hiddenLogo:YES];
88   -// [LetsGameAPI disableFB:NO];
  88 +// [LetsGameAPI disableFB:YES];
  89 +// [LetsGameAPI disableGoogle:YES];
89 90 NSLog(@"sdk version:%@",[[LetsGameAPI instance] version]);
90 91 //启用vk登录
91 92 VKBridge *vkBridge = [[VKBridge alloc] initWithVKAppId:@"5029792"];
ios/GameSDKDemo/letsgameDemo/letsgameDemo-Info.plist
... ... @@ -36,6 +36,14 @@
36 36 <string>vk5029792</string>
37 37 </array>
38 38 </dict>
  39 + <dict>
  40 + <key>CFBundleTypeRole</key>
  41 + <string>Editor</string>
  42 + <key>CFBundleURLSchemes</key>
  43 + <array>
  44 + <string>wxd0242de3794f1016</string>
  45 + </array>
  46 + </dict>
39 47 </array>
40 48 <key>CFBundleVersion</key>
41 49 <string>1.1.1</string>
... ... @@ -43,6 +51,11 @@
43 51 <string>1401636950118536</string>
44 52 <key>FacebookDisplayName</key>
45 53 <string>letsgameDemo</string>
  54 + <key>LSApplicationQueriesSchemes</key>
  55 + <array>
  56 + <string>weixin</string>
  57 + <string>wechat</string>
  58 + </array>
46 59 <key>LSRequiresIPhoneOS</key>
47 60 <true/>
48 61 <key>NSAppTransportSecurity</key>
ios/GameSDKResources.bundle/PayJs.txt
... ... @@ -8,12 +8,12 @@ if (window[bridge]) { return }
8 8  
9 9 // 创建隐藏的iframe
10 10 function _createQueueReadyIframe(doc) {
11   -messagingIframe = doc.createElement('iframe');
12   -messagingIframe.style.display = 'none';
13   -doc.documentElement.appendChild(messagingIframe);
14   -webInfoIframe = doc.createElement('iframe');
15   -webInfoIframe.style,display = 'none';
16   -doc.documentElement.appendChild(webInfoIframe);
  11 + messagingIframe = doc.createElement('iframe');
  12 + messagingIframe.style.display = 'none';
  13 + doc.documentElement.appendChild(messagingIframe);
  14 + webInfoIframe = doc.createElement('iframe');
  15 + webInfoIframe.style,display = 'none';
  16 + doc.documentElement.appendChild(webInfoIframe);
17 17 }
18 18  
19 19  
... ... @@ -51,6 +51,6 @@ messagingIframe.src=CUSTOM_PROTOCOL_SCHEME + &#39;:&#39; + arguments.callee.name + &#39;:&#39; +
51 51 _createQueueReadyIframe(document);
52 52 //通知js开始初始化
53 53 if(typeof(onInjectJsOver)=='function')
54   -onInjectJsOver();
  54 + onInjectJsOver();
55 55  
56 56 -})();
  57 +})();
57 58 \ No newline at end of file
ios/GameSDKResources.bundle/images/ic_wc@2x.png

4.82 KB

ios/GameSDKResources.bundle/template.html
... ... @@ -1,36 +0,0 @@
1   -<!doctype html>
2   -<html>
3   -<head>
4   -<script src="http://code.angularjs.org/angular-1.0.1.min.js"></script>
5   -
6   -</head>
7   -<body ng-app="myApp" ng-controller="mainCtrl">
8   -
9   -<button ng-click="refresh()">refresh</button>
10   -<div style="background: #07242E; color: #708284;height: auto;overflow: auto;min-height: 600px;max-height:700px" >
11   -
12   -<ul>
13   -<li ng-repeat="x in items" style='font-size:15px'>
14   - {{ x.logtime }} &nbsp; [{{x.level}}]-{{x.filename}}:{{x.line}}/{{x.function}} &nbsp;=> {{x.message}}
15   -</li>
16   -</ul>
17   -
18   -</div>
19   -
20   -<script>
21   -var app = angular.module('myApp', []);
22   -
23   -app.controller('mainCtrl', function($scope, $http) {
24   - $http.get(location+'logs').success(function(response) {
25   - $scope.items = response;
26   - });
27   - $scope.refresh = function(){
28   - $http.get(location+'logs').success(function(response){
29   - $scope.items = response;
30   - });
31   - };
32   -});
33   -
34   -</script>
35   -</body>
36   -</html>
37 0 \ No newline at end of file