表格完善,测量功能添加
This commit is contained in:
@@ -125,11 +125,6 @@ OPMapWidget::OPMapWidget(QWidget *parent, Configuration *config) : QGraphicsView
|
||||
connect(waypointsetting,SIGNAL(WPLoad(QString)),
|
||||
this,SLOT(WPLoad(QString)));
|
||||
|
||||
/*
|
||||
connect(this,SIGNAL(allPoint(QMap<int,int>)),
|
||||
waypointsetting,SLOT(setallPoint(QMap<int,int>)));
|
||||
*/
|
||||
|
||||
connect(waypointsetting,SIGNAL(searchall()),
|
||||
this,SLOT(WPsearchall()));
|
||||
|
||||
@@ -198,7 +193,12 @@ void OPMapWidget::ruler_clicked(void)
|
||||
if(isMeasure)
|
||||
{
|
||||
isMeasure = false;
|
||||
this->setCursor(Qt::ArrowCursor);
|
||||
//this->setCursor(Qt::ArrowCursor);
|
||||
if(measureline)
|
||||
{
|
||||
measureline->hide();
|
||||
|
||||
}
|
||||
}
|
||||
else
|
||||
{
|
||||
@@ -210,9 +210,11 @@ void OPMapWidget::ruler_clicked(void)
|
||||
measureline->show();
|
||||
}
|
||||
|
||||
QPixmap pix(":/markers/images/ruler.png");
|
||||
this->setCursor(QCursor(pix.scaled(QSize(50,50), Qt::KeepAspectRatio)));
|
||||
//QPixmap pix(":/markers/images/ruler.png");
|
||||
//this->setCursor(QCursor(pix.scaled(QSize(50,50), Qt::KeepAspectRatio)));
|
||||
}
|
||||
|
||||
emit measureState(isMeasure);
|
||||
}
|
||||
|
||||
void OPMapWidget::table_clicked(void)
|
||||
@@ -632,8 +634,8 @@ void OPMapWidget::mouseMoveEvent(QMouseEvent *event)
|
||||
|
||||
if(isMeasure)
|
||||
{
|
||||
QPixmap pix(":/markers/images/ruler.png");
|
||||
this->setCursor(QCursor(pix.scaled(QSize(50,50), Qt::KeepAspectRatio)));
|
||||
//QPixmap pix(":/markers/images/ruler.png");
|
||||
//this->setCursor(QCursor(pix.scaled(QSize(50,50), Qt::KeepAspectRatio)));
|
||||
}
|
||||
|
||||
|
||||
@@ -709,8 +711,8 @@ void OPMapWidget::mousePressEvent(QMouseEvent *event)
|
||||
|
||||
if(isMeasure)
|
||||
{
|
||||
QPixmap pix(":/markers/images/ruler.png");
|
||||
this->setCursor(QCursor(pix.scaled(QSize(50,50), Qt::KeepAspectRatio)));
|
||||
//QPixmap pix(":/markers/images/ruler.png");
|
||||
//this->setCursor(QCursor(pix.scaled(QSize(50,50), Qt::KeepAspectRatio)));
|
||||
}
|
||||
|
||||
|
||||
@@ -725,8 +727,8 @@ void OPMapWidget::mouseReleaseEvent(QMouseEvent *event)
|
||||
|
||||
if(isMeasure)
|
||||
{
|
||||
QPixmap pix(":/markers/images/ruler.png");
|
||||
this->setCursor(QCursor(pix.scaled(QSize(50,50), Qt::KeepAspectRatio)));
|
||||
//QPixmap pix(":/markers/images/ruler.png");
|
||||
//this->setCursor(QCursor(pix.scaled(QSize(50,50), Qt::KeepAspectRatio)));
|
||||
}
|
||||
|
||||
//qDebug() << "relea";
|
||||
@@ -738,8 +740,8 @@ void OPMapWidget::mouseDoubleClickEvent(QMouseEvent *event)
|
||||
|
||||
if(isMeasure)
|
||||
{
|
||||
QPixmap pix(":/markers/images/ruler.png");
|
||||
this->setCursor(QCursor(pix.scaled(QSize(50,50), Qt::KeepAspectRatio)));
|
||||
//QPixmap pix(":/markers/images/ruler.png");
|
||||
//this->setCursor(QCursor(pix.scaled(QSize(50,50), Qt::KeepAspectRatio)));
|
||||
}
|
||||
|
||||
if(isMeasure)
|
||||
@@ -2213,6 +2215,8 @@ void OPMapWidget::WPGroup(int value)
|
||||
{
|
||||
currentGroup = value;
|
||||
|
||||
|
||||
|
||||
qDebug() << "group checkout" << value;
|
||||
|
||||
//切换当前航线,其他都隐藏,或者高亮当前
|
||||
@@ -2273,6 +2277,8 @@ void OPMapWidget::WPGroup(int value)
|
||||
}
|
||||
}
|
||||
|
||||
emit settableGroup(currentGroup);
|
||||
|
||||
update();
|
||||
}
|
||||
|
||||
|
||||
Reference in New Issue
Block a user