摘要: 插入头文件:import java.lang.reflect.Field;import com.android.internal.view.menu.MenuPopupHelper;import android.view.Menu;import android.view.MenuInflater;i... 阅读全文
posted @ 2015-08-03 10:38 williamgufeng 阅读(429) 评论(0) 推荐(0) 编辑
摘要: 加入头文件:import java.lang.reflect.Field;import com.android.internal.view.menu.MenuPopupHelper;加入反射: try { Field field = mPopupMenu.getClass... 阅读全文
posted @ 2015-08-03 10:35 williamgufeng 阅读(1115) 评论(0) 推荐(0) 编辑
摘要: import java.lang.reflect.Method;...... @Override public boolean onCreateOptionsMenu(Menu menu) { MenuInflater inflater = getMenuInflater(... 阅读全文
posted @ 2015-08-03 10:32 williamgufeng 阅读(856) 评论(0) 推荐(0) 编辑
摘要: 代码种使用:private CircleView mCircleView = null;......mCircleView = new CircleView(this, mHandler);RelativeLayout rela = (RelativeLayout)findViewById(R.id... 阅读全文
posted @ 2015-08-03 10:25 williamgufeng 阅读(188) 评论(0) 推荐(0) 编辑
摘要: 代码中使用自定义View:private SeekView mSeekView = null;......mSeekView = new SeekView(this, mHandler);RelativeLayout rela = (RelativeLayout)findViewById(R.id.... 阅读全文
posted @ 2015-08-03 10:21 williamgufeng 阅读(240) 评论(0) 推荐(0) 编辑
摘要: java代码中重写View:package com.android.systemui.recent;import android.content.Context;import android.graphics.Canvas;import android.graphics.Color;import a... 阅读全文
posted @ 2015-08-03 10:17 williamgufeng 阅读(238) 评论(0) 推荐(0) 编辑