Revision a84c3a25
Added by Leszek Koltunski almost 3 years ago
src/main/java/org/distorted/dialogs/RubikDialogTutorialView.java | ||
---|---|---|
45 | 45 |
|
46 | 46 |
public class RubikDialogTutorialView extends FrameLayout |
47 | 47 |
{ |
48 |
private boolean mCanClick; |
|
49 |
|
|
50 |
/////////////////////////////////////////////////////////////////////////////////////////////////// |
|
51 |
|
|
48 | 52 |
public RubikDialogTutorialView(Context context, AttributeSet attrs, int defStyle) |
49 | 53 |
{ |
50 | 54 |
super(context, attrs, defStyle); |
... | ... | |
63 | 67 |
{ |
64 | 68 |
super(act); |
65 | 69 |
|
70 |
clickPossible(true); |
|
66 | 71 |
int widthT = (int)(width* RubikActivity.TUTORIAL_ITEM_TEXT); |
67 | 72 |
|
68 | 73 |
RubikActivity ract = (RubikActivity)getContext(); |
... | ... | |
94 | 99 |
addView(tab); |
95 | 100 |
} |
96 | 101 |
|
102 |
/////////////////////////////////////////////////////////////////////////////////////////////////// |
|
103 |
|
|
104 |
void clickPossible(boolean click) |
|
105 |
{ |
|
106 |
mCanClick = click; |
|
107 |
} |
|
108 |
|
|
97 | 109 |
/////////////////////////////////////////////////////////////////////////////////////////////////// |
98 | 110 |
|
99 | 111 |
private View createRow(final RubikActivity act, int countryID, final String desc, final String url, |
... | ... | |
111 | 123 |
@Override |
112 | 124 |
public void onClick(View v) |
113 | 125 |
{ |
114 |
act.switchTutorial(url,obj,size); |
|
115 |
analyticsReport(act,desc,auth,obj,size); |
|
126 |
if( mCanClick ) |
|
127 |
{ |
|
128 |
act.switchTutorial(url,obj,size); |
|
129 |
analyticsReport(act,desc,auth,obj,size); |
|
130 |
clickPossible(false); |
|
131 |
} |
|
116 | 132 |
} |
117 | 133 |
}); |
118 | 134 |
|
Also available in: Unified diff
Make it impossible to launch more than one Tutorial screen at a time.