Giter VIP home page Giter VIP logo

hypopmenuview's Introduction

Hi there 👋

  • 🤔 I have a blog
  • 🌱 I’m currently learning PLT.

hypopmenuview's People

Contributors

wwdc14yh avatar

Stargazers

 avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar

Watchers

 avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar

hypopmenuview's Issues

咨询

菜鸟一个,已经集成了您的三方库,效果很好,但是如何添加代码当点击图标时,会跳到其它页面,而不是返回

Context not created!

我在运行时会报错,<UIVisualEffectView 0x7ffda0513380> is being asked to animate its opacity. This will cause the effect to appear broken until opacity returns to 1.
Context not created!
求问什么原因...

iOS11 上崩溃

点击按钮 崩溃在 HyPopMenuView.m 的 118 行

报错如下:
Terminating app due to uncaught exception 'NSInternalInconsistencyException', reason: '<popMenvTopView: 0x7fbaed70ca80; frame = (0 44; 375 92); autoresize = W+H; layer = <CALayer: 0x60400042a400>> has been added as a subview to <UIVisualEffectView: 0x7fbaed404a50; frame = (0 0; 375 667); layer = <CALayer: 0x60000003f9a0>>. Do not add subviews directly to the visual effect view itself, instead add them to the -contentView.'

弹出菜单后,点击选项,发现并不是所有的都有放大的动画

HyPopMenuView.m 文件内,- (void)selectedFunc:(PopMenuButton *)sender 方法有问题

 NSLog(@"点击按钮的标题>>>>>>>>>>>>>>>>>>>>>>>>%@", sender.model.titleString);

// sender.layer.cornerRadius = CGRectGetWidth(sender.frame)/2;
// sender.backgroundColor = [UIColor redColor];
//UIWindow window = (id)[self getMainView];
__weak HyPopMenuView
weakView = self;
for (PopMenuModel obj in _dataSource) {
PopMenuModel
model = obj;
NSLog(@"遍历到的按钮>>>>>>>>>>>>%@", obj.titleString);
PopMenuButton* button = (id)model.customView;
if (sender == button) {
[sender selectdAnimation];
}else{
[button cancelAnimation];
}
dispatch_after(dispatch_time(DISPATCH_TIME_NOW, (int64_t)(1 * NSEC_PER_SEC)), dispatch_get_main_queue(), ^{
[model performSelector:@selector(_obj)];
});
}
其中的判断方式,sender == button, 并不安全
image
sender 地址出现重复,放大效果有问题。

IOS8.0 swift 点击menu button后 delegate没有被调用

public func popMenuView(popMenuView: HyPopMenuView!, didSelectItemAtIndex index: UInt) {
}

点击menu button之后,上面的delegate没被调用, 不知道什么问题。Debug的时候,显示下面方法里的这个if条件不满足: if ([weakView.delegate respondsToSelector:@selector(popMenuView:didSelectItemAtIndex:)])

  • (void)selectedFunc:(PopMenuButton_)sender
    {
    _weak HyPopMenuView weakView = self;
    [_dataSource enumerateObjectsUsingBlock:^(id _Nonnull obj, NSUInteger idx, BOOL* _Nonnull stop) {
    PopMenuModel* model = obj;
    PopMenuButton* button = (id)model.customView;
    if (sender == button) {
    [sender selectdAnimation];
    }
    else {
    [button cancelAnimation];
    }
    dispatch_after(dispatch_time(DISPATCH_TIME_NOW, (int64_t)(0.4 * NSEC_PER_SEC)), dispatch_get_main_queue(), ^{
    [model performSelector:@selector(_obj)];
    });
    }];
    NSUInteger idx = [_dataSource indexOfObject:sender.model];
    dispatch_after(dispatch_time(DISPATCH_TIME_NOW, (int64_t)(0.2f * NSEC_PER_SEC)), dispatch_get_main_queue(), ^{
    if (weakView.delegate) {
    if ([weakView.delegate isKindOfClass:[[weakView currentViewController] class]]) {
    if ([weakView.delegate respondsToSelector:@selector(popMenuView:didSelectItemAtIndex:)]) {
    [weakView.delegate popMenuView:weakView didSelectItemAtIndex:idx];
    }
    }
    else {
    NSLog(@"不在同一个控制器");
    }
    }
    });
    [UIView animateWithDuration:0.2 animations:^{
    weakView.bottomView.backgroundColor = [UIColor clearColor];
    weakView.disappearButton.transform = CGAffineTransformMakeRotation(0);
    [weakView.disappearButton setAlpha:0.1f];
    }];

    [UIView animateKeyframesWithDuration:0.5 delay:0.2f options:0 animations:^{
    weakView.backgroundView.alpha = 0.0;
    }
    completion:^(BOOL finished) {

        [weakView.backgroundView removeFromSuperview];
        [window setHidden:finished];
    }];
    

    }

这不是一个issues!

了解到你现在在找工作,我们公司也在招聘ios高级工程师,是否愿意留电话号码?

菜单上的button出现异常

我把demo里viewController 里的代理方法里面的内容屏蔽掉,如下

  • (void)popMenuView:(HyPopMenuView*)popMenuView
    didSelectItemAtIndex:(NSUInteger)index
    {
    // UIViewController* t =
    // [self.storyboard instantiateViewControllerWithIdentifier:@"two"];
    // [self.navigationController pushViewController:t animated:false];
    }
    然后点击加号弹出菜单,点击菜单上的button,菜单消失。连续重复操作,界面就出现了下面的状况
    image
    。。图片显示不了 我描述一下吧,就是菜单上只剩下当前点的button。其他的没有了。再次点击加号后,菜单上一闪而过所有button。

行数计算错误

HyPopMenuView.m M327
NSUInteger toRows = (_dataSource.count / column);
Demo中有6个按钮,6/3=2行是正确的,如果只有5个按钮5/3=1结果是一行,整个位置会发生错误。
需要改为
NSUInteger toRows = (_dataSource.count / column) + ((_dataSource.count % column) ? 1 : 0);

iOS适配问题

在iOS9下presentViewController会提示unexpected nil window in _UIApplicationHandleEventFromQueueEvent, _windowServerHitTestWindow: (null),希望修复一下window的使用。

Swift

@wwdc14 i converted this project to swift and it all works great but the top view won't appear. I tried everything and added the view as well. Could you take a look at it if I send you the swift project

导入报错

导入Pop运行都没问题,一导入HyPopMenuView那六个文件就报错,编译过不了……"OBJC_CLASS$_POPSpringAnimation", referenced from: objc-class-ref in HyPopMenuView.o

Recommend Projects

  • React photo React

    A declarative, efficient, and flexible JavaScript library for building user interfaces.

  • Vue.js photo Vue.js

    🖖 Vue.js is a progressive, incrementally-adoptable JavaScript framework for building UI on the web.

  • Typescript photo Typescript

    TypeScript is a superset of JavaScript that compiles to clean JavaScript output.

  • TensorFlow photo TensorFlow

    An Open Source Machine Learning Framework for Everyone

  • Django photo Django

    The Web framework for perfectionists with deadlines.

  • D3 photo D3

    Bring data to life with SVG, Canvas and HTML. 📊📈🎉

Recommend Topics

  • javascript

    JavaScript (JS) is a lightweight interpreted programming language with first-class functions.

  • web

    Some thing interesting about web. New door for the world.

  • server

    A server is a program made to process requests and deliver data to clients.

  • Machine learning

    Machine learning is a way of modeling and interpreting data that allows a piece of software to respond intelligently.

  • Game

    Some thing interesting about game, make everyone happy.

Recommend Org

  • Facebook photo Facebook

    We are working to build community through open source technology. NB: members must have two-factor auth.

  • Microsoft photo Microsoft

    Open source projects and samples from Microsoft.

  • Google photo Google

    Google ❤️ Open Source for everyone.

  • D3 photo D3

    Data-Driven Documents codes.