summaryrefslogtreecommitdiff
diff options
context:
space:
mode:
authorlukefromdc <[email protected]>2023-08-23 22:30:14 -0400
committerraveit65 <[email protected]>2023-08-24 10:12:50 +0200
commit1096ea06a10a68071ae304727a81a73375bfcee4 (patch)
tree8b535d3bc074b448b2a19e33dcd695b5d12a8afc
parent4168605da2fb85f2440e1c223f530d0b831ffdb9 (diff)
downloadcaja-1096ea06a10a68071ae304727a81a73375bfcee4.tar.bz2
caja-1096ea06a10a68071ae304727a81a73375bfcee4.tar.xz
fix gfile sort and symlink warnings w glib2.76 or later
*Use code borrowed from Nemo
-rw-r--r--libcaja-private/caja-directory-async.c2
-rw-r--r--libcaja-private/caja-file.c5
2 files changed, 4 insertions, 3 deletions
diff --git a/libcaja-private/caja-directory-async.c b/libcaja-private/caja-directory-async.c
index 885fe492..84e17d4a 100644
--- a/libcaja-private/caja-directory-async.c
+++ b/libcaja-private/caja-directory-async.c
@@ -3807,7 +3807,7 @@ static gboolean is_trusted_system_desktop_file (GFile *file)
return FALSE;
}
- target = g_file_info_get_symlink_target (info);
+ target = g_file_info_get_attribute_byte_string (info, G_FILE_ATTRIBUTE_STANDARD_SYMLINK_TARGET);
if (!target) {
goto done;
}
diff --git a/libcaja-private/caja-file.c b/libcaja-private/caja-file.c
index 6d07b24a..faa7bb50 100644
--- a/libcaja-private/caja-file.c
+++ b/libcaja-private/caja-file.c
@@ -2396,7 +2396,7 @@ update_info_internal (CajaFile *file,
}
file->details->size_on_disk = size_on_disk;
- sort_order = g_file_info_get_sort_order (info);
+ sort_order = g_file_info_get_attribute_int32 (info, G_FILE_ATTRIBUTE_STANDARD_SORT_ORDER);
if (file->details->sort_order != sort_order) {
changed = TRUE;
}
@@ -2451,7 +2451,8 @@ update_info_internal (CajaFile *file,
file->details->thumbnailing_failed = (thumbnailing_failed != FALSE);
}
- symlink_name = g_file_info_get_symlink_target (info);
+ symlink_name = g_file_info_get_attribute_byte_string (info, G_FILE_ATTRIBUTE_STANDARD_SYMLINK_TARGET);
+
if (eel_strcmp (file->details->symlink_name, symlink_name) != 0) {
changed = TRUE;
g_free (file->details->symlink_name);