本頁介紹了下面列出的每個版本中 Car UI 庫所做的更新。
汽車使用者介面庫 2.6.0
新功能
- 新增了
CarUiToolbar
徽標的點擊監聽器。
已解決的問題
- 修正了透過外掛程式進行更新時
CarUiToolbar
的溢出對話框內容仍然過時的問題。 - 修正了由於應用了不正確的插圖而導致
CarUiRecyclerView
的滾動條不可見的問題。 - 修正了插件回傳 null
InsetsChangedListener
時的問題。 - 新增了一項檢查以強制
AppStyledView
中呈現的內容不得使用Theme.CarUi
。 - 修正了大橫向螢幕中的預設
AppStyledView
定位。 - 新增了
AppStyledView
背景和暗量的自訂。 - 新增了對顯示
AppStyledView
後呼叫AppStyledDialog#setContentView()
的支援。
已棄用這些方法:
-
CarUi#installBaseLayoutAround(View, InsetsChangedListener, boolean)
,請改用CarUi#InsetsChangedListener(Context, View, InsetsChangedListener, boolean)
。 -
CarUi#installBaseLayoutAround(View, InsetsChangedListener, boolean, boolean)
,請改用CarUi#InsetsChangedListener(Context, View, InsetsChangedListener, boolean, boolean)
。
car-ui-lib-plugin-apis 1.5.0
新功能
- 新增了
CarUiToolbar
徽標點擊監聽器的自訂。
已棄用這些項目:
-
PluginFactoryOEMV6
,請改用PluginFactoryOEMV7
。 -
ToolbarControllerOEMV2
,請改用ToolbarControllerOEMV3
。
汽車使用者介面庫 2.5.1
已解決的問題
- 修正了阻止載入 car-ui-lib 插件的 ProGuard 問題。
- 修正了插件的前向相容性,該插件會在運行時導致 NPE。
- 強制 car-ui-lib 插件必須是系統應用程式。
- 修正了
CarUiRecyclerView
在某些情況下不顯示捲軸的問題。 - 修正了使用外掛時選定的選項卡不更新的問題。
- 修正了使用外掛時實例化
SearchView
問題。 - 使用 Activity 上下文初始化汽車服務 UX 限制狀態回調,以實現正確的顯示配置。
- 更新了無效註釋。
汽車使用者介面庫 2.5.0
已解決的問題
- 優化插件啟動時間。
- 修正了應用程式始終返回 1 作為最大支援插件版本的問題。
- 刪除了主題的覆蓋,以強制
AppStyledView
中的Theme.CarUi
。 - 新增了可重寫的方法來在
ListPreferenceFragment
上設定標題。
car-ui-lib-plugin-apis 1.4.0
新功能
- 允許 OEM 自訂
CarUiPreference
。
已棄用這些項目:
-
PluginFactoryOEMV5
,請改用PluginFactoryOEMV6
。
汽車使用者介面庫 2.4.0
新功能
- 新增了對過渡到
AppStyledView
支援。
已解決的問題
- 更新了
AppStyledRecyclerViewAdapter
以不再公開。 - 為
AppStyledDialogController
的優化提供了一個方便的上下文方法。 - 將
AppStyledViewNavIcon
定義移至AppStyledDialogController
。 - 刪除了
AppStyledView
中對Theme.CarUi
主題的強制覆蓋。 - 新增了過渡以支援
AppStyledView
畫面的渲染。 - 將
car_ui_recycler_view_no_scrollbar
加入到可以覆蓋的項目清單中。 - 為
CarUiRecyclerView
espressoViewActions
和ViewMatchers
建立了 Gradle 函式庫。 - 重構應用程式樣式視圖以使用
ScrollView
。
car-ui-lib-plugin-apis 1.3.0
新功能
已棄用這些項目:
-
PluginFactoryOEMV4
,請改用PluginFactoryOEMV5
。 -
RecyclerViewOEMV1
,請改用RecyclerViewOEMV2
。 -
OnScrollListenerOEMV1
,請改用RecyclerViewOEMV2.OnScrollListenerOEMV2
。
汽車使用者介面庫 2.3.0
新功能
新增了新組件:
-
CarUiShortcutsPopup
新增了對以下滾動條屬性的支援:
-
android:fadeScrollbars
-
android:scrollbars
-
android:scrollbarThumbVertical
-
android:scrollbarTrackVertical
-
android:scrollbarStyle
-
android:scrollbarFadeDuration
-
android:verticalScrollbarPosition
-
android:requiresFadingEdge
已解決的問題
修復了
CarUiRecyclerView
,它在Activity
重新建立時沒有保持位置。解決了客戶端程式碼和 IME 服務之間的點陣圖序列化不相容問題。
啟用
NavHostFragment
與PreferenceFragment
的使用。
car-ui-lib-plugin-apis 1.2.0
新功能
將java.util.function
介面的使用替換為以下程式庫介面:
-
com.android.car.ui.plugin.oemapis.BiConsumer
-
com.android.car.ui.plugin.oemapis.Consumer
-
com.android.car.ui.plugin.oemapis.Function
已棄用這些項目:
-
PluginFactoryOEMV3
,請改用PluginFactoryOEMV4
。 -
ToolbarControllerOEMV1
,請改用ToolbarControllerOEMV2
。 -
ContentListItemOEMV1
,請改用ContentListItemOEMV2
。 -
ImeSearchInterfaceOEMV1
,請改用ImeSearchInterfaceOEMV2
。
將 nullness 介面的函式庫實作替換為androidx.annotations
的實作。
car-ui-lib-plugin-apis 1.1.1
此版本將minSdkVersion
更新為 28。
汽車使用者介面庫 2.2.1
本次發布:
- 介紹
CarUiFooterPreference
- 將
minSdkVersion
更新為 28。
car-ui-lib-plugin-apis 1.1.0
本次發布:
- 棄用
AppStyledViewControllerOEMV1
推出
AppStyledViewControllerOEMV2
合併了
AppStyledViewControllerOEMV1
的變更:public abstract int getContentAreaHeight(); public abstract int getContentAreaWidth();
棄用
PluginFactoryOEMV1
和PluginFactoryOEMV2
引入
PluginFactoryOEMV3
介面。
汽車使用者介面庫 2.1.0
本次發布:
新增
AppStyledView
客戶端 API:public int getContentAreaHeight(); public int getContentAreaWidth();
介紹
CarUiPrimarySwitchPreference
更新
AppStyledDialogController
建構子以需要Activity
而不是Context
:補充:
public AppStyledDialogController(android.app.Activity);
棄用:
public AppStyledDialogController(android.content.Context);
car-ui-lib-plugin-apis 1.0.1
此版本新增了 nullness 註解。
car-ui-lib-plugin-apis 1.0.0
此版本引入了對以下car-ui-lib
插件 API 的支援:
-
AppStyledViewDialog
-
CarUiRecyclerView
-
CarUiToolbar
-
CarUiListItems
汽車使用者介面庫 2.0.0
此版本可在Google Maven上使用,引入了對這些元件car-ui-lib
插件支援:
-
AppStyledViewDialog
-
CarUiRecyclerView
-
CarUiToolbar
-
CarUiListItems
汽車使用者介面庫 1.0.0
此版本可在適用於 Android 12 及更低版本的 AOSP 上使用,並提供以下支援:
-
AppStyledViewDialog
-
CarUiRecyclerView
-
CarUiToolbar
-
CarUiListItems
- 對話
- 透過運行時資源覆蓋 (RRO)進行資源定制
PreferencesFragment
- 旋轉支撐
WideScreenImeKeyboard