Created Code style (markdown)
parent
5e433ed3a5
commit
deabe60058
|
@ -0,0 +1,13 @@
|
|||
---
|
||||
|
||||
This wiki contains the developer documentation for AntennaPod. If you are a user and you are looking for help, have a look at our [website](https://antennapod.org/faq)!
|
||||
|
||||
---
|
||||
|
||||
### Code style
|
||||
|
||||
For the Java code, AntennaPod uses a style similar to [Google's Java style](https://google.github.io/styleguide/javaguide.html). You can find a Checkstyle configuration [here](https://github.com/AntennaPod/AntennaPod/blob/develop/config/checkstyle/checkstyle-new-code.xml). Checkstyle is run automatically when creating a pull request.
|
||||
|
||||
### Resource ID naming
|
||||
|
||||
Please use lowerCamelCase for naming `@+id` resources. For `TextViews` and `ImageViews`, just describing the element is enough (`title`, `background`). For `ViewGroups` like `LinearLayouts`, describing is usually enough, too: `playbackControls`. Buttons should always have the suffix `Button` (`viewDetailsButton`, `playButton`) and floating action buttons (fab) the suffix `Fab` (`addFeedFab`). In rare cases where it is really clear what the id is referring to, it may also be named after the type of the element (`recyclerView`).
|
Loading…
Reference in New Issue