1 |
ad9e8bb3
|
Leszek Koltunski
|
///////////////////////////////////////////////////////////////////////////////////////////////////
|
2 |
|
|
// Copyright 2020 Leszek Koltunski //
|
3 |
|
|
// //
|
4 |
|
|
// This file is part of Magic Cube. //
|
5 |
|
|
// //
|
6 |
|
|
// Magic Cube is free software: you can redistribute it and/or modify //
|
7 |
|
|
// it under the terms of the GNU General Public License as published by //
|
8 |
|
|
// the Free Software Foundation, either version 2 of the License, or //
|
9 |
|
|
// (at your option) any later version. //
|
10 |
|
|
// //
|
11 |
|
|
// Magic Cube is distributed in the hope that it will be useful, //
|
12 |
|
|
// but WITHOUT ANY WARRANTY; without even the implied warranty of //
|
13 |
|
|
// MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the //
|
14 |
|
|
// GNU General Public License for more details. //
|
15 |
|
|
// //
|
16 |
|
|
// You should have received a copy of the GNU General Public License //
|
17 |
|
|
// along with Magic Cube. If not, see <http://www.gnu.org/licenses/>. //
|
18 |
|
|
///////////////////////////////////////////////////////////////////////////////////////////////////
|
19 |
|
|
|
20 |
1f9772f3
|
Leszek Koltunski
|
package org.distorted.states;
|
21 |
ad9e8bb3
|
Leszek Koltunski
|
|
22 |
|
|
import android.content.SharedPreferences;
|
23 |
e3c74c0f
|
Leszek Koltunski
|
import android.util.TypedValue;
|
24 |
ad9e8bb3
|
Leszek Koltunski
|
import android.view.LayoutInflater;
|
25 |
a6d3b158
|
Leszek Koltunski
|
import android.view.View;
|
26 |
0e5ad27c
|
Leszek Koltunski
|
import android.widget.ImageButton;
|
27 |
ad9e8bb3
|
Leszek Koltunski
|
import android.widget.LinearLayout;
|
28 |
|
|
import android.widget.TextView;
|
29 |
|
|
|
30 |
1f9772f3
|
Leszek Koltunski
|
import org.distorted.main.R;
|
31 |
|
|
import org.distorted.main.RubikActivity;
|
32 |
5a4d4fba
|
Leszek Koltunski
|
import org.distorted.main.RubikPreRender;
|
33 |
9c2f0c91
|
Leszek Koltunski
|
import org.distorted.objects.TwistyObject;
|
34 |
|
|
import org.distorted.objects.ObjectList;
|
35 |
f0e87514
|
Leszek Koltunski
|
import org.distorted.scores.RubikScores;
|
36 |
ad9e8bb3
|
Leszek Koltunski
|
|
37 |
0e5ad27c
|
Leszek Koltunski
|
import java.util.ArrayList;
|
38 |
0333d81e
|
Leszek Koltunski
|
import java.util.Timer;
|
39 |
|
|
import java.util.TimerTask;
|
40 |
|
|
|
41 |
ad9e8bb3
|
Leszek Koltunski
|
///////////////////////////////////////////////////////////////////////////////////////////////////
|
42 |
|
|
|
43 |
5a4d4fba
|
Leszek Koltunski
|
public class RubikStateSolving extends RubikStateAbstract implements RubikPreRender.ActionFinishedListener
|
44 |
ad9e8bb3
|
Leszek Koltunski
|
{
|
45 |
0e5ad27c
|
Leszek Koltunski
|
private static final int DURATION_MILLIS = 750;
|
46 |
|
|
|
47 |
0333d81e
|
Leszek Koltunski
|
private TextView mTime;
|
48 |
|
|
private Timer mTimer;
|
49 |
|
|
private long mStartTime;
|
50 |
|
|
private boolean mRunning;
|
51 |
f0e87514
|
Leszek Koltunski
|
private RubikScores mScores;
|
52 |
46405bb4
|
Leszek Koltunski
|
private ImageButton mPrevButton, mLockButton, mBackButton;
|
53 |
0e5ad27c
|
Leszek Koltunski
|
private boolean mCanPrevMove;
|
54 |
|
|
private ArrayList<Move> mMoves;
|
55 |
2e8ec627
|
Leszek Koltunski
|
private long mElapsed;
|
56 |
0e5ad27c
|
Leszek Koltunski
|
|
57 |
|
|
private static class Move
|
58 |
|
|
{
|
59 |
|
|
private int mAxis, mRow, mAngle;
|
60 |
|
|
|
61 |
|
|
Move(int axis, int row, int angle)
|
62 |
|
|
{
|
63 |
|
|
mAxis = axis;
|
64 |
|
|
mRow = row;
|
65 |
|
|
mAngle= angle;
|
66 |
|
|
}
|
67 |
|
|
}
|
68 |
329c0aeb
|
Leszek Koltunski
|
|
69 |
0333d81e
|
Leszek Koltunski
|
///////////////////////////////////////////////////////////////////////////////////////////////////
|
70 |
|
|
|
71 |
329c0aeb
|
Leszek Koltunski
|
RubikStateSolving()
|
72 |
|
|
{
|
73 |
714292f1
|
Leszek Koltunski
|
mScores = RubikScores.getInstance();
|
74 |
329c0aeb
|
Leszek Koltunski
|
}
|
75 |
|
|
|
76 |
|
|
///////////////////////////////////////////////////////////////////////////////////////////////////
|
77 |
|
|
|
78 |
|
|
void leaveState(RubikActivity act)
|
79 |
ad9e8bb3
|
Leszek Koltunski
|
{
|
80 |
807d82b7
|
Leszek Koltunski
|
stopCounting();
|
81 |
ad9e8bb3
|
Leszek Koltunski
|
}
|
82 |
|
|
|
83 |
|
|
///////////////////////////////////////////////////////////////////////////////////////////////////
|
84 |
|
|
|
85 |
a6d3b158
|
Leszek Koltunski
|
void enterState(final RubikActivity act)
|
86 |
ad9e8bb3
|
Leszek Koltunski
|
{
|
87 |
e3c74c0f
|
Leszek Koltunski
|
float width = act.getScreenWidthInPixels();
|
88 |
|
|
float titleSize = width*RubikActivity.TITLE_TEXT_SIZE;
|
89 |
|
|
|
90 |
0e5ad27c
|
Leszek Koltunski
|
mCanPrevMove = true;
|
91 |
|
|
|
92 |
2e8ec627
|
Leszek Koltunski
|
startCounting(act);
|
93 |
|
|
|
94 |
0e5ad27c
|
Leszek Koltunski
|
if( mMoves==null ) mMoves = new ArrayList<>();
|
95 |
|
|
else mMoves.clear();
|
96 |
|
|
|
97 |
ad9e8bb3
|
Leszek Koltunski
|
LayoutInflater inflater = act.getLayoutInflater();
|
98 |
|
|
|
99 |
|
|
// TOP ////////////////////////////
|
100 |
7289fd6c
|
Leszek Koltunski
|
LinearLayout layoutTop = act.findViewById(R.id.upperBar);
|
101 |
ad9e8bb3
|
Leszek Koltunski
|
layoutTop.removeAllViews();
|
102 |
0333d81e
|
Leszek Koltunski
|
mTime = (TextView)inflater.inflate(R.layout.upper_text, null);
|
103 |
2e8ec627
|
Leszek Koltunski
|
int elapsed = (int)mElapsed/1000;
|
104 |
e3c74c0f
|
Leszek Koltunski
|
mTime.setTextSize(TypedValue.COMPLEX_UNIT_PX, titleSize);
|
105 |
2e8ec627
|
Leszek Koltunski
|
mTime.setText(act.getString(R.string.tm_placeholder,elapsed/60,elapsed%60));
|
106 |
0333d81e
|
Leszek Koltunski
|
layoutTop.addView(mTime);
|
107 |
ad9e8bb3
|
Leszek Koltunski
|
|
108 |
|
|
// BOT ////////////////////////////
|
109 |
92843d3b
|
Leszek Koltunski
|
LinearLayout layoutBot = act.findViewById(R.id.lowerBar);
|
110 |
|
|
layoutBot.removeAllViews();
|
111 |
|
|
|
112 |
|
|
LinearLayout.LayoutParams paramsL = new LinearLayout.LayoutParams(LinearLayout.LayoutParams.MATCH_PARENT,LinearLayout.LayoutParams.MATCH_PARENT,1);
|
113 |
4fb1fc0d
|
Leszek Koltunski
|
|
114 |
92843d3b
|
Leszek Koltunski
|
LinearLayout layoutLeft = new LinearLayout(act);
|
115 |
|
|
layoutLeft.setLayoutParams(paramsL);
|
116 |
4fb1fc0d
|
Leszek Koltunski
|
LinearLayout layoutMid = new LinearLayout(act);
|
117 |
|
|
layoutMid.setLayoutParams(paramsL);
|
118 |
92843d3b
|
Leszek Koltunski
|
LinearLayout layoutRight = new LinearLayout(act);
|
119 |
|
|
layoutRight.setLayoutParams(paramsL);
|
120 |
0e5ad27c
|
Leszek Koltunski
|
|
121 |
46405bb4
|
Leszek Koltunski
|
setupPrevButtom(act,width);
|
122 |
0e5ad27c
|
Leszek Koltunski
|
layoutLeft.addView(mPrevButton);
|
123 |
46405bb4
|
Leszek Koltunski
|
setupLockButton(act,width);
|
124 |
|
|
layoutMid.addView(mLockButton);
|
125 |
|
|
setupBackButtom(act,width);
|
126 |
|
|
layoutRight.addView(mBackButton);
|
127 |
0e5ad27c
|
Leszek Koltunski
|
|
128 |
46405bb4
|
Leszek Koltunski
|
layoutBot.addView(layoutLeft);
|
129 |
|
|
layoutBot.addView(layoutMid);
|
130 |
|
|
layoutBot.addView(layoutRight);
|
131 |
|
|
}
|
132 |
|
|
|
133 |
|
|
|
134 |
|
|
///////////////////////////////////////////////////////////////////////////////////////////////////
|
135 |
|
|
|
136 |
|
|
private void setupBackButtom(final RubikActivity act, float width)
|
137 |
|
|
{
|
138 |
ad0c8e0e
|
Leszek Koltunski
|
int padding = (int)(width*RubikActivity.PADDING);
|
139 |
|
|
int margin = (int)(width*RubikActivity.MARGIN);
|
140 |
46405bb4
|
Leszek Koltunski
|
final int icon = RubikActivity.getDrawable(R.drawable.ui_small_back,R.drawable.ui_medium_back, R.drawable.ui_big_back, R.drawable.ui_huge_back);
|
141 |
|
|
|
142 |
4c0cd600
|
Leszek Koltunski
|
LinearLayout.LayoutParams params = new LinearLayout.LayoutParams(LinearLayout.LayoutParams.MATCH_PARENT,LinearLayout.LayoutParams.MATCH_PARENT);
|
143 |
ad0c8e0e
|
Leszek Koltunski
|
params.topMargin = margin;
|
144 |
|
|
params.bottomMargin = margin;
|
145 |
|
|
params.leftMargin = margin;
|
146 |
|
|
params.rightMargin = margin;
|
147 |
ad9e8bb3
|
Leszek Koltunski
|
|
148 |
46405bb4
|
Leszek Koltunski
|
mBackButton = new ImageButton(act);
|
149 |
|
|
mBackButton.setLayoutParams(params);
|
150 |
|
|
mBackButton.setPadding(padding,0,padding,0);
|
151 |
|
|
mBackButton.setImageResource(icon);
|
152 |
4fb1fc0d
|
Leszek Koltunski
|
|
153 |
46405bb4
|
Leszek Koltunski
|
mBackButton.setOnClickListener( new View.OnClickListener()
|
154 |
a6d3b158
|
Leszek Koltunski
|
{
|
155 |
|
|
@Override
|
156 |
|
|
public void onClick(View v)
|
157 |
|
|
{
|
158 |
|
|
RubikState.goBack(act);
|
159 |
|
|
}
|
160 |
|
|
});
|
161 |
46405bb4
|
Leszek Koltunski
|
}
|
162 |
a6d3b158
|
Leszek Koltunski
|
|
163 |
46405bb4
|
Leszek Koltunski
|
///////////////////////////////////////////////////////////////////////////////////////////////////
|
164 |
92843d3b
|
Leszek Koltunski
|
|
165 |
46405bb4
|
Leszek Koltunski
|
private void setupLockButton(final RubikActivity act, final float width)
|
166 |
|
|
{
|
167 |
|
|
int padding = (int)(width*RubikActivity.PADDING);
|
168 |
|
|
int margin = (int)(width*RubikActivity.MARGIN);
|
169 |
|
|
|
170 |
|
|
LinearLayout.LayoutParams params = new LinearLayout.LayoutParams(LinearLayout.LayoutParams.MATCH_PARENT, LinearLayout.LayoutParams.MATCH_PARENT);
|
171 |
|
|
params.topMargin = margin;
|
172 |
|
|
params.bottomMargin = margin;
|
173 |
|
|
params.leftMargin = margin;
|
174 |
|
|
params.rightMargin = margin;
|
175 |
|
|
|
176 |
|
|
mLockButton = new ImageButton(act);
|
177 |
|
|
mLockButton.setLayoutParams(params);
|
178 |
|
|
mLockButton.setPadding(padding,0,padding,0);
|
179 |
|
|
mLockButton.setImageResource(getLockIcon(act));
|
180 |
|
|
|
181 |
|
|
mLockButton.setOnClickListener( new View.OnClickListener()
|
182 |
|
|
{
|
183 |
|
|
@Override
|
184 |
|
|
public void onClick(View v)
|
185 |
|
|
{
|
186 |
|
|
toggleLock(act);
|
187 |
|
|
}
|
188 |
|
|
});
|
189 |
ad9e8bb3
|
Leszek Koltunski
|
}
|
190 |
|
|
|
191 |
0e5ad27c
|
Leszek Koltunski
|
///////////////////////////////////////////////////////////////////////////////////////////////////
|
192 |
|
|
|
193 |
46405bb4
|
Leszek Koltunski
|
private void setupPrevButtom(final RubikActivity act, float width)
|
194 |
0e5ad27c
|
Leszek Koltunski
|
{
|
195 |
ad0c8e0e
|
Leszek Koltunski
|
int padding = (int)(width*RubikActivity.PADDING);
|
196 |
|
|
int margin = (int)(width*RubikActivity.MARGIN);
|
197 |
31a9f38d
|
Leszek Koltunski
|
int icon = RubikActivity.getDrawable(R.drawable.ui_small_cube_back,R.drawable.ui_medium_cube_back, R.drawable.ui_big_cube_back, R.drawable.ui_huge_cube_back);
|
198 |
98e7cc0f
|
Leszek Koltunski
|
|
199 |
4fb1fc0d
|
Leszek Koltunski
|
LinearLayout.LayoutParams params = new LinearLayout.LayoutParams(LinearLayout.LayoutParams.MATCH_PARENT,LinearLayout.LayoutParams.MATCH_PARENT);
|
200 |
ad0c8e0e
|
Leszek Koltunski
|
params.topMargin = margin;
|
201 |
|
|
params.bottomMargin = margin;
|
202 |
|
|
params.leftMargin = margin;
|
203 |
|
|
params.rightMargin = margin;
|
204 |
|
|
|
205 |
0e5ad27c
|
Leszek Koltunski
|
mPrevButton = new ImageButton(act);
|
206 |
|
|
mPrevButton.setLayoutParams(params);
|
207 |
|
|
mPrevButton.setPadding(padding,0,padding,0);
|
208 |
f6a9c538
|
Leszek Koltunski
|
mPrevButton.setImageResource(icon);
|
209 |
0e5ad27c
|
Leszek Koltunski
|
|
210 |
|
|
mPrevButton.setOnClickListener( new View.OnClickListener()
|
211 |
|
|
{
|
212 |
|
|
@Override
|
213 |
|
|
public void onClick(View v)
|
214 |
|
|
{
|
215 |
5a4d4fba
|
Leszek Koltunski
|
RubikPreRender pre = act.getPreRender();
|
216 |
|
|
backMove(pre);
|
217 |
0e5ad27c
|
Leszek Koltunski
|
}
|
218 |
|
|
});
|
219 |
|
|
}
|
220 |
|
|
|
221 |
|
|
///////////////////////////////////////////////////////////////////////////////////////////////////
|
222 |
|
|
|
223 |
5a4d4fba
|
Leszek Koltunski
|
private void backMove(RubikPreRender pre)
|
224 |
0e5ad27c
|
Leszek Koltunski
|
{
|
225 |
|
|
if( mCanPrevMove )
|
226 |
|
|
{
|
227 |
|
|
int numMoves = mMoves.size();
|
228 |
|
|
|
229 |
|
|
if( numMoves>0 )
|
230 |
|
|
{
|
231 |
|
|
Move move = mMoves.remove(numMoves-1);
|
232 |
9c2f0c91
|
Leszek Koltunski
|
TwistyObject object = pre.getObject();
|
233 |
0e5ad27c
|
Leszek Koltunski
|
|
234 |
|
|
int axis = move.mAxis;
|
235 |
|
|
int row = (1<<move.mRow);
|
236 |
|
|
int angle = move.mAngle;
|
237 |
|
|
int numRot= Math.abs(angle*object.getBasicAngle()/360);
|
238 |
|
|
|
239 |
|
|
if( angle!=0 )
|
240 |
|
|
{
|
241 |
|
|
mCanPrevMove = false;
|
242 |
5a4d4fba
|
Leszek Koltunski
|
pre.addRotation(this, axis, row, -angle, numRot*DURATION_MILLIS);
|
243 |
0e5ad27c
|
Leszek Koltunski
|
}
|
244 |
|
|
else
|
245 |
|
|
{
|
246 |
|
|
android.util.Log.e("solution", "error: trying to back move of angle 0");
|
247 |
|
|
}
|
248 |
|
|
}
|
249 |
|
|
}
|
250 |
|
|
}
|
251 |
|
|
|
252 |
46405bb4
|
Leszek Koltunski
|
///////////////////////////////////////////////////////////////////////////////////////////////////
|
253 |
|
|
|
254 |
|
|
private void toggleLock(RubikActivity act)
|
255 |
|
|
{
|
256 |
|
|
act.toggleLock();
|
257 |
|
|
mLockButton.setImageResource(getLockIcon(act));
|
258 |
|
|
}
|
259 |
|
|
|
260 |
|
|
///////////////////////////////////////////////////////////////////////////////////////////////////
|
261 |
|
|
|
262 |
|
|
private int getLockIcon(RubikActivity act)
|
263 |
|
|
{
|
264 |
|
|
if( act.retLocked() )
|
265 |
|
|
{
|
266 |
|
|
return RubikActivity.getDrawable(R.drawable.ui_small_locked,R.drawable.ui_medium_locked, R.drawable.ui_big_locked, R.drawable.ui_huge_locked);
|
267 |
|
|
}
|
268 |
|
|
else
|
269 |
|
|
{
|
270 |
|
|
return RubikActivity.getDrawable(R.drawable.ui_small_unlocked,R.drawable.ui_medium_unlocked, R.drawable.ui_big_unlocked, R.drawable.ui_huge_unlocked);
|
271 |
|
|
}
|
272 |
|
|
}
|
273 |
|
|
|
274 |
0e5ad27c
|
Leszek Koltunski
|
///////////////////////////////////////////////////////////////////////////////////////////////////
|
275 |
|
|
|
276 |
|
|
public void addMove(int axis, int row, int angle)
|
277 |
|
|
{
|
278 |
|
|
mMoves.add(new Move(axis,row,angle));
|
279 |
|
|
}
|
280 |
|
|
|
281 |
ad9e8bb3
|
Leszek Koltunski
|
///////////////////////////////////////////////////////////////////////////////////////////////////
|
282 |
|
|
|
283 |
|
|
public void savePreferences(SharedPreferences.Editor editor)
|
284 |
|
|
{
|
285 |
2e8ec627
|
Leszek Koltunski
|
mElapsed = System.currentTimeMillis()-mStartTime;
|
286 |
|
|
editor.putLong("stateSolving_elapsed" , mElapsed);
|
287 |
f0e87514
|
Leszek Koltunski
|
mScores.savePreferences(editor);
|
288 |
ad9e8bb3
|
Leszek Koltunski
|
}
|
289 |
|
|
|
290 |
|
|
///////////////////////////////////////////////////////////////////////////////////////////////////
|
291 |
|
|
|
292 |
|
|
public void restorePreferences(SharedPreferences preferences)
|
293 |
|
|
{
|
294 |
2e8ec627
|
Leszek Koltunski
|
mElapsed = preferences.getLong("stateSolving_elapsed" , 0 );
|
295 |
f0e87514
|
Leszek Koltunski
|
mScores.restorePreferences(preferences);
|
296 |
ad9e8bb3
|
Leszek Koltunski
|
}
|
297 |
0333d81e
|
Leszek Koltunski
|
|
298 |
|
|
///////////////////////////////////////////////////////////////////////////////////////////////////
|
299 |
|
|
|
300 |
2e8ec627
|
Leszek Koltunski
|
private void startCounting(final RubikActivity act)
|
301 |
0333d81e
|
Leszek Koltunski
|
{
|
302 |
|
|
if( !mRunning )
|
303 |
|
|
{
|
304 |
|
|
mRunning = true;
|
305 |
2e8ec627
|
Leszek Koltunski
|
mStartTime = System.currentTimeMillis() - mElapsed;
|
306 |
0333d81e
|
Leszek Koltunski
|
mTimer = new Timer();
|
307 |
|
|
|
308 |
|
|
mTimer.scheduleAtFixedRate(new TimerTask()
|
309 |
|
|
{
|
310 |
|
|
@Override
|
311 |
|
|
public void run()
|
312 |
|
|
{
|
313 |
|
|
act.runOnUiThread(new Runnable()
|
314 |
|
|
{
|
315 |
|
|
@Override
|
316 |
|
|
public void run()
|
317 |
|
|
{
|
318 |
|
|
int elapsed = (int)(System.currentTimeMillis()-mStartTime)/1000;
|
319 |
|
|
mTime.setText(act.getString(R.string.tm_placeholder,elapsed/60,elapsed%60));
|
320 |
|
|
}
|
321 |
|
|
});
|
322 |
|
|
}
|
323 |
|
|
}, 0, 1000);
|
324 |
|
|
}
|
325 |
|
|
}
|
326 |
|
|
|
327 |
|
|
///////////////////////////////////////////////////////////////////////////////////////////////////
|
328 |
|
|
|
329 |
1f894991
|
Leszek Koltunski
|
private void stopCounting()
|
330 |
|
|
{
|
331 |
|
|
if( mTimer!=null )
|
332 |
|
|
{
|
333 |
|
|
mTimer.cancel();
|
334 |
|
|
mTimer = null;
|
335 |
|
|
}
|
336 |
|
|
|
337 |
|
|
mRunning = false;
|
338 |
|
|
}
|
339 |
|
|
|
340 |
|
|
///////////////////////////////////////////////////////////////////////////////////////////////////
|
341 |
|
|
|
342 |
|
|
public long getRecord()
|
343 |
0333d81e
|
Leszek Koltunski
|
{
|
344 |
|
|
if( mRunning )
|
345 |
|
|
{
|
346 |
1f894991
|
Leszek Koltunski
|
stopCounting();
|
347 |
0333d81e
|
Leszek Koltunski
|
|
348 |
2e8ec627
|
Leszek Koltunski
|
mElapsed = System.currentTimeMillis()-mStartTime;
|
349 |
329c0aeb
|
Leszek Koltunski
|
|
350 |
|
|
RubikStatePlay play = (RubikStatePlay)RubikState.PLAY.getStateClass();
|
351 |
4888e97c
|
Leszek Koltunski
|
int object = play.getObject();
|
352 |
|
|
int size = play.getSize();
|
353 |
85b09df4
|
Leszek Koltunski
|
int level = play.getLevel();
|
354 |
9c2f0c91
|
Leszek Koltunski
|
int realSize= ObjectList.getSizeIndex(object,size);
|
355 |
329c0aeb
|
Leszek Koltunski
|
|
356 |
2e8ec627
|
Leszek Koltunski
|
boolean isNew = mScores.setRecord(object, realSize, level, mElapsed);
|
357 |
e41e7dc3
|
Leszek Koltunski
|
|
358 |
2e8ec627
|
Leszek Koltunski
|
return isNew ? mElapsed : -mElapsed;
|
359 |
0333d81e
|
Leszek Koltunski
|
}
|
360 |
|
|
|
361 |
|
|
return 0;
|
362 |
|
|
}
|
363 |
0e5ad27c
|
Leszek Koltunski
|
|
364 |
2e8ec627
|
Leszek Koltunski
|
///////////////////////////////////////////////////////////////////////////////////////////////////
|
365 |
|
|
|
366 |
|
|
public void resetElapsed()
|
367 |
|
|
{
|
368 |
|
|
mElapsed = 0;
|
369 |
|
|
}
|
370 |
|
|
|
371 |
0e5ad27c
|
Leszek Koltunski
|
///////////////////////////////////////////////////////////////////////////////////////////////////
|
372 |
|
|
|
373 |
|
|
public void onActionFinished(final long effectID)
|
374 |
|
|
{
|
375 |
|
|
mCanPrevMove = true;
|
376 |
|
|
}
|
377 |
ad9e8bb3
|
Leszek Koltunski
|
}
|