This repository has been archived on 2021-12-05. You can view files and clone it, but cannot push or open issues or pull requests.
2020-10-08 14:34:21 +02:00
|
|
|
package envoy.client.ui.control;
|
|
|
|
|
|
|
|
import javafx.scene.control.Label;
|
|
|
|
|
|
|
|
import envoy.data.Group;
|
|
|
|
|
|
|
|
/**
|
|
|
|
* Displays the amount of members in a {@link Group}.
|
|
|
|
*
|
|
|
|
* @author Leon Hofmeister
|
|
|
|
* @since Envoy Client v0.3-beta
|
|
|
|
*/
|
|
|
|
public final class GroupSizeLabel extends Label {
|
|
|
|
|
|
|
|
/**
|
|
|
|
* @param recipient the group whose members to show
|
|
|
|
* @since Envoy Client v0.3-beta
|
|
|
|
*/
|
2020-10-16 20:21:22 +02:00
|
|
|
public GroupSizeLabel(Group recipient) {
|
|
|
|
super(recipient.getContacts().size() + " member" + (recipient.getContacts().size() != 1 ? "s" : ""));
|
|
|
|
}
|
2020-10-08 14:34:21 +02:00
|
|
|
}
|