diff options
author | Campbell Barton <ideasman42@gmail.com> | 2010-08-05 05:46:34 +0400 |
---|---|---|
committer | Campbell Barton <ideasman42@gmail.com> | 2010-08-05 05:46:34 +0400 |
commit | db5a5c131cc9d379c74c1b9afd116d61af87feb7 (patch) | |
tree | 38eeb697b6e0ba931f502ccb6bfa224795b4a0c2 | |
parent | 5453e2c2fe7f9413100775d8c607d9e8e004b1f7 (diff) |
patch [#23185] Mark All in Text Editor always reports "Text not found" when wrap is off
-rw-r--r-- | source/blender/editors/space_text/text_ops.c | 4 |
1 files changed, 3 insertions, 1 deletions
diff --git a/source/blender/editors/space_text/text_ops.c b/source/blender/editors/space_text/text_ops.c index ead25615b4e..efdb1638558 100644 --- a/source/blender/editors/space_text/text_ops.c +++ b/source/blender/editors/space_text/text_ops.c @@ -2366,6 +2366,7 @@ static int find_and_replace(bContext *C, wmOperator *op, short mode) SpaceText *st= CTX_wm_space_text(C); Text *start= NULL, *text= st->text; int flags, first= 1; + int found = 0; char *tmp; if(!st->findstr[0] || (mode == TEXT_REPLACE && !st->replacestr[0])) @@ -2431,9 +2432,10 @@ static int find_and_replace(bContext *C, wmOperator *op, short mode) first= 1; } else { - BKE_reportf(op->reports, RPT_ERROR, "Text not found: %s", st->findstr); + if(!found) BKE_reportf(op->reports, RPT_ERROR, "Text not found: %s", st->findstr); break; } + found = 1; } while(mode==TEXT_MARK_ALL); return OPERATOR_FINISHED; |