-
Notifications
You must be signed in to change notification settings - Fork 7
/
Copy pathworldlistwea.h
64 lines (55 loc) · 1.51 KB
/
worldlistwea.h
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
37
38
39
40
41
42
43
44
45
46
47
48
49
50
51
52
53
54
55
56
57
58
59
60
61
62
63
64
#ifndef WORLDLISTWEA_H
#define WORLDLISTWEA_H
#include <QMainWindow>
#include <QLabel>
#include <QMap>
#include <QMainWindow>
#include<QNetworkAccessManager>
#include<QNetworkReply>
#include<QListWidget>
#include "citywithtemp.h"
namespace Ui {
class WorldListWea;
}
class WorldListWea : public QMainWindow
{
Q_OBJECT
public:
explicit WorldListWea(QWidget *parent = nullptr);
~WorldListWea();
QString updateCity;
QString updateTemp;
QString updateType;
QList<QString> cityList;
QList<QString> tempList;
QList<QString> typeList;
QList<QString> clickedCity;
protected:
void contextMenuEvent(QContextMenuEvent* event);
void mousePressEvent(QMouseEvent* event);
void mouseMoveEvent(QMouseEvent* event);
void setState();
void asiaCity();
void euCity();
void afCity();
void naCity();
void oaCity();
signals:
void BackButton();
void setData(QString text);
void sendIsland(QString);
private slots:
void on_pushButton_2_clicked();
void on_listWidget_itemDoubleClicked(QListWidgetItem *item);
void on_stateWidget_itemDoubleClicked();
void on_listBtn_clicked();
void getTemp(QString temp,QString city,QString type);
private:
Ui::WorldListWea *ui;
QMenu* mExitMenu; // 退出菜单
QAction* mExitAct; // 菜单项(退出)
QPoint mOffset; //窗口移动时,鼠标与左上角的偏移
QNetworkAccessManager* mNetAccessManager;
void AddItem(QString city, QString temp, QString pic);
};
#endif // WORLDLISTWEA_H