Fix #1116849 ("Downloading metadata" window over size of screen)

This commit is contained in:
Kovid Goyal 2013-02-06 09:16:24 +05:30
parent 5ef20f66eb
commit 76d3c12b1e

View File

@ -376,6 +376,13 @@ class Comments(QWebView): # {{{
<html>
'''%(fam, f, c)
self.setHtml(templ%html)
def sizeHint(self):
# This is needed, because on windows the dialog cannot be resized to
# so that this widgets height become < sizeHint().height(). Qt sets the
# sizeHint to (800, 600), which makes the dialog unusable on smaller
# screens.
return QSize(800, 300)
# }}}
class IdentifyWorker(Thread): # {{{
@ -977,12 +984,6 @@ class FullFetch(QDialog): # {{{
if geom is not None and geom:
self.restoreGeometry(geom)
# Workaround for Qt 4.8.0 bug that causes the frame of the window to go
# off the top of the screen if a max height is not set for the
# QWebView. Seems to only happen on windows, but keep it for all
# platforms just in case.
self.identify_widget.comments_view.setMaximumHeight(self.height()-100)
self.finished.connect(self.cleanup)
def view_log(self):