diff --git a/res/drawable/ic_cancel.xml b/res/drawable/ic_cancel.xml
deleted file mode 100644
index 7d2b57e..0000000
--- a/res/drawable/ic_cancel.xml
+++ /dev/null
@@ -1,9 +0,0 @@
-
-
-
diff --git a/res/drawable/ic_delete_black.xml b/res/drawable/ic_delete_black.xml
deleted file mode 100644
index 125a58f..0000000
--- a/res/drawable/ic_delete_black.xml
+++ /dev/null
@@ -1,9 +0,0 @@
-
-
-
diff --git a/res/drawable/ic_download.xml b/res/drawable/ic_download.xml
deleted file mode 100644
index a3932dd..0000000
--- a/res/drawable/ic_download.xml
+++ /dev/null
@@ -1,10 +0,0 @@
-
-
-
-
diff --git a/res/drawable/ic_info.xml b/res/drawable/ic_info.xml
deleted file mode 100644
index cf53e14..0000000
--- a/res/drawable/ic_info.xml
+++ /dev/null
@@ -1,9 +0,0 @@
-
-
-
diff --git a/res/drawable/ic_pause.xml b/res/drawable/ic_pause.xml
deleted file mode 100644
index d060a4c..0000000
--- a/res/drawable/ic_pause.xml
+++ /dev/null
@@ -1,10 +0,0 @@
-
-
-
-
diff --git a/res/drawable/ic_resume.xml b/res/drawable/ic_resume.xml
deleted file mode 100644
index 078ab9d..0000000
--- a/res/drawable/ic_resume.xml
+++ /dev/null
@@ -1,10 +0,0 @@
-
-
-
-
diff --git a/res/layout/activity_updates.xml b/res/layout/activity_updates.xml
index 8be4d6e..2671d53 100644
--- a/res/layout/activity_updates.xml
+++ b/res/layout/activity_updates.xml
@@ -43,7 +43,7 @@
android:textSize="56sp" />
@@ -62,7 +62,7 @@
android:id="@+id/header_last_check"
android:layout_width="wrap_content"
android:layout_height="wrap_content"
- android:layout_below="@id/header_build_version"
+ android:layout_below="@id/header_build_date"
android:textColor="?android:attr/textColorPrimary"
android:textSize="12sp" />
diff --git a/res/layout/update_item_view.xml b/res/layout/update_item_view.xml
index c12eae1..4abfebf 100644
--- a/res/layout/update_item_view.xml
+++ b/res/layout/update_item_view.xml
@@ -1,105 +1,73 @@
+ android:nextFocusRight="@+id/update_action"
+ app:cardCornerRadius="0dp"
+ app:contentPadding="16dp">
-
+ android:layout_weight="1"
+ android:orientation="vertical">
-
+
+
+
+
+ android:paddingTop="8dp"
+ android:visibility="gone"
+ tools:progress="65"
+ tools:visibility="visible" />
-
-
-
-
-
-
+ android:ellipsize="marquee"
+ android:singleLine="true"
+ tools:text="162 of 300 MB (3 minutes left) • 65%" />
+
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
+
-
diff --git a/res/values/strings.xml b/res/values/strings.xml
index 7b814e1..306249d 100644
--- a/res/values/strings.xml
+++ b/res/values/strings.xml
@@ -83,18 +83,18 @@
LineageOS %1$s
LineageOS %1$s - %2$s
- %1$s of %2$s
- %1$s of %2$s - %3$s left
+ %1$s of %2$s • %3$s
+ %1$s of %2$s (%3$s left) • %4$s
Verifying update
No new updates found. To manually check for new updates, use the Refresh button.
- Download
- Pause download
- Resume download
- Install update
- Show information
- Delete update
- Cancel installation
+ Download
+ Pause
+ Resume
+ Install
+ Info
+ Delete
+ Cancel
Delete file
Delete the selected update file?
diff --git a/src/org/lineageos/updater/ExportUpdateService.java b/src/org/lineageos/updater/ExportUpdateService.java
index e272dc8..37c1239 100644
--- a/src/org/lineageos/updater/ExportUpdateService.java
+++ b/src/org/lineageos/updater/ExportUpdateService.java
@@ -151,7 +151,7 @@ public class ExportUpdateService extends Service {
notificationStyle.bigText(destination.getName());
notificationBuilder.setStyle(notificationStyle);
notificationBuilder.setSmallIcon(R.drawable.ic_system_update);
- notificationBuilder.addAction(R.drawable.ic_pause,
+ notificationBuilder.addAction(com.android.internal.R.drawable.ic_media_pause,
getString(android.R.string.cancel),
getStopPendingIntent());
diff --git a/src/org/lineageos/updater/UpdatesListAdapter.java b/src/org/lineageos/updater/UpdatesListAdapter.java
index db4985b..6ed4f7a 100644
--- a/src/org/lineageos/updater/UpdatesListAdapter.java
+++ b/src/org/lineageos/updater/UpdatesListAdapter.java
@@ -35,8 +35,8 @@ import android.view.Gravity;
import android.view.LayoutInflater;
import android.view.View;
import android.view.ViewGroup;
+import android.widget.Button;
import android.widget.CheckBox;
-import android.widget.ImageButton;
import android.widget.ProgressBar;
import android.widget.TextView;
@@ -78,31 +78,23 @@ public class UpdatesListAdapter extends RecyclerView.Adapter 0) {
CharSequence etaString = StringGenerator.formatDuration(mActivity, eta * 1000);
viewHolder.mProgressText.setText(mActivity.getString(
- R.string.list_download_progress_eta, downloaded, total, etaString));
+ R.string.list_download_progress_eta_new, downloaded, total, etaString,
+ percentage));
} else {
viewHolder.mProgressText.setText(mActivity.getString(
- R.string.list_download_progress, downloaded, total));
+ R.string.list_download_progress_new, downloaded, total, percentage));
}
setButtonAction(viewHolder.mAction, Action.PAUSE, downloadId, true);
viewHolder.mProgressBar.setIndeterminate(update.getStatus() == UpdateStatus.STARTING);
viewHolder.mProgressBar.setProgress(update.getProgress());
- String percentage = NumberFormat.getPercentInstance().format(
- update.getProgress() / 100.f);
- viewHolder.mProgressPercentage.setText(percentage);
} else if (mUpdaterController.isInstallingUpdate(downloadId)) {
setButtonAction(viewHolder.mAction, Action.CANCEL_INSTALLATION, downloadId, true);
boolean notAB = !mUpdaterController.isInstallingABUpdate();
@@ -164,38 +150,31 @@ public class UpdatesListAdapter extends RecyclerView.Adapter {
if (checkbox.isChecked()) {
preferences.edit()
@@ -307,29 +292,23 @@ public class UpdatesListAdapter extends RecyclerView.Adapter startDownloadWithWarning(downloadId) : null;
break;
case PAUSE:
- button.setImageResource(R.drawable.ic_pause);
- button.setContentDescription(
- mActivity.getString(R.string.action_description_pause));
+ button.setText(R.string.action_pause);
button.setEnabled(enabled);
clickListener = enabled ? view -> mUpdaterController.pauseDownload(downloadId)
: null;
break;
case RESUME: {
- button.setImageResource(R.drawable.ic_resume);
- button.setContentDescription(
- mActivity.getString(R.string.action_description_resume));
+ button.setText(R.string.action_resume);
button.setEnabled(enabled);
UpdateInfo update = mUpdaterController.getUpdate(downloadId);
final boolean canInstall = Utils.canInstall(update) ||
@@ -345,9 +324,7 @@ public class UpdatesListAdapter extends RecyclerView.Adapter showInfoDialog() : null;
}
break;
case DELETE: {
- button.setImageResource(R.drawable.ic_delete_black);
- button.setContentDescription(
- mActivity.getString(R.string.action_description_delete));
+ button.setText(R.string.action_delete);
button.setEnabled(enabled);
clickListener = enabled ? view -> getDeleteDialog(downloadId).show() : null;
}
break;
case CANCEL_INSTALLATION: {
- button.setImageResource(R.drawable.ic_cancel);
- button.setContentDescription(
- mActivity.getString(R.string.action_description_cancel));
+ button.setText(R.string.action_cancel);
button.setEnabled(enabled);
clickListener = enabled ? view -> getCancelInstallationDialog().show() : null;
}