Revert "chore: Upgrade to flutter 3.7.0 & Upgrade firebase dependencies"

pull/498/head
Hugo Walbecq 3 years ago committed by Hugo Walbecq
parent 226eabe115
commit 586c5d5fab

@ -4,9 +4,7 @@ import 'dart:developer';
import 'package:bloc/bloc.dart'; import 'package:bloc/bloc.dart';
import 'package:cloud_firestore/cloud_firestore.dart'; import 'package:cloud_firestore/cloud_firestore.dart';
import 'package:firebase_auth/firebase_auth.dart'; import 'package:firebase_auth/firebase_auth.dart';
import 'package:firebase_core/firebase_core.dart';
import 'package:flutter/widgets.dart'; import 'package:flutter/widgets.dart';
import 'package:pinball/firebase_options.dart';
class AppBlocObserver extends BlocObserver { class AppBlocObserver extends BlocObserver {
@override @override
@ -32,7 +30,6 @@ Future<void> bootstrap(BootstrapBuilder builder) async {
FlutterError.onError = (details) { FlutterError.onError = (details) {
log(details.exceptionAsString(), stackTrace: details.stack); log(details.exceptionAsString(), stackTrace: details.stack);
}; };
await Firebase.initializeApp(options: DefaultFirebaseOptions.currentPlatform);
await runZonedGuarded( await runZonedGuarded(
() async { () async {

@ -1,64 +0,0 @@
// File generated by FlutterFire CLI.
// ignore_for_file: lines_longer_than_80_chars, avoid_classes_with_only_static_members
import 'package:firebase_core/firebase_core.dart' show FirebaseOptions;
import 'package:flutter/foundation.dart'
show defaultTargetPlatform, kIsWeb, TargetPlatform;
/// Default [FirebaseOptions] for use with your Firebase apps.
///
/// Example:
/// ```dart
/// import 'firebase_options.dart';
/// // ...
/// await Firebase.initializeApp(
/// options: DefaultFirebaseOptions.currentPlatform,
/// );
/// ```
class DefaultFirebaseOptions {
static FirebaseOptions get currentPlatform {
if (kIsWeb) {
return web;
}
switch (defaultTargetPlatform) {
case TargetPlatform.android:
throw UnsupportedError(
'DefaultFirebaseOptions have not been configured for android - '
'you can reconfigure this by running the FlutterFire CLI again.',
);
case TargetPlatform.iOS:
throw UnsupportedError(
'DefaultFirebaseOptions have not been configured for ios - '
'you can reconfigure this by running the FlutterFire CLI again.',
);
case TargetPlatform.macOS:
throw UnsupportedError(
'DefaultFirebaseOptions have not been configured for macos - '
'you can reconfigure this by running the FlutterFire CLI again.',
);
case TargetPlatform.windows:
throw UnsupportedError(
'DefaultFirebaseOptions have not been configured for windows - '
'you can reconfigure this by running the FlutterFire CLI again.',
);
case TargetPlatform.linux:
throw UnsupportedError(
'DefaultFirebaseOptions have not been configured for linux - '
'you can reconfigure this by running the FlutterFire CLI again.',
);
case TargetPlatform.fuchsia:
throw UnsupportedError(
'DefaultFirebaseOptions are not supported for this platform.',
);
}
}
static const FirebaseOptions web = FirebaseOptions(
apiKey: 'AIzaSyBgMVAvYccjNypCDdpW0ol6syCcISU2yjM',
appId: '1:725488140557:web:7c61a0755fc23436fe7044',
messagingSenderId: '725488140557',
projectId: 'pinball-dev',
authDomain: 'pinball-dev.firebaseapp.com',
storageBucket: 'pinball-dev.appspot.com',
measurementId: 'G-9NW8SZRFJR',
);
}

@ -72,7 +72,7 @@ class LeaderboardDisplay extends PositionComponent with HasGameRef {
duration: 0.5, duration: 0.5,
curve: Curves.easeIn, curve: Curves.easeIn,
), ),
)..onComplete = () { )..onFinishCallback = () {
current.removeFromParent(); current.removeFromParent();
inactiveArrow.active = true; inactiveArrow.active = true;
firstChild<PositionComponent>()?.add( firstChild<PositionComponent>()?.add(

@ -213,7 +213,7 @@ class PinballGame extends PinballForge2DGame
} }
} }
class DebugPinballGame extends PinballGame with PanDetector { class DebugPinballGame extends PinballGame with FPSCounter, PanDetector {
DebugPinballGame({ DebugPinballGame({
required CharacterThemeCubit characterThemeBloc, required CharacterThemeCubit characterThemeBloc,
required LeaderboardRepository leaderboardRepository, required LeaderboardRepository leaderboardRepository,
@ -238,12 +238,7 @@ class DebugPinballGame extends PinballGame with PanDetector {
@override @override
Future<void> onLoad() async { Future<void> onLoad() async {
await super.onLoad(); await super.onLoad();
final fpsComponent = FpsComponent(); await addAll([PreviewLine(), _DebugInformation()]);
await addAll([
PreviewLine(),
fpsComponent,
_DebugInformation(fpsComponent: fpsComponent)
]);
} }
@override @override
@ -304,7 +299,6 @@ class PreviewLine extends PositionComponent with HasGameRef<DebugPinballGame> {
} }
class _DebugInformation extends Component with HasGameRef<DebugPinballGame> { class _DebugInformation extends Component with HasGameRef<DebugPinballGame> {
_DebugInformation({required this.fpsComponent});
@override @override
PositionType get positionType => PositionType.widget; PositionType get positionType => PositionType.widget;
@ -316,12 +310,11 @@ class _DebugInformation extends Component with HasGameRef<DebugPinballGame> {
); );
final _debugBackgroundPaint = Paint()..color = Colors.white; final _debugBackgroundPaint = Paint()..color = Colors.white;
final FpsComponent fpsComponent;
@override @override
void render(Canvas canvas) { void render(Canvas canvas) {
final debugText = [ final debugText = [
'FPS: ${fpsComponent.fps}', 'FPS: ${gameRef.fps().toStringAsFixed(1)}',
'BALLS: ${gameRef.descendants().whereType<Ball>().length}', 'BALLS: ${gameRef.descendants().whereType<Ball>().length}',
].join(' | '); ].join(' | ');

@ -7,7 +7,7 @@ environment:
sdk: ">=2.16.0 <3.0.0" sdk: ">=2.16.0 <3.0.0"
dependencies: dependencies:
firebase_auth: ^4.2.5 firebase_auth: ^3.3.16
flutter: flutter:
sdk: flutter sdk: flutter

@ -7,7 +7,7 @@ environment:
sdk: ">=2.16.0 <3.0.0" sdk: ">=2.16.0 <3.0.0"
dependencies: dependencies:
cloud_firestore: ^4.3.1 cloud_firestore: ^3.1.10
equatable: ^2.0.3 equatable: ^2.0.3
flutter: flutter:
sdk: flutter sdk: flutter

@ -1,5 +1,6 @@
import 'package:flame/components.dart'; import 'package:flame/components.dart';
import 'package:pinball_components/pinball_components.dart'; import 'package:pinball_components/pinball_components.dart';
import 'package:pinball_flame/pinball_flame.dart';
/// {@template ball_impulsing_behavior} /// {@template ball_impulsing_behavior}
/// Impulses the [Ball] in a given direction. /// Impulses the [Ball] in a given direction.
@ -16,5 +17,6 @@ class BallImpulsingBehavior extends Component with ParentIsA<Ball> {
Future<void> onLoad() async { Future<void> onLoad() async {
await super.onLoad(); await super.onLoad();
parent.body.linearVelocity = _impulse; parent.body.linearVelocity = _impulse;
shouldRemove = true;
} }
} }

@ -18,6 +18,7 @@ class GoogleWordAnimatingBehavior extends TimerComponent
} else { } else {
timer.stop(); timer.stop();
bloc.onReset(); bloc.onReset();
shouldRemove = true;
} }
} }
} }

@ -5,152 +5,133 @@ packages:
dependency: transitive dependency: transitive
description: description:
name: args name: args
sha256: "0bd9a99b6eb96f07af141f0eb53eace8983e8e5aa5de59777aca31684680ef22" url: "https://pub.dartlang.org"
url: "https://pub.dev"
source: hosted source: hosted
version: "2.3.0" version: "2.3.0"
async: async:
dependency: transitive dependency: transitive
description: description:
name: async name: async
sha256: bfe67ef28df125b7dddcea62755991f807aa39a2492a23e1550161692950bbe0 url: "https://pub.dartlang.org"
url: "https://pub.dev"
source: hosted source: hosted
version: "2.10.0" version: "2.8.2"
audioplayers: audioplayers:
dependency: transitive dependency: transitive
description: description:
name: audioplayers name: audioplayers
sha256: a565e7e3e8a21a823b8cd7fed0bde1eb3796a96b373374be557adecfb511fa6b url: "https://pub.dartlang.org"
url: "https://pub.dev"
source: hosted source: hosted
version: "0.20.1" version: "0.20.1"
bloc: bloc:
dependency: transitive dependency: transitive
description: description:
name: bloc name: bloc
sha256: "318e6cc6803d93b8d2de5f580e452ca565bcaa44f724d5156c71961426b88e03" url: "https://pub.dartlang.org"
url: "https://pub.dev"
source: hosted source: hosted
version: "8.0.3" version: "8.0.3"
boolean_selector: boolean_selector:
dependency: transitive dependency: transitive
description: description:
name: boolean_selector name: boolean_selector
sha256: "6cfb5af12253eaf2b368f07bacc5a80d1301a071c73360d746b7f2e32d762c66" url: "https://pub.dartlang.org"
url: "https://pub.dev"
source: hosted source: hosted
version: "2.1.1" version: "2.1.0"
characters: characters:
dependency: transitive dependency: transitive
description: description:
name: characters name: characters
sha256: e6a326c8af69605aec75ed6c187d06b349707a27fbff8222ca9cc2cff167975c url: "https://pub.dartlang.org"
url: "https://pub.dev"
source: hosted source: hosted
version: "1.2.1" version: "1.2.0"
charcode: charcode:
dependency: transitive dependency: transitive
description: description:
name: charcode name: charcode
sha256: fb98c0f6d12c920a02ee2d998da788bca066ca5f148492b7085ee23372b12306 url: "https://pub.dartlang.org"
url: "https://pub.dev"
source: hosted source: hosted
version: "1.3.1" version: "1.3.1"
clock: clock:
dependency: transitive dependency: transitive
description: description:
name: clock name: clock
sha256: cb6d7f03e1de671e34607e909a7213e31d7752be4fb66a86d29fe1eb14bfb5cf url: "https://pub.dartlang.org"
url: "https://pub.dev"
source: hosted source: hosted
version: "1.1.1" version: "1.1.0"
collection: collection:
dependency: transitive dependency: transitive
description: description:
name: collection name: collection
sha256: cfc915e6923fe5ce6e153b0723c753045de46de1b4d63771530504004a45fae0 url: "https://pub.dartlang.org"
url: "https://pub.dev"
source: hosted source: hosted
version: "1.17.0" version: "1.15.0"
crypto: crypto:
dependency: transitive dependency: transitive
description: description:
name: crypto name: crypto
sha256: aa274aa7774f8964e4f4f38cc994db7b6158dd36e9187aaceaddc994b35c6c67 url: "https://pub.dartlang.org"
url: "https://pub.dev"
source: hosted source: hosted
version: "3.0.2" version: "3.0.2"
dashbook: dashbook:
dependency: "direct main" dependency: "direct main"
description: description:
name: dashbook name: dashbook
sha256: a022d40095694c7345cac93ade887de3b0a8935cc45602dc533ec75568f4ef74 url: "https://pub.dartlang.org"
url: "https://pub.dev"
source: hosted source: hosted
version: "0.1.7" version: "0.1.7"
device_frame: device_frame:
dependency: transitive dependency: transitive
description: description:
name: device_frame name: device_frame
sha256: d5b4541a8755a36ac50b6605200e51db6d264438a38f327aec2ce31870e49885 url: "https://pub.dartlang.org"
url: "https://pub.dev"
source: hosted source: hosted
version: "1.0.0" version: "1.0.0"
equatable: equatable:
dependency: transitive dependency: transitive
description: description:
name: equatable name: equatable
sha256: c6094fd1efad3046334a9c40bee022147e55c25401ccd89b94e373e3edadd375 url: "https://pub.dartlang.org"
url: "https://pub.dev"
source: hosted source: hosted
version: "2.0.3" version: "2.0.3"
fake_async: fake_async:
dependency: transitive dependency: transitive
description: description:
name: fake_async name: fake_async
sha256: "511392330127add0b769b75a987850d136345d9227c6b94c96a04cf4a391bf78" url: "https://pub.dartlang.org"
url: "https://pub.dev"
source: hosted source: hosted
version: "1.3.1" version: "1.2.0"
ffi: ffi:
dependency: transitive dependency: transitive
description: description:
name: ffi name: ffi
sha256: "35d0f481d939de0d640b3db9a7aa36a52cd22054a798a73b4f50bdad5ce12678" url: "https://pub.dartlang.org"
url: "https://pub.dev"
source: hosted source: hosted
version: "1.1.2" version: "1.1.2"
file: file:
dependency: transitive dependency: transitive
description: description:
name: file name: file
sha256: b69516f2c26a5bcac4eee2e32512e1a5205ab312b3536c1c1227b2b942b5f9ad url: "https://pub.dartlang.org"
url: "https://pub.dev"
source: hosted source: hosted
version: "6.1.2" version: "6.1.2"
flame: flame:
dependency: "direct main" dependency: "direct main"
description: description:
name: flame name: flame
sha256: "400b10d146e0f6c88975087d7a52963937c8958789803161fad9ab39bfd16697" url: "https://pub.dartlang.org"
url: "https://pub.dev"
source: hosted source: hosted
version: "1.1.1" version: "1.1.1"
flame_audio: flame_audio:
dependency: transitive dependency: transitive
description: description:
name: flame_audio name: flame_audio
sha256: c512d6a046a90b82133242779cfe92612c7d1328a1480042c09b34bcbfaac555 url: "https://pub.dartlang.org"
url: "https://pub.dev"
source: hosted source: hosted
version: "1.0.2" version: "1.0.2"
flame_bloc: flame_bloc:
dependency: "direct main" dependency: "direct main"
description: description:
name: flame_bloc name: flame_bloc
sha256: "161896160315dfd92c9578fa4fe27728b6ac085655fb55a70d7ff229f16fb91c" url: "https://pub.dartlang.org"
url: "https://pub.dev"
source: hosted source: hosted
version: "1.4.0" version: "1.4.0"
flame_forge2d: flame_forge2d:
@ -171,24 +152,21 @@ packages:
dependency: transitive dependency: transitive
description: description:
name: flutter_bloc name: flutter_bloc
sha256: "7b84d9777db3e30a5051c6718331be57e4cfc0c2424be82ac1771392cad7dbe8" url: "https://pub.dartlang.org"
url: "https://pub.dev"
source: hosted source: hosted
version: "8.0.1" version: "8.0.1"
flutter_colorpicker: flutter_colorpicker:
dependency: transitive dependency: transitive
description: description:
name: flutter_colorpicker name: flutter_colorpicker
sha256: "458a6ed8ea480eb16ff892aedb4b7092b2804affd7e046591fb03127e8d8ef8b" url: "https://pub.dartlang.org"
url: "https://pub.dev"
source: hosted source: hosted
version: "1.0.3" version: "1.0.3"
flutter_markdown: flutter_markdown:
dependency: transitive dependency: transitive
description: description:
name: flutter_markdown name: flutter_markdown
sha256: "5a3ecbecfed294a464b952494daafc05cf97f6faf9441168f507e9c9400f50e0" url: "https://pub.dartlang.org"
url: "https://pub.dev"
source: hosted source: hosted
version: "0.6.9" version: "0.6.9"
flutter_test: flutter_test:
@ -205,16 +183,14 @@ packages:
dependency: transitive dependency: transitive
description: description:
name: forge2d name: forge2d
sha256: "82e6e89bd1224d87066e9b164d534c4977f4895f554f931608a182534fac6e5e" url: "https://pub.dartlang.org"
url: "https://pub.dev"
source: hosted source: hosted
version: "0.11.0" version: "0.11.0"
freezed_annotation: freezed_annotation:
dependency: transitive dependency: transitive
description: description:
name: freezed_annotation name: freezed_annotation
sha256: "1be037f901137bf2b9a0c309e9bf2694d6ec77687645211218191ade4f41a4b8" url: "https://pub.dartlang.org"
url: "https://pub.dev"
source: hosted source: hosted
version: "1.1.0" version: "1.1.0"
geometry: geometry:
@ -228,152 +204,133 @@ packages:
dependency: transitive dependency: transitive
description: description:
name: http name: http
sha256: "2ed163531e071c2c6b7c659635112f24cb64ecbebf6af46b550d536c0b1aa112" url: "https://pub.dartlang.org"
url: "https://pub.dev"
source: hosted source: hosted
version: "0.13.4" version: "0.13.4"
http_parser: http_parser:
dependency: transitive dependency: transitive
description: description:
name: http_parser name: http_parser
sha256: e362d639ba3bc07d5a71faebb98cde68c05bfbcfbbb444b60b6f60bb67719185 url: "https://pub.dartlang.org"
url: "https://pub.dev"
source: hosted source: hosted
version: "4.0.0" version: "4.0.0"
intl: intl:
dependency: transitive dependency: transitive
description: description:
name: intl name: intl
sha256: "910f85bce16fb5c6f614e117efa303e85a1731bb0081edf3604a2ae6e9a3cc91" url: "https://pub.dartlang.org"
url: "https://pub.dev"
source: hosted source: hosted
version: "0.17.0" version: "0.17.0"
js: js:
dependency: transitive dependency: transitive
description: description:
name: js name: js
sha256: "5528c2f391ededb7775ec1daa69e65a2d61276f7552de2b5f7b8d34ee9fd4ab7" url: "https://pub.dartlang.org"
url: "https://pub.dev"
source: hosted source: hosted
version: "0.6.5" version: "0.6.3"
json_annotation: json_annotation:
dependency: transitive dependency: transitive
description: description:
name: json_annotation name: json_annotation
sha256: "2639efc0237c7b71c6584696c0847ea4e4733ddaf571ae9c79d5295e8ae17272" url: "https://pub.dartlang.org"
url: "https://pub.dev"
source: hosted source: hosted
version: "4.4.0" version: "4.4.0"
markdown: markdown:
dependency: transitive dependency: transitive
description: description:
name: markdown name: markdown
sha256: "01512006c8429f604eb10f9848717baeaedf99e991d14a50d540d9beff08e5c6" url: "https://pub.dartlang.org"
url: "https://pub.dev"
source: hosted source: hosted
version: "4.0.1" version: "4.0.1"
matcher: matcher:
dependency: transitive dependency: transitive
description: description:
name: matcher name: matcher
sha256: "16db949ceee371e9b99d22f88fa3a73c4e59fd0afed0bd25fc336eb76c198b72" url: "https://pub.dartlang.org"
url: "https://pub.dev"
source: hosted source: hosted
version: "0.12.13" version: "0.12.11"
material_color_utilities: material_color_utilities:
dependency: transitive dependency: transitive
description: description:
name: material_color_utilities name: material_color_utilities
sha256: d92141dc6fe1dad30722f9aa826c7fbc896d021d792f80678280601aff8cf724 url: "https://pub.dartlang.org"
url: "https://pub.dev"
source: hosted source: hosted
version: "0.2.0" version: "0.1.3"
meta: meta:
dependency: transitive dependency: transitive
description: description:
name: meta name: meta
sha256: "6c268b42ed578a53088d834796959e4a1814b5e9e164f147f580a386e5decf42" url: "https://pub.dartlang.org"
url: "https://pub.dev"
source: hosted source: hosted
version: "1.8.0" version: "1.7.0"
nested: nested:
dependency: transitive dependency: transitive
description: description:
name: nested name: nested
sha256: "03bac4c528c64c95c722ec99280375a6f2fc708eec17c7b3f07253b626cd2a20" url: "https://pub.dartlang.org"
url: "https://pub.dev"
source: hosted source: hosted
version: "1.0.0" version: "1.0.0"
ordered_set: ordered_set:
dependency: transitive dependency: transitive
description: description:
name: ordered_set name: ordered_set
sha256: "74b0454418f58c34c8e527d91fb1ef571297dbcd5d3b4e5f983dc884e39cdf85" url: "https://pub.dartlang.org"
url: "https://pub.dev"
source: hosted source: hosted
version: "5.0.0" version: "5.0.0"
path: path:
dependency: transitive dependency: transitive
description: description:
name: path name: path
sha256: db9d4f58c908a4ba5953fcee2ae317c94889433e5024c27ce74a37f94267945b url: "https://pub.dartlang.org"
url: "https://pub.dev"
source: hosted source: hosted
version: "1.8.2" version: "1.8.0"
path_provider: path_provider:
dependency: transitive dependency: transitive
description: description:
name: path_provider name: path_provider
sha256: e92dee4d38a9044605cb3fb253e9b46eb9375dfcad4515d0379b44ac90797568 url: "https://pub.dartlang.org"
url: "https://pub.dev"
source: hosted source: hosted
version: "2.0.9" version: "2.0.9"
path_provider_android: path_provider_android:
dependency: transitive dependency: transitive
description: description:
name: path_provider_android name: path_provider_android
sha256: "32bbab16092df3bedab89ed9f2c1cfaedf25d96a5036f62f16d5e372890d068c" url: "https://pub.dartlang.org"
url: "https://pub.dev"
source: hosted source: hosted
version: "2.0.13" version: "2.0.13"
path_provider_ios: path_provider_ios:
dependency: transitive dependency: transitive
description: description:
name: path_provider_ios name: path_provider_ios
sha256: "943b76e54056386432cdc2731cb303e2f580346b61a1fc73819721767be72309" url: "https://pub.dartlang.org"
url: "https://pub.dev"
source: hosted source: hosted
version: "2.0.8" version: "2.0.8"
path_provider_linux: path_provider_linux:
dependency: transitive dependency: transitive
description: description:
name: path_provider_linux name: path_provider_linux
sha256: "1e109f4df28bd95eab71e323008b53d19c4d633bc1ab05b577518773474e9621" url: "https://pub.dartlang.org"
url: "https://pub.dev"
source: hosted source: hosted
version: "2.1.5" version: "2.1.5"
path_provider_macos: path_provider_macos:
dependency: transitive dependency: transitive
description: description:
name: path_provider_macos name: path_provider_macos
sha256: "0adeb313e1f2c3fc52baeeee59b0fe9c2d1f7da56fd96a9234e1702ec653a453" url: "https://pub.dartlang.org"
url: "https://pub.dev"
source: hosted source: hosted
version: "2.0.5" version: "2.0.5"
path_provider_platform_interface: path_provider_platform_interface:
dependency: transitive dependency: transitive
description: description:
name: path_provider_platform_interface name: path_provider_platform_interface
sha256: "3dc0d51b07f85fec3746d9f4e8d31c73bb173cafa2e763f03f8df2e8d1878882" url: "https://pub.dartlang.org"
url: "https://pub.dev"
source: hosted source: hosted
version: "2.0.3" version: "2.0.3"
path_provider_windows: path_provider_windows:
dependency: transitive dependency: transitive
description: description:
name: path_provider_windows name: path_provider_windows
sha256: "366ad4e3541ea707f859e7148d4d5aba67d589d7936cee04a05c464a277eeb27" url: "https://pub.dartlang.org"
url: "https://pub.dev"
source: hosted source: hosted
version: "2.0.5" version: "2.0.5"
pinball_audio: pinball_audio:
@ -415,96 +372,84 @@ packages:
dependency: transitive dependency: transitive
description: description:
name: platform name: platform
sha256: "4a451831508d7d6ca779f7ac6e212b4023dd5a7d08a27a63da33756410e32b76" url: "https://pub.dartlang.org"
url: "https://pub.dev"
source: hosted source: hosted
version: "3.1.0" version: "3.1.0"
plugin_platform_interface: plugin_platform_interface:
dependency: transitive dependency: transitive
description: description:
name: plugin_platform_interface name: plugin_platform_interface
sha256: "075f927ebbab4262ace8d0b283929ac5410c0ac4e7fc123c76429564facfb757" url: "https://pub.dartlang.org"
url: "https://pub.dev"
source: hosted source: hosted
version: "2.1.2" version: "2.1.2"
process: process:
dependency: transitive dependency: transitive
description: description:
name: process name: process
sha256: "53fd8db9cec1d37b0574e12f07520d582019cb6c44abf5479a01505099a34a09" url: "https://pub.dartlang.org"
url: "https://pub.dev"
source: hosted source: hosted
version: "4.2.4" version: "4.2.4"
provider: provider:
dependency: transitive dependency: transitive
description: description:
name: provider name: provider
sha256: "7896193cf752c40ba7f7732a95264319a787871e5d628225357f5c909182bc06" url: "https://pub.dartlang.org"
url: "https://pub.dev"
source: hosted source: hosted
version: "6.0.2" version: "6.0.2"
shared_preferences: shared_preferences:
dependency: transitive dependency: transitive
description: description:
name: shared_preferences name: shared_preferences
sha256: "1cd0c3c0be0826eb52362ab018a81eed13b616ad9a52548c6ceb1bb349e6b6eb" url: "https://pub.dartlang.org"
url: "https://pub.dev"
source: hosted source: hosted
version: "2.0.13" version: "2.0.13"
shared_preferences_android: shared_preferences_android:
dependency: transitive dependency: transitive
description: description:
name: shared_preferences_android name: shared_preferences_android
sha256: bc236594233d10b7668dd90414fe0e09d906115aaa1dfe269e478e5f2af532a6 url: "https://pub.dartlang.org"
url: "https://pub.dev"
source: hosted source: hosted
version: "2.0.11" version: "2.0.11"
shared_preferences_ios: shared_preferences_ios:
dependency: transitive dependency: transitive
description: description:
name: shared_preferences_ios name: shared_preferences_ios
sha256: "69d593a80fee48b97c66787eb930cdd42941c1537e80a1ff88a8c12a926c47d4" url: "https://pub.dartlang.org"
url: "https://pub.dev"
source: hosted source: hosted
version: "2.1.0" version: "2.1.0"
shared_preferences_linux: shared_preferences_linux:
dependency: transitive dependency: transitive
description: description:
name: shared_preferences_linux name: shared_preferences_linux
sha256: ac361c65c4cf342dfc0a8b9e45eab66b9b3ad6eaff9785850d4ec0cf6b474422 url: "https://pub.dartlang.org"
url: "https://pub.dev"
source: hosted source: hosted
version: "2.1.0" version: "2.1.0"
shared_preferences_macos: shared_preferences_macos:
dependency: transitive dependency: transitive
description: description:
name: shared_preferences_macos name: shared_preferences_macos
sha256: f063907c3f678de8daa033d234b7c9e420df5fe3d499a97bfb82cc30cf171496 url: "https://pub.dartlang.org"
url: "https://pub.dev"
source: hosted source: hosted
version: "2.0.3" version: "2.0.3"
shared_preferences_platform_interface: shared_preferences_platform_interface:
dependency: transitive dependency: transitive
description: description:
name: shared_preferences_platform_interface name: shared_preferences_platform_interface
sha256: "992f0fdc46d0a3c0ac2e5859f2de0e577bbe51f78a77ee8f357cbe626a2ad32d" url: "https://pub.dartlang.org"
url: "https://pub.dev"
source: hosted source: hosted
version: "2.0.0" version: "2.0.0"
shared_preferences_web: shared_preferences_web:
dependency: transitive dependency: transitive
description: description:
name: shared_preferences_web name: shared_preferences_web
sha256: "09da0185028a227d51721cade7a3cbd5cc5f163a19593266f2acba87f729bf9c" url: "https://pub.dartlang.org"
url: "https://pub.dev"
source: hosted source: hosted
version: "2.0.3" version: "2.0.3"
shared_preferences_windows: shared_preferences_windows:
dependency: transitive dependency: transitive
description: description:
name: shared_preferences_windows name: shared_preferences_windows
sha256: ae68cf0df0910e38c95522dbd8a6082ce9715053c369750c5709d17de81d032e url: "https://pub.dartlang.org"
url: "https://pub.dev"
source: hosted source: hosted
version: "2.1.0" version: "2.1.0"
sky_engine: sky_engine:
@ -516,170 +461,149 @@ packages:
dependency: transitive dependency: transitive
description: description:
name: source_span name: source_span
sha256: dd904f795d4b4f3b870833847c461801f6750a9fa8e61ea5ac53f9422b31f250 url: "https://pub.dartlang.org"
url: "https://pub.dev"
source: hosted source: hosted
version: "1.9.1" version: "1.8.1"
stack_trace: stack_trace:
dependency: transitive dependency: transitive
description: description:
name: stack_trace name: stack_trace
sha256: c3c7d8edb15bee7f0f74debd4b9c5f3c2ea86766fe4178eb2a18eb30a0bdaed5 url: "https://pub.dartlang.org"
url: "https://pub.dev"
source: hosted source: hosted
version: "1.11.0" version: "1.10.0"
stream_channel: stream_channel:
dependency: transitive dependency: transitive
description: description:
name: stream_channel name: stream_channel
sha256: "83615bee9045c1d322bbbd1ba209b7a749c2cbcdcb3fdd1df8eb488b3279c1c8" url: "https://pub.dartlang.org"
url: "https://pub.dev"
source: hosted source: hosted
version: "2.1.1" version: "2.1.0"
string_scanner: string_scanner:
dependency: transitive dependency: transitive
description: description:
name: string_scanner name: string_scanner
sha256: "556692adab6cfa87322a115640c11f13cb77b3f076ddcc5d6ae3c20242bedcde" url: "https://pub.dartlang.org"
url: "https://pub.dev"
source: hosted source: hosted
version: "1.2.0" version: "1.1.0"
synchronized: synchronized:
dependency: transitive dependency: transitive
description: description:
name: synchronized name: synchronized
sha256: a7f0790927c0806ae0d5eb061c713748fa6070ef0037e391a2d53c3844c09dc2 url: "https://pub.dartlang.org"
url: "https://pub.dev"
source: hosted source: hosted
version: "3.0.0+2" version: "3.0.0+2"
term_glyph: term_glyph:
dependency: transitive dependency: transitive
description: description:
name: term_glyph name: term_glyph
sha256: a29248a84fbb7c79282b40b8c72a1209db169a2e0542bce341da992fe1bc7e84 url: "https://pub.dartlang.org"
url: "https://pub.dev"
source: hosted source: hosted
version: "1.2.1" version: "1.2.0"
test_api: test_api:
dependency: transitive dependency: transitive
description: description:
name: test_api name: test_api
sha256: ad540f65f92caa91bf21dfc8ffb8c589d6e4dc0c2267818b4cc2792857706206 url: "https://pub.dartlang.org"
url: "https://pub.dev"
source: hosted source: hosted
version: "0.4.16" version: "0.4.8"
typed_data: typed_data:
dependency: transitive dependency: transitive
description: description:
name: typed_data name: typed_data
sha256: "53bdf7e979cfbf3e28987552fd72f637e63f3c8724c9e56d9246942dc2fa36ee" url: "https://pub.dartlang.org"
url: "https://pub.dev"
source: hosted source: hosted
version: "1.3.0" version: "1.3.0"
url_launcher: url_launcher:
dependency: transitive dependency: transitive
description: description:
name: url_launcher name: url_launcher
sha256: "2d9de5efddbd134ee68d73d0735e7477c00bcbf1ee91afa37514d6c876d38587" url: "https://pub.dartlang.org"
url: "https://pub.dev"
source: hosted source: hosted
version: "6.1.0" version: "6.1.0"
url_launcher_android: url_launcher_android:
dependency: transitive dependency: transitive
description: description:
name: url_launcher_android name: url_launcher_android
sha256: b693e6698f7e6985710d67a050e3acbdda3b9cfc4b43b9f1c40cdbe42c705b92 url: "https://pub.dartlang.org"
url: "https://pub.dev"
source: hosted source: hosted
version: "6.0.15" version: "6.0.15"
url_launcher_ios: url_launcher_ios:
dependency: transitive dependency: transitive
description: description:
name: url_launcher_ios name: url_launcher_ios
sha256: e51a93f0da65733beb69fdbc43cea524d86ed8e524479e9faefc9304cec34a57 url: "https://pub.dartlang.org"
url: "https://pub.dev"
source: hosted source: hosted
version: "6.0.15" version: "6.0.15"
url_launcher_linux: url_launcher_linux:
dependency: transitive dependency: transitive
description: description:
name: url_launcher_linux name: url_launcher_linux
sha256: c3ec89d52305ec647cf037eafe2be8d2f1149b5723d1f2ec716fc3d58469de5d url: "https://pub.dartlang.org"
url: "https://pub.dev"
source: hosted source: hosted
version: "3.0.0" version: "3.0.0"
url_launcher_macos: url_launcher_macos:
dependency: transitive dependency: transitive
description: description:
name: url_launcher_macos name: url_launcher_macos
sha256: c028c7f80fdb99cf48b94c471c0f8b9b855a188f4865df76e2a7663ae640e9d2 url: "https://pub.dartlang.org"
url: "https://pub.dev"
source: hosted source: hosted
version: "3.0.0" version: "3.0.0"
url_launcher_platform_interface: url_launcher_platform_interface:
dependency: transitive dependency: transitive
description: description:
name: url_launcher_platform_interface name: url_launcher_platform_interface
sha256: "1b9c4dab07794498b83b5f938e26b20f68c3b460a3015b0307f9541cb34ef93d" url: "https://pub.dartlang.org"
url: "https://pub.dev"
source: hosted source: hosted
version: "2.0.5" version: "2.0.5"
url_launcher_web: url_launcher_web:
dependency: transitive dependency: transitive
description: description:
name: url_launcher_web name: url_launcher_web
sha256: "2b5494722d4eb0fe1a12ceb15a4b132ba7dfc92793089c243bf109bed828d97f" url: "https://pub.dartlang.org"
url: "https://pub.dev"
source: hosted source: hosted
version: "2.0.9" version: "2.0.9"
url_launcher_windows: url_launcher_windows:
dependency: transitive dependency: transitive
description: description:
name: url_launcher_windows name: url_launcher_windows
sha256: aa14bdb9265fa22416fc387b33e44eb37fd38768bf465fafcec73d283f3457b1 url: "https://pub.dartlang.org"
url: "https://pub.dev"
source: hosted source: hosted
version: "3.0.0" version: "3.0.0"
uuid: uuid:
dependency: transitive dependency: transitive
description: description:
name: uuid name: uuid
sha256: "2469694ad079893e3b434a627970c33f2fa5adc46dfe03c9617546969a9a8afc" url: "https://pub.dartlang.org"
url: "https://pub.dev"
source: hosted source: hosted
version: "3.0.6" version: "3.0.6"
vector_math: vector_math:
dependency: transitive dependency: transitive
description: description:
name: vector_math name: vector_math
sha256: "80b3257d1492ce4d091729e3a67a60407d227c27241d6927be0130c98e741803" url: "https://pub.dartlang.org"
url: "https://pub.dev"
source: hosted source: hosted
version: "2.1.4" version: "2.1.1"
very_good_analysis: very_good_analysis:
dependency: "direct dev" dependency: "direct dev"
description: description:
name: very_good_analysis name: very_good_analysis
sha256: cecd7a0e92978dbece97c255502c8965f2db3439cde5a11f4b2c65f1955911ee url: "https://pub.dartlang.org"
url: "https://pub.dev"
source: hosted source: hosted
version: "2.4.0" version: "2.4.0"
win32: win32:
dependency: transitive dependency: transitive
description: description:
name: win32 name: win32
sha256: "8dd0c450f748d553a8181c6cb9fdf12b987cebaeccdbc75032186b89ae93907b" url: "https://pub.dartlang.org"
url: "https://pub.dev"
source: hosted source: hosted
version: "2.4.4" version: "2.4.4"
xdg_directories: xdg_directories:
dependency: transitive dependency: transitive
description: description:
name: xdg_directories name: xdg_directories
sha256: "060b6e1c891d956f72b5ac9463466c37cce3fa962a921532fc001e86fe93438e" url: "https://pub.dartlang.org"
url: "https://pub.dev"
source: hosted source: hosted
version: "0.2.0+1" version: "0.2.0+1"
sdks: sdks:
dart: ">=2.18.0 <3.0.0" dart: ">=2.16.0 <3.0.0"
flutter: ">=2.10.0" flutter: ">=2.10.0"

@ -5,6 +5,7 @@ export 'src/canvas/canvas.dart';
export 'src/flame_provider.dart'; export 'src/flame_provider.dart';
export 'src/keyboard_input_controller.dart'; export 'src/keyboard_input_controller.dart';
export 'src/layer.dart'; export 'src/layer.dart';
export 'src/parent_is_a.dart';
export 'src/pinball_forge2d_game.dart'; export 'src/pinball_forge2d_game.dart';
export 'src/shapes/shapes.dart'; export 'src/shapes/shapes.dart';
export 'src/sprite_animation.dart'; export 'src/sprite_animation.dart';

@ -1,5 +1,6 @@
import 'package:flame/components.dart'; import 'package:flame/components.dart';
import 'package:flame_forge2d/flame_forge2d.dart'; import 'package:flame_forge2d/flame_forge2d.dart';
import 'package:pinball_flame/pinball_flame.dart';
/// Appends a new [ContactCallbacks] to the parent. /// Appends a new [ContactCallbacks] to the parent.
/// ///

@ -174,16 +174,4 @@ class CanvasWrapper implements Canvas {
@override @override
void translate(double dx, double dy) => canvas.translate(dx, dy); void translate(double dx, double dy) => canvas.translate(dx, dy);
@override
Rect getDestinationClipBounds() => canvas.getDestinationClipBounds();
@override
Rect getLocalClipBounds() => canvas.getLocalClipBounds();
@override
Float64List getTransform() => canvas.getTransform();
@override
void restoreToCount(int count) => canvas.restoreToCount(count);
} }

@ -1,6 +1,6 @@
import 'dart:ui'; import 'dart:ui';
import 'package:collection/collection.dart' as collection; import 'package:collection/collection.dart' as collection;
import 'package:flame/components.dart'; import 'package:flame/components.dart';
import 'package:pinball_flame/src/canvas/canvas_wrapper.dart'; import 'package:pinball_flame/src/canvas/canvas_wrapper.dart';

@ -1,5 +1,3 @@
import 'dart:async';
import 'package:flame/components.dart'; import 'package:flame/components.dart';
/// A mixin that ensures a parent is of the given type [T]. /// A mixin that ensures a parent is of the given type [T].
@ -8,7 +6,7 @@ mixin ParentIsA<T extends Component> on Component {
T get parent => super.parent! as T; T get parent => super.parent! as T;
@override @override
FutureOr<void> addToParent(covariant T parent) { Future<void>? addToParent(covariant T parent) {
return super.addToParent(parent); return super.addToParent(parent);
} }
} }

@ -349,7 +349,7 @@ void main() {
); );
expect( expect(
game.overlays.activeOverlays, game.overlays.value,
contains(PinballGame.mobileControlsOverlay), contains(PinballGame.mobileControlsOverlay),
); );
}, },
@ -378,7 +378,7 @@ void main() {
); );
expect( expect(
game.overlays.activeOverlays, game.overlays.value,
isNot(contains(PinballGame.mobileControlsOverlay)), isNot(contains(PinballGame.mobileControlsOverlay)),
); );
}, },

@ -1,6 +1,6 @@
import 'dart:typed_data'; import 'dart:typed_data';
import 'package:flame/cache.dart'; import 'package:flame/assets.dart';
import 'package:flame/flame.dart'; import 'package:flame/flame.dart';
import 'package:flutter/material.dart'; import 'package:flutter/material.dart';
import 'package:flutter_test/flutter_test.dart'; import 'package:flutter_test/flutter_test.dart';

Loading…
Cancel
Save