Change listview item double click to show part view

- Issue MatterHackers/MCCentral#4464
Library -> Part -> DoubleClick should fire Open behavior
This commit is contained in:
John Lewin 2018-11-01 17:00:27 -07:00
parent 53cb371879
commit da320e739e
3 changed files with 11 additions and 7 deletions

View file

@ -698,11 +698,7 @@ namespace MatterHackers.MatterControl.PrintLibrary
Icon = AggContext.StaticData.LoadIcon("cube.png", 16, 16, theme.InvertIcons),
Action = (selectedLibraryItems, listView) =>
{
ApplicationController.Instance.MainView.CreatePartTab().ContinueWith(task =>
{
var workspace = ApplicationController.Instance.Workspaces.Last();
workspace.SceneContext.AddToPlate(selectedLibraryItems);
});
ApplicationController.Instance.OpenIntoNewTab(selectedLibraryItems);
},
IsEnabled = (selectedListItems, listView) =>
{

View file

@ -435,8 +435,7 @@ namespace MatterHackers.MatterControl.CustomWidgets
// List items
if (itemModel != null)
{
var activeContext = ApplicationController.Instance.DragDropData;
activeContext.SceneContext?.AddToPlate(new[] { itemModel });
ApplicationController.Instance.OpenIntoNewTab(new[] { itemModel });
}
}
});