Commit 03b0da4f authored by Albert Astals Cid's avatar Albert Astals Cid

No need for a new function, just make the old one public

parent a2688e00
......@@ -232,8 +232,3 @@ bool KGmap::getDivisionCanAsk(const QString &div, division::askMode am) const
{
return getDivision(div) -> canAsk(am);
}
division *KGmap::getDivisionByRgb(QRgb c) const
{
return getDivision(c);
}
......@@ -55,14 +55,10 @@ class KGmap
QString getDivisionToCapitalQuestionPattern() const;
QString getCapitalToDivisionTitle() const;
QString getDivisionToCapitalTitle() const;
/**
* Public alternative of getDivision(QRgb c)
*/
division *getDivisionByRgb(QRgb c) const;
division *getDivision(QRgb c) const;
private:
division *getDivision(const QString &divisionName) const;
division *getDivision(QRgb c) const;
QList<division*> p_divisions;
......
......@@ -173,11 +173,11 @@ void mapAsker::handleMapClick(QRgb c, const QPoint &p)
{
int i = p_shuffledColormap.indexOf(vColorRgb);
origColor = p_originalColormap[i];
vDivision = p_map->getDivisionByRgb(origColor);
vDivision = p_map->getDivision(origColor);
}
else
{
vDivision = p_map->getDivisionByRgb(vColorRgb);
vDivision = p_map->getDivision(vColorRgb);
}
vDivisionName = i18nc(p_map -> getFileName().toUtf8(), vDivision->getName().toUtf8());
vAnswer.append(vDivisionName);
......
Markdown is supported
0% or
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment