Overrided on_dpi_changed() for some Dialogs:

BedShapeDialog, KBShortcutsDialog, ConfigWizard, Preferences
This commit is contained in:
YuSanka 2019-04-18 02:03:40 +02:00
parent 077321b228
commit e97e8c6af6
13 changed files with 178 additions and 45 deletions

View file

@ -5,24 +5,39 @@
#include <map>
#include <vector>
#include "GUI_Utils.hpp"
#include "wxExtensions.hpp"
namespace Slic3r {
namespace GUI {
class KBShortcutsDialog : public wxDialog
class KBShortcutsDialog : public DPIDialog/*wxDialog*/
{
enum PLACED_SIZER_ID
{
szLeft = 0,
szRight
};
typedef std::pair<std::string, std::string> Shortcut;
typedef std::vector< Shortcut > Shortcuts;
typedef std::vector< std::pair<wxString, std::pair<Shortcuts, int>> > ShortcutsVec;
typedef std::vector< std::pair<wxString, std::pair<Shortcuts, PLACED_SIZER_ID>> > ShortcutsVec;
wxString text_info {wxEmptyString};
ShortcutsVec m_full_shortcuts;
ShortcutsVec m_full_shortcuts;
wxSizer* main_sizer;
PrusaBitmap m_logo_bmp;
std::vector<wxStaticBitmap*> m_head_bitmaps;
public:
KBShortcutsDialog();
void fill_shortcuts();
protected:
void on_dpi_changed(const wxRect &suggested_rect) override;
private:
void onCloseDialog(wxEvent &);
};