直播间开通贵族结束

This commit is contained in:
18401019693
2022-09-19 17:07:59 +08:00
parent f531fd4d0e
commit 1935ac14f0
6 changed files with 120 additions and 19 deletions

View File

@@ -7,7 +7,6 @@ import android.content.Intent;
import android.net.Uri;
import android.os.Build;
import android.provider.MediaStore;
import androidx.annotation.RequiresApi;
import android.text.TextUtils;
import android.util.Log;
import android.view.View;
@@ -21,9 +20,12 @@ import android.webkit.WebViewClient;
import android.widget.LinearLayout;
import android.widget.ProgressBar;
import androidx.annotation.RequiresApi;
import com.alibaba.android.arouter.facade.annotation.Route;
import com.alibaba.fastjson.JSON;
import com.alibaba.fastjson.JSONObject;
import com.opensource.svgaplayer.SVGACallback;
import com.opensource.svgaplayer.SVGADrawable;
import com.opensource.svgaplayer.SVGAImageView;
import com.opensource.svgaplayer.SVGAParser;
@@ -184,6 +186,7 @@ public class RewardActivity extends AbsActivity {
new SVGAParser(mContext).parse(new URL(svg), new SVGAParser.ParseCompletion() {
@Override
public void onComplete(SVGAVideoEntity videoItem) {
svga.setVisibility(View.VISIBLE);
SVGADrawable drawable = new SVGADrawable(videoItem);
svga.setImageDrawable(drawable);
svga.setLoops(1);
@@ -194,6 +197,28 @@ public class RewardActivity extends AbsActivity {
public void onError() {
}
});
svga.setCallback(new SVGACallback() {
@Override
public void onPause() {
}
@Override
public void onFinished() {
svga.clear();
svga.setVisibility(View.GONE);
}
@Override
public void onRepeat() {
}
@Override
public void onStep(int i, double v) {
}
});
} catch (MalformedURLException e) {
e.printStackTrace();
}
@@ -215,7 +240,7 @@ public class RewardActivity extends AbsActivity {
@JavascriptInterface
public void gotoHomePage(String indexStr) {
Log.e("tgasss","indexStr3"+indexStr);
Log.e("tgasss", "indexStr3" + indexStr);
if (!"".equals(indexStr) && indexStr != null) {
int index = -1;

View File

@@ -7,7 +7,6 @@ import android.content.Intent;
import android.net.Uri;
import android.os.Build;
import android.provider.MediaStore;
import androidx.annotation.RequiresApi;
import android.text.TextUtils;
import android.util.Log;
import android.view.View;
@@ -21,8 +20,11 @@ import android.webkit.WebViewClient;
import android.widget.LinearLayout;
import android.widget.ProgressBar;
import androidx.annotation.RequiresApi;
import com.alibaba.android.arouter.facade.annotation.Route;
import com.alibaba.android.arouter.launcher.ARouter;
import com.opensource.svgaplayer.SVGACallback;
import com.opensource.svgaplayer.SVGADrawable;
import com.opensource.svgaplayer.SVGAImageView;
import com.opensource.svgaplayer.SVGAParser;
@@ -189,16 +191,40 @@ public class ZhuangBanActivity extends AbsActivity {
new SVGAParser(mContext).parse(new URL(svg), new SVGAParser.ParseCompletion() {
@Override
public void onComplete(SVGAVideoEntity videoItem) {
svga.setVisibility(View.VISIBLE);
SVGADrawable drawable = new SVGADrawable(videoItem);
svga.setImageDrawable(drawable);
svga.setLoops(1);
svga.startAnimation();
}
@Override
public void onError() {
}
});
svga.setCallback(new SVGACallback() {
@Override
public void onPause() {
}
@Override
public void onFinished() {
svga.clear();
svga.setVisibility(View.GONE);
}
@Override
public void onRepeat() {
}
@Override
public void onStep(int i, double v) {
}
});
} catch (MalformedURLException e) {
e.printStackTrace();
}
@@ -217,7 +243,7 @@ public class ZhuangBanActivity extends AbsActivity {
@JavascriptInterface
public void gotoHomePage(String indexStr) {
Log.e("tgasss","indexStr2"+indexStr);
Log.e("tgasss", "indexStr2" + indexStr);
if (!"".equals(indexStr) && indexStr != null) {
int index = -1;
if ("0".equals(indexStr)) {