remove compiler warnings
This commit is contained in:
parent
b3c3157354
commit
4abbbd9f84
1 changed files with 24 additions and 22 deletions
|
@ -3113,6 +3113,7 @@ void BlackboxWindow::beginResize(int x_root, int y_root, Corner dir) {
|
||||||
|
|
||||||
default:
|
default:
|
||||||
assert(false); // unhandled Corner
|
assert(false); // unhandled Corner
|
||||||
|
return; // unreachable, for the compiler
|
||||||
}
|
}
|
||||||
|
|
||||||
XGrabServer(blackbox->getXDisplay());
|
XGrabServer(blackbox->getXDisplay());
|
||||||
|
@ -3151,29 +3152,30 @@ void BlackboxWindow::doResize(int x_root, int y_root) {
|
||||||
Corner anchor;
|
Corner anchor;
|
||||||
|
|
||||||
switch (resize_dir) {
|
switch (resize_dir) {
|
||||||
case BottomLeft:
|
case BottomLeft:
|
||||||
anchor = TopRight;
|
anchor = TopRight;
|
||||||
frame.changing.setSize(frame.rect.width() - (x_root - frame.grab_x),
|
frame.changing.setSize(frame.rect.width() - (x_root - frame.grab_x),
|
||||||
frame.rect.height() + (y_root - frame.grab_y));
|
frame.rect.height() + (y_root - frame.grab_y));
|
||||||
break;
|
break;
|
||||||
case BottomRight:
|
case BottomRight:
|
||||||
anchor = TopLeft;
|
anchor = TopLeft;
|
||||||
frame.changing.setSize(frame.rect.width() + (x_root - frame.grab_x),
|
frame.changing.setSize(frame.rect.width() + (x_root - frame.grab_x),
|
||||||
frame.rect.height() + (y_root - frame.grab_y));
|
frame.rect.height() + (y_root - frame.grab_y));
|
||||||
break;
|
break;
|
||||||
case TopLeft:
|
case TopLeft:
|
||||||
anchor = BottomRight;
|
anchor = BottomRight;
|
||||||
frame.changing.setSize(frame.rect.width() - (x_root - frame.grab_x),
|
frame.changing.setSize(frame.rect.width() - (x_root - frame.grab_x),
|
||||||
frame.rect.height() - (y_root - frame.grab_y));
|
frame.rect.height() - (y_root - frame.grab_y));
|
||||||
break;
|
break;
|
||||||
case TopRight:
|
case TopRight:
|
||||||
anchor = BottomLeft;
|
anchor = BottomLeft;
|
||||||
frame.changing.setSize(frame.rect.width() + (x_root - frame.grab_x),
|
frame.changing.setSize(frame.rect.width() + (x_root - frame.grab_x),
|
||||||
frame.rect.height() - (y_root - frame.grab_y));
|
frame.rect.height() - (y_root - frame.grab_y));
|
||||||
break;
|
break;
|
||||||
|
|
||||||
default:
|
default:
|
||||||
assert(false); // unhandled Corner
|
assert(false); // unhandled Corner
|
||||||
|
return; // unreachable, for the compiler
|
||||||
}
|
}
|
||||||
|
|
||||||
constrain(anchor, &gw, &gh);
|
constrain(anchor, &gw, &gh);
|
||||||
|
|
Loading…
Reference in a new issue