Store Sequence sequence location in a shared_ptr class
[mussa.git] / alg / glseqbrowser.hpp
index 2b313f65e5fca7bcd62434118572ea6fc702555d..38ede4bc05476ffa32458850db76aafe9ae1e368 100644 (file)
@@ -50,6 +50,11 @@ public:
   float viewportHeight() const;
   //! return width of the viewport in world coordinates
   float viewportWidth() const;
+  
+  //! return viewport height in pixels
+  int viewportPixelHeight() const;
+  //! return viewport width in pixels
+  int viewportPixelWidth() const;
 
   //! zoom out far enough to show the full size of the sequence
   double zoomOut();
@@ -100,9 +105,7 @@ public:
   //! copy sequence from selected track using formating function
   template<class Item>
   size_t copySelectedTracks(std::list<Item>& result, 
-             Item (*format_track)(boost::shared_ptr<Sequence> s,
-                                  int left, 
-                                  int right));
+             Item (*format_track)(const Sequence& s, int left, int right));
   //! copy sequence from selected tracks as FASTA sequences
   /*! \return number of base pairs copied
    */
@@ -206,12 +209,12 @@ private:
   float viewport_center;
   double zoom_level;
   boost::shared_ptr<AnnotationColors> color_mapper;
-  //! container of all the GlSequences loaded into our scene
-  std::vector<boost::shared_ptr<GlSequence> > track_container;
   //! counter for each path added to us via connect
   int pathid;
 
 protected:
+  //! container of all the GlSequences loaded into our scene
+  std::vector<boost::shared_ptr<GlSequence> > track_container;
   //! where to draw our box (world coordinates)
   rect<float> selectedRegion;
   //! true if we have a selection