Merge branch 'master' into MDLF-2.0.1
# Conflicts: # README.md # ios/Runner.xcodeproj/project.pbxproj # ios/Runner/Info.plist # linux/CMakeLists.txt
This commit is contained in:
commit
6950daca27
@ -1,3 +1,10 @@
|
|||||||
|
plugins {
|
||||||
|
id "com.android.application"
|
||||||
|
id "kotlin-android"
|
||||||
|
// The Flutter Gradle Plugin must be applied after the Android and Kotlin Gradle plugins.
|
||||||
|
id "dev.flutter.flutter-gradle-plugin"
|
||||||
|
}
|
||||||
|
|
||||||
def localProperties = new Properties()
|
def localProperties = new Properties()
|
||||||
def localPropertiesFile = rootProject.file('local.properties')
|
def localPropertiesFile = rootProject.file('local.properties')
|
||||||
if (localPropertiesFile.exists()) {
|
if (localPropertiesFile.exists()) {
|
||||||
@ -12,10 +19,10 @@ if (keystorePropertiesFile.exists()) {
|
|||||||
keystoreProperties.load(new FileInputStream(keystorePropertiesFile))
|
keystoreProperties.load(new FileInputStream(keystorePropertiesFile))
|
||||||
}
|
}
|
||||||
|
|
||||||
def flutterRoot = localProperties.getProperty('flutter.sdk')
|
/*def flutterRoot = localProperties.getProperty('flutter.sdk')
|
||||||
if (flutterRoot == null) {
|
if (flutterRoot == null) {
|
||||||
throw new GradleException("Flutter SDK not found. Define location with flutter.sdk in the local.properties file.")
|
throw new GradleException("Flutter SDK not found. Define location with flutter.sdk in the local.properties file.")
|
||||||
}
|
}*/
|
||||||
|
|
||||||
def flutterVersionCode = localProperties.getProperty('flutter.versionCode')
|
def flutterVersionCode = localProperties.getProperty('flutter.versionCode')
|
||||||
if (flutterVersionCode == null) {
|
if (flutterVersionCode == null) {
|
||||||
@ -27,9 +34,9 @@ if (flutterVersionName == null) {
|
|||||||
flutterVersionName = '1.0'
|
flutterVersionName = '1.0'
|
||||||
}
|
}
|
||||||
|
|
||||||
apply plugin: 'com.android.application'
|
/*apply plugin: 'com.android.application'
|
||||||
apply plugin: 'kotlin-android'
|
apply plugin: 'kotlin-android'
|
||||||
apply from: "$flutterRoot/packages/flutter_tools/gradle/flutter.gradle"
|
apply from: "$flutterRoot/packages/flutter_tools/gradle/flutter.gradle"*/
|
||||||
|
|
||||||
android {
|
android {
|
||||||
compileSdkVersion 34
|
compileSdkVersion 34
|
||||||
@ -49,7 +56,7 @@ android {
|
|||||||
|
|
||||||
defaultConfig {
|
defaultConfig {
|
||||||
// TODO: Specify your own unique Application ID (https://developer.android.com/studio/build/application-id.html).
|
// TODO: Specify your own unique Application ID (https://developer.android.com/studio/build/application-id.html).
|
||||||
applicationId "be.unov.myinfomate.mdlf" // Update for mdlf and other clients -- "be.unov.mymuseum.fortsaintheribert"
|
applicationId "be.unov.mymuseum.fortsaintheribert" // Update for mdlf and other clients -- "be.unov.mymuseum.fortsaintheribert" // be.unov.myinfomate.mdlf
|
||||||
minSdkVersion flutter.minSdkVersion
|
minSdkVersion flutter.minSdkVersion
|
||||||
targetSdkVersion flutter.targetSdkVersion
|
targetSdkVersion flutter.targetSdkVersion
|
||||||
versionCode flutterVersionCode.toInteger()
|
versionCode flutterVersionCode.toInteger()
|
||||||
@ -81,6 +88,6 @@ flutter {
|
|||||||
source '../..'
|
source '../..'
|
||||||
}
|
}
|
||||||
|
|
||||||
dependencies {
|
/*dependencies {
|
||||||
implementation "org.jetbrains.kotlin:kotlin-stdlib-jdk7:$kotlin_version"
|
implementation "org.jetbrains.kotlin:kotlin-stdlib-jdk7:$kotlin_version"
|
||||||
}
|
}*/
|
||||||
|
|||||||
@ -1,4 +1,4 @@
|
|||||||
buildscript {
|
/*buildscript {
|
||||||
ext.kotlin_version = '1.9.0'
|
ext.kotlin_version = '1.9.0'
|
||||||
repositories {
|
repositories {
|
||||||
google()
|
google()
|
||||||
@ -9,7 +9,7 @@ buildscript {
|
|||||||
classpath 'com.android.tools.build:gradle:7.2.0'
|
classpath 'com.android.tools.build:gradle:7.2.0'
|
||||||
classpath "org.jetbrains.kotlin:kotlin-gradle-plugin:$kotlin_version"
|
classpath "org.jetbrains.kotlin:kotlin-gradle-plugin:$kotlin_version"
|
||||||
}
|
}
|
||||||
}
|
}*/
|
||||||
|
|
||||||
allprojects {
|
allprojects {
|
||||||
repositories {
|
repositories {
|
||||||
|
|||||||
@ -1,4 +1,4 @@
|
|||||||
include ':app'
|
/*include ':app'
|
||||||
|
|
||||||
def localPropertiesFile = new File(rootProject.projectDir, "local.properties")
|
def localPropertiesFile = new File(rootProject.projectDir, "local.properties")
|
||||||
def properties = new Properties()
|
def properties = new Properties()
|
||||||
@ -9,3 +9,30 @@ localPropertiesFile.withReader("UTF-8") { reader -> properties.load(reader) }
|
|||||||
def flutterSdkPath = properties.getProperty("flutter.sdk")
|
def flutterSdkPath = properties.getProperty("flutter.sdk")
|
||||||
assert flutterSdkPath != null, "flutter.sdk not set in local.properties"
|
assert flutterSdkPath != null, "flutter.sdk not set in local.properties"
|
||||||
apply from: "$flutterSdkPath/packages/flutter_tools/gradle/app_plugin_loader.gradle"
|
apply from: "$flutterSdkPath/packages/flutter_tools/gradle/app_plugin_loader.gradle"
|
||||||
|
*/
|
||||||
|
|
||||||
|
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
|
||||||
|
}()
|
||||||
|
|
||||||
|
includeBuild("$flutterSdkPath/packages/flutter_tools/gradle")
|
||||||
|
|
||||||
|
repositories {
|
||||||
|
google()
|
||||||
|
mavenCentral()
|
||||||
|
gradlePluginPortal()
|
||||||
|
}
|
||||||
|
}
|
||||||
|
|
||||||
|
plugins {
|
||||||
|
id "dev.flutter.flutter-plugin-loader" version "1.0.0"
|
||||||
|
id "com.android.application" version "7.2.0" apply false
|
||||||
|
id "org.jetbrains.kotlin.android" version "1.9.0" apply false
|
||||||
|
}
|
||||||
|
|
||||||
|
include ":app"
|
||||||
@ -32,9 +32,9 @@ class _CustomAppBarState extends State<CustomAppBar> {
|
|||||||
|
|
||||||
String cleanedTitle = widget.title.replaceAll('\n', ' ').replaceAll('<br>', ' ');
|
String cleanedTitle = widget.title.replaceAll('\n', ' ').replaceAll('<br>', ' ');
|
||||||
|
|
||||||
String formattedTitle = cleanedTitle.length > 45
|
/*String formattedTitle = cleanedTitle.length > 45
|
||||||
? cleanedTitle.substring(0, 45) + '...'
|
? cleanedTitle.substring(0, 45) + '...'
|
||||||
: cleanedTitle;
|
: cleanedTitle;*/
|
||||||
|
|
||||||
//final notchInset = MediaQuery.of(context).padding;
|
//final notchInset = MediaQuery.of(context).padding;
|
||||||
return AppBar(
|
return AppBar(
|
||||||
@ -54,10 +54,10 @@ class _CustomAppBarState extends State<CustomAppBar> {
|
|||||||
},
|
},
|
||||||
child: SizedBox(
|
child: SizedBox(
|
||||||
width: widget.isHomeButton ? size.width * 0.8 : null,
|
width: widget.isHomeButton ? size.width * 0.8 : null,
|
||||||
height: 60,
|
height: 58,
|
||||||
child: Center(
|
child: Center(
|
||||||
child: HtmlWidget(
|
child: HtmlWidget(
|
||||||
formattedTitle,
|
cleanedTitle,
|
||||||
textStyle: const TextStyle(color: Colors.white, fontFamily: 'Roboto', fontSize: 20),
|
textStyle: const TextStyle(color: Colors.white, fontFamily: 'Roboto', fontSize: 20),
|
||||||
customStylesBuilder: (element)
|
customStylesBuilder: (element)
|
||||||
{
|
{
|
||||||
|
|||||||
@ -124,7 +124,8 @@ class _ScannerDialogState extends State<ScannerDialog> {
|
|||||||
borderRadius: 10,
|
borderRadius: 10,
|
||||||
borderLength: 25,
|
borderLength: 25,
|
||||||
borderWidth: 5,
|
borderWidth: 5,
|
||||||
cutOutSize: 225.0),
|
overlayColor: Colors.black.withValues(alpha: 0.55),
|
||||||
|
cutOutSize: 225.0),
|
||||||
onPermissionSet: (ctrl, p) => _onPermissionSet(context, ctrl, p),
|
onPermissionSet: (ctrl, p) => _onPermissionSet(context, ctrl, p),
|
||||||
);
|
);
|
||||||
}
|
}
|
||||||
|
|||||||
@ -66,6 +66,8 @@ class _AudioPlayerFloatingContainerState extends State<AudioPlayerFloatingContai
|
|||||||
|
|
||||||
currentpostlabel = "$minutesToShow:$secondsToShow";
|
currentpostlabel = "$minutesToShow:$secondsToShow";
|
||||||
|
|
||||||
|
}
|
||||||
|
if(mounted && player.duration != null) {
|
||||||
setState(() {
|
setState(() {
|
||||||
//refresh the UI
|
//refresh the UI
|
||||||
if(currentpos > player.duration!.inMilliseconds) {
|
if(currentpos > player.duration!.inMilliseconds) {
|
||||||
@ -80,8 +82,6 @@ class _AudioPlayerFloatingContainerState extends State<AudioPlayerFloatingContai
|
|||||||
}
|
}
|
||||||
});
|
});
|
||||||
|
|
||||||
|
|
||||||
|
|
||||||
/*player.onPositionChanged.listen((Duration p){
|
/*player.onPositionChanged.listen((Duration p){
|
||||||
currentpos = p.inMilliseconds; //get the current position of playing audio
|
currentpos = p.inMilliseconds; //get the current position of playing audio
|
||||||
|
|
||||||
@ -125,11 +125,11 @@ class _AudioPlayerFloatingContainerState extends State<AudioPlayerFloatingContai
|
|||||||
}
|
}
|
||||||
|
|
||||||
@override
|
@override
|
||||||
void dispose() {
|
void dispose() async {
|
||||||
if (player.playing) {
|
Future.microtask(() async {
|
||||||
player.stop();
|
await player.stop();
|
||||||
}
|
await player.dispose();
|
||||||
player.dispose();
|
});
|
||||||
super.dispose();
|
super.dispose();
|
||||||
}
|
}
|
||||||
|
|
||||||
|
|||||||
@ -350,11 +350,12 @@ class _ConfigurationsListState extends State<ConfigurationsList> {
|
|||||||
borderRadius: BorderRadius.all(Radius.circular(20.0))
|
borderRadius: BorderRadius.all(Radius.circular(20.0))
|
||||||
),
|
),
|
||||||
content: SizedBox(
|
content: SizedBox(
|
||||||
width: 400,
|
width: 350,
|
||||||
height: 200,
|
height: 125,
|
||||||
child: DownloadConfigurationWidget(configuration: configuration),
|
child: Center(
|
||||||
|
child: DownloadConfigurationWidget(configuration: configuration)
|
||||||
|
),
|
||||||
),
|
),
|
||||||
actions: const <Widget>[],
|
|
||||||
), context: context
|
), context: context
|
||||||
);
|
);
|
||||||
isDialogOpen = false;
|
isDialogOpen = false;
|
||||||
|
|||||||
@ -262,24 +262,23 @@ class _DownloadConfigurationWidgetState extends State<DownloadConfigurationWidge
|
|||||||
VisitAppContext visitAppContext = appContext.getContext();
|
VisitAppContext visitAppContext = appContext.getContext();
|
||||||
Size size = MediaQuery.of(context).size;
|
Size size = MediaQuery.of(context).size;
|
||||||
|
|
||||||
return Column(
|
return Center(
|
||||||
mainAxisAlignment: MainAxisAlignment.spaceBetween,
|
child: FutureBuilder(future: download(context, visitAppContext), builder: (context, snapshot) {
|
||||||
children: [
|
return ValueListenableBuilder<int>(
|
||||||
Spacer(),
|
valueListenable: currentResourceNbr,
|
||||||
Padding(
|
builder: (context, valueNbr, _) {
|
||||||
padding: const EdgeInsets.only(bottom: 10.0),
|
|
||||||
child: FutureBuilder(future: download(context, visitAppContext), builder: (context, snapshot) {
|
|
||||||
if (snapshot.connectionState == ConnectionState.waiting) {
|
|
||||||
Color primaryColor = kMainColor1;
|
|
||||||
return Center(child: CircularProgressIndicator(color: primaryColor));
|
|
||||||
} else {
|
|
||||||
return ValueListenableBuilder<int>(
|
return ValueListenableBuilder<int>(
|
||||||
valueListenable: currentResourceNbr,
|
valueListenable: currentResourceIndex,
|
||||||
builder: (context, valueNbr, _) {
|
builder: (context, valueIndex, _) {
|
||||||
return ValueListenableBuilder<int>(
|
var valueInPercentage = valueNbr > 0 ? (valueIndex / valueNbr) * 100 : 100;
|
||||||
valueListenable: currentResourceIndex,
|
String formattedPercentage = valueInPercentage.toStringAsFixed(0);
|
||||||
builder: (context, valueIndex, _) {
|
return Column(
|
||||||
return Center(
|
mainAxisAlignment: MainAxisAlignment.spaceAround,
|
||||||
|
crossAxisAlignment: CrossAxisAlignment.center,
|
||||||
|
children: [
|
||||||
|
Center(
|
||||||
|
child: Padding(
|
||||||
|
padding: const EdgeInsets.all(8.0),
|
||||||
child: Text(
|
child: Text(
|
||||||
textAlign: TextAlign.center,
|
textAlign: TextAlign.center,
|
||||||
valueIndex == valueNbr && valueNbr != -1 ? valueNbr == 0 ?
|
valueIndex == valueNbr && valueNbr != -1 ? valueNbr == 0 ?
|
||||||
@ -292,38 +291,39 @@ class _DownloadConfigurationWidgetState extends State<DownloadConfigurationWidge
|
|||||||
appContext.getContext()),
|
appContext.getContext()),
|
||||||
style: const TextStyle(fontSize: 20),
|
style: const TextStyle(fontSize: 20),
|
||||||
),
|
),
|
||||||
);
|
),
|
||||||
}
|
),
|
||||||
|
if(valueNbr != -1 && valueNbr != 0)
|
||||||
|
Center(
|
||||||
|
child: Column(
|
||||||
|
mainAxisAlignment: MainAxisAlignment.center,
|
||||||
|
mainAxisSize: MainAxisSize.min,
|
||||||
|
children: [
|
||||||
|
Padding(
|
||||||
|
padding: const EdgeInsets.all(8.0),
|
||||||
|
child: LinearProgressIndicator(
|
||||||
|
value: valueInPercentage / 100,
|
||||||
|
semanticsLabel: 'Linear progress indicator',
|
||||||
|
color: kMainColor0,
|
||||||
|
),
|
||||||
|
),
|
||||||
|
Padding(
|
||||||
|
padding: const EdgeInsets.all(8.0),
|
||||||
|
child: Text(
|
||||||
|
'$formattedPercentage%',
|
||||||
|
style: const TextStyle(fontSize: 28, fontWeight: FontWeight.w500),
|
||||||
|
),
|
||||||
|
),
|
||||||
|
],
|
||||||
|
),
|
||||||
|
)
|
||||||
|
],
|
||||||
);
|
);
|
||||||
}
|
}
|
||||||
);
|
);
|
||||||
}
|
}
|
||||||
}),
|
);
|
||||||
),
|
}),
|
||||||
ValueListenableBuilder<int>(
|
|
||||||
valueListenable: currentResourceNbr,
|
|
||||||
builder: (context, valueNbr, _) {
|
|
||||||
return ValueListenableBuilder<int>(
|
|
||||||
valueListenable: currentResourceIndex,
|
|
||||||
builder: (context, valueIndex, _) {
|
|
||||||
var valueInPercentage = valueNbr > 0 ? (valueIndex / valueNbr) * 100 : 100;
|
|
||||||
String formattedPercentage = valueInPercentage.toStringAsFixed(0); // Limite à 2 décimales
|
|
||||||
|
|
||||||
return valueNbr != -1 && valueNbr != 0 ? Center(
|
|
||||||
child: Padding(
|
|
||||||
padding: const EdgeInsets.only(bottom: 8.0),
|
|
||||||
child: Text(
|
|
||||||
'$formattedPercentage%',
|
|
||||||
style: const TextStyle(fontSize: 45, fontWeight: FontWeight.w500),
|
|
||||||
),
|
|
||||||
),
|
|
||||||
) : const SizedBox(height: 0,width: 0);
|
|
||||||
}
|
|
||||||
);
|
|
||||||
}
|
|
||||||
),
|
|
||||||
Spacer()
|
|
||||||
],
|
|
||||||
);
|
);
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
|
|||||||
BIN
release/fortSaintHeribert_2_0_2.aab
Normal file
BIN
release/fortSaintHeribert_2_0_2.aab
Normal file
Binary file not shown.
Loading…
x
Reference in New Issue
Block a user