小编Fai*_*tar的帖子

用于Cocoapods库的架构armv7的未定义符号

我偶然发现了一个我需要处理的项目问题.该项目使用Cocoapods来管理其库.我pod install像往常一样开始运行,但xcode给了我错误.我得到了Undefined symbols for architecture armv7你在下面的图片中看到的:

在此输入图像描述

所有这些符号都是我用于项目的库.例如.AFNetworking,RNBlurModalView.我试图从项目中删除所有Cocoapods相关文件并pod install再次运行,但它仍然无法解决问题.

到目前为止我做了什么:

  • 清理项目并重新构建.
  • 删除Cocoapods相关文件并pod install再次运行.
  • 试图在Project Target中的Compile Sources中添加类,但不能.该类位于Pods工作区中.
  • 设置编译有源体系仅从YESNO.

我也尝试了同样问题的解决方案,但没有一个对我有用.

如果它有帮助,我正在使用xCode6和Cocoapods 0.34.4.项目有效的架构是armv7 and armv7s.

更新:运行时pod install --verbose

Integrating client project

Integrating target `Pods` (`AIYOCore.xcodeproj` project)

[!] The use of implicit sources has been deprecated. To continue using all of the sources currently on your machine, add the following to the top of your Podfile: …
Run Code Online (Sandbox Code Playgroud)

xcode armv7 ios cocoapods xcode-project

29
推荐指数
1
解决办法
1万
查看次数

WISWebView内部UIScrollView:滚动冲突

上下文

我有一个WKWebView我以编程方式嵌入一个UIView,这UIView是嵌入在一个UIScrollView.

想象:

场景的视图层次结构

这是我所做的简化版本:

UIScrollView
|
+---- UIView
|    |
|    +-- UIButton
|    |
|    +-- UILabel
|
+---- UIView
     |
     +-- WKWebView
Run Code Online (Sandbox Code Playgroud)

我不希望WKWebView滚动,我通过在页面上注入以下脚本来禁用它.

document.ontouchmove = function(event) { event.preventDefault(); }
Run Code Online (Sandbox Code Playgroud)



问题

目前,当我点击内部时滚动不起作用WKWebView.但是一旦我回到UIView上面,我就可以再次滚动.我在附件中附上了一个GIF.红色部分是WKWebView绿色部分UIView.


滚动问题



我做了什么

  1. 我已禁用滚动使用scrollEnabled,它不起作用,因为我仍然可以滚动WKWebview.

    webView.scrollView.scrollEnabled = false
    webView.scrollView.bounces = false
    
    Run Code Online (Sandbox Code Playgroud)
  2. 加载网页后注入以下javascript(当前解决方案)

    document.ontouchmove = function(event) { event.preventDefault(); }
    
    Run Code Online (Sandbox Code Playgroud)
  3. UITableViewController对视图使用静态,但我仍遇到同样的问题.


参考文献:

webkit uiwebview uiscrollview ios wkwebview

5
推荐指数
1
解决办法
2823
查看次数