Changeset 14143
- Timestamp:
- Jul 24, 2013, 5:11:21 PM (9 years ago)
- File:
-
- 1 edited
Legend:
- Unmodified
- Added
- Removed
-
trunk/gtk/util.c
r14142 r14143 362 362 gtr_open_file (const char * path) 363 363 { 364 char * uri; 365 366 if (g_path_is_absolute (path)) 367 { 368 uri = g_strdup_printf ("file://%s", path); 369 } 370 else 371 { 372 char * cwd = g_get_current_dir (); 373 uri = g_strdup_printf ("file://%s/%s", cwd, path); 374 g_free (cwd); 375 } 376 364 GFile * file = g_file_new_for_path (path); 365 gchar * uri = g_file_get_uri (file); 377 366 gtr_open_uri (uri); 378 367 g_free (uri); 368 g_object_unref (file); 379 369 } 380 370
Note: See TracChangeset
for help on using the changeset viewer.