mirror of
https://github.com/SoftFever/OrcaSlicer.git
synced 2025-07-11 16:57:53 -06:00
Search: 1. The position of the search window is in the middle of the scene.
2. When "Search in English" is checked, then search in English names too. 3. Added score value at the end of option name -> [score_value] 4. Set focus to the Plater, when switch from some tab with focused field to the Plater and search window is shown. 5. For the mode, when settings are in non-modal dialog, neither dialog nor tabpanel doesn't receive wxEVT_KEY_UP event, when some field is selected. So, like a workaround we check wxEVT_KEY_UP event for the Filed and switch between tabs if Ctrl+(1-4) was pressed + PreferencesDialog: fixed a control of the difference in layout modes
This commit is contained in:
parent
3a6bc2e31a
commit
559f9279d9
7 changed files with 58 additions and 9 deletions
|
@ -4391,7 +4391,7 @@ bool GLCanvas3D::_render_search_list(float pos_x) const
|
|||
bool action_taken = false;
|
||||
ImGuiWrapper* imgui = wxGetApp().imgui();
|
||||
|
||||
const float x = pos_x * (float)wxGetApp().plater()->get_camera().get_zoom() + 0.5f * (float)get_canvas_size().get_width();
|
||||
const float x = /*pos_x * (float)wxGetApp().plater()->get_camera().get_zoom() + */0.5f * (float)get_canvas_size().get_width();
|
||||
imgui->set_next_window_pos(x, m_main_toolbar.get_height(), ImGuiCond_Always, 0.5f, 0.0f);
|
||||
std::string title = L("Search");
|
||||
imgui->begin(_(title), ImGuiWindowFlags_NoMove | ImGuiWindowFlags_NoResize | ImGuiWindowFlags_NoCollapse);
|
||||
|
@ -7143,9 +7143,14 @@ bool GLCanvas3D::_deactivate_undo_redo_toolbar_items()
|
|||
return false;
|
||||
}
|
||||
|
||||
bool GLCanvas3D::is_search_pressed() const
|
||||
{
|
||||
return m_main_toolbar.is_item_pressed("search");
|
||||
}
|
||||
|
||||
bool GLCanvas3D::_deactivate_search_toolbar_item()
|
||||
{
|
||||
if (m_main_toolbar.is_item_pressed("search"))
|
||||
if (is_search_pressed())
|
||||
{
|
||||
m_main_toolbar.force_left_action(m_main_toolbar.get_item_id("search"), *this);
|
||||
return true;
|
||||
|
|
Loading…
Add table
Add a link
Reference in a new issue