Git Product home page Git Product logo

hodor's People

Contributors

aufree avatar ravirdv avatar

Stargazers

 avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar

Watchers

 avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar

hodor's Issues

使用Hodor的一个疑问

我的页面包含了侧滑抽屉,如果我多个页面都使用了国际化,难道得再切换后发个通知全部刷新一下UI么,这样是不是太复杂了。或者你有没有更好的办法

Help with implementing library

Hi, this is not an issue as I was able to edit your project and added new ViewController which worked well. However, after copying the Language.m(.h) files into my project and using kLang(), I am not able to load Chinese Strings (no text shows up if I select Chinese) and English shows when I select English though I have set them up in the Localisable.string for Simplified Chinese. I need help with this. Any pointers will be highly appreciated. Thanks

关于系统语言的获取

你好, 我觉得系统语言的获取不应该使用[[NSBundle mainBundle] preferredLocalizations],
而应该取[NSLocale preferredLanguages]中第0个, 再判断, 我只想到了用这种不严谨的判断方法:
NSString *firstLanguage = [NSLocale preferredLanguages].firstObject;
if ([firstLanguage hasPrefix:@"en"]) {
return 英语;
}
if ([firstLanguage hasPrefix:@"zh-Hans"] || //简体
[firstLanguage hasPrefix:@"yue-Hans"] //粤语简体
) {
return 中文简体;
}
if ([firstLanguage hasPrefix:@"zh-Hant"] || //繁体
[firstLanguage hasPrefix:@"zh-TW"] || //**
[firstLanguage hasPrefix:@"zh-HK"] || //香港
[firstLanguage hasPrefix:@"yue-Hant"] //粤语繁体
) {
return 中文繁体;
}
if ([firstLanguage hasPrefix:@"ja"]) {
return 日语;
}
if ([firstLanguage hasPrefix:@"ko"]) {
return 韩语;
}

return 其他;

使用宏重定义国际化方法的问题

使用系统的方法我们可以使用genstrings配合完成国际化的工作,使用宏重定义后该工具就不能使用了。对于这块的优化作者有没有啥想法或者实践啊?

Recommend Projects

  • React photo React

    A declarative, efficient, and flexible JavaScript library for building user interfaces.

  • Vue.js photo Vue.js

    🖖 Vue.js is a progressive, incrementally-adoptable JavaScript framework for building UI on the web.

  • Typescript photo Typescript

    TypeScript is a superset of JavaScript that compiles to clean JavaScript output.

  • TensorFlow photo TensorFlow

    An Open Source Machine Learning Framework for Everyone

  • Django photo Django

    The Web framework for perfectionists with deadlines.

  • D3 photo D3

    Bring data to life with SVG, Canvas and HTML. 📊📈🎉

Recommend Topics

  • javascript

    JavaScript (JS) is a lightweight interpreted programming language with first-class functions.

  • web

    Some thing interesting about web. New door for the world.

  • server

    A server is a program made to process requests and deliver data to clients.

  • Machine learning

    Machine learning is a way of modeling and interpreting data that allows a piece of software to respond intelligently.

  • Game

    Some thing interesting about game, make everyone happy.

Recommend Org

  • Facebook photo Facebook

    We are working to build community through open source technology. NB: members must have two-factor auth.

  • Microsoft photo Microsoft

    Open source projects and samples from Microsoft.

  • Google photo Google

    Google ❤️ Open Source for everyone.

  • D3 photo D3

    Data-Driven Documents codes.