GV

GeezerVison

The World Wide Web, restored to 800 pixels of glory.

Home|About|Gaming cabinet|Archives|How it works|Starter sites

On this site

  • Sign in
  • ActionsCI/CD and automation
  • CodespacesCloud development environments
  • All Features
  • Documentation
  • Training
  • Certifications
  • Build with Copilot
  • Customize Copilot
  • Integrations
  • Trending repos
  • GitHub Sponsors
  • Developer articles
  • Enterprises

This view

  • Original page
  • New address

GeezerVison is showing github.com — GitHub - Norbert515/DropDownWarning: Drop down message

BranchesTags
Open more actions menu

Latest commit

 

History

46 Commits
46 Commits

Folders and files

NameName
Last commit message
Last commit date
.idea
.idea
 
 
app
app
 
 
dropdownwarninglibrary
dropdownwarninglibrary
 
 
gif
gif
 
 
gradle/wrapper
gradle/wrapper
 
 
.gitignore
.gitignore
 
 
LICENSE.txt
LICENSE.txt
 
 
README.md
README.md
 
 
build.gradle
build.gradle
 
 
dropdownwarninglibrary-release.aar
dropdownwarninglibrary-release.aar
 
 
gradle.properties
gradle.properties
 
 
gradlew
gradlew
 
 
gradlew.bat
gradlew.bat
 
 
settings.gradle
settings.gradle
 
 

Repository files navigation

DropDownWarning

Easy to implemente drop down warning/ message

Installation

Download the .aar file

Go to File -> New -> New Module -> Import .Jar/.AAR Package

Add this to your dependecies

dependecies{
    compile project (":dropdownwarninglibrary-release")
}

Or simply include

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

in your project gradle and then:

dependencies {
	        compile 'com.github.Norbert515:DropDownWarning:-SNAPSHOT'
	}

Code

First you need the top level Layout (most of the times it's a relative layout), you will need to give it an id in the XML.

RelativeLayout rootView = (RelativeLayout) findViewById(R.id.rootView);

Next you need to create a DropDownWarning.Builder

###Builder

DropDownWarning dropDownWarning = new DropDownWarning.Builder(Context context, ViewGroup parent)

    .interpolatorIn(Interpolator interpolator) //Intepolator used for the "show" animation
    
    .interpolatorOut(Interpolator interpolator) //Interpolator used for the "hide" animation
    
    .animationLength(int length) //Lenght of the animation in ms
    
    .textHeight(int height) //Height of the text view
    
    .message(String message) //Message to display
    
    .foregroundColor(int color) //Color of the text in argb
    
    .backgroundColor(int color) //Color of the background in argb
    
    .build() //return DropDownWarning

To display the warning you need to call:

dropDownWarning.show()

and to hide it:

dropDownWarning.hide()

#License

MIT License

Copyright (c) 2016 Norbert Kozsir

Permission is hereby granted, free of charge, to any person obtaining a copy
of this software and associated documentation files (the "Software"), to deal
in the Software without restriction, including without limitation the rights
to use, copy, modify, merge, publish, distribute, sublicense, and/or sell
copies of the Software, and to permit persons to whom the Software is
furnished to do so, subject to the following conditions:

The above copyright notice and this permission notice shall be included in all
copies or substantial portions of the Software.

THE SOFTWARE IS PROVIDED "AS IS", WITHOUT WARRANTY OF ANY KIND, EXPRESS OR
IMPLIED, INCLUDING BUT NOT LIMITED TO THE WARRANTIES OF MERCHANTABILITY,
FITNESS FOR A PARTICULAR PURPOSE AND NONINFRINGEMENT. IN NO EVENT SHALL THE
AUTHORS OR COPYRIGHT HOLDERS BE LIABLE FOR ANY CLAIM, DAMAGES OR OTHER
LIABILITY, WHETHER IN AN ACTION OF CONTRACT, TORT OR OTHERWISE, ARISING FROM,
OUT OF OR IN CONNECTION WITH THE SOFTWARE OR THE USE OR OTHER DEALINGS IN THE
SOFTWARE.

About

Drop down message

Resources

Readme
MIT license
Activity

Stars

247 stars

Watchers

10 watching

Forks

36 forks
Report repository

Releases

Packages

Contributors

Languages

You are visitor 01402792 — GeezerVison does not store the pages you look up.
Best viewed with Netscape Navigator 4.7 or Internet Explorer 6 at 800×600. No cookies required.