forked from mirror/monocles_chat_clean
Merge pull request 'master' (#2) from Arne/monocles_chat:master into master
Reviewed-on: https://codeberg.org/Pirujo/monocles_chat_translate/pulls/2
This commit is contained in:
commit
253642d7b7
12 changed files with 51 additions and 39 deletions
24
build.gradle
24
build.gradle
|
@ -6,7 +6,7 @@ buildscript {
|
|||
mavenCentral()
|
||||
}
|
||||
dependencies {
|
||||
classpath 'com.android.tools.build:gradle:7.2.0'
|
||||
classpath 'com.android.tools.build:gradle:7.2.1'
|
||||
}
|
||||
}
|
||||
|
||||
|
@ -34,7 +34,7 @@ configurations {
|
|||
}
|
||||
|
||||
dependencies {
|
||||
playstoreImplementation('com.google.firebase:firebase-messaging:23.0.2') {
|
||||
playstoreImplementation('com.google.firebase:firebase-messaging:23.0.5') {
|
||||
exclude group: 'com.google.firebase', module: 'firebase-core'
|
||||
exclude group: 'com.google.firebase', module: 'firebase-analytics'
|
||||
exclude group: 'com.google.firebase', module: 'firebase-measurement-connector'
|
||||
|
@ -50,7 +50,7 @@ dependencies {
|
|||
//implementation 'org.webrtc:google-webrtc:1.0.32006'
|
||||
implementation 'org.bouncycastle:bcmail-jdk15on:1.64'
|
||||
implementation 'org.gnu.inet:libidn:1.15'
|
||||
implementation 'com.google.zxing:core:3.3.3' // > 3.3.x not working below SDK 24
|
||||
implementation 'com.google.zxing:core:3.5.0' // > 3.3.x not working below SDK 24
|
||||
implementation 'de.measite.minidns:minidns-hla:0.2.4'
|
||||
implementation 'me.leolin:ShortcutBadger:1.1.22@aar'
|
||||
implementation 'org.whispersystems:signal-protocol-java:2.6.2'
|
||||
|
@ -59,20 +59,20 @@ dependencies {
|
|||
implementation 'com.google.code.gson:gson:2.8.6'
|
||||
implementation 'androidx.multidex:multidex:2.0.1'
|
||||
implementation 'androidx.legacy:legacy-support-v13:1.0.0'
|
||||
implementation 'androidx.appcompat:appcompat:1.3.1' // 1.4.0 needs minCompileSdk 31
|
||||
implementation 'androidx.appcompat:appcompat:1.4.2' // 1.4.0 needs minCompileSdk 31
|
||||
implementation 'androidx.exifinterface:exifinterface:1.3.3'
|
||||
implementation 'androidx.legacy:legacy-support-v4:1.0.0'
|
||||
implementation "androidx.emoji2:emoji2:1.1.0-rc01"
|
||||
gitImplementation "androidx.emoji2:emoji2-bundled:1.1.0-rc01"
|
||||
implementation "androidx.emoji2:emoji2:1.2.0-alpha04"
|
||||
gitImplementation "androidx.emoji2:emoji2-bundled:1.2.0-alpha04"
|
||||
implementation 'androidx.recyclerview:recyclerview:1.2.1'
|
||||
implementation 'com.google.android.material:material:1.4.0'
|
||||
implementation 'com.google.android.material:material:1.6.1'
|
||||
implementation 'androidx.cardview:cardview:1.0.0' // for compatibility
|
||||
implementation 'com.davemorrissey.labs:subsampling-scale-image-view:3.10.0'
|
||||
implementation 'com.google.android.exoplayer:exoplayer-core:2.15.0'
|
||||
implementation 'com.google.android.exoplayer:exoplayer-ui:2.15.0'
|
||||
implementation 'com.google.android.exoplayer:exoplayer-core:2.18.0'
|
||||
implementation 'com.google.android.exoplayer:exoplayer-ui:2.18.0'
|
||||
implementation 'com.wefika:flowlayout:0.4.1'
|
||||
implementation 'com.googlecode.ez-vcard:ez-vcard:0.10.5'
|
||||
implementation 'org.jxmpp:jxmpp-jid:1.0.2'
|
||||
implementation 'org.jxmpp:jxmpp-jid:1.0.3'
|
||||
implementation 'org.hsluv:hsluv:0.2'
|
||||
implementation 'org.conscrypt:conscrypt-android:2.5.2'
|
||||
implementation 'pl.droidsonroids.gif:android-gif-drawable:1.2.24'
|
||||
|
@ -80,7 +80,7 @@ dependencies {
|
|||
implementation 'org.osmdroid:osmdroid-android:6.1.11'
|
||||
implementation 'com.leinardi.android:speed-dial:3.2.0'
|
||||
implementation 'com.squareup.picasso:picasso:2.71828'
|
||||
implementation 'com.squareup.okhttp3:okhttp:4.9.2'
|
||||
implementation 'com.squareup.okhttp3:okhttp:4.9.3'
|
||||
implementation 'com.squareup.retrofit2:retrofit:2.9.0'
|
||||
implementation 'com.squareup.retrofit2:converter-gson:2.9.0'
|
||||
implementation 'com.google.guava:guava:31.0.1-android'
|
||||
|
@ -102,7 +102,7 @@ android {
|
|||
compileSdkVersion 31
|
||||
|
||||
defaultConfig {
|
||||
minSdkVersion 21
|
||||
minSdkVersion 24
|
||||
targetSdkVersion 30
|
||||
|
||||
//versionNameSuffix " beta_(2021-12-19)" // " beta_(XXXX-XX-XX)" // activate for beta versions
|
||||
|
|
|
@ -10,6 +10,7 @@ import java.util.List;
|
|||
import java.util.Locale;
|
||||
import java.util.Random;
|
||||
|
||||
import eu.siacs.conversations.BuildConfig;
|
||||
import eu.siacs.conversations.crypto.XmppDomainVerifier;
|
||||
import eu.siacs.conversations.services.ProviderService;
|
||||
import eu.siacs.conversations.xmpp.Jid;
|
||||
|
@ -57,10 +58,10 @@ public final class Config {
|
|||
public static final String LOGTAG = BuildConfig.LOGTAG;
|
||||
|
||||
public static final Jid BUG_REPORTS = Jid.of("support@monocles.de");
|
||||
public static final Uri HELP = Uri.parse("https://monocles.de/howto");
|
||||
public static final Uri HELP = Uri.parse("https://monocles.wiki");
|
||||
|
||||
public static final String inviteUserURL = "https://" + monocles() + "/i/";
|
||||
public static final String inviteMUCURL = "https://" + monocles() + "/j/";
|
||||
public static final String inviteUserURL = monocles() + "/i/";
|
||||
public static final String inviteMUCURL = monocles() + "/j/";
|
||||
public static final String inviteHostURL = monocles(); // without http(s)
|
||||
public static final String INVITE_DOMAIN = monocles();
|
||||
public static final String termsOfUseURL = "https://monocles.de/impressum/";
|
||||
|
|
|
@ -665,6 +665,7 @@ public class Account extends AbstractEntity implements AvatarService.Avatarable
|
|||
ONLINE(false),
|
||||
NO_INTERNET(false),
|
||||
UNAUTHORIZED,
|
||||
TEMPORARY_AUTH_FAILURE,
|
||||
SERVER_NOT_FOUND,
|
||||
REGISTRATION_SUCCESSFUL(false),
|
||||
REGISTRATION_FAILED(true, false),
|
||||
|
|
|
@ -131,6 +131,7 @@ public class IqGenerator extends AbstractGenerator {
|
|||
|
||||
public IqPacket publishNick(String nick) {
|
||||
final Element item = new Element("item");
|
||||
item.setAttribute("id", "current");
|
||||
item.addChild("nick", Namespace.NICK).setContent(nick);
|
||||
return publish(Namespace.NICK, item);
|
||||
}
|
||||
|
|
|
@ -192,7 +192,7 @@ public class ConversationsActivity extends XmppActivity implements OnConversatio
|
|||
Log.d(Config.LOGTAG, "Device is running Android < SDK 23, no restart required: " + FirstStartTime);
|
||||
}
|
||||
|
||||
Intent intent = pendingViewIntent.pop();
|
||||
final Intent intent = pendingViewIntent.pop();
|
||||
if (intent != null) {
|
||||
if (processViewIntent(intent)) {
|
||||
if (binding.secondaryFragment != null) {
|
||||
|
@ -237,7 +237,7 @@ public class ConversationsActivity extends XmppActivity implements OnConversatio
|
|||
notifyFragmentOfBackendConnected(id);
|
||||
}
|
||||
|
||||
ActivityResult activityResult = postponedActivityResult.pop();
|
||||
final ActivityResult activityResult = postponedActivityResult.pop();
|
||||
if (activityResult != null) {
|
||||
handleActivityResult(activityResult);
|
||||
}
|
||||
|
|
|
@ -32,6 +32,7 @@ import androidx.databinding.DataBindingUtil;
|
|||
|
||||
import com.davemorrissey.labs.subscaleview.ImageSource;
|
||||
import com.davemorrissey.labs.subscaleview.SubsamplingScaleImageView;
|
||||
import com.google.android.exoplayer2.MediaItem;
|
||||
import com.google.android.exoplayer2.PlaybackException;
|
||||
import com.google.android.exoplayer2.Player;
|
||||
import com.google.android.exoplayer2.SimpleExoPlayer;
|
||||
|
@ -331,7 +332,7 @@ public class MediaViewerActivity extends XmppActivity implements AudioManager.On
|
|||
player.setRepeatMode(Player.REPEAT_MODE_OFF);
|
||||
binding.messageVideoView.setPlayer(player);
|
||||
DataSource.Factory dataSourceFactory = new DefaultDataSourceFactory(this, System.getProperty("http.agent"));
|
||||
MediaSource videoSource = new ProgressiveMediaSource.Factory(dataSourceFactory).createMediaSource(uri);
|
||||
MediaSource videoSource = new ProgressiveMediaSource.Factory(dataSourceFactory).createMediaSource(MediaItem.fromUri(uri));
|
||||
player.prepare(videoSource);
|
||||
requestAudioFocus();
|
||||
setVolumeControlStream(AudioManager.STREAM_MUSIC);
|
||||
|
|
|
@ -53,6 +53,7 @@ import javax.net.ssl.SSLSocketFactory;
|
|||
import javax.net.ssl.X509KeyManager;
|
||||
import javax.net.ssl.X509TrustManager;
|
||||
|
||||
import com.google.common.base.Strings;
|
||||
import eu.siacs.conversations.BuildConfig;
|
||||
import eu.siacs.conversations.Config;
|
||||
import eu.siacs.conversations.R;
|
||||
|
@ -519,20 +520,25 @@ public class XmppConnection implements Runnable {
|
|||
} else if (nextTag.isStart("failure")) {
|
||||
final Element failure = tagReader.readElement(nextTag);
|
||||
if (Namespace.SASL.equals(failure.getNamespace())) {
|
||||
final String text = failure.findChildContent("text");
|
||||
if (failure.hasChild("account-disabled") && text != null) {
|
||||
Matcher matcher = Patterns.AUTOLINK_WEB_URL.matcher(text);
|
||||
if (failure.hasChild("temporary-auth-failure")) {
|
||||
throw new StateChangingException(Account.State.TEMPORARY_AUTH_FAILURE);
|
||||
} else if (failure.hasChild("account-disabled")) {
|
||||
final String text = failure.findChildContent("text");
|
||||
if ( Strings.isNullOrEmpty(text)) {
|
||||
throw new StateChangingException(Account.State.UNAUTHORIZED);
|
||||
}
|
||||
final Matcher matcher = Patterns.AUTOLINK_WEB_URL.matcher(text);
|
||||
if (matcher.find()) {
|
||||
final HttpUrl url;
|
||||
try {
|
||||
url = HttpUrl.get(text.substring(matcher.start(), matcher.end()));
|
||||
if (url.isHttps()) {
|
||||
this.redirectionUrl = url;
|
||||
throw new StateChangingException(Account.State.PAYMENT_REQUIRED);
|
||||
}
|
||||
} catch (IllegalArgumentException e) {
|
||||
} catch (final IllegalArgumentException e) {
|
||||
throw new StateChangingException(Account.State.UNAUTHORIZED);
|
||||
}
|
||||
if (url.isHttps()) {
|
||||
this.redirectionUrl = url;
|
||||
throw new StateChangingException(Account.State.PAYMENT_REQUIRED);
|
||||
}
|
||||
}
|
||||
}
|
||||
throw new StateChangingException(Account.State.UNAUTHORIZED);
|
||||
|
|
|
@ -569,9 +569,9 @@ public class JingleConnectionManager extends AbstractConnectionManager {
|
|||
}
|
||||
}
|
||||
synchronized (this.rtpSessionProposals) {
|
||||
for (Map.Entry<RtpSessionProposal, DeviceDiscoveryState> entry :
|
||||
for (final Map.Entry<RtpSessionProposal, DeviceDiscoveryState> entry :
|
||||
this.rtpSessionProposals.entrySet()) {
|
||||
RtpSessionProposal proposal = entry.getKey();
|
||||
final RtpSessionProposal proposal = entry.getKey();
|
||||
if (proposal.account == contact.getAccount()
|
||||
&& contact.getJid().asBareJid().equals(proposal.with)) {
|
||||
final DeviceDiscoveryState preexistingState = entry.getValue();
|
||||
|
|
|
@ -1176,4 +1176,5 @@
|
|||
<string name="orbot_not_found">Orbot nicht gefunden</string>
|
||||
<string name="participants">Teilnehmer</string>
|
||||
<string name="download_failed_invalid_file">Download fehlgeschlagen: Ungültige Datei</string>
|
||||
<string name="account_status_temporary_auth_failure">Temporärer Authentifizierungsfehler</string>
|
||||
</resources>
|
||||
|
|
|
@ -42,11 +42,11 @@
|
|||
<string name="invidious_host">monocles.live</string>
|
||||
<bool name="plain_text_logs">false</bool>
|
||||
<bool name="validate_hostname">false</bool>
|
||||
<bool name="show_foreground_service">false</bool>
|
||||
<bool name="show_foreground_service">true</bool>
|
||||
<bool name="warn_unencrypted_chat">true</bool>
|
||||
<bool name="hide_you_are_not_participating">false</bool>
|
||||
<bool name="use_bundled_emoji">true</bool>
|
||||
<bool name="enable_multi_accounts">false</bool>
|
||||
<bool name="enable_multi_accounts">true</bool>
|
||||
<bool name="show_qr_code_scan">true</bool>
|
||||
<bool name="show_individual_search_options">true</bool>
|
||||
<bool name="show_combined_search_options">false</bool>
|
||||
|
@ -96,7 +96,7 @@
|
|||
<bool name="easy_downloader">false</bool>
|
||||
<bool name="hide_memory_warning">false</bool>
|
||||
<bool name="pause_voice">false</bool>
|
||||
<bool name="show_date_in_quotes">true</bool>
|
||||
<bool name="show_date_in_quotes">false</bool>
|
||||
<integer name="individual_notification">0</integer>
|
||||
|
||||
<!--
|
||||
|
@ -119,7 +119,7 @@
|
|||
</string-array>
|
||||
|
||||
<string-array name="support_site">
|
||||
<item>https://monocles.de/howto/</item>
|
||||
<item>https://monocles.wiki</item>
|
||||
<item>https://www.jabber.de/support/</item>
|
||||
<item>https://dismail.de/contact.html</item>
|
||||
<item>https://www.draugr.de/kontakt/</item>
|
||||
|
|
|
@ -1203,4 +1203,5 @@
|
|||
<string name="participants">Participants</string>
|
||||
<string name="download_failed_invalid_file">Download failed: Invalid file</string>
|
||||
<string name="orbot_not_found">Orbot not found</string>
|
||||
<string name="account_status_temporary_auth_failure">Temporary authentication failure</string>
|
||||
</resources>
|
||||
|
|
|
@ -8,7 +8,7 @@
|
|||
<intent
|
||||
android:action="android.intent.action.VIEW"
|
||||
android:targetClass="eu.siacs.conversations.ui.SettingsActivity"
|
||||
android:targetPackage="@string/applicationId">
|
||||
android:targetPackage="de.monocles.chat">
|
||||
<extra
|
||||
android:name="page"
|
||||
android:value="userinterface" />
|
||||
|
@ -129,7 +129,7 @@
|
|||
<intent
|
||||
android:action="android.intent.action.VIEW"
|
||||
android:targetClass="eu.siacs.conversations.ui.SettingsActivity"
|
||||
android:targetPackage="@string/applicationId">
|
||||
android:targetPackage="de.monocles.chat">
|
||||
<extra
|
||||
android:name="page"
|
||||
android:value="notifications" />
|
||||
|
@ -146,7 +146,7 @@
|
|||
<intent
|
||||
android:action="android.intent.action.VIEW"
|
||||
android:targetClass="eu.siacs.conversations.ui.SettingsActivity"
|
||||
android:targetPackage="@string/applicationId">
|
||||
android:targetPackage="de.monocles.chat">
|
||||
<extra
|
||||
android:name="page"
|
||||
android:value="quiet_hours" />
|
||||
|
@ -218,7 +218,7 @@
|
|||
<intent
|
||||
android:action="android.intent.action.VIEW"
|
||||
android:targetClass="eu.siacs.conversations.ui.SettingsActivity"
|
||||
android:targetPackage="@string/applicationId">
|
||||
android:targetPackage="de.monocles.chat">
|
||||
<extra
|
||||
android:name="page"
|
||||
android:value="attachments" />
|
||||
|
@ -279,7 +279,7 @@
|
|||
<intent
|
||||
android:action="android.intent.action.VIEW"
|
||||
android:targetClass="eu.siacs.conversations.ui.SettingsActivity"
|
||||
android:targetPackage="@string/applicationId">
|
||||
android:targetPackage="de.monocles.chat">
|
||||
<extra
|
||||
android:name="page"
|
||||
android:value="presence" />
|
||||
|
@ -316,7 +316,7 @@
|
|||
<intent
|
||||
android:action="android.intent.action.VIEW"
|
||||
android:targetClass="eu.siacs.conversations.ui.SettingsActivity"
|
||||
android:targetPackage="@string/applicationId">
|
||||
android:targetPackage="de.monocles.chat">
|
||||
<extra
|
||||
android:name="page"
|
||||
android:value="security" />
|
||||
|
@ -453,7 +453,7 @@
|
|||
<intent
|
||||
android:action="android.intent.action.VIEW"
|
||||
android:targetClass="eu.siacs.conversations.ui.SettingsActivity"
|
||||
android:targetPackage="@string/applicationId">
|
||||
android:targetPackage="de.monocles.chat">
|
||||
<extra
|
||||
android:name="page"
|
||||
android:value="expert" />
|
||||
|
|
Loading…
Add table
Reference in a new issue