2012年4月19日
摘要: ADrawableis a pluggable drawing container that is usually associated with a View. For instance, aBitmapDrawableis used to display images, aShapeDrawableto draw shapes and gradients, and so on. You can even combine them to create complex renderings.As a matter of fact, they are so convenient that mos 阅读全文
posted @ 2012-04-19 14:08 maneater 阅读(177) 评论(0) 推荐(0) 编辑
摘要: 1.Setting the minSdkVersion设置最小支持的sdk<manifest> ... <uses-sdkandroid:minSdkVersion="3"/> ... </manifest>2.Using reflection使用反射检测要 使用的类 在当前运行环境下 是否有需要调用的属性或方法。likeandroid.os.Debug.dumpHprofData(String filename). TheDebugclass has existed since Android 1.0, but the method i 阅读全文
posted @ 2012-04-19 10:39 maneater 阅读(217) 评论(0) 推荐(0) 编辑
  2012年4月4日
摘要: <html><title></title><head><script>function loads(){var elements=document.getElementsByTagName("div"); for(var i=0;i<elements.length;i++){ var eleObj=elements[i]; eleObj.onclick=doSomething(eleObj.innerHTML);//传递参数 } } function doSomething(content){ //返回一个匿 阅读全文
posted @ 2012-04-04 17:17 maneater 阅读(1162) 评论(0) 推荐(0) 编辑
  2012年3月22日
摘要: 1.本地工程使用代码加载log4j的配置文件PropertyConfigurator.configure("log4j.properties");使用log4jLogger logger = Logger.getLogger(this.getClass());logger.info("start up...");2.普通Web工程在使用servlet或Listener在应用启动的时候使用代码加载log4j的配置文件,比如listenner,在web.xml注册listenner <listener> <listener-class> 阅读全文
posted @ 2012-03-22 22:40 maneater 阅读(460) 评论(0) 推荐(0) 编辑
  2012年3月21日
摘要: 工作中接触代码少,只能靠自己的不断努力了。需要引入jquery-1.4.2.js,jquery在这里大材小用了.<!DOCTYPE html PUBLIC "-//W3C//DTD HTML 4.01 Transitional//EN" "http://www.w3.org/TR/html4/loose.dtd"><html><head><meta http-equiv="Content-Type" content="text/html; charset=UTF-8"> 阅读全文
posted @ 2012-03-21 17:14 maneater 阅读(285) 评论(0) 推荐(1) 编辑
  2012年3月19日
摘要: <script type="text/javascript"> function Animal(name){ this.name=name; } Animal.prototype.sayName=function(){ alert("My name is:"+this.name); } Animal.prototype.sayHi=function(){ alert("Hi! from animal:"+this.name); }function Tiger(name){ Animal.call(this, name);/ 阅读全文
posted @ 2012-03-19 14:32 maneater 阅读(177) 评论(0) 推荐(1) 编辑