Caliburn.Micro 约定中使用的复数混乱

发布于 2024-12-13 04:45:35 字数 381 浏览 6 评论 0原文

我在很多地方使用了 Caliburn.Micro 约定,即如果您有一个名为 Apples 的集合,则可以添加一个名为 SelectedApple 的属性,并且每当您在组合框中选择了名为 Apples 的内容。

这一切都很好。然而现在,我有一个不同类型状态的列表,但我无法让它发挥作用,也许是因为 Caliburn 和我不同意状态一词的正确复数形式。

我有一个名为 Statuses 的集合和一个名为 SelectedStatus 的属性。组合框填充了所有状态,但是当我在列表中选择其中之一时没有任何反应。

我已经尝试了 Statuses、Status、Stati,但均无济于事。

谁能明白为什么这不起作用?

I have used a Caliburn.Micro convention many places that says if you have a collection called Apples, you can add a property with the name SelectedApple, and this will be called whenever you select something in a ComboBox with the name Apples.

All of this is well. Now however, I have a list of different type of Statuses, but I cannot get this to work, maybe because Caliburn and I do not agree upon the proper plural form of the word status.

I have a collection called Statuses, and a property called SelectedStatus. The ComboBox is filled with all the statuses, but nothing happens when I select one of them in the list.

I have tried both Statuses, Status, Stati but to no avail.

Can anyone see why this isn't working?

如果你对这篇内容有疑问,欢迎到本站社区发帖提问 参与讨论,获取更多帮助,或者扫码二维码加入 Web 技术交流群。

扫码二维码加入Web技术交流群

发布评论

需要 登录 才能够评论, 你可以免费 注册 一个本站的账号。

评论(2

凝望流年 2024-12-20 04:45:35

我从未听说过 Caliburn.Micro,但我在网上找到了文档并决定搜索它。 答案就在那里

单数化 – 将单词从复数形式转换为单数形式。默认实现非常基本,只是去掉尾随的 's'。

I'd never heard of Caliburn.Micro, but I found the documentation online and decided to search it. And the answer is in there.

Singularize – Turns a word from its plural form to its singular form. The default implementation is really basic and just strips the trailing ‘s’.

━╋う一瞬間旳綻放 2024-12-20 04:45:35

我相信它需要一个名为 SelectedStatuse 的属性,因为它只是删除“Statuses”中尾随的“s”并在前面加上“Selected”一词。

I believe it's expecting a property called SelectedStatuse, since it is just lopping off the trailing 's' in 'Statuses' and prepending the word 'Selected.'

~没有更多了~
我们使用 Cookies 和其他技术来定制您的体验包括您的登录状态等。通过阅读我们的 隐私政策 了解更多相关信息。 单击 接受 或继续使用网站,即表示您同意使用 Cookies 和您的相关数据。
原文