Skip to content

Commit

Permalink
Only set Window.Content when null. Resolves #224
Browse files Browse the repository at this point in the history
  • Loading branch information
nigel-sampson committed Nov 16, 2015
1 parent c59a82b commit c437f13
Show file tree
Hide file tree
Showing 2 changed files with 2 additions and 2 deletions.
2 changes: 1 addition & 1 deletion src/Caliburn.Micro.Platform/win8/CaliburnApplication.cs
Original file line number Diff line number Diff line change
Expand Up @@ -229,7 +229,7 @@ protected void DisplayRootView(Type viewType, object paramter = null) {
RootFrame.Navigate(viewType, paramter);

// Seems stupid but observed weird behaviour when resetting the Content
if (Window.Current.Content != RootFrame)
if (Window.Current.Content == null)
Window.Current.Content = RootFrame;

Window.Current.Activate();
Expand Down
2 changes: 1 addition & 1 deletion src/Caliburn.Micro.Platform/win8/INavigationService.cs
Original file line number Diff line number Diff line change
Expand Up @@ -479,7 +479,7 @@ public virtual bool ResumeState() {

BindViewModel(view);

if (Window.Current.Content != frame)
if (Window.Current.Content == null)
Window.Current.Content = frame;

Window.Current.Activate();
Expand Down

0 comments on commit c437f13

Please sign in to comment.