Donate to e Foundation | Murena handsets with /e/OS | Own a part of Murena! Learn more

Commit 8c11ec18 authored by cketti's avatar cketti
Browse files

Code style/documentation cleanup (no functional changes)

parent cd37ae16
Loading
Loading
Loading
Loading
+5 −13
Original line number Diff line number Diff line
@@ -323,19 +323,11 @@ http://k9mail.googlecode.com/.
    <string name="global_settings_confirm_action_mark_all_as_read">Alle als gelesen markieren</string>
    <string name="global_settings_confirm_action_send">Senden</string>

    <string name="global_settings_notification_hide_subject_mode_title">Betreff in Benachrichtigungen verbergen</string>
    <string name="global_settings_notification_hide_subject_mode_summary">Verbergen des Betreffes in Benachrichtigungen</string>
    <string-array name="global_settings_notification_hide_subject_mode">
        <item name="1">Niemals verbergen</item>
        <item name="2">Nur, wenn Gerät gesperrt ist</item>
        <item name="3">Immer verbergen</item>
    </string-array>
    
    <string-array name="global_settings_notification_hide_subject_mode_values">
        <item name="1">NEVER</item>
        <item name="2">WHEN_LOCKED</item>
        <item name="3">ALWAYS</item>
    </string-array>
    <string name="global_settings_notification_hide_subject_title">Betreff in Benachrichtigungen verbergen</string>
    <string name="global_settings_notification_hide_subject_summary">Verbergen des Betreffes in Benachrichtigungen</string>
    <string name="global_settings_notification_hide_subject_never">Niemals</string>
    <string name="global_settings_notification_hide_subject_when_locked">Wenn der Bildschirm gesperrt ist</string>
    <string name="global_settings_notification_hide_subject_always">Immer</string>

    <string name="global_settings_batch_buttons">Gruppenoperationen-Schaltflächen</string>
    <string name="global_settings_batch_buttons_summary">Zeige folgende Schaltflächen in der Nachrichtenliste an</string>
+12 −0
Original line number Diff line number Diff line
@@ -667,4 +667,16 @@
        <item>AUTO</item>
    </string-array>

    <string-array name="global_settings_notification_hide_subject_entries">
        <item name="1">@string/global_settings_notification_hide_subject_never</item>
        <item name="2">@string/global_settings_notification_hide_subject_when_locked</item>
        <item name="3">@string/global_settings_notification_hide_subject_always</item>
    </string-array>

    <string-array name="global_settings_notification_hide_subject_values">
        <item name="1">NEVER</item>
        <item name="2">WHEN_LOCKED</item>
        <item name="3">ALWAYS</item>
    </string-array>

</resources>
+6 −14
Original line number Diff line number Diff line
@@ -326,19 +326,11 @@ http://k9mail.googlecode.com/
    <string name="global_settings_confirm_action_mark_all_as_read">Mark all as read</string>
    <string name="global_settings_confirm_action_send">Send</string>

    <string name="global_settings_notification_hide_subject_mode_title">Hide subject in notifications</string>
    <string name="global_settings_notification_hide_subject_mode_summary">When to hide the subject in the notification bar.</string>
    <string-array name="global_settings_notification_hide_subject_mode">
        <item name="1">Never</item>
        <item name="2">When phone is locked</item>
        <item name="3">Always</item>
    </string-array>
    
    <string-array name="global_settings_notification_hide_subject_mode_values">
        <item name="1">NEVER</item>
        <item name="2">WHEN_LOCKED</item>
        <item name="3">ALWAYS</item>
    </string-array>
    <string name="global_settings_notification_hide_subject_title">Hide subject in notifications</string>
    <string name="global_settings_notification_hide_subject_summary">When to hide the subject in the notification bar.</string>
    <string name="global_settings_notification_hide_subject_never">Never</string>
    <string name="global_settings_notification_hide_subject_when_locked">When phone is locked</string>
    <string name="global_settings_notification_hide_subject_always">Always</string>

    <string name="global_settings_batch_buttons">Batch buttons</string>
    <string name="global_settings_batch_buttons_summary">Configure message list batch buttons</string>
+4 −4
Original line number Diff line number Diff line
@@ -352,10 +352,10 @@
            android:persistent="false"
            android:key="notification_hide_subject"
            android:defaultValue="NEVER"
            android:entries="@array/global_settings_notification_hide_subject_mode"
            android:entryValues="@array/global_settings_notification_hide_subject_mode_values"
            android:title="@string/global_settings_notification_hide_subject_mode_title"
            android:summary="@string/global_settings_notification_hide_subject_mode_summary"/>
            android:entries="@array/global_settings_notification_hide_subject_entries"
            android:entryValues="@array/global_settings_notification_hide_subject_values"
            android:title="@string/global_settings_notification_hide_subject_title"
            android:summary="@string/global_settings_notification_hide_subject_summary"/>

    </PreferenceScreen>

+13 −14
Original line number Diff line number Diff line
@@ -155,11 +155,11 @@ public class K9 extends Application {
    private static boolean mConfirmDeleteStarred = false;
    private static boolean mConfirmSpam = false;
    private static boolean mConfirmMarkAllAsRead = true;
    private static NotificationHideSubject mNotificationHideSubject = NotificationHideSubject.NEVER;

    private static NotificationHideSubject sNotificationHideSubject = NotificationHideSubject.NEVER;

    /**
     * controls when to show the subject
     * in the notification area
     * -> Global Settings -> Privacy -> Notification
     * Controls when to hide the subject in the notification area.
     */
    public enum NotificationHideSubject {
        ALWAYS,
@@ -475,7 +475,7 @@ public class K9 extends Application {
        editor.putString("sortTypeEnum", mSortType.name());
        editor.putBoolean("sortAscending", mSortAscending.get(mSortType));

        editor.putString("notificationHideSubjectMode", mNotificationHideSubject.toString());
        editor.putString("notificationHideSubject", sNotificationHideSubject.toString());

        editor.putBoolean("compactLayouts", compactLayouts);
        editor.putString("attachmentdefaultpath", mAttachmentDefaultPath);
@@ -639,7 +639,9 @@ public class K9 extends Application {
        boolean sortAscending = sprefs.getBoolean("sortAscending", Account.DEFAULT_SORT_ASCENDING);
        mSortAscending.put(mSortType, sortAscending);

        mNotificationHideSubject = NotificationHideSubject.valueOf(sprefs.getString("notificationHideSubjectMode", NotificationHideSubject.NEVER.toString()));
        String notificationHideSubject = sprefs.getString("notificationHideSubject",
                NotificationHideSubject.NEVER.toString());
        sNotificationHideSubject = NotificationHideSubject.valueOf(notificationHideSubject);

        compactLayouts = sprefs.getBoolean("compactLayouts", false);
        mAttachmentDefaultPath = sprefs.getString("attachmentdefaultpath",  Environment.getExternalStorageDirectory().toString());
@@ -1057,15 +1059,12 @@ public class K9 extends Application {
        mConfirmMarkAllAsRead = confirm;
    }

    /**
     * @return Whether privacy rules should be applied when system is locked
     */
    public static NotificationHideSubject getNotificationHideSubjectMode() {
        return mNotificationHideSubject;
    public static NotificationHideSubject getNotificationHideSubject() {
        return sNotificationHideSubject;
    }

    public static void setNotificationHideSubjectMode(final NotificationHideSubject mode) {
        mNotificationHideSubject = mode;
    public static void setNotificationHideSubject(final NotificationHideSubject mode) {
        sNotificationHideSubject = mode;
    }

    public static boolean useCompactLayouts() {
Loading