Skip to content
API Documentation
BastionGuard™
RsyncLogWindow Class Reference
Inheritance diagram for RsyncLogWindow:

Public Member Functions

signal void request_close ()
 RsyncLogWindow (string _rsync_log_file, bool embedded=false)
Gtk.Widget detach_root_widget ()

Private Member Functions

bool on_close_request ()

Private Attributes

int def_width = 800
int def_height = 600
RsyncLogBox logbox
string rsync_log_file
bool embedded_mode = false

Detailed Description

Definition at line 36 of file RsyncLogWindow.vala.

Constructor & Destructor Documentation

◆ RsyncLogWindow()

RsyncLogWindow.RsyncLogWindow ( string _rsync_log_file,
bool embedded = false )
inline

Definition at line 48 of file RsyncLogWindow.vala.

48 {
49 embedded_mode = embedded;
50
51 log_debug("RsyncLogWindow: RsyncLogWindow()");
52
53 this.title = _("Rsync Log Viewer");
54 this.set_default_size(def_width, def_height);
55 this.set_icon_name("bastionguard-backup");
56 this.resizable = true;
57 if (!embedded_mode) this.modal = true;
58
59 if (!embedded_mode) this.close_request.connect(() => {
60 return on_close_request();
61 });
62
63 rsync_log_file = _rsync_log_file;
64
65 logbox = new RsyncLogBox(this);
66 this.set_child(logbox);
67
68 if (!embedded_mode)
69 show();
70
72
73 log_debug("RsyncLogWindow: RsyncLogWindow(): exit");
74 }
#define _(s)
void open_log(string _rsync_log_file)
RsyncLogBox(Gtk.Window _window)
RsyncLogBox logbox
void log_debug(string message)

References _, def_height, def_width, embedded_mode, TeeJee.Logging.log_debug(), logbox, on_close_request(), RsyncLogBox.open_log(), rsync_log_file, and RsyncLogBox.RsyncLogBox().

Referenced by MainWindow.open_rsync_log_page().

Member Function Documentation

◆ detach_root_widget()

Gtk.Widget RsyncLogWindow.detach_root_widget ( )
inline

Definition at line 87 of file RsyncLogWindow.vala.

87 {
88 set_child(null);
89 return logbox;
90 }

References logbox.

◆ on_close_request()

bool RsyncLogWindow.on_close_request ( )
inlineprivate

Definition at line 76 of file RsyncLogWindow.vala.

76 {
77
78 if (logbox.is_running){
79 return true; // keep window open
80 }
81 else{
82 return false; // close window
83 }
84 }

References RsyncLogBox.is_running, and logbox.

Referenced by RsyncLogWindow().

◆ request_close()

signal void RsyncLogWindow.request_close ( )

Member Data Documentation

◆ def_height

int RsyncLogWindow.def_height = 600
private

Definition at line 42 of file RsyncLogWindow.vala.

Referenced by RsyncLogWindow().

◆ def_width

int RsyncLogWindow.def_width = 800
private

Definition at line 41 of file RsyncLogWindow.vala.

Referenced by RsyncLogWindow().

◆ embedded_mode

bool RsyncLogWindow.embedded_mode = false
private

Definition at line 46 of file RsyncLogWindow.vala.

Referenced by RsyncLogWindow().

◆ logbox

RsyncLogBox RsyncLogWindow.logbox
private

Definition at line 44 of file RsyncLogWindow.vala.

Referenced by detach_root_widget(), on_close_request(), and RsyncLogWindow().

◆ rsync_log_file

string RsyncLogWindow.rsync_log_file
private

Definition at line 45 of file RsyncLogWindow.vala.

Referenced by RsyncLogWindow().


The documentation for this class was generated from the following file: