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 Game Hub is the central screen of the Kids Learning App, surfacing a hand-picked library of HTML5 games inside a native Android WebView browser. When the app launches, GameMainAct checks for an active internet connection and routes the user to either the game catalogue or a dedicated offline screen, keeping the experience smooth regardless of network status.

How It Works

GameMainAct (layout: activity_game_main) acts as the shell. When a user taps a game thumbnail, the activity packages the game’s URL as an Intent extra and starts GameLoader, which renders the game inside a full-screen WebView.
String webAddress = getIntent().getStringExtra("WEB_PASSING");
web = (WebView) findViewById(R.id.web);
web.loadUrl(webAddress);
web.getSettings().setJavaScriptEnabled(true);
web.setWebViewClient(new WebViewClient());
WebViewClient ensures page navigations stay inside the app rather than launching an external browser. The back-button handler lets players navigate WebView history before exiting:
@Override
public void onBackPressed() {
    if (web.canGoBack()) {
        web.goBack();
    } else {
        super.onBackPressed();
    }
}
The INTERNET permission must be declared in AndroidManifest.xml for both AdMob and the game WebViews to function correctly.

Internet Connectivity Check

Before displaying the hub, GameMainAct uses ConnectivityManager to verify network availability. If the device is offline, the app immediately redirects to the No_internet Activity so players see a friendly message instead of a broken WebView.
ConnectivityManager cm =
    (ConnectivityManager) getSystemService(Context.CONNECTIVITY_SERVICE);
NetworkInfo activeNetwork = cm.getActiveNetworkInfo();
boolean isConnected = activeNetwork != null && activeNetwork.isConnectedOrConnecting();
if (!isConnected) {
    startActivity(new Intent(GameMainAct.this, No_internet.class));
    finish();
}
ACCESS_NETWORK_STATE permission is required for ConnectivityManager to read the current network state. Removing it will cause a SecurityException at runtime.

Most Played Games

The Most Played section features six ImageView tiles (mostplaygame1mostplaygame6). Each tile opens its game in GameLoader via a Famobi-hosted URL.
SlotGame
mostplaygame1Om Nom Run
mostplaygame2Diamond Rush
mostplaygame3Table Tennis World Tour
mostplaygame4Archery World Tour
mostplaygame53D Free Kick
mostplaygame68 Ball Billiards Classic
The Popular section presents five CardView tiles (popular1popular5) that highlight trending titles curated for kids.
SlotGame
popular1Bubble Tower 3D
popular2Tower Crash 3D
popular3Element Blocks
popular4Moto X3M Pool Party
popular5Gold Mine

Bottom Navigation

The bottom navigation bar provides quick access to the app’s three main destinations.

Home

Returns to the main GameMainAct screen displaying Most Played and Popular sections.

Category

Launches the Category Activity where players can browse games by genre (Racing, Action, Cards, Classic).

Contact

Opens the Contact Activity, allowing users to reach the developer at [email protected].

Bottom Sheet Options

Tapping the navigation sheet ImageView (btmnav) slides up a bottom sheet dialog with three quick actions.
Fires an Android ACTION_SEND share intent so players can recommend the app to friends and family via any installed sharing target (WhatsApp, Gmail, etc.).
Launches the Play Store listing using a market:// URI so users can leave a star rating without leaving the flow.
Opens the device email client pre-addressed to [email protected] so players or parents can send feedback directly.

First-Time Launch Tracking

GameMainAct uses SharedPreferences to detect whether this is the user’s first launch. This flag can be used to display an onboarding walkthrough or splash content on the initial open only.
Use the first-launch SharedPreferences flag to show permissions rationale or a welcome tutorial before the user dives into the game catalogue.

Build docs developers (and LLMs) love