Application: kdevelop (4.0.0 (using KDevPlatform 1.0.0)) KDE Platform Version: 4.4.2 (KDE 4.4.2) Qt Version: 4.6.2 Operating System: Linux 2.6.32-21-generic x86_64 Distribution: Ubuntu 10.04 LTS -- Information about the crash: I can reproduce this error as follow: 1-Open kdevelop with qthelp documentation selected. 2-Go to settings->Configure Kdevelop 3-In Complements sections unmark qt documentation. Some times the program crash as this point.If you can't see any crash then 4-Click on the combobox to select cmake documentation or qthelp documentation The crash can be reproduced every time. -- Backtrace: Application: KDevelop (kdevelop.bin), signal: Aborted [Current thread is 1 (Thread 0x7f3e073cb760 (LWP 7607))] Thread 11 (Thread 0x7f3df3017710 (LWP 7608)): #0 pthread_cond_timedwait@@GLIBC_2.3.2 () at ../nptl/sysdeps/unix/sysv/linux/x86_64/pthread_cond_timedwait.S:211 #1 0x00007f3e05b71692 in QWaitConditionPrivate::wait (this=<value optimized out>, mutex=0x1ea7780, time=200000) at thread/qwaitcondition_unix.cpp:85 #2 QWaitCondition::wait (this=<value optimized out>, mutex=0x1ea7780, time=200000) at thread/qwaitcondition_unix.cpp:159 #3 0x00007f3e015f906e in KDevelop::DUChainPrivate::CleanupThread::run (this=0x1ea7760) at ../../language/duchain/duchain.cpp:286 #4 0x00007f3e05b70775 in QThreadPrivate::start (arg=0x1ea7760) at thread/qthread_unix.cpp:248 #5 0x00007f3e045b39ca in start_thread (arg=<value optimized out>) at pthread_create.c:300 #6 0x00007f3e048b069d in clone () at ../sysdeps/unix/sysv/linux/x86_64/clone.S:112 #7 0x0000000000000000 in ?? () Thread 10 (Thread 0x7f3de8ca3710 (LWP 7609)): #0 pthread_cond_wait@@GLIBC_2.3.2 () at ../nptl/sysdeps/unix/sysv/linux/x86_64/pthread_cond_wait.S:162 #1 0x00007f3e05b7172b in QWaitConditionPrivate::wait (this=<value optimized out>, mutex=0x1cd2620, time=18446744073709551615) at thread/qwaitcondition_unix.cpp:87 #2 QWaitCondition::wait (this=<value optimized out>, mutex=0x1cd2620, time=18446744073709551615) at thread/qwaitcondition_unix.cpp:159 #3 0x00007f3dfca31026 in ThreadWeaver::WeaverImpl::blockThreadUntilJobsAreBeingAssigned (this=0x276bfd0, th=0x1cd1ca0) at ../../../threadweaver/Weaver/WeaverImpl.cpp:365 #4 0x00007f3dfca336ab in ThreadWeaver::WorkingHardState::applyForWork (this=0x1c1e7b0, th=0x1cd1ca0) at ../../../threadweaver/Weaver/WorkingHardState.cpp:71 #5 0x00007f3dfca31bff in ThreadWeaver::ThreadRunHelper::run (this=0x7f3de8ca2e00, parent=0x276bfd0, th=0x1cd1ca0) at ../../../threadweaver/Weaver/Thread.cpp:87 #6 0x00007f3dfca32168 in ThreadWeaver::Thread::run (this=0x1cd1ca0) at ../../../threadweaver/Weaver/Thread.cpp:142 #7 0x00007f3e05b70775 in QThreadPrivate::start (arg=0x1cd1ca0) at thread/qthread_unix.cpp:248 #8 0x00007f3e045b39ca in start_thread (arg=<value optimized out>) at pthread_create.c:300 #9 0x00007f3e048b069d in clone () at ../sysdeps/unix/sysv/linux/x86_64/clone.S:112 #10 0x0000000000000000 in ?? () Thread 9 (Thread 0x7f3de2821710 (LWP 7633)): #0 QTimerInfoList::updateCurrentTime (this=0x28c8970) at kernel/qeventdispatcher_unix.cpp:339 #1 0x00007f3e05c906d5 in QTimerInfoList::timerWait (this=0x28c8970, tm=...) at kernel/qeventdispatcher_unix.cpp:443 #2 0x00007f3e05c8e75d in timerSourcePrepareHelper (src=<value optimized out>, timeout=0x7f3de2820c5c) at kernel/qeventdispatcher_glib.cpp:136 #3 0x00007f3e05c8e805 in timerSourcePrepare (source=0x28c8970, timeout=0x7f3de2820bf0) at kernel/qeventdispatcher_glib.cpp:169 #4 0x00007f3dfef94eb1 in g_main_context_prepare () from /lib/libglib-2.0.so.0 #5 0x00007f3dfef95318 in ?? () from /lib/libglib-2.0.so.0 #6 0x00007f3dfef958fc in g_main_context_iteration () from /lib/libglib-2.0.so.0 #7 0x00007f3e05c8e566 in QEventDispatcherGlib::processEvents (this=0x28ce820, flags=<value optimized out>) at kernel/qeventdispatcher_glib.cpp:414 #8 0x00007f3e05c63992 in QEventLoop::processEvents (this=<value optimized out>, flags=) at kernel/qeventloop.cpp:149 #9 0x00007f3e05c63d6c in QEventLoop::exec (this=0x7f3de2820df0, flags=) at kernel/qeventloop.cpp:201 #10 0x00007f3e05b6dd59 in QThread::exec (this=<value optimized out>) at thread/qthread.cpp:487 #11 0x00007f3e05b70775 in QThreadPrivate::start (arg=0x28b2bf0) at thread/qthread_unix.cpp:248 #12 0x00007f3e045b39ca in start_thread (arg=<value optimized out>) at pthread_create.c:300 #13 0x00007f3e048b069d in clone () at ../sysdeps/unix/sysv/linux/x86_64/clone.S:112 #14 0x0000000000000000 in ?? () Thread 8 (Thread 0x7f3ddc987710 (LWP 7658)): #0 0x00007f3e048a3f53 in *__GI___poll (fds=<value optimized out>, nfds=<value optimized out>, timeout=-1) at ../sysdeps/unix/sysv/linux/poll.c:87 #1 0x00007f3dfef954a9 in ?? () from /lib/libglib-2.0.so.0 #2 0x00007f3dfef958fc in g_main_context_iteration () from /lib/libglib-2.0.so.0 #3 0x00007f3e05c8e566 in QEventDispatcherGlib::processEvents (this=0x2f1ba40, flags=<value optimized out>) at kernel/qeventdispatcher_glib.cpp:414 #4 0x00007f3e05c63992 in QEventLoop::processEvents (this=<value optimized out>, flags=) at kernel/qeventloop.cpp:149 #5 0x00007f3e05c63d6c in QEventLoop::exec (this=0x7f3ddc986db0, flags=) at kernel/qeventloop.cpp:201 #6 0x00007f3e05b6dd59 in QThread::exec (this=<value optimized out>) at thread/qthread.cpp:487 #7 0x00007f3e05c44178 in QInotifyFileSystemWatcherEngine::run (this=0x2889800) at io/qfilesystemwatcher_inotify.cpp:248 #8 0x00007f3e05b70775 in QThreadPrivate::start (arg=0x2889800) at thread/qthread_unix.cpp:248 #9 0x00007f3e045b39ca in start_thread (arg=<value optimized out>) at pthread_create.c:300 #10 0x00007f3e048b069d in clone () at ../sysdeps/unix/sysv/linux/x86_64/clone.S:112 #11 0x0000000000000000 in ?? () Thread 7 (Thread 0x7f3de2020710 (LWP 7706)): #0 pthread_cond_wait@@GLIBC_2.3.2 () at ../nptl/sysdeps/unix/sysv/linux/x86_64/pthread_cond_wait.S:162 #1 0x00007f3dfdcfa2a6 in QTWTF::TCMalloc_PageHeap::scavengerThread (this=0x7f3dfdfd8220) at ../3rdparty/javascriptcore/JavaScriptCore/wtf/FastMalloc.cpp:2304 #2 0x00007f3dfdcfa2e9 in QTWTF::TCMalloc_PageHeap::runScavengerThread (context=0x7f3dfdfe62ec) at ../3rdparty/javascriptcore/JavaScriptCore/wtf/FastMalloc.cpp:1438 #3 0x00007f3e045b39ca in start_thread (arg=<value optimized out>) at pthread_create.c:300 #4 0x00007f3e048b069d in clone () at ../sysdeps/unix/sysv/linux/x86_64/clone.S:112 #5 0x0000000000000000 in ?? () Thread 6 (Thread 0x7f3ddacf0710 (LWP 7724)): #0 0x00007f3e048a3f53 in *__GI___poll (fds=<value optimized out>, nfds=<value optimized out>, timeout=-1) at ../sysdeps/unix/sysv/linux/poll.c:87 #1 0x00007f3dfef954a9 in ?? () from /lib/libglib-2.0.so.0 #2 0x00007f3dfef958fc in g_main_context_iteration () from /lib/libglib-2.0.so.0 #3 0x00007f3e05c8e566 in QEventDispatcherGlib::processEvents (this=0x3a078d0, flags=<value optimized out>) at kernel/qeventdispatcher_glib.cpp:414 #4 0x00007f3e05c63992 in QEventLoop::processEvents (this=<value optimized out>, flags=) at kernel/qeventloop.cpp:149 #5 0x00007f3e05c63d6c in QEventLoop::exec (this=0x7f3ddacefdf0, flags=) at kernel/qeventloop.cpp:201 #6 0x00007f3e05b6dd59 in QThread::exec (this=<value optimized out>) at thread/qthread.cpp:487 #7 0x00007f3e05b70775 in QThreadPrivate::start (arg=0x7f3dec1a3090) at thread/qthread_unix.cpp:248 #8 0x00007f3e045b39ca in start_thread (arg=<value optimized out>) at pthread_create.c:300 #9 0x00007f3e048b069d in clone () at ../sysdeps/unix/sysv/linux/x86_64/clone.S:112 #10 0x0000000000000000 in ?? () Thread 5 (Thread 0x7f3dda4ef710 (LWP 7725)): #0 0x00007f3e048a3f53 in *__GI___poll (fds=<value optimized out>, nfds=<value optimized out>, timeout=-1) at ../sysdeps/unix/sysv/linux/poll.c:87 #1 0x00007f3dfef954a9 in ?? () from /lib/libglib-2.0.so.0 #2 0x00007f3dfef958fc in g_main_context_iteration () from /lib/libglib-2.0.so.0 #3 0x00007f3e05c8e566 in QEventDispatcherGlib::processEvents (this=0x2f069c0, flags=<value optimized out>) at kernel/qeventdispatcher_glib.cpp:414 #4 0x00007f3e05c63992 in QEventLoop::processEvents (this=<value optimized out>, flags=) at kernel/qeventloop.cpp:149 #5 0x00007f3e05c63d6c in QEventLoop::exec (this=0x7f3dda4eedf0, flags=) at kernel/qeventloop.cpp:201 #6 0x00007f3e05b6dd59 in QThread::exec (this=<value optimized out>) at thread/qthread.cpp:487 #7 0x00007f3e05b70775 in QThreadPrivate::start (arg=0x7f3dec0cc690) at thread/qthread_unix.cpp:248 #8 0x00007f3e045b39ca in start_thread (arg=<value optimized out>) at pthread_create.c:300 #9 0x00007f3e048b069d in clone () at ../sysdeps/unix/sysv/linux/x86_64/clone.S:112 #10 0x0000000000000000 in ?? () Thread 4 (Thread 0x7f3dd9cee710 (LWP 7726)): #0 pthread_cond_timedwait@@GLIBC_2.3.2 () at ../nptl/sysdeps/unix/sysv/linux/x86_64/pthread_cond_timedwait.S:211 #1 0x00007f3e05b700e5 in thread_sleep (ti=0x7f3dd9ceddb0) at thread/qthread_unix.cpp:398 #2 0x00007f3e05b70250 in QThread::msleep (msecs=<value optimized out>) at thread/qthread_unix.cpp:424 #3 0x00007f3ddb575f41 in ?? () from /usr/lib/kde4/kdevcpplanguagesupport.so #4 0x00007f3e05b70775 in QThreadPrivate::start (arg=0x7f3dec058ea0) at thread/qthread_unix.cpp:248 #5 0x00007f3e045b39ca in start_thread (arg=<value optimized out>) at pthread_create.c:300 #6 0x00007f3e048b069d in clone () at ../sysdeps/unix/sysv/linux/x86_64/clone.S:112 #7 0x0000000000000000 in ?? () Thread 3 (Thread 0x7f3dd854e710 (LWP 7733)): #0 pthread_cond_wait@@GLIBC_2.3.2 () at ../nptl/sysdeps/unix/sysv/linux/x86_64/pthread_cond_wait.S:162 #1 0x00007f3e05b7172b in QWaitConditionPrivate::wait (this=<value optimized out>, mutex=0x1dd8dc0, time=18446744073709551615) at thread/qwaitcondition_unix.cpp:87 #2 QWaitCondition::wait (this=<value optimized out>, mutex=0x1dd8dc0, time=18446744073709551615) at thread/qwaitcondition_unix.cpp:159 #3 0x00007f3dfca31026 in ThreadWeaver::WeaverImpl::blockThreadUntilJobsAreBeingAssigned (this=0x1dd7330, th=0x43e4f90) at ../../../threadweaver/Weaver/WeaverImpl.cpp:365 #4 0x00007f3dfca336ab in ThreadWeaver::WorkingHardState::applyForWork (this=0x1dd3750, th=0x43e4f90) at ../../../threadweaver/Weaver/WorkingHardState.cpp:71 #5 0x00007f3dfca336c4 in ThreadWeaver::WorkingHardState::applyForWork (this=0x1dd3750, th=0x43e4f90) at ../../../threadweaver/Weaver/WorkingHardState.cpp:74 #6 0x00007f3dfca31bff in ThreadWeaver::ThreadRunHelper::run (this=0x7f3dd854de00, parent=0x1dd7330, th=0x43e4f90) at ../../../threadweaver/Weaver/Thread.cpp:87 #7 0x00007f3dfca32168 in ThreadWeaver::Thread::run (this=0x43e4f90) at ../../../threadweaver/Weaver/Thread.cpp:142 #8 0x00007f3e05b70775 in QThreadPrivate::start (arg=0x43e4f90) at thread/qthread_unix.cpp:248 #9 0x00007f3e045b39ca in start_thread (arg=<value optimized out>) at pthread_create.c:300 #10 0x00007f3e048b069d in clone () at ../sysdeps/unix/sysv/linux/x86_64/clone.S:112 #11 0x0000000000000000 in ?? () Thread 2 (Thread 0x7f3dd7d4d710 (LWP 7734)): #0 pthread_cond_wait@@GLIBC_2.3.2 () at ../nptl/sysdeps/unix/sysv/linux/x86_64/pthread_cond_wait.S:162 #1 0x00007f3e05b7172b in QWaitConditionPrivate::wait (this=<value optimized out>, mutex=0x1dd8dc0, time=18446744073709551615) at thread/qwaitcondition_unix.cpp:87 #2 QWaitCondition::wait (this=<value optimized out>, mutex=0x1dd8dc0, time=18446744073709551615) at thread/qwaitcondition_unix.cpp:159 #3 0x00007f3dfca31026 in ThreadWeaver::WeaverImpl::blockThreadUntilJobsAreBeingAssigned (this=0x1dd7330, th=0x2f1d340) at ../../../threadweaver/Weaver/WeaverImpl.cpp:365 #4 0x00007f3dfca336ab in ThreadWeaver::WorkingHardState::applyForWork (this=0x1dd3750, th=0x2f1d340) at ../../../threadweaver/Weaver/WorkingHardState.cpp:71 #5 0x00007f3dfca31bff in ThreadWeaver::ThreadRunHelper::run (this=0x7f3dd7d4ce00, parent=0x1dd7330, th=0x2f1d340) at ../../../threadweaver/Weaver/Thread.cpp:87 #6 0x00007f3dfca32168 in ThreadWeaver::Thread::run (this=0x2f1d340) at ../../../threadweaver/Weaver/Thread.cpp:142 #7 0x00007f3e05b70775 in QThreadPrivate::start (arg=0x2f1d340) at thread/qthread_unix.cpp:248 #8 0x00007f3e045b39ca in start_thread (arg=<value optimized out>) at pthread_create.c:300 #9 0x00007f3e048b069d in clone () at ../sysdeps/unix/sysv/linux/x86_64/clone.S:112 #10 0x0000000000000000 in ?? () Thread 1 (Thread 0x7f3e073cb760 (LWP 7607)): [KCrash Handler] #5 0x00007f3e047fda75 in *__GI_raise (sig=<value optimized out>) at ../nptl/sysdeps/unix/sysv/linux/raise.c:64 #6 0x00007f3e048015c0 in *__GI_abort () at abort.c:92 #7 0x00007f3e04c188e5 in __gnu_cxx::__verbose_terminate_handler() () from /usr/lib/libstdc++.so.6 #8 0x00007f3e04c16d16 in ?? () from /usr/lib/libstdc++.so.6 #9 0x00007f3e04c16d43 in std::terminate() () from /usr/lib/libstdc++.so.6 #10 0x00007f3e04c1761f in __cxa_pure_virtual () from /usr/lib/libstdc++.so.6 #11 0x00007f3e068c6828 in ProvidersModel::data (this=<value optimized out>, index=<value optimized out>, role=<value optimized out>) at ../../shell/documentationview.cpp:51 #12 0x00007f3e053eb1ec in QComboBoxPrivate::itemText (this=0x39eaf80, index=...) at widgets/qcombobox.cpp:1241 #13 0x00007f3e053eb386 in QComboBox::currentText (this=<value optimized out>) at widgets/qcombobox.cpp:2009 #14 0x00007f3e053ebe76 in QComboBox::initStyleOption (this=0x39eae80, option=0x7fffcda6a7b0) at widgets/qcombobox.cpp:1090 #15 0x00007f3e053ed4db in QComboBoxPrivate::newHoverControl (this=0x39eaf80, pos=...) at widgets/qcombobox.cpp:240 #16 0x00007f3e053ed680 in QComboBoxPrivate::updateHoverControl (this=0x39eaf80, pos=...) at widgets/qcombobox.cpp:228 #17 0x00007f3e053eed8c in QComboBox::event (this=0x39eae80, event=0x7fffcda6a920) at widgets/qcombobox.cpp:2725 #18 0x00007f3e0501e22c in QApplicationPrivate::notify_helper (this=0x1ae2680, receiver=0x39eae80, e=0x7fffcda6a920) at kernel/qapplication.cpp:4300 #19 0x00007f3e05023a17 in QApplicationPrivate::dispatchEnterLeave (enter=<value optimized out>, leave=<value optimized out>) at kernel/qapplication.cpp:2633 #20 0x00007f3e0502406e in QApplicationPrivate::sendMouseEvent (receiver=0x39eae80, event=0x7fffcda6aba0, alienWidget=0x39eae80, nativeWidget=0x43898e0, buttonDown=<value optimized out>, lastMouseReceiver=<value optimized out>, spontaneous=true) at kernel/qapplication.cpp:2945 #21 0x00007f3e050a3f65 in QETWidget::translateMouseEvent (this=0x43898e0, event=<value optimized out>) at kernel/qapplication_x11.cpp:4368 #22 0x00007f3e050a28ac in QApplication::x11ProcessEvent (this=<value optimized out>, event=0x7fffcda6b4c0) at kernel/qapplication_x11.cpp:3501 #23 0x00007f3e050ce882 in x11EventSourceDispatch (s=0x1ae6450, callback=<value optimized out>, user_data=<value optimized out>) at kernel/qguieventdispatcher_glib.cpp:146 #24 0x00007f3dfef918c2 in g_main_context_dispatch () from /lib/libglib-2.0.so.0 #25 0x00007f3dfef95748 in ?? () from /lib/libglib-2.0.so.0 #26 0x00007f3dfef958fc in g_main_context_iteration () from /lib/libglib-2.0.so.0 #27 0x00007f3e05c8e513 in QEventDispatcherGlib::processEvents (this=0x128cf50, flags=<value optimized out>) at kernel/qeventdispatcher_glib.cpp:412 #28 0x00007f3e050ce46e in QGuiEventDispatcherGlib::processEvents (this=0x1db7, flags=<value optimized out>) at kernel/qguieventdispatcher_glib.cpp:204 #29 0x00007f3e05c63992 in QEventLoop::processEvents (this=<value optimized out>, flags=) at kernel/qeventloop.cpp:149 #30 0x00007f3e05c63d6c in QEventLoop::exec (this=0x7fffcda6b7f0, flags=) at kernel/qeventloop.cpp:201 #31 0x00007f3e05c67aab in QCoreApplication::exec () at kernel/qcoreapplication.cpp:981 #32 0x00000000004088cf in _start () Reported using DrKonqi
Can reproduce here, "Complements" is apparently a not-quite-correct translation of Plugins. Apparently the documentationcontroller (or some of its parts) keep references to the documentation plugins, but don't hook into the plugin loading/unloading notifications. And hence they crash trying to access an already deleted plugin pointer.
*** Bug 241592 has been marked as a duplicate of this bug. ***
*** Bug 247406 has been marked as a duplicate of this bug. ***
*** Bug 247476 has been marked as a duplicate of this bug. ***
commit 44351dcd6d70a7c0f6d0d34714b2178435f559f3 Author: Aleix Pol <aleixpol@kde.org> Date: Thu Aug 12 23:20:06 2010 +0200 Make the Documentation view aware of documentation plugins being hot-(un)pluged instead of crashing. BUG: 236037 diff --git a/shell/documentationview.cpp b/shell/documentationview.cpp index 71486f3..ff7acb3 100644 --- a/shell/documentationview.cpp +++ b/shell/documentationview.cpp @@ -24,6 +24,7 @@ #include <QTextEdit> #include <QCompleter> #include <QLayout> +#include <QTextBrowser> #include <KLineEdit> #include <KDebug> #include <KIcon> @@ -31,53 +32,9 @@ #include <interfaces/icore.h> #include <interfaces/idocumentationprovider.h> #include <interfaces/idocumentationcontroller.h> -#include <QTextBrowser> +#include <interfaces/iplugincontroller.h> -class ProvidersModel : public QAbstractListModel -{ - public: - - ProvidersModel(QObject* parent = 0) - : QAbstractListModel(parent) - , mProviders(KDevelop::ICore::self()->documentationController()->documentationProviders()) - {} - - virtual QVariant data(const QModelIndex& index, int role = Qt::DisplayRole) const - { - QVariant ret; - switch(role) - { - case Qt::DisplayRole: - ret=provider(index.row())->name(); - break; - case Qt::DecorationRole: - ret=provider(index.row())->icon(); - break; - } - return ret; - } - - virtual int rowCount(const QModelIndex&) const - { - return mProviders.count(); - } - - QList<KDevelop::IDocumentationProvider*> providers() { - return mProviders; - } - - KDevelop::IDocumentationProvider* provider(int pos) const - { - return mProviders[pos]; - } - - int rowForProvider(KDevelop::IDocumentationProvider* provider) - { - return mProviders.indexOf(provider); - } - private: - QList<KDevelop::IDocumentationProvider*> mProviders; -}; +using namespace KDevelop; DocumentationView::DocumentationView(QWidget* parent) : QWidget(parent) @@ -217,3 +174,62 @@ void DocumentationView::changedProvider(int row) showHome(); } + +////////////// ProvidersModel ////////////////// + +ProvidersModel::ProvidersModel(QObject* parent) + : QAbstractListModel(parent) + , mProviders(ICore::self()->documentationController()->documentationProviders()) +{ + connect(ICore::self()->pluginController(), SIGNAL(pluginUnloaded(KDevelop::IPlugin*)), SLOT(unloaded(KDevelop::IPlugin*))); + connect(ICore::self()->pluginController(), SIGNAL(pluginLoaded(KDevelop::IPlugin*)), SLOT(loaded(KDevelop::IPlugin*))); +} + +QVariant ProvidersModel::data(const QModelIndex& index, int role) const +{ + qDebug() << "peppepepepe" << index; + QVariant ret; + switch (role) + { + case Qt::DisplayRole: + ret=provider(index.row())->name(); + break; + case Qt::DecorationRole: + ret=provider(index.row())->icon(); + break; + } + return ret; +} + +void ProvidersModel::unloaded(KDevelop::IPlugin* p) +{ + IDocumentationProvider* prov=p->extension<IDocumentationProvider>(); + int idx=-1; + if (prov) + idx = mProviders.indexOf(prov); + + qDebug() << "---------unloaded" << ICore::self()->pluginController()->pluginInfo(p).name() << idx << prov << p->extensions(); + if (idx>=0) { + beginRemoveRows(QModelIndex(), idx, idx); + mProviders.removeAt(idx); + endRemoveRows(); + } +} + +void ProvidersModel::loaded(IPlugin* p) +{ + IDocumentationProvider* prov=p->extension<IDocumentationProvider>(); + + qDebug() << "++++++++++loaded" << ICore::self()->pluginController()->pluginInfo(p).name() << prov; + if (prov && !mProviders.contains(prov)) { + beginInsertRows(QModelIndex(), 0, 0); + mProviders.append(prov); + endInsertRows(); + } +} + +int ProvidersModel::rowForProvider(IDocumentationProvider* provider) { return mProviders.indexOf(provider); } +IDocumentationProvider* ProvidersModel::provider(int pos) const { return mProviders[pos]; } +QList< IDocumentationProvider* > ProvidersModel::providers() { return mProviders; } +int ProvidersModel::rowCount(const QModelIndex&) const { return mProviders.count(); } + diff --git a/shell/documentationview.h b/shell/documentationview.h index fe46506..d25e6ab 100644 --- a/shell/documentationview.h +++ b/shell/documentationview.h @@ -20,9 +20,12 @@ #define DOCUMENTATIONVIEW_H #include <QWidget> +#include <QAbstractListModel> #include <KToolBar> #include <interfaces/idocumentation.h> +namespace KDevelop { class IPlugin; } + class QModelIndex; class KLineEdit; class ProvidersModel; @@ -59,4 +62,25 @@ class DocumentationView : public QWidget ProvidersModel* mProvidersModel; }; +class ProvidersModel : public QAbstractListModel +{ + Q_OBJECT + public: + + ProvidersModel(QObject* parent = 0); + + virtual QVariant data(const QModelIndex& index, int role = Qt::DisplayRole) const; + virtual int rowCount(const QModelIndex&) const; + QList<KDevelop::IDocumentationProvider*> providers(); + KDevelop::IDocumentationProvider* provider(int pos) const; + int rowForProvider(KDevelop::IDocumentationProvider* provider); + + public slots: + void unloaded(KDevelop::IPlugin* p); + void loaded(KDevelop::IPlugin* p); + + private: + QList<KDevelop::IDocumentationProvider*> mProviders; +}; + #endif // DOCUMENTATIONVIEW_H
*** Bug 249244 has been marked as a duplicate of this bug. ***
*** Bug 251938 has been marked as a duplicate of this bug. ***
*** Bug 252744 has been marked as a duplicate of this bug. ***
*** Bug 253884 has been marked as a duplicate of this bug. ***
*** Bug 254233 has been marked as a duplicate of this bug. ***
*** Bug 254267 has been marked as a duplicate of this bug. ***
*** Bug 254713 has been marked as a duplicate of this bug. ***
*** Bug 254855 has been marked as a duplicate of this bug. ***
*** Bug 254859 has been marked as a duplicate of this bug. ***
Created attachment 52868 [details] New crash information added by DrKonqi kdevelop (4.0.2 (using KDevPlatform 1.0.2)) on KDE Platform 4.5.1 (KDE 4.5.1) using Qt 4.7.0 - What I was doing when the application crashed: Closing KDevelop makes the program crash in error. This happens on Ubuntu 10.04 after a fresh install of KDevelop from the repo. -- Backtrace (Reduced): #6 0x00007f2302964f45 in ProvidersModel::data (this=<value optimized out>, index=<value optimized out>, role=<value optimized out>) at ../../shell/documentationview.cpp:51 #7 0x00007f230143f84c in QComboBoxPrivate::itemText (this=0x3600640, index=...) at widgets/qcombobox.cpp:1270 #8 0x00007f230143f9e6 in QComboBox::currentText (this=<value optimized out>) at widgets/qcombobox.cpp:2039 #9 0x00007f23014404f6 in QComboBox::initStyleOption (this=0x3600510, option=0x7fffd5706490) at widgets/qcombobox.cpp:1119 #10 0x00007f2301442f26 in QComboBoxPrivate::updateViewContainerPaletteAndOpacity (this=0x3600640) at widgets/qcombobox.cpp:1078
*** Bug 255629 has been marked as a duplicate of this bug. ***
*** Bug 255837 has been marked as a duplicate of this bug. ***
*** Bug 255931 has been marked as a duplicate of this bug. ***
*** Bug 256265 has been marked as a duplicate of this bug. ***
*** Bug 256399 has been marked as a duplicate of this bug. ***
*** Bug 258330 has been marked as a duplicate of this bug. ***
*** Bug 258335 has been marked as a duplicate of this bug. ***
*** Bug 259329 has been marked as a duplicate of this bug. ***
*** Bug 259334 has been marked as a duplicate of this bug. ***
*** Bug 260580 has been marked as a duplicate of this bug. ***
Created attachment 55345 [details] New crash information added by DrKonqi kdevelop (4.0.2 (using KDevPlatform 1.0.2)) on KDE Platform 4.5.1 (KDE 4.5.1) using Qt 4.7.0 - What I was doing when the application crashed: basta che apre l'ide e poi lo richiuda per avere sistematicamente l'errore in chiusura -- Backtrace (Reduced): #14 0x00d6ed6a in ProvidersModel::data (this=0x9734bd8, index=..., role=0) at ../../shell/documentationview.cpp:51 #15 0x01743b39 in QComboBoxPrivate::itemText (this=0x9734700, index=...) at widgets/qcombobox.cpp:1270 #16 0x01743cd0 in QComboBox::currentText (this=0x9734550) at widgets/qcombobox.cpp:2039 #17 0x017448fd in QComboBox::initStyleOption (this=0x9734550, option=0xbfa40ee0) at widgets/qcombobox.cpp:1119 #18 0x01747e61 in QComboBoxPrivate::updateViewContainerPaletteAndOpacity (this=0x9734700) at widgets/qcombobox.cpp:1078
*** Bug 262630 has been marked as a duplicate of this bug. ***
*** Bug 262889 has been marked as a duplicate of this bug. ***
Hi, U made a mistake. Because Im not developer responsble for these bugs. Dont worry, the people around Lucas will do that. Im windows developer for 3D games like stalker and WaterWorlds. 2011/1/11, Milian Wolff <mail@milianw.de>: > https://bugs.kde.org/show_bug.cgi?id=236037 > > > Milian Wolff <mail@milianw.de> changed: > > What |Removed |Added > ---------------------------------------------------------------------------- > CC| |martin.christopher.r@gmail. > | |com > > > > > --- Comment #29 from Milian Wolff <mail milianw de> 2011-01-11 20:43:22 --- > *** Bug 262630 has been marked as a duplicate of this bug. *** > > -- > Configure bugmail: https://bugs.kde.org/userprefs.cgi?tab=email > ------- You are receiving this mail because: ------- > You are on the CC list for the bug. >
*** Bug 263051 has been marked as a duplicate of this bug. ***
*** Bug 263079 has been marked as a duplicate of this bug. ***
Hi, U made a mistake. Because Im not developer responsble for these bugs. Dont worry, the people around Lucas will do that. Im windows developer for 3D games like stalker and WaterWorlds. 2011/1/13, Milian Wolff <mail@milianw.de>: > https://bugs.kde.org/show_bug.cgi?id=236037 > > > Milian Wolff <mail@milianw.de> changed: > > What |Removed |Added > ---------------------------------------------------------------------------- > CC| |sir.gustav.the.coder@gmail. > | |com > > > > > --- Comment #33 from Milian Wolff <mail milianw de> 2011-01-13 23:10:37 --- > *** Bug 263079 has been marked as a duplicate of this bug. *** > > -- > Configure bugmail: https://bugs.kde.org/userprefs.cgi?tab=email > ------- You are receiving this mail because: ------- > You are on the CC list for the bug. >
*** Bug 263260 has been marked as a duplicate of this bug. ***
Created attachment 56205 [details] New crash information added by DrKonqi kdevelop (4.0.2 (using KDevPlatform 1.0.2)) on KDE Platform 4.5.1 (KDE 4.5.1) using Qt 4.7.0 - What I was doing when the application crashed: wen i close the application, it give me a message: sorry the application is closed unexpectedly. -- Backtrace (Reduced): #14 0x009b6d6a in ProvidersModel::data (this=0x9205650, index=..., role=0) at ../../shell/documentationview.cpp:51 #15 0x01538b39 in QComboBoxPrivate::itemText (this=0x92052e0, index=...) at widgets/qcombobox.cpp:1270 #16 0x01538cd0 in QComboBox::currentText (this=0x92042e0) at widgets/qcombobox.cpp:2039 #17 0x015398fd in QComboBox::initStyleOption (this=0x92042e0, option=0xbf8264a0) at widgets/qcombobox.cpp:1119 #18 0x0153ce61 in QComboBoxPrivate::updateViewContainerPaletteAndOpacity (this=0x92052e0) at widgets/qcombobox.cpp:1078
*** Bug 263701 has been marked as a duplicate of this bug. ***
*** Bug 264098 has been marked as a duplicate of this bug. ***
*** Bug 264522 has been marked as a duplicate of this bug. ***
*** Bug 265213 has been marked as a duplicate of this bug. ***
*** Bug 265324 has been marked as a duplicate of this bug. ***
*** Bug 265732 has been marked as a duplicate of this bug. ***
Created attachment 57062 [details] New crash information added by DrKonqi kdevelop (4.0.2 (using KDevPlatform 1.0.2)) on KDE Platform 4.5.1 (KDE 4.5.1) using Qt 4.7.0 - What I was doing when the application crashed: nothing, I started kdevelop and after I closed it -- Backtrace (Reduced): #6 0x00007f8a32bb4f45 in ProvidersModel::data (this=<value optimized out>, index=<value optimized out>, role=<value optimized out>) at ../../shell/documentationview.cpp:51 #7 0x00007f8a3168f84c in QComboBoxPrivate::itemText (this=0x2eb7400, index=...) at widgets/qcombobox.cpp:1270 #8 0x00007f8a3168f9e6 in QComboBox::currentText (this=<value optimized out>) at widgets/qcombobox.cpp:2039 #9 0x00007f8a316904f6 in QComboBox::initStyleOption (this=0x2eb6ae0, option=0x7fff8c387c10) at widgets/qcombobox.cpp:1119 #10 0x00007f8a31692f26 in QComboBoxPrivate::updateViewContainerPaletteAndOpacity (this=0x2eb7400) at widgets/qcombobox.cpp:1078
*** Bug 266144 has been marked as a duplicate of this bug. ***
Created attachment 57200 [details] New crash information added by DrKonqi kdevelop (4.0.2 (using KDevPlatform 1.0.2)) on KDE Platform 4.5.1 (KDE 4.5.1) using Qt 4.7.0 - What I was doing when the application crashed: Also seeingthe same crash as everyone else. KDevelop crashes every time I close it, regardless of whether the app is closed by menu, title bar [X] or Alt-F4 -- Backtrace (Reduced): #14 0x007f1d6a in ProvidersModel::data (this=0x96c84c8, index=..., role=0) at ../../shell/documentationview.cpp:51 #15 0x05470b39 in QComboBoxPrivate::itemText (this=0x92578b8, index=...) at widgets/qcombobox.cpp:1270 #16 0x05470cd0 in QComboBox::currentText (this=0x96c6f60) at widgets/qcombobox.cpp:2039 #17 0x054718fd in QComboBox::initStyleOption (this=0x96c6f60, option=0xbf8a96d0) at widgets/qcombobox.cpp:1119 #18 0x05474e61 in QComboBoxPrivate::updateViewContainerPaletteAndOpacity (this=0x92578b8) at widgets/qcombobox.cpp:1078
*** Bug 266482 has been marked as a duplicate of this bug. ***
*** Bug 267092 has been marked as a duplicate of this bug. ***
*** Bug 267067 has been marked as a duplicate of this bug. ***
*** Bug 267023 has been marked as a duplicate of this bug. ***
*** Bug 267585 has been marked as a duplicate of this bug. ***
*** Bug 268100 has been marked as a duplicate of this bug. ***
*** Bug 268611 has been marked as a duplicate of this bug. ***
Thanks a lot. On Wed, Mar 16, 2011 at 2:05 PM, Milian Wolff <mail@milianw.de> wrote: > https://bugs.kde.org/show_bug.cgi?id=236037 > > > Milian Wolff <mail@milianw.de> changed: > > What |Removed |Added > > ---------------------------------------------------------------------------- > CC| |jack.xg.zhang@gmail.com > > > > > --- Comment #52 from Milian Wolff <mail milianw de> 2011-03-16 19:05:54 > --- > *** Bug 268611 has been marked as a duplicate of this bug. *** > > -- > Configure bugmail: https://bugs.kde.org/userprefs.cgi?tab=email > ------- You are receiving this mail because: ------- > You are on the CC list for the bug. >
*** Bug 268788 has been marked as a duplicate of this bug. ***
*** Bug 269349 has been marked as a duplicate of this bug. ***
*** Bug 270124 has been marked as a duplicate of this bug. ***
*** Bug 270679 has been marked as a duplicate of this bug. ***
*** Bug 271428 has been marked as a duplicate of this bug. ***
*** Bug 271783 has been marked as a duplicate of this bug. ***
*** Bug 271842 has been marked as a duplicate of this bug. ***
*** Bug 271902 has been marked as a duplicate of this bug. ***
*** Bug 280714 has been marked as a duplicate of this bug. ***
*** Bug 295161 has been marked as a duplicate of this bug. ***
Created attachment 69855 [details] New crash information added by DrKonqi kdevelop (4.0.2 (using KDevPlatform 1.0.2)) on KDE Platform 4.5.5 (KDE 4.5.5) using Qt 4.7.0 - What I was doing when the application crashed: Segmentation fault on exit (ubuntu 10.10). I just clicked on the "X" button and, after the main window close, the "crash report window" opened up. I did it three times. I was using KDevelop for the first time (just some trial executions). -- Backtrace (Reduced): #7 0x00f5ad67 in ProvidersModel::data (this=0xa3c7a10, index=..., role=0) at ../../shell/documentationview.cpp:51 #8 0x0151ab39 in QComboBoxPrivate::itemText (this=0xa3c7538, index=...) at widgets/qcombobox.cpp:1270 #9 0x0151acd0 in QComboBox::currentText (this=0xa3c7388) at widgets/qcombobox.cpp:2039 #10 0x0151b8fd in QComboBox::initStyleOption (this=0xa3c7388, option=0xbfb2e320) at widgets/qcombobox.cpp:1119 #11 0x0151ee61 in QComboBoxPrivate::updateViewContainerPaletteAndOpacity (this=0xa3c7538) at widgets/qcombobox.cpp:1078
*** Bug 307180 has been marked as a duplicate of this bug. ***