~ubuntu-branches/ubuntu/intrepid/gedit/intrepid-proposed

« back to all changes in this revision

Viewing changes to gedit/gedit-utils.c

  • Committer: Bazaar Package Importer
  • Author(s): Sebastien Bacher
  • Date: 2008-09-08 21:33:44 UTC
  • mfrom: (1.1.48 upstream)
  • Revision ID: james.westby@ubuntu.com-20080908213344-eiv4gvnuily7unti
Tags: 2.23.92-0ubuntu1
* New upstream version:
  - Bugfixes related to the gio port (lp: #236953, #262007)

Show diffs side-by-side

added added

removed removed

Lines of Context:
27
27
 * list of people on the gedit Team.  
28
28
 * See the ChangeLog files for a list of changes. 
29
29
 *
30
 
 * $Id: gedit-utils.c 6379 2008-08-10 16:40:21Z pborelli $
 
30
 * $Id: gedit-utils.c 6498 2008-09-07 13:50:57Z pborelli $
31
31
 */
32
32
 
33
33
#ifdef HAVE_CONFIG_H
549
549
                        GTK_DIALOG_MODAL | GTK_DIALOG_DESTROY_WITH_PARENT,
550
550
                        GTK_MESSAGE_ERROR,
551
551
                        GTK_BUTTONS_OK,
552
 
                        str);
 
552
                        "%s", str);
553
553
 
554
554
        g_free (str);
555
 
        
 
555
 
556
556
        if (wg != NULL)
557
557
                gtk_window_group_add_window (wg, GTK_WINDOW (dialog));
558
558
                
1264
1264
 * Filter, modify, unescape and change @uri to make it appropriate
1265
1265
 * for display to users.
1266
1266
 * 
1267
 
 * Rules:
1268
 
 * <ul>
1269
 
 * <li>file: uri without fragments should appear as local paths.</li>
1270
 
 * <li>file: uri with fragments should appear as file:uri.</li>
1271
 
 * <li>All other uri appear as expected.</li>
1272
 
 * </ul>
1273
 
 *
1274
1267
 * This function is a convenient wrapper for g_file_get_parse_name
1275
1268
 *
1276
1269
 * Return value: a string which represents @uri and can be displayed.
1280
1273
{
1281
1274
        GFile *gfile;
1282
1275
        gchar *parse_name;
1283
 
        gchar *unescape;
1284
 
        
 
1276
 
1285
1277
        gfile = g_file_new_for_uri (uri);
1286
 
        
1287
1278
        parse_name = g_file_get_parse_name (gfile);
1288
 
        unescape = g_uri_unescape_string (parse_name, NULL);
1289
 
        g_free (parse_name);
1290
 
        
1291
1279
        g_object_unref (gfile);
1292
 
        return unescape;
 
1280
 
 
1281
        return parse_name;
1293
1282
}
1294
1283
 
1295
1284
/**