What is the difference between PopUpWindow and Dialog?

后端 未结 3 1471
小蘑菇
小蘑菇 2021-02-13 04:07

Basically the question is stated in the title. Any preferences in using one or another? Maybe some specific tasks where one is superior/ more efficient/ better than the other?

3条回答
  •  有刺的猬
    2021-02-13 04:44

    Dialog is designed for taking controlled action on popup events where you need to take action before proceed to continue next. It's auto-adjustable with the screen at center aligned manner.

    But PopupWindow is informative popup which deals as layout. It can be shown anywhere in the screen as per position set and You can also use this with animated form as there is animation facility also with it.

    So if you are looking for just show the information in popup then I suggest use PopupWindow and if you want some action control like "YES", "No" or any decision making action then go with Dialog.

提交回复
热议问题