Skip to content

Commit

Permalink
Bug fix vari
Browse files Browse the repository at this point in the history
  • Loading branch information
federunco committed Sep 12, 2020
1 parent add9b4c commit 2a8ff75
Show file tree
Hide file tree
Showing 2 changed files with 30 additions and 13 deletions.
28 changes: 17 additions & 11 deletions lib/app_main/app_main.dart
Original file line number Diff line number Diff line change
Expand Up @@ -192,17 +192,23 @@ class _AppMainState extends State<AppMain> with SingleTickerProviderStateMixin {
SharedPreferences prefs = await SharedPreferences.getInstance();
bool _hasTutorialShown = prefs.getBool('tutorialShown') ?? false;
if (!_hasTutorialShown) {
_initTutorialTargets();
TutorialCoachMark(
context,
targets: _targets,
colorShadow: Colors.black,
textSkip: AppLocalizations.of(context).translate("skip"),
paddingFocus: 7,
opacityShadow: 0.8,
onFinish: () => prefs.setBool('tutorialShown', true),
onClickSkip: () => prefs.setBool('tutorialShown', true),
)..show();
Future.delayed(
Duration(milliseconds: 700),
(){
_initTutorialTargets();
TutorialCoachMark(
context,
targets: _targets,
colorShadow: Colors.black,
textSkip: AppLocalizations.of(context).translate("skip"),
paddingFocus: 7,
opacityShadow: 0.8,
onFinish: () => prefs.setBool('tutorialShown', true),
onClickSkip: () => prefs.setBool('tutorialShown', true),
)..show();
},
);

}
}

Expand Down
15 changes: 13 additions & 2 deletions lib/ui/sobrero_appbar.dart
Original file line number Diff line number Diff line change
Expand Up @@ -2,7 +2,10 @@
// Use of this source code is governed by the GPG 3.0 license that can be
// found in the LICENSE file.

import 'dart:io';

import 'package:animations/animations.dart';
import 'package:flutter/foundation.dart';
import 'package:flutter/material.dart';
import 'package:flutter_tabler_icons/flutter_tabler_icons.dart';

Expand All @@ -12,7 +15,10 @@ import 'package:mySobrero/ui/helper.dart';

class SobreroAppBar extends StatelessWidget implements PreferredSizeWidget {
@override
Size get preferredSize => Size(double.infinity, 65);
Size get preferredSize => Size(
double.infinity,
Platform.isMacOS ? 100 : 66
);

final double elevation;
final double topCorrection;
Expand Down Expand Up @@ -52,7 +58,12 @@ class SobreroAppBar extends StatelessWidget implements PreferredSizeWidget {
),
child: SafeArea(
child: Padding(
padding: EdgeInsets.fromLTRB(20,3 - topCorrection,20,3 + topCorrection),
padding: EdgeInsets.fromLTRB(
20,
(Platform.isMacOS ? 47 : 3) - topCorrection,
20,
3 + topCorrection,
),
child: Row(
children: [
IconButton(
Expand Down

0 comments on commit 2a8ff75

Please sign in to comment.