commit | 5d0c1419ced881ae3321b7c6e3f23bbcacde473a | [log] [tgz] |
---|---|---|
author | Marcin Wiacek <marcin@mwiacek.com> | Wed Jul 11 22:34:20 2018 |
committer | Commit Bot <commit-bot@chromium.org> | Wed Jul 11 22:34:20 2018 |
tree | 14dd7c2e0f0af301372eef83fd585cd6e12f5afd | |
parent | 0c4e06c2d21cc9a69f0a2a871a873b30c12b8fee [diff] |
@IntDef cleanup in browser/java/appmenu @IntDef/@StringDef annotation are preferred way for declaring set of String/int values: 1. they need less space in APK than enum, see https://developer.android.com/topic/performance/reduce-apk-size#remove-enums 2. they give more control over allowed values than "static final" values Main goal of patch is writing "static final" values, enum and some classes in one common @IntDef/@StringDef form: 1. with @IntDef/@StringDef first, @Retention second and related @interface third 2. with values inside @interface 3. with NUM_ENTRIES declaring number of entries if necessary 4. with comment about numbering from 0 without gaps when necessary 5. with @Retention(RetentionPolicy.SOURCE) 6. without "static final" in the @interface Additionally there are done some other trivial cleanups. Change-Id: Ie6b59c0f1a8ec6fe50d3177619f0768798f97508 Reviewed-on: https://chromium-review.googlesource.com/1128092 Commit-Queue: Marcin WiÄ…cek <marcin@mwiacek.com> Commit-Queue: Theresa <twellington@chromium.org> Reviewed-by: Theresa <twellington@chromium.org> Cr-Commit-Position: refs/heads/master@{#574382}
Chromium is an open-source browser project that aims to build a safer, faster, and more stable way for all users to experience the web.
The project's web site is https://www.chromium.org.
Documentation in the source is rooted in docs/README.md.
Learn how to Get Around the Chromium Source Code Directory Structure .