public static void Load(this ISceneManager sceneManager, IGraphSceneDisplay <IVisual, IVisualEdge> display, Int64 id, bool checkOpen = true) { if (id == 0) { return; } if (checkOpen && sceneManager.IsSceneOpen(id, true, true)) { return; } var scene = sceneManager.Load(display.Data.Graph, display.Layout, id); var info = sceneManager.SheetStore.GetSheetInfo(id); display.AssignScene(scene, info); }
public static void Load(this ISceneManager sceneManager, IGraphSceneDisplay <IVisual, IVisualEdge> display, Content <Stream> content, bool checkOpen = true) { if (content == null) { return; } var id = sceneManager.IdOf(content); if (checkOpen && sceneManager.IsSceneOpen(id, true, true)) { return; } var scene = sceneManager.LoadFromContent(content, display.Data.Graph, display.Layout); var info = sceneManager.SheetStore.GetSheetInfo(id); display.AssignScene(scene, info); }