Welcome to mirror list, hosted at ThFree Co, Russian Federation.

git.blender.org/blender.git - Unnamed repository; edit this file 'description' to name the repository.
summaryrefslogtreecommitdiff
AgeCommit message (Collapse)Author
2022-01-13Outliner: Compile all Outliner files in C++Julian Eisel
We want to refactor quite some of the Outliner code using C++, this is a logical step to help the transition to a new architecture. Includes plenty of fixes to make this compile without warnings, trying not to change logic. The usual stuff (casts from `void *`, designated initializers, compound literals, etc.).
2021-12-08Cleanup: move public doc-strings into headers for 'editors'Campbell Barton
Ref T92709
2021-09-29Texts in Outliner dont activatePhilipp Oeser
Texts in Outliner dont activate on selecting (Text Editor did not change to selected text) which is a bit inconsistent to other ID types. ref T90862 Maniphest Tasks: T90862 Differential Revision: https://developer.blender.org/D12412
2021-09-02Cleanup: remove redundant alloc argument to SEQ_editing_getCampbell Barton
Callers that require lazy initialization can use SEQ_editing_ensure.
2021-08-26Fix T90915: outliner select behaves as if Ctrl is heldCampbell Barton
Error in 452cc0193255c9e80ca4f163a2d524ed6bb17ef1
2021-08-03WM: don't store selection properties typically set in the key-mapCampbell Barton
While this was already the case for the most part some selection operators stored common settings for reuse such as "toggle", "extend" & "deselect". Disabling storing these settings for later execution as it means failure to set these options in the key-map re-uses the value of the shortcut that was last called. Skip saving these settings since this is a case where reusing them isn't helpful. Resolves T90275.
2021-07-23Cleanup: code comments punctuation / spacingCampbell Barton
2021-07-13Refactor: Move vertex group names to object dataHans Goudey
This commit moves the storage of `bDeformGroup` and the active index to `Mesh`, `Lattice`, and `bGPdata` instead of `Object`. Utility functions are added to allow easy access to the vertex groups given an object or an ID. As explained in T88951, the list of vertex group names is currently stored separately per object, even though vertex group data is stored on the geometry. This tends to complicate code and cause bugs, especially as geometry is created procedurally and tied less closely to an object. The "Copy Vertex Groups to Linked" operator is removed, since they are stored on the geometry anyway. This patch leaves the object-level python API for vertex groups in place. Creating a geometry-level RNA API can be a separate step; the changes in this commit are invasive enough as it is. Note that opening a file saved in 3.0 in an earlier version means the vertex groups will not be available. Differential Revision: https://developer.blender.org/D11689
2021-07-05Cleanup: spelling in commentsCampbell Barton
2021-06-24Cleanup: comment blocks, trailing space in commentsCampbell Barton
2021-03-12Cleanup: redundant outliner includesCampbell Barton
2021-03-05Cleanup: Add & use enum value for ID Outliner element typeJulian Eisel
Code to check if the Outliner tree-element type was the general ID one would always check against "0" (explicity or even implicitly). For somebody unfamiliar with the code this is very confusing. Instead the value should be given a name, e.g. through an enum. Adds `TSE_SOME_ID` as the "default" ID tree-element type. Other types may still represent IDs, as I explained in a comment at the definition. There may also still be cases where the type is checked against "0". I noted in the comment that such cases should be cleaned up if found.
2021-02-20Cleanup: Disentangle outliner active status "get" and "set"Hans Goudey
Previously the same functions were used to both set and get the active state for outliner tree elements. This has quite a few problems. - It's hard to tell when data is changed or simply read - It prevents using `const` - The code is full of if statements, making it longer and less readable. This commit replaces the `tree_element_type_active` and `tree_element_active` functions with `_get` and `_set` variants. One has const arguments and returns the active state, the other deals only with setting the state. While this refactor results in slightly more lines of code, the result is much better in my opinion. This commit also removes unused variables from arguments of the affected functions. Differential Revision: https://developer.blender.org/D10232
2021-02-14Cleanup: spellingCampbell Barton
2021-02-08Cleanup: Remove dead code for keymap Outliner display modeJulian Eisel
This wasn't used for a long time and there are no plans to bring this back.
2021-01-22Merge branch 'blender-v2.92-release'Campbell Barton
2021-01-22Fix T84920: Crash undoing object activation in the outlinerCampbell Barton
Regression from d8992192e5512380f57433df113f3e3f8b22f7cb The original code relied on having a separate edit-object pointer than the active object. Use a utility function to avoid code duplication as there are other areas that have similar functionality.
2021-01-20Cleanup: remove extra in trailing asteriskCampbell Barton
Comment blocks not conforming to convention.
2020-12-22UI: Properties editor popover and outliner syncNathan Craddock
This adds a popover to the properties editor. Currently the only setting is for controlling outliner to properties syncing. Because we cannot define a perfect heuristic to determine when properties editors should change tabs based on outliner icon selection, we need an option to enable or disable this behavior per properties editor. There are 3 options for controlling the syncing. Auto uses the heuristic to only allow tab switching when a properties editor and outliner share a border. On and off enable and disable syncing respectively. Differential Revision: https://developer.blender.org/D9758
2020-12-19Cleanup: Split SEQ_sequencer.h fileRichard Antalik
2020-12-19Cleanup: Rename BKE_sequencer functionsRichard Antalik
API functions get SEQ_ prefix. Intern functions get seq_ prefix Functions also have appropriate category included in name.
2020-12-18Outliner: Set active modifier on clickHans Goudey
The outliner already expands the panel for the modifier you click on, this just extends that idea to also set it active, which is consistent with behavior of active and selected items elsewhere in Blender.
2020-11-27Cleanup: Move logic to `outliner_find_item_at_x_in_row`Nathan Craddock
Move the logic for determining if the item at a given x position is an icon into the function. This is used for determining selection over an icon, and will be used in a later commit for checking for hover over an icon. No functional changes.
2020-11-24Outliner: Switch properties tabs only on icon clickNathan Craddock
According to feedback the outliner to properties editor tab switching was annoying when it always changed tabs on selection, especially for selecting individual objects. This limits the tab switching behavior to only when the icons in the outliner are selected.
2020-11-13Outliner: Sync with property editor physics tabHans Goudey
This commit makes the property editor switch to the physics tab instead of the modifier tab when selecting physics modifiers. Since the modifier isn't visible then, it's confusing to change the expansion, so this commit also disables the modifier expansion for these modifiers. Differential Revision: https://developer.blender.org/D9544
2020-11-11Merge branch 'blender-v2.91-release' into masterPhilipp Oeser
2020-11-11Fix 'outliner_scroll_view()' not reaching wanted elementPhilipp Oeser
Scrolling to an item after opening relevant parents can go wrong if said parent e.g. the last in the list [as in: then the Outliner does not scroll down all the way] It stems from the fact that 'region->v2d.tot.ymin' is not up-to-date in outliner_scroll_view after outliner_show_active opens up parents, 'tot' will only update on a redraw. Now calculate the trees height on the fly using 'outliner_tree_dimensions()'. ref D9521 ref T82553 Maniphest Tasks: T82553 Differential Revision: https://developer.blender.org/D9523
2020-11-11Merge branch 'blender-v2.91-release'Nathan Craddock
2020-11-11Fix: Selection not possible from outliner gutterNathan Craddock
Selection should be possible from the left gutter in object mode. When in other modes the mode column displays icon buttons which should be prioritized for selection only in those modes. Introduced in rB2110af20f5e6.
2020-11-06Merge branch 'blender-v2.91-release' into masterPhilipp Oeser
2020-11-06Fix Outliner editbone selection with 'Sync Selection'Philipp Oeser
When editbones were selected from the Outliner (and they were connected to a parent) with the 'Sync Selection' option turned ON, they could not get duplicated. For duplication to work, the (connected) parent bone's tip also has to be selected [which was not the case when selection is done from the Outliner under above circumstances]. The reason being that armature_duplicate_selected_exec -> ED_armature_edit_sync_selection clears the BONE_ROOTSEL flag if the parent bone's BONE_TIPSEL is not set. Caused by rB71eb65328078 btw. The correct "parent-tip-selection" would actually happen in activation - `tree_element_active_ebone` -- `tree_element_active_ebone__sel` but for 'Sync Selection' this happens [also] in - `outliner_sync_selection_from_outliner` -- `outliner_select_sync_to_edit_bone` which did not do the "flushing" to the parent bone's tip Now use existing dedicated function for this. ref. T82347 Reviewers: Zachman Differential Revision: https://developer.blender.org/D9470
2020-11-06Cleanup: use ELEM macroCampbell Barton
2020-11-01Rename BKE_sequencer.hRichard Antalik
Reviewed By: sergey Differential Revision: https://developer.blender.org/D9349
2020-10-30Merge branch 'blender-v2.91-release'Campbell Barton
2020-10-30Merge branch 'blender-v2.91-release'Campbell Barton
2020-10-30Outliner: use undo-group for outliner mode switchingCampbell Barton
Switching modes no longer adds multiple undo steps from a user perspective.
2020-10-30Fix outliner mode toggling with multi-object pose/edit modeCampbell Barton
For edit/pose modes clicking in the mode-column would include other selected objects (besides the active object), causing other objects to remain in the mode even though Control wasn't held. Also replace `ED_object_mode_generic_exit(...)` on all objects with a single call to `ED_object_mode_set(...)` so switching modes will only exit the current mode, leaving objects in other modes unchanged.
2020-10-28Outliner: Properties editor sync on selectionNathan Craddock
When outliner datablocks are selected, switch to the corresponding tab for that datablock in properties editors. Only properties editors that share an edge with the outliner will change tabs. Additionally, when modifiers, constraints, and shader effects are selected from the outliner, the panel will be expanded in all properties editors. Part of T77408 Manifest Task: https://developer.blender.org/T63991 Differential Revision: https://developer.blender.org/D8638
2020-09-30Cleanup: Use LISTBASE_FOREACH macro in outliner codeHans Goudey
2020-09-16Outliner: Modifier/constraint/shaderfx drag and drop operatorNathan Craddock
This adds an operator to allow drag and drop of modifiers, constraints, and shader effects within the outliner. Referred to as "data stack" in the code for simplicity. The following operations are allowed: * Reordering within an object or bone * Copying a single modifier/constraint/effect to another object or bone * Copying (linking) all modifiers/constraints/effects to another object or bone. This complements the recent work done for panel-based modifier layouts by allowing reordering in the outliner. It also makes it simple to copy a single modifier/constraint/effect to another object. Differential Revision: https://developer.blender.org/D8642
2020-09-10Cleanup: remove else-after-returnJacques Lucke
This causes a clang-tidy error.
2020-09-10Cleanup: Remove outliner edit mode context menu entriesNathan Craddock
The outliner context menu has options to enter and exit edit mode, but they only show in edit mode, and they don't work. This removes the broken entries and related code. Part of T77408 Differential Revision: https://developer.blender.org/D8641
2020-09-10Outliner: Move mode toggling to left columnNathan Craddock
Add a column of icons in the left gutter of the outliner for controlling the interaction modes of objects. When an object is in a mode other than object mode, the mode icon will draw to the left of that object. Any other objects that are valid to be added or swapped into the mode are drawn with a dot to the left of the object. Clicking the dot to the left of an object will swap that object with the current active object in the interaction mode. For edit and pose modes, ctrl clicking the dot will add that object to the current mode. Clicking the mode icon next to the active object removes it and all other objects from the current mode. The behavior is nearly identical to the previous edit/pose mode toggling by selecting the mesh and armature datablocks, with additional support for all interaction modes. Currently two undo steps are pushed to prevent an assert. Part of T77408 Manifest Task: https://developer.blender.org/T68498 Differential Revision: https://developer.blender.org/D8641
2020-08-28Fix: Outliner walk navigation in Data API modeNathan Craddock
Because the subtrees in Data API mode are empty for performance reasons, it was impossible to move through the tree with walk navigation. This adds an exception to allow walk navigation to expand subtrees in that mode.
2020-08-27Fix Outliner allowing to enter Pose Mode on linked armatureJulian Eisel
If a different object was active, clicking on a linked armature's pose in the Outliner would enter Pose Mode for it. This would actually cause a failed assert, but in release builds the armature would just enter pose mode. Steps to reproduce were: * Link in armature object * Activate a different object * In the Outliner, un-collapse the armature object * Activate Pose Mode by clicking on its pose there
2020-08-27Fix (unreported): Outliner Data API tree subtree expansionNathan Craddock
The changes in rB70151e41dc02 broke subtree expansion in the Data API display mode because the closed subtrees are empty lists. Move the empty subtree check from `outliner_item_openclose` to the walk navigation code to prevent the issue.
2020-08-26Outliner: Left and right walk navigationNathan Craddock
Previously the left and right arrow keys would close and open the active tree element, but a subsequent key press would not select up or down the tree as is common in tree-based interfaces. Walking left and right now does a selection action after opening or closing the active tree item. For example, a right key press on a closed element will open it's subtree, and an additional right key press will select the first child element. A left key press anywhere in a subtree will first close the active element if it's subtree is expanded. Walking left again will select the parent element. Part of T77408 Differential Revision: https://developer.blender.org/D8650
2020-08-20Outliner: Avoid rebuilding tree on selection/active changesJulian Eisel
We can avoid the rather expensive outliner tree rebuilds and only redraw if nothing but the selection or active item changes. This should give a bit of speedup for heavy scenes. For this to work I had to correct a few notifiers, some were only sending selection/active change notifiers that actually did things like adding objects. I also added a more precise notifier type for when the active collection changes. At the notifier subtype/action level we're not even close to running out of bits, so this should be fine. Also had to correct a wrong notifier check (was using `&` rather than `==`).
2020-08-07Cleanup: Rename soops to space_outlinerNathan Craddock
No functional changes. Rename soops, soutliner, and so to space_outliner.
2020-07-03Cleanup: Use C-style comments in outliner filesNathan Craddock
No functional changes. Convert all C++ style comments to C comments. Also capitalize and add full stops. The comments themselves were not cleaned up. Some could be removed or reworded.