1
|
///////////////////////////////////////////////////////////////////////////////////////////////////
|
2
|
// Copyright 2024 Leszek Koltunski //
|
3
|
// //
|
4
|
// This file is part of Magic Cube. //
|
5
|
// //
|
6
|
// Magic Cube is proprietary software licensed under an EULA which you should have received //
|
7
|
// along with the code. If not, check https://distorted.org/magic/License-Magic-Cube.html //
|
8
|
///////////////////////////////////////////////////////////////////////////////////////////////////
|
9
|
|
10
|
package org.distorted.phasedsolver;
|
11
|
|
12
|
import org.distorted.objectlib.helpers.ObjectLibInterface;
|
13
|
|
14
|
import java.lang.ref.WeakReference;
|
15
|
|
16
|
///////////////////////////////////////////////////////////////////////////////////////////////////
|
17
|
|
18
|
public class SolverObjectLibInterface implements ObjectLibInterface
|
19
|
{
|
20
|
private final WeakReference<SolverActivity> mAct;
|
21
|
|
22
|
///////////////////////////////////////////////////////////////////////////////////////////////////
|
23
|
|
24
|
SolverObjectLibInterface(SolverActivity act) { mAct = new WeakReference<>(act); }
|
25
|
public void onWinEffectFinished(long startTime, long endTime, String debug, int scrambleNum) { }
|
26
|
public void onScrambleEffectFinished() { }
|
27
|
public void onBeginRotation() { }
|
28
|
public void onSolved() { }
|
29
|
public void onObjectCreated(long time) { }
|
30
|
public void failedToDrag() { }
|
31
|
public void reportBlockProblem(int type, int place, long pause, long resume, long time) { }
|
32
|
public void reportProblem(String problem, boolean reportException) {}
|
33
|
public void onReplaceModeDown(int cubit, int face) { }
|
34
|
public void onReplaceModeUp() { }
|
35
|
public void reportJSONError(String error, int ordinal) { }
|
36
|
|
37
|
///////////////////////////////////////////////////////////////////////////////////////////////////
|
38
|
|
39
|
public void onRemoveRotation(int axis, int row, int angle)
|
40
|
{
|
41
|
SolverActivity act = mAct.get();
|
42
|
act.addMove(axis,row,angle);
|
43
|
}
|
44
|
}
|