diff options
author | Martin Wehner <martin.wehner@epost.de> | 2005-02-06 15:48:08 +0000 |
---|---|---|
committer | Martin Wehner <mwehner@src.gnome.org> | 2005-02-06 15:48:08 +0000 |
commit | 3f7cb1df7e17546ba8dd7d36e68c031d59ea2323 (patch) | |
tree | a3fdd5439e6ad8b2c4b2ec92a1f4310c8663ae79 /libnautilus-private | |
parent | 2393abd153749e1b27494f50e9e38dea02c93e75 (diff) | |
download | nautilus-3f7cb1df7e17546ba8dd7d36e68c031d59ea2323.tar.gz |
Use new gnome_desktop_item_set_launch_time() API. (#166334)
2005-02-06 Martin Wehner <martin.wehner@epost.de>
* libnautilus-private/nautilus-program-choosing.c:
(slowly_and_stupidly_obtain_timestamp),
(nautilus_launch_show_file), (nautilus_launch_application),
(nautilus_launch_desktop_file):
Use new gnome_desktop_item_set_launch_time() API. (#166334)
* configure.in:
Require gnome-desktop 2.9.91
Patch from Elijah Newren <newren@gmail.com>
Diffstat (limited to 'libnautilus-private')
-rw-r--r-- | libnautilus-private/nautilus-program-choosing.c | 13 |
1 files changed, 7 insertions, 6 deletions
diff --git a/libnautilus-private/nautilus-program-choosing.c b/libnautilus-private/nautilus-program-choosing.c index b47d08902..ab6d9dc89 100644 --- a/libnautilus-private/nautilus-program-choosing.c +++ b/libnautilus-private/nautilus-program-choosing.c @@ -366,14 +366,11 @@ add_startup_timeout (GdkScreen *screen, * this should not be needed. */ static Time -slowly_and_stupidly_obtain_timestamp (SnDisplay *display) +slowly_and_stupidly_obtain_timestamp (Display *xdisplay) { Window xwindow; - Display *xdisplay; XEvent event; - xdisplay = sn_display_get_x_display (display); - { XSetWindowAttributes attrs; Atom atom_name; @@ -511,7 +508,7 @@ void nautilus_launch_show_file (NautilusFile *file, char **old_envp; Time timestamp; - timestamp = slowly_and_stupidly_obtain_timestamp (sn_display); + timestamp = slowly_and_stupidly_obtain_timestamp (GDK_WINDOW_XDISPLAY (GTK_WIDGET (parent_window)->window)); binary_name = gnome_vfs_mime_application_get_binary_name (application); @@ -742,7 +739,7 @@ nautilus_launch_application (GnomeVFSMimeApplication *application, char **old_envp; Time timestamp; - timestamp = slowly_and_stupidly_obtain_timestamp (sn_display); + timestamp = slowly_and_stupidly_obtain_timestamp (GDK_WINDOW_XDISPLAY (GTK_WIDGET (parent_window)->window)); binary_name = gnome_vfs_mime_application_get_binary_name (application); @@ -858,6 +855,7 @@ nautilus_launch_desktop_file (GdkScreen *screen, const GList *p; int total, count; char **envp; + Time timestamp; /* strip the leading command specifier */ if (eel_str_has_prefix (desktop_file_uri, NAUTILUS_DESKTOP_COMMAND_SPECIFIER)) { @@ -947,6 +945,9 @@ nautilus_launch_desktop_file (GdkScreen *screen, } error = NULL; + + timestamp = slowly_and_stupidly_obtain_timestamp (GDK_WINDOW_XDISPLAY (GTK_WIDGET (parent_window)->window)); + gnome_desktop_item_set_launch_time (ditem, timestamp); gnome_desktop_item_launch_with_env (ditem, (GList *) parameter_uris, flags, envp, &error); |