You cannot select more than 25 topics
Topics must start with a letter or number, can include dashes ('-') and can be up to 35 characters long.
27 lines
773 B
C
27 lines
773 B
C
|
|
#ifndef TOOLS_H
|
|
#define TOOLS_H
|
|
|
|
#include <QIcon>
|
|
#include <QString>
|
|
|
|
QIcon getDevIcon(QString states){
|
|
if (states == QString("正常运行")){
|
|
return QIcon(":/Static/fanNormal.png");
|
|
}else if (states == QString("通讯中断")){
|
|
return QIcon(":/Static/fanfanInterrupted.png");
|
|
}else if (states == QString("待机等风")){
|
|
return QIcon(":/Static/fanStandby.png");
|
|
}else if (states == QString("停机维护")){
|
|
return QIcon(":/Static/fanHutdown.png");
|
|
}else if (states == QString("故障停机")){
|
|
return QIcon(":/Static/fanError.png");
|
|
}else if (states == QString("启动")){
|
|
return QIcon(":/Static/fanRun.png");
|
|
}else{
|
|
return QIcon(":/Static/fanNormal.png");
|
|
}
|
|
}
|
|
|
|
#endif // TOOLS_H
|