This affected sculpt, vertex- and weightpaint.
So attempting to (temporarily) switching to the smooth/blur tools from
another tool using the "Shift" shortcut can fail if the corresponding
smooth/blur brush is not found/missing [which was the case in the report
because the brush was deleted].
In this case, brushes dont really get switched, but blender would still
try to cache the size (because the smooth/blur brush temporarily uses
the same size as the previous brush) of the smooth brush in
`StrokeCache` (see `smooth_brush_toggle_on`). Then in
`smooth_brush_toggle_off` it was assumed brushes were actually switched
and the (non-existing) size of the (missing) smooth brush was applied to
the **actual** brush.
Now restructure code a bit so in the case of a missing brush we can
early out (without affecting the **actual** brush then).
Pull Request: #111516
Registering a node with a `bl_idname` same as a built-in node will lead
to crash because `rna_Node_unregister` does not check `nt->rna_ext.data`
to see whether it's not null (which indicates whether this node is
registered with python or not). Now fixed.
Pull Request: #111615
If this is not a system override, this leads to the override actually
being reset (which might affect the 3Dview and most probably affects the
Properties Editor).
Now use the same modifiers as used elsewhere for resetting a library
override.
Pull Request: #111469
Previously `SEQ_modifier_list_copy` in append mode does not ensure
unique strip name, which will result in duplicated names in target
modifier list, then `strip_modifier_remove(name="something")` can remove
the wrong one later on. Now fixed using `BLI_uniquename`.
Pull Request: #111602
The code ensuring that an object (or obdata) is not made local if it is
used by linked data that is not tagged to be made local was blatantly
buggy, leading to over-detecting such cases.
Note that this code remains fairly fragile imho, think the whole Main
data-base of IDs should be checked, other data-types than Objects can
use objects! But this is for another day.
Status of selected bold, italics, underline, and small caps requires
that the curve have an editfont object. Not checking for this works
interactively but can cause errors in Python. This PR adds explicit
getters and setters that check for editfont.
Pull Request: #110513
Specifying the correct operator context (`INVOKE_REGION_CHANNELS` in
this case) is mandatory, otherwise looking up the shortcut in
`wm_keymap_item_find_props` will fetch the wrong region
(`RGN_TYPE_WINDOW` not `RGN_TYPE_CHANNELS`) and thus wont find the keymap
item in that region keymap.
This was already done for the other menus, not for the context menu
though.
Pull Request: #111376
Mistake in (7-year-old) f6c09eadf0.
The operator was just cancelled if the right button was found, instead
it should only cancel if the button is _not_ found.
Pull Request: #111373
Since menus are created flipped (from event handling point of view), the
root layout block needs to be flagged `UI_BLOCK_IS_FLIP`.
This was missing for a couple of `uiMenuCreateFunc`, namely:
- creating worspaces menu
- modifiers extra ops
- constraints extra ops
- GP modifiers extra ops
- GP Shader FX extra ops
Same fix as f51de2246c.
Not crtitcal, but could go into LTS I guess.
Pull Request: #111341
WM_report on the unlikely event when an area (smaller than minimums) is
within the combined operation bounds (close or join) and interferes.
Pull Request: #111280
Fixes NaN in Vector Displacement node caused by the normalization of
0, 0, 0 vectors.
This fixes both visual rendering issues and an "illegal address" error
on the GPU. The "illegal address" error came from the Light Tree
Sampling code not handling the NaN normals well, leading to weird code
paths being taken, eventually leading to a kernel_assert and a
user facing illegal address error.
Pull Request: #111294
When the temporary File Browser uses a maximized editor, it reuses the
File/Asset Browser under the cursor. When the file browsing action is
confirmed, the old editor state is restored but the file-list cleared,
so it fails to find the active asset and the ID it represents in
context.
Work around this by getting the ID before spawning the File Browser from
the operator.
When copying (CTRL+L->Animation Data) a driver between two objects
that are linked with library overrides, `AnimData` was not created.
This did crash Blender when it tried to use the `nullptr`
The reason it crashed is because the function
`DEG_id_tag_update()`
was never called.
Fix it by restructuring the code so the function gets called
Pull Request: #110795