Skip to content

Commit

Permalink
Fixed disable animations not applying in places
Browse files Browse the repository at this point in the history
Fixed being allowed to set minion skill values
  • Loading branch information
CalebQ42 committed Aug 30, 2024
1 parent 4dc2abf commit 58fef46
Show file tree
Hide file tree
Showing 5 changed files with 19 additions and 14 deletions.
4 changes: 4 additions & 0 deletions lib/sw.dart
Original file line number Diff line number Diff line change
Expand Up @@ -70,6 +70,10 @@ class SW with TopResources {
app.prefs.newDrive = true;
}
if (kDebugMode) app.devMode = true;
if (app.prefs.noAnimations) {
app.globalDuration = Duration.zero;
app.transitionDuration = Duration.zero;
}
if (!kIsWeb) {
await pathprov.loadLibrary();
var docDir = await pathprov.getApplicationDocumentsDirectory();
Expand Down
17 changes: 9 additions & 8 deletions lib/ui/dialogs/creature/skill_edit.dart
Original file line number Diff line number Diff line change
Expand Up @@ -51,15 +51,16 @@ class SkillEditDialog {
children: [
Container(height: 15),
_SkillSelector(skill, bot),
Container(height: 10),
TextField(
keyboardType: TextInputType.number,
inputFormatters: [FilteringTextInputFormatter.digitsOnly],
controller: valueController,
decoration: InputDecoration(
labelText: SW.of(context).locale.value,
if (creature is Character) Container(height: 10),
if (creature is Character)
TextField(
keyboardType: TextInputType.number,
inputFormatters: [FilteringTextInputFormatter.digitsOnly],
controller: valueController,
decoration: InputDecoration(
labelText: SW.of(context).locale.value,
),
),
),
if (creature is Character) Container(height: 10),
if (creature is Character)
UpdatingSwitchTile(
Expand Down
1 change: 1 addition & 0 deletions lib/ui/misc/info_card.dart
Original file line number Diff line number Diff line change
Expand Up @@ -34,6 +34,7 @@ class _InfoCardState extends State<InfoCard> {
childrenPadding: const EdgeInsets.all(10),
expansionAnimationStyle: AnimationStyle(
duration: app.globalDuration,
reverseDuration: app.globalDuration,
),
title: AnimatedAlign(
curve: Curves.easeOutBack,
Expand Down
7 changes: 3 additions & 4 deletions pubspec.lock
Original file line number Diff line number Diff line change
Expand Up @@ -100,10 +100,9 @@ packages:
darkstorm_common:
dependency: "direct main"
description:
name: darkstorm_common
sha256: "8661f4fe4dbdd454ffa7a29729d516993de7279728057aeb981e1d9004bfb825"
url: "https://pub.dev"
source: hosted
path: "../darkstorm-common"
relative: true
source: path
version: "2.0.0"
dbus:
dependency: transitive
Expand Down
4 changes: 2 additions & 2 deletions pubspec.yaml
Original file line number Diff line number Diff line change
Expand Up @@ -3,7 +3,7 @@ description: Character sheet and dice app for the FFG Star Wars TTRPG

publish_to: "none"

version: 4.3.3+198
version: 4.3.4+199

environment:
sdk: ">=3.0.0-417.2.beta <4.0.0"
Expand All @@ -28,7 +28,7 @@ dependencies:
googleapis: ^13.2.0
uuid: ^4.4.2
flutter_dotenv: ^5.1.0
darkstorm_common: ^2.0.0
darkstorm_common: ^2.0.1
flutter_secure_storage: ^9.2.2
http: ^1.2.2

Expand Down

0 comments on commit 58fef46

Please sign in to comment.