[Bio] / Sprout / Sprout.pm Repository:
ViewVC logotype

Diff of /Sprout/Sprout.pm

Parent Directory Parent Directory | Revision Log Revision Log | View Patch Patch

revision 1.122, Mon Jan 19 21:46:21 2009 UTC revision 1.124, Wed Mar 4 00:09:43 2009 UTC
# Line 133  Line 133 
133                         maxSegmentLength => 4500,        # maximum feature segment length                         maxSegmentLength => 4500,        # maximum feature segment length
134                         maxSequenceLength => 8000,       # maximum contig sequence length                         maxSequenceLength => 8000,       # maximum contig sequence length
135                         noDBOpen     => 0,               # 1 to suppress the database open                         noDBOpen     => 0,               # 1 to suppress the database open
136                           demandDriven => 0,               # 1 for forward-only queries
137                        }, $options);                        }, $options);
138      # Get the data directory.      # Get the data directory.
139      my $dataDir = $optionTable->{dataDir};      my $dataDir = $optionTable->{dataDir};
# Line 148  Line 149 
149      }      }
150      # Create the ERDB object.      # Create the ERDB object.
151      my $xmlFileName = "$optionTable->{xmlFileName}";      my $xmlFileName = "$optionTable->{xmlFileName}";
152      my $retVal = ERDB::new($class, $dbh, $xmlFileName);      my $retVal = ERDB::new($class, $dbh, $xmlFileName, %$optionTable);
153      # Add the option table and XML file name.      # Add the option table and XML file name.
154      $retVal->{_options} = $optionTable;      $retVal->{_options} = $optionTable;
155      $retVal->{_xmlName} = $xmlFileName;      $retVal->{_xmlName} = $xmlFileName;
# Line 688  Line 689 
689      # Set up the multiple-select flag.      # Set up the multiple-select flag.
690      my $multipleTag = ($multiSelect ? " multiple" : "" );      my $multipleTag = ($multiSelect ? " multiple" : "" );
691      # Set up the style class.      # Set up the style class.
692      my $classTag = ($class ? " class=\"$class\"" : "" );      my $classTag = ($class ? " $class" : "" );
693      # Create the SELECT tag and stuff it into the output array.      # Create the SELECT tag and stuff it into the output array.
694      my @lines = ("<SELECT name=\"$menuName\" id=\"$menuID\" $onChangeTag$multipleTag$classTag size=\"$rows\">");      my @lines = qq(<SELECT name="$menuName" id="$menuID" class="genomeSelect $class" $onChangeTag$multipleTag$classTag size="$rows">);
695      # Loop through the groups.      # Loop through the groups.
696      for my $group (@groups) {      for my $group (@groups) {
697          # Get the genomes in the group.          # Get the genomes in the group.
# Line 723  Line 724 
724          # displayed. For multiple-select mode, we include a button that selects the displayed          # displayed. For multiple-select mode, we include a button that selects the displayed
725          # genes. For single-select mode, we use a plain label instead.          # genes. For single-select mode, we use a plain label instead.
726          my $searchThingName = "${menuID}_SearchThing";          my $searchThingName = "${menuID}_SearchThing";
727          my $searchThingLabel = ($multiSelect ? "<INPUT type=\"button\" name=\"MacroSearch\" class=\"button\" value=\"Select genomes containing\" onClick=\"selectShowing('$menuID', '$searchThingName'); $showSelect;\" />"          my $searchThingLabel = "Type to narrow selection";
728                                               : "Show genomes containing");          my $searchThingButton = "";
729            my $goHint = "";
730            if ($multiSelect) {
731                $searchThingButton = qq(<INPUT type="button" name="MacroSearch" class="button" value="Go" onClick="selectShowing('$menuID', '$searchThingName'); $showSelect;" />);
732                $goHint = " Click <strong>Go</strong> to select them.";
733            }
734          push @lines, "<br />$searchThingLabel&nbsp;" .          push @lines, "<br />$searchThingLabel&nbsp;" .
735                       "<INPUT type=\"text\" id=\"$searchThingName\" name=\"$searchThingName\" size=\"30\" onKeyup=\"showTyped('$menuID', '$searchThingName');\" />" .                       qq(<INPUT type="text" id="$searchThingName" name="$searchThingName" class="genomeSearchThing" onKeyup="showTyped('$menuID', '$searchThingName');" />) .
736                       Hint("GenomeControl", "Type here to filter the genomes displayed.") . "<br />";                       $searchThingButton .
737                         Hint("GenomeControl", "Type a genome ID or part of an organism name to filter the genomes displayed.$goHint") . "<br />";
738          # For multi-select mode, we also have buttons to set and clear selections.          # For multi-select mode, we also have buttons to set and clear selections.
739          if ($multiSelect) {          if ($multiSelect) {
740              push @lines, "<INPUT type=\"button\" name=\"ClearAll\" class=\"bigButton\"  value=\"Clear All\" onClick=\"clearAll(getElementById('$menuID')); $showSelect\" />";              push @lines, qq(<INPUT type="button" name="ClearAll" class="bigButton genomeButton" value="Clear All" onClick="clearAll(getElementById('$menuID')); $showSelect" />);
741              push @lines, "<INPUT type=\"button\" name=\"SelectAll\" class=\"bigButton\" value=\"Select All\" onClick=\"selectAll(getElementById('$menuID')); $showSelect\" />";              push @lines, qq(<INPUT type="button" name="SelectAll" class="bigButton genomeButton" value="Select All" onClick="selectAll(getElementById('$menuID')); $showSelect" />);
742              push @lines, "<INPUT type=\"button\" name=\"NMPDROnly\" class=\"bigButton\"  value=\"Select NMPDR\" onClick=\"selectSome(getElementById('$menuID'), $nmpdrCount, true); $showSelect;\" />";              push @lines, qq(<INPUT type="button" name="NMPDROnly" class="bigButton genomeButton" value="Select NMPDR" onClick="selectSome(getElementById('$menuID'), $nmpdrCount, true); $showSelect;" />);
743          }          }
744          # Add a hidden field we can use to generate organism page hyperlinks.          # Add a hidden field we can use to generate organism page hyperlinks.
745          push @lines, "<INPUT type=\"hidden\" id=\"$urlID\" value=\"$FIG_Config::cgi_url/wiki/rest.cgi/NmpdrPlugin/SeedViewer?page=Organism;organism=\" />";          push @lines, qq(<INPUT type="hidden" id="$urlID" value="$FIG_Config::cgi_url/wiki/rest.cgi/NmpdrPlugin/SeedViewer?page=Organism;organism=" />);
746          # Add the status display. This tells the user what's selected no matter where the list is scrolled.          # Add the status display. This tells the user what's selected no matter where the list is scrolled.
747          push @lines, "<DIV id=\"$divID\" class=\"Panel\"></DIV>";          push @lines, qq(<DIV id="$divID" class="Panel"></DIV>);
748      }      }
749      # Assemble all the lines into a string.      # Assemble all the lines into a string.
750      my $retVal = join("\n", @lines, "");      my $retVal = join("\n", @lines, "");

Legend:
Removed from v.1.122  
changed lines
  Added in v.1.124

MCS Webmaster
ViewVC Help
Powered by ViewVC 1.0.3