zoukankan      html  css  js  c++  java
  • 获取网络图片的宽高

    headerImageView.contentMode = UIViewContentModeScaleAspectFit;

    [headerScrollView addSubview:headerImageView];
     
    int imgWidth = headerImageView.image.size.width;
                    int imgHight = headerImageView.image.size.height;
                     
                    int aWidth = headerImageView.image.size.width/headerImageView.frame.size.width;
                     
                    int LastWidth = imgWidth/aWidth;
                    int LastHight = imgHight/aWidth;
     
    //视频暂停图片
                    UIImageView *imageee = [[UIImageView alloc] initWithFrame:CGRectMake((SCREEN_WIDTH-100)/2, (SCREEN_HEIGHT-100)/2, 370/2, 310/2)];
                    imageee.image = LOAD_IMAGE(@"newhouse_mov_stop");
                    imageee.center = headerImageView.center;
                    [headerScrollView addSubview:imageee];
                     
                    UIButton *movbtn = [[UIButton alloc] initWithFrame:CGRectMake(0+i*SCREEN_WIDTH, 0, LastWidth, LastHight)];
                    movbtn.backgroundColor = [UIColor clearColor];
                    movbtn.tag = 400+i;
                    [movbtn addTarget:self action:@selector(doBoFang:) forControlEvents:UIControlEventTouchUpInside];
                    movbtn.center = headerImageView.center;
                    [headerScrollView addSubview:movbtn];
  • 相关阅读:
    android自动登录
    【199】ArcGIS 添加自定义工具到工具箱
    【198】Synergy
    【197】PowerShell 通过 FTP 下载文件
    【196】Dell 移动工作站系统安装方法
    php如何同时连接多个数据库
    FreeRTOS学习笔记——任务间使用队列同步数据
    牛腩新闻发布系统之发布
    Linux散列表(二)——宏
    Excel导入数据库(三)——SqlBulkCopy
  • 原文地址:https://www.cnblogs.com/-ios/p/4669737.html
Copyright © 2011-2022 走看看