This file contains hidden or 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
import 'package:flutter/material.dart'; | |
import 'package:get/get.dart'; | |
class Controller extends GetxController with StateMixin<String> { | |
final String changeThis = 'Super Cool String'; | |
@override | |
Future<void> onInit() async { | |
await Future.delayed(2.seconds); //To see the loading | |
change(changeThis, status: RxStatus.success()); |
This file contains hidden or 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
import 'dart:async'; | |
import 'dart:math' as math; | |
import 'dart:ui'; | |
import 'package:flutter/cupertino.dart'; | |
import 'package:flutter/foundation.dart'; | |
import 'package:flutter/material.dart'; | |
import 'package:flutter/services.dart'; | |
import 'package:flutter_icons/flutter_icons.dart'; | |
import 'package:get/get.dart'; |
This file contains hidden or 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
import 'package:flutter/material.dart'; | |
import 'package:flutter/services.dart'; | |
void main() { | |
// Setting the screen orientation [landscape] | |
WidgetsFlutterBinding.ensureInitialized(); | |
SystemChrome.setPreferredOrientations( | |
[DeviceOrientation.landscapeLeft, DeviceOrientation.landscapeRight]) | |
.then((_) { | |
runApp(MyApp()); |
This file contains hidden or 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
import 'package:flutter/material.dart'; | |
import 'package:flutter/services.dart'; | |
void main() { | |
WidgetsFlutterBinding.ensureInitialized(); | |
SystemChrome.setPreferredOrientations( | |
[DeviceOrientation.landscapeLeft, DeviceOrientation.landscapeRight]) | |
.then((_) { | |
runApp(MyApp()); | |
}); |
This file contains hidden or 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
/// roipeker 2021 | |
/// sample video: | |
/// https://media.giphy.com/media/xC8rB3jR9nXDJDMwQM/source.mp4 | |
/// add graphx to your pubspec. | |
/// Add in ur code: | |
/// SceneBuilderWidget(builder: () => SceneController(front: SceneDialer()),), | |
import 'package:flutter/material.dart'; | |
import 'package:graphx/graphx.dart'; |
This file contains hidden or 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
import 'package:flutter/material.dart'; | |
class KeepAlivePage extends StatefulWidget { | |
const KeepAlivePage({ | |
Key key, | |
@required this.child, | |
}) : super(key: key); | |
final Widget child; |
This file contains hidden or 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
import 'package:flutter/material.dart'; | |
import 'package:get/get.dart'; | |
void main() { | |
runApp( | |
GetMaterialApp( | |
debugShowCheckedModeBanner: false, | |
initialRoute: '/', | |
themeMode: ThemeMode.system, | |
darkTheme: ThemeData.dark(), |
This file contains hidden or 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
import 'package:flutter/material.dart'; | |
void main() => runApp(MyApp()); | |
class MyApp extends StatelessWidget { | |
@override | |
Widget build(BuildContext context) { | |
return MaterialApp( | |
title: 'Material App', | |
home: Home(), |
This file contains hidden or 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
import 'dart:async'; | |
import 'dart:convert'; | |
import 'package:flutter/material.dart'; | |
import 'package:flutter/services.dart' show rootBundle; | |
class MyStatefulWidget extends StatefulWidget { | |
const MyStatefulWidget({Key? key}) : super(key: key); |
This file contains hidden or 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
import 'package:flutter/material.dart'; | |
import 'package:get/get.dart'; | |
void main() => runApp(MyApp()); | |
class MyApp extends StatelessWidget { | |
@override | |
Widget build(BuildContext context) { | |
return MaterialApp( | |
title: 'Material App', |
OlderNewer