Skip to content

Commit 01e051c

Browse files
committed
Enable support for dynamic theme stroke
Use material card if required on API 16 and above.
1 parent bfdc61f commit 01e051c

File tree

1 file changed

+4
-0
lines changed

1 file changed

+4
-0
lines changed

dynamic-support/src/main/java/com/pranavpandey/android/dynamic/support/theme/DynamicLayoutInflater.java

Lines changed: 4 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -382,6 +382,10 @@ public void run() {
382382
protected @Nullable View onCustomiseView(@Nullable View view,
383383
@NonNull Context context, @NonNull AttributeSet attrs) {
384384
if (view != null) {
385+
if (view instanceof DynamicCardView && ((DynamicCardView) view).isStrokeRequired()) {
386+
view = new DynamicMaterialCardView(context, attrs);
387+
}
388+
385389
if (ADS_TAG_IGNORE.equals(view.getTag())) {
386390
view = null;
387391
}

0 commit comments

Comments
 (0)