Windows Phone 8.1 BottomAppBar在恢复或导航到另一个页面后消失

时间:2015-06-25 09:10:01

标签: windows-phone-8.1 appbar messagedialog

我在xaml中为一个ListPage和ReportsPage中的另一个BottomAppBar声明了BottomAppBar。 有时当应用程序恢复BottomAppBar消失时,当我使用MessageDialog控件从ListPage导航到ReportsPage时,它经常消失。

  

末页:

<Page.BottomAppBar>
    <CommandBar x:Name="bottomApplicationBar" Loaded="FrameworkElement_OnLoaded">
        <AppBarButton x:Name="AddAppBarButton" IsEnabled="True" Label="{Binding [select_button], Source={StaticResource LocalizedStrings}}" Icon="Edit" />
        <AppBarButton x:Name="RefreshAppBarButton" IsEnabled="True" Label="{Binding [refresh_button],Source={StaticResource LocalizedStrings}}" Icon="Refresh" />
        <AppBarButton IsEnabled="False" x:Name="SetTripTypeBarButton" Label="{Binding [triplist_bulkedit_set_trip_class], Source={StaticResource LocalizedStrings}}" Visibility="Collapsed"  Flyout="{StaticResource TripTypeFlyout}">
            <AppBarButton.Icon>
                <FontIcon Glyph="T" FontWeight="Bold"/>
            </AppBarButton.Icon>
        </AppBarButton>
        <AppBarButton IsEnabled="False" x:Name="SetTripPurposeBarButton" Label="{Binding [triplist_bulkedit_set_purpose], Source={StaticResource LocalizedStrings}}" Visibility="Collapsed" >
            <AppBarButton.Icon>
                <FontIcon Glyph="P" FontWeight="Bold"/>
            </AppBarButton.Icon>
        </AppBarButton>
        <AppBarButton IsEnabled="False" x:Name="DeleteAppBarItem" Label="{Binding [triplist_bulkedit_delete], Source={StaticResource LocalizedStrings}}" Icon="Delete" ></AppBarButton>
        <CommandBar.SecondaryCommands>
            <AppBarButton Visibility="Collapsed" x:Name="allTripsButton"  Label="{Binding [triplist_bulkedit_all_trips],Source={StaticResource LocalizedStrings}}" Icon="Font" />                
            <AppBarButton Visibility="Collapsed" x:Name="allTripsPurposeButton" Label="{Binding [triplist_bulkedit_missing_purpose], Source={StaticResource LocalizedStrings}}" />
            <AppBarButton Visibility="Collapsed" x:Name="allTripsFromReportButton" Label="{Binding [triplist_bulkedit_all_trips],Source={StaticResource LocalizedStrings}}"   />
        </CommandBar.SecondaryCommands>
    </CommandBar>
</Page.BottomAppBar>     
  

ReportsPage:

<Page.BottomAppBar>
    <CommandBar x:Name="submitAppBar" IsOpen="True" >
        <CommandBar.PrimaryCommands>               
            <AppBarButton x:Name="submitReportAppBarButton" Label="{Binding [report_submission_submit_button], Source={StaticResource LocalizedStrings}}" Click="SubmitReportAppBarButton_OnClick" Icon="Accept" IsEnabled="False" />
        </CommandBar.PrimaryCommands>
    </CommandBar>
</Page.BottomAppBar>

0 个答案:

没有答案