Merge lp:~jeremywootten/pantheon-files/fix-1027319 into lp:~elementary-apps/pantheon-files/trunk

Proposed by Jeremy Wootten
Status: Merged
Approved by: Danielle Foré
Approved revision: 1236
Merged at revision: 1236
Proposed branch: lp:~jeremywootten/pantheon-files/fix-1027319
Merge into: lp:~elementary-apps/pantheon-files/trunk
Diff against target: 30 lines (+9/-0)
2 files modified
schemas/org.pantheon.files.gschema.xml (+5/-0)
src/marlin-places-sidebar.c (+4/-0)
To merge this branch: bzr merge lp:~jeremywootten/pantheon-files/fix-1027319
Reviewer Review Type Date Requested Status
Danielle Foré Approve
Cody Garver (community) Approve
Review via email: mp+170694@code.launchpad.net

Commit message

Fixes bug 1027319 by imposing a minimum width on the marlin-places-sidebar.

Description of the change

Fixes bug 1027319 by imposing a minimum width on the marlin-places-sidebar,thereby circumventing problems with rendering this widget with very small width. The optimum minimum width needs to be agreed. I have set it to 96, which is wide enough for the category headers to not to be truncated. This value is set by a new key in the org.pantheon.files.preferences schema.

To post a comment you must log in.
Revision history for this message
Cody Garver (codygarver) wrote :

I can confirm this fixes that crash. We just need to hear from design team about the min width value.

review: Approve
Revision history for this message
Danielle Foré (danrabbit) :
review: Approve

Preview Diff

[H/L] Next/Prev Comment, [J/K] Next/Prev File, [N/P] Next/Prev Hunk
1=== modified file 'schemas/org.pantheon.files.gschema.xml'
2--- schemas/org.pantheon.files.gschema.xml 2013-06-01 20:18:10 +0000
3+++ schemas/org.pantheon.files.gschema.xml 2013-06-20 20:25:31 +0000
4@@ -95,6 +95,11 @@
5 <summary>Width of the side pane</summary>
6 <description>The default width of the side pane in new windows.</description>
7 </key>
8+ <key type="i" name="minimum-sidebar-width">
9+ <default>96</default>
10+ <summary>Minimum width of the side pane</summary>
11+ <description>The minimum width of the side pane.</description>
12+ </key>
13 <key type="b" name="confirm-trash">
14 <default>true</default>
15 <summary>Confirm trash</summary>
16
17=== modified file 'src/marlin-places-sidebar.c'
18--- src/marlin-places-sidebar.c 2013-05-27 22:20:15 +0000
19+++ src/marlin-places-sidebar.c 2013-06-20 20:25:31 +0000
20@@ -2851,6 +2851,10 @@
21
22 /* tree view */
23 tree_view = GTK_TREE_VIEW (gtk_tree_view_new ());
24+
25+ /*stop side-bar being shrunk too small, which causes a crash*/
26+ gtk_widget_set_size_request (tree_view, g_settings_get_int (settings, "minimum-sidebar-width"), -1);
27+
28 gtk_tree_view_set_headers_visible (tree_view, FALSE);
29
30 col = GTK_TREE_VIEW_COLUMN (gtk_tree_view_column_new ());

Subscribers

People subscribed via source and target branches

to all changes: