Skip to content

Commit

Permalink
Fixes from mateusz for the following issues:
Browse files Browse the repository at this point in the history
1453164     getCurrentLongAttribute incomplete return path
1449301   QgsSingleSymbolRenderer::operator= must return a value
1449277   QgsLegendGroup::insert must return a value
1449268   QgsGeometryVertexIndex::operator= must return a value
1449257   QgsGraduatedSymbolRenderer::operator= must return a value
1449252   QgsContinuousColorRenderer::operator= must return a value
1448031   QgsUniqueValueRenderer::operator= must return a value
1448028   QgsMapLayer::draw must return a value
1448014   'and' is undefined keyword




git-svn-id: http://svn.osgeo.org/qgis/trunk/qgis@5060 c8812cc2-4d05-0410-92ff-de0c093fc19c
  • Loading branch information
timlinux committed Mar 18, 2006
1 parent dc20cde commit ad79318
Show file tree
Hide file tree
Showing 12 changed files with 42 additions and 27 deletions.
1 change: 1 addition & 0 deletions ChangeLog
@@ -1,5 +1,6 @@
/* ChangeLog,v 1.214 2004/11/12 00:42:21 gsherman Exp */
------------------------------------------------------------------------------

Version 0.8 'Joesephine' .... development version
2006-01-23 [timlinux] 0.7.9.10
** Dropped use of qpicture and resampling for point markers in favour of
Expand Down
1 change: 1 addition & 0 deletions src/core/qgsgeometryvertexindex.cpp
Expand Up @@ -31,6 +31,7 @@ QgsGeometryVertexIndex::QgsGeometryVertexIndex( QgsGeometryVertexIndex const & r
QgsGeometryVertexIndex & QgsGeometryVertexIndex::operator=( QgsGeometryVertexIndex const & rhs )
{
mIndex = rhs.mIndex;
return *this;
}

QgsGeometryVertexIndex::~QgsGeometryVertexIndex()
Expand Down
1 change: 1 addition & 0 deletions src/gui/qgscontinuouscolorrenderer.cpp
Expand Up @@ -54,6 +54,7 @@ QgsContinuousColorRenderer& QgsContinuousColorRenderer::operator=(const QgsConti
mMinimumSymbol = new QgsSymbol(*other.mMinimumSymbol);
mMaximumSymbol = new QgsSymbol(*other.mMaximumSymbol);
}
return *this;
}

QgsContinuousColorRenderer::~QgsContinuousColorRenderer()
Expand Down
18 changes: 10 additions & 8 deletions src/gui/qgsgraduatedsymbolrenderer.cpp
Expand Up @@ -49,15 +49,17 @@ QgsGraduatedSymbolRenderer& QgsGraduatedSymbolRenderer::operator=(const QgsGradu
{
if(this != &other)
{
mVectorType = other.mVectorType;
mClassificationField = other.mClassificationField;
removeSymbols();
const std::list<QgsSymbol*> s = other.symbols();
for(std::list<QgsSymbol*>::const_iterator it=s.begin(); it!=s.end(); ++it)
{
addSymbol(new QgsSymbol(**it));
}
mVectorType = other.mVectorType;
mClassificationField = other.mClassificationField;
removeSymbols();
const std::list<QgsSymbol*> s = other.symbols();
for(std::list<QgsSymbol*>::const_iterator it=s.begin(); it!=s.end(); ++it)
{
addSymbol(new QgsSymbol(**it));
}
}

return *this;
}

QgsGraduatedSymbolRenderer::~QgsGraduatedSymbolRenderer()
Expand Down
1 change: 1 addition & 0 deletions src/gui/qgslabel.cpp
Expand Up @@ -38,6 +38,7 @@

// use M_PI define PI 3.141592654
#ifdef WIN32
#undef M_PI
#define M_PI 4*atan(1.0)
#endif

Expand Down
1 change: 1 addition & 0 deletions src/gui/qgsmaplayer.cpp
Expand Up @@ -157,6 +157,7 @@ void QgsMapLayer::draw(QPainter *, QgsRect * viewExtent, int yTransform)
bool QgsMapLayer::draw(QPainter *, QgsRect *, QgsMapToPixel *)
{
// std::cout << "In QgsMapLayer::draw" << std::endl;
return false;
}

void QgsMapLayer::drawLabels(QPainter *, QgsRect *, QgsMapToPixel *)
Expand Down
5 changes: 4 additions & 1 deletion src/gui/qgsserversourceselect.cpp
Expand Up @@ -283,7 +283,10 @@ void QgsServerSourceSelect::populateImageEncodingGroup(QgsWmsProvider* wmsProvid

std::set<QString> QgsServerSourceSelect::crsForSelection()
{
std::set<QString> crsCandidates;;
std::set<QString> crsCandidates;

// XXX - mloskot - temporary solution, function must return a value
return crsCandidates;

QStringList::const_iterator i;
for (i = m_selectedLayers.constBegin(); i != m_selectedLayers.constEnd(); ++i)
Expand Down
7 changes: 4 additions & 3 deletions src/gui/qgssinglesymbolrenderer.cpp
Expand Up @@ -67,10 +67,11 @@ QgsSingleSymbolRenderer& QgsSingleSymbolRenderer::operator=(const QgsSingleSymbo
{
if(this!=&other)
{
mVectorType = other.mVectorType;
delete mSymbol;
mSymbol = new QgsSymbol(*other.mSymbol);
mVectorType = other.mVectorType;
delete mSymbol;
mSymbol = new QgsSymbol(*other.mSymbol);
}
return *this;
}

QgsSingleSymbolRenderer::~QgsSingleSymbolRenderer()
Expand Down
17 changes: 9 additions & 8 deletions src/gui/qgsuniquevaluerenderer.cpp
Expand Up @@ -51,15 +51,16 @@ QgsUniqueValueRenderer& QgsUniqueValueRenderer::operator=(const QgsUniqueValueRe
{
if(this != &other)
{
mVectorType = other.mVectorType;
mClassificationField = other.mClassificationField;
clearValues();
for(std::map<QString, QgsSymbol*>::iterator it=mSymbols.begin(); it!=mSymbols.end(); ++it)
{
QgsSymbol* s = new QgsSymbol(*(it->second));
insertValue(it->first, s);
}
mVectorType = other.mVectorType;
mClassificationField = other.mClassificationField;
clearValues();
for(std::map<QString, QgsSymbol*>::iterator it=mSymbols.begin(); it!=mSymbols.end(); ++it)
{
QgsSymbol* s = new QgsSymbol(*(it->second));
insertValue(it->first, s);
}
}
return *this;
}

QgsUniqueValueRenderer::~QgsUniqueValueRenderer()
Expand Down
5 changes: 4 additions & 1 deletion src/legend/qgslegendgroup.cpp
Expand Up @@ -99,8 +99,11 @@ bool QgsLegendGroup::insert(QgsLegendItem* theItem)
{
if(theItem->type() == LEGEND_LAYER)
{
addChild(theItem);
addChild(theItem);
}
// XXX - mloskot - I don't know what to return
// but this function must return a value
return true;
}

std::list<QgsLegendLayerFile*> QgsLegendGroup::legendLayerFiles()
Expand Down
4 changes: 2 additions & 2 deletions src/ui/qgisappbase.ui
Expand Up @@ -89,8 +89,8 @@
<rect>
<x>0</x>
<y>0</y>
<width>341</width>
<height>237</height>
<width>363</width>
<height>243</height>
</rect>
</property>
<attribute name="label" >
Expand Down
8 changes: 4 additions & 4 deletions src/widgets/projectionselector/qgsprojectionselector.cpp
Expand Up @@ -161,8 +161,8 @@ void QgsProjectionSelector::setSelectedSRSID(long theSRSID)
void QgsProjectionSelector::applySRSNameSelection()
{
if (
(mSRSNameSelectionPending) and
(mProjListDone) and
(mSRSNameSelectionPending) &&
(mProjListDone) &&
(mUserProjListDone)
)
{
Expand Down Expand Up @@ -190,8 +190,8 @@ void QgsProjectionSelector::applySRSNameSelection()
void QgsProjectionSelector::applySRSIDSelection()
{
if (
(mSRSIDSelectionPending) and
(mProjListDone) and
(mSRSIDSelectionPending) &&
(mProjListDone) &&
(mUserProjListDone)
)
{
Expand Down

0 comments on commit ad79318

Please sign in to comment.