Skip to content
GitLab
Menu
Projects
Groups
Snippets
Help
Help
Support
Community forum
Keyboard shortcuts
?
Submit feedback
Contribute to GitLab
Sign in
Toggle navigation
Menu
Open sidebar
PIM
KAlarm
Commits
3b0afdbf
Commit
3b0afdbf
authored
Oct 25, 2020
by
David Jarvie
Browse files
Cancel any screen saver when an alarm is displayed
parent
6533a3a1
Pipeline
#38681
passed with stage
in 16 minutes and 26 seconds
Changes
5
Pipelines
1
Hide whitespace changes
Inline
Side-by-side
CMakeLists.txt
View file @
3b0afdbf
...
...
@@ -76,6 +76,7 @@ find_package(KF5GlobalAccel ${KF5_MIN_VERSION} REQUIRED)
find_package
(
KF5GuiAddons
${
KF5_MIN_VERSION
}
REQUIRED
)
find_package
(
KF5Holidays
${
KF5_MIN_VERSION
}
CONFIG REQUIRED
)
find_package
(
KF5I18n
${
KF5_MIN_VERSION
}
CONFIG REQUIRED
)
find_package
(
KF5IdleTime
${
KF5_MIN_VERSION
}
CONFIG REQUIRED
)
find_package
(
KF5JobWidgets
${
KF5_MIN_VERSION
}
REQUIRED
)
find_package
(
KF5KCMUtils
${
KF5_MIN_VERSION
}
CONFIG REQUIRED
)
find_package
(
KF5KIO
${
KF5_MIN_VERSION
}
CONFIG REQUIRED
)
...
...
Changelog
View file @
3b0afdbf
...
...
@@ -3,6 +3,7 @@ KAlarm Change Log
=== Version 3.1.0 (KDE Applications 20.12) --- 25 October 2020 ===
+ Add option to show alarm message as a notification instead of in a window [KDE Bug 345922]
+ Don't execute display alarms while desktop notifications are inhibited.
+ Cancel any screen saver when an alarm is displayed.
=== Version 3.0.3 (KDE Applications 20.08.3) --- 25 October 2020 ===
+ Prevent resources being disabled at logout [KDE Bug 427722]
...
...
src/CMakeLists.txt
View file @
3b0afdbf
...
...
@@ -173,6 +173,7 @@ target_link_libraries(kalarm_bin
KF5::GlobalAccel
KF5::GuiAddons
KF5::Holidays
KF5::IdleTime
KF5::KIOWidgets
KF5::Notifications
KF5::NotifyConfig
...
...
src/messagenotification.cpp
View file @
3b0afdbf
...
...
@@ -18,6 +18,7 @@
#include <KAboutData>
#include <KLocalizedString>
#include <KIdleTime>
#ifdef RESTORE_NOTIFICATIONS
#include <KConfigGroup>
#include <KConfigGui>
...
...
@@ -360,6 +361,9 @@ void MessageNotification::showDisplay()
qCDebug
(
KALARM_LOG
)
<<
"MessageNotification::showDisplay: sendEvent"
;
sendEvent
();
mShown
=
true
;
// Ensure that the screen wakes from sleep, in case the window manager
// doesn't do this when the notification is displayed.
KIdleTime
::
instance
()
->
simulateUserActivity
();
}
if
(
!
mDisplayComplete
&&
!
mErrorWindow
()
&&
mAlarmType
()
!=
KAAlarm
::
INVALID_ALARM
)
mHelper
->
displayComplete
(
false
);
// reschedule
...
...
src/messagewindow.cpp
View file @
3b0afdbf
...
...
@@ -34,6 +34,7 @@
#include <KTextEdit>
#include <KWindowSystem>
#include <KSqueezedTextLabel>
#include <KIdleTime>
#if KDEPIM_HAVE_X11
#include <KWindowInfo>
#include <netwm.h>
...
...
@@ -827,6 +828,9 @@ void MessageWindow::display()
if
(
Preferences
::
messageButtonDelay
()
==
0
)
move
(
0
,
0
);
MainWindowBase
::
show
();
// Ensure that the screen wakes from sleep, in case the window manager
// doesn't do this when the window is displayed.
KIdleTime
::
instance
()
->
simulateUserActivity
();
}
}
...
...
Write
Preview
Markdown
is supported
0%
Try again
or
attach a new file
.
Attach a file
Cancel
You are about to add
0
people
to the discussion. Proceed with caution.
Finish editing this message first!
Cancel
Please
register
or
sign in
to comment