Przeglądaj źródła

remove useless page

lijinliang 3 lat temu
rodzic
commit
a7b5654c38

+ 20 - 24
src/ui/ui_ads_hmi_1px/ADCIntelligentVehicle.cpp

@@ -246,12 +246,8 @@ ADCIntelligentVehicle::ADCIntelligentVehicle(QWidget *parent)
     ServiceCarStatus.lidar_y_offset = atof(xp.GetParam("lidar_y_offset","0").data());
 
 
-    ui->listWidget->setIconSize(QSize(40,40));
     ui->stackedWidget->setCurrentIndex(0);
 
-    //  QObject::connect(ui->listWidget,SIGNAL(currentRowChanged(int)),ui->stackedWidget,SLOT(on_listWidget_clicked()));//信号与槽
-    QObject::connect(ui->listWidget,SIGNAL(currentRowChanged(int)),this,SLOT(on_listWidget_clicked()));//信号与槽
-
     //    /********************************** 百度地图显示  ********************************/
     //    mMapview = new QWebEngineView(ui->stackedWidget->widget(0));
     ////    qDebug((QDir::currentPath()).toLatin1().data());
@@ -259,9 +255,9 @@ ADCIntelligentVehicle::ADCIntelligentVehicle(QWidget *parent)
     //    mMapview->setGeometry(750,250,400,400);
     //    /********************************************************************************/
 
-    ui->listWidget->setCurrentRow(1);    //apollo_fu debug 20200409
+//    ui->listWidget->setCurrentRow(1);    //apollo_fu debug 20200409
 
-    myview = new MyView(ui->stackedWidget->widget(1));
+    myview = new MyView(ui->stackedWidget->widget(0));
     myview->setObjectName(QStringLiteral("graphicsView"));
     myview->setGeometry(QRect(0, 100, 900, 750)); //从屏幕上(0,100)位置开始(即为最左上角的点),显示一个900*900的界面(宽900,高900)
 
@@ -1366,26 +1362,26 @@ void ADCIntelligentVehicle::paintEvent(QPaintEvent *)
  */
 void ADCIntelligentVehicle::on_listWidget_clicked()
 {
-    int currentRow=ui->listWidget->currentRow(); //currentRow()获取当前行号
+//    int currentRow=ui->listWidget->currentRow(); //currentRow()获取当前行号
 
-    if(currentRow==0) //点击第一切换到第一页
-    {
-        ui->stackedWidget->setCurrentIndex(0);//为堆栈窗体切换到当前索引
-    }
+//    if(currentRow==0) //点击第一切换到第一页
+//    {
+//        ui->stackedWidget->setCurrentIndex(0);//为堆栈窗体切换到当前索引
+//    }
 
-    else if(currentRow==1)
-    {
-        ui->stackedWidget->setCurrentIndex(1);
-    }
-    else if(currentRow==2)
-    {
-        ui->stackedWidget->setCurrentIndex(2);
-    }
+//    else if(currentRow==1)
+//    {
+//        ui->stackedWidget->setCurrentIndex(1);
+//    }
+//    else if(currentRow==2)
+//    {
+//        ui->stackedWidget->setCurrentIndex(2);
+//    }
 
-    else
-    {
-        ui->stackedWidget->setCurrentIndex(0);
-    }
+//    else
+//    {
+//        ui->stackedWidget->setCurrentIndex(0);
+//    }
 }
 
 /**
@@ -2220,7 +2216,7 @@ void ADCIntelligentVehicle::on_button_vin_set_clicked()
     bool ok;
     QString text = QInputDialog::getText(this, tr("输入车辆VIN:"),
                                          tr("VIN:"), QLineEdit::Normal,
-                                         QDir::home().dirName(), &ok);
+                                         Q_NULLPTR, &ok);
     if (ok && !text.isEmpty())
     {
         gstrvin = text.toStdString();

+ 4 - 122
src/ui/ui_ads_hmi_1px/ADCIntelligentVehicle.ui

@@ -121,80 +121,13 @@
    <property name="styleSheet">
     <string notr="true">background-color: rgb(60, 60, 60);</string>
    </property>
-   <widget class="QListWidget" name="listWidget">
-    <property name="geometry">
-     <rect>
-      <x>10</x>
-      <y>30</y>
-      <width>41</width>
-      <height>651</height>
-     </rect>
-    </property>
-    <property name="styleSheet">
-     <string notr="true">selection-background-color: rgb(59, 59, 59);</string>
-    </property>
-    <item>
-     <property name="text">
-      <string/>
-     </property>
-     <property name="font">
-      <font>
-       <family>AR PL UKai CN</family>
-       <pointsize>20</pointsize>
-      </font>
-     </property>
-     <property name="textAlignment">
-      <set>AlignCenter</set>
-     </property>
-     <property name="icon">
-      <iconset resource="ADCIntelligentVehicle.qrc">
-       <normaloff>:/ADCIntelligentVehicle/start.jpg</normaloff>:/ADCIntelligentVehicle/start.jpg</iconset>
-     </property>
-    </item>
-    <item>
-     <property name="text">
-      <string/>
-     </property>
-     <property name="font">
-      <font>
-       <family>AR PL UKai CN</family>
-       <pointsize>20</pointsize>
-      </font>
-     </property>
-     <property name="textAlignment">
-      <set>AlignCenter</set>
-     </property>
-     <property name="icon">
-      <iconset resource="ADCIntelligentVehicle.qrc">
-       <normaloff>:/ADCIntelligentVehicle/run.jpg</normaloff>:/ADCIntelligentVehicle/run.jpg</iconset>
-     </property>
-    </item>
-    <item>
-     <property name="text">
-      <string/>
-     </property>
-     <property name="font">
-      <font>
-       <family>AR PL UKai CN</family>
-       <pointsize>20</pointsize>
-      </font>
-     </property>
-     <property name="textAlignment">
-      <set>AlignCenter</set>
-     </property>
-     <property name="icon">
-      <iconset resource="ADCIntelligentVehicle.qrc">
-       <normaloff>:/ADCIntelligentVehicle/test.jpg</normaloff>:/ADCIntelligentVehicle/test.jpg</iconset>
-     </property>
-    </item>
-   </widget>
    <widget class="QStackedWidget" name="stackedWidget">
     <property name="enabled">
      <bool>true</bool>
     </property>
     <property name="geometry">
      <rect>
-      <x>50</x>
+      <x>30</x>
       <y>30</y>
       <width>1500</width>
       <height>871</height>
@@ -373,57 +306,8 @@
      </palette>
     </property>
     <property name="currentIndex">
-     <number>1</number>
+     <number>0</number>
     </property>
-    <widget class="QWidget" name="page_0">
-     <widget class="QLabel" name="label_5">
-      <property name="geometry">
-       <rect>
-        <x>150</x>
-        <y>90</y>
-        <width>541</width>
-        <height>81</height>
-       </rect>
-      </property>
-      <property name="font">
-       <font>
-        <family>AR PL UKai CN</family>
-        <pointsize>50</pointsize>
-       </font>
-      </property>
-      <property name="styleSheet">
-       <string notr="true">color: rgb(238, 238, 236);</string>
-      </property>
-      <property name="text">
-       <string>开启自动驾驶之旅</string>
-      </property>
-     </widget>
-     <widget class="QLabel" name="label_9">
-      <property name="geometry">
-       <rect>
-        <x>280</x>
-        <y>220</y>
-        <width>281</width>
-        <height>21</height>
-       </rect>
-      </property>
-      <property name="font">
-       <font>
-        <family>AR PL UKai CN</family>
-        <pointsize>15</pointsize>
-       </font>
-      </property>
-      <property name="layoutDirection">
-       <enum>Qt::LeftToRight</enum>
-      </property>
-      <property name="styleSheet">
-       <string notr="true">color: rgb(255, 255, 255);</string>
-      </property>
-      <property name="text">
-       <string>Start A Journey Of Autopilot</string>
-      </property>
-     </widget>
-    </widget>
     <widget class="QWidget" name="page_1">
      <widget class="QLabel" name="lb_current_speed_big">
       <property name="geometry">
@@ -11673,7 +11557,6 @@ p, li { white-space: pre-wrap; }
       </widget>
      </widget>
     </widget>
-    <widget class="QWidget" name="page_2"/>
    </widget>
    <widget class="QWidget" name="widget" native="true">
     <property name="geometry">
@@ -11777,8 +11660,8 @@ p, li { white-space: pre-wrap; }
     </property>
     <property name="geometry">
      <rect>
-      <x>50</x>
-      <y>890</y>
+      <x>40</x>
+      <y>900</y>
       <width>781</width>
       <height>71</height>
      </rect>
@@ -11878,7 +11761,6 @@ p, li { white-space: pre-wrap; }
      </item>
     </layout>
    </widget>
-   <zorder>listWidget</zorder>
    <zorder>widget</zorder>
    <zorder>stackedWidget</zorder>
    <zorder>verticalLayoutWidget</zorder>