PVS V547: always false comparisons

Change-Id: I1c7790ff0aa537b974bdc0fd65d76f277ea5f8cf
Reviewed-on: https://review.haiku-os.org/c/1647
Reviewed-by: waddlesplash <[email protected]>
This commit is contained in:
Adrien Destugues
2019-07-27 15:16:31 +00:00
committed by waddlesplash
parent 84a5d9f625
commit 6967695c4e
7 changed files with 58 additions and 69 deletions
+7 -6
View File
@@ -277,15 +277,16 @@ BScrollBar::BScrollBar(BMessage* data)
int32 orientation;
if (data->FindInt32("_orient", &orientation) < B_OK) {
fOrientation = B_VERTICAL;
if ((Flags() & B_SUPPORTS_LAYOUT) == 0) {
// just to make sure
SetResizingMode(fOrientation == B_VERTICAL
? B_FOLLOW_TOP_BOTTOM | B_FOLLOW_RIGHT
: B_FOLLOW_LEFT_RIGHT | B_FOLLOW_BOTTOM);
}
} else
fOrientation = (enum orientation)orientation;
if ((Flags() & B_SUPPORTS_LAYOUT) == 0) {
// just to make sure
SetResizingMode(fOrientation == B_VERTICAL
? B_FOLLOW_TOP_BOTTOM | B_FOLLOW_RIGHT
: B_FOLLOW_LEFT_RIGHT | B_FOLLOW_BOTTOM);
}
if (data->FindFloat("_prop", &fProportion) < B_OK)
fProportion = 0.0;