[gnome-packagekit] Only show the on-battery warning only if we would have performed the update
- From: Richard Hughes <rhughes src gnome org>
- To: svn-commits-list gnome org
- Cc:
- Subject: [gnome-packagekit] Only show the on-battery warning only if we would have performed the update
- Date: Mon, 24 Aug 2009 07:40:14 +0000 (UTC)
commit 5a87fc9b23cebf062b924dfc04c031fdc22c6d2d
Author: Richard Hughes <richard hughsie com>
Date: Mon Aug 24 08:39:07 2009 +0100
Only show the on-battery warning only if we would have performed the update
src/gpk-check-update.c | 4 +++-
1 files changed, 3 insertions(+), 1 deletions(-)
---
diff --git a/src/gpk-check-update.c b/src/gpk-check-update.c
index 309a9db..d8a652f 100644
--- a/src/gpk-check-update.c
+++ b/src/gpk-check-update.c
@@ -911,7 +911,9 @@ gpk_check_update_process_updates (GpkCheckUpdate *cupdate, PkPackageList *list,
/* are we on battery and configured to skip the action */
ret = gpk_check_update_check_on_battery (cupdate);
- if (!ret) {
+ if (!ret &&
+ ((update == GPK_UPDATE_ENUM_SECURITY && security_array->len > 0) ||
+ update == GPK_UPDATE_ENUM_ALL)) {
egg_debug ("on battery so not doing update");
/* play the sound, using sounds from the naming spec */
[
Date Prev][
Date Next] [
Thread Prev][
Thread Next]
[
Thread Index]
[
Date Index]
[
Author Index]