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
diff options
context:
space:
mode:
authorHarley Acheson <harley.acheson@gmail.com>2019-09-10 18:07:39 +0300
committerHarley Acheson <harley.acheson@gmail.com>2019-09-10 18:07:39 +0300
commit8f55794c0e803ec5454febe2e45651c721f62c8f (patch)
treed72ee691ad669096d7f86e498560631cccadb515 /source/blender/editors/interface/resources.c
parenta3e7440cfdd2f307e5c57922fd22e8770f0b8390 (diff)
UI: File Browser Custom Folder Color
Allows file browser folders to be shown in a theme-selectable color, default of manila. Differential Revision: https://developer.blender.org/D5713 Reviewed by Brecht Van Lommel
Diffstat (limited to 'source/blender/editors/interface/resources.c')
-rw-r--r--source/blender/editors/interface/resources.c8
1 files changed, 6 insertions, 2 deletions
diff --git a/source/blender/editors/interface/resources.c b/source/blender/editors/interface/resources.c
index 7c5d5401d08..ae161f1017c 100644
--- a/source/blender/editors/interface/resources.c
+++ b/source/blender/editors/interface/resources.c
@@ -905,6 +905,9 @@ const uchar *UI_ThemeGetColorPtr(bTheme *btheme, int spacetype, int colorid)
case TH_ICON_SHADING:
cp = btheme->tui.icon_shading;
break;
+ case TH_ICON_FOLDER:
+ cp = btheme->tui.icon_folder;
+ break;
case TH_ICON_FUND: {
/* Development fund icon color is not part of theme. */
static const uchar red[4] = {204, 48, 72, 255};
@@ -1391,8 +1394,9 @@ bool UI_GetIconThemeColor4ubv(int colorid, uchar col[4])
/* Always color development fund icon. */
}
else if (!((theme_spacetype == SPACE_OUTLINER && theme_regionid == RGN_TYPE_WINDOW) ||
- (theme_spacetype == SPACE_PROPERTIES && theme_regionid == RGN_TYPE_NAV_BAR))) {
- /* Only colored icons in outliner and popups, overall UI is intended
+ (theme_spacetype == SPACE_PROPERTIES && theme_regionid == RGN_TYPE_NAV_BAR) ||
+ (theme_spacetype == SPACE_FILE && theme_regionid == RGN_TYPE_WINDOW))) {
+ /* Only colored icons in specific places, overall UI is intended
* to stay monochrome and out of the way except a few places where it
* is important to communicate different data types. */
return false;