File indexing completed on 2024-04-14 15:52:16

0001 /*
0002     SPDX-FileCopyrightText: 2000 Shie Erlich <krusader@users.sourceforge.net>
0003     SPDX-FileCopyrightText: 2000 Rafi Yanai <krusader@users.sourceforge.net>
0004     SPDX-FileCopyrightText: 2004-2022 Krusader Krew <https://krusader.org>
0005 
0006     SPDX-License-Identifier: GPL-2.0-or-later
0007 */
0008 
0009 #ifndef KRACTIONS_H
0010 #define KRACTIONS_H
0011 
0012 #include "GUI/recentlyclosedtabsmenu.h"
0013 
0014 // QtCore
0015 #include <QObject>
0016 // QtWidgets
0017 #include <QAction>
0018 
0019 #include <KWidgetsAddons/KToggleAction>
0020 
0021 class Krusader;
0022 
0023 class KrActions : public QObject
0024 {
0025     Q_OBJECT
0026 public:
0027     explicit KrActions(QObject *parent)
0028         : QObject(parent)
0029     {
0030     }
0031 
0032     // Actions
0033     static QAction *actCompare;
0034     static QAction *actCmdlinePopup, *actLocate, *actSwitchFullScreenTE;
0035     static QAction *actDiskUsage, *actSavePosition;
0036     static QAction *actHomeTerminal, *actProfiles;
0037     static QAction *actMountMan, *actNewTool, *actSwapPanels, *actSwapSides;
0038     static QAction *actKonfigurator, *actToolsSetup, *actFind;
0039     static QAction *actRemoteEncoding;
0040     static RecentlyClosedTabsMenu *actClosedTabsMenu;
0041     static QAction *actSelectColorMask, *actMultiRename, *actOpenLeftBm, *actOpenRightBm, *actAddBookmark;
0042     static QAction *actSplit;
0043     static QAction *actCombine;
0044     static QAction *actUserMenu;
0045     static QAction *actManageUseractions;
0046 #ifdef SYNCHRONIZER_ENABLED
0047     static QAction *actSyncDirs;
0048 #endif
0049     static QAction *actVerticalMode;
0050     static QAction *actEmptyTrash, *actTrashBin;
0051     static QAction *actPopularUrls;
0052     static KToggleAction *actToggleTerminal;
0053     static QAction *actSelectNewerAndSingle, *actSelectNewer, *actSelectSingle, *actSelectDifferentAndSingle, *actSelectDifferent;
0054     static QAction *actF10Quit;
0055     /** actions for setting the execution mode of commands from commanddline */
0056     static QAction *actExecStartAndForget, *actExecCollectSeparate, *actExecCollectTogether, *actExecTerminalExternal, *actExecTerminalEmbedded;
0057     static KToggleAction *actToggleFnkeys, *actToggleCmdline, *actShowStatusBar, *actToggleHidden, *actCompareDirs;
0058 
0059     static QAction **compareArray[];
0060     /** actions for setting the execution mode of commands from commanddline */
0061     static QAction **execTypeArray[];
0062 
0063     /** JobMan toolbar actions */
0064     static QAction *actJobProgress;
0065     static QAction *actJobControl;
0066     static QAction *actJobMode;
0067     static QAction *actJobUndo;
0068 
0069     static void setupActions(Krusader *krusader);
0070 };
0071 
0072 // krusader's actions - things krusader can do!
0073 #define krHomeTerm KrActions::actHomeTerminal // open terminal@home dir
0074 #define krRemoteEncoding KrActions::actRemoteEncoding // remote encoding menu
0075 #define krMountMan KrActions::actMountMan // run Mount-manager
0076 #define krNewTool KrActions::actNewTool // Add a new tool to menu
0077 #define krKonfigurator KrActions::actKonfigurator
0078 #define krToolsSetup KrActions::actToolsSetup // setup the tools menu
0079 #define krRoot KrActions::actRoot
0080 #define krFind KrActions::actFind // find files
0081 #define krMultiRename KrActions::actMultiRename
0082 // #define krToggleSortByExt KrActions::actToggleSortByExt// Sort by extension
0083 #define krSwitchFullScreenTE KrActions::actSwitchFullScreenTE
0084 #define krCmdlinePopup KrActions::actCmdlinePopup
0085 #define krSplit KrActions::actSplit
0086 #define krCombine KrActions::actCombine
0087 #define krUserMenu KrActions::actUserMenu
0088 #define krPopularUrls KrActions::actPopularUrls
0089 
0090 #endif