I have a SettingsFlyout with a ListView with TextBlocks and when I try to reorder a TextBlock, the TextBlock dissapears behind the SettingsFlyout. When I move the TextBlock to the left, the TextBlock appears as soon as it moves from under the SettingsFlyOut.
I tried to give the TextBlocks a higher z-index, but that doesn't solve the problem.
Is this a bug? And can it be solved with a workaround?
Edit:
I found a workaround:
In the listview event DragItemStarting I make a grid with a white background on the underlying page visible and set the SettingsFlyout background transparent.
In the SettingsFlyout event 'LostFocus' I hide the white grid in the background and set the SettingsFlyout background back to white.
private void lstvwOrder_DragItemsStarting(object sender, DragItemsStartingEventArgs e)
{
Frame RootFRame = Window.Current.Content as Frame;
Page PageRoot = RootFRame.Content as Page;
Grid GridMain = PageRoot.FindName("GridMain") as Grid;
Grid grdSettingsBackground = PageRoot.FindName("grdSettingsBackground") as Grid;
grdSettingsBackground.Visibility = Visibility.Visible;
flyoutPreferences.Background = new SolidColorBrush(Colors.Transparent);
}
private void flyoutPreferences_LostFocus(object sender, RoutedEventArgs e)
{
Frame RootFRame = Window.Current.Content as Frame;
Page PageRoot = RootFRame.Content as Page;
Grid GridMain = PageRoot.FindName("GridMain") as Grid;
Grid grdSettingsBackground = PageRoot.FindName("grdSettingsBackground") as Grid;
flyoutPreferences.Background = new SolidColorBrush(Colors.White);
grdSettingsBackground.Visibility = Visibility.Collapsed;
}
The 'GridMain' is the first grid on every page and 'grdSettingsFlyout' is the grid with the same dimensions as the SettingsFlyout and with a white background color.