[packagekit] [PATCH] update-viewer: Don't select blocked updates
James Westby
jw+debian at jameswestby.net
Fri Sep 12 09:35:21 PDT 2008
Blocked updates can't be installed, so don't select them by default.
If they are selected then the user must laboriously de-select them all,
otherwise the update will fail.
---
src/gpk-update-viewer.c | 4 +++-
1 files changed, 3 insertions(+), 1 deletions(-)
diff --git a/src/gpk-update-viewer.c b/src/gpk-update-viewer.c
index 8c62b43..5a0978c 100644
--- a/src/gpk-update-viewer.c
+++ b/src/gpk-update-viewer.c
@@ -553,6 +553,7 @@ gpk_update_viewer_get_new_update_list (void)
gchar **package_ids;
GtkTreeIter iter;
gboolean ret;
+ gboolean selected;
/* spin */
gpk_update_viewer_description_animation_start ();
@@ -586,12 +587,13 @@ gpk_update_viewer_get_new_update_list (void)
icon_name = gpk_info_enum_to_icon_name (obj->info);
gtk_list_store_append (list_store_details, &iter);
package_id = pk_package_id_to_string (obj->id);
+ selected = obj->info != PK_INFO_ENUM_BLOCKED;
gtk_list_store_set (list_store_details, &iter,
PACKAGES_COLUMN_TEXT, text,
PACKAGES_COLUMN_ID, package_id,
PACKAGES_COLUMN_ICON, icon_name,
PACKAGES_COLUMN_INFO, obj->info,
- PACKAGES_COLUMN_SELECT, TRUE,
+ PACKAGES_COLUMN_SELECT, selected,
-1);
g_free (package_id);
g_free (text);
--
1.5.6.3
More information about the PackageKit
mailing list