my $DATADIR = '@DATADIR@';
my $VERSION = '@VERSION@';
my $VERBOSE = FALSE;
+my $READONLY = FALSE;
my $CLAWSV = undef;
my $main_window = undef;
}
sub check_claws_not_running {
+ return TRUE if $READONLY;
my $tmpdir = (defined $ENV{TMPDIR})? $ENV{TMPDIR}: '/tmp';
$tmpdir = '/tmp' if ($tmpdir eq '');
my $lockdir = "$tmpdir/claws-mail-$<";
GetOptions('h|help' => sub { print_help (); $cont = FALSE },
'v|version' => sub { print_version (); $cont = FALSE },
'b|verbose' => sub { $VERBOSE = TRUE },
+ 'r|read-only' => sub { $READONLY = TRUE },
'u|use-claws-version=s' => \&opt_use_claws_version,
'a|alternate-config-dir=s' => \&opt_alternate_config_dir,
'c|clawsrc=s' => \&opt_clawsrc)
my $hbox = Gtk2::HBox->new (FALSE, 5);
# signal handlers
$b_exit->signal_connect (clicked => sub { Gtk2->main_quit });
+ $b_apply->set_sensitive (not $READONLY);
$b_apply->signal_connect (clicked => sub {
save_preferences ($parent);
save_ac_preferences ($parent);