worker8/TourGuide

First tooltip does not appear

Opened this issue · 0 comments

I am trying to use TourGuide on Wear OS. The tooltip does not appear the first time I use the "PlayOn" function but does the second time. Here is my code:

`final TourGuide tourGuide = TourGuide.init(activity).with(TourGuide.Technique.CLICK);
ToolTip toolTip = new ToolTip();
toolTip.setGravity(Gravity.TOP);
toolTip.setDescription("Click description");
Overlay overlay = new Overlay();
overlay.setMDisableClickThroughHole(true);
overlay.setMStyle(Overlay.Style.CIRCLE);

                overlay.setOnClickListener(view -> {
                    tourGuide.cleanUp();
                    clicks++;
                    if(clicks == 1) {
                        tourGuide.playOn(episodeFragment.findViewById(R.id.play_button));
                    }
                });

        Pointer downloadPointer = new Pointer(Gravity.CENTER);
        tourGuide.setPointer(downloadPointer)
                .setToolTip(toolTip)
                .setOverlay(overlay);
        tourGuide.playOn(episodeFragment.findViewById(R.id.play_button));`