使用quick时自己封装的类存放于特定的目录,便于以后使用
下面是作者经常用到的一个按钮local MyButton = class("MyButton")
function MyButton:ctor(params,scene,listener)
self.button = nil
local time = 0.1
local offset = 40
self.b...
分类:
其他好文 时间:
2015-03-17 12:27:35
阅读次数:
127
1. Mysql的limit用法在我们使用查询语句的时候,经常要返回前几条或者中间某几行数据,这个时候怎么办呢?不用担心,mysql已经为我们提供了这样一个功能。Sql代码1 SELECT * FROM table LIMIT [offset,] rows | rows OFFSET offset ...
分类:
数据库 时间:
2015-03-17 11:51:59
阅读次数:
234
#include void *mmap(void *addr, size_t length, int prot, int flags,int fd, off_t offset); int munmap(void *addr, size_t length);mmap,存储映射,将文件映射...
分类:
其他好文 时间:
2015-03-16 15:54:30
阅读次数:
164
#define XTAL_FREQ 12000000#define VECT_TAB_OFFSET 0x0000void SystemInit(void){ //PLL0时钟配置 LPC_SC->SCS = 0X00000020; /*使能外部主晶振,频率范围1-20M*/ if (LPC_SC->...
分类:
其他好文 时间:
2015-03-15 02:02:41
阅读次数:
282
第一种方式是直接使用锚点配合链接标签:
Scroll to here
Jump to H2
现在大多数实现都采用该种方式。但是这种方式没有动画效果,跳转是直接发生的。
第二种方式使用jQuery中的animate方法实现:
var target= $('#h2-anchor').offset().top;
$('body').animate({scrollTop...
分类:
Web程序 时间:
2015-03-14 12:29:07
阅读次数:
154
新项目使用的是ECSHOP的程序,用的PHP版本比较高,导致错误一片,普通错误写法修改下就可以解决,但针对PHP Warning:Illegal string offset,百度了几次都未解决,最后添加一个判断解决问题,避开此错误if(is_array($arrVar)){语句}
分类:
Web程序 时间:
2015-03-14 06:09:42
阅读次数:
155
int fseek(FILE *stream, long offset, int fromwhere);fseek 用于二进制方式打开的文件,移动文件读写指针位置.int fseek( FILE *stream, long offset, int origin );第一个参数stream为文件指针第...
分类:
其他好文 时间:
2015-03-12 22:26:58
阅读次数:
100
开发板上的nand flash写不了,擦除不了:Bad block at 0xxxxx in erase block from 0xxxxx will be skipped……解决方法:nand scrub$(offset) $(size)yenter删除标记的坏块,这样就把整个flash格式化了....
分类:
其他好文 时间:
2015-03-12 00:53:17
阅读次数:
156
/*1.获取当前元素的索引值*/var index=$(this).parent().children().index(this);/*2.某个区域滑动到窗口顶部*/$("html,body").scrollTop($("dom").offset().top,500);$("html,body")....
分类:
Web程序 时间:
2015-03-10 13:56:40
阅读次数:
140
代码如下
Shader "Custom/Curved" {
Properties {
_MainTex ("Base (RGB)", 2D) = "white" {}
_QOffset ("Offset", Vector) = (0,0,0,0)
_Brightness ("Brightness", Float) = 0.0
_Dist ("Distance",...
分类:
编程语言 时间:
2015-03-10 12:16:48
阅读次数:
3504