fix problems with motif changes not showing up in sequencebrowser
authorDiane Trout <diane@caltech.edu>
Tue, 3 Apr 2007 23:39:44 +0000 (23:39 +0000)
committerDiane Trout <diane@caltech.edu>
Tue, 3 Apr 2007 23:39:44 +0000 (23:39 +0000)
This patch adds a couple of new unit test cases to make sure that
when the motif sequence list is changed it is actually reflected
in the sequence browser.

The problem was that when I originally coded it, a GlSequence held
a shared_ptr<Sequence> so even though SequenceBrowser had new copies
of GlSequence, the underlying Sequence was still shared.

The change to GlSequence being a subclass of Sequence with a copy
of the motif_list meant that changes to the motif_list in one
copy weren't reflected in the copy held by the SequenceBrowser.

I fixed it by changing sequence to hold a shared_ptr<list<motif> >.
the downside is that that the motif_list is now always shared
between copies of a Sequence, which is likely to cause problems
when opening a second mussa window.

However since I plan on tossing the current annotation and motif handling
code at some point in the near future, this patch should be "good
enough".


No differences found