From edacf95ad24fca3c4ae08b44ffdfe4be5c68fdc1 Mon Sep 17 00:00:00 2001 From: christopherm Date: Fri, 13 Oct 2006 16:28:21 +0000 Subject: removing bin/lynx and bin/mozilla folders. All scripts are now at bin/ with bin/custom for custom scripts (user specific or otherwise) git-svn-id: https://ledger-smb.svn.sourceforge.net/svnroot/ledger-smb/trunk@208 4979c152-3d1c-0410-bac9-87ea11338e46 --- bin/mozilla/menu.pl | 245 ---------------------------------------------------- 1 file changed, 245 deletions(-) delete mode 100755 bin/mozilla/menu.pl (limited to 'bin/mozilla/menu.pl') diff --git a/bin/mozilla/menu.pl b/bin/mozilla/menu.pl deleted file mode 100755 index 199a21cc..00000000 --- a/bin/mozilla/menu.pl +++ /dev/null @@ -1,245 +0,0 @@ -#===================================================================== -# LedgerSMB -# Small Medium Business Accounting software -# http://www.ledgersmb.org/ -# -# -# See COPYRIGHT file for copyright information -#====================================================================== -# -# This file has undergone whitespace cleanup. -# -#====================================================================== -# -# two frame layout with refractured menu -# -####################################################################### - -$menufile = "menu.ini"; -use LedgerSMB::Menu; - -1; -# end of main - - -sub display { - - $menuwidth = ($ENV{HTTP_USER_AGENT} =~ /links/i) ? "240" : "155"; - $menuwidth = $myconfig{menuwidth} if $myconfig{menuwidth}; - - $form->header(!$form->{duplicate}); - - print qq| - - - - - - |; - -} - - - -sub acc_menu { - - my $menu = new Menu "$menufile"; - $menu->add_file("custom_$menufile") if -f "custom_$menufile"; - $menu->add_file("$form->{login}_$menufile") if -f "$form->{login}_$menufile"; - - $form->{title} = $locale->text('Accounting Menu'); - - my $headeradd = q| - |; - $form->header(undef, $headeradd); - print q| - - - - |; - - if ($form->{js}) { - &js_menu($menu); - } else { - §ion_menu($menu); - } - - print q| - - - |; - -} - - -sub section_menu { - - my ($menu, $level) = @_; - - # build tiered menus - my @menuorder = $menu->access_control(\%myconfig, $level); - - while (@menuorder) { - $item = shift @menuorder; - $label = $item; - $label =~ s/$level--//g; - - my $spacer = " " x (($item =~ s/--/--/g) * 2); - - $label =~ s/.*--//g; - $label = $locale->text($label); - $label =~ s/ / /g if $label !~ /{$item}{target} = "main_window" unless $menu->{$item}{target}; - - if ($menu->{$item}{submenu}) { - - $menu->{$item}{$item} = !$form->{$item}; - - if ($form->{level} && $item =~ $form->{level}) { - - # expand menu - print qq|
\n$spacer|.$menu->menuitem(\%myconfig, \%$form, $item, $level).qq|$label|; - - # remove same level items - map { shift @menuorder } grep /^$item/, @menuorder; - - §ion_menu($menu, $item); - - print qq|
\n|; - - } else { - - print qq|
\n$spacer|.$menu->menuitem(\%myconfig, \%$form, $item, $level).qq|$label ...|; - - # remove same level items - map { shift @menuorder } grep /^$item/, @menuorder; - - } - - } else { - - if ($menu->{$item}{module}) { - - print qq|
\n$spacer|.$menu->menuitem(\%myconfig, \%$form, $item, $level).qq|$label|; - - } else { - - $form->{tag}++; - print qq|

$label

|; - - §ion_menu($menu, $item); - - print qq|
\n|; - - } - } - } -} - - -sub js_menu { - - my ($menu, $level) = @_; - - print qq|
|; - - # build tiered menus - my @menuorder = $menu->access_control(\%myconfig, $level); - - while (@menuorder){ - $i++; - $item = shift @menuorder; - $label = $item; - $label =~ s/.*--//g; - $label = $locale->text($label); - - $menu->{$item}{target} = "main_window" unless $menu->{$item}{target}; - - if ($menu->{$item}{submenu}) { - - $display = "display: none;" unless $level eq ' '; - - print qq| - - - |; - - } else { - - if ($menu->{$item}{module}) { - - if ($level eq "") { - print qq||; - - # remove same level items - map { shift @menuorder } grep /^$item/, @menuorder; - - &js_menu($menu, $item); - - } else { - - print qq||; - } - - } else { - - $display = "display: none;" unless $item eq ' '; - - print qq| - - |; - - } - - } - - } - - print qq|
|; -} - - -sub menubar { - -1; - -} - - -- cgit v1.2.3