Skip to content

Commit

Permalink
Use dart3
Browse files Browse the repository at this point in the history
  • Loading branch information
Yesterday17 committed Aug 28, 2023
1 parent 03ad638 commit be9a569
Show file tree
Hide file tree
Showing 21 changed files with 348 additions and 225 deletions.
2 changes: 1 addition & 1 deletion README.md
Original file line number Diff line number Diff line change
Expand Up @@ -16,7 +16,7 @@ Desktop / Mobile client for Project Anni.
export CPATH="$(clang -v 2>&1 | grep "Selected GCC installation" | rev | cut -d' ' -f1 | rev)/include"

# [Optional] Build models
flutter pub run build_runner build --delete-conflicting-outputs
dart run build_runner build --delete-conflicting-outputs

# Build apk
flutter build apk --release --split-per-abi --split-debug-info debug --obfuscate
Expand Down
2 changes: 1 addition & 1 deletion analysis_options.yaml
Original file line number Diff line number Diff line change
Expand Up @@ -26,6 +26,6 @@ linter:
prefer_single_quotes: true
use_enums: true
prefer_final_locals: true
prefer_final_parameters: true
prefer_final_parameters: false
# Additional information about this file can be found at
# https://dart.dev/guides/language/analysis-options
126 changes: 100 additions & 26 deletions annix/Cargo.lock

Some generated files are not rendered by default. Learn more about how customized files appear on GitHub.

4 changes: 2 additions & 2 deletions annix/Cargo.toml
Original file line number Diff line number Diff line change
Expand Up @@ -7,12 +7,12 @@ edition = "2021"
crate-type = ["staticlib", "cdylib", "rlib"]

[dependencies]
flutter_rust_bridge = { version = "1.72.2", features = ["uuid"] }
flutter_rust_bridge = { version = "1.81.0", features = ["uuid"] }
once_cell = "1.17.1"
rusqlite = { version = "0.28.0", features = ["bundled"] }

anni-repo = { version = "0.3.2", features = ["db"] }
uuid = "1"

[build-dependencies]
flutter_rust_bridge_codegen = { version = "1.72.0", features = ["uuid"] }
flutter_rust_bridge_codegen = { version = "1.81.0", features = ["uuid"] }
7 changes: 4 additions & 3 deletions annix/src/network/generated.rs
Original file line number Diff line number Diff line change
Expand Up @@ -9,10 +9,11 @@
clippy::too_many_arguments
)]
// AUTO GENERATED FILE, DO NOT EDIT.
// Generated by `flutter_rust_bridge`@ 1.72.0.
// Generated by `flutter_rust_bridge`@ 1.81.0.

use crate::network::api::*;
use core::panic::UnwindSafe;
use flutter_rust_bridge::rust2dart::IntoIntoDart;
use flutter_rust_bridge::*;
use std::ffi::c_void;
use std::sync::Arc;
Expand All @@ -25,7 +26,7 @@ fn wire_update_network_status_impl(
port_: MessagePort,
is_online: impl Wire2Api<bool> + UnwindSafe,
) {
FLUTTER_RUST_BRIDGE_HANDLER.wrap(
FLUTTER_RUST_BRIDGE_HANDLER.wrap::<_, _, _, ()>(
WrapInfo {
debug_name: "update_network_status",
port: Some(port_),
Expand All @@ -41,7 +42,7 @@ fn wire_is_online__method__NetworkStatus_impl(
port_: MessagePort,
that: impl Wire2Api<NetworkStatus> + UnwindSafe,
) {
FLUTTER_RUST_BRIDGE_HANDLER.wrap(
FLUTTER_RUST_BRIDGE_HANDLER.wrap::<_, _, _, bool>(
WrapInfo {
debug_name: "is_online__method__NetworkStatus",
port: Some(port_),
Expand Down
Loading

0 comments on commit be9a569

Please sign in to comment.