-
Notifications
You must be signed in to change notification settings - Fork 447
Commit
This commit does not belong to any branch on this repository, and may belong to a fork outside of the repository.
- Loading branch information
Showing
44 changed files
with
513 additions
and
301 deletions.
There are no files selected for viewing
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -1 +1 @@ | ||
v1.7.3 | ||
v1.7.4 |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -1,4 +1,3 @@ | ||
v1.7.3 | ||
- [x] ✨ 可以隐藏发电图标(设置项) | ||
- [x] ✨ 可以给阅读器加灰度滤镜(设置项)(彩色墨水屏下或许有用) | ||
- [x] ✨ 可以选择阅读器背景色(设置项)(白色可防止墨水屏下拖影) | ||
v1.7.4 | ||
- [x] ♻️ 优化发电 | ||
- [x] ♻️ 优化设置 |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,28 @@ | ||
import 'package:flutter/material.dart'; | ||
import '../Method.dart'; | ||
|
||
const _propertyName = "eBookScrolling"; | ||
|
||
late bool _eBookScrolling; | ||
|
||
bool get eBookScrolling => _eBookScrolling; | ||
|
||
Future initEBookScrolling() async { | ||
_eBookScrolling = (await method.loadProperty(_propertyName, "false")) == "true"; | ||
} | ||
|
||
Widget eBookScrollingSetting() { | ||
return StatefulBuilder( | ||
builder: (BuildContext context, void Function(void Function()) setState) { | ||
return SwitchListTile( | ||
title: const Text("电子书模式滚动UI"), | ||
value: _eBookScrolling, | ||
onChanged: (value) async { | ||
await method.saveProperty(_propertyName, "$value"); | ||
_eBookScrolling = value; | ||
setState(() {}); | ||
}, | ||
); | ||
}, | ||
); | ||
} |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,37 @@ | ||
import 'package:flutter/material.dart'; | ||
|
||
import '../Method.dart'; | ||
|
||
const _propertyName = "eBookScrollingRange"; | ||
|
||
late int _eBookScrollingRange; | ||
|
||
Future initEBookScrollingRange() async { | ||
_eBookScrollingRange = | ||
int.parse((await method.loadProperty(_propertyName, "80"))); | ||
} | ||
|
||
double get eBookScrollingRange => _eBookScrollingRange / 100; | ||
|
||
Widget eBookScrollingRangeSetting() { | ||
return StatefulBuilder( | ||
builder: (BuildContext context, void Function(void Function()) setState) { | ||
return ListTile( | ||
title: Text("电子书模式滚动UI - 滚动幅度 : $_eBookScrollingRange%屏幕高度"), | ||
subtitle: Slider( | ||
min: 30.toDouble(), | ||
max: 80.toDouble(), | ||
value: _eBookScrollingRange.toDouble(), | ||
onChanged: (double value) async { | ||
final va = value.toInt(); | ||
await method.loadProperty(_propertyName, "$va"); | ||
setState(() { | ||
_eBookScrollingRange = va; | ||
}); | ||
}, | ||
divisions: (80 - 30), | ||
), | ||
); | ||
}, | ||
); | ||
} |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,36 @@ | ||
import 'package:flutter/material.dart'; | ||
|
||
import '../Method.dart'; | ||
|
||
const _propertyName = "eBookScrollingTrigger"; | ||
|
||
late double _eBookScrollingTrigger; | ||
|
||
Future initEBookScrollingTrigger() async { | ||
_eBookScrollingTrigger = | ||
double.parse((await method.loadProperty(_propertyName, "0.3"))); | ||
} | ||
|
||
double get eBookScrollingTrigger => _eBookScrollingTrigger; | ||
|
||
Widget eBookScrollingTriggerSetting() { | ||
return StatefulBuilder( | ||
builder: (BuildContext context, void Function(void Function()) setState) { | ||
return ListTile( | ||
title: Text("电子书模式滚动UI - 触发距离 : $_eBookScrollingTrigger 厘米"), | ||
subtitle: Slider( | ||
min: 0.1.toDouble(), | ||
max: 2.0.toDouble(), | ||
value: _eBookScrollingTrigger.toDouble(), | ||
onChanged: (double value) async { | ||
await method.saveProperty(_propertyName, "$value"); | ||
setState((){ | ||
_eBookScrollingTrigger = value; | ||
}); | ||
}, | ||
divisions: (20 - 1), | ||
), | ||
); | ||
}, | ||
); | ||
} |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Oops, something went wrong.