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 <julian@blender.org>2020-12-15 20:49:56 +0300
committerJulian Eisel <julian@blender.org>2020-12-15 20:56:26 +0300
commitffe63b0440cb55dee7a0ec3c383cce99167b47a1 (patch)
treeb761fbeacbab737311d5f1737087bb91aa78efe0
parentb24712a9ca6fa807660a02d6988269748daecdbf (diff)
Fix crash opening maximized File Browser from Asset Browser
If Preferences > Interface > Temporary Editors > File Browser is set to "Maximized Area", opening a File Browser from an Asset Browser would cause the new maximized editor to be an Asset Browser. Exiting it again would crash. This fixes the wrong behavior and the crash. There's still an issue with exiting the editor again, it stays a File Browser then and doesn't go back to being an Asset Browser. That's to be fixed separately.
-rw-r--r--source/blender/editors/screen/screen_edit.c1
-rw-r--r--source/blender/editors/space_file/filesel.c2
2 files changed, 2 insertions, 1 deletions
diff --git a/source/blender/editors/screen/screen_edit.c b/source/blender/editors/screen/screen_edit.c
index 6be2fb8004b..c3dcaefab79 100644
--- a/source/blender/editors/screen/screen_edit.c
+++ b/source/blender/editors/screen/screen_edit.c
@@ -1369,6 +1369,7 @@ ScrArea *ED_screen_state_toggle(bContext *C, wmWindow *win, ScrArea *area, const
newa->full = oldscreen;
ED_screen_change(C, screen);
+ ED_area_tag_refresh(newa);
}
/* XXX bad code: setscreen() ends with first area active. fullscreen render assumes this too */
diff --git a/source/blender/editors/space_file/filesel.c b/source/blender/editors/space_file/filesel.c
index cd27b7b5773..b919a30e6cd 100644
--- a/source/blender/editors/space_file/filesel.c
+++ b/source/blender/editors/space_file/filesel.c
@@ -490,7 +490,7 @@ void ED_fileselect_set_params_from_userdef(SpaceFile *sfile)
wmOperator *op = sfile->op;
UserDef_FileSpaceData *sfile_udata = &U.file_space_data;
- BLI_assert(sfile->browse_mode == FILE_BROWSE_MODE_FILES);
+ sfile->browse_mode = FILE_BROWSE_MODE_FILES;
FileSelectParams *params = fileselect_ensure_updated_file_params(sfile);
if (!op) {