private ToolViewModel ReloadTool(Xceed.Wpf.AvalonDock.Layout.LayoutContent model) { string cId = model.ContentId; var anchorable = model as Xceed.Wpf.AvalonDock.Layout.LayoutAnchorable; if (anchorable == null) { return(null); } if (cId == SearchViewModel.ToolContentId) { // нельзя делать после логина / убирать - в авалоне всегда должна быть модель searchPanel = new SearchViewModel() { Title = "Поиск" }; searchPanel.SetAnchorable(anchorable); searchPanel.IsVisible = switcher.WithSearch; Tools.Add(searchPanel); return(searchPanel); } return(null); }
public PaneViewModel(string windowID, string title, Xceed.Wpf.AvalonDock.Layout.LayoutContent layoutPane, System.Windows.Controls.UserControl contentControl) { WindowID = windowID; Title = title; LayoutPane = layoutPane; ContentControl = contentControl; }
public ToolViewModel(string windowID, string name, Xceed.Wpf.AvalonDock.Layout.LayoutContent layoutPane, System.Windows.Controls.UserControl control, SystemControllerEnums.DockPosition position) : base(windowID, name, layoutPane, control) { Name = name; Title = name; DockPosition = position; }
public DocumentViewModel(string windowID, string title, Xceed.Wpf.AvalonDock.Layout.LayoutContent layoutPane, System.Windows.Controls.UserControl control) : base(windowID, title, layoutPane, control) { // Asigna las propiedades IsDirty = false; // Asigna el icono //IconSource = ISC.ConvertFromInvariantString(@"pack://application:,,/Images/document.png") as ImageSource; }
private ScreenBaseViewModel ReloadDocument(Xceed.Wpf.AvalonDock.Layout.LayoutContent model) { string cId = model.ContentId; if (cId == ScreenBaseViewModel.ScreenContentId) { return(CurrentView); } return(null); }