diff --git a/.github/workflows/benchmark.yml b/.github/workflows/benchmark.yml index 7447a37f8..be28358ee 100644 --- a/.github/workflows/benchmark.yml +++ b/.github/workflows/benchmark.yml @@ -25,13 +25,13 @@ jobs: - name: Setup Flutter uses: subosito/flutter-action@v2.8.0 with: - flutter-version: '3.32.4' + flutter-version: '3.35.4' channel: 'stable' - name: Setup Dependencies run: | sudo apt-get update -y - sudo apt-get install -y ninja-build libgtk-3-dev libolm3 libmpv-dev mpv ffmpeg libmimalloc-dev + sudo apt-get install -y ninja-build libgtk-3-dev libmpv-dev mpv ffmpeg libmimalloc-dev - name: Configure Flutter diff --git a/.github/workflows/build.yml b/.github/workflows/build.yml index 9b421e91d..f9daa625d 100644 --- a/.github/workflows/build.yml +++ b/.github/workflows/build.yml @@ -10,7 +10,7 @@ env: jobs: build-windows: - runs-on: windows-latest + runs-on: windows-2022 steps: - name: Checkout uses: actions/checkout@v2 @@ -20,7 +20,7 @@ jobs: - name: Setup Flutter uses: subosito/flutter-action@v2.8.0 with: - flutter-version: '3.32.4' + flutter-version: '3.35.4' channel: 'stable' - name: Configure Flutter @@ -48,7 +48,7 @@ jobs: - name: Setup Flutter uses: subosito/flutter-action@v2.8.0 with: - flutter-version: '3.32.4' + flutter-version: '3.35.4' channel: 'stable' - name: Setup Java @@ -59,7 +59,7 @@ jobs: - name: Setup Tools run: | sudo apt-get update -y - sudo apt-get install -y ninja-build libgtk-3-dev libolm3 libmpv-dev mpv ffmpeg + sudo apt-get install -y ninja-build libgtk-3-dev libmpv-dev mpv ffmpeg - name: Code Generation run: | @@ -82,7 +82,7 @@ jobs: - name: Setup Flutter uses: subosito/flutter-action@v2.8.0 with: - flutter-version: '3.32.4' + flutter-version: '3.35.4' channel: 'stable' - name: Setup Java @@ -93,7 +93,7 @@ jobs: - name: Setup Tools run: | sudo apt-get update -y - sudo apt-get install -y ninja-build libgtk-3-dev libolm3 libmpv-dev mpv ffmpeg + sudo apt-get install -y ninja-build libgtk-3-dev libmpv-dev mpv ffmpeg - name: Code Generation run: | @@ -117,13 +117,13 @@ jobs: - name: Setup Flutter uses: subosito/flutter-action@v2.8.0 with: - flutter-version: '3.32.4' + flutter-version: '3.35.4' channel: 'stable' - name: Setup Tools run: | sudo apt-get update -y - sudo apt-get install -y ninja-build libgtk-3-dev libolm3 libmpv-dev mpv ffmpeg libmimalloc-dev webkit2gtk-4.1 + sudo apt-get install -y ninja-build libgtk-3-dev libmpv-dev mpv ffmpeg libmimalloc-dev webkit2gtk-4.1 - name: Code Generation run: | @@ -150,13 +150,13 @@ jobs: - name: Setup Flutter uses: subosito/flutter-action@v2.8.0 with: - flutter-version: '3.32.4' + flutter-version: '3.35.4' channel: 'stable' - name: Setup Tools run: | sudo apt-get update -y - sudo apt-get install -y ninja-build libgtk-3-dev libolm3 libmpv-dev mpv ffmpeg + sudo apt-get install -y ninja-build libgtk-3-dev libmpv-dev mpv ffmpeg - name: Code Generation run: | diff --git a/.github/workflows/integration-test.yml b/.github/workflows/integration-test.yml index b815656a3..e341dfb9f 100644 --- a/.github/workflows/integration-test.yml +++ b/.github/workflows/integration-test.yml @@ -22,13 +22,13 @@ jobs: - name: Setup Flutter ╰(✿˙ᗜ˙)੭━☆゚.*・。゚ uses: subosito/flutter-action@v2.8.0 with: - flutter-version: '3.32.4' + flutter-version: '3.35.4' channel: 'stable' - name: Setup Tools ᕙ|” ◉ ◡ ◉ ”|ᕗ run: | sudo apt-get update -y - sudo apt-get install -y ninja-build libgtk-3-dev libolm3 libmpv-dev mpv ffmpeg libmimalloc-dev + sudo apt-get install -y ninja-build libgtk-3-dev libmpv-dev mpv ffmpeg libmimalloc-dev - name: Start Synapse [◯ ‸ ◯] run: | diff --git a/.github/workflows/release.yml b/.github/workflows/release.yml index 219d6155b..65200b5d7 100644 --- a/.github/workflows/release.yml +++ b/.github/workflows/release.yml @@ -12,7 +12,7 @@ env: jobs: release-windows: - runs-on: windows-latest + runs-on: windows-2022 steps: - name: Checkout uses: actions/checkout@v2 @@ -22,21 +22,9 @@ jobs: - name: Setup Flutter uses: subosito/flutter-action@v2.8.0 with: - flutter-version: '3.32.4' + flutter-version: '3.35.4' channel: 'stable' - - name: Clone Olm - run: | - git clone https://gitlab.matrix.org/matrix-org/olm.git - cd ./olm - git checkout 7e0c8277032e40308987257b711b38af8d77cc69 - - - name: Build Olm - run: | - cd ./olm - cmake -DCMAKE_BUILD_TYPE=Release . -A x64 -Bbuild - cmake --build build --config Release - - name: Configure Flutter run: flutter config --enable-windows-desktop @@ -51,14 +39,6 @@ jobs: cd .\commet dart run scripts/build_release.dart --platform windows --version_tag ${{ github.event.release.tag_name || 'v0.0.0-artifact' }} --git_hash ${{ github.sha }} - - name: Include libolm - run: | - dir - dir .\olm - dir .\commet - dir .\commet\build\windows - move .\olm\build\Release\olm.dll .\commet\build\windows\x64\runner\Release\libolm.dll - - name: Archive run: tar -a -c -f commet-windows.zip -C .\commet\build\windows\x64\runner\ Release @@ -92,7 +72,7 @@ jobs: - name: Setup Flutter uses: subosito/flutter-action@v2.8.0 with: - flutter-version: '3.32.4' + flutter-version: '3.35.4' channel: 'stable' - name: Setup Java @@ -103,7 +83,7 @@ jobs: - name: Setup Tools run: | sudo apt-get update -y - sudo apt-get install -y ninja-build libgtk-3-dev libolm3 libmpv-dev mpv ffmpeg + sudo apt-get install -y ninja-build libgtk-3-dev libmpv-dev mpv ffmpeg - name: Code Generation run: | @@ -149,7 +129,7 @@ jobs: - name: Setup Flutter uses: subosito/flutter-action@v2.8.0 with: - flutter-version: '3.32.4' + flutter-version: '3.35.4' channel: 'stable' - name: Setup Java @@ -160,7 +140,7 @@ jobs: - name: Setup Tools run: | sudo apt-get update -y - sudo apt-get install -y ninja-build libgtk-3-dev libolm3 libmpv-dev mpv ffmpeg + sudo apt-get install -y ninja-build libgtk-3-dev libmpv-dev mpv ffmpeg - name: Code Generation run: | @@ -211,13 +191,13 @@ jobs: - name: Setup Flutter uses: subosito/flutter-action@v2.8.0 with: - flutter-version: '3.32.4' + flutter-version: '3.35.4' channel: 'stable' - name: Setup Tools run: | sudo apt-get update -y - sudo apt-get install -y ninja-build libgtk-3-dev libolm3 libmpv-dev mpv ffmpeg libmimalloc-dev webkit2gtk-4.1 + sudo apt-get install -y ninja-build libgtk-3-dev libmpv-dev mpv ffmpeg libmimalloc-dev webkit2gtk-4.1 libasound2-dev - name: Code Generation run: | @@ -269,13 +249,13 @@ jobs: - name: Setup Flutter uses: subosito/flutter-action@v2.8.0 with: - flutter-version: '3.32.4' + flutter-version: '3.35.4' channel: 'stable' - name: Setup Tools run: | sudo apt-get update -y - sudo apt-get install -y ninja-build libgtk-3-dev libolm3 libmpv-dev mpv ffmpeg libmimalloc-dev flatpak-builder flatpak webkit2gtk-4.1 + sudo apt-get install -y ninja-build libgtk-3-dev libmpv-dev mpv ffmpeg libmimalloc-dev flatpak-builder flatpak webkit2gtk-4.1 - name: Code Generation run: | @@ -290,7 +270,7 @@ jobs: - name: Create Flatpak run: | sudo flatpak remote-add --if-not-exists flathub https://flathub.org/repo/flathub.flatpakrepo - sudo flatpak install -y flathub org.freedesktop.Platform//24.08 org.freedesktop.Sdk//24.08 + sudo flatpak install -y flathub org.gnome.Platform//48 org.gnome.Sdk//48 mkdir -p commet/linux/flatpak/commet cp -r $PROJECT_PATH/build/linux/x64/release/bundle $PROJECT_PATH/linux/flatpak/commet/bundle version=$(echo ${{ github.event.release.tag_name || 'v0.0.0-artifact' }} | grep -oP '[0-9]+([.][0-9]+)+') @@ -330,13 +310,13 @@ jobs: - name: Setup Flutter uses: subosito/flutter-action@v2.8.0 with: - flutter-version: '3.32.4' + flutter-version: '3.35.4' channel: 'stable' - name: Setup Tools run: | sudo apt-get update -y - sudo apt-get install -y ninja-build libgtk-3-dev libolm3 libmpv-dev mpv ffmpeg libmimalloc-dev webkit2gtk-4.1 + sudo apt-get install -y ninja-build libgtk-3-dev libmpv-dev mpv ffmpeg libmimalloc-dev webkit2gtk-4.1 - name: Code Generation run: | @@ -383,30 +363,27 @@ jobs: - name: Setup Flutter uses: subosito/flutter-action@v2.8.0 with: - flutter-version: '3.32.4' + flutter-version: '3.35.4' channel: 'stable' - name: Setup Tools run: | sudo apt-get update -y - sudo apt-get install -y ninja-build libgtk-3-dev libolm3 libmpv-dev mpv ffmpeg webkit2gtk-4.1 + sudo apt-get install -y ninja-build libgtk-3-dev libmpv-dev mpv ffmpeg webkit2gtk-4.1 - name: Code Generation run: | cd $PROJECT_PATH dart run scripts/codegen.dart - - - name: Include Olm + + - uses: moonrepo/setup-rust@v1 + - run: rustup component add rust-src --toolchain nightly-x86_64-unknown-linux-gnu + + - name: Prepare web run: | cd $PROJECT_PATH - cd assets/js - rm -r package - curl -L 'https://github.com/famedly/olm/releases/download/v2.0.0/olm.zip' > olm.zip - sha256sum -c <<< '644bbc7cdcf5931fb64c1b556a3672830ca2af6615caa814458785043895c6df olm.zip' - unzip olm.zip - rm olm.zip - mv javascript package - + ./scripts/prepare-web.sh + - name: Build Web run: | cd $PROJECT_PATH diff --git a/.github/workflows/static-analysis.yml b/.github/workflows/static-analysis.yml index cc11460cd..b3ef3a184 100644 --- a/.github/workflows/static-analysis.yml +++ b/.github/workflows/static-analysis.yml @@ -19,13 +19,13 @@ jobs: - name: Setup Flutter ╰(✿˙ᗜ˙)੭━☆゚.*・。゚ uses: subosito/flutter-action@v2.8.0 with: - flutter-version: '3.32.4' + flutter-version: '3.35.4' channel: 'stable' - name: Setup Tools ᕙ|” ◉ ◡ ◉ ”|ᕗ run: | sudo apt-get update -y - sudo apt-get install -y ninja-build libgtk-3-dev libolm3 libmpv-dev mpv libmimalloc-dev + sudo apt-get install -y ninja-build libgtk-3-dev libmpv-dev mpv libmimalloc-dev - name: Configure Flutter (∩`-´)⊃━☆゚.*・。゚ run: flutter config --enable-linux-desktop diff --git a/.gitignore b/.gitignore index bf49e5e8d..2b0b2b3c9 100644 --- a/.gitignore +++ b/.gitignore @@ -3,3 +3,6 @@ commet/coverage/lcov.info commet/assets/js/package/olm.js commet/assets/js/package/olm.wasm commet/assets/js/package/olm_legacy.js +commet/.vodozemac/ +commet/assets/vodozemac/vodozemac_bindings_dart_bg.wasm +commet/assets/vodozemac/vodozemac_bindings_dart.js diff --git a/README.md b/README.md index 4ef39371e..a0a530a22 100644 --- a/README.md +++ b/README.md @@ -42,7 +42,7 @@ Help translate Commet to your language on [Weblate](https://hosted.weblate.org/p # Development -Commet is built using [Flutter](https://flutter.dev), currently v3.32.4 +Commet is built using [Flutter](https://flutter.dev), currently v3.35.4 This repo currently has a monorepo structure, containing two flutter projects: Commet and Tiamat. Commet is the main client, and Tiamat is a sort of wrapper around Material with some extra goodies, which is used to maintain a consistent style across the app. Tiamat may eventually be moved to its own repo, but for now it is maintained here for ease of development. ## Building @@ -52,7 +52,7 @@ This repo currently has a monorepo structure, containing two flutter projects: C ### 2. Install Libraries Commet requires some additional libraries to be built ```bash -sudo apt-get install -y ninja-build libgtk-3-dev libolm3 libmpv-dev mpv ffmpeg libmimalloc-dev +sudo apt-get install -y ninja-build libgtk-3-dev libmpv-dev mpv ffmpeg libmimalloc-dev ``` ### 3. Fetch Dependencies diff --git a/commet/analysis_options.yaml b/commet/analysis_options.yaml index 79c0e6644..33305c6cf 100644 --- a/commet/analysis_options.yaml +++ b/commet/analysis_options.yaml @@ -1,5 +1,3 @@ -include: package:flutter_lints/flutter.yaml - analyzer: errors: curly_braces_in_flow_control_structures: ignore @@ -8,4 +6,5 @@ analyzer: - lib/generated/*.dart - lib/generated/l10n/*.dart - lib/main.widgetbook.dart - - integration_test/** \ No newline at end of file + - integration_test/** + - lib/generated/** \ No newline at end of file diff --git a/commet/android/build.gradle b/commet/android/build.gradle index aa3b1f57c..202a6f273 100644 --- a/commet/android/build.gradle +++ b/commet/android/build.gradle @@ -15,7 +15,7 @@ subprojects { if (project.plugins.hasPlugin("com.android.application") || project.plugins.hasPlugin("com.android.library")) { project.android { - compileSdkVersion 35 + compileSdkVersion 36 buildToolsVersion "34.0.0" } } diff --git a/commet/assets/vodozemac/.gitkeep b/commet/assets/vodozemac/.gitkeep new file mode 100644 index 000000000..e69de29bb diff --git a/commet/integration_test/README.md b/commet/integration_test/README.md index ca28a839a..4700454bd 100644 --- a/commet/integration_test/README.md +++ b/commet/integration_test/README.md @@ -2,7 +2,6 @@ To run unit tests, there are a few prerequisites. - - Make sure you have `libolm3` installed `sudo apt install libolm3` - Run Code Generation [scripts/codegen.dart](../scripts/codegen.dart) - Configure environment variables [. scripts/setup-env.sh](../scripts/setup-env.sh) - Start the synapse docker server [scripts/integration-server-synapse.sh](../scripts/integration-server-synapse.sh) diff --git a/commet/lib/client/call_manager.dart b/commet/lib/client/call_manager.dart index 00262d342..e01e66fd9 100644 --- a/commet/lib/client/call_manager.dart +++ b/commet/lib/client/call_manager.dart @@ -126,7 +126,7 @@ class CallManager { player = null; } - onCallStateChanged(VoipSession event) { + void onCallStateChanged(VoipSession event) { if (event.state == VoipState.connected || event.state == VoipState.connecting) { stopRingtone(); diff --git a/commet/lib/client/client_manager.dart b/commet/lib/client/client_manager.dart index e609e1195..f39c906af 100644 --- a/commet/lib/client/client_manager.dart +++ b/commet/lib/client/client_manager.dart @@ -9,10 +9,8 @@ import 'package:commet/client/matrix/matrix_client.dart'; import 'package:commet/client/stale_info.dart'; import 'package:commet/client/tasks/client_connection_status_task.dart'; import 'package:commet/main.dart'; -import 'package:commet/ui/pages/developer/app_inspector/value_reflector_widget.dart'; import 'package:commet/utils/notifying_list.dart'; -@Reflector() class ClientManager { final Map _clients = {}; diff --git a/commet/lib/client/components/push_notification/android/android_notifier.dart b/commet/lib/client/components/push_notification/android/android_notifier.dart index a4b1c0db3..704826c88 100644 --- a/commet/lib/client/components/push_notification/android/android_notifier.dart +++ b/commet/lib/client/components/push_notification/android/android_notifier.dart @@ -142,9 +142,10 @@ class AndroidNotifier implements Notifier { shortcutId: content.roomId, silent: content.priority == NotificationPriority.low, ticker: content.content, - bubbleActivity: - bubblesEnabled ? "chat.commet.commetapp.BubbleActivity" : null, - bubbleExtra: bubblesEnabled ? payload : null, + bubble: bubblesEnabled + ? BubbleMetadata("chat.commet.commetapp.BubbleActivity", + extra: payload) + : null, color: const Color.fromARGB(0xff, 0x53, 0x4c, 0xdd)); await flutterLocalNotificationsPlugin?.show( diff --git a/commet/lib/client/components/push_notification/linux/linux_notifier.dart b/commet/lib/client/components/push_notification/linux/linux_notifier.dart index 1fe84010f..f7cf9065c 100644 --- a/commet/lib/client/components/push_notification/linux/linux_notifier.dart +++ b/commet/lib/client/components/push_notification/linux/linux_notifier.dart @@ -86,10 +86,10 @@ class LinuxNotifier implements Notifier { @override Future notify(NotificationContent notification) async { switch (notification.runtimeType) { - case MessageNotificationContent: + case MessageNotificationContent _: return displayMessageNotification( notification as MessageNotificationContent); - case CallNotificationContent: + case CallNotificationContent _: return displayCallNotification(notification as CallNotificationContent); default: } diff --git a/commet/lib/client/components/push_notification/notification_content.dart b/commet/lib/client/components/push_notification/notification_content.dart index 72f4e55ad..260ad47de 100644 --- a/commet/lib/client/components/push_notification/notification_content.dart +++ b/commet/lib/client/components/push_notification/notification_content.dart @@ -29,7 +29,7 @@ class MessageNotificationContent extends NotificationContent { required String senderName, required this.senderId, required this.roomName, - required String content, + required super.content, required this.eventId, required this.roomId, required this.clientId, @@ -37,7 +37,7 @@ class MessageNotificationContent extends NotificationContent { this.roomImage, this.senderImage, this.attachedImage, - }) : super(title: senderName, content: content); + }) : super(title: senderName); } class CallNotificationContent extends NotificationContent { diff --git a/commet/lib/client/components/room_component.dart b/commet/lib/client/components/room_component.dart index afeafde2d..ba605deb4 100644 --- a/commet/lib/client/components/room_component.dart +++ b/commet/lib/client/components/room_component.dart @@ -6,7 +6,7 @@ abstract class RoomComponent late T _room; T get room => _room; - RoomComponent(R client, T room) : super(client) { + RoomComponent(super.client, T room) { _room = room; } } diff --git a/commet/lib/client/components/space_component.dart b/commet/lib/client/components/space_component.dart index 102ba18a1..fe89f2a6a 100644 --- a/commet/lib/client/components/space_component.dart +++ b/commet/lib/client/components/space_component.dart @@ -6,7 +6,7 @@ abstract class SpaceComponent late T _space; T get space => _space; - SpaceComponent(R client, T space) : super(client) { + SpaceComponent(super.client, T space) { _space = space; } } diff --git a/commet/lib/client/matrix/auth/matrix_sso_login_flow.dart b/commet/lib/client/matrix/auth/matrix_sso_login_flow.dart index 7261ea801..84a51ba5d 100644 --- a/commet/lib/client/matrix/auth/matrix_sso_login_flow.dart +++ b/commet/lib/client/matrix/auth/matrix_sso_login_flow.dart @@ -12,6 +12,7 @@ import 'package:universal_html/html.dart' as html; import 'package:matrix/matrix.dart' as matrix; class MatrixSSOLoginFlow implements SsoLoginFlow { + @override String? id; String? brand; diff --git a/commet/lib/client/matrix/components/rtc_data_channel/matrix_rtc_data_channel_component.dart b/commet/lib/client/matrix/components/rtc_data_channel/matrix_rtc_data_channel_component.dart index a2b91a73f..ca9690f72 100644 --- a/commet/lib/client/matrix/components/rtc_data_channel/matrix_rtc_data_channel_component.dart +++ b/commet/lib/client/matrix/components/rtc_data_channel/matrix_rtc_data_channel_component.dart @@ -36,7 +36,8 @@ class MatrixRTCDataChannelComponent return MatrixRtcDataChannel(sesh, channel, purpose: purpose); } - dataChannelOpenedCallback(MatrixVoipSession session, RTCDataChannel channel) { + void dataChannelOpenedCallback( + MatrixVoipSession session, RTCDataChannel channel) { var newChannel = MatrixRtcDataChannel(session, channel); if (newChannel.purpose == diff --git a/commet/lib/client/matrix/database/matrix_database_html.dart b/commet/lib/client/matrix/database/matrix_database_html.dart index b5a6ce4af..7c3956919 100644 --- a/commet/lib/client/matrix/database/matrix_database_html.dart +++ b/commet/lib/client/matrix/database/matrix_database_html.dart @@ -4,7 +4,7 @@ import 'package:universal_html/html.dart' as html; Future getMatrixDatabaseImplementation(String clientName) async { await html.window.navigator.storage?.persist(); - var db = MatrixSdkDatabase(clientName); + var db = await MatrixSdkDatabase.init(clientName); await db.open(); return db; } diff --git a/commet/lib/client/matrix/matrix_client.dart b/commet/lib/client/matrix/matrix_client.dart index 45492d404..dc7f661cf 100644 --- a/commet/lib/client/matrix/matrix_client.dart +++ b/commet/lib/client/matrix/matrix_client.dart @@ -18,7 +18,6 @@ import 'package:commet/debug/log.dart'; import 'package:commet/diagnostic/diagnostics.dart'; import 'package:commet/main.dart'; import 'package:commet/ui/navigation/adaptive_dialog.dart'; -import 'package:commet/ui/pages/developer/app_inspector/value_reflector_widget.dart'; import 'package:commet/ui/pages/matrix/authentication/matrix_uia_request.dart'; import 'package:commet/utils/list_extension.dart'; import 'package:commet/utils/notifying_list.dart'; @@ -31,14 +30,14 @@ import 'package:flutter/material.dart'; import 'package:intl/intl.dart'; import 'package:matrix/matrix.dart' as matrix; import 'package:matrix/encryption.dart'; +import 'package:flutter_vodozemac/flutter_vodozemac.dart' as vodozemac; import '../../ui/atoms/code_block.dart'; import '../../ui/pages/matrix/verification/matrix_verification_page.dart'; import 'matrix_room.dart'; import 'matrix_space.dart'; -import 'package:olm/olm.dart' as olm; +import 'package:vodozemac/vodozemac.dart' as vod; -@Reflector() class MatrixClient extends Client { late matrix.Client _matrixClient; late final List> componentsInternal; @@ -70,7 +69,8 @@ class MatrixClient extends Client { ? const matrix.NativeImplementationsDummy() : matrix.NativeImplementationsIsolate(compute); - MatrixClient({required String identifier}) { + MatrixClient( + {required String identifier, required matrix.DatabaseApi database}) { if (preferences.developerMode) { matrix.Logs().level = matrix.Level.verbose; } else { @@ -78,12 +78,17 @@ class MatrixClient extends Client { } _id = identifier; - _matrixClient = _createMatrixClient(identifier); + _matrixClient = _createMatrixClient(identifier, database); _matrixClient.onSync.stream.listen(onMatrixClientSync); componentsInternal = ComponentRegistry.getMatrixComponents(this); } + static Future create(String identifier) async { + final database = await getMatrixDatabase(identifier); + return MatrixClient(identifier: identifier, database: database); + } + static String hash(String name) { var bytes = utf8.encode(name); var hash = sha256.convert(bytes); @@ -140,6 +145,13 @@ class MatrixClient extends Client { "Text that explains to the user that libolm dependency is not found", ); + static String get matrixClientVodozemacMissingMessage => Intl.message( + "vodozemac is not installed or was not found. End to End Encryption will not be available until this is resolved", + name: "matrixClientVodozemacMissingMessage", + desc: + "Text that explains to the user that vodozemac dependency is not found", + ); + static String get matrixClientEncryptionWarningTitle => Intl.message( "Encryption Warning", name: "matrixClientEncryptionWarningTitle", @@ -157,7 +169,7 @@ class MatrixClient extends Client { if (clients != null) { for (var clientName in clients) { - var client = MatrixClient(identifier: clientName); + var client = await MatrixClient.create(clientName); manager.addClient(client); futures.add(Diagnostics.general .timeAsync("Initializing client $clientName", () async { @@ -183,13 +195,15 @@ class MatrixClient extends Client { static Future _checkSystem(ClientManager clientManager) async { try { - await olm.init(); - olm.get_library_version(); + await vod.init(wasmPath: './assets/assets/vodozemac/'); + if (!vod.isInitialized()) { + throw Exception("Vodozemac failed to initialize!"); + } } catch (exception) { clientManager.alertManager.addAlert(Alert( AlertType.warning, titleGetter: () => matrixClientEncryptionWarningTitle, - messageGetter: () => matrixClientOlmMissingMessage, + messageGetter: () => matrixClientVodozemacMissingMessage, )); } } @@ -197,7 +211,8 @@ class MatrixClient extends Client { static matrix.NativeImplementations get nativeImplementations => BuildConfig.WEB ? const matrix.NativeImplementationsDummy() - : matrix.NativeImplementationsIsolate(compute); + : matrix.NativeImplementationsIsolate(compute, + vodozemacInit: vodozemac.init); @override Future init(bool loadingFromCache, {bool isBackgroundService = false}) async { @@ -267,7 +282,7 @@ class MatrixClient extends Client { @override bool isLoggedIn() => _matrixClient.isLogged(); - matrix.Client _createMatrixClient(String name) { + matrix.Client _createMatrixClient(String name, matrix.DatabaseApi database) { var client = matrix.Client( name, verificationMethods: { @@ -284,7 +299,7 @@ class MatrixClient extends Client { matrix.AuthenticationTypes.sso }, nativeImplementations: nativeImplementations, - databaseBuilder: (client) => getMatrixDatabase(client.clientName), + database: database, logLevel: matrix.Level.verbose, ); @@ -315,7 +330,7 @@ class MatrixClient extends Client { Future _updateOwnProfile() async { final id = _matrixClient.userID; if (id != null) { - var data = await _matrixClient.database!.getUserProfile(id); + var data = await _matrixClient.database.getUserProfile(id); if (data != null) { self = MatrixProfile( _matrixClient, diff --git a/commet/lib/client/matrix/matrix_mxc_image_provider.dart b/commet/lib/client/matrix/matrix_mxc_image_provider.dart index e0fa180a6..1d2204792 100644 --- a/commet/lib/client/matrix/matrix_mxc_image_provider.dart +++ b/commet/lib/client/matrix/matrix_mxc_image_provider.dart @@ -11,18 +11,17 @@ import '../../utils/image/lod_image.dart'; class MatrixMxcImage extends LODImageProvider { Uri identifier; MatrixMxcImage(this.identifier, Client matrixClient, - {String? blurhash, + {super.blurhash, bool? doThumbnail, bool? doFullres, bool cache = true, - bool autoLoadFullRes = true, + super.autoLoadFullRes, super.thumbnailHeight, super.fullResHeight, Event? matrixEvent}) : super( id: "$identifier-$doThumbnail-$doFullres-$thumbnailHeight-$fullResHeight", - blurhash: blurhash, loadThumbnail: (doThumbnail == null || doThumbnail == true) ? () => loadMatrixThumbnail( matrixClient, identifier, matrixEvent, cache: cache) @@ -30,8 +29,7 @@ class MatrixMxcImage extends LODImageProvider { loadFullRes: (doFullres == null || doFullres == true) ? () => loadMatrixFullRes(matrixClient, identifier, matrixEvent, cache: cache) - : null, - autoLoadFullRes: autoLoadFullRes); + : null); static String getThumbnailIdentifier(Uri uri) { return "matrix_thumbnail-$uri"; diff --git a/commet/lib/client/matrix/matrix_profile.dart b/commet/lib/client/matrix/matrix_profile.dart index 9ff8a0a90..ebee0dce5 100644 --- a/commet/lib/client/matrix/matrix_profile.dart +++ b/commet/lib/client/matrix/matrix_profile.dart @@ -1,11 +1,9 @@ import 'package:commet/client/matrix/matrix_member.dart'; import 'package:commet/client/matrix/matrix_mxc_image_provider.dart'; import 'package:commet/client/profile.dart'; -import 'package:commet/ui/pages/developer/app_inspector/value_reflector_widget.dart'; import 'package:flutter/widgets.dart'; import 'package:matrix/matrix.dart' as matrix; -@Reflector() class MatrixProfile implements Profile { matrix.Profile profile; matrix.Client client; diff --git a/commet/lib/client/matrix/matrix_room.dart b/commet/lib/client/matrix/matrix_room.dart index 1c28fe4c6..ed17086a9 100644 --- a/commet/lib/client/matrix/matrix_room.dart +++ b/commet/lib/client/matrix/matrix_room.dart @@ -35,7 +35,6 @@ import 'package:commet/client/timeline_events/timeline_event_message.dart'; import 'package:commet/config/build_config.dart'; import 'package:commet/debug/log.dart'; import 'package:commet/main.dart'; -import 'package:commet/ui/pages/developer/app_inspector/value_reflector_widget.dart'; import 'package:commet/utils/image_utils.dart'; import 'package:commet/utils/mime.dart'; import 'package:flutter/material.dart'; @@ -50,7 +49,6 @@ import '../attachment.dart'; import '../client.dart'; import 'package:matrix/matrix.dart' as matrix; -@Reflector() class MatrixRoom extends Room { late matrix.Room _matrixRoom; diff --git a/commet/lib/client/matrix/matrix_space.dart b/commet/lib/client/matrix/matrix_space.dart index aa4e7589b..3b12293c5 100644 --- a/commet/lib/client/matrix/matrix_space.dart +++ b/commet/lib/client/matrix/matrix_space.dart @@ -11,14 +11,12 @@ import 'package:commet/client/matrix/matrix_room_permissions.dart'; import 'package:commet/client/matrix/matrix_room_preview.dart'; import 'package:commet/client/permissions.dart'; import 'package:commet/client/room_preview.dart'; -import 'package:commet/ui/pages/developer/app_inspector/value_reflector_widget.dart'; import 'package:commet/utils/notifying_list.dart'; import 'package:flutter/material.dart'; import 'package:matrix/matrix.dart' as matrix; import 'matrix_peer.dart'; -@Reflector() class MatrixSpace extends Space { late matrix.Room _matrixRoom; late matrix.Client _matrixClient; diff --git a/commet/lib/client/matrix/matrix_timeline.dart b/commet/lib/client/matrix/matrix_timeline.dart index ee43e6da7..e0b621156 100644 --- a/commet/lib/client/matrix/matrix_timeline.dart +++ b/commet/lib/client/matrix/matrix_timeline.dart @@ -6,12 +6,10 @@ import 'package:commet/client/matrix/timeline_events/matrix_timeline_event.dart' import 'package:commet/client/timeline_events/timeline_event.dart'; import 'package:commet/client/timeline_events/timeline_event_message.dart'; import 'package:commet/client/timeline_events/timeline_event_sticker.dart'; -import 'package:commet/ui/pages/developer/app_inspector/value_reflector_widget.dart'; import '../client.dart'; import 'package:matrix/matrix.dart' as matrix; -@Reflector() class MatrixTimeline extends Timeline { matrix.Timeline? _matrixTimeline; late matrix.Room _matrixRoom; diff --git a/commet/lib/client/matrix/timeline_events/matrix_timeline_event.dart b/commet/lib/client/matrix/timeline_events/matrix_timeline_event.dart index e17d85abf..7948e14a9 100644 --- a/commet/lib/client/matrix/timeline_events/matrix_timeline_event.dart +++ b/commet/lib/client/matrix/timeline_events/matrix_timeline_event.dart @@ -34,7 +34,6 @@ abstract class MatrixTimelineEvent implements TimelineEvent { matrix.EventStatus.sending => TimelineEventStatus.sending, matrix.EventStatus.sent => TimelineEventStatus.sent, matrix.EventStatus.synced => TimelineEventStatus.synced, - matrix.EventStatus.roomState => TimelineEventStatus.roomState, }; @override diff --git a/commet/lib/config/app_config.dart b/commet/lib/config/app_config.dart index c10221da3..d1f1952ef 100644 --- a/commet/lib/config/app_config.dart +++ b/commet/lib/config/app_config.dart @@ -1,4 +1,4 @@ -library config; +library; import 'package:commet/config/build_config.dart'; import 'package:path/path.dart'; diff --git a/commet/lib/main.dart b/commet/lib/main.dart index fd716dfa5..bc7d37a1d 100644 --- a/commet/lib/main.dart +++ b/commet/lib/main.dart @@ -11,8 +11,8 @@ import 'package:commet/config/platform_utils.dart'; import 'package:commet/config/preferences.dart'; import 'package:commet/debug/log.dart'; import 'package:commet/diagnostic/diagnostics.dart'; +import 'package:commet/generated/intl/messages_all.dart'; import 'package:commet/generated/l10n.dart'; -import 'package:commet/generated/l10n/messages_all_locales.dart'; import 'package:commet/ui/pages/bubble/bubble_page.dart'; import 'package:commet/ui/pages/fatal_error/fatal_error_page.dart'; import 'package:commet/ui/pages/login/login_page.dart'; @@ -246,12 +246,11 @@ void enableEdgeToEdge() async { class App extends StatelessWidget { const App( - {Key? key, + {super.key, required this.clientManager, this.initialTheme, this.initialRoom, - this.initialClientId}) - : super(key: key); + this.initialClientId}); final ThemeData? initialTheme; final ClientManager clientManager; diff --git a/commet/lib/ui/atoms/pill.dart b/commet/lib/ui/atoms/pill.dart index f8f4ecb6c..bde7d8826 100644 --- a/commet/lib/ui/atoms/pill.dart +++ b/commet/lib/ui/atoms/pill.dart @@ -9,14 +9,14 @@ class Pill extends StatelessWidget { final ImageProvider? image; const Pill({ - Key? key, + super.key, required this.identifier, required this.url, required this.displayText, this.future, this.onTap, this.image, - }) : super(key: key); + }); @override build(BuildContext context) { diff --git a/commet/lib/ui/atoms/rich_text_field.dart b/commet/lib/ui/atoms/rich_text_field.dart index 0aee99506..a93246364 100644 --- a/commet/lib/ui/atoms/rich_text_field.dart +++ b/commet/lib/ui/atoms/rich_text_field.dart @@ -6,7 +6,7 @@ import 'package:markdown/markdown.dart' as md; import 'package:tiamat/config/config.dart'; class RichTextEditingController extends TextEditingController { - RichTextEditingController({String? text}) : super(text: text); + RichTextEditingController({super.text}); @override TextSpan buildTextSpan( diff --git a/commet/lib/ui/atoms/scaled_safe_area.dart b/commet/lib/ui/atoms/scaled_safe_area.dart index 01dd33a41..15c6cd085 100644 --- a/commet/lib/ui/atoms/scaled_safe_area.dart +++ b/commet/lib/ui/atoms/scaled_safe_area.dart @@ -6,16 +6,11 @@ class ScaledSafeArea extends SafeArea { const ScaledSafeArea({ super.key, required super.child, - bool bottom = true, - bool top = true, - bool left = true, - bool right = true, - }) : super( - bottom: bottom, - top: top, - right: right, - left: left, - ); + super.bottom, + super.top, + super.left, + super.right, + }); @override Widget build(BuildContext context) { diff --git a/commet/lib/ui/molecules/overlapping_panels.dart b/commet/lib/ui/molecules/overlapping_panels.dart index 06acbf55c..cb9821970 100644 --- a/commet/lib/ui/molecules/overlapping_panels.dart +++ b/commet/lib/ui/molecules/overlapping_panels.dart @@ -44,8 +44,7 @@ class OverlappingPanels extends StatefulWidget { this.restWidth = 40, this.onSideChange, this.onDragStart, - Key? key}) - : super(key: key); + super.key}); static OverlappingPanelsState? of(BuildContext context) { return context.findAncestorStateOfType(); diff --git a/commet/lib/ui/molecules/timeline_events/events/timeline_event_view_reactions.dart b/commet/lib/ui/molecules/timeline_events/events/timeline_event_view_reactions.dart index 69717b836..57d81bf8a 100644 --- a/commet/lib/ui/molecules/timeline_events/events/timeline_event_view_reactions.dart +++ b/commet/lib/ui/molecules/timeline_events/events/timeline_event_view_reactions.dart @@ -51,7 +51,7 @@ class _TimelineEventViewReactionsState extends State }).toList()); } - onReactionTapped(Emoticon emote) { + void onReactionTapped(Emoticon emote) { if (reactions[emote]?.contains(currentUserIdentifier) == true) { widget.timeline.room.removeReaction(event, emote); } else { diff --git a/commet/lib/ui/molecules/user_list.dart b/commet/lib/ui/molecules/user_list.dart index c76a69a8f..9a5d90d94 100644 --- a/commet/lib/ui/molecules/user_list.dart +++ b/commet/lib/ui/molecules/user_list.dart @@ -114,11 +114,6 @@ class _RoomMemberListState extends State { return null; } - if (index == 0) { - return importantMembers?[index].$2 ?? - widget.room.getMemberRole(roomMembers[index].identifier); - } - if (index == importantMembers?.length) { var user = getDisplayUser(index); return widget.room.getMemberRole(user.identifier); @@ -126,6 +121,11 @@ class _RoomMemberListState extends State { if (importantMembers != null && index < importantMembers!.length) { var role = importantMembers![index].$2; + + if (index == 0) { + return role; + } + var prevRole = importantMembers![index - 1].$2; if (prevRole != role) { diff --git a/commet/lib/ui/organisms/chat/chat_view.dart b/commet/lib/ui/organisms/chat/chat_view.dart index 1fb4f7116..9c23e5192 100644 --- a/commet/lib/ui/organisms/chat/chat_view.dart +++ b/commet/lib/ui/organisms/chat/chat_view.dart @@ -78,7 +78,7 @@ class ChatView extends StatelessWidget { state.room.timeline!.markAsRead(event); } - clearNotifications(Room room) { + void clearNotifications(Room room) { // if we clear notifications when opening bubble, the bubble disappears if (state.isBubble) { return; diff --git a/commet/lib/ui/organisms/sidebar_call_icon/sidebar_calls_list.dart b/commet/lib/ui/organisms/sidebar_call_icon/sidebar_calls_list.dart index 704c717d1..be19d965b 100644 --- a/commet/lib/ui/organisms/sidebar_call_icon/sidebar_calls_list.dart +++ b/commet/lib/ui/organisms/sidebar_call_icon/sidebar_calls_list.dart @@ -80,7 +80,7 @@ class _SidebarCallsListState extends State { ); } - addOverlay() { + void addOverlay() { overlay = OverlayEntry(builder: buildOverlay); Overlay.of(context).insert(overlay!); } @@ -144,7 +144,7 @@ class _SidebarCallsListState extends State { updateHover(false); } - onSelectionUpdate( + void onSelectionUpdate( LayerLink link, VoipSession session, bool showWhileUnhovered) { setState(() { this.link = link; diff --git a/commet/lib/ui/organisms/space_summary/space_summary.dart b/commet/lib/ui/organisms/space_summary/space_summary.dart index 8ae818f7c..5e2800f04 100644 --- a/commet/lib/ui/organisms/space_summary/space_summary.dart +++ b/commet/lib/ui/organisms/space_summary/space_summary.dart @@ -83,11 +83,11 @@ class _SpaceSummaryState extends State { NavigationUtils.navigateTo(context, SpaceSettingsPage(space: widget.space)); } - openRoomSettings(Room room) { + void openRoomSettings(Room room) { NavigationUtils.navigateTo(context, RoomSettingsPage(room: room)); } - onAddRoomButtonTap() { + void onAddRoomButtonTap() { AdaptiveDialog.show(context, builder: (dialogContext) => AddSpaceOrRoom.askCreateOrExistingRoom( client: widget.space.client, diff --git a/commet/lib/ui/pages/add_space_or_room/add_space_or_room.dart b/commet/lib/ui/pages/add_space_or_room/add_space_or_room.dart index 69d14d93b..d03b7aa56 100644 --- a/commet/lib/ui/pages/add_space_or_room/add_space_or_room.dart +++ b/commet/lib/ui/pages/add_space_or_room/add_space_or_room.dart @@ -39,7 +39,7 @@ class AddSpaceOrRoom extends StatefulWidget { State createState() => AddSpaceOrRoomState(); const AddSpaceOrRoom.askCreateOrExistingRoom( - {Key? key, + {super.key, List? rooms, this.client, this.clients, @@ -49,8 +49,7 @@ class AddSpaceOrRoom extends StatefulWidget { eligibleRooms = rooms, createSpace = null, joinRoom = null, - joinSpace = null, - super(key: key); + joinSpace = null; } class AddSpaceOrRoomState extends State { diff --git a/commet/lib/ui/pages/developer/app_inspector/app_inspector_page.dart b/commet/lib/ui/pages/developer/app_inspector/app_inspector_page.dart deleted file mode 100644 index cfece26f6..000000000 --- a/commet/lib/ui/pages/developer/app_inspector/app_inspector_page.dart +++ /dev/null @@ -1,40 +0,0 @@ -import 'package:commet/main.dart'; -import 'package:commet/ui/atoms/scaled_safe_area.dart'; -import 'package:commet/ui/pages/developer/app_inspector/value_reflector_widget.dart'; -import 'package:flutter/material.dart'; -import 'package:tiamat/tiamat.dart' as tiamat; - -class AppInspectorPage extends StatelessWidget { - const AppInspectorPage({super.key}); - - @override - Widget build(BuildContext context) { - return Scaffold( - body: SingleChildScrollView( - child: ScaledSafeArea( - child: SelectionArea( - child: Column( - crossAxisAlignment: CrossAxisAlignment.start, - children: [ - Padding( - padding: const EdgeInsets.all(8.0), - child: tiamat.CircleButton( - icon: Icons.arrow_back, - radius: 27, - onPressed: () => Navigator.of(context).pop(), - ), - ), - const Padding( - padding: EdgeInsets.all(20.0), - child: tiamat.Text.body( - "Warning: This inspector allows you to view lots of information that would typically be hidden, some of which could be sensitive. It is recommended that you do not view this page if your screen may be visible to others\n\nWhile effort has been made to redact sensitive information, we cannot guarantee that we have caught everything. Continue at your own risk."), - ), - ValueReflectorWidget(value: clientManager!) - ], - ), - ), - ), - ), - ); - } -} diff --git a/commet/lib/ui/pages/developer/app_inspector/field_inspector.dart b/commet/lib/ui/pages/developer/app_inspector/field_inspector.dart deleted file mode 100644 index 1a02c4550..000000000 --- a/commet/lib/ui/pages/developer/app_inspector/field_inspector.dart +++ /dev/null @@ -1,143 +0,0 @@ -import 'package:commet/ui/pages/developer/app_inspector/reflectable_extensions.dart'; -import 'package:commet/ui/pages/developer/app_inspector/value_reflector_widget.dart'; -import 'package:flutter/material.dart'; -import 'package:reflectable/reflectable.dart'; -import 'package:tiamat/tiamat.dart' as tiamat; - -class FieldInspector extends StatefulWidget { - const FieldInspector( - {required this.declaration, required this.instance, super.key}); - final MethodMirror declaration; - final dynamic instance; - @override - State createState() => FieldInspectorState(); -} - -class FieldInspectorState extends State { - dynamic fieldValue; - - @override - void initState() { - try { - final result = ReflectableExtensions.invoke( - widget.instance, widget.declaration.simpleName); - fieldValue = result; - } catch (_) {} - - super.initState(); - } - - static String displayValue(dynamic value) { - if (value == null) { - return "null"; - } - - if (value is String) { - return value; - } - - try { - var v = "$value name: ${value.name}"; - return v; - } catch (_) {} - - try { - var v = "$value displayname: ${value.displayname}"; - return v; - } catch (_) {} - - try { - var v = "$value displayName: ${value.displayName}"; - return v; - } catch (_) {} - - try { - var v = "$value id: ${value.id}"; - return v; - } catch (_) {} - - return value.toString(); - } - - @override - Widget build(BuildContext context) { - final color = (Theme.of(context).brightness == Brightness.dark - ? Colors.white - : Colors.black) - .withAlpha(7); - - return ExpansionTile( - expandedCrossAxisAlignment: CrossAxisAlignment.start, - expandedAlignment: Alignment.topLeft, - backgroundColor: color, - dense: true, - title: Row( - children: [ - tiamat.Text(widget.declaration.simpleName.toString()), - const SizedBox(width: 20), - Flexible( - child: tiamat.Text.labelLow( - displayValue(fieldValue), - maxLines: 1, - overflow: TextOverflow.ellipsis, - ), - ) - ], - ), - children: [buildValue(fieldValue)], - ); - } - - Widget buildValue(dynamic value, {int index = 0}) { - if (value == null) { - return const tiamat.Text("null"); - } - - if (value is List) { - return Column( - mainAxisAlignment: MainAxisAlignment.start, - crossAxisAlignment: CrossAxisAlignment.start, - children: (value) - .mapIndexed((e, i) => Container(child: buildValue(e))) - .toList(), - ); - } - - if (value is Map) { - return Column( - crossAxisAlignment: CrossAxisAlignment.start, - children: value.keys.mapIndexed((e, i) { - var label = displayValue(e); - if (label == "") { - label = "\"\""; - } - return Padding( - padding: const EdgeInsets.fromLTRB(10, 0, 0, 0), - child: Column( - crossAxisAlignment: CrossAxisAlignment.start, - mainAxisAlignment: MainAxisAlignment.start, - mainAxisSize: MainAxisSize.min, - children: [ - tiamat.Text.labelLow( - "$label:", - ), - Padding( - padding: const EdgeInsets.fromLTRB(10, 0, 0, 0), - child: buildValue(value[e], index: i), - ) - ], - ), - ); - }).toList(), - ); - } - - return Padding( - padding: const EdgeInsets.fromLTRB(20, 0, 0, 0), - child: ValueReflectorWidget( - value: value, - index: index, - ), - ); - } -} diff --git a/commet/lib/ui/pages/developer/app_inspector/reflectable_extensions.dart b/commet/lib/ui/pages/developer/app_inspector/reflectable_extensions.dart deleted file mode 100644 index 53a234ec5..000000000 --- a/commet/lib/ui/pages/developer/app_inspector/reflectable_extensions.dart +++ /dev/null @@ -1,10 +0,0 @@ -// ignore: implementation_imports -import 'package:reflectable/src/reflectable_builder_based.dart' as builder; - -class ReflectableExtensions { - static Object? invoke(dynamic object, String name) { - var getter = builder.data.values.first.getters[name]!; - var result = getter(object); - return result; - } -} diff --git a/commet/lib/ui/pages/developer/app_inspector/reflectable_matrix_client.dart b/commet/lib/ui/pages/developer/app_inspector/reflectable_matrix_client.dart deleted file mode 100644 index bbd9ae436..000000000 --- a/commet/lib/ui/pages/developer/app_inspector/reflectable_matrix_client.dart +++ /dev/null @@ -1,40 +0,0 @@ -import 'package:commet/ui/pages/developer/app_inspector/value_reflector_widget.dart'; -import 'package:matrix/matrix.dart' as matrix; -// ignore: implementation_imports -import 'package:matrix/src/utils/space_child.dart'; - -@Reflector() -class ReflectableMatrixClient extends matrix.Client { - ReflectableMatrixClient(super.clientName); -} - -@Reflector() -class ReflectableMatrixRoom extends matrix.Room { - ReflectableMatrixRoom({required super.id, required super.client}); -} - -@Reflector() -class ReflectableMatrixEvent extends matrix.Event { - ReflectableMatrixEvent( - {required super.content, - required super.type, - required super.eventId, - required super.senderId, - required super.originServerTs, - required super.room}); -} - -@Reflector() -class ReflectableMatrixSpaceChild extends SpaceChild { - ReflectableMatrixSpaceChild.fromState(super.state) : super.fromState(); -} - -@Reflector() -class ReflectableMatrixSpaceParent extends SpaceParent { - ReflectableMatrixSpaceParent.fromState(super.state) : super.fromState(); -} - -@Reflector() -class ReflectableMatrixBasicEvent extends matrix.BasicEvent { - ReflectableMatrixBasicEvent({required super.type, required super.content}); -} diff --git a/commet/lib/ui/pages/developer/app_inspector/value_reflector_widget.dart b/commet/lib/ui/pages/developer/app_inspector/value_reflector_widget.dart deleted file mode 100644 index ceaa07ff4..000000000 --- a/commet/lib/ui/pages/developer/app_inspector/value_reflector_widget.dart +++ /dev/null @@ -1,100 +0,0 @@ -import 'package:commet/main.reflectable.dart'; -import 'package:commet/ui/pages/developer/app_inspector/field_inspector.dart'; -import 'package:commet/ui/pages/developer/app_inspector/reflectable_matrix_client.dart'; -import 'package:flutter/material.dart'; -import 'package:reflectable/reflectable.dart'; -import 'package:tiamat/tiamat.dart' as tiamat; -import 'package:matrix/matrix.dart' as matrix; - -// ignore: implementation_imports -import 'package:matrix/src/utils/space_child.dart'; - -class Reflector extends Reflectable { - const Reflector() - : super(typingCapability, invokingCapability, - libraryDependenciesCapability); -} - -const reflector = Reflector(); - -class ValueReflectorWidget extends StatefulWidget { - const ValueReflectorWidget({required this.value, super.key, this.index = 0}); - final dynamic value; - final int index; - - @override - State createState() => _ValueReflectorWidgetState(); -} - -class _ValueReflectorWidgetState extends State { - ClassMirror? classMirror; - late List keys; - @override - void initState() { - initializeReflectable(); - - var type = { - matrix.Client: ReflectableMatrixClient, - matrix.Room: ReflectableMatrixRoom, - matrix.Event: ReflectableMatrixEvent, - SpaceChild: ReflectableMatrixSpaceChild, - SpaceParent: ReflectableMatrixSpaceParent, - matrix.BasicEvent: ReflectableMatrixBasicEvent - }[widget.value.runtimeType] ?? - widget.value.runtimeType; - - if (reflector.canReflectType(type)) { - classMirror = reflector.reflectType(type) as ClassMirror; - keys = classMirror!.instanceMembers.keys.toList() - ..sort((a, b) => a.compareTo(b)) - ..removeWhere((e) => - classMirror!.instanceMembers[e]!.isRegularMethod || - classMirror!.instanceMembers[e]!.isSetter); - } - - super.initState(); - } - - @override - Widget build(BuildContext context) { - if (classMirror == null) { - return tiamat.Text.labelLow(widget.value.toString()); - } - - final color = (Theme.of(context).brightness == Brightness.dark - ? Colors.white - : Colors.black) - .withAlpha(7); - - return Padding( - padding: const EdgeInsets.all(2), - child: ExpansionTile( - backgroundColor: color, - title: - tiamat.Text.label(FieldInspectorState.displayValue(widget.value)), - children: [ - Column( - crossAxisAlignment: CrossAxisAlignment.stretch, - mainAxisSize: MainAxisSize.min, - children: keys.mapIndexed((e, i) { - if ([ - "accessToken", - "bearerToken", - "fingerprintKey", - "identityKey" - ].contains(e)) { - return Padding( - padding: const EdgeInsets.fromLTRB(8, 4, 0, 4), - child: tiamat.Text.error("$e (Redacted)"), - ); - } - - return FieldInspector( - declaration: classMirror!.instanceMembers[e]!, - instance: widget.value, - ); - }).toList()), - ]), - ); - } -} diff --git a/commet/lib/ui/pages/developer/benchmarks/timeline_viewer_benchmark.dart b/commet/lib/ui/pages/developer/benchmarks/timeline_viewer_benchmark.dart index 607af6fea..e275d5d22 100644 --- a/commet/lib/ui/pages/developer/benchmarks/timeline_viewer_benchmark.dart +++ b/commet/lib/ui/pages/developer/benchmarks/timeline_viewer_benchmark.dart @@ -17,17 +17,18 @@ class BenchmarkTimelineViewer extends StatefulWidget { } class _BenchmarkTimelineViewerState extends State { - late Timeline timeline; + Timeline? timeline; @override void initState() { - var client = MatrixClient(identifier: "benchmark"); - client.mockComponents(); - client.self = MatrixProfile(client.getMatrixClient(), - matrix.Profile(userId: '@benchy:matrix.org', displayName: 'benchy')); + MatrixClient.create("benchmark").then((client) { + client.mockComponents(); + client.self = MatrixProfile(client.getMatrixClient(), + matrix.Profile(userId: '@benchy:matrix.org', displayName: 'benchy')); - var room = client.createRoomWithData(); - timeline = room.getBenchmarkTimeline(); + var room = client.createRoomWithData(); + timeline = room.getBenchmarkTimeline(); + }); super.initState(); } @@ -38,11 +39,13 @@ class _BenchmarkTimelineViewerState extends State { onPressed: () => Navigator.of(context).pop(), child: const Icon(Icons.chevron_left), ), - body: RoomTimelineWidgetView( - key: const ValueKey("timeline-viewer-benchmark"), - timeline: timeline, - // doMessageOverlayMenu: false, - ), + body: timeline != null + ? RoomTimelineWidgetView( + key: const ValueKey("timeline-viewer-benchmark"), + timeline: timeline!, + // doMessageOverlayMenu: false, + ) + : Container(), ); } } diff --git a/commet/lib/ui/pages/login/login_page.dart b/commet/lib/ui/pages/login/login_page.dart index 427413e3d..5c222cc45 100644 --- a/commet/lib/ui/pages/login/login_page.dart +++ b/commet/lib/ui/pages/login/login_page.dart @@ -39,7 +39,7 @@ class LoginPageState extends State { StreamSubscription? progressSubscription; double? progress; List? loginFlows; - late Client loginClient; + Client? loginClient; final Debouncer homeserverUpdateDebouncer = Debouncer(delay: const Duration(seconds: 1)); @@ -51,10 +51,12 @@ class LoginPageState extends State { @override void initState() { var internalId = RandomUtils.getRandomString(20); - loginClient = MatrixClient(identifier: internalId); + MatrixClient.create(internalId).then((client) { + loginClient = client; - progressSubscription = loginClient.connectionStatusChanged.stream - .listen(onLoginProgressChanged); + progressSubscription = loginClient!.connectionStatusChanged.stream + .listen(onLoginProgressChanged); + }); super.initState(); } @@ -85,6 +87,7 @@ class LoginPageState extends State { } Future doLogin(Future Function() login) async { + if (loginClient == null) return; if (isServerValid == false) { return; } @@ -122,21 +125,23 @@ class LoginPageState extends State { } if (result == LoginResult.success) { - clientManager?.addClient(loginClient); - widget.onSuccess?.call(loginClient); + clientManager?.addClient(loginClient!); + widget.onSuccess?.call(loginClient!); } } Future doSsoLogin(SsoLoginFlow flow) async { - await doLogin(() => loginClient.executeLoginFlow(flow)); + if (loginClient == null) return; + await doLogin(() => loginClient!.executeLoginFlow(flow)); } Future doPasswordLogin( PasswordLoginFlow flow, String username, String password) async { + if (loginClient == null) return; flow.username = username; flow.password = password; - await doLogin(() => loginClient.executeLoginFlow(flow)); + await doLogin(() => loginClient!.executeLoginFlow(flow)); } void onLoginProgressChanged(ClientConnectionStatusUpdate event) { @@ -146,6 +151,8 @@ class LoginPageState extends State { } Future updateHomeserver(String input) async { + if (loginClient == null) return; + setState(() { loginFlows = null; loadingServerInfo = true; @@ -153,7 +160,7 @@ class LoginPageState extends State { }); var uri = Uri.https(input); - var result = await loginClient.setHomeserver(uri); + var result = await loginClient!.setHomeserver(uri); setState(() { loadingServerInfo = false; diff --git a/commet/lib/ui/pages/settings/categories/about/settings_category_about.dart b/commet/lib/ui/pages/settings/categories/about/settings_category_about.dart index 91a27e7f7..f13b304f8 100644 --- a/commet/lib/ui/pages/settings/categories/about/settings_category_about.dart +++ b/commet/lib/ui/pages/settings/categories/about/settings_category_about.dart @@ -12,8 +12,8 @@ import 'package:intl/intl.dart'; import 'package:flutter/material.dart' as m; import 'package:tiamat/tiamat.dart' as tiamat; -// ignore: depend_on_referenced_packages -import 'package:olm/olm.dart' as olm; + +import 'package:vodozemac/vodozemac.dart' as vod; class SettingsCategoryAbout implements SettingsCategory { String get labelSettingsAppLogs => Intl.message("Logs", @@ -117,7 +117,7 @@ class _AppInfoState extends State<_AppInfo> { ], ), if (preferences.developerMode) - tiamat.Text.labelLow(getOlmVersion()), + tiamat.Text.labelLow(getEncryptionInfo()), ], ), Padding( @@ -145,16 +145,26 @@ class _AppInfoState extends State<_AppInfo> { ); } - String getOlmVersion() { + String getEncryptionInfo() { + var info = getVodozemacVersion(); + info ??= "No encryption library found"; + return info; + } + + String? getVodozemacVersion() { try { - var version = olm.get_library_version(); - return "Olm: ${version.join(".")}"; + var initialized = vod.isInitialized(); + if (initialized) { + return "Vodozemac Initialized"; + } + + return null; } catch (exception) { - return "No Olm version found"; + return null; } } - copySystemInfo() { + void copySystemInfo() { var data = """
Device Information diff --git a/commet/lib/ui/pages/settings/categories/app/notification_settings/notification_settings_page.dart b/commet/lib/ui/pages/settings/categories/app/notification_settings/notification_settings_page.dart index 577025fa7..6efc2029b 100644 --- a/commet/lib/ui/pages/settings/categories/app/notification_settings/notification_settings_page.dart +++ b/commet/lib/ui/pages/settings/categories/app/notification_settings/notification_settings_page.dart @@ -106,7 +106,7 @@ class _NotificationSettingsPageState extends State { ); } - onPushGatewaySelected() async { + Future onPushGatewaySelected() async { var value = (pushGatewayKey.currentState as DropdownTextFieldState).value; preferences.setPushGateway(value); diff --git a/commet/lib/ui/pages/settings/categories/app/voip_settings/voip_debug_matrix_client.dart b/commet/lib/ui/pages/settings/categories/app/voip_settings/voip_debug_matrix_client.dart index c48a50001..e249d7c65 100644 --- a/commet/lib/ui/pages/settings/categories/app/voip_settings/voip_debug_matrix_client.dart +++ b/commet/lib/ui/pages/settings/categories/app/voip_settings/voip_debug_matrix_client.dart @@ -174,7 +174,7 @@ class _VoipDebugMatrixClientState extends State { ); } - testTurn() async { + Future testTurn() async { foundCandidates = List.empty(growable: true); var servers = credentials == null @@ -223,13 +223,13 @@ class _VoipDebugMatrixClientState extends State { await connection!.setLocalDescription(offer); } - onIceCandidate(webrtc.RTCIceCandidate candidate) { + void onIceCandidate(webrtc.RTCIceCandidate candidate) { setState(() { foundCandidates.add(candidate); }); } - onIceGatheringState(webrtc.RTCIceGatheringState state) { + void onIceGatheringState(webrtc.RTCIceGatheringState state) { setState(() { gatheringState = state; }); diff --git a/commet/lib/ui/pages/settings/categories/developer/developer_settings_page.dart b/commet/lib/ui/pages/settings/categories/developer/developer_settings_page.dart index 191bffe8c..3d2a793f2 100644 --- a/commet/lib/ui/pages/settings/categories/developer/developer_settings_page.dart +++ b/commet/lib/ui/pages/settings/categories/developer/developer_settings_page.dart @@ -5,7 +5,6 @@ import 'package:commet/config/app_config.dart'; import 'package:commet/diagnostic/diagnostics.dart'; import 'package:commet/main.dart'; import 'package:commet/ui/navigation/navigation_utils.dart'; -import 'package:commet/ui/pages/developer/app_inspector/app_inspector_page.dart'; import 'package:commet/ui/pages/developer/benchmarks/timeline_viewer_benchmark.dart'; import 'package:commet/ui/pages/settings/categories/developer/cumulative_diagnostics_widget.dart'; import 'package:commet/utils/background_tasks/background_task_manager.dart'; @@ -31,7 +30,6 @@ class _DeveloperSettingsPageState extends State { children: [ performance(), benchmarks(), - inspect(), windowSize(), notificationTests(), rendering(), @@ -90,28 +88,6 @@ class _DeveloperSettingsPageState extends State { ]); } - Widget inspect() { - return ExpansionTile( - title: const tiamat.Text.labelEmphasised("Inspect"), - initiallyExpanded: false, - backgroundColor: Theme.of(context).colorScheme.surfaceContainerLow, - collapsedBackgroundColor: - Theme.of(context).colorScheme.surfaceContainerLow, - children: [ - Wrap( - spacing: 8, - runSpacing: 8, - children: [ - tiamat.Button( - text: "Inspect App State", - onTap: () => NavigationUtils.navigateTo( - context, const AppInspectorPage()), - ) - ], - ), - ]); - } - Widget benchmarks() { return ExpansionTile( title: const tiamat.Text.labelEmphasised("Benchmarks"), diff --git a/commet/lib/ui/pages/settings/categories/developer/log_page.dart b/commet/lib/ui/pages/settings/categories/developer/log_page.dart index dd193023c..60d65ab8a 100644 --- a/commet/lib/ui/pages/settings/categories/developer/log_page.dart +++ b/commet/lib/ui/pages/settings/categories/developer/log_page.dart @@ -196,7 +196,7 @@ class _LogPageState extends State { }); } - reportIssue(LogEntryException entry) async { + Future reportIssue(LogEntryException entry) async { var data = await getErrorData(entry); var uri = Uri.https("github.com", "/commetchat/commet/issues/new", { "title": entry.content.split("\n").first, diff --git a/commet/lib/ui/pages/settings/categories/room/appearance/room_appearance_settings_page.dart b/commet/lib/ui/pages/settings/categories/room/appearance/room_appearance_settings_page.dart index 2d8111b3d..65185e32f 100644 --- a/commet/lib/ui/pages/settings/categories/room/appearance/room_appearance_settings_page.dart +++ b/commet/lib/ui/pages/settings/categories/room/appearance/room_appearance_settings_page.dart @@ -27,9 +27,9 @@ class _RoomAppearanceSettingsPageState ); } - setRoomAvatar(Uint8List bytes, String? mimeType) {} + void setRoomAvatar(Uint8List bytes, String? mimeType) {} - setRoomName(String name) { + void setRoomName(String name) { widget.room.setDisplayName(name); } } diff --git a/commet/lib/ui/pages/settings/categories/room/permissions/matrix/matrix_room_permissions_view.dart b/commet/lib/ui/pages/settings/categories/room/permissions/matrix/matrix_room_permissions_view.dart index 1f4d000f7..4ea35c78a 100644 --- a/commet/lib/ui/pages/settings/categories/room/permissions/matrix/matrix_room_permissions_view.dart +++ b/commet/lib/ui/pages/settings/categories/room/permissions/matrix/matrix_room_permissions_view.dart @@ -299,7 +299,7 @@ class _MatrixRoomPermissionsViewState extends State { } } - applySettings() async { + Future applySettings() async { setState(() { isLoading = true; }); diff --git a/commet/lib/ui/pages/settings/categories/space/space_appearance_settings_page.dart b/commet/lib/ui/pages/settings/categories/space/space_appearance_settings_page.dart index f33101a57..eb7c11905 100644 --- a/commet/lib/ui/pages/settings/categories/space/space_appearance_settings_page.dart +++ b/commet/lib/ui/pages/settings/categories/space/space_appearance_settings_page.dart @@ -27,11 +27,11 @@ class _SpaceAppearanceSettingsPageState ); } - onAvatarPicked(Uint8List bytes, String? mimeType) { + void onAvatarPicked(Uint8List bytes, String? mimeType) { widget.space.changeAvatar(bytes, mimeType); } - setName(String name) { + void setName(String name) { widget.space.setDisplayName(name); } } diff --git a/commet/lib/ui/pages/setup/setup_page.dart b/commet/lib/ui/pages/setup/setup_page.dart index 92aa225ef..763c16d51 100644 --- a/commet/lib/ui/pages/setup/setup_page.dart +++ b/commet/lib/ui/pages/setup/setup_page.dart @@ -93,7 +93,7 @@ class _SetupPageState extends State { ); } - goNextMenu() { + void goNextMenu() { currentMenu.submit(); var newIndex = currentMenuIndex + 1; setState(() { diff --git a/commet/lib/utils/autofill_utils.dart b/commet/lib/utils/autofill_utils.dart index 7a0392180..9b54458cb 100644 --- a/commet/lib/utils/autofill_utils.dart +++ b/commet/lib/utils/autofill_utils.dart @@ -122,6 +122,5 @@ class AutofillSearchResult { class AutofillSearchResultEmoticon extends AutofillSearchResult { Emoticon emoticon; - AutofillSearchResultEmoticon(String result, String slug, this.emoticon) - : super(result, slug); + AutofillSearchResultEmoticon(super.result, super.slug, this.emoticon); } diff --git a/commet/lib/utils/debounce.dart b/commet/lib/utils/debounce.dart index 1c4ac3ba8..8463c23f5 100644 --- a/commet/lib/utils/debounce.dart +++ b/commet/lib/utils/debounce.dart @@ -8,12 +8,12 @@ class Debouncer { Debouncer({required this.delay}); - run(void Function() action) { + void run(void Function() action) { _timer?.cancel(); _timer = Timer(delay, action); } - cancel() { + void cancel() { _timer?.cancel(); _timer = null; } diff --git a/commet/linux/debian/DEBIAN/control-ubuntu-22.04 b/commet/linux/debian/DEBIAN/control-ubuntu-22.04 index 3da99c7c6..10100232b 100644 --- a/commet/linux/debian/DEBIAN/control-ubuntu-22.04 +++ b/commet/linux/debian/DEBIAN/control-ubuntu-22.04 @@ -3,6 +3,6 @@ Version: {{VERSION_TAG}} Architecture: all Essential: no Priority: optional -Depends: libmpv1, libolm3 +Depends: libmpv1 Maintainer: Airyz Description: Your space to connect! diff --git a/commet/linux/debian/DEBIAN/control-ubuntu-24.04 b/commet/linux/debian/DEBIAN/control-ubuntu-24.04 index 8c2f6b69a..f0ceabe0b 100644 --- a/commet/linux/debian/DEBIAN/control-ubuntu-24.04 +++ b/commet/linux/debian/DEBIAN/control-ubuntu-24.04 @@ -3,6 +3,6 @@ Version: {{VERSION_TAG}} Architecture: all Essential: no Priority: optional -Depends: libmpv2, libolm3 +Depends: libmpv2 Maintainer: Airyz Description: Your space to connect! diff --git a/commet/linux/flatpak/chat.commet.commetapp.yaml b/commet/linux/flatpak/chat.commet.commetapp.yaml index 7a623a291..d903e8c6d 100644 --- a/commet/linux/flatpak/chat.commet.commetapp.yaml +++ b/commet/linux/flatpak/chat.commet.commetapp.yaml @@ -1,7 +1,7 @@ app-id: chat.commet.commetapp -runtime: org.freedesktop.Platform -runtime-version: '24.08' -sdk: org.freedesktop.Sdk +runtime: org.gnome.Platform +runtime-version: '48' +sdk: org.gnome.Sdk command: commet separate-locales: false diff --git a/commet/linux/flutter/generated_plugins.cmake b/commet/linux/flutter/generated_plugins.cmake index 35a5c44b2..6b6e39b3a 100644 --- a/commet/linux/flutter/generated_plugins.cmake +++ b/commet/linux/flutter/generated_plugins.cmake @@ -19,6 +19,7 @@ list(APPEND FLUTTER_PLUGIN_LIST ) list(APPEND FLUTTER_FFI_PLUGIN_LIST + flutter_vodozemac ) set(PLUGIN_BUNDLED_LIBRARIES) diff --git a/commet/pubspec.lock b/commet/pubspec.lock index 011d6f1c8..1c83fda33 100644 --- a/commet/pubspec.lock +++ b/commet/pubspec.lock @@ -5,23 +5,18 @@ packages: dependency: transitive description: name: _fe_analyzer_shared - sha256: "16e298750b6d0af7ce8a3ba7c18c69c3785d11b15ec83f6dcd0ad2a0009b3cab" + sha256: da0d9209ca76bde579f2da330aeb9df62b6319c834fa7baae052021b0462401f url: "https://pub.dev" source: hosted - version: "76.0.0" - _macros: - dependency: transitive - description: dart - source: sdk - version: "0.3.3" + version: "85.0.0" analyzer: - dependency: transitive + dependency: "direct overridden" description: name: analyzer - sha256: "1f14db053a8c23e260789e9b0980fa27f2680dd640932cae5e1137cce0e46e1e" + sha256: "974859dc0ff5f37bc4313244b3218c791810d03ab3470a579580279ba971a48d" url: "https://pub.dev" source: hosted - version: "6.11.0" + version: "7.7.1" archive: dependency: "direct main" description: @@ -38,14 +33,6 @@ packages: url: "https://pub.dev" source: hosted version: "2.7.0" - asn1lib: - dependency: transitive - description: - name: asn1lib - sha256: "0511d6be23b007e95105ae023db599aea731df604608978dada7f9faf2637623" - url: "https://pub.dev" - source: hosted - version: "1.6.4" async: dependency: transitive description: @@ -86,6 +73,14 @@ packages: url: "https://pub.dev" source: hosted version: "2.4.2" + build_cli_annotations: + dependency: transitive + description: + name: build_cli_annotations + sha256: e563c2e01de8974566a1998410d3f6f03521788160a02503b0b1f1a46c7b3d95 + url: "https://pub.dev" + source: hosted + version: "2.1.1" build_config: dependency: "direct main" description: @@ -138,10 +133,10 @@ packages: dependency: transitive description: name: built_value - sha256: "082001b5c3dc495d4a42f1d5789990505df20d8547d42507c29050af6933ee27" + sha256: a30f0a0e38671e89a492c44d005b5545b830a961575bbd8336d42869ff71066d url: "https://pub.dev" source: hosted - version: "8.10.1" + version: "8.12.0" canonical_json: dependency: transitive description: @@ -202,12 +197,12 @@ packages: dependency: transitive description: name: code_builder - sha256: "0ec10bf4a89e4c613960bf1e8b42c64127021740fb21640c29c909826a5eea3e" + sha256: "11654819532ba94c34de52ff5feb52bd81cba1de00ef2ed622fd50295f9d4243" url: "https://pub.dev" source: hosted - version: "4.10.1" + version: "4.11.0" collection: - dependency: transitive + dependency: "direct main" description: name: collection sha256: "2f5709ae4d3d59dd8f7cd309b4e023046b57d8a6c82130785d2b0e5868084e76" @@ -234,10 +229,10 @@ packages: dependency: transitive description: name: coverage - sha256: aa07dbe5f2294c827b7edb9a87bba44a9c15a3cc81bc8da2ca19b37322d30080 + sha256: "5da775aa218eaf2151c721b16c01c7676fbfdd99cebba2bf64e8b807a28ff94d" url: "https://pub.dev" source: hosted - version: "1.14.1" + version: "1.15.0" cross_file: dependency: transitive description: @@ -290,10 +285,10 @@ packages: dependency: transitive description: name: dart_webrtc - sha256: "5b76fd85ac95d6f5dee3e7d7de8d4b51bfbec1dc73804647c6aebb52d6297116" + sha256: "51bcda4ba5d7dd9e65a309244ce3ac0b58025e6e1f6d7442cee4cd02134ef65f" url: "https://pub.dev" source: hosted - version: "1.5.3+hotfix.2" + version: "1.6.0" dbus: dependency: transitive description: @@ -338,26 +333,26 @@ packages: dependency: transitive description: name: device_info_plus_platform_interface - sha256: "0b04e02b30791224b31969eb1b50d723498f402971bff3630bca2ba839bd1ed2" + sha256: e1ea89119e34903dca74b883d0dd78eb762814f97fb6c76f35e9ff74d261a18f url: "https://pub.dev" source: hosted - version: "7.0.2" + version: "7.0.3" drift: dependency: "direct main" description: name: drift - sha256: b584ddeb2b74436735dd2cf746d2d021e19a9a6770f409212fd5cbc2814ada85 + sha256: "6aaea757f53bb035e8a3baedf3d1d53a79d6549a6c13d84f7546509da9372c7c" url: "https://pub.dev" source: hosted - version: "2.26.1" + version: "2.28.1" drift_dev: dependency: "direct dev" description: name: drift_dev - sha256: "0d3f8b33b76cf1c6a82ee34d9511c40957549c4674b8f1688609e6d6c7306588" + sha256: "68c138e884527d2bd61df2ade276c3a144df84d1adeb0ab8f3196b5afe021bd4" url: "https://pub.dev" source: hosted - version: "2.26.0" + version: "2.28.0" dropdown_button2: dependency: transitive description: @@ -375,14 +370,6 @@ packages: url: "https://github.com/Airyzz/material-flutter-packages.git" source: git version: "1.7.0" - encrypt: - dependency: "direct main" - description: - name: encrypt - sha256: "62d9aa4670cc2a8798bab89b39fc71b6dfbacf615de6cf5001fb39f7e4a996a2" - url: "https://pub.dev" - source: hosted - version: "5.0.3" enhanced_enum: dependency: transitive description: @@ -416,7 +403,7 @@ packages: source: hosted version: "2.1.4" file: - dependency: transitive + dependency: "direct dev" description: name: file sha256: a3b4f84adafef897088c160faf7dfffb7696046cb13ae90b508c2cbc95d3b8d4 @@ -427,10 +414,10 @@ packages: dependency: "direct main" description: name: file_picker - sha256: ef9908739bdd9c476353d6adff72e88fd00c625f5b959ae23f7567bd5137db0a + sha256: f2d9f173c2c14635cc0e9b14c143c49ef30b4934e8d1d274d6206fcb0086a06f url: "https://pub.dev" source: hosted - version: "10.2.0" + version: "10.3.3" fixnum: dependency: transitive description: @@ -456,10 +443,10 @@ packages: dependency: transitive description: name: flutter_background_service_android - sha256: b73d903056240e23a5c56d9e52d3a5d02ae41cb18b2988a97304ae37b2bae4bf + sha256: ca0793d4cd19f1e194a130918401a3d0b1076c81236f7273458ae96987944a87 url: "https://pub.dev" source: hosted - version: "6.3.0" + version: "6.3.1" flutter_background_service_ios: dependency: transitive description: @@ -515,23 +502,15 @@ packages: url: "https://pub.dev" source: hosted version: "0.13.1" - flutter_lints: - dependency: "direct dev" - description: - name: flutter_lints - sha256: "3105dc8492f6183fb076ccf1f351ac3d60564bff92e20bfc4af9cc1651f4e7e1" - url: "https://pub.dev" - source: hosted - version: "6.0.0" flutter_local_notifications: dependency: "direct main" description: path: flutter_local_notifications ref: HEAD - resolved-ref: aa7b3adce37af540d058906493e91371e8a28dae + resolved-ref: "78a9fe5132f720bc9e501fb26a1962a14915f69d" url: "https://github.com/commetchat/flutter_local_notifications.git" source: git - version: "19.2.1" + version: "19.4.1" flutter_local_notifications_linux: dependency: transitive description: @@ -544,18 +523,18 @@ packages: dependency: transitive description: name: flutter_local_notifications_platform_interface - sha256: "2569b973fc9d1f63a37410a9f7c1c552081226c597190cb359ef5d5762d1631c" + sha256: "277d25d960c15674ce78ca97f57d0bae2ee401c844b6ac80fcd972a9c99d09fe" url: "https://pub.dev" source: hosted - version: "9.0.0" + version: "9.1.0" flutter_local_notifications_windows: dependency: transitive description: name: flutter_local_notifications_windows - sha256: f8fc0652a601f83419d623c85723a3e82ad81f92b33eaa9bcc21ea1b94773e6e + sha256: "8d658f0d367c48bd420e7cf2d26655e2d1130147bca1eea917e576ca76668aaf" url: "https://pub.dev" source: hosted - version: "1.0.0" + version: "1.0.3" flutter_localizations: dependency: "direct main" description: flutter @@ -569,14 +548,6 @@ packages: url: "https://pub.dev" source: hosted version: "0.6.23" - flutter_olm: - dependency: "direct main" - description: - name: flutter_olm - sha256: "5e6211af8cba1abf7d1f92e543f6d573dfe6017fe4742e0d04ba84beab47f940" - url: "https://pub.dev" - source: hosted - version: "2.0.0" flutter_openssl_crypto: dependency: "direct main" description: @@ -589,10 +560,18 @@ packages: dependency: transitive description: name: flutter_plugin_android_lifecycle - sha256: f948e346c12f8d5480d2825e03de228d0eb8c3a737e4cdaa122267b89c022b5e + sha256: b0694b7fb1689b0e6cc193b3f1fcac6423c4f93c74fb20b806c6b6f196db0c31 url: "https://pub.dev" source: hosted - version: "2.0.28" + version: "2.0.30" + flutter_rust_bridge: + dependency: transitive + description: + name: flutter_rust_bridge + sha256: b416ff56002789e636244fb4cc449f587656eff995e5a7169457eb0593fcaddb + url: "https://pub.dev" + source: hosted + version: "2.10.0" flutter_shortcuts_new: dependency: "direct main" description: @@ -613,15 +592,23 @@ packages: dependency: "direct main" description: name: flutter_svg - sha256: d44bf546b13025ec7353091516f6881f1d4c633993cb109c3916c3a0159dadf1 + sha256: b9c2ad5872518a27507ab432d1fb97e8813b05f0fc693f9d40fad06d073e0678 url: "https://pub.dev" source: hosted - version: "2.1.0" + version: "2.2.1" flutter_test: dependency: "direct dev" description: flutter source: sdk version: "0.0.0" + flutter_vodozemac: + dependency: "direct main" + description: + name: flutter_vodozemac + sha256: "2405ca121b84d1cd83200a14021022e1691b123a23bcefc36adc7740cefbc1f9" + url: "https://pub.dev" + source: hosted + version: "0.2.2" flutter_web_auth_2: dependency: "direct main" description: @@ -647,10 +634,10 @@ packages: dependency: "direct main" description: name: flutter_webrtc - sha256: dd47ca103b5b6217771e6277882674276d9621bbf9eb23da3c03898b507844e3 + sha256: "792aa1e5838a719f29ae52c0773dbb5dd781fc33b1bf87c321b274e55ab51ad1" url: "https://pub.dev" source: hosted - version: "0.14.1" + version: "0.14.2" frontend_server_client: dependency: transitive description: @@ -676,10 +663,10 @@ packages: dependency: transitive description: name: get_it - sha256: d85128a5dae4ea777324730dc65edd9c9f43155c109d5cc0a69cab74139fbac1 + sha256: a4292e7cf67193f8e7c1258203104eb2a51ec8b3a04baa14695f4064c144297b url: "https://pub.dev" source: hosted - version: "7.7.0" + version: "8.2.0" glob: dependency: transitive description: @@ -704,14 +691,6 @@ packages: url: "https://pub.dev" source: hosted version: "0.1.1" - hive: - dependency: transitive - description: - name: hive - sha256: "8dcf6db979d7933da8217edcec84e9df1bdb4e4edc7fc77dbd5aa74356d6d941" - url: "https://pub.dev" - source: hosted - version: "2.2.3" html: dependency: "direct main" description: @@ -732,10 +711,10 @@ packages: dependency: "direct main" description: name: http - sha256: "2c11f3f94c687ee9bad77c171151672986360b2b001d109814ee7140b2cf261b" + sha256: bb2ce4590bc2667c96f318d68cac1b5a7987ec819351d32b1c987239a815e007 url: "https://pub.dev" source: hosted - version: "1.4.0" + version: "1.5.0" http_multi_server: dependency: transitive description: @@ -833,34 +812,26 @@ packages: dependency: transitive description: name: leak_tracker - sha256: "6bb818ecbdffe216e81182c2f0714a2e62b593f4a4f13098713ff1685dfb6ab0" + sha256: "33e2e26bdd85a0112ec15400c8cbffea70d0f9c3407491f672a2fad47915e2de" url: "https://pub.dev" source: hosted - version: "10.0.9" + version: "11.0.2" leak_tracker_flutter_testing: dependency: transitive description: name: leak_tracker_flutter_testing - sha256: f8b613e7e6a13ec79cfdc0e97638fddb3ab848452eff057653abd3edba760573 + sha256: "1dbc140bb5a23c75ea9c4811222756104fbcd1a27173f0c34ca01e16bea473c1" url: "https://pub.dev" source: hosted - version: "3.0.9" + version: "3.0.10" leak_tracker_testing: dependency: transitive description: name: leak_tracker_testing - sha256: "6ba465d5d76e67ddf503e1161d1f4a6bc42306f9d66ca1e8f079a47290fb06d3" + sha256: "8d5a2d49f4a66b49744b23b018848400d23e54caf9463f4eb20df3eb8acb2eb1" url: "https://pub.dev" source: hosted - version: "3.0.1" - lints: - dependency: transitive - description: - name: lints - sha256: a5e2b223cb7c9c8efdc663ef484fdd95bb243bff242ef5b13e26883547fce9a0 - url: "https://pub.dev" - source: hosted - version: "6.0.0" + version: "3.0.2" list_counter: dependency: transitive description: @@ -881,10 +852,10 @@ packages: dependency: transitive description: name: logger - sha256: be4b23575aac7ebf01f225a241eb7f6b5641eeaf43c6a8613510fc2f8cf187d1 + sha256: "55d6c23a6c15db14920e037fe7e0dc32e7cdaf3b64b4b25df2d541b5b6b81c0c" url: "https://pub.dev" source: hosted - version: "2.5.0" + version: "2.6.1" logging: dependency: transitive description: @@ -893,16 +864,8 @@ packages: url: "https://pub.dev" source: hosted version: "1.3.0" - macros: - dependency: transitive - description: - name: macros - sha256: "1d9e801cd66f7ea3663c45fc708450db1fa57f988142c64289142c9b7ee80656" - url: "https://pub.dev" - source: hosted - version: "0.1.3-main.0" markdown: - dependency: transitive + dependency: "direct main" description: name: markdown sha256: "935e23e1ff3bc02d390bad4d4be001208ee92cc217cb5b5a6c19bc14aaa318c1" @@ -929,17 +892,17 @@ packages: dependency: "direct main" description: path: "." - ref: voip - resolved-ref: "98307cc8c3a71db744cdb2b0da0cada5feb4c109" + ref: "upstream-v1.1.1" + resolved-ref: "45d195c9e1b19ea064431e21b13e08d6faff774b" url: "https://github.com/commetchat/matrix-dart-sdk.git" source: git - version: "0.38.0" + version: "1.1.1" matrix_dart_sdk_drift_db: dependency: "direct main" description: path: "." - ref: voip - resolved-ref: fa6e94488a6b573863fae7561b0d23bbc73e315f + ref: "upstream-v1.1.1" + resolved-ref: acfa4940dd1d7887b472486fc29a20ff89967a26 url: "https://github.com/commetchat/matrix-dart-sdk-drift-db.git" source: git version: "0.0.1" @@ -1027,10 +990,10 @@ packages: dependency: "direct dev" description: name: msix - sha256: edde648a8133bf301883c869d19d127049683037c65ff64173ba526ac7a8af2f + sha256: f88033fcb9e0dd8de5b18897cbebbd28ea30596810f4a7c86b12b0c03ace87e5 url: "https://pub.dev" source: hosted - version: "3.16.9" + version: "3.16.12" nested: dependency: transitive description: @@ -1047,14 +1010,6 @@ packages: url: "https://pub.dev" source: hosted version: "2.0.2" - olm: - dependency: "direct main" - description: - name: olm - sha256: "3306bf534ceb914fd148b3b4a3d603fb5e067b2e6da8304025b47c24cfdf6b46" - url: "https://pub.dev" - source: hosted - version: "2.0.4" package_config: dependency: transitive description: @@ -1067,18 +1022,18 @@ packages: dependency: transitive description: name: package_info_plus - sha256: "7976bfe4c583170d6cdc7077e3237560b364149fcd268b5f53d95a991963b191" + sha256: f69da0d3189a4b4ceaeb1a3defb0f329b3b352517f52bed4290f83d4f06bc08d url: "https://pub.dev" source: hosted - version: "8.3.0" + version: "9.0.0" package_info_plus_platform_interface: dependency: transitive description: name: package_info_plus_platform_interface - sha256: "6c935fb612dff8e3cc9632c2b301720c77450a126114126ffaafe28d2e87956c" + sha256: "202a487f08836a592a6bd4f901ac69b3a8f146af552bbd14407b6b41e1c3f086" url: "https://pub.dev" source: hosted - version: "3.2.0" + version: "3.2.1" pasteboard: dependency: "direct main" description: @@ -1115,18 +1070,18 @@ packages: dependency: transitive description: name: path_provider_android - sha256: d0d310befe2c8ab9e7f393288ccbb11b60c019c6b5afc21973eeee4dda2b35e9 + sha256: "993381400e94d18469750e5b9dcb8206f15bc09f9da86b9e44a9b0092a0066db" url: "https://pub.dev" source: hosted - version: "2.2.17" + version: "2.2.18" path_provider_foundation: dependency: transitive description: name: path_provider_foundation - sha256: "4843174df4d288f5e29185bd6e72a6fbdf5a4a4602717eed565497429f179942" + sha256: "16eef174aacb07e09c351502740fa6254c165757638eba1e9116b0a781201bbd" url: "https://pub.dev" source: hosted - version: "2.4.1" + version: "2.4.2" path_provider_linux: dependency: transitive description: @@ -1223,30 +1178,22 @@ packages: url: "https://pub.dev" source: hosted version: "2.1.8" - pointycastle: - dependency: "direct main" - description: - name: pointycastle - sha256: "4be0097fcf3fd3e8449e53730c631200ebc7b88016acecab2b0da2f0149222fe" - url: "https://pub.dev" - source: hosted - version: "3.9.1" pool: dependency: transitive description: name: pool - sha256: "20fe868b6314b322ea036ba325e6fc0711a22948856475e2c2b6306e8ab39c2a" + sha256: "978783255c543aa3586a1b3c21f6e9d720eb315376a915872c61ef8b5c20177d" url: "https://pub.dev" source: hosted - version: "1.5.1" + version: "1.5.2" process: dependency: transitive description: name: process - sha256: "107d8be718f120bbba9dcd1e95e3bd325b1b4a4f07db64154635ba03f2567a0d" + sha256: c6248e4526673988586e8c00bb22a49210c258dc91df5227d5da9748ecf79744 url: "https://pub.dev" source: hosted - version: "5.0.3" + version: "5.0.5" protobuf: dependency: transitive description: @@ -1259,10 +1206,10 @@ packages: dependency: "direct main" description: name: provider - sha256: "4abbd070a04e9ddc287673bf5a030c7ca8b685ff70218720abab8b092f53dd84" + sha256: "4e82183fa20e5ca25703ead7e05de9e4cceed1fbd1eadc1ac3cb6f565a09f272" url: "https://pub.dev" source: hosted - version: "6.1.5" + version: "6.1.5+1" pub_semver: dependency: transitive description: @@ -1328,14 +1275,6 @@ packages: url: "https://github.com/daadu/receive_intent" source: git version: "0.2.7" - reflectable: - dependency: "direct main" - description: - name: reflectable - sha256: "35ee17c3b759fa935cc7e9247445903384520fd174e0d6c142d8288e5439fd5b" - url: "https://pub.dev" - source: hosted - version: "4.0.12" safe_local_storage: dependency: transitive description: @@ -1348,10 +1287,10 @@ packages: dependency: transitive description: name: screen_brightness_android - sha256: "6ba1b5812f66c64e9e4892be2d36ecd34210f4e0da8bdec6a2ea34f1aa42683e" + sha256: d34f5321abd03bc3474f4c381f53d189117eba0b039eac1916aa92cca5fd0a96 url: "https://pub.dev" source: hosted - version: "2.1.1" + version: "2.1.3" screen_brightness_platform_interface: dependency: transitive description: @@ -1396,10 +1335,10 @@ packages: dependency: transitive description: name: shared_preferences_android - sha256: "20cbd561f743a342c76c151d6ddb93a9ce6005751e7aa458baad3858bfbfb6ac" + sha256: a2608114b1ffdcbc9c120eb71a0e207c71da56202852d4aab8a5e30a82269e74 url: "https://pub.dev" source: hosted - version: "2.4.10" + version: "2.4.12" shared_preferences_foundation: dependency: transitive description: @@ -1546,18 +1485,18 @@ packages: dependency: transitive description: name: sqflite_android - sha256: "2b3070c5fa881839f8b402ee4a39c1b4d561704d4ebbbcfb808a119bc2a1701b" + sha256: ecd684501ebc2ae9a83536e8b15731642b9570dc8623e0073d227d0ee2bfea88 url: "https://pub.dev" source: hosted - version: "2.4.1" + version: "2.4.2+2" sqflite_common: dependency: transitive description: name: sqflite_common - sha256: "84731e8bfd8303a3389903e01fb2141b6e59b5973cacbb0929021df08dddbe8b" + sha256: "6ef422a4525ecc601db6c0a2233ff448c731307906e92cabc9ba292afaae16a6" url: "https://pub.dev" source: hosted - version: "2.5.5" + version: "2.5.6" sqflite_common_ffi: dependency: "direct main" description: @@ -1586,26 +1525,26 @@ packages: dependency: transitive description: name: sqlite3 - sha256: c0503c69b44d5714e6abbf4c1f51a3c3cc42b75ce785f44404765e4635481d38 + sha256: f393d92c71bdcc118d6203d07c991b9be0f84b1a6f89dd4f7eed348131329924 url: "https://pub.dev" source: hosted - version: "2.7.6" + version: "2.9.0" sqlite3_flutter_libs: dependency: "direct main" description: name: sqlite3_flutter_libs - sha256: e07232b998755fe795655c56d1f5426e0190c9c435e1752d39e7b1cd33699c71 + sha256: "2b03273e71867a8a4d030861fc21706200debe5c5858a4b9e58f4a1c129586a4" url: "https://pub.dev" source: hosted - version: "0.5.34" + version: "0.5.39" sqlparser: dependency: transitive description: name: sqlparser - sha256: "27dd0a9f0c02e22ac0eb42a23df9ea079ce69b52bb4a3b478d64e0ef34a263ee" + sha256: "57090342af1ce32bb499aa641f4ecdd2d6231b9403cea537ac059e803cc20d67" url: "https://pub.dev" source: hosted - version: "0.41.0" + version: "0.41.2" stack_trace: dependency: transitive description: @@ -1667,10 +1606,10 @@ packages: dependency: transitive description: name: synchronized - sha256: "0669c70faae6270521ee4f05bffd2919892d42d1276e6c495be80174b6bc0ef6" + sha256: c254ade258ec8282947a0acbbc90b9575b4f19673533ee46f2f6e9b3aeefd7c0 url: "https://pub.dev" source: hosted - version: "3.3.1" + version: "3.4.0" term_glyph: dependency: transitive description: @@ -1683,26 +1622,26 @@ packages: dependency: "direct main" description: name: test - sha256: "301b213cd241ca982e9ba50266bd3f5bd1ea33f1455554c5abb85d1be0e2d87e" + sha256: "65e29d831719be0591f7b3b1a32a3cda258ec98c58c7b25f7b84241bc31215bb" url: "https://pub.dev" source: hosted - version: "1.25.15" + version: "1.26.2" test_api: dependency: transitive description: name: test_api - sha256: fb31f383e2ee25fbbfe06b40fe21e1e458d14080e3c67e7ba0acfde4df4e0bbd + sha256: "522f00f556e73044315fa4585ec3270f1808a4b186c936e612cab0b565ff1e00" url: "https://pub.dev" source: hosted - version: "0.7.4" + version: "0.7.6" test_core: dependency: transitive description: name: test_core - sha256: "84d17c3486c8dfdbe5e12a50c8ae176d15e2a771b96909a9442b40173649ccaa" + sha256: "80bf5a02b60af04b09e14f6fe68b921aad119493e26e490deaca5993fef1b05a" url: "https://pub.dev" source: hosted - version: "0.6.8" + version: "0.6.11" tiamat: dependency: "direct main" description: @@ -1810,26 +1749,26 @@ packages: dependency: "direct main" description: name: url_launcher - sha256: "9d06212b1362abc2f0f0d78e6f09f726608c74e3b9462e8368bb03314aa8d603" + sha256: f6a7e5c4835bb4e3026a04793a4199ca2d14c739ec378fdfe23fc8075d0439f8 url: "https://pub.dev" source: hosted - version: "6.3.1" + version: "6.3.2" url_launcher_android: dependency: transitive description: name: url_launcher_android - sha256: "8582d7f6fe14d2652b4c45c9b6c14c0b678c2af2d083a11b604caeba51930d79" + sha256: "199bc33e746088546a39cc5f36bac5a278c5e53b40cb3196f99e7345fdcfae6b" url: "https://pub.dev" source: hosted - version: "6.3.16" + version: "6.3.22" url_launcher_ios: dependency: transitive description: name: url_launcher_ios - sha256: "7f2022359d4c099eea7df3fdf739f7d3d3b9faf3166fb1dd390775176e0b76cb" + sha256: d80b3f567a617cb923546034cc94bfe44eb15f989fe670b37f26abdb9d939cb7 url: "https://pub.dev" source: hosted - version: "6.3.3" + version: "6.3.4" url_launcher_linux: dependency: transitive description: @@ -1842,10 +1781,10 @@ packages: dependency: transitive description: name: url_launcher_macos - sha256: "17ba2000b847f334f16626a574c702b196723af2a289e7a93ffcb79acff855c2" + sha256: c043a77d6600ac9c38300567f33ef12b0ef4f4783a2c1f00231d2b1941fea13f url: "https://pub.dev" source: hosted - version: "3.2.2" + version: "3.2.3" url_launcher_platform_interface: dependency: transitive description: @@ -1871,7 +1810,7 @@ packages: source: hosted version: "3.1.4" uuid: - dependency: transitive + dependency: "direct main" description: name: uuid sha256: a5be9ef6618a7ac1e964353ef476418026db906c4facdedaa299b7a2e71690ff @@ -1898,26 +1837,34 @@ packages: dependency: transitive description: name: vector_graphics_compiler - sha256: "557a315b7d2a6dbb0aaaff84d857967ce6bdc96a63dc6ee2a57ce5a6ee5d3331" + sha256: d354a7ec6931e6047785f4db12a1f61ec3d43b207fc0790f863818543f8ff0dc url: "https://pub.dev" source: hosted - version: "1.1.17" + version: "1.1.19" vector_math: dependency: transitive description: name: vector_math - sha256: "80b3257d1492ce4d091729e3a67a60407d227c27241d6927be0130c98e741803" + sha256: d530bd74fea330e6e364cda7a85019c434070188383e1cd8d9777ee586914c5b url: "https://pub.dev" source: hosted - version: "2.1.4" + version: "2.2.0" vm_service: dependency: transitive description: name: vm_service - sha256: ddfa8d30d89985b96407efce8acbdd124701f96741f2d981ca860662f1c0dc02 + sha256: "45caa6c5917fa127b5dbcfbd1fa60b14e583afdc08bfc96dda38886ca252eb60" url: "https://pub.dev" source: hosted - version: "15.0.0" + version: "15.0.2" + vodozemac: + dependency: "direct main" + description: + name: vodozemac + sha256: dba14017e042748fb22d270e8ab1d3e46965b89788dd3857dba938ec07571968 + url: "https://pub.dev" + source: hosted + version: "0.2.0" volume_controller: dependency: transitive description: @@ -1930,26 +1877,26 @@ packages: dependency: transitive description: name: wakelock_plus - sha256: a474e314c3e8fb5adef1f9ae2d247e57467ad557fa7483a2b895bc1b421c5678 + sha256: "9296d40c9adbedaba95d1e704f4e0b434be446e2792948d0e4aa977048104228" url: "https://pub.dev" source: hosted - version: "1.3.2" + version: "1.4.0" wakelock_plus_platform_interface: dependency: transitive description: name: wakelock_plus_platform_interface - sha256: e10444072e50dbc4999d7316fd303f7ea53d31c824aa5eb05d7ccbdd98985207 + sha256: "036deb14cd62f558ca3b73006d52ce049fabcdcb2eddfe0bf0fe4e8a943b5cf2" url: "https://pub.dev" source: hosted - version: "1.2.3" + version: "1.3.0" watcher: dependency: transitive description: name: watcher - sha256: "0b7fd4a0bbc4b92641dbf20adfd7e3fd1398fe17102d94b674234563e110088a" + sha256: "5bf046f41320ac97a469d506261797f35254fa61c641741ef32dacda98b7d39c" url: "https://pub.dev" source: hosted - version: "1.1.2" + version: "1.1.3" web: dependency: transitive description: @@ -1991,21 +1938,21 @@ packages: source: hosted version: "1.2.1" webrtc_interface: - dependency: transitive + dependency: "direct main" description: name: webrtc_interface - sha256: "86fe3afc81a08481dfb25cf14a5a94e27062ecef25544783f352c914e0bbc1ca" + sha256: "2e604a31703ad26781782fb14fa8a4ee621154ee2c513d2b9938e486fa695233" url: "https://pub.dev" source: hosted - version: "1.2.2+hotfix.2" + version: "1.3.0" widgetbook_annotation: dependency: transitive description: name: widgetbook_annotation - sha256: "41662c48c2a0e82cac676a83727203d863621a5f6fb2505395287b8789afdf38" + sha256: d29eef40efac4beb51f5e9d3bb6dd800db986f7020822b06b60d27f0299dac49 url: "https://pub.dev" source: hosted - version: "3.5.0" + version: "3.7.0" win32: dependency: transitive description: @@ -2026,10 +1973,10 @@ packages: dependency: "direct main" description: name: win_toast - sha256: "7d0976d321ee034f3dfc79ec5b9ee7b8d8669413eea3559298e12c40ccea29d1" + sha256: "1e0dc6e1094bc882ed87133e80c12cbe805d72f6faa7ed98795c7ffe7f7ea900" url: "https://pub.dev" source: hosted - version: "0.3.1" + version: "0.4.0" window_manager: dependency: "direct main" description: @@ -2079,5 +2026,5 @@ packages: source: hosted version: "2.1.0" sdks: - dart: ">=3.8.0 <4.0.0" - flutter: ">=3.27.0" + dart: ">=3.9.0 <4.0.0" + flutter: ">=3.35.0" diff --git a/commet/pubspec.yaml b/commet/pubspec.yaml index 3c5334e81..d78711029 100644 --- a/commet/pubspec.yaml +++ b/commet/pubspec.yaml @@ -15,7 +15,6 @@ dependencies: flutter_background_service: ^5.0.5 flutter_blurhash: ^0.8.2 flutter_markdown: ^0.6.9+1 - flutter_olm: ^2.0.0 flutter_openssl_crypto: ^0.5.0 flutter_staggered_grid_view: ^0.7.0 flutter_svg: ^2.0.7 @@ -24,14 +23,12 @@ dependencies: http: ^1.1.0 implicitly_animated_list: ^2.2.0 intl: any - intl_translation: ^0.20.0 intl_utils: any just_the_tooltip: ^0.0.12 - media_kit: ^1.1.11 - media_kit_video: ^1.2.5 - media_kit_libs_video: ^1.0.5 + media_kit: ^1.2.0 + media_kit_libs_video: ^1.0.6 + media_kit_video: ^1.3.0 mime: ^1.0.4 - olm: ^2.0.3 pasteboard: ^0.2.0 path: ^1.8.2 path_provider: ^2.0.13 @@ -45,7 +42,7 @@ dependencies: unifiedpush: ^5.0.1 universal_html: ^2.2.4 url_launcher: ^6.1.11 - win_toast: ^0.3.0 + win_toast: ^0.4.0 window_manager: ^0.3.4 flutter: sdk: flutter @@ -67,11 +64,11 @@ dependencies: matrix: git: url: https://github.com/commetchat/matrix-dart-sdk.git - ref: main + ref: upstream-v1.1.1 matrix_dart_sdk_drift_db: git: url: https://github.com/commetchat/matrix-dart-sdk-drift-db.git - ref: voip + ref: upstream-v1.1.1 signal_sticker_api: git: https://github.com/commetchat/signal-sticker-api.git @@ -79,13 +76,10 @@ dependencies: git: https://github.com/lagmachine-com/starfield.git sqlite3_flutter_libs: ^0.5.23 fuzzy: ^0.5.1 - encrypt: ^5.0.3 - pointycastle: ^3.7.4 - drift: ^2.22.1 + drift: ^2.28.1 archive: ^3.6.1 exif: ^3.3.0 image: ^4.2.0 - reflectable: ^4.0.10 flutter_webrtc: ^0.14.1 file_picker: ^10.2.0 flutter_web_auth_2: ^4.1.0 @@ -94,6 +88,9 @@ dependencies: url: https://github.com/daadu/receive_intent ref: master flutter_shortcuts_new: ^2.0.0 + flutter_vodozemac: ^0.2.2 + vodozemac: ^0.2.0 + intl_translation: ^0.20.1 ## ---- Putting some extra lines in here to help git with the diff @@ -104,27 +101,25 @@ dependencies: ## End Google Services Dependencies ## ---- ## ---- - + markdown: any + collection: any + webrtc_interface: any + uuid: any dependency_overrides: - # Force dependency overrides for all (direct or transitive) dependencies - - matrix: - git: - url: https://github.com/commetchat/matrix-dart-sdk.git - ref: voip + analyzer: ^7.3.0 dev_dependencies: + drift_dev: ^2.28.0 build_runner: ^2.4.11 flutter_launcher_icons: ^0.13.1 - flutter_lints: ^6.0.0 msix: ^3.7.0 pubspec_dependency_sorter: ^1.0.4 flutter_test: sdk: flutter integration_test: sdk: flutter - drift_dev: ^2.18.0 - + file: any + flutter_intl: class_name: T main_locale: en @@ -159,6 +154,7 @@ flutter: - assets/emoji_data/ - assets/emoji_data/shortcodes/ - assets/js/package/ + - assets/vodozemac/ shaders: - assets/shader/texture_coordinate.frag - assets/shader/star_trails.frag diff --git a/commet/scripts/build_release.dart b/commet/scripts/build_release.dart index c57b3c74d..2ffbaa169 100644 --- a/commet/scripts/build_release.dart +++ b/commet/scripts/build_release.dart @@ -44,7 +44,7 @@ String getFlutterPlatformName(String platform) { return platform; } -main(List args) async { +Future main(List args) async { String version = getVersionTag(args); String platform = getPlatform(args); String hash = getHash(args); @@ -81,8 +81,8 @@ main(List args) async { "ENABLE_GOOGLE_SERVICES=$enableGoogleServices", if (buildDetail != null) "--dart-define", if (buildDetail != null) "BUILD_DETAIL=$buildDetail", - if (platform == "web") "--web-renderer", - if (platform == "web") "html", + if (platform == "web") "--dart-define", + if (platform == "web") "FLUTTER_WEB_CANVASKIT_URL=canvaskit/", if (platform == "web") "--source-maps" ], runInShell: true, diff --git a/commet/scripts/codegen.dart b/commet/scripts/codegen.dart index 03d1dafcf..bc906fb2d 100644 --- a/commet/scripts/codegen.dart +++ b/commet/scripts/codegen.dart @@ -115,6 +115,7 @@ Future buildRunner() async { "run", "build_runner", "build", + "--delete-conflicting-outputs", ], runInShell: true, ); diff --git a/commet/scripts/extract_strings.dart b/commet/scripts/extract_strings.dart index 1bfb76b28..92c1e77c3 100644 --- a/commet/scripts/extract_strings.dart +++ b/commet/scripts/extract_strings.dart @@ -23,7 +23,7 @@ void extractStrings(List files) async { print(process.stderr); } -main() async { +Future main() async { var files = await codegen.generateFileLists(); extractStrings(files); } diff --git a/commet/scripts/prepare-web.sh b/commet/scripts/prepare-web.sh new file mode 100755 index 000000000..875ae0a46 --- /dev/null +++ b/commet/scripts/prepare-web.sh @@ -0,0 +1,10 @@ +#!/bin/sh -ve + +git clone https://github.com/famedly/dart-vodozemac.git .vodozemac +cd .vodozemac +cargo install flutter_rust_bridge_codegen +flutter_rust_bridge_codegen build-web --dart-root dart --rust-root $(readlink -f rust) --release +cd .. +rm -f ./assets/vodozemac/vodozemac_bindings_dart* +mv .vodozemac/dart/web/pkg/vodozemac_bindings_dart* ./assets/vodozemac/ +rm -rf .vodozemac diff --git a/commet/scripts/setup_android_release.dart b/commet/scripts/setup_android_release.dart index ae42229ea..6cf0ed850 100644 --- a/commet/scripts/setup_android_release.dart +++ b/commet/scripts/setup_android_release.dart @@ -14,7 +14,7 @@ void writeEncodedKeyfile(String file) { File("$file.b64").writeAsString(b64); } -decodeAndWriteKeyFile(String keyB64) { +void decodeAndWriteKeyFile(String keyB64) { var bytes = base64Decode(keyB64); var file = File("android/key.jks"); if (!file.existsSync()) { @@ -24,7 +24,7 @@ decodeAndWriteKeyFile(String keyB64) { file.writeAsBytesSync(bytes); } -writeKeyProperties(String password) { +void writeKeyProperties(String password) { var file = File("android/key.properties"); if (!file.existsSync()) { file.createSync(recursive: true); @@ -38,7 +38,7 @@ storeFile=../key.jks """); } -main(List args) { +void main(List args) { //Utility to encode a keyfile to base64, not needed for setup String? keyFile = getArg(args, "--key_file"); diff --git a/commet/web/index.html b/commet/web/index.html index 36c2a5a25..3b81920b3 100644 --- a/commet/web/index.html +++ b/commet/web/index.html @@ -39,8 +39,6 @@ - - diff --git a/commet/windows/flutter/generated_plugins.cmake b/commet/windows/flutter/generated_plugins.cmake index 29a23f069..34ca0c9d1 100644 --- a/commet/windows/flutter/generated_plugins.cmake +++ b/commet/windows/flutter/generated_plugins.cmake @@ -22,6 +22,7 @@ list(APPEND FLUTTER_PLUGIN_LIST list(APPEND FLUTTER_FFI_PLUGIN_LIST flutter_local_notifications_windows + flutter_vodozemac ) set(PLUGIN_BUNDLED_LIBRARIES)