bdk-blender/doc
Luca Rood 8a799b00f8 Fix T100423: Addon's custom context menu entries get overridden by other addons
This introduces a new `UI_MT_button_context_menu` class which is
registered at startup. Addons can append/prepend draw functions to this
class, in order to add their custom context menu entries.

The new class replaces the old `WM_MT_button_context` class, thus
requiring a small change in addons using this feature. This is done
because addons were previously required to register the class
themselves, which caused addons to override each other's context menu
entries.

Now the class registration is handled by Blender, and addons need only
append their draw functions. The new class name ensures that addons
using the old method don't override menu entries made using the new
class.

Menu entries added with the legacy `WM_MT_button_context` class are
still drawn for backwards compatibility, but this class must not be used
going forward, as any addon using it still runs the risk of having its
menu entries overridden, and support for the legacy class is subject to
removal in a future version.

Reviewed By: campbellbarton

Maniphest Tasks: T100423

Differential Revision: https://developer.blender.org/D15702
2022-08-18 14:46:30 +02:00
..
blender_file_format Cleanup: autopep8 2022-04-26 15:03:04 +10:00
doxygen Blender 3.3 bcon1 - alpha 2022-05-02 10:28:30 +02:00
guides Spelling fixes in comments and descriptions, patch by luzpaz 2019-07-31 14:27:35 +02:00
license Docs: add license text file for LGPL2.1 2022-03-18 10:27:01 +11:00
manpage Cleanup: remove "<pep8 compliant>" from headers 2022-06-02 20:16:20 +10:00
python_api Fix T100423: Addon's custom context menu entries get overridden by other addons 2022-08-18 14:46:30 +02:00