Summary: | display actual resource usage number in mouseover popup | ||
---|---|---|---|
Product: | [Unmaintained] ksysguard | Reporter: | Nan Zou <nzou> |
Component: | general | Assignee: | KSysGuard Developers <ksysguard-bugs> |
Status: | RESOLVED FIXED | ||
Severity: | wishlist | CC: | colin, tiago.freire |
Priority: | NOR | ||
Version: | unspecified | ||
Target Milestone: | --- | ||
Platform: | Compiled Sources | ||
OS: | Linux | ||
Latest Commit: | Version Fixed In: | ||
Sentry Crash Report: |
Description
Nan Zou
2003-05-27 21:42:50 UTC
"Digital" labels on the graphs would be something nice to add too, but I like your tooltip idea. From Frédéric Motte on bug 60540: Color of data tracked will be another nice information to have. *** Bug 60540 has been marked as a duplicate of this bug. *** Greg, I've added the color already to KDE4. Showing the values.. the trouble is i can show the value but it won't update _while the tooltip is being shown_. You can't modify the tooltip in real time. as for not updating in real time while the tooltip is being displayed... does it HAVE to be a tooltip? won't KDE 4 allow for more stuff and eye candy? Not just for beauty, but a better way to convey information. Look at our pager. instead of a tooltip it does this baloon with icons and information about runnin programs on that desktop etc. I like to use a small kicker, but i'd like to see, when I hover my mouse over the ksysguard cpu meter, for instance (could be anything else), pops me a baloon not unlike the pager one (minus the animation maybe?), with a BIG version of the graph itself (say 64x64) and the textual information at the right, updated in real time. Okay from revision 610259 it now shows the values in the tooltip. Tiago, I really like your idea. Could you file it as another wish please as it's separate. Situation: My fan goes off cause the CPU load shoots up to 100% Reaction: First look at KSysGuard-Applet in the controllbar Frustration: It does not show me the culprit It just takes too long to open up the processtable, deactivate the treeview, sort for CPU-Usage, pic the process, activate the treeview again, sort alphabetically and sroll to monitor it. Anyway, how do I sort for the total CPU usage and not the partial user usage? KSysGuard itself becomes slow, because the other process is going wild. And second until you see it on the screen, the show is all over and the process gone or sleeping. What I'd really love to have is a quick display of the top consumer and maybe offer some way to send it a KILL. And if you really want to see me drooling: Add a history, so that I can hover my mouse over the graph and see the culprit, who caused that peek CPU-Usage. In other words: Have a look at Process Explorer, that does a pretty good job in the M$ Windows world: http://www.microsoft.com/technet/sysinternals/utilities/ProcessExplorer.mspx Holger, please file a separate bug report. Showing the 'culprit' a good idea, but it should be a separate wishlist item. Re: Ksysguard's speed The kde4 version is very fast. It should be able to respond under any load. Re: Total CPU usage The kde4 version shows total CPU usage by default now. @Greg My request is now at Bug 143348 I wasn't complaining about KSysGuards normal speed. This is about the abnormal situation of another process eating up 99% CPU. Looking forward for openSUSE to release an update to KDE4 :-) commit fae4a67a16b9907708c940c1ea72ec1a0eaf7bb9 Author: Colin Guthrie <cguthrie@mandriva.org> Date: Wed May 12 10:03:59 2010 +0100 pulse: Some signal emission protection and some debug tweaks. This commit ensures that the objectDescriptionChanged signal is only emitted when PA is active. If we try to connect, succeed, but the backend ultimately cannot support PA, we fail. At present the GST backend operates a 'hit and hope' policy with regards to the pulsesink. This needs to be tightened up. Also added is extra debug info when the support is enabled and a new debug method which is not called anywhere but can be useful when debugging code. CCBUG: 59052 diff --git a/phonon/pulsesupport.cpp b/phonon/pulsesupport.cpp index e85abd5..769d7e1 100644 --- a/phonon/pulsesupport.cpp +++ b/phonon/pulsesupport.cpp @@ -666,6 +666,19 @@ void PulseSupport::shutdown() } } +void PulseSupport::debug() +{ +#ifdef HAVE_PULSEAUDIO + logMessage(QString("Have we been initialised yet? %1").arg(s_instance ? "Yes" : "No")); + if (s_instance) { + logMessage(QString("Connected to PulseAudio? %1").arg(s_pulseActive ? "Yes" : "No")); + logMessage(QString("PulseAudio support 'Active'? %1").arg(s_instance->isActive() ? "Yes" : "No")); + } +#else + logMessage("PulseAudio support not available."); +#endif +} + PulseSupport::PulseSupport() : QObject(), mEnabled(false) { @@ -780,7 +793,6 @@ void PulseSupport::connectToDaemon() bool PulseSupport::isActive() { #ifdef HAVE_PULSEAUDIO - //logMessage(QString("Enabled Breakdown: mEnabled: %1, s_pulseActive %2").arg(mEnabled).arg(s_pulseActive)); return mEnabled && s_pulseActive; #else return false; @@ -790,6 +802,9 @@ bool PulseSupport::isActive() void PulseSupport::enable(bool enabled) { mEnabled = enabled; +#ifdef HAVE_PULSEAUDIO + logMessage(QString("Enabled Breakdown: mEnabled: %1, s_pulseActive %2").arg(mEnabled ? "Yes" : "No" ).arg(s_pulseActive ? "Yes" : "No")); +#endif } QList<int> PulseSupport::objectDescriptionIndexes(ObjectDescriptionType type) const @@ -997,7 +1012,8 @@ PulseStream *PulseSupport::registerCaptureStream(QString streamUuid, Category ca void PulseSupport::emitObjectDescriptionChanged(ObjectDescriptionType type) { - emit objectDescriptionChanged(type); + if (mEnabled) + emit objectDescriptionChanged(type); } bool PulseSupport::setOutputName(QString streamUuid, QString name) { diff --git a/phonon/pulsesupport.h b/phonon/pulsesupport.h index dc08330..d78ac64 100644 --- a/phonon/pulsesupport.h +++ b/phonon/pulsesupport.h @@ -66,6 +66,7 @@ namespace Phonon // or phonon supports capture properly... which ever comes first. void clearStreamCache(QString streamUuid); + static void debug(); public slots: void connectToDaemon(); commit 70babff2d8f27828c5912a879538d04a756fc86c Author: Colin Guthrie <cguthrie@mandriva.org> Date: Wed May 12 10:43:23 2010 +0100 gstreamer: Rejig the PulseAudio detection and handling a little. Attempt to make the PulseAudio initialisation in GStreamer a bit more robust. Validate the initial sink usage if it comes from either env var or settings against the known status of PA (is it running or not) and only ever try a 'pulsesink' if it is running, with 'auto' favouring 'pulsesink' when PA is running. When trying to open the device fails when PA is running we change back to 'auto' and try again. This handles the case when the GStreamer 'pulsesink' is not available (which is hard as it's a -good plugin these days). CCBUG: 59052 diff --git a/gstreamer/devicemanager.cpp b/gstreamer/devicemanager.cpp index c3826eb..6485094 100644 --- a/gstreamer/devicemanager.cpp +++ b/gstreamer/devicemanager.cpp @@ -82,13 +82,21 @@ DeviceManager::DeviceManager(Backend *backend) PulseSupport *pulse = PulseSupport::getInstance(); m_audioSink = qgetenv("PHONON_GST_AUDIOSINK"); - if (m_audioSink.isEmpty()) { + if (m_audioSink.isEmpty()) m_audioSink = settings.value(QLatin1String("audiosink"), "Auto").toByteArray().toLower(); - if (m_audioSink == "auto" && pulse->isActive()) - m_audioSink = "pulsesink"; - } - if ("pulsesink" != m_audioSink) + + if ("pulsesink" == m_audioSink && !pulse->isActive()) { + // If pulsesink is specifically requested, but not active, then + // fall back to auto. + m_audioSink = "auto"; + } else if (m_audioSink == "auto" && pulse->isActive()) { + // We favour specific PA support if it's active and we're in 'auto' mode + // (although it may still be disabled if the pipeline cannot be made) + m_audioSink = "pulsesink"; + } else if (m_audioSink != "pulsesink") { + // Otherwise, PA should not be used. pulse->enable(false); + } m_videoSinkWidget = qgetenv("PHONON_GST_VIDEOMODE"); if (m_videoSinkWidget.isEmpty()) { @@ -234,9 +242,19 @@ GstElement *DeviceManager::createAudioSink(Category category) sink = gst_element_factory_make (m_audioSink, NULL); if (canOpenDevice(sink)) m_backend->logMessage(QString("AudioOutput using %0").arg(QString::fromUtf8(m_audioSink))); - else if (sink) { - gst_object_unref(sink); - sink = 0; + else { + if (sink) { + gst_object_unref(sink); + sink = 0; + } + if ("pulsesink" == m_audioSink) { + // We've tried to use PulseAudio support, but the GST plugin + // doesn't exits. Let's try again, but not use PA support this time. + m_backend->logMessage("PulseAudio support failed. Falling back to 'auto'"); + PulseSupport::getInstance()->enable(false); + m_audioSink = "auto"; + sink = createAudioSink(); + } } } } commit 67b424626866d1a4b2e80c3e93698456042889fc Author: Colin Guthrie <cguthrie@mandriva.org> Date: Wed May 12 10:55:37 2010 +0100 gstreamer: Move some code inside pointer protection. This can only happen if asserts are disabled, so this is somewhat unlikely, but it's better to be safe. This is unlikely to be related to the bug #59052, but in the event that PA is running but both 'pulsesink' and 'fakesink' cannot be created AND asserts are disabled, then this could cause some issues. CCBUG: 59052 diff --git a/gstreamer/devicemanager.cpp b/gstreamer/devicemanager.cpp index 6485094..3b0d4c3 100644 --- a/gstreamer/devicemanager.cpp +++ b/gstreamer/devicemanager.cpp @@ -392,10 +392,10 @@ void DeviceManager::updateDeviceList() } } } - } - gst_element_set_state (audioSink, GST_STATE_NULL); - gst_object_unref (audioSink); + gst_element_set_state (audioSink, GST_STATE_NULL); + gst_object_unref (audioSink); + } } /** Dammit. Totally incorrect bug reference. Sorry about that :( |