forked from openlp/openlp
more
This commit is contained in:
parent
57235cbd36
commit
e6fbdc4f9b
@ -88,11 +88,11 @@ class Ui_FormattingTagDialog(object):
|
|||||||
self.list_data_grid_layout.addWidget(self.tag_table_widget)
|
self.list_data_grid_layout.addWidget(self.tag_table_widget)
|
||||||
self.edit_button_layout = QtWidgets.QHBoxLayout()
|
self.edit_button_layout = QtWidgets.QHBoxLayout()
|
||||||
self.new_button = QtWidgets.QPushButton(formatting_tag_dialog)
|
self.new_button = QtWidgets.QPushButton(formatting_tag_dialog)
|
||||||
self.new_button.setIcon(build_icon(UiIcons().new))
|
self.new_button.setIcon(UiIcons().new)
|
||||||
self.new_button.setObjectName('new_button')
|
self.new_button.setObjectName('new_button')
|
||||||
self.edit_button_layout.addWidget(self.new_button)
|
self.edit_button_layout.addWidget(self.new_button)
|
||||||
self.delete_button = QtWidgets.QPushButton(formatting_tag_dialog)
|
self.delete_button = QtWidgets.QPushButton(formatting_tag_dialog)
|
||||||
self.delete_button.setIcon(build_icon(':/general/general_delete.png'))
|
self.delete_button.setIcon(UiIcons().delete)
|
||||||
self.delete_button.setObjectName('delete_button')
|
self.delete_button.setObjectName('delete_button')
|
||||||
self.edit_button_layout.addWidget(self.delete_button)
|
self.edit_button_layout.addWidget(self.delete_button)
|
||||||
self.edit_button_layout.addStretch()
|
self.edit_button_layout.addStretch()
|
||||||
@ -101,7 +101,7 @@ class Ui_FormattingTagDialog(object):
|
|||||||
self.save_button = self.button_box.button(QtWidgets.QDialogButtonBox.Save)
|
self.save_button = self.button_box.button(QtWidgets.QDialogButtonBox.Save)
|
||||||
self.save_button.setObjectName('save_button')
|
self.save_button.setObjectName('save_button')
|
||||||
self.restore_button = self.button_box.button(QtWidgets.QDialogButtonBox.RestoreDefaults)
|
self.restore_button = self.button_box.button(QtWidgets.QDialogButtonBox.RestoreDefaults)
|
||||||
self.restore_button.setIcon(build_icon(':/general/general_revert.png'))
|
self.restore_button.setIcon(UiIcons().undo)
|
||||||
self.restore_button.setObjectName('restore_button')
|
self.restore_button.setObjectName('restore_button')
|
||||||
self.list_data_grid_layout.addWidget(self.button_box)
|
self.list_data_grid_layout.addWidget(self.button_box)
|
||||||
self.retranslateUi(formatting_tag_dialog)
|
self.retranslateUi(formatting_tag_dialog)
|
||||||
|
@ -53,6 +53,7 @@ class UiIcons(object):
|
|||||||
QtGui.QPalette.ButtonText))
|
QtGui.QPalette.ButtonText))
|
||||||
icon_list = {
|
icon_list = {
|
||||||
'add': 'fa.plus-circle',
|
'add': 'fa.plus-circle',
|
||||||
|
'alert': 'fa.exclamation-triangle',
|
||||||
'arrow_down': 'fa.arrow-down',
|
'arrow_down': 'fa.arrow-down',
|
||||||
'arrow_left': 'fa.arrow-left',
|
'arrow_left': 'fa.arrow-left',
|
||||||
'arrow_right': 'fa.arrow-right',
|
'arrow_right': 'fa.arrow-right',
|
||||||
@ -72,7 +73,9 @@ class UiIcons(object):
|
|||||||
'edit': 'fa.edit',
|
'edit': 'fa.edit',
|
||||||
'exit': 'fa.sign-out',
|
'exit': 'fa.sign-out',
|
||||||
'download': 'fa.cloud-download',
|
'download': 'fa.cloud-download',
|
||||||
|
'info': 'fa.info',
|
||||||
'live': 'fa.camera',
|
'live': 'fa.camera',
|
||||||
|
'manual': 'fa.graduation-cap',
|
||||||
'minus': 'fa.minus',
|
'minus': 'fa.minus',
|
||||||
'music': 'fa.music',
|
'music': 'fa.music',
|
||||||
'new': 'fa.file',
|
'new': 'fa.file',
|
||||||
@ -88,6 +91,7 @@ class UiIcons(object):
|
|||||||
'remote': 'fa.rss',
|
'remote': 'fa.rss',
|
||||||
'save': 'fa.save',
|
'save': 'fa.save',
|
||||||
'settings': 'fa.cogs',
|
'settings': 'fa.cogs',
|
||||||
|
'shortcuts': 'fa.wrench',
|
||||||
'stop': 'fa.stop',
|
'stop': 'fa.stop',
|
||||||
'theme': 'fa.file-image-o',
|
'theme': 'fa.file-image-o',
|
||||||
'top': 'fa.angle-double-up',
|
'top': 'fa.angle-double-up',
|
||||||
|
@ -245,7 +245,7 @@ class Ui_MainWindow(object):
|
|||||||
'toolsOpenDataFolder', icon=UiIcons().open,
|
'toolsOpenDataFolder', icon=UiIcons().open,
|
||||||
category=UiStrings().Tools, can_shortcuts=True)
|
category=UiStrings().Tools, can_shortcuts=True)
|
||||||
self.tools_first_time_wizard = create_action(main_window,
|
self.tools_first_time_wizard = create_action(main_window,
|
||||||
'toolsFirstTimeWizard', icon=':/general/general_revert.png',
|
'toolsFirstTimeWizard', icon=UiIcons().undo,
|
||||||
category=UiStrings().Tools, can_shortcuts=True)
|
category=UiStrings().Tools, can_shortcuts=True)
|
||||||
self.update_theme_images = create_action(main_window,
|
self.update_theme_images = create_action(main_window,
|
||||||
'updateThemeImages', category=UiStrings().Tools, can_shortcuts=True)
|
'updateThemeImages', category=UiStrings().Tools, can_shortcuts=True)
|
||||||
@ -268,7 +268,7 @@ class Ui_MainWindow(object):
|
|||||||
language_item = create_action(main_window, key, checked=qm_list[key] == saved_language)
|
language_item = create_action(main_window, key, checked=qm_list[key] == saved_language)
|
||||||
add_actions(self.language_group, [language_item])
|
add_actions(self.language_group, [language_item])
|
||||||
self.settings_shortcuts_item = create_action(main_window, 'settingsShortcutsItem',
|
self.settings_shortcuts_item = create_action(main_window, 'settingsShortcutsItem',
|
||||||
icon=':/system/system_configure_shortcuts.png',
|
icon=UiIcons().shortcuts,
|
||||||
category=UiStrings().Settings, can_shortcuts=True)
|
category=UiStrings().Settings, can_shortcuts=True)
|
||||||
# Formatting Tags were also known as display tags.
|
# Formatting Tags were also known as display tags.
|
||||||
self.formatting_tag_item = create_action(main_window, 'displayTagItem',
|
self.formatting_tag_item = create_action(main_window, 'displayTagItem',
|
||||||
@ -284,7 +284,7 @@ class Ui_MainWindow(object):
|
|||||||
self.settings_export_item = create_action(main_window, 'settingsExportItem',
|
self.settings_export_item = create_action(main_window, 'settingsExportItem',
|
||||||
category=UiStrings().Export, can_shortcuts=True)
|
category=UiStrings().Export, can_shortcuts=True)
|
||||||
action_list.add_category(UiStrings().Help, CategoryOrder.standard_menu)
|
action_list.add_category(UiStrings().Help, CategoryOrder.standard_menu)
|
||||||
self.about_item = create_action(main_window, 'aboutItem', icon=':/system/system_about.png',
|
self.about_item = create_action(main_window, 'aboutItem', icon=UiIcons().info,
|
||||||
can_shortcuts=True, category=UiStrings().Help,
|
can_shortcuts=True, category=UiStrings().Help,
|
||||||
triggers=self.on_about_item_clicked)
|
triggers=self.on_about_item_clicked)
|
||||||
# Give QT Extra Hint that this is an About Menu Item
|
# Give QT Extra Hint that this is an About Menu Item
|
||||||
@ -293,7 +293,7 @@ class Ui_MainWindow(object):
|
|||||||
self.local_help_file = AppLocation.get_directory(AppLocation.AppDir) / 'OpenLP.chm'
|
self.local_help_file = AppLocation.get_directory(AppLocation.AppDir) / 'OpenLP.chm'
|
||||||
elif is_macosx():
|
elif is_macosx():
|
||||||
self.local_help_file = AppLocation.get_directory(AppLocation.AppDir) / '..' / 'Resources' / 'OpenLP.help'
|
self.local_help_file = AppLocation.get_directory(AppLocation.AppDir) / '..' / 'Resources' / 'OpenLP.help'
|
||||||
self.user_manual_item = create_action(main_window, 'userManualItem', icon=':/system/system_help_contents.png',
|
self.user_manual_item = create_action(main_window, 'userManualItem', icon=UiIcons().manual,
|
||||||
can_shortcuts=True, category=UiStrings().Help,
|
can_shortcuts=True, category=UiStrings().Help,
|
||||||
triggers=self.on_help_clicked)
|
triggers=self.on_help_clicked)
|
||||||
self.web_site_item = create_action(main_window, 'webSiteItem', can_shortcuts=True, category=UiStrings().Help)
|
self.web_site_item = create_action(main_window, 'webSiteItem', can_shortcuts=True, category=UiStrings().Help)
|
||||||
@ -625,7 +625,7 @@ class MainWindow(QtWidgets.QMainWindow, Ui_MainWindow, LogMixin, RegistryPropert
|
|||||||
"""
|
"""
|
||||||
version_text = translate('OpenLP.MainWindow', 'Version {new} of OpenLP is now available for download (you are '
|
version_text = translate('OpenLP.MainWindow', 'Version {new} of OpenLP is now available for download (you are '
|
||||||
'currently running version {current}). \n\nYou can download the latest version from '
|
'currently running version {current}). \n\nYou can download the latest version from '
|
||||||
'http://openlp.org/.').format(new=version, current=get_version()[u'full'])
|
'https://openlp.org/.').format(new=version, current=get_version()[u'full'])
|
||||||
QtWidgets.QMessageBox.question(self, translate('OpenLP.MainWindow', 'OpenLP Version Updated'), version_text)
|
QtWidgets.QMessageBox.question(self, translate('OpenLP.MainWindow', 'OpenLP Version Updated'), version_text)
|
||||||
|
|
||||||
def show(self):
|
def show(self):
|
||||||
@ -775,7 +775,7 @@ class MainWindow(QtWidgets.QMainWindow, Ui_MainWindow, LogMixin, RegistryPropert
|
|||||||
Load the OpenLP website
|
Load the OpenLP website
|
||||||
"""
|
"""
|
||||||
import webbrowser
|
import webbrowser
|
||||||
webbrowser.open_new('http://openlp.org/')
|
webbrowser.open_new('https://openlp.org/')
|
||||||
|
|
||||||
def on_help_clicked(self):
|
def on_help_clicked(self):
|
||||||
"""
|
"""
|
||||||
@ -786,7 +786,7 @@ class MainWindow(QtWidgets.QMainWindow, Ui_MainWindow, LogMixin, RegistryPropert
|
|||||||
QtGui.QDesktopServices.openUrl(QtCore.QUrl.fromLocalFile(str(self.local_help_file)))
|
QtGui.QDesktopServices.openUrl(QtCore.QUrl.fromLocalFile(str(self.local_help_file)))
|
||||||
else:
|
else:
|
||||||
import webbrowser
|
import webbrowser
|
||||||
webbrowser.open_new('http://manual.openlp.org/')
|
webbrowser.open_new('https://manual.openlp.org/')
|
||||||
|
|
||||||
def on_about_item_clicked(self):
|
def on_about_item_clicked(self):
|
||||||
"""
|
"""
|
||||||
|
@ -33,6 +33,7 @@ from openlp.core.lib.db import Manager
|
|||||||
from openlp.core.lib.theme import VerticalType
|
from openlp.core.lib.theme import VerticalType
|
||||||
from openlp.core.lib.ui import create_action
|
from openlp.core.lib.ui import create_action
|
||||||
from openlp.core.ui import AlertLocation
|
from openlp.core.ui import AlertLocation
|
||||||
|
from openlp.core.ui.icons import UiIcons
|
||||||
from openlp.plugins.alerts.endpoint import api_alerts_endpoint, alerts_endpoint
|
from openlp.plugins.alerts.endpoint import api_alerts_endpoint, alerts_endpoint
|
||||||
from openlp.plugins.alerts.forms import AlertForm
|
from openlp.plugins.alerts.forms import AlertForm
|
||||||
from openlp.plugins.alerts.lib import AlertsManager, AlertsTab
|
from openlp.plugins.alerts.lib import AlertsManager, AlertsTab
|
||||||
@ -155,7 +156,7 @@ class AlertsPlugin(Plugin):
|
|||||||
log.info('add tools menu')
|
log.info('add tools menu')
|
||||||
self.tools_alert_item = create_action(tools_menu, 'toolsAlertItem',
|
self.tools_alert_item = create_action(tools_menu, 'toolsAlertItem',
|
||||||
text=translate('AlertsPlugin', '&Alert'),
|
text=translate('AlertsPlugin', '&Alert'),
|
||||||
icon=':/plugins/plugin_alerts.png',
|
icon=UiIcons().alert,
|
||||||
statustip=translate('AlertsPlugin', 'Show an alert message.'),
|
statustip=translate('AlertsPlugin', 'Show an alert message.'),
|
||||||
visible=False, can_shortcuts=True, triggers=self.on_alerts_trigger)
|
visible=False, can_shortcuts=True, triggers=self.on_alerts_trigger)
|
||||||
self.main_window.tools_menu.addAction(self.tools_alert_item)
|
self.main_window.tools_menu.addAction(self.tools_alert_item)
|
||||||
|
Loading…
Reference in New Issue
Block a user