MCPcopy Create free account
hub / github.com/cc20110101/RedisView / FeedBack

Method FeedBack

src/RedisView/AppView/FeedBack.cpp:11–55  ·  view source on GitHub ↗

Source from the content-addressed store, hash-verified

9#include "FeedBack.h"
10
11FeedBack::FeedBack(QWidget *parent) :
12 QDialog(parent) {
13
14 setWindowTitle(tr("反馈信息"));
15 QHBoxLayout *hBox_LB = new QHBoxLayout;
16 QLabel *lb_say = new QLabel(tr("请输入你要提交的内容..."));
17 hBox_LB->addWidget(lb_say);
18
19 QHBoxLayout *hBox_ED = new QHBoxLayout;
20 QTextEdit *te_infomation = new QTextEdit;
21 QString sPlaceholderText = tr("1、这个问题的详细描述,有何现象?");
22 sPlaceholderText += "\r\n";
23 sPlaceholderText += tr("2、是如何产生的,造成了什么影响?");
24 te_infomation->setPlaceholderText(sPlaceholderText);
25 hBox_ED->addWidget(te_infomation);
26
27 QHBoxLayout *hBox_LE = new QHBoxLayout;
28 QLabel *lb_contact = new QLabel(tr("联系方式: "));
29 QLineEdit *le_contact = new QLineEdit;
30 le_contact->setPlaceholderText(tr("留下您的QQ或手机号"));
31 hBox_LE->addWidget(lb_contact, 1);
32 hBox_LE->addWidget(le_contact, 3);
33
34 QHBoxLayout *hBox_BT = new QHBoxLayout;
35 QPushButton *OK = new QPushButton(tr("确定"));
36 QPushButton *Exit = new QPushButton(tr("取消"));
37 hBox_BT->addWidget(OK);
38 hBox_BT->addWidget(Exit);
39
40 QGridLayout *mainLayout = new QGridLayout;
41 mainLayout->addLayout(hBox_LB, 0, 0, 1, 6);
42 mainLayout->addLayout(hBox_ED, 1, 0, 5, 6);
43 mainLayout->addLayout(hBox_LE, 6, 0, 1, 6);
44 mainLayout->addLayout(hBox_BT, 7, 4, 1, 2);
45// mainLayout->setRowStretch(3, 1);
46// mainLayout->setColumnStretch(0, 1);
47// mainLayout->setColumnStretch(2, 1);
48
49 setLayout(mainLayout);
50
51 connect(OK, SIGNAL(clicked()), this, SLOT(onOK()));
52 connect(Exit, SIGNAL(clicked()), this, SLOT(onExit()));
53
54 te_infomation->setText(tr("感谢反馈,但是鉴于服务端成本压力,此功能暂时不实现,请到下载网站进行反馈,谢谢"));
55}
56
57void FeedBack::onOK() {
58 //发送信息,服务端很容易,但开源软件成本问题此处不实现

Callers

nothing calls this directly

Calls 1

setTextMethod · 0.45

Tested by

no test coverage detected