Commit 91fb7099 authored by Kurt Hindenburg's avatar Kurt Hindenburg
Browse files

Remove commented code and dead-code that was used in commented code

(cherry picked from commit ffd9e56c)
parent d02b0c0b
......@@ -1342,22 +1342,17 @@ void ColorSchemeViewDelegate::paint(QPainter* painter, const QStyleOptionViewIte
painter->setBrush(gradient);
painter->drawRoundRect(backgroundRect , 4 , 30);
//const bool isChecked = index.data(Qt::CheckStateRole) == Qt::Checked;
const bool isSelected = option.state & QStyle::State_Selected;
// draw border on selected items
if (isSelected) { //|| isChecked )
if (isSelected) {
static const int selectedBorderWidth = 6;
painter->setBrush(QBrush(Qt::NoBrush));
QPen pen;
QColor highlightColor = option.palette.highlight().color();
if (isSelected)
highlightColor.setAlphaF(1.0);
else
highlightColor.setAlphaF(0.7);
highlightColor.setAlphaF(1.0);
pen.setBrush(highlightColor);
pen.setWidth(selectedBorderWidth);
......
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