Blender Git Commit Log

Git Commits -> Revision 6f87489

Revision 6f87489 by Julian Eisel (outliner-cpp-refactor)
November 6, 2020, 21:55 (GMT)
UI Code Quality: General refactor of Outliner View Layer display mode creation

* Turn functions into member functions (makes API for a type more obvious &
local, allows implicitly sharing data through member variables, enables order
independend definition of functions, allows more natural language for
function names because of the obvious context).
* Move important variables to classes rather than passing around all the time
(shorter, more task-focused code, localizes important data names).
* Add helper class for adding object children sub-trees (smaller, more focused
units are easier to reason about, have higher coherence, better testability,
can manage own resources easily with RAII).
* Use C++ iterators over C-macros (arguably more readable, less macros is
generally preferred)
* Add doxygen groups (visually emphasizes the coherence of code sections,
provide place for higher level comments on sections).
* Prefer references over pointers for passing by reference (makes clear that
NULL is not a valid value and that the current scope is not the owner).

Commit Details:

Full Hash: 6f87489536eb5a75dbed9968b889745ae023b14d
Parent Commit: cf94571
Lines Changed: +231, -158

4 Modified Paths:

/source/blender/editors/space_outliner/outliner_tree.c (+2, -1) (Diff)
/source/blender/editors/space_outliner/tree/tree_view.cc (+2, -2) (Diff)
/source/blender/editors/space_outliner/tree/tree_view.hh (+27, -3) (Diff)
/source/blender/editors/space_outliner/tree/tree_view_view_layer.cc (+200, -152) (Diff)
By: Miika HämäläinenLast update: Nov-07-2014 14:18MiikaHweb | 2003-2021