Allow IObjectSlicer to drive active settings
This commit is contained in:
parent
cd5b5c6fe4
commit
5c81e19a3c
5 changed files with 13 additions and 5 deletions
|
|
@ -74,7 +74,7 @@ namespace MatterHackers.MatterControl.SlicerConfiguration
|
|||
public class PrinterSettings
|
||||
{
|
||||
// TODO: Move to more appropriate location after more consideration
|
||||
public static IObjectSlicer ExternalSlicer { get; set; }
|
||||
public static IObjectSlicer Slicer { get; set; }
|
||||
|
||||
// Latest version should be in the form of:
|
||||
// Year|month|day|versionForDay (to support multiple revisions on a given day)
|
||||
|
|
@ -711,6 +711,12 @@ namespace MatterHackers.MatterControl.SlicerConfiguration
|
|||
&& (differsFromPreset || differsFromBase);
|
||||
}
|
||||
|
||||
public bool IsActive(string canonicalSettingsName)
|
||||
{
|
||||
return PrinterSettings.Slicer.MapContains(canonicalSettingsName)
|
||||
|| PrinterSettings.ApplicationLevelSettings.Contains(canonicalSettingsName);
|
||||
}
|
||||
|
||||
// Helper method to debug settings layers per setting
|
||||
public List<(string layerName, string currentValue)> GetLayerValues(string sliceSetting, IEnumerable<PrinterSettingsLayer> layerCascade = null)
|
||||
{
|
||||
|
|
|
|||
Loading…
Add table
Add a link
Reference in a new issue