Android Question Works SetLayoutAnimated differently in b4a & b4j?

LucaMs

Expert
Licensed User
Longtime User
Please, try in b4j the code in this b4a code module.

You would get:

B4A:
Expand.gif


B4J:
Expand b4j.gif


Same code used.
 

Erel

B4X founder
Staff member
Licensed User
Longtime User
Tip: remove the jFX object from the class. It will then be cross platform compatible. And the 'ignore comments are not required.

The problem with the animation happens because the PreserveRatio property of the ImageView is set to True. So the image is scaled automatically. Set it to False and it should work.

test.gif
 
Upvote 0

LucaMs

Expert
Licensed User
Longtime User
Tip: remove the jFX object from the class. It will then be cross platform compatible.
So, you can use (open-import) in b4a-b4i a code module created with b4j?

Actually I do not need an answer because I just looked at Klaus's xChart example and the same code module is shared between the 3 projects.

But I did not think this was possible, since the first line of the module is:

B4J=true
 
Upvote 0

LucaMs

Expert
Licensed User
Longtime User
Upvote 0
Top