]> jfr.im git - irc/kvirc/KVIrc.git/commitdiff
Fix favorites filter icon in servers dialog
authorSzymon Tomasz Stefanek <redacted>
Wed, 30 Dec 2015 05:30:21 +0000 (06:30 +0100)
committerSzymon Tomasz Stefanek <redacted>
Wed, 30 Dec 2015 05:30:21 +0000 (06:30 +0100)
CMakeLists.txt
src/kvirc/kernel/KviIconManager.cpp
src/modules/options/OptionsWidget_servers.cpp

index ba31958b7a5e84dd9aee6377086794d5c756fb53..ff1d448d6f90d126f69441bf8b8cb4c5b0f1e1ae 100644 (file)
@@ -33,7 +33,6 @@
 # GLOBAL DEFS
 ###############################################################################
 
-
 # Minimum cmake version
 cmake_minimum_required(VERSION 3.1.0)
 
index d9d4a6657b3ecff02dcd1e9f59a0caf99f3a9c9a..11b95fa860007cdb12371d34e73facad1bfda35f 100644 (file)
@@ -417,8 +417,8 @@ static const char * g_szIconNames[KviIconManager::IconCount] =
        "facepalm",            // 331
        "identity",            // 332
        "nickpopup",           // 333
-       "tools"                // 334
-       "favoriteOff"          // 335
+       "tools",               // 334
+       "favoriteoff"          // 335
 
 };
 
index c70f649725b98f1aa0da23644da19ecdf2b24ec8..4094e0c6be73eb7fe5c9a3d8547c4cae86bab3dd 100644 (file)
@@ -1271,7 +1271,7 @@ OptionsWidget_servers::OptionsWidget_servers(QWidget * parent)
        addWidgetToLayout(m_pFilterEdit,1,0,1,0);
 
        m_pShowFavoritesOnlyButton = new QToolButton(this);
-       m_pShowFavoritesOnlyButton->setIcon(*(g_pIconManager->getSmallIcon(KviIconManager::Favorite)));
+       m_pShowFavoritesOnlyButton->setIcon(*(g_pIconManager->getSmallIcon(KviIconManager::FavoriteOff)));
        m_pShowFavoritesOnlyButton->setCheckable(true);
        m_pShowFavoritesOnlyButton->setChecked(KVI_OPTION_BOOL(KviOption_boolShowFavoriteServersOnly));
        KviTalToolTip::add(m_pShowFavoritesOnlyButton,__tr2qs_ctx("<center>If this option is enabled, only servers you have favorited will be displayed</center>","options"));
@@ -2034,6 +2034,11 @@ void OptionsWidget_servers::updateFavoritesFilter(bool bSet)
                }
                network->setHidden(!uServers);
        }
+       
+       m_pShowFavoritesOnlyButton->setIcon(
+                       *(g_pIconManager->getSmallIcon(bSet ? KviIconManager::Favorite : KviIconManager::FavoriteOff))
+               );
+
 }
 
 void OptionsWidget_servers::copyServer()