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-04-03Cleanup: Remove interface region files to C++Hans Goudey
Moves all `interface_region*` files to C++ except for the tooptip region which is slightly more complicated. Also move a few other files as well. This helps to simplify and speed up code, especially through the use of better C++ data structures. This change builds on all platforms on the buildbot.
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-12-08Cleanup: move public doc-strings into headers for 'editors'Campbell Barton
Ref T92709
2021-11-05Cleanup (UI): Add/use type for operator context enumJulian Eisel
Adds a `wmOperatorCallContext` typedef for the existing `WM_OP_XXX` operator context enum. This adds type safety, allows the compiler to produce better warnings and helps understanding what a variable is for. Differential Revision: https://developer.blender.org/D13113 Reviewed by: Campbell Barton
2021-10-20Cleanup: use an array for wmEvent cursor position variablesAaron Carlisle
Use arrays for wmEvent coordinates, this quiets warnings with GCC11. - `x, y` -> `xy`. - `prevx, prevy` -> `prev_xy`. - `prevclickx, prevclicky` -> `prev_click_xy`. There is still some cleanup such as using `copy_v2_v2_int()`, this can be done separately. Reviewed By: campbellbarton, Severin Ref D12901
2021-07-03Cleanup: consistent use of tags: NOTE/TODO/FIXME/XXXCampbell Barton
Also use doxy style function reference `#` prefix chars when referencing identifiers.
2021-06-30UI: custom free function improvementsJacques Lucke
This changes `UI_but_func_tooltip_set` so that it allows passing a custom free function, which has two benefits: * The caller can pass `null` to indicate that the value should not be freed. * Arbitrary c++ data can be passed to the callback (before the struct had to be trivially destructible). I added `uiFreeArgFunc` and used it in other places where appropriate. Differential Revision: https://developer.blender.org/D11738
2021-05-03Cleanup: spellingCampbell Barton
2021-04-30Cleanup: interface_intern.h doc-stringsCampbell Barton
Also clarify some vague comments & add doxygen section for menu-memory.
2021-02-14Cleanup: spellingCampbell Barton
2020-10-03Cleanup: Remove/replace C standard library assert() and header usagesJulian Eisel
We have our own assert implementation, `BLI_assert()` that is prefered over the C standard library one. Its output is more consistent across compilers and makes termination on assert failure optional (through `WITH_ASSERT_ABORT`). In many places we'd include the C library header without ever accessing it.
2020-09-30Cleanup: convert gforge task ID's to phabricator formatValentin
Cleanup old tracker task format to the new. e.g: [#34039] to T34039 Ref D8718
2020-08-19UI Code Quality: Use LISTBASE_FOREACH in interface directoryHans Goudey
I only skipped a few loops in the monstrous ui_handle_menu_event function. Also, I only changed variable names where necessary to prevent redeclarations. Differential Revision: https://developer.blender.org/D8586
2020-08-16Fix popups opening in the wrong direction over headersCampbell Barton
Checks for header alignment didn't account for tool-header & header having different alignment. There is no reason to use a lookup function on the area (ED_area_header_alignment) as we already have region. Check the regions alignment directly, remove access functions.
2020-07-03Cleanup: Interface, Clang-Tidy else-after-return fixesSybren A. Stüvel
This addresses warnings from Clang-Tidy's `readability-else-after-return` rule in the `source/blender/editors/interface` module. No functional changes.
2020-06-17UI: Improve Modifier Panel Header MenuHans Goudey
This makes a few changes to the modifier panel header: 1. Adds "move to top" and "move to bottom" buttons. 2. Adds a checkmark icon for "apply" 3. Makes it narrower, the text is closer to the dropdown icon. (Requires the change in ui_block_func_POPUP) Differential Revision: https://developer.blender.org/D8040
2020-05-07Cleanup: remove unused operator arguments to UI_popup_block_invoke_exCampbell Barton
Add optional can_refresh argument, useful to prevent text field from exiting on refresh.
2020-04-15Fix incorrect UI_SEP_CHAR checksCampbell Barton
- Menu drawing function used first instance instead of last. - Menu hash function checked for the character without first checking UI_BUT_HAS_SEP_CHAR was enabled.
2020-04-03Code Quality: Replace for loops with LISTBASE_FOREACHDalai Felinto
Note this only changes cases where the variable was declared inside the for loop. To handle it outside as well is a different challenge. Differential Revision: https://developer.blender.org/D7320
2020-04-03Cleanup: Rename ScrArea variables from sa to areaJulian Eisel
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.
2020-03-19Cleanup: `make format` after SortedIncludes changeDalai Felinto
2020-03-15Cleanup: use 'const' style argumentCampbell Barton
2020-03-06Cleanup: Rename ARegion variables from ar to regionJulian Eisel
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.
2020-03-06Cleanup: Reduce context usage in UI functionsJulian Eisel
Part of https://developer.blender.org/T74429. There's a chance that this causes some issues becaue in some cases we change from getting the window from context to getting it from somewhere else.
2020-01-16Fix wrong usages of region align enumerationsJulian Eisel
`ARegion.alignment` unfortunately is a mixture of value and bitflag enumerations. When checking for left/right/top/bottom region alignment, the flags have to be masked out usually. Most of the fixed cases here probably didn't cause issues in practice, but could in fact break at any point when surrounding logic changes. In fact the assert in #region_visible_rect_calc() failed in an older file from https://bugs.debian.org/cgi-bin/bugreport.cgi?bug=949035. This fixes it.
2019-09-20Fix T69097: Empty context menu for dimensionsCampbell Barton
Adjust empty menu check to skip the menu title.
2019-05-14Interface: Free argument callback for popupsJacques Lucke
Reviewers: brecht Differential Revision: https://developer.blender.org/D4858
2019-04-19UI: move top-bar into the spaces headerCampbell Barton
Currently this is only in the 3D viewport however all spaces that use the tool-system will have this region added. D4680 by @brecht with own updates.
2019-04-17ClangFormat: apply to source, most of internCampbell Barton
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
2019-04-05Interface: New region type 'Footer', used by text editorGeorge Vogiatzis
* It can be hidden by dragging it up/down. * It can be at the top or bottom, independent of the header. * It uses the color theme from the header. * It does not change its color, when the area becomes active. Currently, it is used in the text editor to display the file path. Differential Revision: https://developer.blender.org/D4601
2019-03-25Cleanup: use braces for interface codeCampbell Barton
2019-03-21UI: replace button open event with activate on initCampbell Barton
No user visible change.
2019-03-18Fix color ramp eyedropper menu itemCampbell Barton
This couldn't be accessed because the poll function was checking the active button. Add a "color_ramp" context pointer which is set by the menu. Alternative fix to D3984
2019-03-13Cleanup: rename uiBlock.mx,my to bounds_offsetCampbell Barton
Use a name that related to block bounds calculation (mx/my are typically used for mouse x,y).
2019-03-05Fix T62216: order of items flipped in some menus like object mode.Brecht Van Lommel
2019-03-05Fix upside down tool menusCampbell Barton
Regression from 4dd575e5ab55e153f8
2019-02-21UI: enum property menus now expand down, consistent with other menus.Mikhail Rachinskiy
Differential Revision: https://developer.blender.org/D4359
2019-02-18doxygen: add newline after \fileCampbell Barton
While \file doesn't need an argument, it can't have another doxy command after it.
2019-02-06Cleanup: remove redundant doxygen \file argumentCampbell Barton
Move \ingroup onto same line to be more compact and make it clear the file is in the group.
2019-02-01Cleanup: remove redundant, invalid info from headersCampbell Barton
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.
2019-01-15Cleanup: comment line length (editors)Campbell Barton
Prevents clang-format wrapping text before comments.
2019-01-04Fix T59946: multiple quit dialogs possible.Sebastian Parborg
Differential Revision: https://developer.blender.org/D4147
2018-09-11Merge branch 'master' into blender2.8Campbell Barton
2018-09-11UI: split theme draw style into separate fieldCampbell Barton
Was using UI_BLOCK_LOOP to control draw style, this meant we couldn't use popup theme colors for cases where it the interface has the same purpose as a popup but happens not to use this flag.
2018-06-23Merge branch 'master' into blender2.8Campbell Barton
2018-06-23UI: alternate fix for empty context menuCampbell Barton
block and layout could be NULL and checking this everywhere wasn't practical. Instead of lazy initializing, add UI_popup_menu_end_or_cancel which cancels empty popup menus.
2018-05-06Cleanup: deprecate area.headertype.Brecht Van Lommel
This was still used in a few places but not kept in sync with the actual header position. Always get alignment from the header region now.
2018-04-30Fix some popup menus that don't support it refreshing and crashing.Brecht Van Lommel
2018-04-25UI: use a wider minimum menu widthCampbell Barton
Icon only buttons with menus would be too narrow, especially buttons for selecting tools.
2018-04-23Cleanup: styleCampbell Barton