mirror of
https://git.salome-platform.org/gitpub/modules/geom.git
synced 2024-11-15 10:08:35 +05:00
CCAR: In transparency dialog set tracking to false to avoid setting transparency
for each move of the cursor. The transparency is only set when cursor is up.
This commit is contained in:
parent
03f77667e6
commit
2afbe2f2dc
@ -120,6 +120,7 @@ GEOMToolsGUI_TransparencyDlg::GEOMToolsGUI_TransparencyDlg( QWidget* parent )
|
||||
mySlider->setSingleStep( 1 );
|
||||
mySlider->setPageStep( 10 );
|
||||
//mySlider->setValue( 5 );
|
||||
mySlider->setTracking(false);
|
||||
|
||||
mySlider->setTickPosition( QSlider::TicksLeft );
|
||||
GroupC1Layout->addWidget( mySlider, 1, 0, 1, 3 );
|
||||
@ -155,7 +156,7 @@ GEOMToolsGUI_TransparencyDlg::GEOMToolsGUI_TransparencyDlg( QWidget* parent )
|
||||
connect(buttonOk, SIGNAL(clicked()), this, SLOT(ClickOnOk()));
|
||||
connect(buttonHelp, SIGNAL(clicked()), this, SLOT(ClickOnHelp()));
|
||||
connect(mySlider, SIGNAL(valueChanged(int)), this, SLOT(SetTransparency()));
|
||||
connect(mySlider, SIGNAL(sliderMoved(int)), this, SLOT(ValueHasChanged()));
|
||||
connect(mySlider, SIGNAL(sliderMoved(int)), this, SLOT(SliderHasMoved(int)));
|
||||
}
|
||||
|
||||
|
||||
@ -224,6 +225,15 @@ void GEOMToolsGUI_TransparencyDlg::ValueHasChanged()
|
||||
myValueLab->setText( QString("%1%").arg( mySlider->value() ) );
|
||||
}
|
||||
|
||||
//=================================================================================
|
||||
// function : SliderHasMoved()
|
||||
// purpose : Called when value of slider change
|
||||
//=================================================================================
|
||||
void GEOMToolsGUI_TransparencyDlg::SliderHasMoved(int value)
|
||||
{
|
||||
myValueLab->setText( QString("%1%").arg( value ) );
|
||||
}
|
||||
|
||||
//=================================================================================
|
||||
// function : SetTransparency()
|
||||
// purpose : Called when value of slider change
|
||||
|
@ -61,6 +61,7 @@ private slots:
|
||||
void ClickOnClose();
|
||||
void ClickOnHelp();
|
||||
void ValueHasChanged();
|
||||
void SliderHasMoved(int);
|
||||
void SetTransparency();
|
||||
};
|
||||
|
||||
|
Loading…
Reference in New Issue
Block a user