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-02-11File headers: SPDX License migrationCampbell Barton
Use a shorter/simpler license convention, stops the header taking so much space. Follow the SPDX license specification: https://spdx.org/licenses - C/C++/objc/objc++ - Python - Shell Scripts - CMake, GNUmakefile While most of the source tree has been included - `./extern/` was left out. - `./intern/cycles` & `./intern/atomic` are also excluded because they use different header conventions. doc/license/SPDX-license-identifiers.txt has been added to list SPDX all used identifiers. See P2788 for the script that automated these edits. Reviewed By: brecht, mont29, sergey Ref D14069
2021-11-30Cleanup: capitalize NOTE tagCampbell Barton
2021-11-01Fix compile error on WindowsJulian Eisel
Caused by 7150f919d3ca. This undid part of 79a88b5e919d. Added a comment for why this include is needed, to avoid this error from happening again.
2021-10-25Tests: assets, add BKE callback init/finalize to test setup/teardownSybren A. Stüvel
Add calls to `BKE_callback_global_init()` and `BKE_callback_global_finalize()` to ensure unit tests mimick Blender (and don't trip the assertions added in rBbeea601e7253). No functional changes to Blender.
2021-10-22Asset Catalogs: support reloading without losing local changesSybren A. Stüvel
Keep track of unsaved asset catalog changes, in a more granular way than just one boolean per asset library. Individual catalogs can now be marked with a flag `has_unsaved_changes`. This is taken into account when reloading data from the catalog definition file (CDF): - New catalog in CDF: gets loaded - Already-known catalog in CDF: - local unsaved changes: on-disk catalog is ignored - otherwise: on-disk catalog replaces in-memory one - Already-known catalog that does not exist in CDF: - local unsaved changes: catalog is kept around - otherwise: catalog is deleted. Because this saving-is-also-loading behaviour, the "has unsaved changes" flags are all stored in the undo buffer; undoing after saving will not change the CDF, but at least it'll undo the loading from disk, and it'll re-mark any changes as "not saved". Reviewed By: Severin Differential Revision: https://developer.blender.org/D12967
2021-10-19Asset Browser: Improved workflow for asset catalog savingSybren A. Stüvel
No longer save asset catalogs on blendfile save. Instead: - extend the confirmation prompt for unsaved changes to show unsaved catalogs. - In the confirmation prompt, make catalog saving explicit & optional, just like we do it for external images. {F10881736} - In the Asset Browser catalog tree, show an operator icon to save the catalogs to disk. It's grayed out if there are no changes to save, or if the .blend wasn't saved yet (required to know where to save the catalog definitions to). {F10881743} Much of the work was done by @Severin and reviewed by me, then we swapped roles. Reviewed By: Severin Differential Revision: https://developer.blender.org/D12796
2021-10-19Fix compilation error about undefined `PATH_MAX`Sybren A. Stüvel
2021-10-19Asset Library Service: make insensitive to trailing slashesSybren A. Stüvel
Make `AssetLibraryService::get_asset_library_on_disk(path)` insensitive to trailing slashes; i.e. `get_asset_library_on_disk("/path")` and `get_asset_library_on_disk("/path/¨)` will now return the same `AssetLibrary*`.
2021-10-18Fix failing `AssetLibraryService` test by removing test codeSybren A. Stüvel
Remove the code I had hoped to fix in rB3edae09e, the fix was unreliable. No functional changes to Blender.
2021-10-18Asset Library Service: fix failing unit testSybren A. Stüvel
On GCC in release mode (and maybe also debug mode without ASAN enabled), allocating an `AssetLibraryService` will reuse the space that should have just been freed. This made a test fail, as it was testing that new memory was allocated and not some old instance reused. To ensure that the calls that should allocate a new block of memory return a unique pointer, I added some dummy allocation to the test. No functional changes to Blender
2021-10-18Assets: add global `bke::AssetLibraryService` classSybren A. Stüvel
Add `blender::bke::AssetLibraryService` class that acts like a blendfile-scoped singleton. It's allocated upon the first call to `BKE_asset_library_load` and destroyed in the LOAD-PRE handler. The `AssetLibraryService` ensures that edits to asset catalogs are not lost when the asset browser editor closes (or even reloads). Instead, the `AssetLibrary` pointers it owns are kept around as long as the blend file is open. Reviewed By: Severin Maniphest Tasks: T92151 Differential Revision: https://developer.blender.org/D12885