mirror of
https://github.com/YACReader/yacreader
synced 2025-05-28 03:10:27 -04:00
Format
This commit is contained in:
parent
e587f59ddb
commit
a632480422
@ -87,7 +87,7 @@
|
||||
#include <shellapi.h>
|
||||
#endif
|
||||
#ifdef Q_OS_MACOS
|
||||
#include "trayhandler.h"
|
||||
#include "trayhandler.h"
|
||||
#endif
|
||||
|
||||
LibraryWindow::LibraryWindow()
|
||||
@ -531,229 +531,229 @@ void LibraryWindow::createActions()
|
||||
setAllAsNonReadAction->setToolTip(tr("Set all comics as unread"));
|
||||
setAllAsNonReadAction->setIcon(QIcon(":/images/comics_view_toolbar/setAllUnread.png"));*/
|
||||
|
||||
showHideMarksAction = new QAction(tr("Show/Hide marks"), this);
|
||||
showHideMarksAction->setToolTip(tr("Show or hide read marks"));
|
||||
showHideMarksAction->setData(SHOW_HIDE_MARKS_ACTION_YL);
|
||||
showHideMarksAction->setShortcut(ShortcutsManager::getShortcutsManager().getShortcut(SHOW_HIDE_MARKS_ACTION_YL));
|
||||
showHideMarksAction->setCheckable(true);
|
||||
showHideMarksAction->setIcon(QIcon(":/images/comics_view_toolbar/showMarks.png"));
|
||||
showHideMarksAction->setChecked(true);
|
||||
showHideMarksAction = new QAction(tr("Show/Hide marks"), this);
|
||||
showHideMarksAction->setToolTip(tr("Show or hide read marks"));
|
||||
showHideMarksAction->setData(SHOW_HIDE_MARKS_ACTION_YL);
|
||||
showHideMarksAction->setShortcut(ShortcutsManager::getShortcutsManager().getShortcut(SHOW_HIDE_MARKS_ACTION_YL));
|
||||
showHideMarksAction->setCheckable(true);
|
||||
showHideMarksAction->setIcon(QIcon(":/images/comics_view_toolbar/showMarks.png"));
|
||||
showHideMarksAction->setChecked(true);
|
||||
#ifndef Q_OS_MAC
|
||||
toggleFullScreenAction = new QAction(tr("Fullscreen mode on/off"), this);
|
||||
toggleFullScreenAction->setToolTip(tr("Fullscreen mode on/off"));
|
||||
toggleFullScreenAction->setData(TOGGLE_FULL_SCREEN_ACTION_YL);
|
||||
toggleFullScreenAction->setShortcut(ShortcutsManager::getShortcutsManager().getShortcut(TOGGLE_FULL_SCREEN_ACTION_YL));
|
||||
QIcon icoFullscreenButton;
|
||||
icoFullscreenButton.addPixmap(QPixmap(":/images/main_toolbar/fullscreen.png"), QIcon::Normal);
|
||||
toggleFullScreenAction->setIcon(icoFullscreenButton);
|
||||
toggleFullScreenAction = new QAction(tr("Fullscreen mode on/off"), this);
|
||||
toggleFullScreenAction->setToolTip(tr("Fullscreen mode on/off"));
|
||||
toggleFullScreenAction->setData(TOGGLE_FULL_SCREEN_ACTION_YL);
|
||||
toggleFullScreenAction->setShortcut(ShortcutsManager::getShortcutsManager().getShortcut(TOGGLE_FULL_SCREEN_ACTION_YL));
|
||||
QIcon icoFullscreenButton;
|
||||
icoFullscreenButton.addPixmap(QPixmap(":/images/main_toolbar/fullscreen.png"), QIcon::Normal);
|
||||
toggleFullScreenAction->setIcon(icoFullscreenButton);
|
||||
#endif
|
||||
helpAboutAction = new QAction(this);
|
||||
helpAboutAction->setToolTip(tr("Help, About YACReader"));
|
||||
helpAboutAction->setData(HELP_ABOUT_ACTION_YL);
|
||||
helpAboutAction->setShortcut(ShortcutsManager::getShortcutsManager().getShortcut(HELP_ABOUT_ACTION_YL));
|
||||
QIcon icoHelpButton;
|
||||
icoHelpButton.addFile(":/images/main_toolbar/help.png", QSize(), QIcon::Normal);
|
||||
helpAboutAction->setIcon(icoHelpButton);
|
||||
helpAboutAction = new QAction(this);
|
||||
helpAboutAction->setToolTip(tr("Help, About YACReader"));
|
||||
helpAboutAction->setData(HELP_ABOUT_ACTION_YL);
|
||||
helpAboutAction->setShortcut(ShortcutsManager::getShortcutsManager().getShortcut(HELP_ABOUT_ACTION_YL));
|
||||
QIcon icoHelpButton;
|
||||
icoHelpButton.addFile(":/images/main_toolbar/help.png", QSize(), QIcon::Normal);
|
||||
helpAboutAction->setIcon(icoHelpButton);
|
||||
|
||||
addFolderAction = new QAction(tr("Add new folder"), this);
|
||||
addFolderAction->setData(ADD_FOLDER_ACTION_YL);
|
||||
addFolderAction->setShortcut(ShortcutsManager::getShortcutsManager().getShortcut(ADD_FOLDER_ACTION_YL));
|
||||
addFolderAction->setToolTip(tr("Add new folder to the current library"));
|
||||
addFolderAction->setIcon(QIcon(":/images/sidebar/addNew_sidebar.png"));
|
||||
addFolderAction = new QAction(tr("Add new folder"), this);
|
||||
addFolderAction->setData(ADD_FOLDER_ACTION_YL);
|
||||
addFolderAction->setShortcut(ShortcutsManager::getShortcutsManager().getShortcut(ADD_FOLDER_ACTION_YL));
|
||||
addFolderAction->setToolTip(tr("Add new folder to the current library"));
|
||||
addFolderAction->setIcon(QIcon(":/images/sidebar/addNew_sidebar.png"));
|
||||
|
||||
deleteFolderAction = new QAction(tr("Delete folder"), this);
|
||||
deleteFolderAction->setData(REMOVE_FOLDER_ACTION_YL);
|
||||
deleteFolderAction->setShortcut(ShortcutsManager::getShortcutsManager().getShortcut(REMOVE_FOLDER_ACTION_YL));
|
||||
deleteFolderAction->setToolTip(tr("Delete current folder from disk"));
|
||||
deleteFolderAction->setIcon(QIcon(":/images/sidebar/delete_sidebar.png"));
|
||||
deleteFolderAction = new QAction(tr("Delete folder"), this);
|
||||
deleteFolderAction->setData(REMOVE_FOLDER_ACTION_YL);
|
||||
deleteFolderAction->setShortcut(ShortcutsManager::getShortcutsManager().getShortcut(REMOVE_FOLDER_ACTION_YL));
|
||||
deleteFolderAction->setToolTip(tr("Delete current folder from disk"));
|
||||
deleteFolderAction->setIcon(QIcon(":/images/sidebar/delete_sidebar.png"));
|
||||
|
||||
setRootIndexAction = new QAction(this);
|
||||
setRootIndexAction->setData(SET_ROOT_INDEX_ACTION_YL);
|
||||
setRootIndexAction->setShortcut(ShortcutsManager::getShortcutsManager().getShortcut(SET_ROOT_INDEX_ACTION_YL));
|
||||
setRootIndexAction->setToolTip(tr("Select root node"));
|
||||
setRootIndexAction->setIcon(QIcon(":/images/sidebar/setRoot.png"));
|
||||
setRootIndexAction = new QAction(this);
|
||||
setRootIndexAction->setData(SET_ROOT_INDEX_ACTION_YL);
|
||||
setRootIndexAction->setShortcut(ShortcutsManager::getShortcutsManager().getShortcut(SET_ROOT_INDEX_ACTION_YL));
|
||||
setRootIndexAction->setToolTip(tr("Select root node"));
|
||||
setRootIndexAction->setIcon(QIcon(":/images/sidebar/setRoot.png"));
|
||||
|
||||
expandAllNodesAction = new QAction(this);
|
||||
expandAllNodesAction->setToolTip(tr("Expand all nodes"));
|
||||
expandAllNodesAction->setData(EXPAND_ALL_NODES_ACTION_YL);
|
||||
expandAllNodesAction->setShortcut(ShortcutsManager::getShortcutsManager().getShortcut(EXPAND_ALL_NODES_ACTION_YL));
|
||||
expandAllNodesAction->setIcon(QIcon(":/images/sidebar/expand.png"));
|
||||
expandAllNodesAction = new QAction(this);
|
||||
expandAllNodesAction->setToolTip(tr("Expand all nodes"));
|
||||
expandAllNodesAction->setData(EXPAND_ALL_NODES_ACTION_YL);
|
||||
expandAllNodesAction->setShortcut(ShortcutsManager::getShortcutsManager().getShortcut(EXPAND_ALL_NODES_ACTION_YL));
|
||||
expandAllNodesAction->setIcon(QIcon(":/images/sidebar/expand.png"));
|
||||
|
||||
colapseAllNodesAction = new QAction(this);
|
||||
colapseAllNodesAction->setToolTip(tr("Collapse all nodes"));
|
||||
colapseAllNodesAction->setData(COLAPSE_ALL_NODES_ACTION_YL);
|
||||
colapseAllNodesAction->setShortcut(ShortcutsManager::getShortcutsManager().getShortcut(COLAPSE_ALL_NODES_ACTION_YL));
|
||||
colapseAllNodesAction->setIcon(QIcon(":/images/sidebar/colapse.png"));
|
||||
colapseAllNodesAction = new QAction(this);
|
||||
colapseAllNodesAction->setToolTip(tr("Collapse all nodes"));
|
||||
colapseAllNodesAction->setData(COLAPSE_ALL_NODES_ACTION_YL);
|
||||
colapseAllNodesAction->setShortcut(ShortcutsManager::getShortcutsManager().getShortcut(COLAPSE_ALL_NODES_ACTION_YL));
|
||||
colapseAllNodesAction->setIcon(QIcon(":/images/sidebar/colapse.png"));
|
||||
|
||||
optionsAction = new QAction(this);
|
||||
optionsAction->setToolTip(tr("Show options dialog"));
|
||||
optionsAction->setData(OPTIONS_ACTION_YL);
|
||||
optionsAction->setShortcut(ShortcutsManager::getShortcutsManager().getShortcut(OPTIONS_ACTION_YL));
|
||||
QIcon icoSettingsButton;
|
||||
icoSettingsButton.addFile(":/images/main_toolbar/settings.png", QSize(), QIcon::Normal);
|
||||
optionsAction->setIcon(icoSettingsButton);
|
||||
optionsAction = new QAction(this);
|
||||
optionsAction->setToolTip(tr("Show options dialog"));
|
||||
optionsAction->setData(OPTIONS_ACTION_YL);
|
||||
optionsAction->setShortcut(ShortcutsManager::getShortcutsManager().getShortcut(OPTIONS_ACTION_YL));
|
||||
QIcon icoSettingsButton;
|
||||
icoSettingsButton.addFile(":/images/main_toolbar/settings.png", QSize(), QIcon::Normal);
|
||||
optionsAction->setIcon(icoSettingsButton);
|
||||
|
||||
serverConfigAction = new QAction(this);
|
||||
serverConfigAction->setToolTip(tr("Show comics server options dialog"));
|
||||
serverConfigAction->setData(SERVER_CONFIG_ACTION_YL);
|
||||
serverConfigAction->setShortcut(ShortcutsManager::getShortcutsManager().getShortcut(SERVER_CONFIG_ACTION_YL));
|
||||
QIcon icoServerButton;
|
||||
icoServerButton.addFile(":/images/main_toolbar/server.png", QSize(), QIcon::Normal);
|
||||
serverConfigAction->setIcon(icoServerButton);
|
||||
serverConfigAction = new QAction(this);
|
||||
serverConfigAction->setToolTip(tr("Show comics server options dialog"));
|
||||
serverConfigAction->setData(SERVER_CONFIG_ACTION_YL);
|
||||
serverConfigAction->setShortcut(ShortcutsManager::getShortcutsManager().getShortcut(SERVER_CONFIG_ACTION_YL));
|
||||
QIcon icoServerButton;
|
||||
icoServerButton.addFile(":/images/main_toolbar/server.png", QSize(), QIcon::Normal);
|
||||
serverConfigAction->setIcon(icoServerButton);
|
||||
|
||||
toggleComicsViewAction = new QAction(tr("Change between comics views"), this);
|
||||
toggleComicsViewAction->setToolTip(tr("Change between comics views"));
|
||||
QIcon icoViewsButton;
|
||||
toggleComicsViewAction = new QAction(tr("Change between comics views"), this);
|
||||
toggleComicsViewAction->setToolTip(tr("Change between comics views"));
|
||||
QIcon icoViewsButton;
|
||||
|
||||
if (!settings->contains(COMICS_VIEW_STATUS) || settings->value(COMICS_VIEW_STATUS) == Flow)
|
||||
icoViewsButton.addFile(":/images/main_toolbar/grid.png", QSize(), QIcon::Normal);
|
||||
else if (settings->value(COMICS_VIEW_STATUS) == Grid)
|
||||
icoViewsButton.addFile(":/images/main_toolbar/info.png", QSize(), QIcon::Normal);
|
||||
else
|
||||
icoViewsButton.addFile(":/images/main_toolbar/flow.png", QSize(), QIcon::Normal);
|
||||
if (!settings->contains(COMICS_VIEW_STATUS) || settings->value(COMICS_VIEW_STATUS) == Flow)
|
||||
icoViewsButton.addFile(":/images/main_toolbar/grid.png", QSize(), QIcon::Normal);
|
||||
else if (settings->value(COMICS_VIEW_STATUS) == Grid)
|
||||
icoViewsButton.addFile(":/images/main_toolbar/info.png", QSize(), QIcon::Normal);
|
||||
else
|
||||
icoViewsButton.addFile(":/images/main_toolbar/flow.png", QSize(), QIcon::Normal);
|
||||
|
||||
toggleComicsViewAction->setData(TOGGLE_COMICS_VIEW_ACTION_YL);
|
||||
toggleComicsViewAction->setShortcut(ShortcutsManager::getShortcutsManager().getShortcut(TOGGLE_COMICS_VIEW_ACTION_YL));
|
||||
toggleComicsViewAction->setIcon(icoViewsButton);
|
||||
//socialAction = new QAction(this);
|
||||
toggleComicsViewAction->setData(TOGGLE_COMICS_VIEW_ACTION_YL);
|
||||
toggleComicsViewAction->setShortcut(ShortcutsManager::getShortcutsManager().getShortcut(TOGGLE_COMICS_VIEW_ACTION_YL));
|
||||
toggleComicsViewAction->setIcon(icoViewsButton);
|
||||
//socialAction = new QAction(this);
|
||||
|
||||
openContainingFolderAction = new QAction(this);
|
||||
openContainingFolderAction->setText(tr("Open folder..."));
|
||||
openContainingFolderAction->setData(OPEN_CONTAINING_FOLDER_ACTION_YL);
|
||||
openContainingFolderAction->setShortcut(ShortcutsManager::getShortcutsManager().getShortcut(OPEN_CONTAINING_FOLDER_ACTION_YL));
|
||||
openContainingFolderAction->setIcon(QIcon(":/images/menus_icons/open.png"));
|
||||
openContainingFolderAction = new QAction(this);
|
||||
openContainingFolderAction->setText(tr("Open folder..."));
|
||||
openContainingFolderAction->setData(OPEN_CONTAINING_FOLDER_ACTION_YL);
|
||||
openContainingFolderAction->setShortcut(ShortcutsManager::getShortcutsManager().getShortcut(OPEN_CONTAINING_FOLDER_ACTION_YL));
|
||||
openContainingFolderAction->setIcon(QIcon(":/images/menus_icons/open.png"));
|
||||
|
||||
setFolderAsNotCompletedAction = new QAction(this);
|
||||
setFolderAsNotCompletedAction->setText(tr("Set as uncompleted"));
|
||||
setFolderAsNotCompletedAction->setData(SET_FOLDER_AS_NOT_COMPLETED_ACTION_YL);
|
||||
setFolderAsNotCompletedAction->setShortcut(ShortcutsManager::getShortcutsManager().getShortcut(SET_FOLDER_AS_NOT_COMPLETED_ACTION_YL));
|
||||
setFolderAsNotCompletedAction = new QAction(this);
|
||||
setFolderAsNotCompletedAction->setText(tr("Set as uncompleted"));
|
||||
setFolderAsNotCompletedAction->setData(SET_FOLDER_AS_NOT_COMPLETED_ACTION_YL);
|
||||
setFolderAsNotCompletedAction->setShortcut(ShortcutsManager::getShortcutsManager().getShortcut(SET_FOLDER_AS_NOT_COMPLETED_ACTION_YL));
|
||||
|
||||
setFolderAsCompletedAction = new QAction(this);
|
||||
setFolderAsCompletedAction->setText(tr("Set as completed"));
|
||||
setFolderAsCompletedAction->setData(SET_FOLDER_AS_COMPLETED_ACTION_YL);
|
||||
setFolderAsCompletedAction->setShortcut(ShortcutsManager::getShortcutsManager().getShortcut(SET_FOLDER_AS_COMPLETED_ACTION_YL));
|
||||
setFolderAsCompletedAction = new QAction(this);
|
||||
setFolderAsCompletedAction->setText(tr("Set as completed"));
|
||||
setFolderAsCompletedAction->setData(SET_FOLDER_AS_COMPLETED_ACTION_YL);
|
||||
setFolderAsCompletedAction->setShortcut(ShortcutsManager::getShortcutsManager().getShortcut(SET_FOLDER_AS_COMPLETED_ACTION_YL));
|
||||
|
||||
setFolderAsReadAction = new QAction(this);
|
||||
setFolderAsReadAction->setText(tr("Set as read"));
|
||||
setFolderAsReadAction->setData(SET_FOLDER_AS_READ_ACTION_YL);
|
||||
setFolderAsReadAction->setShortcut(ShortcutsManager::getShortcutsManager().getShortcut(SET_FOLDER_AS_READ_ACTION_YL));
|
||||
setFolderAsReadAction = new QAction(this);
|
||||
setFolderAsReadAction->setText(tr("Set as read"));
|
||||
setFolderAsReadAction->setData(SET_FOLDER_AS_READ_ACTION_YL);
|
||||
setFolderAsReadAction->setShortcut(ShortcutsManager::getShortcutsManager().getShortcut(SET_FOLDER_AS_READ_ACTION_YL));
|
||||
|
||||
setFolderAsUnreadAction = new QAction(this);
|
||||
setFolderAsUnreadAction->setText(tr("Set as unread"));
|
||||
setFolderAsUnreadAction->setData(SET_FOLDER_AS_UNREAD_ACTION_YL);
|
||||
setFolderAsUnreadAction->setShortcut(ShortcutsManager::getShortcutsManager().getShortcut(SET_FOLDER_AS_UNREAD_ACTION_YL));
|
||||
setFolderAsUnreadAction = new QAction(this);
|
||||
setFolderAsUnreadAction->setText(tr("Set as unread"));
|
||||
setFolderAsUnreadAction->setData(SET_FOLDER_AS_UNREAD_ACTION_YL);
|
||||
setFolderAsUnreadAction->setShortcut(ShortcutsManager::getShortcutsManager().getShortcut(SET_FOLDER_AS_UNREAD_ACTION_YL));
|
||||
|
||||
openContainingFolderComicAction = new QAction(this);
|
||||
openContainingFolderComicAction->setText(tr("Open containing folder..."));
|
||||
openContainingFolderComicAction->setData(OPEN_CONTAINING_FOLDER_COMIC_ACTION_YL);
|
||||
openContainingFolderComicAction->setShortcut(ShortcutsManager::getShortcutsManager().getShortcut(OPEN_CONTAINING_FOLDER_COMIC_ACTION_YL));
|
||||
openContainingFolderComicAction->setIcon(QIcon(":/images/menus_icons/open.png"));
|
||||
openContainingFolderComicAction = new QAction(this);
|
||||
openContainingFolderComicAction->setText(tr("Open containing folder..."));
|
||||
openContainingFolderComicAction->setData(OPEN_CONTAINING_FOLDER_COMIC_ACTION_YL);
|
||||
openContainingFolderComicAction->setShortcut(ShortcutsManager::getShortcutsManager().getShortcut(OPEN_CONTAINING_FOLDER_COMIC_ACTION_YL));
|
||||
openContainingFolderComicAction->setIcon(QIcon(":/images/menus_icons/open.png"));
|
||||
|
||||
resetComicRatingAction = new QAction(this);
|
||||
resetComicRatingAction->setText(tr("Reset comic rating"));
|
||||
resetComicRatingAction->setData(RESET_COMIC_RATING_ACTION_YL);
|
||||
resetComicRatingAction->setShortcut(ShortcutsManager::getShortcutsManager().getShortcut(RESET_COMIC_RATING_ACTION_YL));
|
||||
resetComicRatingAction = new QAction(this);
|
||||
resetComicRatingAction->setText(tr("Reset comic rating"));
|
||||
resetComicRatingAction->setData(RESET_COMIC_RATING_ACTION_YL);
|
||||
resetComicRatingAction->setShortcut(ShortcutsManager::getShortcutsManager().getShortcut(RESET_COMIC_RATING_ACTION_YL));
|
||||
|
||||
//Edit comics actions------------------------------------------------------
|
||||
selectAllComicsAction = new QAction(this);
|
||||
selectAllComicsAction->setText(tr("Select all comics"));
|
||||
selectAllComicsAction->setData(SELECT_ALL_COMICS_ACTION_YL);
|
||||
selectAllComicsAction->setShortcut(ShortcutsManager::getShortcutsManager().getShortcut(SELECT_ALL_COMICS_ACTION_YL));
|
||||
selectAllComicsAction->setIcon(QIcon(":/images/comics_view_toolbar/selectAll.png"));
|
||||
//Edit comics actions------------------------------------------------------
|
||||
selectAllComicsAction = new QAction(this);
|
||||
selectAllComicsAction->setText(tr("Select all comics"));
|
||||
selectAllComicsAction->setData(SELECT_ALL_COMICS_ACTION_YL);
|
||||
selectAllComicsAction->setShortcut(ShortcutsManager::getShortcutsManager().getShortcut(SELECT_ALL_COMICS_ACTION_YL));
|
||||
selectAllComicsAction->setIcon(QIcon(":/images/comics_view_toolbar/selectAll.png"));
|
||||
|
||||
editSelectedComicsAction = new QAction(this);
|
||||
editSelectedComicsAction->setText(tr("Edit"));
|
||||
editSelectedComicsAction->setData(EDIT_SELECTED_COMICS_ACTION_YL);
|
||||
editSelectedComicsAction->setShortcut(ShortcutsManager::getShortcutsManager().getShortcut(EDIT_SELECTED_COMICS_ACTION_YL));
|
||||
editSelectedComicsAction->setIcon(QIcon(":/images/comics_view_toolbar/editComic.png"));
|
||||
editSelectedComicsAction = new QAction(this);
|
||||
editSelectedComicsAction->setText(tr("Edit"));
|
||||
editSelectedComicsAction->setData(EDIT_SELECTED_COMICS_ACTION_YL);
|
||||
editSelectedComicsAction->setShortcut(ShortcutsManager::getShortcutsManager().getShortcut(EDIT_SELECTED_COMICS_ACTION_YL));
|
||||
editSelectedComicsAction->setIcon(QIcon(":/images/comics_view_toolbar/editComic.png"));
|
||||
|
||||
asignOrderAction = new QAction(this);
|
||||
asignOrderAction->setText(tr("Assign current order to comics"));
|
||||
asignOrderAction->setData(ASIGN_ORDER_ACTION_YL);
|
||||
asignOrderAction->setShortcut(ShortcutsManager::getShortcutsManager().getShortcut(ASIGN_ORDER_ACTION_YL));
|
||||
asignOrderAction->setIcon(QIcon(":/images/comics_view_toolbar/asignNumber.png"));
|
||||
asignOrderAction = new QAction(this);
|
||||
asignOrderAction->setText(tr("Assign current order to comics"));
|
||||
asignOrderAction->setData(ASIGN_ORDER_ACTION_YL);
|
||||
asignOrderAction->setShortcut(ShortcutsManager::getShortcutsManager().getShortcut(ASIGN_ORDER_ACTION_YL));
|
||||
asignOrderAction->setIcon(QIcon(":/images/comics_view_toolbar/asignNumber.png"));
|
||||
|
||||
forceCoverExtractedAction = new QAction(this);
|
||||
forceCoverExtractedAction->setText(tr("Update cover"));
|
||||
forceCoverExtractedAction->setData(FORCE_COVER_EXTRACTED_ACTION_YL);
|
||||
forceCoverExtractedAction->setShortcut(ShortcutsManager::getShortcutsManager().getShortcut(FORCE_COVER_EXTRACTED_ACTION_YL));
|
||||
forceCoverExtractedAction->setIcon(QIcon(":/images/importCover.png"));
|
||||
forceCoverExtractedAction = new QAction(this);
|
||||
forceCoverExtractedAction->setText(tr("Update cover"));
|
||||
forceCoverExtractedAction->setData(FORCE_COVER_EXTRACTED_ACTION_YL);
|
||||
forceCoverExtractedAction->setShortcut(ShortcutsManager::getShortcutsManager().getShortcut(FORCE_COVER_EXTRACTED_ACTION_YL));
|
||||
forceCoverExtractedAction->setIcon(QIcon(":/images/importCover.png"));
|
||||
|
||||
deleteComicsAction = new QAction(this);
|
||||
deleteComicsAction->setText(tr("Delete selected comics"));
|
||||
deleteComicsAction->setData(DELETE_COMICS_ACTION_YL);
|
||||
deleteComicsAction->setShortcut(ShortcutsManager::getShortcutsManager().getShortcut(DELETE_COMICS_ACTION_YL));
|
||||
deleteComicsAction->setIcon(QIcon(":/images/comics_view_toolbar/trash.png"));
|
||||
deleteComicsAction = new QAction(this);
|
||||
deleteComicsAction->setText(tr("Delete selected comics"));
|
||||
deleteComicsAction->setData(DELETE_COMICS_ACTION_YL);
|
||||
deleteComicsAction->setShortcut(ShortcutsManager::getShortcutsManager().getShortcut(DELETE_COMICS_ACTION_YL));
|
||||
deleteComicsAction->setIcon(QIcon(":/images/comics_view_toolbar/trash.png"));
|
||||
|
||||
getInfoAction = new QAction(this);
|
||||
getInfoAction->setData(GET_INFO_ACTION_YL);
|
||||
getInfoAction->setShortcut(ShortcutsManager::getShortcutsManager().getShortcut(GET_INFO_ACTION_YL));
|
||||
getInfoAction->setText(tr("Download tags from Comic Vine"));
|
||||
getInfoAction->setIcon(QIcon(":/images/comics_view_toolbar/getInfo.png"));
|
||||
//-------------------------------------------------------------------------
|
||||
getInfoAction = new QAction(this);
|
||||
getInfoAction->setData(GET_INFO_ACTION_YL);
|
||||
getInfoAction->setShortcut(ShortcutsManager::getShortcutsManager().getShortcut(GET_INFO_ACTION_YL));
|
||||
getInfoAction->setText(tr("Download tags from Comic Vine"));
|
||||
getInfoAction->setIcon(QIcon(":/images/comics_view_toolbar/getInfo.png"));
|
||||
//-------------------------------------------------------------------------
|
||||
|
||||
showEditShortcutsAction = new QAction(tr("Edit shortcuts"), this);
|
||||
showEditShortcutsAction->setData(SHOW_EDIT_SHORTCUTS_ACTION_YL);
|
||||
showEditShortcutsAction->setShortcut(ShortcutsManager::getShortcutsManager().getShortcut(SHOW_EDIT_SHORTCUTS_ACTION_YL));
|
||||
showEditShortcutsAction->setShortcutContext(Qt::ApplicationShortcut);
|
||||
addAction(showEditShortcutsAction);
|
||||
showEditShortcutsAction = new QAction(tr("Edit shortcuts"), this);
|
||||
showEditShortcutsAction->setData(SHOW_EDIT_SHORTCUTS_ACTION_YL);
|
||||
showEditShortcutsAction->setShortcut(ShortcutsManager::getShortcutsManager().getShortcut(SHOW_EDIT_SHORTCUTS_ACTION_YL));
|
||||
showEditShortcutsAction->setShortcutContext(Qt::ApplicationShortcut);
|
||||
addAction(showEditShortcutsAction);
|
||||
|
||||
updateFolderAction = new QAction(tr("Update folder"), this);
|
||||
updateFolderAction->setIcon(QIcon(":/images/menus_icons/updateLibraryIcon.png"));
|
||||
updateFolderAction = new QAction(tr("Update folder"), this);
|
||||
updateFolderAction->setIcon(QIcon(":/images/menus_icons/updateLibraryIcon.png"));
|
||||
|
||||
updateCurrentFolderAction = new QAction(tr("Update current folder"), this);
|
||||
updateCurrentFolderAction->setData(UPDATE_CURRENT_FOLDER_ACTION_YL);
|
||||
updateCurrentFolderAction->setShortcut(ShortcutsManager::getShortcutsManager().getShortcut(UPDATE_CURRENT_FOLDER_ACTION_YL));
|
||||
updateCurrentFolderAction->setIcon(QIcon(":/images/menus_icons/updateLibraryIcon.png"));
|
||||
updateCurrentFolderAction = new QAction(tr("Update current folder"), this);
|
||||
updateCurrentFolderAction->setData(UPDATE_CURRENT_FOLDER_ACTION_YL);
|
||||
updateCurrentFolderAction->setShortcut(ShortcutsManager::getShortcutsManager().getShortcut(UPDATE_CURRENT_FOLDER_ACTION_YL));
|
||||
updateCurrentFolderAction->setIcon(QIcon(":/images/menus_icons/updateLibraryIcon.png"));
|
||||
|
||||
addReadingListAction = new QAction(tr("Add new reading list"), this);
|
||||
addReadingListAction->setData(ADD_READING_LIST_ACTION_YL);
|
||||
addReadingListAction->setShortcut(ShortcutsManager::getShortcutsManager().getShortcut(ADD_READING_LIST_ACTION_YL));
|
||||
addReadingListAction->setToolTip(tr("Add a new reading list to the current library"));
|
||||
addReadingListAction->setIcon(QIcon(":/images/sidebar/addNew_sidebar.png"));
|
||||
addReadingListAction = new QAction(tr("Add new reading list"), this);
|
||||
addReadingListAction->setData(ADD_READING_LIST_ACTION_YL);
|
||||
addReadingListAction->setShortcut(ShortcutsManager::getShortcutsManager().getShortcut(ADD_READING_LIST_ACTION_YL));
|
||||
addReadingListAction->setToolTip(tr("Add a new reading list to the current library"));
|
||||
addReadingListAction->setIcon(QIcon(":/images/sidebar/addNew_sidebar.png"));
|
||||
|
||||
deleteReadingListAction = new QAction(tr("Remove reading list"), this);
|
||||
deleteReadingListAction->setData(REMOVE_READING_LIST_ACTION_YL);
|
||||
deleteReadingListAction->setShortcut(ShortcutsManager::getShortcutsManager().getShortcut(REMOVE_READING_LIST_ACTION_YL));
|
||||
deleteReadingListAction->setToolTip(tr("Remove current reading list from the library"));
|
||||
deleteReadingListAction->setIcon(QIcon(":/images/sidebar/delete_sidebar.png"));
|
||||
deleteReadingListAction = new QAction(tr("Remove reading list"), this);
|
||||
deleteReadingListAction->setData(REMOVE_READING_LIST_ACTION_YL);
|
||||
deleteReadingListAction->setShortcut(ShortcutsManager::getShortcutsManager().getShortcut(REMOVE_READING_LIST_ACTION_YL));
|
||||
deleteReadingListAction->setToolTip(tr("Remove current reading list from the library"));
|
||||
deleteReadingListAction->setIcon(QIcon(":/images/sidebar/delete_sidebar.png"));
|
||||
|
||||
addLabelAction = new QAction(tr("Add new label"), this);
|
||||
addLabelAction->setData(ADD_LABEL_ACTION_YL);
|
||||
addLabelAction->setShortcut(ShortcutsManager::getShortcutsManager().getShortcut(ADD_LABEL_ACTION_YL));
|
||||
addLabelAction->setToolTip(tr("Add a new label to this library"));
|
||||
addLabelAction->setIcon(QIcon(":/images/sidebar/addLabelIcon.png"));
|
||||
addLabelAction = new QAction(tr("Add new label"), this);
|
||||
addLabelAction->setData(ADD_LABEL_ACTION_YL);
|
||||
addLabelAction->setShortcut(ShortcutsManager::getShortcutsManager().getShortcut(ADD_LABEL_ACTION_YL));
|
||||
addLabelAction->setToolTip(tr("Add a new label to this library"));
|
||||
addLabelAction->setIcon(QIcon(":/images/sidebar/addLabelIcon.png"));
|
||||
|
||||
renameListAction = new QAction(tr("Rename selected list"), this);
|
||||
renameListAction->setData(RENAME_LIST_ACTION_YL);
|
||||
renameListAction->setShortcut(ShortcutsManager::getShortcutsManager().getShortcut(RENAME_LIST_ACTION_YL));
|
||||
renameListAction->setToolTip(tr("Rename any selected labels or lists"));
|
||||
renameListAction->setIcon(QIcon(":/images/sidebar/renameListIcon.png"));
|
||||
renameListAction = new QAction(tr("Rename selected list"), this);
|
||||
renameListAction->setData(RENAME_LIST_ACTION_YL);
|
||||
renameListAction->setShortcut(ShortcutsManager::getShortcutsManager().getShortcut(RENAME_LIST_ACTION_YL));
|
||||
renameListAction->setToolTip(tr("Rename any selected labels or lists"));
|
||||
renameListAction->setIcon(QIcon(":/images/sidebar/renameListIcon.png"));
|
||||
|
||||
//--
|
||||
addToMenuAction = new QAction(tr("Add to..."), this);
|
||||
//--
|
||||
addToMenuAction = new QAction(tr("Add to..."), this);
|
||||
|
||||
addToFavoritesAction = new QAction(tr("Favorites"), this);
|
||||
addToFavoritesAction->setData(ADD_TO_FAVORITES_ACTION_YL);
|
||||
addToFavoritesAction->setShortcut(ShortcutsManager::getShortcutsManager().getShortcut(ADD_TO_FAVORITES_ACTION_YL));
|
||||
addToFavoritesAction->setToolTip(tr("Add selected comics to favorites list"));
|
||||
addToFavoritesAction->setIcon(QIcon(":/images/lists/default_1.png"));
|
||||
addToFavoritesAction = new QAction(tr("Favorites"), this);
|
||||
addToFavoritesAction->setData(ADD_TO_FAVORITES_ACTION_YL);
|
||||
addToFavoritesAction->setShortcut(ShortcutsManager::getShortcutsManager().getShortcut(ADD_TO_FAVORITES_ACTION_YL));
|
||||
addToFavoritesAction->setToolTip(tr("Add selected comics to favorites list"));
|
||||
addToFavoritesAction->setIcon(QIcon(":/images/lists/default_1.png"));
|
||||
|
||||
//actions not asigned to any widget
|
||||
this->addAction(saveCoversToAction);
|
||||
this->addAction(openContainingFolderAction);
|
||||
this->addAction(updateCurrentFolderAction);
|
||||
this->addAction(resetComicRatingAction);
|
||||
this->addAction(setFolderAsCompletedAction);
|
||||
this->addAction(setFolderAsNotCompletedAction);
|
||||
this->addAction(setFolderAsReadAction);
|
||||
this->addAction(setFolderAsUnreadAction);
|
||||
//actions not asigned to any widget
|
||||
this->addAction(saveCoversToAction);
|
||||
this->addAction(openContainingFolderAction);
|
||||
this->addAction(updateCurrentFolderAction);
|
||||
this->addAction(resetComicRatingAction);
|
||||
this->addAction(setFolderAsCompletedAction);
|
||||
this->addAction(setFolderAsNotCompletedAction);
|
||||
this->addAction(setFolderAsReadAction);
|
||||
this->addAction(setFolderAsUnreadAction);
|
||||
#ifndef Q_OS_MAC
|
||||
this->addAction(toggleFullScreenAction);
|
||||
this->addAction(toggleFullScreenAction);
|
||||
#endif
|
||||
|
||||
//disable actions
|
||||
disableAllActions();
|
||||
//disable actions
|
||||
disableAllActions();
|
||||
}
|
||||
void LibraryWindow::disableComicsActions(bool disabled)
|
||||
{
|
||||
|
@ -21,7 +21,7 @@
|
||||
#include "exit_check.h"
|
||||
#include "opengl_checker.h"
|
||||
#ifdef Q_OS_MACOS
|
||||
#include "trayhandler.h"
|
||||
#include "trayhandler.h"
|
||||
#endif
|
||||
|
||||
#include "QsLog.h"
|
||||
@ -130,12 +130,12 @@ int main(int argc, char **argv)
|
||||
app.setApplicationVersion(VERSION);
|
||||
app.setAttribute(Qt::AA_UseHighDpiPixmaps);
|
||||
|
||||
// Set window icon according to Freedesktop icon specification
|
||||
// This is mostly relevant for Linux and other Unix systems
|
||||
if (QIcon::hasThemeIcon("YACReaderLibrary")) {
|
||||
app.setWindowIcon(QIcon::fromTheme("YACReaderLibrary"));
|
||||
}
|
||||
// TODO: We might want to add a fallback icon here.
|
||||
// Set window icon according to Freedesktop icon specification
|
||||
// This is mostly relevant for Linux and other Unix systems
|
||||
if (QIcon::hasThemeIcon("YACReaderLibrary")) {
|
||||
app.setWindowIcon(QIcon::fromTheme("YACReaderLibrary"));
|
||||
}
|
||||
// TODO: We might want to add a fallback icon here.
|
||||
|
||||
QString destLog = YACReader::getSettingsPath() + "/yacreaderlibrary.log";
|
||||
QDir().mkpath(YACReader::getSettingsPath());
|
||||
@ -216,18 +216,18 @@ int main(int argc, char **argv)
|
||||
}
|
||||
|
||||
#ifdef SERVER_RELEASE
|
||||
QSettings * settings = new QSettings(YACReader::getSettingsPath()+"/YACReaderLibrary.ini",QSettings::IniFormat); //TODO unificar la creaci<63>n del fichero de config con el servidor
|
||||
settings->beginGroup("libraryConfig");
|
||||
QSettings *settings = new QSettings(YACReader::getSettingsPath() + "/YACReaderLibrary.ini", QSettings::IniFormat); //TODO unificar la creaci<63>n del fichero de config con el servidor
|
||||
settings->beginGroup("libraryConfig");
|
||||
|
||||
s = new Startup();
|
||||
s = new Startup();
|
||||
|
||||
if (settings->value(SERVER_ON, true).toBool()) {
|
||||
s->start();
|
||||
}
|
||||
#endif
|
||||
QLOG_INFO() << "YACReaderLibrary attempting to start";
|
||||
QLOG_INFO() << "YACReaderLibrary attempting to start";
|
||||
|
||||
logSystemAndConfig();
|
||||
logSystemAndConfig();
|
||||
|
||||
if (YACReaderLocalServer::isRunning()) //s<>lo se permite una instancia de YACReaderLibrary
|
||||
{
|
||||
@ -241,24 +241,24 @@ int main(int argc, char **argv)
|
||||
|
||||
auto mw = new LibraryWindow();
|
||||
|
||||
mw->connect(localServer,SIGNAL(comicUpdated(quint64, const ComicDB &)),mw,SLOT(updateComicsView(quint64, const ComicDB &)), Qt::QueuedConnection);
|
||||
mw->connect(localServer, SIGNAL(comicUpdated(quint64, const ComicDB &)), mw, SLOT(updateComicsView(quint64, const ComicDB &)), Qt::QueuedConnection);
|
||||
|
||||
//connections to localServer
|
||||
//connections to localServer
|
||||
|
||||
mw->show();
|
||||
mw->show();
|
||||
|
||||
int ret = app.exec();
|
||||
int ret = app.exec();
|
||||
|
||||
QLOG_INFO() << "YACReaderLibrary closed with exit code :" << ret;
|
||||
|
||||
YACReader::exitCheck(ret);
|
||||
|
||||
//shutdown
|
||||
s->stop();
|
||||
delete s;
|
||||
localServer->close();
|
||||
delete localServer;
|
||||
delete mw;
|
||||
//shutdown
|
||||
s->stop();
|
||||
delete s;
|
||||
localServer->close();
|
||||
delete localServer;
|
||||
delete mw;
|
||||
|
||||
QsLogging::Logger::destroyInstance();
|
||||
|
||||
|
@ -44,8 +44,8 @@ OptionsDialog::OptionsDialog(QWidget *parent)
|
||||
sw->hide();
|
||||
#endif
|
||||
// Tray icon settings
|
||||
QGroupBox * trayIconBox = new QGroupBox(tr("Tray icon settings"));
|
||||
QVBoxLayout * trayLayout = new QVBoxLayout();
|
||||
QGroupBox *trayIconBox = new QGroupBox(tr("Tray icon settings"));
|
||||
QVBoxLayout *trayLayout = new QVBoxLayout();
|
||||
|
||||
auto apiKeyLayout = new QVBoxLayout();
|
||||
auto apiKeyButton = new QPushButton(tr("Edit Comic Vine API key"));
|
||||
|
@ -19,20 +19,21 @@ public slots:
|
||||
void editApiKey();
|
||||
void restoreOptions(QSettings *settings) override;
|
||||
|
||||
private slots:
|
||||
void useBackgroundImageCheckClicked(bool checked);
|
||||
void backgroundImageOpacitySliderChanged(int value);
|
||||
void backgroundImageBlurRadiusSliderChanged(int value);
|
||||
void useCurrentComicCoverCheckClicked(bool checked);
|
||||
void resetToDefaults();
|
||||
private:
|
||||
QCheckBox * useBackgroundImageCheck;
|
||||
QCheckBox * useCurrentComicCoverCheck;
|
||||
QSlider * backgroundImageOpacitySlider;
|
||||
QSlider * backgroundImageBlurRadiusSlider;
|
||||
QLabel * opacityLabel;
|
||||
QLabel * blurLabel;
|
||||
QPushButton * resetButton;
|
||||
private slots:
|
||||
void useBackgroundImageCheckClicked(bool checked);
|
||||
void backgroundImageOpacitySliderChanged(int value);
|
||||
void backgroundImageBlurRadiusSliderChanged(int value);
|
||||
void useCurrentComicCoverCheckClicked(bool checked);
|
||||
void resetToDefaults();
|
||||
|
||||
private:
|
||||
QCheckBox *useBackgroundImageCheck;
|
||||
QCheckBox *useCurrentComicCoverCheck;
|
||||
QSlider *backgroundImageOpacitySlider;
|
||||
QSlider *backgroundImageBlurRadiusSlider;
|
||||
QLabel *opacityLabel;
|
||||
QLabel *blurLabel;
|
||||
QPushButton *resetButton;
|
||||
};
|
||||
|
||||
#endif
|
||||
|
Loading…
Reference in New Issue
Block a user