Commit f705d533 authored by Sebastian Eichelbaum's avatar Sebastian Eichelbaum
Browse files

[ADD] - WPropColor widget now supports alpha values on machines with Qt version >= 4.5

parent b9b40d3f
......@@ -103,8 +103,12 @@ WColor WPropertyColorWidget::toWColor( QColor color )
void WPropertyColorWidget::buttonReleased()
{
QColor current = toQColor( m_colorProperty->get() );
current = QColorDialog::getColor( current, this );
#if QT_VERSION >= 0x040500
current = QColorDialog::getColor( current, this, QString( "Select Color" ), QColorDialog::ShowAlphaChannel );
#else
current = QColorDialog::getColor( current, this );
#endif
// convert it back to a WColor
invalidate( !m_colorProperty->set( toWColor( current ) ) ); // NOTE: set automatically checks the validity of the value
......
Markdown is supported
0% or .
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment