]> git.donarmstrong.com Git - biopieces.git/commitdiff
finished cleaning index.cgi
authormartinahansen <martinahansen@74ccb610-7750-0410-82ae-013aeee3265d>
Thu, 26 Nov 2009 12:37:36 +0000 (12:37 +0000)
committermartinahansen <martinahansen@74ccb610-7750-0410-82ae-013aeee3265d>
Thu, 26 Nov 2009 12:37:36 +0000 (12:37 +0000)
git-svn-id: http://biopieces.googlecode.com/svn/trunk@777 74ccb610-7750-0410-82ae-013aeee3265d

www/index.cgi

index 3888a0b227750c9f947e10ac72103b76a5d8fc43..41256f32964cbf6130ee612dc1b81f143588dd57 100755 (executable)
@@ -23,7 +23,7 @@
 use strict;
 use warnings;
 
-use lib "/Users/maasha/biopieces/code_perl/";   # FIXME should be shell and httpd env variable
+use lib $ENV{ 'BP_PERL' };
 
 use CGI;
 use Data::Dumper;
@@ -31,9 +31,9 @@ use Maasha::Common;
 use Maasha::Filesys;
 use Maasha::Calc;
 use Maasha::XHTML;
-use Maasha::KISS::IO;
-use Maasha::KISS::Track;
-use Maasha::KISS::Draw;
+use Maasha::KISS;
+use Maasha::BBrowser::Track;
+use Maasha::BBrowser::Draw;
 
 my ( $cgi, $cookie, @html );
 
@@ -59,8 +59,8 @@ push @html, Maasha::XHTML::form_end;
 push @html, Maasha::XHTML::body_end;
 push @html, Maasha::XHTML::html_end;
 
-# push @html, Maasha::KISS::Draw::hdump( $cgi->param );  # DEBUG
-# push @html, Maasha::KISS::Draw::hdump( $cookie );      # DEBUG
+# push @html, Maasha::BBrowser::Draw::hdump( $cgi->param );  # DEBUG
+# push @html, Maasha::BBrowser::Draw::hdump( $cookie );      # DEBUG
 
 print "$_\n" foreach @html;
 
@@ -192,7 +192,7 @@ sub cookie_end
 
     my ( $max );
     
-    $max = Maasha::Filesys::file_size( Maasha::KISS::Track::path_seq( $cookie ) );
+    $max = Maasha::Filesys::file_size( Maasha::BBrowser::Track::path_seq( $cookie ) );
 
     if ( defined $cookie->{ 'NAV_END' } )
     {
@@ -220,7 +220,7 @@ sub cookie_zoom
 
     my ( $max, $dist, $new_dist, $dist_diff );
 
-    $max = Maasha::Filesys::file_size( Maasha::KISS::Track::path_seq( $cookie ) );
+    $max = Maasha::Filesys::file_size( Maasha::BBrowser::Track::path_seq( $cookie ) );
 
     $dist = $cookie->{ 'NAV_END' } - $cookie->{ 'NAV_START' };
 
@@ -263,7 +263,7 @@ sub cookie_move
 
     my ( $max, $dist, $shift, $new_start, $new_end );
 
-    $max = Maasha::Filesys::file_size( Maasha::KISS::Track::path_seq( $cookie ) );
+    $max = Maasha::Filesys::file_size( Maasha::BBrowser::Track::path_seq( $cookie ) );
 
     $dist = $cookie->{ 'NAV_END' } - $cookie->{ 'NAV_START' };
 
@@ -575,16 +575,16 @@ sub section_browse
 
     my ( @tracks, $i, @features, $feat, $elem, $file, $surface, $cr, @html, @img );
 
-    push @features, [ Maasha::KISS::Track::track_ruler( $cookie ) ];
-    push @features, [ Maasha::KISS::Track::track_seq( $cookie ) ];
+    push @features, [ Maasha::BBrowser::Track::track_ruler( $cookie ) ];
+    push @features, [ Maasha::BBrowser::Track::track_seq( $cookie ) ];
 
-    @tracks = Maasha::KISS::Track::path_tracks( $cookie );
+    @tracks = Maasha::BBrowser::Track::path_tracks( $cookie );
 
     for ( $i = 0; $i < @tracks; $i++ )
     {
-        $cookie->{ 'FEAT_COLOR' } = Maasha::KISS::Draw::palette( $i );
+        $cookie->{ 'FEAT_COLOR' } = Maasha::BBrowser::Draw::palette( $i );
 
-        push @features, [ Maasha::KISS::Track::track_feature( $tracks[ $i ], $cookie, $cookie ) ];
+        push @features, [ Maasha::BBrowser::Track::track_feature( $tracks[ $i ], $cookie, $cookie ) ];
     }
 
     $file = "fisk.png";   # FIXME
@@ -593,10 +593,10 @@ sub section_browse
     $cr      = Cairo::Context->create( $surface );
 
     foreach $feat ( @features ) {
-        Maasha::KISS::Draw::draw_feature( $cr, $feat ) if $feat;
+        Maasha::BBrowser::Draw::draw_feature( $cr, $feat ) if $feat;
     }
 
-    Maasha::KISS::Draw::file_png( $surface, $file );
+    Maasha::BBrowser::Draw::file_png( $surface, $file );
 
     push @img, Maasha::XHTML::img(
         src    => $file,