mirror of
https://github.com/ArcaneChat/android.git
synced 2026-07-03 14:05:24 +02:00
Get channels out of experimental (#4403)
* Get channels out of experimental * Update CHANGELOG.md Co-authored-by: adb <adb@merlinux.eu>
This commit is contained in:
@@ -5,7 +5,6 @@ import androidx.annotation.NonNull;
|
||||
import com.b44t.messenger.DcContact;
|
||||
import com.b44t.messenger.DcContext;
|
||||
import org.thoughtcrime.securesms.util.AsyncLoader;
|
||||
import org.thoughtcrime.securesms.util.Prefs;
|
||||
import org.thoughtcrime.securesms.util.Util;
|
||||
|
||||
public class DcContactsLoader extends AsyncLoader<DcContactsLoader.Ret> {
|
||||
@@ -53,10 +52,7 @@ public class DcContactsLoader extends AsyncLoader<DcContactsLoader.Ret> {
|
||||
}
|
||||
if (query == null && addCreateGroupLinks) {
|
||||
additional_items = Util.appendInt(additional_items, DcContact.DC_CONTACT_ID_NEW_GROUP);
|
||||
|
||||
final boolean broadcastsEnabled = Prefs.isNewBroadcastAvailable(getContext());
|
||||
if (broadcastsEnabled)
|
||||
additional_items = Util.appendInt(additional_items, DcContact.DC_CONTACT_ID_NEW_BROADCAST);
|
||||
additional_items = Util.appendInt(additional_items, DcContact.DC_CONTACT_ID_NEW_BROADCAST);
|
||||
|
||||
if (!dcContext.isChatmail()) {
|
||||
additional_items =
|
||||
|
||||
@@ -151,24 +151,6 @@ public class AdvancedPreferenceFragment extends ListSummaryPreferenceFragment
|
||||
}
|
||||
updateWebxdcStoreSummary();
|
||||
|
||||
Preference newBroadcastList = this.findPreference("pref_new_broadcast_list");
|
||||
if (newBroadcastList != null) {
|
||||
newBroadcastList.setOnPreferenceChangeListener(
|
||||
(preference, newValue) -> {
|
||||
if ((Boolean) newValue) {
|
||||
new AlertDialog.Builder(requireActivity())
|
||||
.setTitle("Thanks for trying out \"Channels\"!")
|
||||
.setMessage(
|
||||
"• You can now create new \"Channels\" from the \"New Chat\" dialog\n\n"
|
||||
+ "• If you want to quit the experimental feature, you can disable it at \"Settings / Advanced\"")
|
||||
.setCancelable(false)
|
||||
.setPositiveButton(R.string.ok, null)
|
||||
.show();
|
||||
}
|
||||
return true;
|
||||
});
|
||||
}
|
||||
|
||||
Preference locationStreamingEnabled = this.findPreference("pref_location_streaming_enabled");
|
||||
if (locationStreamingEnabled != null) {
|
||||
locationStreamingEnabled.setOnPreferenceChangeListener(
|
||||
|
||||
@@ -198,10 +198,6 @@ public class Prefs {
|
||||
}
|
||||
}
|
||||
|
||||
public static boolean isNewBroadcastAvailable(Context context) {
|
||||
return getBooleanPreference(context, "pref_new_broadcast_list", false);
|
||||
}
|
||||
|
||||
// ringtone
|
||||
|
||||
public static @NonNull Uri getNotificationRingtone(Context context) {
|
||||
|
||||
Reference in New Issue
Block a user