Revise AddToQueueFromLibraryButtonAddsItemToQueue test
- Restore Add To Queue functionality - Expose reusable AddAllItems() to PrintQueueCollection - Revise base implementation of FileSystemItem to support default name based on filename unless set
This commit is contained in:
parent
ba754dba19
commit
add70a2f90
4 changed files with 39 additions and 44 deletions
|
|
@ -64,6 +64,13 @@ namespace MatterHackers.MatterControl.Library
|
|||
}
|
||||
|
||||
public override async void Add(IEnumerable<ILibraryItem> items)
|
||||
{
|
||||
await AddAllItems(items);
|
||||
|
||||
this.ReloadContainer();
|
||||
}
|
||||
|
||||
public static async Task AddAllItems(IEnumerable<ILibraryItem> items)
|
||||
{
|
||||
await Task.Run(async () =>
|
||||
{
|
||||
|
|
@ -98,8 +105,6 @@ namespace MatterHackers.MatterControl.Library
|
|||
0);
|
||||
}
|
||||
}
|
||||
|
||||
this.ReloadContainer();
|
||||
});
|
||||
}
|
||||
|
||||
|
|
@ -110,7 +115,7 @@ namespace MatterHackers.MatterControl.Library
|
|||
var fileSystemItem = item as FileSystemFileItem;
|
||||
if (fileSystemItem != null)
|
||||
{
|
||||
var matches = QueueData.Instance.PrintItems.Where(p => p.FileLocation == fileSystemItem.Path);
|
||||
var matches = QueueData.Instance.PrintItems.Where(p => p.FileLocation == fileSystemItem.Path).ToList();
|
||||
|
||||
foreach(var printItem in matches)
|
||||
{
|
||||
|
|
|
|||
Loading…
Add table
Add a link
Reference in a new issue