~cjwatson/debconf/dbus

« back to all changes in this revision

Viewing changes to Debconf/Element/Dialog/Error.pm

  • Committer: cjwatson
  • Date: 2006-01-23 21:02:47 UTC
  • Revision ID: vcs-imports@canonical.com-20060123210247-e72616d29ed40ac7
* Add support for templates of type 'error', which are largely treated
  like notes except that they are displayed no matter what the priority
  and even if they've previously been seen. For example, this can be used
  for input validation errors. This is compatible with cdebconf.

Show diffs side-by-side

added added

removed removed

Lines of Context:
 
1
#!/usr/bin/perl -w
 
2
 
 
3
=head1 NAME
 
4
 
 
5
Debconf::Element::Dialog::Error - An error message in a dialog box
 
6
 
 
7
=cut
 
8
 
 
9
package Debconf::Element::Dialog::Error;
 
10
use strict;
 
11
use base qw(Debconf::Element);
 
12
 
 
13
=head1 DESCRIPTION
 
14
 
 
15
This is an input element that can display a dialog box with an error message
 
16
on it.
 
17
 
 
18
=cut
 
19
 
 
20
sub show {
 
21
        my $this=shift;
 
22
 
 
23
        $this->frontend->showtext($this->question, 
 
24
                $this->question->description."\n\n".
 
25
                $this->question->extended_description
 
26
        );
 
27
        $this->value('');
 
28
}
 
29
 
 
30
1