[nautilus/wip/apoos-maximus/gsoc2020: 20/29] properties-window: Stop setting "inconsistent_string" data
- From: António Fernandes <antoniof src gnome org>
- To: commits-list gnome org
- Cc:
- Subject: [nautilus/wip/apoos-maximus/gsoc2020: 20/29] properties-window: Stop setting "inconsistent_string" data
- Date: Wed, 5 Aug 2020 13:48:12 +0000 (UTC)
commit 7073050b80e205447898fa8154c1cb95fabbca26
Author: Apoorv Sachan <apoorv 99 sachan gmail com>
Date: Sat Jul 11 00:49:35 2020 +0530
properties-window: Stop setting "inconsistent_string" data
This is always the same for all labels, so there is no point.
src/nautilus-properties-window.c | 47 ++++------------------------------------
1 file changed, 4 insertions(+), 43 deletions(-)
---
diff --git a/src/nautilus-properties-window.c b/src/nautilus-properties-window.c
index 84c848cb7..301783ae4 100644
--- a/src/nautilus-properties-window.c
+++ b/src/nautilus-properties-window.c
@@ -1341,6 +1341,9 @@ file_list_all_directories (GList *file_list)
return TRUE;
}
+#define INCONSISTENT_STATE_STRING \
+ "\xE2\x80\x92"
+
static void
value_field_update_internal (GtkLabel *label,
GList *file_list)
@@ -1353,7 +1356,7 @@ value_field_update_internal (GtkLabel *label,
g_assert (GTK_IS_LABEL (label));
attribute_name = g_object_get_data (G_OBJECT (label), "file_attribute");
- inconsistent_string = g_object_get_data (G_OBJECT (label), "inconsistent_string");
+ inconsistent_string = INCONSISTENT_STATE_STRING;
attribute_value = file_list_get_string_attribute (file_list,
attribute_name,
inconsistent_string);
@@ -2257,9 +2260,6 @@ schedule_directory_contents_update (NautilusPropertiesWindow *window)
}
}
-#define INCONSISTENT_STATE_STRING \
- "\xE2\x80\x92"
-
static void
setup_contents_field (NautilusPropertiesWindow *window,
GtkGrid *grid)
@@ -2790,9 +2790,6 @@ setup_basic_page (NautilusPropertiesWindow *window)
g_object_set_data_full (G_OBJECT (window->type_value_label), "file_attribute",
g_strdup ("detailed_type"), g_free);
- g_object_set_data_full (G_OBJECT (window->type_value_label), "inconsistent_string",
- g_strdup (INCONSISTENT_STATE_STRING), g_free);
-
g_object_set_data (G_OBJECT (window->type_value_label), "show_original", GINT_TO_POINTER (FALSE));
window->value_fields = g_list_prepend (window->value_fields,
@@ -2806,9 +2803,6 @@ setup_basic_page (NautilusPropertiesWindow *window)
g_object_set_data_full (G_OBJECT (window->link_target_value_label), "file_attribute",
g_strdup ("link_target"), g_free);
- g_object_set_data_full (G_OBJECT (window->link_target_value_label), "inconsistent_string",
- g_strdup (INCONSISTENT_STATE_STRING), g_free);
-
g_object_set_data (G_OBJECT (window->link_target_value_label), "show_original", GINT_TO_POINTER
(FALSE));
window->value_fields = g_list_prepend (window->value_fields,
@@ -2831,9 +2825,6 @@ setup_basic_page (NautilusPropertiesWindow *window)
g_object_set_data_full (G_OBJECT (window->size_value_label), "file_attribute",
g_strdup ("size_detail"), g_free);
- g_object_set_data_full (G_OBJECT (window->size_value_label), "inconsistent_string",
- g_strdup (INCONSISTENT_STATE_STRING), g_free);
-
g_object_set_data (G_OBJECT (window->size_value_label), "show_original", GINT_TO_POINTER (FALSE));
window->value_fields = g_list_prepend (window->value_fields,
@@ -2848,9 +2839,6 @@ setup_basic_page (NautilusPropertiesWindow *window)
g_object_set_data_full (G_OBJECT (window->parent_folder_value_label), "file_attribute",
g_strdup ("where"), g_free);
- g_object_set_data_full (G_OBJECT (window->parent_folder_value_label), "inconsistent_string",
- g_strdup (INCONSISTENT_STATE_STRING), g_free);
-
g_object_set_data (G_OBJECT (window->parent_folder_value_label), "show_original", GINT_TO_POINTER
(location_show_original (window)));
window->value_fields = g_list_prepend (window->value_fields,
@@ -2864,9 +2852,6 @@ setup_basic_page (NautilusPropertiesWindow *window)
g_object_set_data_full (G_OBJECT (window->original_folder_value_label), "file_attribute",
g_strdup ("trash_orig_path"), g_free);
- g_object_set_data_full (G_OBJECT (window->original_folder_value_label), "inconsistent_string",
- g_strdup (INCONSISTENT_STATE_STRING), g_free);
-
g_object_set_data (G_OBJECT (window->original_folder_value_label), "show_original", GINT_TO_POINTER
(FALSE));
window->value_fields = g_list_prepend (window->value_fields,
@@ -2880,9 +2865,6 @@ setup_basic_page (NautilusPropertiesWindow *window)
g_object_set_data_full (G_OBJECT (window->volume_value_label), "file_attribute",
g_strdup ("volume"), g_free);
- g_object_set_data_full (G_OBJECT (window->volume_value_label), "inconsistent_string",
- g_strdup (INCONSISTENT_STATE_STRING), g_free);
-
g_object_set_data (G_OBJECT (window->volume_value_label), "show_original", GINT_TO_POINTER (FALSE));
window->value_fields = g_list_prepend (window->value_fields,
@@ -2896,9 +2878,6 @@ setup_basic_page (NautilusPropertiesWindow *window)
g_object_set_data_full (G_OBJECT (window->trashed_on_value_label), "file_attribute",
g_strdup ("trashed_on_full"), g_free);
- g_object_set_data_full (G_OBJECT (window->trashed_on_value_label), "inconsistent_string",
- g_strdup (INCONSISTENT_STATE_STRING), g_free);
-
g_object_set_data (G_OBJECT (window->trashed_on_value_label), "show_original", GINT_TO_POINTER
(FALSE));
window->value_fields = g_list_prepend (window->value_fields,
@@ -2919,9 +2898,6 @@ setup_basic_page (NautilusPropertiesWindow *window)
g_object_set_data_full (G_OBJECT (window->accessed_value_label), "file_attribute",
g_strdup ("date_accessed_full"), g_free);
- g_object_set_data_full (G_OBJECT (window->accessed_value_label), "inconsistent_string",
- g_strdup (INCONSISTENT_STATE_STRING), g_free);
-
g_object_set_data (G_OBJECT (window->accessed_value_label), "show_original", GINT_TO_POINTER
(FALSE));
window->value_fields = g_list_prepend (window->value_fields,
@@ -2936,9 +2912,6 @@ setup_basic_page (NautilusPropertiesWindow *window)
g_object_set_data_full (G_OBJECT (window->modified_value_label), "file_attribute",
g_strdup ("date_modified_full"), g_free);
- g_object_set_data_full (G_OBJECT (window->modified_value_label), "inconsistent_string",
- g_strdup (INCONSISTENT_STATE_STRING), g_free);
-
g_object_set_data (G_OBJECT (window->modified_value_label), "show_original", GINT_TO_POINTER
(FALSE));
window->value_fields = g_list_prepend (window->value_fields,
@@ -2956,9 +2929,6 @@ setup_basic_page (NautilusPropertiesWindow *window)
g_object_set_data_full (G_OBJECT (window->free_space_value_label), "file_attribute",
g_strdup ("free_space"), g_free);
- g_object_set_data_full (G_OBJECT (window->free_space_value_label), "inconsistent_string",
- g_strdup (INCONSISTENT_STATE_STRING), g_free);
-
g_object_set_data (G_OBJECT (window->free_space_value_label), "show_original", GINT_TO_POINTER
(FALSE));
window->value_fields = g_list_prepend (window->value_fields,
@@ -3929,9 +3899,6 @@ create_simple_permissions (NautilusPropertiesWindow *window,
g_object_set_data_full (G_OBJECT (owner_value_label), "file_attribute",
g_strdup ("owner"), g_free);
- g_object_set_data_full (G_OBJECT (owner_value_label), "inconsistent_string",
- g_strdup (INCONSISTENT_STATE_STRING), g_free);
-
g_object_set_data (G_OBJECT (owner_value_label), "show_original", GINT_TO_POINTER (FALSE));
window->value_fields = g_list_prepend (window->value_fields,
@@ -3982,9 +3949,6 @@ create_simple_permissions (NautilusPropertiesWindow *window,
g_object_set_data_full (G_OBJECT (group_value_label), "file_attribute",
g_strdup ("group"), g_free);
- g_object_set_data_full (G_OBJECT (group_value_label), "inconsistent_string",
- g_strdup (INCONSISTENT_STATE_STRING), g_free);
-
g_object_set_data (G_OBJECT (group_value_label), "show_original", GINT_TO_POINTER (FALSE));
window->value_fields = g_list_prepend (window->value_fields,
@@ -4358,9 +4322,6 @@ setup_permissions_page (NautilusPropertiesWindow *window)
g_object_set_data_full (G_OBJECT (window->security_context_value_label), "file_attribute",
g_strdup ("selinux_context"), g_free);
- g_object_set_data_full (G_OBJECT (window->security_context_value_label), "inconsistent_string",
- g_strdup (INCONSISTENT_STATE_STRING), g_free);
-
g_object_set_data (G_OBJECT (window->security_context_value_label), "show_original", GINT_TO_POINTER
(FALSE));
window->value_fields = g_list_prepend (window->value_fields,
[
Date Prev][
Date Next] [
Thread Prev][
Thread Next]
[
Thread Index]
[
Date Index]
[
Author Index]