Skip to content
GitLab
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
50c9f586
Commit
50c9f586
authored
Apr 22, 2020
by
David Jarvie
Browse files
Add qDebug operator for CalEvent::Type
parent
f2941119
Changes
2
Hide whitespace changes
Inline
Side-by-side
src/kacalendar.cpp
View file @
50c9f586
...
...
@@ -2,7 +2,7 @@
* kacalendar.cpp - KAlarm kcal library calendar and event functions
* This file is part of kalarmcal library, which provides access to KAlarm
* calendar data.
* Copyright © 2001-20
19
David Jarvie <djarvie@kde.org>
* Copyright © 2001-20
20
David Jarvie <djarvie@kde.org>
*
* This library is free software; you can redistribute it and/or modify
* it under the terms of the GNU Library General Public License as published
...
...
@@ -457,4 +457,17 @@ QStringList mimeTypes(Types types)
}
// namespace KAlarmCal
QDebug
operator
<<
(
QDebug
debug
,
KAlarmCal
::
CalEvent
::
Type
type
)
{
const
char
*
str
;
switch
(
type
)
{
case
KAlarmCal
::
CalEvent
::
ACTIVE
:
str
=
"Active alarms"
;
break
;
case
KAlarmCal
::
CalEvent
::
ARCHIVED
:
str
=
"Archived alarms"
;
break
;
case
KAlarmCal
::
CalEvent
::
TEMPLATE
:
str
=
"Alarm templates"
;
break
;
default:
return
debug
;
}
debug
<<
str
;
return
debug
;
}
// vim: et sw=4:
src/kacalendar.h
View file @
50c9f586
...
...
@@ -2,7 +2,7 @@
* kacalendar.h - KAlarm kcal library calendar and event categorisation
* This file is part of kalarmcal library, which provides access to KAlarm
* calendar data.
* Copyright © 2005-20
19
David Jarvie <djarvie@kde.org>
* Copyright © 2005-20
20
David Jarvie <djarvie@kde.org>
*
* This library is free software; you can redistribute it and/or modify
* it under the terms of the GNU Library General Public License as published
...
...
@@ -33,6 +33,7 @@
#include
<QByteArray>
#include
<QStringList>
#include
<QDebug>
namespace
KCalendarCore
{
...
...
@@ -149,6 +150,8 @@ Q_DECLARE_OPERATORS_FOR_FLAGS(CalEvent::Types)
}
// namespace KAlarmCal
KALARMCAL_EXPORT
QDebug
operator
<<
(
QDebug
,
KAlarmCal
::
CalEvent
::
Type
);
#endif // KALARM_KACALENDAR_H
// vim: et sw=4:
Write
Preview
Supports
Markdown
0%
Try again
or
attach a new 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