FIX: unable to select filament map mode in macos

1. add wxPU_CONTAINS_CONTROLS when construct
2. fix some ui bugs

jira:NONE

Signed-off-by: xun.zhang <xun.zhang@bambulab.com>
Change-Id: I413dbaa35f3f79c97e2db3f8b2cdb5ab55739484
(cherry picked from commit cd23329267a1d2c9d28098d73bc007ce4fd58eb2)
This commit is contained in:
xun.zhang
2024-12-23 16:30:30 +08:00
committed by Noisyfox
parent f9869d4b5b
commit a378afde0b
3 changed files with 78 additions and 58 deletions

View File

@@ -5,6 +5,8 @@
#include <wx/hyperlink.h>
#include "wxExtensions.hpp"
#include "Widgets/PopupWindow.hpp"
#include "Widgets/CheckBox.hpp"
#include "Widgets/Label.hpp"
namespace Slic3r { namespace GUI {
@@ -24,13 +26,13 @@ private:
void StartTimer();
void ResetTimer();
void OnRadioBtn(wxCommandEvent &event);
void OnRadioBtn(int idx);
void OnLeaveWindow(wxMouseEvent &);
void OnEnterWindow(wxMouseEvent &);
void OnTimer(wxTimerEvent &event);
void OnRemindBtn(wxCommandEvent &event);
void Init(bool connect_status);
void Init();
void UpdateButtonStatus(int hover_idx = -1);
void DrawRoundedCorner(int radius);
@@ -40,15 +42,16 @@ private:
const std::vector<FilamentMapMode> mode_list = {fmmAutoForFlush, fmmAutoForMatch, fmmManual};
FilamentMapMode m_mode;
bool m_connected{ false };
wxTimer *m_timer;
std::vector<wxBitmapButton *> radio_btns;
std::vector<wxStaticText *> button_labels;
std::vector<wxStaticText *> button_desps;
std::vector<wxStaticText *> detail_infos;
std::vector<Label *> button_labels;
std::vector<Label *> button_desps;
std::vector<Label *> detail_infos;
wxStaticText *wiki_link;
wxCheckBox *remind_checkbox;
CheckBox* remind_checkbox;
};
}} // namespace Slic3r::GUI
#endif