Calendar stuff.
This commit is contained in:
@@ -1,4 +1,4 @@
|
||||
<abstract:AppShellAbstract
|
||||
<abstract:AppShellAbstract
|
||||
x:Class="Wino.Calendar.Views.AppShell"
|
||||
xmlns="http://schemas.microsoft.com/winfx/2006/xaml/presentation"
|
||||
xmlns:x="http://schemas.microsoft.com/winfx/2006/xaml"
|
||||
@@ -119,6 +119,7 @@
|
||||
FontSize="14"
|
||||
FontWeight="Normal"
|
||||
IsHitTestVisible="False"
|
||||
DisplayType="{x:Bind ViewModel.StatePersistenceService.CalendarDisplayType, Mode=OneWay}"
|
||||
ItemsSource="{x:Bind ViewModel.DateNavigationHeaderItems}"
|
||||
SelectedIndex="{x:Bind ViewModel.SelectedDateNavigationHeaderIndex, Mode=OneWay}">
|
||||
<FlipView.ItemTemplate>
|
||||
|
||||
@@ -20,13 +20,13 @@ public sealed partial class AppShell : AppShellAbstract,
|
||||
InitializeComponent();
|
||||
|
||||
Window.Current.SetTitleBar(DragArea);
|
||||
ManageCalendarDisplayType();
|
||||
ManageCalendarDisplayType(ViewModel.StatePersistenceService.CalendarDisplayType);
|
||||
}
|
||||
|
||||
private void ManageCalendarDisplayType()
|
||||
private void ManageCalendarDisplayType(Core.Domain.Enums.CalendarDisplayType displayType)
|
||||
{
|
||||
// Go to different states based on the display type.
|
||||
if (ViewModel.IsVerticalCalendar)
|
||||
if (displayType == Core.Domain.Enums.CalendarDisplayType.Month)
|
||||
{
|
||||
VisualStateManager.GoToState(this, STATE_VerticalCalendar, false);
|
||||
}
|
||||
@@ -42,7 +42,7 @@ public sealed partial class AppShell : AppShellAbstract,
|
||||
|
||||
public void Receive(CalendarDisplayTypeChangedMessage message)
|
||||
{
|
||||
ManageCalendarDisplayType();
|
||||
ManageCalendarDisplayType(message.NewDisplayType);
|
||||
}
|
||||
|
||||
private void ShellFrameContentNavigated(object sender, Windows.UI.Xaml.Navigation.NavigationEventArgs e)
|
||||
|
||||
Reference in New Issue
Block a user