code-google-com / bpbible

Automatically exported from code.google.com/p/bpbible
Other
0 stars 0 forks source link

Doing other things during search causes problems #8

Open GoogleCodeExporter opened 9 years ago

GoogleCodeExporter commented 9 years ago
What steps will reproduce the problem?
1. Start a Sword search
2. Move over a footnote

Traceback (most recent call last):
  File "/media/disk/python/bpbible/gui/htmlbase.py", line 515, in MouseMove
    self.Idle(None)
  File "/media/disk/python/bpbible/gui/htmlbase.py", line 663, in Idle
    self.OnCellMouseEnter(cellover, xx, yy)
  File "/media/disk/python/bpbible/displayframe.py", line 143, in
OnCellMouseEnter
    protocol_handler.on_hover(self, href, x, y)
  File "/media/disk/python/bpbible/protocols.py", line 22, in on_hover
    self._handle(self.hover, frame, href, x, y)
  File "/media/disk/python/bpbible/protocols.py", line 32, in _handle
    d[protocol](frame, href, url, *args)
  File "/media/disk/python/bpbible/displayframe.py", line 207, in on_hover
    data = bible.GetFootnoteData(module, passage, value, "body")
  File "/media/disk/python/bpbible/backend/book.py", line 288, in
GetFootnoteData
    def GetReferencesFromMod(self, modname, ref, context=None, max_verses=-1):
  File "/afs/monash/users/b/p/bpmor3/lib/python2.5/site-packages/Sword.py",
line 248, in __getitem__
    def __getitem__(*args): return
_Sword.AttributeTypeListMap___getitem__(*args)
IndexError: key not found

The module carries the entry attributes as state around with it. This can
cause problems with lots of things.

Original issue reported on code.google.com by benpmor...@gmail.com on 5 May 2008 at 3:12

GoogleCodeExporter commented 9 years ago
Probably need to keep two modules - a display one and a backend one.
This could either be by keeping two SWMgr sets, or by creating a SWModule 
descendant
when needed.

Original comment by benpmor...@gmail.com on 19 May 2008 at 3:08