24 |
24 |
|
25 |
25 |
public class TutorialScreen
|
26 |
26 |
{
|
27 |
|
private TransparentImageButton mSolveButton, mScrambleButton, mBackButton;
|
|
27 |
private TransparentImageButton mDialogButton, mSolveButton, mScrambleButton, mBackButton;
|
28 |
28 |
private TransparentImageButton mLockButton, mEmptyButton1, mEmptyButton2, mEmptyButton3;
|
29 |
29 |
private final LockController mLockController;
|
30 |
30 |
private final MovesController mMovesController;
|
... | ... | |
74 |
74 |
mEmptyButton3.setClickable(false);
|
75 |
75 |
}
|
76 |
76 |
|
|
77 |
///////////////////////////////////////////////////////////////////////////////////////////////////
|
|
78 |
|
|
79 |
private void setupDialogButton(final TutorialActivity act)
|
|
80 |
{
|
|
81 |
LinearLayout.LayoutParams params = new LinearLayout.LayoutParams(LinearLayout.LayoutParams.MATCH_PARENT,LinearLayout.LayoutParams.MATCH_PARENT,1.0f);
|
|
82 |
mDialogButton = new TransparentImageButton(act,R.drawable.ui_menu,params);
|
|
83 |
|
|
84 |
mDialogButton.setOnClickListener( new View.OnClickListener()
|
|
85 |
{
|
|
86 |
@Override
|
|
87 |
public void onClick(View v)
|
|
88 |
{
|
|
89 |
act.showDialog();
|
|
90 |
}
|
|
91 |
});
|
|
92 |
}
|
|
93 |
|
77 |
94 |
///////////////////////////////////////////////////////////////////////////////////////////////////
|
78 |
95 |
|
79 |
96 |
private void setupSolveButton(final TutorialActivity act)
|
... | ... | |
139 |
156 |
ObjectControl control = act.getControl();
|
140 |
157 |
mMovesController.setupButton(act,control);
|
141 |
158 |
mLockController.setupButton(act,control);
|
|
159 |
setupDialogButton(act);
|
142 |
160 |
setupSolveButton(act);
|
143 |
161 |
setupScrambleButton(act);
|
|
162 |
layout.addView(mDialogButton);
|
144 |
163 |
layout.addView(mSolveButton);
|
145 |
164 |
layout.addView(mScrambleButton);
|
146 |
165 |
layout.addView(mMovesController.getButton());
|
Progress with Tutorial activity.