From 6b21320aa30527543b9d3610c07f2642f40e60a2 Mon Sep 17 00:00:00 2001 From: vanhofen Date: Wed, 8 Oct 2014 11:21:56 +0200 Subject: [PATCH] plugins: add and use default hint icon; THX to fred_feuerstein Origin commit data ------------------ Commit: https://github.com/neutrino-images/ni-neutrino/commit/765ad18b07c1f22af5ed4ed1200afa883dd3cfd4 Author: vanhofen Date: 2014-10-08 (Wed, 08 Oct 2014) Origin message was: ------------------ - plugins: add and use default hint icon; THX to fred_feuerstein --- data/icons/Makefile.am | 1 + data/icons/hint_plugin.png | Bin 0 -> 2856 bytes src/gui/plugins.cpp | 8 ++++++-- src/gui/widget/icons.h | 3 +++ 4 files changed, 10 insertions(+), 2 deletions(-) create mode 100644 data/icons/hint_plugin.png diff --git a/data/icons/Makefile.am b/data/icons/Makefile.am index b865f5c4b..43eceae09 100644 --- a/data/icons/Makefile.am +++ b/data/icons/Makefile.am @@ -110,6 +110,7 @@ install_DATA += \ hint_osd.png \ hint_personalize.png \ hint_picview.png \ + hint_plugin.png \ hint_protection.png \ hint_radiomode.png \ hint_reboot.png \ diff --git a/data/icons/hint_plugin.png b/data/icons/hint_plugin.png new file mode 100644 index 0000000000000000000000000000000000000000..4e53b64260729d1968680364ce2b268a20de5582 GIT binary patch literal 2856 zcmV+@3)l3CP) z4+Itv->2#T000SaNLh0L02U3&26+ZX9H;ZSyjK>~BVuEe332PIUup};tTovLHp*DdMwW6V-kC>Y20WwEGgkfj__e!{sYh{XW-IS|ErLGGo9w2UUqccSqx; zz3-oX)qlr+YG9x*dg#c%zZ4J|132)`winjdZrtU_DFP<<0O)scR!6b{NX4K_UKqG} zW%yTbeX=>CwA;6osQf+Qn_K~Q@^(C&b% zpv>unfzr#Zk+ZmLxZ%=rOP`aF+L`W(|aaEuQQf&)M1Tl;VlaP~fR#i~mc|Wwby|bgyDfIY7 z7E}0`$7v~kwvWVoO#%Mod7P3FjGhsIH(s2Zw{6S1X5WL4%#`qS5Rn7{!_QE!o_LrE z3>=aMEc`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1WyW6^M9}#%8 zPtZf2C6%sqiw$UU#ji?s{MG4UYYl%NBO7ncKf)!L0Dtu(87;(MX1q`WY!8jIDE9e?dSM ziyD4=?15u$=vpj*>O+1)lzSs8%L^d~61o9}Z^PG6yh@P9DFZje){Jtp(umTb@H~Da z;W2h&M&rZCFX2+B`_jAht4}E0Jp^VyOIIh#sctw}k$?S>9W~9b6#7qH9<5&~d0WClFh61ESF zN;n}O%`2&{T#{VK5YfnC%yLeXSp4RJncK(;@OSH1#f3j^X)Xeg6xD-$a^>)mhFeve zRu1osx7A5kk!%#iSg*1QwFun9812Z6KW0#JJ>Gs<^^OG~uC?P$g>?!TZgbHRK9r*A zP%-@u9&7Zyw{CIZWse(jd5VBGEWi`o8Kjw)g^A3p^_JjCWEF5N{-SQnWr!k^bxfp5 z)%kG8NJP9AUptl`=y9Iuh&+h};zB1CQ)Au8(hoOcK%g%FHjMiGR6}7pC?x3Ew3^U& z+~U&)U@_7)x^2QNqte}I{C;WlUPndm^tppx%s2Wy2#?`-*rw{z>`;_pQkBaeM3|5FF0CZLqY0ZNj?V}kxgXMe=wW-gmVMqtU;DBP@`NMow1 z6_wd9f3s6vK|kJ+E2aF^<hide = false; plugin_data->type = CPlugins::P_TYPE_DISABLED; plugin_data->integration = CPlugins::I_TYPE_DISABLED; - plugin_data->hinticon = plugin_data->filename + "_hint"; + plugin_data->hinticon = NEUTRINO_ICON_HINT_PLUGIN; + + std::string _hintIcon = plugin_data->plugindir + "/" + plugin_data->filename + "_hint.png"; + if (access(_hintIcon.c_str(), F_OK) == 0) + plugin_data->hinticon = _hintIcon; for (int i = 0; i < linecount; i++) { @@ -294,7 +298,7 @@ bool CPlugins::parseCfg(plugin *plugin_data) inFile.close(); - std::string _hintIcon = plugin_data->plugindir + "/" + plugin_data->hinticon + ".png"; + _hintIcon = plugin_data->plugindir + "/" + plugin_data->hinticon + ".png"; if (access(_hintIcon.c_str(), F_OK) == 0) plugin_data->hinticon = _hintIcon; diff --git a/src/gui/widget/icons.h b/src/gui/widget/icons.h index 6a9be6880..1c671fc53 100644 --- a/src/gui/widget/icons.h +++ b/src/gui/widget/icons.h @@ -253,6 +253,9 @@ #define NEUTRINO_ICON_HINT_RESTORE "hint_restore" #define NEUTRINO_ICON_HINT_FACTORY "hint_factory" +/* plugins */ +#define NEUTRINO_ICON_HINT_PLUGIN "hint_plugin" + /* opkg manager */ #define NEUTRINO_ICON_CHECKMARK "checkmark" #define NEUTRINO_ICON_WARNING "warning"