1 Star 0 Fork 0

shede333 / BMAlertHud

加入 Gitee
与超过 1200万 开发者一起发现、参与优秀开源项目,私有仓库也完全免费 :)
免费加入
克隆/下载
贡献代码
同步代码
取消
提示: 由于 Git 不支持空文件夾,创建文件夹后会生成空的 .keep 文件
Loading...
README
MIT

BMAlertHud

create by shede333

模仿系统的 UIAlertView ,但是 UIAlertView 不支持title 和 message 的文本格式自定义化;
所以就仿照系统的 UIAlertView 原始功能,支持使用 NSAttributedString ,这样就可以自定义文本格式了,效果如下图;

###支持的功能:

  • 支持 叠加 的弹出 多个 Alert框;
  • 适配 iOS6、7、8
  • 弹框支持随着屏幕的 方向旋转而旋转

###使用方式

很简单,就一行代码,直接调用 BMAlertHud里的 静态方法即可

注意
除了把 BMAlertHud文件夹拷贝过去加入你的工程里,还要记得把 ThirdParty文件夹也要拷贝过去加入你的工程里,因为 ThirdParty里面是我依赖的第三方库

###Other

当然,你也可以再次基础上,重写 BMAlertView 实现自己的AlertView,而其余的弹出、隐藏、旋转、适配等工作,你都可以不用做了。

###未实现的功能

  • 目前支持0、1、2个按钮,3个以上的按钮暂不支持
  • 当AlertHud设置为不支持旋转时,弹框只支持一个方向

###参考

iOS系统自带的 UIAlertView 以及 屏幕自动旋转的实现

图片丢失

图片丢失

The MIT License (MIT) Copyright (c) 2013 shede333 Permission is hereby granted, free of charge, to any person obtaining a copy of this software and associated documentation files (the "Software"), to deal in the Software without restriction, including without limitation the rights to use, copy, modify, merge, publish, distribute, sublicense, and/or sell copies of the Software, and to permit persons to whom the Software is furnished to do so, subject to the following conditions: The above copyright notice and this permission notice shall be included in all copies or substantial portions of the Software. THE SOFTWARE IS PROVIDED "AS IS", WITHOUT WARRANTY OF ANY KIND, EXPRESS OR IMPLIED, INCLUDING BUT NOT LIMITED TO THE WARRANTIES OF MERCHANTABILITY, FITNESS FOR A PARTICULAR PURPOSE AND NONINFRINGEMENT. IN NO EVENT SHALL THE AUTHORS OR COPYRIGHT HOLDERS BE LIABLE FOR ANY CLAIM, DAMAGES OR OTHER LIABILITY, WHETHER IN AN ACTION OF CONTRACT, TORT OR OTHERWISE, ARISING FROM, OUT OF OR IN CONNECTION WITH THE SOFTWARE OR THE USE OR OTHER DEALINGS IN THE SOFTWARE.

简介

模仿系统的UIAlertView,但是支持文本格式定制 展开 收起
Objective-C
MIT
取消

发行版

暂无发行版

贡献者

全部

近期动态

加载更多
不能加载更多了
Objective-C
1
https://gitee.com/shede333/BMAlertHud.git
git@gitee.com:shede333/BMAlertHud.git
shede333
BMAlertHud
BMAlertHud
master

搜索帮助