Skip to content

Navigation Menu

Sign in
Appearance settings

Search code, repositories, users, issues, pull requests...

Provide feedback

We read every piece of feedback, and take your input very seriously.

Saved searches

Use saved searches to filter your results more quickly

Sign up
Appearance settings

Commit 35d7c18

Browse files
authored
Merge branch 'master' into firebase-analytics
2 parents 9d6e70b + d02e85a commit 35d7c18

File tree

98 files changed

+639
-607
lines changed

Some content is hidden

Large Commits have some content hidden by default. Use the searchbox below for content that may be hidden.

98 files changed

+639
-607
lines changed

‎ios/Podfile‎

Lines changed: 15 additions & 61 deletions
Original file line numberDiff line numberDiff line change
@@ -10,78 +10,32 @@ project 'Runner', {
1010
'Release' => :release,
1111
}
1212

13-
def parse_KV_file(file,separator='=')
14-
file_abs_path = File.expand_path(file)
15-
if !File.exists?file_abs_path
16-
return[];
13+
def flutter_root
14+
generated_xcode_build_settings_path = File.expand_path(File.join('..','Flutter','Generated.xcconfig'),__FILE__)
15+
unlessFile.exist?(generated_xcode_build_settings_path)
16+
raise"#{generated_xcode_build_settings_path} must exist. If you're running pod install manually, make sure flutter pub get is executed first"
1717
end
18-
generated_key_values = {}
19-
skip_line_start_symbols = ["#", "/"]
20-
File.foreach(file_abs_path) do |line|
21-
next if skip_line_start_symbols.any? { |symbol| line =~ /^\s*#{symbol}/ }
22-
plugin = line.split(pattern=separator)
23-
if plugin.length == 2
24-
podname = plugin[0].strip()
25-
path = plugin[1].strip()
26-
podpath = File.expand_path("#{path}", file_abs_path)
27-
generated_key_values[podname] = podpath
28-
else
29-
puts "Invalid plugin specification: #{line}"
30-
end
18+
19+
File.foreach(generated_xcode_build_settings_path) do |line|
20+
matches = line.match(/FLUTTER_ROOT\=(.*)/)
21+
return matches[1].strip if matches
3122
end
32-
generated_key_values
23+
raise"FLUTTER_ROOT not found in #{generated_xcode_build_settings_path}. Try deleting Generated.xcconfig, then run flutter pub get"
3324
end
3425

26+
require File.expand_path(File.join('packages', 'flutter_tools', 'bin', 'podhelper'), flutter_root)
27+
28+
flutter_ios_podfile_setup
29+
3530
target 'Runner' do
3631
use_frameworks!
3732
use_modular_headers!
3833

39-
# Flutter Pod
40-
41-
copied_flutter_dir = File.join(__dir__, 'Flutter')
42-
copied_framework_path = File.join(copied_flutter_dir, 'Flutter.framework')
43-
copied_podspec_path = File.join(copied_flutter_dir, 'Flutter.podspec')
44-
unless File.exist?(copied_framework_path) && File.exist?(copied_podspec_path)
45-
# Copy Flutter.framework and Flutter.podspec to Flutter/ to have something to link against if the xcode backend script has not run yet.
46-
# That script will copy the correct debug/profile/release version of the framework based on the currently selected Xcode configuration.
47-
# CocoaPods will not embed the framework on pod install (before any build phases can generate) if the dylib does not exist.
48-
49-
generated_xcode_build_settings_path = File.join(copied_flutter_dir, 'Generated.xcconfig')
50-
unless File.exist?(generated_xcode_build_settings_path)
51-
raise "Generated.xcconfig must exist. If you're running pod install manually, make sure flutter pub get is executed first"
52-
end
53-
generated_xcode_build_settings = parse_KV_file(generated_xcode_build_settings_path)
54-
cached_framework_dir = generated_xcode_build_settings['FLUTTER_FRAMEWORK_DIR'];
55-
56-
unless File.exist?(copied_framework_path)
57-
FileUtils.cp_r(File.join(cached_framework_dir, 'Flutter.framework'), copied_flutter_dir)
58-
end
59-
unless File.exist?(copied_podspec_path)
60-
FileUtils.cp(File.join(cached_framework_dir, 'Flutter.podspec'), copied_flutter_dir)
61-
end
62-
end
63-
64-
# Keep pod path relative so it can be checked into Podfile.lock.
65-
pod 'Flutter', :path => 'Flutter'
66-
67-
# Plugin Pods
68-
69-
# Prepare symlinks folder. We use symlinks to avoid having Podfile.lock
70-
# referring to absolute paths on developers' machines.
71-
system('rm -rf .symlinks')
72-
system('mkdir -p .symlinks/plugins')
73-
plugin_pods = parse_KV_file('../.flutter-plugins')
74-
plugin_pods.each do |name, path|
75-
symlink = File.join('.symlinks', 'plugins', name)
76-
File.symlink(path, symlink)
77-
pod name, :path => File.join(symlink, 'ios')
78-
end
34+
flutter_install_all_ios_pods File.dirname(File.realpath(__FILE__))
7935
end
8036

8137
post_install do |installer|
8238
installer.pods_project.targets.each do |target|
83-
target.build_configurations.each do |config|
84-
config.build_settings['ENABLE_BITCODE'] = 'NO'
85-
end
39+
flutter_additional_ios_build_settings(target)
8640
end
8741
end

‎ios/Podfile.lock‎

Lines changed: 8 additions & 68 deletions
Original file line numberDiff line numberDiff line change
@@ -5,59 +5,29 @@ PODS:
55
- FMDB (2.7.5):
66
- FMDB/standard (= 2.7.5)
77
- FMDB/standard (2.7.5)
8-
- path_provider (0.0.1):
9-
- Flutter
10-
- path_provider_linux (0.0.1):
11-
- Flutter
12-
- path_provider_macos (0.0.1):
8+
- package_info (0.0.1):
139
- Flutter
14-
- path_provider_windows (0.0.1):
10+
- path_provider (0.0.1):
1511
- Flutter
1612
- share (0.0.1):
1713
- Flutter
1814
- shared_preferences (0.0.1):
1915
- Flutter
20-
- shared_preferences_linux (0.0.1):
21-
- Flutter
22-
- shared_preferences_macos (0.0.1):
23-
- Flutter
24-
- shared_preferences_web (0.0.1):
25-
- Flutter
26-
- shared_preferences_windows (0.0.1):
27-
- Flutter
2816
- sqflite (0.0.2):
2917
- Flutter
3018
- FMDB (>= 2.7.5)
3119
- url_launcher (0.0.1):
3220
- Flutter
33-
- url_launcher_linux (0.0.1):
34-
- Flutter
35-
- url_launcher_macos (0.0.1):
36-
- Flutter
37-
- url_launcher_web (0.0.1):
38-
- Flutter
39-
- url_launcher_windows (0.0.1):
40-
- Flutter
4121

4222
DEPENDENCIES:
4323
- device_info (from `.symlinks/plugins/device_info/ios`)
4424
- Flutter (from `Flutter`)
25+
- package_info (from `.symlinks/plugins/package_info/ios`)
4526
- path_provider (from `.symlinks/plugins/path_provider/ios`)
46-
- path_provider_linux (from `.symlinks/plugins/path_provider_linux/ios`)
47-
- path_provider_macos (from `.symlinks/plugins/path_provider_macos/ios`)
48-
- path_provider_windows (from `.symlinks/plugins/path_provider_windows/ios`)
4927
- share (from `.symlinks/plugins/share/ios`)
5028
- shared_preferences (from `.symlinks/plugins/shared_preferences/ios`)
51-
- shared_preferences_linux (from `.symlinks/plugins/shared_preferences_linux/ios`)
52-
- shared_preferences_macos (from `.symlinks/plugins/shared_preferences_macos/ios`)
53-
- shared_preferences_web (from `.symlinks/plugins/shared_preferences_web/ios`)
54-
- shared_preferences_windows (from `.symlinks/plugins/shared_preferences_windows/ios`)
5529
- sqflite (from `.symlinks/plugins/sqflite/ios`)
5630
- url_launcher (from `.symlinks/plugins/url_launcher/ios`)
57-
- url_launcher_linux (from `.symlinks/plugins/url_launcher_linux/ios`)
58-
- url_launcher_macos (from `.symlinks/plugins/url_launcher_macos/ios`)
59-
- url_launcher_web (from `.symlinks/plugins/url_launcher_web/ios`)
60-
- url_launcher_windows (from `.symlinks/plugins/url_launcher_windows/ios`)
6131

6232
SPEC REPOS:
6333
trunk:
@@ -68,60 +38,30 @@ EXTERNAL SOURCES:
6838
:path: ".symlinks/plugins/device_info/ios"
6939
Flutter:
7040
:path: Flutter
41+
package_info:
42+
:path: ".symlinks/plugins/package_info/ios"
7143
path_provider:
7244
:path: ".symlinks/plugins/path_provider/ios"
73-
path_provider_linux:
74-
:path: ".symlinks/plugins/path_provider_linux/ios"
75-
path_provider_macos:
76-
:path: ".symlinks/plugins/path_provider_macos/ios"
77-
path_provider_windows:
78-
:path: ".symlinks/plugins/path_provider_windows/ios"
7945
share:
8046
:path: ".symlinks/plugins/share/ios"
8147
shared_preferences:
8248
:path: ".symlinks/plugins/shared_preferences/ios"
83-
shared_preferences_linux:
84-
:path: ".symlinks/plugins/shared_preferences_linux/ios"
85-
shared_preferences_macos:
86-
:path: ".symlinks/plugins/shared_preferences_macos/ios"
87-
shared_preferences_web:
88-
:path: ".symlinks/plugins/shared_preferences_web/ios"
89-
shared_preferences_windows:
90-
:path: ".symlinks/plugins/shared_preferences_windows/ios"
9149
sqflite:
9250
:path: ".symlinks/plugins/sqflite/ios"
9351
url_launcher:
9452
:path: ".symlinks/plugins/url_launcher/ios"
95-
url_launcher_linux:
96-
:path: ".symlinks/plugins/url_launcher_linux/ios"
97-
url_launcher_macos:
98-
:path: ".symlinks/plugins/url_launcher_macos/ios"
99-
url_launcher_web:
100-
:path: ".symlinks/plugins/url_launcher_web/ios"
101-
url_launcher_windows:
102-
:path: ".symlinks/plugins/url_launcher_windows/ios"
10353

10454
SPEC CHECKSUMS:
10555
device_info: d7d233b645a32c40dfdc212de5cf646ca482f175
106-
Flutter: 0e3d915762c693b495b44d77113d4970485de6ec
56+
Flutter: 434fef37c0980e73bb6479ef766c45957d4b510c
10757
FMDB: 2ce00b547f966261cd18927a3ddb07cb6f3db82a
58+
package_info: 873975fc26034f0b863a300ad47e7f1ac6c7ec62
10859
path_provider: abfe2b5c733d04e238b0d8691db0cfd63a27a93c
109-
path_provider_linux: 4d630dc393e1f20364f3e3b4a2ff41d9674a84e4
110-
path_provider_macos: f760a3c5b04357c380e2fddb6f9db6f3015897e0
111-
path_provider_windows: a2b81600c677ac1959367280991971cb9a1edb3b
11260
share: 0b2c3e82132f5888bccca3351c504d0003b3b410
11361
shared_preferences: af6bfa751691cdc24be3045c43ec037377ada40d
114-
shared_preferences_linux: afefbfe8d921e207f01ede8b60373d9e3b566b78
115-
shared_preferences_macos: f3f29b71ccbb56bf40c9dd6396c9acf15e214087
116-
shared_preferences_web: 141cce0c3ed1a1c5bf2a0e44f52d31eeb66e5ea9
117-
shared_preferences_windows: 36b76d6f54e76ead957e60b49e2f124b4cd3e6ae
11862
sqflite: 6d358c025f5b867b29ed92fc697fd34924e11904
11963
url_launcher: 6fef411d543ceb26efce54b05a0a40bfd74cbbef
120-
url_launcher_linux: ac237cb7a8058736e4aae38bdbcc748a4b394cc0
121-
url_launcher_macos: fd7894421cd39320dce5f292fc99ea9270b2a313
122-
url_launcher_web: e5527357f037c87560776e36436bf2b0288b965c
123-
url_launcher_windows: 683d7c283894db8d1914d3ab2223b20cc1ad95d5
12464

125-
PODFILE CHECKSUM: c34e2287a9ccaa606aeceab922830efb9a6ff69a
65+
PODFILE CHECKSUM: aafe91acc616949ddb318b77800a7f51bffa2a4c
12666

12767
COCOAPODS: 1.10.0

‎ios/Runner.xcodeproj/project.xcworkspace/contents.xcworkspacedata‎

Lines changed: 1 addition & 1 deletion
Some generated files are not rendered by default. Learn more about customizing how changed files appear on GitHub.

‎ios/Runner/Info.plist‎

Lines changed: 5 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -39,5 +39,10 @@
3939
</array>
4040
<key>UIViewControllerBasedStatusBarAppearance</key>
4141
<false/>
42+
<key>CFBundleLocalizations</key>
43+
<array>
44+
<string>en</string>
45+
<string>tr</string>
46+
</array>
4247
</dict>
4348
</plist>

‎lib/core/base/model/base_model.dart‎

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -1,4 +1,4 @@
11
abstract class BaseModel<T> {
2-
Map<String, Object> toJson();
2+
Map<String, Object?> toJson();
33
T fromJson(Map<String, Object> json);
44
}

‎lib/core/base/model/base_view_model.dart‎

Lines changed: 3 additions & 3 deletions
Original file line numberDiff line numberDiff line change
@@ -7,10 +7,10 @@ import '../../init/network/network_manager.dart';
77
import '../../init/network/vexana_manager.dart';
88

99
abstract class BaseViewModel {
10-
BuildContext context;
10+
BuildContext? context;
1111

12-
ICoreDio coreDio = NetworkManager.instance.coreDio;
13-
VexanaManager vexanaManager = VexanaManager.instance;
12+
ICoreDioNullSafety? coreDio = NetworkManager.instance!.coreDio;
13+
VexanaManager? vexanaManager = VexanaManager.instance;
1414
LocaleManager localeManager = LocaleManager.instance;
1515
NavigationService navigation = NavigationService.instance;
1616

‎lib/core/base/view/base_widget.dart‎

Lines changed: 4 additions & 10 deletions
Original file line numberDiff line numberDiff line change
@@ -5,22 +5,16 @@ class BaseView<T extends Store> extends StatefulWidget {
55
final Widget Function(BuildContext context, T value) onPageBuilder;
66
final T viewModel;
77
final Function(T model) onModelReady;
8-
final VoidCallback onDispose;
8+
final VoidCallback? onDispose;
99

10-
const BaseView(
11-
{Key key,
12-
@required this.viewModel,
13-
@required this.onPageBuilder,
14-
this.onModelReady,
15-
this.onDispose})
16-
: super(key: key);
10+
const BaseView({Key? key, required this.viewModel, required this.onPageBuilder, required this.onModelReady, this.onDispose}) : super(key: key);
1711

1812
@override
1913
_BaseViewState<T> createState() => _BaseViewState<T>();
2014
}
2115

2216
class _BaseViewState<T extends Store> extends State<BaseView<T>> {
23-
T model;
17+
lateT model;
2418
@override
2519
void initState() {
2620
model = widget.viewModel;
@@ -31,7 +25,7 @@ class _BaseViewState<T extends Store> extends State<BaseView<T>> {
3125
@override
3226
void dispose() {
3327
super.dispose();
34-
if (widget.onDispose != null) widget.onDispose();
28+
if (widget.onDispose != null) widget.onDispose!();
3529
}
3630

3731
@override

‎lib/core/components/button/icon_button.dart‎

Lines changed: 2 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -3,10 +3,10 @@ import 'package:flutter/material.dart';
33
import 'normal_button.dart';
44

55
class IconNormalButton extends StatelessWidget {
6-
final VoidCallback onPressed;
6+
final VoidCallback? onPressed;
77
final IconData icon;
88

9-
const IconNormalButton({Key key, this.onPressed, @required this.icon}) : super(key: key);
9+
const IconNormalButton({Key? key, this.onPressed, required this.icon}) : super(key: key);
1010
@override
1111
Widget build(BuildContext context) {
1212
return NormalButton(
Lines changed: 16 additions & 6 deletions
Original file line numberDiff line numberDiff line change
@@ -1,18 +1,28 @@
11
import 'package:flutter/material.dart';
22

33
class NormalButton extends StatelessWidget {
4-
final Widget child;
4+
final Widget? child;
55

6-
final VoidCallback onPressed;
6+
final VoidCallback? onPressed;
77

8-
const NormalButton({Key key, this.child, this.onPressed}) : super(key: key);
8+
const NormalButton({Key? key, this.child, this.onPressed}) : super(key: key);
99
@override
1010
Widget build(BuildContext context) {
11-
return RaisedButton(
12-
padding: EdgeInsets.all(15),
13-
elevation: 10,
11+
return ElevatedButton(
12+
style: ButtonStyle(
13+
padding: MaterialStateProperty.all(EdgeInsets.all(15)),
14+
elevation: MaterialStateProperty.all(10),
15+
),
1416
onPressed: onPressed,
1517
child: child,
1618
);
1719
}
1820
}
21+
22+
// BEFORE: NULL SAFETY
23+
// return RaisedButton(
24+
// padding: EdgeInsets.all(15),
25+
// elevation: 10,
26+
// onPressed: onPressed,
27+
// child: child,
28+
// );

‎lib/core/components/button/title_text_button.dart‎

Lines changed: 2 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -3,10 +3,10 @@ import 'package:flutter/material.dart';
33
import 'normal_button.dart';
44

55
class TitleTextButton extends StatelessWidget {
6-
final VoidCallback onPressed;
6+
final VoidCallback? onPressed;
77
final String text;
88

9-
const TitleTextButton({Key key, this.onPressed, @required this.text}) : super(key: key);
9+
const TitleTextButton({Key? key, this.onPressed, required this.text}) : super(key: key);
1010
@override
1111
Widget build(BuildContext context) {
1212
return NormalButton(

0 commit comments

Comments
(0)

AltStyle によって変換されたページ (->オリジナル) /