mirror of
https://github.com/FULU-Foundation/OrcaSlicer-bambulab.git
synced 2026-05-18 15:39:04 -07:00
UnsavedChangesDialog improvements:
* support markup text and colored icons for cells + Extended BitmapTextRenderer for using of markup text
This commit is contained in:
@@ -2,9 +2,10 @@
|
||||
#define slic3r_GUI_ObjectDataViewModel_hpp_
|
||||
|
||||
#include <wx/dataview.h>
|
||||
|
||||
#include <vector>
|
||||
|
||||
#include "GUI_App.hpp"
|
||||
|
||||
namespace Slic3r {
|
||||
|
||||
enum class ModelVolumeType : int;
|
||||
@@ -83,9 +84,19 @@ public:
|
||||
) :
|
||||
wxDataViewCustomRenderer(wxT("DataViewBitmapText"), mode, align),
|
||||
m_parent(parent)
|
||||
{}
|
||||
{
|
||||
#ifdef SUPPORTS_MARKUP
|
||||
m_markupText = nullptr;
|
||||
#endif // SUPPORTS_MARKUP
|
||||
}
|
||||
#endif //ENABLE_NONCUSTOM_DATA_VIEW_RENDERING
|
||||
|
||||
~BitmapTextRenderer();
|
||||
|
||||
#ifdef SUPPORTS_MARKUP
|
||||
void EnableMarkup(bool enable = true);
|
||||
#endif // SUPPORTS_MARKUP
|
||||
|
||||
bool SetValue(const wxVariant& value);
|
||||
bool GetValue(wxVariant& value) const;
|
||||
#if ENABLE_NONCUSTOM_DATA_VIEW_RENDERING && wxUSE_ACCESSIBILITY
|
||||
@@ -114,6 +125,10 @@ private:
|
||||
DataViewBitmapText m_value;
|
||||
bool m_was_unusable_symbol{ false };
|
||||
wxWindow* m_parent{ nullptr };
|
||||
|
||||
#ifdef SUPPORTS_MARKUP
|
||||
class wxItemMarkupText* m_markupText;
|
||||
#endif // SUPPORTS_MARKUP
|
||||
};
|
||||
|
||||
|
||||
|
||||
Reference in New Issue
Block a user