fix(all): Update the Flutter version

This commit is contained in:
PapaTutuWawa 2024-09-29 18:56:57 +02:00
parent bf653cf556
commit 145bdff33b
19 changed files with 534 additions and 508 deletions

View File

@ -1,3 +1,9 @@
plugins {
id "com.android.application"
id "kotlin-android"
id "dev.flutter.flutter-gradle-plugin"
}
def localProperties = new Properties()
def localPropertiesFile = rootProject.file('local.properties')
if (localPropertiesFile.exists()) {
@ -6,11 +12,6 @@ if (localPropertiesFile.exists()) {
}
}
def flutterRoot = localProperties.getProperty('flutter.sdk')
if (flutterRoot == null) {
throw new GradleException("Flutter SDK not found. Define location with flutter.sdk in the local.properties file.")
}
def flutterVersionCode = localProperties.getProperty('flutter.versionCode')
if (flutterVersionCode == null) {
flutterVersionCode = '1'
@ -21,12 +22,8 @@ if (flutterVersionName == null) {
flutterVersionName = '1.0'
}
apply plugin: 'com.android.application'
apply plugin: 'kotlin-android'
apply from: "$flutterRoot/packages/flutter_tools/gradle/flutter.gradle"
android {
compileSdkVersion 33
compileSdkVersion 34
compileOptions {
sourceCompatibility JavaVersion.VERSION_1_8
@ -67,6 +64,5 @@ flutter {
}
dependencies {
implementation "org.jetbrains.kotlin:kotlin-stdlib-jdk7:$kotlin_version"
implementation "androidx.activity:activity-ktx:1.7.2"
}

View File

@ -1,16 +1,3 @@
buildscript {
ext.kotlin_version = '1.8.21'
repositories {
google()
mavenCentral()
}
dependencies {
classpath 'com.android.tools.build:gradle:7.1.2'
classpath "org.jetbrains.kotlin:kotlin-gradle-plugin:$kotlin_version"
}
}
allprojects {
repositories {
google()

View File

@ -1,11 +1,25 @@
include ':app'
pluginManagement {
def flutterSdkPath = {
def properties = new Properties()
file("local.properties").withInputStream { properties.load(it) }
def flutterSdkPath = properties.getProperty("flutter.sdk")
assert flutterSdkPath != null, "flutter.sdk not set in local.properties"
return flutterSdkPath
}()
def localPropertiesFile = new File(rootProject.projectDir, "local.properties")
def properties = new Properties()
includeBuild("$flutterSdkPath/packages/flutter_tools/gradle")
assert localPropertiesFile.exists()
localPropertiesFile.withReader("UTF-8") { reader -> properties.load(reader) }
repositories {
google()
mavenCentral()
gradlePluginPortal()
}
}
def flutterSdkPath = properties.getProperty("flutter.sdk")
assert flutterSdkPath != null, "flutter.sdk not set in local.properties"
apply from: "$flutterSdkPath/packages/flutter_tools/gradle/app_plugin_loader.gradle"
plugins {
id "dev.flutter.flutter-plugin-loader" version "1.0.0"
id "com.android.application" version "7.1.2" apply false
id "org.jetbrains.kotlin.android" version "1.8.21" apply false
}
include ":app"

View File

@ -3,15 +3,15 @@
"android-nixpkgs": {
"inputs": {
"devshell": "devshell",
"flake-utils": "flake-utils_2",
"flake-utils": "flake-utils",
"nixpkgs": "nixpkgs"
},
"locked": {
"lastModified": 1705781728,
"narHash": "sha256-7FBCjLHXFiWN44euZkp9xlvgxgsBLVJC3SGGwxbdVD4=",
"lastModified": 1727554699,
"narHash": "sha256-puBCNL5PW7Pej+6Srmi2YjEgNeE015NFe33hbkkLqeQ=",
"owner": "tadfisher",
"repo": "android-nixpkgs",
"rev": "974b9a9fd58b94b8ff5dbabc2c271e1dec857fd2",
"rev": "bc34ef1c71fe9eafcfb1d637b431fca83d746625",
"type": "github"
},
"original": {
@ -22,7 +22,7 @@
},
"bab": {
"inputs": {
"flake-utils": "flake-utils_3",
"flake-utils": "flake-utils_2",
"nixpkgs": "nixpkgs_2"
},
"locked": {
@ -41,18 +41,17 @@
},
"devshell": {
"inputs": {
"flake-utils": "flake-utils",
"nixpkgs": [
"android-nixpkgs",
"nixpkgs"
]
},
"locked": {
"lastModified": 1705332421,
"narHash": "sha256-USpGLPme1IuqG78JNqSaRabilwkCyHmVWY0M9vYyqEA=",
"lastModified": 1722113426,
"narHash": "sha256-Yo/3loq572A8Su6aY5GP56knpuKYRvM2a1meP9oJZCw=",
"owner": "numtide",
"repo": "devshell",
"rev": "83cb93d6d063ad290beee669f4badf9914cc16ec",
"rev": "67cce7359e4cd3c45296fb4aaf6a19e2a9c757ae",
"type": "github"
},
"original": {
@ -66,11 +65,11 @@
"systems": "systems"
},
"locked": {
"lastModified": 1701680307,
"narHash": "sha256-kAuep2h5ajznlPMD9rnQyffWG8EM/C73lejGofXvdM8=",
"lastModified": 1726560853,
"narHash": "sha256-X6rJYSESBVr3hBoH0WbKE5KvhPU5bloyZ2L4K60/fPQ=",
"owner": "numtide",
"repo": "flake-utils",
"rev": "4022d587cbbfd70fe950c1e2083a02621806a725",
"rev": "c1dfcf08411b08f6b8615f7d8971a2bfa81d5e8a",
"type": "github"
},
"original": {
@ -83,24 +82,6 @@
"inputs": {
"systems": "systems_2"
},
"locked": {
"lastModified": 1705309234,
"narHash": "sha256-uNRRNRKmJyCRC/8y1RqBkqWBLM034y4qN7EprSdmgyA=",
"owner": "numtide",
"repo": "flake-utils",
"rev": "1ef2e671c3b0c19053962c07dbda38332dcebf26",
"type": "github"
},
"original": {
"owner": "numtide",
"repo": "flake-utils",
"type": "github"
}
},
"flake-utils_3": {
"inputs": {
"systems": "systems_3"
},
"locked": {
"lastModified": 1689068808,
"narHash": "sha256-6ixXo3wt24N/melDWjq70UuHQLxGV8jZvooRanIHXw0=",
@ -115,9 +96,9 @@
"type": "github"
}
},
"flake-utils_4": {
"flake-utils_3": {
"inputs": {
"systems": "systems_4"
"systems": "systems_3"
},
"locked": {
"lastModified": 1692799911,
@ -135,11 +116,11 @@
},
"nixpkgs": {
"locked": {
"lastModified": 1705496572,
"narHash": "sha256-rPIe9G5EBLXdBdn9ilGc0nq082lzQd0xGGe092R/5QE=",
"lastModified": 1727348695,
"narHash": "sha256-J+PeFKSDV+pHL7ukkfpVzCOO7mBSrrpJ3svwBFABbhI=",
"owner": "NixOS",
"repo": "nixpkgs",
"rev": "842d9d80cfd4560648c785f8a4e6f3b096790e19",
"rev": "1925c603f17fc89f4c8f6bf6f631a802ad85d784",
"type": "github"
},
"original": {
@ -167,11 +148,11 @@
},
"nixpkgs_3": {
"locked": {
"lastModified": 1705697961,
"narHash": "sha256-XepT3WS516evSFYkme3GrcI3+7uwXHqtHbip+t24J7E=",
"lastModified": 1727586919,
"narHash": "sha256-e/YXG0tO5GWHDS8QQauj8aj4HhXEm602q9swrrlTlKQ=",
"owner": "NixOS",
"repo": "nixpkgs",
"rev": "e5d1c87f5813afde2dda384ac807c57a105721cc",
"rev": "2dcd9c55e8914017226f5948ac22c53872a13ee2",
"type": "github"
},
"original": {
@ -185,7 +166,7 @@
"inputs": {
"android-nixpkgs": "android-nixpkgs",
"bab": "bab",
"flake-utils": "flake-utils_4",
"flake-utils": "flake-utils_3",
"nixpkgs": "nixpkgs_3"
}
},
@ -233,21 +214,6 @@
"repo": "default",
"type": "github"
}
},
"systems_4": {
"locked": {
"lastModified": 1681028828,
"narHash": "sha256-Vy1rq5AaRuLzOxct8nz4T6wlgyUR7zLU309k9mBC768=",
"owner": "nix-systems",
"repo": "default",
"rev": "da67096a3b9bf56a91d16901293e51ba5b49a27e",
"type": "github"
},
"original": {
"owner": "nix-systems",
"repo": "default",
"type": "github"
}
}
},
"root": "root",

View File

@ -35,6 +35,7 @@
platforms-android-30
platforms-android-31
platforms-android-33
platforms-android-34
# For flutter_zxing
cmake-3-18-1

View File

@ -18,12 +18,12 @@ class ConnectivityService {
final Logger _log = Logger('ConnectivityService');
/// Caches the current connectivity state
late ConnectivityResult _connectivity;
late List<ConnectivityResult> _connectivity;
Stream<ConnectivityEvent> get stream => _controller.stream;
@visibleForTesting
void setConnectivity(ConnectivityResult result) {
void setConnectivity(List<ConnectivityResult> result) {
_log.warning(
'Internal connectivity state changed by request originating from outside ConnectivityService',
);
@ -34,10 +34,10 @@ class ConnectivityService {
final conn = Connectivity();
_connectivity = await conn.checkConnectivity();
conn.onConnectivityChanged.listen((ConnectivityResult result) {
final regained = _connectivity == ConnectivityResult.none &&
result != ConnectivityResult.none;
final lost = result == ConnectivityResult.none;
conn.onConnectivityChanged.listen((List<ConnectivityResult> result) {
final regained = _connectivity.contains(ConnectivityResult.none) &&
!result.contains(ConnectivityResult.none);
final lost = result.contains(ConnectivityResult.none);
_connectivity = result;
_controller.add(
@ -49,9 +49,9 @@ class ConnectivityService {
});
}
ConnectivityResult get currentState => _connectivity;
List<ConnectivityResult> get currentState => _connectivity;
Future<bool> hasConnection() async {
return _connectivity != ConnectivityResult.none;
return !_connectivity.contains(ConnectivityResult.none);
}
}

View File

@ -457,12 +457,14 @@ Future<void> openFile(String path) async {
/// bgColor attribute.
Config getEmojiPickerConfig(Color backgroundColor) {
return Config(
bgColor: backgroundColor,
// Make the "no recents" text translatable.
noRecents: Text(
t.emojiPicker.noRecents,
style: const TextStyle(fontSize: 20),
textAlign: TextAlign.center,
emojiViewConfig: EmojiViewConfig(
backgroundColor: backgroundColor,
// Make the "no recents" text translatable.
noRecents: Text(
t.emojiPicker.noRecents,
style: const TextStyle(fontSize: 20),
textAlign: TextAlign.center,
),
),
);
}

View File

@ -56,9 +56,9 @@ class SettingsPage extends StatelessWidget {
),
SettingsRow(
title: t.pages.settings.stickers.title,
prefix: Padding(
padding: const EdgeInsets.only(right: 16),
child: Icon(PhosphorIcons.fill.sticker),
prefix: const Padding(
padding: EdgeInsets.only(right: 16),
child: Icon(PhosphorIconsFill.sticker),
),
onTap: () {
Navigator.pushNamed(context, stickersRoute);

View File

@ -80,18 +80,18 @@ class StickerPacksSettingsState extends State<StickerPacksSettingsPage> {
),
description: snapshot.data![index].description,
crossAxisAlignment: CrossAxisAlignment.start,
prefix: Padding(
padding: const EdgeInsets.only(right: 16),
prefix: const Padding(
padding: EdgeInsets.only(right: 16),
child: SizedBox(
width: 48,
height: 48,
// TODO(PapaTutuWawa): Sticker pack thumbnails would be nice
child: ClipRRect(
borderRadius: const BorderRadius.all(radiusLarge),
borderRadius: BorderRadius.all(radiusLarge),
child: ColoredBox(
color: Colors.white60,
child: Icon(
PhosphorIcons.regular.sticker,
PhosphorIconsRegular.sticker,
size: 32,
),
),

View File

@ -7,13 +7,13 @@ class UIConnectivityService {
final _conn = Connectivity();
/// The cached connection state.
ConnectivityResult _state = ConnectivityResult.none;
ConnectivityResult get status => _state;
List<ConnectivityResult> _state = [ConnectivityResult.none];
List<ConnectivityResult> get status => _state;
/// The subscription to the event stream
late StreamSubscription<ConnectivityResult> _subscription;
late StreamSubscription<List<ConnectivityResult>> _subscription;
bool get hasConnection => _state != ConnectivityResult.none;
bool get hasConnection => !_state.contains(ConnectivityResult.none);
/// Initializes the event stream and populates the cache.
Future<void> initialize() async {

View File

@ -121,10 +121,10 @@ class MessageBubbleBottomState extends State<MessageBubbleBottom> {
),
if (widget.message.stickerPackId != null &&
!GetIt.I.get<PreferencesCubit>().state.enableStickers)
Padding(
padding: const EdgeInsets.only(left: 3),
const Padding(
padding: EdgeInsets.only(left: 3),
child: Icon(
PhosphorIcons.regular.sticker,
PhosphorIconsRegular.sticker,
size: _bubbleBottomIconSize,
color: Colors.white,
),

View File

@ -49,10 +49,10 @@ class StickerChatWidget extends StatelessWidget {
child: Row(
mainAxisSize: MainAxisSize.min,
children: [
Padding(
padding: const EdgeInsets.only(right: 8),
const Padding(
padding: EdgeInsets.only(right: 8),
child: Icon(
PhosphorIcons.regular.sticker,
PhosphorIconsRegular.sticker,
),
),
Text(

View File

@ -49,10 +49,10 @@ class QuotedStickerWidget extends StatelessWidget {
Row(
mainAxisSize: MainAxisSize.min,
children: [
Padding(
const Padding(
padding: const EdgeInsets.only(right: 8),
child: Icon(
PhosphorIcons.regular.sticker,
PhosphorIconsRegular.sticker,
),
),
Text(

View File

@ -45,9 +45,9 @@ class CombinedPicker extends StatelessWidget {
TabBar(
controller: tabController,
indicatorColor: primaryColor,
tabs: [
const Tab(icon: Icon(Icons.insert_emoticon)),
Tab(icon: Icon(PhosphorIcons.regular.sticker)),
tabs: const [
Tab(icon: Icon(Icons.insert_emoticon)),
Tab(icon: Icon(PhosphorIconsRegular.sticker)),
],
),
Expanded(

View File

@ -251,8 +251,8 @@ class ConversationCard extends StatelessWidget {
size: 20,
);
} else {
preview = Icon(
PhosphorIcons.regular.sticker,
preview = const Icon(
PhosphorIconsRegular.sticker,
size: 20,
);
}

View File

@ -59,7 +59,7 @@ class MobileMessagingTextFieldController {
bool requestingPermission = false;
/// The audio recorder.
final Record _recorder = Record();
final AudioRecorder _recorder = AudioRecorder();
/// The JID of the currently opened chat.
final String conversationJid;
@ -107,6 +107,7 @@ class MobileMessagingTextFieldController {
filename,
);
await _recorder.start(
const RecordConfig(),
path: recordingFilePath,
);
}

View File

@ -48,7 +48,7 @@ class EmojiStickerPickerIcon extends StatelessWidget {
? Icons.keyboard
: (tabController.index == 0
? Icons.emoji_emotions
: PhosphorIcons.regular.sticker),
: PhosphorIconsRegular.sticker),
size: iconSize,
color: primaryColor,
),

File diff suppressed because it is too large Load Diff

View File

@ -7,49 +7,49 @@ version: 0.5.1+14
environment:
sdk: ">=3.0.0 <4.0.0"
flutter: "3.7.3"
flutter: "3.24.1"
dependencies:
archive: ^3.3.9
archive: ^3.6.1
audiofileplayer: 2.1.1
auto_size_text: 3.0.0
badges: ^3.1.2
better_open_file: ^3.6.4
bloc: ^8.1.2
collection: ^1.16.0
connectivity_plus: ^4.0.2
better_open_file: ^3.6.5
bloc: ^8.1.4
collection: ^1.18.0
connectivity_plus: ^6.0.5
cropperx: 1.1.1
cryptography: ^2.6.0
cryptography: ^2.7.0
#cupertino_icons: 1.0.2
dart_emoji: 0.2.0+2
decorated_icon: 1.2.1
dynamic_color: 1.6.8
emoji_picker_flutter: ^1.6.1
dynamic_color: ^1.7.0
emoji_picker_flutter: ^3.1.0
flutter:
sdk: flutter
flutter_bloc: ^8.1.3
flutter_bloc: ^8.1.6
flutter_blurhash: 0.8.2
flutter_contacts: ^1.1.7+1
flutter_image_compress: ^2.0.4
flutter_isolate: ^2.0.4
flutter_keyboard_visibility: ^5.4.1
flutter_contacts: ^1.1.9+2
flutter_image_compress: ^2.3.0
flutter_isolate: ^2.1.0
flutter_keyboard_visibility: ^6.0.0
flutter_localizations:
sdk: flutter
flutter_parsed_text: 2.2.1
flutter_secure_storage: ^9.0.0
flutter_secure_storage: ^9.2.2
flutter_speed_dial: ^7.0.0
flutter_vibrate: 1.3.0
flutter_zxing: ^1.4.1
fluttertoast: ^8.2.2
freezed_annotation: ^2.4.1
get_it: ^7.6.4
grouped_list: 5.1.2
flutter_zxing: ^1.7.0
fluttertoast: ^8.2.8
freezed_annotation: ^2.4.4
get_it: ^7.7.0
grouped_list: ^6.0.0
hex: 0.2.0
image: ^4.0.17
json_annotation: ^4.8.1
image: ^4.2.0
json_annotation: ^4.9.0
logging: ^1.2.0
meta: ^1.7.0
mime: ^1.0.4
meta: ^1.15.0
mime: ^1.0.6
move_to_background:
git:
url: https://github.com/ViliusP/move_to_background.git
@ -75,50 +75,50 @@ dependencies:
moxxyv2_builders:
hosted: https://git.polynom.me/api/packages/Moxxy/pub
version: 0.2.1
native_imaging: 0.1.0
native_imaging: ^0.1.1
omemo_dart:
hosted: https://git.polynom.me/api/packages/PapaTutuWawa/pub
version: 0.5.1
version: 0.6.0
page_transition: ^2.1.0
path: ^1.8.3
path_provider: ^2.1.1
permission_handler: ^11.0.0
phosphor_flutter: ^2.0.0
path: ^1.9.0
path_provider: ^2.1.4
permission_handler: ^11.3.1
phosphor_flutter: ^2.1.0
qr_flutter: ^4.1.0
random_string: 2.3.1
record: ^4.4.4
share_handler: ^0.0.17
slang: 3.23.0
slang_flutter: 3.23.0
sqflite_common: ^2.5.0
sqflite_sqlcipher: ^2.2.1
record: ^5.1.2
share_handler: ^0.0.21
slang: ^3.31.2
slang_flutter: ^3.31.0
sqflite_common: ^2.5.4+4
sqflite_sqlcipher: ^3.1.0+1
#scrollable_positioned_list: 0.2.3
swipeable_tile:
git:
url: https://github.com/PapaTutuWawa/swipeable_tile.git
ref: bfab5e28f1f1ea624232002f0d05481cb2bd9997
synchronized: ^3.1.0
synchronized: ^3.3.0+3
udp: 5.0.3
url_launcher: ^6.1.14
url_launcher: ^6.3.0
#unifiedpush: 3.0.1
uuid: ^3.0.7
video_player: ^2.7.2
video_player: ^2.9.1
visibility_detector: 0.4.0+2
dev_dependencies:
build_runner: ^2.4.6
flutter_launcher_icons: ^0.13.1
flutter_lints: ^2.0.1
build_runner: ^2.4.12
flutter_launcher_icons: ^0.14.1
flutter_lints: ^5.0.0
#flutter_test:
# sdk: flutter
freezed: ^2.1.0+1
freezed: ^2.5.7
#integration_test:
# sdk: flutter
json_serializable: ^6.3.1
pigeon: 11.0.1
slang_build_runner: 3.23.0
test: ^1.21.1
very_good_analysis: ^5.1.0
json_serializable: ^6.8.0
pigeon: ^22.4.1
slang_build_runner: ^3.31.0
test: ^1.25.7
very_good_analysis: ^6.0.0
dependency_overrides:
# NOTE: Leave here for development purposes
@ -127,14 +127,19 @@ dependency_overrides:
# moxxmpp_socket_tcp:
# path: ../moxxmpp/packages/moxxmpp_socket_tcp
# omemo_dart:
# path: ../../Personal/omemo_dart
# path: ../omemo_dart
moxxmpp:
git:
url: https://codeberg.org/moxxy/moxxmpp.git
rev: 365ff2f23850b1808d3f6ea39c3789badf39ad7b
rev: db77790bf4caa6a35dd1b3121306050ff8d73681
path: packages/moxxmpp
omemo_dart:
git:
url: https://github.com/PapaTutuWawa/omemo_dart.git
rev: 124c997fa3f0792fa50ff66b80f43c3b71382f89
# NOTE: Leave here for development purposes
# moxxy_native:
# path: ../moxxy_native