finish flatpak stuff

pull/2/head
axtlos 3 years ago
parent fef7395144
commit 7de76f6740
No known key found for this signature in database
GPG Key ID: A468AFD71DD51D4A

@ -17,6 +17,7 @@ class InstallPrefs {
final String hostname; final String hostname;
final bool ipv6; final bool ipv6;
final bool enableTimeshift; final bool enableTimeshift;
final bool enableFlatpak;
final bool manualPartitioning; final bool manualPartitioning;
final List<String> partitions; final List<String> partitions;
@ -36,6 +37,7 @@ class InstallPrefs {
this.hostname = "", this.hostname = "",
this.ipv6 = false, this.ipv6 = false,
this.enableTimeshift = false, this.enableTimeshift = false,
this.enableFlatpak = false,
this.manualPartitioning = false, this.manualPartitioning = false,
this.partitions = const [], this.partitions = const [],
}); });
@ -72,6 +74,7 @@ class InstallPrefs {
"rootpass": rootPass, "rootpass": rootPass,
"desktop": desktop.name, "desktop": desktop.name,
"timeshift": enableTimeshift, "timeshift": enableTimeshift,
"flatpak": enableFlatpak,
"extra_packages": [ "extra_packages": [
"firefox", "firefox",
] ]

@ -33,6 +33,7 @@ Widget install(
String hostname, String hostname,
bool ipv6, bool ipv6,
bool enableTimeshift, bool enableTimeshift,
bool enableFlatpak,
setOutput, setOutput,
output, output,
running, running,
@ -67,6 +68,7 @@ Widget install(
hostname: hostname, hostname: hostname,
ipv6: ipv6, ipv6: ipv6,
enableTimeshift: enableTimeshift, enableTimeshift: enableTimeshift,
enableFlatpak: enableFlatpak,
); );
String jsonPrefs = jsonEncode(prefs.toJson()); String jsonPrefs = jsonEncode(prefs.toJson());
//writeConfig(jsonPrefs); //writeConfig(jsonPrefs);
@ -94,14 +96,6 @@ Widget install(
borderRadius: BorderRadius.circular(10), borderRadius: BorderRadius.circular(10),
border: Border.all(color: Colors.black), border: Border.all(color: Colors.black),
color: const Color.fromARGB(255, 15, 15, 15), color: const Color.fromARGB(255, 15, 15, 15),
//color: Colors.black,
/*boxShadow: const [
BoxShadow(
color: Colors.black,
blurRadius: 2,
offset: Offset(-2, 3),
),
]*/
), ),
child: SingleChildScrollView( child: SingleChildScrollView(
reverse: true, reverse: true,

@ -1,4 +1,5 @@
import 'package:flutter/material.dart'; import 'package:flutter/material.dart';
import 'package:adwaita_icons/adwaita_icons.dart';
final _formKey = GlobalKey<FormState>(); final _formKey = GlobalKey<FormState>();
RegExp hostnameRegex = RegExp( RegExp hostnameRegex = RegExp(
@ -16,7 +17,10 @@ Widget misc(
setConfirmRootPass, setConfirmRootPass,
rootPass, rootPass,
confirmRootPass, confirmRootPass,
enableFlatpak,
setFlatpak,
next) { next) {
bool flatpak = true;
return Column( return Column(
mainAxisAlignment: MainAxisAlignment.spaceBetween, mainAxisAlignment: MainAxisAlignment.spaceBetween,
children: [ children: [
@ -259,15 +263,20 @@ Widget misc(
child: CheckboxListTile( child: CheckboxListTile(
title: const Text('Enable flatpak', title: const Text('Enable flatpak',
style: TextStyle(color: Colors.white)), style: TextStyle(color: Colors.white)),
value: flatpak, value: enableFlatpak,
onChanged: () {}, onChanged: (bool? value) {
setFlatpak(value!);
},
secondary: Container( secondary: Container(
decoration: const BlxDecoration( decoration: const BoxDecoration(
shape: BoxShape.circle, shape: BoxShape.circle,
color: Colors.white, color: Colors.white,
), ),
padding: const EdgeInsets.fromLTRB(10, 10, 10, 13), padding: const EdgeInsets.fromLTRB(10, 10, 10, 13),
child: const Icon(Icons.box, color: Colors.black), child: const AdwaitaIcon(
AdwaitaIcons.package_x_generic,
color: Colors.black,
),
), ),
), ),
), ),

@ -56,6 +56,7 @@ Widget summary(
String hostname, String hostname,
bool ipv6, bool ipv6,
bool enableTimeshift, bool enableTimeshift,
bool enableFlatpak,
String rotational, String rotational,
String diskSize, String diskSize,
setDiskType, setDiskType,
@ -293,6 +294,9 @@ Widget summary(
const SizedBox(height: 10), const SizedBox(height: 10),
infoTextTemplate( infoTextTemplate(
"Enable timeshift", enableTimeshift.toString()), "Enable timeshift", enableTimeshift.toString()),
const SizedBox(height: 10),
infoTextTemplate(
"Install flatpak,", enableFlatpak.toString()),
], ],
), ),
), ),

@ -12,7 +12,6 @@ import 'package:jade_gui/locales/europe.dart';
import 'package:jade_gui/locales/indian.dart'; import 'package:jade_gui/locales/indian.dart';
import 'package:jade_gui/locales/mexico.dart'; import 'package:jade_gui/locales/mexico.dart';
import 'package:jade_gui/locales/pacific.dart'; import 'package:jade_gui/locales/pacific.dart';
import 'package:jade_gui/locales/us.dart';
import 'package:jade_gui/classes/location.dart'; import 'package:jade_gui/classes/location.dart';
class Local { class Local {
@ -37,5 +36,4 @@ List<Local> locations = [
Local(indian, "Indian"), Local(indian, "Indian"),
Local(mexico, "Mexico"), Local(mexico, "Mexico"),
Local(pacific, "Pacific"), Local(pacific, "Pacific"),
Local(us, "US"),
]; ];

@ -120,6 +120,7 @@ class _JadeguiState extends State<Jadegui> {
bool isEfi = false; bool isEfi = false;
bool ipv6 = false; bool ipv6 = false;
bool enableTimeshift = true; bool enableTimeshift = true;
bool enableFlatpak = true;
bool connected = false; bool connected = false;
bool manualPartitioning = false; bool manualPartitioning = false;
bool running = false; bool running = false;
@ -571,6 +572,13 @@ class _JadeguiState extends State<Jadegui> {
_selectedIndex = _selectedIndex + 1; _selectedIndex = _selectedIndex + 1;
}); });
}, },
enableFlatpak,
(value) {
setState(() {
enableFlatpak = value;
writeToLog("Enable flatpak: $enableFlatpak");
});
},
), ),
), ),
), ),
@ -700,6 +708,7 @@ class _JadeguiState extends State<Jadegui> {
hostname, hostname,
ipv6, ipv6,
enableTimeshift, enableTimeshift,
enableFlatpak,
_diskType, _diskType,
diskInfo, diskInfo,
(value) { (value) {
@ -747,6 +756,7 @@ class _JadeguiState extends State<Jadegui> {
hostname, hostname,
ipv6, ipv6,
enableTimeshift, enableTimeshift,
enableFlatpak,
(value) { (value) {
setState(() { setState(() {
if (value.compareTo(output) == 1) { if (value.compareTo(output) == 1) {

@ -1,6 +1,13 @@
# Generated by pub # Generated by pub
# See https://dart.dev/tools/pub/glossary#lockfile # See https://dart.dev/tools/pub/glossary#lockfile
packages: packages:
adwaita_icons:
dependency: "direct main"
description:
name: adwaita_icons
url: "https://pub.dartlang.org"
source: hosted
version: "0.2.1"
args: args:
dependency: transitive dependency: transitive
description: description:
@ -90,6 +97,13 @@ packages:
url: "https://pub.dartlang.org" url: "https://pub.dartlang.org"
source: hosted source: hosted
version: "1.0.4" version: "1.0.4"
flutter_svg:
dependency: transitive
description:
name: flutter_svg
url: "https://pub.dartlang.org"
source: hosted
version: "1.0.3"
flutter_test: flutter_test:
dependency: "direct dev" dependency: "direct dev"
description: flutter description: flutter
@ -130,6 +144,20 @@ packages:
url: "https://pub.dartlang.org" url: "https://pub.dartlang.org"
source: hosted source: hosted
version: "1.8.0" version: "1.8.0"
path_drawing:
dependency: transitive
description:
name: path_drawing
url: "https://pub.dartlang.org"
source: hosted
version: "1.0.0"
path_parsing:
dependency: transitive
description:
name: path_parsing
url: "https://pub.dartlang.org"
source: hosted
version: "1.0.0"
path_provider: path_provider:
dependency: "direct main" dependency: "direct main"
description: description:
@ -179,6 +207,13 @@ packages:
url: "https://pub.dartlang.org" url: "https://pub.dartlang.org"
source: hosted source: hosted
version: "2.0.5" version: "2.0.5"
petitparser:
dependency: transitive
description:
name: petitparser
url: "https://pub.dartlang.org"
source: hosted
version: "4.4.0"
platform: platform:
dependency: transitive dependency: transitive
description: description:
@ -305,6 +340,13 @@ packages:
url: "https://pub.dartlang.org" url: "https://pub.dartlang.org"
source: hosted source: hosted
version: "0.2.0+1" version: "0.2.0+1"
xml:
dependency: transitive
description:
name: xml
url: "https://pub.dartlang.org"
source: hosted
version: "5.3.1"
yaml: yaml:
dependency: transitive dependency: transitive
description: description:

@ -41,6 +41,7 @@ dependencies:
url: https://github.com/google/flutter-desktop-embedding.git url: https://github.com/google/flutter-desktop-embedding.git
path: plugins/window_size path: plugins/window_size
ref: a738913c8ce2c9f47515382d40827e794a334274 ref: a738913c8ce2c9f47515382d40827e794a334274
adwaita_icons: ^0.2.1
dev_dependencies: dev_dependencies:

Loading…
Cancel
Save