Puas yog ProgressDialog deprecated?
Puas yog ProgressDialog deprecated?

Video: Puas yog ProgressDialog deprecated?

Video: Puas yog ProgressDialog deprecated?
Video: "Puag Yoj Mas" [OFFICIAL MUSIC VIDEO] - KT Killing Em 2024, Kaum ib hlis
Anonim

ProgressDialog Qhov zoo tuaj yeem rov ua dua los ntawm kev tso ProgressBar rau hauv AlertDialog. Koj tseem tuaj yeem siv nws, tab sis Android tsis xav kom koj siv nws, yog vim li cas nws yog tsis pom zoo.

Tsis tas li ntawd, vim li cas ProgressDialog tsis raug tso cai?

" Deprecated " hais txog cov haujlwm lossis cov ntsiab lus uas tau hloov los ntawm cov tshiab. ProgressDialog yog modal dialog, uas tiv thaiv tus neeg siv los ntawm kev cuam tshuam nrog lub app. Hloov chaw ntawm kev siv cov chav kawm no, koj yuav tsum siv qhov ntsuas kev nce qib xws li ProgressBar, uas tuaj yeem kos rau hauv koj lub app's UI.

Dab tsi yog kev nce qib dialog hauv Android? Android ProgressDialog yog a dialog lub thawv / dialog qhov rais uas qhia cov kev vam meej ntawm ib txoj haujlwm. Android Progress Dialog yuav luag zoo ib yam li ProgressBar nrog rau qhov tshwj tsis yog tias qhov no tshwm sim ua ib qho dialog lub thawv. Yuav kom tsim tau ib ProgressDialog los tso saib ib qho ProgressBar peb yuav tsum tau instantiate nws zoo li no.

Tom qab ntawd, kuv tuaj yeem siv dab tsi los ntawm ProgressDialog?

Koj ua tau siv ProgressBar tsis yog ProgressDialog . Tsim ib qho ProgressBar hauv kev cai sib tham nrog TextView thiab lwm yam widget uas koj xav tau.

Dab tsi yog kev siv qhov nce qib hauv Android?

Hauv Android , ProgressBar yog siv los tso saib cov xwm txheej ntawm kev ua haujlwm ua tiav xws li kev txheeb xyuas cov xwm txheej ntawm kev ua haujlwm lossis rub tawm cov ntaub ntawv thiab lwm yam hauv Android , los ntawm default a kev nce qib bar yuav muab tso tawm kom pom raws li lub log tig tab sis Yog tias peb xav kom nws tso tawm kom pom raws li kab rov tav bar ces peb yuav tsum tau siv style attribute raws li kab rov tav.

Pom zoo: