Attached method to Closed event on Popup not firing when popup is dismissed

Topics: Actions & Coroutines, Bugs, Conventions
Oct 15, 2013 at 10:19 AM
Edited Oct 15, 2013 at 10:19 AM

When attaching a handler to the 'Closed' event on a Popup in WinRT XAML, the handler is not triggered, even though the popup closes. If i add a handler in the codebehind and add it directly to the Closed event on the Popup in XAML it works fine.

Ive tried using both short syntax and full XAML syntax for the ActionMessage, nothing works.

The 'Closed' event is triggered when i click 'outside' the popup, because of the IsLightDismissEnabled="True" setting.

Here is my XAML:
<Popup VerticalOffset="-200"
        IsOpen="{Binding Settings, Converter={StaticResource ThruthyConverter}}"
        cal:Message.Attach="[Event Closed] = [Action CloseSettings]">
    <Border Background="DarkCyan">
        <ContentControl cal:View.Model="{Binding Settings}"
                        cal:View.Context="{Binding SettingsContext}" />
<Button cal:Message.Attach="OpenSettings('CreateUser')">Opret bruger</Button>
Anyone got any thoughts?
Oct 15, 2013 at 5:46 PM