private static void OnTopmostChanged(DependencyObject obj, DependencyPropertyChangedEventArgs e) { TsfPopup tsfPopup = obj as TsfPopup; if ((object)tsfPopup != null && tsfPopup.IsOpen) { tsfPopup.UpdateWindow(); } }
/// <summary> /// Creates a new instance of the <see cref="PagedViewModelBase{T1,T2}"/> class. /// </summary> /// <param name="itemsPerPage">Integer value to determine number of items per page.</param> /// <param name="autoSave">Boolean value to determine is user changes should be saved automatically.</param> protected PagedViewModelBase(int itemsPerPage, bool autoSave = true) { m_itemsPerPage = itemsPerPage; m_autoSave = autoSave; Initialize(); if (itemsPerPage > 0) { Load(); } m_timer = new DispatcherTimer(); m_timer.Interval = TimeSpan.FromSeconds(5); m_timer.Tick += m_timer_Tick; m_statusTextBlock = Application.Current.MainWindow.FindName("TextBlockResult") as TextBlock; m_statusPopup = Application.Current.MainWindow.FindName("PopupStatus") as TsfPopup; }