Merge lp:~elementary-pantheon/switchboard-plug-security-privacy/info-tooltip into lp:~elementary-apps/switchboard-plug-security-privacy/trunk

Proposed by Danielle Foré
Status: Merged
Approved by: Cody Garver
Approved revision: 253
Merged at revision: 253
Proposed branch: lp:~elementary-pantheon/switchboard-plug-security-privacy/info-tooltip
Merge into: lp:~elementary-apps/switchboard-plug-security-privacy/trunk
Diff against target: 55 lines (+2/-29)
1 file modified
src/TrackPanel.vala (+2/-29)
To merge this branch: bzr merge lp:~elementary-pantheon/switchboard-plug-security-privacy/info-tooltip
Reviewer Review Type Date Requested Status
elementary Apps team Pending
Review via email: mp+307235@code.launchpad.net

Commit message

TrackPanel.vala: Remove info_popover in favor of tooltip text

Description of the change

Follow up from some discussion we had before. If there are no interactive elements and only information, we should use (i) with a tooltip. If there are interactive elements then it's ... with a popover.

Since this is only info, should be a tooltip

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
=== modified file 'src/TrackPanel.vala'
--- src/TrackPanel.vala 2016-03-02 18:05:24 +0000
+++ src/TrackPanel.vala 2016-09-29 20:38:29 +0000
@@ -25,7 +25,6 @@
25 private Gtk.RecentManager recent;25 private Gtk.RecentManager recent;
26 private List<Gtk.RecentInfo> items;26 private List<Gtk.RecentInfo> items;
2727
28 private Gtk.Popover info_popover;
29 private Gtk.Popover remove_popover;28 private Gtk.Popover remove_popover;
30 private Dialogs.AppChooser app_chooser;29 private Dialogs.AppChooser app_chooser;
31 private ApplicationBlacklist app_blacklist;30 private ApplicationBlacklist app_blacklist;
@@ -87,17 +86,8 @@
8786
88 create_description_panel ();87 create_description_panel ();
8988
90 var info_button = new Gtk.ToggleButton ();89 var info_button = new Gtk.Image.from_icon_name ("help-info-symbolic", Gtk.IconSize.MENU);
91 info_button.tooltip_text = _("Read more…");90 info_button.tooltip_text = _("This operating system can gather useful statistics about file and app usage to provide extra functionality. If other people can see or access your account, you may wish to limit which items are recorded.");
92 info_button.image = new Gtk.Image.from_icon_name ("help-info-symbolic", Gtk.IconSize.MENU);
93 info_button.relief = Gtk.ReliefStyle.NONE;
94 info_button.notify["active"].connect (() => {
95 if (info_button.active == false) {
96 info_popover.hide ();
97 } else {
98 info_popover.show_all ();
99 }
100 });
10191
102 var record_grid = new Gtk.Grid ();92 var record_grid = new Gtk.Grid ();
103 record_grid.column_spacing = 12;93 record_grid.column_spacing = 12;
@@ -105,23 +95,6 @@
105 record_grid.add (record_switch);95 record_grid.add (record_switch);
106 record_grid.add (info_button);96 record_grid.add (info_button);
10797
108 /* Info Popover */
109
110 var explain_label = new Gtk.Label (_("This operating system can gather useful statistics about file and app usage to provide extra functionality. If other people can see or access your account, you may wish to limit which items are recorded."));
111 explain_label.wrap = true;
112 explain_label.max_width_chars = 60;
113
114 var info_popover_grid = new Gtk.Grid ();
115 info_popover_grid.margin = 12;
116
117 info_popover = new Gtk.Popover (info_button);
118 info_popover.add (info_popover_grid);
119 info_popover.closed.connect (() => {
120 info_button.active = false;
121 });
122
123 info_popover_grid.add (explain_label);
124
125 /* Remove Popover */98 /* Remove Popover */
12699
127 var clear_data = new Gtk.ToggleButton.with_label (_("Clear Usage Data…"));100 var clear_data = new Gtk.ToggleButton.with_label (_("Clear Usage Data…"));

Subscribers

People subscribed via source and target branches