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:
authorJulian Eisel <eiseljulian@gmail.com>2019-12-10 19:01:53 +0300
committerJulian Eisel <eiseljulian@gmail.com>2019-12-10 19:09:08 +0300
commit4fa774b53346a1533c6c0c62ddbd220979adb6c2 (patch)
treecc41d10d60e0aec4908b9b590779a3ebd84d51d9 /source/blender
parentc5767a24b9eeb167995c425cc76597c103caf7db (diff)
Fix: Fullscreen File Browser showing override warning on file open
Steps to reproduce were: * Change File Browser display mode to fullscreen in Preferences * File > Save As (make sure existing .blend is selected) * File > Open The file name would still be shown in red and the + and - icons would be visible, which should only be the case for saving files, not opening. Note that this change makes all `FileSelectParams.flag` values be reset on re-opening a File Browser, which *may* in fact cause other issues. It's easy to fix those though, and I'd prefer properly resetting the flags and only keeping specific ones in that case.
Diffstat (limited to 'source/blender')
-rw-r--r--source/blender/editors/space_file/filesel.c5
1 files changed, 1 insertions, 4 deletions
diff --git a/source/blender/editors/space_file/filesel.c b/source/blender/editors/space_file/filesel.c
index f8adf9b707a..99e4fc62980 100644
--- a/source/blender/editors/space_file/filesel.c
+++ b/source/blender/editors/space_file/filesel.c
@@ -160,14 +160,11 @@ short ED_fileselect_set_params(SpaceFile *sfile)
BLI_path_abs(params->dir, blendfile_path);
}
+ params->flag = 0;
if (is_directory == true && is_filename == false && is_filepath == false &&
is_files == false) {
params->flag |= FILE_DIRSEL_ONLY;
}
- else {
- params->flag &= ~FILE_DIRSEL_ONLY;
- }
-
if ((prop = RNA_struct_find_property(op->ptr, "check_existing"))) {
params->flag |= RNA_property_boolean_get(op->ptr, prop) ? FILE_CHECK_EXISTING : 0;
}