[英]Flutter: WeChat Assets Picker. Change language to English
I am using flutter wechat_assets_picker , but the language in select picture/camera screen is in Chinese: enter image description here我正在使用flutter wechat_assets_picker ,但是选择图片/相机屏幕中的语言是中文:在此处输入图像描述
Is there anyway to change the language to English?有没有办法把语言改成英文? Thank you
谢谢
you have to just pass EnglishTextDelegate to textDelegate argument您只需将 EnglishTextDelegate 传递给 textDelegate 参数
selectedImages = await AssetPicker.pickAssets(context,textDelegate:EnglishTextDelegate() ); selectedImages = 等待 AssetPicker.pickAssets(context,textDelegate:EnglishTextDelegate());
The plugin now supports determining which language (if the language is supported) to use by lookup the Locale
through the widget tree.该插件现在支持通过在小部件树中查找
Locale
来确定使用哪种语言(如果支持该语言)。 In summary:总之:
Locale
specified in the WidgetsApp
), the picker will do its own to choose the matching locale.WidgetsApp
中指定的Locale
)支持本地化,则选择器将自行选择匹配的语言环境。AssetPickerTextDelegate
, then pass through the AssetPickerConfig.textDelegate
when calling the picker.AssetPickerTextDelegate
自定义您自己的语言,然后在调用选择器时通过AssetPickerConfig.textDelegate
传递。
声明:本站的技术帖子网页,遵循CC BY-SA 4.0协议,如果您需要转载,请注明本站网址或者原文地址。任何问题请咨询:yoyou2525@163.com.