1. Overview
The ExcludeMessageWindow module explains mandatory exclusion rules and home-directory behavior.
Its principal responsibilities are:
- Lists protected system paths
- Shows default home-directory exclusion guidance
- Provides a modal acknowledgement action
2. Class Structure and Dependencies
public class ExcludeMessageWindow : Gtk.Dialog
The source imports:
GtkGeeTeeJee.LoggingTeeJee.FileSystemTeeJee.JsonHelperTeeJee.ProcessHelperTeeJee.GtkHelperTeeJee.SystemTeeJee.Misc
The GTK inheritance and imported modules allow the component to participate in the application event loop, share the central backup state, and construct native GTK4 controls.
3. Primary Runtime State
The principal fields declared by the module include:
Gtk.Box vbox_main– primary vertical layout containerGtk.Box hbox_action– Box widget used by the interfaceGtk.ListBox exclude_list– ListBox widget used by the interfaceScrolledWindow sw_exclude– runtime reference for sw excludeLabel lbl_header_exclude– label used to display header exclude informationLabel lbl_exclude– label used to display exclude informationLabel lbl_header_home– label used to display header home informationLabel lbl_home– label used to display home informationButton btn_ok– button used to trigger the corresponding ok action
4. User Interface Composition
The module directly constructs the following GTK widget types:
Gtk.Box– layout containersGtk.Label– headings, descriptions, and status textGtk.ListBox– dynamic selectable rowsGtk.ListBoxRow– custom list rows
Event-driven behavior is connected through signals such as:
clicked
5. Initialization
ExcludeMessageWindow()
public ExcludeMessageWindow()
Initializes the class instance, creates its GTK controls, and prepares the initial state. It reads or updates central state through App.exclude_list_default. It creates Gtk.Label, Gtk.ListBox where required. It connects the clicked signal.
6. Central Controller Integration
The module reads or modifies the following Main controller members through the global App object:
App.exclude_list_default
7. Method Reference
exclude_list_add_item()
private void exclude_list_add_item(string path)
Implements the exclude list add item operation. It creates Gtk.Box, Gtk.Label, Gtk.ListBoxRow where required.
btn_ok_clicked()
private void btn_ok_clicked()
Implements the btn ok clicked operation.
8. External Resources and Paths
The component does not directly define protected filesystem paths or external command strings.
9. Data and Event Flow
- Construct the component and initialize its child controls
- React to GTK signals generated by navigation, selections, and action controls
- Read or update central backup and restore state through the global controller
10. Runtime and Security Considerations
- Shared controller state: the component reads and modifies the global
Appcontroller used by the surrounding workflow. - Signal-driven behavior: GTK callbacks update the model and interface when controls are activated or changed.
11. Implementation Considerations
- Global coupling: the class depends on the process-wide
Appobject rather than receiving a controller through dependency injection.
12. Licensing
The applicable licensing terms are defined by the source-file header and the containing BastionGuard Backup project.
