summaryrefslogtreecommitdiff
path: root/java
diff options
context:
space:
mode:
authorTreehugger Robot <treehugger-gerrit@google.com>2017-10-05 16:49:00 +0000
committerGerrit Code Review <noreply-gerritcodereview@google.com>2017-10-05 16:49:00 +0000
commitce1377873666ee7732bfe0d9cd7ec6d8986c9125 (patch)
treea9b695e0e4fa2cffac0faf4c45430e721022ee15 /java
parent3a292c344c845f0620639c9eecdd5c3353ff5265 (diff)
parent71216ca5347800ffa2fefc1869bcedbee6e35a6b (diff)
Merge changes If771fbea,Ib213cf3c
* changes: No longer close cursors manually after onLoadFinished is called. FAB now properly scales in multiwindowed mode.
Diffstat (limited to 'java')
-rw-r--r--java/com/android/dialer/app/res/layout/dialtacts_activity.xml5
-rw-r--r--java/com/android/dialer/searchfragment/list/SearchCursorManager.java29
2 files changed, 5 insertions, 29 deletions
diff --git a/java/com/android/dialer/app/res/layout/dialtacts_activity.xml b/java/com/android/dialer/app/res/layout/dialtacts_activity.xml
index 4c07f1c9e..1627844d6 100644
--- a/java/com/android/dialer/app/res/layout/dialtacts_activity.xml
+++ b/java/com/android/dialer/app/res/layout/dialtacts_activity.xml
@@ -41,13 +41,12 @@
<android.support.design.widget.FloatingActionButton
android:id="@+id/floating_action_button"
- android:layout_width="@dimen/floating_action_button_width"
- android:layout_height="@dimen/floating_action_button_height"
+ android:layout_width="wrap_content"
+ android:layout_height="wrap_content"
android:layout_gravity="center_horizontal|bottom"
android:layout_marginBottom="@dimen/floating_action_button_margin_bottom"
android:contentDescription="@string/action_menu_dialpad_button"
android:src="@drawable/quantum_ic_dialpad_white_24"
- android:scaleType="center"
app:elevation="@dimen/floating_action_button_translation_z"
app:backgroundTint="@color/dialer_secondary_color"/>
diff --git a/java/com/android/dialer/searchfragment/list/SearchCursorManager.java b/java/com/android/dialer/searchfragment/list/SearchCursorManager.java
index c6aca8e68..364e97b8c 100644
--- a/java/com/android/dialer/searchfragment/list/SearchCursorManager.java
+++ b/java/com/android/dialer/searchfragment/list/SearchCursorManager.java
@@ -101,10 +101,6 @@ public final class SearchCursorManager {
return false;
}
- if (contactsCursor != null && !contactsCursor.isClosed()) {
- contactsCursor.close();
- }
-
if (cursor != null) {
contactsCursor = cursor;
} else {
@@ -119,10 +115,6 @@ public final class SearchCursorManager {
return false;
}
- if (nearbyPlacesCursor != null && !nearbyPlacesCursor.isClosed()) {
- nearbyPlacesCursor.close();
- }
-
if (cursor != null) {
nearbyPlacesCursor = cursor;
} else {
@@ -146,10 +138,6 @@ public final class SearchCursorManager {
return false;
}
- if (corpDirectoryCursor != null && !corpDirectoryCursor.isClosed()) {
- corpDirectoryCursor.close();
- }
-
if (cursor != null) {
corpDirectoryCursor = cursor;
} else {
@@ -286,20 +274,9 @@ public final class SearchCursorManager {
/** removes all cursors. */
void clear() {
- if (contactsCursor != null) {
- contactsCursor.close();
- contactsCursor = null;
- }
-
- if (nearbyPlacesCursor != null) {
- nearbyPlacesCursor.close();
- nearbyPlacesCursor = null;
- }
-
- if (corpDirectoryCursor != null) {
- corpDirectoryCursor.close();
- corpDirectoryCursor = null;
- }
+ contactsCursor = null;
+ nearbyPlacesCursor = null;
+ corpDirectoryCursor = null;
}
/**