Properly initialize standalone comments editing box

This commit is contained in:
Kovid Goyal 2013-10-16 13:22:34 +05:30
parent f11ab7d0c3
commit e60dce0133

View File

@ -18,8 +18,8 @@ class CommentsDialog(QDialog, Ui_CommentsDialog):
self.setWindowFlags(self.windowFlags()&(~Qt.WindowContextHelpButtonHint)) self.setWindowFlags(self.windowFlags()&(~Qt.WindowContextHelpButtonHint))
self.setWindowIcon(icon) self.setWindowIcon(icon)
if text is not None: self.textbox.html = comments_to_html(text) if text else ''
self.textbox.html = comments_to_html(text) self.textbox.wyswyg_dirtied()
# self.textbox.setTabChangesFocus(True) # self.textbox.setTabChangesFocus(True)
self.buttonBox.button(QDialogButtonBox.Ok).setText(_('&OK')) self.buttonBox.button(QDialogButtonBox.Ok).setText(_('&OK'))
self.buttonBox.button(QDialogButtonBox.Cancel).setText(_('&Cancel')) self.buttonBox.button(QDialogButtonBox.Cancel).setText(_('&Cancel'))