[nautilus] Revert "Add support for a column that combines atime and mtime"
- From: Cosimo Cecchi <cosimoc src gnome org>
- To: commits-list gnome org
- Cc:
- Subject: [nautilus] Revert "Add support for a column that combines atime and mtime"
- Date: Tue, 31 Jul 2012 15:02:52 +0000 (UTC)
commit 60a191a9004c58310882fcd8981d254b16f6e837
Author: Cosimo Cecchi <cosimoc gnome org>
Date: Tue Jul 31 16:15:45 2012 +0200
Revert "Add support for a column that combines atime and mtime"
Unfortunately we can't really support this right now, as the atime we
retrieve is mostly a lie.
This reverts commit 85a1b463bfb89c79064059cd3fbaeeeb8775ba89.
libnautilus-private/nautilus-column-utilities.c | 10 ------
libnautilus-private/nautilus-file.c | 35 +------------------
libnautilus-private/nautilus-file.h | 2 -
libnautilus-private/nautilus-vfs-file.c | 10 ------
.../org.gnome.nautilus.gschema.xml.in | 4 +-
5 files changed, 4 insertions(+), 57 deletions(-)
---
diff --git a/libnautilus-private/nautilus-column-utilities.c b/libnautilus-private/nautilus-column-utilities.c
index 2f24fbe..757f777 100644
--- a/libnautilus-private/nautilus-column-utilities.c
+++ b/libnautilus-private/nautilus-column-utilities.c
@@ -35,7 +35,6 @@ static const char *default_column_order[] = {
"name",
"size",
"type",
- "date_used",
"date_modified",
"date_accessed",
"owner",
@@ -77,15 +76,6 @@ get_builtin_columns (void)
NULL));
columns = g_list_append (columns,
g_object_new (NAUTILUS_TYPE_COLUMN,
- "name", "date_used",
- "attribute", "date_used",
- "label", _("Used"),
- "description", _("The date the file was last used."),
- "default-sort-order", GTK_SORT_DESCENDING,
- NULL));
-
- columns = g_list_append (columns,
- g_object_new (NAUTILUS_TYPE_COLUMN,
"name", "date_modified",
"attribute", "date_modified",
"label", _("Modified"),
diff --git a/libnautilus-private/nautilus-file.c b/libnautilus-private/nautilus-file.c
index 71b1fef..1721c68 100644
--- a/libnautilus-private/nautilus-file.c
+++ b/libnautilus-private/nautilus-file.c
@@ -124,9 +124,6 @@ static GQuark attribute_name_q,
attribute_accessed_date_q,
attribute_date_accessed_q,
attribute_date_accessed_full_q,
- attribute_used_date_q,
- attribute_date_used_q,
- attribute_date_used_full_q,
attribute_mime_type_q,
attribute_size_detail_q,
attribute_deep_size_q,
@@ -2723,9 +2720,6 @@ get_time (NautilusFile *file,
case NAUTILUS_DATE_TYPE_ACCESSED:
time = file->details->atime;
break;
- case NAUTILUS_DATE_TYPE_USED:
- time = MAX (file->details->atime, file->details->mtime);
- break;
case NAUTILUS_DATE_TYPE_TRASHED:
time = file->details->trash_time;
break;
@@ -3153,12 +3147,6 @@ nautilus_file_compare_for_sort (NautilusFile *file_1,
result = compare_by_full_path (file_1, file_2);
}
break;
- case NAUTILUS_FILE_SORT_BY_USED_TIME:
- result = compare_by_time (file_1, file_2, NAUTILUS_DATE_TYPE_USED);
- if (result == 0) {
- result = compare_by_full_path (file_1, file_2);
- }
- break;
case NAUTILUS_FILE_SORT_BY_TRASHED_TIME:
result = compare_by_time (file_1, file_2, NAUTILUS_DATE_TYPE_TRASHED);
if (result == 0) {
@@ -3218,11 +3206,6 @@ nautilus_file_compare_for_sort_by_attribute_q (NautilusFile
NAUTILUS_FILE_SORT_BY_ATIME,
directories_first,
reversed);
- } else if (attribute == attribute_used_date_q || attribute == attribute_date_used_q || attribute == attribute_date_used_full_q) {
- return nautilus_file_compare_for_sort (file_1, file_2,
- NAUTILUS_FILE_SORT_BY_ATIME,
- directories_first,
- reversed);
} else if (attribute == attribute_trashed_on_q || attribute == attribute_trashed_on_full_q) {
return nautilus_file_compare_for_sort (file_1, file_2,
NAUTILUS_FILE_SORT_BY_TRASHED_TIME,
@@ -4315,7 +4298,6 @@ nautilus_file_get_date (NautilusFile *file,
g_return_val_if_fail (date_type == NAUTILUS_DATE_TYPE_CHANGED
|| date_type == NAUTILUS_DATE_TYPE_ACCESSED
|| date_type == NAUTILUS_DATE_TYPE_MODIFIED
- || date_type == NAUTILUS_DATE_TYPE_USED
|| date_type == NAUTILUS_DATE_TYPE_TRASHED
|| date_type == NAUTILUS_DATE_TYPE_PERMISSIONS_CHANGED, FALSE);
@@ -5870,8 +5852,8 @@ nautilus_file_get_deep_directory_count_as_string (NautilusFile *file)
* @file: NautilusFile representing the file in question.
* @attribute_name: The name of the desired attribute. The currently supported
* set includes "name", "type", "mime_type", "size", "deep_size", "deep_directory_count",
- * "deep_file_count", "deep_total_count", "date_modified", "date_changed", "date_accessed", "date_used",
- * "date_permissions", "date_modified_full", "date_changed_full", "date_accessed_full", "date_used_full",
+ * "deep_file_count", "deep_total_count", "date_modified", "date_changed", "date_accessed",
+ * "date_permissions", "date_modified_full", "date_changed_full", "date_accessed_full",
* "date_permissions_full", "owner", "group", "permissions", "octal_permissions", "uri", "where",
* "link_target", "volume", "free_space", "selinux_context", "trashed_on", "trashed_on_full", "trashed_orig_path"
*
@@ -5944,16 +5926,6 @@ nautilus_file_get_string_attribute_q (NautilusFile *file, GQuark attribute_q)
NAUTILUS_DATE_TYPE_ACCESSED,
FALSE);
}
- if (attribute_q == attribute_date_used_q) {
- return nautilus_file_get_date_as_string (file,
- NAUTILUS_DATE_TYPE_USED,
- TRUE);
- }
- if (attribute_q == attribute_date_used_full_q) {
- return nautilus_file_get_date_as_string (file,
- NAUTILUS_DATE_TYPE_USED,
- FALSE);
- }
if (attribute_q == attribute_trashed_on_q) {
return nautilus_file_get_date_as_string (file,
NAUTILUS_DATE_TYPE_TRASHED,
@@ -7924,9 +7896,6 @@ nautilus_file_class_init (NautilusFileClass *class)
attribute_accessed_date_q = g_quark_from_static_string ("accessed_date");
attribute_date_accessed_q = g_quark_from_static_string ("date_accessed");
attribute_date_accessed_full_q = g_quark_from_static_string ("date_accessed_full");
- attribute_used_date_q = g_quark_from_static_string ("used_date");
- attribute_date_used_q = g_quark_from_static_string ("date_used");
- attribute_date_used_full_q = g_quark_from_static_string ("date_used_full");
attribute_mime_type_q = g_quark_from_static_string ("mime_type");
attribute_size_detail_q = g_quark_from_static_string ("size_detail");
attribute_deep_size_q = g_quark_from_static_string ("deep_size");
diff --git a/libnautilus-private/nautilus-file.h b/libnautilus-private/nautilus-file.h
index 87118f8..f482377 100644
--- a/libnautilus-private/nautilus-file.h
+++ b/libnautilus-private/nautilus-file.h
@@ -60,7 +60,6 @@ typedef enum {
NAUTILUS_FILE_SORT_BY_TYPE,
NAUTILUS_FILE_SORT_BY_MTIME,
NAUTILUS_FILE_SORT_BY_ATIME,
- NAUTILUS_FILE_SORT_BY_USED_TIME,
NAUTILUS_FILE_SORT_BY_TRASHED_TIME
} NautilusFileSortType;
@@ -475,7 +474,6 @@ typedef enum {
NAUTILUS_DATE_TYPE_MODIFIED,
NAUTILUS_DATE_TYPE_CHANGED,
NAUTILUS_DATE_TYPE_ACCESSED,
- NAUTILUS_DATE_TYPE_USED,
NAUTILUS_DATE_TYPE_PERMISSIONS_CHANGED,
NAUTILUS_DATE_TYPE_TRASHED
} NautilusDateType;
diff --git a/libnautilus-private/nautilus-vfs-file.c b/libnautilus-private/nautilus-vfs-file.c
index 44c1fc4..fdb3ad0 100644
--- a/libnautilus-private/nautilus-vfs-file.c
+++ b/libnautilus-private/nautilus-vfs-file.c
@@ -304,16 +304,6 @@ vfs_file_get_date (NautilusFile *file,
*date = file->details->mtime;
}
return TRUE;
- case NAUTILUS_DATE_TYPE_USED:
- /* Before we have info on a file, the date is unknown. */
- if (file->details->mtime == 0 && file->details->atime == 0) {
- return FALSE;
- }
- if (date != NULL) {
- *date = MAX (file->details->atime,
- file->details->mtime);
- }
- return TRUE;
case NAUTILUS_DATE_TYPE_TRASHED:
/* Before we have info on a file, the date is unknown. */
if (file->details->trash_time == 0) {
diff --git a/libnautilus-private/org.gnome.nautilus.gschema.xml.in b/libnautilus-private/org.gnome.nautilus.gschema.xml.in
index 262ced3..56435d1 100644
--- a/libnautilus-private/org.gnome.nautilus.gschema.xml.in
+++ b/libnautilus-private/org.gnome.nautilus.gschema.xml.in
@@ -234,12 +234,12 @@
<_description>Default zoom level used by the list view.</_description>
</key>
<key name="default-visible-columns" type="as">
- <default>[ 'name', 'size', 'type', 'date_used' ]</default>
+ <default>[ 'name', 'size', 'type', 'date_modified' ]</default>
<_summary>Default list of columns visible in the list view</_summary>
<_description>Default list of columns visible in the list view.</_description>
</key>
<key name="default-column-order" type="as">
- <default>[ 'name', 'size', 'type', 'date_used' ]</default>
+ <default>[ 'name', 'size', 'type', 'date_modified' ]</default>
<_summary>Default column order in the list view</_summary>
<_description>Default column order in the list view.</_description>
</key>
[
Date Prev][
Date Next] [
Thread Prev][
Thread Next]
[
Thread Index]
[
Date Index]
[
Author Index]