parent
673c5bd894
commit
8b7e29ae33
3 changed files with 14 additions and 3 deletions
2
.gitmodules
vendored
2
.gitmodules
vendored
|
|
@ -1,4 +1,4 @@
|
||||||
[submodule "gomuks"]
|
[submodule "gomuks"]
|
||||||
path = gomuks
|
path = gomuks
|
||||||
url = https://github.com/Henry-Hiles/gomuks
|
url = https://github.com/Henry-Hiles/gomuks
|
||||||
branch = quad/chore/remove-root-set
|
branch = quad/feat/customizable-device-name
|
||||||
|
|
|
||||||
2
gomuks
2
gomuks
|
|
@ -1 +1 @@
|
||||||
Subproject commit c20070298d450cc02f465a503a5a52fea74af0d5
|
Subproject commit ae11daa1b14b103688e57accb9c65ad6401cb3ef
|
||||||
|
|
@ -7,6 +7,7 @@ import "dart:math";
|
||||||
import "package:fast_immutable_collections/fast_immutable_collections.dart";
|
import "package:fast_immutable_collections/fast_immutable_collections.dart";
|
||||||
import "package:ffi/ffi.dart";
|
import "package:ffi/ffi.dart";
|
||||||
import "package:flutter/foundation.dart";
|
import "package:flutter/foundation.dart";
|
||||||
|
import "package:intl/intl.dart";
|
||||||
import "package:nexus/controllers/account_data.dart";
|
import "package:nexus/controllers/account_data.dart";
|
||||||
import "package:nexus/controllers/client_state.dart";
|
import "package:nexus/controllers/client_state.dart";
|
||||||
import "package:nexus/controllers/init_complete.dart";
|
import "package:nexus/controllers/init_complete.dart";
|
||||||
|
|
@ -68,7 +69,17 @@ class ClientController extends AsyncNotifier<int> {
|
||||||
..free(valuePtr);
|
..free(valuePtr);
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
final handle = await Isolate.run(GomuksInit);
|
final handle = await Isolate.run(() {
|
||||||
|
final message =
|
||||||
|
"Nexus on ${toBeginningOfSentenceCase(Platform.operatingSystem)}"
|
||||||
|
.toNativeUtf8()
|
||||||
|
.cast<Char>();
|
||||||
|
try {
|
||||||
|
return GomuksInit(message);
|
||||||
|
} finally {
|
||||||
|
calloc.free(message);
|
||||||
|
}
|
||||||
|
});
|
||||||
|
|
||||||
final callable =
|
final callable =
|
||||||
NativeCallable<
|
NativeCallable<
|
||||||
|
|
|
||||||
Loading…
Reference in a new issue