]> git.sesse.net Git - nageru/commit - nageru/theme.cpp
Add disable_if_always_disabled() to Block objects.
authorSteinar H. Gunderson <sgunderson@bigfoot.com>
Sat, 22 Jun 2019 13:16:14 +0000 (15:16 +0200)
committerSteinar H. Gunderson <sgunderson@bigfoot.com>
Sat, 22 Jun 2019 13:16:14 +0000 (15:16 +0200)
commit87ca88abe461522ff7386ee179a87a2ba2f5012c
tree1a92fe3fb7e956ddb8b3ac5fa554212fff492417
parent87509c3d91b3726ba3186cb92c44db2e8fb50a40
Add disable_if_always_disabled() to Block objects.

This allows the theme to specify that a given effect only makes sense
if another effect is enabled; e.g. a crop that only makes sense if
immediately followed by a resize. This can cut down the number of
instantiations in some cases.

Also change so that 0 is no longer always the canonical choice;
if disabling a block is a possibility, that is. In situations with
things disabling each other transitively, this could reduce the
number of instantiations further.
nageru/scene.cpp
nageru/scene.h
nageru/theme.cpp