mirror of
https://github.com/SoftFever/OrcaSlicer.git
synced 2025-07-11 16:57:53 -06:00
Experiment on OSX to understand events order
This commit is contained in:
parent
f7c0303acf
commit
1148c8c018
1 changed files with 9 additions and 5 deletions
|
@ -188,6 +188,9 @@ wxBoxSizer* content_objects_list(wxWindow *win)
|
||||||
|
|
||||||
m_objects_ctrl->Bind(wxEVT_DATAVIEW_SELECTION_CHANGED, [](wxEvent& event)
|
m_objects_ctrl->Bind(wxEVT_DATAVIEW_SELECTION_CHANGED, [](wxEvent& event)
|
||||||
{
|
{
|
||||||
|
#ifdef __WXOSX__
|
||||||
|
wxMessageBox("DATAVIEW_SELECTION_CHANGED");
|
||||||
|
#endif //__WXOSX__
|
||||||
object_ctrl_selection_changed();
|
object_ctrl_selection_changed();
|
||||||
});
|
});
|
||||||
|
|
||||||
|
@ -212,12 +215,11 @@ wxBoxSizer* content_objects_list(wxWindow *win)
|
||||||
event.Skip();
|
event.Skip();
|
||||||
});
|
});
|
||||||
|
|
||||||
|
#ifdef __WXMSW__
|
||||||
m_objects_ctrl->Bind(wxEVT_CHOICE, [](wxCommandEvent& event)
|
m_objects_ctrl->Bind(wxEVT_CHOICE, [](wxCommandEvent& event)
|
||||||
{
|
{
|
||||||
wxMessageBox("Ku-ku");
|
if (!*m_config)
|
||||||
if (!*m_config)
|
|
||||||
return;
|
return;
|
||||||
auto config = m_config;
|
|
||||||
|
|
||||||
wxString str = event.GetString();
|
wxString str = event.GetString();
|
||||||
int extruder = str.size() > 1 ? 0 : atoi(str.c_str());
|
int extruder = str.size() > 1 ? 0 : atoi(str.c_str());
|
||||||
|
@ -228,10 +230,12 @@ wxBoxSizer* content_objects_list(wxWindow *win)
|
||||||
get_main_frame()->ProcessWindowEvent(e);
|
get_main_frame()->ProcessWindowEvent(e);
|
||||||
}
|
}
|
||||||
});
|
});
|
||||||
|
#else
|
||||||
#ifndef __WXMSW__
|
|
||||||
m_objects_ctrl->Bind(wxEVT_DATAVIEW_ITEM_VALUE_CHANGED, [](wxDataViewEvent& event)
|
m_objects_ctrl->Bind(wxEVT_DATAVIEW_ITEM_VALUE_CHANGED, [](wxDataViewEvent& event)
|
||||||
{
|
{
|
||||||
|
#ifdef __WXOSX__
|
||||||
|
wxMessageBox("DATAVIEW_ITEM_VALUE_CHANGED");
|
||||||
|
#endif //__WXOSX__
|
||||||
if (!*m_config)
|
if (!*m_config)
|
||||||
return;
|
return;
|
||||||
if (event.GetColumn() == 3)
|
if (event.GetColumn() == 3)
|
||||||
|
|
Loading…
Add table
Add a link
Reference in a new issue