原文链接:http://stackoverflow.com/questions/18725396/onconfigurationchange-not-called-after-changing-locale
在Fragment依附的Activity的manifest android:configChange="" 不能只加locale (android:configChange="locale"),还需要加上layoutDirection(android:configChange="layoutDirection|locale")。具体原因猜测应该是某些语言下是需要RTL(Right to Left),所以必须加上layoutDirection 才能触发Fragment中的onConfigurationChanged()方法的回调。。。
在Android开发中,当应用的语言设置更改时,理解如何正确地配置`android:configChange`属性以触发Fragment的`onConfigurationChanged()`方法回调至关重要。本文详细解释了为何在设置`locale`时还需加入`layoutDirection`参数,以及其背后的原理。

被折叠的 条评论
为什么被折叠?



