Age | Commit message (Collapse) | Author |
|
- Add blentranslation `BLT_*` module.
- moved & split `BLF_translation.h` into (`BLT_translation.h`, `BLT_lang.h`).
- moved `BLF_*_unifont` functions from `blf_translation.c` to new source file `blf_font_i18n.c`.
|
|
|
|
We already had that for global keymaps (used e.g. to generate shortcuts for menu entries),
but this wasn’t possible for modal keymaps yet (e.g. help message in header during
transforms and other modal operation).
This commit only adds needing background code, it does not change anything from user PoV.
Modal operators will be updated to use it in comming weeks.
Thanks to Campbell for revisions & suggestions. :)
Differential Revision: https://developer.blender.org/D780
|
|
Make sure SEQ_TYPE_EFFECT is only used as a flag, not as number
comparison.
This should allow us to add new non-effect types in between
effect types (every 8 indices).
Dirty, but alternative of separating type/subtype means we lose
forward compatibility.
|
|
treehash must always been checked before used!
Reported on irc by sebastian_k and investigated by sergey, thanks!
|
|
On existing Blender could rebuild tree many times (on freeing each ID).
Use a flag instead of immediately rebuilding.
|
|
Was running cleanup on every draw.
|
|
on undo due to invalid mem access.
We cannot nuke treestore in readfile's `blo_lib_link_screen_restore()`, because this will
destroy all UI-state data (like opened/closed items, etc.).
Since we cannot know for sure whether an ID pointer from tselem->id is valid here, we
have to ensure they are never invalid, i.e. to always set them to NULL when we delete them.
To do so, this commit uses a similar approach as what already exists for ID references
in WM notifiers - it extends `free_notifier_reference_cb()` to also nullify those IDs in
all outliners.
Note that some ID types are not used(shown) by outliner currently, so `TREESTORE_ID_TYPE` macro
was added, that checks whether an ID is possibly used by outliner. Avoids a few searches
in whole tree whene deleting some IDs.
Reviewers: campbellbarton, sergey
Maniphest Tasks: T44439
Differential Revision: https://developer.blender.org/D1272
|
|
This is an API specifically for the outliner,
not some generic hierarchical hash structure.
|
|
Avoids complicated casts accessing as int
|
|
|
|
appropriate place in the file
|
|
Orphaned datablocks are those which have either:
* 0 users
* A "fake" user only
In the case of the former, they will be quietly discarded from the file on the next
save + reload. Hence, it is helpful to have a view where you can confirm which ones
fall into this category and might be worth saving.
We also include datablocks with a fake user only so that datablocks given a user
above can have that easily turned off again (in case the user makes a mistake).
Another benefit of showing these is that it become easier to remove fake users from
datablocks you no longer want retained without having to hunt for them.
|
|
|
|
D1045 by @a.romanov
|
|
This is still very rudimentary, and lacks many things.
* This needs a better icon. Perhaps we can look into using colour swatches here
too like in all the other places?
* The "active" check needs to be implemented still
* Various restriction toggles to come still
|
|
This commit just adds entries for the Grease Pencil datablocks in the Outliner.
Currently, there's not much more to see here, but the following commits will see
to that.
|
|
Makes usage of those funcs much more clear, we even had mixed '!strcmp(foo, bar)'
and 'strcmp(foo, bar) == 0' in several places...
|
|
|
|
A new option to the Outliner's View menu is added to enable/disable sorting of items.
|
|
potential crashers.
|
|
both on main level and in nested tree.
Request from Gooseberry team. This eases a bit managing dependancies in complex .blend files.
Reviewers: campbellbarton
Subscribers: fsiddi
Projects: #user_interface, #bf_blender:_next
Differential Revision: https://developer.blender.org/D943
|
|
`BLI_strncpy_ensure_pad()` is also useful with current master code.
The two others (`BLI_strcmp_ignore_pad()` and `BLI_filelist_duplicate()`)
are only used in asset branch currently, but think they could be useful
in other places too, and simplifies handling of asset branch & future patch review.
Reviewers: campbellbarton
Reviewed By: campbellbarton
Differential Revision: https://developer.blender.org/D965
|
|
|
|
|
|
build flag is off.
The Datablocks display mode still shows line style ID datablocks to keep track of line styles
hidden from user interactions in the Properties window.
|
|
|
|
|
|
|
|
4ca67869cc7a."
This reverts commit a47a4ef82f37428d391cc14a30fa611d6714e71d.
|
|
|
|
Opted to keep includes if they are used indirectly (even if removing is possible).
|
|
|
|
|
|
|
|
Remove KeyMap mode from outliner, was an old half-finished features redondant with user preferences settings...
Also moved key map item's "event type to map type" and map type defines at WM level, this is too much generic to be at RNA level.
Also added a check in versionning code to convert all outdated outliner modes to a valid one (seems old 'verse' ones were not handled as well).
Thanks to Brecht for reviews and advices!
|
|
Freestyle is not enabled.
Line style data blocks are shown in the outliner only when the Blender Internal is used.
|
|
not enabled.
|
|
|
|
|
|
had to be done in every file using fnmatch (autoexec.c did not, wonder how it could work under unix???).
Thanks to Brecht for noting this!
|
|
In previous optimization in outliner I assumed that order in treehash was not important.
But testing outliner in datablocks mode revealed a problem: when user expands multiple recursive levels and then closes any element, it always closed the top level of recursion.
Now it should work fine with recursive trees.
Now treehash contains groups of elements indexed by (id,nr,type). Adding an element with the same (id,nr,type) results in appending it to existing group. No duplicates are possible in treehash.
This commit should also make lookups a little bit faster, because searching in small arrays by "used" is faster than searching in hashtable with duplicates by "id,nr,type,used".
|
|
|
|
ghash/edgehash.
the outliner does this intentionally, so add a flag to allow this situation optionally.
|
|
present on 2 Scenes
This is done by fixing logic for finding the first unused element in treehash.
The blend file from [36486] also exposes a memleak, but it should be addressed separately.
|
|
check so DM_to_mesh() can have a NULL object passed (currently not used) and remove redundant NULL check.
|
|
was using the wrong flag variable for toggling render layers, was setting pass flags instead of the layer on/off flag.
|
|
- performance of outliner was low because of unoptimal data structures.
- now it uses BLI_mempool instead of custom mempool and GHash to make searches for duplicates faster.
- also fix undesired behaviour of BLI_mempool_as_arrayN
thanks to Campbell Barton and Lukas Tönne for helping me get a better fix put together.
|
|
This significantly lowers the position of outliner_draw_tree_element in profiler
and partially fixes [#36260] (2,300 Objects Makes Blender Unresponsive)
|
|
- memset() was argument was truncated.
- outliner had redundant NULL check.
- node texture was allocating memory to make a unique name which isnt needed for a fixed size string.
|