增加了Route类,增加了等待窗口,将wait.rar解压到build文件夹下即可,完成了定制路线界面框架。

master
DongYanqi1029 4 years ago
parent 181d116b38
commit 2e53885596

@ -33,12 +33,13 @@ SOURCES += \
mainwidget.cpp \
mainwindow.cpp \
planwidget.cpp \
popwidget.cpp \
preferencewidget.cpp \
recommendwidget.cpp \
registermanager.cpp \
registerwidget.cpp \
routechoicewidget.cpp \
searchresultwidget.cpp \
searchwidget.cpp \
showplaceinfowidget.cpp \
showrouteinfowidget.cpp \
smtp.cpp \
@ -64,12 +65,13 @@ HEADERS += \
mainwidget.h \
mainwindow.h \
planwidget.h \
popwidget.h \
preferencewidget.h \
recommendwidget.h \
registermanager.h \
registerwidget.h \
routechoicewidget.h \
searchresultwidget.h \
searchwidget.h \
showplaceinfowidget.h \
showrouteinfowidget.h \
smtp.h \
@ -92,15 +94,18 @@ FORMS += \
mainwidget.ui \
mainwindow.ui \
planwidget.ui \
popwidget.ui \
preferencewidget.ui \
recommendwidget.ui \
registerwidget.ui \
routechoicewidget.ui \
searchwidget.ui \
showplaceinfowidget.ui \
showrouteinfowidget.ui \
sortwidget.ui \
userinfowidget.ui \
userwidget.ui \
waitwidget.ui \
webwidget.ui
# Default rules for deployment.

@ -1,10 +1,10 @@
<?xml version="1.0" encoding="UTF-8"?>
<!DOCTYPE QtCreatorProject>
<!-- Written by QtCreator 4.11.1, 2021-07-05T20:59:56. -->
<!-- Written by QtCreator 4.11.1, 2021-07-06T12:18:14. -->
<qtcreator>
<data>
<variable>EnvironmentId</variable>
<value type="QByteArray">{5009ac75-b61d-4c91-8540-bc9e10b6e582}</value>
<value type="QByteArray">{61ba832e-6c30-4ab6-b0b8-ace44f46ca0c}</value>
</data>
<data>
<variable>ProjectExplorer.Project.ActiveTarget</variable>
@ -44,8 +44,8 @@
<value type="bool" key="EditorConfiguration.SpacesForTabs">true</value>
<value type="int" key="EditorConfiguration.TabKeyBehavior">0</value>
<value type="int" key="EditorConfiguration.TabSize">8</value>
<value type="bool" key="EditorConfiguration.UseGlobal">true</value>
<value type="int" key="EditorConfiguration.Utf8BomBehavior">1</value>
<value type="bool" key="EditorConfiguration.UseGlobal">false</value>
<value type="int" key="EditorConfiguration.Utf8BomBehavior">0</value>
<value type="bool" key="EditorConfiguration.addFinalNewLine">true</value>
<value type="bool" key="EditorConfiguration.cleanIndentation">true</value>
<value type="bool" key="EditorConfiguration.cleanWhitespace">true</value>
@ -55,21 +55,23 @@
<data>
<variable>ProjectExplorer.Project.PluginSettings</variable>
<valuemap type="QVariantMap">
<valuelist type="QVariantList" key="ClangCodeModel.CustomCommandLineKey"/>
<valuelist type="QVariantList" key="ClangCodeModel.CustomCommandLineKey">
<value type="QString">-fno-delayed-template-parsing</value>
</valuelist>
<value type="bool" key="ClangCodeModel.UseGlobalConfig">true</value>
</valuemap>
</data>
<data>
<variable>ProjectExplorer.Project.Target.0</variable>
<valuemap type="QVariantMap">
<value type="QString" key="ProjectExplorer.ProjectConfiguration.DefaultDisplayName">Desktop Qt 5.14.2 GCC 64bit</value>
<value type="QString" key="ProjectExplorer.ProjectConfiguration.DisplayName">Desktop Qt 5.14.2 GCC 64bit</value>
<value type="QString" key="ProjectExplorer.ProjectConfiguration.Id">qt.qt5.5142.gcc_64_kit</value>
<value type="QString" key="ProjectExplorer.ProjectConfiguration.DefaultDisplayName">Desktop Qt 5.14.2 MSVC2017 64bit</value>
<value type="QString" key="ProjectExplorer.ProjectConfiguration.DisplayName">Desktop Qt 5.14.2 MSVC2017 64bit</value>
<value type="QString" key="ProjectExplorer.ProjectConfiguration.Id">qt.qt5.5142.win64_msvc2017_64_kit</value>
<value type="int" key="ProjectExplorer.Target.ActiveBuildConfiguration">0</value>
<value type="int" key="ProjectExplorer.Target.ActiveDeployConfiguration">0</value>
<value type="int" key="ProjectExplorer.Target.ActiveRunConfiguration">0</value>
<valuemap type="QVariantMap" key="ProjectExplorer.Target.BuildConfiguration.0">
<value type="QString" key="ProjectExplorer.BuildConfiguration.BuildDirectory">/home/extra/Study/2021SpringTerm/Architecture/TourInChangSha/src/build-ChangShaTour-Desktop_Qt_5_14_2_GCC_64bit-Debug</value>
<value type="QString" key="ProjectExplorer.BuildConfiguration.BuildDirectory">D:/Study/SE/project/code/Trip-in-Chang-sha-main-4/Trip-in-Chang-sha-main/build-ChangShaTour-Desktop_Qt_5_14_2_MSVC2017_64bit-Debug</value>
<valuemap type="QVariantMap" key="ProjectExplorer.BuildConfiguration.BuildStepList.0">
<valuemap type="QVariantMap" key="ProjectExplorer.BuildStepList.Step.0">
<value type="bool" key="ProjectExplorer.BuildStep.Enabled">true</value>
@ -117,7 +119,7 @@
<value type="int" key="Qt4ProjectManager.Qt4BuildConfiguration.BuildConfiguration">2</value>
</valuemap>
<valuemap type="QVariantMap" key="ProjectExplorer.Target.BuildConfiguration.1">
<value type="QString" key="ProjectExplorer.BuildConfiguration.BuildDirectory">/home/extra/Study/2021SpringTerm/Architecture/TourInChangSha/src/build-ChangShaTour-Desktop_Qt_5_14_2_GCC_64bit-Release</value>
<value type="QString" key="ProjectExplorer.BuildConfiguration.BuildDirectory">D:/Study/SE/project/code/Trip-in-Chang-sha-main-4/Trip-in-Chang-sha-main/build-ChangShaTour-Desktop_Qt_5_14_2_MSVC2017_64bit-Release</value>
<valuemap type="QVariantMap" key="ProjectExplorer.BuildConfiguration.BuildStepList.0">
<valuemap type="QVariantMap" key="ProjectExplorer.BuildStepList.Step.0">
<value type="bool" key="ProjectExplorer.BuildStep.Enabled">true</value>
@ -165,7 +167,7 @@
<value type="int" key="Qt4ProjectManager.Qt4BuildConfiguration.BuildConfiguration">0</value>
</valuemap>
<valuemap type="QVariantMap" key="ProjectExplorer.Target.BuildConfiguration.2">
<value type="QString" key="ProjectExplorer.BuildConfiguration.BuildDirectory">/home/extra/Study/2021SpringTerm/Architecture/TourInChangSha/src/build-ChangShaTour-Desktop_Qt_5_14_2_GCC_64bit-Profile</value>
<value type="QString" key="ProjectExplorer.BuildConfiguration.BuildDirectory">D:/Study/SE/project/code/Trip-in-Chang-sha-main-4/Trip-in-Chang-sha-main/build-ChangShaTour-Desktop_Qt_5_14_2_MSVC2017_64bit-Profile</value>
<valuemap type="QVariantMap" key="ProjectExplorer.BuildConfiguration.BuildStepList.0">
<valuemap type="QVariantMap" key="ProjectExplorer.BuildStepList.Step.0">
<value type="bool" key="ProjectExplorer.BuildStep.Enabled">true</value>
@ -285,8 +287,9 @@
</valuelist>
<value type="int" key="PE.EnvironmentAspect.Base">2</value>
<valuelist type="QVariantList" key="PE.EnvironmentAspect.Changes"/>
<value type="QString" key="ProjectExplorer.ProjectConfiguration.Id">Qt4ProjectManager.Qt4RunConfiguration:/home/extra/Study/2021SpringTerm/Architecture/TourInChangSha/src/ChangShaTour/ChangShaTour.pro</value>
<value type="QString" key="ProjectExplorer.RunConfiguration.BuildKey">/home/extra/Study/2021SpringTerm/Architecture/TourInChangSha/src/ChangShaTour/ChangShaTour.pro</value>
<value type="QString" key="ProjectExplorer.ProjectConfiguration.DisplayName">ChangShaTour2</value>
<value type="QString" key="ProjectExplorer.ProjectConfiguration.Id">Qt4ProjectManager.Qt4RunConfiguration:D:/ChangShaTour/ChangShaTour.pro</value>
<value type="QString" key="ProjectExplorer.RunConfiguration.BuildKey">D:/ChangShaTour/ChangShaTour.pro</value>
<value type="QString" key="RunConfiguration.Arguments"></value>
<value type="bool" key="RunConfiguration.Arguments.multi">false</value>
<value type="QString" key="RunConfiguration.OverrideDebuggerStartup"></value>
@ -297,14 +300,500 @@
<value type="bool" key="RunConfiguration.UseQmlDebugger">false</value>
<value type="bool" key="RunConfiguration.UseQmlDebuggerAuto">true</value>
<value type="QString" key="RunConfiguration.WorkingDirectory"></value>
<value type="QString" key="RunConfiguration.WorkingDirectory.default">/home/extra/Study/2021SpringTerm/Architecture/TourInChangSha/src/build-ChangShaTour-Desktop_Qt_5_14_2_GCC_64bit-Debug</value>
<value type="QString" key="RunConfiguration.WorkingDirectory.default">D:/Study/SE/project/code/Trip-in-Chang-sha-main-4/Trip-in-Chang-sha-main/build-ChangShaTour-Desktop_Qt_5_14_2_MSVC2017_64bit-Debug</value>
</valuemap>
<value type="int" key="ProjectExplorer.Target.RunConfigurationCount">1</value>
</valuemap>
</data>
<data>
<variable>ProjectExplorer.Project.Target.1</variable>
<valuemap type="QVariantMap">
<value type="QString" key="ProjectExplorer.ProjectConfiguration.DefaultDisplayName">Desktop Qt 5.14.2 MinGW 32-bit</value>
<value type="QString" key="ProjectExplorer.ProjectConfiguration.DisplayName">Desktop Qt 5.14.2 MinGW 32-bit</value>
<value type="QString" key="ProjectExplorer.ProjectConfiguration.Id">qt.qt5.5142.win32_mingw73_kit</value>
<value type="int" key="ProjectExplorer.Target.ActiveBuildConfiguration">0</value>
<value type="int" key="ProjectExplorer.Target.ActiveDeployConfiguration">0</value>
<value type="int" key="ProjectExplorer.Target.ActiveRunConfiguration">0</value>
<valuemap type="QVariantMap" key="ProjectExplorer.Target.BuildConfiguration.0">
<value type="QString" key="ProjectExplorer.BuildConfiguration.BuildDirectory">D:/Study/SE/project/code/Trip-in-Chang-sha-main-4/Trip-in-Chang-sha-main/build-ChangShaTour-Desktop_Qt_5_14_2_MinGW_32_bit-Debug</value>
<valuemap type="QVariantMap" key="ProjectExplorer.BuildConfiguration.BuildStepList.0">
<valuemap type="QVariantMap" key="ProjectExplorer.BuildStepList.Step.0">
<value type="bool" key="ProjectExplorer.BuildStep.Enabled">true</value>
<value type="QString" key="ProjectExplorer.ProjectConfiguration.Id">QtProjectManager.QMakeBuildStep</value>
<value type="bool" key="QtProjectManager.QMakeBuildStep.LinkQmlDebuggingLibrary">true</value>
<value type="QString" key="QtProjectManager.QMakeBuildStep.QMakeArguments"></value>
<value type="bool" key="QtProjectManager.QMakeBuildStep.QMakeForced">false</value>
<value type="bool" key="QtProjectManager.QMakeBuildStep.SeparateDebugInfo">false</value>
<value type="bool" key="QtProjectManager.QMakeBuildStep.UseQtQuickCompiler">false</value>
</valuemap>
<valuemap type="QVariantMap" key="ProjectExplorer.BuildStepList.Step.1">
<value type="bool" key="ProjectExplorer.BuildStep.Enabled">true</value>
<value type="QString" key="ProjectExplorer.ProjectConfiguration.Id">Qt4ProjectManager.MakeStep</value>
<valuelist type="QVariantList" key="Qt4ProjectManager.MakeStep.BuildTargets"/>
<value type="bool" key="Qt4ProjectManager.MakeStep.Clean">false</value>
<value type="QString" key="Qt4ProjectManager.MakeStep.MakeArguments"></value>
<value type="QString" key="Qt4ProjectManager.MakeStep.MakeCommand"></value>
<value type="bool" key="Qt4ProjectManager.MakeStep.OverrideMakeflags">false</value>
</valuemap>
<value type="int" key="ProjectExplorer.BuildStepList.StepsCount">2</value>
<value type="QString" key="ProjectExplorer.ProjectConfiguration.DefaultDisplayName">Build</value>
<value type="QString" key="ProjectExplorer.ProjectConfiguration.DisplayName">Build</value>
<value type="QString" key="ProjectExplorer.ProjectConfiguration.Id">ProjectExplorer.BuildSteps.Build</value>
</valuemap>
<valuemap type="QVariantMap" key="ProjectExplorer.BuildConfiguration.BuildStepList.1">
<valuemap type="QVariantMap" key="ProjectExplorer.BuildStepList.Step.0">
<value type="bool" key="ProjectExplorer.BuildStep.Enabled">true</value>
<value type="QString" key="ProjectExplorer.ProjectConfiguration.Id">Qt4ProjectManager.MakeStep</value>
<valuelist type="QVariantList" key="Qt4ProjectManager.MakeStep.BuildTargets"/>
<value type="bool" key="Qt4ProjectManager.MakeStep.Clean">true</value>
<value type="QString" key="Qt4ProjectManager.MakeStep.MakeArguments">clean</value>
<value type="QString" key="Qt4ProjectManager.MakeStep.MakeCommand"></value>
<value type="bool" key="Qt4ProjectManager.MakeStep.OverrideMakeflags">false</value>
</valuemap>
<value type="int" key="ProjectExplorer.BuildStepList.StepsCount">1</value>
<value type="QString" key="ProjectExplorer.ProjectConfiguration.DefaultDisplayName">Clean</value>
<value type="QString" key="ProjectExplorer.ProjectConfiguration.DisplayName">Clean</value>
<value type="QString" key="ProjectExplorer.ProjectConfiguration.Id">ProjectExplorer.BuildSteps.Clean</value>
</valuemap>
<value type="int" key="ProjectExplorer.BuildConfiguration.BuildStepListCount">2</value>
<value type="bool" key="ProjectExplorer.BuildConfiguration.ClearSystemEnvironment">false</value>
<valuelist type="QVariantList" key="ProjectExplorer.BuildConfiguration.UserEnvironmentChanges"/>
<value type="QString" key="ProjectExplorer.ProjectConfiguration.DisplayName">Debug</value>
<value type="QString" key="ProjectExplorer.ProjectConfiguration.Id">Qt4ProjectManager.Qt4BuildConfiguration</value>
<value type="int" key="Qt4ProjectManager.Qt4BuildConfiguration.BuildConfiguration">2</value>
</valuemap>
<valuemap type="QVariantMap" key="ProjectExplorer.Target.BuildConfiguration.1">
<value type="QString" key="ProjectExplorer.BuildConfiguration.BuildDirectory">D:/Study/SE/project/code/Trip-in-Chang-sha-main-4/Trip-in-Chang-sha-main/build-ChangShaTour-Desktop_Qt_5_14_2_MinGW_32_bit-Release</value>
<valuemap type="QVariantMap" key="ProjectExplorer.BuildConfiguration.BuildStepList.0">
<valuemap type="QVariantMap" key="ProjectExplorer.BuildStepList.Step.0">
<value type="bool" key="ProjectExplorer.BuildStep.Enabled">true</value>
<value type="QString" key="ProjectExplorer.ProjectConfiguration.Id">QtProjectManager.QMakeBuildStep</value>
<value type="bool" key="QtProjectManager.QMakeBuildStep.LinkQmlDebuggingLibrary">false</value>
<value type="QString" key="QtProjectManager.QMakeBuildStep.QMakeArguments"></value>
<value type="bool" key="QtProjectManager.QMakeBuildStep.QMakeForced">false</value>
<value type="bool" key="QtProjectManager.QMakeBuildStep.SeparateDebugInfo">false</value>
<value type="bool" key="QtProjectManager.QMakeBuildStep.UseQtQuickCompiler">true</value>
</valuemap>
<valuemap type="QVariantMap" key="ProjectExplorer.BuildStepList.Step.1">
<value type="bool" key="ProjectExplorer.BuildStep.Enabled">true</value>
<value type="QString" key="ProjectExplorer.ProjectConfiguration.Id">Qt4ProjectManager.MakeStep</value>
<valuelist type="QVariantList" key="Qt4ProjectManager.MakeStep.BuildTargets"/>
<value type="bool" key="Qt4ProjectManager.MakeStep.Clean">false</value>
<value type="QString" key="Qt4ProjectManager.MakeStep.MakeArguments"></value>
<value type="QString" key="Qt4ProjectManager.MakeStep.MakeCommand"></value>
<value type="bool" key="Qt4ProjectManager.MakeStep.OverrideMakeflags">false</value>
</valuemap>
<value type="int" key="ProjectExplorer.BuildStepList.StepsCount">2</value>
<value type="QString" key="ProjectExplorer.ProjectConfiguration.DefaultDisplayName">Build</value>
<value type="QString" key="ProjectExplorer.ProjectConfiguration.DisplayName">Build</value>
<value type="QString" key="ProjectExplorer.ProjectConfiguration.Id">ProjectExplorer.BuildSteps.Build</value>
</valuemap>
<valuemap type="QVariantMap" key="ProjectExplorer.BuildConfiguration.BuildStepList.1">
<valuemap type="QVariantMap" key="ProjectExplorer.BuildStepList.Step.0">
<value type="bool" key="ProjectExplorer.BuildStep.Enabled">true</value>
<value type="QString" key="ProjectExplorer.ProjectConfiguration.Id">Qt4ProjectManager.MakeStep</value>
<valuelist type="QVariantList" key="Qt4ProjectManager.MakeStep.BuildTargets"/>
<value type="bool" key="Qt4ProjectManager.MakeStep.Clean">true</value>
<value type="QString" key="Qt4ProjectManager.MakeStep.MakeArguments">clean</value>
<value type="QString" key="Qt4ProjectManager.MakeStep.MakeCommand"></value>
<value type="bool" key="Qt4ProjectManager.MakeStep.OverrideMakeflags">false</value>
</valuemap>
<value type="int" key="ProjectExplorer.BuildStepList.StepsCount">1</value>
<value type="QString" key="ProjectExplorer.ProjectConfiguration.DefaultDisplayName">Clean</value>
<value type="QString" key="ProjectExplorer.ProjectConfiguration.DisplayName">Clean</value>
<value type="QString" key="ProjectExplorer.ProjectConfiguration.Id">ProjectExplorer.BuildSteps.Clean</value>
</valuemap>
<value type="int" key="ProjectExplorer.BuildConfiguration.BuildStepListCount">2</value>
<value type="bool" key="ProjectExplorer.BuildConfiguration.ClearSystemEnvironment">false</value>
<valuelist type="QVariantList" key="ProjectExplorer.BuildConfiguration.UserEnvironmentChanges"/>
<value type="QString" key="ProjectExplorer.ProjectConfiguration.DisplayName">Release</value>
<value type="QString" key="ProjectExplorer.ProjectConfiguration.Id">Qt4ProjectManager.Qt4BuildConfiguration</value>
<value type="int" key="Qt4ProjectManager.Qt4BuildConfiguration.BuildConfiguration">0</value>
</valuemap>
<valuemap type="QVariantMap" key="ProjectExplorer.Target.BuildConfiguration.2">
<value type="QString" key="ProjectExplorer.BuildConfiguration.BuildDirectory">D:/Study/SE/project/code/Trip-in-Chang-sha-main-4/Trip-in-Chang-sha-main/build-ChangShaTour-Desktop_Qt_5_14_2_MinGW_32_bit-Profile</value>
<valuemap type="QVariantMap" key="ProjectExplorer.BuildConfiguration.BuildStepList.0">
<valuemap type="QVariantMap" key="ProjectExplorer.BuildStepList.Step.0">
<value type="bool" key="ProjectExplorer.BuildStep.Enabled">true</value>
<value type="QString" key="ProjectExplorer.ProjectConfiguration.Id">QtProjectManager.QMakeBuildStep</value>
<value type="bool" key="QtProjectManager.QMakeBuildStep.LinkQmlDebuggingLibrary">true</value>
<value type="QString" key="QtProjectManager.QMakeBuildStep.QMakeArguments"></value>
<value type="bool" key="QtProjectManager.QMakeBuildStep.QMakeForced">false</value>
<value type="bool" key="QtProjectManager.QMakeBuildStep.SeparateDebugInfo">true</value>
<value type="bool" key="QtProjectManager.QMakeBuildStep.UseQtQuickCompiler">true</value>
</valuemap>
<valuemap type="QVariantMap" key="ProjectExplorer.BuildStepList.Step.1">
<value type="bool" key="ProjectExplorer.BuildStep.Enabled">true</value>
<value type="QString" key="ProjectExplorer.ProjectConfiguration.Id">Qt4ProjectManager.MakeStep</value>
<valuelist type="QVariantList" key="Qt4ProjectManager.MakeStep.BuildTargets"/>
<value type="bool" key="Qt4ProjectManager.MakeStep.Clean">false</value>
<value type="QString" key="Qt4ProjectManager.MakeStep.MakeArguments"></value>
<value type="QString" key="Qt4ProjectManager.MakeStep.MakeCommand"></value>
<value type="bool" key="Qt4ProjectManager.MakeStep.OverrideMakeflags">false</value>
</valuemap>
<value type="int" key="ProjectExplorer.BuildStepList.StepsCount">2</value>
<value type="QString" key="ProjectExplorer.ProjectConfiguration.DefaultDisplayName">Build</value>
<value type="QString" key="ProjectExplorer.ProjectConfiguration.DisplayName">Build</value>
<value type="QString" key="ProjectExplorer.ProjectConfiguration.Id">ProjectExplorer.BuildSteps.Build</value>
</valuemap>
<valuemap type="QVariantMap" key="ProjectExplorer.BuildConfiguration.BuildStepList.1">
<valuemap type="QVariantMap" key="ProjectExplorer.BuildStepList.Step.0">
<value type="bool" key="ProjectExplorer.BuildStep.Enabled">true</value>
<value type="QString" key="ProjectExplorer.ProjectConfiguration.Id">Qt4ProjectManager.MakeStep</value>
<valuelist type="QVariantList" key="Qt4ProjectManager.MakeStep.BuildTargets"/>
<value type="bool" key="Qt4ProjectManager.MakeStep.Clean">true</value>
<value type="QString" key="Qt4ProjectManager.MakeStep.MakeArguments">clean</value>
<value type="QString" key="Qt4ProjectManager.MakeStep.MakeCommand"></value>
<value type="bool" key="Qt4ProjectManager.MakeStep.OverrideMakeflags">false</value>
</valuemap>
<value type="int" key="ProjectExplorer.BuildStepList.StepsCount">1</value>
<value type="QString" key="ProjectExplorer.ProjectConfiguration.DefaultDisplayName">Clean</value>
<value type="QString" key="ProjectExplorer.ProjectConfiguration.DisplayName">Clean</value>
<value type="QString" key="ProjectExplorer.ProjectConfiguration.Id">ProjectExplorer.BuildSteps.Clean</value>
</valuemap>
<value type="int" key="ProjectExplorer.BuildConfiguration.BuildStepListCount">2</value>
<value type="bool" key="ProjectExplorer.BuildConfiguration.ClearSystemEnvironment">false</value>
<valuelist type="QVariantList" key="ProjectExplorer.BuildConfiguration.UserEnvironmentChanges"/>
<value type="QString" key="ProjectExplorer.ProjectConfiguration.DisplayName">Profile</value>
<value type="QString" key="ProjectExplorer.ProjectConfiguration.Id">Qt4ProjectManager.Qt4BuildConfiguration</value>
<value type="int" key="Qt4ProjectManager.Qt4BuildConfiguration.BuildConfiguration">0</value>
</valuemap>
<value type="int" key="ProjectExplorer.Target.BuildConfigurationCount">3</value>
<valuemap type="QVariantMap" key="ProjectExplorer.Target.DeployConfiguration.0">
<valuemap type="QVariantMap" key="ProjectExplorer.BuildConfiguration.BuildStepList.0">
<value type="int" key="ProjectExplorer.BuildStepList.StepsCount">0</value>
<value type="QString" key="ProjectExplorer.ProjectConfiguration.DefaultDisplayName">Deploy</value>
<value type="QString" key="ProjectExplorer.ProjectConfiguration.DisplayName">Deploy</value>
<value type="QString" key="ProjectExplorer.ProjectConfiguration.Id">ProjectExplorer.BuildSteps.Deploy</value>
</valuemap>
<value type="int" key="ProjectExplorer.BuildConfiguration.BuildStepListCount">1</value>
<value type="QString" key="ProjectExplorer.ProjectConfiguration.Id">ProjectExplorer.DefaultDeployConfiguration</value>
</valuemap>
<value type="int" key="ProjectExplorer.Target.DeployConfigurationCount">1</value>
<valuemap type="QVariantMap" key="ProjectExplorer.Target.PluginSettings"/>
<valuemap type="QVariantMap" key="ProjectExplorer.Target.RunConfiguration.0">
<value type="QString" key="Analyzer.Perf.CallgraphMode">dwarf</value>
<valuelist type="QVariantList" key="Analyzer.Perf.Events">
<value type="QString">cpu-cycles</value>
</valuelist>
<valuelist type="QVariantList" key="Analyzer.Perf.ExtraArguments"/>
<value type="int" key="Analyzer.Perf.Frequency">250</value>
<valuelist type="QVariantList" key="Analyzer.Perf.RecordArguments">
<value type="QString">-e</value>
<value type="QString">cpu-cycles</value>
<value type="QString">--call-graph</value>
<value type="QString">dwarf,4096</value>
<value type="QString">-F</value>
<value type="QString">250</value>
</valuelist>
<value type="QString" key="Analyzer.Perf.SampleMode">-F</value>
<value type="bool" key="Analyzer.Perf.Settings.UseGlobalSettings">true</value>
<value type="int" key="Analyzer.Perf.StackSize">4096</value>
<value type="bool" key="Analyzer.QmlProfiler.AggregateTraces">false</value>
<value type="bool" key="Analyzer.QmlProfiler.FlushEnabled">false</value>
<value type="uint" key="Analyzer.QmlProfiler.FlushInterval">1000</value>
<value type="QString" key="Analyzer.QmlProfiler.LastTraceFile"></value>
<value type="bool" key="Analyzer.QmlProfiler.Settings.UseGlobalSettings">true</value>
<valuelist type="QVariantList" key="Analyzer.Valgrind.AddedSuppressionFiles"/>
<value type="bool" key="Analyzer.Valgrind.Callgrind.CollectBusEvents">false</value>
<value type="bool" key="Analyzer.Valgrind.Callgrind.CollectSystime">false</value>
<value type="bool" key="Analyzer.Valgrind.Callgrind.EnableBranchSim">false</value>
<value type="bool" key="Analyzer.Valgrind.Callgrind.EnableCacheSim">false</value>
<value type="bool" key="Analyzer.Valgrind.Callgrind.EnableEventToolTips">true</value>
<value type="double" key="Analyzer.Valgrind.Callgrind.MinimumCostRatio">0.01</value>
<value type="double" key="Analyzer.Valgrind.Callgrind.VisualisationMinimumCostRatio">10</value>
<value type="bool" key="Analyzer.Valgrind.FilterExternalIssues">true</value>
<value type="QString" key="Analyzer.Valgrind.KCachegrindExecutable">kcachegrind</value>
<value type="int" key="Analyzer.Valgrind.LeakCheckOnFinish">1</value>
<value type="int" key="Analyzer.Valgrind.NumCallers">25</value>
<valuelist type="QVariantList" key="Analyzer.Valgrind.RemovedSuppressionFiles"/>
<value type="int" key="Analyzer.Valgrind.SelfModifyingCodeDetection">1</value>
<value type="bool" key="Analyzer.Valgrind.Settings.UseGlobalSettings">true</value>
<value type="bool" key="Analyzer.Valgrind.ShowReachable">false</value>
<value type="bool" key="Analyzer.Valgrind.TrackOrigins">true</value>
<value type="QString" key="Analyzer.Valgrind.ValgrindExecutable">valgrind</value>
<valuelist type="QVariantList" key="Analyzer.Valgrind.VisibleErrorKinds">
<value type="int">0</value>
<value type="int">1</value>
<value type="int">2</value>
<value type="int">3</value>
<value type="int">4</value>
<value type="int">5</value>
<value type="int">6</value>
<value type="int">7</value>
<value type="int">8</value>
<value type="int">9</value>
<value type="int">10</value>
<value type="int">11</value>
<value type="int">12</value>
<value type="int">13</value>
<value type="int">14</value>
</valuelist>
<value type="int" key="PE.EnvironmentAspect.Base">2</value>
<valuelist type="QVariantList" key="PE.EnvironmentAspect.Changes"/>
<value type="QString" key="ProjectExplorer.CustomExecutableRunConfiguration.Executable"></value>
<value type="QString" key="ProjectExplorer.ProjectConfiguration.Id">ProjectExplorer.CustomExecutableRunConfiguration</value>
<value type="QString" key="ProjectExplorer.RunConfiguration.BuildKey"></value>
<value type="QString" key="RunConfiguration.Arguments"></value>
<value type="bool" key="RunConfiguration.Arguments.multi">false</value>
<value type="QString" key="RunConfiguration.OverrideDebuggerStartup"></value>
<value type="bool" key="RunConfiguration.UseCppDebugger">false</value>
<value type="bool" key="RunConfiguration.UseCppDebuggerAuto">true</value>
<value type="bool" key="RunConfiguration.UseMultiProcess">false</value>
<value type="bool" key="RunConfiguration.UseQmlDebugger">false</value>
<value type="bool" key="RunConfiguration.UseQmlDebuggerAuto">true</value>
<value type="QString" key="RunConfiguration.WorkingDirectory"></value>
<value type="QString" key="RunConfiguration.WorkingDirectory.default"></value>
</valuemap>
<value type="int" key="ProjectExplorer.Target.RunConfigurationCount">1</value>
</valuemap>
</data>
<data>
<variable>ProjectExplorer.Project.Target.2</variable>
<valuemap type="QVariantMap">
<value type="QString" key="ProjectExplorer.ProjectConfiguration.DefaultDisplayName">Desktop Qt 5.14.2 MinGW 64-bit</value>
<value type="QString" key="ProjectExplorer.ProjectConfiguration.DisplayName">Desktop Qt 5.14.2 MinGW 64-bit</value>
<value type="QString" key="ProjectExplorer.ProjectConfiguration.Id">qt.qt5.5142.win64_mingw73_kit</value>
<value type="int" key="ProjectExplorer.Target.ActiveBuildConfiguration">0</value>
<value type="int" key="ProjectExplorer.Target.ActiveDeployConfiguration">0</value>
<value type="int" key="ProjectExplorer.Target.ActiveRunConfiguration">0</value>
<valuemap type="QVariantMap" key="ProjectExplorer.Target.BuildConfiguration.0">
<value type="QString" key="ProjectExplorer.BuildConfiguration.BuildDirectory">D:/Study/SE/project/code/Trip-in-Chang-sha-main-4/Trip-in-Chang-sha-main/build-ChangShaTour-Desktop_Qt_5_14_2_MinGW_64_bit-Debug</value>
<valuemap type="QVariantMap" key="ProjectExplorer.BuildConfiguration.BuildStepList.0">
<valuemap type="QVariantMap" key="ProjectExplorer.BuildStepList.Step.0">
<value type="bool" key="ProjectExplorer.BuildStep.Enabled">true</value>
<value type="QString" key="ProjectExplorer.ProjectConfiguration.Id">QtProjectManager.QMakeBuildStep</value>
<value type="bool" key="QtProjectManager.QMakeBuildStep.LinkQmlDebuggingLibrary">true</value>
<value type="QString" key="QtProjectManager.QMakeBuildStep.QMakeArguments"></value>
<value type="bool" key="QtProjectManager.QMakeBuildStep.QMakeForced">false</value>
<value type="bool" key="QtProjectManager.QMakeBuildStep.SeparateDebugInfo">false</value>
<value type="bool" key="QtProjectManager.QMakeBuildStep.UseQtQuickCompiler">false</value>
</valuemap>
<valuemap type="QVariantMap" key="ProjectExplorer.BuildStepList.Step.1">
<value type="bool" key="ProjectExplorer.BuildStep.Enabled">true</value>
<value type="QString" key="ProjectExplorer.ProjectConfiguration.Id">Qt4ProjectManager.MakeStep</value>
<valuelist type="QVariantList" key="Qt4ProjectManager.MakeStep.BuildTargets"/>
<value type="bool" key="Qt4ProjectManager.MakeStep.Clean">false</value>
<value type="QString" key="Qt4ProjectManager.MakeStep.MakeArguments"></value>
<value type="QString" key="Qt4ProjectManager.MakeStep.MakeCommand"></value>
<value type="bool" key="Qt4ProjectManager.MakeStep.OverrideMakeflags">false</value>
</valuemap>
<value type="int" key="ProjectExplorer.BuildStepList.StepsCount">2</value>
<value type="QString" key="ProjectExplorer.ProjectConfiguration.DefaultDisplayName">Build</value>
<value type="QString" key="ProjectExplorer.ProjectConfiguration.DisplayName">Build</value>
<value type="QString" key="ProjectExplorer.ProjectConfiguration.Id">ProjectExplorer.BuildSteps.Build</value>
</valuemap>
<valuemap type="QVariantMap" key="ProjectExplorer.BuildConfiguration.BuildStepList.1">
<valuemap type="QVariantMap" key="ProjectExplorer.BuildStepList.Step.0">
<value type="bool" key="ProjectExplorer.BuildStep.Enabled">true</value>
<value type="QString" key="ProjectExplorer.ProjectConfiguration.Id">Qt4ProjectManager.MakeStep</value>
<valuelist type="QVariantList" key="Qt4ProjectManager.MakeStep.BuildTargets"/>
<value type="bool" key="Qt4ProjectManager.MakeStep.Clean">true</value>
<value type="QString" key="Qt4ProjectManager.MakeStep.MakeArguments">clean</value>
<value type="QString" key="Qt4ProjectManager.MakeStep.MakeCommand"></value>
<value type="bool" key="Qt4ProjectManager.MakeStep.OverrideMakeflags">false</value>
</valuemap>
<value type="int" key="ProjectExplorer.BuildStepList.StepsCount">1</value>
<value type="QString" key="ProjectExplorer.ProjectConfiguration.DefaultDisplayName">Clean</value>
<value type="QString" key="ProjectExplorer.ProjectConfiguration.DisplayName">Clean</value>
<value type="QString" key="ProjectExplorer.ProjectConfiguration.Id">ProjectExplorer.BuildSteps.Clean</value>
</valuemap>
<value type="int" key="ProjectExplorer.BuildConfiguration.BuildStepListCount">2</value>
<value type="bool" key="ProjectExplorer.BuildConfiguration.ClearSystemEnvironment">false</value>
<valuelist type="QVariantList" key="ProjectExplorer.BuildConfiguration.UserEnvironmentChanges"/>
<value type="QString" key="ProjectExplorer.ProjectConfiguration.DisplayName">Debug</value>
<value type="QString" key="ProjectExplorer.ProjectConfiguration.Id">Qt4ProjectManager.Qt4BuildConfiguration</value>
<value type="int" key="Qt4ProjectManager.Qt4BuildConfiguration.BuildConfiguration">2</value>
</valuemap>
<valuemap type="QVariantMap" key="ProjectExplorer.Target.BuildConfiguration.1">
<value type="QString" key="ProjectExplorer.BuildConfiguration.BuildDirectory">D:/Study/SE/project/code/Trip-in-Chang-sha-main-4/Trip-in-Chang-sha-main/build-ChangShaTour-Desktop_Qt_5_14_2_MinGW_64_bit-Release</value>
<valuemap type="QVariantMap" key="ProjectExplorer.BuildConfiguration.BuildStepList.0">
<valuemap type="QVariantMap" key="ProjectExplorer.BuildStepList.Step.0">
<value type="bool" key="ProjectExplorer.BuildStep.Enabled">true</value>
<value type="QString" key="ProjectExplorer.ProjectConfiguration.Id">QtProjectManager.QMakeBuildStep</value>
<value type="bool" key="QtProjectManager.QMakeBuildStep.LinkQmlDebuggingLibrary">false</value>
<value type="QString" key="QtProjectManager.QMakeBuildStep.QMakeArguments"></value>
<value type="bool" key="QtProjectManager.QMakeBuildStep.QMakeForced">false</value>
<value type="bool" key="QtProjectManager.QMakeBuildStep.SeparateDebugInfo">false</value>
<value type="bool" key="QtProjectManager.QMakeBuildStep.UseQtQuickCompiler">true</value>
</valuemap>
<valuemap type="QVariantMap" key="ProjectExplorer.BuildStepList.Step.1">
<value type="bool" key="ProjectExplorer.BuildStep.Enabled">true</value>
<value type="QString" key="ProjectExplorer.ProjectConfiguration.Id">Qt4ProjectManager.MakeStep</value>
<valuelist type="QVariantList" key="Qt4ProjectManager.MakeStep.BuildTargets"/>
<value type="bool" key="Qt4ProjectManager.MakeStep.Clean">false</value>
<value type="QString" key="Qt4ProjectManager.MakeStep.MakeArguments"></value>
<value type="QString" key="Qt4ProjectManager.MakeStep.MakeCommand"></value>
<value type="bool" key="Qt4ProjectManager.MakeStep.OverrideMakeflags">false</value>
</valuemap>
<value type="int" key="ProjectExplorer.BuildStepList.StepsCount">2</value>
<value type="QString" key="ProjectExplorer.ProjectConfiguration.DefaultDisplayName">Build</value>
<value type="QString" key="ProjectExplorer.ProjectConfiguration.DisplayName">Build</value>
<value type="QString" key="ProjectExplorer.ProjectConfiguration.Id">ProjectExplorer.BuildSteps.Build</value>
</valuemap>
<valuemap type="QVariantMap" key="ProjectExplorer.BuildConfiguration.BuildStepList.1">
<valuemap type="QVariantMap" key="ProjectExplorer.BuildStepList.Step.0">
<value type="bool" key="ProjectExplorer.BuildStep.Enabled">true</value>
<value type="QString" key="ProjectExplorer.ProjectConfiguration.Id">Qt4ProjectManager.MakeStep</value>
<valuelist type="QVariantList" key="Qt4ProjectManager.MakeStep.BuildTargets"/>
<value type="bool" key="Qt4ProjectManager.MakeStep.Clean">true</value>
<value type="QString" key="Qt4ProjectManager.MakeStep.MakeArguments">clean</value>
<value type="QString" key="Qt4ProjectManager.MakeStep.MakeCommand"></value>
<value type="bool" key="Qt4ProjectManager.MakeStep.OverrideMakeflags">false</value>
</valuemap>
<value type="int" key="ProjectExplorer.BuildStepList.StepsCount">1</value>
<value type="QString" key="ProjectExplorer.ProjectConfiguration.DefaultDisplayName">Clean</value>
<value type="QString" key="ProjectExplorer.ProjectConfiguration.DisplayName">Clean</value>
<value type="QString" key="ProjectExplorer.ProjectConfiguration.Id">ProjectExplorer.BuildSteps.Clean</value>
</valuemap>
<value type="int" key="ProjectExplorer.BuildConfiguration.BuildStepListCount">2</value>
<value type="bool" key="ProjectExplorer.BuildConfiguration.ClearSystemEnvironment">false</value>
<valuelist type="QVariantList" key="ProjectExplorer.BuildConfiguration.UserEnvironmentChanges"/>
<value type="QString" key="ProjectExplorer.ProjectConfiguration.DisplayName">Release</value>
<value type="QString" key="ProjectExplorer.ProjectConfiguration.Id">Qt4ProjectManager.Qt4BuildConfiguration</value>
<value type="int" key="Qt4ProjectManager.Qt4BuildConfiguration.BuildConfiguration">0</value>
</valuemap>
<valuemap type="QVariantMap" key="ProjectExplorer.Target.BuildConfiguration.2">
<value type="QString" key="ProjectExplorer.BuildConfiguration.BuildDirectory">D:/Study/SE/project/code/Trip-in-Chang-sha-main-4/Trip-in-Chang-sha-main/build-ChangShaTour-Desktop_Qt_5_14_2_MinGW_64_bit-Profile</value>
<valuemap type="QVariantMap" key="ProjectExplorer.BuildConfiguration.BuildStepList.0">
<valuemap type="QVariantMap" key="ProjectExplorer.BuildStepList.Step.0">
<value type="bool" key="ProjectExplorer.BuildStep.Enabled">true</value>
<value type="QString" key="ProjectExplorer.ProjectConfiguration.Id">QtProjectManager.QMakeBuildStep</value>
<value type="bool" key="QtProjectManager.QMakeBuildStep.LinkQmlDebuggingLibrary">true</value>
<value type="QString" key="QtProjectManager.QMakeBuildStep.QMakeArguments"></value>
<value type="bool" key="QtProjectManager.QMakeBuildStep.QMakeForced">false</value>
<value type="bool" key="QtProjectManager.QMakeBuildStep.SeparateDebugInfo">true</value>
<value type="bool" key="QtProjectManager.QMakeBuildStep.UseQtQuickCompiler">true</value>
</valuemap>
<valuemap type="QVariantMap" key="ProjectExplorer.BuildStepList.Step.1">
<value type="bool" key="ProjectExplorer.BuildStep.Enabled">true</value>
<value type="QString" key="ProjectExplorer.ProjectConfiguration.Id">Qt4ProjectManager.MakeStep</value>
<valuelist type="QVariantList" key="Qt4ProjectManager.MakeStep.BuildTargets"/>
<value type="bool" key="Qt4ProjectManager.MakeStep.Clean">false</value>
<value type="QString" key="Qt4ProjectManager.MakeStep.MakeArguments"></value>
<value type="QString" key="Qt4ProjectManager.MakeStep.MakeCommand"></value>
<value type="bool" key="Qt4ProjectManager.MakeStep.OverrideMakeflags">false</value>
</valuemap>
<value type="int" key="ProjectExplorer.BuildStepList.StepsCount">2</value>
<value type="QString" key="ProjectExplorer.ProjectConfiguration.DefaultDisplayName">Build</value>
<value type="QString" key="ProjectExplorer.ProjectConfiguration.DisplayName">Build</value>
<value type="QString" key="ProjectExplorer.ProjectConfiguration.Id">ProjectExplorer.BuildSteps.Build</value>
</valuemap>
<valuemap type="QVariantMap" key="ProjectExplorer.BuildConfiguration.BuildStepList.1">
<valuemap type="QVariantMap" key="ProjectExplorer.BuildStepList.Step.0">
<value type="bool" key="ProjectExplorer.BuildStep.Enabled">true</value>
<value type="QString" key="ProjectExplorer.ProjectConfiguration.Id">Qt4ProjectManager.MakeStep</value>
<valuelist type="QVariantList" key="Qt4ProjectManager.MakeStep.BuildTargets"/>
<value type="bool" key="Qt4ProjectManager.MakeStep.Clean">true</value>
<value type="QString" key="Qt4ProjectManager.MakeStep.MakeArguments">clean</value>
<value type="QString" key="Qt4ProjectManager.MakeStep.MakeCommand"></value>
<value type="bool" key="Qt4ProjectManager.MakeStep.OverrideMakeflags">false</value>
</valuemap>
<value type="int" key="ProjectExplorer.BuildStepList.StepsCount">1</value>
<value type="QString" key="ProjectExplorer.ProjectConfiguration.DefaultDisplayName">Clean</value>
<value type="QString" key="ProjectExplorer.ProjectConfiguration.DisplayName">Clean</value>
<value type="QString" key="ProjectExplorer.ProjectConfiguration.Id">ProjectExplorer.BuildSteps.Clean</value>
</valuemap>
<value type="int" key="ProjectExplorer.BuildConfiguration.BuildStepListCount">2</value>
<value type="bool" key="ProjectExplorer.BuildConfiguration.ClearSystemEnvironment">false</value>
<valuelist type="QVariantList" key="ProjectExplorer.BuildConfiguration.UserEnvironmentChanges"/>
<value type="QString" key="ProjectExplorer.ProjectConfiguration.DisplayName">Profile</value>
<value type="QString" key="ProjectExplorer.ProjectConfiguration.Id">Qt4ProjectManager.Qt4BuildConfiguration</value>
<value type="int" key="Qt4ProjectManager.Qt4BuildConfiguration.BuildConfiguration">0</value>
</valuemap>
<value type="int" key="ProjectExplorer.Target.BuildConfigurationCount">3</value>
<valuemap type="QVariantMap" key="ProjectExplorer.Target.DeployConfiguration.0">
<valuemap type="QVariantMap" key="ProjectExplorer.BuildConfiguration.BuildStepList.0">
<value type="int" key="ProjectExplorer.BuildStepList.StepsCount">0</value>
<value type="QString" key="ProjectExplorer.ProjectConfiguration.DefaultDisplayName">Deploy</value>
<value type="QString" key="ProjectExplorer.ProjectConfiguration.DisplayName">Deploy</value>
<value type="QString" key="ProjectExplorer.ProjectConfiguration.Id">ProjectExplorer.BuildSteps.Deploy</value>
</valuemap>
<value type="int" key="ProjectExplorer.BuildConfiguration.BuildStepListCount">1</value>
<value type="QString" key="ProjectExplorer.ProjectConfiguration.Id">ProjectExplorer.DefaultDeployConfiguration</value>
</valuemap>
<value type="int" key="ProjectExplorer.Target.DeployConfigurationCount">1</value>
<valuemap type="QVariantMap" key="ProjectExplorer.Target.PluginSettings"/>
<valuemap type="QVariantMap" key="ProjectExplorer.Target.RunConfiguration.0">
<value type="QString" key="Analyzer.Perf.CallgraphMode">dwarf</value>
<valuelist type="QVariantList" key="Analyzer.Perf.Events">
<value type="QString">cpu-cycles</value>
</valuelist>
<valuelist type="QVariantList" key="Analyzer.Perf.ExtraArguments"/>
<value type="int" key="Analyzer.Perf.Frequency">250</value>
<valuelist type="QVariantList" key="Analyzer.Perf.RecordArguments">
<value type="QString">-e</value>
<value type="QString">cpu-cycles</value>
<value type="QString">--call-graph</value>
<value type="QString">dwarf,4096</value>
<value type="QString">-F</value>
<value type="QString">250</value>
</valuelist>
<value type="QString" key="Analyzer.Perf.SampleMode">-F</value>
<value type="bool" key="Analyzer.Perf.Settings.UseGlobalSettings">true</value>
<value type="int" key="Analyzer.Perf.StackSize">4096</value>
<value type="bool" key="Analyzer.QmlProfiler.AggregateTraces">false</value>
<value type="bool" key="Analyzer.QmlProfiler.FlushEnabled">false</value>
<value type="uint" key="Analyzer.QmlProfiler.FlushInterval">1000</value>
<value type="QString" key="Analyzer.QmlProfiler.LastTraceFile"></value>
<value type="bool" key="Analyzer.QmlProfiler.Settings.UseGlobalSettings">true</value>
<valuelist type="QVariantList" key="Analyzer.Valgrind.AddedSuppressionFiles"/>
<value type="bool" key="Analyzer.Valgrind.Callgrind.CollectBusEvents">false</value>
<value type="bool" key="Analyzer.Valgrind.Callgrind.CollectSystime">false</value>
<value type="bool" key="Analyzer.Valgrind.Callgrind.EnableBranchSim">false</value>
<value type="bool" key="Analyzer.Valgrind.Callgrind.EnableCacheSim">false</value>
<value type="bool" key="Analyzer.Valgrind.Callgrind.EnableEventToolTips">true</value>
<value type="double" key="Analyzer.Valgrind.Callgrind.MinimumCostRatio">0.01</value>
<value type="double" key="Analyzer.Valgrind.Callgrind.VisualisationMinimumCostRatio">10</value>
<value type="bool" key="Analyzer.Valgrind.FilterExternalIssues">true</value>
<value type="QString" key="Analyzer.Valgrind.KCachegrindExecutable">kcachegrind</value>
<value type="int" key="Analyzer.Valgrind.LeakCheckOnFinish">1</value>
<value type="int" key="Analyzer.Valgrind.NumCallers">25</value>
<valuelist type="QVariantList" key="Analyzer.Valgrind.RemovedSuppressionFiles"/>
<value type="int" key="Analyzer.Valgrind.SelfModifyingCodeDetection">1</value>
<value type="bool" key="Analyzer.Valgrind.Settings.UseGlobalSettings">true</value>
<value type="bool" key="Analyzer.Valgrind.ShowReachable">false</value>
<value type="bool" key="Analyzer.Valgrind.TrackOrigins">true</value>
<value type="QString" key="Analyzer.Valgrind.ValgrindExecutable">valgrind</value>
<valuelist type="QVariantList" key="Analyzer.Valgrind.VisibleErrorKinds">
<value type="int">0</value>
<value type="int">1</value>
<value type="int">2</value>
<value type="int">3</value>
<value type="int">4</value>
<value type="int">5</value>
<value type="int">6</value>
<value type="int">7</value>
<value type="int">8</value>
<value type="int">9</value>
<value type="int">10</value>
<value type="int">11</value>
<value type="int">12</value>
<value type="int">13</value>
<value type="int">14</value>
</valuelist>
<value type="int" key="PE.EnvironmentAspect.Base">2</value>
<valuelist type="QVariantList" key="PE.EnvironmentAspect.Changes"/>
<value type="QString" key="ProjectExplorer.CustomExecutableRunConfiguration.Executable"></value>
<value type="QString" key="ProjectExplorer.ProjectConfiguration.Id">ProjectExplorer.CustomExecutableRunConfiguration</value>
<value type="QString" key="ProjectExplorer.RunConfiguration.BuildKey"></value>
<value type="QString" key="RunConfiguration.Arguments"></value>
<value type="bool" key="RunConfiguration.Arguments.multi">false</value>
<value type="QString" key="RunConfiguration.OverrideDebuggerStartup"></value>
<value type="bool" key="RunConfiguration.UseCppDebugger">false</value>
<value type="bool" key="RunConfiguration.UseCppDebuggerAuto">true</value>
<value type="bool" key="RunConfiguration.UseMultiProcess">false</value>
<value type="bool" key="RunConfiguration.UseQmlDebugger">false</value>
<value type="bool" key="RunConfiguration.UseQmlDebuggerAuto">true</value>
<value type="QString" key="RunConfiguration.WorkingDirectory"></value>
<value type="QString" key="RunConfiguration.WorkingDirectory.default"></value>
</valuemap>
<value type="int" key="ProjectExplorer.Target.RunConfigurationCount">1</value>
</valuemap>
</data>
<data>
<variable>ProjectExplorer.Project.TargetCount</variable>
<value type="int">1</value>
<value type="int">3</value>
</data>
<data>
<variable>ProjectExplorer.Project.Updater.FileVersion</variable>

@ -0,0 +1,21 @@
#include <QMetaType>
#include <QString>
#ifndef ROUTEITEM_H
#define ROUTEITEM_H
struct routeItem{
QString placeName;
QString url;
QString cateId;
QString startTime;
QString endTime;
QString traffic;
int distance;
int timeCost;
QString description;
struct routeItem * next;
};
typedef struct routeItem RouteItem;
#endif // ROUTEITEM_H

@ -6,9 +6,126 @@ CustomizeWidget::CustomizeWidget(QWidget *parent) :
ui(new Ui::CustomizeWidget)
{
ui->setupUi(this);
num = 1;
limit = 15;
mainLayout = new QVBoxLayout();
lineList = (QHBoxLayout **)malloc(sizeof(QHBoxLayout *) * limit);
labelList = (QLabel **)malloc(sizeof(QLabel *) * limit);
placeBtnList = (QPushButton **)malloc(sizeof(QPushButton *) * limit);
addBtnList = (QPushButton **)malloc(sizeof(QPushButton *) * limit);
delBtnList = (QPushButton **)malloc(sizeof(QPushButton *) * limit);
for(int i = 0; i < limit; i++)
{
nameList.append("");
urlList.append("");
cateIdList.append("");
}
spaceList = (QHBoxLayout **)malloc(sizeof(QHBoxLayout *) * (limit - 1));
spacers = (QLabel **)malloc(sizeof(QLabel *) * (limit - 1));
this->setLayout(mainLayout);
for (int i = 0; i < limit; i++)
{
lineList[i] = new QHBoxLayout();
labelList[i] = new QLabel(QString::number(i+1));
labelList[i]->setAlignment(Qt::AlignCenter);
placeBtnList[i] = new QPushButton("");
addBtnList[i] = new QPushButton("add");
delBtnList[i] = new QPushButton("del");
mainLayout->addLayout(lineList[i]);
lineList[i]->setAlignment(Qt::AlignTop);
lineList[i]->addWidget(labelList[i],1);
lineList[i]->addWidget(placeBtnList[i],12);
lineList[i]->addWidget(addBtnList[i],2);
lineList[i]->addWidget(delBtnList[i],2);
connect(placeBtnList[i], &QPushButton::clicked, this, [=](){setBtn(i);});
connect(addBtnList[i], &QPushButton::clicked, this, [=](){addAt(i);});
connect(delBtnList[i], &QPushButton::clicked, this, [=](){delAt(i);});
if (i > 0)
{
visibleAt(i, false);
}
}
for (int i = 0; i < (limit - 1); i++)
{
spaceList[i] = new QHBoxLayout();
spacers[i] = new QLabel();
spaceList[i]->addWidget(spacers[i]);
mainLayout->addLayout(spaceList[i]);
}
}
CustomizeWidget::~CustomizeWidget()
{
delete ui;
}
void CustomizeWidget::visibleAt(int index, bool flag)
{
labelList[index]->setVisible(flag);
placeBtnList[index]->setVisible(flag);
addBtnList[index]->setVisible(flag);
delBtnList[index]->setVisible(flag);
// if (flag)
// placeBtnList[index]->setText("Choose Place");
// else
// placeBtnList[index]->setText("");
}
void CustomizeWidget::addAt(int index)
{
if (num < limit)
{
num++;
visibleAt(num - 1, true);
spacers[limit - num]->setVisible(false);
qDebug() << "Add at " << QString::number(index);
for (int i = num - 1; i > index + 1; i--)
{
nameList[i] = nameList[i - 1];
placeBtnList[i]->setText(nameList[i]);
}
nameList[index + 1] = "";
placeBtnList[index + 1]->setText(nameList[index + 1]);
}
}
void CustomizeWidget::delAt(int index)
{
if (num > 1)
{
num--;
visibleAt(num, false);
spacers[limit - num - 1]->setVisible(true);
qDebug() << "Del at " << QString::number(index);
for (int i = index; i < num ; i++)
{
nameList[i] = nameList[i + 1];
placeBtnList[i]->setText(nameList[i]);
}
nameList[num] = "";
placeBtnList[num]->setText(nameList[index + 1]);
}
}
void CustomizeWidget::setBtn(int index)
{
PopWidget * w = new PopWidget();
w->show();
connect(w->getConfirmBtn(), &QPushButton::clicked, this, [=](){w->close();});
connect(w->getCancelBtn(), &QPushButton::clicked, this, [=](){w->close();});
qDebug() << "Set Btn" << QString::number(index);
}

@ -2,6 +2,15 @@
#define CUSTOMIZEWIDGET_H
#include <QWidget>
#include <QHBoxLayout>
#include <QVBoxLayout>
#include <QGridLayout>
#include <QScrollArea>
#include <QPushButton>
#include <QLabel>
#include <QString>
#include <QDebug>
#include "popwidget.h"
#if _MSC_VER >= 1600
#pragma execution_character_set("utf-8")
@ -19,8 +28,31 @@ public:
explicit CustomizeWidget(QWidget *parent = nullptr);
~CustomizeWidget();
void visibleAt(int index, bool flag);
void addAt(int index);
void delAt(int index);
void setBtn(int index);
QString getBtn(int index);
private:
Ui::CustomizeWidget *ui;
int num;
int limit;
QStringList nameList;
QStringList urlList;
QStringList cateIdList;
QHBoxLayout **lineList;
QLabel **labelList;
QPushButton **placeBtnList;
QPushButton **addBtnList;
QPushButton ** delBtnList;
QHBoxLayout ** spaceList;
QLabel **spacers;
QVBoxLayout *mainLayout;
};
#endif // CUSTOMIZEWIDGET_H

@ -170,7 +170,7 @@ void ListWidget::setHotList()
queryMeituan.bindValue(":url", url);
QStringList list = queryMeituanDatabase(queryMeituan);//获得图片链接和店铺名和id
imgDownloader *imgDownload = new imgDownloader();
QString imgPath = "D:/Study/SE/project/images/" + labelToDb[cate] + list[2] + ".png";
QString imgPath = "./images/" + labelToDb[cate] + list[2] + ".png";
imgDownload->downloadFileFromUrl(list[0], imgPath);
btn = setBtn(btn, imgPath, list[1]);
connect(btn, &QToolButton::clicked, this, [=](){web->loadPage(url, cate); subWidget->setVisible(false); web->setVisible(true);});

@ -21,7 +21,7 @@ MainWidget::MainWidget(QWidget *parent) :
homeWidget = new HomeWidget(this);
userWidget = new UserWidget(this);
searchWidget = new SearchResultWidget(this);
searchWidget = new SearchWidget(this);
userWidget->setVisible(false);
searchWidget->setVisible(false);

@ -9,7 +9,7 @@
#include <QMessageBox>
#include "homewidget.h"
#include "userwidget.h"
#include "searchresultwidget.h"
#include "searchwidget.h"
#if _MSC_VER >= 1600
#pragma execution_character_set("utf-8")
@ -42,7 +42,7 @@ private:
HomeWidget *homeWidget;
UserWidget *userWidget;
SearchResultWidget *searchWidget;
SearchWidget *searchWidget;
public slots:
void switchToHome();

@ -37,10 +37,13 @@ void MainWindow::switchToMain()
{
//setMaximumSize(QSize(1330,1000));
// showMaximized();
WaitStart();
loginWidget->deleteLater();
mainWidget = new MainWidget();
mainWidget = new MainWidget(this);
WaitEnd();
resize(1600, 900);
setCentralWidget(mainWidget);
move ((QApplication::desktop()->width() - this->width())/2,(QApplication::desktop()->height() - this->height())/2);
}
else
{
@ -91,6 +94,18 @@ void MainWindow::switchToLogin()
setCentralWidget(loginWidget);
}
void MainWindow::WaitStart()
{
waitProcess = new QProcess(this);
QStringList arguments;
waitProcess->start("./Wait/Wait.exe");
}
void MainWindow::WaitEnd()
{
waitProcess->kill();
}
MainWindow::~MainWindow()
{
delete ui;

@ -2,6 +2,8 @@
#define MAINWINDOW_H
#include <QMainWindow>
#include <QDesktopWidget>
#include <QProcess>
#include "loginwidget.h"
#include "mainwidget.h"
#include "loginmanager.h"
@ -32,6 +34,7 @@ private:
RegisterWidget *registerWidget;
RegisterManager * registerManager;
QProcess * waitProcess;
public slots:
void switchToMain();
@ -39,5 +42,7 @@ public slots:
void switchToLogin();
void registerConfirmSwitch();
void clickGetVerificationCodeButton();
void WaitStart();
void WaitEnd();
};
#endif // MAINWINDOW_H

@ -0,0 +1,242 @@
#include "popwidget.h"
#include "ui_popwidget.h"
PopWidget::PopWidget(QWidget *parent) :
QWidget(parent),
ui(new Ui::PopWidget)
{
ui->setupUi(this);
this->setWindowModality(Qt::ApplicationModal);
this->setFixedSize(QSize(400,1000));
chosen.append("");
chosen.append("");
chosen.append("");
showLimit = 15;
currentPage = 1;
offset = 0;
btnList = (QToolButton **)malloc(sizeof(QToolButton *) * showLimit);
mainLayout = new QVBoxLayout();
notify = new QLabel("请从您的收藏夹中选择场所添加到路线中");
notify->setAlignment(Qt::AlignCenter);
searchLine = new QHBoxLayout();
searchBar = new QLineEdit();
searchBtn = new QPushButton("搜索");
returnSearchBtn = new QPushButton("退出搜索");
scroll = new QScrollArea();
scrollWidget = new QWidget;
scrollLayout = new QVBoxLayout();
pageLine = new QHBoxLayout();
up = new QPushButton("上一页");
down = new QPushButton("下一页");
chosenLabel = new QLabel("您还未选择场所...");
chosenLabel->setAlignment(Qt::AlignLeft);
closeLine = new QHBoxLayout();
confirm = new QPushButton("确认");
cancel = new QPushButton("取消");
this->setLayout(mainLayout);
mainLayout->addWidget(notify);
mainLayout->addLayout(searchLine);
mainLayout->addWidget(scroll);
mainLayout->addLayout(pageLine);
mainLayout->addWidget(chosenLabel);
mainLayout->addLayout(closeLine);
searchLine->addWidget(searchBar, 6);
searchLine->addWidget(searchBtn, 1);
// scrollWidget->setLayout(scrollLayout);
// //查询数据库,进行按钮布局
// scroll->setWidget(scrollWidget);
getTotalNum();
setScreen();
pageLine->addWidget(up);
pageLine->addWidget(down);
closeLine->addWidget(confirm);
closeLine->addWidget(cancel);
connect(up, &QPushButton::clicked, this, &PopWidget::pageUp);
connect(down, &QPushButton::clicked, this, &PopWidget::pageDown);
}
PopWidget::~PopWidget()
{
delete ui;
}
QPushButton * PopWidget::getConfirmBtn()
{
return confirm;
}
QPushButton * PopWidget::getCancelBtn()
{
return cancel;
}
//从店铺收藏夹获取店铺
void PopWidget::getTotalNum()
{
//查询条目数
QSqlQuery query(userDb);
query.prepare("select count(*) as num from favPlaces where userId = :id");
query.bindValue(":id", Id);
query.exec();
query.next();
qDebug() << " popWidget totalNum:" << query.value("num");
totalNum = query.value("num").value<qlonglong>();
pageNum = (totalNum + showLimit - 1)/showLimit;
}
void PopWidget::queryDatabase()
{
QSqlQuery query(userDb);
query.prepare("select * from favPlaces where userId = :id limit :offset, :limit");
query.bindValue(":id", Id);
query.bindValue(":offset", offset);
query.bindValue(":limit", showLimit);
query.exec();
int i = 0;
while(query.next()==true)
{
QVariant detail = query.value("url");
urlList.append(detail.value<QString>());
i++;
}
currentNum = i;
qDebug() << "popWidget currentNum:" << currentNum;
}
QToolButton * PopWidget::setBtn(QToolButton *btn, QString text, QString img)
{
if(img != "")
btn->setIcon(QIcon(img));
btn->setText(text);
btn->setToolButtonStyle(Qt::ToolButtonTextBesideIcon);
btn->setIconSize(QSize(100,200));
btn->setFixedSize(300,100);
return btn;
}
void PopWidget::setBtns()
{
int i = 0;
for (i; i < currentNum; i++)
{
int index = i;
//下载图片到本地
// QString imgPath = "D:/Study/SE/project/images/" + cateList[currentCate] + QString::number(idList[index]) + ".png";
// imgDownloader *download = new imgDownloader();
// download->downloadFileFromUrl(imgList[index], imgPath);
btnList[index] = setBtn(btnList[index], urlList[index], "D:/Study/SE/project/images/transparent.png");
disconnect(btnList[index], 0, 0, 0);
connect(btnList[index], &QToolButton::clicked, this, [=](){setChosen(index);});
}
}
void PopWidget::setChosen(int index)
{
if (urlList[index] != chosen[1])
{
// chosen[0] = nameList[index];
chosen[1] = urlList[index];
// chosen[2] = imgList[index];
qDebug() << "popWidget chosen:" + chosen[0] + chosen[1] + chosen[2];
chosenLabel->setText("您选择了" + chosen[1]);
}
else
{
chosen[0] = "";
chosen[1] = "";
chosen[2] = "";
chosenLabel->setText("您还未选择场所...");
}
}
void PopWidget::setScreen()
{
qDebug() << "popWidget currentPage:" << currentPage;
qDebug() << "popWidget offset:" << offset;
urlList.clear();
imgList.clear();
nameList.clear();
for (int i = 0; i < showLimit; i++)
btnList[i] = new QToolButton();
queryDatabase();
qDebug("query success");
setBtns();
qDebug("setBtns success");
scroll->takeWidget();
scrollWidget->deleteLater();
scrollWidget = new QWidget();
scrollLayout->deleteLater();
scrollLayout = new QVBoxLayout();
scrollWidget->setLayout(scrollLayout);
for (int i = 0; i < currentNum; i++)
{
scrollLayout->addWidget(btnList[i]);
}
scroll->setWidget(scrollWidget);
}
void PopWidget::pageUp()
{
currentPage--;
if (currentPage < 1)
{
currentPage = 1;
qDebug("这是第一页");
}
else
{
offset -= showLimit;
rollTop();
setScreen();
}
}
void PopWidget::pageDown()
{
currentPage++;
if (currentPage > pageNum)
{
currentPage = pageNum;
qDebug("已经是最后一页了!");
}
else
{
offset += showLimit;
rollTop();
setScreen();
}
}
void PopWidget::rollTop()
{
QScrollBar *scrollBar = scroll->verticalScrollBar();
scrollBar->setValue(scrollBar->minimum());
}

@ -0,0 +1,86 @@
#ifndef POPWIDGET_H
#define POPWIDGET_H
#include <QWidget>
#include <QPushButton>
#include <QVBoxLayout>
#include <QHBoxLayout>
#include <QLineEdit>
#include <QLabel>
#include <QScrollArea>
#include <QSqlQuery>
#include <QDebug>
#include <QToolButton>
#include <QIcon>
#include <QScrollBar>
#include "cglobal.h"
#if _MSC_VER >= 1600
#pragma execution_character_set("utf-8")
#endif
namespace Ui {
class PopWidget;
}
class PopWidget : public QWidget
{
Q_OBJECT
public:
explicit PopWidget(QWidget *parent = nullptr);
~PopWidget();
QPushButton * getConfirmBtn();
QPushButton * getCancelBtn();
void getTotalNum();
void queryDatabase();
void pageUp();
void pageDown();
void setScreen();
void setBtns();
QToolButton * setBtn(QToolButton *btn, QString text, QString img);
void setChosen(int index);
void rollTop();
private:
Ui::PopWidget *ui;
bool inSearch;
QStringList chosen;//被选中的场所在当,有三个值name,url,img
int totalNum;//收藏夹总共有多少条
int showLimit;//一页中最多显示条数
int pageNum;//总页数
int currentPage;//当前所在页数
int currentNum;//当前页中条目数量
int offset;//query语句中的偏移量
QStringList nameList;
QStringList urlList;
QStringList imgList;
QToolButton **btnList;
QVBoxLayout *mainLayout;
QLabel *notify;
QHBoxLayout *searchLine;
QLineEdit *searchBar;
QPushButton *searchBtn;
QPushButton *returnSearchBtn;
QScrollArea *scroll;
QWidget *scrollWidget;
QVBoxLayout *scrollLayout;
QHBoxLayout *pageLine;
QPushButton *up;
QPushButton *down;
QLabel *chosenLabel;
QHBoxLayout *closeLine;
QPushButton *confirm;
QPushButton *cancel;
};
#endif // POPWIDGET_H

@ -0,0 +1,21 @@
<ui version="4.0">
<author/>
<comment/>
<exportmacro/>
<class>PopWidget</class>
<widget class="QWidget" name="PopWidget">
<property name="geometry">
<rect>
<x>0</x>
<y>0</y>
<width>400</width>
<height>300</height>
</rect>
</property>
<property name="windowTitle">
<string>Form</string>
</property>
</widget>
<pixmapfunction/>
<connections/>
</ui>

@ -151,10 +151,7 @@ void RecommendWidget::setBtns()
{
int index = i * column + j;
//下载图片到本地
// QString imgPath = ":/images" + idList[index] + ".jpg";
QString imgPath = "C:/Users/13648/Desktop/Trip-in-Chang-sha/ChangShaTour/images/"+labelToDb[cateIdList[index]] + QString::number(idList[index]) + ".png";
// qDebug() << QDir::currentPath();
// QString imgPath = "D:/Study/SE/project/images/" + labelToDb[cateIdList[index]] + QString::number(idList[index]) + ".png";
QString imgPath = "./images/" + labelToDb[cateIdList[index]] + QString::number(idList[index]) + ".png";
imgDownloader *download = new imgDownloader();
download->downloadFileFromUrl(imgList[index], imgPath);
qDebug()<<imgList[index];

@ -0,0 +1,95 @@
#include "route.h"
Route::Route()
{
routeItems=(RouteItem*)malloc(sizeof (RouteItem));
routeItems->next=NULL;
}
//route结构体使用方式和query类似
//Route * oneRoute = getAllItems();
//while (oneRoute->next!=NULL)
//{
// oneRoute=oneRoute->next;
// url=oneRoute->url;
//}
RouteItem * Route::getAllItems()
{
return this->routeItems;
}
int Route::getRouteId()
{
return this->routeId;
}
QString Route::getRouteName()
{
return this->routeName;
}
int Route::getUserId()
{
return this->userId;
}
void Route::setRouteName(QString name)
{
this->routeName = name;
}
void Route::setUserId(int id)
{
this->userId=id;
}
void Route::setRouteId(int id)
{
this->routeId=id;
}
void Route::setAllItems(QStringList titleList,QStringList urlList,QStringList cateIdList,QStringList startTimeList,QStringList endTimeList,QStringList trafficList,int * distanceList,int * timeCostList,QStringList descriptionList)
{
RouteItem * head= routeItems;
RouteItem * p;
int totalSize=titleList.size();
int i;
for(i=0;i<totalSize;i++)
{
p=(RouteItem * )malloc(sizeof (RouteItem));
p->placeName = titleList[i];
p->url = urlList[i];
p->cateId = cateIdList[i];
p->startTime = startTimeList[i];
p->endTime = endTimeList[i];
p->traffic = trafficList[i];
p->distance = distanceList[i];
p->timeCost = timeCostList[i];
p->description = descriptionList[i];
p->next = NULL;
head->next = p;
head=head->next;
}
}
//删除和添加都是根据位置位置从1开始计数
RouteItem * Route::addItem(RouteItem * oneItem,int locate)
{
RouteItem * p = routeItems;
int i = 0;
while(p->next != NULL&&i<locate)
{
p = p->next;
i++;
}
oneItem->next = p->next;
p->next=oneItem;
return routeItems;
}
RouteItem * Route::deleteItem(int locate)
{
RouteItem * p = routeItems;
RouteItem * pre = routeItems;
int i = 0;
while(p->next != NULL&&i<locate)
{
pre = p;
p = p->next;
i++;
}
pre->next = p->next;
free(p);
return routeItems;
}

@ -0,0 +1,28 @@
#ifndef ROUTE_H
#define ROUTE_H
#include <RouteItem.h>
#include <QStringList>
class Route
{
public:
Route();
struct routeItem * getAllItems();
//距离和时间都用int表示单位m/km时间s/min统一一下
void setAllItems(QStringList titleList,QStringList urlList,QStringList cateIdList,QStringList startTimeList,QStringList endTimeList,QStringList trafficList,int *distanceList,int *timeCostList,QStringList descriptionList);
int getRouteId();
int getUserId();
QString getRouteName();
void setRouteName(QString name);
void setRouteId(int id);
void setUserId(int id);
RouteItem * addItem(RouteItem * oneItem,int locate);
RouteItem * deleteItem(int locate);
private:
QString name;
int userId=0;//路线没有用户时默认为0
int routeId=0;//路线编号默认为0
struct routeItem *routeItems;
};
#endif // ROUTE_H

@ -1,311 +0,0 @@
#include "searchresultwidget.h"
SearchResultWidget::SearchResultWidget(QWidget *parent) : QWidget(parent)
{
showLimit = 15;
cateList.append("food");
cateList.append("entertainment");
cateList.append("hotel");
cateList.append("attractions");
cateList.append("sport");
lengthList = (int *)malloc(sizeof(int) * cateList.length());
idList = (int *)malloc(sizeof(int) * showLimit);
mainLayout = new QVBoxLayout();
subWidget = new QWidget();
web = new WebWidget();
nullWidget = new QLabel("抱歉,未找到您要的结果。");
subLayout = new QVBoxLayout();
rtn = new QPushButton("返回");
scroll = new QScrollArea();
scrollWidget = new QWidget();
scrollLayout = new QVBoxLayout();
btnList = (QToolButton **)malloc(sizeof(QToolButton *) * showLimit);
for (int i = 0; i <showLimit; i++)
{
int index = i;
btnList[index] = new QToolButton();
btnList[index] = setBtn(btnList[index], "D:/Study/SE/project/images/transparent.png", "");
}
switchLine = new QHBoxLayout();
up = new QPushButton("上一页");
down = new QPushButton("下一页");
//设置布局
this->setLayout(mainLayout);
mainLayout->addWidget(subWidget);
mainLayout->addWidget(web);
mainLayout->addWidget(nullWidget);
web->setVisible(false);
nullWidget->setVisible(false);
subWidget->setLayout(subLayout);
subLayout->addWidget(rtn);
subLayout->addWidget(scroll);
subLayout->addLayout(switchLine);
switchLine->addWidget(up);
switchLine->addWidget(down);
connect(web->getReturnBtn(), &QPushButton::clicked, this, &SearchResultWidget::returnWeb);
connect(up, &QPushButton::clicked, this, &SearchResultWidget::pageUp);
connect(down, &QPushButton::clicked, this, &SearchResultWidget::pageDown);
}
QPushButton *SearchResultWidget::getReturnBtn()
{
return rtn;
}
void SearchResultWidget::sendInput(QString input)
{
this->segment = input;
qDebug() << "segment:" <<segment;
}
void SearchResultWidget::getTotalNum()
{
//查询条目数
QSqlQuery query(meituanDb);
int length = cateList.length();
for (int i = 0; i < length; i++)
{
query.prepare("select count(*) as num from " + cateList[i] + " where title like :segment");
query.bindValue(":segment", "%" + segment + "%");
query.exec();
query.next();
qDebug() << cateList[i] + " totalNum:" << query.value("num");
lengthList[i] = query.value("num").value<qlonglong>();
totalNum += query.value("num").value<qlonglong>();
}
pageNum = (totalNum + showLimit - 1)/showLimit;
page2cate = (int *)malloc(sizeof(int) * pageNum);
page2offset = (int *)malloc(sizeof(int) * pageNum);
}
void SearchResultWidget::queryDatabase(QSqlQuery query)
{
query.exec();
int i = currentHead;
while(query.next()==true && i < showLimit)
{
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 cateId = query.value("cateId");
// QVariant avgprice = query.value("avgprice");
QString name = title.value<QString>();
QString score = QString::number(avgscore.value<double>());
QString commentNum = QString::number(comments.value<qlonglong>());
QString addr = address.value<QString>();
// QString price = QString::number(avgprice.value<qlonglong>());
QString text = name + "\n" + score + "" + commentNum + "条评论\n" + addr + "\n";// + "人均" + price + "元";
QString cateid = cateId.value<QString>();
idList[i] = id.value<qlonglong>();
urlList.append(detail.value<QString>());
imgList.append(frontimg.value<QString>());
textList.append(text);
cateIdList.append(cateid);
i++;
}
currentQueryLength = i - currentHead;
}
QToolButton *SearchResultWidget::setBtn(QToolButton *btn, const QString iconPath, const QString text)
{
if(iconPath != "")
btn->setIcon(QIcon(iconPath));
btn->setText(text);
btn->setToolButtonStyle(Qt::ToolButtonTextBesideIcon);
btn->setIconSize(QSize(100,200));
btn->setFixedSize(1230,200);
return btn;
}
void SearchResultWidget::setBtns()
{
int i = currentHead;
// qDebug() << "currentHead:" << currentHead;
// qDebug() << "currentQueryLength:" << currentQueryLength;
for (i; i < currentHead + currentQueryLength; i++)
{
int index = i;
//下载图片到本地
QString imgPath = "D:/Study/SE/project/images/" + cateList[currentCate] + QString::number(idList[index]) + ".png";
imgDownloader *download = new imgDownloader();
download->downloadFileFromUrl(imgList[index], imgPath);
btnList[index] = setBtn(btnList[index], imgPath, textList[index]);
qDebug() << "info:" << cateList[currentCate] << idList[index] << urlList[index] << imgList[index];
// btnList[index]->setVisible(true);
disconnect(btnList[index], 0, 0, 0);
connect(btnList[index], &QToolButton::clicked, this, [=](){web->loadPage(urlList[index], cateIdList[index]); subWidget->setVisible(false); web->setVisible(true); nullWidget->setVisible(false);});
}
for (i; i < showLimit; i++)
{
int index = i;
btnList[index] = setBtn(btnList[index], "D:/Study/SE/project/images/transparent.png", "");
// btnList[index]->setVisible(false);
disconnect(btnList[index], 0, 0, 0);
}
// offset += currentQueryLength;
// currentHead += currentQueryLength;
}
void SearchResultWidget::querySet()
{
rollTop();
//重置存储查询信息的列表
urlList.clear();
imgList.clear();
textList.clear();
cateIdList.clear();
currentHead = 0;
currentQueryLength = 0;
currentCate = page2cate[currentPage - 1];
currentOffset = page2offset[currentPage - 1];
// subLayout->removeWidget(scroll);
scroll->takeWidget();
scrollWidget->deleteLater();
scrollWidget = new QWidget();
scrollLayout->deleteLater();
scrollLayout = new QVBoxLayout();
scrollWidget->setLayout(scrollLayout);
qDebug() << "currentPage:" << currentPage;
QSqlQuery query(meituanDb);
while (currentHead < showLimit)
{
//判断是否换表
if (currentOffset >= lengthList[currentCate])
{
currentCate += 1;
currentOffset = 0;
if (currentCate >= cateList.length())
break;
}
//查询数据
query.prepare("select * from " + cateList[currentCate] + " where title like :segment limit :offset , :showLimit");
query.bindValue(":segment", "%" + segment + "%");
query.bindValue(":offset", currentOffset);
qDebug() << "currentCate:" << currentCate;
// qDebug() << "offset:" << offset;
query.bindValue(":showLimit", showLimit);
queryDatabase(query);
// qDebug() << "query success";
//设置按钮
setBtns();
// qDebug() << "set buttons success";
//设置滚动界面布局
for (int i = currentHead; i < currentHead + currentQueryLength; i++)
{
scrollLayout->addWidget(btnList[i]);
}
currentOffset += currentQueryLength;
currentHead += currentQueryLength;
}
page2cate[currentPage] = currentCate;
page2offset[currentPage] = currentOffset;
scroll->setWidget(scrollWidget);
}
void SearchResultWidget::showResult()
{
totalNum = 0;
pageNum = 0;
getTotalNum();
qDebug() << "totalNum:" << totalNum;
qDebug() << "pageNum:" << pageNum;
currentPage = 1;
currentCate = 0;
currentOffset = 0;
page2cate[0] = currentCate;
page2offset[0] = currentOffset;
if (totalNum)
{
querySet();
subWidget->setVisible(true);
nullWidget->setVisible(false);
}
else
{
subWidget->setVisible(false);
nullWidget->setVisible(true);
}
web->setVisible(false);
}
void SearchResultWidget::returnWeb()
{
subWidget->setVisible(true);
web->setVisible(false);
nullWidget->setVisible(false);
}
void SearchResultWidget::pageUp()
{
currentPage--;
if (currentPage < 1)
{
currentPage = 1;
qDebug("这是第一页");
}
else
{
rollTop();
querySet();
}
}
void SearchResultWidget::pageDown()
{
currentPage++;
if (currentPage > pageNum)
{
currentPage = pageNum;
qDebug("已经是最后一页了!");
}
else
{
rollTop();
querySet();
}
}
void SearchResultWidget::rollTop()
{
QScrollBar *scrollBar = scroll->verticalScrollBar();
scrollBar->setValue(scrollBar->minimum());
}

@ -1,87 +0,0 @@
#ifndef SEARCHRESULTWIDGET_H
#define SEARCHRESULTWIDGET_H
#include <QWidget>
#include <QPushButton>
#include <QToolButton>
#include <QVBoxLayout>
#include <QHBoxLayout>
#include <QSqlQuery>
#include <QVariant>
#include <QDebug>
#include <QScrollArea>
#include <QScrollBar>
#include <QLabel>
#include "databaseconnector.h"
#include "webwidget.h"
#include "imgdownloader.h"
class SearchResultWidget : public QWidget
{
Q_OBJECT
public:
explicit SearchResultWidget(QWidget *parent = nullptr);
void sendInput(QString input);
void queryDatabase(QSqlQuery query);
void getTotalNum();
void showResult();
QPushButton *getReturnBtn();
QToolButton *setBtn(QToolButton *btn, const QString iconPath, const QString text);
void querySet();
void setBtns();
void pageUp();
void pageDown();
void returnWeb();
void rollTop();
signals:
private:
QString segment;
QStringList urlList;
QStringList imgList;
QStringList textList;
int *idList;
QStringList cateIdList;
QStringList cateList;
int totalNum;
int *lengthList;
int pageNum;
int showLimit;
int currentPage;
int currentHead;
int currentQueryLength;
int currentCate;
int currentOffset;
int *page2cate;
int *page2offset;
QVBoxLayout *mainLayout;
QWidget *subWidget;
WebWidget *web;
QLabel *nullWidget;
QVBoxLayout *subLayout;
QPushButton *rtn;
QScrollArea *scroll;
QWidget *scrollWidget;
QVBoxLayout *scrollLayout;
QToolButton **btnList;
QHBoxLayout *switchLine;
QPushButton *up;
QPushButton *down;
};
#endif // SEARCHRESULTWIDGET_H

@ -1,4 +1,4 @@
#include "searchwidget.h"
#include "searchwidget.h"
#include "ui_searchwidget.h"
SearchWidget::SearchWidget(QWidget *parent) :
@ -6,9 +6,315 @@ SearchWidget::SearchWidget(QWidget *parent) :
ui(new Ui::SearchWidget)
{
ui->setupUi(this);
showLimit = 15;
cateList.append("food");
cateList.append("entertainment");
cateList.append("hotel");
cateList.append("attractions");
cateList.append("sport");
lengthList = (int *)malloc(sizeof(int) * cateList.length());
idList = (int *)malloc(sizeof(int) * showLimit);
mainLayout = new QVBoxLayout();
subWidget = new QWidget();
web = new WebWidget();
nullWidget = new QLabel("抱歉,未找到您要的结果。");
subLayout = new QVBoxLayout();
rtn = new QPushButton("返回");
scroll = new QScrollArea();
scrollWidget = new QWidget();
scrollLayout = new QVBoxLayout();
btnList = (QToolButton **)malloc(sizeof(QToolButton *) * showLimit);
switchLine = new QHBoxLayout();
up = new QPushButton("上一页");
down = new QPushButton("下一页");
//设置布局
this->setLayout(mainLayout);
mainLayout->addWidget(subWidget);
mainLayout->addWidget(web);
mainLayout->addWidget(nullWidget);
web->setVisible(false);
nullWidget->setVisible(false);
subWidget->setLayout(subLayout);
subLayout->addWidget(rtn);
subLayout->addWidget(scroll);
subLayout->addLayout(switchLine);
switchLine->addWidget(up);
switchLine->addWidget(down);
connect(web->getReturnBtn(), &QPushButton::clicked, this, &SearchWidget::returnWeb);
connect(up, &QPushButton::clicked, this, &SearchWidget::pageUp);
connect(down, &QPushButton::clicked, this, &SearchWidget::pageDown);
}
SearchWidget::~SearchWidget()
{
delete ui;
}
QPushButton *SearchWidget::getReturnBtn()
{
return rtn;
}
void SearchWidget::sendInput(QString input)
{
this->segment = input;
qDebug() << "segment:" <<segment;
}
void SearchWidget::getTotalNum()
{
//查询条目数
QSqlQuery query(meituanDb);
int length = cateList.length();
for (int i = 0; i < length; i++)
{
query.prepare("select count(*) as num from " + cateList[i] + " where title like :segment");
query.bindValue(":segment", "%" + segment + "%");
query.exec();
query.next();
qDebug() << cateList[i] + " totalNum:" << query.value("num");
lengthList[i] = query.value("num").value<qlonglong>();
totalNum += query.value("num").value<qlonglong>();
}
pageNum = (totalNum + showLimit - 1)/showLimit;
page2cate = (int *)malloc(sizeof(int) * pageNum);
page2offset = (int *)malloc(sizeof(int) * pageNum);
}
void SearchWidget::queryDatabase(QSqlQuery query)
{
query.exec();
int i = currentHead;
while(query.next()==true && i < showLimit)
{
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 cateId = query.value("cateId");
// QVariant avgprice = query.value("avgprice");
QString name = title.value<QString>();
QString score = QString::number(avgscore.value<double>());
QString commentNum = QString::number(comments.value<qlonglong>());
QString addr = address.value<QString>();
// QString price = QString::number(avgprice.value<qlonglong>());
QString text = name + "\n" + score + "" + commentNum + "条评论\n" + addr + "\n";// + "人均" + price + "元";
QString cateid = cateId.value<QString>();
idList[i] = id.value<qlonglong>();
urlList.append(detail.value<QString>());
imgList.append(frontimg.value<QString>());
textList.append(text);
cateIdList.append(cateid);
i++;
}
currentQueryLength = i - currentHead;
}
QToolButton *SearchWidget::setBtn(QToolButton *btn, const QString iconPath, const QString text)
{
if(iconPath != "")
btn->setIcon(QIcon(iconPath));
btn->setText(text);
btn->setToolButtonStyle(Qt::ToolButtonTextBesideIcon);
btn->setIconSize(QSize(100,200));
btn->setFixedSize(1230,200);
return btn;
}
void SearchWidget::setBtns()
{
int i = currentHead;
// qDebug() << "currentHead:" << currentHead;
// qDebug() << "currentQueryLength:" << currentQueryLength;
for (i; i < currentHead + currentQueryLength; i++)
{
int index = i;
//下载图片到本地
QString imgPath = "./images/" + cateList[currentCate] + QString::number(idList[index]) + ".png";
imgDownloader *download = new imgDownloader();
download->downloadFileFromUrl(imgList[index], imgPath);
btnList[index] = setBtn(btnList[index], imgPath, textList[index]);
qDebug() << "info:" << cateList[currentCate] << idList[index] << urlList[index] << imgList[index];
// btnList[index]->setVisible(true);
disconnect(btnList[index], 0, 0, 0);
connect(btnList[index], &QToolButton::clicked, this, [=](){web->loadPage(urlList[index], cateIdList[index]); subWidget->setVisible(false); web->setVisible(true); nullWidget->setVisible(false);});
}
for (i; i < showLimit; i++)
{
int index = i;
btnList[index] = setBtn(btnList[index], "./images/transparent.png", "");
// btnList[index]->setVisible(false);
disconnect(btnList[index], 0, 0, 0);
}
// offset += currentQueryLength;
// currentHead += currentQueryLength;
}
void SearchWidget::querySet()
{
rollTop();
//重置存储查询信息的列表
urlList.clear();
imgList.clear();
textList.clear();
cateIdList.clear();
currentHead = 0;
currentQueryLength = 0;
currentCate = page2cate[currentPage - 1];
currentOffset = page2offset[currentPage - 1];
for (int i = 0; i <showLimit; i++)
{
int index = i;
btnList[index] = new QToolButton();
}
// subLayout->removeWidget(scroll);
scroll->takeWidget();
scrollWidget->deleteLater();
scrollWidget = new QWidget();
scrollLayout->deleteLater();
scrollLayout = new QVBoxLayout();
scrollWidget->setLayout(scrollLayout);
qDebug() << "currentPage:" << currentPage;
QSqlQuery query(meituanDb);
while (currentHead < showLimit)
{
//判断是否换表
if (currentOffset >= lengthList[currentCate])
{
currentCate += 1;
currentOffset = 0;
if (currentCate >= cateList.length())
break;
}
//查询数据
query.prepare("select * from " + cateList[currentCate] + " where title like :segment limit :offset , :showLimit");
query.bindValue(":segment", "%" + segment + "%");
query.bindValue(":offset", currentOffset);
qDebug() << "currentCate:" << currentCate;
// qDebug() << "offset:" << offset;
query.bindValue(":showLimit", showLimit);
queryDatabase(query);
// qDebug() << "query success";
//设置按钮
setBtns();
// qDebug() << "set buttons success";
//设置滚动界面布局
for (int i = currentHead; i < currentHead + currentQueryLength; i++)
{
scrollLayout->addWidget(btnList[i]);
}
currentOffset += currentQueryLength;
currentHead += currentQueryLength;
}
page2cate[currentPage] = currentCate;
page2offset[currentPage] = currentOffset;
scroll->setWidget(scrollWidget);
}
void SearchWidget::showResult()
{
totalNum = 0;
pageNum = 0;
getTotalNum();
qDebug() << "totalNum:" << totalNum;
qDebug() << "pageNum:" << pageNum;
currentPage = 1;
currentCate = 0;
currentOffset = 0;
page2cate[0] = currentCate;
page2offset[0] = currentOffset;
if (totalNum)
{
querySet();
subWidget->setVisible(true);
nullWidget->setVisible(false);
}
else
{
subWidget->setVisible(false);
nullWidget->setVisible(true);
}
web->setVisible(false);
}
void SearchWidget::returnWeb()
{
subWidget->setVisible(true);
web->setVisible(false);
nullWidget->setVisible(false);
}
void SearchWidget::pageUp()
{
currentPage--;
if (currentPage < 1)
{
currentPage = 1;
qDebug("这是第一页");
}
else
{
rollTop();
querySet();
}
}
void SearchWidget::pageDown()
{
currentPage++;
if (currentPage > pageNum)
{
currentPage = pageNum;
qDebug("已经是最后一页了!");
}
else
{
rollTop();
querySet();
}
}
void SearchWidget::rollTop()
{
QScrollBar *scrollBar = scroll->verticalScrollBar();
scrollBar->setValue(scrollBar->minimum());
}

@ -1,7 +1,24 @@
#ifndef SEARCHWIDGET_H
#ifndef SEARCHWIDGET_H
#define SEARCHWIDGET_H
#include <QWidget>
#include <QPushButton>
#include <QToolButton>
#include <QVBoxLayout>
#include <QHBoxLayout>
#include <QSqlQuery>
#include <QVariant>
#include <QDebug>
#include <QScrollArea>
#include <QScrollBar>
#include <QLabel>
#include "databaseconnector.h"
#include "webwidget.h"
#include "imgdownloader.h"
#if _MSC_VER >= 1600
#pragma execution_character_set("utf-8")
#endif
namespace Ui {
class SearchWidget;
@ -15,8 +32,63 @@ public:
explicit SearchWidget(QWidget *parent = nullptr);
~SearchWidget();
void sendInput(QString input);
void queryDatabase(QSqlQuery query);
void getTotalNum();
void showResult();
QPushButton *getReturnBtn();
QToolButton *setBtn(QToolButton *btn, const QString iconPath, const QString text);
void querySet();
void setBtns();
void pageUp();
void pageDown();
void returnWeb();
void rollTop();
private:
Ui::SearchWidget *ui;
QString segment;
QStringList urlList;
QStringList imgList;
QStringList textList;
int *idList;
QStringList cateIdList;
QStringList cateList;
int totalNum;
int *lengthList;
int pageNum;
int showLimit;
int currentPage;
int currentHead;
int currentQueryLength;
int currentCate;
int currentOffset;
int *page2cate;
int *page2offset;
QVBoxLayout *mainLayout;
QWidget *subWidget;
WebWidget *web;
QLabel *nullWidget;
QVBoxLayout *subLayout;
QPushButton *rtn;
QScrollArea *scroll;
QWidget *scrollWidget;
QVBoxLayout *scrollLayout;
QToolButton **btnList;
QHBoxLayout *switchLine;
QPushButton *up;
QPushButton *down;
};
#endif // SEARCHWIDGET_H

@ -261,7 +261,7 @@ void SortWidget::Screen(QString str)
queryDatabase(query, "select * from " + screenCode + " limit " + QString::number(row));
else
queryDatabase(query, "select * from " + screenCode + " where cateId=\"" + str + "\" limit " + QString::number(row));
size = size < row? size: row;
size = fmin(size, row);
scroll->takeWidget();
subWidget->deleteLater();
@ -320,7 +320,7 @@ void SortWidget::nextPage()
queryDatabase(query, "select * from " + screenCode + " limit " + QString::number(row * (pageNumber + 1)) + "," + QString::number(row));
else
queryDatabase(query, "select * from " + screenCode + " where cateId=\"" + screenStr + "\" limit " + QString::number(row * (pageNumber + 1)) + "," + QString::number(row));
size = size < row? size: row;
size = fmin(size, row);
scroll->takeWidget();
subWidget->deleteLater();
@ -354,7 +354,7 @@ void SortWidget::backPage()
queryDatabase(query, "select * from " + screenCode + " limit " + QString::number(row * (pageNumber - 1)) + "," + QString::number(row));
else
queryDatabase(query, "select * from " + screenCode + " where cateId=\"" + screenStr + "\" limit " + QString::number(row * (pageNumber - 1)) + "," + QString::number(row));
size = size < row? size: row;
size = fmin(size, row);
scroll->takeWidget();
subWidget->deleteLater();

@ -0,0 +1,38 @@
#include "waitwidget.h"
#include "ui_waitwidget.h"
WaitWidget::WaitWidget(QWidget *parent) :
QWidget(parent),
ui(new Ui::WaitWidget)
{
ui->setupUi(this);
background = new QLabel(this);
this->setWindowOpacity(0.8);
setWindowFlags(Qt::Dialog | Qt::FramelessWindowHint);//设置为对话框风格,并且去掉边框
setWindowModality(Qt::WindowModal);//设置为模式对话框,同时在构造该对话框时要设置父窗口
SetBackground("./softImages/waitGirl.gif");
}
WaitWidget::~WaitWidget()
{
delete ui;
}
void WaitWidget::SetBackground(QString url)
{
background->setStyleSheet("background-color: transparent;");
//新建QMovie对象并用资源文件初始化
QMovie * mov = new QMovie(url);
//setMoive
background->setMovie(mov);
background->setScaledContents(true);
//播放动画
mov->start();
}
void WaitWidget::resizeEvent(QResizeEvent *event)
{
background->resize(this->size());
}

@ -0,0 +1,29 @@
#ifndef WAITWIDGET_H
#define WAITWIDGET_H
#include <QWidget>
#include <QLabel>
#include <QMovie>
namespace Ui {
class WaitWidget;
}
class WaitWidget : public QWidget
{
Q_OBJECT
public:
explicit WaitWidget(QWidget *parent = nullptr);
~WaitWidget();
void SetBackground(QString);
void resizeEvent(QResizeEvent *event);
private:
Ui::WaitWidget *ui;
QLabel * background;
};
#endif // WAITWIDGET_H

@ -0,0 +1,21 @@
<ui version="4.0">
<author/>
<comment/>
<exportmacro/>
<class>WaitWidget</class>
<widget class="QWidget" name="WaitWidget">
<property name="geometry">
<rect>
<x>0</x>
<y>0</y>
<width>400</width>
<height>300</height>
</rect>
</property>
<property name="windowTitle">
<string>Form</string>
</property>
</widget>
<pixmapfunction/>
<connections/>
</ui>

Binary file not shown.
Loading…
Cancel
Save