AYGestureHelpView 0.2.0

AYGestureHelpView 0.2.0

测试已测试
Lang语言 Obj-CObjective C
许可证 MIT
发布最后发布2015年11月

Ayan Yenbekbay 维护。



  • Ayan Yenbekbay

一个可以显示手势教程的视图。

AYGestureHelpView

使用方法

您可以为单一手势显示教程。

AYGestureHelpView *helpView = [AYGestureHelpView new];
[helpView doubleTapWithLabelText:NSLocalizedString(@"Double tap to open the menu", nil) labelPoint:CGPointMake(self.view.center.x, self.view.center.y + 70) touchPoint:self.view.center dismissHandler:nil hideOnDismiss:YES];

或您可以链式调用手势。

AYGestureHelpView *helpView = [AYGestureHelpView new];
[helpView doubleTapWithLabelText:NSLocalizedString(@"Double tap to open the menu", nil) labelPoint:CGPointMake(self.view.center.x, self.view.center.y + 70) touchPoint:self.view.center dismissHandler:^{
  [helpView swipeWithLabelText:NSLocalizedString(@"Swipe to scroll through cards", nil) labelPoint:CGPointMake(self.view.center.x, self.view.center.y + 70) touchStartPoint:CGPointMake(self.view.center.x + 25, self.view.center.y) touchEndPoint:CGPointMake(self.view.center.x - 25, self.view.center.y) dismissHandler:^{
    [helpView swipeWithLabelText:NSLocalizedString(@"Pull down to refresh", nil) labelPoint:CGPointMake(self.view.center.x, self.view.center.y + 70) touchStartPoint:CGPointMake(self.view.center.x, self.view.center.y - 50)  touchEndPoint:self.view.center dismissHandler:nil hideOnDismiss:YES];
  } hideOnDismiss:NO];
} hideOnDismiss:NO];

安装

AYGestureHelpView 通过 CocoaPods 提供。要安装它,只需将以下行添加到您的 Podfile 中:

pod "AYGestureHelpView"

作者

Ayan Yenbekbay, [email protected]

许可证

Copyright (c) 2015 Ayan Yenbekbay <[email protected]>

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.