This commit is contained in:
2020-05-22 22:46:52 +08:00
parent b97e07e1ab
commit 08ee19400b
8 changed files with 16 additions and 14 deletions

View File

@ -1,5 +1,5 @@
<?xml version="1.0" encoding="utf-8"?> <?xml version="1.0" encoding="utf-8"?>
<manifest xmlns:android="http://schemas.android.com/apk/res/android" android:versionName="1.0.521" package="org.tsanie.pixiview" android:versionCode="10"> <manifest xmlns:android="http://schemas.android.com/apk/res/android" android:versionName="1.0.522" package="org.tsanie.pixiview" android:versionCode="11">
<uses-sdk android:minSdkVersion="25" android:targetSdkVersion="28" /> <uses-sdk android:minSdkVersion="25" android:targetSdkVersion="28" />
<application android:label="Pixiview" android:icon="@mipmap/icon" android:roundIcon="@mipmap/icon_round"></application> <application android:label="Pixiview" android:icon="@mipmap/icon" android:roundIcon="@mipmap/icon_round"></application>
<uses-permission android:name="android.permission.ACCESS_NETWORK_STATE" /> <uses-permission android:name="android.permission.ACCESS_NETWORK_STATE" />

View File

@ -2,7 +2,6 @@
//------------------------------------------------------------------------------ //------------------------------------------------------------------------------
// <auto-generated> // <auto-generated>
// This code was generated by a tool. // This code was generated by a tool.
// Runtime Version:4.0.30319.42000
// //
// Changes to this file may cause incorrect behavior and will be lost if // Changes to this file may cause incorrect behavior and will be lost if
// the code is regenerated. // the code is regenerated.

View File

@ -29,8 +29,8 @@
<string>com.apple.share-services</string> <string>com.apple.share-services</string>
</dict> </dict>
<key>CFBundleShortVersionString</key> <key>CFBundleShortVersionString</key>
<string>1.0.521</string> <string>1.0.522</string>
<key>CFBundleVersion</key> <key>CFBundleVersion</key>
<string>10</string> <string>11</string>
</dict> </dict>
</plist> </plist>

View File

@ -79,8 +79,8 @@
</dict> </dict>
</array> </array>
<key>CFBundleShortVersionString</key> <key>CFBundleShortVersionString</key>
<string>1.0.521</string> <string>1.0.522</string>
<key>CFBundleVersion</key> <key>CFBundleVersion</key>
<string>10</string> <string>11</string>
</dict> </dict>
</plist> </plist>

View File

@ -20,7 +20,7 @@
<StackLayout.GestureRecognizers> <StackLayout.GestureRecognizers>
<TapGestureRecognizer Tapped="TapGestureRecognizer_Tapped"/> <TapGestureRecognizer Tapped="TapGestureRecognizer_Tapped"/>
</StackLayout.GestureRecognizers> </StackLayout.GestureRecognizers>
<Label Text="{Binding Title}" <Label Text="{Binding InternalTitle}"
TextColor="{DynamicResource TextColor}" TextColor="{DynamicResource TextColor}"
FontSize="{OnPlatform Android=18}" FontSize="{OnPlatform Android=18}"
LineBreakMode="HeadTruncation" LineBreakMode="HeadTruncation"

View File

@ -14,6 +14,15 @@ namespace Pixiview.Illust
{ {
private static readonly string[] segmentDates = { "daily", "weekly", "monthly", "male" }; private static readonly string[] segmentDates = { "daily", "weekly", "monthly", "male" };
public static readonly BindableProperty InternalTitleProperty = BindableProperty.Create(
nameof(InternalTitle), typeof(string), typeof(RankingPage));
public string InternalTitle
{
get => (string)GetValue(InternalTitleProperty);
set => SetValue(InternalTitleProperty, value);
}
public static readonly BindableProperty SegmentDateProperty = BindableProperty.Create( public static readonly BindableProperty SegmentDateProperty = BindableProperty.Create(
nameof(SegmentDate), typeof(int), typeof(RankingPage), propertyChanged: OnSegmentDatePropertyChanged); nameof(SegmentDate), typeof(int), typeof(RankingPage), propertyChanged: OnSegmentDatePropertyChanged);
public static readonly BindableProperty SegmentTypeVisibleProperty = BindableProperty.Create( public static readonly BindableProperty SegmentTypeVisibleProperty = BindableProperty.Create(
@ -132,12 +141,10 @@ namespace Pixiview.Illust
} }
SegmentTypeVisible = r18; SegmentTypeVisible = r18;
#if __ANDROID__
if (currentPage != 1 && Illusts == null) if (currentPage != 1 && Illusts == null)
{ {
currentPage = 1; currentPage = 1;
} }
#endif
base.OnAppearing(); base.OnAppearing();
} }
@ -190,7 +197,7 @@ namespace Pixiview.Illust
now = default; now = default;
} }
date = ResourceHelper.GetResource(data.mode, date); date = ResourceHelper.GetResource(data.mode, date);
MainThread.BeginInvokeOnMainThread(() => Title = date); MainThread.BeginInvokeOnMainThread(() => InternalTitle = date);
var prev_date = data.prev_date; var prev_date = data.prev_date;
if (int.TryParse(prev_date, out _)) if (int.TryParse(prev_date, out _))

View File

@ -29,12 +29,10 @@ namespace Pixiview.Illust
protected override void OnAppearing() protected override void OnAppearing()
{ {
#if __ANDROID__
if (startIndex != -1 && Illusts == null) if (startIndex != -1 && Illusts == null)
{ {
startIndex = -1; startIndex = -1;
} }
#endif
base.OnAppearing(); base.OnAppearing();
} }

View File

@ -40,12 +40,10 @@ namespace Pixiview.Illust
protected override void OnAppearing() protected override void OnAppearing()
{ {
#if __ANDROID__
if (startIndex != -1 && Illusts == null) if (startIndex != -1 && Illusts == null)
{ {
startIndex = -1; startIndex = -1;
} }
#endif
base.OnAppearing(); base.OnAppearing();
} }