#include </home/runner/work/OrcaSlicer/OrcaSlicer/src/slic3r/GUI/wxExtensions.hpp>
◆ OnCheckListBoxFunction
| Enumerator |
|---|
| FreeToProceed | |
| RefuseToProceed | |
| WasRefusedLastTime | |
118 {
119 FreeToProceed,
120 RefuseToProceed,
121 WasRefusedLastTime
122 } m_check_box_events_status = OnCheckListBoxFunction::FreeToProceed;
◆ Create()
| bool wxCheckListBoxComboPopup::Create |
( |
wxWindow * | parent | ) |
|
|
virtual |
213{
214 return wxCheckListBox::Create(parent, wxID_HIGHEST + 1, wxPoint(0, 0));
215}
◆ GetAdjustedSize()
| wxSize wxCheckListBoxComboPopup::GetAdjustedSize |
( |
int | minWidth, |
|
|
int | prefHeight, |
|
|
int | maxHeight ) |
|
virtual |
233{
234
235
236
237 wxComboCtrl* cmb = GetComboCtrl();
238 if (cmb != nullptr) {
239 wxSize size = GetComboCtrl()->GetSize();
240
241 unsigned int count = GetCount();
243 int max_width = size.x;
244 for (
unsigned int i = 0; i <
count; ++i) {
245 max_width = std::max(max_width, 60 + GetTextExtent(GetString(i)).x);
246 }
247 size.SetWidth(max_width);
248 size.SetHeight(
count * cmb->GetCharHeight());
249 }
250 else
252
253 return size;
254 }
255 else
257}
static unsigned int count
Definition AuxiliaryDataViewModel.cpp:246
References count, DefaultHeight, and DefaultWidth.
◆ GetControl()
| wxWindow * wxCheckListBoxComboPopup::GetControl |
( |
| ) |
|
|
virtual |
218{
219 return this;
220}
◆ GetStringValue()
| wxString wxCheckListBoxComboPopup::GetStringValue |
( |
| ) |
const |
|
virtual |
◆ OnCheckListBox()
| void wxCheckListBoxComboPopup::OnCheckListBox |
( |
wxCommandEvent & | evt | ) |
|
◆ OnKeyEvent()
| void wxCheckListBoxComboPopup::OnKeyEvent |
( |
wxKeyEvent & | evt | ) |
|
|
virtual |
260{
261
262 switch (evt.GetKeyCode())
263 {
264 case WXK_LEFT:
265 case WXK_UP:
266 case WXK_RIGHT:
267 case WXK_DOWN:
268 case WXK_PAGEUP:
269 case WXK_PAGEDOWN:
270 case WXK_END:
271 case WXK_HOME:
272 case WXK_NUMPAD_LEFT:
273 case WXK_NUMPAD_UP:
274 case WXK_NUMPAD_RIGHT:
275 case WXK_NUMPAD_DOWN:
276 case WXK_NUMPAD_PAGEUP:
277 case WXK_NUMPAD_PAGEDOWN:
278 case WXK_NUMPAD_END:
279 case WXK_NUMPAD_HOME:
280 {
281 break;
282 }
283 default:
284 {
285 evt.Skip();
286 break;
287 }
288 }
289}
Referenced by Slic3r::GUI::create_combochecklist().
◆ OnListBoxSelection()
| void wxCheckListBoxComboPopup::OnListBoxSelection |
( |
wxCommandEvent & | evt | ) |
|
319{
320
321
322 int selId = GetSelection();
323 if (selId != wxNOT_FOUND)
324 {
325 #ifndef _WIN32
327 #endif
328 Check((unsigned int)selId, !IsChecked((unsigned int)selId));
329
331
332 SetSelection(wxNOT_FOUND);
333 wxCommandEvent event(wxEVT_CHECKLISTBOX, GetId());
334 event.SetInt(selId);
335 event.SetEventObject(this);
336 ProcessEvent(event);
337 }
338}
References FreeToProceed, m_check_box_events_status, and RefuseToProceed.
Referenced by Slic3r::GUI::create_combochecklist().
◆ SetStringValue()
| void wxCheckListBoxComboPopup::SetStringValue |
( |
const wxString & | value | ) |
|
|
virtual |
◆ DefaultHeight
| const unsigned int wxCheckListBoxComboPopup::DefaultHeight = 200 |
|
staticprivate |
◆ DefaultWidth
| const unsigned int wxCheckListBoxComboPopup::DefaultWidth = 200 |
|
staticprivate |
◆ m_check_box_events_status
◆ m_text
| wxString wxCheckListBoxComboPopup::m_text |
|
private |
The documentation for this class was generated from the following files: