Kill start-here.

2004-07-16  Alexander Larsson  <alexl@redhat.com>

	* data/Makefile.am:
	* data/preferences.desktop.in:
	* data/serverconfig.desktop.in:
	* data/serverconfig.directory.in:
	* data/starthere-link.desktop.in:
	* data/starthere.desktop.in:
	* data/starthere.directory.in:
	* data/sysconfig.desktop.in:
	* data/sysconfig.directory.in:
	* src/nautilus-application.c: (nautilus_application_startup),
	(desktop_changed_callback):
	* src/nautilus-window-menus.c:
	(nautilus_window_initialize_menus_part_1):

	Kill start-here.
This commit is contained in:
Alexander Larsson 2004-07-16 15:01:59 +00:00 committed by Alexander Larsson
parent e3fb33bfdd
commit 4459a08b7a
12 changed files with 18 additions and 193 deletions

View file

@ -1,3 +1,21 @@
2004-07-16 Alexander Larsson <alexl@redhat.com>
* data/Makefile.am:
* data/preferences.desktop.in:
* data/serverconfig.desktop.in:
* data/serverconfig.directory.in:
* data/starthere-link.desktop.in:
* data/starthere.desktop.in:
* data/starthere.directory.in:
* data/sysconfig.desktop.in:
* data/sysconfig.directory.in:
* src/nautilus-application.c: (nautilus_application_startup),
(desktop_changed_callback):
* src/nautilus-window-menus.c:
(nautilus_window_initialize_menus_part_1):
Kill start-here.
2004-07-15 Jürg Billeter <j@bitron.ch>
* libnautilus-private/apps_nautilus_preferences.schemas.in:

View file

@ -1,31 +1,5 @@
NULL=
@INTLTOOL_DESKTOP_RULE@
@INTLTOOL_DIRECTORY_RULE@
DESKTOP_IN_FILES= applications.desktop.in \
starthere.desktop.in \
sysconfig.desktop.in \
preferences.desktop.in \
serverconfig.desktop.in \
starthere-link.desktop.in \
$(NULL)
DIRECTORY_IN_FILES= serverconfig.directory.in \
starthere.directory.in \
sysconfig.directory.in \
$(NULL)
DESKTOP_FILES=$(DESKTOP_IN_FILES:.desktop.in=.desktop)
DIRECTORY_FILES=$(DIRECTORY_IN_FILES:.directory.in=.directory)
startheredir= $(sysconfdir)/X11/starthere
starthere_DATA= applications.desktop \
sysconfig.desktop \
preferences.desktop \
serverconfig.desktop \
$(NULL)
nautilusdatadir = $(datadir)/nautilus
nautilusdata_DATA = \
@ -33,25 +7,11 @@ nautilusdata_DATA = \
static_bookmarks.xml \
nautilus-extras.placeholder \
nautilus-suggested.placeholder \
starthere.desktop \
starthere-link.desktop \
$(NULL)
EXTRA_DIST = $(nautilusdata_DATA) \
$(DESKTOP_IN_FILES) \
$(DESKTOP_FILES) \
$(DIRECTORY_IN_FILES) \
$(DIRECTORY_FILES) \
$(NULL)
SUBDIRS = \
patterns \
$(NULL)
install-data-local: $(DIRECTORY_FILES)
$(mkinstalldirs) $(DESTDIR)$(sysconfdir)/X11/starthere
$(mkinstalldirs) $(DESTDIR)$(sysconfdir)/X11/sysconfig
$(mkinstalldirs) $(DESTDIR)$(sysconfdir)/X11/serverconfig
$(INSTALL_DATA) starthere.directory $(DESTDIR)$(sysconfdir)/X11/starthere/.directory
$(INSTALL_DATA) sysconfig.directory $(DESTDIR)$(sysconfdir)/X11/sysconfig/.directory
$(INSTALL_DATA) serverconfig.directory $(DESTDIR)$(sysconfdir)/X11/serverconfig/.directory

View file

@ -1,8 +0,0 @@
[Desktop Entry]
Encoding=UTF-8
Type=Link
_Name=Desktop Preferences
_Comment=Adjust your user environment
URL=preferences:///
Icon=gnome-desktop-config
Terminal=false

View file

@ -1,8 +0,0 @@
[Desktop Entry]
Encoding=UTF-8
Type=Link
_Name=Server Settings
_Comment=Configure network services (web server, DNS server, etc.)
URL=server-settings:
Icon=gnome-server-config
Terminal=false

View file

@ -1,5 +0,0 @@
[Desktop Entry]
_Name=Server Settings
_Comment=Configure network services
Icon=gnome-server-config
Type=Directory

View file

@ -1,8 +0,0 @@
[Desktop Entry]
Encoding=UTF-8
Type=Link
_Name=Start Here
_Comment=Start Here
URL=start-here:
Icon=gnome-starthere
Terminal=false

View file

@ -1,9 +0,0 @@
[Desktop Entry]
Encoding=UTF-8
_Name=Start Here
_Comment=Start Here
Exec=nautilus start-here:
Icon=gnome-starthere
X-Nautilus-Icon=gnome-starthere
Terminal=false
Type=Application

View file

@ -1,5 +0,0 @@
[Desktop Entry]
_Name=Start Here
_Comment=Start Here
Icon=gnome-starthere
Type=Directory

View file

@ -1,8 +0,0 @@
[Desktop Entry]
Encoding=UTF-8
Type=Link
_Name=System Settings
_Comment=Change systemwide settings (affects all users)
URL=system-settings:
Icon=gnome-system-config
Terminal=false

View file

@ -1,5 +0,0 @@
[Desktop Entry]
_Name=System Settings
_Comment=Change systemwide settings (affects all users)
Icon=gnome-system-config
Type=Directory

View file

@ -100,7 +100,6 @@ static GList *nautilus_application_window_list;
/* Keeps track of all the object windows */
static GList *nautilus_application_spatial_window_list;
static gboolean need_to_show_first_time_druid (void);
static void desktop_changed_callback (gpointer user_data);
static void desktop_location_changed_callback (gpointer user_data);
static void volume_unmounted_callback (GnomeVFSVolumeMonitor *monitor,
@ -368,36 +367,6 @@ migrate_old_nautilus_files (void)
g_free (migrated_file);
}
static gint
create_starthere_link_callback (gpointer data)
{
char *desktop_path;
char *desktop_link_file;
char *cmd;
/* Create default services icon on the desktop */
desktop_path = nautilus_get_desktop_directory ();
desktop_link_file = g_build_filename (desktop_path,
"starthere.desktop",
NULL);
cmd = g_strconcat ("/bin/cp ",
NAUTILUS_DATADIR,
"/starthere-link.desktop ",
desktop_link_file,
NULL);
if (system (cmd) != 0) {
g_warning ("Failed to execute command '%s'\n", cmd);
}
g_free (desktop_path);
g_free (desktop_link_file);
g_free (cmd);
return FALSE;
}
static void
finish_startup (NautilusApplication *application)
{
@ -504,16 +473,6 @@ nautilus_application_startup (NautilusApplication *application,
return;
}
/* Run the first time startup druid if needed. */
if (do_first_time_druid_check && need_to_show_first_time_druid ()) {
/* Do this at idle time, once nautilus has initialized
* itself. Otherwise we may spawn a second nautilus
* process when looking for a metadata factory..
*/
g_idle_add (create_starthere_link_callback, NULL);
nautilus_set_first_time_file_flag ();
}
initialize_kde_trash_hack ();
CORBA_exception_init (&ev);
@ -1104,51 +1063,6 @@ desktop_changed_callback (gpointer user_data)
update_session (gnome_master_client ());
}
/*
* need_to_show_first_time_druid
*
* Determine whether Nautilus needs to show the first time druid.
*
* Note that the flag file indicating whether the druid has been
* presented is: ~/.nautilus/first-time-flag.
*
* Another alternative could be to use preferences to store this flag
* However, there because of bug 41229 this is not yet possible.
*
* Also, for debugging purposes, it is convenient to have just one file
* to kill in order to test the startup druid:
*
* rm -f ~/.nautilus/first-time-flag
*
* In order to accomplish the same thing with preferences, you would have
* to either kill ALL your preferences or spend time digging in ~/.gconf
* xml files finding the right one.
*/
static gboolean
need_to_show_first_time_druid (void)
{
gboolean result;
char *user_directory;
char *druid_flag_file_name;
user_directory = nautilus_get_user_directory ();
druid_flag_file_name = g_strconcat (user_directory, "/first-time-flag", NULL);
result = !g_file_test (druid_flag_file_name, G_FILE_TEST_EXISTS);
g_free (druid_flag_file_name);
/* we changed the name of the flag for version 1.0, so we should
* check for and delete the old one, if the new one didn't exist
*/
if (result) {
druid_flag_file_name = g_strconcat (user_directory, "/first-time-wizard-flag", NULL);
unlink (druid_flag_file_name);
g_free (druid_flag_file_name);
}
g_free (user_directory);
return result;
}
static gboolean
window_can_be_closed (NautilusWindow *window)
{

View file

@ -96,7 +96,6 @@
#define ID_SHOW_HIDE_LOCATION_BAR "Show Hide Location Bar"
#define ID_SHOW_HIDE_STATUS_BAR "Show Hide Statusbar"
#define START_HERE_URI "start-here:"
#define COMPUTER_URI "computer:"
#define BURN_CD_URI "burn:"
@ -361,15 +360,6 @@ go_menu_home_callback (BonoboUIComponent *component,
nautilus_window_go_home (NAUTILUS_WINDOW (user_data));
}
static void
go_menu_start_here_callback (BonoboUIComponent *component,
gpointer user_data,
const char *verb)
{
nautilus_window_go_to (NAUTILUS_WINDOW (user_data),
START_HERE_URI);
}
static void
go_menu_go_to_computer_callback (BonoboUIComponent *component,
gpointer user_data,
@ -677,7 +667,6 @@ nautilus_window_initialize_menus_part_1 (NautilusWindow *window)
BONOBO_UI_VERB ("Backgrounds and Emblems", backgrounds_and_emblems_callback),
BONOBO_UI_VERB ("Up", go_menu_up_callback),
BONOBO_UI_VERB ("Home", go_menu_home_callback),
BONOBO_UI_VERB ("Start Here", go_menu_start_here_callback),
BONOBO_UI_VERB ("Go to Computer", go_menu_go_to_computer_callback),
BONOBO_UI_VERB ("Go to Templates", go_menu_go_to_templates_callback),
BONOBO_UI_VERB ("Go to Trash", go_menu_go_to_trash_callback),