Tabnine Logo
DropDownWarning
Code IndexAdd Tabnine to your IDE (free)

How to use
DropDownWarning
in
com.nks.dropdownwarninglibrary

Best Java code snippets using com.nks.dropdownwarninglibrary.DropDownWarning (Showing top 5 results out of 315)

origin: Norbert515/DropDownWarning

public DropDownWarning build(){
  return new DropDownWarning(this);
}
origin: Norbert515/DropDownWarning

public DropDownWarning(Builder builder){
  super(builder.context);
  warningMessage = builder.warningMessage;
  backgroundColor = builder.backgroundColor;
  foregroundColor = builder.foregroundColor;
  height = builder.height;
  interpolatorIn = builder.interpolatorIn;
  interpolatorOut = builder.interpolatorOut;
  animationLength = builder.animationLength;
  parent = builder.parent;
  addWarningView();
  setUpLayoutParams();
  initializeAnimation();
}
origin: Norbert515/DropDownWarning

  @Override
  public void onClick(View v) {
    if(on){
      dropDownWarning.hide();
      on = false;
    }else{
      dropDownWarning.show();
      dropDownWarning.setOnClickListener(new View.OnClickListener() {
        @Override
        public void onClick(View view) {
          Toast.makeText(getApplicationContext(),"DropDownWarning pressed", Toast.LENGTH_LONG).show();
        }
      });
      on = true;
    }
  }
});
origin: Norbert515/DropDownWarning

private void addWarningView(){
  textView = new TextView(getContext());
  textView.setText(warningMessage);
  textView.setBackgroundColor(backgroundColor);
  textView.setGravity(Gravity.CENTER);
  textView.setPadding(0,12,0,12);
  textView.setVisibility(INVISIBLE);
  textView.setTextColor(foregroundColor);
  LayoutParams l = new LayoutParams(ViewGroup.LayoutParams.MATCH_PARENT, height);
  textView.setLayoutParams(l);
  addView(textView);
}
origin: Norbert515/DropDownWarning

private void setUpLayoutParams(){
  LayoutParams l = new LayoutParams(ViewGroup.LayoutParams.MATCH_PARENT, ViewGroup.LayoutParams.MATCH_PARENT);
  setLayoutParams(l);
  parent.addView(this);
}
com.nks.dropdownwarninglibraryDropDownWarning

Javadoc

Created by Norbert on 31.08.2016.

Most used methods

  • <init>
  • addView
  • addWarningView
  • getContext
  • hide
    Starts fade out animation and hides text view
  • initializeAnimation
  • setLayoutParams
  • setOnClickListener
  • setUpLayoutParams
  • show
    Starts fade in animation and shows text view

Popular in Java

  • Updating database using SQL prepared statement
  • setScale (BigDecimal)
  • getSharedPreferences (Context)
  • getContentResolver (Context)
  • String (java.lang)
  • Collection (java.util)
    Collection is the root of the collection hierarchy. It defines operations on data collections and t
  • TimerTask (java.util)
    The TimerTask class represents a task to run at a specified time. The task may be run once or repeat
  • UUID (java.util)
    UUID is an immutable representation of a 128-bit universally unique identifier (UUID). There are mul
  • AtomicInteger (java.util.concurrent.atomic)
    An int value that may be updated atomically. See the java.util.concurrent.atomic package specificati
  • JFileChooser (javax.swing)
  • Top 15 Vim Plugins
Tabnine Logo
  • Products

    Search for Java codeSearch for JavaScript code
  • IDE Plugins

    IntelliJ IDEAWebStormVisual StudioAndroid StudioEclipseVisual Studio CodePyCharmSublime TextPhpStormVimAtomGoLandRubyMineEmacsJupyter NotebookJupyter LabRiderDataGripAppCode
  • Company

    About UsContact UsCareers
  • Resources

    FAQBlogTabnine AcademyStudentsTerms of usePrivacy policyJava Code IndexJavascript Code Index
Get Tabnine for your IDE now