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
class MyClipper extends CustomClipper<Path> { | |
final double _borderRadius; | |
final double _angle; | |
MyClipper({ | |
double? borderRadius, | |
double? angle, | |
}) : _borderRadius = borderRadius ?? .1, | |
_angle = angle ?? degToRad(80); |
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
void main() { | |
var a = 'A'; | |
var b = 'B'; | |
var page1 = 'A'; | |
var page2 = 'B'; | |
var page1Impl = page1 == a; | |
var page2Impl = page2 == a; | |
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
import 'package:flutter/material.dart'; | |
void main(){ | |
runApp(const Alinhamento()); | |
} | |
class Alinhamento extends StatelessWidget { | |
const Alinhamento({Key? key}) : super(key: key); |
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
import 'package:flutter/material.dart'; | |
class OverlayImage extends StatelessWidget { | |
const OverlayImage({super.key}); | |
@override | |
Widget build(BuildContext context) { | |
return Material( | |
type: MaterialType.transparency, | |
child: SafeArea( |
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
import 'dart:io'; | |
import 'package:dialog/overlayimage/overlay.dart'; | |
import 'package:dialog/show_overlay_method.dart'; | |
import 'package:flutter/material.dart'; | |
import 'package:flutter_test/flutter_test.dart'; | |
import 'package:network_image_mock/network_image_mock.dart'; | |
void main() { | |
TestWidgetsFlutterBinding.ensureInitialized(); |
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
// error | |
══╡ EXCEPTION CAUGHT BY FLUTTER TEST FRAMEWORK ╞════════════════════════════════════════════════════ | |
The following assertion was thrown running a test: | |
Navigator operation requested with a context that does not include a Navigator. | |
The context used to push or pop routes from the Navigator must be that of a widget that is a | |
descendant of a Navigator widget. | |
// method | |
import 'package:dialog/overlayimage/overlay.dart'; |
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
import 'package:flutter/material.dart'; | |
void main() { | |
runApp(const MyApp()); | |
} | |
class MyApp extends StatelessWidget { | |
const MyApp({super.key}); | |
@override |
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
abstract class Model{} | |
abstract class DatabaseLocal<T extends Model> { | |
Future<T> getById(); | |
Future<T> create(T data); | |
Future<T> update(T data); | |
Future<T> delete(T data); | |
Future<T> createIndex(T data); |
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
class Sum { | |
num add(int a, int b) { | |
return a + b; | |
} | |
} | |
class Divide { | |
int divide(int a, int b) { | |
return a ~/ b; | |
} |
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
// Player | |
// Objetivo: Tocar musicas em mais de uma fonte (Spotify e Dezer) | |
// Construir as classes baseado no principio SOLID e CLEAN para esse player | |
// 1) search music by artist | |
// 2) search music by id | |
// 3) play music | |
// 4) pause music |