fixed short lines; some other trivial fixes

This commit is contained in:
Andreas Preikschat 2013-03-01 10:20:26 +01:00
commit 1ef6cde4e4
15 changed files with 57 additions and 103 deletions

View File

@ -200,12 +200,10 @@ class VerticalType(object):
Names = [u'top', u'middle', u'bottom']
BOOLEAN_LIST = [u'bold', u'italics', u'override', u'outline', u'shadow',
u'slide_transition']
BOOLEAN_LIST = [u'bold', u'italics', u'override', u'outline', u'shadow', u'slide_transition']
INTEGER_LIST = [u'size', u'line_adjustment', u'x', u'height', u'y',
u'width', u'shadow_size', u'outline_size', u'horizontal_align',
u'vertical_align', u'wrap_style']
INTEGER_LIST = [u'size', u'line_adjustment', u'x', u'height', u'y', u'width', u'shadow_size', u'outline_size',
u'horizontal_align', u'vertical_align', u'wrap_style']
class ThemeXML(object):
@ -234,8 +232,7 @@ class ThemeXML(object):
if self.background_filename and path:
self.theme_name = self.theme_name.strip()
self.background_filename = self.background_filename.strip()
self.background_filename = os.path.join(path, self.theme_name,
self.background_filename)
self.background_filename = os.path.join(path, self.theme_name, self.background_filename)
def _new_document(self, name):
"""
@ -308,11 +305,9 @@ class ThemeXML(object):
# Create endColor element
self.child_element(background, u'borderColor', unicode(borderColor))
def add_font(self, name, color, size, override, fonttype=u'main',
bold=u'False', italics=u'False', line_adjustment=0,
xpos=0, ypos=0, width=0, height=0, outline=u'False',
outline_color=u'#ffffff', outline_pixel=2, shadow=u'False',
shadow_color=u'#ffffff', shadow_pixel=5):
def add_font(self, name, color, size, override, fonttype=u'main', bold=u'False', italics=u'False',
line_adjustment=0, xpos=0, ypos=0, width=0, height=0, outline=u'False', outline_color=u'#ffffff',
outline_pixel=2, shadow=u'False', shadow_color=u'#ffffff', shadow_pixel=5):
"""
Add a Font.

View File

@ -308,8 +308,7 @@ class AdvancedTab(SettingsTab):
self.service_name_day.setItemText(5, translate('OpenLP.AdvancedTab', 'Saturday'))
self.service_name_day.setItemText(6, translate('OpenLP.AdvancedTab', 'Sunday'))
self.service_name_day.setItemText(7, translate('OpenLP.AdvancedTab', 'Now'))
self.service_name_time.setToolTip(translate('OpenLP.AdvancedTab',
'Time when usual service starts.'))
self.service_name_time.setToolTip(translate('OpenLP.AdvancedTab', 'Time when usual service starts.'))
self.service_name_label.setText(translate('OpenLP.AdvancedTab', 'Name:'))
self.service_name_edit.setToolTip(translate('OpenLP.AdvancedTab', 'Consult the OpenLP manual for usage.'))
self.service_name_revert_button.setToolTip(
@ -524,8 +523,7 @@ class AdvancedTab(SettingsTab):
"""
Select the background colour of the default display screen.
"""
new_color = QtGui.QColorDialog.getColor(
QtGui.QColor(self.default_color), self)
new_color = QtGui.QColorDialog.getColor(QtGui.QColor(self.default_color), self)
if new_color.isValid():
self.default_color = new_color.name()
self.default_color_button.setStyleSheet(u'background-color: %s' % self.default_color)

View File

@ -85,8 +85,7 @@ class Ui_ExceptionDialog(object):
self.exceptionLayout.addWidget(self.button_box)
self.retranslateUi(exceptionDialog)
QtCore.QObject.connect(self.descriptionTextEdit,
QtCore.SIGNAL(u'textChanged()'), self.onDescriptionUpdated)
QtCore.QObject.connect(self.descriptionTextEdit, QtCore.SIGNAL(u'textChanged()'), self.onDescriptionUpdated)
def retranslateUi(self, exceptionDialog):
"""
@ -102,9 +101,6 @@ class Ui_ExceptionDialog(object):
'developers, so please e-mail it to bugs@openlp.org, along with a '
'detailed description of what you were doing when the problem '
'occurred.'))
self.sendReportButton.setText(translate('OpenLP.ExceptionDialog',
'Send E-Mail'))
self.saveReportButton.setText(translate('OpenLP.ExceptionDialog',
'Save to File'))
self.attachFileButton.setText(translate('OpenLP.ExceptionDialog',
'Attach File'))
self.sendReportButton.setText(translate('OpenLP.ExceptionDialog', 'Send E-Mail'))
self.saveReportButton.setText(translate('OpenLP.ExceptionDialog', 'Save to File'))
self.attachFileButton.setText(translate('OpenLP.ExceptionDialog', 'Attach File'))

View File

@ -98,8 +98,7 @@ class FirstTimeForm(QtGui.QWizard, Ui_FirstTimeWizard):
self.update_screen_list_combo()
self.was_download_cancelled = False
self.downloading = translate('OpenLP.FirstTimeWizard', 'Downloading %s...')
QtCore.QObject.connect(self.cancelButton, QtCore.SIGNAL('clicked()'),
self.onCancelButtonClicked)
QtCore.QObject.connect(self.cancelButton, QtCore.SIGNAL('clicked()'), self.onCancelButtonClicked)
QtCore.QObject.connect(self.noInternetFinishButton, QtCore.SIGNAL('clicked()'),
self.onNoInternetFinishButtonClicked)
QtCore.QObject.connect(self, QtCore.SIGNAL(u'currentIdChanged(int)'), self.onCurrentIdChanged)

View File

@ -48,8 +48,7 @@ class FirstTimeLanguageForm(QtGui.QDialog, Ui_FirstTimeLanguageDialog):
self.setupUi(self)
self.qmList = LanguageManager.get_qm_list()
self.languageComboBox.addItem(u'Autodetect')
for key in sorted(self.qmList.keys()):
self.languageComboBox.addItem(key)
self.languageComboBox.addItems(sorted(self.qmList.keys()))
def exec_(self):
"""

View File

@ -208,13 +208,11 @@ class Ui_FirstTimeWizard(object):
"""
Translate the UI on the fly
"""
FirstTimeWizard.setWindowTitle(translate(
'OpenLP.FirstTimeWizard', 'First Time Wizard'))
FirstTimeWizard.setWindowTitle(translate('OpenLP.FirstTimeWizard', 'First Time Wizard'))
self.titleLabel.setText(u'<span style="font-size:14pt; font-weight:600;">%s</span>' %
translate('OpenLP.FirstTimeWizard', 'Welcome to the First Time Wizard'))
self.informationLabel.setText(translate('OpenLP.FirstTimeWizard',
'This wizard will help you to configure OpenLP for initial use.'
' Click the next button below to start.'))
'This wizard will help you to configure OpenLP for initial use. Click the next button below to start.'))
self.pluginPage.setTitle(translate('OpenLP.FirstTimeWizard', 'Activate required Plugins'))
self.pluginPage.setSubTitle(translate('OpenLP.FirstTimeWizard', 'Select the Plugins you wish to use. '))
self.songsCheckBox.setText(translate('OpenLP.FirstTimeWizard', 'Songs'))
@ -240,8 +238,7 @@ class Ui_FirstTimeWizard(object):
'check your Internet connection and re-run this wizard by '
'selecting "Tools/Re-run First Time Wizard" from OpenLP.')
self.cancelWizardText = translate('OpenLP.FirstTimeWizard',
'\n\nTo cancel the First Time Wizard completely (and not start '
'OpenLP), click the Cancel button now.')
'\n\nTo cancel the First Time Wizard completely (and not start OpenLP), click the Cancel button now.')
self.songsPage.setTitle(translate('OpenLP.FirstTimeWizard', 'Sample Songs'))
self.songsPage.setSubTitle(translate('OpenLP.FirstTimeWizard', 'Select and download public domain songs.'))
self.biblesPage.setTitle(translate('OpenLP.FirstTimeWizard', 'Sample Bibles'))

View File

@ -127,7 +127,6 @@ class FormattingTagForm(QtGui.QDialog, Ui_FormattingTagDialog):
self.tagTableWidget.selectRow(self.tagTableWidget.rowCount() - 1)
self.onRowSelected()
self.tagTableWidget.scrollToBottom()
#self.savePushButton.setEnabled(False)
def onDeleteClicked(self):
"""

View File

@ -231,8 +231,7 @@ class GeneralTab(SettingsTab):
self.usernameLabel.setText(translate('OpenLP.GeneralTab', 'SongSelect username:'))
self.passwordLabel.setText(translate('OpenLP.GeneralTab', 'SongSelect password:'))
# Moved from display tab
self.overrideRadioButton.setText(translate('OpenLP.GeneralTab',
'Override display position:'))
self.overrideRadioButton.setText(translate('OpenLP.GeneralTab', 'Override display position:'))
self.customXLabel.setText(translate('OpenLP.GeneralTab', 'X'))
self.customYLabel.setText(translate('OpenLP.GeneralTab', 'Y'))
self.customHeightLabel.setText(translate('OpenLP.GeneralTab', 'Height'))

View File

@ -96,14 +96,11 @@ class Display(QtGui.QGraphicsView):
self.frame = self.page.mainFrame()
if self.isLive and log.getEffectiveLevel() == logging.DEBUG:
self.webView.settings().setAttribute(QtWebKit.QWebSettings.DeveloperExtrasEnabled, True)
QtCore.QObject.connect(self.webView,
QtCore.SIGNAL(u'loadFinished(bool)'), self.isWebLoaded)
QtCore.QObject.connect(self.webView, QtCore.SIGNAL(u'loadFinished(bool)'), self.isWebLoaded)
self.setVerticalScrollBarPolicy(QtCore.Qt.ScrollBarAlwaysOff)
self.setHorizontalScrollBarPolicy(QtCore.Qt.ScrollBarAlwaysOff)
self.frame.setScrollBarPolicy(QtCore.Qt.Vertical,
QtCore.Qt.ScrollBarAlwaysOff)
self.frame.setScrollBarPolicy(QtCore.Qt.Horizontal,
QtCore.Qt.ScrollBarAlwaysOff)
self.frame.setScrollBarPolicy(QtCore.Qt.Vertical, QtCore.Qt.ScrollBarAlwaysOff)
self.frame.setScrollBarPolicy(QtCore.Qt.Horizontal, QtCore.Qt.ScrollBarAlwaysOff)
def resizeEvent(self, event):
"""
@ -213,9 +210,7 @@ class MainDisplay(Display):
image_file = Settings().value(u'advanced/default image')
splash_image = QtGui.QImage(image_file)
self.initialFrame = QtGui.QImage(
self.screen[u'size'].width(),
self.screen[u'size'].height(),
QtGui.QImage.Format_ARGB32_Premultiplied)
self.screen[u'size'].width(), self.screen[u'size'].height(), QtGui.QImage.Format_ARGB32_Premultiplied)
painter_image = QtGui.QPainter()
painter_image.begin(self.initialFrame)
painter_image.fillRect(self.initialFrame.rect(), background_color)

View File

@ -173,18 +173,16 @@ class PrintServiceForm(QtGui.QDialog, Ui_PrintServiceDialog):
custom_css = get_text_file_string(css_path)
if not custom_css:
custom_css = DEFAULT_CSS
self._addElement(u'style', custom_css, html_data.head,
attribute=(u'type', u'text/css'))
self._addElement(u'style', custom_css, html_data.head, attribute=(u'type', u'text/css'))
self._addElement(u'body', parent=html_data)
self._addElement(u'h1', cgi.escape(self.titleLineEdit.text()),
html_data.body, classId=u'serviceTitle')
self._addElement(u'h1', cgi.escape(self.titleLineEdit.text()), html_data.body, classId=u'serviceTitle')
for index, item in enumerate(self.service_manager.service_items):
self._addPreviewItem(html_data.body, item[u'service_item'], index)
# Add the custom service notes:
if self.footerTextEdit.toPlainText():
div = self._addElement(u'div', parent=html_data.body, classId=u'customNotes')
self._addElement(u'span', translate('OpenLP.ServiceManager', 'Custom Service Notes: '), div,
classId=u'customNotesTitle')
self._addElement(
u'span', translate('OpenLP.ServiceManager', 'Custom Service Notes: '), div, classId=u'customNotesTitle')
self._addElement(u'span', cgi.escape(self.footerTextEdit.toPlainText()), div, classId=u'customNotesText')
self.document.setHtml(html.tostring(html_data))
self.previewWidget.updatePreview()
@ -227,8 +225,7 @@ class PrintServiceForm(QtGui.QDialog, Ui_PrintServiceDialog):
if self.notesCheckBox.isChecked():
if item.notes:
p = self._addElement(u'div', classId=u'itemNotes', parent=div)
self._addElement(u'span', translate('OpenLP.ServiceManager', 'Notes: '), p,
classId=u'itemNotesTitle')
self._addElement(u'span', translate('OpenLP.ServiceManager', 'Notes: '), p, classId=u'itemNotesTitle')
self._addElement(u'span', cgi.escape(item.notes).replace(u'\n', u'<br>'), p, classId=u'itemNotesText')
# Add play length of media files.
if item.is_media() and self.metaDataCheckBox.isChecked():
@ -236,13 +233,11 @@ class PrintServiceForm(QtGui.QDialog, Ui_PrintServiceDialog):
if item.end_time > 0:
tme = item.end_time - item.start_time
title = self._addElement(u'div', classId=u'media', parent=div)
self._addElement(u'span', translate('OpenLP.ServiceManager', 'Playing time: '), title,
classId=u'mediaTitle')
self._addElement(u'span', unicode(datetime.timedelta(seconds=tme)),
title, classId=u'mediaText')
self._addElement(
u'span', translate('OpenLP.ServiceManager', 'Playing time: '), title, classId=u'mediaTitle')
self._addElement(u'span', unicode(datetime.timedelta(seconds=tme)), title, classId=u'mediaText')
def _addElement(self, tag, text=None, parent=None, classId=None,
attribute=None):
def _addElement(self, tag, text=None, parent=None, classId=None, attribute=None):
"""
Creates a html element. If ``text`` is given, the element's text will
set and if a ``parent`` is given, the element is appended.

View File

@ -46,8 +46,7 @@ class ServiceItemEditForm(QtGui.QDialog, Ui_ServiceItemEditDialog):
QtGui.QDialog.__init__(self, self.main_window)
self.setupUi(self)
self.item_list = []
QtCore.QObject.connect(self.list_widget, QtCore.SIGNAL(u'currentRowChanged(int)'),
self.on_current_row_changed)
QtCore.QObject.connect(self.list_widget, QtCore.SIGNAL(u'currentRowChanged(int)'), self.on_current_row_changed)
def set_service_item(self, item):
"""
@ -57,8 +56,7 @@ class ServiceItemEditForm(QtGui.QDialog, Ui_ServiceItemEditDialog):
self.item_list = []
if self.item.is_image():
self.data = True
for frame in self.item._raw_frames:
self.item_list.append(frame)
self.item_list.extend(self.item._raw_frames)
self.load_data()
self.list_widget.setCurrentItem(self.list_widget.currentItem())
@ -94,9 +92,8 @@ class ServiceItemEditForm(QtGui.QDialog, Ui_ServiceItemEditDialog):
self.item_list.pop(row)
self.load_data()
if row == self.list_widget.count():
self.list_widget.setCurrentRow(row - 1)
else:
self.list_widget.setCurrentRow(row)
row -= 1
self.list_widget.setCurrentRow(row)
def on_up_button_clicked(self):
"""
@ -163,4 +160,4 @@ class ServiceItemEditForm(QtGui.QDialog, Ui_ServiceItemEditDialog):
self._main_window = Registry().get(u'main_window')
return self._main_window
main_window = property(_get_main_window)
main_window = property(_get_main_window)

View File

@ -69,12 +69,9 @@ class StartTimeForm(QtGui.QDialog, Ui_StartTimeDialog):
"""
When the dialog succeeds, this is run
"""
start = self.hourSpinBox.value() * 3600 + \
self.minuteSpinBox.value() * 60 + \
self.secondSpinBox.value()
start = self.hourSpinBox.value() * 3600 + self.minuteSpinBox.value() * 60 + self.secondSpinBox.value()
end = self.hourFinishSpinBox.value() * 3600 + \
self.minuteFinishSpinBox.value() * 60 + \
self.secondFinishSpinBox.value()
self.minuteFinishSpinBox.value() * 60 + self.secondFinishSpinBox.value()
if end > self.item[u'service_item'].media_length:
critical_error_message_box(title=translate('OpenLP.StartTimeForm', 'Time Validation Error'),
message=translate('OpenLP.StartTimeForm', 'Finish time is set after the end of the media item'))

View File

@ -291,8 +291,7 @@ class ThemeManager(QtGui.QWidget):
save_to = None
save_from = None
if theme_data.background_type == u'image':
save_to = os.path.join(self.path, new_theme_name,
os.path.split(unicode(theme_data.background_filename))[1])
save_to = os.path.join(self.path, new_theme_name, os.path.split(unicode(theme_data.background_filename))[1])
save_from = theme_data.background_filename
theme_data.theme_name = new_theme_name
theme_data.extend_image_filename(self.path)
@ -373,8 +372,7 @@ class ThemeManager(QtGui.QWidget):
for files in os.walk(source):
for name in files[2]:
theme_zip.write(
os.path.join(source, name).encode(u'utf-8'),
os.path.join(theme, name).encode(u'utf-8')
os.path.join(source, name).encode(u'utf-8'), os.path.join(theme, name).encode(u'utf-8')
)
QtGui.QMessageBox.information(self,
translate('OpenLP.ThemeManager', 'Theme Exported'),
@ -771,20 +769,20 @@ class ThemeManager(QtGui.QWidget):
theme = Theme(xml_data)
new_theme = ThemeXML()
new_theme.theme_name = self.badV1NameChars.sub(u'', theme.Name)
if theme.BackgroundType == 0:
if theme.BackgroundType == BackgroundType.Solid:
new_theme.background_type = BackgroundType.to_string(BackgroundType.Solid)
new_theme.background_color = unicode(theme.BackgroundParameter1.name())
elif theme.BackgroundType == 1:
elif theme.BackgroundType == BackgroundType.Horizontal:
new_theme.background_type = BackgroundType.to_string(BackgroundType.Gradient)
new_theme.background_direction = BackgroundGradientType.to_string(BackgroundGradientType.Horizontal)
if theme.BackgroundParameter3.name() == 1:
new_theme.background_direction = BackgroundGradientType.to_string(BackgroundGradientType.Horizontal)
new_theme.background_start_color = unicode(theme.BackgroundParameter1.name())
new_theme.background_end_color = unicode(theme.BackgroundParameter2.name())
elif theme.BackgroundType == 2:
elif theme.BackgroundType == BackgroundType.Image:
new_theme.background_type = BackgroundType.to_string(BackgroundType.Image)
new_theme.background_filename = unicode(theme.BackgroundParameter1)
elif theme.BackgroundType == 3:
elif theme.BackgroundType == BackgroundType.Transparent:
new_theme.background_type = BackgroundType.to_string(BackgroundType.Transparent)
new_theme.font_main_name = theme.FontName
new_theme.font_main_color = unicode(theme.FontColor.name())

View File

@ -48,8 +48,7 @@ class Ui_ThemeWizard(object):
themeWizard.setModal(True)
themeWizard.setWizardStyle(QtGui.QWizard.ModernStyle)
themeWizard.setOptions(QtGui.QWizard.IndependentPages |
QtGui.QWizard.NoBackButtonOnStartPage |
QtGui.QWizard.HaveCustomButton1)
QtGui.QWizard.NoBackButtonOnStartPage | QtGui.QWizard.HaveCustomButton1)
self.spacer = QtGui.QSpacerItem(10, 0, QtGui.QSizePolicy.Fixed, QtGui.QSizePolicy.Minimum)
# Welcome Page
add_welcome_page(themeWizard, u':/wizards/wizard_createtheme.bmp')
@ -398,9 +397,8 @@ class Ui_ThemeWizard(object):
self.titleLabel.setText(u'<span style="font-size:14pt; font-weight:600;">%s</span>' %
translate('OpenLP.ThemeWizard', 'Welcome to the Theme Wizard'))
self.informationLabel.setText(
translate('OpenLP.ThemeWizard', 'This wizard will help you to '
'create and edit your themes. Click the next button below to '
'start the process by setting up your background.'))
translate('OpenLP.ThemeWizard', 'This wizard will help you to create and edit your themes. Click the next '
'button below to start the process by setting up your background.'))
self.backgroundPage.setTitle(translate('OpenLP.ThemeWizard', 'Set Up Background'))
self.backgroundPage.setSubTitle(translate('OpenLP.ThemeWizard', 'Set up your theme\'s background '
'according to the parameters below.'))
@ -417,10 +415,8 @@ class Ui_ThemeWizard(object):
self.gradientTypeLabel.setText(translate('OpenLP.ThemeWizard', 'Gradient:'))
self.gradientComboBox.setItemText(BackgroundGradientType.Horizontal,
translate('OpenLP.ThemeWizard', 'Horizontal'))
self.gradientComboBox.setItemText(BackgroundGradientType.Vertical,
translate('OpenLP.ThemeWizard', 'Vertical'))
self.gradientComboBox.setItemText(BackgroundGradientType.Circular,
translate('OpenLP.ThemeWizard', 'Circular'))
self.gradientComboBox.setItemText(BackgroundGradientType.Vertical, translate('OpenLP.ThemeWizard', 'Vertical'))
self.gradientComboBox.setItemText(BackgroundGradientType.Circular, translate('OpenLP.ThemeWizard', 'Circular'))
self.gradientComboBox.setItemText(BackgroundGradientType.LeftTop,
translate('OpenLP.ThemeWizard', 'Top Left - Bottom Right'))
self.gradientComboBox.setItemText(BackgroundGradientType.LeftBottom,
@ -484,12 +480,10 @@ class Ui_ThemeWizard(object):
self.footerHeightSpinBox.setSuffix(translate('OpenLP.ThemeWizard', 'px'))
self.footerPositionCheckBox.setText(translate('OpenLP.ThemeWizard', 'Use default location'))
themeWizard.setOption(QtGui.QWizard.HaveCustomButton1, False)
themeWizard.setButtonText(QtGui.QWizard.CustomButton1,
translate('OpenLP.ThemeWizard', 'Layout Preview'))
themeWizard.setButtonText(QtGui.QWizard.CustomButton1, translate('OpenLP.ThemeWizard', 'Layout Preview'))
self.previewPage.setTitle(translate('OpenLP.ThemeWizard', 'Preview and Save'))
self.previewPage.setSubTitle(translate('OpenLP.ThemeWizard', 'Preview the theme and save it.'))
self.themeNameLabel.setText(translate('OpenLP.ThemeWizard', 'Theme name:'))
# Align all QFormLayouts towards each other.
labelWidth = max(self.backgroundLabel.minimumSizeHint().width(),
self.horizontalLabel.minimumSizeHint().width())
labelWidth = max(self.backgroundLabel.minimumSizeHint().width(), self.horizontalLabel.minimumSizeHint().width())
self.spacer.changeSize(labelWidth, 0, QtGui.QSizePolicy.Fixed, QtGui.QSizePolicy.Fixed)

View File

@ -57,11 +57,9 @@ class WizardStrings(object):
Importing = translate('OpenLP.Ui', 'Importing')
ImportingType = translate('OpenLP.Ui', 'Importing "%s"...')
ImportSelect = translate('OpenLP.Ui', 'Select Import Source')
ImportSelectLong = translate('OpenLP.Ui',
'Select the import format and the location to import from.')
NoSqlite = translate('OpenLP.Ui', 'The openlp.org 1.x importer has been '
'disabled due to a missing Python module. If you want to use this '
'importer, you will need to install the "python-sqlite" module.')
ImportSelectLong = translate('OpenLP.Ui', 'Select the import format and the location to import from.')
NoSqlite = translate('OpenLP.Ui', 'The openlp.org 1.x importer has been disabled due to a missing Python module. '
'If you want to use this importer, you will need to install the "python-sqlite" module.')
OpenTypeFile = translate('OpenLP.Ui', 'Open %s File')
OpenTypeFolder = translate('OpenLP.Ui', 'Open %s Folder')
PercentSymbolFormat = translate('OpenLP.Ui', '%p%')
@ -106,8 +104,7 @@ class OpenLPWizard(QtGui.QWizard):
self.setModal(True)
self.setWizardStyle(QtGui.QWizard.ModernStyle)
self.setOptions(QtGui.QWizard.IndependentPages |
QtGui.QWizard.NoBackButtonOnStartPage |
QtGui.QWizard.NoBackButtonOnLastPage)
QtGui.QWizard.NoBackButtonOnStartPage | QtGui.QWizard.NoBackButtonOnLastPage)
add_welcome_page(self, image)
self.addCustomPages()
self.addProgressPage()
@ -281,8 +278,7 @@ class OpenLPWizard(QtGui.QWizard):
The place where to save the last opened directory.
"""
folder = QtGui.QFileDialog.getExistingDirectory(self, title,
Settings().value(self.plugin.settingsSection + u'/' + setting_name),
QtGui.QFileDialog.ShowDirsOnly)
Settings().value(self.plugin.settingsSection + u'/' + setting_name), QtGui.QFileDialog.ShowDirsOnly)
if folder:
editbox.setText(folder)
Settings().setValue(self.plugin.settingsSection + u'/' + setting_name, folder)