这里将创建一个自定义的Panel,命名为TestPanel。
如果单机了TestPanel的标题,则有事件headerClick进行响应。
<s:Panel xmlns:fx="http://ns.adobe.com/mxml/2009"
xmlns:s="library://ns.adobe.com/flex/spark"
xmlns:mx="library://ns.adobe....
分类:
其他好文 时间:
2014-04-29 13:46:20
阅读次数:
435
windows下面可以主线程while loop接受input;但是觉得很丑。
linux没办法这样,可以用注册信号的办法。实现起来也不难:
#include "stdio.h"
#include "unistd.h"
#include "signal.h"
#include "error.h"
volatile bool isStop = false;
static void handl...
分类:
其他好文 时间:
2014-04-29 13:42:21
阅读次数:
418
有时候我们会需要在界面上拖动view;uiview是继承于uiresponder的,所以可以响应触摸相关的事件。
重点是以下一组方法:
- (void)touchesBegan:(NSSet *)touches withEvent:(UIEvent *)event
- (void)touchesMoved:(NSSet *)touches withEvent:(UIEvent...
分类:
移动开发 时间:
2014-04-29 13:41:20
阅读次数:
485
- (CGFloat)folderSizeAtPath:(NSString *) folderPath
{
NSFileManager * manager = [NSFileManager defaultManager];
if (![manager fileExistsAtPath:folderPath])
{
return 0;
...
分类:
移动开发 时间:
2014-04-29 13:36:20
阅读次数:
379
在windows下运行VMware创建的虚拟机时出错,无法运行。
错误提示大概为:
Failed to lock the file
Cannot open the disk 'D:\Windows Server 2008 R2 x64.vmdk' or one of the snapshot disks it depends on.
解决方法:
把虚拟机文件夹里【.lck】...
分类:
其他好文 时间:
2014-04-29 13:28:21
阅读次数:
366
在监控线上系统时,需要实时监控异常日志信息。...
分类:
其他好文 时间:
2014-04-29 13:27:20
阅读次数:
320
#include
#include
#include
#include
int main() {
int i,v;
char bs[33];
char b[33];
char hs[9];
char h[9];
char s[4];
char *e;
// 十进制整数转二进制串;
i=1024;
ltoa(i,b,2...
分类:
其他好文 时间:
2014-04-29 13:26:21
阅读次数:
485
习惯了用apache后,当第一次用nginx时,把原来的项目(thinkphp框架)部署在新服务器上的时候,惊呆了!
所有的URL模式下都不能正常运行,甚至连css,js文件都不能正常加载。
原因是ngibx不支持pathinfo
主要是需要配置nginx
location / {
root D:/wnmp/www;
index ind...
分类:
Web程序 时间:
2014-04-29 13:11:20
阅读次数:
680