现在位置: 首页 > veni发表的所有文章
  • 10月
  • 09日
移动开发 ⁄ 共 1841字 评论关闭
文本转自:http://blog.csdn.net/nandai136/article/details/12106091?reload 最近,画UI的时候用到了CheckBox,系统自带的样式美观方面实在不怎么给力。所以就需要自定义图片了。 两种状态,使用selector 轻松搞定。当时,我是这么想的,结果意外发生了。点击时候图片不变化,并且实际的check点击事件还是正常的。 最初我是这么写的: [html] view plaincopy <?xml version="1.0" encoding="utf-8"?>      <selector xmlns:android="http://schemas.android.com/apk/res/android">          <i......
阅读全文
  • 10月
  • 01日
综合 ⁄ 共 148字 评论关闭
有四对夫妻共度一个欢乐的夜晚,他们的名字是伊丽莎白,珍妮,玛丽,安妮,亨利,彼得,路易斯和罗杰。在某个时刻: 亨利的妻子不是与自己的丈夫在跳舞,而是与伊丽莎白的丈夫在跳舞; 罗杰与安妮不在跳舞; 彼得在吹小号,而玛丽在弹钢琴; 如果安妮的丈夫不是彼得,那么罗杰的妻子是哪一位? 时间限制3分钟,答案见评论。
阅读全文
  • 08月
  • 22日
综合 ⁄ 共 704字 评论关闭
   self.nav = [[[NavViewController alloc] initWithRootViewController:self.viewController] autorelease];    [self.nav.navigationBar setBackgroundImage:[UIImage imageNamed:@"navbg"] forBarMetrics:UIBarMetricsDefault];    NSDictionary *dict = [NSDictionary dictionaryWithObjectsAndKeys:[UIColor whiteColor],UITextAttributeTextColor,[UIColor blackColor],UITextAttributeTextShadowColor,[UIFont boldSystemFontOfSize:20.0],UITextAttributeFont,CGSizeMake(0, -1.0),UITextAttributeTextShadowOffset, nil......
阅读全文
  • 04月
  • 15日
综合 ⁄ 共 1469字 评论关闭
from: http://www.programmer.com.cn/6746/   文/蒋宇捷 蒋宇捷 创新工场魔图项目技术总监 创业公司面对的现实问题是难以招到优秀的工程师。和大公司相比,创业公司的待遇低、压力大、稳定性差,而且既符合职位条件又有创业意愿的人很难寻觅,还需要时机合适,我就遇见过几次候选人因为家事而放弃机会的情况。 现在我每天花1/3的时间在开发工作,1/3的时间在团队事务和沟通,1/3的时间在招揽各种优秀的人才上。 如何找到优质的候选人 在自己的同事和朋友中找。 我们团队一位工程师曾经获得招聘......
阅读全文
  • 04月
  • 09日
综合 ⁄ 共 11201字 评论关闭
内容转自:http://aspxboy.com/private/2013/default.aspx            WSE(Web Services Enhancements)是微软为了使开发者通过.NET创建出更强大,更好用的Web Services而推出功能增强插件。现在最新的版本是WSE2.0(SP2).本文描述了如何使用WSE2.0中的安全功能增强部分来实现安全的Web Services。WSE的安全功能增强实现的是WS-Security标准,此标准是WebService自己的安全协议,由IBM, BEA, Microsoft等联合制定,所以在.NET和Java系统上都可实现。     其实通过WSE实现安全有两种途径:一种就是我们下面要介绍的通过编写代码的方......
阅读全文
  • 02月
  • 01日
综合 ⁄ 共 1532字 评论关闭
As Easy As A+B Time Limit: 2000/1000 MS (Java/Others)    Memory Limit: 65536/32768 K (Java/Others) Total Submission(s): 30295    Accepted Submission(s): 12993 Problem Description These days, I am thinking about a question, how can I get a problem as easy as A+B? It is fairly difficulty to do such a thing. Of course, I got it after many waking nights. Give you some integers, your task is to sort these number ascending (升序). You should know how easy the problem is now! Good luck!   ......
阅读全文
  • 01月
  • 13日
综合 ⁄ 共 1936字 评论关闭
Description Bessie is out in the field and wants to get back to the barn to get as much sleep as possible before Farmer John wakes her for the morning milking. Bessie needs her beauty sleep, so she wants to get back as quickly as possible. Farmer John's field has N (2 <= N <= 1000) landmarks in it, uniquely numbered 1..N. Landmark 1 is the barn; the apple tree grove in which Bessie stands all day is landmark N. Cows travel in the field using T (1 <= T <= 2000) bidirectional ......
阅读全文
  • 11月
  • 14日
综合 ⁄ 共 1323字 评论关闭
水题。给你n个点m条边。入度为0的点标为1,如果一个点只有一个点指向,那么它标为那个点的标数。如果一个点有两个或以上相同标号的点指向。那么给它标为i+1,如果有更大的话就标为更大的。求最大的标号。 拓扑排序 //First Edit Time: 2014-07-15 12:40 //Last Edit Time: 2014-07-15 12:40 //Filename:C.cpp #include <iostream> #include <cstdio> #include <cstring> #include <cmath> #include <set> #include <vector> #include <map> #include <queue> #include <set&g......
阅读全文
  • 11月
  • 12日
综合 ⁄ 共 1591字 评论关闭
如何实现将View向上平移自身高度一半的距离?   TranslateAnimation translate = new TranslateAnimation( Animation.RELATIVE_TO_SELF, 0, Animation.RELATIVE_TO_SELF, 0,  Animation.RELATIVE_TO_SELF, 0, Animation.RELATIVE_TO_SELF, 0.5f); mView.startAnimation(translate); 问题:当动画结束后,View会跳回到原始位置。   改进: AnimationSet set = new AnimationSet(true); TranslateAnimation translate = new TranslateAnimation( Animation.RELATIVE_TO_SELF, 0, Animation.RELATIVE_TO_SELF, 0,  Animation.RELATIV......
阅读全文
  • 10月
  • 06日
综合 ⁄ 共 2663字 评论关闭
原文链接:http://gamedevelopment.tutsplus.com/tutorials/understanding-steering-behaviors-flee-and-arrival--gamedev-1303 跑开 在前面介绍的寻找行为中,我们介绍了一种基于两个向量力来将人物推向目标的行为方式:预期速度和控制力 desired_velocity = normalize(target - position) * max_velocity ; steering = desired_velocity - velocity ; 在上面说的desired_velocity是从人物直接指向目标的。我们只要简单的将目标点减去人物的点就能够得到这个速度。 而在本节中,同样的,我们也需要使用这样的两个力,但是,我们......
阅读全文
  • 09月
  • 14日
综合 ⁄ 共 61字 评论关闭
find . -type f -name "*.c" -exec grep "xxxx" {} /; -print   grep *.c -e "xxx"
阅读全文
  • 09月
  • 07日
综合 ⁄ 共 3728字 评论关闭
关 键 词:C 阅读提示:在C++的历史发展中,有很多的语言特征(特别是语言的晦涩之处)来自于C语言,预处理就是其中的一个。C++从C语言那里把C语言预处理器继承过来(C语言预处理器,被Bjarne博士简称为Cpp,不知道是不是C Program Preprocessor的简称)。  一、预处理的由来:在C++的历史发展中,有很多的语言特征(特别是语言的晦涩之处)来自于C语言,预处理就是其中的一个。C++从C语言那里把C语言预处理器继承过来(C语言预处理器,被Bjarne博士简称为Cpp,不知道是不是C Program Preprocessor的简称)。二、常见的预处理功能......
阅读全文