ソースを参照

new spring festival

hanjing 6 年 前
コミット
aa0509313d

+ 13 - 0
app/build.gradle

@@ -110,6 +110,19 @@ android {
             signingConfig signingConfigs.config
 
         }
+        sheepTheme {
+            applicationId "com.sheep.jiuyan.samllsheep"
+            manifestPlaceholders = [DUANDUAN_GRAPH    : "sheep",
+                                    DUANDUAN_DATASHARE: "sheep",
+                                    jpush_appkey      : "28b74d520261c6f78e3e0921",
+                                    umeng_app_key     : "5ab0a1da8f4a9d742900035f"
+            ]
+            buildConfigField "String", "DUANDUAN_DATASHARE", '"sheep"'
+            buildConfigField "String", "DUANDUAN_GRAPH", '"sheep"'
+            resValue "string", "app_name", "小绵羊"
+            buildConfigField "boolean", "XXTEA_ENCRYPT", 'true'
+            signingConfig signingConfigs.config
+        }
     }
     sourceSets {
         main() {

BIN
app/src/main/res/mipmap-xxhdpi/home_blue_bg.png


BIN
app/src/main/res/mipmap-xxhdpi/home_blue_bg.webp


+ 58 - 0
app/src/sheepTheme/java/com/sheep/jiuyan/samllsheep/wxapi/WXEntryActivity.java

@@ -0,0 +1,58 @@
+package com.sheep.jiuyan.samllsheep.wxapi;
+
+import android.content.Intent;
+import android.os.Bundle;
+import android.util.Log;
+
+import com.sheep.gamegroup.event.WXLoginAuthEvent;
+import com.sheep.jiuyan.samllsheep.Config;
+import com.tencent.mm.opensdk.modelbase.BaseReq;
+import com.tencent.mm.opensdk.modelbase.BaseResp;
+import com.tencent.mm.opensdk.modelmsg.SendAuth;
+import com.tencent.mm.opensdk.openapi.IWXAPI;
+import com.tencent.mm.opensdk.openapi.WXAPIFactory;
+import com.umeng.socialize.weixin.view.WXCallbackActivity;
+
+import org.greenrobot.eventbus.EventBus;
+
+public class WXEntryActivity extends WXCallbackActivity {//implements IWXAPIEventHandler
+
+    @Override
+    public void onCreate(Bundle bundle) {
+        super.onCreate(bundle);
+        IWXAPI wxapi = WXAPIFactory.createWXAPI(this, Config.WX_AUTH_APP_ID, true);
+        wxapi.registerApp(Config.WX_AUTH_APP_ID);
+        wxapi.handleIntent(getIntent(), this);
+        finish();
+    }
+
+    @Override
+    public void onNewIntent(Intent newIntent) {
+        IWXAPI wxapi = WXAPIFactory.createWXAPI(this, Config.WX_AUTH_APP_ID, true);
+        wxapi.registerApp(Config.WX_AUTH_APP_ID);
+        wxapi.handleIntent(getIntent(), this);
+        finish();
+    }
+
+    @Override
+    public void onReq(BaseReq baseReq) {
+        if(!(baseReq instanceof SendAuth.Req)){
+            super.onReq(baseReq);
+        }
+    }
+
+    @Override
+    public void onResp(BaseResp resp) {
+        if (resp instanceof SendAuth.Resp) {
+            if (resp.errCode == BaseResp.ErrCode.ERR_OK) {
+                String code = ((SendAuth.Resp) resp).code;
+                EventBus.getDefault().post(new WXLoginAuthEvent(code));
+            } else{
+                EventBus.getDefault().post(new WXLoginAuthEvent(null));
+            }
+        } else {
+            super.onResp(resp);
+        }
+    }
+
+}

+ 7 - 0
app/src/sheepTheme/java/com/sheep/jiuyan/samllsheep/wxapi/WXPayEntryActivity.java

@@ -0,0 +1,7 @@
+package com.sheep.jiuyan.samllsheep.wxapi;
+
+
+import com.sheep.gamegroup.module.pay.activity.SheepWXPayEntryActivity;
+
+public class WXPayEntryActivity extends SheepWXPayEntryActivity {
+}

BIN
app/src/sheepTheme/res/drawable-xxhdpi/homepage_zhuanqian.png


BIN
app/src/sheepTheme/res/drawable-xxhdpi/homepage_zhuanqian_click.png


BIN
app/src/sheepTheme/res/drawable-xxhdpi/tab_big_yq.png


BIN
app/src/sheepTheme/res/drawable-xxhdpi/tab_game.png


BIN
app/src/sheepTheme/res/drawable-xxhdpi/tab_game_blue.png


BIN
app/src/sheepTheme/res/mipmap-xxhdpi/bg_person.png


BIN
app/src/sheepTheme/res/mipmap-xxhdpi/home_blue_bg.png