All Questions
Tagged with visibility android
623
questions
0
votes
2
answers
2k
views
Invisible items becomes visible on scroll in RecyclerView
I have two buttons to play and pause a track in a RecyclerView item. When play button tapped, I want to hide it and show pause button. I've done this and it's working but I have a problem. Once I ...
0
votes
3
answers
292
views
Unable to change visibility of view other than onCreate method
I am unable to change the view visibility inside other function rather than onCreate method. Its working only at time of onCreate is called.
public class CameraXActivity extends AppCompatActivity {
...
2
votes
1
answer
241
views
Doing a task after a view became invisible
I'm writing a screenshot app using Android MediaProjection Api in which an overlay button is shown on top of everything and user can click it to capture a screenshot anywhere. Since MediaProjection ...
-1
votes
1
answer
2k
views
visibility of a layout in Kotlin
I got a layout that i want to make visible (which was "GONE" first) on clicking a button.
<include
android:id="@+id/registration_layout"
layout="@layout/...
7
votes
1
answer
2k
views
doOnPreDraw method not getting called for some items in a recyclerView
I'm having troubles with some animation in a recycler view. I do the relevant measurements in onViewAttachedToWindow:
override fun onViewAttachedToWindow(holder: PairingViewHolder) {
super....
0
votes
2
answers
242
views
View layout that are initially hidden, then onclick will make view visible, and vice versa(Android)
I have a constraint layout visibility that are initially set to GONE expandableLayout.setVisibility(View.GONE);. I want to make the view to be visible when 'setOnClickListener' are issued. Then, when ...
1
vote
2
answers
181
views
Cant check if my textview that inside of an array is visible or not in Kotlin
I have a 2D array (matrix) of Textviews called Board. Board has 16 Textviews in it, only one of them is invisible. In this given lines of code, I tried to find the invisible one between all the rest. ...
0
votes
1
answer
229
views
Live Wallpaper isVisible/onVisibilityChanged not working with Android 9+ App drawer
I have observed No visibility change reported by the isVisible() and/or onVisibilityChanged() when a Live Wallpaper is covered by AppsDrawer on an Android 9 phone. I am guessing it's because the Apps ...
1
vote
0
answers
690
views
Motionlayout and visibility make layout different to the Constraintlayout
I am converting the current constraintlayout to MotionLayout for the animation. What I do is quite simple, when the user scroll the second recycler view , the first recycler view should be hide. And ...
0
votes
1
answer
84
views
android Xml layout, visibility gone resize my parent layout
i have an issue with my xml layout
i have a switch which is supposed to hide / activate the visibility of one my layout
but when i hide my layout, somehow my root layout width is modified
here is my ...
1
vote
1
answer
458
views
Set visibility for view to gone for an inflated layout
I am trying to set the visibility of some views as gone after layout inflation but it doesn't work. If I try to access the tag of the view , I can clearly see that I am accessing the right view. This ...
4
votes
1
answer
921
views
Android MVVM UI control
I'm started to learn MVVM with LiveData on Android. I think displaying and updating basic data is clear to me. The topic I struggle to find a best practice for is controling the UI.
Let's say I have a ...
-1
votes
1
answer
647
views
how to change visibility a view in a fragment from the activity
As stated in the title how can change visibility a view in a fragment from the activity?
My code has a launch activity and a fragment. I want to change the visibility of a view inside fragment from ...
0
votes
2
answers
63
views
Visibility to Gone in Android
I am working on dynamic view. I am everything like generating Image view's id ,constraints with loop and setting all in code. I want one Pause and Start button. If I click on pause everything should ...
2
votes
1
answer
1k
views
Java Android Badge Drawable not working properly after configuration change
I have a Bottom Navigation view with a badge drawable that shows new chats.
This badges are updated upon a listener to Firebase database, where I store the notification counter. When this value ...