wpffluent-ribbon

Backstage Button doesn't close Backstage


In Office 2010 when a Backstage button is pressed the Backstage would automatically close. For example I have a Backstage with New, Open and Save buttons.

When I click on a button the Backstage is not being closed - I suppose that's not the correct behavior. How can I let Fluent-Ribbon handle the Backstage correct?

I'm using the current release 2.0 from november 2010 (http://fluent.codeplex.com/releases/view/55556).


Solution

  • This seems to be a defect in the ribbon that is fixed in the latest version in sound control, but not yet in the latest released version.

    For now you can work around this using the following

    // During initialisation
    myRibbon.Menu.AddHandler(PopupService.DismissPopupEvent, (DismissPopupEventHandler)OnPopupDismiss);
    
    private void OnPopupDismiss(object sender, DismissPopupEventArgs e)
    {
        var backstage = Menu as Backstage;
        if (backstage != null)
        {
            backstage.IsOpen = false;
        }
    }