MCPcopy Create free account
hub / github.com/CloudCompare/CloudCompare / select

Method select

libs/CCPluginAPI/src/ccColorScaleEditorWidget.cpp:276–296  ·  view source on GitHub ↗

Source from the content-addressed store, hash-verified

274}
275
276void SlidersWidget::select(int index, bool silent/*=false*/)
277{
278 assert(m_sliders);
279
280 //look for previously selected slider
281 int activeSliderIndex = m_sliders->selected();
282
283 if (index == activeSliderIndex) //nothing to do
284 return;
285
286 //deselect old one (if any)
287 if (activeSliderIndex >= 0)
288 m_sliders->element(activeSliderIndex)->setSelected(false);
289
290 //select new one (if any)
291 if (index >= 0)
292 m_sliders->element(index)->setSelected(true);
293
294 if (!silent)
295 Q_EMIT sliderSelected(index);
296}
297
298ColorScaleElementSlider* SlidersWidget::addNewSlider(double relativePos, QColor color)
299{

Callers 6

unselectEntityMethod · 0.80
selectEntityMethod · 0.80
selectEntitiesMethod · 0.80
onPointClickedMethod · 0.80
setSelectedStepIndexMethod · 0.80
loadFileMethod · 0.80

Calls 3

selectedMethod · 0.80
setSelectedMethod · 0.80
elementMethod · 0.80

Tested by

no test coverage detected