roxasora / rxwebviewcontroller Goto Github PK
View Code? Open in Web Editor NEW实现类似微信的 webView 导航效果,包括进度条,左滑返回上个网页或者直接关闭,就像 UINavigationController
实现类似微信的 webView 导航效果,包括进度条,左滑返回上个网页或者直接关闭,就像 UINavigationController
why you do this in viewDidDisappear method
self.webView.delegate = nil
iphone7真机与模拟器都无法侧滑返回,iphone6模拟器缺可以
如题,因为项目需要,要用自己的NavigationController,push的时候会闪动一下,有什么解决方案吗?ths
我写了个demo,模拟器上面可以正常运行,但是真机上面侧滑返回无效,iOS9.3系统,XCode7.3开发。是有什么要注意的没弄好吗?
模拟器会闪。。真机不会。。
抖动一下,是不是位置出现偏差导致的?正常的goback不会抖动的
self.shouldSnapshot = NO; self.enableHostInfo = NO;
原因是因为 -(instancetype)initWithUrl:(NSURL *)url
这个方法里有上面的设置,
但是我实在看不懂这两个属性怎么会影响到[self.webView stringByEvaluatingJavaScriptFromString:@""]
这句代码失效,还请指点一下。
self.navigationController.navigationBarHidden = YES 的时候 不会触发 -(BOOL)navigationBar:(UINavigationBar *)navigationBar shouldPopItem:(UINavigationItem *)item
所有 self.navigationController.navigationBarHidden = YES的页面 记得在pop之前要 self.navigationController.navigationBarHidden = NO;
就没事了
另外,有两个RxWebViewController文件夹。
直接在demo上运行,进入第二个页面之后右滑就失效了,只能点返回才能返回上一个页面。
Installing RxWebViewController (0.0.2)
Generating Pods project
Integrating client project
Sending stats
Pod installation complete! There are 22 dependencies from the Podfile and 24 total pods installed.
navigationBar.hidden在viewAppear与view Disappear里执行, 点击的返回按钮是自己写得,点击后发现 [self popViewControllerAnimated:YES]会执行2次,导致每次都POP到rootViewController。我尝试在拦截里通过navigationBar.hidden判断,但是没有效果。在这里我建议是否可以在跳到网页的时候,自己写一个navigation bar,然后在拦截里通过navigation bar的类型判断,当然这个navigation bar的样式依旧可以自定义,在这里非常感谢您提供了这么好用加载网页框架!
发现每一次进一次webview 内存大概增加10M 还没有来得及分析原因
fix bug
判断直接用的是webView.canGoBack属性,但如果当前push的RxWebViewController,所加载的页面是包含重定向的话,即加载A网页,自动跳转到B网页,canGoBack值会为真。此时点击【返回】按钮,则goBack加载A网页,自动跳B网页,相当于重新又加载了一遍B网页,无法pop出去了。
把当前VC设置setNavigationBarHidden为YES, 然后进入WebViewVC,点返回,页面返回当当前界面,再次进入,再点返回,页面就不会返回了,而且返回按钮也没用了!
//当前VC设置代码
非常喜欢这个项目,但是有很多BUG没有解决,如果R主没有太多精力来维护这个项目,建议添加几个合作者来完善这个项目。
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.