|
@@ -114,9 +114,8 @@ class SceneEditActivity : AppCompatActivity(), ActorAdapter.OnActorDragListener,
|
|
|
sceneEditView.layoutParams = layoutPrams
|
|
|
project.story?.let {
|
|
|
it.scenes?.let{
|
|
|
- it[0].sceneWidth = monitorSize.widthPixels
|
|
|
- for (i in 0 until INIT_SCENE_NUMBER){
|
|
|
- addScene(0)
|
|
|
+ for (i in 0 until it.size) {
|
|
|
+ it[i].sceneWidth = monitorSize.widthPixels
|
|
|
}
|
|
|
sceneEditView.scene = it[0]
|
|
|
}
|
|
@@ -353,7 +352,9 @@ class SceneEditActivity : AppCompatActivity(), ActorAdapter.OnActorDragListener,
|
|
|
navigationBar.removeAllViews()
|
|
|
paint_view.visibility = View.INVISIBLE
|
|
|
startRecord.visibility = View.VISIBLE
|
|
|
- initNavigationBarView(currentSceneIndex)
|
|
|
+ //initNavigationBarView(currentSceneIndex)
|
|
|
+ navigationBar.removeAllViews()
|
|
|
+ initNavigationFunction()
|
|
|
FileUtils.saveBitmapForActor(this, paint_view.bitmap, System.currentTimeMillis().toString())
|
|
|
project.story?.let {
|
|
|
it.scenes?.let{
|
|
@@ -390,6 +391,7 @@ class SceneEditActivity : AppCompatActivity(), ActorAdapter.OnActorDragListener,
|
|
|
var actorRecyclerView = selectActorView.findViewById<RecyclerView>(R.id.select_actor_recycler_view)
|
|
|
actorRecyclerView.layoutManager = layoutManager
|
|
|
actorRecyclerView.adapter = actorAdapter
|
|
|
+ actorRecyclerView.isNestedScrollingEnabled = false
|
|
|
viewContainer.addView(selectActorView)
|
|
|
selectActorView.layoutParams.width = monitorSize.widthPixels
|
|
|
selectActorView.btn_object.setOnClickListener {
|
|
@@ -888,6 +890,7 @@ class SceneEditActivity : AppCompatActivity(), ActorAdapter.OnActorDragListener,
|
|
|
popupWindow.dismiss()
|
|
|
}
|
|
|
}
|
|
|
+ sceneEditView.setLayerVisible(currentLayerIndex)
|
|
|
}
|
|
|
popupView.opacity.setOnClickListener {
|
|
|
popupWindow.dismiss()
|
|
@@ -907,6 +910,7 @@ class SceneEditActivity : AppCompatActivity(), ActorAdapter.OnActorDragListener,
|
|
|
it.scenes?.let {
|
|
|
it[currentSceneIndex].layers[currentLayerIndex].actors[actor.positionZ].opacity = p1.toFloat().div(100)
|
|
|
sceneEditView.scene = it[currentSceneIndex]
|
|
|
+ sceneEditView.setLayerVisible(currentLayerIndex)
|
|
|
}
|
|
|
}
|
|
|
}
|
|
@@ -917,7 +921,9 @@ class SceneEditActivity : AppCompatActivity(), ActorAdapter.OnActorDragListener,
|
|
|
})
|
|
|
popupView.tv_opacity_dialog_ok.setOnClickListener {
|
|
|
popupWindow.dismiss()
|
|
|
+ sceneEditView.setLayerVisible(currentLayerIndex)
|
|
|
}
|
|
|
+ sceneEditView.setLayerVisible(currentLayerIndex)
|
|
|
}
|
|
|
popupView.Mirror.setOnClickListener {
|
|
|
project.story?.let {
|
|
@@ -928,17 +934,19 @@ class SceneEditActivity : AppCompatActivity(), ActorAdapter.OnActorDragListener,
|
|
|
popupWindow.dismiss()
|
|
|
}
|
|
|
}
|
|
|
+ sceneEditView.setLayerVisible(currentLayerIndex)
|
|
|
}
|
|
|
popupView.bring_to_front.setOnClickListener{
|
|
|
project.story?.let {
|
|
|
it.scenes?.let {
|
|
|
- it[currentSceneIndex].layers[currentLayerIndex].actors.remove(actor)
|
|
|
+ it[currentSceneIndex].layers[currentLayerIndex].actors.removeAt(actor.positionZ)
|
|
|
it[currentSceneIndex].layers[currentLayerIndex].actors.add(actor)
|
|
|
setActorPositionZ(it[currentLayerIndex].layers[currentLayerIndex].actors)
|
|
|
sceneEditView.scene = it[currentSceneIndex]
|
|
|
popupWindow.dismiss()
|
|
|
}
|
|
|
}
|
|
|
+ sceneEditView.setLayerVisible(currentLayerIndex)
|
|
|
}
|
|
|
popupView.send_to_back.setOnClickListener{
|
|
|
project.story?.let {
|
|
@@ -950,15 +958,18 @@ class SceneEditActivity : AppCompatActivity(), ActorAdapter.OnActorDragListener,
|
|
|
popupWindow.dismiss()
|
|
|
}
|
|
|
}
|
|
|
+ sceneEditView.setLayerVisible(currentLayerIndex)
|
|
|
}
|
|
|
popupView.delete.setOnClickListener{
|
|
|
project.story?.let {
|
|
|
it.scenes?.let {
|
|
|
it[currentSceneIndex].layers[currentLayerIndex].actors.removeAt(actor.positionZ)
|
|
|
+ setActorPositionZ(it[currentLayerIndex].layers[currentLayerIndex].actors)
|
|
|
sceneEditView.scene = it[currentSceneIndex]
|
|
|
popupWindow.dismiss()
|
|
|
}
|
|
|
}
|
|
|
+ sceneEditView.setLayerVisible(currentLayerIndex)
|
|
|
}
|
|
|
return popupView
|
|
|
}
|
|
@@ -975,6 +986,7 @@ class SceneEditActivity : AppCompatActivity(), ActorAdapter.OnActorDragListener,
|
|
|
popupWindow.dismiss()
|
|
|
}
|
|
|
}
|
|
|
+ sceneEditView.setLayerVisible(currentLayerIndex)
|
|
|
}
|
|
|
popupView.duplicate_dialogue.setOnClickListener{
|
|
|
project.story?.let {
|
|
@@ -1000,6 +1012,7 @@ class SceneEditActivity : AppCompatActivity(), ActorAdapter.OnActorDragListener,
|
|
|
popupWindow.dismiss()
|
|
|
}
|
|
|
}
|
|
|
+ sceneEditView.setLayerVisible(currentLayerIndex)
|
|
|
}
|
|
|
popupView.Mirror_dialogue.setOnClickListener {
|
|
|
project.story?.let {
|
|
@@ -1010,6 +1023,7 @@ class SceneEditActivity : AppCompatActivity(), ActorAdapter.OnActorDragListener,
|
|
|
popupWindow.dismiss()
|
|
|
}
|
|
|
}
|
|
|
+ sceneEditView.setLayerVisible(currentLayerIndex)
|
|
|
}
|
|
|
popupView.layout_dialogue_dialog_color.setOnClickListener {
|
|
|
popupWindow.dismiss()
|
|
@@ -1094,12 +1108,14 @@ class SceneEditActivity : AppCompatActivity(), ActorAdapter.OnActorDragListener,
|
|
|
}
|
|
|
popupView.tv_color_dialog_ok.setOnClickListener {
|
|
|
popupWindow.dismiss()
|
|
|
+ sceneEditView.setLayerVisible(currentLayerIndex)
|
|
|
}
|
|
|
popupWindow.width = ViewGroup.LayoutParams.WRAP_CONTENT
|
|
|
popupWindow.height = ViewGroup.LayoutParams.WRAP_CONTENT
|
|
|
popupWindow.contentView = popupView
|
|
|
popupWindow.isOutsideTouchable = false
|
|
|
popupWindow.showAtLocation(sceneEditView, Gravity.START,actor.positionX,0)
|
|
|
+ sceneEditView.setLayerVisible(currentLayerIndex)
|
|
|
}
|
|
|
popupView.bring_to_front_dialogue.setOnClickListener{
|
|
|
project.story?.let {
|
|
@@ -1111,6 +1127,7 @@ class SceneEditActivity : AppCompatActivity(), ActorAdapter.OnActorDragListener,
|
|
|
popupWindow.dismiss()
|
|
|
}
|
|
|
}
|
|
|
+ sceneEditView.setLayerVisible(currentLayerIndex)
|
|
|
}
|
|
|
popupView.send_to_back_dialogue.setOnClickListener{
|
|
|
project.story?.let {
|
|
@@ -1122,15 +1139,18 @@ class SceneEditActivity : AppCompatActivity(), ActorAdapter.OnActorDragListener,
|
|
|
popupWindow.dismiss()
|
|
|
}
|
|
|
}
|
|
|
+ sceneEditView.setLayerVisible(currentLayerIndex)
|
|
|
}
|
|
|
popupView.delete_dialogue.setOnClickListener{
|
|
|
project.story?.let {
|
|
|
it.scenes?.let {
|
|
|
it[currentSceneIndex].layers[currentLayerIndex].actors.removeAt(actor.positionZ)
|
|
|
+ setActorPositionZ(it[currentLayerIndex].layers[currentLayerIndex].actors)
|
|
|
sceneEditView.scene = it[currentSceneIndex]
|
|
|
popupWindow.dismiss()
|
|
|
}
|
|
|
}
|
|
|
+ sceneEditView.setLayerVisible(currentLayerIndex)
|
|
|
}
|
|
|
return popupView
|
|
|
}
|