Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Adds sksl to reduce animations stutter #167

Merged
merged 3 commits into from
Jul 29, 2021
Merged
Show file tree
Hide file tree
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension


Conversations
Failed to load comments.
Jump to
Jump to file
Failed to load files.
Diff view
Diff view
4 changes: 3 additions & 1 deletion .github/workflows/pull-request.yml
Original file line number Diff line number Diff line change
Expand Up @@ -7,8 +7,9 @@ on:
- main

env:
flutter_version: "2.2.3"
flutter_version: "2.4.0-4.2.pre"
java_version: "12.x"
flutter_channel: "beta"

jobs:
build:
Expand All @@ -35,6 +36,7 @@ jobs:
uses: subosito/flutter-action@v1
with:
flutter-version: ${{ env.flutter_version }}
channel: ${{ env.flutter_channel }}

# Run pre-requisites to build both applications (iOS and Android)
- name: Analyze and run tests
Expand Down
4 changes: 3 additions & 1 deletion .github/workflows/release.yml
Original file line number Diff line number Diff line change
Expand Up @@ -6,8 +6,9 @@ on:
- published

env:
flutter_version: "2.2.3"
flutter_version: "2.4.0-4.2.pre"
java_version: "12.x"
flutter_channel: "beta"

jobs:
build:
Expand Down Expand Up @@ -40,6 +41,7 @@ jobs:
uses: subosito/flutter-action@v1
with:
flutter-version: ${{ env.flutter_version }}
channel: ${{ env.flutter_channel }}

# Uses `shimataro/ssh-key-action@v2` action to install Github SSH private key locally and setup github.com domain
# as a known host.
Expand Down
1 change: 1 addition & 0 deletions android/app/build.gradle
Original file line number Diff line number Diff line change
Expand Up @@ -41,6 +41,7 @@ android {
applicationId "com.olmps.memoClient"
minSdkVersion 17
targetSdkVersion 30
multiDexEnabled true
versionCode 5
versionName flutterVersionName
}
Expand Down
2 changes: 1 addition & 1 deletion android/fastlane/Fastfile
Original file line number Diff line number Diff line change
Expand Up @@ -10,7 +10,7 @@ platform :android do
android_set_version_code()

# Build the app
sh("flutter", "build", "appbundle", "--dart-define=ENV=PROD")
sh("flutter", "build", "appbundle", "--dart-define=ENV=PROD", "--bundle-sksl-path android_animations.json")

# Gets version info
version_info = flutter_version(
Expand Down
1 change: 1 addition & 0 deletions android_animations.json

Large diffs are not rendered by default.

2 changes: 1 addition & 1 deletion ios/Flutter/AppFrameworkInfo.plist
Original file line number Diff line number Diff line change
Expand Up @@ -21,6 +21,6 @@
<key>CFBundleVersion</key>
<string>1.0</string>
<key>MinimumOSVersion</key>
<string>8.0</string>
<string>9.0</string>
Copy link
Contributor

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Why the iOS minimum version was also bumped?

Copy link
Contributor Author

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

I don't know why Flutter is automatically bumping this version to 9 every time I build the iOS app:

CleanShot 2021-07-28 at 17 15 56

There's nothing about the minimum version change in the Breaking Changes guide, although they state in Build and release an iOS app
that the minimum supported version is iOS 9.0 (we also have deployment target set to 9.0 in the PBX)

CleanShot 2021-07-28 at 17 19 07
CleanShot 2021-07-28 at 17 18 58

TLDR: I don't know why Flutter automatically bumped, but the version 9 seems to be the correct one

</dict>
</plist>
72 changes: 21 additions & 51 deletions ios/Podfile.lock
Original file line number Diff line number Diff line change
@@ -1,38 +1,4 @@
PODS:
- DKImagePickerController/Core (4.3.2):
- DKImagePickerController/ImageDataManager
- DKImagePickerController/Resource
- DKImagePickerController/ImageDataManager (4.3.2)
- DKImagePickerController/PhotoGallery (4.3.2):
- DKImagePickerController/Core
- DKPhotoGallery
- DKImagePickerController/Resource (4.3.2)
- DKPhotoGallery (0.0.17):
- DKPhotoGallery/Core (= 0.0.17)
- DKPhotoGallery/Model (= 0.0.17)
- DKPhotoGallery/Preview (= 0.0.17)
- DKPhotoGallery/Resource (= 0.0.17)
- SDWebImage
- SwiftyGif
- DKPhotoGallery/Core (0.0.17):
- DKPhotoGallery/Model
- DKPhotoGallery/Preview
- SDWebImage
- SwiftyGif
- DKPhotoGallery/Model (0.0.17):
- SDWebImage
- SwiftyGif
- DKPhotoGallery/Preview (0.0.17):
- DKPhotoGallery/Model
- DKPhotoGallery/Resource
- SDWebImage
- SwiftyGif
- DKPhotoGallery/Resource (0.0.17):
- SDWebImage
- SwiftyGif
- file_picker (0.0.1):
- DKImagePickerController/PhotoGallery
- Flutter
- Firebase/AnalyticsWithoutAdIdSupport (8.3.0):
- Firebase/CoreOnly
- FirebaseAnalytics/WithoutAdIdSupport (~> 8.3.0)
Expand Down Expand Up @@ -82,6 +48,13 @@ PODS:
- GoogleUtilities/UserDefaults (~> 7.4)
- PromisesObjC (< 3.0, >= 1.2)
- Flutter (1.0.0)
- flutter_inappwebview (0.0.1):
- Flutter
- flutter_inappwebview/Core (= 0.0.1)
- OrderedSet (~> 5.0)
- flutter_inappwebview/Core (0.0.1):
- Flutter
- OrderedSet (~> 5.0)
- flutter_keyboard_visibility (0.0.1):
- Flutter
- GoogleAppMeasurement/WithoutAdIdSupport (8.3.0):
Expand Down Expand Up @@ -120,34 +93,32 @@ PODS:
- nanopb/encode (= 2.30908.0)
- nanopb/decode (2.30908.0)
- nanopb/encode (2.30908.0)
- OrderedSet (5.0.0)
- package_info (0.0.1):
- Flutter
- path_provider (0.0.1):
- Flutter
- PromisesObjC (1.2.12)
- SDWebImage (5.11.1):
- SDWebImage/Core (= 5.11.1)
- SDWebImage/Core (5.11.1)
- SwiftyGif (5.4.0)
- url_launcher (0.0.1):
- Flutter
- video_player (0.0.1):
- Flutter

DEPENDENCIES:
- file_picker (from `.symlinks/plugins/file_picker/ios`)
- firebase_analytics (from `.symlinks/plugins/firebase_analytics/ios`)
- firebase_core (from `.symlinks/plugins/firebase_core/ios`)
- firebase_crashlytics (from `.symlinks/plugins/firebase_crashlytics/ios`)
- Flutter (from `Flutter`)
- flutter_inappwebview (from `.symlinks/plugins/flutter_inappwebview/ios`)
- flutter_keyboard_visibility (from `.symlinks/plugins/flutter_keyboard_visibility/ios`)
- image_picker (from `.symlinks/plugins/image_picker/ios`)
- package_info (from `.symlinks/plugins/package_info/ios`)
- path_provider (from `.symlinks/plugins/path_provider/ios`)
- url_launcher (from `.symlinks/plugins/url_launcher/ios`)
- video_player (from `.symlinks/plugins/video_player/ios`)

SPEC REPOS:
trunk:
- DKImagePickerController
- DKPhotoGallery
- Firebase
- FirebaseAnalytics
- FirebaseCore
Expand All @@ -158,13 +129,10 @@ SPEC REPOS:
- GoogleDataTransport
- GoogleUtilities
- nanopb
- OrderedSet
- PromisesObjC
- SDWebImage
- SwiftyGif

EXTERNAL SOURCES:
file_picker:
:path: ".symlinks/plugins/file_picker/ios"
firebase_analytics:
:path: ".symlinks/plugins/firebase_analytics/ios"
firebase_core:
Expand All @@ -173,6 +141,8 @@ EXTERNAL SOURCES:
:path: ".symlinks/plugins/firebase_crashlytics/ios"
Flutter:
:path: Flutter
flutter_inappwebview:
:path: ".symlinks/plugins/flutter_inappwebview/ios"
flutter_keyboard_visibility:
:path: ".symlinks/plugins/flutter_keyboard_visibility/ios"
image_picker:
Expand All @@ -183,11 +153,10 @@ EXTERNAL SOURCES:
:path: ".symlinks/plugins/path_provider/ios"
url_launcher:
:path: ".symlinks/plugins/url_launcher/ios"
video_player:
:path: ".symlinks/plugins/video_player/ios"

SPEC CHECKSUMS:
DKImagePickerController: b5eb7f7a388e4643264105d648d01f727110fc3d
DKPhotoGallery: fdfad5125a9fdda9cc57df834d49df790dbb4179
file_picker: 3e6c3790de664ccf9b882732d9db5eaf6b8d4eb1
Firebase: 817b9171d0d51dccc458b94a5e8edff6b1dd323d
firebase_analytics: 960bf7a27a2bf7cd04cacce66962c13561efd0b8
firebase_core: 72374607c8c6f5a0adc0559e5c5bf57deda975e3
Expand All @@ -198,18 +167,19 @@ SPEC CHECKSUMS:
FirebaseCrashlytics: 3d83f2e8a47f476f47c82ff4536b169df6781271
FirebaseInstallations: 1585729afc787877763208c2088ed84221161f77
Flutter: 434fef37c0980e73bb6479ef766c45957d4b510c
flutter_inappwebview: bfd58618f49dc62f2676de690fc6dcda1d6c3721
flutter_keyboard_visibility: 0339d06371254c3eb25eeb90ba8d17dca8f9c069
GoogleAppMeasurement: de70802583dedceb0bca18172b345307e8f410b8
GoogleDataTransport: 85fd18ff3019bb85d3f2c551d04c481dedf71fc9
GoogleUtilities: eea970f4a389963963bffe8d8fabe43540678b9c
image_picker: 50e7c7ff960e5f58faa4d1f4af84a771c671bc4a
image_picker: e06f7a68f000bd36f552c1847e33cda96ed31f1f
nanopb: a0ba3315591a9ae0a16a309ee504766e90db0c96
OrderedSet: aaeb196f7fef5a9edf55d89760da9176ad40b93c
package_info: 873975fc26034f0b863a300ad47e7f1ac6c7ec62
path_provider: abfe2b5c733d04e238b0d8691db0cfd63a27a93c
PromisesObjC: 3113f7f76903778cf4a0586bd1ab89329a0b7b97
SDWebImage: a7f831e1a65eb5e285e3fb046a23fcfbf08e696d
SwiftyGif: 5d4af95df24caf1c570dbbcb32a3b8a0763bc6d7
url_launcher: 6fef411d543ceb26efce54b05a0a40bfd74cbbef
video_player: 9cc823b1d9da7e8427ee591e8438bfbcde500e6e

PODFILE CHECKSUM: 93c13a6b510094ca189e0993ce1f80877faea644

Expand Down
2 changes: 1 addition & 1 deletion ios/fastlane/Fastfile
Original file line number Diff line number Diff line change
Expand Up @@ -83,7 +83,7 @@ platform :ios do
)

# Run flutter build with release mode
sh("flutter", "build", "ipa", "--release", "--dart-define=ENV=PROD", "--export-options-plist=ios/exportOptions.plist")
sh("flutter", "build", "ipa", "--release", "--dart-define=ENV=PROD", "--export-options-plist=ios/exportOptions.plist", "--bundle-sksl-path ios_animations.json")

# Zip dSYMs
sh(
Expand Down
1 change: 1 addition & 0 deletions ios_animations.json

Large diffs are not rendered by default.

2 changes: 1 addition & 1 deletion lib/application/pages/details/collection_details_page.dart
Original file line number Diff line number Diff line change
Expand Up @@ -4,10 +4,10 @@ import 'package:flutter_riverpod/flutter_riverpod.dart';
import 'package:layoutr/common_layout.dart';
Copy link
Contributor Author

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Sorted the imports alphabetically (flutter analyze complains if not)

Copy link
Contributor

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Do you know if this is linteable? It seems that it should, if flutter is complaining.

Copy link
Contributor Author

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

This is being catch by the linter:

CleanShot 2021-07-28 at 17 26 14

I'm just thinking why Flutter wasn't complaining before about it, but I have no idea why

import 'package:memo/application/constants/strings.dart' as strings;
import 'package:memo/application/coordinator/routes_coordinator.dart';
import 'package:memo/application/pages/details/contributor_view.dart';
import 'package:memo/application/pages/details/details_providers.dart';
import 'package:memo/application/theme/theme_controller.dart';
import 'package:memo/application/view-models/details/collection_details_vm.dart';
import 'package:memo/application/pages/details/contributor_view.dart';
import 'package:memo/application/widgets/theme/hero_collection_card.dart';
import 'package:memo/application/widgets/theme/resources_list.dart';
import 'package:memo/application/widgets/theme/themed_container.dart';
Expand Down
8 changes: 4 additions & 4 deletions lib/application/pages/details/contributor_view.dart
Original file line number Diff line number Diff line change
Expand Up @@ -3,14 +3,14 @@ import 'package:flutter/material.dart';
import 'package:flutter_hooks/flutter_hooks.dart';
import 'package:layoutr/layoutr.dart';

import 'package:memo/application/theme/theme_controller.dart';
import 'package:memo/application/view-models/details/collection_details_vm.dart';
import 'package:memo/application/widgets/theme/link.dart';
import 'package:memo/application/constants/animations.dart' as anims;
import 'package:memo/application/constants/dimensions.dart' as dimens;
import 'package:memo/application/constants/strings.dart' as strings;
import 'package:memo/application/constants/images.dart' as images;
import 'package:memo/application/constants/strings.dart' as strings;
import 'package:memo/application/theme/theme_controller.dart';
import 'package:memo/application/utils/bottom_sheet.dart';
import 'package:memo/application/view-models/details/collection_details_vm.dart';
import 'package:memo/application/widgets/theme/link.dart';

/// Displays a custom-layout view for a list of [contributors].
///
Expand Down
2 changes: 1 addition & 1 deletion lib/application/pages/home/home_page.dart
Original file line number Diff line number Diff line change
Expand Up @@ -5,8 +5,8 @@ import 'package:memo/application/constants/strings.dart' as strings;
import 'package:memo/application/coordinator/routes_coordinator.dart';
import 'package:memo/application/pages/home/collections/collections_page.dart';
import 'package:memo/application/pages/home/progress/progress_page.dart';
import 'package:memo/application/widgets/theme/themed_container.dart';
import 'package:memo/application/widgets/material/asset_icon_button.dart';
import 'package:memo/application/widgets/theme/themed_container.dart';

enum HomeBottomTab { collections, progress }

Expand Down
1 change: 0 additions & 1 deletion lib/application/theme/material_theme_data.dart
Original file line number Diff line number Diff line change
Expand Up @@ -89,7 +89,6 @@ ThemeData buildThemeData({
colorScheme: colorScheme,
textTheme: textTheme,
primaryTextTheme: textTheme,
accentTextTheme: textTheme,
scaffoldBackgroundColor: neutralSwatch.shade900,
cardTheme: cardTheme,
elevatedButtonTheme: elevatedButtonTheme,
Expand Down
2 changes: 1 addition & 1 deletion lib/application/utils/bottom_sheet.dart
Original file line number Diff line number Diff line change
@@ -1,8 +1,8 @@
import 'package:flutter/material.dart';
import 'package:flutter_riverpod/flutter_riverpod.dart';
import 'package:layoutr/common_layout.dart';
import 'package:memo/application/constants/dimensions.dart' as dimens;
import 'package:memo/application/theme/theme_controller.dart';
import 'package:flutter_riverpod/flutter_riverpod.dart';

/// Wraps a [showModalBottomSheet] behavior that resizes itself content based on [child] size
///
Expand Down
4 changes: 2 additions & 2 deletions lib/application/view-models/app_vm.dart
Original file line number Diff line number Diff line change
Expand Up @@ -2,6 +2,8 @@ import 'package:flutter/foundation.dart';
import 'package:flutter/services.dart';
import 'package:flutter_riverpod/flutter_riverpod.dart';
import 'package:memo/data/gateways/application_bundle.dart';
import 'package:memo/data/gateways/sembast.dart' as sembast;
import 'package:memo/data/gateways/sembast_database.dart';
import 'package:memo/data/repositories/collection_repository.dart';
import 'package:memo/data/repositories/memo_execution_repository.dart';
import 'package:memo/data/repositories/memo_repository.dart';
Expand All @@ -11,8 +13,6 @@ import 'package:memo/data/repositories/user_repository.dart';
import 'package:memo/data/repositories/version_repository.dart';
import 'package:memo/domain/isolated_services/memory_recall_services.dart';
import 'package:memo/domain/services/collection_services.dart';
import 'package:memo/data/gateways/sembast_database.dart';
import 'package:memo/data/gateways/sembast.dart' as sembast;
import 'package:memo/domain/services/execution_services.dart';
import 'package:memo/domain/services/progress_services.dart';
import 'package:memo/domain/services/resource_services.dart';
Expand Down
Original file line number Diff line number Diff line change
@@ -1,8 +1,8 @@
import 'package:flutter/material.dart';
import 'package:flutter_hooks/flutter_hooks.dart';
import 'package:memo/application/theme/theme_controller.dart';
import 'package:memo/application/constants/animations.dart' as anims;
import 'package:memo/application/constants/dimensions.dart' as dimens;
import 'package:memo/application/theme/theme_controller.dart';
import 'package:memo/application/widgets/animatable_progress.dart';

/// Centers a styled [Text] element above a [AnimatableCircularProgress] with [progressValue].
Expand Down
2 changes: 1 addition & 1 deletion lib/application/widgets/theme/resources_list.dart
Original file line number Diff line number Diff line change
@@ -1,7 +1,7 @@
import 'package:flutter/material.dart';
import 'package:layoutr/common_layout.dart';
import 'package:memo/application/constants/strings.dart' as strings;
import 'package:memo/application/constants/dimensions.dart' as dimens;
import 'package:memo/application/constants/strings.dart' as strings;
import 'package:memo/application/utils/scaffold_messenger.dart';
import 'package:memo/application/widgets/theme/link.dart';

Expand Down
2 changes: 1 addition & 1 deletion lib/application/widgets/theme/themed_tab_bar.dart
Original file line number Diff line number Diff line change
@@ -1,7 +1,7 @@
import 'package:flutter/material.dart';
import 'package:flutter_hooks/flutter_hooks.dart';
import 'package:memo/application/theme/theme_controller.dart';
import 'package:memo/application/constants/dimensions.dart' as dimens;
import 'package:memo/application/theme/theme_controller.dart';

/// Decorates a [TabBar] with custom layout specs.
class ThemedTabBar extends HookWidget {
Expand Down
2 changes: 1 addition & 1 deletion lib/data/repositories/collection_repository.dart
Original file line number Diff line number Diff line change
Expand Up @@ -3,8 +3,8 @@ import 'dart:async';
import 'package:memo/core/faults/errors/inconsistent_state_error.dart';
import 'package:memo/data/gateways/application_bundle.dart';
import 'package:memo/data/gateways/sembast_database.dart';
import 'package:memo/data/serializers/collection_serializer.dart';
import 'package:memo/data/serializers/collection_memos_serializer.dart';
import 'package:memo/data/serializers/collection_serializer.dart';
import 'package:memo/data/serializers/contributor_serializer.dart';
import 'package:memo/data/serializers/memo_difficulty_parser.dart';
import 'package:memo/domain/enums/memo_difficulty.dart';
Expand Down
2 changes: 1 addition & 1 deletion lib/data/repositories/user_repository.dart
Original file line number Diff line number Diff line change
Expand Up @@ -2,8 +2,8 @@ import 'dart:async';

import 'package:memo/core/faults/errors/inconsistent_state_error.dart';
import 'package:memo/data/gateways/sembast_database.dart';
import 'package:memo/data/serializers/user_serializer.dart';
import 'package:memo/data/serializers/memo_difficulty_parser.dart';
import 'package:memo/data/serializers/user_serializer.dart';
import 'package:memo/domain/enums/memo_difficulty.dart';
import 'package:memo/domain/models/user.dart';

Expand Down