how do you implement custom animations

how do you implement custom animations?

I want to tell you nobody can come up with this stuff off the top of their head , if anybody claims that they can, they are lying to you unless you just finished implementing something that is entirely related to this question.
you're not going to be able to hit all the points

the first thing you feel is a deep sinking feeling in your heart, you're not sure what do they want me to say to describe the whole process to describe how I Implement them

let's find out what is required here.

first of all, show the classes' name you're going to use. Android provides several classes, there's the value animator object, animator and AnimatorSet.

you don't really need to go into them, just mention that you know them that's amazing.

but it's not amazing enough if you just stop right there, you're going to say you need to choose the right class for the right job you need to know what you need.

like I want to animate the position of an object, the size, the color.

these are all high level talk it's not implementation stuff.

you would say I would create the animation object given the properties and the duration how long I would animate it for, then I would call start() to start the animation

easy, then you would probably need to add an animator listener to be notified of what happens during the animation. like it start, it is cannceled, it is ended.
you need to override all of these methods ,you add your custom code here. where you need it you can customize

your can add an interpolator, indicate how an animation changes over time for example

you can also just use the View Property animator because in the end you are animating properties of a view this is a very direct simple easy to use API

you may be wondering I said in the beginning that no one can come up with the stuff off the top of their head, how did I do it I Googled it that's what I did, and to study for this stuff you have to Google it you have to memorize them

I hope they can serve as a reference for you when you are studying for something like this.

大體思路是:?jiǎn)柕酱笾碌膯栴}, 作為一個(gè)普通開發(fā)者來說, 不可能一上來就能說的面面俱到, 除非是剛好這幾天寫過這個(gè)功能。回答可以先回答要完成這個(gè)功能, android都提供了哪幾個(gè)相關(guān)的類。 之后把相關(guān)類的大致用法給說明下。提一句 I should give the properties by google it.
如果趕上自己正好了解的知識(shí)點(diǎn), 就說的詳細(xì)些, 如果確實(shí)了解的不多, 就說個(gè)大概, 至于詳細(xì)的類屬性和該調(diào)用什么方法, 就直接說I will google it.

最后編輯于
?著作權(quán)歸作者所有,轉(zhuǎn)載或內(nèi)容合作請(qǐng)聯(lián)系作者
【社區(qū)內(nèi)容提示】社區(qū)部分內(nèi)容疑似由AI輔助生成,瀏覽時(shí)請(qǐng)結(jié)合常識(shí)與多方信息審慎甄別。
平臺(tái)聲明:文章內(nèi)容(如有圖片或視頻亦包括在內(nèi))由作者上傳并發(fā)布,文章內(nèi)容僅代表作者本人觀點(diǎn),簡(jiǎn)書系信息發(fā)布平臺(tái),僅提供信息存儲(chǔ)服務(wù)。

相關(guān)閱讀更多精彩內(nèi)容

友情鏈接更多精彩內(nèi)容