Merge branch 'master' of https://github.com/prusa3d/Slic3r
This commit is contained in:
commit
58acbd6bc9
4 changed files with 29 additions and 17 deletions
|
@ -1223,7 +1223,8 @@ namespace Slic3r {
|
|||
return;
|
||||
|
||||
// see http://reprap.org/wiki/G-code#M203:_Set_maximum_feedrate
|
||||
float factor = (dialect == gcfMarlin) ? 1.0f : MMMIN_TO_MMSEC;
|
||||
// http://smoothieware.org/supported-g-codes
|
||||
float factor = (dialect == gcfMarlin || dialect == gcfSmoothie) ? 1.0f : MMMIN_TO_MMSEC;
|
||||
|
||||
if (line.has_x())
|
||||
set_axis_max_feedrate(X, line.x() * factor);
|
||||
|
|
|
@ -36,6 +36,8 @@
|
|||
#define ENABLE_REMOVE_TABS_FROM_PLATER (1 && ENABLE_1_42_0)
|
||||
// Constrains the camera target into the scene bounding box
|
||||
#define ENABLE_CONSTRAINED_CAMERA_TARGET (1 && ENABLE_1_42_0)
|
||||
// Use wxDataViewRender instead of wxDataViewCustomRenderer
|
||||
#define ENABLE_NONCUSTOM_DATA_VIEW_RENDERING (0 && ENABLE_1_42_0)
|
||||
|
||||
#endif // _technologies_h_
|
||||
|
||||
|
|
|
@ -1228,14 +1228,6 @@ void PrusaObjectDataViewModel::SetVolumeType(const wxDataViewItem &item, const i
|
|||
ItemChanged(item);
|
||||
}
|
||||
|
||||
PrusaBitmapTextRenderer::PrusaBitmapTextRenderer(wxDataViewCellMode mode /*= wxDATAVIEW_CELL_EDITABLE*/,
|
||||
int align /*= wxDVR_DEFAULT_ALIGNMENT*/):
|
||||
wxDataViewRenderer(wxT("PrusaDataViewBitmapText"), mode, align)
|
||||
{
|
||||
SetMode(mode);
|
||||
SetAlignment(align);
|
||||
}
|
||||
|
||||
//-----------------------------------------------------------------------------
|
||||
// PrusaDataViewBitmapText
|
||||
//-----------------------------------------------------------------------------
|
||||
|
@ -1248,6 +1240,16 @@ IMPLEMENT_VARIANT_OBJECT(PrusaDataViewBitmapText)
|
|||
// PrusaIconTextRenderer
|
||||
// ---------------------------------------------------------
|
||||
|
||||
#if ENABLE_NONCUSTOM_DATA_VIEW_RENDERING
|
||||
PrusaBitmapTextRenderer::PrusaBitmapTextRenderer(wxDataViewCellMode mode /*= wxDATAVIEW_CELL_EDITABLE*/,
|
||||
int align /*= wxDVR_DEFAULT_ALIGNMENT*/):
|
||||
wxDataViewRenderer(wxT("PrusaDataViewBitmapText"), mode, align)
|
||||
{
|
||||
SetMode(mode);
|
||||
SetAlignment(align);
|
||||
}
|
||||
#endif // ENABLE_NONCUSTOM_DATA_VIEW_RENDERING
|
||||
|
||||
bool PrusaBitmapTextRenderer::SetValue(const wxVariant &value)
|
||||
{
|
||||
m_value << value;
|
||||
|
@ -1259,12 +1261,12 @@ bool PrusaBitmapTextRenderer::GetValue(wxVariant& WXUNUSED(value)) const
|
|||
return false;
|
||||
}
|
||||
|
||||
#if wxUSE_ACCESSIBILITY
|
||||
#if ENABLE_NONCUSTOM_DATA_VIEW_RENDERING && wxUSE_ACCESSIBILITY
|
||||
wxString PrusaBitmapTextRenderer::GetAccessibleDescription() const
|
||||
{
|
||||
return m_value.GetText();
|
||||
}
|
||||
#endif // wxUSE_ACCESSIBILITY
|
||||
#endif // wxUSE_ACCESSIBILITY && ENABLE_NONCUSTOM_DATA_VIEW_RENDERING
|
||||
|
||||
bool PrusaBitmapTextRenderer::Render(wxRect rect, wxDC *dc, int state)
|
||||
{
|
||||
|
|
|
@ -518,19 +518,26 @@ public:
|
|||
// ----------------------------------------------------------------------------
|
||||
// PrusaBitmapTextRenderer
|
||||
// ----------------------------------------------------------------------------
|
||||
|
||||
class PrusaBitmapTextRenderer : public wxDataViewRenderer//CustomRenderer
|
||||
#if ENABLE_NONCUSTOM_DATA_VIEW_RENDERING
|
||||
class PrusaBitmapTextRenderer : public wxDataViewRenderer
|
||||
#else
|
||||
class PrusaBitmapTextRenderer : public wxDataViewCustomRenderer
|
||||
#endif //ENABLE_NONCUSTOM_DATA_VIEW_RENDERING
|
||||
{
|
||||
public:
|
||||
PrusaBitmapTextRenderer(wxDataViewCellMode mode = wxDATAVIEW_CELL_EDITABLE,
|
||||
int align = wxDVR_DEFAULT_ALIGNMENT);//:
|
||||
// wxDataViewRenderer/*CustomRenderer*/(wxT("PrusaDataViewBitmapText"), mode, align) {}
|
||||
int align = wxDVR_DEFAULT_ALIGNMENT
|
||||
#if ENABLE_NONCUSTOM_DATA_VIEW_RENDERING
|
||||
);
|
||||
#else
|
||||
) : wxDataViewCustomRenderer(wxT("PrusaDataViewBitmapText"), mode, align) {}
|
||||
#endif //ENABLE_NONCUSTOM_DATA_VIEW_RENDERING
|
||||
|
||||
bool SetValue(const wxVariant &value);
|
||||
bool GetValue(wxVariant &value) const;
|
||||
#if wxUSE_ACCESSIBILITY
|
||||
#if ENABLE_NONCUSTOM_DATA_VIEW_RENDERING && wxUSE_ACCESSIBILITY
|
||||
virtual wxString GetAccessibleDescription() const override;
|
||||
#endif // wxUSE_ACCESSIBILITY
|
||||
#endif // wxUSE_ACCESSIBILITY && ENABLE_NONCUSTOM_DATA_VIEW_RENDERING
|
||||
|
||||
virtual bool Render(wxRect cell, wxDC *dc, int state);
|
||||
virtual wxSize GetSize() const;
|
||||
|
|
Loading…
Reference in a new issue