mirror of
https://github.com/kovidgoyal/calibre.git
synced 2025-07-09 03:04:10 -04:00
Fix #7826 (Book Details window sizing on netbooks screen version)
This commit is contained in:
parent
88264f6650
commit
bd4fbc3060
@ -253,7 +253,12 @@ class BookInfo(QWebView):
|
|||||||
% (left_pane, right_pane)))
|
% (left_pane, right_pane)))
|
||||||
|
|
||||||
def mouseDoubleClickEvent(self, ev):
|
def mouseDoubleClickEvent(self, ev):
|
||||||
ev.ignore()
|
if self.width() - ev.x() < 25 or \
|
||||||
|
self.height() - ev.y() < 25:
|
||||||
|
# Filter out double clicks on the scroll bar
|
||||||
|
ev.accept()
|
||||||
|
else:
|
||||||
|
ev.ignore()
|
||||||
|
|
||||||
# }}}
|
# }}}
|
||||||
|
|
||||||
|
@ -23,10 +23,6 @@ class BookInfo(QDialog, Ui_BookInfo):
|
|||||||
self.comments.sizeHint = self.comments_size_hint
|
self.comments.sizeHint = self.comments_size_hint
|
||||||
self.view_func = view_func
|
self.view_func = view_func
|
||||||
|
|
||||||
desktop = QCoreApplication.instance().desktop()
|
|
||||||
screen_height = desktop.availableGeometry().height() - 100
|
|
||||||
self.resize(self.size().width(), screen_height)
|
|
||||||
|
|
||||||
|
|
||||||
self.view = view
|
self.view = view
|
||||||
self.current_row = None
|
self.current_row = None
|
||||||
@ -40,8 +36,13 @@ class BookInfo(QDialog, Ui_BookInfo):
|
|||||||
self.fit_cover.stateChanged.connect(self.toggle_cover_fit)
|
self.fit_cover.stateChanged.connect(self.toggle_cover_fit)
|
||||||
self.cover.resizeEvent = self.cover_view_resized
|
self.cover.resizeEvent = self.cover_view_resized
|
||||||
|
|
||||||
|
desktop = QCoreApplication.instance().desktop()
|
||||||
|
screen_height = desktop.availableGeometry().height() - 100
|
||||||
|
self.resize(self.size().width(), screen_height)
|
||||||
|
|
||||||
|
|
||||||
def comments_size_hint(self):
|
def comments_size_hint(self):
|
||||||
return QSize(350, 350)
|
return QSize(350, 250)
|
||||||
|
|
||||||
def toggle_cover_fit(self, state):
|
def toggle_cover_fit(self, state):
|
||||||
dynamic.set('book_info_dialog_fit_cover', self.fit_cover.isChecked())
|
dynamic.set('book_info_dialog_fit_cover', self.fit_cover.isChecked())
|
||||||
|
@ -7,7 +7,7 @@
|
|||||||
<x>0</x>
|
<x>0</x>
|
||||||
<y>0</y>
|
<y>0</y>
|
||||||
<width>917</width>
|
<width>917</width>
|
||||||
<height>783</height>
|
<height>480</height>
|
||||||
</rect>
|
</rect>
|
||||||
</property>
|
</property>
|
||||||
<property name="windowTitle">
|
<property name="windowTitle">
|
||||||
|
Loading…
x
Reference in New Issue
Block a user