Merge lp:~elementary-apps/appcenter/no-double-update into lp:~elementary-apps/appcenter/appcenter

Proposed by Daniel Fore on 2016-06-15
Status: Merged
Approved by: Felipe Escoto on 2016-06-15
Approved revision: 198
Merged at revision: 200
Proposed branch: lp:~elementary-apps/appcenter/no-double-update
Merge into: lp:~elementary-apps/appcenter/appcenter
Diff against target: 35 lines (+2/-5)
2 files modified
src/Views/AppListView.vala (+1/-0)
src/Widgets/PackageRow.vala (+1/-5)
To merge this branch: bzr merge lp:~elementary-apps/appcenter/no-double-update
Reviewer Review Type Date Requested Status
Felipe Escoto 2016-06-15 Approve on 2016-06-15
Review via email: mp+297504@code.launchpad.net

Commit message

Don't show update button for updated apps

Description of the change

Decide to show the update button when we're choosing the row header so that these two are always in sync

To post a comment you must log in.
198. By Daniel Fore on 2016-06-15

only use visible

review: Approve

Preview Diff

[H/L] Next/Prev Comment, [J/K] Next/Prev File, [N/P] Next/Prev Hunk
1=== modified file 'src/Views/AppListView.vala'
2--- src/Views/AppListView.vala 2016-04-24 21:16:21 +0000
3+++ src/Views/AppListView.vala 2016-06-15 17:11:22 +0000
4@@ -116,6 +116,7 @@
5 [CCode (instance_pos = -1)]
6 private void package_row_update_header (Widgets.PackageRow row, Widgets.PackageRow? before) {
7 bool update_available = row.package.update_available;
8+ row.action_stack.visible = row.package.update_available;
9 if (before == null && update_available) {
10 var updates_grid = get_updates_grid ();
11 row.set_header (updates_grid);
12
13=== modified file 'src/Widgets/PackageRow.vala'
14--- src/Widgets/PackageRow.vala 2016-03-20 00:34:08 +0000
15+++ src/Widgets/PackageRow.vala 2016-06-15 17:11:22 +0000
16@@ -29,7 +29,7 @@
17
18 public Gtk.Button update_button;
19 public Gtk.Button cancel_button;
20- Gtk.Stack action_stack;
21+ public Gtk.Stack action_stack;
22 Gtk.Grid update_grid;
23 Gtk.ProgressBar update_progressbar;
24 Gtk.Label update_label;
25@@ -66,11 +66,7 @@
26 changed ();
27 });
28
29- action_stack.no_show_all = !package.update_available;
30- action_stack.show_all ();
31 package.notify["update-available"].connect (() => {
32- action_stack.no_show_all = !package.update_available;
33- action_stack.show_all ();
34 changed ();
35 });
36

Subscribers

People subscribed via source and target branches

to all changes: