SVN_SILENT a few bits of code consistency
svn path=/trunk/KDE/kdebase/workspace/libs/plasma/; revision=833494
This commit is contained in:
parent
504ebb9e0c
commit
853b6a1f93
@ -173,25 +173,26 @@ void ToolTipManager::registerWidget(QGraphicsWidget *widget)
|
|||||||
|
|
||||||
void ToolTipManager::unregisterWidget(QGraphicsWidget *widget)
|
void ToolTipManager::unregisterWidget(QGraphicsWidget *widget)
|
||||||
{
|
{
|
||||||
if (d->tooltips.contains(widget)) {
|
if (!d->tooltips.contains(widget)) {
|
||||||
|
return;
|
||||||
|
}
|
||||||
|
|
||||||
ToolTip * tooltip = d->tooltips.take(widget);
|
ToolTip * tooltip = d->tooltips.take(widget);
|
||||||
if (tooltip) {
|
if (tooltip) {
|
||||||
delete tooltip;
|
delete tooltip;
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
}
|
|
||||||
|
|
||||||
void ToolTipManager::setWidgetToolTipContent(QGraphicsWidget *widget,const ToolTipContent &data)
|
void ToolTipManager::setWidgetToolTipContent(QGraphicsWidget *widget,const ToolTipContent &data)
|
||||||
{
|
{
|
||||||
if (!d->tooltips.contains(widget)) {
|
if (!d->tooltips.contains(widget)) {
|
||||||
return;
|
return;
|
||||||
}
|
}
|
||||||
else {
|
|
||||||
ToolTip * tooltip = d->tooltips.value(widget);
|
ToolTip * tooltip = d->tooltips.value(widget);
|
||||||
tooltip->setContent(data);
|
tooltip->setContent(data);
|
||||||
tooltip->updateTheme();
|
tooltip->updateTheme();
|
||||||
}
|
}
|
||||||
}
|
|
||||||
|
|
||||||
bool ToolTipManager::widgetHasToolTip(QGraphicsWidget *widget)
|
bool ToolTipManager::widgetHasToolTip(QGraphicsWidget *widget)
|
||||||
{
|
{
|
||||||
|
Loading…
Reference in New Issue
Block a user