Skip to content

Commit

Permalink
Merge pull request #66 from appunite/fix/android-build
Browse files Browse the repository at this point in the history
fix: prepare for iOS release
  • Loading branch information
agnkuz authored Jul 25, 2024
2 parents b5c709b + 7c972d2 commit e5f8a1b
Show file tree
Hide file tree
Showing 11 changed files with 12 additions and 66 deletions.
1 change: 1 addition & 0 deletions android/app/build.gradle
Original file line number Diff line number Diff line change
Expand Up @@ -79,4 +79,5 @@ flutter {

dependencies {
implementation 'com.google.android.gms:play-services-pay:16.0.3'
implementation 'com.android.support:multidex:1.0.3'
}
6 changes: 6 additions & 0 deletions ios/Runner.xcodeproj/project.pbxproj
Original file line number Diff line number Diff line change
Expand Up @@ -475,6 +475,8 @@
DEVELOPMENT_TEAM = WWNLSUFXTJ;
ENABLE_BITCODE = NO;
INFOPLIST_FILE = Runner/Info.plist;
INFOPLIST_KEY_CFBundleDisplayName = "Better World - Save the Planet";
INFOPLIST_KEY_LSApplicationCategoryType = "public.app-category.educational-games";
IPHONEOS_DEPLOYMENT_TARGET = 13.0;
LD_RUNPATH_SEARCH_PATHS = (
"$(inherited)",
Expand Down Expand Up @@ -655,6 +657,8 @@
DEVELOPMENT_TEAM = WWNLSUFXTJ;
ENABLE_BITCODE = NO;
INFOPLIST_FILE = Runner/Info.plist;
INFOPLIST_KEY_CFBundleDisplayName = "Better World - Save the Planet";
INFOPLIST_KEY_LSApplicationCategoryType = "public.app-category.educational-games";
IPHONEOS_DEPLOYMENT_TARGET = 13.0;
LD_RUNPATH_SEARCH_PATHS = (
"$(inherited)",
Expand All @@ -679,6 +683,8 @@
DEVELOPMENT_TEAM = WWNLSUFXTJ;
ENABLE_BITCODE = NO;
INFOPLIST_FILE = Runner/Info.plist;
INFOPLIST_KEY_CFBundleDisplayName = "Better World - Save the Planet";
INFOPLIST_KEY_LSApplicationCategoryType = "public.app-category.educational-games";
IPHONEOS_DEPLOYMENT_TARGET = 13.0;
LD_RUNPATH_SEARCH_PATHS = (
"$(inherited)",
Expand Down
10 changes: 2 additions & 8 deletions ios/Runner/Info.plist
Original file line number Diff line number Diff line change
Expand Up @@ -34,18 +34,12 @@
<string>LaunchScreen</string>
<key>UIMainStoryboardFile</key>
<string>Main</string>
<key>UIRequiresFullScreen</key>
<false/>
<key>UIStatusBarHidden</key>
<true/>
<key>UISupportedInterfaceOrientations</key>
<array>
<string>UIInterfaceOrientationPortrait</string>
<string>UIInterfaceOrientationLandscapeLeft</string>
<string>UIInterfaceOrientationLandscapeRight</string>
</array>
<key>UISupportedInterfaceOrientations~ipad</key>
<array>
<string>UIInterfaceOrientationPortrait</string>
<string>UIInterfaceOrientationPortraitUpsideDown</string>
<string>UIInterfaceOrientationLandscapeLeft</string>
<string>UIInterfaceOrientationLandscapeRight</string>
</array>
Expand Down
29 changes: 0 additions & 29 deletions lib/connectivity/connectivity_controller.dart

This file was deleted.

13 changes: 0 additions & 13 deletions lib/main.dart
Original file line number Diff line number Diff line change
@@ -1,5 +1,3 @@
import 'package:better_world/connectivity/connectivity_controller.dart';
import 'package:better_world/connectivity/no_connection_screen.dart';
import 'package:better_world/player_progress/persistence/database_persistence.dart';
import 'package:better_world/player_progress/persistence/firebase_persistence.dart';
import 'package:better_world/player_progress/persistence/local_player_persistence.dart';
Expand Down Expand Up @@ -75,9 +73,6 @@ class BetterWorldGame extends StatelessWidget {
localStorage: localPlayerPersistence,
),
),
ChangeNotifierProvider(
create: (context) => ConnectivityController(),
),
Provider(create: (_) => SettingsController()),
ProxyProvider2<SettingsController, AppLifecycleStateNotifier, AudioController>(
// Ensures that music starts immediately.
Expand All @@ -99,14 +94,6 @@ class BetterWorldGame extends StatelessWidget {
routeInformationProvider: router.routeInformationProvider,
routeInformationParser: router.routeInformationParser,
routerDelegate: router.routerDelegate,
builder: (context, child) {
final connectivityController = context.watch<ConnectivityController>();
if (connectivityController.isConnected) {
return child!;
} else {
return const NoConnectionScreen();
}
},
scrollBehavior: const MaterialScrollBehavior().copyWith(
dragDevices: {
PointerDeviceKind.mouse,
Expand Down
5 changes: 1 addition & 4 deletions lib/main_map/map_animation.dart
Original file line number Diff line number Diff line change
@@ -1,5 +1,3 @@
import 'dart:io';

import 'package:better_world/audio/audio_controller.dart';
import 'package:better_world/audio/sounds.dart';
import 'package:better_world/challenges/lights_out_challenge/lights_out_challenge_screen.dart';
Expand All @@ -11,7 +9,6 @@ import 'package:better_world/challenges/trees_challenge/trees_challenge_screen.d
import 'package:better_world/common/asset_paths.dart';
import 'package:better_world/player_progress/entities/challenges_entity.dart';
import 'package:better_world/player_progress/player_progress_controller.dart';
import 'package:flutter/foundation.dart';
import 'package:flutter/material.dart';
import 'package:go_router/go_router.dart';
import 'package:provider/provider.dart';
Expand Down Expand Up @@ -149,7 +146,7 @@ class _MapAnimationState extends State<MapAnimation> {
Widget build(BuildContext context) {
return RiveAnimation.asset(
AssetPaths.mapAnimation,
fit: kIsWeb || Platform.isMacOS ? BoxFit.contain : BoxFit.cover,
fit: BoxFit.contain,
artboard: 'map',
onInit: _onInit,
);
Expand Down
5 changes: 1 addition & 4 deletions lib/style/const_values.dart
Original file line number Diff line number Diff line change
@@ -1,15 +1,12 @@
import 'dart:io';

import 'package:better_world/common/asset_paths.dart';
import 'package:flutter/foundation.dart';
import 'package:flutter/material.dart';

final BorderRadius borderRadius12 = BorderRadius.circular(12);
final BorderRadius borderRadius16 = BorderRadius.circular(16);
final BorderRadius borderRadius24 = BorderRadius.circular(24);
final BorderRadius borderRadius32 = BorderRadius.circular(32);

bool displayAdditionalPadding = kIsWeb || Platform.isMacOS || Platform.isAndroid;
bool displayAdditionalPadding = true; // kIsWeb || Platform.isMacOS || Platform.isAndroid;

const gameCompletedBadgeTitle = 'World Hero';
const gameCompletedBadgeDescription =
Expand Down
2 changes: 0 additions & 2 deletions macos/Flutter/GeneratedPluginRegistrant.swift
Original file line number Diff line number Diff line change
Expand Up @@ -7,7 +7,6 @@ import Foundation

import audioplayers_darwin
import cloud_firestore
import connectivity_plus
import firebase_core
import package_info_plus
import path_provider_foundation
Expand All @@ -19,7 +18,6 @@ import wakelock_plus
func RegisterGeneratedPlugins(registry: FlutterPluginRegistry) {
AudioplayersDarwinPlugin.register(with: registry.registrar(forPlugin: "AudioplayersDarwinPlugin"))
FLTFirebaseFirestorePlugin.register(with: registry.registrar(forPlugin: "FLTFirebaseFirestorePlugin"))
ConnectivityPlusPlugin.register(with: registry.registrar(forPlugin: "ConnectivityPlusPlugin"))
FLTFirebaseCorePlugin.register(with: registry.registrar(forPlugin: "FLTFirebaseCorePlugin"))
FPPPackageInfoPlusPlugin.register(with: registry.registrar(forPlugin: "FPPPackageInfoPlusPlugin"))
PathProviderPlugin.register(with: registry.registrar(forPlugin: "PathProviderPlugin"))
Expand Down
3 changes: 1 addition & 2 deletions pubspec.yaml
Original file line number Diff line number Diff line change
Expand Up @@ -14,7 +14,6 @@ dependencies:
audioplayers: ^5.2.1
cloud_firestore: ^4.17.0
confetti: ^0.7.0
connecteo: 2.2.1
cupertino_icons: ^1.0.6
device_preview: ^1.1.0
fake_cloud_firestore: ^2.4.9
Expand All @@ -35,7 +34,7 @@ dependencies:
mocktail: ^1.0.3
nes_ui: ^0.10.0
overlay_tutorial: ^3.0.0
package_info_plus: ^7.0.0
package_info_plus: any
pausable_timer: ^3.1.0+3
provider: ^6.0.5
rive: ^0.12.4
Expand Down
3 changes: 0 additions & 3 deletions windows/flutter/generated_plugin_registrant.cc
Original file line number Diff line number Diff line change
Expand Up @@ -8,7 +8,6 @@

#include <audioplayers_windows/audioplayers_windows_plugin.h>
#include <cloud_firestore/cloud_firestore_plugin_c_api.h>
#include <connectivity_plus/connectivity_plus_windows_plugin.h>
#include <firebase_core/firebase_core_plugin_c_api.h>
#include <rive_common/rive_plugin.h>
#include <url_launcher_windows/url_launcher_windows.h>
Expand All @@ -18,8 +17,6 @@ void RegisterPlugins(flutter::PluginRegistry* registry) {
registry->GetRegistrarForPlugin("AudioplayersWindowsPlugin"));
CloudFirestorePluginCApiRegisterWithRegistrar(
registry->GetRegistrarForPlugin("CloudFirestorePluginCApi"));
ConnectivityPlusWindowsPluginRegisterWithRegistrar(
registry->GetRegistrarForPlugin("ConnectivityPlusWindowsPlugin"));
FirebaseCorePluginCApiRegisterWithRegistrar(
registry->GetRegistrarForPlugin("FirebaseCorePluginCApi"));
RivePluginRegisterWithRegistrar(
Expand Down
1 change: 0 additions & 1 deletion windows/flutter/generated_plugins.cmake
Original file line number Diff line number Diff line change
Expand Up @@ -5,7 +5,6 @@
list(APPEND FLUTTER_PLUGIN_LIST
audioplayers_windows
cloud_firestore
connectivity_plus
firebase_core
rive_common
url_launcher_windows
Expand Down

0 comments on commit e5f8a1b

Please sign in to comment.