Age | Commit message (Collapse) | Author |
|
- Re-order freeing so an instances __del__ method runs before the
`ExtensionRNA` has been freed.
- "remove" functions no longer free the gizmo/gizmo-group memory,
needed so the identifier used when freeing the extension
doesn't use the freed identifier.
|
|
These functions with many arguments can be unwieldy. Aside from the obvious issues
with rewriting the list of arguments and the opportunities for error and frustration
that presents, the long list of arguments make these systems hard to change. So when
an argument should be added, someone might skip that and add some hack instead.
So, as proposed in T73586#1037210, this patch instead uses a "params" struct for
each of these callbacks.
- Use param argument for `ARegionType.listener`
- Remove unused window field in region listener
- Use param argument for `SpaceType.listener`
- Use params struct for `ARegionType.message_subscribe`
Differential Revision: https://developer.blender.org/D9750
|
|
No functional changes
|
|
This replaces header include guards with `#pragma once`.
A couple of include guards are not removed yet (e.g. `__RNA_TYPES_H__`),
because they are used in other places.
This patch has been generated by P1561 followed by `make format`.
Differential Revision: https://developer.blender.org/D8466
|
|
This removes extern-C blocks around other includes and adds
such blocks for some headers that need them.
|
|
Follow up of b2ee1770d4c3 and 10c2254d412d, part of T74432.
Now the area and region naming conventions should be less confusing.
Mostly a careful batch rename but had to do few smaller fixes.
Also ran clang-format on affected files.
|
|
The old convention was easy to confuse with ScrArea.
Part of https://developer.blender.org/T74432.
This is mostly a batch rename with some manual fixing. Only single word
variable names are changed, no prefixed/suffixed names.
Brecht van Lommel and Campbell Barton both gave me a green light for
this convention change.
Also ran clan clang format on affected files.
|
|
|
|
Move redraw tagging to the gesture modal operator
to make sure this only runs when it's needed.
Caused by d591c8a350310, which tagged the region to redraw when the
gizmos were tagged to refresh, however they wont redraw when hidden.
Thanks to @jbakker for finding the root cause.
|
|
This resolves a logical problem using tweak as a fallback tool.
See: T66304#828742
The select action would immediately show the gizmo underneath it,
then the tweak would be handled by the gizmo instead of moving the item
under the cursor.
Currently this works by hiding the gizmo until the tweak event ends.
While it's simpler to check if the gizmo received a mouse-down event,
it causes flickering before each drag event which feels like a glitch.
This is optional for each gizmo type because there are cases where this
can be useful to activate the gizmo immediately (mesh rip for example).
|
|
Allows for adding checks before/after refresh, not yet added.
|
|
Gizmo group types now store a user count so they aren't unlinked
while other tools are using them.
The tool system now works with multiple windows.
|
|
Introduced in recent commit c93af8529dfec
|
|
|
|
Clear gizmo highlight when the cursor leaves the region.
|
|
The legacy keymap now activates on press.
|
|
|
|
Allows gizmos clicks to fall through for gizmos which only drag,
currently unused.
|
|
Existing functions were written to match the setup_keymap callback.
Add versions that can be called with the window manager for convenience.
|
|
While support for gizmo specific keymaps remains, this should only
be used if a gizmo-group is doing something that requires one.
There was also a hidden limitation that meant only the last registered
tweak keymap would ever be used.
For now leave this using the generic keymap since all
tweak modal keymaps were using the same template anyway.
|
|
While internally these are separate gizmos,
there is no reason to have a keymaps for each.
Also prefix the gizmo with "3D View"
since there are other kinds of transform gizmos.
|
|
Apply clang format as proposed in T53211.
For details on usage and instructions for migrating branches
without conflicts, see:
https://wiki.blender.org/wiki/Tools/ClangFormat
|
|
Re-create gizmos when changing theme colors, since
theme colors don't change often this allows gizmos to setup their
colors on initialization.
|
|
While \file doesn't need an argument, it can't have another doxy
command after it.
|
|
Tools were relying on gizmos drawing to initialize their gizmos,
now tool gizmos are initialized immediately.
|
|
Move \ingroup onto same line to be more compact and
make it clear the file is in the group.
|
|
BF-admins agree to remove header information that isn't useful,
to reduce noise.
- BEGIN/END license blocks
Developers should add non license comments as separate comment blocks.
No need for separator text.
- Contributors
This is often invalid, outdated or misleading
especially when splitting files.
It's more useful to git-blame to find out who has developed the code.
See P901 for script to perform these edits.
|
|
Done using:
source/tools/utils_maintenance/c_sort_blocks.py
|
|
|
|
|
|
|
|
|
|
Partially re-initializing a gizmo is often more trouble then removing
and re-adding.
|
|
|
|
Displaying the labels tip immediately feels too intrusive,
make this work more like regular tooltips, displaying more quickly.
Tooltips can now uses multiple passes, each pass with it's own delay
for the next pass to show.
|
|
Add float in API names since we may want access to other types.
|
|
Most of these were mismatched const qualifiers
|
|
|
|
|
|
|
|
Edit doxy files and header guards only.
|