introduce bottombar

This commit is contained in:
Flummi 2025-06-02 11:10:42 +02:00
parent 9c54010925
commit ee424c47c2

View File

@ -117,49 +117,58 @@ class _MediaGridState extends State<MediaGrid> {
foregroundColor: const Color.fromARGB(255, 255, 255, 255),
title: Row(
mainAxisAlignment: MainAxisAlignment.spaceBetween,
children: [
const Text('f0cks'),
DropdownButton<String>(
value: _selectedMode,
dropdownColor: const Color.fromARGB(255, 43, 43, 43),
iconEnabledColor: const Color.fromARGB(255, 255, 255, 255),
items: ["alles", "image", "video", "audio"].map((String value) {
return DropdownMenuItem<String>(
value: value,
child: Text(value, style: TextStyle(color: Colors.white)),
);
}).toList(),
onChanged: (String? newValue) {
if (newValue != null) {
setState(() {
_selectedMode = newValue;
_refreshMedia();
});
}
},
),
DropdownButton<int>(
value: _crossAxisCount,
dropdownColor: const Color.fromARGB(255, 43, 43, 43),
iconEnabledColor: const Color.fromARGB(255, 255, 255, 255),
items: [3, 4].map((int value) {
return DropdownMenuItem<int>(
value: value,
child: Text(
'$value Spalten',
style: TextStyle(color: Colors.white),
),
);
}).toList(),
onChanged: (int? newValue) {
if (newValue != null) {
setState(() {
_crossAxisCount = newValue;
});
}
},
),
],
children: [const Text('f0cks')],
),
),
bottomNavigationBar: BottomAppBar(
color: const Color.fromARGB(255, 43, 43, 43),
child: Padding(
padding: const EdgeInsets.symmetric(horizontal: 16.0),
child: Row(
mainAxisAlignment: MainAxisAlignment.spaceBetween,
children: [
DropdownButton<String>(
value: _selectedMode,
dropdownColor: const Color.fromARGB(255, 43, 43, 43),
iconEnabledColor: Colors.white,
items: ["alles", "image", "video", "audio"].map((String value) {
return DropdownMenuItem<String>(
value: value,
child: Text(value, style: TextStyle(color: Colors.white)),
);
}).toList(),
onChanged: (String? newValue) {
if (newValue != null) {
setState(() {
_selectedMode = newValue;
_refreshMedia();
});
}
},
),
DropdownButton<int>(
value: _crossAxisCount,
dropdownColor: const Color.fromARGB(255, 43, 43, 43),
iconEnabledColor: Colors.white,
items: [3, 4].map((int value) {
return DropdownMenuItem<int>(
value: value,
child: Text(
'$value Spalten',
style: TextStyle(color: Colors.white),
),
);
}).toList(),
onChanged: (int? newValue) {
if (newValue != null) {
setState(() {
_crossAxisCount = newValue;
});
}
},
),
],
),
),
),
body: RefreshIndicator(