Revert "UI: use correct singular and plural nouns in report messages"

Convention is to use (s) postfix for cases where there can be one or multiple,
so stay consistent with that.

This reverts commit 3e8276311e.
This commit is contained in:
2019-10-02 12:52:58 +02:00
parent a434b30667
commit 01c824ac88
7 changed files with 11 additions and 56 deletions

View File

@@ -267,11 +267,7 @@ void BKE_packedfile_pack_all(Main *bmain, ReportList *reports, bool verbose)
}
if (tot > 0) {
BKE_reportf(reports,
RPT_INFO,
tot == 1 ? "Packed %d file" :
"Packed %d files",
tot);
BKE_reportf(reports, RPT_INFO, "Packed %d file(s)", tot);
}
else if (verbose) {
BKE_report(reports, RPT_INFO, "No new files have been packed");

View File

@@ -2044,11 +2044,7 @@ static int edbm_edge_rotate_selected_exec(bContext *C, wmOperator *op)
}
if (tot_failed_all != 0) {
BKE_reportf(op->reports,
RPT_WARNING,
tot_failed_all == 1 ? "Unable to rotate %d edge" :
"Unable to rotate %d edges",
tot_failed_all);
BKE_reportf(op->reports, RPT_WARNING, "Unable to rotate %d edge(s)", tot_failed_all);
}
return OPERATOR_FINISHED;
@@ -3165,11 +3161,7 @@ static int edbm_remove_doubles_exec(bContext *C, wmOperator *op)
}
MEM_freeN(objects);
BKE_reportf(op->reports,
RPT_INFO,
count_multi == 1 ? "Removed %d vertex" :
"Removed %d vertices",
count_multi);
BKE_reportf(op->reports, RPT_INFO, "Removed %d vertice(s)", count_multi);
return OPERATOR_FINISHED;
}

View File

@@ -1581,11 +1581,7 @@ static int object_delete_exec(bContext *C, wmOperator *op)
}
CTX_DATA_END;
BKE_reportf(op->reports,
RPT_INFO,
changed_count == 1 ? "Deleted %u object" :
"Deleted %u objects",
changed_count);
BKE_reportf(op->reports, RPT_INFO, "Deleted %u object(s)", changed_count);
if (changed_count == 0) {
return OPERATOR_CANCELLED;

View File

@@ -3076,11 +3076,7 @@ static int remove_doubles_exec(bContext *C, wmOperator *op)
return OPERATOR_CANCELLED;
}
BKE_reportf(op->reports,
RPT_INFO,
totremoved == 1 ? "Removed %d double particle" :
"Removed %d double particles",
totremoved);
BKE_reportf(op->reports, RPT_INFO, "Removed %d double particle(s)", totremoved);
DEG_id_tag_update(&ob->id, ID_RECALC_GEOMETRY);
WM_event_add_notifier(C, NC_OBJECT | ND_PARTICLE | NA_EDITED, ob);

View File

@@ -2298,12 +2298,7 @@ static int image_save_sequence_exec(bContext *C, wmOperator *op)
/* get a filename for menu */
BLI_split_dir_part(first_ibuf->name, di, sizeof(di));
BKE_reportf(op->reports,
RPT_INFO,
tot == 1 ? "%d image will be saved in %s" :
"%d images will be saved in %s",
tot,
di);
BKE_reportf(op->reports, RPT_INFO, "%d image(s) will be saved in %s", tot, di);
iter = IMB_moviecacheIter_new(image->cache);
while (!IMB_moviecacheIter_done(iter)) {

View File

@@ -770,11 +770,7 @@ static int outliner_id_copy_exec(bContext *C, wmOperator *op)
BLI_make_file_string("/", str, BKE_tempdir_base(), "copybuffer.blend");
BKE_copybuffer_save(bmain, str, op->reports);
BKE_reportf(op->reports,
RPT_INFO,
num_ids == 1 ? "Copied %d selected data-block" :
"Copied %d selected data-blocks",
num_ids);
BKE_reportf(op->reports, RPT_INFO, "Copied %d selected data-block(s)", num_ids);
return OPERATOR_FINISHED;
}
@@ -808,11 +804,7 @@ static int outliner_id_paste_exec(bContext *C, wmOperator *op)
WM_event_add_notifier(C, NC_WINDOW, NULL);
BKE_reportf(op->reports,
RPT_INFO,
num_pasted == 1 ? "%d data-block pasted" :
"%d data-blocks pasted",
num_pasted);
BKE_reportf(op->reports, RPT_INFO, "%d data-block(s) pasted", num_pasted);
return OPERATOR_FINISHED;
}
@@ -2265,11 +2257,7 @@ static int outliner_orphans_purge_exec(bContext *C, wmOperator *op)
BKE_id_multi_tagged_delete(bmain);
BKE_reportf(op->reports,
RPT_INFO,
num_tagged[INDEX_ID_NULL] == 1 ? "Deleted %d data-block" :
"Deleted %d data-blocks",
num_tagged[INDEX_ID_NULL]);
BKE_reportf(op->reports, RPT_INFO, "Deleted %d data-block(s)", num_tagged[INDEX_ID_NULL]);
/* XXX: tree management normally happens from draw_outliner(), but when
* you're clicking to fast on Delete object from context menu in

View File

@@ -79,11 +79,7 @@ static int view3d_copybuffer_exec(bContext *C, wmOperator *op)
BLI_make_file_string("/", str, BKE_tempdir_base(), "copybuffer.blend");
BKE_copybuffer_save(bmain, str, op->reports);
BKE_reportf(op->reports,
RPT_INFO,
num_copied == 1 ? "Copied %d selected object" :
"Copied %d selected objects",
num_copied);
BKE_reportf(op->reports, RPT_INFO, "Copied %d selected object(s)", num_copied);
return OPERATOR_FINISHED;
}
@@ -122,11 +118,7 @@ static int view3d_pastebuffer_exec(bContext *C, wmOperator *op)
WM_event_add_notifier(C, NC_WINDOW, NULL);
BKE_reportf(op->reports,
RPT_INFO,
num_pasted == 1 ? "%d object pasted" :
"%d objects pasted",
num_pasted);
BKE_reportf(op->reports, RPT_INFO, "%d object(s) pasted", num_pasted);
return OPERATOR_FINISHED;
}