mirror of
https://github.com/lollipopkit/flutter_server_box.git
synced 2025-12-17 07:14:28 +01:00
Improve animation by using SKSL
This commit is contained in:
1
android.sksl.json
Normal file
1
android.sksl.json
Normal file
File diff suppressed because one or more lines are too long
1
ios.sksl.json
Normal file
1
ios.sksl.json
Normal file
File diff suppressed because one or more lines are too long
@@ -354,7 +354,7 @@
|
||||
buildSettings = {
|
||||
ASSETCATALOG_COMPILER_APPICON_NAME = AppIcon;
|
||||
CLANG_ENABLE_MODULES = YES;
|
||||
CURRENT_PROJECT_VERSION = 108;
|
||||
CURRENT_PROJECT_VERSION = 112;
|
||||
DEVELOPMENT_TEAM = BA88US33G6;
|
||||
ENABLE_BITCODE = NO;
|
||||
INFOPLIST_FILE = Runner/Info.plist;
|
||||
@@ -362,7 +362,7 @@
|
||||
"$(inherited)",
|
||||
"@executable_path/Frameworks",
|
||||
);
|
||||
MARKETING_VERSION = 1.0.108;
|
||||
MARKETING_VERSION = 1.0.112;
|
||||
PRODUCT_BUNDLE_IDENTIFIER = com.lollipopkit.toolbox;
|
||||
PRODUCT_NAME = "$(TARGET_NAME)";
|
||||
SWIFT_OBJC_BRIDGING_HEADER = "Runner/Runner-Bridging-Header.h";
|
||||
@@ -484,7 +484,7 @@
|
||||
buildSettings = {
|
||||
ASSETCATALOG_COMPILER_APPICON_NAME = AppIcon;
|
||||
CLANG_ENABLE_MODULES = YES;
|
||||
CURRENT_PROJECT_VERSION = 108;
|
||||
CURRENT_PROJECT_VERSION = 112;
|
||||
DEVELOPMENT_TEAM = BA88US33G6;
|
||||
ENABLE_BITCODE = NO;
|
||||
INFOPLIST_FILE = Runner/Info.plist;
|
||||
@@ -492,7 +492,7 @@
|
||||
"$(inherited)",
|
||||
"@executable_path/Frameworks",
|
||||
);
|
||||
MARKETING_VERSION = 1.0.108;
|
||||
MARKETING_VERSION = 1.0.112;
|
||||
PRODUCT_BUNDLE_IDENTIFIER = com.lollipopkit.toolbox;
|
||||
PRODUCT_NAME = "$(TARGET_NAME)";
|
||||
SWIFT_OBJC_BRIDGING_HEADER = "Runner/Runner-Bridging-Header.h";
|
||||
@@ -508,7 +508,7 @@
|
||||
buildSettings = {
|
||||
ASSETCATALOG_COMPILER_APPICON_NAME = AppIcon;
|
||||
CLANG_ENABLE_MODULES = YES;
|
||||
CURRENT_PROJECT_VERSION = 108;
|
||||
CURRENT_PROJECT_VERSION = 112;
|
||||
DEVELOPMENT_TEAM = BA88US33G6;
|
||||
ENABLE_BITCODE = NO;
|
||||
INFOPLIST_FILE = Runner/Info.plist;
|
||||
@@ -516,7 +516,7 @@
|
||||
"$(inherited)",
|
||||
"@executable_path/Frameworks",
|
||||
);
|
||||
MARKETING_VERSION = 1.0.108;
|
||||
MARKETING_VERSION = 1.0.112;
|
||||
PRODUCT_BUNDLE_IDENTIFIER = com.lollipopkit.toolbox;
|
||||
PRODUCT_NAME = "$(TARGET_NAME)";
|
||||
SWIFT_OBJC_BRIDGING_HEADER = "Runner/Runner-Bridging-Header.h";
|
||||
|
||||
@@ -2,9 +2,9 @@
|
||||
|
||||
class BuildData {
|
||||
static const String name = "ServerBox";
|
||||
static const int build = 111;
|
||||
static const int build = 112;
|
||||
static const String engine =
|
||||
"Flutter 2.10.4 • channel stable • https://github.com/flutter/flutter.git\nFramework • revision c860cba910 (13 days ago) • 2022-03-25 00:23:12 -0500\nEngine • revision 57d3bac3dd\nTools • Dart 2.16.2 • DevTools 2.9.2\n";
|
||||
static const String buildAt = "2022-04-07 19:53:12.283804";
|
||||
static const int modifications = 0;
|
||||
"Flutter 2.10.4 • channel stable • https://github.com/flutter/flutter.git\nFramework • revision c860cba910 (3 weeks ago) • 2022-03-25 00:23:12 -0500\nEngine • revision 57d3bac3dd\nTools • Dart 2.16.2 • DevTools 2.9.2\n";
|
||||
static const String buildAt = "2022-04-15 19:07:21.221650";
|
||||
static const int modifications = 7;
|
||||
}
|
||||
|
||||
@@ -63,18 +63,18 @@ class _AptManagePageState extends State<AptManagePage>
|
||||
apt.refreshInstalled();
|
||||
return centerLoading;
|
||||
}
|
||||
if (!apt.isSU) {
|
||||
return Center(
|
||||
child: Text(
|
||||
'Only supported as root. Not "${apt.whoami}".',
|
||||
style: greyStyle,
|
||||
),
|
||||
);
|
||||
}
|
||||
return ListView(
|
||||
padding: const EdgeInsets.all(13),
|
||||
children:
|
||||
[_buildUpdatePanel(apt)].map((e) => RoundRectCard(e)).toList(),
|
||||
children: [
|
||||
const Padding(
|
||||
padding: EdgeInsets.all(17),
|
||||
child: Text(
|
||||
'Experimental features.\nPlease report bugs on Github Issue.',
|
||||
textAlign: TextAlign.center,
|
||||
),
|
||||
),
|
||||
_buildUpdatePanel(apt)
|
||||
].map((e) => RoundRectCard(e)).toList(),
|
||||
);
|
||||
}),
|
||||
);
|
||||
|
||||
@@ -104,12 +104,12 @@ class _MyHomePageState extends State<MyHomePage>
|
||||
childDecoration: const BoxDecoration(
|
||||
// NOTICE: Uncomment if you want to add shadow behind the page.
|
||||
// Keep in mind that it may cause animation jerks.
|
||||
boxShadow: <BoxShadow>[
|
||||
BoxShadow(
|
||||
color: Colors.black12,
|
||||
blurRadius: 0.0,
|
||||
),
|
||||
],
|
||||
// boxShadow: <BoxShadow>[
|
||||
// BoxShadow(
|
||||
// color: Colors.black12,
|
||||
// blurRadius: 0.0,
|
||||
// ),
|
||||
// ],
|
||||
borderRadius: BorderRadius.all(Radius.circular(16)),
|
||||
),
|
||||
drawer: _buildDrawer(),
|
||||
@@ -278,7 +278,11 @@ class _MyHomePageState extends State<MyHomePage>
|
||||
}
|
||||
|
||||
String _buildVersionStr() {
|
||||
return 'Ver: 1.0.${BuildData.build}';
|
||||
var mod = '';
|
||||
if (BuildData.modifications != 0) {
|
||||
mod = '(+${BuildData.modifications})';
|
||||
}
|
||||
return 'Ver: 1.0.${BuildData.build}$mod';
|
||||
}
|
||||
|
||||
@override
|
||||
|
||||
17
make.dart
17
make.dart
@@ -5,6 +5,7 @@ import 'dart:convert';
|
||||
import 'dart:io';
|
||||
|
||||
const appName = 'ServerBox';
|
||||
const skslFileSuffix = '.sksl.json';
|
||||
|
||||
Future<int> getGitCommitCount() async {
|
||||
final result = await Process.run('git', ['log', '--oneline']);
|
||||
@@ -90,7 +91,8 @@ Future<void> flutterBuild(String source, String target, bool isAndroid) async {
|
||||
isAndroid ? 'apk' : 'ipa',
|
||||
'--target-platform=android-arm64',
|
||||
'--build-number=$build',
|
||||
'--build-name=1.0.$build'
|
||||
'--build-name=1.0.$build',
|
||||
'--bundle-sksl-path=${isAndroid ? 'android' : 'ios'}$skslFileSuffix',
|
||||
];
|
||||
if (!isAndroid) args.removeAt(2);
|
||||
print('Building with args: ${args.join(' ')}');
|
||||
@@ -100,7 +102,16 @@ Future<void> flutterBuild(String source, String target, bool isAndroid) async {
|
||||
if (exitCode == 0) {
|
||||
target = target.replaceFirst('build', build.toString());
|
||||
print('Copying from $source to $target');
|
||||
if (isAndroid) {
|
||||
await File(source).copy(target);
|
||||
} else {
|
||||
final result = await Process.run('cp', ['-r', source, target]);
|
||||
if (result.exitCode != 0) {
|
||||
print(result.stderr);
|
||||
exit(1);
|
||||
}
|
||||
}
|
||||
|
||||
print('Done.');
|
||||
} else {
|
||||
print(buildResult.stderr.toString());
|
||||
@@ -112,8 +123,8 @@ Future<void> flutterBuild(String source, String target, bool isAndroid) async {
|
||||
}
|
||||
|
||||
Future<void> flutterBuildIOS() async {
|
||||
await flutterBuild('./build/ios/iphoneos/ToastTiku.app',
|
||||
'./release/${appName}_build.app', false);
|
||||
await flutterBuild('./build/ios/archive/Runner.xcarchive',
|
||||
'./release/${appName}_build.xcarchive', false);
|
||||
}
|
||||
|
||||
Future<void> flutterBuildAndroid() async {
|
||||
|
||||
Reference in New Issue
Block a user