Skip to content

Commit

Permalink
clean code pictograms view
Browse files Browse the repository at this point in the history
  • Loading branch information
gonojuarez committed Nov 22, 2022
1 parent a0c425e commit b21b2d5
Show file tree
Hide file tree
Showing 4 changed files with 6 additions and 6 deletions.
Original file line number Diff line number Diff line change
Expand Up @@ -87,7 +87,7 @@ protected void setData() {
Drawable drawable = findResource(pictogramsLibraryGameGroup.getPictogram());
glideAttatcher.setHeight(IconHeight).setWidth(IconWidth).useDiskCacheStrategy().loadDrawable(drawable, this.icon);
} else {
selectIcon(pictogramsLibraryGameGroup, this.icon);
selectIcon(pictogramsLibraryGameGroup, this.icon,glideAttatcher);
}
}

Expand Down Expand Up @@ -134,7 +134,7 @@ public void setData(int height, int with) {
Drawable drawable = findResource(pictogramsLibraryGameGroup.getPictogram());
glideAttatcher.setHeight(height).setWidth(with).useDiskCacheStrategy().loadDrawable(drawable, this.icon);
} else {
selectIcon(pictogramsLibraryGameGroup, this.icon);
selectIcon(pictogramsLibraryGameGroup, this.icon,glideAttatcher);
}
}

Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -101,7 +101,7 @@ protected void setData() {
Drawable drawable = findResource(pictogramsLibraryGroup.getPictogram());
glideAttatcher.setHeight(IconHeight).setWidth(IconWidth).useDiskCacheStrategy().setRadius(25).UseCornerRadius(true).loadDrawable(drawable, this.icon);
} else {
selectIcon(pictogramsLibraryGroup,this.icon);
selectIcon(pictogramsLibraryGroup,this.icon,glideAttatcher);
}
}

Expand Down Expand Up @@ -141,7 +141,7 @@ public void setData(int height, int with) {
Drawable drawable = findResource(pictogramsLibraryGroup.getPictogram());
glideAttatcher.setHeight(height).setWidth(with).useDiskCacheStrategy().setRadius(25).UseCornerRadius(true).loadDrawable(drawable, this.icon);
} else {
selectIcon(pictogramsLibraryGroup,this.icon);
selectIcon(pictogramsLibraryGroup,this.icon,glideAttatcher);
}
}

Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -177,7 +177,7 @@ protected void setData(){
glideAttatcher.useDiskCacheStrategy().loadDrawable(Uri.parse(pictogramsLibraryPictogram.getPictogram()),this.icon);
}
}else{
selectIcon(pictogramsLibraryPictogram,this.icon);
selectIcon(pictogramsLibraryPictogram,this.icon,glideAttatcher);
}
}

Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -79,7 +79,7 @@ public void selectIcon(){

}

protected void selectIcon(final OTTAAProjectObjects object,ImageView icon) {
protected void selectIcon(final OTTAAProjectObjects object,ImageView icon,GlideAttatcher glideAttatcher) {
String path = object.getEditedPictogram();
File picture=new File(path);
if(picture.exists())
Expand Down

0 comments on commit b21b2d5

Please sign in to comment.