summaryrefslogtreecommitdiff
path: root/src/nautilus-properties-window.c
diff options
context:
space:
mode:
authorTimothy OBrien <obrien.timothy.a@gmail.com>2019-02-09 02:26:38 +1100
committerCarlos Soriano <csoriano1618+gnome@gmail.com>2019-02-11 11:39:28 +0000
commit8078950532922c78f35cb7140be0567c0f413d3c (patch)
tree9a2d3fefb9be781e41887366463986bc48b7efe2 /src/nautilus-properties-window.c
parent6a9c7f3fd4fdab268ef18add75ec43f312d56ddb (diff)
downloadnautilus-8078950532922c78f35cb7140be0567c0f413d3c.tar.gz
properties-window: Logic for displaying Modified and Accessed times
Modified times were not displaying when viewing directory properties. Added logic to show the Accessed and Modified fields at appropriate times when either files or folders are selected. Fixes #723
Diffstat (limited to 'src/nautilus-properties-window.c')
-rw-r--r--src/nautilus-properties-window.c19
1 files changed, 17 insertions, 2 deletions
diff --git a/src/nautilus-properties-window.c b/src/nautilus-properties-window.c
index 2fb932f44..464a131ca 100644
--- a/src/nautilus-properties-window.c
+++ b/src/nautilus-properties-window.c
@@ -2674,7 +2674,8 @@ should_show_accessed_date (NautilusPropertiesWindow *window)
* day decide that it is useful, we should separately
* consider whether it's useful for "trash:".
*/
- if (file_list_all_directories (window->target_files))
+ if (file_list_all_directories (window->target_files)
+ || is_multi_file_window (window))
{
return FALSE;
}
@@ -2683,6 +2684,12 @@ should_show_accessed_date (NautilusPropertiesWindow *window)
}
static gboolean
+should_show_modified_date (NautilusPropertiesWindow *window)
+{
+ return !is_multi_file_window (window);
+}
+
+static gboolean
should_show_trashed_on (NautilusPropertiesWindow *window)
{
GList *l;
@@ -3252,14 +3259,22 @@ create_basic_page (NautilusPropertiesWindow *window)
FALSE);
}
- if (should_show_accessed_date (window))
+ if (should_show_accessed_date (window)
+ || should_show_modified_date (window))
{
append_blank_row (grid);
+ }
+ if (should_show_accessed_date (window))
+ {
append_title_value_pair (window, grid, _("Accessed:"),
"date_accessed_full",
INCONSISTENT_STATE_STRING,
FALSE);
+ }
+
+ if (should_show_modified_date (window))
+ {
append_title_value_pair (window, grid, _("Modified:"),
"date_modified_full",
INCONSISTENT_STATE_STRING,