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:
Diffstat (limited to 'source/blender/editors/space_buttons/buttons_ops.c')
-rw-r--r--source/blender/editors/space_buttons/buttons_ops.c6
1 files changed, 6 insertions, 0 deletions
diff --git a/source/blender/editors/space_buttons/buttons_ops.c b/source/blender/editors/space_buttons/buttons_ops.c
index b1a25d093d2..26516bcda99 100644
--- a/source/blender/editors/space_buttons/buttons_ops.c
+++ b/source/blender/editors/space_buttons/buttons_ops.c
@@ -43,6 +43,7 @@
#include "BKE_context.h"
#include "BKE_global.h"
#include "BKE_main.h"
+#include "BKE_report.h"
#include "WM_api.h"
#include "WM_types.h"
@@ -160,6 +161,11 @@ static int file_browse_invoke(bContext *C, wmOperator *op, wmEvent *event)
FileBrowseOp *fbo;
char *str;
+ if (CTX_wm_space_file(C)) {
+ BKE_report(op->reports, RPT_ERROR, "Can't activate a file selector, one already open");
+ return OPERATOR_CANCELLED;
+ }
+
uiFileBrowseContextProperty(C, &ptr, &prop);
if(!prop)