From owner-freebsd-ports-bugs@FreeBSD.ORG Fri Nov 30 06:50:02 2007 Return-Path: Delivered-To: freebsd-ports-bugs@hub.freebsd.org Received: from mx1.freebsd.org (mx1.freebsd.org [IPv6:2001:4f8:fff6::34]) by hub.freebsd.org (Postfix) with ESMTP id E43B316A420 for ; Fri, 30 Nov 2007 06:50:01 +0000 (UTC) (envelope-from gnats@FreeBSD.org) Received: from freefall.freebsd.org (freefall.freebsd.org [IPv6:2001:4f8:fff6::28]) by mx1.freebsd.org (Postfix) with ESMTP id B12F513C455 for ; Fri, 30 Nov 2007 06:50:01 +0000 (UTC) (envelope-from gnats@FreeBSD.org) Received: from freefall.freebsd.org (gnats@localhost [127.0.0.1]) by freefall.freebsd.org (8.14.2/8.14.2) with ESMTP id lAU6o1Ue029444 for ; Fri, 30 Nov 2007 06:50:01 GMT (envelope-from gnats@freefall.freebsd.org) Received: (from gnats@localhost) by freefall.freebsd.org (8.14.2/8.14.1/Submit) id lAU6o1av029443; Fri, 30 Nov 2007 06:50:01 GMT (envelope-from gnats) Resent-Date: Fri, 30 Nov 2007 06:50:01 GMT Resent-Message-Id: <200711300650.lAU6o1av029443@freefall.freebsd.org> Resent-From: FreeBSD-gnats-submit@FreeBSD.org (GNATS Filer) Resent-To: freebsd-ports-bugs@FreeBSD.org Resent-Reply-To: FreeBSD-gnats-submit@FreeBSD.org, Mehmet Kose Received: from mx1.freebsd.org (mx1.freebsd.org [IPv6:2001:4f8:fff6::34]) by hub.freebsd.org (Postfix) with ESMTP id 8280C16A417 for ; Fri, 30 Nov 2007 06:41:41 +0000 (UTC) (envelope-from nobody@FreeBSD.org) Received: from www.freebsd.org (www.freebsd.org [IPv6:2001:4f8:fff6::21]) by mx1.freebsd.org (Postfix) with ESMTP id 5F42413C4F3 for ; Fri, 30 Nov 2007 06:41:41 +0000 (UTC) (envelope-from nobody@FreeBSD.org) Received: from www.freebsd.org (localhost [127.0.0.1]) by www.freebsd.org (8.14.2/8.14.2) with ESMTP id lAU6fStK077708 for ; Fri, 30 Nov 2007 06:41:28 GMT (envelope-from nobody@www.freebsd.org) Received: (from nobody@localhost) by www.freebsd.org (8.14.2/8.14.1/Submit) id lAU6fSDs077704; Fri, 30 Nov 2007 06:41:28 GMT (envelope-from nobody) Message-Id: <200711300641.lAU6fSDs077704@www.freebsd.org> Date: Fri, 30 Nov 2007 06:41:28 GMT From: Mehmet Kose To: freebsd-gnats-submit@FreeBSD.org X-Send-Pr-Version: www-3.1 Cc: Subject: ports/118345: Nautilus patch for not keeping windows open in spatial mode. X-BeenThere: freebsd-ports-bugs@freebsd.org X-Mailman-Version: 2.1.5 Precedence: list List-Id: Ports bug reports List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , X-List-Received-Date: Fri, 30 Nov 2007 06:50:02 -0000 >Number: 118345 >Category: ports >Synopsis: Nautilus patch for not keeping windows open in spatial mode. >Confidential: no >Severity: non-critical >Priority: low >Responsible: freebsd-ports-bugs >State: open >Quarter: >Keywords: >Date-Required: >Class: change-request >Submitter-Id: current-users >Arrival-Date: Fri Nov 30 06:50:01 UTC 2007 >Closed-Date: >Last-Modified: >Originator: Mehmet Kose >Release: 7.0 Beta 3 >Organization: >Environment: FreeBSD decaf.ev 7.0-BETA3 FreeBSD 7.0-BETA3 #0: Fri Nov 16 22:20:33 UTC 2007 root@logan.cse.buffalo.edu:/usr/obj/usr/src/sys/GENERIC i386 >Description: For someone who likes small windows but don't want to keep them when opening another folder inside, I took this patch taken from Ubuntu. >How-To-Repeat: >Fix: Makefile patch: -OPTIONS= TRACKER "Enable Tracker Search (sysutils/tracker)" Off +OPTIONS= TRACKER "Enable Tracker Search (sysutils/tracker)" Off \ + CLOSEBEHIND "Auto Close Behind Window in Spatial Mode" Off +.if !defined(WITHOUT_CLOSEBEHIND) +EXTRA_PATCHES+= ${PATCHDIR}/xpatch-close_behind +.endif Patch attached with submission follows: --- libnautilus-private/apps_nautilus_preferences.schemas.in.orig 2007-09-18 09:51:48.000000000 +0300 +++ libnautilus-private/apps_nautilus_preferences.schemas.in 2007-11-30 04:11:49.000000000 +0200 @@ -54,6 +54,21 @@ + /schemas/apps/nautilus/preferences/auto_close_behind_window + /apps/nautilus/preferences/auto_close_behind_window + nautilus + bool + true + + Don't keep behind windows open in spatial mode + + If set to true, then Nautilus spatial windows will automatically + closed after opening a folder in them. + + + + + /schemas/apps/nautilus/preferences/always_use_location_entry /apps/nautilus/preferences/always_use_location_entry nautilus --- libnautilus-private/nautilus-global-preferences.c.orig 2007-06-27 10:12:34.000000000 +0300 +++ libnautilus-private/nautilus-global-preferences.c 2007-11-30 04:35:31.000000000 +0200 @@ -262,6 +262,10 @@ PREFERENCE_BOOLEAN, GINT_TO_POINTER (FALSE) }, + { NAUTILUS_PREFERENCES_AUTO_CLOSE_BEHIND_WINDOW, + PREFERENCE_BOOLEAN, + GINT_TO_POINTER (FALSE) + }, { NAUTILUS_PREFERENCES_SHOW_BACKUP_FILES, PREFERENCE_BOOLEAN, GINT_TO_POINTER (FALSE) --- libnautilus-private/nautilus-global-preferences.h.orig 2007-06-27 10:12:34.000000000 +0300 +++ libnautilus-private/nautilus-global-preferences.h 2007-11-30 04:20:42.000000000 +0200 @@ -80,6 +80,9 @@ /* Spatial or browser mode */ #define NAUTILUS_PREFERENCES_ALWAYS_USE_BROWSER "preferences/always_use_browser" +/* Close behind window in spatial mode */ +#define NAUTILUS_PREFERENCES_AUTO_CLOSE_BEHIND_WINDOW "preferences/auto_close_behind_window" + /* Which views should be displayed for new windows */ #define NAUTILUS_PREFERENCES_START_WITH_LOCATION_BAR "preferences/start_with_location_bar" #define NAUTILUS_PREFERENCES_ALWAYS_USE_LOCATION_ENTRY "preferences/always_use_location_entry" --- src/file-manager/fm-directory-view.c.orig 2007-08-27 11:03:57.000000000 +0300 +++ src/file-manager/fm-directory-view.c 2007-11-30 05:00:21.000000000 +0200 @@ -8872,6 +8872,16 @@ parameters->view = view; parameters->files = nautilus_file_list_copy (files); parameters->mode = mode; + + if ( eel_preferences_get_boolean + (NAUTILUS_PREFERENCES_AUTO_CLOSE_BEHIND_WINDOW) && nautilus_file_is_directory (file)) { + if (flags== NAUTILUS_WINDOW_OPEN_FLAG_CLOSE_BEHIND) + flags=0; + else + flags=NAUTILUS_WINDOW_OPEN_FLAG_CLOSE_BEHIND; + } + + parameters->flags = flags; parameters->mount_success = FALSE; parameters->pending_mounts = 0; --- src/nautilus-spatial-window.c.orig 2007-09-10 09:56:43.000000000 +0300 +++ src/nautilus-spatial-window.c 2007-11-30 05:07:53.000000000 +0200 @@ -527,7 +527,10 @@ { close_behind = TRUE; } - nautilus_window_open_location_with_selection (NAUTILUS_WINDOW (window), location, selection, close_behind); + if ( eel_preferences_get_boolean(NAUTILUS_PREFERENCES_AUTO_CLOSE_BEHIND_WINDOW)) + nautilus_window_open_location_with_selection (NAUTILUS_WINDOW (window), location, selection, !close_behind); + else + nautilus_window_open_location_with_selection (NAUTILUS_WINDOW (window), location, selection, close_behind); } if (event != NULL) { >Release-Note: >Audit-Trail: >Unformatted: