diff options
author | Konrad Puklicki <puklicki> | 2020-05-27 13:04:14 +0300 |
---|---|---|
committer | Julian Eisel <julian@blender.org> | 2020-05-27 13:06:35 +0300 |
commit | e490dc4346dba5f29dada59ef421dfff499d65a9 (patch) | |
tree | 230efe66695ea208e66422a21c494b1cd52e251e /intern/opensubdiv/internal | |
parent | bab5fbb66c03145705b32453ca781bd68bdb4134 (diff) |
UI: Skip unnecessary cursor setting
Currently, in sculpting, weight paint and vertex paint modes every cursor
movement triggers redraw of a brush. During that redraw, native cursor is set.
Under the hood, setting the cursor causes freeing of previous cursor and
allocating a new one. In most cases, in previously mentioned modes, recreating
cursor is unnecessary since cursor stays the same.
This patch adds a check which skips cursor change if requested cursor is
already set. The check could be added in pain_cursor.c, but I felt adding it
inside WM_cursor_set function would hopefully skip more unnecessary cursor
reallocations.
Differential Revision: https://developer.blender.org/D7828
Reviewed by: Julian Eisel
Diffstat (limited to 'intern/opensubdiv/internal')
0 files changed, 0 insertions, 0 deletions