August 26, 2020
  • 7:34 am Cách tách gộp ô trong Excel – How to Merge Cells in Excel
  • 7:23 am Cách xem mật khẩu wifi cho điện thoại Samsung , Oppo, wifi Tenda , iPhone| Dương Văn An
  • 7:10 am HƯỚNG TẢI NHẠC YOUTUBE VỀ MÁY TÍNH DẠNG FILE ZING MP3 ĐƠN GIẢN NHẤT
  • 6:58 am One Punch Man – Tập 05 [Việt sub] [Bản giới hạn]
  • 6:43 am Bài tập Excel nâng cao có hướng dẫn giải [Cực Hay]



By default Android only offers a circular indeterminate ProgressBar, that has a spinning animation and indicates that something is loading, but doesn’t show the actual progress. If we want a determinate progress bar that shows the progress, we usually have to set it to a horizontal ProgressBar with style=”?android:progressBarStyleHorizontal”.
In this video you’re going to learn, how to create a circular determinate ProgressBar with the progressDrawable attribute and a self made XML drawable.

Example code:

____________________
❗ Subscribe to the channel:

⏯ Watch more tutorials:

⭐ Become a channel member for exclusive tutorials and other perks:

㊙ Help translating the videos:

💚 Support the content:

💬 Join the Discord chat:

🎧 Audiobooks and podcasts for programmers:

👶 How to get started with Android development:

📣 Follow Coding in Flow on social media:

Facebook:

Instagram:

Twitter:

Blog:

Nguồn: https://alimentproteine.com/

Xem thêm bài viết khác: https://alimentproteine.com/cong-nghe/

admin

RELATED ARTICLES

46 COMMENTS

  1. Rupert Rawnsley Posted on June 28, 2020 at 4:57 pm

    Great tutorial. Here's how I modified the XML file to start progress from the top and to put a gray background like the horizontal progress bar has:

    <?xml version="1.0" encoding="utf-8"?>
    <layer-list xmlns:android="http://schemas.android.com/apk/res/android">
    <item>
    <shape
    android:shape="ring"
    android:thicknessRatio="16"
    android:useLevel="false">
    <solid android:color="#DDDDDD" />
    </shape>
    </item>
    <item>
    <rotate
    android:fromDegrees="270"
    android:toDegrees="270"
    android:pivotX="50%"
    android:pivotY="50%" >
    >
    <shape
    android:shape="ring"
    android:thicknessRatio="16"
    android:useLevel="true">
    <solid android:color="@color/colorAccent" />
    </shape>
    </rotate>
    </item>
    </layer-list>

    Reply
  2. Mikko Marttala Posted on June 28, 2020 at 4:57 pm

    I am so happy whenever im looking for a specific tutorial and find one of yours, cheers buddy!

    Reply
  3. Javier Sarmiento Posted on June 28, 2020 at 4:57 pm

    Great video!

    Reply
  4. Carlos Aguirre Posted on June 28, 2020 at 4:57 pm

    Thanks!

    Reply
  5. Code Generator Posted on June 28, 2020 at 4:57 pm

    Wow.
    the best tutor ever. I have learnt constraint layout from this channel and hope to learn more.
    What's your name again, Sir?

    Reply
  6. Вадим Чурун Posted on June 28, 2020 at 4:57 pm

    My goal was to stop ProgressBar spinning. I was about to reject using ProgerssBar and switch to another solution or even a custom view, but your tutorial came out with a simple workaround. Thanks a lot!

    Reply
  7. Gustav Bentzen Posted on June 28, 2020 at 4:57 pm

    Ty so much. The inner circle ring animation was very nice

    Reply
  8. MG Posted on June 28, 2020 at 4:57 pm

    Doesn't work on android
    Ugh you're using desktop and this video is do those very advanced in knowledge. Have know idea how you even got to where you are. Unless to me

    Reply
  9. Faba Fabaz Posted on June 28, 2020 at 4:57 pm

    Really is helpful tutorial, but pleas broo I use tecno hot 5 and there is Circle bar loading on the screen can you please help me how can I remove it?

    Reply
  10. a Woolen Sleevelet Posted on June 28, 2020 at 4:57 pm

    great tutorial

    Reply
  11. 장성혁 Posted on June 28, 2020 at 4:57 pm

    How can I see window showing progress in real time? https://www.youtube.com/watch?v=hSfN_aYKkzo&t=247 the right side of your video.

    Reply
  12. nilstest nilseru Posted on June 28, 2020 at 4:57 pm

    in germany we call this great vid

    Reply
  13. Deepak shah Posted on June 28, 2020 at 4:57 pm

    Please make a video on Round Seekbar.

    Reply
  14. Санкаршана дас Posted on June 28, 2020 at 4:57 pm

    Very useful! And very professionally mounted!

    Reply
  15. Stanislav Shelemekh Posted on June 28, 2020 at 4:57 pm

    Amazing! Thanks, Sir!!! ❤

    Reply
  16. Matt Graves Posted on June 28, 2020 at 4:57 pm

    aha I knew if I spent countless hours watching your videos that I could extract some voodoo magic from Android… this is some badass voodoo magic here…
    combined with the include in views… man I can't even imagine all the stuff that we can create…

    Reply
  17. TECHNOMATRY Posted on June 28, 2020 at 4:57 pm

    Well how to hide loading animation when file is loaded..?
    Plzz replying

    Reply
  18. Moaz El-sawaf Posted on June 28, 2020 at 4:57 pm

    Thanks a lot sir <3

    Reply
  19. Piero Linares Posted on June 28, 2020 at 4:57 pm

    Great tutorial

    Reply
  20. slash0t5 Posted on June 28, 2020 at 4:57 pm

    Whoever left a thumbsdown must be really jealous of you. Hervorragend. Absolut lobenswert.

    Reply
  21. XYZERTUBE Posted on June 28, 2020 at 4:57 pm

    Thanks!How can I make this smoother?

    Reply
  22. Joshua Douce Posted on June 28, 2020 at 4:57 pm

    Thanks Man!!!!!!

    Reply
  23. Şaban KARACA Posted on June 28, 2020 at 4:57 pm

    Great job! Thanks a lot!

    Reply
  24. Atheesh Rathnaweera Posted on June 28, 2020 at 4:57 pm

    Thank you very much.

    Reply
  25. MOHAN LAL CHOUDHARY Posted on June 28, 2020 at 4:57 pm

    Sir you are a *GOOD TEACHER*.
    But tell me how to use with WebView

    Reply
  26. VISWESWARAN 1998 Posted on June 28, 2020 at 4:57 pm

    I really love the short time of this video which directly goes into the concepts rather explaining how to create a new android project in android studio in every single video one makes. Thank you and keep up the great work!

    Reply
  27. Muhammad Tahir Posted on June 28, 2020 at 4:57 pm

    Hello there, i want to hide all my Views when i use SearchView in my Activity and want to show ProgressBar during the image load… Need your help plz….

    Reply
  28. Aninu Apps Posted on June 28, 2020 at 4:57 pm

    Thanks 🙂

    Reply
  29. Pree Nxus Posted on June 28, 2020 at 4:57 pm

    How to use it in dialog?

    Reply
  30. Clark Wu Posted on June 28, 2020 at 4:57 pm

    For anyone who encountered the problem of using setProgress which requires API level >= 24.
    You can use setProgress(percent)to avoid the problem. setProgress(percent, animate: false) with animate input requires higher API

    Reply
  31. Clark Wu Posted on June 28, 2020 at 4:57 pm

    What a great tutorial. Thanks!!!

    Reply
  32. GabriellaMZ Posted on June 28, 2020 at 4:57 pm

    Is this Java?

    Reply
  33. Muhammad Tariq Posted on June 28, 2020 at 4:57 pm

    How to display progress inside ring, if our progress is set to 30% then I also want to display this 30% inside ring?

    Reply
  34. Robert` DROP TABLE Students - - Posted on June 28, 2020 at 4:57 pm

    Very helpful 🙂

    Reply
  35. Al Rey Panilagao Posted on June 28, 2020 at 4:57 pm

    Arigatou Sensei

    Reply
  36. Eagle E Posted on June 28, 2020 at 4:57 pm

    This dude, is a boss. Fight me.

    Reply
  37. roul3688 Posted on June 28, 2020 at 4:57 pm

    I don't have my work PC with me to experiment so I'll ask… how could I add a textview in the middle of the ring showing the progress percentage in its numeric representation, ie "25%"?

    Reply
  38. moin Posted on June 28, 2020 at 4:57 pm

    Sir , how to change progressbar color from default color .

    Reply
  39. hashir hasan Posted on June 28, 2020 at 4:57 pm

    superb video (Y)

    Reply
  40. Alexander Scorpion Posted on June 28, 2020 at 4:57 pm

    Hi cloud u show how can i make this show negative progress ?

    Reply
  41. parvez rafi Posted on June 28, 2020 at 4:57 pm

    how do make the progress start from the top?

    Reply
  42. Vishesh Dubey Posted on June 28, 2020 at 4:57 pm

    How to animate it?

    Reply
  43. Amrit Singh Posted on June 28, 2020 at 4:57 pm

    Thanks Awesome Tricks

    Reply
  44. kavinraj bs Posted on June 28, 2020 at 4:57 pm

    How to add rounded edges to the ring like this (https://www.google.co.in/search?q=circular+rounded+progress+bar&source=lnms&tbm=isch&sa=X&ved=0ahUKEwiRhbavtJHdAhUBKY8KHRg7AEQQ_AUICigB&biw=1366&bih=635#imgrc=LU1r8YYlIW_g9M:)

    Reply
  45. gpealejandro00 Posted on June 28, 2020 at 4:57 pm

    I wasn't looking for this but it's amazing, I hadn't thought something like that

    Reply
LEAVE A COMMENT