Search in sources :

Example 1 with Builder

use of com.github.amlcurran.showcaseview.ShowcaseView.Builder in project k-9 by k9mail.

the class HighlightDialogFragment method highlightViewInBackground.

protected void highlightViewInBackground() {
    if (!getArguments().containsKey(ARG_HIGHLIGHT_VIEW)) {
        return;
    }
    Activity activity = getActivity();
    if (activity == null) {
        throw new IllegalStateException("fragment must be attached to set highlight!");
    }
    boolean alreadyShowing = showcaseView != null && showcaseView.isShowing();
    if (alreadyShowing) {
        return;
    }
    int highlightedView = getArguments().getInt(ARG_HIGHLIGHT_VIEW);
    showcaseView = new Builder(activity).setTarget(new ViewTarget(highlightedView, activity)).hideOnTouchOutside().blockAllTouches().withMaterialShowcase().setStyle(R.style.ShowcaseTheme).build();
    showcaseView.hideButton();
}
Also used : Builder(com.github.amlcurran.showcaseview.ShowcaseView.Builder) Activity(android.app.Activity) ViewTarget(com.github.amlcurran.showcaseview.targets.ViewTarget)

Aggregations

Activity (android.app.Activity)1 Builder (com.github.amlcurran.showcaseview.ShowcaseView.Builder)1 ViewTarget (com.github.amlcurran.showcaseview.targets.ViewTarget)1