[Bf-blender-cvs] [eed1beff88a] master: UI: Using Consistent Font Icon in File Browser

Harley Acheson noreply at git.blender.org
Thu Mar 5 22:24:52 CET 2020


Commit: eed1beff88afbf84d37aa2ceef62501ec3888bed
Author: Harley Acheson
Date:   Thu Mar 5 13:23:28 2020 -0800
Branches: master
https://developer.blender.org/rBeed1beff88afbf84d37aa2ceef62501ec3888bed

UI: Using Consistent Font Icon in File Browser

Use only one font icon in File Browser for all platforms. Correct mistake to allow this icon to be used.

Differential Revision: https://developer.blender.org/D7037

Reviewed by Brecht Van Lommel

===================================================================

M	source/blender/editors/space_file/file_draw.c
M	source/blender/editors/space_file/fsmenu.c

===================================================================

diff --git a/source/blender/editors/space_file/file_draw.c b/source/blender/editors/space_file/file_draw.c
index 1739c15cbc6..db29d058e49 100644
--- a/source/blender/editors/space_file/file_draw.c
+++ b/source/blender/editors/space_file/file_draw.c
@@ -313,7 +313,7 @@ static void file_draw_preview(uiBlock *block,
   GPU_blend_set_func_separate(
       GPU_SRC_ALPHA, GPU_ONE_MINUS_SRC_ALPHA, GPU_ONE, GPU_ONE_MINUS_SRC_ALPHA);
 
-  if (icon && (icon != ICON_FILE_FONT)) {
+  if (icon && !(typeflags & FILE_TYPE_FTFONT)) {
     /* size of center icon is scaled to fit container and UI scale */
     float icon_x, icon_y;
 
diff --git a/source/blender/editors/space_file/fsmenu.c b/source/blender/editors/space_file/fsmenu.c
index af3ad0c354d..939235fc59a 100644
--- a/source/blender/editors/space_file/fsmenu.c
+++ b/source/blender/editors/space_file/fsmenu.c
@@ -739,7 +739,7 @@ void fsmenu_read_system(struct FSMenu *fsmenu, int read_bookmarks)
                                 FS_CATEGORY_SYSTEM_BOOKMARKS,
                                 &FOLDERID_Fonts,
                                 IFACE_("Fonts"),
-                                ICON_FONTPREVIEW,
+                                ICON_FILE_FONT,
                                 FS_INSERT_LAST);
 
       /* These items are just put in path cache for thumbnail views and if bookmarked. */



More information about the Bf-blender-cvs mailing list