mirror of
https://github.com/OrcaSlicer/OrcaSlicer.git
synced 2026-10-06 07:11:10 +00:00
* Add Missing Includes Across src/slic3r/GUI Every GUI source and header now directly includes the headers declaring what it uses, rather than relying on the precompiled header or transitive includes. Generated with clang-tidy misc-include-cleaner, plus one hand edit making CalibrationPanel.hpp self-contained. * Drop the OS-Specific Includes Added Outside Their Platform Guards GLib, GTK, D-Bus and POSIX headers are only used inside platform #if blocks, which already include them. Added unconditionally at the top of the file they broke the Windows build. * Add the clang-tidy Configuration That Generated These Includes Only misc-include-cleaner's missing-include check, with the headers it must never suggest: per-platform, internal and OS-specific ones that would break other platforms or are not meant to be included directly. * Match Windows Paths in the clang-tidy Ignore List Header paths use backslashes on Windows, so every / in a pattern is now [/\\]. The Windows SDK headers are ignored alongside the other OS-specific ones, and the list is one pattern per line. Suggested by @raistlin7447 from a Windows clang-cl run.
55 lines
1.6 KiB
C++
55 lines
1.6 KiB
C++
#ifndef _STEP_MESH_DIALOG_H_
|
|
#define _STEP_MESH_DIALOG_H_
|
|
|
|
#include <thread>
|
|
#include <wx/event.h>
|
|
#include "GUI_App.hpp"
|
|
#include "GUI_Utils.hpp"
|
|
#include "libslic3r/Format/STEP.hpp"
|
|
#include "Widgets/Button.hpp"
|
|
class Button;
|
|
|
|
class StepMeshDialog : public Slic3r::GUI::DPIDialog
|
|
{
|
|
public:
|
|
StepMeshDialog(wxWindow* parent, Slic3r::Step& file, double linear_init, double angle_init);
|
|
~StepMeshDialog() override;
|
|
void on_dpi_changed(const wxRect& suggested_rect) override;
|
|
inline double get_linear_deflection() {
|
|
double value;
|
|
if (m_linear_last.ToDouble(&value)) {
|
|
return value;
|
|
}else {
|
|
return m_last_linear;
|
|
}
|
|
}
|
|
inline double get_angle_deflection() {
|
|
double value;
|
|
if (m_angle_last.ToDouble(&value)) {
|
|
return value;
|
|
} else {
|
|
return m_last_angle;
|
|
}
|
|
}
|
|
inline bool get_split_compound_value() {
|
|
return m_split_compound_checkbox->GetValue();
|
|
}
|
|
private:
|
|
Slic3r::Step& m_file;
|
|
wxCheckBox* m_checkbox = nullptr;
|
|
wxCheckBox* m_split_compound_checkbox = nullptr;
|
|
wxCheckBox* m_save_default_checkbox = nullptr;
|
|
wxString m_linear_last;
|
|
wxString m_angle_last;
|
|
wxStaticText* mesh_face_number_text;
|
|
double m_last_linear = 0.003;
|
|
double m_last_angle = 0.5;
|
|
unsigned int m_mesh_number = 0;
|
|
boost::thread* m_task {nullptr};
|
|
bool validate_number_range(const wxString& value, double min, double max);
|
|
void update_mesh_number_text();
|
|
void on_task_done(wxCommandEvent& event);
|
|
void stop_task();
|
|
};
|
|
|
|
#endif // _STEP_MESH_DIALOG_H_
|