Giter Site home page Giter Site logo

pickerview's Introduction

PickerView

🌴自己动手丰衣足食

2023年5月17日 11:40:00 更新了app.assets下的province.json文件

【注】在使用地区选择器时, 如果后台给了地址接口, 建议参照app.assets下的province.json统一好格式。如果后台没有接口, 可使用 Idea打开项目https://github.com/javakam/GetDistricts, 执行GetDistricts.main方法即可下载最新的province.json 不过需要先申请高德Key(申请地址https://lbs.amap.com/api/webservice/guide/api/district/)

2. 引入

repositories {
    mavenCentral()
    maven { url "https://s01.oss.sonatype.org/content/groups/public" }
}
implementation 'com.github.javakam:widget.wheelview:1.3.0@aar'
implementation 'com.github.javakam:widget.pickerview:1.3.0@aar'

3. 修改内容

  • 支持 androidx
  • setPadding(l,t,r,b) 新增内容视图调整上下左右边距
  • setRangDate(startDate, endDate) 现支持"年,月,日,时,分,秒"的限定, 原版仅支持"年月日"
  • 关闭了默认的数字文本缩放效果: WheelView.initPaints -> paintCenterText.setTextScaleX(1.1F) -> 1.0F
  • 优化返回值显示, 如传入的 type 秒值为 false, 回来结果相应秒值为 00 -> WheelTime.getTime()
  • 更新了province.json(2023年5月17日 11:45:56), 并为此写了个Java小项目, 项目地址 👉 https://github.com/javakam/GetDistricts , Idea打开, 高德Key需要自己申请 👉 以下部分代码片段

全国行政区域信息(高德)

4. 获取全国行政区域信息(高德) 👉 https://lbs.amap.com/api/webservice/guide/api/district/

5. 使用说明

除了3修改内容外, 其它与原版完全一致。

Bigkoo/Android-PickerView原版说明文件 👉 README_ORIGIN.md

pickerview's People

Contributors

javakam avatar

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.