有时候需要使用第三库提供一些资源,是不能直接通过R获取的,要加上包名。
例如:
//引入依赖
implementation 'com.google.android.material:material:1.6.0'
//使用
View bottomSheetInternal = bottomSheetDialog.findViewById(com.google.android.material.R.layout.design_bottom_sheet_dialog);
有时候需要使用第三库提供一些资源,是不能直接通过R获取的,要加上包名。
例如:
//引入依赖
implementation 'com.google.android.material:material:1.6.0'
//使用
View bottomSheetInternal = bottomSheetDialog.findViewById(com.google.android.material.R.layout.design_bottom_sheet_dialog);