feat: 版本升级 V1.0.2;完善「关于/帮助」页(分平台显示)
- 版本 1.0.2+4(Android versionCode 4,可覆盖安装) - 关于页重构:Logo + 名称/版本/平台;安卓显示「已授权(平板版免授权)」与保存位置说明,桌面显示授权状态/MAC/授权指南;官网入口安卓走原生 Intent - 帮助中心「界面与快捷键」按平台显示触屏操作说明(单指点选/按住移动/端点把手改时长/双指缩放平移) - 重建 dist 与签名 APK(release/sequence_diagram_tablet_v1.0.2_release.apk)
This commit is contained in:
+1
-1
@@ -127,7 +127,7 @@ flutter pub get
|
|||||||
flutter build apk --release # 产物:build\app\outputs\flutter-apk\app-release.apk
|
flutter build apk --release # 产物:build\app\outputs\flutter-apk\app-release.apk
|
||||||
```
|
```
|
||||||
|
|
||||||
- 发布包归档:`release\sequence_diagram_tablet_v1.0.1_release.apk`(universal:arm64-v8a / armeabi-v7a / x86_64)。
|
- 发布包归档:`release\sequence_diagram_tablet_v1.0.2_release.apk`(universal:arm64-v8a / armeabi-v7a / x86_64)。
|
||||||
- 上架应用商店时建议在 `android\app\build.gradle.kts` 配置正式签名后再构建 AAB:
|
- 上架应用商店时建议在 `android\app\build.gradle.kts` 配置正式签名后再构建 AAB:
|
||||||
`flutter build appbundle --release`。
|
`flutter build appbundle --release`。
|
||||||
- 应用名「时序图设计器」、包名 `cc.sincos.sequence_diagram`、launcher 图标由
|
- 应用名「时序图设计器」、包名 `cc.sincos.sequence_diagram`、launcher 图标由
|
||||||
|
|||||||
@@ -9,7 +9,7 @@
|
|||||||
- **深色 / 浅色双主题**:右上角 ☀ / ☾ 一键切换,语义颜色不变,导出 SVG 与屏幕一致
|
- **深色 / 浅色双主题**:右上角 ☀ / ☾ 一键切换,语义颜色不变,导出 SVG 与屏幕一致
|
||||||
- **导出 SVG**:矢量、分层、带语义 `id` / `data-*` 元数据,可直接进工艺卡与 MES
|
- **导出 SVG**:矢量、分层、带语义 `id` / `data-*` 元数据,可直接进工艺卡与 MES
|
||||||
|
|
||||||
## 正式版 V1.1.1
|
## 正式版 V1.0.2
|
||||||
|
|
||||||
**可运行的 Flutter Windows 桌面正式版**(源码在 `lib/`),设计人:呆头鹅。
|
**可运行的 Flutter Windows 桌面正式版**(源码在 `lib/`),设计人:呆头鹅。
|
||||||
|
|
||||||
@@ -97,7 +97,7 @@ Flutter 3.29+(Desktop) · CustomPainter 自绘 · Riverpod · 不可变模
|
|||||||
- **正式签名**:release 用独立 keystore 签名(`android/key/release.jks`,见 `BUILD-NOTES.md`),更新安装无需卸载重装;
|
- **正式签名**:release 用独立 keystore 签名(`android/key/release.jks`,见 `BUILD-NOTES.md`),更新安装无需卸载重装;
|
||||||
- **构建**:JDK 17 + Android SDK 36(详见 `BUILD-NOTES.md`),Gradle 与 Maven 已配置国内镜像:
|
- **构建**:JDK 17 + Android SDK 36(详见 `BUILD-NOTES.md`),Gradle 与 Maven 已配置国内镜像:
|
||||||
```bash
|
```bash
|
||||||
flutter build apk --release # 产物 → release/sequence_diagram_tablet_v1.0.1_release.apk
|
flutter build apk --release # 产物 → release/sequence_diagram_tablet_v1.0.2_release.apk
|
||||||
```
|
```
|
||||||
- **自测**:`test/tablet_layout_test.dart` 覆盖 1280×800、2560×1600、960×600、800×480、竖屏 800×1280、600×960 等 7 种分辨率的无溢出回归;
|
- **自测**:`test/tablet_layout_test.dart` 覆盖 1280×800、2560×1600、960×600、800×480、竖屏 800×1280、600×960 等 7 种分辨率的无溢出回归;
|
||||||
- **demo 图**:`demo/tablet-*.png`(由 `test/tablet_screenshots_test.dart` 生成)。
|
- **demo 图**:`demo/tablet-*.png`(由 `test/tablet_screenshots_test.dart` 生成)。
|
||||||
@@ -113,6 +113,6 @@ Flutter 3.29+(Desktop) · CustomPainter 自绘 · Riverpod · 不可变模
|
|||||||
|
|
||||||
- **软件**:时序图设计器 · Sequence Diagram Studio
|
- **软件**:时序图设计器 · Sequence Diagram Studio
|
||||||
- **设计人**:呆头鹅
|
- **设计人**:呆头鹅
|
||||||
- **版本**:V1.1.1
|
- **版本**:V1.0.2
|
||||||
- **版权**:Copyright © 2026 呆头鹅。保留所有权利。
|
- **版权**:Copyright © 2026 呆头鹅。保留所有权利。
|
||||||
- **架构文档**:[`docs/ARCHITECTURE.md`](docs/ARCHITECTURE.md) · **使用帮助**:[`docs/HELP.md`](docs/HELP.md)
|
- **架构文档**:[`docs/ARCHITECTURE.md`](docs/ARCHITECTURE.md) · **使用帮助**:[`docs/HELP.md`](docs/HELP.md)
|
||||||
|
|||||||
@@ -1,6 +1,7 @@
|
|||||||
package cc.sincos.sequence_diagram
|
package cc.sincos.sequence_diagram
|
||||||
|
|
||||||
import android.content.ContentValues
|
import android.content.ContentValues
|
||||||
|
import android.content.Intent
|
||||||
import android.net.Uri
|
import android.net.Uri
|
||||||
import android.os.Build
|
import android.os.Build
|
||||||
import android.os.Environment
|
import android.os.Environment
|
||||||
@@ -67,6 +68,19 @@ class MainActivity : FlutterActivity() {
|
|||||||
}
|
}
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
|
"openUrl" -> {
|
||||||
|
val url = call.argument<String>("url")
|
||||||
|
if (url == null) {
|
||||||
|
result.error("ARGS", "url required", null)
|
||||||
|
} else {
|
||||||
|
try {
|
||||||
|
startActivity(Intent(Intent.ACTION_VIEW, Uri.parse(url)))
|
||||||
|
result.success(true)
|
||||||
|
} catch (e: Exception) {
|
||||||
|
result.error("OPEN", e.message, null)
|
||||||
|
}
|
||||||
|
}
|
||||||
|
}
|
||||||
else -> result.notImplemented()
|
else -> result.notImplemented()
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
|
|||||||
@@ -117,4 +117,11 @@ class AndroidDocs {
|
|||||||
if (r == null) return null;
|
if (r == null) return null;
|
||||||
return r as Uint8List;
|
return r as Uint8List;
|
||||||
}
|
}
|
||||||
|
|
||||||
|
/// 用系统浏览器打开网址(官网入口;安卓经原生 Intent)。
|
||||||
|
static Future<void> openUrl(String url) async {
|
||||||
|
try {
|
||||||
|
await _channel.invokeMethod<void>('openUrl', <String, Object?>{'url': url});
|
||||||
|
} catch (_) {}
|
||||||
|
}
|
||||||
}
|
}
|
||||||
|
|||||||
+99
-36
@@ -18,6 +18,7 @@ import '../persistence/android_docs.dart';
|
|||||||
import '../persistence/storage.dart';
|
import '../persistence/storage.dart';
|
||||||
import '../state/app_controller.dart';
|
import '../state/app_controller.dart';
|
||||||
import '../theme/tokens.dart';
|
import '../theme/tokens.dart';
|
||||||
|
import 'app_logo.dart';
|
||||||
|
|
||||||
// ===================== 对话框等比缩放 =====================
|
// ===================== 对话框等比缩放 =====================
|
||||||
|
|
||||||
@@ -2036,9 +2037,13 @@ class HelpDialog extends StatelessWidget {
|
|||||||
<String>['我要隐藏 / 显示侧栏', '工具栏右侧两个侧栏按钮,分别控制左、右侧栏。'],
|
<String>['我要隐藏 / 显示侧栏', '工具栏右侧两个侧栏按钮,分别控制左、右侧栏。'],
|
||||||
<String>['我要钉住侧栏', '侧栏标题右侧图钉:钉住=固定占位;取消钉住=悬浮,鼠标移开自动收起。'],
|
<String>['我要钉住侧栏', '侧栏标题右侧图钉:钉住=固定占位;取消钉住=悬浮,鼠标移开自动收起。'],
|
||||||
<String>['边缘把手', '侧栏收起后画布边缘有细把手:悬停临时展开,点击固定显示。'],
|
<String>['边缘把手', '侧栏收起后画布边缘有细把手:悬停临时展开,点击固定显示。'],
|
||||||
<String>['拖拽 / 缩放', '左键拖拽平移相位;拖端点改时长;Shift+拖拽改层;Ctrl+滚轮缩放。'],
|
if (Platform.isAndroid)
|
||||||
|
<String>['触屏操作', '单指点选选中动作;按住动作整体拖动移动;选中后抓两端白色把手拖拽改时长;空白单指不平移;双指捏合缩放、双指拖拽平移。']
|
||||||
|
else
|
||||||
|
<String>['拖拽 / 缩放', '左键拖拽平移相位;拖端点改时长;Shift+拖拽改层;Ctrl+滚轮缩放。'],
|
||||||
<String>['双击编辑', '双击画布色块(条形块 / 圆弧)或左侧动作行 → 打开动作编辑对话框。'],
|
<String>['双击编辑', '双击画布色块(条形块 / 圆弧)或左侧动作行 → 打开动作编辑对话框。'],
|
||||||
<String>['右键动作', '菜单:添加依赖 / 改层 / 复制 / 删除。'],
|
if (!Platform.isAndroid)
|
||||||
|
<String>['右键动作', '菜单:添加依赖 / 改层 / 复制 / 删除。'],
|
||||||
<String>['撤销 / 保存', 'Ctrl+Z / Ctrl+Y 撤销重做;Ctrl+S 保存;Ctrl+O / Ctrl+N 打开 / 新建。'],
|
<String>['撤销 / 保存', 'Ctrl+Z / Ctrl+Y 撤销重做;Ctrl+S 保存;Ctrl+O / Ctrl+N 打开 / 新建。'],
|
||||||
<String>['帮助入口', '顶部工具栏右侧「?」或 F1 打开帮助中心;画布编辑工具条不重复放置帮助按钮。'],
|
<String>['帮助入口', '顶部工具栏右侧「?」或 F1 打开帮助中心;画布编辑工具条不重复放置帮助按钮。'],
|
||||||
<String>['导出入口', '导出 SVG / PNG 统一放在顶部工具栏右侧,避免多处重复。'],
|
<String>['导出入口', '导出 SVG / PNG 统一放在顶部工具栏右侧,避免多处重复。'],
|
||||||
@@ -2065,7 +2070,13 @@ class HelpDialog extends StatelessWidget {
|
|||||||
}
|
}
|
||||||
|
|
||||||
/// 用系统默认程序打开网址(官网导航)。
|
/// 用系统默认程序打开网址(官网导航)。
|
||||||
|
///
|
||||||
|
/// 安卓经原生 Intent 打开浏览器;桌面用 rundll32 / start。
|
||||||
Future<void> _openUrl(String url) async {
|
Future<void> _openUrl(String url) async {
|
||||||
|
if (AndroidDocs.isAvailable) {
|
||||||
|
await AndroidDocs.openUrl(url);
|
||||||
|
return;
|
||||||
|
}
|
||||||
try {
|
try {
|
||||||
await Process.run('rundll32', <String>['url.dll,FileProtocolHandler', url]);
|
await Process.run('rundll32', <String>['url.dll,FileProtocolHandler', url]);
|
||||||
} catch (_) {
|
} catch (_) {
|
||||||
@@ -2075,8 +2086,10 @@ class HelpDialog extends StatelessWidget {
|
|||||||
}
|
}
|
||||||
}
|
}
|
||||||
|
|
||||||
/// 「关于」页:软件信息 + 授权状态 + 本机 MAC + 授权指南 + 官网入口。
|
/// 「关于」页:软件信息 + 平台 / 授权状态 + 官网入口;
|
||||||
|
/// 桌面版追加授权指南(MAC 申请 .lic),平板版展示免授权与保存位置说明。
|
||||||
Widget _about(BuildContext context, Tokens t) {
|
Widget _about(BuildContext context, Tokens t) {
|
||||||
|
final bool android = AndroidDocs.isAvailable;
|
||||||
final LicenseInfo info = LicenseService.instance.info;
|
final LicenseInfo info = LicenseService.instance.info;
|
||||||
final String lic = info.valid
|
final String lic = info.valid
|
||||||
? '已授权(${info.filePath?.split(RegExp(r'[\\/]')).last ?? '.lic'})'
|
? '已授权(${info.filePath?.split(RegExp(r'[\\/]')).last ?? '.lic'})'
|
||||||
@@ -2096,21 +2109,43 @@ class HelpDialog extends StatelessWidget {
|
|||||||
],
|
],
|
||||||
),
|
),
|
||||||
);
|
);
|
||||||
Widget guideLine(String s) =>
|
Widget guideLine(String s) => Text(s, style: TextStyle(color: t.sub, fontSize: 11.5, height: 1.7));
|
||||||
Text(s, style: TextStyle(color: t.sub, fontSize: 11.5, height: 1.7));
|
|
||||||
return ListView(
|
return ListView(
|
||||||
padding: const EdgeInsets.only(top: 14),
|
padding: const EdgeInsets.only(top: 14),
|
||||||
children: <Widget>[
|
children: <Widget>[
|
||||||
row('软件名称', '时序图设计器 · Sequence Diagram Studio'),
|
Row(
|
||||||
|
children: <Widget>[
|
||||||
|
const AppLogo(size: 48),
|
||||||
|
const SizedBox(width: 14),
|
||||||
|
Expanded(
|
||||||
|
child: Column(
|
||||||
|
crossAxisAlignment: CrossAxisAlignment.start,
|
||||||
|
children: <Widget>[
|
||||||
|
Text('时序图设计器 · Sequence Diagram Studio',
|
||||||
|
style: TextStyle(color: t.text, fontSize: 15, fontWeight: FontWeight.w700)),
|
||||||
|
const SizedBox(height: 4),
|
||||||
|
Text('V1.0.2(${android ? 'Android 平板版' : 'Windows 桌面版'})',
|
||||||
|
style: TextStyle(color: t.dim, fontSize: 12)),
|
||||||
|
],
|
||||||
|
),
|
||||||
|
),
|
||||||
|
],
|
||||||
|
),
|
||||||
|
const SizedBox(height: 14),
|
||||||
row('设计人', '呆头鹅'),
|
row('设计人', '呆头鹅'),
|
||||||
row('版本', 'V1.1.1'),
|
row(
|
||||||
row('授权状态', lic, vc: info.valid ? t.ok : t.danger),
|
'授权状态',
|
||||||
// 注意:绝不能展示「期望授权串」——它等同于 .lic 内容,公开即可被绕过授权。
|
android ? '已授权(平板版免授权)' : lic,
|
||||||
row('本机 MAC', info.mac ?? '读取失败'),
|
vc: (android || info.valid) ? t.ok : t.danger,
|
||||||
|
),
|
||||||
|
if (!android)
|
||||||
|
// 注意:绝不能展示「期望授权串」——它等同于 .lic 内容,公开即可被绕过授权。
|
||||||
|
row('本机 MAC', info.mac ?? '读取失败'),
|
||||||
row('版权声明', 'Copyright © 2026 呆头鹅。保留所有权利。'),
|
row('版权声明', 'Copyright © 2026 呆头鹅。保留所有权利。'),
|
||||||
row('用途', '面向 PLC 流程节拍 / 相位角设计;未经许可不得用于商业再分发。'),
|
row('产品简介', '面向 PLC 流程节拍 / 相位角设计的时序图工具:条形 / 圆周双视图、'
|
||||||
|
'FS / SS 依赖与关键路径、SVG / PNG 导出,成果可直接进工艺卡与 MES。'),
|
||||||
const SizedBox(height: 6),
|
const SizedBox(height: 6),
|
||||||
// 官网入口(点击图标导航到 sincos.cc)。
|
// 官网入口(点击导航到 sincos.cc)。
|
||||||
Row(
|
Row(
|
||||||
children: <Widget>[
|
children: <Widget>[
|
||||||
InkWell(
|
InkWell(
|
||||||
@@ -2131,31 +2166,59 @@ class HelpDialog extends StatelessWidget {
|
|||||||
],
|
],
|
||||||
),
|
),
|
||||||
const SizedBox(height: 10),
|
const SizedBox(height: 10),
|
||||||
// 授权指南(替代原来的邮件申请按钮)。
|
if (!android)
|
||||||
Container(
|
// 授权指南(桌面版:按本机 MAC 申请 .lic)。
|
||||||
padding: const EdgeInsets.all(12),
|
Container(
|
||||||
decoration: BoxDecoration(
|
padding: const EdgeInsets.all(12),
|
||||||
color: t.info,
|
decoration: BoxDecoration(
|
||||||
borderRadius: BorderRadius.circular(10),
|
color: t.info,
|
||||||
border: Border.all(color: t.line),
|
borderRadius: BorderRadius.circular(10),
|
||||||
|
border: Border.all(color: t.line),
|
||||||
|
),
|
||||||
|
child: Column(
|
||||||
|
crossAxisAlignment: CrossAxisAlignment.start,
|
||||||
|
children: <Widget>[
|
||||||
|
Row(
|
||||||
|
children: <Widget>[
|
||||||
|
Icon(Icons.menu_book_outlined, size: 16, color: t.accent),
|
||||||
|
const SizedBox(width: 6),
|
||||||
|
Text('授权指南', style: TextStyle(color: t.accent, fontSize: 12.5, fontWeight: FontWeight.w600)),
|
||||||
|
],
|
||||||
|
),
|
||||||
|
const SizedBox(height: 8),
|
||||||
|
guideLine('1. 复制上方「本机 MAC」。'),
|
||||||
|
guideLine('2. 访问官网 sincos.cc,或把 MAC 发送到邮箱 liuyu65@126.com 申请授权。'),
|
||||||
|
guideLine('3. 收到 .lic 文件后,放入软件目录下的 license 文件夹,重启软件即可导出 SVG / PNG。'),
|
||||||
|
],
|
||||||
|
),
|
||||||
|
)
|
||||||
|
else
|
||||||
|
// 平板版说明:免授权 + 保存位置 + 反馈方式。
|
||||||
|
Container(
|
||||||
|
padding: const EdgeInsets.all(12),
|
||||||
|
decoration: BoxDecoration(
|
||||||
|
color: t.info,
|
||||||
|
borderRadius: BorderRadius.circular(10),
|
||||||
|
border: Border.all(color: t.line),
|
||||||
|
),
|
||||||
|
child: Column(
|
||||||
|
crossAxisAlignment: CrossAxisAlignment.start,
|
||||||
|
children: <Widget>[
|
||||||
|
Row(
|
||||||
|
children: <Widget>[
|
||||||
|
Icon(Icons.tablet_android, size: 16, color: t.accent),
|
||||||
|
const SizedBox(width: 6),
|
||||||
|
Text('平板版说明', style: TextStyle(color: t.accent, fontSize: 12.5, fontWeight: FontWeight.w600)),
|
||||||
|
],
|
||||||
|
),
|
||||||
|
const SizedBox(height: 8),
|
||||||
|
guideLine('本版面向应用商店分发,无需授权,全部功能可用。'),
|
||||||
|
guideLine('保存 / 导出文件位于平板「文件管理」可见的公共目录(默认 Documents/SequenceDiagram,'
|
||||||
|
'可在保存对话框中更改位置)。'),
|
||||||
|
guideLine('帮助与反馈:官网 sincos.cc 或邮箱 liuyu65@126.com。'),
|
||||||
|
],
|
||||||
|
),
|
||||||
),
|
),
|
||||||
child: Column(
|
|
||||||
crossAxisAlignment: CrossAxisAlignment.start,
|
|
||||||
children: <Widget>[
|
|
||||||
Row(
|
|
||||||
children: <Widget>[
|
|
||||||
Icon(Icons.menu_book_outlined, size: 16, color: t.accent),
|
|
||||||
const SizedBox(width: 6),
|
|
||||||
Text('授权指南', style: TextStyle(color: t.accent, fontSize: 12.5, fontWeight: FontWeight.w600)),
|
|
||||||
],
|
|
||||||
),
|
|
||||||
const SizedBox(height: 8),
|
|
||||||
guideLine('1. 复制上方「本机 MAC」。'),
|
|
||||||
guideLine('2. 访问官网 sincos.cc,或把 MAC 发送到邮箱 liuyu65@126.com 申请授权。'),
|
|
||||||
guideLine('3. 收到 .lic 文件后,放入软件目录下的 license 文件夹,重启软件即可导出 SVG / PNG。'),
|
|
||||||
],
|
|
||||||
),
|
|
||||||
),
|
|
||||||
],
|
],
|
||||||
);
|
);
|
||||||
}
|
}
|
||||||
|
|||||||
+1
-1
@@ -16,7 +16,7 @@ publish_to: 'none' # Remove this line if you wish to publish to pub.dev
|
|||||||
# https://developer.apple.com/library/archive/documentation/General/Reference/InfoPlistKeyReference/Articles/CoreFoundationKeys.html
|
# https://developer.apple.com/library/archive/documentation/General/Reference/InfoPlistKeyReference/Articles/CoreFoundationKeys.html
|
||||||
# In Windows, build-name is used as the major, minor, and patch parts
|
# In Windows, build-name is used as the major, minor, and patch parts
|
||||||
# of the product and file versions while build-number is used as the build suffix.
|
# of the product and file versions while build-number is used as the build suffix.
|
||||||
version: 1.1.1+3
|
version: 1.0.2+4
|
||||||
|
|
||||||
environment:
|
environment:
|
||||||
sdk: ^3.13.3
|
sdk: ^3.13.3
|
||||||
|
|||||||
Reference in New Issue
Block a user