Fix Filter Input in RTL Locales

This commit is contained in:
safaalfulaij
2016-07-29 17:48:32 +03:00
parent 6af5bd98f1
commit 94e2caea73

View File

@@ -76,7 +76,10 @@ void FilterTableHeader::adjustPositions()
{
// Get the current widget, move it and resize it
QWidget* w = filterWidgets.at(i);
w->move(sectionPosition(i) - offset(), w->sizeHint().height() + 2); // The two adds some extra space between the header label and the input widget
if (layoutDirection() == Qt::RightToLeft)
w->move(width() - (sectionPosition(i) + sectionSize(i) - offset()), w->sizeHint().height() + 2); // The two adds some extra space between the header label and the input widget
else
w->move(sectionPosition(i) - offset(), w->sizeHint().height() + 2); // The two adds some extra space between the header label and the input widget
w->resize(sectionSize(i), w->sizeHint().height());
}
}