author | harlekin <harlekin> | 2003-02-10 21:28:14 (UTC) |
---|---|---|
committer | harlekin <harlekin> | 2003-02-10 21:28:14 (UTC) |
commit | bbb3cdf8f91d567f6c2e786bd144b64bd679ff9a (patch) (side-by-side diff) | |
tree | 9c622e670cab66c44d9bd079707945cf3c9bcb89 /core/pim/today/plugins/todolist/todoplugin.cpp | |
parent | de272b8c47c3960a3fe574317fe2e6fb0c32e4af (diff) | |
download | opie-bbb3cdf8f91d567f6c2e786bd144b64bd679ff9a.zip opie-bbb3cdf8f91d567f6c2e786bd144b64bd679ff9a.tar.gz opie-bbb3cdf8f91d567f6c2e786bd144b64bd679ff9a.tar.bz2 |
adapted to new refresh, datebookplugin still need some work
Diffstat (limited to 'core/pim/today/plugins/todolist/todoplugin.cpp') (more/less context) (show whitespace changes)
-rw-r--r-- | core/pim/today/plugins/todolist/todoplugin.cpp | 16 |
1 files changed, 13 insertions, 3 deletions
diff --git a/core/pim/today/plugins/todolist/todoplugin.cpp b/core/pim/today/plugins/todolist/todoplugin.cpp index b5abbd3..1238f92 100644 --- a/core/pim/today/plugins/todolist/todoplugin.cpp +++ b/core/pim/today/plugins/todolist/todoplugin.cpp @@ -15,35 +15,39 @@ ***************************************************************************/ #include "todoplugin.h" #include "todopluginconfig.h" -#include "todopluginwidget.h" TodolistPlugin::TodolistPlugin() { + m_widget = 0l; } TodolistPlugin::~TodolistPlugin() { + delete m_widget; } QString TodolistPlugin::pluginName() const { return QObject::tr( "Todolist plugin" ); } double TodolistPlugin::versionNumber() const { - return 0.8; + return 0.9; } QString TodolistPlugin::pixmapNameWidget() const { return "TodoList"; } QWidget* TodolistPlugin::widget( QWidget *wid ) { - return new TodolistPluginWidget( wid, "Todolist" ); + if(!m_widget) { + m_widget = new TodolistPluginWidget( wid, "Todolist" ); + } + return m_widget; } QString TodolistPlugin::pixmapNameConfig() const { return "TodoList"; } @@ -56,6 +60,12 @@ QString TodolistPlugin::appName() const { } bool TodolistPlugin::excludeFromRefresh() const { return false; } + +void TodolistPlugin::refresh() { + if ( m_widget ) { + m_widget->refresh(); + } +} |