locked
Hover button state is stuck on parent when using CharmFlyout RRS feed

  • Question

  • Hi,

    I'm using charmflyout and the button state is stuck on the parent flyout regardless of how I get back to the parent screen.

    Here the Add button is normal.  However if I click it and then return to this parent form either through the back button or closing the charm and reopening it, it is stuck in the hover state.  I have tried several styles and capturing several events but I can't figure this out.  If I hover over the button and then off of it, the state/display is back to normal. 

    Has anyone run into this?  Anyone have any ideas how to fix this?

    Thanks,

    Mike


    blog - http://www.codesmartnothard.com

    Monday, June 3, 2013 12:53 AM

Answers

  • It's a known bug.

    Matt Small - Microsoft Escalation Engineer - Forum Moderator
    If my reply answers your question, please mark this post as answered.

    NOTE: If I ask for code, please provide something that I can drop directly into a project and run (including XAML), or an actual application project. I'm trying to help a lot of people, so I don't have time to figure out weird snippets with undefined objects and unknown namespaces.

    Tuesday, June 4, 2013 1:02 PM
    Moderator

All replies

  • Here is some additional code from the settings.xaml and settings.xaml.cs files.

            private void OnViewAddEditTfsSettings(object sender, RoutedEventArgs e)
            {
                cfoTfsAddEditSettings.IsOpen = true;
            }
    
            private void OnCloseAddEditTfsSettings(object sender, RoutedEventArgs e)
            {
                cfoAppSettings.IsOpen = true;
                cfoTfsAddEditSettings.IsOpen = false;
            }

    <cfo:CharmFlyout
               x:Name="cfoTfsAddEditSettings"
               Heading="Manage TFS Connections"
               HeadingBackgroundBrush="#FF4E0000"
                ParentFlyout="{Binding ElementName=cfoAppSettings}">
                <StackPanel>
     

    <Button Height="32" Width="32" BorderBrush="Black" x:Name="AddConnectionButton" Click="OnViewAddEditTfsSettings" Command="{Binding AddTfsConnectionCommand}"> <Button.Background> <ImageBrush ImageSource="../Assets/Buttons/Add.png" /> </Button.Background> </Button>




    blog - http://www.codesmartnothard.com


    • Edited by MikeDouglasMVP Monday, June 3, 2013 1:09 AM splitting xml code
    Monday, June 3, 2013 1:07 AM
  • I downloaded the CharmFlyout sample project and it has the same issue.  I didn't notice it at first because the colors were similar.  If you download the source code with the sample, you should be able to reproduce it.  After you go back to the part, hover over the button and away.  You will notice the color change.

    http://charmflyout.codeplex.com/

    Thanks,

    Mike


    blog - http://www.codesmartnothard.com

    Monday, June 3, 2013 5:00 AM
  • See this thread:

    http://social.msdn.microsoft.com/Forums/en-US/winappswithcsharp/thread/32b12df0-f132-43cf-a675-51832e7186fb


    Matt Small - Microsoft Escalation Engineer - Forum Moderator
    If my reply answers your question, please mark this post as answered.

    NOTE: If I ask for code, please provide something that I can drop directly into a project and run (including XAML), or an actual application project. I'm trying to help a lot of people, so I don't have time to figure out weird snippets with undefined objects and unknown namespaces.

    Monday, June 3, 2013 12:57 PM
    Moderator
  • Hi Matt,

    Thanks for the reply.  I tried to use this but the flyout charms are contained in a usercontrol and not a page/view.  I'm not setting NavigationCacheMode="Required" and I don't have access to this property.  Do you how this would work with a usercontrol and the flyoutcharm?  I tried a number of different things but none of them seem to have any affect.

    Thanks,

    Mike


    blog - http://www.codesmartnothard.com

    Tuesday, June 4, 2013 12:57 PM
  • It's a known bug.

    Matt Small - Microsoft Escalation Engineer - Forum Moderator
    If my reply answers your question, please mark this post as answered.

    NOTE: If I ask for code, please provide something that I can drop directly into a project and run (including XAML), or an actual application project. I'm trying to help a lot of people, so I don't have time to figure out weird snippets with undefined objects and unknown namespaces.

    Tuesday, June 4, 2013 1:02 PM
    Moderator
  • That is unfortunate.  I guess I'll have to make the hover style very similar to the normal one so it will be hard to notice.

    Thanks,

    Mike


    blog - http://www.codesmartnothard.com

    Tuesday, June 4, 2013 1:46 PM