Skip to content

Commit

Permalink
about page, etc; v0.3.0
Browse files Browse the repository at this point in the history
  • Loading branch information
fuwa37 committed Jul 20, 2020
1 parent bd20173 commit eb9082e
Show file tree
Hide file tree
Showing 9 changed files with 732 additions and 517 deletions.
7 changes: 7 additions & 0 deletions CHANGELOG.md
Original file line number Diff line number Diff line change
@@ -1,3 +1,10 @@
## 0.3.0

* Add About page
* Add "check new version" & download from app
* Replace Trace result's broken video with image
* Some UIs change

## 0.2.0

* App icon added
Expand Down
2 changes: 1 addition & 1 deletion README.md
Original file line number Diff line number Diff line change
Expand Up @@ -9,7 +9,7 @@ Sauce finder
* [ ] Implement on-the-air update (auto-updater)
* [x] ~~App's icon~~
* [ ] **Better app's icon**
* [ ] App's about page
* [x] ~~App's about page~~
* [ ] Search's history
* [ ] **Better state management**
* [ ] **Refactoring**
Binary file added assets/app_icon_circle.png
Loading
Sorry, something went wrong. Reload?
Sorry, we cannot display this file.
Sorry, this file is invalid so it cannot be displayed.
34 changes: 34 additions & 0 deletions lib/common/common.dart
Original file line number Diff line number Diff line change
Expand Up @@ -284,6 +284,17 @@ class NoResultException implements Exception {
}
}

class NoSupportedApkException implements Exception {
String message;

NoSupportedApkException([this.message]);

String toString() {
if (message == null) return "Exception";
return "$message";
}
}

properImageHelp(BuildContext context, ScrollController _helpController) {
showDialog(
context: context,
Expand Down Expand Up @@ -358,3 +369,26 @@ loadingDialog({@required BuildContext scaffoldContext, CancelToken token}) {
},
);
}

showSnackBar(
{@required String msg,
@required ScaffoldState state,
SnackBarAction act,
Duration dur = const Duration(seconds: 4)}) {
state?.removeCurrentSnackBar();
state?.showSnackBar(SnackBar(
content: Text("$msg"),
behavior: SnackBarBehavior.floating,
action: act,
duration: dur,
));
}

double mapRange(
{@required double input,
@required double x1,
@required double y1,
@required double x2,
@required double y2}) {
return (input - x1) / (y1 - x1) * (y2 - x2) + x2;
}
Loading

0 comments on commit eb9082e

Please sign in to comment.