提交 195b72c7 编写于 作者: 杜庆泉's avatar 杜庆泉

修改部分uts 语法,避免警告

上级 ef29a1b2
......@@ -111,9 +111,8 @@ class AddUIRunnable implements Runnable {
textView.setBackgroundColor(Color.RED)
textView.setTag("helloText")
textView.setGravity(Gravity.CENTER)
let decorView = UTSAndroid.getUniActivity()!.window.decorView;
let decorView = UTSAndroid.getUniActivity()!.getWindow().getDecorView();
let frameContent = decorView.findViewById<FrameLayout>(android.R.id.content)
let layoutParam = new FrameLayout.LayoutParams(ViewGroup.LayoutParams.MATCH_PARENT, ViewGroup.LayoutParams.WRAP_CONTENT);
......
......@@ -2,12 +2,14 @@ package uts.sdk.modules.utsSyntaxcase
import android.os.Build
import io.dcloud.uts.UTSAndroid
import io.dcloud.uts.console
object NativeCode {
fun getPhoneInfo():String{
return "${Build.BOARD}-${Build.USER}"
val ret = "${Build.BOARD}-${Build.USER}"
console.log("PhoneInfo",ret)
return ret
}
fun finishActivity(){
......
Markdown is supported
0% .
You are about to add 0 people to the discussion. Proceed with caution.
先完成此消息的编辑!
想要评论请 注册