ViewVC Help
View File | Revision Log | Show Annotations | Download File
/cvs/Mozilla-Plugin/Plugin/Gtk.pm
Revision: 1.1
Committed: Sat Feb 24 01:48:38 2001 UTC (23 years, 3 months ago) by root
Branch: MAIN
Log Message:
*** empty log message ***

File Contents

# User Rev Content
1 root 1.1 =head1 NAME
2    
3     Mozilla::Plugin - embed perl into mozilla/netscape.
4    
5     =head1 SYNOPSIS
6    
7     <embed type="application/x-mperl-tk" />
8    
9     =head1 DESCRIPTION
10    
11     sorry...
12    
13     =over 4
14    
15     =cut
16    
17     package Mozilla::Plugin::Gtk;
18    
19     use base Mozilla::Plugin;
20    
21     use Gtk;
22    
23     $VERSION = 0.01;
24    
25     sub mainloop
26    
27     sub new {
28     my $class = shift;
29     my $self = $class->SUPER::new(@_);
30    
31     $self;
32     }
33    
34     sub window_new {
35     my $self = shift;
36     $self->SUPER::window_new(@_);
37    
38     init Gtk;
39     use Gtk;
40    
41     my $w = $self->{win} = new Gtk::Plug $_[0];
42     $w->add(my $v = new Gtk::VBox 5,5);
43     $v->add(Gtk::Button->new("Hulla"));
44     $w->show_all;
45     }
46    
47     sub window_delete {
48     my $self = shift;
49     $self->SUPER::window_delete(@_);
50    
51     delete $self->{win};
52     }
53    
54     sub DESTROY {
55     warn "DESTROY";
56     }
57    
58     1;
59    
60     =back
61    
62     =head1 BUGS
63    
64     =head1 SEE ALSO
65    
66     L<PApp>.
67    
68     =head1 AUTHOR
69    
70     Marc Lehmann <pcg@goof.com>
71     http://www.goof.com/pcg/marc/
72    
73     =cut
74