Merge branch 'blender-v4.0-release'
This commit is contained in:
@@ -970,15 +970,14 @@ static void setup_app_blend_file_data(bContext *C,
|
||||
|
||||
static void handle_subversion_warning(Main *main, BlendFileReadReport *reports)
|
||||
{
|
||||
if (main->minversionfile > BLENDER_FILE_VERSION ||
|
||||
(main->minversionfile == BLENDER_FILE_VERSION &&
|
||||
main->minsubversionfile > BLENDER_FILE_SUBVERSION))
|
||||
if (main->versionfile > BLENDER_FILE_VERSION || (main->versionfile == BLENDER_FILE_VERSION &&
|
||||
main->subversionfile > BLENDER_FILE_SUBVERSION))
|
||||
{
|
||||
BKE_reportf(reports->reports,
|
||||
RPT_WARNING,
|
||||
"File written by newer Blender binary (%d.%d), expect loss of data!",
|
||||
main->minversionfile,
|
||||
main->minsubversionfile);
|
||||
main->versionfile,
|
||||
main->subversionfile);
|
||||
}
|
||||
}
|
||||
|
||||
|
||||
@@ -2856,6 +2856,9 @@ static int wm_open_mainfile__open(bContext *C, wmOperator *op)
|
||||
RNA_string_get(op->ptr, "filepath", filepath);
|
||||
BLI_path_canonicalize_native(filepath, sizeof(filepath));
|
||||
|
||||
/* For file opening, also print in console for warnings, not only errors. */
|
||||
BKE_report_print_level_set(op->reports, RPT_WARNING);
|
||||
|
||||
/* re-use last loaded setting so we can reload a file without changing */
|
||||
wm_open_init_load_ui(op, false);
|
||||
wm_open_init_use_scripts(op, false);
|
||||
@@ -2864,9 +2867,6 @@ static int wm_open_mainfile__open(bContext *C, wmOperator *op)
|
||||
SET_FLAG_FROM_TEST(G.f, RNA_boolean_get(op->ptr, "use_scripts"), G_FLAG_SCRIPT_AUTOEXEC);
|
||||
success = wm_file_read_opwrap(C, filepath, op->reports);
|
||||
|
||||
/* for file open also popup for warnings, not only errors */
|
||||
BKE_report_print_level_set(op->reports, RPT_WARNING);
|
||||
|
||||
if (success) {
|
||||
if (G.fileflags & G_FILE_NO_UI) {
|
||||
ED_outliner_select_sync_from_all_tag(C);
|
||||
|
||||
Reference in New Issue
Block a user