Giter Club home page Giter Club logo

utils-android's Introduction

Hi there 👋

I'm an engineer:

  • 🔭 I’m currently working on my Apps:
    • LeafNote: A private Markdown and note App for Android. You can try it on GooglePlay Store or CoolAPK.
    • AnySecret: A password and privacy manager App for iPhone (more platforms will be supported latter). You can try it on Apple Store.
    • One Habit: Habit, Pomodoro and Check-in, An App helps you cultivate a good habit.
    • 英语汪: An app to help Chinese learn english. It could translate words and sentences.
  • 🌱 I’m currently learning iOS development.
  • 📱 My open suorce Apps:
    • MarkNote: An open source markdown note-taking application for Android.
    • OmniList: An open source TODO App for Android.

utils-android's People

Contributors

shouheng88 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

utils-android's Issues

bug

me.shouheng.utils.ui.BarUtils#setNavBarLightMode(android.app.Activity, boolean)

bug

方法错误,返回值没有!!

fun View.toBitmap() { ImageUtils.view2Bitmap(this) }

TODO

        (binding.vp.getChildAt(0) as? RecyclerView)?.overScrollMode = RecyclerView.OVER_SCROLL_NEVER

add a convinent method for ViewPager2 to set overScrollMode

需求池

  1. SPUtils getInstance 方法重命名为 get,getInstance 太长
  2. LogUtils 类重命名为 L,LogUtils 太长
  3. 应用前后台切换的监听
  4. 动画工具类修改名称
  5. 权限工具类增加自定义权限名称的接口

新增需求

  • 平板检测相关的逻辑添加到 utils
  • let 等的增强版本 letOrElse 便捷方法

代码缩进等相关的快捷方法

SpannableString(binding.tvLog.text).apply {
    setSpan(UnderlineSpan(), 0, binding.tvLog.text.length, 0)
}

快捷方法调整

/Users/shouhwang/.gradle/caches/modules-2/files-2.1/com.github.Shouheng88/utils-ktx/2.8.7/3d16a937b3877b2a49b6d05a9c49cb4667b181fa/utils-ktx-2.8.7-sources.jar!/me/shouheng/utils/ktx/StringKtx.kt:67

fun String.safeToInt(str: String, def: Int = 0): Int = try { str.toInt() } catch (e: NumberFormatException) { def }

fun String.safeToLong(str: String, def: Long = 0): Long = try { str.toLong() } catch (e: NumberFormatException) { def }

fun String.safeToFloat(str: String, def: Float = 0f): Float = try { str.toFloat() } catch (e: NumberFormatException) { def }

fun String.safeToDouble(str: String, def: Double = .0): Double = try { str.toDouble() } catch (e: NumberFormatException) { def }

写错了,应该用 this 就行

activity utils

activity 启动动画

增加 noanimation 使用


            activity.overridePendingTransition(0, 0)

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.