OSDN Git Service

CMFM: Display new fso datetimes props
authorJorge Ruesga <jorge@ruesga.com>
Sun, 6 Jan 2013 18:52:53 +0000 (19:52 +0100)
committerMarco Brohet <therbom@gmail.com>
Mon, 7 Jan 2013 11:19:59 +0000 (12:19 +0100)
Add to FsoPropertiesDialog the new fso datetimes properties:
- Last accessed
- Last modified
- Last changed

Remove old fso_properties_dialog_date string from translations.

Change-Id: I881658ae0fbc6c935995ffb4ad7a02172d06bb2c
Signed-off-by: jruesga <jorge@ruesga.com>
18 files changed:
res/layout/fso_properties_dialog.xml
res/values-cs/strings.xml
res/values-da/strings.xml
res/values-de/strings.xml
res/values-el/strings.xml
res/values-es/strings.xml
res/values-fr/strings.xml
res/values-hu/strings.xml
res/values-it/strings.xml
res/values-ja/strings.xml
res/values-nl/strings.xml
res/values-pt-rBR/strings.xml
res/values-pt-rPT/strings.xml
res/values-ro/strings.xml
res/values-ru/strings.xml
res/values-zh-rCN/strings.xml
res/values/strings.xml
src/com/cyanogenmod/filemanager/ui/dialogs/FsoPropertiesDialog.java

index 7c4886b..45c3845 100644 (file)
           android:textAppearance="@style/secondary_text_appearance" />
       </TableRow>
 
-      <!-- Date -->
+      <!-- Last Accessed Time -->
       <TableRow
         android:layout_marginLeft="@dimen/extra_large_margin"
         android:layout_marginRight="@dimen/extra_large_margin" >
 
         <TextView
-          android:id="@+id/fso_properties_date_label"
+          android:id="@+id/fso_properties_last_accessed_label"
           android:layout_width="match_parent"
           android:layout_height="wrap_content"
           android:layout_margin="@dimen/default_margin"
           android:gravity="left|center_vertical"
-          android:text="@string/fso_properties_dialog_date"
+          android:text="@string/fso_properties_dialog_last_accessed_date"
           android:textAppearance="@style/primary_text_appearance" />
 
         <TextView
-          android:id="@+id/fso_properties_date"
+          android:id="@+id/fso_properties_last_accessed"
+          android:layout_width="match_parent"
+          android:layout_height="wrap_content"
+          android:layout_margin="@dimen/default_margin"
+          android:paddingRight="@dimen/double_margin"
+          android:gravity="left|center_vertical"
+          android:singleLine="false"
+          android:textAppearance="@style/secondary_text_appearance" />
+      </TableRow>
+
+      <!-- Last Modified Time -->
+      <TableRow
+        android:layout_marginLeft="@dimen/extra_large_margin"
+        android:layout_marginRight="@dimen/extra_large_margin" >
+
+        <TextView
+          android:id="@+id/fso_properties_last_modified_label"
+          android:layout_width="match_parent"
+          android:layout_height="wrap_content"
+          android:layout_margin="@dimen/default_margin"
+          android:gravity="left|center_vertical"
+          android:text="@string/fso_properties_dialog_last_modified_date"
+          android:textAppearance="@style/primary_text_appearance" />
+
+        <TextView
+          android:id="@+id/fso_properties_last_modified"
+          android:layout_width="match_parent"
+          android:layout_height="wrap_content"
+          android:layout_margin="@dimen/default_margin"
+          android:paddingRight="@dimen/double_margin"
+          android:gravity="left|center_vertical"
+          android:singleLine="false"
+          android:textAppearance="@style/secondary_text_appearance" />
+      </TableRow>
+
+      <!-- Last Changed Time -->
+      <TableRow
+        android:layout_marginLeft="@dimen/extra_large_margin"
+        android:layout_marginRight="@dimen/extra_large_margin" >
+
+        <TextView
+          android:id="@+id/fso_properties_last_changed_label"
+          android:layout_width="match_parent"
+          android:layout_height="wrap_content"
+          android:layout_margin="@dimen/default_margin"
+          android:gravity="left|center_vertical"
+          android:text="@string/fso_properties_dialog_last_changed_date"
+          android:textAppearance="@style/primary_text_appearance" />
+
+        <TextView
+          android:id="@+id/fso_properties_last_changed"
           android:layout_width="match_parent"
           android:layout_height="wrap_content"
           android:layout_margin="@dimen/default_margin"
index 8e2fdee..5d045d5 100644 (file)
   <string name="fso_properties_dialog_size">Velikost:</string>
   <!-- Fso Properties Dialog * Contains Label -->
   <string name="fso_properties_dialog_contains">Obsah:</string>
-  <!-- Fso Properties Dialog * Date Label -->
-  <string name="fso_properties_dialog_date">Poslední přístup:</string>
   <!-- Fso Properties Dialog * Owner Label -->
   <string name="fso_properties_dialog_owner">Vlastník:</string>
   <!-- Fso Properties Dialog * Group Label -->
index 912d613..50dff86 100644 (file)
   <string name="fso_properties_dialog_size">Størrelse:</string>
   <!-- Fso Properties Dialog * Contains Label -->
   <string name="fso_properties_dialog_contains">Indeholder:</string>
-  <!-- Fso Properties Dialog * Date Label -->
-  <string name="fso_properties_dialog_date">Sidst tilgået:</string>
   <!-- Fso Properties Dialog * Owner Label -->
   <string name="fso_properties_dialog_owner">Ejer:</string>
   <!-- Fso Properties Dialog * Group Label -->
index 64e4754..771c466 100644 (file)
   <string name="fso_properties_dialog_size">Größe:</string>
   <!-- Fso Properties Dialog * Contains Label -->
   <string name="fso_properties_dialog_contains">Beinhaltet:</string>
-  <!-- Fso Properties Dialog * Date Label -->
-  <string name="fso_properties_dialog_date">Letzter Zugriff:</string>
   <!-- Fso Properties Dialog * Owner Label -->
   <string name="fso_properties_dialog_owner">Besitzer:</string>
   <!-- Fso Properties Dialog * Group Label -->
index 0749843..054735e 100644 (file)
   <string name="fso_properties_dialog_size">Μέγεθος:</string>
   <!-- Fso Properties Dialog * Contains Label -->
   <string name="fso_properties_dialog_contains">Περιέχει:</string>
-  <!-- Fso Properties Dialog * Date Label -->
-  <string name="fso_properties_dialog_date">Τελ. προσπέλαση:</string>
   <!-- Fso Properties Dialog * Owner Label -->
   <string name="fso_properties_dialog_owner">Ιδιοκτήτης:</string>
   <!-- Fso Properties Dialog * Group Label -->
index 757534b..e8ff2af 100644 (file)
   <string name="fso_properties_dialog_link">Enlace:</string>
   <string name="fso_properties_dialog_size">Tamaño:</string>
   <string name="fso_properties_dialog_contains">Contenido:</string>
-  <string name="fso_properties_dialog_date">Último acceso:</string>
   <string name="fso_properties_dialog_owner">Propietario:</string>
   <string name="fso_properties_dialog_group">Grupo:</string>
   <string name="fso_properties_dialog_others">Otros:</string>
index a613de7..6168b20 100644 (file)
   <string name="fso_properties_dialog_size">Taille\u00A0:</string>
   <!-- Fso Properties Dialog * Contains Label -->
   <string name="fso_properties_dialog_contains">Contenu\u00A0:</string>
-  <!-- Fso Properties Dialog * Date Label -->
-  <string name="fso_properties_dialog_date">Dernier accès\u00A0:</string>
   <!-- Fso Properties Dialog * Owner Label -->
   <string name="fso_properties_dialog_owner">Propriétaire\u00A0:</string>
   <!-- Fso Properties Dialog * Group Label -->
index ff1c00e..b45cbb2 100644 (file)
     <string name="fso_properties_dialog_size">Méret:</string>
     <!-- Fso Properties Dialog * Contains Label -->
     <string name="fso_properties_dialog_contains">Tartalmaz:</string>
-    <!-- Fso Properties Dialog * Date Label -->
-    <string name="fso_properties_dialog_date">Utolsó hozzáférés:</string>
     <!-- Fso Properties Dialog * Owner Label -->
     <string name="fso_properties_dialog_owner">Tulajdonos:</string>
     <!-- Fso Properties Dialog * Group Label -->
index b77007d..09aa6d2 100644 (file)
   <string name="fso_properties_dialog_link">Link:</string>
   <string name="fso_properties_dialog_size">Dimensioni:</string>
   <string name="fso_properties_dialog_contains">Contiene:</string>
-  <string name="fso_properties_dialog_date">Ultimo accesso:</string>
   <string name="fso_properties_dialog_owner">Proprietario:</string>
   <string name="fso_properties_dialog_group">Gruppo:</string>
   <string name="fso_properties_dialog_others">Altri:</string>
index 9fd13bf..b08fbac 100644 (file)
   <string name="fso_properties_dialog_size">サイズ:</string>
   <!-- Fso Properties Dialog * Contains Label -->
   <string name="fso_properties_dialog_contains">内包数:</string>
-  <!-- Fso Properties Dialog * Date Label -->
-  <string name="fso_properties_dialog_date">最終アクセス:</string>
   <!-- Fso Properties Dialog * Owner Label -->
   <string name="fso_properties_dialog_owner">オーナー:</string>
   <!-- Fso Properties Dialog * Group Label -->
index ab623c2..6309451 100644 (file)
   <string name="fso_properties_dialog_size">Grootte:</string>
   <!-- Fso Properties Dialog * Contains Label -->
   <string name="fso_properties_dialog_contains">Inhoud:</string>
-  <!-- Fso Properties Dialog * Date Label -->
-  <string name="fso_properties_dialog_date">Recente toegang:</string>
   <!-- Fso Properties Dialog * Owner Label -->
   <string name="fso_properties_dialog_owner">Eigenaar:</string>
   <!-- Fso Properties Dialog * Group Label -->
index 4efa616..c32e2e5 100755 (executable)
     <string name="fso_properties_dialog_link">Vínculo:</string>
     <string name="fso_properties_dialog_size">Tamanho:</string>
     <string name="fso_properties_dialog_contains">Contém:</string>
-    <string name="fso_properties_dialog_date">Último acesso:</string>
     <string name="fso_properties_dialog_owner">Proprietário:</string>
     <string name="fso_properties_dialog_group">Grupo:</string>
     <string name="fso_properties_dialog_others">Outros:</string>
index 0d1cb33..27f9613 100644 (file)
   <string name="fso_properties_dialog_size">Tamanho:</string>
   <!-- Fso Properties Dialog * Contains Label -->
   <string name="fso_properties_dialog_contains">Contém:</string>
-  <!-- Fso Properties Dialog * Date Label -->
-  <string name="fso_properties_dialog_date">Último acesso:</string>
   <!-- Fso Properties Dialog * Owner Label -->
   <string name="fso_properties_dialog_owner">Dono:</string>
   <!-- Fso Properties Dialog * Group Label -->
index f2d174f..9a52a18 100644 (file)
   <string name="fso_properties_dialog_link">Link:</string>\r
   <string name="fso_properties_dialog_size">Dimensiune:</string>\r
   <string name="fso_properties_dialog_contains">Conţin:</string>\r
-  <string name="fso_properties_dialog_date">Ultima accesare:</string>\r
   <string name="fso_properties_dialog_owner">Proprietar:</string>\r
   <string name="fso_properties_dialog_group">Grup:</string>\r
   <string name="fso_properties_dialog_others">Altele:</string>\r
index ece85a7..28f7d33 100644 (file)
   <string name="fso_properties_dialog_link">Ссылка:</string>
   <string name="fso_properties_dialog_size">Размер:</string>
   <string name="fso_properties_dialog_contains">Содержит:</string>
-  <string name="fso_properties_dialog_date">Посл. доступ:</string>
   <string name="fso_properties_dialog_owner">Владелец:</string>
   <string name="fso_properties_dialog_group">Группа:</string>
   <string name="fso_properties_dialog_others">Другое:</string>
index 23e322a..c7478a1 100644 (file)
   <string name="fso_properties_dialog_size">大小:</string>
   <!-- Fso Properties Dialog * Contains Label -->
   <string name="fso_properties_dialog_contains">包含:</string>
-  <!-- Fso Properties Dialog * Date Label -->
-  <string name="fso_properties_dialog_date">最后一次访问:</string>
   <!-- Fso Properties Dialog * Owner Label -->
   <string name="fso_properties_dialog_owner">拥有者:</string>
   <!-- Fso Properties Dialog * Group Label -->
index 4b1a243..070e3dc 100644 (file)
   <string name="fso_properties_dialog_size">Size:</string>
   <!-- Fso Properties Dialog * Contains Label -->
   <string name="fso_properties_dialog_contains">Contains:</string>
-  <!-- Fso Properties Dialog * Date Label -->
-  <string name="fso_properties_dialog_date">Last access:</string>
+  <!-- Fso Properties Dialog * Last Accessed Time Label -->
+  <string name="fso_properties_dialog_last_accessed_date">Accessed:</string>
+  <!-- Fso Properties Dialog * Last Modified Time Label -->
+  <string name="fso_properties_dialog_last_modified_date">Modified:</string>
+  <!-- Fso Properties Dialog * Last Changed Time -->
+  <string name="fso_properties_dialog_last_changed_date">Changed:</string>
   <!-- Fso Properties Dialog * Owner Label -->
   <string name="fso_properties_dialog_owner">Owner:</string>
   <!-- Fso Properties Dialog * Group Label -->
index 87c38c8..95fa193 100644 (file)
@@ -253,7 +253,12 @@ public class FsoPropertiesDialog
         this.mTvSize = (TextView)contentView.findViewById(R.id.fso_properties_size);
         View vContatinsRow = contentView.findViewById(R.id.fso_properties_contains_row);
         this.mTvContains = (TextView)contentView.findViewById(R.id.fso_properties_contains);
-        TextView tvDate = (TextView)contentView.findViewById(R.id.fso_properties_date);
+        TextView tvLastAccessedTime =
+                (TextView)contentView.findViewById(R.id.fso_properties_last_accessed);
+        TextView tvLastModifiedTime =
+                (TextView)contentView.findViewById(R.id.fso_properties_last_modified);
+        TextView tvLastChangedTime =
+                (TextView)contentView.findViewById(R.id.fso_properties_last_changed);
         this.mSpnOwner = (Spinner)contentView.findViewById(R.id.fso_properties_owner);
         this.mSpnGroup = (Spinner)contentView.findViewById(R.id.fso_properties_group);
         this.mInfoMsgView = (TextView)contentView.findViewById(R.id.fso_info_msg);
@@ -291,7 +296,21 @@ public class FsoPropertiesDialog
         this.mTvSize.setText(size);
         this.mTvContains.setText("-");  //$NON-NLS-1$
         DateFormat df = DateFormat.getDateTimeInstance(DateFormat.SHORT, DateFormat.SHORT);
-        tvDate.setText(df.format(this.mFso.getLastModifiedTime()));
+        try {
+            tvLastAccessedTime.setText(df.format(this.mFso.getLastAccessedTime()));
+        } catch (Exception e) {
+            tvLastAccessedTime.setText("-");  //$NON-NLS-1$
+        }
+        try {
+            tvLastModifiedTime.setText(df.format(this.mFso.getLastModifiedTime()));
+        } catch (Exception e) {
+            tvLastModifiedTime.setText("-");  //$NON-NLS-1$
+        }
+        try {
+            tvLastChangedTime.setText(df.format(this.mFso.getLastChangedTime()));
+        } catch (Exception e) {
+            tvLastChangedTime.setText("-");  //$NON-NLS-1$
+        }
 
         //- Permissions
         String loadingMsg = this.mContext.getString(R.string.loading_message);
@@ -1156,9 +1175,17 @@ public class FsoPropertiesDialog
         theme.setTextColor(this.mContext, (TextView)v, "text_color"); //$NON-NLS-1$
         v = this.mContentView.findViewById(R.id.fso_properties_contains);
         theme.setTextColor(this.mContext, (TextView)v, "text_color"); //$NON-NLS-1$
-        v = this.mContentView.findViewById(R.id.fso_properties_date_label);
+        v = this.mContentView.findViewById(R.id.fso_properties_last_accessed_label);
+        theme.setTextColor(this.mContext, (TextView)v, "text_color"); //$NON-NLS-1$
+        v = this.mContentView.findViewById(R.id.fso_properties_last_accessed);
+        theme.setTextColor(this.mContext, (TextView)v, "text_color"); //$NON-NLS-1$
+        v = this.mContentView.findViewById(R.id.fso_properties_last_modified_label);
+        theme.setTextColor(this.mContext, (TextView)v, "text_color"); //$NON-NLS-1$
+        v = this.mContentView.findViewById(R.id.fso_properties_last_modified);
+        theme.setTextColor(this.mContext, (TextView)v, "text_color"); //$NON-NLS-1$
+        v = this.mContentView.findViewById(R.id.fso_properties_last_changed_label);
         theme.setTextColor(this.mContext, (TextView)v, "text_color"); //$NON-NLS-1$
-        v = this.mContentView.findViewById(R.id.fso_properties_date);
+        v = this.mContentView.findViewById(R.id.fso_properties_last_changed);
         theme.setTextColor(this.mContext, (TextView)v, "text_color"); //$NON-NLS-1$
 
         v = this.mContentView.findViewById(R.id.fso_properties_owner_label);