Skip to main content

Documentation Index

Fetch the complete documentation index at: https://mintlify.com/SaadAhmed1122/Kids_learnig_App/llms.txt

Use this file to discover all available pages before exploring further.

The Kids Learning App follows a conventional Android Gradle project layout, with all application source code located under app/src/main/java/com/kidsapp/fiver1/. The package is deliberately flat at the top level for the main activities, with four sub-packages (db/, model/, helper/, layout/, view/, and gameactivities/) handling specialised concerns such as persistence, puzzle rendering, and game modes.

Directory Tree

Kids_learnig_App/
├── app/
│   ├── build.gradle          # App-level Gradle config
│   ├── proguard-rules.pro
│   └── src/main/
│       ├── AndroidManifest.xml
│       ├── java/com/kidsapp/fiver1/
│       │   ├── SplashScreen.java        # Entry point / launcher
│       │   ├── Select_act.java          # Mode picker (Learning vs Games)
│       │   ├── FinalmainScreen.java     # Learning hub
│       │   ├── Animals_question.java    # Animal quiz
│       │   ├── Colours_question_act.java
│       │   ├── FoodActivity.java
│       │   ├── NumbersAct.java
│       │   ├── EmoQuestionsActivity.java
│       │   ├── TravelAct.java
│       │   ├── Vehicals_Act.java
│       │   ├── ScoringPage.java
│       │   ├── Sequencegame.java
│       │   ├── Puzzlemainscreen.java
│       │   ├── Puzzlestart.java
│       │   ├── Show_ImagesMain.java
│       │   ├── AddImge.java
│       │   ├── GameMainAct.java
│       │   ├── GameLoader.java
│       │   ├── AdsClass.java
│       │   ├── db/
│       │   │   ├── MemoryContract.java
│       │   │   ├── MemoryDbHelper.java
│       │   │   └── MemoriesAdapter.java
│       │   ├── model/
│       │   │   └── Memory.java
│       │   ├── helper/
│       │   │   ├── DataHelper.java
│       │   │   ├── Block.java
│       │   │   └── BitmapUtil.java
│       │   ├── layout/
│       │   │   └── PuzzleLayout.java
│       │   ├── view/
│       │   │   └── PuzzleView.java
│       │   └── gameactivities/
│       │       ├── Action.java
│       │       ├── Cards.java
│       │       ├── Classic.java
│       │       ├── Racing.java
│       │       └── Contact.java
│       └── res/
│           ├── drawable/   # Quiz images (b0-b9 animals, c0-c9 food, etc.)
│           ├── layout/     # XML layouts
│           ├── raw/        # background_music.mp3
│           └── anim/       # zoom_in, zoom1-5 animations
└── build.gradle             # Project-level Gradle

Key Packages

The model/ package contains a single class:
  • Memory.java — A plain Java object (POJO) representing one gallery entry. It holds the image encoded as a Base64 string (images are resized to 250 × 250 px via BitmapUtil before encoding) along with any associated metadata. This model is serialised to/from the SQLite database through MemoryDbHelper and surfaced in the UI by MemoriesAdapter.
The helper/ package provides shared utilities used by the puzzle feature:
  • DataHelper.java — Manages the puzzle tile data structure. Implements the core tile-swap algorithm: tiles are represented as an ordered list of Block objects; DataHelper handles shuffling (with solvability checking) and validates move legality before committing a swap.
  • Block.java — A lightweight value object representing a single puzzle tile. Stores the tile’s current position index and its correct (solved) position, allowing DataHelper to detect when the puzzle is complete.
  • BitmapUtil.java — Utility methods for bitmap manipulation: resizing images to the target dimensions (250 × 250 px for gallery storage) and converting between Bitmap and Base64 String for SQLite persistence.
These two packages together implement the custom puzzle UI:
  • PuzzleLayout.java (layout/) — A custom ViewGroup that arranges PuzzleView children in a grid. It overrides onMeasure and onLayout to size and position each tile without relying on standard layout managers, giving precise control over tile boundaries.
  • PuzzleView.java (view/) — A custom View that renders a single puzzle tile. It draws the appropriate cropped region of the source bitmap using Canvas and handles touch events, forwarding valid swipe gestures to DataHelper for processing.
The gameactivities/ package contains the Activity subclasses loaded by GameLoader when a child selects a game category in GameMainAct:
  • Action.java — Hosts the Action-category WebView, loading an action game URL into a full-screen WebView with JavaScript enabled.
  • Cards.java — Hosts card-based games (e.g., memory card flip) in a dedicated WebView activity.
  • Classic.java — Hosts classic mini-games such as simple platformers or arcade titles via WebView.
  • Racing.java — Hosts racing games in a WebView with landscape orientation locked.
  • Contact.java — A lightweight screen providing developer contact information and app version details, accessible from within the game hub.

Drawable Naming Conventions

All quiz and answer images in res/drawable/ follow a strict prefix-and-index naming scheme. Understanding this convention is essential when adding new quiz content or debugging missing image errors.
PrefixContent
b0b9Animal question images
a0a24Animal answer images
c0c9Food question/answer images
d0d19Answer distractor images
e0e9Emotion question images
h0h22Colours & shapes images
m0m9Number answer images
n0n9Number question images
o0o9Object answer images
p0p2Person images
q0q9Things / vehicles question images
s0s9Transport answer images
t0t9Transport question images
w0w16Wildlife / world answer images

Activity Flow

The diagram below summarises the primary navigation paths through the app:
SplashScreen (launcher)
    └── Select_act (mode picker)
            ├── FinalmainScreen (learning hub)
            │       ├── Animals_question
            │       ├── Colours_question_act
            │       ├── FoodActivity
            │       ├── NumbersAct
            │       ├── EmoQuestionsActivity
            │       ├── TravelAct
            │       ├── Vehicals_Act
            │       │       └── ScoringPage (shared results screen)
            │       └── Sequencegame → ScoringPage
            ├── Puzzlemainscreen → Puzzlestart
            ├── Show_ImagesMain ↔ AddImge
            └── GameMainAct → GameLoader
                    └── gameactivities/ (Action, Cards, Classic, Racing)

Build docs developers (and LLMs) love