!133 fix some errors

Merge pull request !133 from likehomedream/UIFIX
This commit is contained in:
KevinDuan 2024-06-01 02:41:42 +00:00 committed by Gitee
commit 240a29e998
No known key found for this signature in database
GPG Key ID: 173E9B9CA92EEF8F
3 changed files with 39 additions and 15 deletions

View File

@ -18,7 +18,7 @@ buildResultWidget::buildResultWidget(QWidget *parent) :
m_buildResult->setText(tr("Theme finished!"));
QLabel *guideLabel = new QLabel();
QString str = "<a href=\"http://172.20.107.254:8082/openlogin\">" + tr("Upload theme platform") + "</a>";
QString str = "<a href=\"https://developer.kylinos.cn/openlogin\">" + tr("Upload theme platform") + "</a>";
guideLabel->setText(str);
guideLabel->setTextFormat(Qt::RichText);
guideLabel->setCursor(Qt::PointingHandCursor);

View File

@ -34,34 +34,39 @@ void DataCollect::sendMainWindowKdkDataAsync(WindowButton theme)
case m_GlobalTheme:
QtConcurrent::run([=]() {
KTrackData *node = kdk_dia_data_init(KEVENTSOURCE_DESKTOP,KEVENT_CLICK);
kdk_dia_upload_default(node,"globaltheme_click","mainwindow");
kdk_dia_upload_default(node,"mainwindow_globaltheme_click","mainwindow");
//释放内存
kdk_dia_data_free(node);
});
break;
case m_IconTheme:
QtConcurrent::run([=]() {
KTrackData *node = kdk_dia_data_init(KEVENTSOURCE_DESKTOP,KEVENT_CLICK);
kdk_dia_upload_default(node,"icontheme_click","mainwindow");
kdk_dia_upload_default(node,"mainwindow_icontheme_click","mainwindow");
kdk_dia_data_free(node);
});
break;
case m_CursorTheme:
QtConcurrent::run([=]() {
KTrackData *node = kdk_dia_data_init(KEVENTSOURCE_DESKTOP,KEVENT_CLICK);
kdk_dia_upload_default(node,"cursortheme_click","mainwindow");
kdk_dia_upload_default(node,"mainwindow_cursortheme_click","mainwindow");
kdk_dia_data_free(node);
});
break;
case m_PlymouthTheme:
QtConcurrent::run([=]() {
KTrackData *node = kdk_dia_data_init(KEVENTSOURCE_DESKTOP,KEVENT_CLICK);
kdk_dia_upload_default(node,"plymouththeme_click","mainwindow");
kdk_dia_upload_default(node,"mainwindow_plymouththeme_click","mainwindow");
kdk_dia_data_free(node);
});
break;
case m_GrubTheme:
QtConcurrent::run([=]() {
KTrackData *node = kdk_dia_data_init(KEVENTSOURCE_DESKTOP,KEVENT_CLICK);
kdk_dia_upload_default(node,"grubtheme_click","mainwindow");
kdk_dia_upload_default(node,"mainwindow_grubtheme_click","mainwindow");
kdk_dia_data_free(node);
});
break;
default:
break;
}
@ -75,33 +80,38 @@ void DataCollect::sendNavigationKdkDataAsync(DataCollect::NavigationButton theme
case n_GlobalTheme:
QtConcurrent::run([=]() {
KTrackData *node = kdk_dia_data_init(KEVENTSOURCE_DESKTOP,KEVENT_CLICK);
kdk_dia_upload_default(node,"globaltheme_click","navigationbar");
kdk_dia_upload_default(node,"navigationbar_globaltheme_click","navigationbar");
kdk_dia_data_free(node);
});
break;
case n_IconTheme:
QtConcurrent::run([=]() {
KTrackData *node = kdk_dia_data_init(KEVENTSOURCE_DESKTOP,KEVENT_CLICK);
kdk_dia_upload_default(node,"icontheme_click","navigationbar");
kdk_dia_upload_default(node,"navigationbar_icontheme_click","navigationbar");
kdk_dia_data_free(node);
});
break;
case n_CursorTheme:
QtConcurrent::run([=]() {
KTrackData *node = kdk_dia_data_init(KEVENTSOURCE_DESKTOP,KEVENT_CLICK);
kdk_dia_upload_default(node,"cursortheme_click","navigationbar");
kdk_dia_upload_default(node,"navigationbar_cursortheme_click","navigationbar");
kdk_dia_data_free(node);
});
break;
case n_PlymouthTheme:
QtConcurrent::run([=]() {
KTrackData *node = kdk_dia_data_init(KEVENTSOURCE_DESKTOP,KEVENT_CLICK);
kdk_dia_upload_default(node,"plymouththeme_click","navigationbar");
kdk_dia_upload_default(node,"navigationbar_plymouththeme_click","navigationbar");
kdk_dia_data_free(node);
});
break;
case n_GrubTheme:
QtConcurrent::run([=]() {
KTrackData *node = kdk_dia_data_init(KEVENTSOURCE_DESKTOP,KEVENT_CLICK);
kdk_dia_upload_default(node,"grubtheme_click","navigationbar");
kdk_dia_upload_default(node,"navigationbar_grubtheme_click","navigationbar");
kdk_dia_data_free(node);
});
break;
default:
break;
}
@ -118,42 +128,49 @@ void DataCollect::sendGlobalThemeKdkDataAsync(DataCollect::GlobalThemeChangeWidg
kdk_dia_upload_default(node,"coverWidget_click","globaltheme");
kdk_dia_data_free(node);
});
break;
case g_WallPaperWidget:
QtConcurrent::run([=]() {
KTrackData *node = kdk_dia_data_init(KEVENTSOURCE_DESKTOP,KEVENT_CLICK);
kdk_dia_upload_default(node,"wallPaperWidget_click","globaltheme");
kdk_dia_data_free(node);
});
break;
case g_ExteriorWidget:
QtConcurrent::run([=]() {
KTrackData *node = kdk_dia_data_init(KEVENTSOURCE_DESKTOP,KEVENT_CLICK);
kdk_dia_upload_default(node,"exteriorWidget_click","globaltheme");
kdk_dia_data_free(node);
});
break;
case g_FilletWidget:
QtConcurrent::run([=]() {
KTrackData *node = kdk_dia_data_init(KEVENTSOURCE_DESKTOP,KEVENT_CLICK);
kdk_dia_upload_default(node,"filletWidget_click","globaltheme");
kdk_dia_data_free(node);
});
break;
case g_AccentColorWidget:
QtConcurrent::run([=]() {
KTrackData *node = kdk_dia_data_init(KEVENTSOURCE_DESKTOP,KEVENT_CLICK);
kdk_dia_upload_default(node,"accentColorWidget_click","globaltheme");
kdk_dia_data_free(node);
});
break;
case g_TransparencyWidget:
QtConcurrent::run([=]() {
KTrackData *node = kdk_dia_data_init(KEVENTSOURCE_DESKTOP,KEVENT_CLICK);
kdk_dia_upload_default(node,"transparencyWidget_click","globaltheme");
kdk_dia_data_free(node);
});
break;
case g_WindowFilletWidget:
QtConcurrent::run([=]() {
KTrackData *node = kdk_dia_data_init(KEVENTSOURCE_DESKTOP,KEVENT_CLICK);
kdk_dia_upload_default(node,"windowFilletWidget_click","globaltheme");
kdk_dia_data_free(node);
});
break;
default:
break;
}

View File

@ -195,10 +195,17 @@ void InfoCreateWidget::InfoProcess(){
m_warningMessage->setText("");
}
} else {
QPalette m_fontqpe;
m_fontqpe.setColor(QPalette::WindowText,Qt::red);
m_warningMessage->setPalette(m_fontqpe);
m_warningMessage->setText(tr("Input format error!"));
if (m_themeNameCNLineEdit->text().isEmpty()) {
QPalette m_fontqpe;
m_fontqpe.setColor(QPalette::WindowText, Qt::red);
m_warningMessage->setPalette(m_fontqpe);
m_warningMessage->setText(tr("Input is empty!"));
}else{
QPalette m_fontqpe;
m_fontqpe.setColor(QPalette::WindowText,Qt::red);
m_warningMessage->setPalette(m_fontqpe);
m_warningMessage->setText(tr("Input format error!"));
}
}
} else {
QPalette m_fontqpe;