how to remove a seekbar from the view with a mouse click - android

I've done something similar to this. Now I want to be able to remove the seekbar from the screen once im done with it. I want to do this simply by clicking somewhere else(anywhere but the seekbar) on the screen. Probably I need some kind of a clicklistener but have no idea how to implement something like this. Any tips, suggestions are welcome.
EDIT:
Just to clarify, by removing I mean hiding the seekbar and not neccessarily deleting it. And I already tried the INVISIBLE thing which isn't the answer to my question.

Related

Android efect animation on click

I've been searching for an easy way to make a cube effect animation when a button is pressed but my search yielded nothing. The idea is that when a button is pressed the text of the button changes after a cube animation is displayed. Does anyone know how something like that can be achieved? Is there maybe a function that helps me do that? Keep in mind I am still a beginner so I am looking for an easy way to it. Thanks for your help.
Android API has "animators" which are responsible for animation of either object properties or values. I'm a bit unsure if this cube you're trying to animate is a shape or just an image view but I am assuming it is an image view. Therefore, this url should help.
https://developer.android.com/reference/android/animation/ObjectAnimator.html

An elegant way to keep integrity of RelativeLayout when animating it?

Ok, so...
I know, there's been a real amount of questions about it, but it either didn't work, or was really fixed in a hard way. Oh, and that's my second day trying to do it, so please, accept my apologies about that and help me for Chet Haase's sake.
I have a button on top of a fragment, and a RecyclerView below it. When i press the button i want it to disappear and a new RelativeLayout with textfields to slide from the top.
I don't want to make it with animateLayoutChanges="true", cause it's not exactly what i was meant to do, and i want rather learn, than do it.
I tried to do it with widget.animate().translation... and the result was that one widget was just thrown in it's place when the rest of layout stood still. That's not what i meant to do.
I tried also to make an "new TranslateAnimation" since it has this "setFillAfter/Before" attribute... but that did not help me neither.
What i tried as well was to update the layout somehow adding to id margins and stuff (don't remember anymore, and i'm in work right now trying to figure it out, sorry) as it was described in some questions.
But none of that worked. I don't include code right now, cause i already tried to do it in some dozens of different ways.
Could you please tell me how to move a widget and make the rest of them to move with it? Is it possible?
I've already got it going once using setVisibility,animateLayoutChanges and animation combination, but that was massive and dirty as a baby duck.
Edit: oh, i almost forgot about it. Another problem is that when i animate/move a widget, only the rendering spod changes, but the real spot of it stays the same (ex. a onclicklistener)
Ok, me again.
I did it this way, that - let's say - i want to slide a button up and remove it.
So i animate it and all the other widgets (right, i can make a ViewGroup) up, put a listener on animation, and on "onAnimationEnd" i clear all the animations and set the visibility to GONE.
The animateLayoutChanges must be set to false
Still it's not what i wanted, so i'd be indebted to anyone who shows me another, better way.

What's is this called and how can I do this?

Attached I have a picture of what I want to do, but I have no idea what it's called, making it very hard to ask the right question or search for the answer.
I want to make it so that when an item in my listview is clicked, a small little drop down will appear, able to show the user a little note. I have no idea what to call that drop down or how to implement something like this in my code.
Thanks in advance.
As described in the comments above, what I was looking for is known as an ExpandableListView.

Bottom Panel in Android

I'm trying to design an app with a layout that will roughly look like this (don't mind the color):
How can I achieve something like that? I'm thinking of using a CardView for that bottom panel (I don't know what it's really called).
Furthermore, I want to hide it (animating it) when the use scrolls on the content. I have tried many codes but they won't work so I won't put them here anyway (like what's suggested here). Thanks for the help.
Whenever I have a question along the lines of "How do I do this neat UI thing I saw once?", I always start by checking out wasabeef's amazing UI library collection. In your case I might start by looking at bottomsheet or AndroidSweetSheet.

Android 1.6 like slider

I need a little help with something that I want to achieve. A want to implement this kind of view in my application :
like the button at the bottom of the page, and when user touch it, it's slide above and show other content. I'm pretty sure that I've found examples like that before, but now when I needed I couldn't find anything similar.
Any ideas what should I look for or even better if you can show me a link to a similar example I will appreciate that!
Thanks in advance!
check this
http://techdroid.kbeanie.com/2009/08/android-sliding-drawer-example.html

Categories

Resources