It's an honour to finially meet you.
- 😄
iOS
/OC
/Swift
/Python
- 🔭 I’m currently working on
JS
projects. - 🌱 I’m currently learning
Vue
/Java
. - 💬 Ask me about anything.
- 📫 How to reach me: [email protected]
- ...
FTPopOverMenu is a pop over menu for iOS which is maybe the easiest one to use. Supports both portrait and landscape. It can show from any UIView, any UIBarButtonItem and any CGRect.
License: MIT License
It's an honour to finially meet you.
iOS
/ OC
/ Swift
/ Python
JS
projects.Vue
/ Java
.I'd like to change the background to dark or light blur.
can you add this feature ?
if we are having the more amount of data, then how to set the static size data to scrollable dat.
i don't want to call the dismiss block when i click the another button.
menu高度能固定吗,像tableview一样,能上下滑动的?
添加了一个menuShowDefaultRows属性。
// FTConfiguration
public var menuShowDefaultRows:Int = 0
fileprivate func configurePopMenuFrame() {
//...
if (arrowDirection == .Up) {
popMenuFrame = CGRect(x: popMenuOriginX, y: (senderRect.origin.y + senderRect.size.height), width: configuration.menuWidth, height: popMenuHeight)
if configuration.menuShowDefaultRows > 0 {
let height = configuration.menuRowHeight * CGFloat(configuration.menuShowDefaultRows) + FTDefaultMenuArrowHeight
popMenuFrame = CGRect(x: popMenuOriginX, y: (senderRect.origin.y + senderRect.size.height), width: configuration.menuWidth, height: height)
}
}
}
使用文档里面写的 如果是 bar button item点击出来的pop,使用了show from event 方法,这个event 参数 有什么用,不是太懂,好像在item 的 action 方法里面 使用 show form sender view 也是可以的。
当设置coverBackgroundColor时,UI效果显示比较突兀一闪,体验不是很好
现在调整frame 的width 没有不管用 请问作者如何操作
如题,数据量多的情况下,整个menu的自动高度会特别长,实在难看,可否考虑下支持固定高度?
赞一个
如题,建议FTPopOverMenuConfiguration可以配置图标的大小
I meet a situation:
The menu show on the top of viewController, i can't touch the cell or the blank space to dismiss. But I can scroll the view below the menu.
The FTPopOverMenuConfiguration
is like below:
FTPopOverMenuConfiguration *configuration = [FTPopOverMenuConfiguration defaultConfiguration];
configuration.menuRowHeight = 50;
configuration.menuWidth = 200;
configuration.borderWidth = 0;
configuration.textFont = [UIFont systemFontOfSize:16];
configuration.textColor = UIColor.blackColor;
configuration.backgroundColor = [UIColor whiteColor];
configuration.shadowColor = [UIColor clearColor];
configuration.shadowRadius = 0;
configuration.shadowOpacity = 0;
configuration.shadowOffsetX = 0;
configuration.shadowOffsetY = 0;
configuration.ignoreImageOriginalColor = YES;
And the calling function is :
[FTPopOverMenu showForSender:titleButton
withMenuArray:titles
imageArray:nil
configuration:configuration
doneBlock:^(NSInteger selectedIndex) {
/// do something
}
dismissBlock:nil];
非常好的弹出菜单实现。
adjustPopOverMenu 里面计算高度没有用全局配置高度,会导致高度定制时候,总体高度不对。
另外,建议能实现直接传菜单图片数组,方便采用 FontAwesome。
我公司项目的组件依赖FTPopOverMenu,但是作者的FTPopOverMenu.podspec没有声明s.ios.deployment_target = '9.0',这样在pod install安装后FTPopOverMenu项目的iOS Deploment Target为iOS 4.3,编译会出错,希望作者早日加上这个设置。
PS: 目前通过修改Podfile脚本解决
post_install do |installer|
installer.pods_project.targets.each do |target|
target.build_configurations.each do |config|
config.build_settings['IPHONEOS_DEPLOYMENT_TARGET'] ='9.0'
end
end
end
i have multiple menu items but i want to change font color of one
e.g 在tableViewCell中,点击cell上某一个View,弹出此菜单控件,菜单显示期间,不影响tableView正常滑动等其他手势
rt,类似sd那样的多种缓存机制
会swift不会 oc 希望能出相对定位的功能。
UIBarButtonItem 获取不到frame。
我看内部使用的是UITableView,应该不支持吧
你这个做得很不错!但api属性不够灵活,属性命令应更贴近苹果的风格才好!
例如:
1,设置属性的不要用单例来控制,在不同界面有可能出现不同属性、色调;
2,FTPopOverMenuConfiguration应该当作一个属性来传;你现在这个如果我使用继承,在init去重设FTPopOverMenuConfiguration属性是无效,导致我每写一次都必须要跟着在+(void)show.....函数前写一大堆配置;
3,返回参数应该返回本类,然后可以通过返回实例再修改对应的popview属性;
4,我想改个背景色,这个情况下应该叫backgroundcolor更恰当,而不是tintColor;backgroundView这个背景颜色也没法改。
个人使用后的一些建议,谢谢!
does FTPopOverMenu support tvOS?
如题,目前都是竖直方向的。
可否增加横向的显示,目前使用这个项目感觉很好,希望作者进一步支持。
看了下代码,设的值不对,应该把selectedCellBackgroundColor设为cell的backgroundView的backgroundColor。
还有个建议,cover呈现和消失的时候如果能有点过渡效果会更好,改编透明度的uiview动画也可以。
现在只能传入图片地址, 而不能传入UIImage,建议可以传入UIImage,以方便图片的多来源
hi! Now only can be single select,could support multiselect on the further?
默认选中第几个,这样的选项有办法实现吗,并且默认选中的菜单字体颜色由另外一个属性去赋值
这应该是一个bug
Hi
I am using checkmark tableview. But after click on row sometime Dismiss block calling instead of index selection. Please help
。
这个属性可以考虑添加到配置项目,目前是4,边距有点小。
看了一下,里面关于菜单的配置使用的是一个单例的configuration,显示菜单也是使用的单例menu。
建议考虑添加相互独立的menu菜单。可以保证在同一个页面弹出多个不同的菜单,而不同的菜单还可以有不同的样式(主要体现在背景色、文字颜色、宽度、高度等)。
大神啊!你这个view显示的时候,我再添加view到window上,怎么调都是被你的view挡住,你在那里设置的啊!没找到啊!原谅我的无知。
当菜单项很多,出现滚动条时,滚动到底部时,会发现多了一项“菜单”(没有任何内容,但有空白位置),这应该是个bug,请作者修复。
A declarative, efficient, and flexible JavaScript library for building user interfaces.
🖖 Vue.js is a progressive, incrementally-adoptable JavaScript framework for building UI on the web.
TypeScript is a superset of JavaScript that compiles to clean JavaScript output.
An Open Source Machine Learning Framework for Everyone
The Web framework for perfectionists with deadlines.
A PHP framework for web artisans
Bring data to life with SVG, Canvas and HTML. 📊📈🎉
JavaScript (JS) is a lightweight interpreted programming language with first-class functions.
Some thing interesting about web. New door for the world.
A server is a program made to process requests and deliver data to clients.
Machine learning is a way of modeling and interpreting data that allows a piece of software to respond intelligently.
Some thing interesting about visualization, use data art
Some thing interesting about game, make everyone happy.
We are working to build community through open source technology. NB: members must have two-factor auth.
Open source projects and samples from Microsoft.
Google ❤️ Open Source for everyone.
Alibaba Open Source for everyone
Data-Driven Documents codes.
China tencent open source team.