Q=7Q
z@U>Kb*c_W*e)h@mUxttReXpAN-+SD;TXC(l=Glh~(9@o!0D6{+`AJrIsVtt4-QYtK>ytPa6mTh(ht+>7WV#E~Oa^oU*I*s!RV@6excH@=R+N0GeTaY+FoT
zb;-7Y(4AJyI!8vs&2
z-Da6TOF-@#ZK9y!ykvl$3+u^TSbu9$CL2xig+!>COsVIopKh0XQ{mt;w&L>thC?RR
z@U;-XJ1+ZiDjZ6^hcAmY&r5p&UxgXv#RuZ+qRs&;BN%!Ku(~H9Ivb14set|H`UmVX
VfBVHkgUbK_002ovPDHLkV1i`TirWAH
literal 0
HcmV?d00001
diff --git a/src/ChangShaTour/qss/lightblue/radiobutton_unchecked.png b/src/ChangShaTour/qss/lightblue/radiobutton_unchecked.png
new file mode 100644
index 0000000000000000000000000000000000000000..433ab0f979d47b3953f9176db4e982640f7a9713
GIT binary patch
literal 520
zcmV+j0{8uiP)bl)X+HK@^3*J2N(xywZZ)*j5Tekup^jIv0T^si2Qv
z0G#s4?>(Q++?l!Xk0rAT7njMl
zSlZ%c2jL9>%8eR5*No1`xAC{7fZgk1!>8FXu(u%0sd4t8wOQ@W1a_|m@6`LR3QcE)
zT2v-lbChh}HqMm6W6Is&i8NCLZpD~St*z+i3t;zp*w8flq0ro@mZ--SWX3>Lp`VPn
zAC7aVv+qMv6PkRQ9S2xreKrh01RCoVHmW5Qnm)~rLd`&a0l=QKLOrf57~NF$xPr^a
zvERK)J`_N)v;k^Sd2X`TlGdU!0P0P93iPrA5Usi8X%hvHs_quR@Xo?*uA;&-VVHT%
zf1(_y+(7=$R#oAdFbseiJqH*(rYi%3M?}u1z>E&S-QWpbA*5>V0TAOm1#t4wPt#24
zC!?i-{bWR%ANi!U6@M>)0LIw^f!q7xnBK!^Zcbl(B0YF%-r>NvAtmm(ZL8!Ps<3<0*J96z?8Nr~aLt
zLJQeVp=(VhyIG146M`=#KKV{MNgdL2($scsXutJ6{rKLK^a1}^WK-dCa(}|%yYQ~#
zsgD7GIFf_VsR0=e&JJ&O0$!x4l)3D4O3tH@wHPG{JfdISrFA|lwVfH~uT-pt@7is(
z5%~H0kES+w+u*DhG1iovraTNXL1_U1g>%B_DpAI@OKay#V@Dy!$2Tuu%>Mvhq^UeC
z;`fpVuMb3^j%0Yv0Jm-|3(z~IPZvccm8rhmi~K|Fl-5l$m;DB3y#o=bV;N31!2o~(
z?pTJCIAlw~SWo7%U)SjB0w_6;7;7HM@Ol&IxsrqEo8YX;DLKEK%uZH74&RMJ){>m2
z+nlX)DmhJ~fVDWn?&HYbbr>ZH4})x1SS=m~84E}PPdh81r#^;9RNv-45|kG3i0ZdW
z|8`(sQK0?-C=2JrzJS6x0fLe^l0P~mbZVW?jINS>fksz}t$YUJrYoQU8JF75lyPml
z#~Lg^m2vH|vNHocUI7PZhd0LgtJ2!}ozkbf0<%T=sxWqLoWB~JwQg2G08p_SE{z>6
zib~!t%I-F&7NEC_vYTt$D6Ac+SPkpi+Heqz^#tD@4u!GvrPf~~!9J}Ghg!eISHM~i
zkM>D?RX!`L9pme%9s<^M;pwx0byEX9u6Op|^%I|N9VgB7g((04002ovPDHLkV1ioP
B5`q8#
literal 0
HcmV?d00001
diff --git a/src/ChangShaTour/recommendwidget.cpp b/src/ChangShaTour/recommendwidget.cpp
new file mode 100644
index 0000000..35b3683
--- /dev/null
+++ b/src/ChangShaTour/recommendwidget.cpp
@@ -0,0 +1,131 @@
+#include "recommendwidget.h"
+#include "ui_recommendwidget.h"
+
+RecommendWidget::RecommendWidget(QWidget *parent) :
+ QWidget(parent),
+ ui(new Ui::RecommendWidget)
+{
+ ui->setupUi(this);
+
+ row = 8;
+ column = 4;
+ web = new WebWidget();
+ connector = new DatabaseConnector();
+ db = connector->connectToDatabase();
+ QSqlQuery query(db);
+
+ verLayout = new QVBoxLayout();
+
+ scroll = new QScrollArea();
+
+ subWidget = new QWidget();
+ subVerLayout = new QVBoxLayout();
+
+ funcLine = new QHBoxLayout();
+ lineList = (QHBoxLayout **)malloc(sizeof(QHBoxLayout *) * row);
+
+ refreshBtn = new QPushButton("刷新");
+ btnList = (QToolButton **)malloc(sizeof(QToolButton *) * row * column);
+
+ //读取数据库,获取按钮信息,初始化各List
+
+ query.exec("select * from meishi limit 32");
+ int i=0;
+ while(query.next()==true&&i<(row * column))
+ {
+ i++;
+ QVariant id = query.value("id");
+
+ QVariant detail = query.value("detail");
+
+ QVariant frontimg = query.value("frontimg");
+
+ QVariant title = query.value("title");
+ QVariant avgscore = query.value("avgscore");
+ QVariant comments = query.value("comments");
+ QVariant address = query.value("address");
+ QVariant avgprice = query.value("avgprice");
+
+ QString name = title.value();
+ QString score = QString::number(avgscore.value());
+ QString commentNum = QString::number(comments.value());
+ QString addr = address.value();
+ QString price = QString::number(avgprice.value());
+ QString text = name + "\n" + score + "分 " + commentNum + "条评论\n" + addr + "\n" + "人均" + price;
+
+ idList.append(id.value());
+ urlList.append(detail.value());
+ imgList.append(frontimg.value());
+ textList.append(text);
+ }
+
+ /*for (int i = 0; i < row; i++)
+ {
+ for (int j = 0; j downloadFileFromUrl(imgList[index], imgPath);
+ btnList[index] = setBtn(btnList[index], imgPath, textList[index]);
+ connect(btnList[index], &QToolButton::clicked, this, [=](){web->view->load(QUrl((const QString)urlList[index])); scroll->setVisible(false); web->setVisible(true);});
+ }
+ }
+
+ //安排布局
+ setLayout(verLayout);
+
+ verLayout->addWidget(scroll);
+ verLayout->addWidget(web);
+ web->setVisible(false);
+
+ subWidget->setLayout(subVerLayout);
+ subVerLayout->addLayout(funcLine);
+ for (int i = 0; i < row; i++)
+ {
+ lineList[i] = new QHBoxLayout();
+ subVerLayout->addLayout(lineList[i]);
+ }
+
+ funcLine->addWidget(refreshBtn);
+ for (int i = 0; i < row; i++)
+ {
+ for (int j = 0; j addWidget(btnList[index]);
+ }
+ }
+
+ //必选要在setWidget方法调用之前把subWidget中的layout设置好,否则显示不出来
+ scroll->setWidget(subWidget);
+
+ connect(web->rtn, &QPushButton::clicked, this, &RecommendWidget::webReturn);*/
+}
+
+QToolButton *RecommendWidget::setBtn(QToolButton *btn, const QString iconPath, const QString text)
+{
+ btn->setIcon(QIcon(iconPath));
+ btn->setText(text);
+ btn->setToolButtonStyle(Qt::ToolButtonTextBesideIcon);
+ btn->setIconSize(QSize(100,200));
+ btn->setFixedSize(500,200);
+
+ return btn;
+}
+
+
+void RecommendWidget::webReturn()
+{
+ scroll->setVisible(true);
+ web->setVisible(false);
+}
+
+RecommendWidget::~RecommendWidget()
+{
+ delete ui;
+}
diff --git a/src/ChangShaTour/recommendwidget.h b/src/ChangShaTour/recommendwidget.h
new file mode 100644
index 0000000..62b8a18
--- /dev/null
+++ b/src/ChangShaTour/recommendwidget.h
@@ -0,0 +1,65 @@
+#ifndef RECOMMENDWIDGET_H
+#define RECOMMENDWIDGET_H
+
+#include
+#include
+#include
+#include
+#include
+#include
+#include
+#include
+#include
+#include
+#include "webwidget.h"
+#include "databaseconnector.h"
+#include "imgdownloader.h"
+
+namespace Ui {
+class RecommendWidget;
+}
+
+class RecommendWidget : public QWidget
+{
+ Q_OBJECT
+
+public:
+ explicit RecommendWidget(QWidget *parent = nullptr);
+ ~RecommendWidget();
+
+ QToolButton *setBtn(QToolButton *btn, const QString iconPath, const QString text);
+ void refresh();
+ void connectWeb();
+ void webReturn();
+ void setBtnIndex();
+
+private:
+ Ui::RecommendWidget *ui;
+
+ int row;
+ int column;
+ QStringList urlList;
+ QStringList imgList;
+ QStringList textList;
+ QStringList idList;
+ WebWidget *web;
+ DatabaseConnector * connector;
+ QSqlDatabase db;
+ QString currentUrl;
+
+ QVBoxLayout *verLayout;
+ QScrollArea *scroll;
+ QWidget *subWidget;
+ QVBoxLayout *subVerLayout;
+
+ QHBoxLayout *funcLine;
+ QHBoxLayout **lineList;
+
+ QPushButton *refreshBtn;
+ QToolButton **btnList;
+
+signals:
+ void btnSignal(QToolButton *btn);
+};
+
+#endif // RECOMMENDWIDGET_H
diff --git a/src/ChangShaTour/recommendwidget.ui b/src/ChangShaTour/recommendwidget.ui
new file mode 100644
index 0000000..5d4f60d
--- /dev/null
+++ b/src/ChangShaTour/recommendwidget.ui
@@ -0,0 +1,21 @@
+
+
+
+
+ RecommendWidget
+
+
+
+ 0
+ 0
+ 400
+ 300
+
+
+
+ Form
+
+
+
+
+
diff --git a/src/ChangShaTour/resource.qrc b/src/ChangShaTour/resource.qrc
new file mode 100644
index 0000000..e84f1ba
--- /dev/null
+++ b/src/ChangShaTour/resource.qrc
@@ -0,0 +1,23 @@
+
+
+ lightblue.css
+ qss/lightblue/add_bottom.png
+ qss/lightblue/add_left.png
+ qss/lightblue/add_right.png
+ qss/lightblue/add_top.png
+ qss/lightblue/branch_close.png
+ qss/lightblue/branch_open.png
+ qss/lightblue/calendar_nextmonth.png
+ qss/lightblue/calendar_prevmonth.png
+ qss/lightblue/checkbox_checked.png
+ qss/lightblue/checkbox_checked_disable.png
+ qss/lightblue/checkbox_parcial.png
+ qss/lightblue/checkbox_parcial_disable.png
+ qss/lightblue/checkbox_unchecked.png
+ qss/lightblue/checkbox_unchecked_disable.png
+ qss/lightblue/radiobutton_checked.png
+ qss/lightblue/radiobutton_checked_disable.png
+ qss/lightblue/radiobutton_unchecked.png
+ qss/lightblue/radiobutton_unchecked_disable.png
+
+
diff --git a/src/ChangShaTour/routechoicewidget.cpp b/src/ChangShaTour/routechoicewidget.cpp
new file mode 100644
index 0000000..19f4f27
--- /dev/null
+++ b/src/ChangShaTour/routechoicewidget.cpp
@@ -0,0 +1,14 @@
+#include "routechoicewidget.h"
+#include "ui_routechoicewidget.h"
+
+RouteChoiceWidget::RouteChoiceWidget(QWidget *parent) :
+ QWidget(parent),
+ ui(new Ui::RouteChoiceWidget)
+{
+ ui->setupUi(this);
+}
+
+RouteChoiceWidget::~RouteChoiceWidget()
+{
+ delete ui;
+}
diff --git a/src/ChangShaTour/routechoicewidget.h b/src/ChangShaTour/routechoicewidget.h
new file mode 100644
index 0000000..1832cab
--- /dev/null
+++ b/src/ChangShaTour/routechoicewidget.h
@@ -0,0 +1,22 @@
+#ifndef ROUTECHOICEWIDGET_H
+#define ROUTECHOICEWIDGET_H
+
+#include
+
+namespace Ui {
+class RouteChoiceWidget;
+}
+
+class RouteChoiceWidget : public QWidget
+{
+ Q_OBJECT
+
+public:
+ explicit RouteChoiceWidget(QWidget *parent = nullptr);
+ ~RouteChoiceWidget();
+
+private:
+ Ui::RouteChoiceWidget *ui;
+};
+
+#endif // ROUTECHOICEWIDGET_H
diff --git a/src/ChangShaTour/routechoicewidget.ui b/src/ChangShaTour/routechoicewidget.ui
new file mode 100644
index 0000000..1bd9eb4
--- /dev/null
+++ b/src/ChangShaTour/routechoicewidget.ui
@@ -0,0 +1,21 @@
+
+
+
+
+ RouteChoiceWidget
+
+
+
+ 0
+ 0
+ 400
+ 300
+
+
+
+ Form
+
+
+
+
+
diff --git a/src/ChangShaTour/showplaceinfowidget.cpp b/src/ChangShaTour/showplaceinfowidget.cpp
new file mode 100644
index 0000000..35e07ce
--- /dev/null
+++ b/src/ChangShaTour/showplaceinfowidget.cpp
@@ -0,0 +1,14 @@
+#include "showplaceinfowidget.h"
+#include "ui_showplaceinfowidget.h"
+
+ShowPlaceInfoWidget::ShowPlaceInfoWidget(QWidget *parent) :
+ QWidget(parent),
+ ui(new Ui::ShowPlaceInfoWidget)
+{
+ ui->setupUi(this);
+}
+
+ShowPlaceInfoWidget::~ShowPlaceInfoWidget()
+{
+ delete ui;
+}
diff --git a/src/ChangShaTour/showplaceinfowidget.h b/src/ChangShaTour/showplaceinfowidget.h
new file mode 100644
index 0000000..9af420a
--- /dev/null
+++ b/src/ChangShaTour/showplaceinfowidget.h
@@ -0,0 +1,22 @@
+#ifndef SHOWPLACEINFOWIDGET_H
+#define SHOWPLACEINFOWIDGET_H
+
+#include
+
+namespace Ui {
+class ShowPlaceInfoWidget;
+}
+
+class ShowPlaceInfoWidget : public QWidget
+{
+ Q_OBJECT
+
+public:
+ explicit ShowPlaceInfoWidget(QWidget *parent = nullptr);
+ ~ShowPlaceInfoWidget();
+
+private:
+ Ui::ShowPlaceInfoWidget *ui;
+};
+
+#endif // SHOWPLACEINFOWIDGET_H
diff --git a/src/ChangShaTour/showplaceinfowidget.ui b/src/ChangShaTour/showplaceinfowidget.ui
new file mode 100644
index 0000000..8543e97
--- /dev/null
+++ b/src/ChangShaTour/showplaceinfowidget.ui
@@ -0,0 +1,21 @@
+
+
+
+
+ ShowPlaceInfoWidget
+
+
+
+ 0
+ 0
+ 400
+ 300
+
+
+
+ Form
+
+
+
+
+
diff --git a/src/ChangShaTour/showrouteinfowidget.cpp b/src/ChangShaTour/showrouteinfowidget.cpp
new file mode 100644
index 0000000..785960d
--- /dev/null
+++ b/src/ChangShaTour/showrouteinfowidget.cpp
@@ -0,0 +1,14 @@
+#include "showrouteinfowidget.h"
+#include "ui_showrouteinfowidget.h"
+
+ShowRouteInfoWidget::ShowRouteInfoWidget(QWidget *parent) :
+ QWidget(parent),
+ ui(new Ui::ShowRouteInfoWidget)
+{
+ ui->setupUi(this);
+}
+
+ShowRouteInfoWidget::~ShowRouteInfoWidget()
+{
+ delete ui;
+}
diff --git a/src/ChangShaTour/showrouteinfowidget.h b/src/ChangShaTour/showrouteinfowidget.h
new file mode 100644
index 0000000..aebbf53
--- /dev/null
+++ b/src/ChangShaTour/showrouteinfowidget.h
@@ -0,0 +1,22 @@
+#ifndef SHOWROUTEINFOWIDGET_H
+#define SHOWROUTEINFOWIDGET_H
+
+#include
+
+namespace Ui {
+class ShowRouteInfoWidget;
+}
+
+class ShowRouteInfoWidget : public QWidget
+{
+ Q_OBJECT
+
+public:
+ explicit ShowRouteInfoWidget(QWidget *parent = nullptr);
+ ~ShowRouteInfoWidget();
+
+private:
+ Ui::ShowRouteInfoWidget *ui;
+};
+
+#endif // SHOWROUTEINFOWIDGET_H
diff --git a/src/ChangShaTour/showrouteinfowidget.ui b/src/ChangShaTour/showrouteinfowidget.ui
new file mode 100644
index 0000000..7f295dd
--- /dev/null
+++ b/src/ChangShaTour/showrouteinfowidget.ui
@@ -0,0 +1,21 @@
+
+
+
+
+ ShowRouteInfoWidget
+
+
+
+ 0
+ 0
+ 400
+ 300
+
+
+
+ Form
+
+
+
+
+
diff --git a/src/ChangShaTour/sortwidget.cpp b/src/ChangShaTour/sortwidget.cpp
new file mode 100644
index 0000000..65687ee
--- /dev/null
+++ b/src/ChangShaTour/sortwidget.cpp
@@ -0,0 +1,22 @@
+#include "sortwidget.h"
+#include "ui_sortwidget.h"
+
+#include
+#include
+
+SortWidget::SortWidget(QWidget *parent) :
+ QWidget(parent),
+ ui(new Ui::SortWidget)
+{
+ ui->setupUi(this);
+
+ QVBoxLayout *layout = new QVBoxLayout();
+
+ setLayout(layout);
+ layout->addWidget(new QLabel("SortWidget"));
+}
+
+SortWidget::~SortWidget()
+{
+ delete ui;
+}
diff --git a/src/ChangShaTour/sortwidget.h b/src/ChangShaTour/sortwidget.h
new file mode 100644
index 0000000..92b1768
--- /dev/null
+++ b/src/ChangShaTour/sortwidget.h
@@ -0,0 +1,22 @@
+#ifndef SORTWIDGET_H
+#define SORTWIDGET_H
+
+#include
+
+namespace Ui {
+class SortWidget;
+}
+
+class SortWidget : public QWidget
+{
+ Q_OBJECT
+
+public:
+ explicit SortWidget(QWidget *parent = nullptr);
+ ~SortWidget();
+
+private:
+ Ui::SortWidget *ui;
+};
+
+#endif // SORTWIDGET_H
diff --git a/src/ChangShaTour/sortwidget.ui b/src/ChangShaTour/sortwidget.ui
new file mode 100644
index 0000000..76fe811
--- /dev/null
+++ b/src/ChangShaTour/sortwidget.ui
@@ -0,0 +1,21 @@
+
+
+
+
+ SortWidget
+
+
+
+ 0
+ 0
+ 400
+ 300
+
+
+
+ Form
+
+
+
+
+
diff --git a/src/ChangShaTour/userinfowidget.cpp b/src/ChangShaTour/userinfowidget.cpp
new file mode 100644
index 0000000..193999d
--- /dev/null
+++ b/src/ChangShaTour/userinfowidget.cpp
@@ -0,0 +1,22 @@
+#include "userinfowidget.h"
+#include "ui_userinfowidget.h"
+
+#include
+#include
+
+UserInfoWidget::UserInfoWidget(QWidget *parent) :
+ QWidget(parent),
+ ui(new Ui::UserInfoWidget)
+{
+ ui->setupUi(this);
+
+ QVBoxLayout *layout = new QVBoxLayout();
+
+ setLayout(layout);
+ layout->addWidget(new QLabel("UserInfoWidget"));
+}
+
+UserInfoWidget::~UserInfoWidget()
+{
+ delete ui;
+}
diff --git a/src/ChangShaTour/userinfowidget.h b/src/ChangShaTour/userinfowidget.h
new file mode 100644
index 0000000..390303a
--- /dev/null
+++ b/src/ChangShaTour/userinfowidget.h
@@ -0,0 +1,22 @@
+#ifndef USERINFOWIDGET_H
+#define USERINFOWIDGET_H
+
+#include
+
+namespace Ui {
+class UserInfoWidget;
+}
+
+class UserInfoWidget : public QWidget
+{
+ Q_OBJECT
+
+public:
+ explicit UserInfoWidget(QWidget *parent = nullptr);
+ ~UserInfoWidget();
+
+private:
+ Ui::UserInfoWidget *ui;
+};
+
+#endif // USERINFOWIDGET_H
diff --git a/src/ChangShaTour/userinfowidget.ui b/src/ChangShaTour/userinfowidget.ui
new file mode 100644
index 0000000..b431b8a
--- /dev/null
+++ b/src/ChangShaTour/userinfowidget.ui
@@ -0,0 +1,21 @@
+
+
+
+
+ UserInfoWidget
+
+
+
+ 0
+ 0
+ 400
+ 300
+
+
+
+ Form
+
+
+
+
+
diff --git a/src/ChangShaTour/userwidget.cpp b/src/ChangShaTour/userwidget.cpp
new file mode 100644
index 0000000..ed63113
--- /dev/null
+++ b/src/ChangShaTour/userwidget.cpp
@@ -0,0 +1,118 @@
+#include "userwidget.h"
+#include "ui_userwidget.h"
+
+UserWidget::UserWidget(QWidget *parent) :
+ QWidget(parent),
+ ui(new Ui::UserWidget)
+{
+ ui->setupUi(this);
+
+ verLayout = new QVBoxLayout();
+
+ horLayout = new QHBoxLayout();
+ userInfoBtn = new QPushButton("个人资料");
+ journyBtn = new QPushButton("行程");
+ favoriteBtn = new QPushButton("Favorite");
+ historyBtn = new QPushButton("历史记录");
+ //默认初始选择为个人资料
+ pageIndex = 0;
+ //userInfoBtn->setStyleSheet("QPushButton{background-color: rgb(20, 62, 134);color:rgb(255, 255, 255);}");
+ //journyBtn->setStyleSheet("QPushButton{color:rgb(255, 255, 255);}""QPushButton:hover{background-color: rgb(20, 62, 134);border:none;color:rgb(255, 255, 255);}");
+ //favoriteBtn->setStyleSheet("QPushButton{color:rgb(255, 255, 255);}""QPushButton:hover{background-color: rgb(20, 62, 134);border:none;color:rgb(255, 255, 255);}");
+ //historyBtn->setStyleSheet("QPushButton{color:rgb(255, 255, 255);}""QPushButton:hover{background-color: rgb(20, 62, 134);border:none;color:rgb(255, 255, 255);}");
+
+ userInfoWidget = new UserInfoWidget(this);
+ journyWidget = new JournyWidget(this);
+ favoriteWidget = new FavoriteWidget(this);
+ historyWidget = new HistoryWidget(this);
+ journyWidget->setVisible(false);
+ favoriteWidget->setVisible(false);
+ historyWidget->setVisible(false);
+
+ setLayout(verLayout);
+
+ verLayout->addLayout(horLayout);
+ verLayout->addWidget(userInfoWidget);
+ verLayout->addWidget(journyWidget);
+ verLayout->addWidget(favoriteWidget);
+ verLayout->addWidget(historyWidget);
+
+ horLayout->addWidget(userInfoBtn);
+ horLayout->addWidget(journyBtn);
+ horLayout->addWidget(favoriteBtn);
+ horLayout->addWidget(historyBtn);
+
+ connect(userInfoBtn, &QPushButton::clicked, this, &UserWidget::switchToUserInfo);
+ connect(journyBtn, &QPushButton::clicked, this, &UserWidget::switchToJourny);
+ connect(favoriteBtn, &QPushButton::clicked, this, &UserWidget::switchToFavorite);
+ connect(historyBtn, &QPushButton::clicked, this, &UserWidget::switchToHistory);
+}
+
+void UserWidget::switchToUserInfo()
+{
+ if (pageIndex != 0)
+ {
+ //userInfoBtn->setStyleSheet("QPushButton{background-color: rgb(20, 62, 134);color:rgb(255, 255, 255);}");
+ //journyBtn->setStyleSheet("QPushButton{color:rgb(255, 255, 255);}""QPushButton:hover{background-color: rgb(20, 62, 134);border:none;color:rgb(255, 255, 255);}");
+ //favoriteBtn->setStyleSheet("QPushButton{color:rgb(255, 255, 255);}""QPushButton:hover{background-color: rgb(20, 62, 134);border:none;color:rgb(255, 255, 255);}");
+ //historyBtn->setStyleSheet("QPushButton{color:rgb(255, 255, 255);}""QPushButton:hover{background-color: rgb(20, 62, 134);border:none;color:rgb(255, 255, 255);}");
+ userInfoWidget->setVisible(true);
+ journyWidget->setVisible(false);
+ favoriteWidget->setVisible(false);
+ historyWidget->setVisible(false);
+ pageIndex = 0;
+ }
+}
+
+void UserWidget::switchToJourny()
+{
+ if (pageIndex != 1)
+ {
+ //userInfoBtn->setStyleSheet("QPushButton{color:rgb(255, 255, 255);}""QPushButton:hover{background-color: rgb(20, 62, 134);border:none;color:rgb(255, 255, 255);}");
+ //journyBtn->setStyleSheet("QPushButton{background-color: rgb(20, 62, 134);color:rgb(255, 255, 255);}");
+ //favoriteBtn->setStyleSheet("QPushButton{color:rgb(255, 255, 255);}""QPushButton:hover{background-color: rgb(20, 62, 134);border:none;color:rgb(255, 255, 255);}");
+ //historyBtn->setStyleSheet("QPushButton{color:rgb(255, 255, 255);}""QPushButton:hover{background-color: rgb(20, 62, 134);border:none;color:rgb(255, 255, 255);}");
+ userInfoWidget->setVisible(false);
+ journyWidget->setVisible(true);
+ favoriteWidget->setVisible(false);
+ historyWidget->setVisible(false);
+ pageIndex = 1;
+ }
+}
+
+void UserWidget::switchToFavorite()
+{
+ if (pageIndex != 2)
+ {
+ //userInfoBtn->setStyleSheet("QPushButton{color:rgb(255, 255, 255);}""QPushButton:hover{background-color: rgb(20, 62, 134);border:none;color:rgb(255, 255, 255);}");
+ //journyBtn->setStyleSheet("QPushButton{color:rgb(255, 255, 255);}""QPushButton:hover{background-color: rgb(20, 62, 134);border:none;color:rgb(255, 255, 255);}");
+ //favoriteBtn->setStyleSheet("QPushButton{background-color: rgb(20, 62, 134);color:rgb(255, 255, 255);}");
+ //historyBtn->setStyleSheet("QPushButton{color:rgb(255, 255, 255);}""QPushButton:hover{background-color: rgb(20, 62, 134);border:none;color:rgb(255, 255, 255);}");
+ userInfoWidget->setVisible(false);
+ journyWidget->setVisible(false);
+ favoriteWidget->setVisible(true);
+ historyWidget->setVisible(false);
+ pageIndex = 2;
+ }
+}
+
+void UserWidget::switchToHistory()
+{
+ if (pageIndex != 3)
+ {
+ //userInfoBtn->setStyleSheet("QPushButton{color:rgb(255, 255, 255);}""QPushButton:hover{background-color: rgb(20, 62, 134);border:none;color:rgb(255, 255, 255);}");
+ //journyBtn->setStyleSheet("QPushButton{color:rgb(255, 255, 255);}""QPushButton:hover{background-color: rgb(20, 62, 134);border:none;color:rgb(255, 255, 255);}");
+ //favoriteBtn->setStyleSheet("QPushButton{color:rgb(255, 255, 255);}""QPushButton:hover{background-color: rgb(20, 62, 134);border:none;color:rgb(255, 255, 255);}");
+ //historyBtn->setStyleSheet("QPushButton{background-color: rgb(20, 62, 134);color:rgb(255, 255, 255);}");
+ userInfoWidget->setVisible(false);
+ journyWidget->setVisible(false);
+ favoriteWidget->setVisible(false);
+ historyWidget->setVisible(true);
+ pageIndex = 3;
+ }
+}
+
+UserWidget::~UserWidget()
+{
+ delete ui;
+}
diff --git a/src/ChangShaTour/userwidget.h b/src/ChangShaTour/userwidget.h
new file mode 100644
index 0000000..eafcdfc
--- /dev/null
+++ b/src/ChangShaTour/userwidget.h
@@ -0,0 +1,50 @@
+#ifndef USERWIDGET_H
+#define USERWIDGET_H
+
+#include
+#include
+#include
+#include
+#include "userinfowidget.h"
+#include "journywidget.h"
+#include "favoritewidget.h"
+#include "historywidget.h"
+
+namespace Ui {
+class UserWidget;
+}
+
+class UserWidget : public QWidget
+{
+ Q_OBJECT
+
+public:
+ explicit UserWidget(QWidget *parent = nullptr);
+ ~UserWidget();
+
+private:
+ Ui::UserWidget *ui;
+
+ int pageIndex;
+
+ QVBoxLayout *verLayout;
+
+ QHBoxLayout *horLayout;
+ QPushButton *userInfoBtn;
+ QPushButton *journyBtn;
+ QPushButton *favoriteBtn;
+ QPushButton *historyBtn;
+
+ UserInfoWidget *userInfoWidget;
+ JournyWidget *journyWidget;
+ FavoriteWidget *favoriteWidget;
+ HistoryWidget *historyWidget;
+
+public slots:
+ void switchToUserInfo();
+ void switchToJourny();
+ void switchToFavorite();
+ void switchToHistory();
+};
+
+#endif // USERWIDGET_H
diff --git a/src/ChangShaTour/userwidget.ui b/src/ChangShaTour/userwidget.ui
new file mode 100644
index 0000000..605c5f2
--- /dev/null
+++ b/src/ChangShaTour/userwidget.ui
@@ -0,0 +1,21 @@
+
+
+
+
+ UserWidget
+
+
+
+ 0
+ 0
+ 400
+ 300
+
+
+
+ Form
+
+
+
+
+
diff --git a/src/ChangShaTour/webwidget.cpp b/src/ChangShaTour/webwidget.cpp
new file mode 100644
index 0000000..8d0c396
--- /dev/null
+++ b/src/ChangShaTour/webwidget.cpp
@@ -0,0 +1,28 @@
+#include "webwidget.h"
+#include "ui_webwidget.h"
+
+WebWidget::WebWidget(QWidget *parent) :
+ QWidget(parent),
+ ui(new Ui::WebWidget)
+{
+ ui->setupUi(this);
+
+ verLayout = new QVBoxLayout();
+
+ horLayout = new QHBoxLayout();
+ view = new QWebEngineView();
+
+ rtn = new QPushButton("返回");
+
+ setLayout(verLayout);
+
+ verLayout->addLayout(horLayout);
+ verLayout->addWidget(view);
+
+ horLayout->addWidget(rtn);
+}
+
+WebWidget::~WebWidget()
+{
+ delete ui;
+}
diff --git a/src/ChangShaTour/webwidget.h b/src/ChangShaTour/webwidget.h
new file mode 100644
index 0000000..bf4ea72
--- /dev/null
+++ b/src/ChangShaTour/webwidget.h
@@ -0,0 +1,31 @@
+#ifndef WEBWIDGET_H
+#define WEBWIDGET_H
+
+#include
+#include
+#include
+#include
+#include
+
+namespace Ui {
+class WebWidget;
+}
+
+class WebWidget : public QWidget
+{
+ Q_OBJECT
+
+public:
+ explicit WebWidget(QWidget *parent = nullptr);
+ ~WebWidget();
+
+ QPushButton *rtn;
+ QWebEngineView *view;
+ QVBoxLayout *verLayout;
+ QHBoxLayout *horLayout;
+
+private:
+ Ui::WebWidget *ui;
+};
+
+#endif // WEBWIDGET_H
diff --git a/src/Changsha_Tour/informationwidget.ui b/src/ChangShaTour/webwidget.ui
similarity index 77%
rename from src/Changsha_Tour/informationwidget.ui
rename to src/ChangShaTour/webwidget.ui
index d4c6903..d93c0c5 100644
--- a/src/Changsha_Tour/informationwidget.ui
+++ b/src/ChangShaTour/webwidget.ui
@@ -1,21 +1,21 @@
-
-
-
-
- InformationWidget
-
-
-
- 0
- 0
- 400
- 300
-
-
-
- Form
-
-
-
-
-
+
+
+
+
+ WebWidget
+
+
+
+ 0
+ 0
+ 400
+ 300
+
+
+
+ Form
+
+
+
+
+
diff --git a/src/Changsha_Tour/Changsha_Tour.pro b/src/Changsha_Tour/Changsha_Tour.pro
deleted file mode 100644
index e98be64..0000000
--- a/src/Changsha_Tour/Changsha_Tour.pro
+++ /dev/null
@@ -1,61 +0,0 @@
-QT += core gui
-
-greaterThan(QT_MAJOR_VERSION, 4): QT += widgets
-
-CONFIG += c++11
-
-# The following define makes your compiler emit warnings if you use
-# any Qt feature that has been marked deprecated (the exact warnings
-# depend on your compiler). Please consult the documentation of the
-# deprecated API in order to know how to port your code away from it.
-DEFINES += QT_DEPRECATED_WARNINGS
-
-# You can also make your code fail to compile if it uses deprecated APIs.
-# In order to do so, uncomment the following line.
-# You can also select to disable deprecated APIs only up to a certain version of Qt.
-#DEFINES += QT_DISABLE_DEPRECATED_BEFORE=0x060000 # disables all the APIs deprecated before Qt 6.0.0
-
-SOURCES += \
- conditionwidget.cpp \
- informationwidget.cpp \
- loginwidget.cpp \
- main.cpp \
- mainwindow.cpp \
- planwidget.cpp \
- preferencewidget.cpp \
- rankwidget.cpp \
- recommandrouteswidget.cpp \
- recommandwidget.cpp \
- searchwidget.cpp \
- showroutewidget.cpp
-
-HEADERS += \
- conditionwidget.h \
- informationwidget.h \
- loginwidget.h \
- mainwindow.h \
- planwidget.h \
- preferencewidget.h \
- rankwidget.h \
- recommandrouteswidget.h \
- recommandwidget.h \
- searchwidget.h \
- showroutewidget.h
-
-FORMS += \
- conditionwidget.ui \
- informationwidget.ui \
- loginwidget.ui \
- mainwindow.ui \
- planwidget.ui \
- preferencewidget.ui \
- rankwidget.ui \
- recommandrouteswidget.ui \
- recommandwidget.ui \
- searchwidget.ui \
- showroutewidget.ui
-
-# Default rules for deployment.
-qnx: target.path = /tmp/$${TARGET}/bin
-else: unix:!android: target.path = /opt/$${TARGET}/bin
-!isEmpty(target.path): INSTALLS += target
diff --git a/src/Changsha_Tour/Changsha_Tour.pro.user b/src/Changsha_Tour/Changsha_Tour.pro.user
deleted file mode 100644
index 5b1bf7a..0000000
--- a/src/Changsha_Tour/Changsha_Tour.pro.user
+++ /dev/null
@@ -1,317 +0,0 @@
-
-
-
-
-
- EnvironmentId
- {5009ac75-b61d-4c91-8540-bc9e10b6e582}
-
-
- ProjectExplorer.Project.ActiveTarget
- 0
-
-
- ProjectExplorer.Project.EditorSettings
-
- true
- false
- true
-
- Cpp
-
- CppGlobal
-
-
-
- QmlJS
-
- QmlJSGlobal
-
-
- 2
- UTF-8
- false
- 4
- false
- 80
- true
- true
- 1
- true
- false
- 0
- true
- true
- 0
- 8
- true
- 1
- true
- true
- true
- false
-
-
-
- ProjectExplorer.Project.PluginSettings
-
-
- true
-
-
-
- ProjectExplorer.Project.Target.0
-
- Desktop Qt 5.14.2 GCC 64bit
- Desktop Qt 5.14.2 GCC 64bit
- qt.qt5.5142.gcc_64_kit
- 0
- 0
- 0
-
- /home/extra/Program/Qt5.14.2/Trip-in-Chang-sha/build-Changsha_Tour-Desktop_Qt_5_14_2_GCC_64bit-Debug
-
-
- true
- QtProjectManager.QMakeBuildStep
- true
-
- false
- false
- false
-
-
- true
- Qt4ProjectManager.MakeStep
-
- false
-
-
- false
-
- 2
- Build
- Build
- ProjectExplorer.BuildSteps.Build
-
-
-
- true
- Qt4ProjectManager.MakeStep
-
- true
- clean
-
- false
-
- 1
- Clean
- Clean
- ProjectExplorer.BuildSteps.Clean
-
- 2
- false
-
- Debug
- Qt4ProjectManager.Qt4BuildConfiguration
- 2
-
-
- /home/extra/Program/Qt5.14.2/Trip-in-Chang-sha/build-Changsha_Tour-Desktop_Qt_5_14_2_GCC_64bit-Release
-
-
- true
- QtProjectManager.QMakeBuildStep
- false
-
- false
- false
- true
-
-
- true
- Qt4ProjectManager.MakeStep
-
- false
-
-
- false
-
- 2
- Build
- Build
- ProjectExplorer.BuildSteps.Build
-
-
-
- true
- Qt4ProjectManager.MakeStep
-
- true
- clean
-
- false
-
- 1
- Clean
- Clean
- ProjectExplorer.BuildSteps.Clean
-
- 2
- false
-
- Release
- Qt4ProjectManager.Qt4BuildConfiguration
- 0
-
-
- /home/extra/Program/Qt5.14.2/Trip-in-Chang-sha/build-Changsha_Tour-Desktop_Qt_5_14_2_GCC_64bit-Profile
-
-
- true
- QtProjectManager.QMakeBuildStep
- true
-
- false
- true
- true
-
-
- true
- Qt4ProjectManager.MakeStep
-
- false
-
-
- false
-
- 2
- Build
- Build
- ProjectExplorer.BuildSteps.Build
-
-
-
- true
- Qt4ProjectManager.MakeStep
-
- true
- clean
-
- false
-
- 1
- Clean
- Clean
- ProjectExplorer.BuildSteps.Clean
-
- 2
- false
-
- Profile
- Qt4ProjectManager.Qt4BuildConfiguration
- 0
-
- 3
-
-
- 0
- Deploy
- Deploy
- ProjectExplorer.BuildSteps.Deploy
-
- 1
- ProjectExplorer.DefaultDeployConfiguration
-
- 1
-
-
- dwarf
-
- cpu-cycles
-
-
- 250
-
- -e
- cpu-cycles
- --call-graph
- dwarf,4096
- -F
- 250
-
- -F
- true
- 4096
- false
- false
- 1000
-
- true
-
- false
- false
- false
- false
- true
- 0.01
- 10
- true
- kcachegrind
- 1
- 25
-
- 1
- true
- false
- true
- valgrind
-
- 0
- 1
- 2
- 3
- 4
- 5
- 6
- 7
- 8
- 9
- 10
- 11
- 12
- 13
- 14
-
- 2
-
- Qt4ProjectManager.Qt4RunConfiguration:/home/extra/Program/Qt5.14.2/Trip-in-Chang-sha/Changsha_Tour/Changsha_Tour.pro
- /home/extra/Program/Qt5.14.2/Trip-in-Chang-sha/Changsha_Tour/Changsha_Tour.pro
-
- false
-
- false
- true
- true
- false
- false
- true
-
- /home/extra/Program/Qt5.14.2/Trip-in-Chang-sha/build-Changsha_Tour-Desktop_Qt_5_14_2_GCC_64bit-Debug
-
- 1
-
-
-
- ProjectExplorer.Project.TargetCount
- 1
-
-
- ProjectExplorer.Project.Updater.FileVersion
- 22
-
-
- Version
- 22
-
-
diff --git a/src/Changsha_Tour/informationwidget.cpp b/src/Changsha_Tour/informationwidget.cpp
deleted file mode 100644
index 22d45cb..0000000
--- a/src/Changsha_Tour/informationwidget.cpp
+++ /dev/null
@@ -1,26 +0,0 @@
-#include "informationwidget.h"
-#include "ui_informationwidget.h"
-
-InformationWidget::InformationWidget(QWidget *parent) :
- QWidget(parent),
- ui(new Ui::InformationWidget)
-{
- ui->setupUi(this);
-
- QVBoxLayout * verticalLayout = new QVBoxLayout();
- logoutButton = new QPushButton("注销");
-
- verticalLayout->addWidget(logoutButton);
-
- this->setLayout(verticalLayout);
-}
-
-InformationWidget::~InformationWidget()
-{
- delete ui;
-}
-
-QPushButton * InformationWidget::GetLogoutButton()
-{
- return logoutButton;
-}
diff --git a/src/Changsha_Tour/informationwidget.h b/src/Changsha_Tour/informationwidget.h
deleted file mode 100644
index 2e48013..0000000
--- a/src/Changsha_Tour/informationwidget.h
+++ /dev/null
@@ -1,27 +0,0 @@
-#ifndef INFORMATIONWIDGET_H
-#define INFORMATIONWIDGET_H
-
-#include
-#include
-#include
-#include
-
-namespace Ui {
-class InformationWidget;
-}
-
-class InformationWidget : public QWidget
-{
- Q_OBJECT
-
-public:
- explicit InformationWidget(QWidget *parent = nullptr);
- ~InformationWidget();
- QPushButton * GetLogoutButton();
-
-private:
- Ui::InformationWidget *ui;
- QPushButton * logoutButton;
-};
-
-#endif // INFORMATIONWIDGET_H
diff --git a/src/Changsha_Tour/main.cpp b/src/Changsha_Tour/main.cpp
deleted file mode 100644
index fd3e533..0000000
--- a/src/Changsha_Tour/main.cpp
+++ /dev/null
@@ -1,11 +0,0 @@
-#include "mainwindow.h"
-
-#include
-
-int main(int argc, char *argv[])
-{
- QApplication a(argc, argv);
- MainWindow w;
- w.show();
- return a.exec();
-}
diff --git a/src/Changsha_Tour/mainwindow.cpp b/src/Changsha_Tour/mainwindow.cpp
deleted file mode 100644
index 4dd320a..0000000
--- a/src/Changsha_Tour/mainwindow.cpp
+++ /dev/null
@@ -1,270 +0,0 @@
-#include "mainwindow.h"
-#include "ui_mainwindow.h"
-#include "recommandwidget.h"
-#include "rankwidget.h"
-#include "searchwidget.h"
-#include "planwidget.h"
-
-MainWindow::MainWindow(QWidget *parent)
- : QMainWindow(parent)
- , ui(new Ui::MainWindow)
-{
- ui->setupUi(this);
- setWindowTitle("长沙游");
-
- loginInterface = new LoginWidget(this);
- centralWidget = GetCentralWidget();
-
- setCentralWidget(loginInterface);
-
- connect(loginInterface->GetLoginButton(), &QPushButton::clicked, this, &MainWindow::SwitchCentralInterface);
-}
-
-MainWindow::~MainWindow()
-{
- delete ui;
-}
-
-QWidget * MainWindow::GetCentralWidget()
-{
- centralWidget = new QWidget(this);
- verticalLayout = new QVBoxLayout();
- horizontalLayout = new QHBoxLayout();
-
- /*在horizontalLayout添加首页按键*/
- homeButton = new QPushButton("首页");
- homeButton->setStyleSheet("QPushButton{background-color: rgb(20, 62, 134);color:rgb(255, 255, 255);}");
- //设置按键样式:默认高亮
- horizontalLayout->addWidget(homeButton);
-
- /*在horizontalLayout添加个人主页按键*/
- userButton = new QPushButton("个人主页");
- userButton->setStyleSheet("QPushButton{color:rgb(255, 255, 255);}""QPushButton:hover{background-color: rgb(20, 62, 134);border:none;color:rgb(255, 255, 255);}");
- //设置按键样式:光标悬停时高亮
- horizontalLayout->addWidget(userButton);
-
- /*在horizontalLayout添加搜索框和搜索按键*/
- findLine = new QLineEdit();
- horizontalLayout->addWidget(findLine);
-
- findButton = new QPushButton("搜索");
- findButton->setStyleSheet("QPushButton{color:rgb(255, 255, 255);}""QPushButton:hover{background-color: rgb(20, 62, 134);border:none;color:rgb(255, 255, 255);}");
- horizontalLayout->addWidget(findButton);
-
- homeSubWidget = GetHomeSubWidget(); //初始化首页
- userSubWidget = GetUserSubWidget(); //初始化个人主页
-
- verticalLayout->addLayout(horizontalLayout);
- verticalLayout->addWidget(homeSubWidget);
- verticalLayout->addWidget(userSubWidget);
- userSubWidget->setVisible(false);
- centralWidget->setLayout(verticalLayout);
-
- inHomePage = true; //默认显示首页界面
-
- connect(homeButton, &QPushButton::clicked, this, &MainWindow::SwitchHomeInterface);
- connect(userButton, &QPushButton::clicked, this, &MainWindow::SwitchUserInterface);
-
- return centralWidget;
-}
-
-QWidget * MainWindow::GetHomeSubWidget()
-{
- QWidget * subWidget = new QWidget(centralWidget);
- QHBoxLayout * subHorizontalLayout = new QHBoxLayout();
- homeSubVerticalLayout = new QVBoxLayout();
-
- recommandButton = new QPushButton("猜你喜欢");
- recommandButton->setStyleSheet("QPushButton{background-color: rgb(20, 62, 134);color:rgb(255, 255, 255);}");
- subHorizontalLayout->addWidget(recommandButton);
-
- rankButton = new QPushButton("热门榜单");
- rankButton->setStyleSheet("QPushButton{color:rgb(255, 255, 255);}""QPushButton:hover{background-color: rgb(20, 62, 134);border:none;color:rgb(255, 255, 255);}");
- subHorizontalLayout->addWidget(rankButton);
-
- searchButton = new QPushButton("分类检索");
- searchButton->setStyleSheet("QPushButton{color:rgb(255, 255, 255);}""QPushButton:hover{background-color: rgb(20, 62, 134);border:none;color:rgb(255, 255, 255);}");
- subHorizontalLayout->addWidget(searchButton);
-
- planButton = new QPushButton("方案规划");
- planButton->setStyleSheet("QPushButton{color:rgb(255, 255, 255);}""QPushButton:hover{background-color: rgb(20, 62, 134);border:none;color:rgb(255, 255, 255);}");
- subHorizontalLayout->addWidget(planButton);
-
- recommandInterface = new RecommandWidget();
- rankInterface = new RankWidget();
- searchInterface = new SearchWidget();
- planInterface = new PlanWidget();
-
- homeSubVerticalLayout->addLayout(subHorizontalLayout);
- homeSubVerticalLayout->addWidget(recommandInterface);
- homeSubVerticalLayout->addWidget(rankInterface);
- rankInterface->setVisible(false);
- homeSubVerticalLayout->addWidget(searchInterface);
- searchInterface->setVisible(false);
- homeSubVerticalLayout->addWidget(planInterface);
- planInterface->setVisible(false);
- subWidget->setLayout(homeSubVerticalLayout);
-
- homeIndex = 0; //首页显示猜你喜欢界面
-
- connect(recommandButton, &QPushButton::clicked, this, &MainWindow::SwitchRecommandInterface);
- connect(rankButton, &QPushButton::clicked, this, &MainWindow::SwitchRankInterface);
- connect(searchButton, &QPushButton::clicked, this, &MainWindow::SwitchSearchInterface);
- connect(planButton, &QPushButton::clicked, this, &MainWindow::SwitchPlanInterface);
-
- return subWidget;
-}
-
-QWidget * MainWindow::GetUserSubWidget()
-{
- QWidget * subWidget = new QWidget(centralWidget);
- QHBoxLayout * subHorizontalLayout = new QHBoxLayout();
- userSubVerticalLayout = new QVBoxLayout();
-
- informationButton = new QPushButton("个人资料");
- informationButton->setStyleSheet("QPushButton{background-color: rgb(20, 62, 134);color:rgb(255, 255, 255);}");
- subHorizontalLayout->addWidget(informationButton);
-
- favoriteButton = new QPushButton("收藏夹");
- favoriteButton->setStyleSheet("QPushButton{color:rgb(255, 255, 255);}""QPushButton:hover{background-color: rgb(20, 62, 134);border:none;color:rgb(255, 255, 255);}");
- subHorizontalLayout->addWidget(favoriteButton);
-
- informationInterface = new InformationWidget();
-
- userSubVerticalLayout->addLayout(subHorizontalLayout);
- userSubVerticalLayout->addWidget(informationInterface);
- subWidget->setLayout(userSubVerticalLayout);
-
- userIndex = 0; //个人主页显示个人资料界面
-
- connect(informationButton, &QPushButton::clicked, this, &MainWindow::SwitchInformationInterface);
- connect(favoriteButton, &QPushButton::clicked, this, &MainWindow::SwitchFavoriteInterface);
- connect(informationInterface->GetLogoutButton(), &QPushButton::clicked, this, &MainWindow::SwitchLoginInterface);
-
- return subWidget;
-}
-
-void MainWindow::SwitchLoginInterface()
-{
- setCentralWidget(loginInterface);
- centralWidget = GetCentralWidget();
-}
-
-void MainWindow::SwitchCentralInterface()
-{
- setCentralWidget(centralWidget);
- loginInterface = new LoginWidget();
- connect(loginInterface->GetLoginButton(), &QPushButton::clicked, this, &MainWindow::SwitchCentralInterface);
-}
-
-void MainWindow::SwitchHomeInterface()
-{
- if ( !inHomePage )
- {
- homeButton->setStyleSheet("QPushButton{background-color: rgb(20, 62, 134);color:rgb(255, 255, 255);}");
- userButton->setStyleSheet("QPushButton{color:rgb(255, 255, 255);}""QPushButton:hover{background-color: rgb(20, 62, 134);border:none;color:rgb(255, 255, 255);}");
- userSubWidget->setVisible(false);
- homeSubWidget->setVisible(true);
- }
- inHomePage = true;
-}
-
-void MainWindow::SwitchUserInterface()
-{
- if ( inHomePage )
- {
- userButton->setStyleSheet("QPushButton{background-color: rgb(20, 62, 134);color:rgb(255, 255, 255);}");
- homeButton->setStyleSheet("QPushButton{color:rgb(255, 255, 255);}""QPushButton:hover{background-color: rgb(20, 62, 134);border:none;color:rgb(255, 255, 255);}");
- homeSubWidget->setVisible(false);
- userSubWidget->setVisible(true);
- }
- inHomePage = false;
-}
-
-void MainWindow::SwitchRecommandInterface()
-{
- if ( homeIndex != 0 )
- {
- recommandButton->setStyleSheet("QPushButton{background-color: rgb(20, 62, 134);color:rgb(255, 255, 255);}");
- rankButton->setStyleSheet("QPushButton{color:rgb(255, 255, 255);}""QPushButton:hover{background-color: rgb(20, 62, 134);border:none;color:rgb(255, 255, 255);}""QPushButton:checked{background-color: rgb(20, 62, 134);border:none;color:rgb(255, 255, 255);}");
- searchButton->setStyleSheet("QPushButton{color:rgb(255, 255, 255);}""QPushButton:hover{background-color: rgb(20, 62, 134);border:none;color:rgb(255, 255, 255);}""QPushButton:checked{background-color: rgb(20, 62, 134);border:none;color:rgb(255, 255, 255);}");
- planButton->setStyleSheet("QPushButton{color:rgb(255, 255, 255);}""QPushButton:hover{background-color: rgb(20, 62, 134);border:none;color:rgb(255, 255, 255);}""QPushButton:checked{background-color: rgb(20, 62, 134);border:none;color:rgb(255, 255, 255);}");
-
- rankInterface->setVisible(false);
- searchInterface->setVisible(false);
- planInterface->setVisible(false);
- recommandInterface->setVisible(true);
- }
- homeIndex = 0;
-}
-
-void MainWindow::SwitchRankInterface()
-{
- if ( homeIndex != 1 )
- {
- rankButton->setStyleSheet("QPushButton{background-color: rgb(20, 62, 134);color:rgb(255, 255, 255);}");
- recommandButton->setStyleSheet("QPushButton{color:rgb(255, 255, 255);}""QPushButton:hover{background-color: rgb(20, 62, 134);border:none;color:rgb(255, 255, 255);}""QPushButton:checked{background-color: rgb(20, 62, 134);border:none;color:rgb(255, 255, 255);}");
- searchButton->setStyleSheet("QPushButton{color:rgb(255, 255, 255);}""QPushButton:hover{background-color: rgb(20, 62, 134);border:none;color:rgb(255, 255, 255);}""QPushButton:checked{background-color: rgb(20, 62, 134);border:none;color:rgb(255, 255, 255);}");
- planButton->setStyleSheet("QPushButton{color:rgb(255, 255, 255);}""QPushButton:hover{background-color: rgb(20, 62, 134);border:none;color:rgb(255, 255, 255);}""QPushButton:checked{background-color: rgb(20, 62, 134);border:none;color:rgb(255, 255, 255);}");
-
- rankInterface->setVisible(true);
- searchInterface->setVisible(false);
- planInterface->setVisible(false);
- recommandInterface->setVisible(false);
- }
- homeIndex = 1;
-}
-
-void MainWindow::SwitchSearchInterface()
-{
- if ( homeIndex != 2 )
- {
- searchButton->setStyleSheet("QPushButton{background-color: rgb(20, 62, 134);color:rgb(255, 255, 255);}");
- rankButton->setStyleSheet("QPushButton{color:rgb(255, 255, 255);}""QPushButton:hover{background-color: rgb(20, 62, 134);border:none;color:rgb(255, 255, 255);}""QPushButton:checked{background-color: rgb(20, 62, 134);border:none;color:rgb(255, 255, 255);}");
- recommandButton->setStyleSheet("QPushButton{color:rgb(255, 255, 255);}""QPushButton:hover{background-color: rgb(20, 62, 134);border:none;color:rgb(255, 255, 255);}""QPushButton:checked{background-color: rgb(20, 62, 134);border:none;color:rgb(255, 255, 255);}");
- planButton->setStyleSheet("QPushButton{color:rgb(255, 255, 255);}""QPushButton:hover{background-color: rgb(20, 62, 134);border:none;color:rgb(255, 255, 255);}""QPushButton:checked{background-color: rgb(20, 62, 134);border:none;color:rgb(255, 255, 255);}");
-
- rankInterface->setVisible(false);
- searchInterface->setVisible(true);
- planInterface->setVisible(false);
- recommandInterface->setVisible(false);
- }
- homeIndex = 2;
-}
-
-void MainWindow::SwitchPlanInterface()
-{
- if ( homeIndex != 3 )
- {
- planButton->setStyleSheet("QPushButton{background-color: rgb(20, 62, 134);color:rgb(255, 255, 255);}");
- rankButton->setStyleSheet("QPushButton{color:rgb(255, 255, 255);}""QPushButton:hover{background-color: rgb(20, 62, 134);border:none;color:rgb(255, 255, 255);}""QPushButton:checked{background-color: rgb(20, 62, 134);border:none;color:rgb(255, 255, 255);}");
- searchButton->setStyleSheet("QPushButton{color:rgb(255, 255, 255);}""QPushButton:hover{background-color: rgb(20, 62, 134);border:none;color:rgb(255, 255, 255);}""QPushButton:checked{background-color: rgb(20, 62, 134);border:none;color:rgb(255, 255, 255);}");
- recommandButton->setStyleSheet("QPushButton{color:rgb(255, 255, 255);}""QPushButton:hover{background-color: rgb(20, 62, 134);border:none;color:rgb(255, 255, 255);}""QPushButton:checked{background-color: rgb(20, 62, 134);border:none;color:rgb(255, 255, 255);}");
-
- rankInterface->setVisible(false);
- searchInterface->setVisible(false);
- planInterface->setVisible(true);
- recommandInterface->setVisible(false);
- }
- homeIndex = 3;
-}
-
-void MainWindow::SwitchInformationInterface()
-{
- if ( userIndex != 0 )
- {
- informationButton->setStyleSheet("QPushButton{background-color: rgb(20, 62, 134);color:rgb(255, 255, 255);}");
- favoriteButton->setStyleSheet("QPushButton{color:rgb(255, 255, 255);}""QPushButton:hover{background-color: rgb(20, 62, 134);border:none;color:rgb(255, 255, 255);}""QPushButton:checked{background-color: rgb(20, 62, 134);border:none;color:rgb(255, 255, 255);}");
- }
- userIndex = 0;
-}
-
-void MainWindow::SwitchFavoriteInterface()
-{
- if ( userIndex != 1 )
- {
- favoriteButton->setStyleSheet("QPushButton{background-color: rgb(20, 62, 134);color:rgb(255, 255, 255);}");
- informationButton->setStyleSheet("QPushButton{color:rgb(255, 255, 255);}""QPushButton:hover{background-color: rgb(20, 62, 134);border:none;color:rgb(255, 255, 255);}""QPushButton:checked{background-color: rgb(20, 62, 134);border:none;color:rgb(255, 255, 255);}");
- }
- userIndex = 1;
-}
diff --git a/src/Changsha_Tour/mainwindow.h b/src/Changsha_Tour/mainwindow.h
deleted file mode 100644
index c9caa5b..0000000
--- a/src/Changsha_Tour/mainwindow.h
+++ /dev/null
@@ -1,82 +0,0 @@
-#ifndef MAINWINDOW_H
-#define MAINWINDOW_H
-
-#include
-#include
-#include
-#include
-#include
-#include "loginwidget.h"
-#include "recommandwidget.h"
-#include "rankwidget.h"
-#include "searchwidget.h"
-#include "planwidget.h"
-#include "informationwidget.h"
-
-QT_BEGIN_NAMESPACE
-namespace Ui { class MainWindow; }
-QT_END_NAMESPACE
-
-class MainWindow : public QMainWindow
-{
- Q_OBJECT
-
-public:
- MainWindow(QWidget *parent = nullptr);
- ~MainWindow();
- QWidget * GetCentralWidget();
- QWidget * GetHomeSubWidget();
- QWidget * GetUserSubWidget();
-
-private:
- Ui::MainWindow *ui;
-
- bool inHomePage; //首页是否正在被显示
- int homeIndex; //首页正在显示的窗口部件索引 0-猜你喜欢 1-热门榜单 2-分类检索 3-方案规划
- int userIndex; //个人主页正在显示的窗口部件索引 0-个人资料 1-收藏夹
-
- QWidget * centralWidget;
- QVBoxLayout * verticalLayout;
- QHBoxLayout * horizontalLayout;
-
- LoginWidget * loginInterface;
-
- QPushButton * homeButton;
- QPushButton * userButton;
- QLineEdit * findLine;
- QPushButton * findButton;
-
- QWidget * homeSubWidget;
- QWidget * userSubWidget;
- QVBoxLayout * homeSubVerticalLayout;
- QVBoxLayout * userSubVerticalLayout;
-
- QPushButton * recommandButton;
- QPushButton * rankButton;
- QPushButton * searchButton;
- QPushButton * planButton;
- QTableWidget * table;
-
- RecommandWidget * recommandInterface;
- RankWidget * rankInterface;
- SearchWidget * searchInterface;
- PlanWidget * planInterface;
-
- QPushButton * informationButton;
- QPushButton * favoriteButton;
-
- InformationWidget * informationInterface;
-
-private slots:
- void SwitchLoginInterface(); //切换到登陆界面
- void SwitchCentralInterface(); //切换到中心界面
- void SwitchHomeInterface(); //切换到首页
- void SwitchUserInterface(); //切换到个人主页
- void SwitchRecommandInterface(); //将首页中子界面切换到猜你喜欢界面
- void SwitchRankInterface(); //将首页中子界面切换到热门榜单界面
- void SwitchSearchInterface(); //将首页中子界面切换到分类检索界面
- void SwitchPlanInterface(); //将首页中子界面切换到方案规划界面
- void SwitchInformationInterface(); //将个人主页中子界面切换到个人资料界面
- void SwitchFavoriteInterface(); //将个人主页中子界面切换到收藏夹界面
-};
-#endif // MAINWINDOW_H
diff --git a/src/Changsha_Tour/planwidget.cpp b/src/Changsha_Tour/planwidget.cpp
deleted file mode 100644
index ea98d0e..0000000
--- a/src/Changsha_Tour/planwidget.cpp
+++ /dev/null
@@ -1,179 +0,0 @@
-#include "planwidget.h"
-#include "ui_planwidget.h"
-
-PlanWidget::PlanWidget(QWidget *parent) :
- QWidget(parent),
- ui(new Ui::PlanWidget)
-{
- ui->setupUi(this);
-
- verticalLayout = new QVBoxLayout();
- horizontalLayout = new QHBoxLayout();
-
- backButton = new QPushButton("返回");
- nextButton = new QPushButton("确认");
- favoriteButton = new QPushButton("收藏");
-
- horizontalLayout->addWidget(backButton);
- horizontalLayout->addStretch(5);
- backButton->setVisible(false);
- horizontalLayout->addWidget(favoriteButton);
- favoriteButton->setVisible(false);
- horizontalLayout->addWidget(nextButton);
- nextButton->setVisible(false);
-
- choiceInterface = GetChoiceWidget();
- conditionInterface = new ConditionWidget();
- preferenceInterface = new PreferenceWidget();
- recommandRoutesInterface = new RecommandRoutesWidget();
- showRouteInterface = new ShowRouteWidget();
-
- /*默认显示功能选择界面*/
- verticalLayout->addLayout(horizontalLayout);
- verticalLayout->addWidget(choiceInterface);
- verticalLayout->addWidget(conditionInterface);
- conditionInterface->setVisible(false);
- verticalLayout->addWidget(preferenceInterface);
- preferenceInterface->setVisible(false);
- verticalLayout->addWidget(recommandRoutesInterface);
- recommandRoutesInterface->setVisible(false);
- verticalLayout->addWidget(showRouteInterface);
- showRouteInterface->setVisible(false);
- interfaceIndex = 0;
-
- this->setLayout(verticalLayout);
-
- connect(recommandRouteButton, &QPushButton::clicked, this, &PlanWidget::SwitchConditionInterface);
-}
-
-PlanWidget::~PlanWidget()
-{
- delete ui;
-}
-
-QWidget * PlanWidget::GetChoiceWidget()
-{
- QWidget * widget = new QWidget(this);
- QVBoxLayout * verticalLayout = new QVBoxLayout();
-
- recommandRouteButton = new QPushButton("推荐方案");
- customizeRouteButton = new QPushButton("定制方案");
- verticalLayout->addWidget(recommandRouteButton);
- verticalLayout->addWidget(customizeRouteButton);
-
- widget->setLayout(verticalLayout);
-
- return widget;
-}
-
-void PlanWidget::SwitchChoiceInterface()
-{
- if ( interfaceIndex == 4 )
- {
- showRouteInterface->deleteLater();
- showRouteInterface = new ShowRouteWidget();
- verticalLayout->addWidget(showRouteInterface);
- }
-
- conditionInterface->deleteLater();
- conditionInterface = new ConditionWidget();
- verticalLayout->addWidget(conditionInterface);
-
- conditionInterface->setVisible(false);
- choiceInterface->setVisible(true);
- backButton->setVisible(false);
- favoriteButton->setVisible(false);
- nextButton->setVisible(false);
-
- interfaceIndex = 0;
-
- disconnect(nextButton, nullptr, nullptr, nullptr);
- connect(nextButton, &QPushButton::clicked, this, &PlanWidget::SwitchConditionInterface);
-}
-
-void PlanWidget::SwitchConditionInterface()
-{
- /*若后退至此界面则刷新下一个页面*/
- if ( interfaceIndex == 2 )
- {
- preferenceInterface->deleteLater();
- preferenceInterface = new PreferenceWidget();
- verticalLayout->addWidget(preferenceInterface);
- }
-
- choiceInterface->setVisible(false);
- conditionInterface->setVisible(true);
- preferenceInterface->setVisible(false);
- backButton->setVisible(true);
- nextButton->setVisible(true);
-
- interfaceIndex = 1;
-
- disconnect(backButton, nullptr, nullptr, nullptr);
- disconnect(nextButton, nullptr, nullptr, nullptr);
- connect(backButton, &QPushButton::clicked, this, &PlanWidget::SwitchChoiceInterface);
- connect(nextButton, &QPushButton::clicked, this, &PlanWidget::SwitchPreferenceInterface);
-}
-
-void PlanWidget::SwitchPreferenceInterface()
-{
- if ( interfaceIndex == 3 )
- {
- recommandRoutesInterface->deleteLater();
- recommandRoutesInterface = new RecommandRoutesWidget();
- verticalLayout->addWidget(recommandRoutesInterface);
- }
-
- conditionInterface->setVisible(false);
- preferenceInterface->setVisible(true);
- recommandRoutesInterface->setVisible(false);
- backButton->setVisible(true);
- nextButton->setVisible(true);
-
- interfaceIndex = 2;
-
- disconnect(backButton, nullptr, nullptr, nullptr);
- disconnect(nextButton, nullptr, nullptr, nullptr);
- connect(backButton, &QPushButton::clicked, this, &PlanWidget::SwitchConditionInterface);
- connect(nextButton, &QPushButton::clicked, this, &PlanWidget::SwitchRecommandRoutesInterface);
-}
-
-void PlanWidget::SwitchRecommandRoutesInterface()
-{
- if ( interfaceIndex == 4 )
- {
- showRouteInterface->deleteLater();
- showRouteInterface = new ShowRouteWidget();
- verticalLayout->addWidget(showRouteInterface);
- }
-
- preferenceInterface->setVisible(false);
- recommandRoutesInterface->setVisible(true);
- showRouteInterface->setVisible(false);
- backButton->setVisible(true);
- favoriteButton->setVisible(false);
- nextButton->setVisible(true);
-
- interfaceIndex = 3;
-
- disconnect(backButton, nullptr, nullptr, nullptr);
- disconnect(nextButton, nullptr, nullptr, nullptr);
- connect(backButton, &QPushButton::clicked, this, &PlanWidget::SwitchPreferenceInterface);
- connect(nextButton, &QPushButton::clicked, this, &PlanWidget::SwitchShowRouteInterface);
-}
-
-void PlanWidget::SwitchShowRouteInterface()
-{
- recommandRoutesInterface->setVisible(false);
- showRouteInterface->setVisible(true);
- backButton->setVisible(true);
- favoriteButton->setVisible(true);
- nextButton->setVisible(true);
-
- interfaceIndex = 4;
-
- disconnect(backButton, nullptr, nullptr, nullptr);
- disconnect(nextButton, nullptr, nullptr, nullptr);
- connect(backButton, &QPushButton::clicked, this, &PlanWidget::SwitchRecommandRoutesInterface);
- connect(nextButton, &QPushButton::clicked, this, &PlanWidget::SwitchChoiceInterface);
-}
diff --git a/src/Changsha_Tour/planwidget.h b/src/Changsha_Tour/planwidget.h
deleted file mode 100644
index 9d14906..0000000
--- a/src/Changsha_Tour/planwidget.h
+++ /dev/null
@@ -1,61 +0,0 @@
-#ifndef PLANWIDGET_H
-#define PLANWIDGET_H
-
-#include
-#include
-#include
-#include
-#include
-#include
-#include
-#include "conditionwidget.h"
-#include "preferencewidget.h"
-#include "recommandrouteswidget.h"
-#include "showroutewidget.h"
-
-namespace Ui {
-class PlanWidget;
-}
-
-class PlanWidget : public QWidget
-{
- Q_OBJECT
-
-public:
- explicit PlanWidget(QWidget *parent = nullptr);
- ~PlanWidget();
-
- QWidget * GetChoiceWidget();
-
-private:
- Ui::PlanWidget *ui;
- int interfaceIndex; //界面索引 0-选择界面 1-条件界面 2-偏好界面 3-推荐界面 4-显示界面
- QVBoxLayout * verticalLayout;
- QHBoxLayout * horizontalLayout;
-
- QPushButton * backButton;
- QPushButton * nextButton;
- QPushButton * favoriteButton;
-
- QWidget * choiceInterface;
-
- QPushButton * recommandRouteButton;
- QPushButton * customizeRouteButton;
-
- ConditionWidget * conditionInterface;
-
- PreferenceWidget * preferenceInterface;
-
- RecommandRoutesWidget * recommandRoutesInterface;
-
- ShowRouteWidget * showRouteInterface;
-
-private slots:
- void SwitchChoiceInterface();
- void SwitchConditionInterface();
- void SwitchPreferenceInterface();
- void SwitchRecommandRoutesInterface();
- void SwitchShowRouteInterface();
-};
-
-#endif // PLANWIDGET_H
diff --git a/src/Changsha_Tour/rankwidget.cpp b/src/Changsha_Tour/rankwidget.cpp
deleted file mode 100644
index 5048d25..0000000
--- a/src/Changsha_Tour/rankwidget.cpp
+++ /dev/null
@@ -1,20 +0,0 @@
-#include "rankwidget.h"
-#include "ui_rankwidget.h"
-
-RankWidget::RankWidget(QWidget *parent) :
- QWidget(parent),
- ui(new Ui::RankWidget)
-{
- ui->setupUi(this);
-
- verticalLayout = new QVBoxLayout();
-
- QTableWidget * table = new QTableWidget();
- verticalLayout->addWidget(table);
- this->setLayout(verticalLayout);
-}
-
-RankWidget::~RankWidget()
-{
- delete ui;
-}
diff --git a/src/Changsha_Tour/rankwidget.h b/src/Changsha_Tour/rankwidget.h
deleted file mode 100644
index 76fc3cc..0000000
--- a/src/Changsha_Tour/rankwidget.h
+++ /dev/null
@@ -1,25 +0,0 @@
-#ifndef RANKWIDGET_H
-#define RANKWIDGET_H
-
-#include
-#include
-#include
-
-namespace Ui {
-class RankWidget;
-}
-
-class RankWidget : public QWidget
-{
- Q_OBJECT
-
-public:
- explicit RankWidget(QWidget *parent = nullptr);
- ~RankWidget();
-
-private:
- Ui::RankWidget *ui;
- QVBoxLayout * verticalLayout;
-};
-
-#endif // RANKWIDGET_H
diff --git a/src/Changsha_Tour/recommandrouteswidget.cpp b/src/Changsha_Tour/recommandrouteswidget.cpp
deleted file mode 100644
index 12c3937..0000000
--- a/src/Changsha_Tour/recommandrouteswidget.cpp
+++ /dev/null
@@ -1,14 +0,0 @@
-#include "recommandrouteswidget.h"
-#include "ui_recommandrouteswidget.h"
-
-RecommandRoutesWidget::RecommandRoutesWidget(QWidget *parent) :
- QWidget(parent),
- ui(new Ui::RecommandRoutesWidget)
-{
- ui->setupUi(this);
-}
-
-RecommandRoutesWidget::~RecommandRoutesWidget()
-{
- delete ui;
-}
diff --git a/src/Changsha_Tour/recommandrouteswidget.h b/src/Changsha_Tour/recommandrouteswidget.h
deleted file mode 100644
index f9fef45..0000000
--- a/src/Changsha_Tour/recommandrouteswidget.h
+++ /dev/null
@@ -1,24 +0,0 @@
-#ifndef RECOMMANDROUTESWIDGET_H
-#define RECOMMANDROUTESWIDGET_H
-
-#include
-#include
-
-namespace Ui {
-class RecommandRoutesWidget;
-}
-
-class RecommandRoutesWidget : public QWidget
-{
- Q_OBJECT
-
-public:
- explicit RecommandRoutesWidget(QWidget *parent = nullptr);
- ~RecommandRoutesWidget();
-
-private:
- Ui::RecommandRoutesWidget *ui;
- QVBoxLayout * verticalLayout;
-};
-
-#endif // RECOMMANDROUTESWIDGET_H
diff --git a/src/Changsha_Tour/recommandwidget.cpp b/src/Changsha_Tour/recommandwidget.cpp
deleted file mode 100644
index 8eea9a5..0000000
--- a/src/Changsha_Tour/recommandwidget.cpp
+++ /dev/null
@@ -1,14 +0,0 @@
-#include "recommandwidget.h"
-#include "ui_recommandwidget.h"
-
-RecommandWidget::RecommandWidget(QWidget *parent) :
- QWidget(parent),
- ui(new Ui::RecommandWidget)
-{
- ui->setupUi(this);
-}
-
-RecommandWidget::~RecommandWidget()
-{
- delete ui;
-}
diff --git a/src/Changsha_Tour/recommandwidget.h b/src/Changsha_Tour/recommandwidget.h
deleted file mode 100644
index 22d46e3..0000000
--- a/src/Changsha_Tour/recommandwidget.h
+++ /dev/null
@@ -1,25 +0,0 @@
-#ifndef RECOMMANDWIDGET_H
-#define RECOMMANDWIDGET_H
-
-#include
-#include
-#include
-
-namespace Ui {
-class RecommandWidget;
-}
-
-class RecommandWidget : public QWidget
-{
- Q_OBJECT
-
-public:
- explicit RecommandWidget(QWidget *parent = nullptr);
- ~RecommandWidget();
-
-private:
- Ui::RecommandWidget *ui;
- QVBoxLayout * verticalLayout;
-};
-
-#endif // RECOMMANDWIDGET_H
diff --git a/src/Changsha_Tour/searchwidget.cpp b/src/Changsha_Tour/searchwidget.cpp
deleted file mode 100644
index ebf8b54..0000000
--- a/src/Changsha_Tour/searchwidget.cpp
+++ /dev/null
@@ -1,20 +0,0 @@
-#include "searchwidget.h"
-#include "ui_searchwidget.h"
-
-SearchWidget::SearchWidget(QWidget *parent) :
- QWidget(parent),
- ui(new Ui::SearchWidget)
-{
- ui->setupUi(this);
-
- verticalLayout = new QVBoxLayout();
-
- QTableWidget * table = new QTableWidget();
- verticalLayout->addWidget(table);
- this->setLayout(verticalLayout);
-}
-
-SearchWidget::~SearchWidget()
-{
- delete ui;
-}
diff --git a/src/Changsha_Tour/searchwidget.h b/src/Changsha_Tour/searchwidget.h
deleted file mode 100644
index 900c2c1..0000000
--- a/src/Changsha_Tour/searchwidget.h
+++ /dev/null
@@ -1,25 +0,0 @@
-#ifndef SEARCHWIDGET_H
-#define SEARCHWIDGET_H
-
-#include
-#include
-#include
-
-namespace Ui {
-class SearchWidget;
-}
-
-class SearchWidget : public QWidget
-{
- Q_OBJECT
-
-public:
- explicit SearchWidget(QWidget *parent = nullptr);
- ~SearchWidget();
-
-private:
- Ui::SearchWidget *ui;
- QVBoxLayout * verticalLayout;
-};
-
-#endif // SEARCHWIDGET_H
diff --git a/src/Changsha_Tour/showroutewidget.cpp b/src/Changsha_Tour/showroutewidget.cpp
deleted file mode 100644
index 6454010..0000000
--- a/src/Changsha_Tour/showroutewidget.cpp
+++ /dev/null
@@ -1,14 +0,0 @@
-#include "showroutewidget.h"
-#include "ui_showroutewidget.h"
-
-ShowRouteWidget::ShowRouteWidget(QWidget *parent) :
- QWidget(parent),
- ui(new Ui::ShowRouteWidget)
-{
- ui->setupUi(this);
-}
-
-ShowRouteWidget::~ShowRouteWidget()
-{
- delete ui;
-}
diff --git a/src/Changsha_Tour/showroutewidget.h b/src/Changsha_Tour/showroutewidget.h
deleted file mode 100644
index 9ccbfe7..0000000
--- a/src/Changsha_Tour/showroutewidget.h
+++ /dev/null
@@ -1,22 +0,0 @@
-#ifndef SHOWROUTEWIDGET_H
-#define SHOWROUTEWIDGET_H
-
-#include
-
-namespace Ui {
-class ShowRouteWidget;
-}
-
-class ShowRouteWidget : public QWidget
-{
- Q_OBJECT
-
-public:
- explicit ShowRouteWidget(QWidget *parent = nullptr);
- ~ShowRouteWidget();
-
-private:
- Ui::ShowRouteWidget *ui;
-};
-
-#endif // SHOWROUTEWIDGET_H
diff --git a/src/Changsha_Tour/showroutewidget.ui b/src/Changsha_Tour/showroutewidget.ui
deleted file mode 100644
index 1d324b7..0000000
--- a/src/Changsha_Tour/showroutewidget.ui
+++ /dev/null
@@ -1,21 +0,0 @@
-
-
-
-
- ShowRouteWidget
-
-
-
- 0
- 0
- 400
- 300
-
-
-
- Form
-
-
-
-
-
|