public void ActivateContent(Content content) { // TODO load order ActiveContent.Add(content); InvalidateCache(); RefreshContent(content); }
public void UpdateActiveAdditionalContent(IReadOnlyCollection <Content> contents) { ActiveContent.Clear(); ActiveContent.Add(Vanilla); foreach (var content in contents) { ActiveContent.Add(content); } InvalidateCache(); }
public override void GetMenu(MenuBuilder bld) { if (RedirectMenuToActiveContent && ActiveContent != null) { ActiveContent.GetMenu(bld); } else { base.GetMenu(bld); } }
public void LoadVanilla(string gameDir) { Vanilla = new Content(); Vanilla.Name = "vanilla"; Vanilla.AbsolutePath = gameDir; logger.LogInformation("Loading portraits from vanilla."); var reader = new PortraitReader(gameDir); Vanilla.PortraitData = reader.Parse(); // Init ActivePortraitData = Vanilla.PortraitData; ActiveContent.Add(Vanilla); InvalidateCache(); }
public void InitContent() { Clear(); ActiveContent = AddContent(); ActiveContent.SetBounds(Splitter <T> .SIZE, Splitter <T> .SIZE, Width - (2 * Splitter <T> .SIZE), Height - (2 * Splitter <T> .SIZE)); }
public void DeactivateContent(Content content) { ActiveContent.Remove(content); InvalidateCache(); }
private void Close_Executed(object sender, ExecutedRoutedEventArgs e) { App.Current.Settings.MainWindowLayout = dock.SaveLayout(); ActiveContent.Close(); }