prmr / JetUML

A desktop application for fast UML diagramming.
GNU General Public License v3.0
619 stars 121 forks source link

Notification-based feedback system graphical component #510

Closed ArthusWQZ closed 9 months ago

ArthusWQZ commented 10 months ago

This pull request follows #508, by consisting of the graphical part of the notification-based feedback system.

It adds a new interface, Notification, and two new classes, NotificationHandler and ToastNotification. A single test file effectively test both classes (they work together).

The NotificationHandler is a Singleton whose spawn() method can be called from anywhere to display a Toast notification on the screen. A ToastNotification object can be even more customized by using the detailed constructor of the class.

Every class implementing the Notification interface can be used with the NotificationHandler.