Commit 254d82a2 authored by Kai Uwe Broulik's avatar Kai Uwe Broulik 🍇

[Folder View] Don't let rubber band get null size

This would cause the rubberband to become invisible and not match any items.

Differential Revision: https://phabricator.kde.org/D9226
parent bdeace1a
......@@ -423,6 +423,11 @@ Item {
rB.height = Math.min(ceil - rB.y, Math.abs(rB.y - cPos.y));
}
// Ensure rubberband is at least 1px in size or else it will become
// invisible and not match any items.
rB.width = Math.max(1, rB.width);
rB.height = Math.max(1, rB.height);
gridView.rectangleSelect(rB.x, rB.y, rB.width, rB.height);
return;
......
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