StoredPointsDialog.cpp   StoredPointsDialog.cpp 
skipping to change at line 27 skipping to change at line 27
* along with this program; if not, write to the Free Software * along with this program; if not, write to the Free Software
* Foundation, Inc., 51 Franklin Street, Suite 500, Boston, MA 02110-1335, USA. * Foundation, Inc., 51 Franklin Street, Suite 500, Boston, MA 02110-1335, USA.
*/ */
#include "StoredPointsDialog.hpp" #include "StoredPointsDialog.hpp"
#include "ui_storedPointsDialog.h" #include "ui_storedPointsDialog.h"
StoredPointsDialog::StoredPointsDialog() StoredPointsDialog::StoredPointsDialog()
{ {
ui = new Ui_StoredPoints; ui = new Ui_StoredPoints;
dialogName = "TelescopeControlStoredPoints";
storedPointsListModel = new QStandardItemModel(0, ColumnCount); storedPointsListModel = new QStandardItemModel(0, ColumnCount);
} }
StoredPointsDialog::~StoredPointsDialog() StoredPointsDialog::~StoredPointsDialog()
{ {
delete ui; delete ui;
delete storedPointsListModel; delete storedPointsListModel;
} }
void StoredPointsDialog::retranslate() void StoredPointsDialog::retranslate()
skipping to change at line 48 skipping to change at line 49
if (dialog) if (dialog)
ui->retranslateUi(dialog); ui->retranslateUi(dialog);
} }
void StoredPointsDialog::createDialogContent() void StoredPointsDialog::createDialogContent()
{ {
ui->setupUi(dialog); ui->setupUi(dialog);
//Inherited connect //Inherited connect
connect(&StelApp::getInstance(), SIGNAL(languageChanged()), this, SL OT(retranslate())); connect(&StelApp::getInstance(), SIGNAL(languageChanged()), this, SL OT(retranslate()));
connect(ui->closeStelWindow, SIGNAL(clicked()), this, SLOT(close())) ; connect(ui->closeStelWindow, SIGNAL(clicked()), this, SLOT(close())) ;
connect(ui->TitleBar, SIGNAL(movedTo(QPoint)), this, SLOT(handleMove dTo(QPoint)));
connect(ui->pushButtonAddPoint, SIGNAL(clicked()), this, SLOT(butt onAddPressed())); connect(ui->pushButtonAddPoint, SIGNAL(clicked()), this, SLOT(butt onAddPressed()));
connect(ui->pushButtonRemovePoint,SIGNAL(clicked()), this, SLOT(butt onRemovePressed())); connect(ui->pushButtonRemovePoint,SIGNAL(clicked()), this, SLOT(butt onRemovePressed()));
connect(ui->pushButtonClearList, SIGNAL(clicked()), this, SLOT(butt onClearPressed()));
connect(ui->pushButtonCurrent, SIGNAL(clicked()), this, SLOT(getCurr entObjectInfo())); connect(ui->pushButtonCurrent, SIGNAL(clicked()), this, SLOT(getCurr entObjectInfo()));
connect(ui->pushButtonCenter, SIGNAL(clicked()), this, SLOT(getCente rInfo())); connect(ui->pushButtonCenter, SIGNAL(clicked()), this, SLOT(getCente rInfo()));
//Initializing the list of telescopes //Initializing the list of telescopes
storedPointsListModel->setColumnCount(ColumnCount); storedPointsListModel->setColumnCount(ColumnCount);
setHeaderNames(); setHeaderNames();
ui->treeViewStoredPoints->setModel(storedPointsListModel); ui->treeViewStoredPoints->setModel(storedPointsListModel);
ui->treeViewStoredPoints->header()->setSectionsMovable(false); ui->treeViewStoredPoints->header()->setSectionsMovable(false);
skipping to change at line 126 skipping to change at line 129
} }
void StoredPointsDialog::buttonRemovePressed() void StoredPointsDialog::buttonRemovePressed()
{ {
int number = ui->treeViewStoredPoints->currentIndex().row(); int number = ui->treeViewStoredPoints->currentIndex().row();
storedPointsListModel->removeRow(number); storedPointsListModel->removeRow(number);
emit removeStoredPoint(number); emit removeStoredPoint(number);
} }
void StoredPointsDialog::buttonClearPressed()
{
storedPointsListModel->clear();
emit clearStoredPoints();
}
void StoredPointsDialog::addModelRow(int number, QString name, QString RA, QString Dec) void StoredPointsDialog::addModelRow(int number, QString name, QString RA, QString Dec)
{ {
QStandardItem* tempItem = 0; QStandardItem* tempItem = 0;
tempItem = new QStandardItem(QString::number(number+1)); tempItem = new QStandardItem(QString::number(number+1));
tempItem->setEditable(false); tempItem->setEditable(false);
storedPointsListModel->setItem(number, ColumnSlot, tempItem); storedPointsListModel->setItem(number, ColumnSlot, tempItem);
tempItem = new QStandardItem(name); tempItem = new QStandardItem(name);
tempItem->setEditable(false); tempItem->setEditable(false);
 End of changes. 4 change blocks. 
0 lines changed or deleted 10 lines changed or added

This html diff was produced by rfcdiff 1.41. The latest version is available from http://tools.ietf.org/tools/rfcdiff/