Brought project up to date with modern Flutter
This commit is contained in:
parent
5b82d2e219
commit
7111f2865e
19 changed files with 235 additions and 188 deletions
1
.gitignore
vendored
1
.gitignore
vendored
|
@ -24,6 +24,7 @@
|
||||||
**/doc/api/
|
**/doc/api/
|
||||||
.dart_tool/
|
.dart_tool/
|
||||||
.flutter-plugins
|
.flutter-plugins
|
||||||
|
.flutter-plugins-dependencies
|
||||||
.packages
|
.packages
|
||||||
.pub-cache/
|
.pub-cache/
|
||||||
.pub/
|
.pub/
|
||||||
|
|
37
.vscode/launch.json
vendored
Normal file
37
.vscode/launch.json
vendored
Normal file
|
@ -0,0 +1,37 @@
|
||||||
|
{
|
||||||
|
// Use IntelliSense to learn about possible attributes.
|
||||||
|
// Hover to view descriptions of existing attributes.
|
||||||
|
// For more information, visit: https://go.microsoft.com/fwlink/?linkid=830387
|
||||||
|
"version": "0.2.0",
|
||||||
|
"configurations": [
|
||||||
|
{
|
||||||
|
"name": "Current Device",
|
||||||
|
"request": "launch",
|
||||||
|
"type": "dart"
|
||||||
|
},
|
||||||
|
{
|
||||||
|
"name": "info_tren (profile mode)",
|
||||||
|
"request": "launch",
|
||||||
|
"type": "dart",
|
||||||
|
"flutterMode": "profile"
|
||||||
|
},
|
||||||
|
{
|
||||||
|
"name": "Android Emulator",
|
||||||
|
"request": "launch",
|
||||||
|
"type": "dart",
|
||||||
|
"deviceId": "sdk gphone"
|
||||||
|
},
|
||||||
|
{
|
||||||
|
"name": "iPhone",
|
||||||
|
"request": "launch",
|
||||||
|
"type": "dart",
|
||||||
|
"deviceId": "iphone"
|
||||||
|
}
|
||||||
|
],
|
||||||
|
"compounds": [
|
||||||
|
{
|
||||||
|
"name": "All Devices",
|
||||||
|
"configurations": ["Android Emulator", "iPhone"]
|
||||||
|
}
|
||||||
|
]
|
||||||
|
}
|
|
@ -9,7 +9,6 @@
|
||||||
additional functionality it is fine to subclass or reimplement
|
additional functionality it is fine to subclass or reimplement
|
||||||
FlutterApplication and put your custom class here. -->
|
FlutterApplication and put your custom class here. -->
|
||||||
<application
|
<application
|
||||||
android:name="io.flutter.app.FlutterApplication"
|
|
||||||
android:label="Info Tren"
|
android:label="Info Tren"
|
||||||
android:icon="@mipmap/ic_launcher">
|
android:icon="@mipmap/ic_launcher">
|
||||||
<activity
|
<activity
|
||||||
|
@ -20,17 +19,22 @@
|
||||||
android:hardwareAccelerated="true"
|
android:hardwareAccelerated="true"
|
||||||
android:windowSoftInputMode="adjustResize"
|
android:windowSoftInputMode="adjustResize"
|
||||||
android:screenOrientation="portrait">
|
android:screenOrientation="portrait">
|
||||||
|
<!-- Specify that the launch screen should continue being displayed -->
|
||||||
|
<!-- until Flutter renders its first frame. -->
|
||||||
|
<meta-data
|
||||||
|
android:name="io.flutter.embedding.android.SplashScreenDrawable"
|
||||||
|
android:resource="@drawable/launch_background" />
|
||||||
<!-- This keeps the window background of the activity showing
|
<!-- This keeps the window background of the activity showing
|
||||||
until Flutter renders its first frame. It can be removed if
|
until Flutter renders its first frame. It can be removed if
|
||||||
there is no splash screen (such as the default splash screen
|
there is no splash screen (such as the default splash screen
|
||||||
defined in @style/LaunchTheme). -->
|
defined in @style/LaunchTheme). -->
|
||||||
<meta-data
|
|
||||||
android:name="io.flutter.app.android.SplashScreenUntilFirstFrame"
|
|
||||||
android:value="true" />
|
|
||||||
<intent-filter>
|
<intent-filter>
|
||||||
<action android:name="android.intent.action.MAIN"/>
|
<action android:name="android.intent.action.MAIN"/>
|
||||||
<category android:name="android.intent.category.LAUNCHER"/>
|
<category android:name="android.intent.category.LAUNCHER"/>
|
||||||
</intent-filter>
|
</intent-filter>
|
||||||
</activity>
|
</activity>
|
||||||
|
<meta-data
|
||||||
|
android:name="flutterEmbedding"
|
||||||
|
android:value="2" />
|
||||||
</application>
|
</application>
|
||||||
</manifest>
|
</manifest>
|
||||||
|
|
|
@ -1,13 +1,6 @@
|
||||||
package ml.dandevelop.info_tren
|
package ml.dandevelop.info_tren
|
||||||
|
|
||||||
import android.os.Bundle
|
import io.flutter.embedding.android.FlutterActivity
|
||||||
|
|
||||||
import io.flutter.app.FlutterActivity
|
|
||||||
import io.flutter.plugins.GeneratedPluginRegistrant
|
|
||||||
|
|
||||||
class MainActivity: FlutterActivity() {
|
class MainActivity: FlutterActivity() {
|
||||||
override fun onCreate(savedInstanceState: Bundle?) {
|
|
||||||
super.onCreate(savedInstanceState)
|
|
||||||
GeneratedPluginRegistrant.registerWith(this)
|
|
||||||
}
|
|
||||||
}
|
}
|
||||||
|
|
18
ios/Flutter/Flutter.podspec
Normal file
18
ios/Flutter/Flutter.podspec
Normal file
|
@ -0,0 +1,18 @@
|
||||||
|
#
|
||||||
|
# NOTE: This podspec is NOT to be published. It is only used as a local source!
|
||||||
|
# This is a generated file; do not edit or check into version control.
|
||||||
|
#
|
||||||
|
|
||||||
|
Pod::Spec.new do |s|
|
||||||
|
s.name = 'Flutter'
|
||||||
|
s.version = '1.0.0'
|
||||||
|
s.summary = 'High-performance, high-fidelity mobile apps.'
|
||||||
|
s.homepage = 'https://flutter.io'
|
||||||
|
s.license = { :type => 'MIT' }
|
||||||
|
s.author = { 'Flutter Dev Team' => 'flutter-dev@googlegroups.com' }
|
||||||
|
s.source = { :git => 'https://github.com/flutter/engine', :tag => s.version.to_s }
|
||||||
|
s.ios.deployment_target = '8.0'
|
||||||
|
# Framework linking is handled by Flutter tooling, not CocoaPods.
|
||||||
|
# Add a placeholder to satisfy `s.dependency 'Flutter'` plugin podspecs.
|
||||||
|
s.vendored_frameworks = 'path/to/nothing'
|
||||||
|
end
|
15
ios/Flutter/flutter_export_environment.sh
Executable file
15
ios/Flutter/flutter_export_environment.sh
Executable file
|
@ -0,0 +1,15 @@
|
||||||
|
#!/bin/sh
|
||||||
|
# This is a generated file; do not edit or check into version control.
|
||||||
|
export "FLUTTER_ROOT=/usr/local/Caskroom/flutter/2.2.3/flutter"
|
||||||
|
export "FLUTTER_APPLICATION_PATH=/Users/dan.cojocaru/info_tren"
|
||||||
|
export "COCOAPODS_PARALLEL_CODE_SIGN=true"
|
||||||
|
export "FLUTTER_TARGET=/Users/dan.cojocaru/info_tren/lib/main.dart"
|
||||||
|
export "FLUTTER_BUILD_DIR=build"
|
||||||
|
export "SYMROOT=${SOURCE_ROOT}/../build/ios"
|
||||||
|
export "FLUTTER_BUILD_NAME=2.0.6"
|
||||||
|
export "FLUTTER_BUILD_NUMBER=2.0.6"
|
||||||
|
export "DART_DEFINES=Zmx1dHRlci5pbnNwZWN0b3Iuc3RydWN0dXJlZEVycm9ycz10cnVl,RkxVVFRFUl9XRUJfQVVUT19ERVRFQ1Q9dHJ1ZQ=="
|
||||||
|
export "DART_OBFUSCATION=false"
|
||||||
|
export "TRACK_WIDGET_CREATION=true"
|
||||||
|
export "TREE_SHAKE_ICONS=false"
|
||||||
|
export "PACKAGE_CONFIG=/Users/dan.cojocaru/info_tren/.dart_tool/package_config.json"
|
67
ios/Podfile
67
ios/Podfile
|
@ -10,65 +10,32 @@ project 'Runner', {
|
||||||
'Release' => :release,
|
'Release' => :release,
|
||||||
}
|
}
|
||||||
|
|
||||||
def parse_KV_file(file, separator='=')
|
def flutter_root
|
||||||
file_abs_path = File.expand_path(file)
|
generated_xcode_build_settings_path = File.expand_path(File.join('..', 'Flutter', 'Generated.xcconfig'), __FILE__)
|
||||||
if !File.exists? file_abs_path
|
unless File.exist?(generated_xcode_build_settings_path)
|
||||||
return [];
|
raise "#{generated_xcode_build_settings_path} must exist. If you're running pod install manually, make sure flutter pub get is executed first"
|
||||||
end
|
end
|
||||||
pods_ary = []
|
|
||||||
skip_line_start_symbols = ["#", "/"]
|
File.foreach(generated_xcode_build_settings_path) do |line|
|
||||||
File.foreach(file_abs_path) { |line|
|
matches = line.match(/FLUTTER_ROOT\=(.*)/)
|
||||||
next if skip_line_start_symbols.any? { |symbol| line =~ /^\s*#{symbol}/ }
|
return matches[1].strip if matches
|
||||||
plugin = line.split(pattern=separator)
|
end
|
||||||
if plugin.length == 2
|
raise "FLUTTER_ROOT not found in #{generated_xcode_build_settings_path}. Try deleting Generated.xcconfig, then run flutter pub get"
|
||||||
podname = plugin[0].strip()
|
|
||||||
path = plugin[1].strip()
|
|
||||||
podpath = File.expand_path("#{path}", file_abs_path)
|
|
||||||
pods_ary.push({:name => podname, :path => podpath});
|
|
||||||
else
|
|
||||||
puts "Invalid plugin specification: #{line}"
|
|
||||||
end
|
|
||||||
}
|
|
||||||
return pods_ary
|
|
||||||
end
|
end
|
||||||
|
|
||||||
|
require File.expand_path(File.join('packages', 'flutter_tools', 'bin', 'podhelper'), flutter_root)
|
||||||
|
|
||||||
|
flutter_ios_podfile_setup
|
||||||
|
|
||||||
target 'Runner' do
|
target 'Runner' do
|
||||||
use_frameworks!
|
use_frameworks!
|
||||||
|
use_modular_headers!
|
||||||
|
|
||||||
# Prepare symlinks folder. We use symlinks to avoid having Podfile.lock
|
flutter_install_all_ios_pods File.dirname(File.realpath(__FILE__))
|
||||||
# referring to absolute paths on developers' machines.
|
|
||||||
system('rm -rf .symlinks')
|
|
||||||
system('mkdir -p .symlinks/plugins')
|
|
||||||
|
|
||||||
# Flutter Pods
|
|
||||||
generated_xcode_build_settings = parse_KV_file('./Flutter/Generated.xcconfig')
|
|
||||||
if generated_xcode_build_settings.empty?
|
|
||||||
puts "Generated.xcconfig must exist. If you're running pod install manually, make sure flutter pub get is executed first."
|
|
||||||
end
|
|
||||||
generated_xcode_build_settings.map { |p|
|
|
||||||
if p[:name] == 'FLUTTER_FRAMEWORK_DIR'
|
|
||||||
symlink = File.join('.symlinks', 'flutter')
|
|
||||||
File.symlink(File.dirname(p[:path]), symlink)
|
|
||||||
pod 'Flutter', :path => File.join(symlink, File.basename(p[:path]))
|
|
||||||
end
|
|
||||||
}
|
|
||||||
|
|
||||||
# Plugin Pods
|
|
||||||
plugin_pods = parse_KV_file('../.flutter-plugins')
|
|
||||||
plugin_pods.map { |p|
|
|
||||||
symlink = File.join('.symlinks', 'plugins', p[:name])
|
|
||||||
File.symlink(p[:path], symlink)
|
|
||||||
pod p[:name], :path => File.join(symlink, 'ios')
|
|
||||||
}
|
|
||||||
end
|
end
|
||||||
|
|
||||||
# Prevent Cocoapods from embedding a second Flutter framework and causing an error with the new Xcode build system.
|
|
||||||
install! 'cocoapods', :disable_input_output_paths => true
|
|
||||||
|
|
||||||
post_install do |installer|
|
post_install do |installer|
|
||||||
installer.pods_project.targets.each do |target|
|
installer.pods_project.targets.each do |target|
|
||||||
target.build_configurations.each do |config|
|
flutter_additional_ios_build_settings(target)
|
||||||
config.build_settings['ENABLE_BITCODE'] = 'NO'
|
|
||||||
end
|
|
||||||
end
|
end
|
||||||
end
|
end
|
||||||
|
|
|
@ -4,19 +4,19 @@ PODS:
|
||||||
- Flutter
|
- Flutter
|
||||||
|
|
||||||
DEPENDENCIES:
|
DEPENDENCIES:
|
||||||
- Flutter (from `.symlinks/flutter/ios-release`)
|
- Flutter (from `Flutter`)
|
||||||
- webview_flutter (from `.symlinks/plugins/webview_flutter/ios`)
|
- webview_flutter (from `.symlinks/plugins/webview_flutter/ios`)
|
||||||
|
|
||||||
EXTERNAL SOURCES:
|
EXTERNAL SOURCES:
|
||||||
Flutter:
|
Flutter:
|
||||||
:path: ".symlinks/flutter/ios-release"
|
:path: Flutter
|
||||||
webview_flutter:
|
webview_flutter:
|
||||||
:path: ".symlinks/plugins/webview_flutter/ios"
|
:path: ".symlinks/plugins/webview_flutter/ios"
|
||||||
|
|
||||||
SPEC CHECKSUMS:
|
SPEC CHECKSUMS:
|
||||||
Flutter: 58dd7d1b27887414a370fcccb9e645c08ffd7a6a
|
Flutter: 434fef37c0980e73bb6479ef766c45957d4b510c
|
||||||
webview_flutter: 1aa7604e6cdb451a9b7ed2c37d5454c0b440246b
|
webview_flutter: 1aa7604e6cdb451a9b7ed2c37d5454c0b440246b
|
||||||
|
|
||||||
PODFILE CHECKSUM: b6a0a141693093b304368d08511b46cf3d1d0ac5
|
PODFILE CHECKSUM: aafe91acc616949ddb318b77800a7f51bffa2a4c
|
||||||
|
|
||||||
COCOAPODS: 1.6.1
|
COCOAPODS: 1.10.1
|
||||||
|
|
|
@ -9,12 +9,8 @@
|
||||||
/* Begin PBXBuildFile section */
|
/* Begin PBXBuildFile section */
|
||||||
1498D2341E8E89220040F4C2 /* GeneratedPluginRegistrant.m in Sources */ = {isa = PBXBuildFile; fileRef = 1498D2331E8E89220040F4C2 /* GeneratedPluginRegistrant.m */; };
|
1498D2341E8E89220040F4C2 /* GeneratedPluginRegistrant.m in Sources */ = {isa = PBXBuildFile; fileRef = 1498D2331E8E89220040F4C2 /* GeneratedPluginRegistrant.m */; };
|
||||||
3B3967161E833CAA004F5970 /* AppFrameworkInfo.plist in Resources */ = {isa = PBXBuildFile; fileRef = 3B3967151E833CAA004F5970 /* AppFrameworkInfo.plist */; };
|
3B3967161E833CAA004F5970 /* AppFrameworkInfo.plist in Resources */ = {isa = PBXBuildFile; fileRef = 3B3967151E833CAA004F5970 /* AppFrameworkInfo.plist */; };
|
||||||
3B80C3941E831B6300D905FE /* App.framework in Frameworks */ = {isa = PBXBuildFile; fileRef = 3B80C3931E831B6300D905FE /* App.framework */; };
|
|
||||||
3B80C3951E831B6300D905FE /* App.framework in Embed Frameworks */ = {isa = PBXBuildFile; fileRef = 3B80C3931E831B6300D905FE /* App.framework */; settings = {ATTRIBUTES = (CodeSignOnCopy, RemoveHeadersOnCopy, ); }; };
|
|
||||||
722F441253D3B79676E4DE80 /* Pods_Runner.framework in Frameworks */ = {isa = PBXBuildFile; fileRef = F72320B12B1F4015789BBC8E /* Pods_Runner.framework */; };
|
722F441253D3B79676E4DE80 /* Pods_Runner.framework in Frameworks */ = {isa = PBXBuildFile; fileRef = F72320B12B1F4015789BBC8E /* Pods_Runner.framework */; };
|
||||||
74858FAF1ED2DC5600515810 /* AppDelegate.swift in Sources */ = {isa = PBXBuildFile; fileRef = 74858FAE1ED2DC5600515810 /* AppDelegate.swift */; };
|
74858FAF1ED2DC5600515810 /* AppDelegate.swift in Sources */ = {isa = PBXBuildFile; fileRef = 74858FAE1ED2DC5600515810 /* AppDelegate.swift */; };
|
||||||
9705A1C61CF904A100538489 /* Flutter.framework in Frameworks */ = {isa = PBXBuildFile; fileRef = 9740EEBA1CF902C7004384FC /* Flutter.framework */; };
|
|
||||||
9705A1C71CF904A300538489 /* Flutter.framework in Embed Frameworks */ = {isa = PBXBuildFile; fileRef = 9740EEBA1CF902C7004384FC /* Flutter.framework */; settings = {ATTRIBUTES = (CodeSignOnCopy, RemoveHeadersOnCopy, ); }; };
|
|
||||||
9740EEB41CF90195004384FC /* Debug.xcconfig in Resources */ = {isa = PBXBuildFile; fileRef = 9740EEB21CF90195004384FC /* Debug.xcconfig */; };
|
9740EEB41CF90195004384FC /* Debug.xcconfig in Resources */ = {isa = PBXBuildFile; fileRef = 9740EEB21CF90195004384FC /* Debug.xcconfig */; };
|
||||||
97C146FC1CF9000F007C117D /* Main.storyboard in Resources */ = {isa = PBXBuildFile; fileRef = 97C146FA1CF9000F007C117D /* Main.storyboard */; };
|
97C146FC1CF9000F007C117D /* Main.storyboard in Resources */ = {isa = PBXBuildFile; fileRef = 97C146FA1CF9000F007C117D /* Main.storyboard */; };
|
||||||
97C146FE1CF9000F007C117D /* Assets.xcassets in Resources */ = {isa = PBXBuildFile; fileRef = 97C146FD1CF9000F007C117D /* Assets.xcassets */; };
|
97C146FE1CF9000F007C117D /* Assets.xcassets in Resources */ = {isa = PBXBuildFile; fileRef = 97C146FD1CF9000F007C117D /* Assets.xcassets */; };
|
||||||
|
@ -28,8 +24,6 @@
|
||||||
dstPath = "";
|
dstPath = "";
|
||||||
dstSubfolderSpec = 10;
|
dstSubfolderSpec = 10;
|
||||||
files = (
|
files = (
|
||||||
3B80C3951E831B6300D905FE /* App.framework in Embed Frameworks */,
|
|
||||||
9705A1C71CF904A300538489 /* Flutter.framework in Embed Frameworks */,
|
|
||||||
);
|
);
|
||||||
name = "Embed Frameworks";
|
name = "Embed Frameworks";
|
||||||
runOnlyForDeploymentPostprocessing = 0;
|
runOnlyForDeploymentPostprocessing = 0;
|
||||||
|
@ -41,7 +35,6 @@
|
||||||
1498D2331E8E89220040F4C2 /* GeneratedPluginRegistrant.m */ = {isa = PBXFileReference; fileEncoding = 4; lastKnownFileType = sourcecode.c.objc; path = GeneratedPluginRegistrant.m; sourceTree = "<group>"; };
|
1498D2331E8E89220040F4C2 /* GeneratedPluginRegistrant.m */ = {isa = PBXFileReference; fileEncoding = 4; lastKnownFileType = sourcecode.c.objc; path = GeneratedPluginRegistrant.m; sourceTree = "<group>"; };
|
||||||
313F1E773DA06364A0C4F20A /* Pods-Runner.debug.xcconfig */ = {isa = PBXFileReference; includeInIndex = 1; lastKnownFileType = text.xcconfig; name = "Pods-Runner.debug.xcconfig"; path = "Target Support Files/Pods-Runner/Pods-Runner.debug.xcconfig"; sourceTree = "<group>"; };
|
313F1E773DA06364A0C4F20A /* Pods-Runner.debug.xcconfig */ = {isa = PBXFileReference; includeInIndex = 1; lastKnownFileType = text.xcconfig; name = "Pods-Runner.debug.xcconfig"; path = "Target Support Files/Pods-Runner/Pods-Runner.debug.xcconfig"; sourceTree = "<group>"; };
|
||||||
3B3967151E833CAA004F5970 /* AppFrameworkInfo.plist */ = {isa = PBXFileReference; fileEncoding = 4; lastKnownFileType = text.plist.xml; name = AppFrameworkInfo.plist; path = Flutter/AppFrameworkInfo.plist; sourceTree = "<group>"; };
|
3B3967151E833CAA004F5970 /* AppFrameworkInfo.plist */ = {isa = PBXFileReference; fileEncoding = 4; lastKnownFileType = text.plist.xml; name = AppFrameworkInfo.plist; path = Flutter/AppFrameworkInfo.plist; sourceTree = "<group>"; };
|
||||||
3B80C3931E831B6300D905FE /* App.framework */ = {isa = PBXFileReference; lastKnownFileType = wrapper.framework; name = App.framework; path = Flutter/App.framework; sourceTree = "<group>"; };
|
|
||||||
636963D381657D3BAEDC0A47 /* Pods-Runner.profile.xcconfig */ = {isa = PBXFileReference; includeInIndex = 1; lastKnownFileType = text.xcconfig; name = "Pods-Runner.profile.xcconfig"; path = "Target Support Files/Pods-Runner/Pods-Runner.profile.xcconfig"; sourceTree = "<group>"; };
|
636963D381657D3BAEDC0A47 /* Pods-Runner.profile.xcconfig */ = {isa = PBXFileReference; includeInIndex = 1; lastKnownFileType = text.xcconfig; name = "Pods-Runner.profile.xcconfig"; path = "Target Support Files/Pods-Runner/Pods-Runner.profile.xcconfig"; sourceTree = "<group>"; };
|
||||||
74858FAD1ED2DC5600515810 /* Runner-Bridging-Header.h */ = {isa = PBXFileReference; lastKnownFileType = sourcecode.c.h; path = "Runner-Bridging-Header.h"; sourceTree = "<group>"; };
|
74858FAD1ED2DC5600515810 /* Runner-Bridging-Header.h */ = {isa = PBXFileReference; lastKnownFileType = sourcecode.c.h; path = "Runner-Bridging-Header.h"; sourceTree = "<group>"; };
|
||||||
74858FAE1ED2DC5600515810 /* AppDelegate.swift */ = {isa = PBXFileReference; fileEncoding = 4; lastKnownFileType = sourcecode.swift; path = AppDelegate.swift; sourceTree = "<group>"; };
|
74858FAE1ED2DC5600515810 /* AppDelegate.swift */ = {isa = PBXFileReference; fileEncoding = 4; lastKnownFileType = sourcecode.swift; path = AppDelegate.swift; sourceTree = "<group>"; };
|
||||||
|
@ -49,7 +42,6 @@
|
||||||
7AFA3C8E1D35360C0083082E /* Release.xcconfig */ = {isa = PBXFileReference; lastKnownFileType = text.xcconfig; name = Release.xcconfig; path = Flutter/Release.xcconfig; sourceTree = "<group>"; };
|
7AFA3C8E1D35360C0083082E /* Release.xcconfig */ = {isa = PBXFileReference; lastKnownFileType = text.xcconfig; name = Release.xcconfig; path = Flutter/Release.xcconfig; sourceTree = "<group>"; };
|
||||||
9740EEB21CF90195004384FC /* Debug.xcconfig */ = {isa = PBXFileReference; fileEncoding = 4; lastKnownFileType = text.xcconfig; name = Debug.xcconfig; path = Flutter/Debug.xcconfig; sourceTree = "<group>"; };
|
9740EEB21CF90195004384FC /* Debug.xcconfig */ = {isa = PBXFileReference; fileEncoding = 4; lastKnownFileType = text.xcconfig; name = Debug.xcconfig; path = Flutter/Debug.xcconfig; sourceTree = "<group>"; };
|
||||||
9740EEB31CF90195004384FC /* Generated.xcconfig */ = {isa = PBXFileReference; fileEncoding = 4; lastKnownFileType = text.xcconfig; name = Generated.xcconfig; path = Flutter/Generated.xcconfig; sourceTree = "<group>"; };
|
9740EEB31CF90195004384FC /* Generated.xcconfig */ = {isa = PBXFileReference; fileEncoding = 4; lastKnownFileType = text.xcconfig; name = Generated.xcconfig; path = Flutter/Generated.xcconfig; sourceTree = "<group>"; };
|
||||||
9740EEBA1CF902C7004384FC /* Flutter.framework */ = {isa = PBXFileReference; lastKnownFileType = wrapper.framework; name = Flutter.framework; path = Flutter/Flutter.framework; sourceTree = "<group>"; };
|
|
||||||
97C146EE1CF9000F007C117D /* Runner.app */ = {isa = PBXFileReference; explicitFileType = wrapper.application; includeInIndex = 0; path = Runner.app; sourceTree = BUILT_PRODUCTS_DIR; };
|
97C146EE1CF9000F007C117D /* Runner.app */ = {isa = PBXFileReference; explicitFileType = wrapper.application; includeInIndex = 0; path = Runner.app; sourceTree = BUILT_PRODUCTS_DIR; };
|
||||||
97C146FB1CF9000F007C117D /* Base */ = {isa = PBXFileReference; lastKnownFileType = file.storyboard; name = Base; path = Base.lproj/Main.storyboard; sourceTree = "<group>"; };
|
97C146FB1CF9000F007C117D /* Base */ = {isa = PBXFileReference; lastKnownFileType = file.storyboard; name = Base; path = Base.lproj/Main.storyboard; sourceTree = "<group>"; };
|
||||||
97C146FD1CF9000F007C117D /* Assets.xcassets */ = {isa = PBXFileReference; lastKnownFileType = folder.assetcatalog; path = Assets.xcassets; sourceTree = "<group>"; };
|
97C146FD1CF9000F007C117D /* Assets.xcassets */ = {isa = PBXFileReference; lastKnownFileType = folder.assetcatalog; path = Assets.xcassets; sourceTree = "<group>"; };
|
||||||
|
@ -63,8 +55,6 @@
|
||||||
isa = PBXFrameworksBuildPhase;
|
isa = PBXFrameworksBuildPhase;
|
||||||
buildActionMask = 2147483647;
|
buildActionMask = 2147483647;
|
||||||
files = (
|
files = (
|
||||||
9705A1C61CF904A100538489 /* Flutter.framework in Frameworks */,
|
|
||||||
3B80C3941E831B6300D905FE /* App.framework in Frameworks */,
|
|
||||||
722F441253D3B79676E4DE80 /* Pods_Runner.framework in Frameworks */,
|
722F441253D3B79676E4DE80 /* Pods_Runner.framework in Frameworks */,
|
||||||
);
|
);
|
||||||
runOnlyForDeploymentPostprocessing = 0;
|
runOnlyForDeploymentPostprocessing = 0;
|
||||||
|
@ -83,9 +73,7 @@
|
||||||
9740EEB11CF90186004384FC /* Flutter */ = {
|
9740EEB11CF90186004384FC /* Flutter */ = {
|
||||||
isa = PBXGroup;
|
isa = PBXGroup;
|
||||||
children = (
|
children = (
|
||||||
3B80C3931E831B6300D905FE /* App.framework */,
|
|
||||||
3B3967151E833CAA004F5970 /* AppFrameworkInfo.plist */,
|
3B3967151E833CAA004F5970 /* AppFrameworkInfo.plist */,
|
||||||
9740EEBA1CF902C7004384FC /* Flutter.framework */,
|
|
||||||
9740EEB21CF90195004384FC /* Debug.xcconfig */,
|
9740EEB21CF90195004384FC /* Debug.xcconfig */,
|
||||||
7AFA3C8E1D35360C0083082E /* Release.xcconfig */,
|
7AFA3C8E1D35360C0083082E /* Release.xcconfig */,
|
||||||
9740EEB31CF90195004384FC /* Generated.xcconfig */,
|
9740EEB31CF90195004384FC /* Generated.xcconfig */,
|
||||||
|
@ -248,14 +236,13 @@
|
||||||
buildActionMask = 2147483647;
|
buildActionMask = 2147483647;
|
||||||
files = (
|
files = (
|
||||||
);
|
);
|
||||||
inputFileListPaths = (
|
|
||||||
);
|
|
||||||
inputPaths = (
|
inputPaths = (
|
||||||
|
"${PODS_ROOT}/Target Support Files/Pods-Runner/Pods-Runner-frameworks.sh",
|
||||||
|
"${BUILT_PRODUCTS_DIR}/webview_flutter/webview_flutter.framework",
|
||||||
);
|
);
|
||||||
name = "[CP] Embed Pods Frameworks";
|
name = "[CP] Embed Pods Frameworks";
|
||||||
outputFileListPaths = (
|
|
||||||
);
|
|
||||||
outputPaths = (
|
outputPaths = (
|
||||||
|
"${TARGET_BUILD_DIR}/${FRAMEWORKS_FOLDER_PATH}/webview_flutter.framework",
|
||||||
);
|
);
|
||||||
runOnlyForDeploymentPostprocessing = 0;
|
runOnlyForDeploymentPostprocessing = 0;
|
||||||
shellPath = /bin/sh;
|
shellPath = /bin/sh;
|
||||||
|
@ -274,7 +261,7 @@
|
||||||
);
|
);
|
||||||
runOnlyForDeploymentPostprocessing = 0;
|
runOnlyForDeploymentPostprocessing = 0;
|
||||||
shellPath = /bin/sh;
|
shellPath = /bin/sh;
|
||||||
shellScript = "/bin/sh \"$FLUTTER_ROOT/packages/flutter_tools/bin/xcode_backend.sh\" thin";
|
shellScript = "/bin/sh \"$FLUTTER_ROOT/packages/flutter_tools/bin/xcode_backend.sh\" embed_and_thin";
|
||||||
};
|
};
|
||||||
9740EEB61CF901F6004384FC /* Run Script */ = {
|
9740EEB61CF901F6004384FC /* Run Script */ = {
|
||||||
isa = PBXShellScriptBuildPhase;
|
isa = PBXShellScriptBuildPhase;
|
||||||
|
@ -326,7 +313,6 @@
|
||||||
/* Begin XCBuildConfiguration section */
|
/* Begin XCBuildConfiguration section */
|
||||||
249021D3217E4FDB00AE95B9 /* Profile */ = {
|
249021D3217E4FDB00AE95B9 /* Profile */ = {
|
||||||
isa = XCBuildConfiguration;
|
isa = XCBuildConfiguration;
|
||||||
baseConfigurationReference = 7AFA3C8E1D35360C0083082E /* Release.xcconfig */;
|
|
||||||
buildSettings = {
|
buildSettings = {
|
||||||
ALWAYS_SEARCH_USER_PATHS = NO;
|
ALWAYS_SEARCH_USER_PATHS = NO;
|
||||||
CLANG_ANALYZER_NONNULL = YES;
|
CLANG_ANALYZER_NONNULL = YES;
|
||||||
|
@ -406,7 +392,6 @@
|
||||||
};
|
};
|
||||||
97C147031CF9000F007C117D /* Debug */ = {
|
97C147031CF9000F007C117D /* Debug */ = {
|
||||||
isa = XCBuildConfiguration;
|
isa = XCBuildConfiguration;
|
||||||
baseConfigurationReference = 9740EEB21CF90195004384FC /* Debug.xcconfig */;
|
|
||||||
buildSettings = {
|
buildSettings = {
|
||||||
ALWAYS_SEARCH_USER_PATHS = NO;
|
ALWAYS_SEARCH_USER_PATHS = NO;
|
||||||
CLANG_ANALYZER_NONNULL = YES;
|
CLANG_ANALYZER_NONNULL = YES;
|
||||||
|
@ -462,7 +447,6 @@
|
||||||
};
|
};
|
||||||
97C147041CF9000F007C117D /* Release */ = {
|
97C147041CF9000F007C117D /* Release */ = {
|
||||||
isa = XCBuildConfiguration;
|
isa = XCBuildConfiguration;
|
||||||
baseConfigurationReference = 7AFA3C8E1D35360C0083082E /* Release.xcconfig */;
|
|
||||||
buildSettings = {
|
buildSettings = {
|
||||||
ALWAYS_SEARCH_USER_PATHS = NO;
|
ALWAYS_SEARCH_USER_PATHS = NO;
|
||||||
CLANG_ANALYZER_NONNULL = YES;
|
CLANG_ANALYZER_NONNULL = YES;
|
||||||
|
|
|
@ -2,6 +2,6 @@
|
||||||
<Workspace
|
<Workspace
|
||||||
version = "1.0">
|
version = "1.0">
|
||||||
<FileRef
|
<FileRef
|
||||||
location = "group:Runner.xcodeproj">
|
location = "self:">
|
||||||
</FileRef>
|
</FileRef>
|
||||||
</Workspace>
|
</Workspace>
|
||||||
|
|
|
@ -102,7 +102,7 @@ class MainPageMaterial extends StatelessWidget with MainPageAction {
|
||||||
child: Column(
|
child: Column(
|
||||||
mainAxisSize: MainAxisSize.min,
|
mainAxisSize: MainAxisSize.min,
|
||||||
children: <Widget>[
|
children: <Widget>[
|
||||||
RaisedButton(
|
ElevatedButton(
|
||||||
child: Text(
|
child: Text(
|
||||||
"Informații despre tren",
|
"Informații despre tren",
|
||||||
style: Theme.of(context).textTheme.button.copyWith(fontSize: 18),
|
style: Theme.of(context).textTheme.button.copyWith(fontSize: 18),
|
||||||
|
@ -111,23 +111,27 @@ class MainPageMaterial extends StatelessWidget with MainPageAction {
|
||||||
onTrainInfoPageInvoke(context);
|
onTrainInfoPageInvoke(context);
|
||||||
},
|
},
|
||||||
),
|
),
|
||||||
RaisedButton(
|
ElevatedButton(
|
||||||
child: Text(
|
child: Text(
|
||||||
"Tabelă plecari/sosiri",
|
"Tabelă plecari/sosiri",
|
||||||
style: Theme.of(context).textTheme.button.copyWith(fontSize: 18),
|
style: Theme.of(context).textTheme.button.copyWith(fontSize: 18),
|
||||||
),
|
),
|
||||||
onPressed: () {
|
// TODO: Implement departure/arrival
|
||||||
onStationBoardPageInvoke(context);
|
onPressed: null,
|
||||||
},
|
// onPressed: () {
|
||||||
|
// onStationBoardPageInvoke(context);
|
||||||
|
// },
|
||||||
),
|
),
|
||||||
RaisedButton(
|
ElevatedButton(
|
||||||
child: Text(
|
child: Text(
|
||||||
"Planificare rută",
|
"Planificare rută",
|
||||||
style: Theme.of(context).textTheme.button.copyWith(fontSize: 18),
|
style: Theme.of(context).textTheme.button.copyWith(fontSize: 18),
|
||||||
),
|
),
|
||||||
onPressed: () {
|
// TODO: Implement route planning
|
||||||
onRoutePlanPageInvoke(context);
|
onPressed: null,
|
||||||
},
|
// onPressed: () {
|
||||||
|
// onRoutePlanPageInvoke(context);
|
||||||
|
// },
|
||||||
)
|
)
|
||||||
].map((w) => Padding(
|
].map((w) => Padding(
|
||||||
padding: const EdgeInsets.fromLTRB(4, 2, 4, 2),
|
padding: const EdgeInsets.fromLTRB(4, 2, 4, 2),
|
||||||
|
@ -163,15 +167,19 @@ class MainPageCupertino extends StatelessWidget with MainPageAction {
|
||||||
),
|
),
|
||||||
CupertinoButton.filled(
|
CupertinoButton.filled(
|
||||||
child: Text("Tabelă plecari/sosiri"),
|
child: Text("Tabelă plecari/sosiri"),
|
||||||
onPressed: () {
|
// TODO: Implement departure/arrival
|
||||||
onStationBoardPageInvoke(context);
|
onPressed: null,
|
||||||
},
|
// onPressed: () {
|
||||||
|
// onStationBoardPageInvoke(context);
|
||||||
|
// },
|
||||||
),
|
),
|
||||||
CupertinoButton.filled(
|
CupertinoButton.filled(
|
||||||
child: Text("Planificare rută"),
|
child: Text("Planificare rută"),
|
||||||
onPressed: () {
|
// TODO: Implement route planning
|
||||||
onRoutePlanPageInvoke(context);
|
onPressed: null,
|
||||||
},
|
// onPressed: () {
|
||||||
|
// onRoutePlanPageInvoke(context);
|
||||||
|
// },
|
||||||
),
|
),
|
||||||
].map((w) => Padding(
|
].map((w) => Padding(
|
||||||
padding: const EdgeInsets.fromLTRB(4, 2, 4, 2),
|
padding: const EdgeInsets.fromLTRB(4, 2, 4, 2),
|
||||||
|
|
|
@ -1,6 +1,5 @@
|
||||||
import 'dart:async';
|
import 'dart:async';
|
||||||
import 'dart:convert';
|
import 'dart:convert';
|
||||||
import 'dart:io' show Platform;
|
|
||||||
|
|
||||||
import 'package:flutter/widgets.dart';
|
import 'package:flutter/widgets.dart';
|
||||||
import 'package:info_tren/hidden_webview.dart';
|
import 'package:info_tren/hidden_webview.dart';
|
||||||
|
@ -479,7 +478,7 @@ class OnDemandNextStop extends OnDemand {
|
||||||
|
|
||||||
class OnDemandStations extends OnDemand {
|
class OnDemandStations extends OnDemand {
|
||||||
final WebViewController _controller;
|
final WebViewController _controller;
|
||||||
List<OnDemand> issuedOnDemands = List();
|
List<OnDemand> issuedOnDemands = [];
|
||||||
|
|
||||||
@override
|
@override
|
||||||
void invalidate() {
|
void invalidate() {
|
||||||
|
@ -744,7 +743,7 @@ class TrainDataWebViewAdapter extends StatefulWidget {
|
||||||
}
|
}
|
||||||
|
|
||||||
static _TrainDataWebViewAdapterState of(BuildContext context) =>
|
static _TrainDataWebViewAdapterState of(BuildContext context) =>
|
||||||
(context.inheritFromWidgetOfExactType(_TrainDataWebViewAdapterInheritedWidget) as _TrainDataWebViewAdapterInheritedWidget)
|
(context.findAncestorWidgetOfExactType<_TrainDataWebViewAdapterInheritedWidget>())
|
||||||
.state;
|
.state;
|
||||||
}
|
}
|
||||||
|
|
||||||
|
@ -841,7 +840,7 @@ class _TrainDataWebViewAdapterState extends State<TrainDataWebViewAdapter> {
|
||||||
return TrainLookupResult.OTHER;
|
return TrainLookupResult.OTHER;
|
||||||
}
|
}
|
||||||
|
|
||||||
List<OnDemand> currentDatas = List();
|
List<OnDemand> currentDatas = [];
|
||||||
|
|
||||||
Future<OnDemandTrainData> trainData({Function onInvalidation}) async {
|
Future<OnDemandTrainData> trainData({Function onInvalidation}) async {
|
||||||
final controller = await webViewController;
|
final controller = await webViewController;
|
||||||
|
|
|
@ -168,14 +168,14 @@ class StopOnLineDetails extends StatelessWidget {
|
||||||
padding: const EdgeInsets.fromLTRB(8.0, 8.0, 8.0, 1.0),
|
padding: const EdgeInsets.fromLTRB(8.0, 8.0, 8.0, 1.0),
|
||||||
child: Text(
|
child: Text(
|
||||||
station.name,
|
station.name,
|
||||||
style: Theme.of(context).textTheme.headline,
|
style: Theme.of(context).textTheme.headline5,
|
||||||
textAlign: TextAlign.center,
|
textAlign: TextAlign.center,
|
||||||
),
|
),
|
||||||
),
|
),
|
||||||
if (station.observations == "ONI")
|
if (station.observations == "ONI")
|
||||||
Padding(
|
Padding(
|
||||||
padding: const EdgeInsets.fromLTRB(8.0, 0.0, 8.0, 0.5),
|
padding: const EdgeInsets.fromLTRB(8.0, 0.0, 8.0, 0.5),
|
||||||
child: Text("oprire ne-itinerarică", style: Theme.of(context).textTheme.body1.copyWith(color: Colors.red.shade700),),
|
child: Text("oprire ne-itinerarică", style: Theme.of(context).textTheme.bodyText2.copyWith(color: Colors.red.shade700),),
|
||||||
),
|
),
|
||||||
Padding(
|
Padding(
|
||||||
padding: const EdgeInsets.fromLTRB(8.0, 0.5, 8.0, 8.0),
|
padding: const EdgeInsets.fromLTRB(8.0, 0.5, 8.0, 8.0),
|
||||||
|
@ -293,14 +293,14 @@ class StopOnLineDelayDetails extends StatelessWidget {
|
||||||
else if (station.delay < 0) {
|
else if (station.delay < 0) {
|
||||||
return Text(
|
return Text(
|
||||||
"${-(station.delay)} minute mai devreme",
|
"${-(station.delay)} minute mai devreme",
|
||||||
style: Theme.of(context).textTheme.body1.copyWith(color: Colors.green.shade700),
|
style: Theme.of(context).textTheme.bodyText2.copyWith(color: Colors.green.shade700),
|
||||||
textAlign: TextAlign.center,
|
textAlign: TextAlign.center,
|
||||||
);
|
);
|
||||||
}
|
}
|
||||||
else {
|
else {
|
||||||
return Text(
|
return Text(
|
||||||
"${station.delay} minute întârziere",
|
"${station.delay} minute întârziere",
|
||||||
style: Theme.of(context).textTheme.body1.copyWith(color: Colors.red.shade700),
|
style: Theme.of(context).textTheme.bodyText2.copyWith(color: Colors.red.shade700),
|
||||||
textAlign: TextAlign.center,
|
textAlign: TextAlign.center,
|
||||||
);
|
);
|
||||||
}
|
}
|
||||||
|
|
|
@ -82,7 +82,7 @@ class TrainName extends StatelessWidget {
|
||||||
Widget build(BuildContext context) {
|
Widget build(BuildContext context) {
|
||||||
return Text(
|
return Text(
|
||||||
"${trainData.rang} ${trainData.trainNumber}",
|
"${trainData.rang} ${trainData.trainNumber}",
|
||||||
style: Theme.of(context).textTheme.display2,
|
style: Theme.of(context).textTheme.headline3,
|
||||||
);
|
);
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
|
@ -99,19 +99,19 @@ class TrainRoute extends StatelessWidget {
|
||||||
Expanded(
|
Expanded(
|
||||||
child: Text(
|
child: Text(
|
||||||
"${trainData.route.split("-")[0]}",
|
"${trainData.route.split("-")[0]}",
|
||||||
style: Theme.of(context).textTheme.body2.copyWith(fontStyle: FontStyle.italic),
|
style: Theme.of(context).textTheme.bodyText1.copyWith(fontStyle: FontStyle.italic),
|
||||||
textAlign: TextAlign.left,
|
textAlign: TextAlign.left,
|
||||||
),
|
),
|
||||||
),
|
),
|
||||||
Text(
|
Text(
|
||||||
"-",
|
"-",
|
||||||
style: Theme.of(context).textTheme.body2.copyWith(fontStyle: FontStyle.italic),
|
style: Theme.of(context).textTheme.bodyText1.copyWith(fontStyle: FontStyle.italic),
|
||||||
textAlign: TextAlign.center,
|
textAlign: TextAlign.center,
|
||||||
),
|
),
|
||||||
Expanded(
|
Expanded(
|
||||||
child: Text(
|
child: Text(
|
||||||
"${trainData.route.split("-")[1]}",
|
"${trainData.route.split("-")[1]}",
|
||||||
style: Theme.of(context).textTheme.body2.copyWith(fontStyle: FontStyle.italic),
|
style: Theme.of(context).textTheme.bodyText1.copyWith(fontStyle: FontStyle.italic),
|
||||||
textAlign: TextAlign.right,
|
textAlign: TextAlign.right,
|
||||||
),
|
),
|
||||||
),
|
),
|
||||||
|
@ -128,7 +128,7 @@ class TrainOperator extends StatelessWidget {
|
||||||
Widget build(BuildContext context) {
|
Widget build(BuildContext context) {
|
||||||
return Text(
|
return Text(
|
||||||
"Operat de ${trainData.operator}",
|
"Operat de ${trainData.operator}",
|
||||||
style: Theme.of(context).textTheme.body1,
|
style: Theme.of(context).textTheme.bodyText2,
|
||||||
textAlign: TextAlign.center,
|
textAlign: TextAlign.center,
|
||||||
);
|
);
|
||||||
}
|
}
|
||||||
|
@ -143,7 +143,7 @@ class TrainStatus extends StatelessWidget {
|
||||||
return Text(
|
return Text(
|
||||||
trainData.state,
|
trainData.state,
|
||||||
textAlign: TextAlign.center,
|
textAlign: TextAlign.center,
|
||||||
style: Theme.of(context).textTheme.headline,
|
style: Theme.of(context).textTheme.headline5,
|
||||||
);
|
);
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
|
@ -182,7 +182,7 @@ class LastUpdate extends StatelessWidget {
|
||||||
children: <Widget>[
|
children: <Widget>[
|
||||||
Padding(
|
Padding(
|
||||||
padding: const EdgeInsets.all(2.0),
|
padding: const EdgeInsets.all(2.0),
|
||||||
child: Text("Ultima informație", style: Theme.of(context).textTheme.headline,),
|
child: Text("Ultima informație", style: Theme.of(context).textTheme.headline5,),
|
||||||
),
|
),
|
||||||
Row(
|
Row(
|
||||||
children: <Widget>[
|
children: <Widget>[
|
||||||
|
@ -202,8 +202,8 @@ class LastUpdate extends StatelessWidget {
|
||||||
child: trainData.lastInfo.delay == 0
|
child: trainData.lastInfo.delay == 0
|
||||||
? Text("Fără întârziere", style: Theme.of(context).textTheme.caption,)
|
? Text("Fără întârziere", style: Theme.of(context).textTheme.caption,)
|
||||||
: trainData.lastInfo.delay > 0
|
: trainData.lastInfo.delay > 0
|
||||||
? Text("${trainData.lastInfo.delay} minute întârziere", style: Theme.of(context).textTheme.body1.copyWith(color: Colors.red.shade700),)
|
? Text("${trainData.lastInfo.delay} minute întârziere", style: Theme.of(context).textTheme.bodyText2.copyWith(color: Colors.red.shade700),)
|
||||||
: Text("${-(trainData.lastInfo.delay)} minute mai devreme", style: Theme.of(context).textTheme.body1.copyWith(color: Colors.green.shade700),)
|
: Text("${-(trainData.lastInfo.delay)} minute mai devreme", style: Theme.of(context).textTheme.bodyText2.copyWith(color: Colors.green.shade700),)
|
||||||
),
|
),
|
||||||
Padding(
|
Padding(
|
||||||
padding: const EdgeInsets.all(2.0),
|
padding: const EdgeInsets.all(2.0),
|
||||||
|
@ -225,7 +225,7 @@ class NextStop extends StatelessWidget {
|
||||||
children: <Widget>[
|
children: <Widget>[
|
||||||
Padding(
|
Padding(
|
||||||
padding: const EdgeInsets.all(2.0),
|
padding: const EdgeInsets.all(2.0),
|
||||||
child: Text("Următoarea oprire", style: Theme.of(context).textTheme.headline,),
|
child: Text("Următoarea oprire", style: Theme.of(context).textTheme.headline5,),
|
||||||
),
|
),
|
||||||
Row(
|
Row(
|
||||||
children: <Widget>[
|
children: <Widget>[
|
||||||
|
|
|
@ -104,7 +104,7 @@ class _TrainInfoMaterialBeforeState extends State<_TrainInfoMaterialBefore> {
|
||||||
CircularProgressIndicator(),
|
CircularProgressIndicator(),
|
||||||
Text(
|
Text(
|
||||||
"Conectare...",
|
"Conectare...",
|
||||||
style: Theme.of(context).textTheme.title,
|
style: Theme.of(context).textTheme.headline6,
|
||||||
),
|
),
|
||||||
],
|
],
|
||||||
),
|
),
|
||||||
|
@ -172,7 +172,7 @@ class _TrainInfoMaterialBeforeState extends State<_TrainInfoMaterialBefore> {
|
||||||
: widget.lookupResult == TrainLookupResult.NOT_FOUND
|
: widget.lookupResult == TrainLookupResult.NOT_FOUND
|
||||||
? "Trenul nu a fost găsit"
|
? "Trenul nu a fost găsit"
|
||||||
: "A apărut o eroare în căutarea trenului",
|
: "A apărut o eroare în căutarea trenului",
|
||||||
style: Theme.of(context).textTheme.title,
|
style: Theme.of(context).textTheme.headline6,
|
||||||
),
|
),
|
||||||
),
|
),
|
||||||
Expanded(child: Container(),),
|
Expanded(child: Container(),),
|
||||||
|
@ -352,9 +352,9 @@ class DisplayTrainID extends StatelessWidget {
|
||||||
return Text(
|
return Text(
|
||||||
"${list[0]} ${list[1]}",
|
"${list[0]} ${list[1]}",
|
||||||
style: (isSmallScreen(context)
|
style: (isSmallScreen(context)
|
||||||
? Theme.of(context).textTheme.display1
|
? Theme.of(context).textTheme.headline4
|
||||||
: Theme.of(context).textTheme.display2).copyWith(
|
: Theme.of(context).textTheme.headline3).copyWith(
|
||||||
color: Theme.of(context).textTheme.body1.color,
|
color: Theme.of(context).textTheme.bodyText2.color,
|
||||||
fontWeight: FontWeight.bold,
|
fontWeight: FontWeight.bold,
|
||||||
),
|
),
|
||||||
textAlign: TextAlign.center,
|
textAlign: TextAlign.center,
|
||||||
|
@ -376,7 +376,7 @@ class DisplayTrainOperator extends StatelessWidget {
|
||||||
builder: (context, op) {
|
builder: (context, op) {
|
||||||
return Text(
|
return Text(
|
||||||
op,
|
op,
|
||||||
style: Theme.of(context).textTheme.body1.copyWith(
|
style: Theme.of(context).textTheme.bodyText2.copyWith(
|
||||||
fontStyle: FontStyle.italic,
|
fontStyle: FontStyle.italic,
|
||||||
fontSize: isSmallScreen(context) ? 12 : 14,
|
fontSize: isSmallScreen(context) ? 12 : 14,
|
||||||
),
|
),
|
||||||
|
@ -404,7 +404,7 @@ class DisplayTrainRoute extends StatelessWidget {
|
||||||
padding: const EdgeInsets.all(4),
|
padding: const EdgeInsets.all(4),
|
||||||
child: Text(
|
child: Text(
|
||||||
routePieces[0],
|
routePieces[0],
|
||||||
style: Theme.of(context).textTheme.body1.copyWith(
|
style: Theme.of(context).textTheme.bodyText2.copyWith(
|
||||||
fontSize: 16,
|
fontSize: 16,
|
||||||
),
|
),
|
||||||
),
|
),
|
||||||
|
@ -418,7 +418,7 @@ class DisplayTrainRoute extends StatelessWidget {
|
||||||
padding: const EdgeInsets.all(4),
|
padding: const EdgeInsets.all(4),
|
||||||
child: Text(
|
child: Text(
|
||||||
routePieces[1],
|
routePieces[1],
|
||||||
style: Theme.of(context).textTheme.body1.copyWith(
|
style: Theme.of(context).textTheme.bodyText2.copyWith(
|
||||||
fontSize: 16,
|
fontSize: 16,
|
||||||
),
|
),
|
||||||
textAlign: TextAlign.right,
|
textAlign: TextAlign.right,
|
||||||
|
@ -446,7 +446,7 @@ class DisplayTrainDeparture extends StatelessWidget {
|
||||||
builder: (context, dataPlecare) {
|
builder: (context, dataPlecare) {
|
||||||
return Text(
|
return Text(
|
||||||
"Plecare în ${dataPlecare.day.toString().padLeft(2, '0')}.${dataPlecare.month.toString().padLeft(2, '0')}.${dataPlecare.year.toString().padLeft(4, '0')}",
|
"Plecare în ${dataPlecare.day.toString().padLeft(2, '0')}.${dataPlecare.month.toString().padLeft(2, '0')}.${dataPlecare.year.toString().padLeft(4, '0')}",
|
||||||
style: Theme.of(context).textTheme.body1.copyWith(
|
style: Theme.of(context).textTheme.bodyText2.copyWith(
|
||||||
fontStyle: FontStyle.italic,
|
fontStyle: FontStyle.italic,
|
||||||
fontWeight: FontWeight.w200,
|
fontWeight: FontWeight.w200,
|
||||||
fontSize: isSmallScreen(context) ? 12 : 14,
|
fontSize: isSmallScreen(context) ? 12 : 14,
|
||||||
|
@ -477,7 +477,7 @@ class DisplayTrainLastInfo extends StatelessWidget {
|
||||||
padding: const EdgeInsets.all(2),
|
padding: const EdgeInsets.all(2),
|
||||||
child: Text(
|
child: Text(
|
||||||
"Ultima informație",
|
"Ultima informație",
|
||||||
style: Theme.of(context).textTheme.body1.copyWith(
|
style: Theme.of(context).textTheme.bodyText2.copyWith(
|
||||||
fontSize: isSmallScreen(context) ? 18 : 20,
|
fontSize: isSmallScreen(context) ? 18 : 20,
|
||||||
fontWeight: FontWeight.bold,
|
fontWeight: FontWeight.bold,
|
||||||
),
|
),
|
||||||
|
@ -493,7 +493,7 @@ class DisplayTrainLastInfo extends StatelessWidget {
|
||||||
builder: (context, station) {
|
builder: (context, station) {
|
||||||
return Text(
|
return Text(
|
||||||
station,
|
station,
|
||||||
style: Theme.of(context).textTheme.body1,
|
style: Theme.of(context).textTheme.bodyText2,
|
||||||
textAlign: TextAlign.left,
|
textAlign: TextAlign.left,
|
||||||
);
|
);
|
||||||
},
|
},
|
||||||
|
@ -507,7 +507,7 @@ class DisplayTrainLastInfo extends StatelessWidget {
|
||||||
builder: (context, event) {
|
builder: (context, event) {
|
||||||
return Text(
|
return Text(
|
||||||
event,
|
event,
|
||||||
style: Theme.of(context).textTheme.body1,
|
style: Theme.of(context).textTheme.bodyText2,
|
||||||
textAlign: TextAlign.right,
|
textAlign: TextAlign.right,
|
||||||
);
|
);
|
||||||
},
|
},
|
||||||
|
@ -540,7 +540,7 @@ class DisplayTrainLastInfo extends StatelessWidget {
|
||||||
if (snapshot.data > 0) {
|
if (snapshot.data > 0) {
|
||||||
return Text(
|
return Text(
|
||||||
"${snapshot.data} minute întârziere",
|
"${snapshot.data} minute întârziere",
|
||||||
style: Theme.of(context).textTheme.body1.copyWith(
|
style: Theme.of(context).textTheme.bodyText2.copyWith(
|
||||||
fontSize: 14,
|
fontSize: 14,
|
||||||
color: Color.fromRGBO(200, 30, 15, 1),
|
color: Color.fromRGBO(200, 30, 15, 1),
|
||||||
),
|
),
|
||||||
|
@ -549,7 +549,7 @@ class DisplayTrainLastInfo extends StatelessWidget {
|
||||||
else {
|
else {
|
||||||
return Text(
|
return Text(
|
||||||
"${-snapshot.data} minute mai devreme",
|
"${-snapshot.data} minute mai devreme",
|
||||||
style: Theme.of(context).textTheme.body1.copyWith(
|
style: Theme.of(context).textTheme.bodyText2.copyWith(
|
||||||
fontSize: 12,
|
fontSize: 12,
|
||||||
color: Color.fromRGBO(15, 200, 15, 1),
|
color: Color.fromRGBO(15, 200, 15, 1),
|
||||||
),
|
),
|
||||||
|
@ -590,7 +590,7 @@ class DisplayTrainNextStop extends StatelessWidget {
|
||||||
padding: const EdgeInsets.all(4),
|
padding: const EdgeInsets.all(4),
|
||||||
child: Text(
|
child: Text(
|
||||||
"Următoarea oprire",
|
"Următoarea oprire",
|
||||||
style: Theme.of(context).textTheme.body1.copyWith(
|
style: Theme.of(context).textTheme.bodyText2.copyWith(
|
||||||
fontSize: isSmallScreen(context) ? 18 : 20,
|
fontSize: isSmallScreen(context) ? 18 : 20,
|
||||||
fontWeight: FontWeight.bold,
|
fontWeight: FontWeight.bold,
|
||||||
),
|
),
|
||||||
|
@ -604,7 +604,7 @@ class DisplayTrainNextStop extends StatelessWidget {
|
||||||
padding: const EdgeInsets.fromLTRB(4, 0, 4, 0),
|
padding: const EdgeInsets.fromLTRB(4, 0, 4, 0),
|
||||||
child: Text(
|
child: Text(
|
||||||
station,
|
station,
|
||||||
style: Theme.of(context).textTheme.body1.copyWith(
|
style: Theme.of(context).textTheme.bodyText2.copyWith(
|
||||||
fontSize: isSmallScreen(context) ? 16 : 18,
|
fontSize: isSmallScreen(context) ? 16 : 18,
|
||||||
fontWeight: FontWeight.w500,
|
fontWeight: FontWeight.w500,
|
||||||
),
|
),
|
||||||
|
@ -623,14 +623,14 @@ class DisplayTrainNextStop extends StatelessWidget {
|
||||||
children: <Widget>[
|
children: <Widget>[
|
||||||
Text(
|
Text(
|
||||||
"în ${arrival.day} ${months[arrival.month - 1]} ${arrival.year}",
|
"în ${arrival.day} ${months[arrival.month - 1]} ${arrival.year}",
|
||||||
style: Theme.of(context).textTheme.body1.copyWith(
|
style: Theme.of(context).textTheme.bodyText2.copyWith(
|
||||||
fontSize: isSmallScreen(context) ? 12 : 14,
|
fontSize: isSmallScreen(context) ? 12 : 14,
|
||||||
),
|
),
|
||||||
textAlign: TextAlign.center,
|
textAlign: TextAlign.center,
|
||||||
),
|
),
|
||||||
Text(
|
Text(
|
||||||
"la ${arrival.hour.toString().padLeft(2, '0')}:${arrival.minute.toString().padLeft(2, '0')}",
|
"la ${arrival.hour.toString().padLeft(2, '0')}:${arrival.minute.toString().padLeft(2, '0')}",
|
||||||
style: Theme.of(context).textTheme.body1.copyWith(
|
style: Theme.of(context).textTheme.bodyText2.copyWith(
|
||||||
fontSize: isSmallScreen(context) ? 12 : 14,
|
fontSize: isSmallScreen(context) ? 12 : 14,
|
||||||
),
|
),
|
||||||
textAlign: TextAlign.center,
|
textAlign: TextAlign.center,
|
||||||
|
@ -672,7 +672,7 @@ class DisplayTrainDestination extends StatelessWidget {
|
||||||
padding: const EdgeInsets.all(4),
|
padding: const EdgeInsets.all(4),
|
||||||
child: Text(
|
child: Text(
|
||||||
"Destinația",
|
"Destinația",
|
||||||
style: Theme.of(context).textTheme.body1.copyWith(
|
style: Theme.of(context).textTheme.bodyText2.copyWith(
|
||||||
fontSize: isSmallScreen(context) ? 18 : 20,
|
fontSize: isSmallScreen(context) ? 18 : 20,
|
||||||
fontWeight: FontWeight.bold,
|
fontWeight: FontWeight.bold,
|
||||||
),
|
),
|
||||||
|
@ -686,7 +686,7 @@ class DisplayTrainDestination extends StatelessWidget {
|
||||||
padding: const EdgeInsets.fromLTRB(4, 0, 4, 0),
|
padding: const EdgeInsets.fromLTRB(4, 0, 4, 0),
|
||||||
child: Text(
|
child: Text(
|
||||||
station,
|
station,
|
||||||
style: Theme.of(context).textTheme.body1.copyWith(
|
style: Theme.of(context).textTheme.bodyText2.copyWith(
|
||||||
fontSize: isSmallScreen(context) ? 16 : 18,
|
fontSize: isSmallScreen(context) ? 16 : 18,
|
||||||
fontWeight: FontWeight.w500,
|
fontWeight: FontWeight.w500,
|
||||||
),
|
),
|
||||||
|
@ -705,14 +705,14 @@ class DisplayTrainDestination extends StatelessWidget {
|
||||||
children: <Widget>[
|
children: <Widget>[
|
||||||
Text(
|
Text(
|
||||||
"în ${arrival.day} ${months[arrival.month - 1]} ${arrival.year}",
|
"în ${arrival.day} ${months[arrival.month - 1]} ${arrival.year}",
|
||||||
style: Theme.of(context).textTheme.body1.copyWith(
|
style: Theme.of(context).textTheme.bodyText2.copyWith(
|
||||||
fontSize: isSmallScreen(context) ? 12 : 14,
|
fontSize: isSmallScreen(context) ? 12 : 14,
|
||||||
),
|
),
|
||||||
textAlign: TextAlign.center,
|
textAlign: TextAlign.center,
|
||||||
),
|
),
|
||||||
Text(
|
Text(
|
||||||
"la ${arrival.hour.toString().padLeft(2, '0')}:${arrival.minute.toString().padLeft(2, '0')}",
|
"la ${arrival.hour.toString().padLeft(2, '0')}:${arrival.minute.toString().padLeft(2, '0')}",
|
||||||
style: Theme.of(context).textTheme.body1.copyWith(
|
style: Theme.of(context).textTheme.bodyText2.copyWith(
|
||||||
fontSize: isSmallScreen(context) ? 12 : 14,
|
fontSize: isSmallScreen(context) ? 12 : 14,
|
||||||
),
|
),
|
||||||
textAlign: TextAlign.center,
|
textAlign: TextAlign.center,
|
||||||
|
@ -747,7 +747,7 @@ class DisplayTrainRouteDistance extends StatelessWidget {
|
||||||
children: <Widget>[
|
children: <Widget>[
|
||||||
Text(
|
Text(
|
||||||
"Distanța rutei",
|
"Distanța rutei",
|
||||||
style: Theme.of(context).textTheme.body1.copyWith(
|
style: Theme.of(context).textTheme.bodyText2.copyWith(
|
||||||
fontSize: isSmallScreen(context) ? 16 : 18,
|
fontSize: isSmallScreen(context) ? 16 : 18,
|
||||||
fontWeight: FontWeight.bold,
|
fontWeight: FontWeight.bold,
|
||||||
),
|
),
|
||||||
|
@ -758,7 +758,7 @@ class DisplayTrainRouteDistance extends StatelessWidget {
|
||||||
builder: (context, distance) {
|
builder: (context, distance) {
|
||||||
return Text(
|
return Text(
|
||||||
"$distance km",
|
"$distance km",
|
||||||
style: Theme.of(context).textTheme.body1.copyWith(
|
style: Theme.of(context).textTheme.bodyText2.copyWith(
|
||||||
fontSize: isSmallScreen(context) ? 14 : 16,
|
fontSize: isSmallScreen(context) ? 14 : 16,
|
||||||
),
|
),
|
||||||
textAlign: TextAlign.center,
|
textAlign: TextAlign.center,
|
||||||
|
@ -789,7 +789,7 @@ class DisplayTrainRouteDuration extends StatelessWidget {
|
||||||
children: <Widget>[
|
children: <Widget>[
|
||||||
Text(
|
Text(
|
||||||
"Durata rutei",
|
"Durata rutei",
|
||||||
style: Theme.of(context).textTheme.body1.copyWith(
|
style: Theme.of(context).textTheme.bodyText2.copyWith(
|
||||||
fontSize: isSmallScreen(context) ? 16 : 18,
|
fontSize: isSmallScreen(context) ? 16 : 18,
|
||||||
fontWeight: FontWeight.bold,
|
fontWeight: FontWeight.bold,
|
||||||
),
|
),
|
||||||
|
@ -831,7 +831,7 @@ class DisplayTrainRouteDuration extends StatelessWidget {
|
||||||
|
|
||||||
return Text(
|
return Text(
|
||||||
durationString.toString(),
|
durationString.toString(),
|
||||||
style: Theme.of(context).textTheme.body1.copyWith(
|
style: Theme.of(context).textTheme.bodyText2.copyWith(
|
||||||
fontSize: isSmallScreen(context) ? 14 : 16,
|
fontSize: isSmallScreen(context) ? 14 : 16,
|
||||||
),
|
),
|
||||||
textAlign: TextAlign.center,
|
textAlign: TextAlign.center,
|
||||||
|
@ -925,8 +925,8 @@ class SlimAppBar extends StatelessWidget {
|
||||||
title,
|
title,
|
||||||
textAlign: TextAlign.center,
|
textAlign: TextAlign.center,
|
||||||
style:
|
style:
|
||||||
Theme.of(context).appBarTheme.textTheme?.caption?.copyWith(color: Theme.of(context).appBarTheme.textTheme?.body1?.color) ??
|
Theme.of(context).appBarTheme.textTheme?.caption?.copyWith(color: Theme.of(context).appBarTheme.textTheme?.bodyText2?.color) ??
|
||||||
Theme.of(context).textTheme.caption.copyWith(color: Theme.of(context).textTheme.body1.color),
|
Theme.of(context).textTheme.caption.copyWith(color: Theme.of(context).textTheme.bodyText2.color),
|
||||||
),
|
),
|
||||||
),
|
),
|
||||||
),
|
),
|
||||||
|
|
|
@ -113,7 +113,7 @@ class KmBadge extends StatelessWidget {
|
||||||
builder: (context, value) {
|
builder: (context, value) {
|
||||||
return Text(
|
return Text(
|
||||||
value.toString(),
|
value.toString(),
|
||||||
style: Theme.of(context).textTheme.body1.copyWith(
|
style: Theme.of(context).textTheme.bodyText2.copyWith(
|
||||||
fontSize: isSmallScreen(context) ? 14 : 18,
|
fontSize: isSmallScreen(context) ? 14 : 18,
|
||||||
fontWeight: MediaQuery.of(context).boldText ? FontWeight.w400 : FontWeight.w200,
|
fontWeight: MediaQuery.of(context).boldText ? FontWeight.w400 : FontWeight.w200,
|
||||||
color: MediaQuery.of(context).boldText ? Colors.white70 : foregroundColor,
|
color: MediaQuery.of(context).boldText ? Colors.white70 : foregroundColor,
|
||||||
|
@ -126,7 +126,7 @@ class KmBadge extends StatelessWidget {
|
||||||
),
|
),
|
||||||
Text(
|
Text(
|
||||||
"km",
|
"km",
|
||||||
style: Theme.of(context).textTheme.body1.copyWith(
|
style: Theme.of(context).textTheme.bodyText2.copyWith(
|
||||||
fontSize: 10,
|
fontSize: 10,
|
||||||
color: MediaQuery.of(context).boldText ? Colors.white70 : foregroundColor,
|
color: MediaQuery.of(context).boldText ? Colors.white70 : foregroundColor,
|
||||||
),
|
),
|
||||||
|
@ -155,7 +155,7 @@ class Title extends StatelessWidget {
|
||||||
builder: (context, items) {
|
builder: (context, items) {
|
||||||
return Text(
|
return Text(
|
||||||
items[0],
|
items[0],
|
||||||
style: Theme.of(context).textTheme.body1.copyWith(
|
style: Theme.of(context).textTheme.bodyText2.copyWith(
|
||||||
fontSize: isSmallScreen(context) ? 18 : 22,
|
fontSize: isSmallScreen(context) ? 18 : 22,
|
||||||
fontWeight: MediaQuery.of(context).boldText ? FontWeight.w400 : FontWeight.w200,
|
fontWeight: MediaQuery.of(context).boldText ? FontWeight.w400 : FontWeight.w200,
|
||||||
fontStyle: items[1] == "ONI" ? FontStyle.italic : FontStyle.normal,
|
fontStyle: items[1] == "ONI" ? FontStyle.italic : FontStyle.normal,
|
||||||
|
@ -204,7 +204,7 @@ class Time extends StatelessWidget {
|
||||||
children: <Widget>[
|
children: <Widget>[
|
||||||
Text(
|
Text(
|
||||||
"→",
|
"→",
|
||||||
style: Theme.of(context).textTheme.body1.copyWith(
|
style: Theme.of(context).textTheme.bodyText2.copyWith(
|
||||||
fontSize: isSmallScreen(context) ? 18 : 22,
|
fontSize: isSmallScreen(context) ? 18 : 22,
|
||||||
),
|
),
|
||||||
),
|
),
|
||||||
|
@ -217,7 +217,7 @@ class Time extends StatelessWidget {
|
||||||
Container(width: 2,),
|
Container(width: 2,),
|
||||||
Text(
|
Text(
|
||||||
"→",
|
"→",
|
||||||
style: Theme.of(context).textTheme.body1.copyWith(
|
style: Theme.of(context).textTheme.bodyText2.copyWith(
|
||||||
fontSize: isSmallScreen(context) ? 18 : 22,
|
fontSize: isSmallScreen(context) ? 18 : 22,
|
||||||
),
|
),
|
||||||
),
|
),
|
||||||
|
@ -251,7 +251,7 @@ class ArrivalTime extends StatelessWidget {
|
||||||
children: <Widget>[
|
children: <Widget>[
|
||||||
Text(
|
Text(
|
||||||
"→",
|
"→",
|
||||||
style: Theme.of(context).textTheme.body1.copyWith(
|
style: Theme.of(context).textTheme.bodyText2.copyWith(
|
||||||
fontSize: isSmallScreen(context) ? 18 : 22,
|
fontSize: isSmallScreen(context) ? 18 : 22,
|
||||||
),
|
),
|
||||||
),
|
),
|
||||||
|
@ -278,13 +278,13 @@ class ArrivalTime extends StatelessWidget {
|
||||||
children: <Widget>[
|
children: <Widget>[
|
||||||
Text(
|
Text(
|
||||||
"${oldDate.hour.toString().padLeft(2, '0')}:${oldDate.minute.toString().padLeft(2, '0')}",
|
"${oldDate.hour.toString().padLeft(2, '0')}:${oldDate.minute.toString().padLeft(2, '0')}",
|
||||||
style: Theme.of(context).textTheme.body1.copyWith(
|
style: Theme.of(context).textTheme.bodyText2.copyWith(
|
||||||
decoration: TextDecoration.lineThrough,
|
decoration: TextDecoration.lineThrough,
|
||||||
),
|
),
|
||||||
),
|
),
|
||||||
Text(
|
Text(
|
||||||
"${data[0]}",
|
"${data[0]}",
|
||||||
style: Theme.of(context).textTheme.body1.copyWith(
|
style: Theme.of(context).textTheme.bodyText2.copyWith(
|
||||||
color: Colors.red.shade300,
|
color: Colors.red.shade300,
|
||||||
),
|
),
|
||||||
),
|
),
|
||||||
|
@ -303,13 +303,13 @@ class ArrivalTime extends StatelessWidget {
|
||||||
children: <Widget>[
|
children: <Widget>[
|
||||||
Text(
|
Text(
|
||||||
"${oldDate.hour.toString().padLeft(2, '0')}:${oldDate.minute.toString().padLeft(2, '0')}",
|
"${oldDate.hour.toString().padLeft(2, '0')}:${oldDate.minute.toString().padLeft(2, '0')}",
|
||||||
style: Theme.of(context).textTheme.body1.copyWith(
|
style: Theme.of(context).textTheme.bodyText2.copyWith(
|
||||||
decoration: TextDecoration.lineThrough,
|
decoration: TextDecoration.lineThrough,
|
||||||
),
|
),
|
||||||
),
|
),
|
||||||
Text(
|
Text(
|
||||||
"${data[0]}",
|
"${data[0]}",
|
||||||
style: Theme.of(context).textTheme.body1.copyWith(
|
style: Theme.of(context).textTheme.bodyText2.copyWith(
|
||||||
color: Colors.green.shade300,
|
color: Colors.green.shade300,
|
||||||
),
|
),
|
||||||
),
|
),
|
||||||
|
@ -398,7 +398,7 @@ class DepartureTime extends StatelessWidget {
|
||||||
Container(width: 2,),
|
Container(width: 2,),
|
||||||
Text(
|
Text(
|
||||||
"→",
|
"→",
|
||||||
style: Theme.of(context).textTheme.body1.copyWith(
|
style: Theme.of(context).textTheme.bodyText2.copyWith(
|
||||||
fontSize: 22,
|
fontSize: 22,
|
||||||
),
|
),
|
||||||
),
|
),
|
||||||
|
@ -421,13 +421,13 @@ class DepartureTime extends StatelessWidget {
|
||||||
children: <Widget>[
|
children: <Widget>[
|
||||||
Text(
|
Text(
|
||||||
"${oldDate.hour.toString().padLeft(2, '0')}:${oldDate.minute.toString().padLeft(2, '0')}",
|
"${oldDate.hour.toString().padLeft(2, '0')}:${oldDate.minute.toString().padLeft(2, '0')}",
|
||||||
style: Theme.of(context).textTheme.body1.copyWith(
|
style: Theme.of(context).textTheme.bodyText2.copyWith(
|
||||||
decoration: TextDecoration.lineThrough,
|
decoration: TextDecoration.lineThrough,
|
||||||
),
|
),
|
||||||
),
|
),
|
||||||
Text(
|
Text(
|
||||||
"${data[0]}",
|
"${data[0]}",
|
||||||
style: Theme.of(context).textTheme.body1.copyWith(
|
style: Theme.of(context).textTheme.bodyText2.copyWith(
|
||||||
color: Colors.red.shade300,
|
color: Colors.red.shade300,
|
||||||
),
|
),
|
||||||
),
|
),
|
||||||
|
@ -446,13 +446,13 @@ class DepartureTime extends StatelessWidget {
|
||||||
children: <Widget>[
|
children: <Widget>[
|
||||||
Text(
|
Text(
|
||||||
"${oldDate.hour.toString().padLeft(2, '0')}:${oldDate.minute.toString().padLeft(2, '0')}",
|
"${oldDate.hour.toString().padLeft(2, '0')}:${oldDate.minute.toString().padLeft(2, '0')}",
|
||||||
style: Theme.of(context).textTheme.body1.copyWith(
|
style: Theme.of(context).textTheme.bodyText2.copyWith(
|
||||||
decoration: TextDecoration.lineThrough,
|
decoration: TextDecoration.lineThrough,
|
||||||
),
|
),
|
||||||
),
|
),
|
||||||
Text(
|
Text(
|
||||||
"${data[0]}",
|
"${data[0]}",
|
||||||
style: Theme.of(context).textTheme.body1.copyWith(
|
style: Theme.of(context).textTheme.bodyText2.copyWith(
|
||||||
color: Colors.green.shade300,
|
color: Colors.green.shade300,
|
||||||
),
|
),
|
||||||
),
|
),
|
||||||
|
@ -483,7 +483,7 @@ class Delay extends StatelessWidget {
|
||||||
else if (delay > 0) {
|
else if (delay > 0) {
|
||||||
return Text(
|
return Text(
|
||||||
"$delay minute întârziere",
|
"$delay minute întârziere",
|
||||||
style: Theme.of(context).textTheme.body1.copyWith(
|
style: Theme.of(context).textTheme.bodyText2.copyWith(
|
||||||
color: Colors.red.shade300,
|
color: Colors.red.shade300,
|
||||||
fontSize: 12,
|
fontSize: 12,
|
||||||
fontStyle: FontStyle.italic,
|
fontStyle: FontStyle.italic,
|
||||||
|
@ -494,7 +494,7 @@ class Delay extends StatelessWidget {
|
||||||
else if (delay < 0) {
|
else if (delay < 0) {
|
||||||
return Text(
|
return Text(
|
||||||
"${-delay} minute mai devreme",
|
"${-delay} minute mai devreme",
|
||||||
style: Theme.of(context).textTheme.body1.copyWith(
|
style: Theme.of(context).textTheme.bodyText2.copyWith(
|
||||||
color: Colors.green.shade300,
|
color: Colors.green.shade300,
|
||||||
fontSize: 12,
|
fontSize: 12,
|
||||||
fontStyle: FontStyle.italic,
|
fontStyle: FontStyle.italic,
|
||||||
|
|
|
@ -21,10 +21,10 @@ mixin TrainInfoPromptCommon {
|
||||||
}
|
}
|
||||||
|
|
||||||
mixin TrainInfoPromptListHandling {
|
mixin TrainInfoPromptListHandling {
|
||||||
List<TrainOperatorLines> operators = List();
|
List<TrainOperatorLines> operators = [];
|
||||||
|
|
||||||
Future loadOperators(BuildContext context) async {
|
Future loadOperators(BuildContext context) async {
|
||||||
operators = List();
|
operators = [];
|
||||||
|
|
||||||
final operatorsString = await DefaultAssetBundle.of(context).loadString("assets/lines/files.txt");
|
final operatorsString = await DefaultAssetBundle.of(context).loadString("assets/lines/files.txt");
|
||||||
final operatorsFilesList = operatorsString.split("\n");
|
final operatorsFilesList = operatorsString.split("\n");
|
||||||
|
@ -265,7 +265,7 @@ class _TrainInfoPromptMaterialState extends State<TrainInfoPromptMaterial> with
|
||||||
labelText: "Numărul trenului",
|
labelText: "Numărul trenului",
|
||||||
),
|
),
|
||||||
inputFormatters: [
|
inputFormatters: [
|
||||||
WhitelistingTextInputFormatter.digitsOnly,
|
FilteringTextInputFormatter.digitsOnly,
|
||||||
],
|
],
|
||||||
textInputAction: TextInputAction.search,
|
textInputAction: TextInputAction.search,
|
||||||
keyboardType: TextInputType.number,
|
keyboardType: TextInputType.number,
|
||||||
|
@ -326,7 +326,7 @@ class _TrainInfoPromptCupertinoState extends State<TrainInfoPromptCupertino> wit
|
||||||
setState(() {});
|
setState(() {});
|
||||||
},
|
},
|
||||||
inputFormatters: [
|
inputFormatters: [
|
||||||
WhitelistingTextInputFormatter.digitsOnly,
|
FilteringTextInputFormatter.digitsOnly,
|
||||||
],
|
],
|
||||||
),
|
),
|
||||||
),
|
),
|
||||||
|
|
|
@ -1,7 +1,7 @@
|
||||||
import 'dart:async';
|
import 'dart:async';
|
||||||
|
|
||||||
Stream<List<T>> listifyStream<T>(Stream<T> stream) async* {
|
Stream<List<T>> listifyStream<T>(Stream<T> stream) async* {
|
||||||
List<T> list = List();
|
List<T> list = [];
|
||||||
|
|
||||||
await for (T item in stream) {
|
await for (T item in stream) {
|
||||||
list.add(item);
|
list.add(item);
|
||||||
|
|
55
pubspec.lock
55
pubspec.lock
|
@ -21,14 +21,14 @@ packages:
|
||||||
name: async
|
name: async
|
||||||
url: "https://pub.dartlang.org"
|
url: "https://pub.dartlang.org"
|
||||||
source: hosted
|
source: hosted
|
||||||
version: "2.2.0"
|
version: "2.6.1"
|
||||||
boolean_selector:
|
boolean_selector:
|
||||||
dependency: transitive
|
dependency: transitive
|
||||||
description:
|
description:
|
||||||
name: boolean_selector
|
name: boolean_selector
|
||||||
url: "https://pub.dartlang.org"
|
url: "https://pub.dartlang.org"
|
||||||
source: hosted
|
source: hosted
|
||||||
version: "1.0.4"
|
version: "2.1.0"
|
||||||
build:
|
build:
|
||||||
dependency: transitive
|
dependency: transitive
|
||||||
description:
|
description:
|
||||||
|
@ -85,13 +85,27 @@ packages:
|
||||||
url: "https://pub.dartlang.org"
|
url: "https://pub.dartlang.org"
|
||||||
source: hosted
|
source: hosted
|
||||||
version: "6.7.0"
|
version: "6.7.0"
|
||||||
|
characters:
|
||||||
|
dependency: transitive
|
||||||
|
description:
|
||||||
|
name: characters
|
||||||
|
url: "https://pub.dartlang.org"
|
||||||
|
source: hosted
|
||||||
|
version: "1.1.0"
|
||||||
charcode:
|
charcode:
|
||||||
dependency: transitive
|
dependency: transitive
|
||||||
description:
|
description:
|
||||||
name: charcode
|
name: charcode
|
||||||
url: "https://pub.dartlang.org"
|
url: "https://pub.dartlang.org"
|
||||||
source: hosted
|
source: hosted
|
||||||
version: "1.1.2"
|
version: "1.2.0"
|
||||||
|
clock:
|
||||||
|
dependency: transitive
|
||||||
|
description:
|
||||||
|
name: clock
|
||||||
|
url: "https://pub.dartlang.org"
|
||||||
|
source: hosted
|
||||||
|
version: "1.1.0"
|
||||||
code_builder:
|
code_builder:
|
||||||
dependency: transitive
|
dependency: transitive
|
||||||
description:
|
description:
|
||||||
|
@ -105,7 +119,7 @@ packages:
|
||||||
name: collection
|
name: collection
|
||||||
url: "https://pub.dartlang.org"
|
url: "https://pub.dartlang.org"
|
||||||
source: hosted
|
source: hosted
|
||||||
version: "1.14.11"
|
version: "1.15.0"
|
||||||
convert:
|
convert:
|
||||||
dependency: transitive
|
dependency: transitive
|
||||||
description:
|
description:
|
||||||
|
@ -141,6 +155,13 @@ packages:
|
||||||
url: "https://pub.dartlang.org"
|
url: "https://pub.dartlang.org"
|
||||||
source: hosted
|
source: hosted
|
||||||
version: "1.2.9"
|
version: "1.2.9"
|
||||||
|
fake_async:
|
||||||
|
dependency: transitive
|
||||||
|
description:
|
||||||
|
name: fake_async
|
||||||
|
url: "https://pub.dartlang.org"
|
||||||
|
source: hosted
|
||||||
|
version: "1.2.0"
|
||||||
fixnum:
|
fixnum:
|
||||||
dependency: transitive
|
dependency: transitive
|
||||||
description:
|
description:
|
||||||
|
@ -255,14 +276,14 @@ packages:
|
||||||
name: matcher
|
name: matcher
|
||||||
url: "https://pub.dartlang.org"
|
url: "https://pub.dartlang.org"
|
||||||
source: hosted
|
source: hosted
|
||||||
version: "0.12.5"
|
version: "0.12.10"
|
||||||
meta:
|
meta:
|
||||||
dependency: transitive
|
dependency: transitive
|
||||||
description:
|
description:
|
||||||
name: meta
|
name: meta
|
||||||
url: "https://pub.dartlang.org"
|
url: "https://pub.dartlang.org"
|
||||||
source: hosted
|
source: hosted
|
||||||
version: "1.1.6"
|
version: "1.3.0"
|
||||||
mime:
|
mime:
|
||||||
dependency: transitive
|
dependency: transitive
|
||||||
description:
|
description:
|
||||||
|
@ -290,7 +311,7 @@ packages:
|
||||||
name: path
|
name: path
|
||||||
url: "https://pub.dartlang.org"
|
url: "https://pub.dartlang.org"
|
||||||
source: hosted
|
source: hosted
|
||||||
version: "1.6.2"
|
version: "1.8.0"
|
||||||
pedantic:
|
pedantic:
|
||||||
dependency: transitive
|
dependency: transitive
|
||||||
description:
|
description:
|
||||||
|
@ -365,21 +386,21 @@ packages:
|
||||||
name: source_span
|
name: source_span
|
||||||
url: "https://pub.dartlang.org"
|
url: "https://pub.dartlang.org"
|
||||||
source: hosted
|
source: hosted
|
||||||
version: "1.5.5"
|
version: "1.8.1"
|
||||||
stack_trace:
|
stack_trace:
|
||||||
dependency: transitive
|
dependency: transitive
|
||||||
description:
|
description:
|
||||||
name: stack_trace
|
name: stack_trace
|
||||||
url: "https://pub.dartlang.org"
|
url: "https://pub.dartlang.org"
|
||||||
source: hosted
|
source: hosted
|
||||||
version: "1.9.3"
|
version: "1.10.0"
|
||||||
stream_channel:
|
stream_channel:
|
||||||
dependency: transitive
|
dependency: transitive
|
||||||
description:
|
description:
|
||||||
name: stream_channel
|
name: stream_channel
|
||||||
url: "https://pub.dartlang.org"
|
url: "https://pub.dartlang.org"
|
||||||
source: hosted
|
source: hosted
|
||||||
version: "2.0.0"
|
version: "2.1.0"
|
||||||
stream_transform:
|
stream_transform:
|
||||||
dependency: transitive
|
dependency: transitive
|
||||||
description:
|
description:
|
||||||
|
@ -393,21 +414,21 @@ packages:
|
||||||
name: string_scanner
|
name: string_scanner
|
||||||
url: "https://pub.dartlang.org"
|
url: "https://pub.dartlang.org"
|
||||||
source: hosted
|
source: hosted
|
||||||
version: "1.0.4"
|
version: "1.1.0"
|
||||||
term_glyph:
|
term_glyph:
|
||||||
dependency: transitive
|
dependency: transitive
|
||||||
description:
|
description:
|
||||||
name: term_glyph
|
name: term_glyph
|
||||||
url: "https://pub.dartlang.org"
|
url: "https://pub.dartlang.org"
|
||||||
source: hosted
|
source: hosted
|
||||||
version: "1.1.0"
|
version: "1.2.0"
|
||||||
test_api:
|
test_api:
|
||||||
dependency: transitive
|
dependency: transitive
|
||||||
description:
|
description:
|
||||||
name: test_api
|
name: test_api
|
||||||
url: "https://pub.dartlang.org"
|
url: "https://pub.dartlang.org"
|
||||||
source: hosted
|
source: hosted
|
||||||
version: "0.2.5"
|
version: "0.3.0"
|
||||||
timing:
|
timing:
|
||||||
dependency: transitive
|
dependency: transitive
|
||||||
description:
|
description:
|
||||||
|
@ -428,14 +449,14 @@ packages:
|
||||||
name: typed_data
|
name: typed_data
|
||||||
url: "https://pub.dartlang.org"
|
url: "https://pub.dartlang.org"
|
||||||
source: hosted
|
source: hosted
|
||||||
version: "1.1.6"
|
version: "1.3.0"
|
||||||
vector_math:
|
vector_math:
|
||||||
dependency: transitive
|
dependency: transitive
|
||||||
description:
|
description:
|
||||||
name: vector_math
|
name: vector_math
|
||||||
url: "https://pub.dartlang.org"
|
url: "https://pub.dartlang.org"
|
||||||
source: hosted
|
source: hosted
|
||||||
version: "2.0.8"
|
version: "2.1.0"
|
||||||
watcher:
|
watcher:
|
||||||
dependency: transitive
|
dependency: transitive
|
||||||
description:
|
description:
|
||||||
|
@ -465,5 +486,5 @@ packages:
|
||||||
source: hosted
|
source: hosted
|
||||||
version: "2.1.16"
|
version: "2.1.16"
|
||||||
sdks:
|
sdks:
|
||||||
dart: ">=2.3.0 <3.0.0"
|
dart: ">=2.12.0 <3.0.0"
|
||||||
flutter: ">=1.5.0 <2.0.0"
|
flutter: ">=1.5.0"
|
||||||
|
|
Loading…
Add table
Reference in a new issue