开发者

Silverlight Prism 4.0 Active Aware Alternative

开发者 https://www.devze.com 2023-02-14 19:17 出处:网络
Is it possible to implement something like the IActiveAware interface in prism where I track whether the User Control is visible or not.(Visually)

Is it possible to implement something like the IActiveAware interface in prism where I track whether the User Control is visible or not.(Visually)

IActiveAware does not work in all scenarios esp开发者_开发知识库ecially when used within sub regions.

Eg. Region A contains a view 1 with Region B with a view 2. When Region A's is navigated to view 3, view 1 IActiveAware's isActive is changed to false, but not the the view 2's IActiveAware, it is still active in memory even when view three is shown.

Cheers


I have included an interface that is based on the Loaded/Unloaded event to track the Visibility of the view on the screen. This works for now.

0

精彩评论

暂无评论...
验证码 换一张
取 消