Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Fix Linking Book cover function #1339

Open
wants to merge 3 commits into
base: master
Choose a base branch
from
Open
Changes from 1 commit
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
7 changes: 4 additions & 3 deletions Scripts/Python/xLinkingBookGUIPopup.py
Original file line number Diff line number Diff line change
Expand Up @@ -527,9 +527,10 @@ def IShowBookNoTreasure(self):
gLinkingBook = ptBook(bookdef,self.key)
gLinkingBook.setSize( width, height )
# make sure there is a cover to show
if not showOpen:
if not self.IsThereACover(bookdef):
showOpen = 1
if not showOpen and not self.IsThereACover(bookdef):
showOpen = 1
else:
showOpen = 0
Copy link
Contributor

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Suggested change
if not showOpen and not self.IsThereACover(bookdef):
showOpen = 1
else:
showOpen = 0
if showOpen and self.IsThereACover(bookdef):
showOpen = 0

Copy link
Contributor

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Also Line 867 if idx > 0: should be if idx >= 0:
Anything other than -1 is true for string find

gLinkingBook.setGUI(gui)
gLinkingBook.show(showOpen)
except LookupError:
Expand Down