Files
react-native/packages/react-native/ReactAndroid
Joe VilchesandFacebook GitHub Bot 144f44f653 Reorder the contents in ReactAccessibilityDelegate.java to be more logical (#49735)
Summary:
Pull Request resolved: https://github.com/facebook/react-native/pull/49735

I always get confused when I open this file. One of the main reasons is the order of contents is quite random, so I decided to reorder things. I tried to find a style guide on this but the [google ones](https://google.github.io/styleguide/javaguide.html#s3.4.2-ordering-class-contents) really just say do something that is logical so...

In general what I did was

* All instance variables, class variables, class constants, etc. are at the top of the class
* The constructor, `setDelegate`, `resetDelegate` methods are at the top of the class since these all deal with creating or destroying instances of this class
* Nested enums towards the bottom of the class so they are not in the way of people trying to reason about the methods and other contents (they are quite long)
* Delete random extra spaces / unneeded comments
* Move some private methods to be closer to the public methods that call them

Changelog: [Internal]

Reviewed By: mlord93

Differential Revision: D70345882

fbshipit-source-id: a8425c7b90c5d4fbea5ee5daa3c4ff9f7f189ce5
2025-02-27 15:38:15 -08:00
..

Building React Native for Android

See the Building from Source guide on the React Native website.

Running tests

When you submit a pull request, ci will automatically run all tests. To run tests locally, see Testing guide on the React Native website.