diff --git a/res/xml/preferences.xml b/res/xml/preferences.xml index 49c56459cc..af30444510 100644 --- a/res/xml/preferences.xml +++ b/res/xml/preferences.xml @@ -2,7 +2,7 @@ - - - + - - - + - - - - - - - - - { private static final String TAG = ThreadPhotoRailAdapter.class.getName(); diff --git a/src/org/thoughtcrime/securesms/notifications/AbstractNotificationBuilder.java b/src/org/thoughtcrime/securesms/notifications/AbstractNotificationBuilder.java index e3621da760..195f760e9a 100644 --- a/src/org/thoughtcrime/securesms/notifications/AbstractNotificationBuilder.java +++ b/src/org/thoughtcrime/securesms/notifications/AbstractNotificationBuilder.java @@ -12,7 +12,7 @@ import android.text.TextUtils; import org.thoughtcrime.securesms.R; import org.thoughtcrime.securesms.database.RecipientDatabase; -import org.thoughtcrime.securesms.preferences.NotificationPrivacyPreference; +import org.thoughtcrime.securesms.preferences.widgets.NotificationPrivacyPreference; import org.thoughtcrime.securesms.recipients.Recipient; import org.thoughtcrime.securesms.util.TextSecurePreferences; import org.thoughtcrime.securesms.util.Util; diff --git a/src/org/thoughtcrime/securesms/notifications/FailedNotificationBuilder.java b/src/org/thoughtcrime/securesms/notifications/FailedNotificationBuilder.java index 1003b9a0d7..b7fc29b176 100644 --- a/src/org/thoughtcrime/securesms/notifications/FailedNotificationBuilder.java +++ b/src/org/thoughtcrime/securesms/notifications/FailedNotificationBuilder.java @@ -7,7 +7,7 @@ import android.graphics.BitmapFactory; import org.thoughtcrime.securesms.R; import org.thoughtcrime.securesms.database.RecipientDatabase; -import org.thoughtcrime.securesms.preferences.NotificationPrivacyPreference; +import org.thoughtcrime.securesms.preferences.widgets.NotificationPrivacyPreference; public class FailedNotificationBuilder extends AbstractNotificationBuilder { diff --git a/src/org/thoughtcrime/securesms/notifications/MultipleRecipientNotificationBuilder.java b/src/org/thoughtcrime/securesms/notifications/MultipleRecipientNotificationBuilder.java index d0e4adce4c..6b585ac07a 100644 --- a/src/org/thoughtcrime/securesms/notifications/MultipleRecipientNotificationBuilder.java +++ b/src/org/thoughtcrime/securesms/notifications/MultipleRecipientNotificationBuilder.java @@ -10,7 +10,7 @@ import android.support.v4.app.NotificationCompat; import org.thoughtcrime.securesms.ConversationListActivity; import org.thoughtcrime.securesms.R; -import org.thoughtcrime.securesms.preferences.NotificationPrivacyPreference; +import org.thoughtcrime.securesms.preferences.widgets.NotificationPrivacyPreference; import org.thoughtcrime.securesms.recipients.Recipient; import org.thoughtcrime.securesms.util.TextSecurePreferences; import org.thoughtcrime.securesms.util.Util; diff --git a/src/org/thoughtcrime/securesms/notifications/PendingMessageNotificationBuilder.java b/src/org/thoughtcrime/securesms/notifications/PendingMessageNotificationBuilder.java index bf0863e0ce..9784cc6ba1 100644 --- a/src/org/thoughtcrime/securesms/notifications/PendingMessageNotificationBuilder.java +++ b/src/org/thoughtcrime/securesms/notifications/PendingMessageNotificationBuilder.java @@ -9,7 +9,7 @@ import android.support.v4.app.NotificationCompat; import org.thoughtcrime.securesms.ConversationListActivity; import org.thoughtcrime.securesms.R; import org.thoughtcrime.securesms.database.RecipientDatabase; -import org.thoughtcrime.securesms.preferences.NotificationPrivacyPreference; +import org.thoughtcrime.securesms.preferences.widgets.NotificationPrivacyPreference; import org.thoughtcrime.securesms.util.TextSecurePreferences; public class PendingMessageNotificationBuilder extends AbstractNotificationBuilder { diff --git a/src/org/thoughtcrime/securesms/notifications/SingleRecipientNotificationBuilder.java b/src/org/thoughtcrime/securesms/notifications/SingleRecipientNotificationBuilder.java index 6d0d7eead4..bd33f778a7 100644 --- a/src/org/thoughtcrime/securesms/notifications/SingleRecipientNotificationBuilder.java +++ b/src/org/thoughtcrime/securesms/notifications/SingleRecipientNotificationBuilder.java @@ -24,7 +24,7 @@ import org.thoughtcrime.securesms.crypto.MasterSecret; import org.thoughtcrime.securesms.mms.DecryptableStreamUriLoader; import org.thoughtcrime.securesms.mms.Slide; import org.thoughtcrime.securesms.mms.SlideDeck; -import org.thoughtcrime.securesms.preferences.NotificationPrivacyPreference; +import org.thoughtcrime.securesms.preferences.widgets.NotificationPrivacyPreference; import org.thoughtcrime.securesms.recipients.Recipient; import org.thoughtcrime.securesms.util.BitmapUtil; import org.thoughtcrime.securesms.util.TextSecurePreferences; diff --git a/src/org/thoughtcrime/securesms/preferences/CorrectedPreferenceFragment.java b/src/org/thoughtcrime/securesms/preferences/CorrectedPreferenceFragment.java index e25ffa60ab..ec9bf41d91 100644 --- a/src/org/thoughtcrime/securesms/preferences/CorrectedPreferenceFragment.java +++ b/src/org/thoughtcrime/securesms/preferences/CorrectedPreferenceFragment.java @@ -8,6 +8,10 @@ import android.support.v7.preference.PreferenceFragmentCompat; import android.view.View; import org.thoughtcrime.securesms.components.CustomDefaultPreference; +import org.thoughtcrime.securesms.preferences.widgets.ColorPickerPreference; +import org.thoughtcrime.securesms.preferences.widgets.ColorPickerPreferenceDialogFragmentCompat; +import org.thoughtcrime.securesms.preferences.widgets.RingtonePreference; +import org.thoughtcrime.securesms.preferences.widgets.RingtonePreferenceDialogFragmentCompat; public abstract class CorrectedPreferenceFragment extends PreferenceFragmentCompat { diff --git a/src/org/thoughtcrime/securesms/preferences/NotificationsPreferenceFragment.java b/src/org/thoughtcrime/securesms/preferences/NotificationsPreferenceFragment.java index 65812f820c..76b5f3e568 100644 --- a/src/org/thoughtcrime/securesms/preferences/NotificationsPreferenceFragment.java +++ b/src/org/thoughtcrime/securesms/preferences/NotificationsPreferenceFragment.java @@ -12,12 +12,12 @@ import android.support.v7.preference.ListPreference; import android.support.v7.preference.Preference; import android.support.v7.preference.PreferenceManager; import android.text.TextUtils; -import android.util.Log; import org.thoughtcrime.securesms.ApplicationPreferencesActivity; import org.thoughtcrime.securesms.R; import org.thoughtcrime.securesms.crypto.MasterSecret; import org.thoughtcrime.securesms.notifications.MessageNotifier; +import org.thoughtcrime.securesms.preferences.widgets.AdvancedRingtonePreference; import org.thoughtcrime.securesms.util.TextSecurePreferences; public class NotificationsPreferenceFragment extends ListSummaryPreferenceFragment { diff --git a/src/org/thoughtcrime/securesms/preferences/AdvancedRingtonePreference.java b/src/org/thoughtcrime/securesms/preferences/widgets/AdvancedRingtonePreference.java similarity index 95% rename from src/org/thoughtcrime/securesms/preferences/AdvancedRingtonePreference.java rename to src/org/thoughtcrime/securesms/preferences/widgets/AdvancedRingtonePreference.java index f83b5cabc4..d11fc60f39 100644 --- a/src/org/thoughtcrime/securesms/preferences/AdvancedRingtonePreference.java +++ b/src/org/thoughtcrime/securesms/preferences/widgets/AdvancedRingtonePreference.java @@ -1,4 +1,4 @@ -package org.thoughtcrime.securesms.preferences; +package org.thoughtcrime.securesms.preferences.widgets; import android.content.Context; import android.net.Uri; diff --git a/src/org/thoughtcrime/securesms/preferences/ColorPickerPreference.java b/src/org/thoughtcrime/securesms/preferences/widgets/ColorPickerPreference.java similarity index 99% rename from src/org/thoughtcrime/securesms/preferences/ColorPickerPreference.java rename to src/org/thoughtcrime/securesms/preferences/widgets/ColorPickerPreference.java index 23f101fd65..e201535c25 100644 --- a/src/org/thoughtcrime/securesms/preferences/ColorPickerPreference.java +++ b/src/org/thoughtcrime/securesms/preferences/widgets/ColorPickerPreference.java @@ -1,4 +1,4 @@ -package org.thoughtcrime.securesms.preferences; +package org.thoughtcrime.securesms.preferences.widgets; import android.annotation.SuppressLint; import android.content.Context; @@ -11,7 +11,6 @@ import android.support.v7.preference.DialogPreference; import android.support.v7.preference.PreferenceViewHolder; import android.text.TextUtils; import android.util.AttributeSet; -import android.util.Log; import android.widget.ImageView; import com.takisoft.colorpicker.ColorPickerDialog; diff --git a/src/org/thoughtcrime/securesms/preferences/ColorPickerPreferenceDialogFragmentCompat.java b/src/org/thoughtcrime/securesms/preferences/widgets/ColorPickerPreferenceDialogFragmentCompat.java similarity index 97% rename from src/org/thoughtcrime/securesms/preferences/ColorPickerPreferenceDialogFragmentCompat.java rename to src/org/thoughtcrime/securesms/preferences/widgets/ColorPickerPreferenceDialogFragmentCompat.java index 1ccb9fbc38..c781c53cdf 100644 --- a/src/org/thoughtcrime/securesms/preferences/ColorPickerPreferenceDialogFragmentCompat.java +++ b/src/org/thoughtcrime/securesms/preferences/widgets/ColorPickerPreferenceDialogFragmentCompat.java @@ -1,4 +1,4 @@ -package org.thoughtcrime.securesms.preferences; +package org.thoughtcrime.securesms.preferences.widgets; import android.app.Dialog; import android.content.DialogInterface; diff --git a/src/org/thoughtcrime/securesms/preferences/LEDColorListPreference.java b/src/org/thoughtcrime/securesms/preferences/widgets/LEDColorListPreference.java similarity index 98% rename from src/org/thoughtcrime/securesms/preferences/LEDColorListPreference.java rename to src/org/thoughtcrime/securesms/preferences/widgets/LEDColorListPreference.java index 107875ada5..5781d127ae 100644 --- a/src/org/thoughtcrime/securesms/preferences/LEDColorListPreference.java +++ b/src/org/thoughtcrime/securesms/preferences/widgets/LEDColorListPreference.java @@ -14,7 +14,7 @@ * You should have received a copy of the GNU General Public License * along with this program. If not, see . */ -package org.thoughtcrime.securesms.preferences; +package org.thoughtcrime.securesms.preferences.widgets; import android.content.Context; import android.graphics.drawable.GradientDrawable; diff --git a/src/org/thoughtcrime/securesms/preferences/NotificationPrivacyPreference.java b/src/org/thoughtcrime/securesms/preferences/widgets/NotificationPrivacyPreference.java similarity index 87% rename from src/org/thoughtcrime/securesms/preferences/NotificationPrivacyPreference.java rename to src/org/thoughtcrime/securesms/preferences/widgets/NotificationPrivacyPreference.java index f2ff00db30..251af9b93b 100644 --- a/src/org/thoughtcrime/securesms/preferences/NotificationPrivacyPreference.java +++ b/src/org/thoughtcrime/securesms/preferences/widgets/NotificationPrivacyPreference.java @@ -1,4 +1,4 @@ -package org.thoughtcrime.securesms.preferences; +package org.thoughtcrime.securesms.preferences.widgets; public class NotificationPrivacyPreference { diff --git a/src/org/thoughtcrime/securesms/preferences/ProfilePreference.java b/src/org/thoughtcrime/securesms/preferences/widgets/ProfilePreference.java similarity index 98% rename from src/org/thoughtcrime/securesms/preferences/ProfilePreference.java rename to src/org/thoughtcrime/securesms/preferences/widgets/ProfilePreference.java index b0ade21558..36f14a97b0 100644 --- a/src/org/thoughtcrime/securesms/preferences/ProfilePreference.java +++ b/src/org/thoughtcrime/securesms/preferences/widgets/ProfilePreference.java @@ -1,4 +1,4 @@ -package org.thoughtcrime.securesms.preferences; +package org.thoughtcrime.securesms.preferences.widgets; import android.content.Context; diff --git a/src/org/thoughtcrime/securesms/preferences/RingtonePreference.java b/src/org/thoughtcrime/securesms/preferences/widgets/RingtonePreference.java similarity index 99% rename from src/org/thoughtcrime/securesms/preferences/RingtonePreference.java rename to src/org/thoughtcrime/securesms/preferences/widgets/RingtonePreference.java index a955196e09..a62f59ce28 100644 --- a/src/org/thoughtcrime/securesms/preferences/RingtonePreference.java +++ b/src/org/thoughtcrime/securesms/preferences/widgets/RingtonePreference.java @@ -1,4 +1,4 @@ -package org.thoughtcrime.securesms.preferences; +package org.thoughtcrime.securesms.preferences.widgets; import android.Manifest; import android.annotation.SuppressLint; @@ -15,8 +15,6 @@ import android.net.Uri; import android.os.Build; import android.provider.MediaStore; import android.support.annotation.IntDef; -import android.support.annotation.Nullable; -import android.support.annotation.StringRes; import android.support.v4.content.res.TypedArrayUtils; import android.support.v7.preference.DialogPreference; import android.support.v7.preference.Preference; diff --git a/src/org/thoughtcrime/securesms/preferences/RingtonePreferenceDialogFragmentCompat.java b/src/org/thoughtcrime/securesms/preferences/widgets/RingtonePreferenceDialogFragmentCompat.java similarity index 99% rename from src/org/thoughtcrime/securesms/preferences/RingtonePreferenceDialogFragmentCompat.java rename to src/org/thoughtcrime/securesms/preferences/widgets/RingtonePreferenceDialogFragmentCompat.java index 57f703c075..d2c9afee59 100644 --- a/src/org/thoughtcrime/securesms/preferences/RingtonePreferenceDialogFragmentCompat.java +++ b/src/org/thoughtcrime/securesms/preferences/widgets/RingtonePreferenceDialogFragmentCompat.java @@ -1,4 +1,4 @@ -package org.thoughtcrime.securesms.preferences; +package org.thoughtcrime.securesms.preferences.widgets; import android.Manifest; diff --git a/src/org/thoughtcrime/securesms/preferences/SignalListPreference.java b/src/org/thoughtcrime/securesms/preferences/widgets/SignalListPreference.java similarity index 96% rename from src/org/thoughtcrime/securesms/preferences/SignalListPreference.java rename to src/org/thoughtcrime/securesms/preferences/widgets/SignalListPreference.java index 5b5f07414e..d7dc6d913d 100644 --- a/src/org/thoughtcrime/securesms/preferences/SignalListPreference.java +++ b/src/org/thoughtcrime/securesms/preferences/widgets/SignalListPreference.java @@ -1,4 +1,4 @@ -package org.thoughtcrime.securesms.preferences; +package org.thoughtcrime.securesms.preferences.widgets; import android.content.Context; diff --git a/src/org/thoughtcrime/securesms/preferences/SignalRingtonePreference.java b/src/org/thoughtcrime/securesms/preferences/widgets/SignalRingtonePreference.java similarity index 92% rename from src/org/thoughtcrime/securesms/preferences/SignalRingtonePreference.java rename to src/org/thoughtcrime/securesms/preferences/widgets/SignalRingtonePreference.java index 33257ee02c..a1096dc23d 100644 --- a/src/org/thoughtcrime/securesms/preferences/SignalRingtonePreference.java +++ b/src/org/thoughtcrime/securesms/preferences/widgets/SignalRingtonePreference.java @@ -1,13 +1,11 @@ -package org.thoughtcrime.securesms.preferences; +package org.thoughtcrime.securesms.preferences.widgets; import android.content.Context; import android.os.Build; -import android.preference.RingtonePreference; import android.support.annotation.RequiresApi; import android.support.v7.preference.PreferenceViewHolder; import android.util.AttributeSet; -import android.view.View; import android.widget.TextView; import org.thoughtcrime.securesms.R; diff --git a/src/org/thoughtcrime/securesms/util/TextSecurePreferences.java b/src/org/thoughtcrime/securesms/util/TextSecurePreferences.java index 7149b7bee3..91e19ddb60 100644 --- a/src/org/thoughtcrime/securesms/util/TextSecurePreferences.java +++ b/src/org/thoughtcrime/securesms/util/TextSecurePreferences.java @@ -15,7 +15,7 @@ import android.util.Log; import com.h6ah4i.android.compat.content.SharedPreferenceCompat; import org.thoughtcrime.securesms.R; -import org.thoughtcrime.securesms.preferences.NotificationPrivacyPreference; +import org.thoughtcrime.securesms.preferences.widgets.NotificationPrivacyPreference; import java.io.IOException; import java.util.Arrays;