Merge lp:~jeremywootten/pantheon-files/fix-1462725-crash-when-renaming-Home-bookmark into lp:~elementary-apps/pantheon-files/trunk

Proposed by Jeremy Wootten
Status: Merged
Approved by: Cody Garver
Approved revision: 1850
Merged at revision: 1858
Proposed branch: lp:~jeremywootten/pantheon-files/fix-1462725-crash-when-renaming-Home-bookmark
Merge into: lp:~elementary-apps/pantheon-files/trunk
Diff against target: 15 lines (+5/-0)
1 file modified
src/View/Sidebar.vala (+5/-0)
To merge this branch: bzr merge lp:~jeremywootten/pantheon-files/fix-1462725-crash-when-renaming-Home-bookmark
Reviewer Review Type Date Requested Status
elementary Apps team Pending
Review via email: mp+261325@code.launchpad.net

Commit message

Do not allow renaming of certain sidebar entries (lp:1462725)

Description of the change

This branch prevents using F2 to rename sidebar entries that are not meant to be renamed, such as the Home and Rubbish Bin entries, and for which an attempt to rename causes a crash.

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/View/Sidebar.vala'
2--- src/View/Sidebar.vala 2015-05-25 09:20:13 +0000
3+++ src/View/Sidebar.vala 2015-06-07 10:54:15 +0000
4@@ -1141,6 +1141,11 @@
5 if (!get_selected_iter ( out iter))
6 return;
7
8+ bool is_bookmark;
9+ store.@get (iter, Column.BOOKMARK, out is_bookmark, -1);
10+ if (!is_bookmark)
11+ return;
12+
13 var path = store.get_path (iter);
14 var column = tree_view.get_column (0);
15 name_renderer.editable = true;

Subscribers

People subscribed via source and target branches

to all changes: