Skip to content

Commit

Permalink
add flat icon theme
Browse files Browse the repository at this point in the history
  • Loading branch information
sonichy committed Mar 15, 2019
1 parent da71027 commit 5a0fee9
Show file tree
Hide file tree
Showing 22 changed files with 24 additions and 3 deletions.
Binary file added icon/Flat/01d.png
Loading
Sorry, something went wrong. Reload?
Sorry, we cannot display this file.
Sorry, this file is invalid so it cannot be displayed.
Binary file added icon/Flat/01n.png
Loading
Sorry, something went wrong. Reload?
Sorry, we cannot display this file.
Sorry, this file is invalid so it cannot be displayed.
Binary file added icon/Flat/02d.png
Loading
Sorry, something went wrong. Reload?
Sorry, we cannot display this file.
Sorry, this file is invalid so it cannot be displayed.
Binary file added icon/Flat/02n.png
Loading
Sorry, something went wrong. Reload?
Sorry, we cannot display this file.
Sorry, this file is invalid so it cannot be displayed.
Binary file added icon/Flat/03d.png
Loading
Sorry, something went wrong. Reload?
Sorry, we cannot display this file.
Sorry, this file is invalid so it cannot be displayed.
Binary file added icon/Flat/03n.png
Loading
Sorry, something went wrong. Reload?
Sorry, we cannot display this file.
Sorry, this file is invalid so it cannot be displayed.
Binary file added icon/Flat/04d.png
Loading
Sorry, something went wrong. Reload?
Sorry, we cannot display this file.
Sorry, this file is invalid so it cannot be displayed.
Binary file added icon/Flat/04n.png
Loading
Sorry, something went wrong. Reload?
Sorry, we cannot display this file.
Sorry, this file is invalid so it cannot be displayed.
Binary file added icon/Flat/09d.png
Loading
Sorry, something went wrong. Reload?
Sorry, we cannot display this file.
Sorry, this file is invalid so it cannot be displayed.
Binary file added icon/Flat/09n.png
Loading
Sorry, something went wrong. Reload?
Sorry, we cannot display this file.
Sorry, this file is invalid so it cannot be displayed.
Binary file added icon/Flat/10d.png
Loading
Sorry, something went wrong. Reload?
Sorry, we cannot display this file.
Sorry, this file is invalid so it cannot be displayed.
Binary file added icon/Flat/10n.png
Loading
Sorry, something went wrong. Reload?
Sorry, we cannot display this file.
Sorry, this file is invalid so it cannot be displayed.
Binary file added icon/Flat/11d.png
Loading
Sorry, something went wrong. Reload?
Sorry, we cannot display this file.
Sorry, this file is invalid so it cannot be displayed.
Binary file added icon/Flat/11n.png
Loading
Sorry, something went wrong. Reload?
Sorry, we cannot display this file.
Sorry, this file is invalid so it cannot be displayed.
Binary file added icon/Flat/13d.png
Loading
Sorry, something went wrong. Reload?
Sorry, we cannot display this file.
Sorry, this file is invalid so it cannot be displayed.
Binary file added icon/Flat/13n.png
Loading
Sorry, something went wrong. Reload?
Sorry, we cannot display this file.
Sorry, this file is invalid so it cannot be displayed.
Binary file added icon/Flat/50d.png
Loading
Sorry, something went wrong. Reload?
Sorry, we cannot display this file.
Sorry, this file is invalid so it cannot be displayed.
Binary file added icon/Flat/50n.png
Loading
Sorry, something went wrong. Reload?
Sorry, we cannot display this file.
Sorry, this file is invalid so it cannot be displayed.
Binary file added icon/Flat/na.png
Loading
Sorry, something went wrong. Reload?
Sorry, we cannot display this file.
Sorry, this file is invalid so it cannot be displayed.
Binary file added icon/custom.png
Loading
Sorry, something went wrong. Reload?
Sorry, we cannot display this file.
Sorry, this file is invalid so it cannot be displayed.
20 changes: 20 additions & 0 deletions res.qrc
Original file line number Diff line number Diff line change
Expand Up @@ -38,5 +38,25 @@
<file>icon/Default/03d.png</file>
<file>icon/Default/09d.png</file>
<file>icon/Default/02n.png</file>
<file>icon/Flat/04n.png</file>
<file>icon/Flat/na.png</file>
<file>icon/Flat/09d.png</file>
<file>icon/Flat/03n.png</file>
<file>icon/Flat/50d.png</file>
<file>icon/Flat/04d.png</file>
<file>icon/Flat/03d.png</file>
<file>icon/Flat/11d.png</file>
<file>icon/Flat/01n.png</file>
<file>icon/Flat/09n.png</file>
<file>icon/Flat/50n.png</file>
<file>icon/Flat/02n.png</file>
<file>icon/Flat/10n.png</file>
<file>icon/Flat/13n.png</file>
<file>icon/Flat/11n.png</file>
<file>icon/Flat/13d.png</file>
<file>icon/Flat/02d.png</file>
<file>icon/Flat/10d.png</file>
<file>icon/Flat/01d.png</file>
<file>icon/custom.png</file>
</qresource>
</RCC>
7 changes: 4 additions & 3 deletions weatherplugin.cpp
Original file line number Diff line number Diff line change
Expand Up @@ -165,7 +165,7 @@ void WeatherPlugin::invokedMenuItem(const QString &itemKey, const QString &menuI

void WeatherPlugin::MBAbout()
{
QMessageBox aboutMB(QMessageBox::NoIcon, "HTYWeather 5.5", "About\n\nDeepin Linux Dock Weather Plugin.\nAuthor: 黄颖\nE-mail: [email protected]\nSource: https://github.com/sonichy/WEATHER_DDE_DOCK\nAPI: https://openweathermap.org/forecast5");
QMessageBox aboutMB(QMessageBox::NoIcon, "HTYWeather 5.6", "About\n\nDeepin Linux Dock Weather Plugin.\nAuthor: 黄颖\nE-mail: [email protected]\nSource: https://github.com/sonichy/WEATHER_DDE_DOCK\nAPI: https://openweathermap.org/forecast5");
aboutMB.setIconPixmap(QPixmap(":/icon/Default/01d.png"));
aboutMB.exec();
}
Expand Down Expand Up @@ -256,15 +256,16 @@ void WeatherPlugin::set()
QComboBox *comboBox_iconTheme = new QComboBox;
comboBox_iconTheme->addItem(QIcon(":icon/Default/01d.png"), "Default");
comboBox_iconTheme->addItem(QIcon(":icon/Simple/01d.png"), "Simple");
comboBox_iconTheme->addItem(QIcon(":icon/Flat/01d.png"), "Flat");
QString iconTheme = m_settings.value("IconTheme","").toString();
if(iconTheme == "" || !iconTheme.startsWith("/")){
comboBox_iconTheme->addItem("Custom");
comboBox_iconTheme->addItem(QIcon(":icon/custom.png"),"Custom");
}else{
comboBox_iconTheme->addItem(QIcon(iconTheme + "/01d.png"), iconTheme);
}
comboBox_iconTheme->setCurrentText(iconTheme);
connect(comboBox_iconTheme, static_cast<void(QComboBox::*)(int)>(&QComboBox::activated), [=](int index){
if(index == 2){
if(index == 3){
QString siconTheme = QFileDialog::getExistingDirectory(dialog, "Icon Theme", iconTheme);
if(siconTheme != ""){
QString icon_path = siconTheme + "/01d.png";
Expand Down

0 comments on commit 5a0fee9

Please sign in to comment.