publicstaticsynchronized SingleToast getInstance() { if (sInstance == null) {
sInstance = new SingleToast();
} return sInstance;
}
private SingleToast() {
}
public SingleToast text(String text, int length) { returnthis.text(text, length, Gravity.CENTER_VERTICAL | Gravity.CENTER_HORIZONTAL, 0, 0);
}
@SuppressLint("ShowToast") synchronizedpublic SingleToast text(String text, int length, int gravity, int x, int y) { if (this.toast == null) { this.toast = Toast.makeText(ThreemaApplication.getAppContext(), text, length);
if (gravity != 0 || x != 0 || y != 0) { this.toast.setGravity(gravity, x, y);
}
Die Informationen auf dieser Webseite wurden
nach bestem Wissen sorgfältig zusammengestellt. Es wird jedoch weder Vollständigkeit, noch Richtigkeit,
noch Qualität der bereit gestellten Informationen zugesichert.
Bemerkung:
Die farbliche Syntaxdarstellung und die Messung sind noch experimentell.