3 files changed, 8 insertions, 3 deletions
diff --git a/noncore/todayplugins/fortune/fortunepluginimpl.cpp b/noncore/todayplugins/fortune/fortunepluginimpl.cpp index 466e322..090aaa7 100644 --- a/noncore/todayplugins/fortune/fortunepluginimpl.cpp +++ b/noncore/todayplugins/fortune/fortunepluginimpl.cpp | |||
@@ -17,33 +17,35 @@ | |||
17 | #include "fortuneplugin.h" | 17 | #include "fortuneplugin.h" |
18 | #include "fortunepluginimpl.h" | 18 | #include "fortunepluginimpl.h" |
19 | 19 | ||
20 | FortunePluginImpl::FortunePluginImpl() | 20 | FortunePluginImpl::FortunePluginImpl() |
21 | { | 21 | { |
22 | fortunePlugin = new FortunePlugin(); | 22 | fortunePlugin = new FortunePlugin(); |
23 | } | 23 | } |
24 | 24 | ||
25 | FortunePluginImpl::~FortunePluginImpl() | 25 | FortunePluginImpl::~FortunePluginImpl() |
26 | { | 26 | { |
27 | delete fortunePlugin; | 27 | delete fortunePlugin; |
28 | } | 28 | } |
29 | 29 | ||
30 | 30 | ||
31 | TodayPluginObject* FortunePluginImpl::guiPart() | 31 | TodayPluginObject* FortunePluginImpl::guiPart() |
32 | { | 32 | { |
33 | return fortunePlugin; | 33 | return fortunePlugin; |
34 | } | 34 | } |
35 | 35 | ||
36 | QRESULT FortunePluginImpl::queryInterface( const QUuid & uuid, QUnknownInterface **iface ) | 36 | QRESULT FortunePluginImpl::queryInterface( const QUuid & uuid, QUnknownInterface **iface ) |
37 | { | 37 | { |
38 | *iface = 0; | 38 | *iface = 0; |
39 | if ( ( uuid == IID_QUnknown ) || ( uuid == IID_TodayPluginInterface ) ) { | 39 | if ( ( uuid == IID_QUnknown ) || ( uuid == IID_TodayPluginInterface ) ) { |
40 | *iface = this, (*iface)->addRef(); | 40 | *iface = this, (*iface)->addRef(); |
41 | } | 41 | }else |
42 | return QS_FALSE; | ||
43 | |||
42 | return QS_OK; | 44 | return QS_OK; |
43 | 45 | ||
44 | } | 46 | } |
45 | 47 | ||
46 | Q_EXPORT_INTERFACE() | 48 | Q_EXPORT_INTERFACE() |
47 | { | 49 | { |
48 | Q_CREATE_INSTANCE( FortunePluginImpl ); | 50 | Q_CREATE_INSTANCE( FortunePluginImpl ); |
49 | } | 51 | } |
diff --git a/noncore/todayplugins/stockticker/stocktickerlib/stocktickerpluginimpl.cpp b/noncore/todayplugins/stockticker/stocktickerlib/stocktickerpluginimpl.cpp index c17781b..ec3e34d 100644 --- a/noncore/todayplugins/stockticker/stocktickerlib/stocktickerpluginimpl.cpp +++ b/noncore/todayplugins/stockticker/stocktickerlib/stocktickerpluginimpl.cpp | |||
@@ -15,32 +15,34 @@ | |||
15 | ***************************************************************************/ | 15 | ***************************************************************************/ |
16 | 16 | ||
17 | 17 | ||
18 | 18 | ||
19 | #include "stocktickerplugin.h" | 19 | #include "stocktickerplugin.h" |
20 | #include "stocktickerpluginimpl.h" | 20 | #include "stocktickerpluginimpl.h" |
21 | 21 | ||
22 | StockTickerPluginImpl::StockTickerPluginImpl() { | 22 | StockTickerPluginImpl::StockTickerPluginImpl() { |
23 | stocktickerPlugin = new StockTickerPlugin(); | 23 | stocktickerPlugin = new StockTickerPlugin(); |
24 | } | 24 | } |
25 | 25 | ||
26 | StockTickerPluginImpl::~StockTickerPluginImpl() { | 26 | StockTickerPluginImpl::~StockTickerPluginImpl() { |
27 | delete stocktickerPlugin; | 27 | delete stocktickerPlugin; |
28 | } | 28 | } |
29 | 29 | ||
30 | 30 | ||
31 | TodayPluginObject* StockTickerPluginImpl::guiPart() { | 31 | TodayPluginObject* StockTickerPluginImpl::guiPart() { |
32 | return stocktickerPlugin; | 32 | return stocktickerPlugin; |
33 | } | 33 | } |
34 | 34 | ||
35 | QRESULT StockTickerPluginImpl::queryInterface( const QUuid & uuid, QUnknownInterface **iface ) { | 35 | QRESULT StockTickerPluginImpl::queryInterface( const QUuid & uuid, QUnknownInterface **iface ) { |
36 | *iface = 0; | 36 | *iface = 0; |
37 | if ( ( uuid == IID_QUnknown ) || ( uuid == IID_TodayPluginInterface ) ) { | 37 | if ( ( uuid == IID_QUnknown ) || ( uuid == IID_TodayPluginInterface ) ) { |
38 | *iface = this, (*iface)->addRef(); | 38 | *iface = this, (*iface)->addRef(); |
39 | } | 39 | }else |
40 | return QS_FALSE; | ||
41 | |||
40 | return QS_OK; | 42 | return QS_OK; |
41 | 43 | ||
42 | } | 44 | } |
43 | 45 | ||
44 | Q_EXPORT_INTERFACE() { | 46 | Q_EXPORT_INTERFACE() { |
45 | Q_CREATE_INSTANCE( StockTickerPluginImpl ); | 47 | Q_CREATE_INSTANCE( StockTickerPluginImpl ); |
46 | } | 48 | } |
diff --git a/noncore/todayplugins/weather/weatherpluginimpl.cpp b/noncore/todayplugins/weather/weatherpluginimpl.cpp index 1a7c27b..fd32a44 100644 --- a/noncore/todayplugins/weather/weatherpluginimpl.cpp +++ b/noncore/todayplugins/weather/weatherpluginimpl.cpp | |||
@@ -30,33 +30,34 @@ | |||
30 | #include "weatherpluginimpl.h" | 30 | #include "weatherpluginimpl.h" |
31 | 31 | ||
32 | WeatherPluginImpl::WeatherPluginImpl() | 32 | WeatherPluginImpl::WeatherPluginImpl() |
33 | { | 33 | { |
34 | weatherPlugin = new WeatherPlugin(); | 34 | weatherPlugin = new WeatherPlugin(); |
35 | } | 35 | } |
36 | 36 | ||
37 | WeatherPluginImpl::~WeatherPluginImpl() | 37 | WeatherPluginImpl::~WeatherPluginImpl() |
38 | { | 38 | { |
39 | delete weatherPlugin; | 39 | delete weatherPlugin; |
40 | } | 40 | } |
41 | 41 | ||
42 | 42 | ||
43 | TodayPluginObject* WeatherPluginImpl::guiPart() | 43 | TodayPluginObject* WeatherPluginImpl::guiPart() |
44 | { | 44 | { |
45 | return weatherPlugin; | 45 | return weatherPlugin; |
46 | } | 46 | } |
47 | 47 | ||
48 | QRESULT WeatherPluginImpl::queryInterface( const QUuid &uuid, QUnknownInterface **iface ) | 48 | QRESULT WeatherPluginImpl::queryInterface( const QUuid &uuid, QUnknownInterface **iface ) |
49 | { | 49 | { |
50 | *iface = 0; | 50 | *iface = 0; |
51 | if ( ( uuid == IID_QUnknown ) || ( uuid == IID_TodayPluginInterface ) ) | 51 | if ( ( uuid == IID_QUnknown ) || ( uuid == IID_TodayPluginInterface ) ) |
52 | { | 52 | { |
53 | *iface = this, (*iface)->addRef(); | 53 | *iface = this, (*iface)->addRef(); |
54 | } | 54 | }else |
55 | return QS_FALSE; | ||
55 | 56 | ||
56 | return QS_OK; | 57 | return QS_OK; |
57 | } | 58 | } |
58 | 59 | ||
59 | Q_EXPORT_INTERFACE() | 60 | Q_EXPORT_INTERFACE() |
60 | { | 61 | { |
61 | Q_CREATE_INSTANCE( WeatherPluginImpl ); | 62 | Q_CREATE_INSTANCE( WeatherPluginImpl ); |
62 | } | 63 | } |