Remove unneeded check
it was already being done in setAlignment anyway
This commit is contained in:
parent
b8e34cffe2
commit
6d8d2fbde8
|
@ -149,20 +149,14 @@ void Panel::setAlignment(const QString &alignment)
|
|||
bool success = false;
|
||||
|
||||
if (alignment.compare("left", Qt::CaseInsensitive) == 0) {
|
||||
if (v->alignment() != Qt::AlignLeft) {
|
||||
success = true;
|
||||
v->setAlignment(Qt::AlignLeft);
|
||||
}
|
||||
success = true;
|
||||
v->setAlignment(Qt::AlignLeft);
|
||||
} else if (alignment.compare("right", Qt::CaseInsensitive) == 0) {
|
||||
if (v->alignment() != Qt::AlignRight) {
|
||||
success = true;
|
||||
v->setAlignment(Qt::AlignRight);
|
||||
}
|
||||
success = true;
|
||||
v->setAlignment(Qt::AlignRight);
|
||||
} else if (alignment.compare("center", Qt::CaseInsensitive) == 0) {
|
||||
if (v->alignment() != Qt::AlignCenter) {
|
||||
success = true;
|
||||
v->setAlignment(Qt::AlignCenter);
|
||||
}
|
||||
success = true;
|
||||
v->setAlignment(Qt::AlignCenter);
|
||||
}
|
||||
|
||||
if (success) {
|
||||
|
|
Loading…
Reference in New Issue
Block a user