当前位置: 首页 > news >正文

建立网站一般经历的阶段/百度竞价推广是什么意思

建立网站一般经历的阶段,百度竞价推广是什么意思,做外贸搜客户的网站,图库素材1、不要直接在UIWindow里面直接使用UIView,而是加载根试图控制器(UIViewController)然后使用控制器改变UIView,这也是Apple官方推荐的方式 [self beginAppearanceTransition:YES animated:NO];[parentViewController addChildView…

1、不要直接在UIWindow里面直接使用UIView,而是加载根试图控制器(UIViewController)然后使用控制器改变UIView,这也是Apple官方推荐的方式

    

 [self beginAppearanceTransition:YES animated:NO];[parentViewController addChildViewController:self];[parentViewController.view addSubview:self.view];[self didMoveToParentViewController:self];[self endAppearanceTransition];

 

2、

在横屏应用中,使用keyWindow添加一个视图,切换设备横屏方向,发现添加的视图不会随着变化方向。

并且只有Window的RootViewController可以监听到屏幕旋转变化。

[[UIApplicationsharedApplication].keyWindow addSubview:view];

解决方法如下:

定义RotateWindow继承UIWindow,并重写addSubview方法。AppDelegate中的window使用RotateWindow。

#define degreesToRadian(x) (M_PI * (x) / 180.0)- (void)addSubview:(UIView *)view {if ([self.subviews count] >= 1) {float angle = ([UIDevice currentDevice].orientation == UIDeviceOrientationLandscapeLeft)?90:-90;view.transform = CGAffineTransformMakeRotation(degreesToRadian(angle));view.frame = CGRectOffset(self.frame, 0, 0);}[super addSubview:view];
}

定义RotateViewController作为window的RootViewController,并重写以下方法

// 仅允许横屏
- (BOOL)shouldAutorotateToInterfaceOrientation:(UIInterfaceOrientation)interfaceOrientation {// Return YES for supported orientations.return (interfaceOrientation == UIInterfaceOrientationLandscapeLeft || interfaceOrientation == UIInterfaceOrientationLandscapeRight);
}// 设备旋转时修改添加视图方向
- (void)willRotateToInterfaceOrientation:(UIInterfaceOrientation)toInterfaceOrientation duration:(NSTimeInterval)duration {UIWindow *window = [UIApplication sharedApplication].keyWindow;int i = 0;for (UIView *view in window.subviews) {if (i != 0) {CGAffineTransform transform = view.transform;transform = CGAffineTransformRotate(transform,  degreesToRadian(180));view.transform = transform;}i++;}
}3、方法:
-(void)rotateView 
{ 
UIWindow *keywindow = [[UIApplication sharedApplication] keyWindow]; 
UIView *bgView = [[UIView alloc] initWithFrame:keywindow.bounds]; 
[keyWindow addSubview:bgView]; 
[bgView release]; [bgView addSubview:_overlayView]; 
[bgView addSubview:self]; 
self.center = CGPointMake(keywindow.bounds.size.width/2.0f, 
keywindow.bounds.size.height/2.0f); // Rotate the image by the specific angle. 
[bgView setTransform:CGAffineTransformMakeRotation(angle)]; [self fadeIn]; 
} 

出自:http://blog.csdn.net/leikezhu1981/article/details/38072221

转载于:https://www.cnblogs.com/mgy007/p/4718679.html

http://www.jmfq.cn/news/5107573.html

相关文章:

  • 某企业管理系统/搜索引擎优化时营销关键词
  • 网站制作一条龙/免费网站在线观看人数在哪
  • 刚做的网站搜索不到/谷歌浏览器下载安装2022最新版
  • 如何建设一个电影网站/网站百度收录批量查询
  • 响应式网站怎么做/郑州百度seo关键词
  • 北京市昌平区社会建设网站/设计培训班学费一般多少
  • 广州app网站建设/宁波谷歌seo推广
  • 网站建设与管理资料下载/百度问一问付费咨询
  • 建筑设计院/提高seo排名
  • 网站是怎么盈利的/模板建站和开发网站区别
  • 德化规划与建设局网站/抖音优化公司
  • 做网站开发怎么接单/百度推广登陆平台登录
  • 有回定ip怎么做网站/网络销售 市场推广
  • 自己做网站除了域名还要买什么/网站联盟营销
  • 电子商务网站建设的概要设计/百度网址提交入口平台
  • 贵州网站开发公司/网络营销成功的案例及其原因
  • 一家只做正品的网站/品牌宣传策略有哪些
  • 网站建设所需物资/关键词收录查询工具
  • 牛二网站建设/网站运营包括哪些内容
  • 网站开发公司创业策划/济南网络推广网络营销
  • 中国最近军事新闻视频/seo规则
  • seo做得好的企业网站/营销活动策划方案
  • 海南网站搭建/石家庄百度快照优化
  • 素材网站的素材可以商用吗/百度统计代码安装位置
  • 监控摄像机网站建设/深圳百度百科
  • 鲅鱼圈网站开发/企业课程培训
  • 网站建设优化哪家好/推广普通话手抄报模板可打印
  • 做网站建设费用预算/怎样申请网站注册
  • 做电影资源网站有哪些内容/seo兼职外包
  • 向网站服务器上传网页文件下载/广告策划书