Re-wrote the load filament wizard as not a macro so we have more control over it
Added it to the setup steps issue: MatterHackers/MCCentral#4429 Put in a loading filament as part of initial setup process
This commit is contained in:
parent
6469cba676
commit
775f1982bd
68 changed files with 832 additions and 492 deletions
|
|
@ -36,6 +36,7 @@ using MatterHackers.Agg.Platform;
|
|||
using MatterHackers.Agg.UI;
|
||||
using MatterHackers.Localizations;
|
||||
using MatterHackers.MatterControl.ConfigurationPage;
|
||||
using MatterHackers.MatterControl.ConfigurationPage.PrintLeveling;
|
||||
using MatterHackers.MatterControl.CustomWidgets;
|
||||
using MatterHackers.MatterControl.PrinterCommunication;
|
||||
using MatterHackers.MatterControl.SlicerConfiguration;
|
||||
|
|
@ -63,15 +64,16 @@ namespace MatterHackers.MatterControl.ActionBar
|
|||
Padding = theme.ToolbarPadding,
|
||||
};
|
||||
|
||||
var loadFilament = new GCodeMacro()
|
||||
{
|
||||
GCode = AggContext.StaticData.ReadAllText(Path.Combine("SliceSettings", "load_filament.txt"))
|
||||
};
|
||||
|
||||
var loadButton = theme.CreateDialogButton("Load".Localize());
|
||||
loadButton.ToolTipText = "Load filament".Localize();
|
||||
loadButton.Name = "Load Filament Button";
|
||||
loadButton.Click += (s, e) => loadFilament.Run(printer.Connection);
|
||||
loadButton.Click += (s, e) =>
|
||||
{
|
||||
UiThread.RunOnIdle(() =>
|
||||
{
|
||||
LoadFilamentWizard.Start(printer, theme, true);
|
||||
});
|
||||
};
|
||||
macroButtons.AddChild(loadButton);
|
||||
|
||||
var unloadFilament = new GCodeMacro()
|
||||
|
|
|
|||
Loading…
Add table
Add a link
Reference in a new issue