[英]MBProgressHud and issues with the constraints
我正在嘗試使用MBProgressHud舉杯,這是代碼,
MBProgressHUD *hud = [MBProgressHUD showHUDAddedTo:view animated:YES];
[hud setMode:MBProgressHUDModeText];
[hud setLabelText:toastText];
hud.labelText.accessibilityLabel = toastText;
hud.yOffset = offset;
[hud hide:YES afterDelay:1.5f];
yoffset
可用於向下推烤面包。 這會有約束嗎? MBProgressHUD是否帶有布局約束。 我需要在屏幕上方顯示它,它應該適用於所有分辨率。
我最終使用了self.view.frame / 2-100,該分辨率對於項目支持的大多數屏幕分辨率都可以正常工作。
聲明:本站的技術帖子網頁,遵循CC BY-SA 4.0協議,如果您需要轉載,請注明本站網址或者原文地址。任何問題請咨詢:yoyou2525@163.com.