Skip to content

Commit

Permalink
tbs static push 03 添加armeabi打包
Browse files Browse the repository at this point in the history
修改任务界面的UI

修改设备列表页的状态显示,只显示在线和离线
  • Loading branch information
admin authored and admin committed Aug 25, 2020
1 parent aed6755 commit 433369c
Show file tree
Hide file tree
Showing 9 changed files with 252 additions and 200 deletions.
246 changes: 175 additions & 71 deletions .idea/workspace.xml

Large diffs are not rendered by default.

5 changes: 2 additions & 3 deletions android/build.gradle
Original file line number Diff line number Diff line change
Expand Up @@ -32,15 +32,14 @@ android {
}
defaultConfig {
minSdkVersion 16
ndk {abiFilters "armeabi"}
}
lintOptions {
disable 'InvalidPackage'
}
}

dependencies {
implementation fileTree(dir: 'libs', include: ['*.jar'])
implementation "org.jetbrains.kotlin:kotlin-stdlib-jdk7:$kotlin_version"
implementation files('libs/tbs_sdk_thirdapp_v3.5.0.1063_43500_staticwithdownload_withoutGame_obfs_20171011_195714.jar')

}
}
Binary file added android/src/main/jniLibs/armeabi/libapp.so
Binary file not shown.
Binary file added android/src/main/jniLibs/armeabi/libflutter.so
Binary file not shown.
Original file line number Diff line number Diff line change
Expand Up @@ -6,6 +6,7 @@ import android.os.Build
import android.os.Bundle
import android.util.Log
import android.widget.LinearLayout
import com.tencent.smtt.export.external.interfaces.SslError
import com.tencent.smtt.export.external.interfaces.SslErrorHandler
import com.tencent.smtt.export.external.interfaces.WebResourceError
import com.tencent.smtt.export.external.interfaces.WebResourceRequest
Expand Down Expand Up @@ -39,15 +40,18 @@ class X5WebViewActivity : Activity() {
title = intent.getStringExtra("title")
url= intent.getStringExtra("url")
setTitle(title)
}

if (QbSdk.canLoadX5(applicationContext)) {
override fun onResume() {
super.onResume()
Log.i(TAG, "onResume")
if (QbSdk.canLoadX5(this)) {
Log.i(TAG, "已安装好,直接显示")
createWebview()
} else {
Log.i(TAG, "新安装")
Thread(Runnable {
val ok = QbSdk.preinstallStaticTbs(this)
//
runOnUiThread {
Log.i(TAG, "安装结果:$ok")
createWebview()
Expand Down Expand Up @@ -107,11 +111,12 @@ class X5WebViewActivity : Activity() {

override fun onReceivedError(p0: WebView?, p1: WebResourceRequest?, p2: WebResourceError?) {
super.onReceivedError(p0, p1, p2)
Log.d(TAG, "webview onReceivedError : $p2")
Log.d(TAG, "webview onReceivedError :description : ${p2?.description} errorCode :"+p2?.errorCode)
}

override fun onReceivedSslError(p0: WebView?, p1: SslErrorHandler?, p2: com.tencent.smtt.export.external.interfaces.SslError?) {
Log.d(TAG, "onReceivedSslError : $p1")
override fun onReceivedSslError(p0: WebView?, p1: SslErrorHandler?, p2: SslError?) {
Log.d(TAG, "webview onReceivedSslError : ${p2.toString()}")
// super.onReceivedSslError(p0, p1, p2)
p1?.proceed()
}
}
Expand Down
14 changes: 14 additions & 0 deletions example/android/app/build.gradle
Original file line number Diff line number Diff line change
Expand Up @@ -43,13 +43,27 @@ android {
targetSdkVersion 28
versionCode flutterVersionCode.toInteger()
versionName flutterVersionName
ndk {
// abiFilters "armeabi" ,"armeabi-v7a", "arm64-v8a"
abiFilters "armeabi"
}
}

buildTypes {
release {
// TODO: Add your own signing config for the release build.
// Signing with the debug keys for now, so `flutter run --release` works.
signingConfig signingConfigs.debug
ndk{
//这里其实我觉可以直接是用"armeabi-v7a",但国内几个大哥之前使用的都是"armeabi"
abiFilters "armeabi"
}
}
debug {
ndk {
//这里要加上,否则debug包会出问题,后面三个为可选,x86建议加上不然部分模拟器回报错
abiFilters "armeabi"
}
}
}
}
Expand Down
4 changes: 2 additions & 2 deletions example/lib/main.dart
Original file line number Diff line number Diff line change
Expand Up @@ -53,8 +53,8 @@ class _MyAppState extends State<MyApp> {
child: InkWell(
onTap: () async {
try {

var gg = await TbsStatic.openWebActivity(" https://10.155.0.134:31311/static/testvideo/video.html?sid=60cbd910-d555-11ea-af73-45d5ffed74da&userName=cross&token=CA50B2B0E37011EA87A219C1CF68FE0E&serverAddress=wss://10.155.0.135:30670/hari&accountId=AZ019121",title: "测试界面",landspace:true );
var gg = await TbsStatic.openWebActivity("https://10.155.0.134:31311/static/testvideo/video.html?sid=60cbd910-d555-11ea-af73-45d5ffed74da&userName=cross&token=F62541A0E5CB11EA87A219C1CF68FE0E&serverAddress=wss://10.155.0.135:30670/hari&accountId=AZ019121",title: "测试界面",landspace:true );
// var gg = await TbsStatic.openWebActivity("http://debugtbs.qq.com",title: "测试界面",landspace:true );
} on PlatformException {

}
Expand Down
87 changes: 26 additions & 61 deletions example/pubspec.lock
Original file line number Diff line number Diff line change
@@ -1,69 +1,62 @@
# Generated by pub
# See https://dart.dev/tools/pub/glossary#lockfile
packages:
archive:
dependency: transitive
description:
name: archive
url: "https://pub.dartlang.org"
source: hosted
version: "2.0.13"
args:
dependency: transitive
description:
name: args
url: "https://pub.dartlang.org"
source: hosted
version: "1.6.0"
async:
dependency: transitive
description:
name: async
url: "https://pub.dartlang.org"
source: hosted
version: "2.4.1"
version: "2.4.2"
boolean_selector:
dependency: transitive
description:
name: boolean_selector
url: "https://pub.dartlang.org"
source: hosted
version: "2.0.0"
charcode:
characters:
dependency: transitive
description:
name: charcode
name: characters
url: "https://pub.dartlang.org"
source: hosted
version: "1.1.3"
collection:
version: "1.0.0"
charcode:
dependency: transitive
description:
name: collection
name: charcode
url: "https://pub.dartlang.org"
source: hosted
version: "1.14.12"
convert:
version: "1.1.3"
clock:
dependency: transitive
description:
name: convert
name: clock
url: "https://pub.dartlang.org"
source: hosted
version: "2.1.1"
crypto:
version: "1.0.1"
collection:
dependency: transitive
description:
name: crypto
name: collection
url: "https://pub.dartlang.org"
source: hosted
version: "2.1.4"
version: "1.14.13"
cupertino_icons:
dependency: "direct main"
description:
name: cupertino_icons
url: "https://pub.dartlang.org"
source: hosted
version: "0.1.3"
fake_async:
dependency: transitive
description:
name: fake_async
url: "https://pub.dartlang.org"
source: hosted
version: "1.1.0"
flutter:
dependency: "direct main"
description: flutter
Expand All @@ -74,20 +67,13 @@ packages:
description: flutter
source: sdk
version: "0.0.0"
image:
dependency: transitive
description:
name: image
url: "https://pub.dartlang.org"
source: hosted
version: "2.1.12"
matcher:
dependency: transitive
description:
name: matcher
url: "https://pub.dartlang.org"
source: hosted
version: "0.12.6"
version: "0.12.8"
meta:
dependency: transitive
description:
Expand All @@ -101,21 +87,7 @@ packages:
name: path
url: "https://pub.dartlang.org"
source: hosted
version: "1.6.4"
petitparser:
dependency: transitive
description:
name: petitparser
url: "https://pub.dartlang.org"
source: hosted
version: "2.4.0"
quiver:
dependency: transitive
description:
name: quiver
url: "https://pub.dartlang.org"
source: hosted
version: "2.1.3"
version: "1.7.0"
sky_engine:
dependency: transitive
description: flutter
Expand All @@ -134,7 +106,7 @@ packages:
name: stack_trace
url: "https://pub.dartlang.org"
source: hosted
version: "1.9.3"
version: "1.9.5"
stream_channel:
dependency: transitive
description:
Expand Down Expand Up @@ -169,28 +141,21 @@ packages:
name: test_api
url: "https://pub.dartlang.org"
source: hosted
version: "0.2.15"
version: "0.2.17"
typed_data:
dependency: transitive
description:
name: typed_data
url: "https://pub.dartlang.org"
source: hosted
version: "1.1.6"
version: "1.2.0"
vector_math:
dependency: transitive
description:
name: vector_math
url: "https://pub.dartlang.org"
source: hosted
version: "2.0.8"
xml:
dependency: transitive
description:
name: xml
url: "https://pub.dartlang.org"
source: hosted
version: "3.6.1"
sdks:
dart: ">=2.7.0 <3.0.0"
dart: ">=2.9.0-14.0.dev <3.0.0"
flutter: ">=1.10.0"
Loading

0 comments on commit 433369c

Please sign in to comment.