forked from fanruan/design
Browse Source
Merge in DESIGN/design from ~FANGLEI/design10.0:feature/x to feature/x * commit '90f2d40f8baef58f5e06396b72e356735fd236ce': REPORT-60538 改用LocaleCenter国际化接口 REPORT-60538 英日韩环境未屏蔽在线组件库feature/x
fanglei
3 years ago
2 changed files with 36 additions and 1 deletions
@ -0,0 +1,26 @@
|
||||
package com.fr.design.locale.impl; |
||||
|
||||
import com.fr.general.GeneralContext; |
||||
import com.fr.general.locale.LocaleMark; |
||||
|
||||
import java.util.HashMap; |
||||
import java.util.Locale; |
||||
import java.util.Map; |
||||
|
||||
public class ShowOnlineWidgetMark implements LocaleMark<Boolean> { |
||||
private Map<Locale, Boolean> map = new HashMap<>(); |
||||
|
||||
public ShowOnlineWidgetMark() { |
||||
map.put(Locale.CHINA, true); |
||||
map.put(Locale.TAIWAN, true); |
||||
map.put(Locale.US, false); |
||||
map.put(Locale.KOREA, false); |
||||
map.put(Locale.JAPAN, false); |
||||
} |
||||
|
||||
@Override |
||||
public Boolean getValue() { |
||||
Boolean result = map.get(GeneralContext.getLocale()); |
||||
return result == null ? false : result; |
||||
} |
||||
} |
Loading…
Reference in new issue