获取布局文件:
int layout=activity.getResources().getIdentifier("layout_hint_dialog","layout",activity.getPackageName());
获取控件ID:
int close_btn1=activity.getResources().getIdentifier("close_btn","id",activity.getPackageName());
int layout=activity.getResources().getIdentifier("layout_hint_dialog","layout",activity.getPackageName());
int close_btn1=activity.getResources().getIdentifier("close_btn","id",activity.getPackageName());