全局可配置值

使用本文中提供的資源來自定義 Dialer。不同的視圖將使用從全局值重定向的資源。有關詳細信息,請參閱 AOSP UX 設計(可能需要登錄)。

撥號盤輸入動作

<!-- Boolean config to gate the dialpad input motion -->
<bool name="config_enable_dial_motion">true</bool>
<!-- Font scale for the last input digit -->
<item name="config_dial_motion_scale_start" format="float" type="integer">1.5</item>
<!-- Scale down motion duration for the last input digit -->
<integer name="config_dial_motion_duration">200</integer>

撥號盤中輸入數字的重力

<!-- 8388629 stands for Gravity.END |
Gravity.CENTER_VERTICAL-->
<integer name="config_dialed_number_gravity">8388629</integer>

詳細的用戶資料

配置為在找到與輸入號碼匹配的聯繫人時顯示詳細的用戶配置文件。為 false 時,顯示聯繫人姓名。如果為 true,則顯示聯繫人頭像、聯繫人姓名和電話號碼標籤。

<bool name="config_show_detailed_user_profile_on_dialpad">false</bool>

背景圖像阿爾法

設置為 0 時,背景圖像不可見。

<!-- Alpha when there is a contact avatar -->
<item name="config_background_image_alpha" format="float"
type="dimen">1.0</item>
<!-- Alpha when there are no contact avatars and uses the letter tile drawable color as background. -->
<item name="config_background_image_error_alpha" format="float" type="dimen">1.0</item>

最近和聯繫人頁面上的操作按鈕

<!-- A config determines whether to show divider and callog_action_button for callog items that
are not stored as contacts. "true" will show divider and button as disable state and "false" will
make divider and button invisible for non contacts. -->
    <bool name="config_show_calllog_action_button_for_non_contact">false</bool>

<!-- A config determines whether to show divider and the button on the right side for contacts
without any contact details. "true" will show divider and button as disable state and "false" will
make divider and button invisible for empty contacts. -->
    <bool name="config_show_contact_detail_button_for_empty_contact">false</bool>

聯繫方式頁面上的登機口地址和導航功能

使用此佈爾配置來控制聯繫人詳細信息頁面上的地址和導航功能。

<!-- A config determines whether to show postal address in contact details page. -->
<bool name="config_show_postal_address">false</bool>

聯繫方式頁面上的工具欄

<!-- A config determines whether to show the action bar view in the contact details page.-->
<bool name="config_show_contact_details_action_bar_view">false</bool>
<!-- A config determines if to show the action bar avatar in the contact details page.-->
<bool name="config_show_contact_details_action_bar_avatar">true</bool>

工具欄標題模式

工具欄標題模式的配置:

  • 0 表示應用名稱。
  • 1 表示沒有工具欄標題。
  • 2 表示連接的藍牙設備名稱。
<!-- Use app name as toolbar title. Supported value see @attr/toolbarTitleMode -->
<integer name="config_toolbar_title_mode">0</integer>

全屏通話界面

全屏調用 UI 的配置門。設置為 true 時,無論 Dialer 用戶如何,接聽來電都會顯示全屏來電 UI。設置為 false 時,當用戶不在 Dialer 中時,接聽來電會關閉 HUN,而不顯示全屏來電 UI。

<bool name="config_show_fullscreen_incall_ui">true</bool>

頭像一角

更改此值會影響所有頭像形狀,包括通知頭像:

  • 0.5 表示圓形頭像。
  • 1 表示方形頭像。
<dimen name="contact_avatar_corner_radius_percent" format="float">0.5</dimen>

用於列表項的頭像大小

使用此配置為這些頁面上的列表項設置頭像大小:

  • 通話記錄頁面
  • 聯繫人頁面
  • 搜索頁面
  • 撥號盤頁面上的個人資料頭像
<dimen name="avatar_icon_size">76dp</dimen>

用戶使用撥號盤撥號時的實時搜索結果

<!-- A config determines whether to show type down list on Dialpad -->
<bool name="config_show_type_down_list_on_dialpad">true</bool>

控制欄高度

設置 Ongoing Call 控制欄的高度、Incoming Call 控制欄的高度和 Call 按鈕的高度。

<dimen name="control_bar_height">96dp</dimen>

列出項目維度

<dimen name="list_item_height">116dp</dimen>