'Change TapTargetView into a TapTargetSequence

In this code example I have a single TapTargetView working:

if (controllerVisible && playerView.isControllerFullyVisible()) {
    if (setPrefs.firstRun) {
        TapTargetView.showFor(PlayerActivity.this,
            TapTarget.forView(buttonSettings, getString(R.string.onboarding_settings_title),
                    getString(R.string.onboarding_settings_description))
                    .outerCircleColor(R.color.blue)
                    .targetCircleColor(R.color.white)
                    .titleTextSize(22)
                    .titleTextColor(R.color.white)
                    .descriptionTextSize(14)
                    .cancelable(true),
            new TapTargetView.Listener() {
                @Override
                public void onTargetClick(TapTargetView view) {
                    super.onTargetClick(view);
                    buttonOpen.performClick();
                }
            });
        setPrefs.markFirstRun();
    }
}

But I cannot work out how to create a TapTargetSequence using the following example:

TapTargetSequence(this)
    .targets(
        TapTarget.forView(buttonSettings, getString(R.string.onboarding_settings_title),
            getString(R.string.onboarding_settings_description))
            .outerCircleColor(R.color.blue)
            .targetCircleColor(R.color.white)
            .titleTextSize(22)
            .titleTextColor(R.color.white)
            .descriptionTextSize(14)
            .cancelable(true),
        TapTarget.forView(buttonMedia, getString(R.string.onboarding_media_title),
            getString(R.string.onboarding_media_description))
            .outerCircleColor(R.color.blue)
            .targetCircleColor(R.color.white)
            .titleTextSize(22)
            .titleTextColor(R.color.white)
            .descriptionTextSize(14)
            .cancelable(true))

I'm having a great deal of trouble with this could someone please help me to figure this out.

Thank you



Solution 1:[1]

Did you use .start(); at last

Like .cancleable(true)).start();

Sources

This article follows the attribution requirements of Stack Overflow and is licensed under CC BY-SA 3.0.

Source: Stack Overflow

Solution Source
Solution 1 Anmol Mahay