This commit is contained in:
2022-03-17 13:19:45 +08:00
parent cac4735bc4
commit b46b150f6a
11 changed files with 40 additions and 59 deletions

View File

@ -32,13 +32,8 @@
VerticalOptions="Center" LongCommand="{Binding TitleLongPressed}">
<Label Text="{Binding SelectedDate, Converter={StaticResource titleDateConverter}}"
TextColor="{DynamicResource PrimaryColor}"
FontSize="{OnPlatform Android=20, iOS=18}">
<Label.FontFamily>
<OnPlatform x:TypeArguments="x:String"
Android="OpenSans-SemiBold.ttf#OpenSans-SemiBold"
iOS="OpenSans-Bold"/>
</Label.FontFamily>
</Label>
FontFamily="{x:Static ui:Definition.SemiBoldFontFamily}"
FontSize="{OnPlatform Android=20, iOS=18}"/>
</ui:LongPressGrid>
<ui:TintImageButton Source="calendar.png" WidthRequest="20" HeightRequest="20"
VerticalOptions="Center" HorizontalOptions="Start"

View File

@ -114,6 +114,16 @@ namespace Billing.Views
private void OnTitleDateLongPressed()
{
billingDate.SetDateTime(DateTime.Today);
try
{
HapticFeedback.Perform();
}
catch (FeatureNotSupportedException) { }
catch (Exception ex)
{
Helper.Error("haptic.feedback", ex);
}
}
private async void OnEditBilling(object o)

View File

@ -13,23 +13,20 @@
Shell.TabBarIsVisible="True">
<Shell.TitleView>
<StackLayout HorizontalOptions="Center" VerticalOptions="Center"
Orientation="Horizontal" Spacing="10">
<StackLayout Orientation="Horizontal" Spacing="10">
<ui:TintImageButton Source="left.png" WidthRequest="20" HeightRequest="20"
VerticalOptions="Center" HorizontalOptions="Start"
Command="{Binding LeftCommand}"/>
<Label Text="{Binding Title}"
TextColor="{DynamicResource PrimaryColor}"
FontSize="{OnPlatform Android=20, iOS=18}"
Padding="10, 0">
FontFamily="{x:Static ui:Definition.SemiBoldFontFamily}"
VerticalOptions="Center"
HorizontalOptions="FillAndExpand"
HorizontalTextAlignment="Center">
<Label.GestureRecognizers>
<TapGestureRecognizer Command="{Binding FilterCommand}"/>
</Label.GestureRecognizers>
<Label.FontFamily>
<OnPlatform x:TypeArguments="x:String"
Android="OpenSans-SemiBold.ttf#OpenSans-SemiBold"
iOS="OpenSans-Bold"/>
</Label.FontFamily>
</Label>
<ui:TintImageButton Source="right.png" WidthRequest="20" HeightRequest="20"
VerticalOptions="Center" HorizontalOptions="End"

View File

@ -35,7 +35,8 @@ namespace Billing.Views
ShareLogsCommand = new Command(OnShareLogsCommand);
InitializeComponent();
var (main, build) = Definition.GetVersion();
var main = AppInfo.VersionString;
var build = AppInfo.BuildString;
SetValue(VersionProperty, $"{main} ({build})");
}