-
Notifications
You must be signed in to change notification settings - Fork 3
Commit
This commit does not belong to any branch on this repository, and may belong to a fork outside of the repository.
- Loading branch information
1 parent
eadedba
commit 55eb5e1
Showing
8 changed files
with
1,090 additions
and
0 deletions.
There are no files selected for viewing
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,168 @@ | ||
import 'package:fluent_ui/fluent_ui.dart'; | ||
|
||
import 'package:bitsdojo_window/bitsdojo_window.dart'; | ||
import 'package:flutter/material.dart' as material; | ||
import 'package:url_launcher/url_launcher.dart'; | ||
|
||
class About extends StatefulWidget { | ||
const About({Key? key}) : super(key: key); | ||
|
||
@override | ||
State<About> createState() => _AboutState(); | ||
} | ||
|
||
class _AboutState extends State<About> { | ||
final _url = 'mailto:[email protected]?'; | ||
@override | ||
Widget build(BuildContext context) { | ||
// var width = MediaQuery.of(context).size.width; | ||
return Column( | ||
children: [ | ||
WindowTitleBarBox( | ||
child: Row( | ||
children: [ | ||
Expanded( | ||
child: MoveWindow(), | ||
), | ||
const WindowButtons() | ||
], | ||
), | ||
), | ||
Padding( | ||
padding: const EdgeInsets.only(top: 100), | ||
child: Column( | ||
mainAxisAlignment: MainAxisAlignment.center, | ||
children: <Widget>[ | ||
Image.asset( | ||
'images/me.png', | ||
height: 100, | ||
width: 100, | ||
), | ||
Text( | ||
'Safius Sifat', | ||
style: TextStyle( | ||
fontFamily: 'Pacifico', | ||
fontSize: 40.0, | ||
color: Colors.purple, | ||
fontWeight: FontWeight.bold, | ||
), | ||
), | ||
Text( | ||
'FLUTTER DEVELOPER', | ||
style: TextStyle( | ||
fontFamily: 'Source Sans Pro', | ||
color: material.Colors.purple.shade100, | ||
fontSize: 20.0, | ||
letterSpacing: 2.5, | ||
fontWeight: FontWeight.bold, | ||
), | ||
), | ||
SizedBox( | ||
height: 20.0, | ||
width: 150.0, | ||
child: material.Divider( | ||
color: material.Colors.purple.shade100, | ||
), | ||
), | ||
Container( | ||
width: 500, | ||
child: material.Card( | ||
color: Colors.purple, | ||
margin: const EdgeInsets.symmetric( | ||
vertical: 10.0, horizontal: 25.0), | ||
child: material.Material( | ||
child: material.Ink( | ||
color: Colors.purple, | ||
child: material.InkWell( | ||
onTap: () async { | ||
if (!await launch( | ||
'https://github.com/Safius-Sifat')) { | ||
throw 'Could not launch https://github.com/Safius-Sifat'; | ||
} | ||
}, | ||
child: ListTile( | ||
shape: RoundedRectangleBorder( | ||
borderRadius: BorderRadius.circular(15.0), | ||
), | ||
leading: Image.asset('images/github.png'), | ||
title: const Text( | ||
'Safius-Sifat', | ||
style: TextStyle( | ||
color: material.Colors.white, | ||
fontFamily: 'Source Sans Pro', | ||
fontSize: 20.0, | ||
), | ||
), | ||
), | ||
), | ||
), | ||
)), | ||
), | ||
Container( | ||
width: 500, | ||
child: material.Card( | ||
color: Colors.purple, | ||
margin: const EdgeInsets.symmetric( | ||
vertical: 10.0, horizontal: 25.0), | ||
child: material.Material( | ||
child: material.Ink( | ||
color: Colors.purple, | ||
child: material.InkWell( | ||
onTap: () async { | ||
if (!await launch(_url)) { | ||
throw 'Could not launch $_url'; | ||
} | ||
}, | ||
child: const ListTile( | ||
leading: Icon( | ||
material.Icons.email, | ||
color: Colors.white, | ||
), | ||
title: Text( | ||
'[email protected]', | ||
style: TextStyle( | ||
fontSize: 20.0, | ||
color: material.Colors.white, | ||
fontFamily: 'Source Sans Pro'), | ||
), | ||
), | ||
), | ||
), | ||
), | ||
), | ||
), | ||
], | ||
), | ||
), | ||
], | ||
); | ||
} | ||
} | ||
|
||
final buttonColors = WindowButtonColors( | ||
iconNormal: const Color.fromARGB(255, 17, 13, 7), | ||
mouseOver: const Color.fromARGB(255, 204, 203, 202), | ||
mouseDown: const Color.fromARGB(255, 136, 136, 136), | ||
iconMouseOver: const Color.fromARGB(255, 0, 0, 0), | ||
iconMouseDown: const Color.fromARGB(255, 0, 0, 0), | ||
); | ||
|
||
final closeButtonColors = WindowButtonColors( | ||
mouseOver: const Color(0xFFD32F2F), | ||
mouseDown: const Color(0xFFB71C1C), | ||
iconNormal: const Color.fromARGB(255, 0, 0, 0), | ||
iconMouseOver: Colors.white); | ||
|
||
class WindowButtons extends StatelessWidget { | ||
const WindowButtons({Key? key}) : super(key: key); | ||
@override | ||
Widget build(BuildContext context) { | ||
return Row( | ||
children: [ | ||
MinimizeWindowButton(colors: buttonColors), | ||
MaximizeWindowButton(colors: buttonColors), | ||
CloseWindowButton(colors: closeButtonColors), | ||
], | ||
); | ||
} | ||
} |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,108 @@ | ||
import 'package:bdix/Utilities/ping_send.dart'; | ||
import 'package:fluent_ui/fluent_ui.dart'; | ||
import 'package:flutter/material.dart' as material; | ||
import 'package:get/get.dart'; | ||
import 'package:bitsdojo_window/bitsdojo_window.dart'; | ||
import 'package:url_launcher/url_launcher.dart'; | ||
|
||
class Favourites extends StatefulWidget { | ||
const Favourites({Key? key}) : super(key: key); | ||
|
||
@override | ||
State<Favourites> createState() => _FavouritesState(); | ||
} | ||
|
||
class _FavouritesState extends State<Favourites> { | ||
NetworkHelper networkHelper = Get.find(); | ||
int index = 0; | ||
List<String> newSaved = []; | ||
@override | ||
void initState() { | ||
super.initState(); | ||
networkHelper.useTheList(); | ||
} | ||
|
||
@override | ||
Widget build(BuildContext context) { | ||
List<String> newSaved = networkHelper.saved.toList(); | ||
return Column( | ||
mainAxisAlignment: MainAxisAlignment.start, | ||
crossAxisAlignment: CrossAxisAlignment.center, | ||
children: [ | ||
WindowTitleBarBox( | ||
child: Row( | ||
children: [ | ||
Expanded( | ||
child: MoveWindow(), | ||
), | ||
const WindowButtons() | ||
], | ||
), | ||
), | ||
Text( | ||
'Favourites', | ||
style: TextStyle( | ||
fontFamily: 'Horizon', | ||
color: material.Colors.purple.shade500, | ||
fontSize: 50, | ||
), | ||
), | ||
Expanded( | ||
child: ScaffoldPage( | ||
content: ListView.builder( | ||
itemCount: newSaved.length, | ||
itemBuilder: (BuildContext context, int index) { | ||
return material.Material( | ||
child: material.Ink( | ||
color: Colors.white, | ||
child: material.InkWell( | ||
onTap: () async { | ||
print(newSaved[index]); | ||
if (!await launch(newSaved[index])) { | ||
throw 'Could not launch url'; | ||
} | ||
}, | ||
child: ListTile( | ||
title: newSaved.isEmpty | ||
? const Text('No Favourites') | ||
: Text('${index + 1}. ${newSaved[index]}'), | ||
), | ||
), | ||
), | ||
); | ||
}, | ||
), | ||
), | ||
), | ||
], | ||
); | ||
} | ||
} | ||
|
||
final buttonColors = WindowButtonColors( | ||
iconNormal: const Color.fromARGB(255, 17, 13, 7), | ||
mouseOver: const Color.fromARGB(255, 204, 203, 202), | ||
mouseDown: const Color.fromARGB(255, 136, 136, 136), | ||
iconMouseOver: const Color.fromARGB(255, 0, 0, 0), | ||
iconMouseDown: const Color.fromARGB(255, 0, 0, 0), | ||
); | ||
|
||
final closeButtonColors = WindowButtonColors( | ||
mouseOver: const Color(0xFFD32F2F), | ||
mouseDown: const Color(0xFFB71C1C), | ||
iconNormal: const Color.fromARGB(255, 0, 0, 0), | ||
iconMouseOver: Colors.white); | ||
|
||
class WindowButtons extends StatelessWidget { | ||
const WindowButtons({Key? key}) : super(key: key); | ||
@override | ||
Widget build(BuildContext context) { | ||
return Row( | ||
children: [ | ||
MinimizeWindowButton(colors: buttonColors), | ||
MaximizeWindowButton(colors: buttonColors), | ||
CloseWindowButton(colors: closeButtonColors), | ||
], | ||
); | ||
} | ||
} |
Oops, something went wrong.