mirror of
https://git.mirrors.martin98.com/https://github.com/slic3r/Slic3r.git
synced 2025-07-30 22:42:03 +08:00
Fixed includes on OSX and silenced override warnings.
This commit is contained in:
parent
6762870529
commit
533a2314fd
@ -17,7 +17,7 @@ namespace Slic3r { namespace GUI {
|
||||
class App: public wxApp
|
||||
{
|
||||
public:
|
||||
virtual bool OnInit();
|
||||
virtual bool OnInit() override;
|
||||
App() : wxApp() {}
|
||||
|
||||
/// Save position, size, and maximize state for a TopLevelWindow (includes Frames) by name in Settings.
|
||||
|
@ -127,7 +127,7 @@ public:
|
||||
protected:
|
||||
virtual std::string LogChannel() override { return "UI_Checkbox"s; }
|
||||
|
||||
void _on_change(std::string opt_id) {
|
||||
void _on_change(std::string opt_id) override {
|
||||
if (!this->disable_change_event && this->window->IsEnabled() && this->on_change != nullptr) {
|
||||
this->on_change(opt_id, this->get_bool());
|
||||
}
|
||||
@ -241,7 +241,7 @@ public:
|
||||
protected:
|
||||
virtual std::string LogChannel() override { return "UI_Choice"s; }
|
||||
|
||||
void _on_change(std::string opt_id) {
|
||||
void _on_change(std::string opt_id) override {
|
||||
if (!this->disable_change_event && this->window->IsEnabled() && this->on_change != nullptr) {
|
||||
this->on_change(opt_id, this->get_string());
|
||||
}
|
||||
@ -283,7 +283,7 @@ protected:
|
||||
void _set_value(double value, bool show_value = false);
|
||||
void _set_value(std::string value);
|
||||
|
||||
void _on_change(std::string opt_id) {
|
||||
void _on_change(std::string opt_id) override {
|
||||
if (!this->disable_change_event && this->window->IsEnabled() && this->on_change != nullptr) {
|
||||
this->on_change(opt_id, this->get_string());
|
||||
}
|
||||
@ -298,7 +298,7 @@ public:
|
||||
|
||||
UI_Point(wxWindow* _parent, Slic3r::ConfigOptionDef _opt);
|
||||
~UI_Point() { _lbl_x->Destroy(); _lbl_y->Destroy(); _ctrl_x->Destroy(); _ctrl_y->Destroy(); }
|
||||
std::string get_string();
|
||||
std::string get_string() override;
|
||||
|
||||
void set_value(boost::any value) override; //< Implements set_value
|
||||
|
||||
@ -347,7 +347,7 @@ class UI_Point3 : public UI_Sizer {
|
||||
public:
|
||||
UI_Point3(wxWindow* _parent, Slic3r::ConfigOptionDef _opt);
|
||||
~UI_Point3() { _lbl_x->Destroy(); _lbl_y->Destroy(); _ctrl_x->Destroy(); _ctrl_y->Destroy(); _lbl_z->Destroy(); _ctrl_z->Destroy(); }
|
||||
std::string get_string();
|
||||
std::string get_string() override;
|
||||
|
||||
void set_value(boost::any value) override; //< Implements set_value
|
||||
|
||||
|
@ -2,9 +2,11 @@
|
||||
#include "Line.hpp"
|
||||
#include "ClipperUtils.hpp"
|
||||
#include "misc_ui.hpp"
|
||||
|
||||
#ifdef __APPLE__
|
||||
#include <OpenGL/glu.h>
|
||||
#else
|
||||
#include <GL/glu.h>
|
||||
|
||||
#endif
|
||||
namespace Slic3r { namespace GUI {
|
||||
|
||||
Scene3D::Scene3D(wxWindow* parent, const wxSize& size) :
|
||||
|
@ -102,7 +102,7 @@ class ConfigOptionFloat : public ConfigOptionSingle<double>
|
||||
public:
|
||||
ConfigOptionFloat() : ConfigOptionSingle<double>(0) {};
|
||||
ConfigOptionFloat(double _value) : ConfigOptionSingle<double>(_value) {};
|
||||
ConfigOptionFloat* clone() const { return new ConfigOptionFloat(this->value); };
|
||||
ConfigOptionFloat* clone() const override { return new ConfigOptionFloat(this->value); };
|
||||
|
||||
double getFloat() const override { return this->value; };
|
||||
void setFloat(double val) override { this->value = val; }
|
||||
@ -199,7 +199,7 @@ class ConfigOptionInts : public ConfigOptionVector<int>
|
||||
ConfigOptionInts(const std::vector<int> _values) : ConfigOptionVector<int>(_values) {};
|
||||
ConfigOptionInts* clone() const override { return new ConfigOptionInts(this->values); };
|
||||
|
||||
std::string serialize() const {
|
||||
std::string serialize() const override {
|
||||
std::ostringstream ss;
|
||||
for (std::vector<int>::const_iterator it = this->values.begin(); it != this->values.end(); ++it) {
|
||||
if (it - this->values.begin() != 0) ss << ",";
|
||||
@ -208,7 +208,7 @@ class ConfigOptionInts : public ConfigOptionVector<int>
|
||||
return ss.str();
|
||||
};
|
||||
|
||||
std::vector<std::string> vserialize() const {
|
||||
std::vector<std::string> vserialize() const override {
|
||||
std::vector<std::string> vv;
|
||||
vv.reserve(this->values.size());
|
||||
for (std::vector<int>::const_iterator it = this->values.begin(); it != this->values.end(); ++it) {
|
||||
@ -219,7 +219,7 @@ class ConfigOptionInts : public ConfigOptionVector<int>
|
||||
return vv;
|
||||
};
|
||||
|
||||
bool deserialize(std::string str, bool append = false) {
|
||||
bool deserialize(std::string str, bool append = false) override {
|
||||
if (!append) this->values.clear();
|
||||
std::istringstream is(str);
|
||||
std::string item_str;
|
||||
|
Loading…
x
Reference in New Issue
Block a user