Changeset View
Changeset View
Standalone View
Standalone View
src/SpectacleConfig.cpp
Show All 38 Lines | 29 | { | |||
---|---|---|---|---|---|
39 | // ActiveWindowScreenShot | 39 | // ActiveWindowScreenShot | ||
40 | // CurrentMonitorScreenShot | 40 | // CurrentMonitorScreenShot | ||
41 | // RectangularRegionScreenShot | 41 | // RectangularRegionScreenShot | ||
42 | // FullScreenScreenShot | 42 | // FullScreenScreenShot | ||
43 | // _launch | 43 | // _launch | ||
44 | { | 44 | { | ||
45 | QAction *action = new QAction(i18n("Launch Spectacle")); | 45 | QAction *action = new QAction(i18n("Launch Spectacle")); | ||
46 | action->setObjectName(QStringLiteral("_launch")); | 46 | action->setObjectName(QStringLiteral("_launch")); | ||
47 | action->setProperty("isConfigurationAction", true); | ||||
47 | shortCutActions->addAction(action->objectName(), action); | 48 | shortCutActions->addAction(action->objectName(), action); | ||
48 | } | 49 | } | ||
49 | { | 50 | { | ||
50 | QAction *action = new QAction(i18n("Capture Entire Desktop")); | 51 | QAction *action = new QAction(i18n("Capture Entire Desktop")); | ||
51 | action->setObjectName(QStringLiteral("FullScreenScreenShot")); | 52 | action->setObjectName(QStringLiteral("FullScreenScreenShot")); | ||
53 | action->setProperty("isConfigurationAction", true); | ||||
52 | shortCutActions->addAction(action->objectName(), action); | 54 | shortCutActions->addAction(action->objectName(), action); | ||
53 | } | 55 | } | ||
54 | { | 56 | { | ||
55 | QAction *action = new QAction(i18n("Capture Current Monitor")); | 57 | QAction *action = new QAction(i18n("Capture Current Monitor")); | ||
56 | action->setObjectName(QStringLiteral("CurrentMonitorScreenShot")); | 58 | action->setObjectName(QStringLiteral("CurrentMonitorScreenShot")); | ||
59 | action->setProperty("isConfigurationAction", true); | ||||
57 | shortCutActions->addAction(action->objectName(), action); | 60 | shortCutActions->addAction(action->objectName(), action); | ||
58 | } | 61 | } | ||
59 | { | 62 | { | ||
60 | QAction *action = new QAction(i18n("Capture Active Window")); | 63 | QAction *action = new QAction(i18n("Capture Active Window")); | ||
61 | action->setObjectName(QStringLiteral("ActiveWindowScreenShot")); | 64 | action->setObjectName(QStringLiteral("ActiveWindowScreenShot")); | ||
65 | action->setProperty("isConfigurationAction", true); | ||||
66 | shortCutActions->addAction(action->objectName(), action); | ||||
67 | } | ||||
68 | { | ||||
69 | QAction *action = new QAction(i18n("Window Under Cursor")); | ||||
70 | action->setObjectName(QStringLiteral("WindowUnderCursorScreenShot")); | ||||
71 | action->setProperty("isConfigurationAction", true); | ||||
62 | shortCutActions->addAction(action->objectName(), action); | 72 | shortCutActions->addAction(action->objectName(), action); | ||
davidre: This also adds this to the shortcut editor which is completetly unrelated and untested if… | |||||
63 | } | 73 | } | ||
64 | { | 74 | { | ||
65 | QAction *action = new QAction(i18n("Capture Rectangular Region")); | 75 | QAction *action = new QAction(i18n("Capture Rectangular Region")); | ||
66 | action->setObjectName(QStringLiteral("RectangularRegionScreenShot")); | 76 | action->setObjectName(QStringLiteral("RectangularRegionScreenShot")); | ||
77 | action->setProperty("isConfigurationAction", true); | ||||
67 | shortCutActions->addAction(action->objectName(), action); | 78 | shortCutActions->addAction(action->objectName(), action); | ||
68 | } | 79 | } | ||
69 | } | 80 | } | ||
70 | 81 | | |||
71 | SpectacleConfig::~SpectacleConfig() | 82 | SpectacleConfig::~SpectacleConfig() | ||
72 | {} | 83 | {} | ||
73 | 84 | | |||
74 | SpectacleConfig* SpectacleConfig::instance() | 85 | SpectacleConfig* SpectacleConfig::instance() | ||
▲ Show 20 Lines • Show All 330 Lines • Show Last 20 Lines |
This also adds this to the shortcut editor which is completetly unrelated and untested if shortcut + window under cursor works.