1

I am using Material ShowcaseView https://github.com/deano2390/MaterialShowcaseView. Now I am getting the view in my app by adding transparency to the PULL DOWN TO REFRESH Activity. But when I click the "Got It" in Image1,the transparency was gone but the image(Arrow) which is marked as Red in Image2 is there.

enter image description here enter image description here

I need to go the next activity when I click "Got it" or I need to replace this "Got it" text into the Button View.How do I do this? Please help me...

I need the output like this..Button over the transparent layer.

enter image description here

Edric
  • 24,639
  • 13
  • 81
  • 91
Parama Sudha
  • 2,583
  • 3
  • 29
  • 48

1 Answers1

0

You can set an onClickListener method to the dismiss button according to this:

https://github.com/deano2390/MaterialShowcaseView/blob/master/sample/src/main/java/uk/co/deanwild/materialshowcaseviewsample/SequenceExample.java

As you can see he uses:

mButtonOne = (Button) findViewById(R.id.btn_one);
mButtonOne.setOnClickListener(this);

mButtonTwo = (Button) findViewById(R.id.btn_two);
mButtonTwo.setOnClickListener(this);

mButtonThree = (Button) findViewById(R.id.btn_three);
mButtonThree.setOnClickListener(this);

and then on the Listener method:

@Override
    public void onClick(View v) {

        if (v.getId() == R.id.btn_one) {
            //presentShowcaseSequence();
            Intent intent  = new Intent(YourCurrentActivity.this, NextActivity.class);
            startActivityIntent(intent);

        } else if (v.getId() == R.id.btn_reset) {

            MaterialShowcaseView.resetSingleUse(this, SHOWCASE_ID);
            Toast.makeText(this, "Showcase reset", Toast.LENGTH_SHORT).show();
        }

    }

Hope it helps!!!

Kostas Drak
  • 3,222
  • 6
  • 28
  • 60
  • I used intent instead of Toast in else if. When I tried to run my app,it directly goes to next activity & not showed the Showcaseview. – Parama Sudha Jan 30 '16 at 09:12
  • you have to actually `presentShowcaseSequence();` method for the first button and then for the second button you should use the Intent – Kostas Drak Jan 30 '16 at 09:13
  • But I am having only one image is there to click. – Parama Sudha Jan 30 '16 at 09:15
  • then present the showcase method in onCreate directly and then use the listener to go the next activity. Its hard for someone to understand without code – Kostas Drak Jan 30 '16 at 09:16
  • Let us [continue this discussion in chat](http://chat.stackoverflow.com/rooms/102061/discussion-between-parama-sudha-and-helldawg13). – Parama Sudha Jan 30 '16 at 09:19