This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
<style> | |
.tips_layer_wrap { | |
position: absolute; | |
top: 0; | |
left: 0; | |
width: 100%; | |
height: 100%; | |
background: rgba(0, 0, 0, .7); | |
z-index: 10000; | |
} |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
- (NSArray *)datas { | |
if (_datas == nil) { | |
NSMutableArray *temp = [NSMutableArray array]; | |
NSString *path = [[NSBundle mainBundle] pathForResource:@"apps.plist" ofType:nil]; | |
NSArray *arr = [NSArray arrayWithContentsOfFile:path]; | |
for (NSDictionary *dict in arr) { | |
CellData *data = [CellData dataWithDict:dict]; | |
[temp addObject:data]; | |
} |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
$('someUlSelector').delegate('someLiSelector', 'click', function() { | |
//codes... | |
//$(this) for the current jquery instance of the element | |
}); |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
// | |
// TableViewController.m | |
// 多图下载 | |
// | |
#import "TableViewController.h" | |
#import "KMCGeigerCounter.h" | |
#import "CellData.h" | |
@interface TableViewController () |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
//预加载 jQuery版本 | |
!(function() { | |
var preloader = function(opts) { | |
var _this = this; | |
_this.files = opts.files; | |
_this.current = 0; | |
_this.progress = opts.progress; | |
_this.complete = opts.complete; | |
_this.container = document.createElement("div"); | |
_this.container.style.cssText = "position:absolute;left:-1000px;top:0;width:1px;height:1px;overflow:hidden"; |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
//1.创建url | |
NSString *urlStr=@"https://github.com/cnbin/insertDemo/archive/master.zip"; | |
urlStr =[urlStr stringByAddingPercentEscapesUsingEncoding:NSUTF8StringEncoding]; | |
NSURL *url=[NSURL URLWithString:urlStr]; | |
//2.创建请求 | |
NSMutableURLRequest *request=[NSMutableURLRequest requestWithURL:url]; | |
//3.创建会话(这里使用了一个全局会话)并且启动任务 | |
NSURLSession *session=[NSURLSession sharedSession]; |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
<!DOCTYPE html> | |
<html xmlns="http://www.w3.org/1999/xhtml"> | |
<head> | |
<meta http-equiv="Content-Type" content="text/html;charset=utf-8" /> | |
<title>居中分页DIV CSS DIVCSS5在线案例演示</title> | |
<style> | |
a { | |
text-decoration: none | |
} |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
- (void)animationBaseTest { | |
CABasicAnimation *baseAnimate = [CABasicAnimation animationWithKeyPath:@"transform.scale"]; | |
baseAnimate.toValue = @(0); | |
baseAnimate.duration = 0.8; | |
baseAnimate.repeatCount = MAXFLOAT; | |
baseAnimate.autoreverses = YES; | |
[self.heart.layer addAnimation:baseAnimate forKey:@"scaleAnimate"]; | |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
- (void)touchesBegan:(NSSet<UITouch *> *)touches withEvent:(UIEvent *)event { | |
CABasicAnimation *baseAnimate1 = [CABasicAnimation animationWithKeyPath:@"transform.scale"]; | |
baseAnimate1.toValue = @(0.1); | |
baseAnimate1.duration = 0.5; | |
CABasicAnimation *baseAnimate2 = [CABasicAnimation animationWithKeyPath:@"position"]; | |
baseAnimate2.toValue = [NSValue valueWithCGPoint:CGPointMake(0, 0)]; | |
baseAnimate2.duration = 0.5; | |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
// | |
// SvGridView.h | |
// SvSinglePixel | |
// | |
// Created by xiaoyong.cxy on 6/23/15. | |
// Copyright (c) 2015 smileEvday. All rights reserved. | |
// | |
#import <UIKit/UIKit.h> |