Commit e6507ad5 authored by Michael Natterer's avatar Michael Natterer 😴 Committed by Michael Natterer
Browse files

enabled passing of file: URIs as command line parameters.

2003-06-23  Michael Natterer  <mitch@gimp.org>

	* app/app_procs.c (app_init): enabled passing of file: URIs
	as command line parameters.
parent badb8c25
2003-06-23 Michael Natterer <mitch@gimp.org>
* app/app_procs.c (app_init): enabled passing of file: URIs
as command line parameters.
2003-06-23 Sven Neumann <sven@gimp.org>
 
* INSTALL
......@@ -280,8 +280,19 @@ app_init (gint gimp_argc,
GError *error = NULL;
gchar *uri;
uri = file_utils_filename_to_uri (the_gimp->load_procs,
gimp_argv[i], &error);
/* first try if we got a file uri */
uri = g_filename_from_uri (gimp_argv[i], NULL, NULL);
if (uri)
{
g_free (uri);
uri = g_strdup (gimp_argv[i]);
}
else
{
uri = file_utils_filename_to_uri (the_gimp->load_procs,
gimp_argv[i], &error);
}
if (! uri)
{
......@@ -303,7 +314,7 @@ app_init (gint gimp_argc,
filename = file_utils_uri_to_utf8_filename (uri);
g_message (_("Opening '%s' failed:\n\n%s"),
g_message (_("Opening '%s' failed:\n%s"),
filename, error->message);
g_clear_error (&error);
......
Markdown is supported
0% or .
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment