The registration screen is where new employees create their ThunderRAR account before they can log in. It is implemented byDocumentation Index
Fetch the complete documentation index at: https://mintlify.com/Viruz7w7/thunderRAR/llms.txt
Use this file to discover all available pages before exploring further.
activity_registro and reached by pressing the REGISTRARSE button on the login screen. After a successful registration the screen passes the chosen username and password back to MainActivity as Intent extras, which MainActivity then stores in memory and uses for credential validation during login.
UI Elements
The registration screen uses aConstraintLayout with the same background image as the login screen (fondo_pantalla_inico). All interactive elements are grouped inside a centred LinearLayout:
| Element | ID / Type | Description |
|---|---|---|
| Title label | textView6 / TextView | Displays the string Registrarse in white at 50 sp. |
| Username field | reg_usuario / EditText | Accepts free text (inputType="text"). Minimum height 48 dp. Placeholder hint: USUARIO. White underline indicator. |
| Password field | reg_password / EditText | Accepts secret input (inputType="textPassword"). Minimum height 48 dp. Placeholder hint: CONTRASEÑA. White underline indicator. |
| REGISTRARSE button | button3 / Button | Blue background (#0029FF), white text at 18 sp. Triggers enviar(View) on click. |
Registration Logic
When the employee taps REGISTRARSE, theenviar(View) method runs the following steps:
Validate non-empty input
If either field is empty, a Toast prompts the user to fill both fields and the method returns early without creating an account.
activity_registro.java
Intent Extras
The credentials are delivered toMainActivity via the following Intent extras:
| Key | Value | Description |
|---|---|---|
"dato" | Username string | The employee username entered in reg_usuario. Retrieved in MainActivity via getIntent().getStringExtra("dato"). |
"dato2" | Password string | The employee password entered in reg_password. Retrieved in MainActivity via getIntent().getStringExtra("dato2"). |
MainActivity.onCreate() reads both extras immediately:
MainActivity.java
inicioSesion(View) to validate login attempts.
Credentials passed via Intent extras are held in memory for the lifetime of the
MainActivity instance. If the activity is destroyed — for example by the user pressing the back button, closing the app, or the system reclaiming memory — the stored credentials are lost and the employee must register again on the next launch.