Commit 508fb0528961ee93182747be534a0816f5db08e2

Authored by 赵康
1 parent 88e1ea2882
Exists in master

upgrade to version2.3.1

Showing 44 changed files with 396 additions and 30 deletions Side-by-side Diff

android/GameSDKRelease/libs/GameSDK2.3.0_proguard.jar
No preview for this file type
android/GameSDKRelease/libs/GameSDK2.3.1_proguard.jar
No preview for this file type
android/GameSDKRelease/res/drawable-hdpi/logo_boa.png

4.64 KB

android/GameSDKRelease/res/drawable-hdpi/logo_coda.png

16.3 KB

android/GameSDKRelease/res/drawable-hdpi/logo_fpt.png

8.35 KB

android/GameSDKRelease/res/drawable-hdpi/logo_globe.png

11.1 KB

android/GameSDKRelease/res/drawable-hdpi/logo_mgc.png

14.8 KB

android/GameSDKRelease/res/drawable-hdpi/logo_mol_global.png

3.07 KB

android/GameSDKRelease/res/drawable-hdpi/logo_onc.png

11.3 KB

android/GameSDKRelease/res/drawable-hdpi/logo_vms.png

13.3 KB

android/GameSDKRelease/res/drawable-hdpi/logo_vnp.png

6.44 KB

android/GameSDKRelease/res/drawable-hdpi/logo_vtt.png

6.39 KB

android/GameSDKRelease/res/drawable-hdpi/logo_yandex.png

5.32 KB

android/GameSDKRelease/res/drawable-mdpi/logo_boa.png

3.08 KB

android/GameSDKRelease/res/drawable-mdpi/logo_coda.png

9.45 KB

android/GameSDKRelease/res/drawable-mdpi/logo_fpt.png

5.09 KB

android/GameSDKRelease/res/drawable-mdpi/logo_globe.png

6.15 KB

android/GameSDKRelease/res/drawable-mdpi/logo_mgc.png

8.24 KB

android/GameSDKRelease/res/drawable-mdpi/logo_mol_global.png

2.36 KB

android/GameSDKRelease/res/drawable-mdpi/logo_onc.png

6.03 KB

android/GameSDKRelease/res/drawable-mdpi/logo_vms.png

7.44 KB

android/GameSDKRelease/res/drawable-mdpi/logo_vnp.png

10.7 KB

android/GameSDKRelease/res/drawable-mdpi/logo_vtt.png

4.09 KB

android/GameSDKRelease/res/drawable-mdpi/logo_yandex.png

3.46 KB

android/GameSDKRelease/res/drawable-xhdpi/logo_boa.png

6.49 KB

android/GameSDKRelease/res/drawable-xhdpi/logo_coda.png

24 KB

android/GameSDKRelease/res/drawable-xhdpi/logo_fpt.png

12.7 KB

android/GameSDKRelease/res/drawable-xhdpi/logo_globe.png

19.3 KB

android/GameSDKRelease/res/drawable-xhdpi/logo_mgc.png

23.8 KB

android/GameSDKRelease/res/drawable-xhdpi/logo_mol_global.png

3.25 KB

android/GameSDKRelease/res/drawable-xhdpi/logo_onc.png

21.4 KB

android/GameSDKRelease/res/drawable-xhdpi/logo_vms.png

23.6 KB

android/GameSDKRelease/res/drawable-xhdpi/logo_vnp.png

10.7 KB

android/GameSDKRelease/res/drawable-xhdpi/logo_vtt.png

9.52 KB

android/GameSDKRelease/res/drawable-xhdpi/logo_yandex.png

6.3 KB

android/GameSDKRelease/res/layout/fragment_login.xml
... ... @@ -20,7 +20,8 @@
20 20 android:layout_marginTop="10dp"
21 21 android:background="@drawable/et_bg"
22 22 android:hint="@string/user_name_hint"
23   - android:imeOptions="flagNoExtractUi" />
  23 + android:imeOptions="flagNoExtractUi"
  24 + android:textColor="@color/black_text" />
24 25  
25 26 <EditText
26 27 android:id="@+id/password"
... ... @@ -32,7 +33,8 @@
32 33 android:background="@drawable/et_bg"
33 34 android:hint="@string/password_hint"
34 35 android:imeOptions="flagNoExtractUi"
35   - android:inputType="textPassword" />
  36 + android:inputType="textPassword"
  37 + android:textColor="@color/black_text" />
36 38  
37 39 <LinearLayout
38 40 android:layout_width="match_parent"
android/GameSDKRelease/res/layout/fragment_payment_choice.xml
... ... @@ -55,7 +55,7 @@
55 55 android:src="@drawable/arrow_tag" />
56 56 </RelativeLayout>
57 57 <RelativeLayout
58   - android:id="@+id/item_mol_point"
  58 + android:id="@+id/item_mol_global"
59 59 android:layout_width="match_parent"
60 60 android:layout_height="wrap_content"
61 61 android:background="@drawable/payment_bg"
... ... @@ -66,7 +66,7 @@
66 66 android:layout_height="wrap_content"
67 67 android:layout_centerVertical="true"
68 68 android:layout_marginLeft="10dp"
69   - android:src="@drawable/logo_mol" />
  69 + android:src="@drawable/logo_mol_global" />
70 70  
71 71 <ImageView
72 72 android:layout_width="wrap_content"
... ... @@ -305,6 +305,236 @@
305 305 android:layout_marginRight="45dp"
306 306 android:src="@drawable/arrow_tag" />
307 307 </RelativeLayout>
  308 +
  309 + <RelativeLayout
  310 + android:id="@+id/item_yandex"
  311 + android:layout_width="match_parent"
  312 + android:layout_height="wrap_content"
  313 + android:background="@drawable/payment_bg"
  314 + android:visibility="gone" >
  315 +
  316 + <ImageView
  317 + android:layout_width="wrap_content"
  318 + android:layout_height="wrap_content"
  319 + android:layout_centerVertical="true"
  320 + android:layout_marginLeft="10dp"
  321 + android:src="@drawable/logo_yandex" />
  322 +
  323 + <ImageView
  324 + android:layout_width="wrap_content"
  325 + android:layout_height="wrap_content"
  326 + android:layout_alignParentRight="true"
  327 + android:layout_centerVertical="true"
  328 + android:layout_marginRight="45dp"
  329 + android:src="@drawable/arrow_tag" />
  330 + </RelativeLayout>
  331 +
  332 + <RelativeLayout
  333 + android:id="@+id/item_vnp"
  334 + android:layout_width="match_parent"
  335 + android:layout_height="wrap_content"
  336 + android:background="@drawable/payment_bg"
  337 + android:visibility="gone" >
  338 +
  339 + <ImageView
  340 + android:layout_width="wrap_content"
  341 + android:layout_height="wrap_content"
  342 + android:layout_centerVertical="true"
  343 + android:layout_marginLeft="10dp"
  344 + android:src="@drawable/logo_vnp" />
  345 +
  346 + <ImageView
  347 + android:layout_width="wrap_content"
  348 + android:layout_height="wrap_content"
  349 + android:layout_alignParentRight="true"
  350 + android:layout_centerVertical="true"
  351 + android:layout_marginRight="45dp"
  352 + android:src="@drawable/arrow_tag" />
  353 + </RelativeLayout>
  354 +
  355 + <RelativeLayout
  356 + android:id="@+id/item_vms"
  357 + android:layout_width="match_parent"
  358 + android:layout_height="wrap_content"
  359 + android:background="@drawable/payment_bg"
  360 + android:visibility="gone" >
  361 +
  362 + <ImageView
  363 + android:layout_width="wrap_content"
  364 + android:layout_height="wrap_content"
  365 + android:layout_centerVertical="true"
  366 + android:layout_marginLeft="10dp"
  367 + android:src="@drawable/logo_vms" />
  368 +
  369 + <ImageView
  370 + android:layout_width="wrap_content"
  371 + android:layout_height="wrap_content"
  372 + android:layout_alignParentRight="true"
  373 + android:layout_centerVertical="true"
  374 + android:layout_marginRight="45dp"
  375 + android:src="@drawable/arrow_tag" />
  376 + </RelativeLayout>
  377 +
  378 + <RelativeLayout
  379 + android:id="@+id/item_fpt"
  380 + android:layout_width="match_parent"
  381 + android:layout_height="wrap_content"
  382 + android:background="@drawable/payment_bg"
  383 + android:visibility="gone" >
  384 +
  385 + <ImageView
  386 + android:layout_width="wrap_content"
  387 + android:layout_height="wrap_content"
  388 + android:layout_centerVertical="true"
  389 + android:layout_marginLeft="10dp"
  390 + android:src="@drawable/logo_fpt" />
  391 +
  392 + <ImageView
  393 + android:layout_width="wrap_content"
  394 + android:layout_height="wrap_content"
  395 + android:layout_alignParentRight="true"
  396 + android:layout_centerVertical="true"
  397 + android:layout_marginRight="45dp"
  398 + android:src="@drawable/arrow_tag" />
  399 + </RelativeLayout>
  400 +
  401 + <RelativeLayout
  402 + android:id="@+id/item_vtt"
  403 + android:layout_width="match_parent"
  404 + android:layout_height="wrap_content"
  405 + android:background="@drawable/payment_bg"
  406 + android:visibility="gone" >
  407 +
  408 + <ImageView
  409 + android:layout_width="wrap_content"
  410 + android:layout_height="wrap_content"
  411 + android:layout_centerVertical="true"
  412 + android:layout_marginLeft="10dp"
  413 + android:src="@drawable/logo_vtt" />
  414 +
  415 + <ImageView
  416 + android:layout_width="wrap_content"
  417 + android:layout_height="wrap_content"
  418 + android:layout_alignParentRight="true"
  419 + android:layout_centerVertical="true"
  420 + android:layout_marginRight="45dp"
  421 + android:src="@drawable/arrow_tag" />
  422 + </RelativeLayout>
  423 +
  424 + <RelativeLayout
  425 + android:id="@+id/item_mgc"
  426 + android:layout_width="match_parent"
  427 + android:layout_height="wrap_content"
  428 + android:background="@drawable/payment_bg"
  429 + android:visibility="gone" >
  430 +
  431 + <ImageView
  432 + android:layout_width="wrap_content"
  433 + android:layout_height="wrap_content"
  434 + android:layout_centerVertical="true"
  435 + android:layout_marginLeft="10dp"
  436 + android:src="@drawable/logo_mgc" />
  437 +
  438 + <ImageView
  439 + android:layout_width="wrap_content"
  440 + android:layout_height="wrap_content"
  441 + android:layout_alignParentRight="true"
  442 + android:layout_centerVertical="true"
  443 + android:layout_marginRight="45dp"
  444 + android:src="@drawable/arrow_tag" />
  445 + </RelativeLayout>
  446 +
  447 + <RelativeLayout
  448 + android:id="@+id/item_onc"
  449 + android:layout_width="match_parent"
  450 + android:layout_height="wrap_content"
  451 + android:background="@drawable/payment_bg"
  452 + android:visibility="gone" >
  453 +
  454 + <ImageView
  455 + android:layout_width="wrap_content"
  456 + android:layout_height="wrap_content"
  457 + android:layout_centerVertical="true"
  458 + android:layout_marginLeft="10dp"
  459 + android:src="@drawable/logo_onc" />
  460 +
  461 + <ImageView
  462 + android:layout_width="wrap_content"
  463 + android:layout_height="wrap_content"
  464 + android:layout_alignParentRight="true"
  465 + android:layout_centerVertical="true"
  466 + android:layout_marginRight="45dp"
  467 + android:src="@drawable/arrow_tag" />
  468 + </RelativeLayout>
  469 +
  470 + <RelativeLayout
  471 + android:id="@+id/item_boa"
  472 + android:layout_width="match_parent"
  473 + android:layout_height="wrap_content"
  474 + android:background="@drawable/payment_bg"
  475 + android:visibility="gone" >
  476 +
  477 + <ImageView
  478 + android:layout_width="wrap_content"
  479 + android:layout_height="wrap_content"
  480 + android:layout_centerVertical="true"
  481 + android:layout_marginLeft="10dp"
  482 + android:src="@drawable/logo_boa" />
  483 +
  484 + <ImageView
  485 + android:layout_width="wrap_content"
  486 + android:layout_height="wrap_content"
  487 + android:layout_alignParentRight="true"
  488 + android:layout_centerVertical="true"
  489 + android:layout_marginRight="45dp"
  490 + android:src="@drawable/arrow_tag" />
  491 + </RelativeLayout>
  492 +
  493 + <RelativeLayout
  494 + android:id="@+id/item_coda"
  495 + android:layout_width="match_parent"
  496 + android:layout_height="wrap_content"
  497 + android:background="@drawable/payment_bg"
  498 + android:visibility="gone" >
  499 +
  500 + <ImageView
  501 + android:layout_width="wrap_content"
  502 + android:layout_height="wrap_content"
  503 + android:layout_centerVertical="true"
  504 + android:layout_marginLeft="10dp"
  505 + android:src="@drawable/logo_coda" />
  506 +
  507 + <ImageView
  508 + android:layout_width="wrap_content"
  509 + android:layout_height="wrap_content"
  510 + android:layout_alignParentRight="true"
  511 + android:layout_centerVertical="true"
  512 + android:layout_marginRight="45dp"
  513 + android:src="@drawable/arrow_tag" />
  514 + </RelativeLayout>
  515 +
  516 + <RelativeLayout
  517 + android:id="@+id/item_globe"
  518 + android:layout_width="match_parent"
  519 + android:layout_height="wrap_content"
  520 + android:background="@drawable/payment_bg"
  521 + android:visibility="gone" >
  522 +
  523 + <ImageView
  524 + android:layout_width="wrap_content"
  525 + android:layout_height="wrap_content"
  526 + android:layout_centerVertical="true"
  527 + android:layout_marginLeft="10dp"
  528 + android:src="@drawable/logo_globe" />
  529 +
  530 + <ImageView
  531 + android:layout_width="wrap_content"
  532 + android:layout_height="wrap_content"
  533 + android:layout_alignParentRight="true"
  534 + android:layout_centerVertical="true"
  535 + android:layout_marginRight="45dp"
  536 + android:src="@drawable/arrow_tag" />
  537 + </RelativeLayout>
308 538 </LinearLayout>
309 539  
310 540 </ScrollView>
311 541 \ No newline at end of file
android/GameSDKRelease/res/layout/fragment_signup.xml
... ... @@ -18,7 +18,8 @@
18 18 android:layout_margin="10dp"
19 19 android:background="@drawable/et_bg"
20 20 android:hint="@string/user_name_hint"
21   - android:imeOptions="flagNoExtractUi" />
  21 + android:imeOptions="flagNoExtractUi"
  22 + android:textColor="@color/black_text" />
22 23  
23 24 <EditText
24 25 android:id="@+id/pwd"
... ... @@ -28,7 +29,8 @@
28 29 android:background="@drawable/et_bg"
29 30 android:hint="@string/password_hint"
30 31 android:imeOptions="flagNoExtractUi"
31   - android:inputType="textPassword" />
  32 + android:inputType="textPassword"
  33 + android:textColor="@color/black_text" />
32 34  
33 35 <Button
34 36 android:id="@+id/signup"
android/GameSDKRelease/res/layout/fragment_yandex.xml
... ... @@ -0,0 +1,119 @@
  1 +<?xml version="1.0" encoding="utf-8"?>
  2 +<ScrollView xmlns:android="http://schemas.android.com/apk/res/android"
  3 + android:layout_width="match_parent"
  4 + android:layout_height="match_parent"
  5 + android:background="@color/payment_common_bg" >
  6 +
  7 + <LinearLayout
  8 + android:layout_width="match_parent"
  9 + android:layout_height="match_parent"
  10 + android:orientation="vertical" >
  11 +
  12 + <TextView
  13 + android:id="@+id/choice_title"
  14 + android:layout_width="match_parent"
  15 + android:layout_height="wrap_content"
  16 + android:background="@drawable/header_tip_bg"
  17 + android:gravity="center_vertical"
  18 + android:paddingLeft="10dp"
  19 + android:text="@string/amount_choice_tip"
  20 + android:textColor="@color/black_text" />
  21 +
  22 + <RelativeLayout
  23 + android:id="@+id/amount_choice"
  24 + android:layout_width="match_parent"
  25 + android:layout_height="wrap_content"
  26 + android:layout_marginLeft="13dp"
  27 + android:layout_marginRight="13dp"
  28 + android:layout_marginTop="16dp"
  29 + android:background="@drawable/choice_box_bg" >
  30 +
  31 + <TextView
  32 + android:id="@+id/tv_amount"
  33 + android:layout_width="wrap_content"
  34 + android:layout_height="wrap_content"
  35 + android:layout_centerVertical="true"
  36 + android:layout_marginLeft="15dp"
  37 + android:text="50d"
  38 + android:textColor="@color/black_text"
  39 + android:textSize="18sp"
  40 + android:textStyle="italic" />
  41 +
  42 + <ImageView
  43 + android:id="@+id/arrow_tag"
  44 + android:layout_width="35dp"
  45 + android:layout_height="35dp"
  46 + android:layout_alignParentRight="true"
  47 + android:layout_centerVertical="true"
  48 + android:scaleType="center"
  49 + android:src="@drawable/ic_arrow_down" />
  50 +
  51 + <View
  52 + android:layout_width="1dp"
  53 + android:layout_height="match_parent"
  54 + android:layout_centerVertical="true"
  55 + android:layout_toLeftOf="@id/arrow_tag"
  56 + android:background="@drawable/split_vertical" />
  57 + </RelativeLayout>
  58 +
  59 + <Button
  60 + android:id="@+id/money"
  61 + android:layout_width="match_parent"
  62 + android:layout_height="wrap_content"
  63 + android:layout_marginLeft="13dp"
  64 + android:layout_marginRight="13dp"
  65 + android:layout_marginTop="23dp"
  66 + android:layout_weight="3"
  67 + android:background="@drawable/btn_orange_bg"
  68 + android:text="@string/yandex_money"
  69 + android:textColor="@android:color/white" />
  70 +
  71 + <Button
  72 + android:id="@+id/bank"
  73 + android:layout_width="match_parent"
  74 + android:layout_height="wrap_content"
  75 + android:layout_marginLeft="13dp"
  76 + android:layout_marginRight="13dp"
  77 + android:layout_marginTop="10dp"
  78 + android:layout_weight="3"
  79 + android:background="@drawable/btn_orange_bg"
  80 + android:text="@string/yandex_bank"
  81 + android:textColor="@android:color/white" />
  82 +
  83 + <Button
  84 + android:id="@+id/cash"
  85 + android:layout_width="match_parent"
  86 + android:layout_height="wrap_content"
  87 + android:layout_marginBottom="20dp"
  88 + android:layout_marginLeft="13dp"
  89 + android:layout_marginRight="13dp"
  90 + android:layout_marginTop="10dp"
  91 + android:layout_weight="3"
  92 + android:background="@drawable/btn_orange_bg"
  93 + android:text="@string/yandex_cash"
  94 + android:textColor="@android:color/white" />
  95 +
  96 + <TextView
  97 + android:id="@+id/summary_title"
  98 + android:layout_width="match_parent"
  99 + android:layout_height="wrap_content"
  100 + android:layout_marginLeft="13dp"
  101 + android:layout_marginRight="13dp"
  102 + android:background="@color/summary_bg"
  103 + android:paddingLeft="10dp"
  104 + android:textColor="@color/black_text"
  105 + android:textSize="12sp" />
  106 +
  107 + <TextView
  108 + android:id="@+id/intro"
  109 + android:layout_width="match_parent"
  110 + android:layout_height="wrap_content"
  111 + android:layout_marginBottom="10dp"
  112 + android:layout_marginLeft="13dp"
  113 + android:layout_marginRight="13dp"
  114 + android:background="@color/summary_bg"
  115 + android:padding="8dp"
  116 + android:textColor="@color/black_text" />
  117 + </LinearLayout>
  118 +
  119 +</ScrollView>
0 120 \ No newline at end of file
android/GameSDKRelease/res/values/strings.xml
... ... @@ -66,8 +66,17 @@
66 66 <string name="title_rixty">Rixty</string>
67 67 <string name="title_ngan">NganLoung</string>
68 68 <string name="title_easy2pay">Easy2Pay</string>
  69 + <string name="title_boa">BOACompra</string>
69 70 <string name="title_indomog_voucher">Indomog</string>
70 71 <string name="title_indomog_account">Indomog Account Balance</string>
  72 + <string name="title_yandex">Yandex</string>
  73 + <string name="title_vnpt_vnp">VinaPhone</string>
  74 + <string name="title_vnpt_vms">MobiFone</string>
  75 + <string name="title_vnpt_onc">Oncash</string>
  76 + <string name="title_vnpt_fpt">FPT</string>
  77 + <string name="title_vnpt_vtt">Viettel</string>
  78 + <string name="title_vnpt_mgc">MegaCard</string>
  79 + <string name="title_coda">Coda Payment</string>
71 80 <string name="title_payment_choice">Select payment methods</string>
72 81 <!-- summary title -->
73 82 <string name="summary_title">Price list:</string>
... ... @@ -86,5 +95,9 @@
86 95 <string name="paypal_choice_tip">Please select the amount</string>
87 96 <!-- gp -->
88 97 <string name="gp_choice_tip">Please select the amount</string>
  98 + <!-- yandex -->
  99 + <string name="yandex_money">Yandex Money</string>
  100 + <string name="yandex_bank">Yandex Bank</string>
  101 + <string name="yandex_cash">Yandex Cash</string>
89 102  
90 103 </resources>
91 104 \ No newline at end of file
android/GameSDKRelease/res/values/themes.xml
... ... @@ -8,7 +8,7 @@
8 8 <item name="android:windowNoTitle">true</item>
9 9 <item name="android:windowBackground">@color/transparent</item>
10 10 <item name="android:backgroundDimEnabled">true</item>
11   - <item name="android:windowFullscreen">true</item>
  11 + <item name="android:windowFullscreen">true</item>
12 12 </style>
13 13  
14 14 <style name="ex_win" parent="@style/container_dialog">
android/GameSDKSample/AndroidManifest.xml
... ... @@ -21,6 +21,11 @@
21 21 <uses-permission android:name="android.permission.CAMERA" />
22 22 <uses-permission android:name="android.permission.VIBRATE" />
23 23 <uses-permission android:name="android.permission.SEND_SMS"/>
  24 + <!-- coda -->
  25 + <uses-permission android:name="android.permission.RECEIVE_SMS" />
  26 + <uses-permission android:name="android.permission.READ_SMS" />
  27 + <uses-permission android:name="android.permission.WRITE_SMS" />
  28 + <uses-permission android:name="android.permission.GET_TASKS" />
24 29  
25 30 <uses-feature
26 31 android:name="android.hardware.camera"
... ... @@ -83,6 +88,20 @@
83 88 android:name="io.card.payment.CardIOActivity"
84 89 android:configChanges="keyboardHidden|orientation" />
85 90 <activity android:name="io.card.payment.DataEntryActivity" />
  91 + <activity
  92 + android:name="com.android.easy2pay.Easy2PayScreen"
  93 + android:theme="@android:style/Theme.Translucent.NoTitleBar" />
  94 + <activity
  95 + android:name="com.codapayments.sdk.pay.CodaWeb"
  96 + android:alwaysRetainTaskState="true"
  97 + android:configChanges="orientation|screenSize"
  98 + android:screenOrientation="unspecified" >
  99 + </activity>
  100 +
  101 + <receiver
  102 + android:name="com.codapayments.sdk.message.PendingTxnReceiver"
  103 + android:enabled="true" >
  104 + </receiver>
86 105 </application>
87 106  
88 107 </manifest>
89 108 \ No newline at end of file
android/GameSDKSample/res/layout/activity_main.xml
... ... @@ -17,13 +17,6 @@
17 17 android:visibility="gone" />
18 18  
19 19 <Button
20   - android:id="@+id/bind"
21   - android:layout_width="wrap_content"
22   - android:layout_height="wrap_content"
23   - android:text="bound"
24   - android:visibility="gone" />
25   -
26   - <Button
27 20 android:id="@+id/pay"
28 21 android:layout_width="wrap_content"
29 22 android:layout_height="wrap_content"
android/GameSDKSample/src/com/gumptech/loginsdk/sample/MainActivity.java
... ... @@ -9,7 +9,6 @@ import android.widget.Button;
9 9 import android.widget.TextView;
10 10 import android.widget.Toast;
11 11  
12   -import com.gumptech.sdk.GumpPreference;
13 12 import com.gumptech.sdk.GumpSDK;
14 13  
15 14 public class MainActivity extends Activity implements GumpSDK.Callback {
... ... @@ -17,7 +16,8 @@ public class MainActivity extends Activity implements GumpSDK.Callback {
17 16 private TextView userInfo;
18 17  
19 18 private Button btnLogout;
20   - private Button btnBind;
  19 +
  20 + private String appId = "10009";
21 21  
22 22 @Override
23 23 protected void onCreate(Bundle savedInstanceState) {
... ... @@ -25,7 +25,6 @@ public class MainActivity extends Activity implements GumpSDK.Callback {
25 25 setContentView(R.layout.activity_main);
26 26 userInfo = (TextView) findViewById(R.id.user_info);
27 27 btnLogout = (Button) findViewById(R.id.logout);
28   - btnBind = (Button) findViewById(R.id.bind);
29 28 btnLogout.setOnClickListener(new View.OnClickListener() {
30 29  
31 30 @Override
... ... @@ -33,13 +32,6 @@ public class MainActivity extends Activity implements GumpSDK.Callback {
33 32 GumpSDK.logout(MainActivity.this, MainActivity.this);
34 33 }
35 34 });
36   - btnBind.setOnClickListener(new View.OnClickListener() {
37   -
38   - @Override
39   - public void onClick(View v) {
40   - GumpSDK.boundMail(MainActivity.this);
41   - }
42   - });
43 35 findViewById(R.id.pay).setOnClickListener(new View.OnClickListener() {
44 36  
45 37 @Override
... ... @@ -54,7 +46,7 @@ public class MainActivity extends Activity implements GumpSDK.Callback {
54 46 GumpSDK.pay(MainActivity.this, payInfo);
55 47 }
56 48 });
57   - GumpSDK.init("10014", "7b9d31aa17b849b238ab79cef0733041", "301596413332339", "1000");
  49 + GumpSDK.init(getApplicationContext(), appId, "483d8df877b31405c1e8fe4247f02d86", "301596413332339", "1000");
58 50 GumpSDK.start(this);
59 51 }
60 52  
... ... @@ -68,8 +60,6 @@ public class MainActivity extends Activity implements GumpSDK.Callback {
68 60 String sessionkey = data.getStringExtra("sessionKey");
69 61 userInfo.setText("userid:" + uid + ",accountType:" + accountType + ",sessionKey:" + sessionkey);
70 62 btnLogout.setVisibility(View.VISIBLE);
71   - if (accountType == GumpPreference.ACCOUNT_TYPE_QUICK_REG)
72   - btnBind.setVisibility(View.VISIBLE);
73 63 } else if (resultCode == RESULT_CANCELED) {
74 64 Toast.makeText(this, "operate be canceled", Toast.LENGTH_SHORT).show();
75 65 }
... ... @@ -77,7 +67,7 @@ public class MainActivity extends Activity implements GumpSDK.Callback {
77 67 if (resultCode == RESULT_OK) {
78 68 int code = data.getIntExtra("code", -1);
79 69 String msg = data.getStringExtra("msg");
80   - int orderId = data.getIntExtra("orderId", -1);
  70 + String orderId = data.getStringExtra("orderId");
81 71 String extraInfo = data.getStringExtra("extraInfo");
82 72 Toast.makeText(this, "pay result: " + code + "," + msg + ",orderId:" + orderId + ",extraInfo:" + extraInfo, Toast.LENGTH_SHORT).show();
83 73 } else if (resultCode == RESULT_CANCELED) {
... ... @@ -90,8 +80,6 @@ public class MainActivity extends Activity implements GumpSDK.Callback {
90 80 @Override
91 81 public void onLogout() {
92 82 btnLogout.setVisibility(View.GONE);
93   - if (btnBind.getVisibility() == View.VISIBLE)
94   - btnBind.setVisibility(View.GONE);
95 83 userInfo.append(" is logout");
96 84 }
97 85