Commit Graph

16 Commits

Author SHA1 Message Date
Christophe Giboudeaux
1587ead53e Fix typos found by codespell
GIT_SILENT
2021-07-14 11:01:00 +02:00
Ahmad Samir
c0274df69a Run clang-format on all cpp/h files
NO_CHANGELOG
2021-03-13 17:35:34 +00:00
Albert Astals Cid
ec41734969 Remove ifdefs, we require Qt 5.14 now 2020-12-18 21:46:01 +01:00
Andreas Cord-Landwehr
d10afb5d2a plasma-framework: Convert copyright statements to SPDX expressions 2020-08-13 19:08:54 +00:00
Friedrich W. H. Kossebau
396c643154 Port away from deprecated qmlRegisterType
GIT_SILENT
2020-06-26 15:48:28 +02:00
Shubham Jangra
1bba82535c Fix unused parameter warning 2018-12-11 23:47:39 +05:30
Kevin Funk
421e1c0126 ASAN: Fix memory leak in CalendarPlugin
Trace:
Indirect leak of 24 byte(s) in 1 object(s) allocated from:
    #0 0x508a17 in __interceptor_malloc (/home/kfunk/devel/install/kf5/bin/plasmashell+0x508a17)
    #1 0x7fcf92aa6230 in QHashData::allocateNode(int) /home/kfunk/devel/src/qt5.11/qtbase/src/corelib/tools/qhash.cpp:479:79
    #2 0x7fcf7a851d10 in QHash<int, QByteArray>::detach() /home/kfunk/devel/build/qt5.11/qtbase/include/QtCore/../../../../../src/qt5.11/qtbase/src/corelib/tools/qhash.h:275:51
    #3 0x7fcf7a8519c9 in QHash<int, QByteArray>::insert(int const&, QByteArray const&) /home/kfunk/devel/build/qt5.11/qtbase/include/QtCore/../../../../../src/qt5.11/qtbase/src/corelib/tools/qhash.h:769:5
    #4 0x7fcf7a859736 in EventPluginsModel::EventPluginsModel(EventPluginsManager*) /home/kfunk/devel/src/kf5/plasma-framework/src/declarativeimports/calendar/eventpluginsmanager.cpp:42:17
    #5 0x7fcf7a854c55 in EventPluginsManager::EventPluginsManager(QObject*) /home/kfunk/devel/src/kf5/plasma-framework/src/declarativeimports/calendar/eventpluginsmanager.cpp:185:19
    ...

Subscribers: kde-frameworks-devel

Tags: #frameworks

Differential Revision: https://phabricator.kde.org/D17031
2018-11-20 15:15:59 +01:00
Aleix Pol
b8b8a69fd1 Remove implicit string casting
Summary: Follow the KF5 guidelines

Test Plan: Plasma shell starts

Reviewers: #plasma, #frameworks, sebas

Reviewed By: #plasma, sebas

Subscribers: plasma-devel

Tags: #plasma, #frameworks

Differential Revision: https://phabricator.kde.org/D9108
2017-12-02 15:44:14 +01:00
Martin Klapetek
b65195ee65 [calendar] qmlRegisterUncreatableType needs a bit more arguments 2015-11-16 11:52:17 -05:00
Martin Klapetek
d0d0a27bac [calendar] Move the plugins handling to a separate class
This is also made a QML singleton that will be used for the applet
config view where it will add the plugin configs once we add that
possibility.

The same instance is then set to the DaysModel from QML.

REVIEW: 125951
2015-11-16 11:49:02 -05:00
Martin Klapetek
fe0384f0d4 [calendar] Add plugin system for Calendar events
This adds a simple plugin interface that can be subclassed
and provide events integration with Plasma Calendar applet.

It's asynchronous and I've kept it deliberately simple.
For now the Calendar tells the plugins which date range
is being displayed, the plugins load the data and then
emit the dataReady() signal containing the events.

The events are stored in a multihash for quick access
by the Calendar's agenda part but also for overall
easy-to-use (eg. in teh model data()).

The event data is stored in EventData class, which has
a pretty self-explanatory members, except perhaps the
"isMinor" property. The intention with this is to support
namedays, where in some countries the calendars have
different name every day. This is just a minor holiday
and as such should not mark the calendar grid, otherwise
the whole grid would be in a different color.

Putting the interface here might raise the question of
depending on plasma-framework, but plugins provided by
KDE can go to plasma-workspace and other 3rd party ones
would just have to live with it. I don't think it will
be a problem but if it turns out it is, we can rethink
the placement.

REVIEW: 125817
CCBUG: 349676
CHANGELOG: Allow plugins to supply event data to Calendar applet
2015-11-16 11:46:26 -05:00
Martin Klapetek
404ed07fb0 Revert "Raise the QML imports version to 2.1"
This reverts commit fa2109ccb6.

Turns out the plan to raise the version with every framework
release is not as simple as raising the version numbers as
this breaks pretty much everything.
2015-02-24 15:31:41 +01:00
Martin Klapetek
fa2109ccb6 Raise the QML imports version to 2.1
Change-Id: Ia753bbc7a55a256486f2d0f225571b9046f03cda
REVIEW: 122696
2015-02-24 13:06:48 +01:00
Kevin Ottens
72ba7b4146 Apply the astyle-kdelibs script 2014-04-26 01:48:37 +02:00
Mark Gaiser
d56f690fcf Add license to calendar component classes. 2013-11-13 13:41:41 +01:00
Marco Martin
e8a4332034 re-add the calendar qml component
CCMAIL:heena393@gmail.com
2013-08-31 15:23:04 +02:00