-
Notifications
You must be signed in to change notification settings - Fork 1
Commit
This commit does not belong to any branch on this repository, and may belong to a fork outside of the repository.
# Conflicts: # settings.gradle # src/conversations/res/values-fr/strings.xml # src/conversations/res/values-pt-rBR/strings.xml # src/main/java/eu/siacs/conversations/parser/IqParser.java # src/main/java/eu/siacs/conversations/services/XmppConnectionService.java # src/main/res/values-fr/strings.xml
- Loading branch information
Showing
357 changed files
with
7,531 additions
and
2,444 deletions.
There are no files selected for viewing
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -1,3 +1,3 @@ | ||
* Wiederkehrende Sicherungen planen | ||
* Realme Geräte von der Anrufintegration ausgenommen | ||
* Realme-Geräte von der Anrufintegration ausgenommen | ||
* Kleine Designverbesserungen (Chatblasen) |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,2 @@ | ||
* Anruf wird nicht mehr stummgeschaltet, wenn das Ausgabegerät gewechselt wird | ||
* Umidigi-Geräte von der Anrufintegration ausgenommen |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1 @@ | ||
* Sicherung als Vordergrunddienst ausführen, damit der Prozess nicht nach 10 Minuten gestoppt wird |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,2 @@ | ||
* Ältere Oppo-Geräte von der Anrufintegration ausgenommen | ||
* Verschiedene Fehlerbehebungen |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1 @@ | ||
* Run Backup as foreground service to prevent process being stopped after 10 minutes |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,2 @@ | ||
* exclude older Oppo devices from call integration | ||
* various bug fixes |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,4 @@ | ||
* Introduction d'un paramètre expert pour faire la découverte de salons sur le serveur local au lieu de search.jabber.network | ||
* Active les coches de délivrance par défaut et supprimer le paramètre | ||
* Active ‘Le bouton Envoyer indique l'état’ par défaut et supprimer le paramètre | ||
* Déplacer les paramètres du service de sauvegarde et de premier plan vers l'écran principal |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,2 @@ | ||
* Arranxo da chamada que deixa de estar silenciada ao cambiar o dispositivo de saída | ||
* Exclusión da integración de chamadas para todos os dispositivos Umidigi |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1 @@ | ||
* Crear a Copia de Apoio usando o servizo en primeiro plano para evitar que sexa detido após 10 minutos |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,2 @@ | ||
* excluír da integración de chamadas aos dispositivos Oppo antigos | ||
* arranxos varios |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,2 @@ | ||
* Corrette le chiamate che venivano smutate cambiando dispositivi di output | ||
* Esclusi tutti i dispositivi Umidigi dall'integrazione di chiamate |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1 @@ | ||
* Avvia backup come servizio in primo piano per impedire che il servizio si fermi dopo 10 minuti |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,2 @@ | ||
* Naprawienie wyłączania wyciszenia rozmowy przy przełączaniu urządzeń wyjściowych | ||
* Wyłączenie wszystkich urządzeń Umidigi z integracji rozmów |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1 @@ | ||
* Uruchamianie kopii zapasowej jako usługi na pierwszym planie, żeby proces nie był zatrzymywany po 10 minutach |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,2 @@ | ||
* Wyłączenie starszych urządzeń Umidigi z integracji rozmów | ||
* Różne poprawki błędów |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,3 @@ | ||
* Planifikim kopjeruajtjesh periodike | ||
* Përjashtim i krejt pajisjeve “realme”, deri te Android 11, nga integrim thirrjesh | ||
* Përmirësime të vockla UI (flluskë mesazhi) |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,2 @@ | ||
* Ndreqje çheshtimi thirrjeje, kur ndërrohet pajisje dëgjimi | ||
* Përjashtim i krejt pajisjeve Umidigi nga integrim thirrjesh |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1 @@ | ||
* Xhirim Kopjeruajtje si shërbim në prapaskenë, për të parandaluar ndalimin e procesit pas 10 minutash |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,2 @@ | ||
* Виправлено ввімкнення звуку виклику при перемиканні пристроїв виводу | ||
* Виключення всіх пристроїв Umidigi з інтеграції викликів |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1 @@ | ||
* Резервне копіювання запускається як процес на передньому плані, щоб запобігти його зупинці через 10 хвилин |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,2 @@ | ||
* Виключення старих пристроїв Oppo з інтеграції викликів | ||
* Виправлення різноманітних помилок |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -1,11 +1,11 @@ | ||
版本2.10.9 | ||
版本 2.10.9 | ||
* 进行音视频通话时请求蓝牙权限(如果您不使用蓝牙耳机可以拒绝) | ||
* 修复呼叫 Movim 时的错误 | ||
* 修复群组聊天的显示错误头像的问题 | ||
* 修复群聊显示错误头像的问题 | ||
* 始终要求选择退出电池优化 | ||
* 在“x 个已连接账号”通知上设置仅本地标志 | ||
* 修复与 Google 地图分享位置插件的交互 | ||
* 移除有关服务器费用的脚注 | ||
* 将文件存储在适合 Android 11 的位置 | ||
* 网络切换后尝试重新连接通话 | ||
* 在来电屏幕中显示来电者JID和帐户JID | ||
* 在来电屏幕中显示来电者 JID 和账号JID |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -1,3 +1,3 @@ | ||
* 计划定期备份 | ||
* 将所有 Android 11 以下的 realme 设备排除在呼叫集成之外 | ||
* 从呼叫集成中排除所有 Android 11 以下的 realme 设备 | ||
* 用户界面(消息气泡)小幅改进 |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,2 @@ | ||
* 修复切换输出设备时呼叫未静音的问题 | ||
* 从呼叫集成中排除所有 Umidigi 设备 |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1 @@ | ||
* 作为前台服务运行备份,防止进程在 10 分钟后停止 |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,2 @@ | ||
* 从呼叫集成中排除较旧的 OPPO 设备 | ||
* 各种错误修复 |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,20 @@ | ||
apply plugin: "java-library" | ||
|
||
repositories { | ||
google() | ||
mavenCentral() | ||
} | ||
|
||
java { | ||
sourceCompatibility = JavaVersion.VERSION_17 | ||
targetCompatibility = JavaVersion.VERSION_17 | ||
} | ||
dependencies { | ||
|
||
implementation project(':libs:annotation') | ||
|
||
annotationProcessor 'com.google.auto.service:auto-service:1.0.1' | ||
api 'com.google.auto.service:auto-service-annotations:1.0.1' | ||
implementation 'com.google.guava:guava:31.1-jre' | ||
|
||
} |
185 changes: 185 additions & 0 deletions
185
...ssor/src/main/java/im/conversations/android/annotation/processor/XmlElementProcessor.java
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,185 @@ | ||
package im.conversations.android.annotation.processor; | ||
|
||
import com.google.auto.service.AutoService; | ||
import com.google.common.base.CaseFormat; | ||
import com.google.common.base.Objects; | ||
import com.google.common.base.Strings; | ||
import com.google.common.collect.ImmutableMap; | ||
|
||
import im.conversations.android.annotation.XmlElement; | ||
import im.conversations.android.annotation.XmlPackage; | ||
|
||
import java.io.IOException; | ||
import java.io.PrintWriter; | ||
import java.util.List; | ||
import java.util.Map; | ||
import java.util.Set; | ||
|
||
import javax.annotation.processing.AbstractProcessor; | ||
import javax.annotation.processing.Processor; | ||
import javax.annotation.processing.RoundEnvironment; | ||
import javax.annotation.processing.SupportedAnnotationTypes; | ||
import javax.annotation.processing.SupportedSourceVersion; | ||
import javax.lang.model.SourceVersion; | ||
import javax.lang.model.element.Element; | ||
import javax.lang.model.element.ExecutableElement; | ||
import javax.lang.model.element.Modifier; | ||
import javax.lang.model.element.PackageElement; | ||
import javax.lang.model.element.TypeElement; | ||
import javax.lang.model.util.ElementFilter; | ||
import javax.tools.JavaFileObject; | ||
|
||
@AutoService(Processor.class) | ||
@SupportedSourceVersion(SourceVersion.RELEASE_17) | ||
@SupportedAnnotationTypes("im.conversations.android.annotation.XmlElement") | ||
public class XmlElementProcessor extends AbstractProcessor { | ||
|
||
@Override | ||
public boolean process(Set<? extends TypeElement> set, RoundEnvironment roundEnvironment) { | ||
final Set<? extends Element> elements = | ||
roundEnvironment.getElementsAnnotatedWith(XmlElement.class); | ||
final ImmutableMap.Builder<Id, String> builder = ImmutableMap.builder(); | ||
for (final Element element : elements) { | ||
if (element instanceof final TypeElement typeElement) { | ||
final Id id = of(typeElement); | ||
builder.put(id, typeElement.getQualifiedName().toString()); | ||
} | ||
} | ||
final ImmutableMap<Id, String> maps = builder.build(); | ||
if (maps.isEmpty()) { | ||
return false; | ||
} | ||
final JavaFileObject extensionFile; | ||
try { | ||
extensionFile = | ||
processingEnv | ||
.getFiler() | ||
.createSourceFile("im.conversations.android.xmpp.Extensions"); | ||
} catch (final IOException e) { | ||
throw new RuntimeException(e); | ||
} | ||
try (final PrintWriter out = new PrintWriter(extensionFile.openWriter())) { | ||
out.println("package im.conversations.android.xmpp;"); | ||
out.println("import com.google.common.collect.BiMap;"); | ||
out.println("import com.google.common.collect.ImmutableBiMap;"); | ||
out.println("import im.conversations.android.xmpp.ExtensionFactory;"); | ||
out.println("import im.conversations.android.xmpp.model.Extension;"); | ||
out.print("\n"); | ||
out.println("public final class Extensions {"); | ||
out.println( | ||
"public static final BiMap<ExtensionFactory.Id, Class<? extends Extension>>" | ||
+ " EXTENSION_CLASS_MAP;"); | ||
out.println("static {"); | ||
out.println( | ||
"final var builder = new ImmutableBiMap.Builder<ExtensionFactory.Id, Class<?" | ||
+ " extends Extension>>();"); | ||
for (final Map.Entry<Id, String> entry : maps.entrySet()) { | ||
Id id = entry.getKey(); | ||
String clazz = entry.getValue(); | ||
out.format( | ||
"builder.put(new ExtensionFactory.Id(\"%s\",\"%s\"),%s.class);", | ||
id.name, id.namespace, clazz); | ||
out.print("\n"); | ||
} | ||
out.println("EXTENSION_CLASS_MAP = builder.build();"); | ||
out.println("}"); | ||
out.println(" private Extensions() {}"); | ||
out.println("}"); | ||
// writing generated file to out … | ||
} catch (IOException e) { | ||
throw new RuntimeException(e); | ||
} | ||
return true; | ||
} | ||
|
||
private static Id of(final TypeElement typeElement) { | ||
final XmlElement xmlElement = typeElement.getAnnotation(XmlElement.class); | ||
final PackageElement packageElement = getPackageElement(typeElement); | ||
final XmlPackage xmlPackage = | ||
packageElement == null ? null : packageElement.getAnnotation(XmlPackage.class); | ||
if (xmlElement == null) { | ||
throw new IllegalStateException( | ||
String.format( | ||
"%s is not annotated as @XmlElement", | ||
typeElement.getQualifiedName().toString())); | ||
} | ||
final String packageNamespace = xmlPackage == null ? null : xmlPackage.namespace(); | ||
final String elementName = xmlElement.name(); | ||
final String elementNamespace = xmlElement.namespace(); | ||
final String namespace; | ||
if (!Strings.isNullOrEmpty(elementNamespace)) { | ||
namespace = elementNamespace; | ||
} else if (!Strings.isNullOrEmpty(packageNamespace)) { | ||
namespace = packageNamespace; | ||
} else { | ||
throw new IllegalStateException( | ||
String.format( | ||
"%s does not declare a namespace", | ||
typeElement.getQualifiedName().toString())); | ||
} | ||
if (!hasEmptyDefaultConstructor(typeElement)) { | ||
throw new IllegalStateException( | ||
String.format( | ||
"%s does not have an empty default constructor", | ||
typeElement.getQualifiedName().toString())); | ||
} | ||
final String name; | ||
if (Strings.isNullOrEmpty(elementName)) { | ||
name = | ||
CaseFormat.UPPER_CAMEL.to( | ||
CaseFormat.LOWER_HYPHEN, typeElement.getSimpleName().toString()); | ||
} else { | ||
name = elementName; | ||
} | ||
return new Id(name, namespace); | ||
} | ||
|
||
private static PackageElement getPackageElement(final TypeElement typeElement) { | ||
final Element parent = typeElement.getEnclosingElement(); | ||
if (parent instanceof PackageElement) { | ||
return (PackageElement) parent; | ||
} else { | ||
final Element nextParent = parent.getEnclosingElement(); | ||
if (nextParent instanceof PackageElement) { | ||
return (PackageElement) nextParent; | ||
} else { | ||
return null; | ||
} | ||
} | ||
} | ||
|
||
private static boolean hasEmptyDefaultConstructor(final TypeElement typeElement) { | ||
final List<ExecutableElement> constructors = | ||
ElementFilter.constructorsIn(typeElement.getEnclosedElements()); | ||
for (final ExecutableElement constructor : constructors) { | ||
if (constructor.getParameters().isEmpty() | ||
&& constructor.getModifiers().contains(Modifier.PUBLIC)) { | ||
return true; | ||
} | ||
} | ||
return false; | ||
} | ||
|
||
public static class Id { | ||
public final String name; | ||
public final String namespace; | ||
|
||
public Id(String name, String namespace) { | ||
this.name = name; | ||
this.namespace = namespace; | ||
} | ||
|
||
@Override | ||
public boolean equals(Object o) { | ||
if (this == o) return true; | ||
if (o == null || getClass() != o.getClass()) return false; | ||
Id id = (Id) o; | ||
return Objects.equal(name, id.name) && Objects.equal(namespace, id.namespace); | ||
} | ||
|
||
@Override | ||
public int hashCode() { | ||
return Objects.hashCode(name, namespace); | ||
} | ||
} | ||
} |
Oops, something went wrong.