forked from geode-sdk/android-launcher
fix broken song download
This commit is contained in:
1 file changed
+23
-3
@@ -28,7 +28,7 @@ import org.cocos2dx.lib.Cocos2dxHelper
|
|||||||
import org.cocos2dx.lib.Cocos2dxRenderer
|
import org.cocos2dx.lib.Cocos2dxRenderer
|
||||||
import org.fmod.FMOD
|
import org.fmod.FMOD
|
||||||
|
|
||||||
class GeometryDashActivity : ComponentActivity() {
|
class GeometryDashActivity : ComponentActivity(), Cocos2dxHelper.Cocos2dxHelperListener {
|
||||||
override fun onCreate(savedInstanceState: Bundle?) {
|
override fun onCreate(savedInstanceState: Bundle?) {
|
||||||
setupUIState()
|
setupUIState()
|
||||||
|
|
||||||
@@ -58,7 +58,7 @@ class GeometryDashActivity : ComponentActivity() {
|
|||||||
AndroidView(
|
AndroidView(
|
||||||
modifier = Modifier.fillMaxSize(),
|
modifier = Modifier.fillMaxSize(),
|
||||||
factory = {
|
factory = {
|
||||||
Cocos2dxGLSurfaceView(this).apply {
|
Cocos2dxGLSurfaceView(this).apply {
|
||||||
setEGLConfigChooser(5, 6, 5, 0, 16, 8)
|
setEGLConfigChooser(5, 6, 5, 0, 16, 8)
|
||||||
initView()
|
initView()
|
||||||
setCocos2dxRenderer(Cocos2dxRenderer())
|
setCocos2dxRenderer(Cocos2dxRenderer())
|
||||||
@@ -78,9 +78,10 @@ class GeometryDashActivity : ComponentActivity() {
|
|||||||
}
|
}
|
||||||
}
|
}
|
||||||
|
|
||||||
|
Cocos2dxHelper.init(this, this)
|
||||||
|
|
||||||
JniToCpp.setupHSSAssets(
|
JniToCpp.setupHSSAssets(
|
||||||
applicationInfo.sourceDir,
|
gdPackageInfo.applicationInfo.sourceDir,
|
||||||
Environment.getExternalStorageDirectory().absolutePath
|
Environment.getExternalStorageDirectory().absolutePath
|
||||||
)
|
)
|
||||||
Cocos2dxHelper.nativeSetApkPath(gdPackageInfo.applicationInfo.sourceDir)
|
Cocos2dxHelper.nativeSetApkPath(gdPackageInfo.applicationInfo.sourceDir)
|
||||||
@@ -107,4 +108,23 @@ class GeometryDashActivity : ComponentActivity() {
|
|||||||
super.onDestroy()
|
super.onDestroy()
|
||||||
FMOD.close()
|
FMOD.close()
|
||||||
}
|
}
|
||||||
|
|
||||||
|
override fun runOnGLThread(pRunnable: Runnable) {
|
||||||
|
TODO("Not yet implemented")
|
||||||
|
}
|
||||||
|
|
||||||
|
override fun showDialog(pTitle: String, pMessage: String) {
|
||||||
|
TODO("Not yet implemented")
|
||||||
|
}
|
||||||
|
|
||||||
|
override fun showEditTextDialog(
|
||||||
|
pTitle: String,
|
||||||
|
pMessage: String,
|
||||||
|
pInputMode: Int,
|
||||||
|
pInputFlag: Int,
|
||||||
|
pReturnType: Int,
|
||||||
|
pMaxLength: Int
|
||||||
|
) {
|
||||||
|
TODO("Not yet implemented")
|
||||||
|
}
|
||||||
}
|
}
|
||||||
Reference in new issue
Block a user