Merge lp:~elementary-pantheon/switchboard-plug-onlineaccounts/checkboxes into lp:~elementary-apps/switchboard-plug-onlineaccounts/trunk

Proposed by Danielle Foré
Status: Merged
Approved by: Corentin Noël
Approved revision: 320
Merged at revision: 320
Proposed branch: lp:~elementary-pantheon/switchboard-plug-onlineaccounts/checkboxes
Merge into: lp:~elementary-apps/switchboard-plug-onlineaccounts/trunk
Diff against target: 34 lines (+3/-6)
1 file modified
src/Views/ACListBox.vala (+3/-6)
To merge this branch: bzr merge lp:~elementary-pantheon/switchboard-plug-onlineaccounts/checkboxes
Reviewer Review Type Date Requested Status
elementary Apps team Pending
Review via email: mp+300843@code.launchpad.net

Commit message

Use Checkboxes instead of switches to give apps access to a service

Description of the change

Use Harvey's suggestion to make these checkboxes instead of switches. Helps the UI not look too cluttered and complicated

To post a comment you must log in.

Preview Diff

[H/L] Next/Prev Comment, [J/K] Next/Prev File, [N/P] Next/Prev Hunk
1=== modified file 'src/Views/ACListBox.vala'
2--- src/Views/ACListBox.vala 2016-07-21 07:53:41 +0000
3+++ src/Views/ACListBox.vala 2016-07-22 07:16:17 +0000
4@@ -76,7 +76,7 @@
5
6 private Gtk.Image app_image;
7 private Gtk.Label app_name;
8- private Gtk.Switch app_switch;
9+ private Gtk.CheckButton app_switch;
10 public AppRow (Ag.Account account, Ag.Application app, Ag.Service service, Signon.Identity identity) {
11 this.account = account;
12 this.app = app;
13@@ -95,10 +95,7 @@
14 app_image = new Gtk.Image ();
15 app_image.icon_size = Gtk.IconSize.DND;
16 app_name = new Gtk.Label (null);
17- app_name.halign = Gtk.Align.START;
18- app_name.hexpand = true;
19- app_switch = new Gtk.Switch ();
20- app_switch.valign = Gtk.Align.CENTER;
21+ app_switch = new Gtk.CheckButton ();
22 app_switch.activate.connect (() => {
23 if (app_switch.active) {
24 allow_app ();
25@@ -110,9 +107,9 @@
26 var grid = new Gtk.Grid ();
27 grid.orientation = Gtk.Orientation.HORIZONTAL;
28 grid.column_spacing = 6;
29+ grid.add (app_switch);
30 grid.add (app_image);
31 grid.add (app_name);
32- grid.add (app_switch);
33 add (grid);
34 }
35

Subscribers

People subscribed via source and target branches