An Android library for member secretGFX group, This can be used to growing your apps and get more install via a simple banner view & native view and interstitial dialog.

Overview

GFX-AdPromote

An Android library for member secretGFX group, This can be used to growing your apps and get more install via a simple banner view & native view and interstitial dialog.

Installation

Step 1. Add the JitPack repository to your project build.gradle file

allprojects {
    repositories {
        //your repository
        maven { url 'https://jitpack.io' }
    }
}

Step 2. Add the dependency in the form

dependencies {
    implementation 'com.github.saidmotya:GFX-AdPromote:1.0.0'
}

Initialize

In your Java code, you can initialize the library with two way : inside splash with param Activity and check if the lib is connected than start the normal activity Or in MyApplication extend Application with param Context, see the full code source for more details :

AppPromote.initializePromote(this,"Your link json her");
        AppPromote.setOnPromoteListener(new OnPromoteListener() {
            @Override
            public void onInitializeSuccessful() {
                //AppPromote onInitializeSuccessful
            }

            @Override
            public void onInitializeFailed(String error) {
                //AppPromote onInitializeFailed
            }
        });

How to use Banner Promote :

Place your banner promote in your xml layout like this:

">
 <com.gfx.adPromote.BannerPromote
        android:id="@+id/banner_view"
        android:layout_width="match_parent"
        android:layout_height="wrap_content"
        app:banner_bodyColor="#FFFFFF"
        app:banner_contentColor="#E41000"
        app:banner_installColor="#FF5722"
        app:banner_installTitle="Install"
        />

Banner Promote Custom Attributes

Attribute Description
banner_bodyColor Color of the banner body (by default is white)
banner_contentColor Color of the banner content : title and description (description by default color : gray)
banner_installColor Install button color : default is blue
banner_installTitle Title of button : default is "Install"

Banner Promote in Java code :

In your Java code, you can initialize your banner view and get listener, you can make the attributes of banner progrmatically or in xml layout :

 BannerPromote bannerPromote = findViewById(R.id.banner_view);
        //bannerPromote.setInstallTitle("Play"); //Banner title button
        //bannerPromote.setInstallColor("#FFC107"); //Title button color with param String or Resource color
        //bannerPromote.setDescriptionColor(R.color.my_color_description);//Description Text color with param String or Resource color
        bannerPromote.setOnBannerListener(new OnBannerListener() {
            @Override
            public void onBannerAdLoaded() {
                //banner loaded.
            }

            @Override
            public void onBannerAdClicked() {
                //banner clicked.
            }

            @Override
            public void onBannerAdFailedToLoad(String error) {
                //banner failed to load.

            }
        });

Banner Promote Example

Banner Promote Example

How to use Native promote :

Place your native promote in your xml layout like this:

">
 <com.gfx.adPromote.NativePromote
        android:id="@+id/native_ad"
        android:layout_width="match_parent"
        android:layout_height="wrap_content"
        app:native_installColor="#4CAF50"
        app:native_installRadius="5"
        app:native_installTitle="Install" />

Native Promote Custom Attributes

Attribute Description
native_installTitle Title button of native, default : "Install"
native_installColor Color of the button native (by default color : blue)
native_contentColor Content color (Title of the app and description)
native_bodyColor Native Body background color : white is the default
native_installRadius Raduis of button install : corner of button, defualt is 20px

Native Promote in Java code :

In your Java code, you can initialize your native view and get listener :

 NativePromote nativePromote = findViewById(R.id.native_ad);
        nativePromote.setButtonColor("#1C7DCA");
        nativePromote.setButtonTitle("Play Now");
        nativePromote.setRadiusButton(10);  //corner of button radius.
        nativePromote.setOnNativeListener(new OnNativeListener() {
            @Override
            public void onNativeAdLoaded() {
                //Native loaded.
            }

            @Override
            public void onNativeAdClicked() {
                //Native clicked.
            }

            @Override
            public void onNativeAdFailedToLoad(String error) {
                //"Native failed to load
            }
        });

Native Promote Example

Native Promote Example

Interstitial Promote in Java code :

Initialize the interstitial promote inside your code and get more controller the attributes programmatically :

  InterstitialPromote interstitialPromote = new InterstitialPromote(MainActivity.this);
        interstitialPromote.setStyle(InterstitialStyle.Advance);
        interstitialPromote.setInstallColor(R.color.my_color); //color of button from resource.
        //interstitialAd.setInstallColor("#E91E63"); //color of button from string.
        interstitialPromote.setTimer(5);//5 second to closed the Ad.
        interstitialPromote.setInstallTitle("Play Now");
        interstitialPromote.setRadiusButton(10); //corner of button radius.
        interstitialPromote.setOnInterstitialAdListener(new OnInterstitialAdListener() {
            @Override
            public void onInterstitialAdLoaded() {
                //interstitialAd loaded.
            }

            @Override
            public void onInterstitialAdClosed() {
                //interstitialAd closed.
            }

            @Override
            public void onInterstitialAdClicked() {
                //interstitialAd clicked.
            }

            @Override
            public void onInterstitialAdFailedToLoad(String error) {
                //Interstitial failed to load
            }
        });

Attributes programmatically for the InterstitialPromote:

  • setStyle Style of interstitial containt 2 style : InterstitialStyle.Advance or InterstitialStyle.Standard.
  • setInstallColor Color of install ad button : blue is default color.
  • setTimer CountDown time in Close button, you can make any time to block the close button : default is 0 (hide countDown).
  • setInstallTitle Title of install button : default is "Install".
  • setRadiusButton Raduis of button install : corner of button, defualt is 20px.

Showing Interstitial Promote :

When our lib initialize successful and check the interstitial is loaded than show him, if not start normal activity, check the code below :

 //check if the interstitial is loaded yet.
                if (interstitialPromote.isAdLoaded()) {

                    interstitialPromote.show(); //call showing interstitial
                    //when user close the interstitial ad, start the next activity.
                    interstitialPromote.setOnAdClosed(new OnAdClosed() {
                        @Override
                        public void onAdClosed() {
                            //your intent
                            //start your Activity
                        }
                    });
                } else {
                    //your intent : when ad is not ready yet.
                    //start your Activity
                }

Interstitial Promote Example

Interstitial Promote Example

File json:

  • The json file must to be uploaded in your server. File Json

Help Maintenance

If you could help me to continue maintain this repo, buying me a cup of coffee will make my life really happy and get much energy out of it.

Buy Me A Coffee

Thanks :

  • The Glide Lib for display images. Visit
  • The Dotsindicator Lib for indicator viewPager. Visit

License

Copyright 2022 SAID MOTYA

Licensed under the Apache License, Version 2.0 (the "License");
you may not use this file except in compliance with the License.
You may obtain a copy of the License at

    http://www.apache.org/licenses/LICENSE-2.0

Unless required by applicable law or agreed to in writing, software
distributed under the License is distributed on an "AS IS" BASIS,
WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
See the License for the specific language governing permissions and
limitations under the License.
You might also like...

This app corrects your sitting posture and provides feedback in real time in conjunction with the app. A sensor of 31 cells detects your posture to get better life-wellness

This app corrects your sitting posture and provides feedback in real time in conjunction with the app. A sensor of 31 cells detects your posture to get better life-wellness

Notichair 실시간 자세분석 및 교정 스마트체어 🏆 상명대학교 PRIME 경진대회 수상 🏆 요구사항 31-cell sensor (mdxs-16-5610) 목차 1. 소개 프로젝트 내용 소개 2. 개발 환경 사전 설정 및 환경 구축 3. 기능 Sensors Ap

Jan 15, 2022

corrects your sitting posture and provides feedback in real time in conjunction with the app. A sensor of 31 cells detects your posture to get better life-wellness

corrects your sitting posture and provides feedback in real time in conjunction with the app. A sensor of 31 cells detects your posture to get better life-wellness

Notichair 실시간 자세분석 및 교정 스마트체어 🏆 상명대학교 PRIME 경진대회 수상 🏆 요구사항 31-cell sensor (mdxs-16-5610) 목차 1. 소개 프로젝트 내용 소개 2. 개발 환경 사전 설정 및 환경 구축 3. 기능 Sensors Ap

Jan 15, 2022

Cross-platform framework for building truly native mobile apps with Java or Kotlin

Cross-platform framework for building truly native mobile apps with Java or Kotlin

Cross-platform framework for building truly native mobile apps with Java or Kotlin. Write Once Run Anywhere support for iOS, Android, Desktop & Web.

Jan 5, 2023

Simple AnimationUtil using Easing functions. Can be used anywhere, Hacked-Client, Mods, etc..

AnimationUtil Simple AnimationUtil using Easing functions. Can be used anywhere, Hacked-Client, Mods, etc.. Render example https://gyazo.com/780b5d8

Jan 8, 2023

OBKV Table Client is Java Library that can be used to access table data from OceanBase storage layer.

OBKV Table Client OBKV Table Client is Java Library that can be used to access table data from OceanBase storage layer. Its access method is different

Dec 16, 2022

SpringBoot service to pick up CAN messages retransmitted by CANBridge and extract certain values for reporting/monitoring/alerting via DataDog

SpringBoot service to pick up CAN messages retransmitted by CANBridge and extract certain values for reporting/monitoring/alerting via DataDog

SpringBoot service to pick up CAN messages retransmitted by CANBridge and extract certain values for reporting/monitoring/alerting via DataDog

Mar 12, 2022

GitHub Action to download and install Oracle's Java Development Kit builds

oracle-actions/setup-java This action downloads a Java Development Kit (JDK) built by Oracle and installs it using actions/setup-java. JDKs built by O

Dec 15, 2022

Share food-Android- - Food donation coded in native android with firebase, google maps api and php server xampp

Share food-Android- - Food donation coded in native android with firebase, google maps api and php server xampp

share_food-Android- Instructions: 1. Create a firebase account and link it with the project via google-services.json. 2. This project also uses a XAMP

Dec 28, 2021

A small companion library to Mixin, designed to help you write your Mixins in a more expressive and compatible way.

MixinExtras A small companion library to Mixin, designed to help you write your Mixins in a more expressive and compatible way. More information about

Jan 7, 2023
Releases(1.0.4)
Owner
SAID MOTYA
I'm mobile developer
SAID MOTYA
Tracks information (skills, inventory, bank, etc.) about a group ironman player and sends it to a website for other group members to view

Group Ironmen Tracker Plugin Website: groupiron.men Source for frontend and server: https://github.com/christoabrown/group-ironmen This plugin tracks

Christopher Brown 7 Nov 11, 2022
Android Library to create Lottie animation view dialog easily with a lot of customization

LottieDialog Android Library to create Lottie animation view dialog easily with a lot of customization Why you should use Lottie Dialog You have no li

Amr Hesham 39 Oct 7, 2022
With react-native-update-in-app library you can easily implement in-app updates in your React Native app using CDN or any other file server

React Native In-App update With react-native-update-in-app library you can easily implement in-app updates in your React Native app using CDN or any o

Nepein Andrey 7 Dec 21, 2022
React native wrapper for Jitsi Meet SDK Library that rely on the native view (Activity / ViewController)

react-native-jitsi-meet-sdk React native wrapper for Jitsi Meet SDK Library. This Library implements the Jitsi SDK with a native activity on the Andro

null 7 May 2, 2022
By this package we can get sim info, call logs and sms logs.Also we can find for specific sim info and call logs as well.

sim_sms_call_info A new flutter plugin project. Getting Started This project is a starting point for a Flutter plug-in package, a specialized package

 Hasib Akon 3 Sep 17, 2022
Auto-Unit-Test-Case-Generator automatically generates high-level code-coverage JUnit test suites for Java, widely used within the ANT Group.

中文README传送门 What is Auto-Unit-Test-Case-Generator Auto-Unit-Test-Case-Generator generates JUnit test suites for Java class just as its name. During te

TRaaS 108 Dec 22, 2022
Get notified with available vaccination centres via SMS

About A simple spring boot application that can track vaccine availability and automatically sends a SMS alert with the avilable centers Features Dose

Vic 21 Nov 16, 2022
Facsimile - Copy Your Most Used Text to Clipboard Easily with Facsimile!. It Helps You to Store You Most Used Text as a Key, Value Pair and Copy it to Clipboard with a Shortcut.

Facsimile An exact copy of Your Information ! Report Bug · Request Feature Table of Contents About The Project Built With Getting Started Installation

Sri lakshmi kanthan P 1 Sep 12, 2022
Simple Design for Java bridge with Javascript. Also can get javascript console.log.

SDBridgeKotlin is here. If your h5 partner confused about how to deal with iOS and Android. This Demo maybe help. 最常见的问题. WebViewJavascriptBridge is n

null 25 Dec 18, 2022
About I build a custom animated alert dialog with rounded corners - Java🚀🔥

Custom Animated AlertDialog Animated AlertDialog With Rounded Corners Alert Dialog Style First you need add this code to your project themes.xml file

Kaveesha Anuhas 2 Jul 15, 2022