上一页 1 ··· 10 11 12 13 14

2014年10月10日

摘要: Android读取自定义View属性attrs.xml : activity_main.xml : MyView.java :public MyView(Context context, AttributeSet attrs) { super(c... 阅读全文
posted @ 2014-10-10 10:31 屌丝迷途 阅读(415) 评论(0) 推荐(0)

2014年9月19日

摘要: @Override protected void onDraw(Canvas canvas) { super.onDraw(canvas); Paint mTextPaint = new Paint(Paint.ANTI_ALIAS_FLAG); ... 阅读全文
posted @ 2014-09-19 16:11 屌丝迷途 阅读(792) 评论(0) 推荐(0)
摘要: textview添加属性:android:singleLine="true" 表示单行显示android:ellipsize="marquee"设置当文字过长时,该控件该如何显示。有如下值设置:”start”—–省略号显示在开头;”end”——省略号显示在结尾;”middle”—-省略号显示在中间;... 阅读全文
posted @ 2014-09-19 15:29 屌丝迷途 阅读(456) 评论(0) 推荐(0)

2014年9月16日

摘要: 1 while(true){2 try { 3 sleep(1000);4 } catch (InterruptedException e) {5 ... 阅读全文
posted @ 2014-09-16 14:32 屌丝迷途 阅读(4487) 评论(0) 推荐(0)

2013年4月9日

摘要: NotificationManager notificationManager = (NotificationManager)getSystemService(NOTIFICATION_SERVICE); Notification notification = new Notification(R.drawable.logo_icon_16,"移动营销", System.currentTimeMillis()); Intent intent = new Intent(Intent.ACTION_MAIN); intent.addCategory(Intent.CATEGOR 阅读全文
posted @ 2013-04-09 00:10 屌丝迷途 阅读(378) 评论(0) 推荐(0)

2013年4月8日

摘要: // 添加常驻通知private void setNotification() { NotificationManager notificationManager = (NotificationManager)getSystemService(NOTIFICATION_SERVICE); Notification notification = new Notification(R.drawable.icon, getString(R.string.app_name), System.currentTimeMillis()); Intent intent = new Inten... 阅读全文
posted @ 2013-04-08 23:50 屌丝迷途 阅读(1892) 评论(0) 推荐(0)
上一页 1 ··· 10 11 12 13 14

导航