Skip to content
Permalink
Browse files

Tidy up indenting.

Remove two unnecessary debugging output lines


git-svn-id: http://svn.osgeo.org/qgis/trunk/qgis@5190 c8812cc2-4d05-0410-92ff-de0c093fc19c
  • Loading branch information
g_j_m
g_j_m committed Apr 6, 2006
1 parent d39e34d commit 278648dd238f093223e52794016019f177ad1fb4
Showing with 17 additions and 19 deletions.
  1. +17 −19 src/gui/qgsproject.cpp
@@ -721,28 +721,28 @@ static QString _getVersion(QDomDocument const &doc)
*/
static QgsMapCanvas * _findMapCanvas(QString const &canonicalMapCanvasName)
{
QgsMapCanvas * theMapCanvas = 0x0;

QWidgetList wlist = QApplication::topLevelWidgets();
foreach (QWidget *widget, QApplication::topLevelWidgets())
{
theMapCanvas = dynamic_cast <QgsMapCanvas *>(widget->child(canonicalMapCanvasName));
if(theMapCanvas)
{
break;
}
}
QgsMapCanvas * theMapCanvas = 0x0;

QWidgetList wlist = QApplication::topLevelWidgets();
foreach (QWidget *widget, QApplication::topLevelWidgets())
{
theMapCanvas = dynamic_cast <QgsMapCanvas *>(widget->child(canonicalMapCanvasName));
if (theMapCanvas)
{
return theMapCanvas;
} else
{
qDebug(("Unable to find canvas widget " + canonicalMapCanvasName).toLocal8Bit().data());

return 0x0; // XXX some sort of error value? Exception?
break;
}
}

if (theMapCanvas)
{
return theMapCanvas;
}
else
{
qDebug(("Unable to find canvas widget " + canonicalMapCanvasName).toLocal8Bit().data());

return 0x0; // XXX some sort of error value? Exception?
}
} // _findMapCanvas


@@ -1125,9 +1125,7 @@ bool QgsProject::read()

// ensure that overview map canvas is set to *entire* extent
QgsRect mapCanvasFullExtent = _getFullExtent("theMapCanvas");
std::cerr <<__FILE__<<__LINE__<<'\n';
_setCanvasExtent("theOverviewCanvas", mapCanvasFullExtent);
std::cerr <<__FILE__<<__LINE__<<'\n';
// now restore the extent for the main canvas
_setCanvasExtent("theMapCanvas", savedExtent);

0 comments on commit 278648d

Please sign in to comment.
You can’t perform that action at this time.