mirror of
https://github.com/cypherstack/stack_wallet.git
synced 2025-01-11 13:14:32 +00:00
desktop starting to height be 3/4 screen height or 900, whichever is smaller
This commit is contained in:
parent
d71899d1df
commit
7db3abab47
1 changed files with 10 additions and 0 deletions
|
@ -1,5 +1,6 @@
|
||||||
import 'dart:async';
|
import 'dart:async';
|
||||||
import 'dart:io';
|
import 'dart:io';
|
||||||
|
import 'dart:math';
|
||||||
|
|
||||||
import 'package:cw_core/node.dart';
|
import 'package:cw_core/node.dart';
|
||||||
import 'package:cw_core/unspent_coins_info.dart';
|
import 'package:cw_core/unspent_coins_info.dart';
|
||||||
|
@ -79,6 +80,15 @@ void main() async {
|
||||||
setWindowTitle('Stack Wallet');
|
setWindowTitle('Stack Wallet');
|
||||||
setWindowMinSize(const Size(1220, 100));
|
setWindowMinSize(const Size(1220, 100));
|
||||||
setWindowMaxSize(Size.infinite);
|
setWindowMaxSize(Size.infinite);
|
||||||
|
final screen = await getCurrentScreen();
|
||||||
|
final screenHeight = screen?.frame.height;
|
||||||
|
if (screenHeight != null) {
|
||||||
|
// starting to height be 3/4 screen height or 900, whichever is smaller
|
||||||
|
final height = min<double>(screenHeight * 0.75, 900);
|
||||||
|
setWindowFrame(
|
||||||
|
Rect.fromLTWH(0, 0, 1220, height),
|
||||||
|
);
|
||||||
|
}
|
||||||
}
|
}
|
||||||
|
|
||||||
// FlutterNativeSplash.preserve(widgetsBinding: widgetsBinding);
|
// FlutterNativeSplash.preserve(widgetsBinding: widgetsBinding);
|
||||||
|
|
Loading…
Reference in a new issue