Fix port by using staticFilesPort in orx-rabbit
This commit is contained in:
@@ -80,7 +80,7 @@ class RabbitControlServer(private val showQRUntilClientConnects: Boolean = true,
|
|||||||
val socket = Socket()
|
val socket = Socket()
|
||||||
socket.connect(InetSocketAddress("google.com", 80))
|
socket.connect(InetSocketAddress("google.com", 80))
|
||||||
val ip = socket.localAddress.toString().replace("/", "")
|
val ip = socket.localAddress.toString().replace("/", "")
|
||||||
val clientUrlWithHash = "http://$ip:8080/rabbit-client/index.html/#$ip:$rcpPort"
|
val clientUrlWithHash = "http://$ip:$staticFilesPort/rabbit-client/index.html/#$ip:$rcpPort"
|
||||||
qrCodeImage = getQRCodeImage(barcodeText = clientUrlWithHash)
|
qrCodeImage = getQRCodeImage(barcodeText = clientUrlWithHash)
|
||||||
println("RabbitControl Web Client: $clientUrlWithHash")
|
println("RabbitControl Web Client: $clientUrlWithHash")
|
||||||
|
|
||||||
@@ -159,6 +159,7 @@ class RabbitControlServer(private val showQRUntilClientConnects: Boolean = true,
|
|||||||
}
|
}
|
||||||
|
|
||||||
|
|
||||||
|
@Suppress("UNCHECKED_CAST")
|
||||||
fun add(objectWithParameters: Any) {
|
fun add(objectWithParameters: Any) {
|
||||||
val parameters = objectWithParameters.listParameters()
|
val parameters = objectWithParameters.listParameters()
|
||||||
|
|
||||||
@@ -215,7 +216,6 @@ class RabbitControlServer(private val showQRUntilClientConnects: Boolean = true,
|
|||||||
param.value = org.rabbitcontrol.rcp.model.types.Vector4(v4.x.toFloat(), v4.y.toFloat(), v4.z.toFloat(), v4.w.toFloat())
|
param.value = org.rabbitcontrol.rcp.model.types.Vector4(v4.x.toFloat(), v4.y.toFloat(), v4.z.toFloat(), v4.w.toFloat())
|
||||||
param
|
param
|
||||||
}
|
}
|
||||||
|
|
||||||
else -> rabbitServer.createBangParameter(it.label)
|
else -> rabbitServer.createBangParameter(it.label)
|
||||||
}
|
}
|
||||||
|
|
||||||
@@ -262,5 +262,6 @@ class RabbitControlServer(private val showQRUntilClientConnects: Boolean = true,
|
|||||||
}
|
}
|
||||||
|
|
||||||
fun <T> KMutableProperty1<out Any, Any?>?.qset(obj: Any, value: T) {
|
fun <T> KMutableProperty1<out Any, Any?>?.qset(obj: Any, value: T) {
|
||||||
|
@Suppress("UNCHECKED_CAST")
|
||||||
return (this as KMutableProperty1<Any, T>).set(obj, value)
|
return (this as KMutableProperty1<Any, T>).set(obj, value)
|
||||||
}
|
}
|
||||||
|
|||||||
Reference in New Issue
Block a user