mirror of
				https://github.com/SoftFever/OrcaSlicer.git
				synced 2025-10-30 12:11:15 -06:00 
			
		
		
		
	Merge branch 'master' of https://github.com/prusa3d/PrusaSlicer into et_gcode_viewer
This commit is contained in:
		
						commit
						603f128568
					
				
					 1 changed files with 9 additions and 5 deletions
				
			
		|  | @ -1209,6 +1209,13 @@ static bool improper_category(const std::string& category, const int extruders_c | |||
|             (!is_object_settings && category == "Support material"); | ||||
| } | ||||
| 
 | ||||
| static bool is_object_item(ItemType item_type) | ||||
| { | ||||
|     return item_type & itObject || item_type & itInstance || | ||||
|             // multi-selection in ObjectList, but full_object in Selection
 | ||||
|             (item_type == itUndef && scene_selection().is_single_full_object()); | ||||
| } | ||||
| 
 | ||||
| void ObjectList::get_options_menu(settings_menu_hierarchy& settings_menu, const bool is_part) | ||||
| { | ||||
|     auto options = get_options(is_part); | ||||
|  | @ -1579,9 +1586,7 @@ wxMenuItem* ObjectList::append_menu_item_settings(wxMenu* menu_) | |||
|     const ItemType item_type = m_objects_model->GetItemType(GetSelection()); | ||||
|     if (item_type == itUndef && !selection.is_single_full_object()) | ||||
|         return nullptr; | ||||
|     const bool is_object_settings = item_type & itObject || item_type & itInstance || | ||||
|                                     // multi-selection in ObjectList, but full_object in Selection
 | ||||
|                                     (item_type == itUndef && selection.is_single_full_object());  | ||||
|     const bool is_object_settings = is_object_item(item_type); | ||||
|     create_freq_settings_popupmenu(menu, is_object_settings); | ||||
| 
 | ||||
|     if (mode == comAdvanced) | ||||
|  | @ -1821,8 +1826,7 @@ wxMenu* ObjectList::create_settings_popupmenu(wxMenu *parent_menu) | |||
|     const wxDataViewItem selected_item = GetSelection(); | ||||
|     wxDataViewItem item = m_objects_model->GetItemType(selected_item) & itSettings ? m_objects_model->GetParent(selected_item) : selected_item; | ||||
| 
 | ||||
|     const bool is_part = !(m_objects_model->GetItemType(item) == itObject || scene_selection().is_single_full_object()); | ||||
|     get_options_menu(settings_menu, is_part); | ||||
|     get_options_menu(settings_menu, !is_object_item(m_objects_model->GetItemType(item))); | ||||
| 
 | ||||
|     for (auto cat : settings_menu) { | ||||
|         append_menu_item(menu, wxID_ANY, _(cat.first), "", | ||||
|  |  | |||
		Loading…
	
	Add table
		Add a link
		
	
		Reference in a new issue
	
	 enricoturri1966
						enricoturri1966