Fix T87170 Multi-Input socket activation zone error with lots of inputs

Calculation of bounding rect for multi-input socket was wrong.

Reviewer: Hans Goudey (HooglyBoogly)

Differential Revision: https://developer.blender.org/D11077
This commit is contained in:
Fabian Schempp 2021-04-26 00:55:55 +02:00
parent f1cf706758
commit db3b610040
Notes: blender-bot 2023-02-13 23:16:02 +01:00
Referenced by issue #87170, Multi-Input socket activation zone error with lots of inputs
1 changed files with 2 additions and 2 deletions

View File

@ -1136,8 +1136,8 @@ static bool cursor_isect_multi_input_socket(const float cursor[2], const bNodeSo
* But keep it smaller because for multi-input socket you
* sometimes want to drag the link to the other side, if you may
* accidentally pick the wrong link otherwise. */
.ymin = socket->locy - node_socket_height * 0.5 - NODE_SOCKSIZE,
.ymax = socket->locy + node_socket_height * 0.5 + NODE_SOCKSIZE,
.ymin = socket->locy - node_socket_height,
.ymax = socket->locy + node_socket_height,
};
if (BLI_rctf_isect_pt(&multi_socket_rect, cursor[0], cursor[1])) {
return true;