1
/***************************************************************************
2
qgsgeomtypedialog.cpp - description
5
copyright : (C) 2004 by Marco Hugentobler
6
email : marco.hugentobler@autoform.ch
7
***************************************************************************/
9
/***************************************************************************
11
* This program is free software; you can redistribute it and/or modify *
12
* it under the terms of the GNU General Public License as published by *
13
* the Free Software Foundation; either version 2 of the License, or *
14
* (at your option) any later version. *
16
***************************************************************************/
17
/* $Id: qgsgeomtypedialog.cpp,v 1.3 2004/10/26 17:28:02 mcoletti Exp $ */
18
#include "qgsgeomtypedialog.h"
19
#include <qradiobutton.h>
21
QgsGeomTypeDialog::QgsGeomTypeDialog(): QgsGeomTypeDialogBase()
23
QObject::connect((QObject*)mOkButton, SIGNAL(clicked()), this, SLOT(accept()));//why is this cast necessary????
24
QObject::connect((QObject*)mCancelButton, SIGNAL(clicked()), this, SLOT(reject()));//why is this cast necessary????
25
mPointRadioButton->setChecked(true);
28
QgsGeomTypeDialog::~QgsGeomTypeDialog()
33
QGis::WKBTYPE QgsGeomTypeDialog::selectedType()
35
if(mPointRadioButton->isChecked())
37
return QGis::WKBPoint;
39
else if(mLineRadioButton->isChecked())
41
return QGis::WKBLineString;
43
else if(mPolygonRadioButton->isChecked())
45
return QGis::WKBPolygon;
48
return QGis::WKBUnknown;