Edit right click pop up on appointment JFXtras

160 views Asked by At

i want to edit this pop up that appears when i perform right click on appointment, so that i can add more textField to get some more informations. I use Agenda from JFXtras library and i do not know how to edit the pop up.

2

There are 2 answers

0
AudioBubble On BEST ANSWER

I found how to do it, i've just added this code :

agenda.setEditAppointmentCallback( (appointment) -> {
        editPopUp();
        return null;
    });

on agenda initialization and editPopUp() call an function that create the pop up that i wanted to show

0
tbeernot On

Have you read the JavaDoc of Agenda?

http://jfxtras.org/doc/8.0/jfxtras-agenda/jfxtras/scene/control/agenda/Agenda.html

Agenda has a default popup that allows the primary properties of appointments to be edited, but maybe you want to do something yourself. If so, you need to register to the editAppointmentCallback, and open your own popup. Because Agenda does not dictate an event/callback mechanism in the implementation of Appointment, it has no way of being informed of changes on the appointment. So when the custom edit is done, make sure that agenda gets updated by calling refresh().