Skip to content

Commit

Permalink
Minor UI changes
Browse files Browse the repository at this point in the history
  • Loading branch information
AminBhst committed Jan 27, 2024
1 parent 76a9332 commit bd6d38a
Show file tree
Hide file tree
Showing 9 changed files with 30 additions and 16 deletions.
1 change: 0 additions & 1 deletion lib/downloader/multi_connection_download_coordinator.dart
Original file line number Diff line number Diff line change
Expand Up @@ -21,7 +21,6 @@ import '../util/readability_util.dart';
/// The coordinator will track the state of the download connections, retrieve and aggregate data such as the overall download speed and progress,
/// manage the availability of pause/resume buttons and assemble the file when the all connections have finished receiving and writing their data.
class MultiConnectionDownloadCoordinator {

/// TODO : send pause command to isolates which are pending connection
/// A map of all stream channels related to the running download requests
Expand Down
11 changes: 7 additions & 4 deletions lib/widget/base/checkbox_confirmation_dialog.dart
Original file line number Diff line number Diff line change
Expand Up @@ -26,12 +26,15 @@ class _CheckedBoxedConfirmationDialogState
Widget build(BuildContext context) {
return AlertDialog(
content: Container(
height: 75,
height: 100,
child: Column(
children: [
Text(
widget.title,
style: const TextStyle(color: Colors.white),
Padding(
padding: EdgeInsets.only(top: 10),
child: Text(
widget.title,
style: const TextStyle(fontSize: 17),
),
),
const SizedBox(height: 20),
Row(
Expand Down
2 changes: 2 additions & 0 deletions lib/widget/download/add_url_dialog.dart
Original file line number Diff line number Diff line change
Expand Up @@ -61,12 +61,14 @@ class _AddUrlDialogState extends State<AddUrlDialog> {
actions: <Widget>[
RoundedOutlinedButton(
text: "Cancel",
width: 95,
borderColor: Colors.red,
textColor: Colors.red,
onPressed: () => _onCancelPressed(context),
),
RoundedOutlinedButton(
text: widget.updateDialog ? "Update" : "Add",
width: 95,
borderColor: Colors.green,
textColor: Colors.green,
onPressed: () => _onAddPressed(context),
Expand Down
4 changes: 4 additions & 0 deletions lib/widget/queue/add_to_queue_window.dart
Original file line number Diff line number Diff line change
Expand Up @@ -26,6 +26,8 @@ class _AddToQueueWindowState extends State<AddToQueueWindow> {
disableCloseButton: true,
padding: EdgeInsets.only(top: 50),
content: Column(
mainAxisAlignment: MainAxisAlignment.center,
crossAxisAlignment: CrossAxisAlignment.center,
children: [
Row(
mainAxisAlignment: MainAxisAlignment.center,
Expand Down Expand Up @@ -61,13 +63,15 @@ class _AddToQueueWindowState extends State<AddToQueueWindow> {
borderColor: Colors.red,
textColor: Colors.red,
text: "Cancel",
width: 95,
),
const SizedBox(width: 10),
RoundedOutlinedButton(
onPressed: onAddPressed,
borderColor: Colors.green,
textColor: Colors.green,
text: "Add",
width: 95,
),
],
)
Expand Down
6 changes: 3 additions & 3 deletions lib/widget/queue/create_queue_window.dart
Original file line number Diff line number Diff line change
Expand Up @@ -30,7 +30,7 @@ class _CreateQueueWindowState extends State<CreateQueueWindow> {
mainAxisAlignment: MainAxisAlignment.center,
crossAxisAlignment: CrossAxisAlignment.center,
children: [
Text("Queue name : ", style: TextStyle(color: Colors.white)),
Text("Queue name : "),
const SizedBox(width: 10),
SizedBox(
width: 150,
Expand All @@ -51,15 +51,15 @@ class _CreateQueueWindowState extends State<CreateQueueWindow> {
crossAxisAlignment: CrossAxisAlignment.center,
children: [
RoundedOutlinedButton(
width: 80,
width: 95,
onPressed: () => Navigator.of(context).pop(),
borderColor: Colors.red,
textColor: Colors.red,
text: "Cancel",
),
const SizedBox(width: 10),
RoundedOutlinedButton(
width: 80,
width: 95,
onPressed: () => onCreatePressed(context),
borderColor: Colors.green,
textColor: Colors.green,
Expand Down
6 changes: 3 additions & 3 deletions lib/widget/queue/start_queue_window.dart
Original file line number Diff line number Diff line change
Expand Up @@ -30,7 +30,7 @@ class _StartQueueWindowState extends State<StartQueueWindow> {
crossAxisAlignment: CrossAxisAlignment.center,
children: [
Text("Number of simultaneous downloads : ",
style: TextStyle(color: Colors.white)),
style: TextStyle(fontSize: 16)),
const SizedBox(width: 10),
SizedBox(
width: 90,
Expand All @@ -52,15 +52,15 @@ class _StartQueueWindowState extends State<StartQueueWindow> {
crossAxisAlignment: CrossAxisAlignment.center,
children: [
RoundedOutlinedButton(
width: 80,
width: 95,
onPressed: () => Navigator.of(context).pop(),
borderColor: Colors.red,
textColor: Colors.red,
text: "Cancel",
),
const SizedBox(width: 20),
RoundedOutlinedButton(
width: 80,
width: 95,
onPressed: () {
widget.onStartPressed(int.parse(txtController.text));
Navigator.of(context).pop();
Expand Down
12 changes: 8 additions & 4 deletions lib/widget/setting/base/settings_group.dart
Original file line number Diff line number Diff line change
Expand Up @@ -20,9 +20,7 @@ class SettingsGroup extends StatelessWidget {

@override
Widget build(BuildContext context) {
final size = MediaQuery
.of(context)
.size;
final size = MediaQuery.of(context).size;
return SizedBox(
height: height,
width: size.width * 0.6 * 0.68,
Expand All @@ -33,7 +31,13 @@ class SettingsGroup extends StatelessWidget {
children: [
Padding(
padding: const EdgeInsets.all(10.0),
child: Text(title, style: const TextStyle(color: Colors.white, fontSize: 18)),
child: Text(
title,
style: const TextStyle(
fontSize: 16,
fontWeight: FontWeight.bold,
),
),
),
Container(
width: containerWidth,
Expand Down
2 changes: 2 additions & 0 deletions lib/widget/top_menu/download_queue_top_menu.dart
Original file line number Diff line number Diff line change
Expand Up @@ -45,13 +45,15 @@ class DownloadQueueTopMenu extends StatelessWidget {
child: TopMenuButton(
onTap: () => onStartQueuePressed(context),
title: 'Start Queue',
fontSize: 12,
icon: const Icon(Icons.play_arrow_rounded, color: Colors.white),
onHoverColor: Colors.green,
),
),
TopMenuButton(
onTap: onStopAllPressed,
title: 'Stop Queue',
fontSize: 12,
icon: const Icon(Icons.stop_circle_rounded, color: Colors.white),
onHoverColor: Colors.redAccent,
),
Expand Down
2 changes: 1 addition & 1 deletion lib/widget/top_menu/top_menu_button.dart
Original file line number Diff line number Diff line change
Expand Up @@ -37,7 +37,7 @@ class TopMenuButton extends StatelessWidget {
padding: const EdgeInsets.all(5),
child: Text(
title,
style: TextStyle(color: Colors.white, fontSize: fontSize),
style: TextStyle(fontSize: fontSize),
textAlign: TextAlign.center,
),
),
Expand Down

0 comments on commit bd6d38a

Please sign in to comment.