make setImagePath virtual

This commit is contained in:
Aaron Seigo 2011-05-20 08:16:01 +02:00
parent 9da79a0840
commit a225402b9e
2 changed files with 1 additions and 7 deletions

View File

@ -778,12 +778,6 @@ bool Svg::containsMultipleImages() const
void Svg::setImagePath(const QString &svgFilePath)
{
//BIC FIXME: setImagePath should be virtual, or call an internal virtual protected method
if (FrameSvg *frame = qobject_cast<FrameSvg *>(this)) {
frame->setImagePath(svgFilePath);
return;
}
if (d->setImagePath(svgFilePath)) {
//kDebug() << "repaintNeeded";
emit repaintNeeded();

2
svg.h
View File

@ -299,7 +299,7 @@ class PLASMA_EXPORT Svg : public QObject
* @arg svgFilePath either an absolute path to an SVG file, or
* an image name
*/
void setImagePath(const QString &svgFilePath);
virtual void setImagePath(const QString &svgFilePath);
/**
* The SVG file to render.