Android data binding, update a view by another viewmodal's observable -


i have view modal x binded view y.

ex: view y.xml

 <variable         name="visit"         type="pkg.x"></variable> 

i have view modal p binded view q.

but view modal's observable controlling behavior of view modal x.

so have define in same layout (y.xml) below

<variable             name="visitcard"             type="pkg.p"></variable>  <variable             name="visit"             type="pkg.x"></variable> 

now want control value in y below.

android:visibility="@{visit.visitstate.equalsignorecase(`calledstate`) &amp;&amp; !visitcard.visitstate.equalsignorecase(`noshow`) ? view.visible : view.gone}" 

but not working expected. in view modal p, if set visitstate.set('noshow'), doesnt reflect other view-modal x? p.s both of these mvvm added activity fragments. should happen when user interact 1 view based on value, other view should change.


Comments

Popular posts from this blog

ubuntu - PHP script to find files of certain extensions in a directory, returns populated array when run in browser, but empty array when run from terminal -

php - How can i create a user dashboard -

javascript - How to detect toggling of the fullscreen-toolbar in jQuery Mobile? -