• Stars
    star
    222
  • Rank 174,341 (Top 4 %)
  • Language
    Java
  • Created over 5 years ago
  • Updated about 2 years ago

Reviews

There are no reviews yet. Be the first to send feedback to the community and the maintainers!

Repository Details

Light Weighted Scratch Card View Library for Android

Android Scratchcard

Light Weighted Scratchcard View Library for Android

AndroidScratchCard - Example

Kindly use the following links to use this library:

In build.gradle (Project)

allprojects {
    repositories {
        ...
        maven { url "https://jitpack.io" }
    }
}

And then in the other gradle file(may be your app gradle or your own module library gradle, but never add in both of them to avoid conflict.)

dependencies {
    // AppCompat version
	  implementation 'com.github.myinnos:AndroidScratchCard:v1.0'
}

How to use

Step 1: add this to your xml:

 <RelativeLayout
        android:layout_width="match_parent"
        android:layout_height="match_parent">

        <TextView
            android:id="@+id/textView"
            android:layout_width="240dp"
            android:layout_height="150dp"
            android:layout_centerInParent="true"
            android:text="YOU EARNED 20" />
  
        <in.myinnos.androidscratchcard.ScratchCard
            android:id="@+id/scratchCard"
            android:layout_width="240dp"
            android:layout_height="150dp"
            android:layout_centerInParent="true"/>

    </RelativeLayout>

Step 2: implement setOnScratchListener to Play with Listener.

private ScratchCard mScratchCard;

.....
    
mScratchCard = (ScratchCard) findViewById(R.id.scratchCard);
mScratchCard.setOnScratchListener(new ScratchCard.OnScratchListener() {
    @Override
    public void onScratch(ScratchCard scratchCard, float visiblePercent) {
         if (visiblePercent > 0.3) {
             mScratchCard.setVisibility(View.GONE);
             Toast.makeText(MainActivity.this, "Content Visible", Toast.LENGTH_SHORT).show();
          }
     }
});
    
Any Queries? or Feedback, please let me know by opening a new issue!

Contact

Prabhakar Thota

If you appreciate my work, consider buying me a cup of to keep me recharged 🤘 by PayPal

License

Copyright 2017 MyInnos

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.

More Repositories

1

AlphabetIndex-Fast-Scroll-RecyclerView

A Powerful AlphabetIndex FastScroller Library for Android's RecyclerView!
Kotlin
596
star
2

AppIconNameChanger

Library to change Android launcher App Icon and App Name programmatically !
Java
592
star
3

AwesomeImagePicker

Awesome Image Picker library will pick images/gifs with beautiful interface. Supports image or gif, Single and Multiple Image selection.
Java
163
star
4

Kotlin-Example

An example for who are all going to start learning Kotlin programming language to develop Android application.
Kotlin
57
star
5

AppFontChanger

Custom font library for android | Library to change/add font of Entire Android Application at once without wasting your time - TextViews, EditText, Buttons, Views etc.,
Java
47
star
6

ImageSliderWithSwipes

This is an Image slider with swipes, Here we used Volley to Image load URL from JSON! Here we make it a very easy way to load images from the Internet and We customized the description font style(OpenSans).
Java
44
star
7

SlidingTabWithColorIcons

Library for Sliding Tab With Color Icons!
Java
35
star
8

GiphyImageResultsPreview

Library for GIF results, preview, play, share everything at one place!
Java
28
star
9

ImageSaveandShare

Library to save image locally and shows options to open and share !
Java
27
star
10

Android-InApp-Update

InApp update library for Android, In-app update is a library a new request flow to prompt active users to update your app.
Java
13
star
11

fansfolio_SMSAppLink

Send fans folio Android app download link as Free Text SMS to anyone around the world! fans folio is a free app to maintain folio for your idols(film stars, cricket stars etc..,). It's the easiest way to connect and talk about your idol. You can share anything about your idol and make him/her famous around the world.
Java
13
star
12

Android-Google-Code-Scanner

The Google code scanner API provides a complete solution for scanning codes without requiring your app to request camera permission.
Java
12
star
13

TensorFlow-Lite-Android-Example

An example Android application using TensorFLow Lite. The demo is a sample camera app that classifies images continuously using either a quantized Mobilenet model or a floating point Inception-v3 model. To run the demo, a device running Android 5.0 ( API 21) or higher is required.
Java
12
star
14

Github-Repo-Widget

Responsive widget showing your Github repo details that you can embed in any website.
JavaScript
9
star
15

WhatsApp-Android-SDK

SDK to Send WhatsApp Messages using the WhatsApp API
Kotlin
7
star
16

Machine-Learning-And-Statistics-Repos

Useful list of Machine Learning And Statistics Repositories
HTML
7
star
17

Swiggy-Scroll-Animation

Building Swiggy Offer Animation on Android
Java
7
star
18

Python-Examples

Python Examples
Python
5
star
19

FormSurveys

Native Form Survey Library like Google Forms for Android
Java
4
star
20

Telegram-Bot-PHP

Telegram Bot for sending message or photo to telegram channel or group using PHP
PHP
4
star
21

GoLang-Examples

GoLang Examples done from gobyexample.com
Go
4
star
22

Twitter-Bot-PHP

Twitter Bot for updating status automatically along with media using PHP
PHP
4
star
23

BackgroundEraserTool

Java
4
star
24

android-workmanager

Android WorkManager Example
Java
3
star
25

PickMode

An example will give you experience Capture Image/Video Mode (Demo)
Java
3
star
26

ChatBot-Example

An example will give you the experience to chat one on one(device level) communication along with Language Translation.
Java
2
star
27

myinnos

Github Profile [username ReadMe]
2
star
28

Note-Android-App

Simple Note Android App using MVVM and Room Database
Kotlin
2
star
29

CustomDialog-Android

Custom Dialog library for android
Java
2
star
30

Bond-Coin-BlockChain

A Simple Java Blockchain for BondCoin | Chat with Incognito
Java
1
star
31

Accident-Severity-Kaggle

Help the Government of India Transport Department to Prevent Accidents!
Jupyter Notebook
1
star
32

FeedExample

Example will give you experience of social feed
Java
1
star
33

SortingServices

Quick and Merge sort operations using sevice
Java
1
star
34

Smart-Contract

HTML
1
star
35

MAFE-HYBRID

An Hybrid application to find gender by name
JavaScript
1
star
36

Wear_WatchFace

WatchFace Example for Wear Watch
Java
1
star
37

TimerSurvey

Native Timer Survey Library like Google Forms for Android
Java
1
star