Commit 321694ab authored by jinzhu's avatar jinzhu

update

parent 6d4fbd9f
package io.flutter.facade; package io.flutter.facade;
import android.app.Activity; import android.app.Activity;
import android.content.Context;
import android.os.Bundle;
import android.arch.lifecycle.Lifecycle; import android.arch.lifecycle.Lifecycle;
import android.arch.lifecycle.LifecycleObserver; import android.arch.lifecycle.LifecycleObserver;
import android.arch.lifecycle.OnLifecycleEvent; import android.arch.lifecycle.OnLifecycleEvent;
import android.content.Context;
import android.os.Bundle;
import android.support.annotation.NonNull; import android.support.annotation.NonNull;
import io.flutter.plugin.common.BasicMessageChannel; import io.flutter.plugin.common.BasicMessageChannel;
import io.flutter.plugin.common.StringCodec; import io.flutter.plugin.common.StringCodec;
import io.flutter.plugins.GeneratedPluginRegistrant;
import io.flutter.view.FlutterMain; import io.flutter.view.FlutterMain;
import io.flutter.view.FlutterNativeView; import io.flutter.view.FlutterNativeView;
import io.flutter.view.FlutterRunArguments; import io.flutter.view.FlutterRunArguments;
import io.flutter.view.FlutterView; import io.flutter.view.FlutterView;
import io.flutter.plugins.GeneratedPluginRegistrant;
/** /**
* Main entry point for using Flutter in Android applications. * Main entry point for using Flutter in Android applications.
......
...@@ -2,12 +2,12 @@ package io.flutter.facade; ...@@ -2,12 +2,12 @@ package io.flutter.facade;
import android.content.Context; import android.content.Context;
import android.os.Bundle; import android.os.Bundle;
import android.support.annotation.NonNull;
import android.support.v4.app.Fragment;
import android.util.AttributeSet; import android.util.AttributeSet;
import android.view.LayoutInflater; import android.view.LayoutInflater;
import android.view.ViewGroup; import android.view.ViewGroup;
import android.support.annotation.NonNull;
import android.support.v4.app.Fragment;
import io.flutter.view.FlutterView; import io.flutter.view.FlutterView;
/** /**
......
...@@ -38,7 +38,7 @@ dependencies { ...@@ -38,7 +38,7 @@ dependencies {
implementation 'com.android.support:appcompat-v7:27.1.1' implementation 'com.android.support:appcompat-v7:27.1.1'
implementation 'com.android.support.constraint:constraint-layout:1.1.2' implementation 'com.android.support.constraint:constraint-layout:1.1.2'
implementation 'com.android.support:design:27.1.1' implementation 'com.android.support:design:27.1.1'
testImplementation 'junit:junit:4.12'
androidTestImplementation 'com.android.support.test:runner:1.0.2' androidTestImplementation 'com.android.support.test:runner:1.0.2'
androidTestImplementation 'com.android.support.test.espresso:espresso-core:3.0.2' androidTestImplementation 'com.android.support.test.espresso:espresso-core:3.0.2'
testImplementation 'junit:junit:4.12'
} }
org.gradle.jvmargs=-Xmx1536M org.gradle.jvmargs=-Xmx1536M
...@@ -3,4 +3,4 @@ include ':app' ...@@ -3,4 +3,4 @@ include ':app'
rootProject.name = 'android_generated' rootProject.name = 'android_generated'
setBinding(new Binding([gradle: this])) setBinding(new Binding([gradle: this]))
evaluate(new File('include_flutter.groovy')) evaluate(new File(settingsDir, 'include_flutter.groovy'))
...@@ -3,7 +3,7 @@ ...@@ -3,7 +3,7 @@
<plist version="1.0"> <plist version="1.0">
<dict> <dict>
<key>CFBundleDevelopmentRegion</key> <key>CFBundleDevelopmentRegion</key>
<string>en</string> <string>$(DEVELOPMENT_LANGUAGE)</string>
<key>CFBundleExecutable</key> <key>CFBundleExecutable</key>
<string>App</string> <string>App</string>
<key>CFBundleIdentifier</key> <key>CFBundleIdentifier</key>
......
// This is a generated file; do not edit or check into version control. // This is a generated file; do not edit or check into version control.
FLUTTER_ROOT=/Users/mac/development/flutter FLUTTER_ROOT=/Users/mac/development/flutter
FLUTTER_APPLICATION_PATH=/Users/mac/code/gmalpha_flutter FLUTTER_APPLICATION_PATH=/Users/mac/code/gmalpha_flutter
FLUTTER_TARGET=lib/main.dart FLUTTER_TARGET=/Users/mac/code/gmalpha_flutter/lib/main.dart
FLUTTER_BUILD_DIR=build FLUTTER_BUILD_DIR=build
SYMROOT=${SOURCE_ROOT}/../build/ios SYMROOT=${SOURCE_ROOT}/../build/ios
FLUTTER_BUILD_NAME=1.0.0 FLUTTER_BUILD_NAME=1.0.0
......
...@@ -23,7 +23,7 @@ end ...@@ -23,7 +23,7 @@ end
def flutter_root(f) def flutter_root(f)
generated_xcode_build_settings = parse_KV_file(File.join(f, File.join('.ios', 'Flutter', 'Generated.xcconfig'))) generated_xcode_build_settings = parse_KV_file(File.join(f, File.join('.ios', 'Flutter', 'Generated.xcconfig')))
if generated_xcode_build_settings.empty? if generated_xcode_build_settings.empty?
puts "Generated.xcconfig must exist. Make sure `flutter packages get` is executed in #{f}." puts "Generated.xcconfig must exist. Make sure `flutter pub get` is executed in #{f}."
exit exit
end end
generated_xcode_build_settings.map { |p| generated_xcode_build_settings.map { |p|
......
platform :ios, '8.0' platform :ios, '8.0'
#open source
source 'https://github.com/CocoaPods/Specs.git'
#our company
source 'git@git.wanmeizhensuo.com:gengmeiios/GMSpecs.git'
target 'Runner' do target 'Runner' do
flutter_application_path = '../' flutter_application_path = '../'
eval(File.read(File.join(flutter_application_path, '.ios', 'Flutter', 'podhelper.rb')), binding) eval(File.read(File.join(flutter_application_path, '.ios', 'Flutter', 'podhelper.rb')), binding)
......
...@@ -7,7 +7,6 @@ ...@@ -7,7 +7,6 @@
objects = { objects = {
/* Begin PBXBuildFile section */ /* Begin PBXBuildFile section */
741F496221355F47001E2961 /* Flutter.framework in Embed Frameworks */ = {isa = PBXBuildFile; fileRef = 741F495E21355F27001E2961 /* Flutter.framework */; settings = {ATTRIBUTES = (CodeSignOnCopy, RemoveHeadersOnCopy, ); }; };
741F496821356857001E2961 /* App.framework in Embed Frameworks */ = {isa = PBXBuildFile; fileRef = 741F496521356807001E2961 /* App.framework */; settings = {ATTRIBUTES = (CodeSignOnCopy, RemoveHeadersOnCopy, ); }; }; 741F496821356857001E2961 /* App.framework in Embed Frameworks */ = {isa = PBXBuildFile; fileRef = 741F496521356807001E2961 /* App.framework */; settings = {ATTRIBUTES = (CodeSignOnCopy, RemoveHeadersOnCopy, ); }; };
74974048213559DB008C567A /* Release.xcconfig in Resources */ = {isa = PBXBuildFile; fileRef = 74974046213559DB008C567A /* Release.xcconfig */; }; 74974048213559DB008C567A /* Release.xcconfig in Resources */ = {isa = PBXBuildFile; fileRef = 74974046213559DB008C567A /* Release.xcconfig */; };
74974049213559DB008C567A /* Debug.xcconfig in Resources */ = {isa = PBXBuildFile; fileRef = 74974047213559DB008C567A /* Debug.xcconfig */; }; 74974049213559DB008C567A /* Debug.xcconfig in Resources */ = {isa = PBXBuildFile; fileRef = 74974047213559DB008C567A /* Debug.xcconfig */; };
...@@ -17,6 +16,7 @@ ...@@ -17,6 +16,7 @@
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 */; };
97C147011CF9000F007C117D /* LaunchScreen.storyboard in Resources */ = {isa = PBXBuildFile; fileRef = 97C146FF1CF9000F007C117D /* LaunchScreen.storyboard */; }; 97C147011CF9000F007C117D /* LaunchScreen.storyboard in Resources */ = {isa = PBXBuildFile; fileRef = 97C146FF1CF9000F007C117D /* LaunchScreen.storyboard */; };
DA920DF7267BFA3D8637F495 /* libPods-Runner.a in Frameworks */ = {isa = PBXBuildFile; fileRef = 35774BCD44364EC525CFFDCC /* libPods-Runner.a */; };
/* End PBXBuildFile section */ /* End PBXBuildFile section */
/* Begin PBXCopyFilesBuildPhase section */ /* Begin PBXCopyFilesBuildPhase section */
...@@ -27,7 +27,6 @@ ...@@ -27,7 +27,6 @@
dstSubfolderSpec = 10; dstSubfolderSpec = 10;
files = ( files = (
741F496821356857001E2961 /* App.framework in Embed Frameworks */, 741F496821356857001E2961 /* App.framework in Embed Frameworks */,
741F496221355F47001E2961 /* Flutter.framework in Embed Frameworks */,
); );
name = "Embed Frameworks"; name = "Embed Frameworks";
runOnlyForDeploymentPostprocessing = 0; runOnlyForDeploymentPostprocessing = 0;
...@@ -35,6 +34,9 @@ ...@@ -35,6 +34,9 @@
/* End PBXCopyFilesBuildPhase section */ /* End PBXCopyFilesBuildPhase section */
/* Begin PBXFileReference section */ /* Begin PBXFileReference section */
02E16F65B185B1E5853D0A9D /* 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>"; };
35774BCD44364EC525CFFDCC /* libPods-Runner.a */ = {isa = PBXFileReference; explicitFileType = archive.ar; includeInIndex = 0; path = "libPods-Runner.a"; sourceTree = BUILT_PRODUCTS_DIR; };
5372C2777A642A45C90EA956 /* Pods-Runner.release.xcconfig */ = {isa = PBXFileReference; includeInIndex = 1; lastKnownFileType = text.xcconfig; name = "Pods-Runner.release.xcconfig"; path = "Target Support Files/Pods-Runner/Pods-Runner.release.xcconfig"; sourceTree = "<group>"; };
741F495E21355F27001E2961 /* Flutter.framework */ = {isa = PBXFileReference; lastKnownFileType = wrapper.framework; name = Flutter.framework; path = ../.ios/Flutter/engine/Flutter.framework; sourceTree = "<group>"; }; 741F495E21355F27001E2961 /* Flutter.framework */ = {isa = PBXFileReference; lastKnownFileType = wrapper.framework; name = Flutter.framework; path = ../.ios/Flutter/engine/Flutter.framework; sourceTree = "<group>"; };
741F496521356807001E2961 /* App.framework */ = {isa = PBXFileReference; lastKnownFileType = wrapper.framework; name = App.framework; path = ../.ios/Flutter/App.framework; sourceTree = "<group>"; }; 741F496521356807001E2961 /* App.framework */ = {isa = PBXFileReference; lastKnownFileType = wrapper.framework; name = App.framework; path = ../.ios/Flutter/App.framework; sourceTree = "<group>"; };
74974046213559DB008C567A /* Release.xcconfig */ = {isa = PBXFileReference; fileEncoding = 4; lastKnownFileType = text.xcconfig; path = Release.xcconfig; sourceTree = "<group>"; }; 74974046213559DB008C567A /* Release.xcconfig */ = {isa = PBXFileReference; fileEncoding = 4; lastKnownFileType = text.xcconfig; path = Release.xcconfig; sourceTree = "<group>"; };
...@@ -49,6 +51,7 @@ ...@@ -49,6 +51,7 @@
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>"; };
97C147001CF9000F007C117D /* Base */ = {isa = PBXFileReference; lastKnownFileType = file.storyboard; name = Base; path = Base.lproj/LaunchScreen.storyboard; sourceTree = "<group>"; }; 97C147001CF9000F007C117D /* Base */ = {isa = PBXFileReference; lastKnownFileType = file.storyboard; name = Base; path = Base.lproj/LaunchScreen.storyboard; sourceTree = "<group>"; };
97C147021CF9000F007C117D /* Info.plist */ = {isa = PBXFileReference; lastKnownFileType = text.plist.xml; path = Info.plist; sourceTree = "<group>"; }; 97C147021CF9000F007C117D /* Info.plist */ = {isa = PBXFileReference; lastKnownFileType = text.plist.xml; path = Info.plist; sourceTree = "<group>"; };
C42C8CC40B760DD2C88D43D5 /* 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>"; };
/* End PBXFileReference section */ /* End PBXFileReference section */
/* Begin PBXFrameworksBuildPhase section */ /* Begin PBXFrameworksBuildPhase section */
...@@ -56,6 +59,7 @@ ...@@ -56,6 +59,7 @@
isa = PBXFrameworksBuildPhase; isa = PBXFrameworksBuildPhase;
buildActionMask = 2147483647; buildActionMask = 2147483647;
files = ( files = (
DA920DF7267BFA3D8637F495 /* libPods-Runner.a in Frameworks */,
); );
runOnlyForDeploymentPostprocessing = 0; runOnlyForDeploymentPostprocessing = 0;
}; };
...@@ -72,6 +76,14 @@ ...@@ -72,6 +76,14 @@
path = Config; path = Config;
sourceTree = "<group>"; sourceTree = "<group>";
}; };
8D3D68B3993FF6F5F7F88296 /* Frameworks */ = {
isa = PBXGroup;
children = (
35774BCD44364EC525CFFDCC /* libPods-Runner.a */,
);
name = Frameworks;
sourceTree = "<group>";
};
9740EEB11CF90186004384FC /* Flutter */ = { 9740EEB11CF90186004384FC /* Flutter */ = {
isa = PBXGroup; isa = PBXGroup;
children = ( children = (
...@@ -89,6 +101,8 @@ ...@@ -89,6 +101,8 @@
9740EEB11CF90186004384FC /* Flutter */, 9740EEB11CF90186004384FC /* Flutter */,
97C146F01CF9000F007C117D /* Runner */, 97C146F01CF9000F007C117D /* Runner */,
97C146EF1CF9000F007C117D /* Products */, 97C146EF1CF9000F007C117D /* Products */,
F7282BDAEDDF68E0EE2727F1 /* Pods */,
8D3D68B3993FF6F5F7F88296 /* Frameworks */,
); );
sourceTree = "<group>"; sourceTree = "<group>";
}; };
...@@ -122,6 +136,16 @@ ...@@ -122,6 +136,16 @@
name = "Supporting Files"; name = "Supporting Files";
sourceTree = "<group>"; sourceTree = "<group>";
}; };
F7282BDAEDDF68E0EE2727F1 /* Pods */ = {
isa = PBXGroup;
children = (
C42C8CC40B760DD2C88D43D5 /* Pods-Runner.debug.xcconfig */,
5372C2777A642A45C90EA956 /* Pods-Runner.release.xcconfig */,
02E16F65B185B1E5853D0A9D /* Pods-Runner.profile.xcconfig */,
);
path = Pods;
sourceTree = "<group>";
};
/* End PBXGroup section */ /* End PBXGroup section */
/* Begin PBXNativeTarget section */ /* Begin PBXNativeTarget section */
...@@ -129,12 +153,14 @@ ...@@ -129,12 +153,14 @@
isa = PBXNativeTarget; isa = PBXNativeTarget;
buildConfigurationList = 97C147051CF9000F007C117D /* Build configuration list for PBXNativeTarget "Runner" */; buildConfigurationList = 97C147051CF9000F007C117D /* Build configuration list for PBXNativeTarget "Runner" */;
buildPhases = ( buildPhases = (
5448CCD2387487D8249AAB6E /* [CP] Check Pods Manifest.lock */,
9740EEB61CF901F6004384FC /* Run Script */, 9740EEB61CF901F6004384FC /* Run Script */,
97C146EA1CF9000F007C117D /* Sources */, 97C146EA1CF9000F007C117D /* Sources */,
97C146EB1CF9000F007C117D /* Frameworks */, 97C146EB1CF9000F007C117D /* Frameworks */,
97C146EC1CF9000F007C117D /* Resources */, 97C146EC1CF9000F007C117D /* Resources */,
3B06AD1E1E4923F5004D2608 /* Thin Binary */, 3B06AD1E1E4923F5004D2608 /* Thin Binary */,
741F496321355F47001E2961 /* Embed Frameworks */, 741F496321355F47001E2961 /* Embed Frameworks */,
6C71C66E015792C2A881863B /* [CP] Embed Pods Frameworks */,
); );
buildRules = ( buildRules = (
); );
...@@ -151,7 +177,7 @@ ...@@ -151,7 +177,7 @@
97C146E61CF9000F007C117D /* Project object */ = { 97C146E61CF9000F007C117D /* Project object */ = {
isa = PBXProject; isa = PBXProject;
attributes = { attributes = {
LastUpgradeCheck = 0910; LastUpgradeCheck = 1020;
ORGANIZATIONNAME = "The Chromium Authors"; ORGANIZATIONNAME = "The Chromium Authors";
TargetAttributes = { TargetAttributes = {
97C146ED1CF9000F007C117D = { 97C146ED1CF9000F007C117D = {
...@@ -161,7 +187,7 @@ ...@@ -161,7 +187,7 @@
}; };
buildConfigurationList = 97C146E91CF9000F007C117D /* Build configuration list for PBXProject "Runner" */; buildConfigurationList = 97C146E91CF9000F007C117D /* Build configuration list for PBXProject "Runner" */;
compatibilityVersion = "Xcode 3.2"; compatibilityVersion = "Xcode 3.2";
developmentRegion = English; developmentRegion = en;
hasScannedForEncodings = 0; hasScannedForEncodings = 0;
knownRegions = ( knownRegions = (
en, en,
...@@ -208,6 +234,46 @@ ...@@ -208,6 +234,46 @@
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\" thin";
}; };
5448CCD2387487D8249AAB6E /* [CP] Check Pods Manifest.lock */ = {
isa = PBXShellScriptBuildPhase;
buildActionMask = 2147483647;
files = (
);
inputFileListPaths = (
);
inputPaths = (
"${PODS_PODFILE_DIR_PATH}/Podfile.lock",
"${PODS_ROOT}/Manifest.lock",
);
name = "[CP] Check Pods Manifest.lock";
outputFileListPaths = (
);
outputPaths = (
"$(DERIVED_FILE_DIR)/Pods-Runner-checkManifestLockResult.txt",
);
runOnlyForDeploymentPostprocessing = 0;
shellPath = /bin/sh;
shellScript = "diff \"${PODS_PODFILE_DIR_PATH}/Podfile.lock\" \"${PODS_ROOT}/Manifest.lock\" > /dev/null\nif [ $? != 0 ] ; then\n # print error to STDERR\n echo \"error: The sandbox is not in sync with the Podfile.lock. Run 'pod install' or update your CocoaPods installation.\" >&2\n exit 1\nfi\n# This output is used by Xcode 'outputs' to avoid re-running this script phase.\necho \"SUCCESS\" > \"${SCRIPT_OUTPUT_FILE_0}\"\n";
showEnvVarsInLog = 0;
};
6C71C66E015792C2A881863B /* [CP] Embed Pods Frameworks */ = {
isa = PBXShellScriptBuildPhase;
buildActionMask = 2147483647;
files = (
);
inputPaths = (
"${PODS_ROOT}/Target Support Files/Pods-Runner/Pods-Runner-frameworks.sh",
"${PODS_ROOT}/../Flutter/engine/Flutter.framework",
);
name = "[CP] Embed Pods Frameworks";
outputPaths = (
"${TARGET_BUILD_DIR}/${FRAMEWORKS_FOLDER_PATH}/Flutter.framework",
);
runOnlyForDeploymentPostprocessing = 0;
shellPath = /bin/sh;
shellScript = "\"${PODS_ROOT}/Target Support Files/Pods-Runner/Pods-Runner-frameworks.sh\"\n";
showEnvVarsInLog = 0;
};
9740EEB61CF901F6004384FC /* Run Script */ = { 9740EEB61CF901F6004384FC /* Run Script */ = {
isa = PBXShellScriptBuildPhase; isa = PBXShellScriptBuildPhase;
buildActionMask = 2147483647; buildActionMask = 2147483647;
...@@ -270,12 +336,14 @@ ...@@ -270,12 +336,14 @@
CLANG_WARN_BOOL_CONVERSION = YES; CLANG_WARN_BOOL_CONVERSION = YES;
CLANG_WARN_COMMA = YES; CLANG_WARN_COMMA = YES;
CLANG_WARN_CONSTANT_CONVERSION = YES; CLANG_WARN_CONSTANT_CONVERSION = YES;
CLANG_WARN_DEPRECATED_OBJC_IMPLEMENTATIONS = YES;
CLANG_WARN_DIRECT_OBJC_ISA_USAGE = YES_ERROR; CLANG_WARN_DIRECT_OBJC_ISA_USAGE = YES_ERROR;
CLANG_WARN_EMPTY_BODY = YES; CLANG_WARN_EMPTY_BODY = YES;
CLANG_WARN_ENUM_CONVERSION = YES; CLANG_WARN_ENUM_CONVERSION = YES;
CLANG_WARN_INFINITE_RECURSION = YES; CLANG_WARN_INFINITE_RECURSION = YES;
CLANG_WARN_INT_CONVERSION = YES; CLANG_WARN_INT_CONVERSION = YES;
CLANG_WARN_NON_LITERAL_NULL_CONVERSION = YES; CLANG_WARN_NON_LITERAL_NULL_CONVERSION = YES;
CLANG_WARN_OBJC_IMPLICIT_RETAIN_SELF = YES;
CLANG_WARN_OBJC_LITERAL_CONVERSION = YES; CLANG_WARN_OBJC_LITERAL_CONVERSION = YES;
CLANG_WARN_OBJC_ROOT_CLASS = YES_ERROR; CLANG_WARN_OBJC_ROOT_CLASS = YES_ERROR;
CLANG_WARN_RANGE_LOOP_ANALYSIS = YES; CLANG_WARN_RANGE_LOOP_ANALYSIS = YES;
...@@ -310,7 +378,7 @@ ...@@ -310,7 +378,7 @@
buildSettings = { buildSettings = {
ASSETCATALOG_COMPILER_APPICON_NAME = AppIcon; ASSETCATALOG_COMPILER_APPICON_NAME = AppIcon;
CURRENT_PROJECT_VERSION = "$(FLUTTER_BUILD_NUMBER)"; CURRENT_PROJECT_VERSION = "$(FLUTTER_BUILD_NUMBER)";
DEVELOPMENT_TEAM = S8QB4VV633; DEVELOPMENT_TEAM = "";
ENABLE_BITCODE = NO; ENABLE_BITCODE = NO;
FRAMEWORK_SEARCH_PATHS = ( FRAMEWORK_SEARCH_PATHS = (
"$(inherited)", "$(inherited)",
...@@ -341,12 +409,14 @@ ...@@ -341,12 +409,14 @@
CLANG_WARN_BOOL_CONVERSION = YES; CLANG_WARN_BOOL_CONVERSION = YES;
CLANG_WARN_COMMA = YES; CLANG_WARN_COMMA = YES;
CLANG_WARN_CONSTANT_CONVERSION = YES; CLANG_WARN_CONSTANT_CONVERSION = YES;
CLANG_WARN_DEPRECATED_OBJC_IMPLEMENTATIONS = YES;
CLANG_WARN_DIRECT_OBJC_ISA_USAGE = YES_ERROR; CLANG_WARN_DIRECT_OBJC_ISA_USAGE = YES_ERROR;
CLANG_WARN_EMPTY_BODY = YES; CLANG_WARN_EMPTY_BODY = YES;
CLANG_WARN_ENUM_CONVERSION = YES; CLANG_WARN_ENUM_CONVERSION = YES;
CLANG_WARN_INFINITE_RECURSION = YES; CLANG_WARN_INFINITE_RECURSION = YES;
CLANG_WARN_INT_CONVERSION = YES; CLANG_WARN_INT_CONVERSION = YES;
CLANG_WARN_NON_LITERAL_NULL_CONVERSION = YES; CLANG_WARN_NON_LITERAL_NULL_CONVERSION = YES;
CLANG_WARN_OBJC_IMPLICIT_RETAIN_SELF = YES;
CLANG_WARN_OBJC_LITERAL_CONVERSION = YES; CLANG_WARN_OBJC_LITERAL_CONVERSION = YES;
CLANG_WARN_OBJC_ROOT_CLASS = YES_ERROR; CLANG_WARN_OBJC_ROOT_CLASS = YES_ERROR;
CLANG_WARN_RANGE_LOOP_ANALYSIS = YES; CLANG_WARN_RANGE_LOOP_ANALYSIS = YES;
...@@ -394,12 +464,14 @@ ...@@ -394,12 +464,14 @@
CLANG_WARN_BOOL_CONVERSION = YES; CLANG_WARN_BOOL_CONVERSION = YES;
CLANG_WARN_COMMA = YES; CLANG_WARN_COMMA = YES;
CLANG_WARN_CONSTANT_CONVERSION = YES; CLANG_WARN_CONSTANT_CONVERSION = YES;
CLANG_WARN_DEPRECATED_OBJC_IMPLEMENTATIONS = YES;
CLANG_WARN_DIRECT_OBJC_ISA_USAGE = YES_ERROR; CLANG_WARN_DIRECT_OBJC_ISA_USAGE = YES_ERROR;
CLANG_WARN_EMPTY_BODY = YES; CLANG_WARN_EMPTY_BODY = YES;
CLANG_WARN_ENUM_CONVERSION = YES; CLANG_WARN_ENUM_CONVERSION = YES;
CLANG_WARN_INFINITE_RECURSION = YES; CLANG_WARN_INFINITE_RECURSION = YES;
CLANG_WARN_INT_CONVERSION = YES; CLANG_WARN_INT_CONVERSION = YES;
CLANG_WARN_NON_LITERAL_NULL_CONVERSION = YES; CLANG_WARN_NON_LITERAL_NULL_CONVERSION = YES;
CLANG_WARN_OBJC_IMPLICIT_RETAIN_SELF = YES;
CLANG_WARN_OBJC_LITERAL_CONVERSION = YES; CLANG_WARN_OBJC_LITERAL_CONVERSION = YES;
CLANG_WARN_OBJC_ROOT_CLASS = YES_ERROR; CLANG_WARN_OBJC_ROOT_CLASS = YES_ERROR;
CLANG_WARN_RANGE_LOOP_ANALYSIS = YES; CLANG_WARN_RANGE_LOOP_ANALYSIS = YES;
...@@ -434,6 +506,7 @@ ...@@ -434,6 +506,7 @@
buildSettings = { buildSettings = {
ASSETCATALOG_COMPILER_APPICON_NAME = AppIcon; ASSETCATALOG_COMPILER_APPICON_NAME = AppIcon;
CURRENT_PROJECT_VERSION = "$(FLUTTER_BUILD_NUMBER)"; CURRENT_PROJECT_VERSION = "$(FLUTTER_BUILD_NUMBER)";
DEVELOPMENT_TEAM = "";
ENABLE_BITCODE = NO; ENABLE_BITCODE = NO;
FRAMEWORK_SEARCH_PATHS = ( FRAMEWORK_SEARCH_PATHS = (
"$(inherited)", "$(inherited)",
...@@ -458,6 +531,7 @@ ...@@ -458,6 +531,7 @@
buildSettings = { buildSettings = {
ASSETCATALOG_COMPILER_APPICON_NAME = AppIcon; ASSETCATALOG_COMPILER_APPICON_NAME = AppIcon;
CURRENT_PROJECT_VERSION = "$(FLUTTER_BUILD_NUMBER)"; CURRENT_PROJECT_VERSION = "$(FLUTTER_BUILD_NUMBER)";
DEVELOPMENT_TEAM = "";
ENABLE_BITCODE = NO; ENABLE_BITCODE = NO;
FRAMEWORK_SEARCH_PATHS = ( FRAMEWORK_SEARCH_PATHS = (
"$(inherited)", "$(inherited)",
...@@ -500,7 +574,6 @@ ...@@ -500,7 +574,6 @@
defaultConfigurationName = Release; defaultConfigurationName = Release;
}; };
/* End XCConfigurationList section */ /* End XCConfigurationList section */
}; };
rootObject = 97C146E61CF9000F007C117D /* Project object */; rootObject = 97C146E61CF9000F007C117D /* Project object */;
} }
<?xml version="1.0" encoding="UTF-8"?> <?xml version="1.0" encoding="UTF-8"?>
<Scheme <Scheme
LastUpgradeVersion = "0910" LastUpgradeVersion = "1020"
version = "1.3"> version = "1.3">
<BuildAction <BuildAction
parallelizeBuildables = "YES" parallelizeBuildables = "YES"
...@@ -26,7 +26,6 @@ ...@@ -26,7 +26,6 @@
buildConfiguration = "Debug" buildConfiguration = "Debug"
selectedDebuggerIdentifier = "Xcode.DebuggerFoundation.Debugger.LLDB" selectedDebuggerIdentifier = "Xcode.DebuggerFoundation.Debugger.LLDB"
selectedLauncherIdentifier = "Xcode.DebuggerFoundation.Launcher.LLDB" selectedLauncherIdentifier = "Xcode.DebuggerFoundation.Launcher.LLDB"
language = ""
shouldUseLaunchSchemeArgsEnv = "YES"> shouldUseLaunchSchemeArgsEnv = "YES">
<Testables> <Testables>
</Testables> </Testables>
...@@ -46,7 +45,6 @@ ...@@ -46,7 +45,6 @@
buildConfiguration = "Debug" buildConfiguration = "Debug"
selectedDebuggerIdentifier = "Xcode.DebuggerFoundation.Debugger.LLDB" selectedDebuggerIdentifier = "Xcode.DebuggerFoundation.Debugger.LLDB"
selectedLauncherIdentifier = "Xcode.DebuggerFoundation.Launcher.LLDB" selectedLauncherIdentifier = "Xcode.DebuggerFoundation.Launcher.LLDB"
language = ""
launchStyle = "0" launchStyle = "0"
useCustomWorkingDirectory = "NO" useCustomWorkingDirectory = "NO"
ignoresPersistentStateOnLaunch = "NO" ignoresPersistentStateOnLaunch = "NO"
......
...@@ -4,4 +4,7 @@ ...@@ -4,4 +4,7 @@
<FileRef <FileRef
location = "group:Runner.xcodeproj"> location = "group:Runner.xcodeproj">
</FileRef> </FileRef>
<FileRef
location = "group:Pods/Pods.xcodeproj">
</FileRef>
</Workspace> </Workspace>
...@@ -3,7 +3,7 @@ ...@@ -3,7 +3,7 @@
<plist version="1.0"> <plist version="1.0">
<dict> <dict>
<key>CFBundleDevelopmentRegion</key> <key>CFBundleDevelopmentRegion</key>
<string>en</string> <string>$(DEVELOPMENT_LANGUAGE)</string>
<key>CFBundleExecutable</key> <key>CFBundleExecutable</key>
<string>$(EXECUTABLE_NAME)</string> <string>$(EXECUTABLE_NAME)</string>
<key>CFBundleIdentifier</key> <key>CFBundleIdentifier</key>
......
...@@ -23,17 +23,9 @@ class _MyAppState extends State<MyApp> { ...@@ -23,17 +23,9 @@ class _MyAppState extends State<MyApp> {
_init(); _init();
FlutterBoost.singleton.registerPageBuilders({ FlutterBoost.singleton.registerPageBuilders({
// 'first': (pageName, params, _) => FirstRouteWidget(),
// 'second': (pageName, params, _) => SecondRouteWidget(),
// 'tab': (pageName, params, _) => TabRouteWidget(),
// 'flutterFragment': (pageName, params, _) => FragmentRouteWidget(params),
'comment_suggest': (pageName, params, _) => CommentSuggest(params), 'comment_suggest': (pageName, params, _) => CommentSuggest(params),
// ///可以在native层通过 getContainerParams 来传递参数 'message_home': (pageName, params, _) => MessageHomePage(),
// 'flutterPage': (pageName, params, _) {
// print("flutterPage params:$params");
// return FlutterRouteWidget();
// },
}); });
FlutterBoost.handleOnStartPage(); FlutterBoost.handleOnStartPage();
} }
......
import 'dart:convert';
import 'package:flutter/material.dart'; import 'package:flutter/material.dart';
import 'package:gmalpha_flutter/model/message/message.dart' as prefix0; // import 'package:gmalpha_flutter/model/message/message.dart' as prefix0;
import 'package:gmalpha_flutter/pages/message/home/message_notification_item.dart'; import 'package:gmalpha_flutter/pages/message/home/message_notification_item.dart';
import 'message_item.dart'; import 'message_item.dart';
import 'package:gmalpha_flutter/model/message/message.dart'; import 'package:gmalpha_flutter/model/message/message.dart';
import 'package:gmalpha_flutter/netWork/DioUtil.dart'; import 'package:gmalpha_flutter/netWork/DioUtil.dart';
import 'package:gmalpha_flutter/toast/toast.dart'; import 'package:pull_to_refresh/pull_to_refresh.dart';
import 'package:flutter_easyrefresh/easy_refresh.dart';
import 'package:flutter/semantics.dart';
class MessageHomePage extends StatefulWidget { class MessageHomePage extends StatefulWidget {
@override @override
_MessageHomePageState createState() => _MessageHomePageState(); _MessageHomePageState createState() => _MessageHomePageState();
} }
class _MessageHomePageState extends State<MessageHomePage> with AutomaticKeepAliveClientMixin { class _MessageHomePageState extends State<MessageHomePage> {
List<ListItem> messageList = List<ListItem>(); List<ListItem> messageList = List<ListItem>();
List<ListItem> dataArr = List<ListItem>(); List<ListItem> dataArr = List<ListItem>();
int pageIndex = 1;
@override RefreshController _refreshController =
bool get wantKeepAlive => true; RefreshController(initialRefresh: true);
void _onRefresh() async{
// dataArr = await _fetchListData();
// if (mounted) setState(() {
// dataArr = dataArr;
// });
// _refreshController.refreshCompleted();
}
void _onLoading() async{
// monitor network fetch
// pageIndex ++;
// List<ListItem> newData = List<ListItem>();
// newData = await _fetchMesssageList();
// this.dataArr.addAll(newData);
// if (mounted) setState(() {
// dataArr = dataArr;
// });
// _refreshController.loadComplete();
}
Future<List<ListItem>> _fetchMesssageList() async { Future<List<ListItem>> _fetchMesssageList() async {
List<Message> messageList = List<Message>(); List<Message> messageList = List<Message>();
print('aaaaa');
BaseResp<List> baseresp = await DioUtil().request<List>(Method.get, "api/v1/reply/my", queryParameters: {'page': 1, 'count': 10}); BaseResp<List> baseresp = await DioUtil().request<List>(Method.get, "api/v1/reply/my", queryParameters: {'page': 1, 'count': 10});
if (baseresp.code != 0) { if (baseresp.code != 0) {
return new Future.error(baseresp.msg); return new Future.error(baseresp.msg);
...@@ -36,11 +53,11 @@ class _MessageHomePageState extends State<MessageHomePage> with AutomaticKeepAli ...@@ -36,11 +53,11 @@ class _MessageHomePageState extends State<MessageHomePage> with AutomaticKeepAli
return Message.fromJson(value); return Message.fromJson(value);
}).toList(); }).toList();
} }
_refreshController.refreshCompleted();
return messageList; return messageList;
} }
Future<List<ListItem>> _fetchNewestInfo() async { Future<List<ListItem>> _fetchNewestInfo() async {
print('---------start----------');
List<ListItem> notiData = List<ListItem>(); List<ListItem> notiData = List<ListItem>();
BaseRespR noteResp = await DioUtil().requestR(Method.get, 'api/v1/push/newest/info'); BaseRespR noteResp = await DioUtil().requestR(Method.get, 'api/v1/push/newest/info');
Map noteData = noteResp.data; Map noteData = noteResp.data;
...@@ -71,51 +88,64 @@ class _MessageHomePageState extends State<MessageHomePage> with AutomaticKeepAli ...@@ -71,51 +88,64 @@ class _MessageHomePageState extends State<MessageHomePage> with AutomaticKeepAli
} }
Future<List<ListItem>> _fetchListData() async { Future<List<ListItem>> _fetchListData() async {
print('---------start---------');
List<ListItem> dataArr = List<ListItem>(); List<ListItem> dataArr = List<ListItem>();
dataArr = await _fetchNewestInfo(); dataArr = await _fetchNewestInfo();
print(dataArr);
List<ListItem> messageData = await _fetchMesssageList(); List<ListItem> messageData = await _fetchMesssageList();
messageData.forEach((item) { messageData.forEach((item) {
dataArr.add(item); dataArr.add(item);
}); });
print(dataArr);
print('---------end---------');
return dataArr; return dataArr;
} }
@override @override
Widget build(BuildContext context) { Widget build(BuildContext context) {
return new Scaffold( return new Scaffold(
appBar: new AppBar( // appBar: new AppBar(
title: new Text('消息'), // title: new Text('消息'),
), // ),
floatingActionButton: new FloatingActionButton( // floatingActionButton: new FloatingActionButton(
onPressed: () { // onPressed: () {
_fetchListData(); // _fetchListData();
}, // },
child: new Icon(Icons.add_box), // child: new Icon(Icons.add_box),
elevation: 3.0, // elevation: 3.0,
highlightElevation: 2.0, // highlightElevation: 2.0,
backgroundColor: Colors.red, // 红色 // backgroundColor: Colors.red, // 红色
), // ),
body: new Container(
body: new Center( child: SmartRefresher(
child: FutureBuilder( // enablePullDown: false,
future: _fetchListData(), enablePullUp: true,
builder: (context, snapshot) { // header: WaterDropHeader(),
switch (snapshot.connectionState) { controller: _refreshController,
case ConnectionState.none: // onRefresh: _onRefresh,
case ConnectionState.waiting: onLoading: _onLoading,
break;
default: // footer: ClassicFooter(),
if (snapshot.hasData) { child: FutureBuilder(
return _createListView(context, snapshot); future: _fetchListData(),
builder: (context, snapshot) {
switch (snapshot.connectionState) {
case ConnectionState.none:
return new Container(height:0.0,width:0.0);
break;
case ConnectionState.waiting:
return new Container(height:0.0,width:0.0);
break;
case ConnectionState.active:
return new Container(height:0.0,width:0.0);
break;
default:
if (snapshot.hasData) {
return _createListView(context, snapshot);
} else {
return new Container(height:0.0,width:0.0);
}
} }
} },
}, ),
), ),
) )
); );
} }
...@@ -126,14 +156,15 @@ class _MessageHomePageState extends State<MessageHomePage> with AutomaticKeepAli ...@@ -126,14 +156,15 @@ class _MessageHomePageState extends State<MessageHomePage> with AutomaticKeepAli
shrinkWrap: true, shrinkWrap: true,
key: new PageStorageKey('message-list'), key: new PageStorageKey('message-list'),
itemCount: dataArr.length, itemCount: dataArr.length,
itemBuilder: (BuildContext context, int index) { itemBuilder: (context,index) {
ListItem item = dataArr[index]; ListItem item = dataArr[index];
if (item is Message) { if (item is Message) {
return new MessageItem(onPressed: (){}, message:item); return new MessageItem(onPressed: (){}, message:item);
} else if (item is NotificationItem){ } else if (item is NotificationItem){
return new MessageNotificationItem(onPressed: (){}, notification: item); return new MessageNotificationItem(onPressed: (){}, notification: item);
} else {
return Text('类型错误');
} }
}, },
); );
} }
......
...@@ -50,7 +50,7 @@ class MessageNotificationItem extends StatelessWidget { ...@@ -50,7 +50,7 @@ class MessageNotificationItem extends StatelessWidget {
), ),
); );
} else { } else {
content = new Container(height:0.0,width:0.0) content = new Container(height:0.0,width:0.0);
} }
return content; return content;
} }
......
# Generated by pub # Generated by pub
# See https://www.dartlang.org/tools/pub/glossary#lockfile # See https://dart.dev/tools/pub/glossary#lockfile
packages: packages:
analyzer: analyzer:
dependency: transitive dependency: transitive
...@@ -21,7 +21,7 @@ packages: ...@@ -21,7 +21,7 @@ packages:
name: async name: async
url: "https://pub.flutter-io.cn" url: "https://pub.flutter-io.cn"
source: hosted source: hosted
version: "2.1.0" version: "2.2.0"
boolean_selector: boolean_selector:
dependency: transitive dependency: transitive
description: description:
...@@ -176,13 +176,6 @@ packages: ...@@ -176,13 +176,6 @@ packages:
url: "https://github.com/alibaba/flutter_boost.git" url: "https://github.com/alibaba/flutter_boost.git"
source: git source: git
version: "0.0.411" version: "0.0.411"
flutter_easyrefresh:
dependency: "direct main"
description:
name: flutter_easyrefresh
url: "https://pub.flutter-io.cn"
source: hosted
version: "1.2.7"
flutter_test: flutter_test:
dependency: "direct dev" dependency: "direct dev"
description: flutter description: flutter
...@@ -336,7 +329,7 @@ packages: ...@@ -336,7 +329,7 @@ packages:
name: pedantic name: pedantic
url: "https://pub.flutter-io.cn" url: "https://pub.flutter-io.cn"
source: hosted source: hosted
version: "1.5.0" version: "1.7.0"
pool: pool:
dependency: transitive dependency: transitive
description: description:
...@@ -358,13 +351,20 @@ packages: ...@@ -358,13 +351,20 @@ packages:
url: "https://pub.flutter-io.cn" url: "https://pub.flutter-io.cn"
source: hosted source: hosted
version: "0.1.4" version: "0.1.4"
pull_to_refresh:
dependency: "direct main"
description:
name: pull_to_refresh
url: "https://pub.flutter-io.cn"
source: hosted
version: "1.5.0"
quiver: quiver:
dependency: transitive dependency: transitive
description: description:
name: quiver name: quiver
url: "https://pub.flutter-io.cn" url: "https://pub.flutter-io.cn"
source: hosted source: hosted
version: "2.0.2" version: "2.0.3"
rxdart: rxdart:
dependency: "direct main" dependency: "direct main"
description: description:
...@@ -446,7 +446,7 @@ packages: ...@@ -446,7 +446,7 @@ packages:
name: test_api name: test_api
url: "https://pub.flutter-io.cn" url: "https://pub.flutter-io.cn"
source: hosted source: hosted
version: "0.2.4" version: "0.2.5"
timing: timing:
dependency: transitive dependency: transitive
description: description:
......
...@@ -31,7 +31,8 @@ dependencies: ...@@ -31,7 +31,8 @@ dependencies:
rxdart: ^0.22.0 #链式编程 rxdart: ^0.22.0 #链式编程
json_serializable: ^3.0.0 #json to model json_serializable: ^3.0.0 #json to model
build_runner: ^1.6.1 build_runner: ^1.6.1
flutter_easyrefresh: ^1.2.7 # 上拉下拉刷新组件 pull_to_refresh: ^1.5.0
# flutter_easyrefresh: ^1.2.7 # 上拉下拉刷新组件
dev_dependencies: dev_dependencies:
......
Markdown is supported
0% or
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment