You cannot select more than 25 topics Topics must start with a letter or number, can include dashes ('-') and can be up to 35 characters long.
CustoMIUIzer/app/src/main/java/name/mikanoshi/customiuizer/holidays/SnowGenerator.java

30 lines
826 B
Java

package name.mikanoshi.customiuizer.holidays;
import android.content.Context;
import com.github.jinatonic.confetti.ConfettoGenerator;
import com.github.jinatonic.confetti.confetto.Confetto;
import com.github.matteobattilana.weather.PrecipType;
import com.github.matteobattilana.weather.confetti.ConfettoInfo;
import java.util.Random;
public class SnowGenerator implements ConfettoGenerator {
private final ConfettoInfo confettoInfo;
private final Context context;
public SnowGenerator(Context ctx) {
super();
this.context = ctx;
this.confettoInfo = new ConfettoInfo(PrecipType.SNOW);
}
public Confetto generateConfetto(Random random) {
return new SnowParticle(this.context, this.confettoInfo);
}
public final ConfettoInfo getConfettoInfo() {
return this.confettoInfo;
}
}