[Taxi无人化] refactor: DebugView打印日志 根据日志分级,使用不同颜色;
This commit is contained in:
@@ -54,7 +54,6 @@ public class DebugView @JvmOverloads constructor(
|
||||
const val BROADCAST_DATA_SHOW = "isShow"
|
||||
|
||||
private var logHistoryTextView: TextView? = null
|
||||
|
||||
fun printInfoMsg(msg: String) {
|
||||
printMsg("Info $msg", MainMoGoApplication.getApp().getColor(R.color.background_info))
|
||||
}
|
||||
@@ -77,7 +76,7 @@ public class DebugView @JvmOverloads constructor(
|
||||
)
|
||||
UiThreadHandler.post({
|
||||
it.append("\n")
|
||||
it.append(spannableMsg.toString())
|
||||
it.append(spannableMsg)
|
||||
|
||||
val offset: Int = it.lineCount * it.lineHeight
|
||||
if (offset > it.height) {
|
||||
|
||||
@@ -190,6 +190,7 @@
|
||||
android:background="@drawable/taxi_debug_view_log_history_bg"
|
||||
android:fadeScrollbars="false"
|
||||
android:maxLines="15"
|
||||
android:minLines="15"
|
||||
android:scrollbars="vertical"
|
||||
android:textColor="@android:color/white"
|
||||
android:textSize="@dimen/dp_24" />
|
||||
|
||||
Reference in New Issue
Block a user