Accepting request 408657 from home:VictorYang:branches:GNOME:Factory

Enable eject option on selection menu.(bsc#981950)

OBS-URL: https://build.opensuse.org/request/show/408657
OBS-URL: https://build.opensuse.org/package/show/GNOME:Factory/nautilus?expand=0&rev=250
This commit is contained in:
Dominique Leuenberger 2016-07-19 09:51:25 +00:00 committed by Git OBS Bridge
parent 4ed501ed31
commit f027eba8a1
3 changed files with 28 additions and 1 deletions

View File

@ -0,0 +1,18 @@
diff --git a/src/nautilus-files-view.c b/src/nautilus-files-view.c
index fd4f2f5..a4e62d6 100644
--- a/src/nautilus-files-view.c
+++ b/src/nautilus-files-view.c
@@ -6474,7 +6474,12 @@ real_update_actions_state (NautilusFilesView *view)
can_move_files && !selection_contains_recent);
/* Drive menu */
- show_mount = show_unmount = show_eject = show_start = show_stop = show_detect_media = FALSE;
+ show_mount = (selection != NULL);
+ show_unmount = (selection != NULL);
+ show_eject = (selection != NULL);
+ show_start = (selection != NULL && selection_count == 1);
+ show_stop = (selection != NULL && selection_count == 1);
+ show_detect_media = (selection != NULL && selection_count == 1);
for (l = selection; l != NULL && (show_mount || show_unmount
|| show_eject
|| show_start || show_stop

View File

@ -1,3 +1,9 @@
-------------------------------------------------------------------
Fri Jul 15 09:05:18 UTC 2016 - tyang@suse.com
- Add nautilus-enable-eject-option-on-selection-menu.patch
Enable eject option on selection menu.(bsc#981950)
-------------------------------------------------------------------
Mon Jun 20 20:18:18 UTC 2016 - mgorse@suse.com

View File

@ -1,7 +1,7 @@
#
# spec file for package nautilus
#
# Copyright (c) 2016 SUSE LINUX GmbH, Nuernberg, Germany.
# Copyright (c) 2016 SUSE LINUX Products GmbH, Nuernberg, Germany.
#
# All modifications and additions to the file contributed by third parties
# remain the property of their copyright owners, unless otherwise agreed
@ -30,6 +30,8 @@ Source99: baselibs.conf
Patch0: nautilus-adjust-style-priority.patch
# PATCH-FIX-UPSTREAM nautilus-bsc979947.patch bsc#979947 bgo#767878 mgorse@suse.com -- only write zoom level to user configuration if the user has adjusted it.
Patch1: nautilus-bsc979947.patch
# PATCH-FIX-SLE nautilus-enable-eject-option-on-selection-menu.patch bsc#981950 tyang@suse.com -- Enable eject option on selection menu
Patch2: nautilus-enable-eject-option-on-selection-menu.patch
Url: http://www.gnome.org
BuildRoot: %{_tmppath}/%{name}-%{version}-build
# needed for directory ownership
@ -114,6 +116,7 @@ This package contains development files for nautilus.
%setup -q
%patch0 -p1
%patch1 -p1
%patch2 -p1
translation-update-upstream
%build