mirror of
https://github.com/OrcaSlicer/OrcaSlicer.git
synced 2026-09-26 18:31:11 +00:00
fix: split infra from impl
This commit is contained in:
@@ -1,9 +1,7 @@
|
||||
#ifndef __QIDI_PRINTER_AGENT_HPP__
|
||||
#define __QIDI_PRINTER_AGENT_HPP__
|
||||
|
||||
#include "IPrinterAgent.hpp"
|
||||
#include "MoonrakerPrinterAgent.hpp"
|
||||
#include "nlohmann/json_fwd.hpp"
|
||||
|
||||
#include <map>
|
||||
#include <string>
|
||||
@@ -23,23 +21,7 @@ public:
|
||||
// Override filament sync (Qidi-specific implementation)
|
||||
bool fetch_filament_info(std::string dev_id, FilamentSyncMode sync_mode = FilamentSyncMode::pull) override;
|
||||
|
||||
static bool parse_slot_response(const std::string& response_body,
|
||||
nlohmann::json& status,
|
||||
nlohmann::json& variables,
|
||||
std::string& error);
|
||||
|
||||
// Print operations — emit QiDi multi-color box config, then delegate to base.
|
||||
int start_print(PrintParams params, OnUpdateStatusFn update_fn, WasCancelledFn cancel_fn, OnWaitFn wait_fn) override;
|
||||
int start_local_print(PrintParams params, OnUpdateStatusFn update_fn, WasCancelledFn cancel_fn) override;
|
||||
int start_local_print_with_record(PrintParams params, OnUpdateStatusFn update_fn, WasCancelledFn cancel_fn, OnWaitFn wait_fn) override;
|
||||
int start_sdcard_print(PrintParams params, OnUpdateStatusFn update_fn, WasCancelledFn cancel_fn) override;
|
||||
|
||||
FilamentSyncMode get_filament_sync_mode() const override;
|
||||
|
||||
private:
|
||||
// Push enable_box + value_t<tool> SAVE_VARIABLEs before a print starts.
|
||||
// Returns false if any command fails (caller should abort the print).
|
||||
bool apply_box_mapping(const PrintParams& params) const;
|
||||
struct QidiFilamentDict
|
||||
{
|
||||
std::map<int, std::string> colors;
|
||||
|
||||
Reference in New Issue
Block a user