Skip to content
Open
Show file tree
Hide file tree
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
2 changes: 1 addition & 1 deletion AndroidManifest.xml
Original file line number Diff line number Diff line change
Expand Up @@ -241,7 +241,7 @@
android:value="com.android.messaging.ui.conversation.ConversationActivity" />
</activity>

<!-- License -->
<!-- License -->
<activity android:name=".ui.LicenseActivity"
android:exported="true"
android:theme="@android:style/Theme.Holo.Light.Dialog"
Expand Down
1 change: 1 addition & 0 deletions app/build.gradle.kts
Original file line number Diff line number Diff line change
Expand Up @@ -98,6 +98,7 @@ dependencies {
implementation("com.google.guava:guava:33.4.8-android")
implementation("com.googlecode.libphonenumber:libphonenumber:8.13.52")
implementation("com.google.code.findbugs:jsr305:3.0.2")
implementation("com.google.android.material:material:1.13.0")

implementation(project(":lib:platform_frameworks_opt_chips"))
implementation(project(":lib:platform_frameworks_opt_photoviewer"))
Expand Down
138 changes: 138 additions & 0 deletions gradle/verification-metadata.xml

Large diffs are not rendered by default.

2 changes: 1 addition & 1 deletion res/layout/add_contacts_confirmation_dialog_body.xml
Original file line number Diff line number Diff line change
Expand Up @@ -28,7 +28,7 @@
android:layout_width="@dimen/conversation_list_contact_icon_size"
android:layout_height="@dimen/conversation_list_contact_icon_size"
android:importantForAccessibility="no"
app:iconSize="large"
app:iconSize="@dimen/icon_large_size"
android:layout_gravity="center_vertical"
android:clickable="true" />

Expand Down
2 changes: 1 addition & 1 deletion res/layout/blocked_participant_list_item_view.xml
Original file line number Diff line number Diff line change
Expand Up @@ -26,7 +26,7 @@
android:layout_width="@dimen/contact_list_icon_size"
android:layout_height="@dimen/contact_list_icon_size"
android:importantForAccessibility="no"
app:iconSize="normal"
app:iconSize="@dimen/icon_normal_size"
android:layout_gravity="center_vertical"/>
<TextView
android:id="@+id/name"
Expand Down
2 changes: 1 addition & 1 deletion res/layout/compose_message_view.xml
Original file line number Diff line number Diff line change
Expand Up @@ -152,7 +152,7 @@
android:layout_width="@dimen/conversation_message_contact_icon_size"
android:layout_height="@dimen/conversation_message_contact_icon_size"
android:importantForAccessibility="no"
app:iconSize="normal"
app:iconSize="@dimen/icon_normal_size"
app:reveal="true"
android:clickable="true" />
<ImageButton
Expand Down
12 changes: 6 additions & 6 deletions res/layout/contact_list_item_view.xml
Original file line number Diff line number Diff line change
Expand Up @@ -43,7 +43,7 @@
android:layout_width="@dimen/contact_list_icon_size"
android:layout_height="@dimen/contact_list_icon_size"
android:importantForAccessibility="no"
app:iconSize="normal"
app:iconSize="@dimen/icon_normal_size"
android:clickable="true" />

<ImageView
Expand All @@ -53,7 +53,7 @@
android:src="@drawable/ic_checkmark_circle_blue"
android:visibility="gone"
android:importantForAccessibility="no"
android:contentDescription="@null"/>
android:contentDescription="@null"/>

</FrameLayout>

Expand All @@ -64,10 +64,10 @@
android:layout_height="wrap_content"
android:layout_gravity="center_vertical" >

<LinearLayout
android:orientation="horizontal"
android:layout_width="match_parent"
android:layout_height="wrap_content">
<LinearLayout
android:orientation="horizontal"
android:layout_width="match_parent"
android:layout_height="wrap_content">
<TextView
android:id="@+id/contact_name"
android:layout_width="wrap_content"
Expand Down
26 changes: 13 additions & 13 deletions res/layout/conversation_list_item_view.xml
Original file line number Diff line number Diff line change
Expand Up @@ -81,7 +81,7 @@
android:layout_height="@dimen/conversation_list_contact_icon_size"
android:importantForAccessibility="no"
android:contentDescription="@null"
app:iconSize="large"
app:iconSize="@dimen/icon_large_size"
android:clickable="true"
android:background="@android:color/transparent" />
<ImageView
Expand Down Expand Up @@ -119,10 +119,10 @@
android:layout_height="wrap_content"
android:background="@android:color/transparent">
<LinearLayout
android:layout_width="0dp"
android:layout_height="wrap_content"
android:layout_weight="1"
android:background="@android:color/transparent">
android:layout_width="0dp"
android:layout_height="wrap_content"
android:layout_weight="1"
android:background="@android:color/transparent">
<ImageView
android:id="@+id/conversation_notification_bell"
style="@style/ConversationListNotificationBellPaddingStyle"
Expand All @@ -144,14 +144,14 @@
android:paddingBottom="2dp" />
</LinearLayout>
<ImageView
android:id="@+id/work_profile_icon"
android:layout_width="wrap_content"
android:layout_height="wrap_content"
android:layout_gravity="right"
android:background="@android:color/transparent"
android:scaleType="center"
android:src="@drawable/ic_work_profile"
android:visibility="gone"/>
android:id="@+id/work_profile_icon"
android:layout_width="wrap_content"
android:layout_height="wrap_content"
android:layout_gravity="right"
android:background="@android:color/transparent"
android:scaleType="center"
android:src="@drawable/ic_work_profile"
android:visibility="gone"/>
</LinearLayout>
<TextView
android:id="@+id/conversation_subject"
Expand Down
2 changes: 1 addition & 1 deletion res/layout/conversation_message_view.xml
Original file line number Diff line number Diff line change
Expand Up @@ -25,7 +25,7 @@
android:id="@+id/conversation_icon"
android:layout_width="@dimen/conversation_message_contact_icon_size"
android:layout_height="@dimen/conversation_message_contact_icon_size"
app:iconSize="normal"
app:iconSize="@dimen/icon_normal_size"
android:clickable="true"
android:layout_gravity="center_vertical"
android:importantForAccessibility="no" />
Expand Down
2 changes: 1 addition & 1 deletion res/layout/person_item_view.xml
Original file line number Diff line number Diff line change
Expand Up @@ -26,7 +26,7 @@
android:layout_width="@dimen/contact_list_icon_size"
android:layout_height="@dimen/contact_list_icon_size"
android:importantForAccessibility="no"
app:iconSize="normal"
app:iconSize="@dimen/icon_normal_size"
android:layout_gravity="center_vertical" />

<LinearLayout
Expand Down
2 changes: 1 addition & 1 deletion res/layout/sim_selector_item_view.xml
Original file line number Diff line number Diff line change
Expand Up @@ -60,6 +60,6 @@
android:importantForAccessibility="no"
android:layout_gravity="center_vertical"
android:elevation="3dp"
app:iconSize="normal" />
app:iconSize="@dimen/icon_normal_size" />

</com.android.messaging.ui.conversation.SimSelectorItemView>
185 changes: 185 additions & 0 deletions res/values-v31/colors.xml
Original file line number Diff line number Diff line change
@@ -0,0 +1,185 @@
<?xml version="1.0" encoding="utf-8"?>
<!--
Copyright (C) 2015 The Android Open Source Project

Licensed under the Apache License, Version 2.0 (the "License");
you may not use this file except in compliance with the License.
You may obtain a copy of the License at

http://www.apache.org/licenses/LICENSE-2.0

Unless required by applicable law or agreed to in writing, software
distributed under the License is distributed on an "AS IS" BASIS,
WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
See the License for the specific language governing permissions and
limitations under the License.
-->
<resources>
<color name="primary_color">@color/material_dynamic_primary40</color>
<color name="secondary_color">@color/material_dynamic_secondary40</color>
<color name="background_color">@color/material_dynamic_neutral40</color>
<color name="tertiary_color">@color/material_dynamic_tertiary40</color>

<color name="primary_color_dark">@color/material_dynamic_primary30</color>
<color name="secondary_color_dark">@color/material_dynamic_secondary30</color>
<color name="background_color_dark">@color/material_dynamic_neutral30</color>
<color name="tertiary_color_dark">@color/material_dynamic_tertiary30</color>

<color name="permission_check_activity_background">@color/primary_color</color>

<!-- Action bar -->
<color name="action_bar_title_text_color">#ffffff</color>
<color name="action_bar_background_color">@color/primary_color</color>
<color name="action_bar_background_color_dark">@color/primary_color</color>
<color name="contextual_action_bar_background_color">#ffffff</color>
<color name="archived_conversation_action_bar_background_color">@color/background_color</color>
<color name="archived_conversation_action_bar_background_color_dark">@color/background_color_dark</color>

<!-- Conversation list -->
<color name="conversation_list_item_read">#636363</color>
<color name="conversation_list_item_unread">#323232</color>
<color name="conversation_list_error">#F05A24</color>
<color name="conversation_list_name">#DE000000</color>
<color name="conversation_list_details">#8A000000</color>

<color name="conversation_compose_divider_start">#44000000</color>

<color name="message_text">#000000</color>
<color name="timestamp_text_outgoing">#99323232</color>
<color name="timestamp_text_incoming">#99ffffff</color>
<color name="timestamp_text_failed">#99ff0000</color>
<color name="compose_send_text_color">#000000</color>

<color name="message_title_text">#ff323232</color>
<color name="message_download_failed_status_text">#000000</color>
<color name="message_info_text">#99ffffff</color>
<color name="message_info_text_incoming_download_failed">#6a6a6a</color>
<color name="message_download_failed_timestamp_text">#007fce</color>
<color name="message_failed_timestamp_text">#99ff0000</color>
<color name="message_action_status_text">#ffffffff</color>
<color name="message_action_info_text">#99ffffff</color>
<color name="message_action_timestamp_text">#ffffffff</color>

<color name="background_item_transparent">@android:color/transparent</color>
<color name="background_item_activated">#670099cc</color>
<color name="background_item_selected">#cc0099cc</color>
<color name="background_item_pressed">#6733b5e5</color>

<color name="subject_editor_bubble">#ffffffff</color>
<color name="message_text_color_incoming">#ffffffff</color>
<color name="message_text_color_incoming_download_failed">#6a6a6a</color>
<color name="message_text_color_outgoing">#ff323232</color>
<color name="conversation_background">#eeeeee</color>
<color name="conversation_edge_effect">#9d9d9d</color>
<color name="compose_message_send_color">@color/primary_color</color>
<color name="compose_message_send_color_pressed">#999999</color>
<color name="message_bubble_color_outgoing">#ffffffff</color>
<color name="message_error_bubble_color_incoming">#e2e2e2</color>
<color name="message_audio_button_color_incoming">#ffffffff</color>
<color name="message_bubble_color_selected">@color/primary_color_dark</color>
<color name="message_image_selected_tint">@color/primary_color_dark</color>
<color name="generic_video_icon">#ff808080</color>

<!-- Base color used for color filtering. -->
<color name="color_filter_base_color">#ff0000</color>

<!-- Activity background color -->
<drawable name="class_zero_background">#7f040000</drawable>

<color name="contact_avatar_default_background">#d2d2d2</color>
<color name="contact_avatar_pressed_color">#40000000</color>
<color name="contact_list_text_primary">#4d4d4d</color>
<color name="contact_list_text_secondary">#999999</color>

<color name="compose_contact_text">@android:color/white</color>
<color name="compose_contact_faint_text">#a0ffffff</color>
<color name="compose_contact_divider">#44000000</color>
<color name="contact_picker_tab_pressed">#ddffffff</color>
<color name="contact_picker_tab_underline">@android:color/white</color>
<color name="contact_list_alphabet_header">@color/primary_color</color>
<color name="contact_picker_background">#ffffff</color>
<color name="chips_dropdown_background_activated">#4285f4</color>
<color name="chips_dropdown_background_pressed">#ededed</color>
<color name="chips_background_color">#33000000</color>
<color name="chips_text_color">@android:color/white</color>

<color name="camera_button_container_background">#80000000</color>

<color name="translucent_white">#80ffffff</color>

<color name="gallery_image_default_background">#eeeeee</color>
<color name="gallery_image_pressed">#6733b5e5</color>
<color name="attachment_preview_more_items_text_background">#44000000</color>

<color name="letter_tile_font_color">#ffffff</color>

<color name="audio_picker_level_primary_color">#29000000</color>
<color name="audio_record_control_button_stroke">#30000000</color>
<color name="audio_picker_hint_text_color">#40000000</color>
<color name="audio_picker_timer_text_color">#323232</color>
<color name="audio_attachment_timer_text_color">#323232</color>
<color name="audio_progress_bar_color">@color/primary_color</color>

<color name="contact_picker_hint_text_color">#40000000</color>

<color name="notification_sender_text">#DE000000</color>
<color name="notification_secondary_text">#8A000000</color>
<color name="notification_tertiary_text">#8A000000</color>
<color name="wearable_notification_participants_count">#a2a2a2</color>
<color name="notification_accent_color">@color/primary_color</color>
<color name="notification_warning_color">#ff0000</color>
<color name="notification_subject_color">#DE000000</color>

<color name="participant_list_text_primary">#4d4d4d</color>
<color name="participant_list_text_secondary">#6d6d6d</color>
<color name="people_and_options_header_text">#6d6d6d</color>
<color name="people_and_options_list_divider">#cccccc</color>

<color name="fab_color">@color/tertiary_color</color>
<color name="fab_pressed_color">@color/tertiary_color_dark</color>
<color name="fab_ripple">@color/background_color</color>

<color name="message_body_size_text_color">#555555</color>
<color name="mms_indicator_color">@color/tertiary_color</color>
<color name="list_empty_text">#6d6d6d</color>
<color name="low_storage_action_item_color">#ff000000</color>
<color name="unblock_item_text_color">@color/tertiary_color</color>
<color name="open_conversation_animation_background_shadow">#40000000</color>
<color name="compose_notification_bar_background">@color/primary_color</color>

<color name="sim_selector_text_primary">#4d4d4d</color>
<color name="sim_selector_text_secondary">#999999</color>
<color name="sim_selector_background_end">#cceeeeee</color>
<color name="sim_selector_background_start">#ffeeeeee</color>
<color name="sim_indicator_color_light">#ffffff</color>
<color name="sim_indicator_color_dark">#323232</color>

<color name="text_highlight_color">@color/tertiary_color_dark</color>
<color name="search_view_text_cursor">#b0dddddd</color>

<color name="button_bar_action_button_text_color">#03a9f4</color>
<color name="button_bar_cancel_button_text_color">#4d4d4d</color>

<color name="settings_list_text_primary">#4d4d4d</color>
<color name="settings_list_text_secondary">#6d6d6d</color>
<color name="group_mms_setting_text_color">#333333</color>
<color name="settings_item_title_text_primary">#000000</color>

<color name="contact_picker_button_text_color">@color/primary_color</color>

<color name="widget_text_color">#424242</color>
<color name="widget_incoming_text_color">@android:color/white</color>
<color name="widget_outgoing_text_color">#424242</color>
<color name="widget_background_color">#ffffff</color>
<color name="ripple_material_light">#40000000</color>
<color name="widget_conversation_title_color">#FFFFFF</color>

<color name="attachment_chooser_audio_background">#eeeeee</color>
<color name="attachment_chooser_vcard_background">#eeeeee</color>

<color name="fastscroll_track_color">#1e000000</color>
<color name="fastscroll_thumb_color">#42000000</color>
<color name="fastscroll_preview_text_color">#ffffff</color>

<color name="google_gray">#F1F1F1</color>
</resources>
2 changes: 1 addition & 1 deletion res/values/attrs.xml
Original file line number Diff line number Diff line change
Expand Up @@ -16,7 +16,7 @@
-->
<resources>
<declare-styleable name="ContactIconView">
<attr name="iconSize">
<attr name="contactIconSize">
<enum name="normal" value="0" />
<enum name="large" value="1" />
<enum name="small" value="2" />
Expand Down
3 changes: 3 additions & 0 deletions res/values/dimens.xml
Original file line number Diff line number Diff line change
Expand Up @@ -16,6 +16,9 @@
-->
<resources>

<dimen name="icon_normal_size">42dp</dimen>
<dimen name="icon_large_size">56dp</dimen>
<dimen name="icon_small_size">12dp</dimen>
<dimen name="action_bar_height">56dp</dimen>
<dimen name="action_bar_elevation">8dp</dimen>
<dimen name="action_bar_text_size">20sp</dimen>
Expand Down
6 changes: 4 additions & 2 deletions src/com/android/messaging/BugleApplication.java
Original file line number Diff line number Diff line change
Expand Up @@ -26,6 +26,7 @@
import android.os.Looper;
import android.telephony.CarrierConfigManager;

import com.google.android.material.color.DynamicColors;
import com.android.messaging.datamodel.DataModel;
import com.android.messaging.receiver.SmsReceiver;
import com.android.messaging.sms.BugleUserAgentInfoLoader;
Expand Down Expand Up @@ -71,6 +72,7 @@ public static boolean isRunningTests() {
@Override
public void onCreate() {
Trace.beginSection("app.onCreate");
DynamicColors.applyToActivitiesIfAvailable(this);
super.onCreate();

// Note onCreate is called in both test and real application environments
Expand Down Expand Up @@ -195,14 +197,14 @@ private void maybeStartProfiling() {
if (file != null) {
android.os.Debug.startMethodTracing(file.getAbsolutePath(), 160 * 1024 * 1024);
new Handler(Looper.getMainLooper()).postDelayed(
new Runnable() {
new Runnable() {
@Override
public void run() {
android.os.Debug.stopMethodTracing();
// Allow world to see trace file
DebugUtils.ensureReadable(file);
LogUtil.d(LogUtil.PROFILE_TAG, "Tracing complete - "
+ file.getAbsolutePath());
+ file.getAbsolutePath());
}
}, 30000);
}
Expand Down
2 changes: 1 addition & 1 deletion src/com/android/messaging/ui/ContactIconView.java
Original file line number Diff line number Diff line change
Expand Up @@ -57,7 +57,7 @@ public ContactIconView(final Context context, final AttributeSet attrs) {
final Resources resources = context.getResources();
final TypedArray a = context.obtainStyledAttributes(attrs, R.styleable.ContactIconView);

final int iconSizeId = a.getInt(R.styleable.ContactIconView_iconSize, 0);
final int iconSizeId = a.getInt(R.styleable.ContactIconView_contactIconSize, 0);
switch (iconSizeId) {
case NORMAL_ICON_SIZE_ID:
mIconSize = (int) resources.getDimension(
Expand Down