I don’t know why, but this does nothing.

I don’t know why, but this does nothing.

LL.bindClass(“android.view.View”);

var i=LL.getEvent().getItem();

var v=i.getRootView().getChildAt(0);

v.setVisibility(View.INVISIBLE);

Pierre Hébert in general I can’t modify the views retrieved by getRootView… At least I haven’t found out how.

]]>

3 Commentsto I don’t know why, but this does nothing.

  1. Anonymous says:

    < ![CDATA[

    Oh oh, visibility is an exception: it is handled in a particular fashion by the ItemLayout container, which has its own visibility rules. If you try this on the first child of the view returned by getRootView, then I think it should work.


    What other modifications are you trying to do ?

    ]]>

  2. Anonymous says:

    < ![CDATA[

    E.g. removing or adding childs to the rootview


    Or setting an image bitmap to the first child (which is an imageview)

    ]]>

  3. Anonymous says:

    < ![CDATA[

    The root view is a TransformLayout, it only accepts one child. Its task is to handle the matrix transformation and as such does not worry about other childs, only the first one is managed. (like a scrollview or other similar ViewGroup)


    The first child shouldn’t be an ImageView? But a BoxLayout ? Keep in mind these are custom views, not android views and they have a really special behavior. For instance there is an IconView instead of an ImageView because it is designed for speed instead of feature, it will only handle a restricted number of features.

    ]]>

Leave a Reply

Your email address will not be published. Required fields are marked *