Commit Graph

2212 Commits

Author SHA1 Message Date
Campbell Barton
ac6e216b26 Merge branch 'blender-v4.2-release' 2024-07-08 13:05:45 +10:00
Campbell Barton
f3630777f6 Extensions: show add-on errors in the add-ons panel
Restore the UI from 4.1. Also correct an error when extensions are
disabled.
2024-07-08 11:36:52 +10:00
Campbell Barton
a515da841b Merge branch 'blender-v4.2-release' 2024-07-07 17:51:42 +10:00
Campbell Barton
5877efbec3 Extensions: add missing checks for errors in IO, JSON & TOML data
Exceptions need be caught and forwarded so they show it in Blender's
interface. While most common errors where accounted for, various IO
errors & malformed JSON/TOML could cause internal operations to fail
with unhandled exceptions.
2024-07-07 17:43:33 +10:00
John Kiril Swenson
406554c11e VSE: Add snapping in preview area
Adds snapping in the VSE preview area.

Source points are the four corners and origins of all selected, visible
image quads. Targets can be preview borders, preview center, or
corners/origins of other strips.

Pull Request: https://projects.blender.org/blender/blender/pulls/122759
2024-07-06 15:24:52 +02:00
Campbell Barton
08bf742302 Merge branch 'blender-v4.2-release' 2024-07-06 15:00:43 +10:00
Campbell Barton
11b1919bcf Extensions: resolve popup glitches when dropping URL's
Use UILayout::template_popup_confirm to replace workarounds that didn't
work very well.

- Resolve "Add Repository..." button in the dialog not closing the
  popup when pressed.
- Add a "Cancel" button while the remote resository data is
  downloading.
- Remove the hack to scale the UILayout to hide the existing
  confirm/cancel buttons.

Resolves #124098.
2024-07-06 14:49:41 +10:00
0aa75ab57b Refactor: rename "Animation data-block" to "Action"
Rename "Animation data-block" to "Action" or "Layered Action", where
appropriate. Some uses of the term actually refer to the `AnimData`
struct, in which case they were left as-is.

No real functional changes, just changing some messages & descriptions.

Pull Request: https://projects.blender.org/blender/blender/pulls/124170
2024-07-05 17:52:55 +02:00
c0364efec0 Refactor: rename 'Action Binding' to 'Action Slot'
Rename 'Binding' to 'Slot'. The old term was causing all kind of
confusion, and 'slot' was considered to be a better term for the
intended functionality.

This commit breaks existing blend files that were using the new layered
Action for their animation. The animation data will be lost due to the
rename, as there is no versioning code or DNA renaming logic. At this
time the new system is still marked as experimental, so shouldn't be
used for anything serious anyway.

Pull Request: https://projects.blender.org/blender/blender/pulls/124170
2024-07-05 17:52:55 +02:00
Campbell Barton
8250ac142f Merge branch 'blender-v4.2-release' 2024-07-05 20:49:47 +10:00
Campbell Barton
337abcdfc1 Merge branch 'blender-v4.2-release' 2024-07-05 20:49:45 +10:00
Campbell Barton
a53aad6f73 Extensions: refactor message logging into a class
Pass a logging class between functions instead of a function. Has the
advantage that different kinds of messages are exposed as methods.
2024-07-05 20:46:40 +10:00
Campbell Barton
08b75549e3 Extensions: add a new error type "FATAL_ERROR"
Some errors were reported as warnings because they didn't prevent the
operation from completing (such as failing to remove some paths when
uninstalling).

Change message types for the extensions internal command line program:

- Add "fatal error" to use when an operation fails and exits with a
  non-zero error code.
- Use "error" when an operation fails which doesn't prevent other
  actions from succeeding.
- Use "warn" reporting issues what don't prevent the operation
  from completing but may cause problems.
2024-07-05 20:46:40 +10:00
Abdelrahman
789bcaae78 GPv3: Port frame_clean_duplicate operator
Port the `frame_clean_duplicate` operator to GPv3.
Resolves #114182.

Pull Request: https://projects.blender.org/blender/blender/pulls/116655
2024-07-05 09:48:20 +02:00
Campbell Barton
169ad993f5 Merge branch 'blender-v4.2-release' 2024-07-05 16:29:03 +10:00
Campbell Barton
726d9c5b38 Extensions: detect remote repositories when dropping a file
When dropping an extension into Blender, check if the extensions is
part of a remote repository which is then used to set the default
repository.

This makes it more convenient to download larger extensions from
remote repositories using a web-browser & drop them into Blender after,
rather than dropping the URL directly into Blender.
2024-07-05 16:18:52 +10:00
Harley Acheson
6fbb5ce8d8 Merge branch 'blender-v4.2-release' 2024-07-04 11:19:14 -07:00
Christoph Lendenfeld
af089bee98 Fix: Add missing Bake Channel operator to Dope Sheet
This PR adds the operator "Bake Channels" to the "Channels" menu of the dope sheet.
The operator was already in the "Channels" menu of the Graph Editor.

Pull Request: https://projects.blender.org/blender/blender/pulls/123559
2024-07-04 17:12:04 +02:00
1d2cea1e3e Show Action Slots (Bindings) in the Action editor
In the Action mode of the Dope Sheet, show the Bindings, optionally
showing all Bindings in that Action. This also works when different
data-block types are animated from the same Action.

Bindings are selectable in the Action editor with box/range select.
Since there is no use for an 'active Binding' yet, this has not been
implemented, and as a result, clicking on a Binding does nothing.

Note on 'Binding' vs 'Slot': this code change was created before the
decision to change the name from 'Bindings' to 'Slots'. To avoid
confusion, and to keep this PR in sync with the code changes, it still
uses the term 'binding'. Renames of 'Binding' to 'Slot' in the code will
happen after this PR lands.

Pull Request: https://projects.blender.org/blender/blender/pulls/122672
2024-07-04 14:44:19 +02:00
Bastien Montagne
9a13aff4b8 Merge branch 'blender-v4.2-release' 2024-07-04 14:39:58 +02:00
Bastien Montagne
dc8ab86aec Cleanup: make format 2024-07-04 14:39:23 +02:00
Damien Picard
cc40d9f565 I18n: Fix translations for NLA
- Do not translate a label containing the name of the active NLA
  action.
- Translate default action name when created by inserting a keyframe.
- Translate "<NoAction>" and other default NLA strip names.
- Translate "<NoAction>" displayed in the UI when no action exists in
  the NLA.
- Translate the temporary meta-strip created when moving an NLA strip
  around. This uses DATA_() for consistency, even though it is not
  really user data.

Issues reported by Gabriel Gazzán.

Pull Request: https://projects.blender.org/blender/blender/pulls/124113
2024-07-04 14:35:19 +02:00
Damien Picard
78b9218c98 I18n: Fix translations for Rigify
Rigify was recently added to the core add-ons, and is now
translatable. This change fixes many issues that made messages
poorly or not translatable.

- Replace f-strings and % formatting with str.format().
- Use iface_ and rpt_ to translate formatted strings.
- Rename metarig submenus from "<Category> (submenu)" to simply
  "<Category>" to allow the menu entries and submenus to have the same
  name and be translated. The label was awkward anyway in my opinion.
- Remove trailing "." in operator reports.
2024-07-04 14:35:17 +02:00
Jeroen Bakker
3891f46084 Merge branch 'blender-v4.2-release' 2024-07-04 12:47:38 +02:00
Jeroen Bakker
1931b8e63f EEVEE: Fix missing material preview
Pull Request: https://projects.blender.org/blender/blender/pulls/124151
2024-07-04 12:46:29 +02:00
Falk David
103f3f261a Fix: GPv3: Draw Tool: Use "Dot" cursor for draw tool
When disabling the "Show Cursor" option in the tool settings for the
draw tool, the cursor was set to the OS default.
This was not the case in GPv2, which used the "Dot" cursor.

The fix enables the "Dot" cursor by default for the draw tool.
2024-07-04 11:22:32 +02:00
Bastien Montagne
b42f2b7634 Merge branch 'blender-v4.2-release' 2024-07-04 11:08:56 +02:00
Damien Picard
6a52c76a65 I18n: Translate messages in extensions, operator descriptions, Node Wrangler
- Operator descriptions use tip_() since they will be displayed in
  tooltips.

- Extension messages:
  - Split "(Add-on|Theme) \"{:s}\" already installed!" into two
    messages.
  - Use rpt_() to translate error messages.

- Restore core add-on name and description translation.

- Use DATA_ to translate paint material slot name, so that translation
  happens only if the user enabled it for user-created data.

- Node Wrangler contains functions used to build operators' poll
  methods. This change allows them to be properly translated by using
  str.format() instead of f-strings, and explicit extraction with
  tip_().

Pull Request: https://projects.blender.org/blender/blender/pulls/123795
2024-07-04 10:49:52 +02:00
Julien Duroure
d8675a3f6a Merge branch 'blender-v4.2-release' 2024-07-04 09:00:46 +02:00
Julien Duroure
8bf4d3c33f glTF exporter: Fix #124072 - avoid crash exporting empty collection at center 2024-07-04 08:57:27 +02:00
Julien Duroure
69390e970f glTF exporter: avoid crash copying props 2024-07-04 08:50:48 +02:00
Julien Duroure
2e03ca4a5b Merge branch 'blender-v4.2-release' 2024-07-04 08:50:26 +02:00
Julien Duroure
0ec32af432 glTF exporter: avoid crash copying props 2024-07-04 08:47:17 +02:00
Campbell Barton
a9763ffabc Merge branch 'blender-v4.2-release' 2024-07-04 12:41:23 +10:00
Campbell Barton
e3457bccbf Extensions: sub-commands "build" & "validate" validate manifest tags
Enforce tags from extensions.blender.org with support for using an
alternate set of tags (for other repositories), or no tag validation
at all if the repositories choose not to enforce this.

- By default building & validating an extensions fails when unknown
  tags are used.

- The option `--valid-tags`` has been added which can either:

  - Reference a JSON file which lists valid tags per extension type.
  - Pass in an empty string to disable tag validation.

Default to constraining packages to use Blender's official tags as every
extension defining their own tags is likely to result in many similar
tags & a bad user experience. Details in code-comments.

Implements #123986.
2024-07-04 11:56:07 +10:00
Xavier Hallade
275b6ee008 Merge branch 'blender-v4.2-release' 2024-07-03 14:03:37 +02:00
Philipp Oeser
cbbeeccd08 Fix #124027: EEVEE light influence UI disappears when light is pinned
As desribed in #90039, we dont have a context object when pinning data,
this was accessed though leading to python errors.

The object was only used for the active state of certain layouts, do to
resolve the errors (and disappearing UI), check if we actually get an
object from context. That means the correct active state of certain
layouts is lost (it could either be always ON or always OFF, PR is using
the former -- since the default visibility is ON, so that would be more
common).

Pull Request: https://projects.blender.org/blender/blender/pulls/124091
2024-07-03 13:43:39 +02:00
Campbell Barton
b615091256 Merge branch 'blender-v4.2-release' 2024-07-03 16:57:15 +10:00
Campbell Barton
463c05b341 Extensions: fix missing redraw after setting tags, report adding a repo
- Report when a repository is added since it's not so clear from the
  popup that a new repository has been added.
- Fix for missing redraw after selecting all/none tags.
- Also access the tags property once instead of getting it for each
  button.
2024-07-03 16:56:01 +10:00
Campbell Barton
9da4f557f1 Merge branch 'blender-v4.2-release' 2024-07-03 16:05:49 +10:00
Campbell Barton
e2b24904c9 Extensions: add buttons to select tags
This is for convenience since manually selecting all/none is tedious.
2024-07-03 15:55:20 +10:00
Bastien Montagne
6d68f82398 Merge branch 'blender-v4.2-release' 2024-07-02 16:52:15 +02:00
Bastien Montagne
570eee1717 Debug: Add new userpref option to enforce recompute of ID usercount on filesave.
This is a workaround to allow user to keep working without loss of data
when an issue like #124049 happens.

This commit also expose again the `use_all_linked_data_direct` debug
option, no idea why that one was removed.
2024-07-02 16:46:19 +02:00
Campbell Barton
9103f9682d Merge branch 'blender-v4.2-release' 2024-07-02 17:06:40 +10:00
Campbell Barton
df6ba6d324 Fix unhandled exception refreshing outdated extensions
Changes the the extension repositories in the preferences while
update notifications were running could raise an exception.

Resolve by only calculating outdated extensions for
repositories that still exist.
2024-07-02 17:04:53 +10:00
Campbell Barton
e3d0997065 Merge branch 'blender-v4.2-release' 2024-07-02 16:19:45 +10:00
Andrej730
1f0592b3b1 Docs: corrections to bpy.utils.register_tool
- Replaced `tool` argument with `tool_cls`.
- Removed `space_type` argument that's not present in the method.

Ref: !118900
2024-07-02 16:18:08 +10:00
Campbell Barton
83ce50f2b8 Merge branch 'blender-v4.2-release' 2024-07-02 16:09:45 +10:00
Thomas Barlow
d1cff7974a Fix #108254: Infinite loop in rna_info.BuildRNAInfo(..)
When a registered class has a non-registered superclass,
rna_info.BuildRNAInfo entered an eternal loop.

The while loop in `rna_info.get_py_class_from_rna` was not mutating the
variables within the loop nor the variable in its condition, meaning it
would loop infinitely if the loop didn't exit in its first iteration.

When yielding registered classes in `subclasses_recurse`, the function
was erroneously checking if the class' superclass was registered rather
than checking the class itself, causing registered classes to be skipped
if their superclass was not also registered. If the class to be found
was skipped, the while loop would not exit in its first iteration and
would thus loop infinitely.

The while loop has been modified to iterate through each base rna type
until there is no further base type.

The `subclasses_recurse` function now correctly checks whether the
subclass is registered, not its superclass, when determining if the
subclass should be yielded.

Besides the fix, no functional changes are expected, the generated
Python API docs remain unchanged.

Ref: !108256
2024-07-02 16:03:26 +10:00
Campbell Barton
d97b7f4cd6 Merge branch 'blender-v4.2-release' 2024-07-02 15:23:11 +10:00