xmlterm changes only (not part of the default build).

Minor changes
This commit is contained in:
svn%xmlterm.org 2000-03-01 01:08:07 +00:00
Родитель fa18215c91
Коммит f58eb5a219
3 изменённых файлов: 49 добавлений и 6 удалений

Просмотреть файл

@ -0,0 +1,42 @@
#!/usr/bin/perl
# menuhack: Modies the tasks menu to insert XMLterm as a menu item
# Execute in the mozilla "package" directory
#
# NOTE: ** This is temporary hack until the chrome registry becomes
# available. Do not use it if you build mozilla yourself, as it
# messes up the important "tasksOverlay.xul" file.
# (Unless you know what you are doing, of course, in which case
# you may execute it in your "mozilla/dist/bin" directory.)
# Usage: menuhack
use Cwd;
# Locate taskOverlay.xul file
my $dir = cwd();
($dir =~ m%.*/(package|dist/bin)%) or
die "menuhack: Please execute in the package or dist/bin directory\n";
chdir "chrome/global/content/default"
or die "menuhack: Directory chrome/global/content/default not found\n";
my $menufile = "tasksOverlay.xul";
# Insert XMLterm menu item into file
open INFILE, "<$menufile" or die "menuhack: Unable to read $menufile\n";
open OUTFILE, ">$menufile.new" or die "menuhack: Unable to create $menufile.new\n";
while (<INFILE>) {
print OUTFILE unless m/XMLterm/;
if (s%(.*)"&editorCmd.label;"(.*)"toEditor\(\);"%$1"XMLterm" $2"window.open('chrome://xmlterm/content/xmlterm.xul','XMLterm','chrome,dialog=no,resizable');"%) {
print OUTFILE;
}
}
close <INFILE>;
close <OUTFILE>;
rename $menufile, "$menufile.bak";
rename "$menufile.new", $menufile;
print "Modified tasksOverlay.xul to display XMLterm item\n";

Просмотреть файл

@ -18,11 +18,11 @@ if ($opt_help) {
# Icon details
#my $imgdir="chrome://xmlterm/skin/default/images"
my $imgdir = "file:/usr/share/pixmaps/mc";
my $imgdir = "file:///usr/share/pixmaps/mc";
my %img;
($img{'directory'}, $img{'executable'}, $img{'plainfile'}) =
('i-directory.png', 'i-executable.png', 'i-regular.png');
($img{'directory'}, $img{'executable'}, $img{'plainfile'}, $img{'urlfile'}) =
('i-directory.png', 'i-executable.png', 'i-regular.png', 'i-regular.png');
my $ncols = 5;
$ncols = $opt_cols if ($opt_cols);
@ -63,9 +63,9 @@ foreach $file (glob("*")) { # for each file in current directory
$sendtxt1 = "$dir/$file";
$sendtxt2 = "./$file";
} elsif (($extension eq ".gif") || ($extension eq ".png")) { # image
} elsif (($extension eq ".gif") || ($extension eq ".png") || ($extension eq ".jpg")) { # image
$filetype = "imagefile";
$fileimg = $file;
$fileimg = "file://$dir/$file";
$sendtxt1 = "xcat $dir/$file";
$sendtxt2 = "xcat $file";

Просмотреть файл

@ -35,7 +35,8 @@
// Create new XMLTerm window
function NewXMLTerm(firstcommand) {
newwin = window.openDialog( "chrome://xmlterm/content/xmlterm.xul",
"", "", firstcommand);
"xmlterm", "chrome,dialog=no,resizable",
firstcommand);
//newwin = window.xmlterm.NewXMLTermWindow(firstcommand);
dump("NewXMLTerm: "+newwin+"\n")
return (false);