| 2935 | } |
| 2936 | |
| 2937 | bool ImGuiMenu::make_visualize_checkbox( std::vector<std::shared_ptr<VisualObject>> selectedVisualObjs, const char* label, AnyVisualizeMaskEnum type, MR::ViewportMask viewportid, bool invert /*= false*/ ) |
| 2938 | { |
| 2939 | auto realRes = getRealValue( selectedVisualObjs, type, viewportid, invert ); |
| 2940 | bool checked = realRes.first; |
| 2941 | const bool res = UI::checkboxMixed( label, &checked, !realRes.second && realRes.first ); |
| 2942 | if ( checked != realRes.first ) |
| 2943 | { |
| 2944 | if ( invert ) |
| 2945 | checked = !checked; |
| 2946 | for ( const auto& data : selectedVisualObjs ) |
| 2947 | if ( data ) |
| 2948 | data->setVisualizeProperty( checked, type, viewportid ); |
| 2949 | } |
| 2950 | |
| 2951 | return res; |
| 2952 | } |
| 2953 | |
| 2954 | template<typename ObjectT> |
| 2955 | void ImGuiMenu::make_color_selector( std::vector<std::shared_ptr<ObjectT>> selectedVisualObjs, const char* label, |
nothing calls this directly
no test coverage detected