summaryrefslogtreecommitdiff
diff options
context:
space:
mode:
authorGeorge Hazan <george.hazan@gmail.com>2015-06-14 13:17:26 +0000
committerGeorge Hazan <george.hazan@gmail.com>2015-06-14 13:17:26 +0000
commit02ed4455c23e3562d71bfc80a0e2c4fede8708f1 (patch)
tree115a3d24e4a3877cd28bd4ff2d9d4011b790cc5f
parentc72584d6b934b37dbd18d5f15ffb24a140e1e3f2 (diff)
- all icolib services removed;
- IcoLib_* functions are bound directly to the code git-svn-id: http://svn.miranda-ng.org/main/trunk@14161 1316c22d-e87f-b044-9b9b-93d7a3e3ba9c
-rw-r--r--bin10/lib/mir_app.libbin7234 -> 7090 bytes
-rw-r--r--bin10/lib/mir_app64.libbin7300 -> 6830 bytes
-rw-r--r--bin12/lib/mir_app.libbin7234 -> 7090 bytes
-rw-r--r--bin12/lib/mir_app64.libbin7300 -> 6830 bytes
-rw-r--r--include/delphi/m_helpers.inc2
-rw-r--r--include/delphi/m_icolib.inc61
-rw-r--r--include/m_core.h2
-rw-r--r--include/m_icolib.h168
-rw-r--r--include/m_skin.h11
-rw-r--r--make_core_def.cmd4
-rw-r--r--plugins/Actman/dlgshare.pas2
-rw-r--r--plugins/Actman/i_opt_dlg2.inc2
-rw-r--r--plugins/Actman/ua/i_opt_dlg.inc6
-rw-r--r--plugins/Actman/ua/i_uaplaces.inc4
-rw-r--r--plugins/AddContactPlus/src/addcontact.cpp12
-rw-r--r--plugins/Alarms/src/icons.cpp10
-rw-r--r--plugins/Alarms/src/options.cpp2
-rw-r--r--plugins/AutoShutdown/src/frame.cpp2
-rw-r--r--plugins/AutoShutdown/src/settingsdlg.cpp2
-rw-r--r--plugins/AutoShutdown/src/shutdownsvc.cpp2
-rw-r--r--plugins/AutoShutdown/src/utils.cpp2
-rw-r--r--plugins/AvatarHistory/src/icolib.cpp6
-rw-r--r--plugins/BASS_interface/src/Main.cpp4
-rw-r--r--plugins/BasicHistory/src/BasicHistory.cpp2
-rw-r--r--plugins/BasicHistory/src/HistoryWindow.cpp16
-rw-r--r--plugins/BasicHistory/src/RichHtmlExport.cpp8
-rw-r--r--plugins/BossKeyPlus/src/BossKey.cpp4
-rw-r--r--plugins/BuddyExpectator/src/BuddyExpectator.cpp14
-rw-r--r--plugins/BuddyExpectator/src/options.cpp2
-rw-r--r--plugins/CSList/src/cslist.cpp6
-rw-r--r--plugins/ChangeKeyboardLayout/src/hook_events.cpp14
-rw-r--r--plugins/ChangeKeyboardLayout/src/main.cpp4
-rw-r--r--plugins/ChangeKeyboardLayout/src/stdafx.h2
-rw-r--r--plugins/ClientChangeNotify/src/ClientChangeNotify.cpp4
-rw-r--r--plugins/Clist_modern/src/modern_clc.cpp18
-rw-r--r--plugins/Clist_modern/src/modern_clui.cpp6
-rw-r--r--plugins/Clist_modern/src/modern_statusbar.cpp4
-rw-r--r--plugins/Clist_modern/src/modern_tbbutton.cpp4
-rw-r--r--plugins/Clist_modern/src/modern_viewmodebar.cpp2
-rw-r--r--plugins/Clist_nicer/src/CLCButton.cpp4
-rw-r--r--plugins/Clist_nicer/src/clistmod.cpp2
-rw-r--r--plugins/Clist_nicer/src/clui.cpp8
-rw-r--r--plugins/Clist_nicer/src/viewmodes.cpp2
-rw-r--r--plugins/CountryFlags/src/extraimg.cpp2
-rw-r--r--plugins/CountryFlags/src/icons.cpp4
-rw-r--r--plugins/CrashDumper/src/crshdmp_icons.cpp2
-rw-r--r--plugins/CrashDumper/src/ui.cpp8
-rw-r--r--plugins/Db3x_mmap/src/ui.cpp4
-rw-r--r--plugins/DbEditorPP/src/icons.cpp2
-rw-r--r--plugins/Db_autobackups/src/backup.cpp2
-rw-r--r--plugins/Dropbox/src/dropbox_icons.cpp2
-rw-r--r--plugins/FTPFileYM/src/utils.cpp2
-rw-r--r--plugins/FavContacts/src/menu.cpp2
-rw-r--r--plugins/FavContacts/src/services.cpp4
-rw-r--r--plugins/FileAsMessage/src/main.cpp4
-rw-r--r--plugins/FingerprintNG/src/fingerprint.cpp26
-rw-r--r--plugins/HistoryPlusPlus/hpp_options.pas2
-rw-r--r--plugins/HistoryStats/src/mu_common.cpp6
-rw-r--r--plugins/HistorySweeperLight/src/options.cpp6
-rw-r--r--plugins/IEView/src/Options.cpp2
-rw-r--r--plugins/Import/src/utils.cpp2
-rw-r--r--plugins/MenuItemEx/src/images.cpp2
-rw-r--r--plugins/MenuItemEx/src/main.cpp18
-rw-r--r--plugins/MessageState/src/messagestate.cpp8
-rw-r--r--plugins/MirLua/src/m_icolib.cpp8
-rw-r--r--plugins/MirOTR/src/icons.cpp21
-rw-r--r--plugins/MirOTR/src/icons.h4
-rw-r--r--plugins/MirOTR/src/mirotrmenu.cpp16
-rw-r--r--plugins/MirOTR/src/otr.cpp4
-rw-r--r--plugins/MirOTR/src/svcs_menu.cpp4
-rw-r--r--plugins/MirOTR/src/svcs_srmm.cpp26
-rw-r--r--plugins/MyDetails/src/frame.cpp14
-rw-r--r--plugins/MyDetails/src/mydetails.cpp2
-rw-r--r--plugins/NewAwaySysMod/src/SetAwayMsg.cpp2
-rw-r--r--plugins/NewXstatusNotify/src/main.cpp2
-rw-r--r--plugins/NewXstatusNotify/src/xstatus.cpp4
-rw-r--r--plugins/New_GPG/src/icons.cpp14
-rw-r--r--plugins/New_GPG/src/init.cpp6
-rw-r--r--plugins/NewsAggregator/Src/Icons.cpp2
-rw-r--r--plugins/NoHistory/src/icons.cpp6
-rw-r--r--plugins/Non-IM Contact/src/services.cpp4
-rw-r--r--plugins/NotesAndReminders/src/main.cpp2
-rw-r--r--plugins/NotesAndReminders/src/notes.cpp22
-rw-r--r--plugins/NotesAndReminders/src/options.cpp2
-rw-r--r--plugins/NotesAndReminders/src/reminders.cpp12
-rw-r--r--plugins/Nudge/src/main.cpp4
-rw-r--r--plugins/Nudge/src/options.cpp2
-rw-r--r--plugins/OpenFolder/src/openFolder.cpp2
-rw-r--r--plugins/PackUpdater/Src/Notifications.cpp4
-rw-r--r--plugins/PackUpdater/Src/PackUpdater.cpp4
-rw-r--r--plugins/Ping/src/utils.cpp16
-rw-r--r--plugins/PluginUpdater/src/DlgListNew.cpp12
-rw-r--r--plugins/PluginUpdater/src/DlgUpdate.cpp10
-rw-r--r--plugins/PluginUpdater/src/Notifications.cpp4
-rw-r--r--plugins/PluginUpdater/src/PluginUpdater.cpp2
-rw-r--r--plugins/Popup/src/actions.cpp22
-rw-r--r--plugins/Popup/src/history.cpp4
-rw-r--r--plugins/Popup/src/main.cpp18
-rw-r--r--plugins/Popup/src/notifications.cpp4
-rw-r--r--plugins/Popup/src/opt_adv.cpp2
-rw-r--r--plugins/Popup/src/opt_class.cpp6
-rw-r--r--plugins/Popup/src/opt_contacts.cpp20
-rw-r--r--plugins/Popup/src/opt_gen.cpp6
-rw-r--r--plugins/Popup/src/opt_skins.cpp4
-rw-r--r--plugins/Popup/src/popup_wnd2.cpp24
-rw-r--r--plugins/Popup/src/services.cpp6
-rw-r--r--plugins/Popup/src/srmm_menu.cpp8
-rw-r--r--plugins/QuickMessages/src/Utils.cpp4
-rw-r--r--plugins/QuickSearch/quicksearch.dpr5
-rw-r--r--plugins/QuickSearch/sr_frame.pas2
-rw-r--r--plugins/QuickSearch/sr_global.pas4
-rw-r--r--plugins/QuickSearch/sr_window.pas7
-rw-r--r--plugins/Quotes/src/IconLib.cpp2
-rw-r--r--plugins/Scriver/src/chat/window.cpp4
-rw-r--r--plugins/Scriver/src/globals.cpp18
-rw-r--r--plugins/Scriver/src/msgdialog.cpp8
-rw-r--r--plugins/Scriver/src/msgs.cpp2
-rw-r--r--plugins/SecureIM/src/loadicons.cpp6
-rw-r--r--plugins/SendScreenshotPlus/src/dlg_msgbox.cpp28
-rw-r--r--plugins/SendScreenshotPlus/src/global.h4
-rw-r--r--plugins/Sessions/Src/Options.cpp4
-rw-r--r--plugins/SimpleStatusMsg/src/awaymsg.cpp6
-rw-r--r--plugins/SimpleStatusMsg/src/msgbox.cpp12
-rw-r--r--plugins/SimpleStatusMsg/src/utils.cpp4
-rw-r--r--plugins/SmileyAdd/src/general.cpp4
-rw-r--r--plugins/SpellChecker/src/ardialog.cpp4
-rw-r--r--plugins/SpellChecker/src/options.cpp4
-rw-r--r--plugins/SpellChecker/src/spellchecker.cpp18
-rw-r--r--plugins/SpellChecker/src/utils.cpp4
-rw-r--r--plugins/StartupSilence/src/main.cpp8
-rw-r--r--plugins/StopSpamPlus/src/opt_proto.cpp4
-rw-r--r--plugins/TabSRMM/src/buttonsbar.cpp86
-rw-r--r--plugins/TabSRMM/src/chat/options.cpp2
-rw-r--r--plugins/TabSRMM/src/chat/window.cpp4
-rw-r--r--plugins/TabSRMM/src/globals.cpp4
-rw-r--r--plugins/TabSRMM/src/msgs.cpp18
-rw-r--r--plugins/TipperYM/src/popwin.cpp6
-rw-r--r--plugins/TipperYM/src/subst.cpp2
-rw-r--r--plugins/TopToolBar/src/toolbar.cpp14
-rw-r--r--plugins/TopToolBar/src/ttbopt.cpp4
-rw-r--r--plugins/TranslitSwitcher/src/Layoutproc.cpp2
-rw-r--r--plugins/UserInfoEx/src/Flags/svc_flagsicons.cpp6
-rw-r--r--plugins/UserInfoEx/src/classMAnnivDate.cpp4
-rw-r--r--plugins/UserInfoEx/src/classPsTreeItem.cpp10
-rw-r--r--plugins/UserInfoEx/src/ctrl_button.cpp2
-rw-r--r--plugins/UserInfoEx/src/ctrl_contact.cpp24
-rw-r--r--plugins/UserInfoEx/src/dlg_anniversarylist.cpp4
-rw-r--r--plugins/UserInfoEx/src/dlg_msgbox.cpp26
-rw-r--r--plugins/UserInfoEx/src/dlg_propsheet.cpp12
-rw-r--r--plugins/UserInfoEx/src/ex_import/dlg_ExImModules.cpp4
-rw-r--r--plugins/UserInfoEx/src/mir_icolib.cpp6
-rw-r--r--plugins/UserInfoEx/src/mir_menuitems.cpp52
-rw-r--r--plugins/UserInfoEx/src/psp_anniversary.cpp6
-rw-r--r--plugins/UserInfoEx/src/psp_base.cpp2
-rw-r--r--plugins/UserInfoEx/src/psp_contact.cpp8
-rw-r--r--plugins/UserInfoEx/src/psp_options.cpp6
-rw-r--r--plugins/UserInfoEx/src/svc_email.cpp2
-rw-r--r--plugins/UserInfoEx/src/svc_homepage.cpp2
-rw-r--r--plugins/UserInfoEx/src/svc_refreshci.cpp10
-rw-r--r--plugins/UserInfoEx/src/svc_reminder.cpp16
-rw-r--r--plugins/Utils.pas/mirutils.pas2
-rw-r--r--plugins/Utils.pas/sedit.pas2
-rw-r--r--plugins/Variables/src/help.cpp2
-rw-r--r--plugins/Watrack/i_gui.inc24
-rw-r--r--plugins/Watrack/lastfm/lastfm.pas4
-rw-r--r--plugins/Watrack/myshows/myshows.pas4
-rw-r--r--plugins/Watrack/popup/popups.pas6
-rw-r--r--plugins/Watrack/proto/proto.pas5
-rw-r--r--plugins/Watrack/stat/statlog.pas4
-rw-r--r--plugins/Watrack/waticons.pas3
-rw-r--r--plugins/Watrack/watrack.dpr2
-rw-r--r--plugins/Weather/src/weather_contacts.cpp8
-rw-r--r--plugins/Weather/src/weather_icons.cpp4
-rw-r--r--plugins/Weather/src/weather_mwin.cpp2
-rw-r--r--plugins/Weather/src/weather_popup.cpp2
-rw-r--r--plugins/Weather/src/weather_userinfo.cpp2
-rw-r--r--plugins/WhenWasIt/src/dlg_handlers.cpp12
-rw-r--r--plugins/WhenWasIt/src/icons.cpp2
-rw-r--r--plugins/WhenWasIt/src/icons.h2
-rw-r--r--plugins/WhenWasIt/src/services.cpp2
-rw-r--r--plugins/WinterSpeak/src/MirandaDialog.cpp2
-rw-r--r--plugins/YAMN/src/main.cpp4
-rw-r--r--plugins/YAPP/src/popwin.cpp6
-rw-r--r--plugins/YAPP/src/yapp.cpp4
-rw-r--r--plugins/mRadio/i_tray.inc9
-rw-r--r--plugins/mRadio/i_visual.inc10
-rw-r--r--plugins/mRadio/rframeapi.pas6
-rw-r--r--protocols/AimOscar/src/theme.cpp18
-rw-r--r--protocols/AimOscar/src/theme.h10
-rw-r--r--protocols/AimOscar/src/ui.cpp18
-rw-r--r--protocols/Dummy/src/dummy_options.cpp8
-rw-r--r--protocols/FacebookRM/src/captcha.cpp8
-rw-r--r--protocols/FacebookRM/src/dialogs.cpp2
-rw-r--r--protocols/FacebookRM/src/proto.cpp18
-rw-r--r--protocols/Gadu-Gadu/Gadu-Gadu_10.vcxproj4
-rw-r--r--protocols/Gadu-Gadu/Gadu-Gadu_12.vcxproj4
-rw-r--r--protocols/Gadu-Gadu/src/gg.h4
-rw-r--r--protocols/Gadu-Gadu/src/icolib.cpp12
-rw-r--r--protocols/Gadu-Gadu/src/links.cpp2
-rw-r--r--protocols/IRCG/src/options.cpp4
-rw-r--r--protocols/IcqOscarJ/src/icq_firstrun.cpp8
-rw-r--r--protocols/IcqOscarJ/src/icq_popups.cpp2
-rw-r--r--protocols/IcqOscarJ/src/icq_xstatus.cpp10
-rw-r--r--protocols/IcqOscarJ/src/loginpassword.cpp8
-rw-r--r--protocols/JabberG/src/jabber_frame.cpp6
-rw-r--r--protocols/JabberG/src/jabber_icolib.cpp16
-rw-r--r--protocols/JabberG/src/jabber_misc.cpp2
-rw-r--r--protocols/JabberG/src/jabber_userinfo.cpp2
-rw-r--r--protocols/MRA/src/MraIcons.cpp6
-rw-r--r--protocols/MSN/src/msn_lists.cpp2
-rw-r--r--protocols/MSN/src/msn_opts.cpp4
-rw-r--r--protocols/Omegle/src/communication.cpp4
-rw-r--r--protocols/Sametime/src/sametime.cpp8
-rw-r--r--protocols/Sametime/src/sametime.h4
-rw-r--r--protocols/SkypeWeb/src/skype_events.cpp10
-rw-r--r--protocols/SkypeWeb/src/skype_icons.cpp6
-rw-r--r--protocols/SkypeWeb/src/skype_trouter.cpp2
-rw-r--r--protocols/Steam/src/steam_dialogs.cpp12
-rw-r--r--protocols/Steam/src/steam_proto.cpp4
-rw-r--r--protocols/Steam/src/steam_utils.cpp2
-rw-r--r--protocols/Steam/src/steam_xstatus.cpp6
-rw-r--r--protocols/Tlen/src/tlen.cpp4
-rw-r--r--protocols/Tox/src/tox_icons.cpp8
-rw-r--r--protocols/Tox/src/tox_multimedia.cpp6
-rw-r--r--protocols/Tox/src/tox_options.cpp4
-rw-r--r--protocols/Tox/src/tox_utils.cpp2
-rw-r--r--protocols/VKontakte/src/misc.cpp2
-rw-r--r--protocols/VKontakte/src/vk_captcha.cpp8
-rw-r--r--protocols/VKontakte/src/vk_options.cpp40
-rw-r--r--protocols/VKontakte/src/vk_proto.cpp40
-rw-r--r--protocols/WhatsApp/src/proto.cpp2
-rw-r--r--protocols/Xfire/src/main.cpp4
-rw-r--r--protocols/Xfire/src/tools.cpp6
-rw-r--r--protocols/Yahoo/src/icolib.cpp4
-rw-r--r--src/core/stdchat/src/options.cpp2
-rw-r--r--src/core/stdmsg/src/msgdialog.cpp4
-rw-r--r--src/core/stdmsg/src/msglog.cpp4
-rw-r--r--src/core/stdmsg/src/msgs.cpp2
-rw-r--r--src/mir_app/src/DefaultExtraIcons.cpp2
-rw-r--r--src/mir_app/src/IcoLib.h2
-rw-r--r--src/mir_app/src/button.cpp5
-rw-r--r--src/mir_app/src/chat.h2
-rw-r--r--src/mir_app/src/chat_opts.cpp4
-rw-r--r--src/mir_app/src/clistmenus.cpp6
-rw-r--r--src/mir_app/src/clui.cpp6
-rw-r--r--src/mir_app/src/dbutils.cpp4
-rw-r--r--src/mir_app/src/genmenu.cpp12
-rw-r--r--src/mir_app/src/icolib.cpp145
-rw-r--r--src/mir_app/src/meta_addto.cpp2
-rw-r--r--src/mir_app/src/meta_edit.cpp2
-rw-r--r--src/mir_app/src/meta_main.cpp2
-rw-r--r--src/mir_app/src/mir_app.def6
-rw-r--r--src/mir_app/src/options_ei.cpp4
-rw-r--r--src/mir_app/src/protocols.cpp4
-rw-r--r--src/mir_app/src/protoopts.cpp6
-rw-r--r--src/mir_app/src/skin2opts.cpp33
-rw-r--r--src/mir_app/src/skinicons.cpp18
-rw-r--r--src/mir_app/src/usedIcons.cpp4
-rw-r--r--src/mir_core/src/ui_utils.cpp6
259 files changed, 1014 insertions, 1185 deletions
diff --git a/bin10/lib/mir_app.lib b/bin10/lib/mir_app.lib
index c9e7c318f4..7bdfd143e1 100644
--- a/bin10/lib/mir_app.lib
+++ b/bin10/lib/mir_app.lib
Binary files differ
diff --git a/bin10/lib/mir_app64.lib b/bin10/lib/mir_app64.lib
index 5095803ba9..e82621a0d3 100644
--- a/bin10/lib/mir_app64.lib
+++ b/bin10/lib/mir_app64.lib
Binary files differ
diff --git a/bin12/lib/mir_app.lib b/bin12/lib/mir_app.lib
index c9e7c318f4..7bdfd143e1 100644
--- a/bin12/lib/mir_app.lib
+++ b/bin12/lib/mir_app.lib
Binary files differ
diff --git a/bin12/lib/mir_app64.lib b/bin12/lib/mir_app64.lib
index 5095803ba9..e82621a0d3 100644
--- a/bin12/lib/mir_app64.lib
+++ b/bin12/lib/mir_app64.lib
Binary files differ
diff --git a/include/delphi/m_helpers.inc b/include/delphi/m_helpers.inc
index 2eb70b9478..550a766780 100644
--- a/include/delphi/m_helpers.inc
+++ b/include/delphi/m_helpers.inc
@@ -553,7 +553,7 @@ end;
function Skin_AddIcon(si:PSKINICONDESC):THANDLE;
begin
- result:=CallService(MS_SKIN2_ADDICON, hLangpack, LPARAM(si));
+ result:=IcoLib_AddIcon(si, hLangpack);
end;
procedure Icon_Register(hInst:HINST; const szSection:PAnsiChar; pIcons:pIconItem; iCount:size_t; prefix:PAnsiChar);
diff --git a/include/delphi/m_icolib.inc b/include/delphi/m_icolib.inc
index f20a919b17..89b1701b21 100644
--- a/include/delphi/m_icolib.inc
+++ b/include/delphi/m_icolib.inc
@@ -28,24 +28,24 @@ const
SIDF_PATH_UNICODE = $200; // Default File is in UCS-2
SIDF_ALL_UNICODE = SIDF_PATH_UNICODE or SIDF_UNICODE;
-const
{
Add a icon into options UI
-
- wParam = 0
- lParam = PSKINICONDESC
returns a handle to the newly added item
}
- MS_SKIN2_ADDICON:PAnsiChar = 'Skin2/Icons/AddIcon';
+
+function IcoLib_AddIcon(pIcon:PSKINICONDESC; iLang:int):THANDLE; stdcall;
+ external AppDLL name 'IcoLib_AddIcon';
{
Remove a icon from options UI
-
- wParam = (THANDLE)icon handle
- lParam = (PChar)icon name, one of them must be specified
WARNING: This will invalidate all HICONs retrieved for specified pszName
}
- MS_SKIN2_REMOVEICON:PAnsiChar = 'Skin2/Icons/RemoveIcon';
+
+procedure IcoLib_RemoveIcon(iconName:PAnsiChar); stdcall;
+ external AppDLL name 'IcoLib_RemoveIcon';
+procedure IcoLib_RemoveIconByHandle(icon:THandle); stdcall;
+ external AppDLL name 'IcoLib_RemoveIconByHandle';
+
{
Retrieve HICON with name specified in lParam
Returned HICON SHOULDN'T be destroyed, it managed by IcoLib
@@ -53,24 +53,23 @@ const
wParam = 0 - small 1 - big
lParam = pszName
}
- MS_SKIN2_GETICON :PAnsiChar = 'Skin2/Icons/GetIcon';
-{
- Retrieve an icolib handle for icon by name specified in lParam
-
- wParam = 0
- lParam = (LPARAM)(char*)pszName
-}
- MS_SKIN2_GETICONHANDLE:PAnsiChar = 'Skin2/Icons/GetIconHandle';
+function IcoLib_GetIcon(iconName:PAnsiChar; big:byte) : HICON; stdcall;
+ external AppDLL name 'IcoLib_GetIcon';
{
Retrieve HICON with HANDLE specified in lParam
Returned HICON SHOULDN'T be destroyed, it is managed by IcoLib
+}
- wParam = (WPARAM)0 - small 1 - big
- lParam = (HANDLE)hIcoLibIcon
+function IcoLib_GetIconByHandle(icon:THandle; big:byte) : HICON; stdcall;
+ external AppDLL name 'IcoLib_GetIconByHandle';
+{
+ Retrieve an icolib handle for icon by name specified in lParam
}
- MS_SKIN2_GETICONBYHANDLE:PAnsiChar = 'Skin2/Icons/GetIconByHandle';
+
+function IcoLib_GetIconHandle(iconName:PAnsiChar):THandle; stdcall;
+ external AppDLL name 'IcoLib_GetIconHandle';
{
Add reference to HICON
@@ -78,28 +77,30 @@ const
wParam = (WPARAM)HICON
lParam = 0 - small 1 - big
}
- MS_SKIN2_ADDREFICON:PAnsiChar = 'Skin2/Icons/AddRef';
+
+function IcoLib_AddRef(icon:HICON) : int; stdcall;
+ external AppDLL name 'IcoLib_AddRef';
{
Retrieved HICON is not needed anymore (this helps optimize GDI usage)
-
- wParam = HICON (optional)
- lParam = pszName (optional) // at least one needs to be specified
}
- MS_SKIN2_RELEASEICON :PAnsiChar = 'Skin2/Icons/ReleaseIcon';
- MS_SKIN2_RELEASEICONBIG:PAnsiChar = 'Skin2/Icons/ReleaseIconBig';
+
+function IcoLib_Release(iconName:PAnsiChar; big:byte) : int; stdcall;
+ external AppDLL name 'IcoLib_Release';
+function IcoLib_ReleaseIcon(icon:THandle; big:byte) : int; stdcall;
+ external AppDLL name 'IcoLib_ReleaseIcon';
{
Check whether HICON is managed by IcoLib
-
- wParam = (WPARAM)HICON
- lParam = 0
}
- MS_SKIN2_ISMANAGEDICON:PAnsiChar = 'Skin2/Icons/IsManaged';
+
+function IcoLib_IsManaged(icon:HICON) : THandle; stdcall;
+ external AppDLL name 'IcoLib_IsManaged';
{
Icons change notification
}
+const
ME_SKIN2_ICONSCHANGED:PAnsiChar = 'Skin2/IconsChanged';
{$ENDIF}
diff --git a/include/m_core.h b/include/m_core.h
index 788d82e96d..b39b0fd703 100644
--- a/include/m_core.h
+++ b/include/m_core.h
@@ -699,7 +699,7 @@ public:
return res;
}
- __forceinline char& operator[](int idx) const { return m_str[idx]; }
+ __forceinline char& operator[](size_t idx) const { return m_str[idx]; }
__forceinline operator char*() const { return m_str; }
__forceinline operator unsigned char*() const { return (unsigned char*)m_str; }
__forceinline operator LPARAM() const { return (LPARAM)m_str; }
diff --git a/include/m_icolib.h b/include/m_icolib.h
index e738df1d89..42f0258ab7 100644
--- a/include/m_icolib.h
+++ b/include/m_icolib.h
@@ -36,17 +36,6 @@ extern int hLangpack;
// are translated by the core, which may lead to double translation.
// Use LPGEN instead which are just dummy wrappers/markers for "lpgen.pl".
-typedef struct {
- MAllStrings section; // section name used to group icons
- MAllStrings description; // description for options dialog
- char *pszName; // name to refer to icon when playing and in db
- MAllStrings defaultFile; // default icon file to use
- int iDefaultIndex; // index of icon in default file
- HICON hDefaultIcon; // handle to default icon
- int cx,cy; // dimensions of icon (if 0 then standard size icon (big and small options available)
- int flags; // combination of SIDF_*
-} SKINICONDESC;
-
#define SIDF_SORTED 0x01 // Icons in section are sorted by name
#define SIDF_UNICODE 0x100 // Section and Description are in UCS-2
#define SIDF_PATH_UNICODE 0x200 // Default File is in UCS-2
@@ -62,142 +51,83 @@ typedef struct {
#define SIDF_ALL_TCHAR 0
#endif
-MIR_APP_DLL(HICON) LoadSkinProtoIcon(const char *szProto, int status, bool big = false);
-MIR_APP_DLL(HICON) LoadSkinIcon(int idx, bool big = false);
-MIR_APP_DLL(HANDLE) GetSkinIconHandle(int idx);
-
-MIR_APP_DLL(HANDLE) IcoLib_AddNewIcon(int hLangpack, SKINICONDESC *sid);
-MIR_APP_DLL(HICON) IcoLib_GetIcon(const char* pszIconName, bool big);
-MIR_APP_DLL(HANDLE) IcoLib_GetIconHandle(const char* pszIconName);
-MIR_APP_DLL(HICON) IcoLib_GetIconByHandle(HANDLE hItem, bool big);
-MIR_APP_DLL(HANDLE) IcoLib_IsManaged(HICON hIcon);
-MIR_APP_DLL(int) IcoLib_ReleaseIcon(HICON hIcon, char* szIconName, bool big = false);
-
-MIR_APP_DLL(void) Button_SetIcon_IcoLib(HWND hDlg, int itemId, int iconId, const char* tooltip);
-MIR_APP_DLL(void) Button_FreeIcon_IcoLib(HWND hDlg, int itemId);
-
-MIR_APP_DLL(void) Window_SetIcon_IcoLib(HWND hWnd, int iconId);
-MIR_APP_DLL(void) Window_SetProtoIcon_IcoLib(HWND hWnd, const char *szProto, int iconId);
-MIR_APP_DLL(void) Window_FreeIcon_IcoLib(HWND hWnd);
-
-///////////////////////////////////////////////////////////////////////////////
-// Adds an icon into options UI
-//
-// wParam = (WPARAM)0
-// lParam = (LPARAM)(SKINICONDESC*)sid;
-// returns a handle to the newly added item
-
-__forceinline HANDLE Skin_AddIcon(SKINICONDESC* si)
-{ return (HANDLE)CallService("Skin2/Icons/AddIcon", hLangpack, (LPARAM)si);
-}
+struct SKINICONDESC
+{
+ MAllStrings section; // section name used to group icons
+ MAllStrings description; // description for options dialog
+ char *pszName; // name to refer to icon when playing and in db
+ MAllStrings defaultFile; // default icon file to use
+ int iDefaultIndex; // index of icon in default file
+ HICON hDefaultIcon; // handle to default icon
+ int cx, cy; // dimensions of icon (if 0 then standard size icon (big and small options available)
+ int flags; // combination of SIDF_*
+};
+
+#if defined(__cplusplus)
+extern "C"
+{
+#endif
///////////////////////////////////////////////////////////////////////////////
-// Removes an icon from options UI
-//
-// wParam = (WPARAM)(HANDLE)hIcolib (optional)
-// lParam = (LPARAM)(char*)pszName (optional)
-// at least one needs to be specified
+// Adds an icon into the icon library
+// returns a handle to the newly added item
-#define MS_SKIN2_REMOVEICON "Skin2/Icons/RemoveIcon"
+MIR_APP_DLL(HANDLE) IcoLib_AddIcon(SKINICONDESC *sid, int _lang = hLangpack);
-__forceinline void Skin_RemoveIcon(const char* szIconName)
-{ CallService(MS_SKIN2_REMOVEICON, 0, (LPARAM)szIconName);
-}
+///////////////////////////////////////////////////////////////////////////////
+// Removes an icon from icon library by icon's name or handle
-__forceinline void Skin_RemoveIconHandle(HANDLE hIcolib)
-{ CallService(MS_SKIN2_REMOVEICON, (WPARAM)hIcolib, 0);
-}
+MIR_APP_DLL(void) IcoLib_RemoveIcon(const char *pszIconName);
+MIR_APP_DLL(void) IcoLib_RemoveIconByHandle(HANDLE hItem);
///////////////////////////////////////////////////////////////////////////////
-// Retrieves HICON with the name specified in lParam
-//
-// wParam = (WPARAM)0 - small 1 - big
-// lParam = (LPARAM)(char*)pszName
-// Returned HICON SHOULDN'T be destroyed, it is managed by IcoLib
+// Retrieves HICON with the name specified in lParam
+// Returned HICON SHOULDN'T be destroyed, it is managed by IcoLib
-#define MS_SKIN2_GETICON "Skin2/Icons/GetIcon"
-
-#ifdef __cplusplus
-__forceinline HICON Skin_GetIcon(const char* szIconName, int size=0)
-#else
-__forceinline HICON Skin_GetIcon(const char* szIconName, int size)
-#endif
-{ return (HICON)CallService(MS_SKIN2_GETICON, size, (LPARAM)szIconName);
-}
+MIR_APP_DLL(HICON) IcoLib_GetIcon(const char *pszIconName, bool big = false);
+MIR_APP_DLL(HICON) IcoLib_GetIconByHandle(HANDLE hItem, bool big = false);
///////////////////////////////////////////////////////////////////////////////
-// Retrieves an icolib handle by the icon's name specified in lParam
-//
-// wParam = (WPARAM)0
-// lParam = (LPARAM)(char*)pszName
+// Retrieves an icolib handle by the icon's name specified in lParam
-#define MS_SKIN2_GETICONHANDLE "Skin2/Icons/GetIconHandle"
-
-__forceinline HANDLE Skin_GetIconHandle(const char* szIconName)
-{ return (HANDLE)CallService(MS_SKIN2_GETICONHANDLE, 0, (LPARAM)szIconName);
-}
+MIR_APP_DLL(HANDLE) IcoLib_GetIconHandle(const char *pszIconName);
///////////////////////////////////////////////////////////////////////////////
-// Retrieves HICON with HANDLE specified in lParam
-//
-// wParam = (WPARAM)0 - small 1 - big
-// lParam = (LPARAM)(HANDLE)hIcoLibIcon
-// Returned HICON SHOULDN'T be destroyed, it is managed by IcoLib
-
-#define MS_SKIN2_GETICONBYHANDLE "Skin2/Icons/GetIconByHandle"
+// Adds 1 to an icon's ref counter. prevents an icon from being unloaded
-#ifdef __cplusplus
-__forceinline HICON Skin_GetIconByHandle(HANDLE hIcolibIcon, int size=0)
-#else
-__forceinline HICON Skin_GetIconByHandle(HANDLE hIcolibIcon, int size)
-#endif
-{ return (HICON)CallService(MS_SKIN2_GETICONBYHANDLE, size, (LPARAM)hIcolibIcon);
-}
+MIR_APP_DLL(int) IcoLib_AddRef(HICON hIcon);
///////////////////////////////////////////////////////////////////////////////
-// Adds a reference to HICON
-//
-// wParam = (WPARAM)HICON
-// lParam = 0 - small 1 - big
+// Retrieved HICON is not needed anymore (releases a reference; thus helps to optimize GDI usage)
-#define MS_SKIN2_ADDREFICON "Skin2/Icons/AddRef"
+MIR_APP_DLL(int) IcoLib_Release(const char *pszIconName, bool big = false);
+MIR_APP_DLL(int) IcoLib_ReleaseIcon(HICON hIcon, bool big = false);
///////////////////////////////////////////////////////////////////////////////
-// Retrieved HICON is not needed anymore (releases a reference; thus helps to optimize GDI usage)
-//
-// wParam = (WPARAM)HICON (optional)
-// lParam = (LPARAM)(char*)pszName (optional) // at least one needs to be specified
-
-#define MS_SKIN2_RELEASEICON "Skin2/Icons/ReleaseIcon"
-#define MS_SKIN2_RELEASEICONBIG "Skin2/Icons/ReleaseIconBig"
+// Checks whether HICON is managed by IcoLib
-__forceinline void Skin_ReleaseIcon(const char* szIconName)
-{ CallService(MS_SKIN2_RELEASEICON, 0, (LPARAM)szIconName);
-}
+MIR_APP_DLL(HANDLE) IcoLib_IsManaged(HICON hIcon);
-#ifdef __cplusplus
-__forceinline void Skin_ReleaseIcon(const char* szIconName, int big)
-{ CallService((big) ? MS_SKIN2_RELEASEICONBIG : MS_SKIN2_RELEASEICON, 0, (LPARAM)szIconName);
-}
+///////////////////////////////////////////////////////////////////////////////
+// Helper to apply an icolib's icon to a button
-__forceinline void Skin_ReleaseIcon(HICON hIcon)
-#else
-__forceinline void Skin_ReleaseIcon2(HICON hIcon)
-#endif
-{ CallService(MS_SKIN2_RELEASEICON, (WPARAM)hIcon, 0);
-}
+MIR_APP_DLL(void) Button_SetIcon_IcoLib(HWND hDlg, int itemId, int iconId, const char* tooltip);
+MIR_APP_DLL(void) Button_FreeIcon_IcoLib(HWND hDlg, int itemId);
///////////////////////////////////////////////////////////////////////////////
-// Checks whether HICON is managed by IcoLib
-//
-// wParam = (WPARAM)HICON
-// lParam = 0
+// Helper to apply an icolib's icon to a window
-#define MS_SKIN2_ISMANAGEDICON "Skin2/Icons/IsManaged"
+MIR_APP_DLL(void) Window_SetIcon_IcoLib(HWND hWnd, int iconId);
+MIR_APP_DLL(void) Window_SetProtoIcon_IcoLib(HWND hWnd, const char *szProto, int iconId);
+MIR_APP_DLL(void) Window_FreeIcon_IcoLib(HWND hWnd);
///////////////////////////////////////////////////////////////////////////////
-// Icons' change notification
+// Icons' change notification event
#define ME_SKIN2_ICONSCHANGED "Skin2/IconsChanged"
+#if defined(__cplusplus)
+}
+#endif
+
#endif /* M_ICOLIB_H__ */
diff --git a/include/m_skin.h b/include/m_skin.h
index 2dfa5db917..7537e4a918 100644
--- a/include/m_skin.h
+++ b/include/m_skin.h
@@ -26,6 +26,10 @@ Foundation, Inc., 59 Temple Place - Suite 330, Boston, MA 02111-1307, USA.
extern int hLangpack;
+#ifndef M_CORE_H__
+#include <m_core.h>
+#endif
+
//loads an icon from the user's custom skin library, or from the exe if there
//isn't one of them
//wParam = id of icon to load - see below
@@ -39,6 +43,13 @@ __forceinline HANDLE LoadSkinnedIconHandle(int id) { return (HANDLE)CallService(
__forceinline HICON LoadSkinnedIconBig(int id) { return (HICON) CallService(MS_SKIN_LOADICON, id, 2); }
__forceinline LPCSTR LoadSkinnedIconName(int id) { return (LPCSTR)CallService(MS_SKIN_LOADICON, id, 3); }
+///////////////////////////////////////////////////////////////////////////////
+// Miranda skin
+
+MIR_APP_DLL(HICON) LoadSkinProtoIcon(const char *szProto, int status, bool big = false);
+MIR_APP_DLL(HICON) LoadSkinIcon(int idx, bool big = false);
+MIR_APP_DLL(HANDLE) GetSkinIconHandle(int idx);
+
// event icons
#define SKINICON_EVENT_MESSAGE 100
#define SKINICON_EVENT_URL 101
diff --git a/make_core_def.cmd b/make_core_def.cmd
index b745d99c64..c46a23aaf3 100644
--- a/make_core_def.cmd
+++ b/make_core_def.cmd
@@ -2,4 +2,6 @@
echo.
.\tools\makedef\makedef.exe /IMAGE:bin12\debug\mir_core.dll /DEF:src\mir_core\src\mir_core.def
echo.
-.\tools\makedef\makedef64.exe /IMAGE:bin12\debug64\mir_core.dll /DEF:src\mir_core\src\mir_core64.def \ No newline at end of file
+.\tools\makedef\makedef64.exe /IMAGE:bin12\debug64\mir_core.dll /DEF:src\mir_core\src\mir_core64.def
+echo.
+.\tools\makedef\makedef.exe /IMAGE:bin12\debug\libs\mir_app.dll /DEF:src\mir_app\src\mir_app.def
diff --git a/plugins/Actman/dlgshare.pas b/plugins/Actman/dlgshare.pas
index 0fc89a975b..d66d059ae5 100644
--- a/plugins/Actman/dlgshare.pas
+++ b/plugins/Actman/dlgshare.pas
@@ -55,7 +55,7 @@ end;
function OptSetButtonIcon(btn:HWND;num:integer):HICON;
begin
- result:=CallService(MS_SKIN2_GETICONBYHANDLE,0,LPARAM(Icons[num].hIcolib));
+ result:=IcoLib_GetIconByHandle(Icons[num].hIcolib,0);
SendMessage(btn,BM_SETIMAGE,IMAGE_ICON,result);
end;
diff --git a/plugins/Actman/i_opt_dlg2.inc b/plugins/Actman/i_opt_dlg2.inc
index c9571f2ea8..fc76ba6fb0 100644
--- a/plugins/Actman/i_opt_dlg2.inc
+++ b/plugins/Actman/i_opt_dlg2.inc
@@ -239,7 +239,7 @@ begin
while p<>nil do
begin
StrCopy(StrCopyE(@buf,IcoLibPrefix),p^.Name);
- ImageList_ReplaceIcon(il,-1,CallService(MS_SKIN2_GETICON,0,lparam(@buf)));
+ ImageList_ReplaceIcon(il,-1,IcoLib_GetIcon(@buf,0));
cbei.pszText :=TranslateW(FastAnsiToWideBuf(p^.Name,buf));
cbei.iItem :=i;
diff --git a/plugins/Actman/ua/i_opt_dlg.inc b/plugins/Actman/ua/i_opt_dlg.inc
index 6e5cc4d117..99b12d44dc 100644
--- a/plugins/Actman/ua/i_opt_dlg.inc
+++ b/plugins/Actman/ua/i_opt_dlg.inc
@@ -192,8 +192,7 @@ begin
li.iItem :=i;
li.lParam :=i;
li.pszText :=UActionList[i].szActDescr;
- li.iImage:=ImageList_ReplaceIcon(il, -1,
- HICON(CallService(MS_SKIN2_GETICONBYHANDLE,0,LPARAM(UActionList[i].hIcolibIcon))));
+ li.iImage :=ImageList_ReplaceIcon(il, -1, IcoLib_GetIconByHandle(UActionList[i].hIcolibIcon,0));
li.iItem :=SendMessageW(wnd,LVM_INSERTITEMW,0,LPARAM(@li));
for lmenu:=main_menu to HIGH(tMenuType) do
@@ -225,8 +224,7 @@ begin
li.mask :=LVIF_IMAGE;
li.iSubItem:=0;
li.iItem :=i;
- li.iImage:=ImageList_ReplaceIcon(il, -1,
- HICON(CallService(MS_SKIN2_GETICONBYHANDLE,0,TLPARAM(UActionList[i].hIcolibIcon))));
+ li.iImage:=ImageList_ReplaceIcon(il, -1, IcoLib_GetIconByHandle(UActionList[i].hIcolibIcon,0));
SendMessageW(wnd,LVM_SETITEM,0,TLPARAM(@li));
end;
ImageList_Destroy(SendMessage(wnd,LVM_SETIMAGELIST,LVSIL_SMALL,il));
diff --git a/plugins/Actman/ua/i_uaplaces.inc b/plugins/Actman/ua/i_uaplaces.inc
index 680566e2fc..9c508a167f 100644
--- a/plugins/Actman/ua/i_uaplaces.inc
+++ b/plugins/Actman/ua/i_uaplaces.inc
@@ -199,7 +199,7 @@ begin
(ActionItem.hIcolibIconPressed<>ActionItem.hIcolibIcon) then
begin
StrCopy(StrCopyE(@buf1,ActionItem.szNameID),'_pressed');
- CallService(MS_SKIN2_REMOVEICON,0,LPARAM(@buf1));
+ IcoLib_RemoveIcon(@buf1);
ActionItem.hIcolibIconPressed:=ActionItem.hIcolibIcon;
end;
end;
@@ -207,7 +207,7 @@ end;
procedure DeleteIcolibIcon(var ActionItem:tMyActionItem);
begin
DeleteIcolibIconP(ActionItem);
- CallService(MS_SKIN2_REMOVEICON,0,LPARAM(ActionItem.szNameID));
+ IcoLib_RemoveIcon(ActionItem.szNameID);
ActionItem.hIcolibIcon :=0;
ActionItem.hIcolibIconPressed:=0;
end;
diff --git a/plugins/AddContactPlus/src/addcontact.cpp b/plugins/AddContactPlus/src/addcontact.cpp
index 2c301ebf20..b56d2f7ce0 100644
--- a/plugins/AddContactPlus/src/addcontact.cpp
+++ b/plugins/AddContactPlus/src/addcontact.cpp
@@ -164,8 +164,8 @@ INT_PTR CALLBACK AddContactDlgProc(HWND hdlg, UINT msg, WPARAM wparam, LPARAM)
Utils_RestoreWindowPositionNoSize(hdlg, NULL, "AddContact", "");
TranslateDialogDefault(hdlg);
- SendMessage(hdlg, WM_SETICON, ICON_BIG, (LPARAM)Skin_GetIcon(ICON_ADD,1));
- SendMessage(hdlg, WM_SETICON, ICON_SMALL, (LPARAM)Skin_GetIcon(ICON_ADD));
+ SendMessage(hdlg, WM_SETICON, ICON_BIG, (LPARAM)IcoLib_GetIcon(ICON_ADD,1));
+ SendMessage(hdlg, WM_SETICON, ICON_SMALL, (LPARAM)IcoLib_GetIcon(ICON_ADD));
HookEventMessage(ME_SKIN2_ICONSCHANGED, hdlg, DM_ADDCONTACT_CHANGEICONS);
HookEventMessage(ME_PROTO_ACCLISTCHANGED, hdlg, DM_ADDCONTACT_CHANGEACCLIST);
{
@@ -324,8 +324,8 @@ INT_PTR CALLBACK AddContactDlgProc(HWND hdlg, UINT msg, WPARAM wparam, LPARAM)
break;
case DM_ADDCONTACT_CHANGEICONS:
- Skin_ReleaseIcon((HICON)SendMessage(hdlg, WM_SETICON, ICON_BIG, (LPARAM)Skin_GetIcon(ICON_ADD, 1)));
- Skin_ReleaseIcon((HICON)SendMessage(hdlg, WM_SETICON, ICON_SMALL, (LPARAM)Skin_GetIcon(ICON_ADD)));
+ IcoLib_ReleaseIcon((HICON)SendMessage(hdlg, WM_SETICON, ICON_BIG, (LPARAM)IcoLib_GetIcon(ICON_ADD, 1)));
+ IcoLib_ReleaseIcon((HICON)SendMessage(hdlg, WM_SETICON, ICON_SMALL, (LPARAM)IcoLib_GetIcon(ICON_ADD)));
break;
case DM_ADDCONTACT_CHANGEACCLIST:
@@ -334,8 +334,8 @@ INT_PTR CALLBACK AddContactDlgProc(HWND hdlg, UINT msg, WPARAM wparam, LPARAM)
case WM_DESTROY:
hAddDlg = NULL;
- Skin_ReleaseIcon((HICON)SendMessage(hdlg, WM_SETICON, ICON_BIG, 0));
- Skin_ReleaseIcon((HICON)SendMessage(hdlg, WM_SETICON, ICON_SMALL, 0));
+ IcoLib_ReleaseIcon((HICON)SendMessage(hdlg, WM_SETICON, ICON_BIG, 0));
+ IcoLib_ReleaseIcon((HICON)SendMessage(hdlg, WM_SETICON, ICON_SMALL, 0));
ImageList_Destroy((HIMAGELIST)SendDlgItemMessage(hdlg, IDC_PROTO, CBEM_GETIMAGELIST, 0, 0));
if (acs) {
db_set_s(NULL, "AddContact", "LastProto", acs->proto);
diff --git a/plugins/Alarms/src/icons.cpp b/plugins/Alarms/src/icons.cpp
index df812194ad..8d2bdd51c3 100644
--- a/plugins/Alarms/src/icons.cpp
+++ b/plugins/Alarms/src/icons.cpp
@@ -14,11 +14,11 @@ static IconItem iconList[] =
int ReloadIcons(WPARAM, LPARAM)
{
- hIconMenuSet = Skin_GetIcon("alarms_menu_set");
- hIconList1 = Skin_GetIcon("alarms_list1");
- hIconList2 = Skin_GetIcon("alarms_list2");
+ hIconMenuSet = IcoLib_GetIcon("alarms_menu_set");
+ hIconList1 = IcoLib_GetIcon("alarms_list1");
+ hIconList2 = IcoLib_GetIcon("alarms_list2");
if ( !ServiceExists(MS_CLIST_FRAMES_ADDFRAME))
- hIconMenuShowHide = Skin_GetIcon("alarms_menu_showhide");
+ hIconMenuShowHide = IcoLib_GetIcon("alarms_menu_showhide");
RefreshReminderFrame();
return 0;
@@ -29,7 +29,7 @@ void InitIcons()
Icon_Register(hInst, "Alarms", iconList, SIZEOF(iconList));
if ( !ServiceExists(MS_CLIST_FRAMES_ADDFRAME))
- hIconMenuShowHide = Skin_GetIcon("alarms_menu_showhide");
+ hIconMenuShowHide = IcoLib_GetIcon("alarms_menu_showhide");
ReloadIcons(0, 0);
HookEvent(ME_SKIN2_ICONSCHANGED, ReloadIcons);
diff --git a/plugins/Alarms/src/options.cpp b/plugins/Alarms/src/options.cpp
index ec040a3833..853c54b285 100644
--- a/plugins/Alarms/src/options.cpp
+++ b/plugins/Alarms/src/options.cpp
@@ -694,7 +694,7 @@ void AddMenuItem()
CLISTMENUITEM mi = { sizeof(mi) };
mi.flags = CMIM_ALL;
- mi.icolibItem = Skin_GetIconHandle("alarms_menu_set");
+ mi.icolibItem = IcoLib_GetIconHandle("alarms_menu_set");
mi.pszName = "Set alarm";
mi.pszService = MODULE "/NewAlarm";
mi.position = 500010000;
diff --git a/plugins/AutoShutdown/src/frame.cpp b/plugins/AutoShutdown/src/frame.cpp
index d64ec5c093..c01bf11b54 100644
--- a/plugins/AutoShutdown/src/frame.cpp
+++ b/plugins/AutoShutdown/src/frame.cpp
@@ -524,7 +524,7 @@ void ShowCountdownFrame(WORD fTimeFlags)
if (ServiceExists(MS_CLIST_FRAMES_ADDFRAME)) {
CLISTFrame clf = { sizeof(clf) };
- clf.hIcon=Skin_GetIcon("AutoShutdown_Active"); /* CListFrames does not make a copy */
+ clf.hIcon=IcoLib_GetIcon("AutoShutdown_Active"); /* CListFrames does not make a copy */
clf.align=alBottom;
clf.height=GetSystemMetrics(SM_CYICON);
clf.Flags=F_VISIBLE|F_SHOWTBTIP|F_NOBORDER|F_SKINNED;
diff --git a/plugins/AutoShutdown/src/settingsdlg.cpp b/plugins/AutoShutdown/src/settingsdlg.cpp
index 70170abfe1..bb221fbaa6 100644
--- a/plugins/AutoShutdown/src/settingsdlg.cpp
+++ b/plugins/AutoShutdown/src/settingsdlg.cpp
@@ -73,7 +73,7 @@ static INT_PTR CALLBACK SettingsDlgProc(HWND hwndDlg,UINT msg,WPARAM wParam,LPAR
hwndSettingsDlg=hwndDlg;
TranslateDialogDefault(hwndDlg);
locale=CallService(MS_LANGPACK_GETLOCALE,0,0);
- SendDlgItemMessage(hwndDlg,IDC_ICON_HEADER,STM_SETIMAGE,IMAGE_ICON,(LPARAM)Skin_GetIcon("AutoShutdown_Header"));
+ SendDlgItemMessage(hwndDlg,IDC_ICON_HEADER,STM_SETIMAGE,IMAGE_ICON,(LPARAM)IcoLib_GetIcon("AutoShutdown_Header"));
{
HFONT hBoldFont;
LOGFONT lf;
diff --git a/plugins/AutoShutdown/src/shutdownsvc.cpp b/plugins/AutoShutdown/src/shutdownsvc.cpp
index a4aafa2763..2a69f1b9cd 100644
--- a/plugins/AutoShutdown/src/shutdownsvc.cpp
+++ b/plugins/AutoShutdown/src/shutdownsvc.cpp
@@ -307,7 +307,7 @@ static INT_PTR CALLBACK ShutdownDlgProc(HWND hwndDlg,UINT msg,WPARAM wParam,LPAR
if (lParam==SDSDT_SHUTDOWN || lParam==SDSDT_REBOOT || lParam==SDSDT_LOGOFF)
ShowWindow(GetDlgItem(hwndDlg,IDC_TEXT_UNSAVEDWARNING),SW_SHOW);
- SendDlgItemMessage(hwndDlg,IDC_ICON_HEADER,STM_SETIMAGE,IMAGE_ICON,(LPARAM)Skin_GetIcon("AutoShutdown_Header"));
+ SendDlgItemMessage(hwndDlg,IDC_ICON_HEADER,STM_SETIMAGE,IMAGE_ICON,(LPARAM)IcoLib_GetIcon("AutoShutdown_Header"));
{
HFONT hBoldFont;
LOGFONT lf;
diff --git a/plugins/AutoShutdown/src/utils.cpp b/plugins/AutoShutdown/src/utils.cpp
index f679d8c3bf..0eaed524a2 100644
--- a/plugins/AutoShutdown/src/utils.cpp
+++ b/plugins/AutoShutdown/src/utils.cpp
@@ -218,7 +218,7 @@ HANDLE IcoLib_AddIconRes(const char *pszDbName,const TCHAR *pszSection,const TCH
sid.cx = GetSystemMetrics(fLarge?SM_CXICON:SM_CXSMICON);
sid.cy = GetSystemMetrics(fLarge?SM_CYICON:SM_CYSMICON);
sid.flags = SIDF_SORTED | SIDF_ALL_TCHAR;
- return Skin_AddIcon(&sid);
+ return IcoLib_AddIcon(&sid);
}
void AddHotkey()
diff --git a/plugins/AvatarHistory/src/icolib.cpp b/plugins/AvatarHistory/src/icolib.cpp
index 7416cf0fc6..eadc7d4542 100644
--- a/plugins/AvatarHistory/src/icolib.cpp
+++ b/plugins/AvatarHistory/src/icolib.cpp
@@ -14,12 +14,12 @@ static IconItem iconList[] =
static HICON LoadIconEx(IconIndex i)
{
- return Skin_GetIconByHandle(iconList[(int)i].hIcolib);
+ return IcoLib_GetIconByHandle(iconList[(int)i].hIcolib);
}
static void ReleaseIconEx(HICON hIcon)
{
- Skin_ReleaseIcon(hIcon);
+ IcoLib_ReleaseIcon(hIcon);
}
static void IcoLibUpdateMenus()
@@ -84,6 +84,6 @@ HICON createProtoOverlayedIcon(MCONTACT hContact)
HICON resIcon = getOverlayedIcon(icon0, icon1, FALSE);
ReleaseIconEx(icon1);
- Skin_ReleaseIcon(icon0);
+ IcoLib_ReleaseIcon(icon0);
return resIcon;
}
diff --git a/plugins/BASS_interface/src/Main.cpp b/plugins/BASS_interface/src/Main.cpp
index 79b6349ba5..520b17e17b 100644
--- a/plugins/BASS_interface/src/Main.cpp
+++ b/plugins/BASS_interface/src/Main.cpp
@@ -328,11 +328,11 @@ int OptionsInit(WPARAM wParam, LPARAM)
static void EnableFrameIcon(bool bEnable)
{
if (bEnable) {
- SendMessage(hwndMute, BM_SETIMAGE, IMAGE_ICON, (LPARAM)Skin_GetIcon("BASSSoundOn"));
+ SendMessage(hwndMute, BM_SETIMAGE, IMAGE_ICON, (LPARAM)IcoLib_GetIcon("BASSSoundOn"));
SendMessage(hwndMute, BUTTONADDTOOLTIP, (WPARAM)Translate("Disable sounds"), 0);
}
else {
- SendMessage(hwndMute, BM_SETIMAGE, IMAGE_ICON, (LPARAM)Skin_GetIcon("BASSSoundOff"));
+ SendMessage(hwndMute, BM_SETIMAGE, IMAGE_ICON, (LPARAM)IcoLib_GetIcon("BASSSoundOff"));
SendMessage(hwndMute, BUTTONADDTOOLTIP, (WPARAM)Translate("Enable sounds"), 0);
}
}
diff --git a/plugins/BasicHistory/src/BasicHistory.cpp b/plugins/BasicHistory/src/BasicHistory.cpp
index b6958e13e2..d38915caec 100644
--- a/plugins/BasicHistory/src/BasicHistory.cpp
+++ b/plugins/BasicHistory/src/BasicHistory.cpp
@@ -189,7 +189,7 @@ HICON LoadIconEx(int iconId, int big)
{
for (int i=0; i < SIZEOF(iconList); i++)
if ( iconList[i].defIconID == iconId)
- return Skin_GetIconByHandle(iconList[i].hIcolib, big);
+ return IcoLib_GetIconByHandle(iconList[i].hIcolib, big);
return 0;
}
diff --git a/plugins/BasicHistory/src/HistoryWindow.cpp b/plugins/BasicHistory/src/HistoryWindow.cpp
index 5c18fcf4a5..2b3a9bd1b4 100644
--- a/plugins/BasicHistory/src/HistoryWindow.cpp
+++ b/plugins/BasicHistory/src/HistoryWindow.cpp
@@ -82,22 +82,22 @@ HistoryWindow::~HistoryWindow()
{
for (int i = 0; i < iconsNum; ++i)
if (eventIcons[i] != NULL)
- Skin_ReleaseIcon(eventIcons[i]);
+ IcoLib_ReleaseIcon(eventIcons[i]);
delete[] eventIcons;
}
if (plusIco != NULL)
- Skin_ReleaseIcon(plusIco);
+ IcoLib_ReleaseIcon(plusIco);
if (minusIco != NULL)
- Skin_ReleaseIcon(minusIco);
+ IcoLib_ReleaseIcon(minusIco);
if (findNextIco != NULL)
- Skin_ReleaseIcon(findNextIco);
+ IcoLib_ReleaseIcon(findNextIco);
if (findPrevIco != NULL)
- Skin_ReleaseIcon(findPrevIco);
+ IcoLib_ReleaseIcon(findPrevIco);
if (himlSmall != NULL)
ImageList_Destroy(himlSmall);
@@ -1117,7 +1117,7 @@ void HistoryWindow::Initialise()
allIconNumber = iconsNum + 3;
eventIcons = new HICON[allIconNumber];
for (int i = 0; i < iconsNum; ++i) {
- eventIcons[i] = Skin_GetIconByHandle( iconList[i].hIcolib );
+ eventIcons[i] = IcoLib_GetIconByHandle( iconList[i].hIcolib );
ImageList_AddIcon(himlSmall, eventIcons[i]);
}
@@ -1198,10 +1198,10 @@ void HistoryWindow::Initialise()
void HistoryWindow::Destroy()
{
HICON hIcon = (HICON)SendMessage(hWnd, WM_SETICON, ICON_BIG, 0);
- Skin_ReleaseIcon(hIcon);
+ IcoLib_ReleaseIcon(hIcon);
hIcon = (HICON)SendMessage(hWnd, WM_SETICON, ICON_SMALL, 0);
- Skin_ReleaseIcon(hIcon);
+ IcoLib_ReleaseIcon(hIcon);
isDestroyed = true;
HistoryWindow::Close(this);
diff --git a/plugins/BasicHistory/src/RichHtmlExport.cpp b/plugins/BasicHistory/src/RichHtmlExport.cpp
index c3c0cefbc2..2ffda4d7e3 100644
--- a/plugins/BasicHistory/src/RichHtmlExport.cpp
+++ b/plugins/BasicHistory/src/RichHtmlExport.cpp
@@ -299,19 +299,19 @@ void RichHtmlExport::WriteHeader(const std::wstring &fileName, const std::wstrin
HICON ico = LoadIconEx(IDI_PLUSEX);
IcoSave(folder + _T("\\pnode.ico"), ico);
- Skin_ReleaseIcon(ico);
+ IcoLib_ReleaseIcon(ico);
ico = LoadIconEx(IDI_MINUSEX);
IcoSave(folder + _T("\\mnode.ico"), ico);
- Skin_ReleaseIcon(ico);
+ IcoLib_ReleaseIcon(ico);
ico = LoadIconEx(IDI_INM);
IcoSave(folder + _T("\\event0.ico"), ico);
- Skin_ReleaseIcon(ico);
+ IcoLib_ReleaseIcon(ico);
ico = LoadIconEx(IDI_OUTM);
IcoSave(folder + _T("\\event1.ico"), ico);
- Skin_ReleaseIcon(ico);
+ IcoLib_ReleaseIcon(ico);
EXP_FILE << _T("<!DOCTYPE HTML PUBLIC \"-//W3C//DTD HTML 4.01 Transitional//EN\">\n");
EXP_FILE << _T("<html><head>\n<meta http-equiv=\"Content-Type\" content=\"text/html; charset=") << encoding << _T("\">\n");
diff --git a/plugins/BossKeyPlus/src/BossKey.cpp b/plugins/BossKeyPlus/src/BossKey.cpp
index 60bdd2084f..5f9a7314ac 100644
--- a/plugins/BossKeyPlus/src/BossKey.cpp
+++ b/plugins/BossKeyPlus/src/BossKey.cpp
@@ -264,7 +264,7 @@ static void CreateTrayIcon(bool create)
nim.hWnd = g_hListenWindow;
nim.uID = 100;
nim.uFlags = NIF_ICON | NIF_MESSAGE | NIF_TIP;
- nim.hIcon = Skin_GetIcon("hidemim");
+ nim.hIcon = IcoLib_GetIcon("hidemim");
nim.uCallbackMessage = WM_USER + 24;
Shell_NotifyIcon(create ? NIM_ADD : NIM_DELETE, &nim);
g_TrayIcon = create;
@@ -539,7 +539,7 @@ void BossKeyMenuItemInit(void) // Add menu item
mi.flags = CMIF_TCHAR;
mi.position = 2000100000;
mi.pszPopupName = 0;
- mi.hIcon = Skin_GetIcon("hidemim");
+ mi.hIcon = IcoLib_GetIcon("hidemim");
mi.ptszName = LPGENT("Hide");
mi.pszService = MS_BOSSKEY_HIDE;
diff --git a/plugins/BuddyExpectator/src/BuddyExpectator.cpp b/plugins/BuddyExpectator/src/BuddyExpectator.cpp
index f9f9a45d0a..4a492abff8 100644
--- a/plugins/BuddyExpectator/src/BuddyExpectator.cpp
+++ b/plugins/BuddyExpectator/src/BuddyExpectator.cpp
@@ -228,7 +228,7 @@ bool isContactGoneFor(MCONTACT hContact, int days)
POPUPDATAT_V2 ppd = { 0 };
ppd.cbSize = sizeof(ppd);
ppd.lchContact = hContact;
- ppd.lchIcon = Skin_GetIcon("enabled_icon");
+ ppd.lchIcon = IcoLib_GetIcon("enabled_icon");
mir_sntprintf(ppd.lptzContactName, SIZEOF(ppd.lptzContactName), TranslateT("Hiding %s (%S)"),
CallService(MS_CLIST_GETCONTACTDISPLAYNAME, hContact, GCDNF_TCHAR),
@@ -408,7 +408,7 @@ INT_PTR ContactStillAbsentAction(WPARAM hContact, LPARAM lParam)
*/
int onIconsChanged(WPARAM, LPARAM)
{
- hIcon = Skin_GetIcon("main_icon");
+ hIcon = IcoLib_GetIcon("main_icon");
return 0;
}
@@ -494,7 +494,7 @@ int SettingChanged(WPARAM hContact, LPARAM lParam)
ppd.cbSize = sizeof(ppd);
ppd.lchContact = hContact;
- ppd.lchIcon = Skin_GetIcon("enabled_icon");
+ ppd.lchIcon = IcoLib_GetIcon("enabled_icon");
_tcsncpy(ppd.lptzContactName, (TCHAR*)CallService(MS_CLIST_GETCONTACTDISPLAYNAME, hContact, GCDNF_TCHAR), MAX_CONTACTNAME);
_tcsncpy(ppd.lptzText, TranslateT("You awaited this contact!"), MAX_SECONDLINE);
if (!options.iUsePopupColors) {
@@ -627,17 +627,17 @@ int ModulesLoaded(WPARAM, LPARAM)
}
missyouactions[0].cbSize = sizeof(POPUPACTION);
- missyouactions[0].lchIcon = Skin_GetIcon("disabled_icon");
+ missyouactions[0].lchIcon = IcoLib_GetIcon("disabled_icon");
mir_strcpy(missyouactions[0].lpzTitle, LPGEN("Disable Miss You"));
missyouactions[0].wParam = missyouactions[0].lParam = 1;
hideactions[0].cbSize = sizeof(POPUPACTION);
- hideactions[0].lchIcon = Skin_GetIcon("hide_icon");
+ hideactions[0].lchIcon = IcoLib_GetIcon("hide_icon");
mir_strcpy(hideactions[0].lpzTitle, LPGEN("Hide contact"));
hideactions[0].wParam = hideactions[0].lParam = 2;
hideactions[1].cbSize = sizeof(POPUPACTION);
- hideactions[1].lchIcon = Skin_GetIcon("neverhide_icon");
+ hideactions[1].lchIcon = IcoLib_GetIcon("neverhide_icon");
mir_strcpy(hideactions[1].lpzTitle, LPGEN("Never hide this contact"));
hideactions[1].wParam = hideactions[1].lParam = 3;
@@ -662,7 +662,7 @@ int onShutdown(WPARAM, LPARAM)
DestroyServiceFunction(hMissYouAction);
DestroyServiceFunction(hMenuMissYouClick);
- Skin_ReleaseIcon(hIcon);
+ IcoLib_ReleaseIcon(hIcon);
return 0;
}
diff --git a/plugins/BuddyExpectator/src/options.cpp b/plugins/BuddyExpectator/src/options.cpp
index d936da7738..6eed6cc9a9 100644
--- a/plugins/BuddyExpectator/src/options.cpp
+++ b/plugins/BuddyExpectator/src/options.cpp
@@ -347,7 +347,7 @@ static INT_PTR CALLBACK PopupOptionsFrameProc(HWND hwndDlg, UINT uMsg, WPARAM wP
CallService(MS_POPUP_ADDPOPUPT, (WPARAM)&ppd, APF_NO_HISTORY);
_tcsncpy(ppd.lptzText, TranslateT("You awaited this contact!"), MAX_SECONDLINE);
- ppd.lchIcon = Skin_GetIcon("enabled_icon");
+ ppd.lchIcon = IcoLib_GetIcon("enabled_icon");
CallService(MS_POPUP_ADDPOPUPT, (WPARAM)&ppd, APF_NO_HISTORY);
}
diff --git a/plugins/CSList/src/cslist.cpp b/plugins/CSList/src/cslist.cpp
index 9b9c5f7ecd..f445d8de7e 100644
--- a/plugins/CSList/src/cslist.cpp
+++ b/plugins/CSList/src/cslist.cpp
@@ -127,7 +127,7 @@ extern "C" __declspec(dllexport) int Load()
TCHAR tszFile[MAX_PATH];
GetModuleFileName(g_hInst, tszFile, MAX_PATH);
- SKINICONDESC sid = { 0 };
+ SKINICONDESC sid = { 0 };
sid.defaultFile.t = tszFile;
sid.flags = SIDF_ALL_TCHAR;
sid.cx = sid.cy = 16;
@@ -140,7 +140,7 @@ extern "C" __declspec(dllexport) int Load()
sid.pszName = szSettingName;
sid.description.t = forms[i].ptszDescr;
sid.iDefaultIndex = -forms[i].iconNoIcoLib;
- forms[i].hIcoLibItem = Skin_AddIcon(&sid);
+ forms[i].hIcoLibItem = IcoLib_AddIcon(&sid);
}
HookEvent(ME_OPT_INITIALISE, OnInitOptions);
@@ -365,7 +365,7 @@ void CSWindow::initButtons()
if (forms[i].idc < 0)
continue;
- SendDlgItemMessage(m_handle, forms[i].idc, BM_SETIMAGE, IMAGE_ICON, (LPARAM)Skin_GetIconByHandle(forms[i].hIcoLibItem));
+ SendDlgItemMessage(m_handle, forms[i].idc, BM_SETIMAGE, IMAGE_ICON, (LPARAM)IcoLib_GetIconByHandle(forms[i].hIcoLibItem));
SendDlgItemMessage(m_handle, forms[i].idc, BUTTONSETASFLATBTN, TRUE, 0); //maybe set as BUTTONSETDEFAULT?
SendDlgItemMessage(m_handle, forms[i].idc, BUTTONADDTOOLTIP, (WPARAM)TranslateTS(forms[i].ptszTitle), BATF_TCHAR);
}
diff --git a/plugins/ChangeKeyboardLayout/src/hook_events.cpp b/plugins/ChangeKeyboardLayout/src/hook_events.cpp
index dbb57e0ad3..29ce01d5f1 100644
--- a/plugins/ChangeKeyboardLayout/src/hook_events.cpp
+++ b/plugins/ChangeKeyboardLayout/src/hook_events.cpp
@@ -1,12 +1,12 @@
#include "stdafx.h"
-INT_PTR APIChangeLayout(WPARAM wParam, LPARAM lParam)
+INT_PTR APIChangeLayout(WPARAM wParam, LPARAM)
{
BOOL CurrentWord = moOptions.CurrentWordLayout;
return ChangeLayout((HWND)wParam, TOT_Layout, CurrentWord);
}
-INT_PTR APIGetLayoutOfText(WPARAM wParam, LPARAM lParam)
+INT_PTR APIGetLayoutOfText(WPARAM, LPARAM lParam)
{
LPTSTR ptszInText = (TCHAR*)lParam;
return (INT_PTR)GetLayoutOfText(ptszInText);
@@ -85,15 +85,15 @@ void RegPopupActions()
}
}
-int OnIconsChanged(WPARAM wParam, LPARAM lParam)
+int OnIconsChanged(WPARAM, LPARAM)
{
- hPopupIcon = Skin_GetIcon("ckl_popup_icon");
- hCopyIcon = Skin_GetIcon("ckl_copy_icon");
+ hPopupIcon = IcoLib_GetIcon("ckl_popup_icon");
+ hCopyIcon = IcoLib_GetIcon("ckl_copy_icon");
RegPopupActions();
return 0;
}
-int ModulesLoaded(WPARAM wParam, LPARAM lParam)
+int ModulesLoaded(WPARAM, LPARAM)
{
LPCTSTR ptszEmptySting = _T("");
@@ -138,7 +138,7 @@ int ModulesLoaded(WPARAM wParam, LPARAM lParam)
return 0;
}
-int OnOptionsInitialise(WPARAM wParam, LPARAM lParam)
+int OnOptionsInitialise(WPARAM wParam, LPARAM)
{
OPTIONSDIALOGPAGE odp = { 0 };
odp.hInstance = hInst;
diff --git a/plugins/ChangeKeyboardLayout/src/main.cpp b/plugins/ChangeKeyboardLayout/src/main.cpp
index d3b73da55f..4f7c7d452a 100644
--- a/plugins/ChangeKeyboardLayout/src/main.cpp
+++ b/plugins/ChangeKeyboardLayout/src/main.cpp
@@ -32,13 +32,13 @@ LPCTSTR ptszSeparators = _T(" \t\n\r");
HANDLE hOptionsInitialize;
-BOOL WINAPI DllMain(HINSTANCE hinstDLL, DWORD fdwReason, LPVOID lpvReserved)
+BOOL WINAPI DllMain(HINSTANCE hinstDLL, DWORD, LPVOID)
{
hInst = hinstDLL;
return TRUE;
}
-extern "C" __declspec(dllexport) PLUGININFOEX* MirandaPluginInfoEx(DWORD mirandaVersion)
+extern "C" __declspec(dllexport) PLUGININFOEX* MirandaPluginInfoEx(DWORD)
{
return &pluginInfoEx;
}
diff --git a/plugins/ChangeKeyboardLayout/src/stdafx.h b/plugins/ChangeKeyboardLayout/src/stdafx.h
index 1160595f75..6eb9e0fadf 100644
--- a/plugins/ChangeKeyboardLayout/src/stdafx.h
+++ b/plugins/ChangeKeyboardLayout/src/stdafx.h
@@ -1,7 +1,5 @@
#ifndef M_CKL_COMMONHEADERS_H
#define M_CKL_COMMONHEADERS_H
-#define _CRT_SECURE_NO_WARNINGS
-#define _CRT_NONSTDC_NO_DEPRECATE
#include <windows.h>
#include <commctrl.h>
diff --git a/plugins/ClientChangeNotify/src/ClientChangeNotify.cpp b/plugins/ClientChangeNotify/src/ClientChangeNotify.cpp
index 09fb832fe5..c290465a79 100644
--- a/plugins/ClientChangeNotify/src/ClientChangeNotify.cpp
+++ b/plugins/ClientChangeNotify/src/ClientChangeNotify.cpp
@@ -279,11 +279,11 @@ static int PrebuildMainMenu(WPARAM wParam, LPARAM lParam)
mi.flags = CMIF_TCHAR | CMIM_NAME | CMIM_ICON;
if (g_PopupOptPage.GetDBValueCopy(IDC_POPUPOPTDLG_POPUPNOTIFY)) {
mi.ptszName = LPGENT("Disable c&lient change notification");
- mi.hIcon = Skin_GetIcon("popup_enabled");
+ mi.hIcon = IcoLib_GetIcon("popup_enabled");
}
else {
mi.ptszName = LPGENT("Enable c&lient change notification");
- mi.hIcon = Skin_GetIcon("popup_disabled");
+ mi.hIcon = IcoLib_GetIcon("popup_disabled");
}
mi.ptszPopupName = LPGENT("Popups");
Menu_ModifyItem(g_hTogglePopupsMenuItem, &mi);
diff --git a/plugins/Clist_modern/src/modern_clc.cpp b/plugins/Clist_modern/src/modern_clc.cpp
index 2f3a6d4313..d5e740ecac 100644
--- a/plugins/Clist_modern/src/modern_clc.cpp
+++ b/plugins/Clist_modern/src/modern_clc.cpp
@@ -93,16 +93,16 @@ static int clcHookIconsChanged(WPARAM, LPARAM)
hAvatarOverlays = ImageList_Create(16, 16, ILC_MASK | ILC_COLOR32, SIZEOF(g_pAvatarOverlayIcons) * 2, 1);
for (i = 0; i < SIZEOF(g_pAvatarOverlayIcons); i++) {
- HICON hIcon = Skin_GetIcon(g_pAvatarOverlayIcons[i].name);
+ HICON hIcon = IcoLib_GetIcon(g_pAvatarOverlayIcons[i].name);
g_pAvatarOverlayIcons[i].listID = ImageList_AddIcon(hAvatarOverlays, hIcon);
- Skin_ReleaseIcon(g_pAvatarOverlayIcons[i].name);
+ IcoLib_Release(g_pAvatarOverlayIcons[i].name);
- hIcon = Skin_GetIcon(g_pStatusOverlayIcons[i].name);
+ hIcon = IcoLib_GetIcon(g_pStatusOverlayIcons[i].name);
g_pStatusOverlayIcons[i].listID = ImageList_AddIcon(hAvatarOverlays, hIcon);
- Skin_ReleaseIcon(g_pStatusOverlayIcons[i].name);
+ IcoLib_Release(g_pStatusOverlayIcons[i].name);
}
- g_hListeningToIcon = Skin_GetIcon("LISTENING_TO_ICON");
+ g_hListeningToIcon = IcoLib_GetIcon("LISTENING_TO_ICON");
pcli->pfnClcBroadcast(INTM_INVALIDATE, 0, 0);
AniAva_UpdateOptions();
@@ -1637,7 +1637,7 @@ static int clcHookModulesLoaded(WPARAM, LPARAM)
TCHAR szMyPath[MAX_PATH];
GetModuleFileName(g_hInst, szMyPath, SIZEOF(szMyPath));
- SKINICONDESC sid = { 0 };
+ SKINICONDESC sid = { 0 };
sid.cx = sid.cy = 16;
sid.defaultFile.t = szMyPath;
sid.flags = SIDF_PATH_TCHAR;
@@ -1646,14 +1646,14 @@ static int clcHookModulesLoaded(WPARAM, LPARAM)
sid.description.a = LPGEN("Listening to");
sid.pszName = "LISTENING_TO_ICON";
sid.iDefaultIndex = -IDI_LISTENING_TO;
- Skin_AddIcon(&sid);
+ IcoLib_AddIcon(&sid);
sid.section.a = LPGEN("Contact list") "/" LPGEN("Avatar overlay");
for (int i = 0; i < SIZEOF(g_pAvatarOverlayIcons); i++) {
sid.description.a = g_pAvatarOverlayIcons[i].description;
sid.pszName = g_pAvatarOverlayIcons[i].name;
sid.iDefaultIndex = -g_pAvatarOverlayIcons[i].id;
- Skin_AddIcon(&sid);
+ IcoLib_AddIcon(&sid);
}
sid.section.a = LPGEN("Contact list") "/" LPGEN("Status overlay");
@@ -1661,7 +1661,7 @@ static int clcHookModulesLoaded(WPARAM, LPARAM)
sid.description.a = g_pStatusOverlayIcons[i].description;
sid.pszName = g_pStatusOverlayIcons[i].name;
sid.iDefaultIndex = -g_pStatusOverlayIcons[i].id;
- Skin_AddIcon(&sid);
+ IcoLib_AddIcon(&sid);
}
clcHookIconsChanged(0, 0);
diff --git a/plugins/Clist_modern/src/modern_clui.cpp b/plugins/Clist_modern/src/modern_clui.cpp
index b1ea419cb8..984f3fb499 100644
--- a/plugins/Clist_modern/src/modern_clui.cpp
+++ b/plugins/Clist_modern/src/modern_clui.cpp
@@ -1566,7 +1566,7 @@ HANDLE RegisterIcolibIconHandle(char *szIcoID, char *szSectionName, char *szDesc
sid.iDefaultIndex = -iDefaultResource;
}
- return Skin_AddIcon(&sid);
+ return IcoLib_AddIcon(&sid);
}
// MAIN WINPROC MESSAGE HANDLERS
@@ -2486,7 +2486,7 @@ LRESULT CLUI::OnDrawItem(UINT, WPARAM wParam, LPARAM lParam)
DrawState(dis->hDC, NULL, NULL, (LPARAM)hIcon, 0, x, y, 0, 0,
DST_ICON | (dis->itemState & ODS_INACTIVE && (((FALSE))) ? DSS_DISABLED : DSS_NORMAL));
- Skin_ReleaseIcon(hIcon);
+ IcoLib_ReleaseIcon(hIcon);
nMirMenuState = dis->itemState;
}
else {
@@ -2533,7 +2533,7 @@ LRESULT CLUI::OnDrawItem(UINT, WPARAM wParam, LPARAM lParam)
mir_snprintf(buf, "Main,ID=MainMenu,Selected=%s,Hot=%s", (dis->itemState&ODS_SELECTED) ? "True" : "False", (dis->itemState&ODS_HOTLIGHT) ? "True" : "False");
SkinDrawGlyph(dis->hDC, &dis->rcItem, &dis->rcItem, buf);
DrawState(dis->hDC, NULL, NULL, (LPARAM)hIcon, 0, (dis->rcItem.right + dis->rcItem.left - GetSystemMetrics(SM_CXSMICON)) / 2 + dx, (dis->rcItem.bottom + dis->rcItem.top - GetSystemMetrics(SM_CYSMICON)) / 2 + dx, 0, 0, DST_ICON);
- Skin_ReleaseIcon(hIcon);
+ IcoLib_ReleaseIcon(hIcon);
nMirMenuState = dis->itemState;
}
diff --git a/plugins/Clist_modern/src/modern_statusbar.cpp b/plugins/Clist_modern/src/modern_statusbar.cpp
index e89d5616ab..1d71974683 100644
--- a/plugins/Clist_modern/src/modern_statusbar.cpp
+++ b/plugins/Clist_modern/src/modern_statusbar.cpp
@@ -506,7 +506,7 @@ int ModernDrawStatusBarWorker(HWND hWnd, HDC hDC)
HICON hLockOverlay = LoadSkinnedIcon(SKINICON_OTHER_STATUS_LOCKED);
if (hLockOverlay != NULL) {
ske_DrawIconEx(hDC, x, iconY, hLockOverlay, iconWidth, iconHeight, 0, NULL, DI_NORMAL | dim);
- Skin_ReleaseIcon(hLockOverlay);
+ IcoLib_ReleaseIcon(hLockOverlay);
}
}
}
@@ -514,7 +514,7 @@ int ModernDrawStatusBarWorker(HWND hWnd, HDC hDC)
if (bNeedDestroy)
DestroyIcon_protect(hIcon);
else
- Skin_ReleaseIcon(hIcon);
+ IcoLib_ReleaseIcon(hIcon);
x += iconWidth + 1;
DeleteObject(rgn);
}
diff --git a/plugins/Clist_modern/src/modern_tbbutton.cpp b/plugins/Clist_modern/src/modern_tbbutton.cpp
index 9d38947961..d78ab4ba15 100644
--- a/plugins/Clist_modern/src/modern_tbbutton.cpp
+++ b/plugins/Clist_modern/src/modern_tbbutton.cpp
@@ -423,12 +423,12 @@ static LRESULT CALLBACK ToolbarButtonProc(HWND hwndDlg, UINT msg, WPARAM wParam
case MBM_SETICOLIBHANDLE:
bct->hIcolibHandle = (HANDLE)lParam;
- bct->hIcon = (bct->hIcolibHandle) ? Skin_GetIconByHandle(bct->hIcolibHandle) : NULL;
+ bct->hIcon = (bct->hIcolibHandle) ? IcoLib_GetIconByHandle(bct->hIcolibHandle) : NULL;
return 1;
case MBM_REFRESHICOLIBICON:
if (bct->hIcolibHandle)
- bct->hIcon = Skin_GetIconByHandle(bct->hIcolibHandle);
+ bct->hIcon = IcoLib_GetIconByHandle(bct->hIcolibHandle);
else
bct->hIcon = NULL;
InvalidateRect(hwndDlg, NULL, TRUE);
diff --git a/plugins/Clist_modern/src/modern_viewmodebar.cpp b/plugins/Clist_modern/src/modern_viewmodebar.cpp
index cd53b1e77b..5f04741f66 100644
--- a/plugins/Clist_modern/src/modern_viewmodebar.cpp
+++ b/plugins/Clist_modern/src/modern_viewmodebar.cpp
@@ -646,7 +646,7 @@ INT_PTR CALLBACK DlgProcViewModesSetup(HWND hwndDlg, UINT msg, WPARAM wParam, LP
for (i = ID_STATUS_OFFLINE; i <= ID_STATUS_OUTTOLUNCH; i++) {
HICON hIcon = LoadSkinnedProtoIcon(NULL, i);
ImageList_AddIcon(himlViewModes, hIcon);
- Skin_ReleaseIcon(hIcon);
+ IcoLib_ReleaseIcon(hIcon);
}
HICON hIcon = (HICON)LoadImage(g_hMirApp, MAKEINTRESOURCE(IDI_SMALLDOT), IMAGE_ICON, 16, 16, 0);
diff --git a/plugins/Clist_nicer/src/CLCButton.cpp b/plugins/Clist_nicer/src/CLCButton.cpp
index 1e21fd318c..a87419a58c 100644
--- a/plugins/Clist_nicer/src/CLCButton.cpp
+++ b/plugins/Clist_nicer/src/CLCButton.cpp
@@ -54,9 +54,9 @@ static void InitDefaultButtons()
tbb.dwFlags |= TTBBF_ASPUSHBUTTON;
tbb.pszTooltipUp = tbb.name = LPGEN(BTNS[i].pszButtonName);
- tbb.hIconHandleUp = Skin_GetIconHandle(BTNS[i].pszButtonID);
+ tbb.hIconHandleUp = IcoLib_GetIconHandle(BTNS[i].pszButtonID);
if (BTNS[i].pszButtonDn)
- tbb.hIconHandleDn = Skin_GetIconHandle(BTNS[i].pszButtonDn);
+ tbb.hIconHandleDn = IcoLib_GetIconHandle(BTNS[i].pszButtonDn);
}
else tbb.dwFlags |= TTBBF_ISSEPARATOR;
diff --git a/plugins/Clist_nicer/src/clistmod.cpp b/plugins/Clist_nicer/src/clistmod.cpp
index c04ac1ba56..26be09aaac 100644
--- a/plugins/Clist_nicer/src/clistmod.cpp
+++ b/plugins/Clist_nicer/src/clistmod.cpp
@@ -67,7 +67,7 @@ int IconFromStatusMode(const char *szProto, int status, MCONTACT hContact, HICON
if (szProto) {
char szBuf[128];
mir_snprintf(szBuf, SIZEOF(szBuf), "%s_conn", szProto);
- *phIcon = Skin_GetIcon(szBuf);
+ *phIcon = IcoLib_GetIcon(szBuf);
}
}
diff --git a/plugins/Clist_nicer/src/clui.cpp b/plugins/Clist_nicer/src/clui.cpp
index 096fe9ff54..c5e69676b6 100644
--- a/plugins/Clist_nicer/src/clui.cpp
+++ b/plugins/Clist_nicer/src/clui.cpp
@@ -248,7 +248,7 @@ static void CacheClientIcons()
for (int i = IDI_OVL_OFFLINE; i <= IDI_OVL_OUTTOLUNCH; i++) {
char szBuffer[128];
mir_snprintf(szBuffer, SIZEOF(szBuffer), "cln_ovl_%d", ID_STATUS_OFFLINE + (i - IDI_OVL_OFFLINE));
- overlayicons[i - IDI_OVL_OFFLINE] = Skin_GetIcon(szBuffer);
+ overlayicons[i - IDI_OVL_OFFLINE] = IcoLib_GetIcon(szBuffer);
}
}
@@ -1686,7 +1686,7 @@ buttons_done:
if (status >= ID_STATUS_CONNECTING && status < ID_STATUS_OFFLINE) {
char szBuffer[128];
mir_snprintf(szBuffer, SIZEOF(szBuffer), "%s_conn", pd->RealName);
- hIcon = Skin_GetIcon(szBuffer);
+ hIcon = IcoLib_GetIcon(szBuffer);
}
else if (cfg::dat.bShowXStatusOnSbar && status > ID_STATUS_OFFLINE) {
int xStatus;
@@ -1708,14 +1708,14 @@ buttons_done:
else if (pd->protopos == nParts - 1)
x -= (cfg::dat.bCRight / 2);
DrawIconEx(dis->hDC, x, (dis->rcItem.top + dis->rcItem.bottom - 16) >> 1, hIcon, 16, 16, 0, NULL, DI_NORMAL);
- Skin_ReleaseIcon(hIcon);
+ IcoLib_ReleaseIcon(hIcon);
if (cfg::getByte("CLUI", "sbar_showlocked", 1)) {
if (cfg::getByte(szProto, "LockMainStatus", 0)) {
hIcon = LoadSkinnedIcon(SKINICON_OTHER_STATUS_LOCKED);
if (hIcon != NULL) {
DrawIconEx(dis->hDC, x, (dis->rcItem.top + dis->rcItem.bottom - 16) >> 1, hIcon, 16, 16, 0, NULL, DI_NORMAL);
- Skin_ReleaseIcon(hIcon);
+ IcoLib_ReleaseIcon(hIcon);
}
}
}
diff --git a/plugins/Clist_nicer/src/viewmodes.cpp b/plugins/Clist_nicer/src/viewmodes.cpp
index 7903d52204..df281499c0 100644
--- a/plugins/Clist_nicer/src/viewmodes.cpp
+++ b/plugins/Clist_nicer/src/viewmodes.cpp
@@ -885,7 +885,7 @@ LRESULT CALLBACK ViewModeFrameWndProc(HWND hwnd, UINT msg, WPARAM wParam, LPARAM
bool bSkinned = cfg::getByte("CLCExt", "bskinned", 0) != 0;
for (int i = 0; i < SIZEOF(_buttons); i++) {
HWND hwndButton = GetDlgItem(hwnd, _buttons[i].btn_id);
- SendMessage(hwndButton, BM_SETIMAGE, IMAGE_ICON, (LPARAM)Skin_GetIcon(_buttons[i].icon));
+ SendMessage(hwndButton, BM_SETIMAGE, IMAGE_ICON, (LPARAM)IcoLib_GetIcon(_buttons[i].icon));
CustomizeButton(hwndButton, bSkinned, !bSkinned, bSkinned);
}
}
diff --git a/plugins/CountryFlags/src/extraimg.cpp b/plugins/CountryFlags/src/extraimg.cpp
index b57a382ea4..cc80628b6c 100644
--- a/plugins/CountryFlags/src/extraimg.cpp
+++ b/plugins/CountryFlags/src/extraimg.cpp
@@ -102,7 +102,7 @@ static void __fastcall SetStatusIcon(MCONTACT hContact,int countryNumber)
Srmm_ModifyIcon(hContact, &sid);
if (sid.hIcon)
- Skin_ReleaseIcon(sid.hIcon);
+ IcoLib_ReleaseIcon(sid.hIcon);
}
// always call in context of main thread
diff --git a/plugins/CountryFlags/src/icons.cpp b/plugins/CountryFlags/src/icons.cpp
index 401f79c15d..8c4ad30328 100644
--- a/plugins/CountryFlags/src/icons.cpp
+++ b/plugins/CountryFlags/src/icons.cpp
@@ -147,7 +147,7 @@ HICON __fastcall LoadFlagIcon(int countryNumber)
char szId[20];
mir_snprintf(szId, SIZEOF(szId), (countryNumber == 0xFFFF) ? "%s0x%X" : "%s%i", "flags_", countryNumber); /* buffer safe */
- return Skin_GetIcon(szId);
+ return IcoLib_GetIcon(szId);
}
int __fastcall CountryNumberToIndex(int countryNumber)
@@ -254,7 +254,7 @@ void InitIcons(void)
}
else sid.hDefaultIcon = NULL;
index = CountryNumberToIndex(countries[i].id);
- phIconHandles[index] = Skin_AddIcon(&sid);
+ phIconHandles[index] = IcoLib_AddIcon(&sid);
if (sid.hDefaultIcon != NULL)
DestroyIcon(sid.hDefaultIcon);
}
diff --git a/plugins/CrashDumper/src/crshdmp_icons.cpp b/plugins/CrashDumper/src/crshdmp_icons.cpp
index 66e0f0e108..d7c5df3424 100644
--- a/plugins/CrashDumper/src/crshdmp_icons.cpp
+++ b/plugins/CrashDumper/src/crshdmp_icons.cpp
@@ -37,7 +37,7 @@ HICON LoadIconEx(int iconId, bool big)
{
for (int i = 0; i < SIZEOF(iconList); i++)
if (iconList[i].defIconID == iconId)
- return Skin_GetIconByHandle(iconList[i].hIcolib, big);
+ return IcoLib_GetIconByHandle(iconList[i].hIcolib, big);
return NULL;
}
diff --git a/plugins/CrashDumper/src/ui.cpp b/plugins/CrashDumper/src/ui.cpp
index ccad81bc18..b5ea469cba 100644
--- a/plugins/CrashDumper/src/ui.cpp
+++ b/plugins/CrashDumper/src/ui.cpp
@@ -165,8 +165,8 @@ INT_PTR CALLBACK DlgProcView(HWND hwndDlg, UINT msg, WPARAM wParam, LPARAM lPara
case WM_DESTROY:
hViewWnd = NULL;
- Skin_ReleaseIcon((HICON)SendMessage(hwndDlg, WM_SETICON, ICON_BIG, 0));
- Skin_ReleaseIcon((HICON)SendMessage(hwndDlg, WM_SETICON, ICON_SMALL, 0));
+ IcoLib_ReleaseIcon((HICON)SendMessage(hwndDlg, WM_SETICON, ICON_BIG, 0));
+ IcoLib_ReleaseIcon((HICON)SendMessage(hwndDlg, WM_SETICON, ICON_SMALL, 0));
Utils_SaveWindowPosition(hwndDlg, NULL, PluginName, "ViewInfo_");
if (servicemode)
PostQuitMessage(0);
@@ -291,8 +291,8 @@ LRESULT CALLBACK DlgProcPopup(HWND hWnd, UINT msg, WPARAM wParam, LPARAM lParam)
break;
case UM_FREEPLUGINDATA:
- Skin_ReleaseIcon((HICON)SendMessage(hWnd, WM_SETICON, ICON_BIG, 0));
- Skin_ReleaseIcon((HICON)SendMessage(hWnd, WM_SETICON, ICON_SMALL, 0));
+ IcoLib_ReleaseIcon((HICON)SendMessage(hWnd, WM_SETICON, ICON_BIG, 0));
+ IcoLib_ReleaseIcon((HICON)SendMessage(hWnd, WM_SETICON, ICON_SMALL, 0));
break;
}
diff --git a/plugins/Db3x_mmap/src/ui.cpp b/plugins/Db3x_mmap/src/ui.cpp
index ec5fcb4184..c19b0fc031 100644
--- a/plugins/Db3x_mmap/src/ui.cpp
+++ b/plugins/Db3x_mmap/src/ui.cpp
@@ -159,7 +159,7 @@ static INT_PTR CALLBACK sttChangePassword(HWND hwndDlg, UINT uMsg, WPARAM wParam
switch (uMsg) {
case WM_INITDIALOG:
TranslateDialogDefault(hwndDlg);
- SendDlgItemMessage(hwndDlg, IDC_HEADERBAR, WM_SETICON, ICON_SMALL, (LPARAM)Skin_GetIconByHandle(iconList[0].hIcolib, true));
+ SendDlgItemMessage(hwndDlg, IDC_HEADERBAR, WM_SETICON, ICON_SMALL, (LPARAM)IcoLib_GetIconByHandle(iconList[0].hIcolib, true));
param = (DlgChangePassParam*)lParam;
SetWindowLongPtr(hwndDlg, GWLP_USERDATA, lParam);
@@ -229,7 +229,7 @@ static INT_PTR CALLBACK sttChangePassword(HWND hwndDlg, UINT uMsg, WPARAM wParam
case WM_DESTROY:
KillTimer(hwndDlg, 1);
- Skin_ReleaseIcon((HICON)SendMessage(hwndDlg, WM_GETICON, ICON_SMALL, 0));
+ IcoLib_ReleaseIcon((HICON)SendMessage(hwndDlg, WM_GETICON, ICON_SMALL, 0));
}
return FALSE;
diff --git a/plugins/DbEditorPP/src/icons.cpp b/plugins/DbEditorPP/src/icons.cpp
index 4ccb5d2dde..475c6e6ce8 100644
--- a/plugins/DbEditorPP/src/icons.cpp
+++ b/plugins/DbEditorPP/src/icons.cpp
@@ -30,7 +30,7 @@ HICON LoadSkinnedDBEIcon(int icon)
{
for (int i = 0; i < SIZEOF(iconList); i++)
if (iconList[i].defIconID == icon)
- return Skin_GetIconByHandle(iconList[i].hIcolib);
+ return IcoLib_GetIconByHandle(iconList[i].hIcolib);
return LoadIcon(hInst, MAKEINTRESOURCE(icon));
}
diff --git a/plugins/Db_autobackups/src/backup.cpp b/plugins/Db_autobackups/src/backup.cpp
index b63690ac72..08d5642e51 100644
--- a/plugins/Db_autobackups/src/backup.cpp
+++ b/plugins/Db_autobackups/src/backup.cpp
@@ -36,7 +36,7 @@ void ShowPopup(TCHAR* ptszText, TCHAR* ptszHeader, TCHAR* ptszPath)
if (ptszPath != NULL)
ppd.PluginData = (void*)mir_tstrdup(ptszPath);
ppd.PluginWindowProc = DlgProcPopup;
- ppd.lchIcon = Skin_GetIcon(iconList[0].szName);
+ ppd.lchIcon = IcoLib_GetIcon(iconList[0].szName);
PUAddPopupT(&ppd);
}
diff --git a/plugins/Dropbox/src/dropbox_icons.cpp b/plugins/Dropbox/src/dropbox_icons.cpp
index 094c27bcb7..ba92aaa8f2 100644
--- a/plugins/Dropbox/src/dropbox_icons.cpp
+++ b/plugins/Dropbox/src/dropbox_icons.cpp
@@ -24,7 +24,7 @@ HICON LoadIconEx(int iconId, bool big)
{
for (int i = 0; i < SIZEOF(iconList); i++)
if (iconList[i].defIconID == iconId)
- return Skin_GetIconByHandle(iconList[i].hIcolib, big);
+ return IcoLib_GetIconByHandle(iconList[i].hIcolib, big);
return NULL;
}
diff --git a/plugins/FTPFileYM/src/utils.cpp b/plugins/FTPFileYM/src/utils.cpp
index 75b5ee1da5..89ec7f8ae0 100644
--- a/plugins/FTPFileYM/src/utils.cpp
+++ b/plugins/FTPFileYM/src/utils.cpp
@@ -49,7 +49,7 @@ HICON Utils::loadIconEx(char *szName)
{
char buff[100];
mir_snprintf(buff, "%s_%s", MODULE, szName);
- return Skin_GetIcon(buff);
+ return IcoLib_GetIcon(buff);
}
TCHAR *Utils::getFileNameFromPath(TCHAR *stzPath)
diff --git a/plugins/FavContacts/src/menu.cpp b/plugins/FavContacts/src/menu.cpp
index ae4e4ab87f..0045f5da1b 100644
--- a/plugins/FavContacts/src/menu.cpp
+++ b/plugins/FavContacts/src/menu.cpp
@@ -259,7 +259,7 @@ static BOOL sttDrawItem_Contact(LPDRAWITEMSTRUCT lpdis, Options *options = NULL)
if (options->wMaxRecent && db_get_b(hContact, "FavContacts", "IsFavourite", 0)) {
DrawIconEx(hdcTemp, lpdis->rcItem.right - 18, (lpdis->rcItem.top + lpdis->rcItem.bottom - 16) / 2,
- Skin_GetIconByHandle(iconList[0].hIcolib), 16, 16, 0, NULL, DI_NORMAL);
+ IcoLib_GetIconByHandle(iconList[0].hIcolib), 16, 16, 0, NULL, DI_NORMAL);
lpdis->rcItem.right -= 20;
}
diff --git a/plugins/FavContacts/src/services.cpp b/plugins/FavContacts/src/services.cpp
index c17e515b2d..7ee80afda2 100644
--- a/plugins/FavContacts/src/services.cpp
+++ b/plugins/FavContacts/src/services.cpp
@@ -161,8 +161,8 @@ int ProcessModulesLoaded(WPARAM, LPARAM)
StatusIconData sid = { sizeof(sid) };
sid.szModule = "FavContacts";
sid.szTooltip = LPGEN("Favorite Contacts");
- sid.hIcon = Skin_GetIconByHandle(iconList[0].hIcolib);
- sid.hIconDisabled = Skin_GetIconByHandle(iconList[1].hIcolib);
+ sid.hIcon = IcoLib_GetIconByHandle(iconList[0].hIcolib);
+ sid.hIconDisabled = IcoLib_GetIconByHandle(iconList[1].hIcolib);
Srmm_AddIcon(&sid);
HookEvent(ME_MSG_ICONPRESSED, ProcessSrmmIconClick);
diff --git a/plugins/FileAsMessage/src/main.cpp b/plugins/FileAsMessage/src/main.cpp
index e54c6b8353..f29f3fb3da 100644
--- a/plugins/FileAsMessage/src/main.cpp
+++ b/plugins/FileAsMessage/src/main.cpp
@@ -43,7 +43,7 @@ int iIconId[5] = { 3, 2, 4, 1, 0 };
int OnSkinIconsChanged(WPARAM wParam, LPARAM lParam)
{
for (int indx = 0; indx < SIZEOF(hIcons); indx++)
- hIcons[indx] = Skin_GetIconByHandle(iconList[indx].hIcolib);
+ hIcons[indx] = IcoLib_GetIconByHandle(iconList[indx].hIcolib);
WindowList_Broadcast(hFileList, WM_FE_SKINCHANGE, 0, 0);
@@ -170,7 +170,7 @@ extern "C" __declspec(dllexport) PLUGININFOEX *MirandaPluginInfoEx(DWORD dwVersi
static int OnModulesLoaded(WPARAM wparam, LPARAM lparam)
{
for (int indx = 0; indx < SIZEOF(hIcons); indx++)
- hIcons[indx] = Skin_GetIconByHandle(iconList[indx].hIcolib);
+ hIcons[indx] = IcoLib_GetIconByHandle(iconList[indx].hIcolib);
hHookSkinIconsChanged = HookEvent(ME_SKIN2_ICONSCHANGED, OnSkinIconsChanged);
diff --git a/plugins/FingerprintNG/src/fingerprint.cpp b/plugins/FingerprintNG/src/fingerprint.cpp
index edc787d283..32c13cf652 100644
--- a/plugins/FingerprintNG/src/fingerprint.cpp
+++ b/plugins/FingerprintNG/src/fingerprint.cpp
@@ -51,7 +51,7 @@ void __fastcall Prepare(KN_FP_MASK* mask, bool bEnable)
mask->szMaskUpper = NULL;
if (mask->hIcolibItem)
- Skin_RemoveIcon(mask->szIconName);
+ IcoLib_RemoveIcon(mask->szIconName);
mask->hIcolibItem = NULL;
if (!mask->szMask || !bEnable)
@@ -78,7 +78,7 @@ void __fastcall Prepare(KN_FP_MASK* mask, bool bEnable)
if (SectName == NULL)
return;
- SKINICONDESC sid = { 0 };
+ SKINICONDESC sid = { 0 };
sid.flags = SIDF_ALL_TCHAR;
sid.section.t = SectName;
sid.pszName = mask->szIconName;
@@ -86,7 +86,7 @@ void __fastcall Prepare(KN_FP_MASK* mask, bool bEnable)
sid.defaultFile.t = destfile;
sid.iDefaultIndex = -mask->iIconIndex;
sid.cx = sid.cy = 16;
- mask->hIcolibItem = Skin_AddIcon(&sid);
+ mask->hIcolibItem = IcoLib_AddIcon(&sid);
}
/*
@@ -374,17 +374,17 @@ HICON __fastcall CreateIconFromIndexes(short base, short overlay, short overlay2
HICON icOverlay4 = NULL;
KN_FP_MASK* mainMask = &(def_kn_fp_mask[base]);
- icMain = Skin_GetIconByHandle(mainMask->hIcolibItem);
+ icMain = IcoLib_GetIconByHandle(mainMask->hIcolibItem);
if (icMain) {
KN_FP_MASK* overlayMask = (overlay != -1) ? &(def_kn_fp_overlays_mask[overlay]) : NULL;
KN_FP_MASK* overlay2Mask = (overlay2 != -1) ? &(def_kn_fp_overlays2_mask[overlay2]) : NULL;
KN_FP_MASK* overlay3Mask = (overlay3 != -1) ? &(def_kn_fp_overlays3_mask[overlay3]) : NULL;
KN_FP_MASK* overlay4Mask = (overlay4 != -1) ? &(def_kn_fp_overlays4_mask[overlay4]) : NULL;
- icOverlay = (overlayMask == NULL) ? NULL : Skin_GetIconByHandle(overlayMask->hIcolibItem);
- icOverlay2 = (overlay2Mask == NULL) ? NULL : Skin_GetIconByHandle(overlay2Mask->hIcolibItem);
- icOverlay3 = (overlay3Mask == NULL) ? NULL : Skin_GetIconByHandle(overlay3Mask->hIcolibItem);
- icOverlay4 = (overlay4Mask == NULL) ? NULL : Skin_GetIconByHandle(overlay4Mask->hIcolibItem);
+ icOverlay = (overlayMask == NULL) ? NULL : IcoLib_GetIconByHandle(overlayMask->hIcolibItem);
+ icOverlay2 = (overlay2Mask == NULL) ? NULL : IcoLib_GetIconByHandle(overlay2Mask->hIcolibItem);
+ icOverlay3 = (overlay3Mask == NULL) ? NULL : IcoLib_GetIconByHandle(overlay3Mask->hIcolibItem);
+ icOverlay4 = (overlay4Mask == NULL) ? NULL : IcoLib_GetIconByHandle(overlay4Mask->hIcolibItem);
hIcon = icMain;
@@ -412,11 +412,11 @@ HICON __fastcall CreateIconFromIndexes(short base, short overlay, short overlay2
if (hIcon == icMain)
hIcon = CopyIcon(icMain);
- Skin_ReleaseIcon(icMain);
- Skin_ReleaseIcon(icOverlay);
- Skin_ReleaseIcon(icOverlay2);
- Skin_ReleaseIcon(icOverlay3);
- Skin_ReleaseIcon(icOverlay4);
+ IcoLib_ReleaseIcon(icMain);
+ IcoLib_ReleaseIcon(icOverlay);
+ IcoLib_ReleaseIcon(icOverlay2);
+ IcoLib_ReleaseIcon(icOverlay3);
+ IcoLib_ReleaseIcon(icOverlay4);
return hIcon;
}
diff --git a/plugins/HistoryPlusPlus/hpp_options.pas b/plugins/HistoryPlusPlus/hpp_options.pas
index 3b135b2678..52e6546d0a 100644
--- a/plugins/HistoryPlusPlus/hpp_options.pas
+++ b/plugins/HistoryPlusPlus/hpp_options.pas
@@ -353,7 +353,7 @@ begin
try
for i := 0 to High(hppIcons) do
begin
- ic := CallService(MS_SKIN2_GETICON, 0, LPARAM(hppIcons[i].name));
+ ic := IcoLib_GetIcon(hppIcons[i].name,0);
if hppIcons[i].handle <> ic then
begin
hppIcons[i].handle := ic;
diff --git a/plugins/HistoryStats/src/mu_common.cpp b/plugins/HistoryStats/src/mu_common.cpp
index 5bd5a5a4ab..5a02f8320c 100644
--- a/plugins/HistoryStats/src/mu_common.cpp
+++ b/plugins/HistoryStats/src/mu_common.cpp
@@ -134,7 +134,7 @@ namespace mu
sid.cx = cx;
sid.cy = cy;
sid.flags = SIDF_TCHAR;
- Skin_AddIcon(&sid);
+ IcoLib_AddIcon(&sid);
}
void addIcon(const TCHAR* szSection, const TCHAR* szDescription, const char* szIconName, HICON hDefaultIcon, int cx /* = 16 */, int cy /* = 16 */)
@@ -149,12 +149,12 @@ namespace mu
sid.cx = cx;
sid.cy = cy;
sid.flags = SIDF_TCHAR;
- Skin_AddIcon(&sid);
+ IcoLib_AddIcon(&sid);
}
HICON getIcon(const char* szIconName)
{
- return reinterpret_cast<HICON>(CallService(MS_SKIN2_GETICON, 0, reinterpret_cast<LPARAM>(szIconName)));
+ return IcoLib_GetIcon(szIconName);
}
}
diff --git a/plugins/HistorySweeperLight/src/options.cpp b/plugins/HistorySweeperLight/src/options.cpp
index 6b4699a0ef..ee7b332859 100644
--- a/plugins/HistorySweeperLight/src/options.cpp
+++ b/plugins/HistorySweeperLight/src/options.cpp
@@ -63,7 +63,7 @@ HICON LoadIconEx(const char* name)
{
char szSettingName[100];
mir_snprintf(szSettingName, SIZEOF(szSettingName), "%s_%s", ModuleName, name);
- return Skin_GetIcon(szSettingName);
+ return IcoLib_GetIcon(szSettingName);
}
HANDLE GetIconHandle(const char* name)
@@ -79,7 +79,7 @@ void ReleaseIconEx(const char* name)
{
char szSettingName[100];
mir_snprintf(szSettingName, SIZEOF(szSettingName), "%s_%s", ModuleName, name);
- Skin_ReleaseIcon(szSettingName);
+ IcoLib_Release(szSettingName);
}
HANDLE hAllContacts, hSystemHistory;
@@ -202,7 +202,7 @@ INT_PTR CALLBACK DlgProcHSOpts(HWND hwndDlg, UINT msg, WPARAM wParam, LPARAM lPa
HICON hIcon = LoadSkinnedIcon(SKINICON_OTHER_SMALLDOT);
ImageList_AddIcon(hIml, hIcon);
- Skin_ReleaseIcon(hIcon);
+ IcoLib_ReleaseIcon(hIcon);
hIcon = LoadIconEx("act1");
ImageList_AddIcon(hIml, hIcon);
diff --git a/plugins/IEView/src/Options.cpp b/plugins/IEView/src/Options.cpp
index 1ae24e9dfd..9be7767e0d 100644
--- a/plugins/IEView/src/Options.cpp
+++ b/plugins/IEView/src/Options.cpp
@@ -347,7 +347,7 @@ static void RefreshProtoIcons()
if (hIcon == NULL) {
hIcon = (HICON)LoadSkinnedIcon(SKINICON_OTHER_MIRANDA);
ImageList_AddIcon(hProtocolImageList, hIcon);
- Skin_ReleaseIcon(hIcon);
+ IcoLib_ReleaseIcon(hIcon);
}
}
}
diff --git a/plugins/Import/src/utils.cpp b/plugins/Import/src/utils.cpp
index 0b03c5299e..826faa8da7 100644
--- a/plugins/Import/src/utils.cpp
+++ b/plugins/Import/src/utils.cpp
@@ -220,7 +220,7 @@ HICON GetIcon(int iIconId, int size)
{
for (int i = 0; i < SIZEOF(iconList); i++)
if (iconList[i].defIconID == iIconId)
- return Skin_GetIconByHandle(iconList[i].hIcolib, size);
+ return IcoLib_GetIconByHandle(iconList[i].hIcolib, size);
return NULL;
}
diff --git a/plugins/MenuItemEx/src/images.cpp b/plugins/MenuItemEx/src/images.cpp
index e0c5d0ede6..451e694903 100644
--- a/plugins/MenuItemEx/src/images.cpp
+++ b/plugins/MenuItemEx/src/images.cpp
@@ -322,7 +322,7 @@ HICON BindOverlayIcon(HICON SourceIcon, LPCSTR OverlayIconName)
CorrectBitmap32Alpha(TargetIconInfo.hbmColor, FALSE);
GetObject(TargetIconInfo.hbmColor, sizeof(BITMAP), &TargetBitmapInfo);
- OverlayIcon = Skin_GetIcon(OverlayIconName);
+ OverlayIcon = IcoLib_GetIcon(OverlayIconName);
if (!GetIconInfo(OverlayIcon, &OverlayIconInfo) || !GetObject(OverlayIconInfo.hbmColor, sizeof(BITMAP), &OverlayBitmapInfo))
return NULL;
diff --git a/plugins/MenuItemEx/src/main.cpp b/plugins/MenuItemEx/src/main.cpp
index 3a97fb52fb..2f86c70366 100644
--- a/plugins/MenuItemEx/src/main.cpp
+++ b/plugins/MenuItemEx/src/main.cpp
@@ -790,7 +790,7 @@ int BuildMenu(WPARAM wparam, LPARAM)
BYTE bHidden = db_get_b(hContact, "CList", "Hidden", 0);
CLISTMENUITEM mi = { sizeof(mi) };
mi.flags |= CMIM_ICON | CMIM_NAME | CMIF_UNICODE;
- mi.hIcon = Skin_GetIcon(bHidden ? "miex_showil" : "miex_hidefl");
+ mi.hIcon = IcoLib_GetIcon(bHidden ? "miex_showil" : "miex_hidefl");
mi.ptszName = bHidden ? LPGENT("Show in list") : LPGENT("Hide from list");
Menu_ModifyItem(hmenuHide, &mi);
}
@@ -916,7 +916,7 @@ static int TabsrmmButtonsInit(WPARAM, LPARAM)
bbd.dwDefPos = 1000;
bbd.ptszTooltip = LPGENT("Browse Received Files");
bbd.bbbFlags = BBBF_ISLSIDEBUTTON | BBBF_CANBEHIDDEN;
- bbd.hIcon = Skin_GetIconHandle("miex_recfiles");
+ bbd.hIcon = IcoLib_GetIconHandle("miex_recfiles");
CallService(MS_BB_ADDBUTTON, 0, (LPARAM)&bbd);
return 0;
@@ -996,7 +996,7 @@ static int PluginInit(WPARAM, LPARAM)
mi.ptszName = LPGENT("Ignore");
mi.pszService = 0;
mi.flags |= CMIF_ROOTHANDLE;
- mi.hIcon = Skin_GetIcon("miex_ignore");
+ mi.hIcon = IcoLib_GetIcon("miex_ignore");
hmenuIgnore = Menu_AddContactMenuItem(&mi);
hIgnoreItem[0] = AddSubmenuItem(hmenuIgnore, ii[0].name, LoadSkinnedIcon(ii[0].icon), 0, MS_IGNORE, pos, ii[0].type);
@@ -1008,13 +1008,13 @@ static int PluginInit(WPARAM, LPARAM)
ood.cbSize = sizeof(ood);
ood.pszGroup = "Contacts";
ood.pszPage = "Ignore";
- AddSubmenuItem(hmenuIgnore, LPGENT("Open ignore settings"), Skin_GetIcon("miex_ignore"), 0, "Opt/OpenOptions", pos, (int)&ood);
+ AddSubmenuItem(hmenuIgnore, LPGENT("Open ignore settings"), IcoLib_GetIcon("miex_ignore"), 0, "Opt/OpenOptions", pos, (int)&ood);
mi.pszPopupName = 0;
mi.position++;
mi.ptszName = LPGENT("Copy to Account");
mi.pszService = MS_PROTO;
- mi.hIcon = Skin_GetIcon("miex_protocol");
+ mi.hIcon = IcoLib_GetIcon("miex_protocol");
hmenuProto = Menu_AddContactMenuItem(&mi);
EnumProtoSubmenu(0, 0);
@@ -1041,7 +1041,7 @@ static int PluginInit(WPARAM, LPARAM)
mi.position++;
mi.ptszName = LPGENT("Browse Received Files");
mi.pszService = MS_RECVFILES;
- mi.hIcon = Skin_GetIcon("miex_recfiles");
+ mi.hIcon = IcoLib_GetIcon("miex_recfiles");
hmenuRecvFiles = Menu_AddContactMenuItem(&mi);
mi.position++;
@@ -1060,9 +1060,9 @@ static int PluginInit(WPARAM, LPARAM)
mi.pszService = MS_COPYMIRVER;
hmenuCopyMirVer = Menu_AddContactMenuItem(&mi);
- hIcon[0] = Skin_GetIcon("miex_copymver");
- hIcon[1] = Skin_GetIcon("miex_vis");
- hIcon[2] = Skin_GetIcon("miex_invis");
+ hIcon[0] = IcoLib_GetIcon("miex_copymver");
+ hIcon[1] = IcoLib_GetIcon("miex_vis");
+ hIcon[2] = IcoLib_GetIcon("miex_invis");
hIcon[3] = MakeHalfAlphaIcon(hIcon[1]);
hIcon[4] = MakeHalfAlphaIcon(hIcon[2]);
diff --git a/plugins/MessageState/src/messagestate.cpp b/plugins/MessageState/src/messagestate.cpp
index 827b0767ad..a8a9fa8aec 100644
--- a/plugins/MessageState/src/messagestate.cpp
+++ b/plugins/MessageState/src/messagestate.cpp
@@ -38,7 +38,7 @@ void SetSRMMIcon(MCONTACT hContact, SRMM_ICON_TYPE type, time_t time = 0)
}
case ICON_READ:
{
- sid.hIcon = Skin_GetIcon("read_icon");
+ sid.hIcon = IcoLib_GetIcon("read_icon");
TCHAR ttime[64];
_locale_t locale = _create_locale(LC_ALL, "");
_tcsftime_l(ttime, SIZEOF(ttime), _T("%X %x"), localtime(&time), locale);
@@ -49,19 +49,19 @@ void SetSRMMIcon(MCONTACT hContact, SRMM_ICON_TYPE type, time_t time = 0)
}
case ICON_UNREAD:
{
- sid.hIcon = Skin_GetIcon("unread_icon");
+ sid.hIcon = IcoLib_GetIcon("unread_icon");
sid.tszTooltip = TranslateT("Last message is not read");
break;
}
case ICON_FAILED:
{
- sid.hIcon = Skin_GetIcon("fail_icon");
+ sid.hIcon = IcoLib_GetIcon("fail_icon");
sid.tszTooltip = TranslateT("Last message was not sent.");
break;
}
case ICON_NOSENT:
{
- sid.hIcon = Skin_GetIcon("nosent_icon");
+ sid.hIcon = IcoLib_GetIcon("nosent_icon");
sid.tszTooltip = TranslateT("Sending...");
break;
}
diff --git a/plugins/MirLua/src/m_icolib.cpp b/plugins/MirLua/src/m_icolib.cpp
index 22da2cbc43..e3bbe36b54 100644
--- a/plugins/MirLua/src/m_icolib.cpp
+++ b/plugins/MirLua/src/m_icolib.cpp
@@ -16,7 +16,7 @@ static int lua_AddIcon(lua_State *L)
si.defaultFile.t = filePath;
si.iDefaultIndex = -IDI_ICON;
- HANDLE res = ::Skin_AddIcon(&si);
+ HANDLE res = ::IcoLib_AddIcon(&si);
lua_pushlightuserdata(L, res);
return 1;
@@ -27,7 +27,7 @@ static int lua_GetIcon(lua_State *L)
char iconName[MAX_PATH];
mir_snprintf(iconName, SIZEOF(iconName), "%s_%s", MODULE, luaL_checkstring(L, 1));
- HANDLE res = ::Skin_GetIconHandle(iconName);
+ HANDLE res = ::IcoLib_GetIconHandle(iconName);
lua_pushlightuserdata(L, res);
return 1;
@@ -38,12 +38,12 @@ static int lua_RemoveIcon(lua_State *L)
INT_PTR res = 0;
if (lua_isuserdata(L, 1))
- res = ::CallService(MS_SKIN2_REMOVEICON, (WPARAM)lua_touserdata(L, 1), 0);
+ ::IcoLib_RemoveIconByHandle(lua_touserdata(L, 1));
else if (lua_isstring(L, 1))
{
char iconName[MAX_PATH];
mir_snprintf(iconName, SIZEOF(iconName), "%s_%s", MODULE, lua_tostring(L, 1));
- res = ::CallService(MS_SKIN2_REMOVEICON, 0, (LPARAM)iconName);
+ ::IcoLib_RemoveIcon(iconName);
}
else
res = 1;
diff --git a/plugins/MirOTR/src/icons.cpp b/plugins/MirOTR/src/icons.cpp
index ca38927383..fa92c1804c 100644
--- a/plugins/MirOTR/src/icons.cpp
+++ b/plugins/MirOTR/src/icons.cpp
@@ -1,7 +1,5 @@
#include "stdafx.h"
-TCHAR g_dllpath[1024];
-
static IconItem iconList[] = {
{ LPGEN(LANG_ICON_OTR), ICON_OTR, IDI_OTR },
{ LPGEN(LANG_ICON_PRIVATE), ICON_PRIVATE, IDI_PRIVATE },
@@ -15,22 +13,3 @@ void InitIcons()
{
Icon_Register(hInst, "OTR", iconList, SIZEOF(iconList));
}
-
-HICON LoadIcon(const char* name, int big) {
- return Skin_GetIcon(name, big);
-}
-
-HANDLE GetIconHandle(const char* name)
-{
- return Skin_GetIconHandle(name);
-}
-
-void ReleaseIcon(const char* name, int big)
-{
- Skin_ReleaseIcon(name, big);
-}
-
-void ReleaseIcon(HICON handle, int big)
-{
- Skin_ReleaseIcon(handle);
-}
diff --git a/plugins/MirOTR/src/icons.h b/plugins/MirOTR/src/icons.h
index 039b455773..a366517bdc 100644
--- a/plugins/MirOTR/src/icons.h
+++ b/plugins/MirOTR/src/icons.h
@@ -7,7 +7,3 @@
#define ICON_REFRESH (MODULENAME"_refresh")
void InitIcons();
-HICON LoadIcon(const char* name, int big);
-HANDLE GetIconHandle(const char* name);
-void ReleaseIcon(const char* name, int big);
-void ReleaseIcon(HICON handle, int big); \ No newline at end of file
diff --git a/plugins/MirOTR/src/mirotrmenu.cpp b/plugins/MirOTR/src/mirotrmenu.cpp
index c616756954..6c685d11f8 100644
--- a/plugins/MirOTR/src/mirotrmenu.cpp
+++ b/plugins/MirOTR/src/mirotrmenu.cpp
@@ -106,25 +106,25 @@ INT_PTR MirOTRMenuCheckService(WPARAM wParam,LPARAM)
mi.flags = CMIM_NAME | CMIM_ICON | CMIF_TCHAR;
switch (level) {
case TRUST_PRIVATE:{
- mi.hIcolibItem = GetIconHandle(ICON_PRIVATE);
+ mi.hIcolibItem = IcoLib_GetIconHandle(ICON_PRIVATE);
mir_tstrncpy(text,TranslateT(LANG_STATUS_PRIVATE),SIZEOF(text));
size_t len = mir_tstrlen(text);
if(len < SIZEOF(text))
mir_sntprintf(text+len, SIZEOF(text)-len, _T(" [v%i]"), context->protocol_version);
break;}
case TRUST_UNVERIFIED:{
- mi.hIcolibItem = GetIconHandle(ICON_UNVERIFIED);
+ mi.hIcolibItem = IcoLib_GetIconHandle(ICON_UNVERIFIED);
mir_tstrncpy(text,TranslateT(LANG_STATUS_UNVERIFIED),SIZEOF(text));
size_t len = mir_tstrlen(text);
if(len < SIZEOF(text))
mir_sntprintf(text+len, SIZEOF(text)-len, _T(" [v%i]"), context->protocol_version);
break;}
case TRUST_FINISHED:
- mi.hIcolibItem = GetIconHandle(ICON_FINISHED);
+ mi.hIcolibItem = IcoLib_GetIconHandle(ICON_FINISHED);
mi.ptszName = TranslateT(LANG_STATUS_FINISHED);
break;
default:
- mi.hIcolibItem = GetIconHandle(ICON_NOT_PRIVATE);
+ mi.hIcolibItem = IcoLib_GetIconHandle(ICON_NOT_PRIVATE);
mi.ptszName = TranslateT(LANG_STATUS_DISABLED);
}
CallService(MO_MODIFYMENUITEM, (WPARAM)hStatusInfoItem, (LPARAM)&mi);
@@ -228,28 +228,28 @@ void InitMirOTRMenu(void)
mi.ptszName = LANG_MENU_START;
mi.position = 100001;
mi.pszService = MS_OTR_MENUSTART;
- mi.icolibItem = GetIconHandle(ICON_UNVERIFIED);
+ mi.icolibItem = IcoLib_GetIconHandle(ICON_UNVERIFIED);
AddMirOTRMenuItem(0, (LPARAM) &mi);
mi.flags = CMIF_TCHAR | CMIF_NOTNOTPRIVATE | CMIF_NOTFINISHED;
mi.ptszName = LANG_MENU_REFRESH;
mi.position = 100002;
mi.pszService = MS_OTR_MENUREFRESH;
- mi.icolibItem = GetIconHandle(ICON_FINISHED);
+ mi.icolibItem = IcoLib_GetIconHandle(ICON_FINISHED);
AddMirOTRMenuItem(0, (LPARAM) &mi);
mi.flags = CMIF_TCHAR | CMIF_NOTNOTPRIVATE;
mi.ptszName = LANG_MENU_STOP;
mi.position = 100003;
mi.pszService = MS_OTR_MENUSTOP;
- mi.icolibItem = GetIconHandle(ICON_NOT_PRIVATE);
+ mi.icolibItem = IcoLib_GetIconHandle(ICON_NOT_PRIVATE);
AddMirOTRMenuItem(0, (LPARAM) &mi);
mi.flags = CMIF_TCHAR | CMIF_NOTNOTPRIVATE | CMIF_NOTFINISHED;
mi.ptszName = LANG_MENU_VERIFY;
mi.position = 200001;
mi.pszService = MS_OTR_MENUVERIFY;
- mi.icolibItem = GetIconHandle(ICON_PRIVATE);
+ mi.icolibItem = IcoLib_GetIconHandle(ICON_PRIVATE);
AddMirOTRMenuItem(0, (LPARAM) &mi);
mi.flags = CMIF_TCHAR|CMIF_CHECKED;
diff --git a/plugins/MirOTR/src/otr.cpp b/plugins/MirOTR/src/otr.cpp
index cda80811eb..9d5a690cd3 100644
--- a/plugins/MirOTR/src/otr.cpp
+++ b/plugins/MirOTR/src/otr.cpp
@@ -55,7 +55,7 @@ INT_PTR CALLBACK GenKeyDlgBoxProc(HWND hWndDlg, UINT msg, WPARAM wParam, LPARAM
return 0;
}
TranslateDialogDefault(hWndDlg);
- SetClassLongPtr(hWndDlg, GCLP_HICON, (LONG_PTR)LoadIcon(ICON_OTR, 1));
+ SetClassLongPtr(hWndDlg, GCLP_HICON, (LONG_PTR)IcoLib_GetIcon(ICON_OTR, 1));
TCHAR buff[256];
TCHAR *proto = mir_a2t((char*)lParam);
mir_sntprintf(buff, TranslateT(LANG_GENERATE_KEY), proto);
@@ -71,7 +71,7 @@ INT_PTR CALLBACK GenKeyDlgBoxProc(HWND hWndDlg, UINT msg, WPARAM wParam, LPARAM
return TRUE;
case WM_DESTROY:
SetClassLongPtr(hWndDlg, GCLP_HICON, 0);
- ReleaseIcon(ICON_OTR, 1);
+ IcoLib_Release(ICON_OTR, 1);
}
return FALSE;
}
diff --git a/plugins/MirOTR/src/svcs_menu.cpp b/plugins/MirOTR/src/svcs_menu.cpp
index caf9fed357..d5837ae2bc 100644
--- a/plugins/MirOTR/src/svcs_menu.cpp
+++ b/plugins/MirOTR/src/svcs_menu.cpp
@@ -164,13 +164,13 @@ void InitMenu()
mi.ptszName = _T(LANG_STOP_OTR);
mi.pszService = MS_OTR_MENUSTOP;
- mi.icolibItem = GetIconHandle(ICON_PRIVATE);
+ mi.icolibItem = IcoLib_GetIconHandle(ICON_PRIVATE);
hStopItem = Menu_AddContactMenuItem(&mi);
mi.ptszName = _T(LANG_START_OTR);
mi.pszService = MS_OTR_MENUSTART;
- mi.icolibItem = GetIconHandle(ICON_NOT_PRIVATE);
+ mi.icolibItem = IcoLib_GetIconHandle(ICON_NOT_PRIVATE);
hStartItem = Menu_AddContactMenuItem(&mi);
diff --git a/plugins/MirOTR/src/svcs_srmm.cpp b/plugins/MirOTR/src/svcs_srmm.cpp
index 62f37c9daa..51ebb6145d 100644
--- a/plugins/MirOTR/src/svcs_srmm.cpp
+++ b/plugins/MirOTR/src/svcs_srmm.cpp
@@ -41,22 +41,22 @@ void SetEncryptionStatus(MCONTACT hContact, TrustLevel level)
case TRUST_FINISHED:
sid.flags = 0;
button.ptszTooltip = TranslateT(LANG_STATUS_FINISHED);
- button.hIcon = GetIconHandle(ICON_FINISHED);
+ button.hIcon = IcoLib_GetIconHandle(ICON_FINISHED);
break;
case TRUST_UNVERIFIED:
sid2.flags = MBF_DISABLED;
button.ptszTooltip = TranslateT(LANG_STATUS_UNVERIFIED);
- button.hIcon = GetIconHandle(ICON_UNVERIFIED);
+ button.hIcon = IcoLib_GetIconHandle(ICON_UNVERIFIED);
break;
case TRUST_PRIVATE:
sid2.flags = 0;
button.ptszTooltip = TranslateT(LANG_STATUS_PRIVATE);
- button.hIcon = GetIconHandle(ICON_PRIVATE);
+ button.hIcon = IcoLib_GetIconHandle(ICON_PRIVATE);
break;
default:
sid.flags = MBF_DISABLED;
button.ptszTooltip = TranslateT(LANG_STATUS_DISABLED);
- button.hIcon = GetIconHandle(ICON_NOT_PRIVATE);
+ button.hIcon = IcoLib_GetIconHandle(ICON_NOT_PRIVATE);
break;
}
button.bbbFlags = 0;
@@ -112,10 +112,10 @@ void InitSRMM()
// add icon to srmm status icons
InitMirOTRMenu();
- hIconNotSecure = LoadIcon(ICON_NOT_PRIVATE, 0);
- hIconFinished = LoadIcon(ICON_FINISHED, 0);
- hIconPrivate = LoadIcon(ICON_PRIVATE, 0);
- hIconUnverified = LoadIcon(ICON_UNVERIFIED, 0);
+ hIconNotSecure = IcoLib_GetIcon(ICON_NOT_PRIVATE, 0);
+ hIconFinished = IcoLib_GetIcon(ICON_FINISHED, 0);
+ hIconPrivate = IcoLib_GetIcon(ICON_PRIVATE, 0);
+ hIconUnverified = IcoLib_GetIcon(ICON_UNVERIFIED, 0);
StatusIconData sid = { sizeof(sid) };
sid.szModule = MODULENAME;
@@ -141,17 +141,17 @@ void InitSRMM()
OTRButton.dwDefPos = 200;
OTRButton.bbbFlags = BBBF_ISRSIDEBUTTON|BBBF_CANBEHIDDEN|BBBF_ISIMBUTTON;
OTRButton.ptszTooltip = TranslateT(LANG_OTR_TOOLTIP);
- OTRButton.hIcon = GetIconHandle(ICON_NOT_PRIVATE);
+ OTRButton.hIcon = IcoLib_GetIconHandle(ICON_NOT_PRIVATE);
HookEvent(ME_MSG_TOOLBARLOADED, SVC_ButtonsBarLoaded);
HookEvent(ME_MSG_BUTTONPRESSED, SVC_ButtonsBarPressed);
}
}
void DeinitSRMM()
{
- ReleaseIcon(ICON_NOT_PRIVATE, 0);
- ReleaseIcon(ICON_FINISHED, 0);
- ReleaseIcon(ICON_PRIVATE, 0);
- ReleaseIcon(ICON_UNVERIFIED, 0);
+ IcoLib_Release(ICON_NOT_PRIVATE, 0);
+ IcoLib_Release(ICON_FINISHED, 0);
+ IcoLib_Release(ICON_PRIVATE, 0);
+ IcoLib_Release(ICON_UNVERIFIED, 0);
hIconNotSecure = hIconFinished = hIconPrivate = hIconUnverified =0;
UninitMirOTRMenu();
diff --git a/plugins/MyDetails/src/frame.cpp b/plugins/MyDetails/src/frame.cpp
index 29284ae3f9..04db33bed2 100644
--- a/plugins/MyDetails/src/frame.cpp
+++ b/plugins/MyDetails/src/frame.cpp
@@ -1181,11 +1181,11 @@ void Draw(HWND hwnd, HDC hdc_orig)
HRGN rgn = CreateRectRgnIndirect(&rc);
SelectClipRgn(hdc, rgn);
- HICON icon = Skin_GetIcon("MYDETAILS_NEXT_PROTOCOL");
+ HICON icon = IcoLib_GetIcon("MYDETAILS_NEXT_PROTOCOL");
if (icon == NULL)
icon = LoadIcon(hInst, MAKEINTRESOURCE(IDI_RIGHT_ARROW));
DrawIconEx(hdc, data->next_proto_rect.left, data->next_proto_rect.top, icon, ICON_SIZE, ICON_SIZE, 0, NULL, DI_NORMAL);
- Skin_ReleaseIcon(icon);
+ IcoLib_ReleaseIcon(icon);
SelectClipRgn(hdc, NULL);
DeleteObject(rgn);
@@ -1194,11 +1194,11 @@ void Draw(HWND hwnd, HDC hdc_orig)
rgn = CreateRectRgnIndirect(&rc);
SelectClipRgn(hdc, rgn);
- icon = Skin_GetIcon("MYDETAILS_PREV_PROTOCOL");
+ icon = IcoLib_GetIcon("MYDETAILS_PREV_PROTOCOL");
if (icon == NULL)
icon = LoadIcon(hInst, MAKEINTRESOURCE(IDI_RIGHT_ARROW));
DrawIconEx(hdc, data->prev_proto_rect.left, data->prev_proto_rect.top, icon, ICON_SIZE, ICON_SIZE, 0, NULL, DI_NORMAL);
- Skin_ReleaseIcon(icon);
+ IcoLib_ReleaseIcon(icon);
SelectClipRgn(hdc, NULL);
DeleteObject(rgn);
@@ -1250,7 +1250,7 @@ void Draw(HWND hwnd, HDC hdc_orig)
if (status_icon != NULL) {
DrawIconEx(hdc, data->status_icon_rect.left, data->status_icon_rect.top, status_icon, ICON_SIZE, ICON_SIZE, 0, NULL, DI_NORMAL);
- Skin_ReleaseIcon(status_icon);
+ IcoLib_ReleaseIcon(status_icon);
}
SelectClipRgn(hdc, NULL);
@@ -1318,11 +1318,11 @@ void Draw(HWND hwnd, HDC hdc_orig)
HRGN rgn = CreateRectRgnIndirect(&rc);
SelectClipRgn(hdc, rgn);
- HICON icon = Skin_GetIcon("LISTENING_TO_ICON");
+ HICON icon = IcoLib_GetIcon("LISTENING_TO_ICON");
if (icon == NULL)
icon = LoadIcon(hInst, MAKEINTRESOURCE(IDI_LISTENINGTO));
DrawIconEx(hdc, data->listening_to_icon_rect.left, data->listening_to_icon_rect.top, icon, ICON_SIZE, ICON_SIZE, 0, NULL, DI_NORMAL);
- Skin_ReleaseIcon(icon);
+ IcoLib_ReleaseIcon(icon);
SelectClipRgn(hdc, NULL);
DeleteObject(rgn);
diff --git a/plugins/MyDetails/src/mydetails.cpp b/plugins/MyDetails/src/mydetails.cpp
index 1bfb2b5c85..b731e71603 100644
--- a/plugins/MyDetails/src/mydetails.cpp
+++ b/plugins/MyDetails/src/mydetails.cpp
@@ -147,7 +147,7 @@ extern "C" __declspec(dllexport) int Load()
// Options
InitOptions();
- if (Skin_GetIcon("LISTENING_TO_ICON") == NULL)
+ if (IcoLib_GetIcon("LISTENING_TO_ICON") == NULL)
Icon_Register(hInst, LPGEN("Contact list"), iconList, 1);
Icon_Register(hInst, LPGEN("My details"), iconList + 1, SIZEOF(iconList) - 1);
diff --git a/plugins/NewAwaySysMod/src/SetAwayMsg.cpp b/plugins/NewAwaySysMod/src/SetAwayMsg.cpp
index 3cf2276d51..78b95e9766 100644
--- a/plugins/NewAwaySysMod/src/SetAwayMsg.cpp
+++ b/plugins/NewAwaySysMod/src/SetAwayMsg.cpp
@@ -435,7 +435,7 @@ HICON g_LoadIconEx(const char* name, bool big)
{
char szSettingName[100];
mir_snprintf(szSettingName, SIZEOF(szSettingName), "%s_%s", "", name);
- return Skin_GetIcon(szSettingName, big);
+ return IcoLib_GetIcon(szSettingName, big);
}
struct {
diff --git a/plugins/NewXstatusNotify/src/main.cpp b/plugins/NewXstatusNotify/src/main.cpp
index 23c302d512..2d22580a03 100644
--- a/plugins/NewXstatusNotify/src/main.cpp
+++ b/plugins/NewXstatusNotify/src/main.cpp
@@ -89,7 +89,7 @@ HANDLE GetIconHandle(char *szIcon)
{
char szSettingName[64];
mir_snprintf(szSettingName, SIZEOF(szSettingName), "%s_%s", MODULE, szIcon);
- return Skin_GetIconHandle(szSettingName);
+ return IcoLib_GetIconHandle(szSettingName);
}
static int __inline CheckStr(char *str, int not_empty, int empty)
diff --git a/plugins/NewXstatusNotify/src/xstatus.cpp b/plugins/NewXstatusNotify/src/xstatus.cpp
index 88bb66a8e7..ef9ff5e47c 100644
--- a/plugins/NewXstatusNotify/src/xstatus.cpp
+++ b/plugins/NewXstatusNotify/src/xstatus.cpp
@@ -174,7 +174,7 @@ void ShowXStatusPopup(XSTATUSCHANGE *xsc)
char szSetting[64];
mir_snprintf(szSetting, "%s/%s/icon", xsc->szProto, (xsc->type == TYPE_JABBER_MOOD) ? "mood" : "activity");
if (!db_get_s(xsc->hContact, "AdvStatus", szSetting, &dbv)) {
- hIcon = Skin_GetIcon(dbv.pszVal);
+ hIcon = IcoLib_GetIcon(dbv.pszVal);
db_free(&dbv);
}
break;
@@ -237,7 +237,7 @@ void BlinkXStatusIcon(XSTATUSCHANGE *xsc)
case TYPE_JABBER_ACTIVITY:
mir_snprintf(szSetting, "%s/%s/icon", xsc->szProto, (xsc->type == TYPE_JABBER_MOOD) ? "mood" : "activity");
if (!db_get_s(xsc->hContact, "AdvStatus", szSetting, &dbv)) {
- hIcon = Skin_GetIcon(dbv.pszVal);
+ hIcon = IcoLib_GetIcon(dbv.pszVal);
db_free(&dbv);
}
break;
diff --git a/plugins/New_GPG/src/icons.cpp b/plugins/New_GPG/src/icons.cpp
index 71493e49f2..c474f0df33 100644
--- a/plugins/New_GPG/src/icons.cpp
+++ b/plugins/New_GPG/src/icons.cpp
@@ -29,16 +29,6 @@ void InitIconLib()
Icon_Register(hInst, szGPGModuleName, iconList, SIZEOF(iconList));
}
-HICON IconLibGetIcon(const char* ident)
-{
- return Skin_GetIcon(ident);
-}
-
-void IconLibReleaseIcon(const char* ident)
-{
- Skin_ReleaseIcon(ident);
-}
-
HANDLE IconLibHookIconsChanged(MIRANDAHOOK hook)
{
return HookEvent(ME_SKIN2_ICONSCHANGED, hook);
@@ -63,14 +53,14 @@ void setSrmmIcon(MCONTACT h)
StatusIconData sid = { sizeof(sid) };
sid.szModule = szGPGModuleName;
- sid.hIcon = IconLibGetIcon("secured");
+ sid.hIcon = IcoLib_GetIcon("secured");
sid.dwId = 1;
sid.flags = enabled ? 0 : MBF_HIDDEN;
Srmm_ModifyIcon(hContact, &sid);
if(hMC != hContact)
Srmm_ModifyIcon(hMC, &sid);
- sid.hIcon = IconLibGetIcon("unsecured");
+ sid.hIcon = IcoLib_GetIcon("unsecured");
sid.dwId = 2;
sid.flags = enabled ? MBF_HIDDEN : 0;
Srmm_ModifyIcon(hContact, &sid);
diff --git a/plugins/New_GPG/src/init.cpp b/plugins/New_GPG/src/init.cpp
index 9c42ba7ae0..e3751ea52a 100644
--- a/plugins/New_GPG/src/init.cpp
+++ b/plugins/New_GPG/src/init.cpp
@@ -124,18 +124,16 @@ static int OnModulesLoaded(WPARAM wParam,LPARAM lParam)
if(!db_get_b(NULL, szGPGModuleName, "FirstRun", 1))
InitCheck();
- HICON IconLibGetIcon(const char* ident);
-
StatusIconData sid = { sizeof(sid) };
sid.szModule = szGPGModuleName;
sid.flags = MBF_HIDDEN;
sid.dwId = 0x00000001;
- sid.hIcon = IconLibGetIcon("secured");
+ sid.hIcon = IcoLib_GetIcon("secured");
sid.szTooltip = LPGEN("GPG Turn off encryption");
Srmm_AddIcon(&sid);
sid.dwId = 0x00000002;
- sid.hIcon = IconLibGetIcon("unsecured");
+ sid.hIcon = IcoLib_GetIcon("unsecured");
sid.szTooltip = LPGEN("GPG Turn on encryption");
Srmm_AddIcon(&sid);
diff --git a/plugins/NewsAggregator/Src/Icons.cpp b/plugins/NewsAggregator/Src/Icons.cpp
index 93c2ad1f5d..9b100c8b06 100644
--- a/plugins/NewsAggregator/Src/Icons.cpp
+++ b/plugins/NewsAggregator/Src/Icons.cpp
@@ -40,7 +40,7 @@ HICON LoadIconEx(const char *name, bool big)
{
char szSettingName[100];
mir_snprintf(szSettingName, SIZEOF(szSettingName), "%s_%s", MODULE, name);
- return Skin_GetIcon(szSettingName, big);
+ return IcoLib_GetIcon(szSettingName, big);
}
HANDLE GetIconHandle(const char *name)
diff --git a/plugins/NoHistory/src/icons.cpp b/plugins/NoHistory/src/icons.cpp
index 0a523c235d..15553d20b3 100644
--- a/plugins/NoHistory/src/icons.cpp
+++ b/plugins/NoHistory/src/icons.cpp
@@ -11,9 +11,9 @@ static IconItem iconList[] =
int ReloadIcons(WPARAM wParam, LPARAM lParam)
{
- hIconRemove = Skin_GetIconByHandle(iconList[0].hIcolib);
- hIconKeep = Skin_GetIconByHandle(iconList[1].hIcolib);
- hIconClear = Skin_GetIconByHandle(iconList[2].hIcolib);
+ hIconRemove = IcoLib_GetIconByHandle(iconList[0].hIcolib);
+ hIconKeep = IcoLib_GetIconByHandle(iconList[1].hIcolib);
+ hIconClear = IcoLib_GetIconByHandle(iconList[2].hIcolib);
return 0;
}
diff --git a/plugins/Non-IM Contact/src/services.cpp b/plugins/Non-IM Contact/src/services.cpp
index 7ef9b0c760..68b5be26fb 100644
--- a/plugins/Non-IM Contact/src/services.cpp
+++ b/plugins/Non-IM Contact/src/services.cpp
@@ -47,12 +47,12 @@ INT_PTR LoadLCIcon(WPARAM wParam, LPARAM lParam)
if (wParam & PLIF_ICOLIBHANDLE)
return (INT_PTR)icoList[0].hIcolib;
- HICON hIcon = Skin_GetIconByHandle(icoList[0].hIcolib, (wParam & PLIF_SMALL) == 0);
+ HICON hIcon = IcoLib_GetIconByHandle(icoList[0].hIcolib, (wParam & PLIF_SMALL) == 0);
if (wParam & PLIF_ICOLIB)
return (INT_PTR)hIcon;
HICON hIcon2 = CopyIcon(hIcon);
- Skin_ReleaseIcon(hIcon);
+ IcoLib_ReleaseIcon(hIcon);
return (INT_PTR)hIcon2;
}
diff --git a/plugins/NotesAndReminders/src/main.cpp b/plugins/NotesAndReminders/src/main.cpp
index 7799f7a0c4..a19ad4f3da 100644
--- a/plugins/NotesAndReminders/src/main.cpp
+++ b/plugins/NotesAndReminders/src/main.cpp
@@ -279,7 +279,7 @@ extern "C" __declspec(dllexport) int Unload(void)
UnhookEvent(hkOptInit);
- Skin_ReleaseIcon(g_hReminderIcon);
+ IcoLib_ReleaseIcon(g_hReminderIcon);
DeleteObject(hBodyFont);
DeleteObject(hCaptionFont);
diff --git a/plugins/NotesAndReminders/src/notes.cpp b/plugins/NotesAndReminders/src/notes.cpp
index c01e247659..5b9500ced6 100644
--- a/plugins/NotesAndReminders/src/notes.cpp
+++ b/plugins/NotesAndReminders/src/notes.cpp
@@ -1296,19 +1296,19 @@ INT_PTR CALLBACK StickyNoteWndProc(HWND hdlg,UINT message,WPARAM wParam,LPARAM l
if (g_ShowNoteButtons) {
HICON hcIcon;
if (SN->OnTop)
- hcIcon = Skin_GetIconByHandle(iconList[4].hIcolib);
+ hcIcon = IcoLib_GetIconByHandle(iconList[4].hIcolib);
else
- hcIcon = Skin_GetIconByHandle(iconList[7].hIcolib);
+ hcIcon = IcoLib_GetIconByHandle(iconList[7].hIcolib);
DrawIcon(hdc, wr.right - wr.left - 16, 0 + 3, hcIcon);
- Skin_ReleaseIcon(hcIcon);
+ IcoLib_ReleaseIcon(hcIcon);
- hcIcon = Skin_GetIconByHandle(iconList[9].hIcolib);
+ hcIcon = IcoLib_GetIconByHandle(iconList[9].hIcolib);
DrawIcon(hdc, wr.right - wr.left - 32, 1 + 3, hcIcon);
- Skin_ReleaseIcon(hcIcon);
+ IcoLib_ReleaseIcon(hcIcon);
- hcIcon = Skin_GetIconByHandle(iconList[8].hIcolib);
+ hcIcon = IcoLib_GetIconByHandle(iconList[8].hIcolib);
DrawIcon(hdc, wr.right - wr.left - 48, 1 + 3, hcIcon);
- Skin_ReleaseIcon(hcIcon);
+ IcoLib_ReleaseIcon(hcIcon);
}
if (wParam && wParam != 1)
@@ -1926,9 +1926,9 @@ INT_PTR CALLBACK DlgProcViewNotes(HWND Dialog,UINT Message,WPARAM wParam,LPARAM
{
HWND H;
- HICON hIcon = Skin_GetIconByHandle(iconList[13].hIcolib, ICON_SMALL);
+ HICON hIcon = IcoLib_GetIconByHandle(iconList[13].hIcolib, ICON_SMALL);
SendMessage(Dialog, WM_SETICON, (WPARAM)ICON_SMALL, (LPARAM)hIcon);
- hIcon = Skin_GetIconByHandle(iconList[13].hIcolib, ICON_BIG);
+ hIcon = IcoLib_GetIconByHandle(iconList[13].hIcolib, ICON_BIG);
SendMessage(Dialog, WM_SETICON, (WPARAM)ICON_BIG, (LPARAM)hIcon);
SetWindowText(Dialog, LPGENT("Notes"));
@@ -1987,8 +1987,8 @@ INT_PTR CALLBACK DlgProcViewNotes(HWND Dialog,UINT Message,WPARAM wParam,LPARAM
case WM_DESTROY:
ListNotesVisible = FALSE;
- Skin_ReleaseIcon((HICON)SendMessage(Dialog, WM_SETICON, ICON_BIG, 0));
- Skin_ReleaseIcon((HICON)SendMessage(Dialog, WM_SETICON, ICON_SMALL, 0));
+ IcoLib_ReleaseIcon((HICON)SendMessage(Dialog, WM_SETICON, ICON_BIG, 0));
+ IcoLib_ReleaseIcon((HICON)SendMessage(Dialog, WM_SETICON, ICON_SMALL, 0));
return TRUE;
case WM_NOTIFY:
diff --git a/plugins/NotesAndReminders/src/options.cpp b/plugins/NotesAndReminders/src/options.cpp
index f80376d434..71c6e76902 100644
--- a/plugins/NotesAndReminders/src/options.cpp
+++ b/plugins/NotesAndReminders/src/options.cpp
@@ -582,7 +582,7 @@ void InitSettings(void)
InitFonts();
- g_hReminderIcon = Skin_GetIconByHandle(iconList[10].hIcolib);
+ g_hReminderIcon = IcoLib_GetIconByHandle(iconList[10].hIcolib);
if (g_Transparency < MIN_ALPHA)
g_Transparency = MIN_ALPHA;
diff --git a/plugins/NotesAndReminders/src/reminders.cpp b/plugins/NotesAndReminders/src/reminders.cpp
index 7f743492cd..28ca688fe7 100644
--- a/plugins/NotesAndReminders/src/reminders.cpp
+++ b/plugins/NotesAndReminders/src/reminders.cpp
@@ -2024,7 +2024,7 @@ INT_PTR CALLBACK DlgProcNewReminder(HWND Dialog,UINT Message,WPARAM wParam,LPARA
}
}
- hIcon = Skin_GetIconByHandle(iconList[12].hIcolib);
+ hIcon = IcoLib_GetIconByHandle(iconList[12].hIcolib);
SendDlgItemMessage(Dialog,IDC_BTN_PLAYSOUND,BM_SETIMAGE,(WPARAM)IMAGE_ICON,(LPARAM)hIcon);
if (NewReminderVisible == 2 && pEditReminder->SoundSel)
@@ -2214,7 +2214,7 @@ INT_PTR CALLBACK DlgProcNewReminder(HWND Dialog,UINT Message,WPARAM wParam,LPARA
}
case WM_DESTROY:
{
- Skin_ReleaseIcon(hIcon);
+ IcoLib_ReleaseIcon(hIcon);
break;
}
}
@@ -2412,9 +2412,9 @@ INT_PTR CALLBACK DlgProcViewReminders(HWND Dialog,UINT Message,WPARAM wParam,LPA
break;
case WM_INITDIALOG:
{
- HICON hIcon = Skin_GetIconByHandle(iconList[6].hIcolib, ICON_SMALL);
+ HICON hIcon = IcoLib_GetIconByHandle(iconList[6].hIcolib, ICON_SMALL);
SendMessage(Dialog, WM_SETICON, (WPARAM)ICON_SMALL, (LPARAM)hIcon);
- hIcon = Skin_GetIconByHandle(iconList[6].hIcolib, ICON_BIG);
+ hIcon = IcoLib_GetIconByHandle(iconList[6].hIcolib, ICON_BIG);
SendMessage(Dialog, WM_SETICON, (WPARAM)ICON_BIG, (LPARAM)hIcon);
TranslateDialogDefault(Dialog);
@@ -2556,8 +2556,8 @@ INT_PTR CALLBACK DlgProcViewReminders(HWND Dialog,UINT Message,WPARAM wParam,LPA
}
}
case WM_DESTROY:
- Skin_ReleaseIcon((HICON)SendMessage(Dialog, WM_SETICON, ICON_BIG, 0));
- Skin_ReleaseIcon((HICON)SendMessage(Dialog, WM_SETICON, ICON_SMALL, 0));
+ IcoLib_ReleaseIcon((HICON)SendMessage(Dialog, WM_SETICON, ICON_BIG, 0));
+ IcoLib_ReleaseIcon((HICON)SendMessage(Dialog, WM_SETICON, ICON_SMALL, 0));
break;
}
return FALSE;
diff --git a/plugins/Nudge/src/main.cpp b/plugins/Nudge/src/main.cpp
index 4c554c263c..88c1756f74 100644
--- a/plugins/Nudge/src/main.cpp
+++ b/plugins/Nudge/src/main.cpp
@@ -394,7 +394,7 @@ void LoadPopupClass()
ppc.flags = PCF_TCHAR;
ppc.pszName = "Nudge";
ppc.ptszDescription = LPGENT("Show Nudge");
- ppc.hIcon = Skin_GetIconByHandle(iconList[0].hIcolib);
+ ppc.hIcon = IcoLib_GetIconByHandle(iconList[0].hIcolib);
ppc.colorBack = NULL;
ppc.colorText = NULL;
ppc.iSeconds = 0;
@@ -459,7 +459,7 @@ void Nudge_ShowPopup(CNudgeElement *n, MCONTACT hContact, TCHAR * Message)
else if (ServiceExists(MS_POPUP_ADDPOPUPT)) {
POPUPDATAT NudgePopup = { 0 };
NudgePopup.lchContact = hContact;
- NudgePopup.lchIcon = Skin_GetIconByHandle(iconList[0].hIcolib);
+ NudgePopup.lchIcon = IcoLib_GetIconByHandle(iconList[0].hIcolib);
NudgePopup.colorBack = 0;
NudgePopup.colorText = 0;
NudgePopup.iSeconds = 0;
diff --git a/plugins/Nudge/src/options.cpp b/plugins/Nudge/src/options.cpp
index b4e1a0d61b..fb5f98a8ad 100644
--- a/plugins/Nudge/src/options.cpp
+++ b/plugins/Nudge/src/options.cpp
@@ -214,7 +214,7 @@ static void CreateImageList(HWND hWnd)
CNudgeElement &p = arNudges[i];
INT_PTR res = CallProtoService(p.ProtocolName, PS_LOADICON, PLI_PROTOCOL | PLIF_SMALL | PLIF_ICOLIB, 0);
if (res == CALLSERVICE_NOTFOUND)
- res = (INT_PTR)Skin_GetIcon("Nudge_Default");
+ res = (INT_PTR)IcoLib_GetIcon("Nudge_Default");
HICON hIcon = (HICON)res;
ImageList_AddIcon(hImList, hIcon);
diff --git a/plugins/OpenFolder/src/openFolder.cpp b/plugins/OpenFolder/src/openFolder.cpp
index 17437bf80a..b224ca5393 100644
--- a/plugins/OpenFolder/src/openFolder.cpp
+++ b/plugins/OpenFolder/src/openFolder.cpp
@@ -65,7 +65,7 @@ HICON LoadIconExEx(const char* IcoLibName, int NonIcoLibIcon)
{
char szSettingName[64];
mir_snprintf(szSettingName, SIZEOF(szSettingName), "%s_%s", OPENFOLDER_MODULE_NAME, IcoLibName);
- return Skin_GetIcon(szSettingName);
+ return IcoLib_GetIcon(szSettingName);
}
extern "C" __declspec(dllexport) PLUGININFOEX* MirandaPluginInfoEx(DWORD mirandaVersion)
diff --git a/plugins/PackUpdater/Src/Notifications.cpp b/plugins/PackUpdater/Src/Notifications.cpp
index aff49ef640..aae2928a79 100644
--- a/plugins/PackUpdater/Src/Notifications.cpp
+++ b/plugins/PackUpdater/Src/Notifications.cpp
@@ -95,11 +95,11 @@ static VOID MakePopupAction(POPUPACTION &pa, INT id)
pa.lParam = 0;
switch (id) {
case IDYES:
- pa.lchIcon = Skin_GetIcon("btn_ok");
+ pa.lchIcon = IcoLib_GetIcon("btn_ok");
strncpy_s(pa.lpzTitle, MODNAME"/Yes", SIZEOF(pa.lpzTitle));
break;
case IDNO:
- pa.lchIcon = Skin_GetIcon("btn_cancel");
+ pa.lchIcon = IcoLib_GetIcon("btn_cancel");
strncpy_s(pa.lpzTitle, MODNAME"/No", SIZEOF(pa.lpzTitle));
break;
}
diff --git a/plugins/PackUpdater/Src/PackUpdater.cpp b/plugins/PackUpdater/Src/PackUpdater.cpp
index e277a80ca4..c7987a96e0 100644
--- a/plugins/PackUpdater/Src/PackUpdater.cpp
+++ b/plugins/PackUpdater/Src/PackUpdater.cpp
@@ -73,7 +73,7 @@ extern "C" __declspec(dllexport) int Load(void)
CLISTMENUITEM mi = { sizeof(mi) };
mi.position = -0x7FFFFFFF;
mi.flags = CMIF_TCHAR;
- mi.hIcon = Skin_GetIcon("check_update");
+ mi.hIcon = IcoLib_GetIcon("check_update");
mi.ptszName = LPGENT("Check for pack updates");
mi.pszService = MODNAME"/CheckUpdates";
Menu_AddMainMenuItem(&mi);
@@ -83,7 +83,7 @@ extern "C" __declspec(dllexport) int Load(void)
mi.cbSize = sizeof(mi);
mi.position = -0x7FFFFFFF;
mi.flags = CMIF_TCHAR;
- mi.hIcon = Skin_GetIcon("empty_folder");
+ mi.hIcon = IcoLib_GetIcon("empty_folder");
mi.ptszName = LPGENT("Clear pack updates folder");
mi.pszService = MODNAME"/EmptyFolder";
Menu_AddMainMenuItem(&mi);
diff --git a/plugins/Ping/src/utils.cpp b/plugins/Ping/src/utils.cpp
index f61f0f9399..aca8eab105 100644
--- a/plugins/Ping/src/utils.cpp
+++ b/plugins/Ping/src/utils.cpp
@@ -293,10 +293,10 @@ static int OnShutdown(WPARAM, LPARAM)
int ReloadIcons(WPARAM, LPARAM)
{
- hIconResponding = Skin_GetIcon("ping_responding");
- hIconNotResponding = Skin_GetIcon("ping_not_responding");
- hIconTesting = Skin_GetIcon("ping_testing");
- hIconDisabled = Skin_GetIcon("ping_disabled");
+ hIconResponding = IcoLib_GetIcon("ping_responding");
+ hIconNotResponding = IcoLib_GetIcon("ping_not_responding");
+ hIconTesting = IcoLib_GetIcon("ping_testing");
+ hIconDisabled = IcoLib_GetIcon("ping_disabled");
RefreshWindow(0, 0);
return 0;
@@ -304,10 +304,10 @@ int ReloadIcons(WPARAM, LPARAM)
void InitUtils()
{
- hIconResponding = Skin_GetIcon("ping_responding");
- hIconNotResponding = Skin_GetIcon("ping_not_responding");
- hIconTesting = Skin_GetIcon("ping_testing");
- hIconDisabled = Skin_GetIcon("ping_disabled");
+ hIconResponding = IcoLib_GetIcon("ping_responding");
+ hIconNotResponding = IcoLib_GetIcon("ping_not_responding");
+ hIconTesting = IcoLib_GetIcon("ping_testing");
+ hIconDisabled = IcoLib_GetIcon("ping_disabled");
POPUPCLASS test = { sizeof(test) };
test.flags = PCF_TCHAR;
diff --git a/plugins/PluginUpdater/src/DlgListNew.cpp b/plugins/PluginUpdater/src/DlgListNew.cpp
index 406f3bb282..6b0de1787e 100644
--- a/plugins/PluginUpdater/src/DlgListNew.cpp
+++ b/plugins/PluginUpdater/src/DlgListNew.cpp
@@ -137,9 +137,9 @@ static int ListDlg_Resize(HWND, LPARAM, UTILRESIZECONTROL *urc)
int ImageList_AddIconFromIconLib(HIMAGELIST hIml, int i)
{
- HICON icon = Skin_GetIconByHandle(iconList[i].hIcolib);
+ HICON icon = IcoLib_GetIconByHandle(iconList[i].hIcolib);
int res = ImageList_AddIcon(hIml, icon);
- Skin_ReleaseIcon(icon);
+ IcoLib_ReleaseIcon(icon);
return res;
}
@@ -152,8 +152,8 @@ INT_PTR CALLBACK DlgList(HWND hDlg, UINT message, WPARAM wParam, LPARAM lParam)
TranslateDialogDefault( hDlg );
oldWndProc = (WNDPROC)SetWindowLongPtr(hwndList, GWLP_WNDPROC, (LONG_PTR)PluginListWndProc);
- SendMessage(hDlg, WM_SETICON, ICON_BIG, (LPARAM)Skin_GetIconByHandle(iconList[2].hIcolib, 1));
- SendMessage(hDlg, WM_SETICON, ICON_SMALL, (LPARAM)Skin_GetIconByHandle(iconList[2].hIcolib));
+ SendMessage(hDlg, WM_SETICON, ICON_BIG, (LPARAM)IcoLib_GetIconByHandle(iconList[2].hIcolib, 1));
+ SendMessage(hDlg, WM_SETICON, ICON_SMALL, (LPARAM)IcoLib_GetIconByHandle(iconList[2].hIcolib));
{
HIMAGELIST hIml = ImageList_Create(16, 16, ILC_MASK | ILC_COLOR32, 4, 0);
ImageList_AddIconFromIconLib(hIml, 1);
@@ -324,8 +324,8 @@ INT_PTR CALLBACK DlgList(HWND hDlg, UINT message, WPARAM wParam, LPARAM lParam)
case WM_DESTROY:
Utils_SaveWindowPosition(hDlg, NULL, MODNAME, "ListWindow");
- Skin_ReleaseIcon((HICON)SendMessage(hDlg, WM_SETICON, ICON_BIG, 0));
- Skin_ReleaseIcon((HICON)SendMessage(hDlg, WM_SETICON, ICON_SMALL, 0));
+ IcoLib_ReleaseIcon((HICON)SendMessage(hDlg, WM_SETICON, ICON_BIG, 0));
+ IcoLib_ReleaseIcon((HICON)SendMessage(hDlg, WM_SETICON, ICON_SMALL, 0));
hwndDialog = NULL;
delete (OBJLIST<FILEINFO> *)GetWindowLongPtr(hDlg, GWLP_USERDATA);
SetWindowLongPtr(hDlg, GWLP_USERDATA, 0);
diff --git a/plugins/PluginUpdater/src/DlgUpdate.cpp b/plugins/PluginUpdater/src/DlgUpdate.cpp
index 3aa968bbce..87fe5e7498 100644
--- a/plugins/PluginUpdater/src/DlgUpdate.cpp
+++ b/plugins/PluginUpdater/src/DlgUpdate.cpp
@@ -161,11 +161,11 @@ static INT_PTR CALLBACK DlgUpdate(HWND hDlg, UINT message, WPARAM wParam, LPARAM
TranslateDialogDefault(hDlg);
SendMessage(hwndList, LVM_SETEXTENDEDLISTVIEWSTYLE, 0, LVS_EX_FULLROWSELECT | LVS_EX_CHECKBOXES);
#if MIRANDA_VER >= 0x0A00
- SendMessage(hDlg, WM_SETICON, ICON_SMALL, (LPARAM)Skin_GetIconByHandle(iconList[0].hIcolib));
- SendMessage(hDlg, WM_SETICON, ICON_BIG, (LPARAM)Skin_GetIconByHandle(iconList[0].hIcolib, 1));
+ SendMessage(hDlg, WM_SETICON, ICON_SMALL, (LPARAM)IcoLib_GetIconByHandle(iconList[0].hIcolib));
+ SendMessage(hDlg, WM_SETICON, ICON_BIG, (LPARAM)IcoLib_GetIconByHandle(iconList[0].hIcolib, 1));
#else
- SendMessage(hDlg, WM_SETICON, ICON_SMALL, (LPARAM)Skin_GetIcon("check_update"));
- SendMessage(hDlg, WM_SETICON, ICON_SMALL, (LPARAM)Skin_GetIcon("check_update",1));
+ SendMessage(hDlg, WM_SETICON, ICON_SMALL, (LPARAM)IcoLib_GetIcon("check_update"));
+ SendMessage(hDlg, WM_SETICON, ICON_SMALL, (LPARAM)IcoLib_GetIcon("check_update",1));
#endif
{
OSVERSIONINFO osver = { sizeof(osver) };
@@ -341,7 +341,7 @@ static INT_PTR CALLBACK DlgUpdate(HWND hDlg, UINT message, WPARAM wParam, LPARAM
break;
case WM_DESTROY:
- Skin_ReleaseIcon((HICON)SendMessage(hDlg, WM_SETICON, ICON_SMALL, 0));
+ IcoLib_ReleaseIcon((HICON)SendMessage(hDlg, WM_SETICON, ICON_SMALL, 0));
Utils_SaveWindowPosition(hDlg, NULL, MODNAME, "ConfirmWindow");
hwndDialog = NULL;
delete (OBJLIST<FILEINFO> *)GetWindowLongPtr(hDlg, GWLP_USERDATA);
diff --git a/plugins/PluginUpdater/src/Notifications.cpp b/plugins/PluginUpdater/src/Notifications.cpp
index b7ac68c75c..4cfec11d5f 100644
--- a/plugins/PluginUpdater/src/Notifications.cpp
+++ b/plugins/PluginUpdater/src/Notifications.cpp
@@ -102,9 +102,9 @@ void ShowPopup(LPCTSTR ptszTitle, LPCTSTR ptszText, int Number)
POPUPDATAT pd = { 0 };
pd.lchContact = NULL;
#if MIRANDA_VER >= 0x0A00
- pd.lchIcon = Skin_GetIconByHandle(iconList[0].hIcolib);
+ pd.lchIcon = IcoLib_GetIconByHandle(iconList[0].hIcolib);
#else
- pd.lchIcon = Skin_GetIcon("check_update");
+ pd.lchIcon = IcoLib_GetIcon("check_update");
#endif
if (Number == POPUP_TYPE_MSG) {
pd.PluginWindowProc = PopupDlgProcRestart;
diff --git a/plugins/PluginUpdater/src/PluginUpdater.cpp b/plugins/PluginUpdater/src/PluginUpdater.cpp
index 86e476bd05..ca93a3442c 100644
--- a/plugins/PluginUpdater/src/PluginUpdater.cpp
+++ b/plugins/PluginUpdater/src/PluginUpdater.cpp
@@ -89,7 +89,7 @@ extern "C" __declspec(dllexport) int Load(void)
#if MIRANDA_VER >= 0x0A00
mi.icolibItem = iconList[0].hIcolib;
#else
- mi.icolibItem = Skin_GetIconHandle("check_update");
+ mi.icolibItem = IcoLib_GetIconHandle("check_update");
#endif
mi.pszName = LPGEN("Check for updates");
mi.pszService = MS_PU_CHECKUPDATES;
diff --git a/plugins/Popup/src/actions.cpp b/plugins/Popup/src/actions.cpp
index 9e33df9586..291d2f10f8 100644
--- a/plugins/Popup/src/actions.cpp
+++ b/plugins/Popup/src/actions.cpp
@@ -35,19 +35,19 @@ void LoadActions()
{
POPUPACTION actions[] =
{
- { sizeof(POPUPACTION), Skin_GetIcon(ICO_ACT_REPLY, 0), LPGEN("General")"/"LPGEN("Quick reply"), 0 },
- { sizeof(POPUPACTION), Skin_GetIcon(ICO_ACT_MESS, 0), LPGEN("General")"/"LPGEN("Send message"), 0 },
- { sizeof(POPUPACTION), Skin_GetIcon(ICO_ACT_INFO, 0), LPGEN("General")"/"LPGEN("User details"), 0 },
- { sizeof(POPUPACTION), Skin_GetIcon(ICO_ACT_MENU, 0), LPGEN("General")"/"LPGEN("Contact menu"), 0 },
- { sizeof(POPUPACTION), Skin_GetIcon(ICO_ACT_ADD, 0), LPGEN("General")"/"LPGEN("Add permanently"), 0 },
- { sizeof(POPUPACTION), Skin_GetIcon(ICO_ACT_PIN, 0), LPGEN("General")"/"LPGEN("Pin popup"), 0 },
- { sizeof(POPUPACTION), Skin_GetIcon(ICO_ACT_CLOSE, 0), LPGEN("General")"/"LPGEN("Dismiss popup"), 0 },
- { sizeof(POPUPACTION), Skin_GetIcon(ICO_ACT_COPY, 0), LPGEN("General")"/"LPGEN("Copy to clipboard"), 0 },
+ { sizeof(POPUPACTION), IcoLib_GetIcon(ICO_ACT_REPLY, 0), LPGEN("General")"/"LPGEN("Quick reply"), 0 },
+ { sizeof(POPUPACTION), IcoLib_GetIcon(ICO_ACT_MESS, 0), LPGEN("General")"/"LPGEN("Send message"), 0 },
+ { sizeof(POPUPACTION), IcoLib_GetIcon(ICO_ACT_INFO, 0), LPGEN("General")"/"LPGEN("User details"), 0 },
+ { sizeof(POPUPACTION), IcoLib_GetIcon(ICO_ACT_MENU, 0), LPGEN("General")"/"LPGEN("Contact menu"), 0 },
+ { sizeof(POPUPACTION), IcoLib_GetIcon(ICO_ACT_ADD, 0), LPGEN("General")"/"LPGEN("Add permanently"), 0 },
+ { sizeof(POPUPACTION), IcoLib_GetIcon(ICO_ACT_PIN, 0), LPGEN("General")"/"LPGEN("Pin popup"), 0 },
+ { sizeof(POPUPACTION), IcoLib_GetIcon(ICO_ACT_CLOSE, 0), LPGEN("General")"/"LPGEN("Dismiss popup"), 0 },
+ { sizeof(POPUPACTION), IcoLib_GetIcon(ICO_ACT_COPY, 0), LPGEN("General")"/"LPGEN("Copy to clipboard"), 0 },
// remove popup action
#if defined(_DEBUG)
- { sizeof(POPUPACTION), Skin_GetIcon(ICO_POPUP_ON, 0), "Popup Plus/Test action", PAF_ENABLED },
- { sizeof(POPUPACTION), Skin_GetIcon(ICO_ACT_CLOSE, 0), "Popup Plus/Second test action", 0 },
+ { sizeof(POPUPACTION), IcoLib_GetIcon(ICO_POPUP_ON, 0), "Popup Plus/Test action", PAF_ENABLED },
+ { sizeof(POPUPACTION), IcoLib_GetIcon(ICO_ACT_CLOSE, 0), "Popup Plus/Second test action", 0 },
{ sizeof(POPUPACTION), LoadSkinnedIcon(SKINICON_OTHER_MIRANDA), "Popup Plus/One more action", PAF_ENABLED },
#endif
};
@@ -189,7 +189,7 @@ INT_PTR CALLBACK DlgProcPopupActions(HWND hwnd, UINT msg, WPARAM wParam, LPARAM
TranslateDialogDefault(hwnd);
- SendDlgItemMessage(hwnd, IDC_ICO_INFO, STM_SETICON, (WPARAM)Skin_GetIcon(ICO_MISC_NOTIFY, 0), 0);
+ SendDlgItemMessage(hwnd, IDC_ICO_INFO, STM_SETICON, (WPARAM)IcoLib_GetIcon(ICO_MISC_NOTIFY, 0), 0);
CheckDlgButton(hwnd, IDC_CHK_ENABLEACTIONS, PopupOptions.actions & ACT_ENABLE ? BST_CHECKED : BST_UNCHECKED);
CheckDlgButton(hwnd, IDC_CHK_IMCONTACTSONLY, PopupOptions.actions & ACT_DEF_IMONLY ? BST_CHECKED : BST_UNCHECKED);
diff --git a/plugins/Popup/src/history.cpp b/plugins/Popup/src/history.cpp
index 2f01e420a6..b2c2d0473b 100644
--- a/plugins/Popup/src/history.cpp
+++ b/plugins/Popup/src/history.cpp
@@ -129,8 +129,8 @@ static INT_PTR CALLBACK HistoryDlgProc(HWND hwnd, UINT msg, WPARAM, LPARAM lPara
HWND hwndList = GetDlgItem(hwnd, IDC_POPUP_LIST);
for (int i = 0; i < arPopupHistory.getCount(); ++i)
ListBox_SetItemData(hwndList, ListBox_AddString(hwndList, _T("")), 0);
- SendMessage(hwnd, WM_SETICON, ICON_SMALL, (LPARAM)Skin_GetIcon(ICO_HISTORY, 0));
- SendMessage(hwnd, WM_SETICON, ICON_BIG, (LPARAM)Skin_GetIcon(ICO_HISTORY, 1));
+ SendMessage(hwnd, WM_SETICON, ICON_SMALL, (LPARAM)IcoLib_GetIcon(ICO_HISTORY, 0));
+ SendMessage(hwnd, WM_SETICON, ICON_BIG, (LPARAM)IcoLib_GetIcon(ICO_HISTORY, 1));
if (gbHppInstalled && PopupOptions.UseHppHistoryLog) {
logType = LOG_HPP;
diff --git a/plugins/Popup/src/main.cpp b/plugins/Popup/src/main.cpp
index 56c2277fd9..56f302c5cd 100644
--- a/plugins/Popup/src/main.cpp
+++ b/plugins/Popup/src/main.cpp
@@ -113,17 +113,17 @@ static int IconsChanged(WPARAM, LPARAM)
CLISTMENUITEM mi = { sizeof(mi) };
if (PopupOptions.ModuleIsEnabled == TRUE) { // The module is enabled.
// The action to do is "disable popups" (show disabled) and we must write "enable popup" in the new item.
- mi.hIcon = Skin_GetIcon(ICO_POPUP_ON, 0);
+ mi.hIcon = IcoLib_GetIcon(ICO_POPUP_ON, 0);
}
else { // The module is disabled.
// The action to do is enable popups (show enabled), then write "disable popup" in the new item.
- mi.hIcon = Skin_GetIcon(ICO_POPUP_OFF, 0);
+ mi.hIcon = IcoLib_GetIcon(ICO_POPUP_OFF, 0);
}
mi.flags = CMIM_ICON;
Menu_ModifyItem(hMenuItem, &mi);
Menu_ModifyItem(hMenuRoot, &mi);
- mi.hIcon = Skin_GetIcon(ICO_HISTORY, 0);
+ mi.hIcon = IcoLib_GetIcon(ICO_HISTORY, 0);
mi.flags = CMIM_ICON;
Menu_ModifyItem(hMenuItemHistory, &mi);
return 0;
@@ -138,8 +138,8 @@ static int TTBLoaded(WPARAM, LPARAM)
if (PopupOptions.ModuleIsEnabled)
ttb.dwFlags |= TTBBF_PUSHED;
ttb.name = LPGEN("Toggle Popups");
- ttb.hIconHandleUp = Skin_GetIconHandle(ICO_TB_POPUP_OFF);
- ttb.hIconHandleDn = Skin_GetIconHandle(ICO_TB_POPUP_ON);
+ ttb.hIconHandleUp = IcoLib_GetIconHandle(ICO_TB_POPUP_OFF);
+ ttb.hIconHandleDn = IcoLib_GetIconHandle(ICO_TB_POPUP_ON);
ttb.pszTooltipUp = LPGEN("Enable Popups");
ttb.pszTooltipDn = LPGEN("Disable Popups");
hTTButton = TopToolbar_AddButton(&ttb);
@@ -156,7 +156,7 @@ INT_PTR svcEnableDisableMenuCommand(WPARAM, LPARAM)
PopupOptions.ModuleIsEnabled = FALSE;
db_set_b(NULL, "Popup", "ModuleIsEnabled", FALSE);
mi.ptszName = LPGENT("Enable Popups");
- mi.hIcon = Skin_GetIcon(ICO_POPUP_OFF, 0);
+ mi.hIcon = IcoLib_GetIcon(ICO_POPUP_OFF, 0);
}
else {
// The module is disabled.
@@ -164,7 +164,7 @@ INT_PTR svcEnableDisableMenuCommand(WPARAM, LPARAM)
PopupOptions.ModuleIsEnabled = TRUE;
db_set_b(NULL, "Popup", "ModuleIsEnabled", TRUE);
mi.ptszName = LPGENT("Disable Popups");
- mi.hIcon = Skin_GetIcon(ICO_POPUP_ON, 0);
+ mi.hIcon = IcoLib_GetIcon(ICO_POPUP_ON, 0);
}
mi.flags = CMIM_NAME | CMIM_ICON | CMIF_TCHAR;
Menu_ModifyItem(hMenuItem, &mi);
@@ -193,7 +193,7 @@ void InitMenuItems(void)
// Build main menu
mi.position = -1000000000 /*1000001*/;
mi.ptszName = LPGENT(MODULNAME_PLU);
- mi.hIcon = Skin_GetIcon(PopupOptions.ModuleIsEnabled ? ICO_POPUP_ON : ICO_POPUP_OFF, 0);
+ mi.hIcon = IcoLib_GetIcon(PopupOptions.ModuleIsEnabled ? ICO_POPUP_ON : ICO_POPUP_OFF, 0);
hMenuRoot = Menu_AddMainMenuItem(&mi);
// Add item to main menu
@@ -209,7 +209,7 @@ void InitMenuItems(void)
mi.position = 1000000000;
mi.popupPosition = 1999990000;
mi.ptszName = LPGENT("Popup History");
- mi.hIcon = Skin_GetIcon(ICO_HISTORY, 0);
+ mi.hIcon = IcoLib_GetIcon(ICO_HISTORY, 0);
mi.pszService = MENUCOMMAND_HISTORY;
hMenuItemHistory = Menu_AddMainMenuItem(&mi);
}
diff --git a/plugins/Popup/src/notifications.cpp b/plugins/Popup/src/notifications.cpp
index 413959315a..6f355f68a5 100644
--- a/plugins/Popup/src/notifications.cpp
+++ b/plugins/Popup/src/notifications.cpp
@@ -217,7 +217,7 @@ HANDLE RegisterNotification(POPUPNOTIFICATION *notification)
sid.pszName = setting;
sid.description.a = notification->lpzName;
sid.hDefaultIcon = notification->lchIcon;
- Skin_AddIcon(&sid);
+ IcoLib_AddIcon(&sid);
gTreeData.insert(ptd);
return (HANDLE)ptd;
@@ -260,7 +260,7 @@ void FillNotificationData(POPUPDATA2 *ppd, DWORD *disableWhen)
char setting[MAXMODULELABELLENGTH];
mir_snprintf(setting, MODULNAME"_%s_%s", ptd->notification.lpzGroup, ptd->notification.lpzName);
- ppd->lchIcon = Skin_GetIcon(setting);
+ ppd->lchIcon = IcoLib_GetIcon(setting);
}
bool IsValidNotification(HANDLE hNotification)
diff --git a/plugins/Popup/src/opt_adv.cpp b/plugins/Popup/src/opt_adv.cpp
index ee594e7494..1183fa07d6 100644
--- a/plugins/Popup/src/opt_adv.cpp
+++ b/plugins/Popup/src/opt_adv.cpp
@@ -112,7 +112,7 @@ INT_PTR CALLBACK DlgProcPopupAdvOpts(HWND hwnd, UINT msg, WPARAM wParam, LPARAM
HWND hCtrl = GetDlgItem(hwnd, IDC_SHOWHISTORY);
SendMessage(hCtrl, BUTTONSETASFLATBTN, TRUE, 0);
SendMessage(hCtrl, BUTTONADDTOOLTIP, (WPARAM)Translate("Popup History"), 0);
- SendMessage(hCtrl, BM_SETIMAGE, IMAGE_ICON, (LPARAM)Skin_GetIcon(ICO_HISTORY, 0));
+ SendMessage(hCtrl, BM_SETIMAGE, IMAGE_ICON, (LPARAM)IcoLib_GetIcon(ICO_HISTORY, 0));
EnableWindow(GetDlgItem(hwnd, IDC_HISTORY_STATIC1), PopupOptions.EnableHistory);
EnableWindow(GetDlgItem(hwnd, IDC_HISTORYSIZE), PopupOptions.EnableHistory);
diff --git a/plugins/Popup/src/opt_class.cpp b/plugins/Popup/src/opt_class.cpp
index f2f427c551..35bd585ed0 100644
--- a/plugins/Popup/src/opt_class.cpp
+++ b/plugins/Popup/src/opt_class.cpp
@@ -183,14 +183,14 @@ INT_PTR CALLBACK DlgProcOptsClasses(HWND hwnd, UINT msg, WPARAM wParam, LPARAM l
TreeView_DeleteAllItems(hwndTree);
// Treeview create image list
HIMAGELIST hImgLst = ImageList_Create(GetSystemMetrics(SM_CXSMICON), GetSystemMetrics(SM_CYSMICON), ILC_COLOR | ILC_COLOR32 | ILC_MASK, 5, num_classes + 1);
- ImageList_ReplaceIcon(hImgLst, -1, Skin_GetIcon(ICO_OPT_GROUP, 0));
+ ImageList_ReplaceIcon(hImgLst, -1, IcoLib_GetIcon(ICO_OPT_GROUP, 0));
TreeView_SetImageList(hwndTree, hImgLst, TVSIL_NORMAL);
for (i = 0; i < gTreeData.getCount(); ++i) {
switch (gTreeData[i]->typ) {
case 1: // Treeview part for typ 1 (notification)
mir_snprintf(iconName, SIZEOF(iconName), "%s_%S_%S", MODULNAME, gTreeData[i]->pszTreeRoot, gTreeData[i]->pszDescription);
- iconIndex = ImageList_ReplaceIcon(hImgLst, -1, Skin_GetIcon(iconName));
+ iconIndex = ImageList_ReplaceIcon(hImgLst, -1, IcoLib_GetIcon(iconName));
mir_sntprintf(itemName, SIZEOF(itemName), _T("%s/%s"), gTreeData[i]->pszTreeRoot, gTreeData[i]->pszDescription);
break;
case 2: // Treeview part typ 2 (popup class api)
@@ -223,7 +223,7 @@ INT_PTR CALLBACK DlgProcOptsClasses(HWND hwnd, UINT msg, WPARAM wParam, LPARAM l
(WPARAM)Translate(statusButtons[i].title), 0);
}
// info icon
- SendDlgItemMessage(hwnd, IDC_ICO_INFO, STM_SETICON, (WPARAM)Skin_GetIcon(ICO_MISC_NOTIFY, 0), 0);
+ SendDlgItemMessage(hwnd, IDC_ICO_INFO, STM_SETICON, (WPARAM)IcoLib_GetIcon(ICO_MISC_NOTIFY, 0), 0);
// more button
EnableWindow(GetDlgItem(hwnd, IDC_MORE), FALSE);
// preview button
diff --git a/plugins/Popup/src/opt_contacts.cpp b/plugins/Popup/src/opt_contacts.cpp
index e51aefe49e..31041c357a 100644
--- a/plugins/Popup/src/opt_contacts.cpp
+++ b/plugins/Popup/src/opt_contacts.cpp
@@ -35,7 +35,7 @@ static void sttSetAllContactIcons(HWND hwndList)
DWORD dwMode = db_get_b(hContact, MODULNAME, "ShowMode", 0);
for (int i = 0; i < 4 /*SIZEOF(sttIcons)*/; ++i)
// hIml element [0] = SKINICON_OTHER_SMALLDOT
- // hIml element [1..5] = Skin_GetIcon(....) ~ old sttIcons
+ // hIml element [1..5] = IcoLib_GetIcon(....) ~ old sttIcons
SendMessage(hwndList, CLM_SETEXTRAIMAGE, (WPARAM)hItem, MAKELPARAM(i, ((int)dwMode == i) ? i + 1 : 0));
}
}
@@ -46,17 +46,17 @@ INT_PTR CALLBACK DlgProcContactOpts(HWND hwnd, UINT msg, WPARAM, LPARAM lParam)
case WM_INITDIALOG:
TranslateDialogDefault(hwnd);
- SendDlgItemMessage(hwnd, IDC_ICO_AUTO, STM_SETICON, (WPARAM)Skin_GetIcon(ICO_OPT_DEF, 0), 0);
- SendDlgItemMessage(hwnd, IDC_ICO_FAVORITE, STM_SETICON, (WPARAM)Skin_GetIcon(ICO_OPT_FAV, 0), 0);
- SendDlgItemMessage(hwnd, IDC_ICO_FULLSCREEN, STM_SETICON, (WPARAM)Skin_GetIcon(ICO_OPT_FULLSCREEN, 0), 0);
- SendDlgItemMessage(hwnd, IDC_ICO_BLOCK, STM_SETICON, (WPARAM)Skin_GetIcon(ICO_OPT_BLOCK, 0), 0);
+ SendDlgItemMessage(hwnd, IDC_ICO_AUTO, STM_SETICON, (WPARAM)IcoLib_GetIcon(ICO_OPT_DEF, 0), 0);
+ SendDlgItemMessage(hwnd, IDC_ICO_FAVORITE, STM_SETICON, (WPARAM)IcoLib_GetIcon(ICO_OPT_FAV, 0), 0);
+ SendDlgItemMessage(hwnd, IDC_ICO_FULLSCREEN, STM_SETICON, (WPARAM)IcoLib_GetIcon(ICO_OPT_FULLSCREEN, 0), 0);
+ SendDlgItemMessage(hwnd, IDC_ICO_BLOCK, STM_SETICON, (WPARAM)IcoLib_GetIcon(ICO_OPT_BLOCK, 0), 0);
{
HIMAGELIST hIml = ImageList_Create(GetSystemMetrics(SM_CXSMICON), GetSystemMetrics(SM_CYSMICON), ILC_COLOR32 | ILC_MASK, 5, 5);
ImageList_AddIcon(hIml, LoadSkinnedIcon(SKINICON_OTHER_SMALLDOT));
- ImageList_AddIcon(hIml, Skin_GetIcon(ICO_OPT_DEF, 0));
- ImageList_AddIcon(hIml, Skin_GetIcon(ICO_OPT_FAV, 0));
- ImageList_AddIcon(hIml, Skin_GetIcon(ICO_OPT_FULLSCREEN, 0));
- ImageList_AddIcon(hIml, Skin_GetIcon(ICO_OPT_BLOCK, 0));
+ ImageList_AddIcon(hIml, IcoLib_GetIcon(ICO_OPT_DEF, 0));
+ ImageList_AddIcon(hIml, IcoLib_GetIcon(ICO_OPT_FAV, 0));
+ ImageList_AddIcon(hIml, IcoLib_GetIcon(ICO_OPT_FULLSCREEN, 0));
+ ImageList_AddIcon(hIml, IcoLib_GetIcon(ICO_OPT_BLOCK, 0));
SendDlgItemMessage(hwnd, IDC_LIST, CLM_SETEXTRAIMAGELIST, 0, (LPARAM)hIml);
SendDlgItemMessage(hwnd, IDC_LIST, CLM_SETEXTRACOLUMNS, 4 /*SIZEOF(sttIcons)*/, 0);
sttResetListOptions(GetDlgItem(hwnd, IDC_LIST));
@@ -88,7 +88,7 @@ INT_PTR CALLBACK DlgProcContactOpts(HWND hwnd, UINT msg, WPARAM, LPARAM lParam)
if (iImage != EMPTY_EXTRA_ICON) {
for (int i = 0; i < 4 /*SIZEOF(sttIcons)*/; ++i)
// hIml element [0] = SKINICON_OTHER_SMALLDOT
- // hIml element [1..5] = Skin_GetIcon(....) ~ old sttIcons
+ // hIml element [1..5] = IcoLib_GetIcon(....) ~ old sttIcons
SendDlgItemMessage(hwnd, IDC_LIST, CLM_SETEXTRAIMAGE, (WPARAM)hItem, MAKELPARAM(i, (i == nm->iColumn) ? i + 1 : 0));
}
SendMessage(GetParent(hwnd), PSM_CHANGED, 0, 0);
diff --git a/plugins/Popup/src/opt_gen.cpp b/plugins/Popup/src/opt_gen.cpp
index 234216ca39..9d11296629 100644
--- a/plugins/Popup/src/opt_gen.cpp
+++ b/plugins/Popup/src/opt_gen.cpp
@@ -182,7 +182,7 @@ INT_PTR CALLBACK DlgProcPopupGeneral(HWND hwnd, UINT msg, WPARAM wParam, LPARAM
HWND hCtrl = GetDlgItem(hwnd, IDC_CUSTOMPOS);
SendMessage(hCtrl, BUTTONSETASFLATBTN, TRUE, 0);
SendMessage(hCtrl, BUTTONADDTOOLTIP, (WPARAM)_T("Popup area"), BATF_TCHAR);
- SendMessage(hCtrl, BM_SETIMAGE, IMAGE_ICON, (LPARAM)Skin_GetIcon(ICO_OPT_RESIZE, 0));
+ SendMessage(hCtrl, BM_SETIMAGE, IMAGE_ICON, (LPARAM)IcoLib_GetIcon(ICO_OPT_RESIZE, 0));
}
// Spreading combobox
{
@@ -627,11 +627,11 @@ INT_PTR CALLBACK PositionBoxDlgProc(HWND hwndDlg, UINT msg, WPARAM wParam, LPARA
SendDlgItemMessage(hwndDlg, IDOK, BUTTONSETASFLATBTN, TRUE, 0);
SendDlgItemMessage(hwndDlg, IDOK, BUTTONADDTOOLTIP, (WPARAM)_T("OK"), BATF_TCHAR);
- SendDlgItemMessage(hwndDlg, IDOK, BM_SETIMAGE, IMAGE_ICON, (LPARAM)Skin_GetIcon(ICO_OPT_OK, 0));
+ SendDlgItemMessage(hwndDlg, IDOK, BM_SETIMAGE, IMAGE_ICON, (LPARAM)IcoLib_GetIcon(ICO_OPT_OK, 0));
SendDlgItemMessage(hwndDlg, IDCANCEL, BUTTONSETASFLATBTN, TRUE, 0);
SendDlgItemMessage(hwndDlg, IDCANCEL, BUTTONADDTOOLTIP, (WPARAM)_T("Cancel"), BATF_TCHAR);
- SendDlgItemMessage(hwndDlg, IDCANCEL, BM_SETIMAGE, IMAGE_ICON, (LPARAM)Skin_GetIcon(ICO_OPT_CANCEL, 0));
+ SendDlgItemMessage(hwndDlg, IDCANCEL, BM_SETIMAGE, IMAGE_ICON, (LPARAM)IcoLib_GetIcon(ICO_OPT_CANCEL, 0));
SetDlgItemInt(hwndDlg, IDC_TXT_TOP, PopupOptions.gapTop, FALSE);
SetDlgItemInt(hwndDlg, IDC_TXT_BOTTOM, PopupOptions.gapBottom, FALSE);
diff --git a/plugins/Popup/src/opt_skins.cpp b/plugins/Popup/src/opt_skins.cpp
index 041607951c..52ac9b6ddc 100644
--- a/plugins/Popup/src/opt_skins.cpp
+++ b/plugins/Popup/src/opt_skins.cpp
@@ -361,7 +361,7 @@ INT_PTR CALLBACK DlgProcPopSkinsOpts(HWND hwndDlg, UINT msg, WPARAM wParam, LPAR
// Skin List reload button
SendDlgItemMessage(hwndDlg, IDC_BTN_RELOAD, BUTTONSETASFLATBTN, TRUE, 0);
- SendDlgItemMessage(hwndDlg, IDC_BTN_RELOAD, BM_SETIMAGE, IMAGE_ICON, (LPARAM)Skin_GetIcon(ICO_OPT_RELOAD, 0));
+ SendDlgItemMessage(hwndDlg, IDC_BTN_RELOAD, BM_SETIMAGE, IMAGE_ICON, (LPARAM)IcoLib_GetIcon(ICO_OPT_RELOAD, 0));
SendDlgItemMessage(hwndDlg, IDC_BTN_RELOAD, BUTTONADDTOOLTIP, (WPARAM)Translate("Refresh List"), 0);
// Skin Option List
@@ -544,7 +544,7 @@ static void BoxPreview_OnPaint(HWND hwnd, HDC mydc, int mode)
HFONT hfnt = (HFONT)SelectObject(mydc, fonts.title);
GetClientRect(hwnd, &rc);
FillRect(mydc, &rc, hbr);
- DrawIconEx(mydc, 10, (rc.bottom - rc.top - 16) / 2, Skin_GetIcon(ICO_POPUP_ON, 0), 16, 16, 0, hbr, DI_NORMAL);
+ DrawIconEx(mydc, 10, (rc.bottom - rc.top - 16) / 2, IcoLib_GetIcon(ICO_POPUP_ON, 0), 16, 16, 0, hbr, DI_NORMAL);
SetBkMode(mydc, TRANSPARENT);
GetClientRect(hwnd, &rc);
rc.left += 30; // 10+16+4 -- icon
diff --git a/plugins/Popup/src/popup_wnd2.cpp b/plugins/Popup/src/popup_wnd2.cpp
index e99ec235a0..2d45ac3553 100644
--- a/plugins/Popup/src/popup_wnd2.cpp
+++ b/plugins/Popup/src/popup_wnd2.cpp
@@ -578,7 +578,7 @@ int PopupWnd2::fixActions(POPUPACTION *theActions, int count)
if (enableDefaultUsr && isIm && IsActionEnabled("General/Quick reply")) {
m_actions[iAction].actionA.cbSize = sizeof(POPUPACTION);
- m_actions[iAction].actionA.lchIcon = Skin_GetIcon(ICO_ACT_REPLY, iconSize);
+ m_actions[iAction].actionA.lchIcon = IcoLib_GetIcon(ICO_ACT_REPLY, iconSize);
mir_strcpy(m_actions[iAction].actionA.lpzTitle, "General/Quick reply");
m_actions[iAction].actionA.wParam = 0;
m_actions[iAction].actionA.lParam = ACT_DEF_REPLY;
@@ -587,7 +587,7 @@ int PopupWnd2::fixActions(POPUPACTION *theActions, int count)
if (enableDefaultUsr && isIm && IsActionEnabled("General/Send message")) {
m_actions[iAction].actionA.cbSize = sizeof(POPUPACTION);
- m_actions[iAction].actionA.lchIcon = Skin_GetIcon(ICO_ACT_MESS, iconSize);
+ m_actions[iAction].actionA.lchIcon = IcoLib_GetIcon(ICO_ACT_MESS, iconSize);
mir_strcpy(m_actions[iAction].actionA.lpzTitle, "General/Send message");
m_actions[iAction].actionA.wParam = 0;
m_actions[iAction].actionA.lParam = ACT_DEF_MESSAGE;
@@ -596,7 +596,7 @@ int PopupWnd2::fixActions(POPUPACTION *theActions, int count)
if (enableDefaultUsr && IsActionEnabled("General/User details")) {
m_actions[iAction].actionA.cbSize = sizeof(POPUPACTION);
- m_actions[iAction].actionA.lchIcon = Skin_GetIcon(ICO_ACT_INFO, iconSize);
+ m_actions[iAction].actionA.lchIcon = IcoLib_GetIcon(ICO_ACT_INFO, iconSize);
mir_strcpy(m_actions[iAction].actionA.lpzTitle, "General/User details");
m_actions[iAction].actionA.wParam = 0;
m_actions[iAction].actionA.lParam = ACT_DEF_DETAILS;
@@ -605,7 +605,7 @@ int PopupWnd2::fixActions(POPUPACTION *theActions, int count)
if (enableDefaultUsr && IsActionEnabled("General/Contact menu")) {
m_actions[iAction].actionA.cbSize = sizeof(POPUPACTION);
- m_actions[iAction].actionA.lchIcon = Skin_GetIcon(ICO_ACT_MENU, iconSize);
+ m_actions[iAction].actionA.lchIcon = IcoLib_GetIcon(ICO_ACT_MENU, iconSize);
mir_strcpy(m_actions[iAction].actionA.lpzTitle, "General/Contact menu");
m_actions[iAction].actionA.wParam = 0;
m_actions[iAction].actionA.lParam = ACT_DEF_MENU;
@@ -614,7 +614,7 @@ int PopupWnd2::fixActions(POPUPACTION *theActions, int count)
if (enableDefaultUsr && db_get_b(m_hContact, "CList", "NotOnList", 0) && IsActionEnabled("General/Add permanently")) {
m_actions[iAction].actionA.cbSize = sizeof(POPUPACTION);
- m_actions[iAction].actionA.lchIcon = Skin_GetIcon(ICO_ACT_ADD, iconSize);
+ m_actions[iAction].actionA.lchIcon = IcoLib_GetIcon(ICO_ACT_ADD, iconSize);
mir_strcpy(m_actions[iAction].actionA.lpzTitle, "General/Add permanently");
m_actions[iAction].actionA.wParam = 0;
m_actions[iAction].actionA.lParam = ACT_DEF_ADD;
@@ -623,7 +623,7 @@ int PopupWnd2::fixActions(POPUPACTION *theActions, int count)
if (enableDefaultGen && (m_iTimeout != -1) && IsActionEnabled("General/Pin popup")) {
m_actions[iAction].actionA.cbSize = sizeof(POPUPACTION);
- m_actions[iAction].actionA.lchIcon = m_bIsPinned ? Skin_GetIcon(ICO_ACT_PINNED, iconSize) : Skin_GetIcon(ICO_ACT_PIN, iconSize);
+ m_actions[iAction].actionA.lchIcon = m_bIsPinned ? IcoLib_GetIcon(ICO_ACT_PINNED, iconSize) : IcoLib_GetIcon(ICO_ACT_PIN, iconSize);
mir_strcpy(m_actions[iAction].actionA.lpzTitle, "General/Pin popup");
m_actions[iAction].actionA.wParam = 0;
m_actions[iAction].actionA.lParam = ACT_DEF_PIN;
@@ -632,7 +632,7 @@ int PopupWnd2::fixActions(POPUPACTION *theActions, int count)
if (enableDefaultGen && IsActionEnabled("General/Dismiss popup")) {
m_actions[iAction].actionA.cbSize = sizeof(POPUPACTION);
- m_actions[iAction].actionA.lchIcon = Skin_GetIcon(ICO_ACT_CLOSE, iconSize);
+ m_actions[iAction].actionA.lchIcon = IcoLib_GetIcon(ICO_ACT_CLOSE, iconSize);
mir_strcpy(m_actions[iAction].actionA.lpzTitle, "General/Dismiss popup");
m_actions[iAction].actionA.wParam = 0;
m_actions[iAction].actionA.lParam = ACT_DEF_DISMISS;
@@ -641,7 +641,7 @@ int PopupWnd2::fixActions(POPUPACTION *theActions, int count)
if (enableDefaultGen && IsActionEnabled("General/Copy to clipboard")) {
m_actions[iAction].actionA.cbSize = sizeof(POPUPACTION);
- m_actions[iAction].actionA.lchIcon = Skin_GetIcon(ICO_ACT_COPY, iconSize);
+ m_actions[iAction].actionA.lchIcon = IcoLib_GetIcon(ICO_ACT_COPY, iconSize);
mir_strcpy(m_actions[iAction].actionA.lpzTitle, "General/Copy to clipboard");
m_actions[iAction].actionA.wParam = 0;
m_actions[iAction].actionA.lParam = ACT_DEF_COPY;
@@ -680,14 +680,14 @@ int PopupWnd2::fixActions(POPUPACTION *theActions, int count, int additional)
void PopupWnd2::setIcon(HICON hNewIcon)
{
if (m_bIcoLib) {
- Skin_ReleaseIcon(m_hIcon);
+ IcoLib_ReleaseIcon(m_hIcon);
m_bIcoLib = false;
}
m_hIcon = hNewIcon;
- if (CallService(MS_SKIN2_ISMANAGEDICON, (WPARAM)m_hIcon, 0)) {
- CallService(MS_SKIN2_ADDREFICON, (WPARAM)m_hIcon, 0);
+ if (IcoLib_IsManaged(m_hIcon)) {
+ IcoLib_AddRef(m_hIcon);
m_bIcoLib = true;
}
}
@@ -988,7 +988,7 @@ LRESULT CALLBACK PopupWnd2::WindowProc(UINT message, WPARAM wParam, LPARAM lPara
m_bIsPinned = !m_bIsPinned;
{
bool iconSize = PopupOptions.actions&ACT_LARGE ? TRUE : FALSE;
- PUModifyActionIcon(m_hwnd, wParam, lParam, m_bIsPinned ? Skin_GetIcon(ICO_ACT_PINNED, iconSize) : Skin_GetIcon(ICO_ACT_PIN, iconSize));
+ PUModifyActionIcon(m_hwnd, wParam, lParam, m_bIsPinned ? IcoLib_GetIcon(ICO_ACT_PINNED, iconSize) : IcoLib_GetIcon(ICO_ACT_PIN, iconSize));
}
break;
diff --git a/plugins/Popup/src/services.cpp b/plugins/Popup/src/services.cpp
index c5da930c89..b77c87a75a 100644
--- a/plugins/Popup/src/services.cpp
+++ b/plugins/Popup/src/services.cpp
@@ -240,21 +240,21 @@ INT_PTR Popup_ShowMessageW(WPARAM wParam, LPARAM lParam)
ppd2.lptzText = (TCHAR*)wParam;
switch (lParam & 0x7fffffff) {
case SM_ERROR:
- ppd2.lchIcon = Skin_GetIcon(ICO_MISC_ERROR, 0);
+ ppd2.lchIcon = IcoLib_GetIcon(ICO_MISC_ERROR, 0);
ppd2.colorBack = RGB(191, 0, 0);
ppd2.colorText = RGB(255, 245, 225);
ppd2.lchNotification = g_hntfError;
ppd2.lptzTitle = TranslateT("Error");
break;
case SM_WARNING:
- ppd2.lchIcon = Skin_GetIcon(ICO_MISC_WARNING, 0);
+ ppd2.lchIcon = IcoLib_GetIcon(ICO_MISC_WARNING, 0);
ppd2.colorBack = RGB(210, 210, 150);
ppd2.colorText = RGB(0, 0, 0);
ppd2.lchNotification = g_hntfWarning;
ppd2.lptzTitle = TranslateT("Warning");
break;
case SM_NOTIFY:
- ppd2.lchIcon = Skin_GetIcon(ICO_MISC_NOTIFY, 0);
+ ppd2.lchIcon = IcoLib_GetIcon(ICO_MISC_NOTIFY, 0);
ppd2.colorBack = RGB(230, 230, 230);
ppd2.colorText = RGB(0, 0, 0);
ppd2.lchNotification = g_hntfNotification;
diff --git a/plugins/Popup/src/srmm_menu.cpp b/plugins/Popup/src/srmm_menu.cpp
index 00c2451c84..c8b0c7289f 100644
--- a/plugins/Popup/src/srmm_menu.cpp
+++ b/plugins/Popup/src/srmm_menu.cpp
@@ -109,22 +109,22 @@ void SrmmMenu_Load()
sid.dwId = 0;
sid.szTooltip = LPGEN("Popup Mode: Auto");
- sid.hIcon = sid.hIconDisabled = Skin_GetIcon(ICO_POPUP_ON, 0);
+ sid.hIcon = sid.hIconDisabled = IcoLib_GetIcon(ICO_POPUP_ON, 0);
Srmm_AddIcon(&sid);
sid.dwId = 1;
sid.szTooltip = LPGEN("Popup Mode: Favorite");
- sid.hIcon = sid.hIconDisabled = Skin_GetIcon(ICO_FAV, 0);
+ sid.hIcon = sid.hIconDisabled = IcoLib_GetIcon(ICO_FAV, 0);
Srmm_AddIcon(&sid);
sid.dwId = 2;
sid.szTooltip = LPGEN("Popup Mode: Ignore fullscreen");
- sid.hIcon = sid.hIconDisabled = Skin_GetIcon(ICO_FULLSCREEN, 0);
+ sid.hIcon = sid.hIconDisabled = IcoLib_GetIcon(ICO_FULLSCREEN, 0);
Srmm_AddIcon(&sid);
sid.dwId = 3;
sid.szTooltip = LPGEN("Popup Mode: Block contact");
- sid.hIcon = sid.hIconDisabled = Skin_GetIcon(ICO_POPUP_OFF, 0);
+ sid.hIcon = sid.hIconDisabled = IcoLib_GetIcon(ICO_POPUP_OFF, 0);
Srmm_AddIcon(&sid);
HookEvent(ME_MSG_ICONPRESSED, SrmmMenu_ProcessIconClick);
diff --git a/plugins/QuickMessages/src/Utils.cpp b/plugins/QuickMessages/src/Utils.cpp
index 8ae1829407..261e42198e 100644
--- a/plugins/QuickMessages/src/Utils.cpp
+++ b/plugins/QuickMessages/src/Utils.cpp
@@ -232,7 +232,7 @@ static HANDLE AddIcon(char* szIcoName)
TCHAR tszPath[MAX_PATH];
GetModuleFileName(hinstance, tszPath, SIZEOF(tszPath));
- SKINICONDESC sid = { 0 };
+ SKINICONDESC sid = { 0 };
sid.flags = SIDF_PATH_TCHAR;
sid.section.a = "Quick Messages";
sid.cx = sid.cy = 16;
@@ -240,7 +240,7 @@ static HANDLE AddIcon(char* szIcoName)
sid.pszName = szIcoName;
sid.defaultFile.t = tszPath;
sid.iDefaultIndex = -IDI_QICON;
- return Skin_AddIcon(&sid);
+ return IcoLib_AddIcon(&sid);
}
DWORD BalanceButtons(int buttonsWas, int buttonsNow)
diff --git a/plugins/QuickSearch/quicksearch.dpr b/plugins/QuickSearch/quicksearch.dpr
index b0041c2d66..764200acdc 100644
--- a/plugins/QuickSearch/quicksearch.dpr
+++ b/plugins/QuickSearch/quicksearch.dpr
@@ -54,15 +54,14 @@ begin
FillChar(mi,SizeOf(mi),0);
mi.cbSize:=sizeof(mi);
mi.flags :=CMIM_ICON;
-
- mi.hIcon:=CallService(MS_SKIN2_GETICON,0,tlparam(QS_QS));
+ mi.hIcon:=IcoLib_GetIcon(QS_QS,0);
CallService(MS_CLIST_MODIFYMENUITEM,MainMenuItem,tlparam(@mi));
// toptoolbar
if ServiceExists(MS_TTB_GETBUTTONOPTIONS)<>0 then
begin
CallService(MS_TTB_GETBUTTONOPTIONS,(hTTBButton shl 16)+TTBO_ALLDATA,TLPARAM(@ttb));
- ttb.hIconUp:=CallService(MS_SKIN2_GETICON,0,TLPARAM(QS_QS));
+ ttb.hIconUp:=IcoLib_GetIcon(QS_QS,0);
ttb.hIconDn:=ttb.hIconUp;
CallService(MS_TTB_SETBUTTONOPTIONS,(hTTBButton shl 16)+TTBO_ALLDATA,TLPARAM(@ttb));
end;
diff --git a/plugins/QuickSearch/sr_frame.pas b/plugins/QuickSearch/sr_frame.pas
index 692692a5ad..63def5d015 100644
--- a/plugins/QuickSearch/sr_frame.pas
+++ b/plugins/QuickSearch/sr_frame.pas
@@ -176,7 +176,7 @@ begin
begin
cbSize :=SizeOf(Frame);
hWnd :=FrameWnd;
- hIcon :=CallService(MS_SKIN2_GETICON,0,tlparam(QS_QS));
+ hIcon :=IcoLib_GetIcon(QS_QS,0);
align :=alTop;
height :=tr.bottom-tr.top+2;
Flags :=F_NOBORDER or F_UNICODE;
diff --git a/plugins/QuickSearch/sr_global.pas b/plugins/QuickSearch/sr_global.pas
index c7cb5af022..b7431f54ca 100644
--- a/plugins/QuickSearch/sr_global.pas
+++ b/plugins/QuickSearch/sr_global.pas
@@ -225,7 +225,7 @@ begin
ZeroMemory(@ttbopt,sizeof(ttbopt));
ttbopt.cbSize :=sizeof(ttbopt);
ttbopt.pszService:=QS_SHOWSERVICE;
- ttbopt.hIconUp :=CallService(MS_SKIN2_GETICON,0,lparam(QS_QS));
+ ttbopt.hIconUp :=IcoLib_GetIcon(QS_QS,0);
ttbopt.hIconDn :=ttbopt.hIconUp;
ttbopt.dwFlags :=TTBBF_VISIBLE;
ttbopt.name :=qs_module;
@@ -248,7 +248,7 @@ begin
// cmi.pszPopupName:=nil;
// cmi.flags :=0;
cmi.pszService :=QS_SHOWSERVICE;
- cmi.hIcon :=CallService(MS_SKIN2_GETICON,0,lparam(QS_QS));
+ cmi.hIcon :=IcoLib_GetIcon(QS_QS,0);
MainMenuItem :=Menu_AddMainMenuItem(@cmi);
begin
diff --git a/plugins/QuickSearch/sr_window.pas b/plugins/QuickSearch/sr_window.pas
index 7fdfcbe373..17fbc25e57 100644
--- a/plugins/QuickSearch/sr_window.pas
+++ b/plugins/QuickSearch/sr_window.pas
@@ -1636,8 +1636,8 @@ begin
end
else if (setting_type=QST_CONTACTINFO) and (cnftype=CNF_GENDER) then
begin
- if hIconF=0 then hIconF:=CallService(MS_SKIN2_GETICON,0,tlparam(QS_FEMALE));
- if hIconM=0 then hIconM:=CallService(MS_SKIN2_GETICON,0,tlparam(QS_MALE));
+ if hIconF=0 then hIconF:=IcoLib_GetIcon(QS_FEMALE,0);
+ if hIconM=0 then hIconM:=IcoLib_GetIcon(QS_MALE,0);
flags:=flags or COL_GENDER;
tstrMale :=TranslateW('Male');
tstrFemale :=TranslateW('Female');
@@ -1977,8 +1977,7 @@ begin
tmp:=tmp and not WS_EX_TOOLWINDOW;
SetWindowLongPtrW(Dialog,GWL_EXSTYLE,tmp);
- SendMessage(Dialog,WM_SETICON,ICON_SMALL,//LoadIcon(hInstance,PAnsiChar(IDI_QS))
- CallService(MS_SKIN2_GETICON,0,tlparam(QS_QS)));
+ SendMessage(Dialog,WM_SETICON,ICON_SMALL,IcoLib_GetIcon(QS_QS,0));
grid:=GetDlgItem(Dialog,IDC_LIST);
// ListView
diff --git a/plugins/Quotes/src/IconLib.cpp b/plugins/Quotes/src/IconLib.cpp
index 31be0a90a8..6205ec3c2e 100644
--- a/plugins/Quotes/src/IconLib.cpp
+++ b/plugins/Quotes/src/IconLib.cpp
@@ -35,7 +35,7 @@ std::string Quotes_MakeIconName(const char* name)
HICON Quotes_LoadIconEx(const char* name, bool bBig /*= false*/)
{
std::string sIconName = Quotes_MakeIconName(name);
- return Skin_GetIcon(sIconName.c_str(), bBig);
+ return IcoLib_GetIcon(sIconName.c_str(), bBig);
}
HANDLE Quotes_GetIconHandle(int iconId)
diff --git a/plugins/Scriver/src/chat/window.cpp b/plugins/Scriver/src/chat/window.cpp
index 638c8feb85..60a5bf88c8 100644
--- a/plugins/Scriver/src/chat/window.cpp
+++ b/plugins/Scriver/src/chat/window.cpp
@@ -1402,7 +1402,7 @@ static INT_PTR CALLBACK RoomWndProc(HWND hwndDlg, UINT uMsg, WPARAM wParam, LPAR
if (g_Settings.bShowContactStatus && g_Settings.bContactStatusFirst && ui->ContactStatus) {
hIcon = LoadSkinnedProtoIcon(si->pszModule, ui->ContactStatus);
DrawIconEx(dis->hDC, x_offset, dis->rcItem.top + offset - 3, hIcon, 16, 16, 0, NULL, DI_NORMAL);
- Skin_ReleaseIcon(hIcon);
+ IcoLib_ReleaseIcon(hIcon);
x_offset += 18;
}
DrawIconEx(dis->hDC, x_offset, dis->rcItem.top + offset, pci->SM_GetStatusIcon(si, ui), 10, 10, 0, NULL, DI_NORMAL);
@@ -1410,7 +1410,7 @@ static INT_PTR CALLBACK RoomWndProc(HWND hwndDlg, UINT uMsg, WPARAM wParam, LPAR
if (g_Settings.bShowContactStatus && !g_Settings.bContactStatusFirst && ui->ContactStatus) {
hIcon = LoadSkinnedProtoIcon(si->pszModule, ui->ContactStatus);
DrawIconEx(dis->hDC, x_offset, dis->rcItem.top + offset - 3, hIcon, 16, 16, 0, NULL, DI_NORMAL);
- Skin_ReleaseIcon(hIcon);
+ IcoLib_ReleaseIcon(hIcon);
x_offset += 18;
}
diff --git a/plugins/Scriver/src/globals.cpp b/plugins/Scriver/src/globals.cpp
index 8a35da30a5..dde38e5739 100644
--- a/plugins/Scriver/src/globals.cpp
+++ b/plugins/Scriver/src/globals.cpp
@@ -176,14 +176,14 @@ int ImageList_AddIcon_Ex(HIMAGELIST hIml, int id)
{
HICON hIcon = LoadSkinnedIcon(id);
int res = ImageList_AddIcon(hIml, hIcon);
- Skin_ReleaseIcon(hIcon);
+ IcoLib_ReleaseIcon(hIcon);
return res;
}
int ImageList_AddIcon_Ex2(HIMAGELIST hIml, HICON hIcon)
{
int res = ImageList_AddIcon(hIml, hIcon);
- Skin_ReleaseIcon(hIcon);
+ IcoLib_ReleaseIcon(hIcon);
return res;
}
@@ -191,7 +191,7 @@ int ImageList_ReplaceIcon_Ex(HIMAGELIST hIml, int nIndex, int id)
{
HICON hIcon = LoadSkinnedIcon(id);
int res = ImageList_ReplaceIcon(hIml, nIndex, hIcon);
- Skin_ReleaseIcon(hIcon);
+ IcoLib_ReleaseIcon(hIcon);
return res;
}
@@ -199,22 +199,22 @@ int ImageList_AddIcon_ProtoEx(HIMAGELIST hIml, const char* szProto, int status)
{
HICON hIcon = LoadSkinnedProtoIcon(szProto, status);
int res = ImageList_AddIcon(hIml, hIcon);
- Skin_ReleaseIcon(hIcon);
+ IcoLib_ReleaseIcon(hIcon);
return res;
}
void ReleaseIcons()
{
- Skin_ReleaseIcon(g_dat.hMsgIcon);
- Skin_ReleaseIcon(g_dat.hMsgIconBig);
- Skin_ReleaseIcon(g_dat.hIconChatBig);
+ IcoLib_ReleaseIcon(g_dat.hMsgIcon);
+ IcoLib_ReleaseIcon(g_dat.hMsgIconBig);
+ IcoLib_ReleaseIcon(g_dat.hIconChatBig);
}
HICON GetCachedIcon(const char *name)
{
for (int i = 0; i < SIZEOF(iconList); i++)
if (!mir_strcmp(iconList[i].szName, name))
- return Skin_GetIconByHandle(iconList[i].hIcolib);
+ return IcoLib_GetIconByHandle(iconList[i].hIcolib);
return NULL;
}
@@ -225,7 +225,7 @@ void LoadGlobalIcons()
g_dat.hMsgIcon = LoadSkinnedIcon(SKINICON_EVENT_MESSAGE);
g_dat.hMsgIconBig = LoadSkinnedIconBig(SKINICON_EVENT_MESSAGE);
- g_dat.hIconChatBig = Skin_GetIcon("chat_window", true);
+ g_dat.hIconChatBig = IcoLib_GetIcon("chat_window", true);
ImageList_RemoveAll(g_dat.hButtonIconList);
ImageList_RemoveAll(g_dat.hChatButtonIconList);
diff --git a/plugins/Scriver/src/msgdialog.cpp b/plugins/Scriver/src/msgdialog.cpp
index 5fd420c57b..6c93ab2243 100644
--- a/plugins/Scriver/src/msgdialog.cpp
+++ b/plugins/Scriver/src/msgdialog.cpp
@@ -223,10 +223,10 @@ void SetStatusIcon(SrmmWindowData *dat)
hContact = dat->hContact;
char *szProto = GetContactProto(hContact);
- Skin_ReleaseIcon(dat->statusIcon);
+ IcoLib_ReleaseIcon(dat->statusIcon);
dat->statusIcon = LoadSkinnedProtoIcon(szProto, dat->wStatus);
- Skin_ReleaseIcon(dat->statusIconBig);
+ IcoLib_ReleaseIcon(dat->statusIconBig);
dat->statusIconBig = LoadSkinnedProtoIconBig(szProto, dat->wStatus);
if ((int)dat->statusIconBig == CALLSERVICE_NOTFOUND)
dat->statusIconBig = NULL;
@@ -1844,8 +1844,8 @@ INT_PTR CALLBACK DlgProcMessage(HWND hwndDlg, UINT msg, WPARAM wParam, LPARAM lP
if (dat->nTypeMode == PROTOTYPE_SELFTYPING_ON)
NotifyTyping(dat, PROTOTYPE_SELFTYPING_OFF);
- Skin_ReleaseIcon(dat->statusIcon);
- Skin_ReleaseIcon(dat->statusIconBig);
+ IcoLib_ReleaseIcon(dat->statusIcon);
+ IcoLib_ReleaseIcon(dat->statusIconBig);
if (dat->statusIconOverlay != NULL) DestroyIcon(dat->statusIconOverlay);
dat->statusIcon = NULL;
dat->statusIconOverlay = NULL;
diff --git a/plugins/Scriver/src/msgs.cpp b/plugins/Scriver/src/msgs.cpp
index 572bcedf47..e4d025badb 100644
--- a/plugins/Scriver/src/msgs.cpp
+++ b/plugins/Scriver/src/msgs.cpp
@@ -454,7 +454,7 @@ static int OnModulesLoaded(WPARAM wParam, LPARAM lParam)
mi.pszName = LPGEN("&Message");
mi.pszService = MS_MSG_SENDMESSAGE;
hMsgMenuItem = Menu_AddContactMenuItem(&mi);
- Skin_ReleaseIcon(mi.hIcon);
+ IcoLib_ReleaseIcon(mi.hIcon);
HookEvent(ME_SMILEYADD_OPTIONSCHANGED, SmileySettingsChanged);
HookEvent(ME_IEVIEW_OPTIONSCHANGED, SmileySettingsChanged);
diff --git a/plugins/SecureIM/src/loadicons.cpp b/plugins/SecureIM/src/loadicons.cpp
index bf6aca904d..bac49973cf 100644
--- a/plugins/SecureIM/src/loadicons.cpp
+++ b/plugins/SecureIM/src/loadicons.cpp
@@ -59,7 +59,7 @@ HINSTANCE LoadIconsPack(const char* szIconsPack)
int ReloadIcons(WPARAM wParam, LPARAM lParam)
{
for (int i = 0; i < SIZEOF(icons); i++) {
- HICON hIcon = Skin_GetIcon(icons[i].name);
+ HICON hIcon = IcoLib_GetIcon(icons[i].name);
if (icons[i].tbl == TBL_IEC)
g_hIEC[icons[i].idx] = hIcon;
else if (icons[i].tbl == TBL_ICO)
@@ -105,9 +105,9 @@ void InitIcons(void)
sid.pszName = icons[i].name;
sid.description.a = icons[i].text;
sid.iDefaultIndex = -icons[i].key;
- HANDLE hIcolib = Skin_AddIcon(&sid);
+ HANDLE hIcolib = IcoLib_AddIcon(&sid);
- HICON hIcon = Skin_GetIconByHandle(hIcolib);
+ HICON hIcon = IcoLib_GetIconByHandle(hIcolib);
if (icons[i].tbl == TBL_IEC)
g_hIEC[icons[i].idx] = hIcon;
else if (icons[i].tbl == TBL_ICO)
diff --git a/plugins/SendScreenshotPlus/src/dlg_msgbox.cpp b/plugins/SendScreenshotPlus/src/dlg_msgbox.cpp
index 2f01d63e3f..9fc6ec2705 100644
--- a/plugins/SendScreenshotPlus/src/dlg_msgbox.cpp
+++ b/plugins/SendScreenshotPlus/src/dlg_msgbox.cpp
@@ -38,7 +38,7 @@ HICON Skin_GetIcon_SendSS(unsigned short id, BOOL big=0)
return GetIcon(ICO_MAIN);
return GetIconBtn(id);
}
-#define Skin_GetIcon Skin_GetIcon_SendSS
+#define IcoLib_GetIcon Skin_GetIcon_SendSS
/// original UserInfoEx codebase (almost):
typedef struct _MSGPOPUPDATA
@@ -124,53 +124,53 @@ static void MakePopupAction(POPUPACTION &pa, int id)
switch (id) {
case IDOK:
- pa.lchIcon = Skin_GetIcon(ICO_BTN_OK);
+ pa.lchIcon = IcoLib_GetIcon(ICO_BTN_OK);
mir_strcpy(pa.lpzTitle, MODNAME"/Ok");
break;
case IDCLOSE:
case IDCANCEL:
- pa.lchIcon = Skin_GetIcon(ICO_BTN_CANCEL);
+ pa.lchIcon = IcoLib_GetIcon(ICO_BTN_CANCEL);
mir_strcpy(pa.lpzTitle, MODNAME"/Cancel");
break;
case IDABORT:
- pa.lchIcon = Skin_GetIcon(ICO_BTN_CANCEL);
+ pa.lchIcon = IcoLib_GetIcon(ICO_BTN_CANCEL);
mir_strcpy(pa.lpzTitle, MODNAME"/Abort");
break;
case IDRETRY:
- pa.lchIcon = Skin_GetIcon(ICO_BTN_UPDATE);
+ pa.lchIcon = IcoLib_GetIcon(ICO_BTN_UPDATE);
mir_strcpy(pa.lpzTitle, MODNAME"/Retry");
break;
case IDIGNORE:
- pa.lchIcon = Skin_GetIcon(ICO_BTN_OK);
+ pa.lchIcon = IcoLib_GetIcon(ICO_BTN_OK);
mir_strcpy(pa.lpzTitle, MODNAME"/Ignore");
break;
case IDYES:
- pa.lchIcon = Skin_GetIcon(ICO_BTN_OK);
+ pa.lchIcon = IcoLib_GetIcon(ICO_BTN_OK);
mir_strcpy(pa.lpzTitle, MODNAME"/Yes");
break;
case IDNO:
- pa.lchIcon = Skin_GetIcon(ICO_BTN_CANCEL);
+ pa.lchIcon = IcoLib_GetIcon(ICO_BTN_CANCEL);
mir_strcpy(pa.lpzTitle, MODNAME"/No");
break;
case IDHELP:
- pa.lchIcon = Skin_GetIcon(ICO_BTN_CANCEL);
+ pa.lchIcon = IcoLib_GetIcon(ICO_BTN_CANCEL);
mir_strcpy(pa.lpzTitle, MODNAME"/Help");
break;
case IDALL:
- pa.lchIcon = Skin_GetIcon(ICO_BTN_OK);
+ pa.lchIcon = IcoLib_GetIcon(ICO_BTN_OK);
mir_strcpy(pa.lpzTitle, MODNAME"/All");
break;
case IDNONE:
- pa.lchIcon = Skin_GetIcon(ICO_BTN_CANCEL);
+ pa.lchIcon = IcoLib_GetIcon(ICO_BTN_CANCEL);
mir_strcpy(pa.lpzTitle, MODNAME"/None");
}
}
@@ -215,7 +215,7 @@ static INT_PTR CALLBACK MsgBoxProc(HWND hDlg, UINT uMsg, WPARAM wParam, LPARAM l
// set infobar's logo icon
SendDlgItemMessage(hDlg, ICO_DLGLOGO, STM_SETIMAGE, IMAGE_ICON,
- (pMsgBox->hiLogo ? (LPARAM)pMsgBox->hiLogo : (LPARAM)Skin_GetIcon(ICO_DLG_DETAILS,TRUE)));
+ (pMsgBox->hiLogo ? (LPARAM)pMsgBox->hiLogo : (LPARAM)IcoLib_GetIcon(ICO_DLG_DETAILS,TRUE)));
// enable headerbar
ShowWindow(GetDlgItem(hDlg, TXT_NAME), SW_SHOW);
@@ -686,7 +686,7 @@ INT_PTR CALLBACK MsgBox(HWND hParent, UINT uType, LPCTSTR pszTitle, LPCTSTR pszI
MSGBOX mb = { 0 };
mb.cbSize = sizeof(MSGBOX);
mb.hParent = hParent;
- mb.hiLogo = Skin_GetIcon(ICO_COMMON_MAIN);
+ mb.hiLogo = IcoLib_GetIcon(ICO_COMMON_MAIN);
mb.hiMsg = NULL;
mb.ptszTitle = TranslateTS(pszTitle);
mb.ptszInfoText = TranslateTS(pszInfo);
@@ -713,7 +713,7 @@ INT_PTR CALLBACK MsgErr(HWND hParent, LPCTSTR pszFormat, ...)
MSGBOX mb = {0};
mb.cbSize = sizeof(MSGBOX);
mb.hParent = hParent;
- mb.hiLogo = Skin_GetIcon(ICO_COMMON_MAIN);
+ mb.hiLogo = IcoLib_GetIcon(ICO_COMMON_MAIN);
mb.hiMsg = NULL;
mb.ptszTitle = tszTitle;
mb.ptszMsg = tszMsg;
diff --git a/plugins/SendScreenshotPlus/src/global.h b/plugins/SendScreenshotPlus/src/global.h
index 339166e774..cec50a38c3 100644
--- a/plugins/SendScreenshotPlus/src/global.h
+++ b/plugins/SendScreenshotPlus/src/global.h
@@ -150,10 +150,10 @@ enum{
ICO_BTN_END_,
};
#define GetIconHandle(ico) ICONS[ico].hIcolib
-#define GetIcon(ico) Skin_GetIconByHandle(GetIconHandle(ico))
+#define GetIcon(ico) IcoLib_GetIconByHandle(GetIconHandle(ico))
extern IconItem ICONS[ICO_END_];
#define GetIconBtnHandle(ico) ICONS_BTN[ico].hIcolib
-#define GetIconBtn(ico) Skin_GetIconByHandle(GetIconBtnHandle(ico))
+#define GetIconBtn(ico) IcoLib_GetIconByHandle(GetIconBtnHandle(ico))
extern IconItem ICONS_BTN[ICO_BTN_END_];
#define PtrIsValid(p) (((p)!=0)&&(((HANDLE)(p))!=INVALID_HANDLE_VALUE))
diff --git a/plugins/Sessions/Src/Options.cpp b/plugins/Sessions/Src/Options.cpp
index 165521e6f5..6db5100514 100644
--- a/plugins/Sessions/Src/Options.cpp
+++ b/plugins/Sessions/Src/Options.cpp
@@ -155,8 +155,8 @@ static INT_PTR CALLBACK OptionsProc(HWND hdlg, UINT msg, WPARAM wparam, LPARAM l
opses_count = 0;
g_opHdlg = hdlg;
bOptionsInit = TRUE;
- hMarked = Skin_GetIconByHandle(iconList[1].hIcolib);
- hNotMarked = Skin_GetIconByHandle(iconList[2].hIcolib);
+ hMarked = IcoLib_GetIconByHandle(iconList[1].hIcolib);
+ hNotMarked = IcoLib_GetIconByHandle(iconList[2].hIcolib);
hIcon = (bChecked = IsMarkedUserDefSession(opses_count)) ? hMarked : hNotMarked;
diff --git a/plugins/SimpleStatusMsg/src/awaymsg.cpp b/plugins/SimpleStatusMsg/src/awaymsg.cpp
index 7a1cb62e4a..76457e7267 100644
--- a/plugins/SimpleStatusMsg/src/awaymsg.cpp
+++ b/plugins/SimpleStatusMsg/src/awaymsg.cpp
@@ -197,8 +197,8 @@ static INT_PTR CALLBACK ReadAwayMsgDlgProc(HWND hwndDlg, UINT message, WPARAM wP
UnhookEvent(dat->hAwayMsgEvent);
Utils_SaveWindowPosition(hwndDlg, dat->hContact, "SRAway", "AwayMsgDlg");
WindowList_Remove(hWindowList, hwndDlg);
- Skin_ReleaseIcon((HICON)SendMessage(hwndDlg, WM_SETICON, ICON_BIG, NULL));
- Skin_ReleaseIcon((HICON)SendMessage(hwndDlg, WM_SETICON, ICON_SMALL, NULL));
+ IcoLib_ReleaseIcon((HICON)SendMessage(hwndDlg, WM_SETICON, ICON_BIG, NULL));
+ IcoLib_ReleaseIcon((HICON)SendMessage(hwndDlg, WM_SETICON, ICON_SMALL, NULL));
mir_free(dat);
break;
}
@@ -384,7 +384,7 @@ static int AwayMsgPreBuildMenu(WPARAM hContact, LPARAM lParam)
}
}
Menu_ModifyItem(hAwayMsgMenuItem, &clmi);
- Skin_ReleaseIcon(clmi.hIcon);
+ IcoLib_ReleaseIcon(clmi.hIcon);
ptrA szMsg(db_get_sa(hContact, "CList", "StatusMsg"));
diff --git a/plugins/SimpleStatusMsg/src/msgbox.cpp b/plugins/SimpleStatusMsg/src/msgbox.cpp
index 99e15d99df..5713bf1c62 100644
--- a/plugins/SimpleStatusMsg/src/msgbox.cpp
+++ b/plugins/SimpleStatusMsg/src/msgbox.cpp
@@ -78,7 +78,7 @@ HIMAGELIST AddStatusIconsToImageList(const char *szProto, int status_flags)
HIMAGELIST himlIcons = ImageList_Create(16, 16, ILC_COLOR32 | ILC_MASK, num_icons, 0);
HICON hicon = LoadSkinnedProtoIcon(szProto, ID_STATUS_OFFLINE);
ImageList_AddIcon(himlIcons, hicon);
- Skin_ReleaseIcon(hicon);
+ IcoLib_ReleaseIcon(hicon);
statusicon_nr[0] = 0;
int j = 1;
@@ -86,7 +86,7 @@ HIMAGELIST AddStatusIconsToImageList(const char *szProto, int status_flags)
if (Proto_Status2Flag(ID_STATUS_ONLINE + i) & status_flags) {
hicon = LoadSkinnedProtoIcon(szProto, ID_STATUS_ONLINE + i);
ImageList_AddIcon(himlIcons, hicon);
- Skin_ReleaseIcon(hicon);
+ IcoLib_ReleaseIcon(hicon);
statusicon_nr[i + 1] = j;
j++;
}
@@ -805,8 +805,8 @@ void ChangeDlgStatus(HWND hwndDlg, struct MsgBoxData *msgbox_data, int iStatus)
else if (iStatus > ID_STATUS_CURRENT)
iStatus = GetCurrentStatus(NULL);
- Skin_ReleaseIcon((HICON)SendMessage(hwndDlg, WM_SETICON, ICON_BIG, (LPARAM)LoadSkinnedProtoIcon(msgbox_data->m_szProto, iStatus)));
- Skin_ReleaseIcon((HICON)SendMessage(hwndDlg, WM_SETICON, ICON_SMALL, (LPARAM)LoadSkinnedProtoIcon(msgbox_data->m_szProto, iStatus)));
+ IcoLib_ReleaseIcon((HICON)SendMessage(hwndDlg, WM_SETICON, ICON_BIG, (LPARAM)LoadSkinnedProtoIcon(msgbox_data->m_szProto, iStatus)));
+ IcoLib_ReleaseIcon((HICON)SendMessage(hwndDlg, WM_SETICON, ICON_SMALL, (LPARAM)LoadSkinnedProtoIcon(msgbox_data->m_szProto, iStatus)));
if (!bDisabled && ((Proto_Status2Flag(iStatus) & msgbox_data->m_iStatusMsgModes)
|| (iStatus == ID_STATUS_OFFLINE && (Proto_Status2Flag(ID_STATUS_INVISIBLE) & msgbox_data->m_iStatusMsgModes))))
@@ -1616,8 +1616,8 @@ INT_PTR CALLBACK AwayMsgBoxDlgProc(HWND hwndDlg, UINT uMsg, WPARAM wParam, LPARA
ReleaseIconEx("predef");
ReleaseIconEx("add");
ReleaseIconEx("clear");
- Skin_ReleaseIcon((HICON)SendMessage(hwndDlg, WM_SETICON, ICON_BIG, 0));
- Skin_ReleaseIcon((HICON)SendMessage(hwndDlg, WM_SETICON, ICON_SMALL, 0));
+ IcoLib_ReleaseIcon((HICON)SendMessage(hwndDlg, WM_SETICON, ICON_BIG, 0));
+ IcoLib_ReleaseIcon((HICON)SendMessage(hwndDlg, WM_SETICON, ICON_SMALL, 0));
hwndSAMsgDialog = NULL;
mir_free(msgbox_data);
diff --git a/plugins/SimpleStatusMsg/src/utils.cpp b/plugins/SimpleStatusMsg/src/utils.cpp
index 2d1b04e920..cff6593801 100644
--- a/plugins/SimpleStatusMsg/src/utils.cpp
+++ b/plugins/SimpleStatusMsg/src/utils.cpp
@@ -43,7 +43,7 @@ HICON LoadIconEx(const char *name)
{
char szSettingName[100];
mir_snprintf(szSettingName, SIZEOF(szSettingName), "SimpleStatusMsg_%s", name);
- return Skin_GetIcon(szSettingName);
+ return IcoLib_GetIcon(szSettingName);
}
HANDLE GetIconHandle(int iconId)
@@ -59,7 +59,7 @@ void ReleaseIconEx(const char *name)
{
char szSettingName[100];
mir_snprintf(szSettingName, SIZEOF(szSettingName), "SimpleStatusMsg_%s", name);
- Skin_ReleaseIcon(szSettingName);
+ IcoLib_Release(szSettingName);
}
HANDLE HookProtoEvent(const char *szModule, const char *szEvent, MIRANDAHOOKPARAM hookProc)
diff --git a/plugins/SmileyAdd/src/general.cpp b/plugins/SmileyAdd/src/general.cpp
index baec75c826..6f2f161101 100644
--- a/plugins/SmileyAdd/src/general.cpp
+++ b/plugins/SmileyAdd/src/general.cpp
@@ -48,12 +48,12 @@ int CalculateTextHeight(HDC hdc, CHARFORMAT2* chf)
HICON GetDefaultIcon(bool copy)
{
- HICON resIco = Skin_GetIcon("SmileyAdd_ButtonSmiley");
+ HICON resIco = IcoLib_GetIcon("SmileyAdd_ButtonSmiley");
if (resIco == NULL)
resIco = (HICON)LoadImage(g_hInst, MAKEINTRESOURCE(IDI_SMILINGICON), IMAGE_ICON, 0, 0, copy ? 0 : LR_SHARED);
else if (copy) {
resIco = (HICON)CopyImage(resIco, IMAGE_ICON, 0, 0, 0);
- Skin_ReleaseIcon("SmileyAdd_ButtonSmiley");
+ IcoLib_Release("SmileyAdd_ButtonSmiley");
}
return resIco;
diff --git a/plugins/SpellChecker/src/ardialog.cpp b/plugins/SpellChecker/src/ardialog.cpp
index a3a5e3d24d..72fc6548c0 100644
--- a/plugins/SpellChecker/src/ardialog.cpp
+++ b/plugins/SpellChecker/src/ardialog.cpp
@@ -165,9 +165,9 @@ static INT_PTR CALLBACK AddReplacementDlgProc(HWND hwndDlg, UINT msg, WPARAM wPa
SetWindowLongPtr(GetDlgItem(hwndDlg, IDC_OLD), GWLP_USERDATA, (LONG_PTR)data);
mir_subclassWindow(GetDlgItem(hwndDlg, IDC_OLD), OnlyCharsEditProc);
- HICON hIcon = Skin_GetIcon("spellchecker_enabled");
+ HICON hIcon = IcoLib_GetIcon("spellchecker_enabled");
SendMessage(hwndDlg, WM_SETICON, ICON_BIG, (LPARAM)hIcon);
- Skin_ReleaseIcon(hIcon);
+ IcoLib_ReleaseIcon(hIcon);
SendDlgItemMessage(hwndDlg, IDC_OLD, EM_LIMITTEXT, 256, 0);
SendDlgItemMessage(hwndDlg, IDC_NEW, EM_LIMITTEXT, 256, 0);
diff --git a/plugins/SpellChecker/src/options.cpp b/plugins/SpellChecker/src/options.cpp
index a1f855ef59..e36ac30ce2 100644
--- a/plugins/SpellChecker/src/options.cpp
+++ b/plugins/SpellChecker/src/options.cpp
@@ -137,14 +137,14 @@ static void DrawItem(LPDRAWITEMSTRUCT lpdis, Dictionary *dict)
// Draw icon
if (opts.use_flags) {
- HICON hFlag = Skin_GetIconByHandle(dict->hIcolib);
+ HICON hFlag = IcoLib_GetIconByHandle(dict->hIcolib);
rc.top = (lpdis->rcItem.bottom + lpdis->rcItem.top - ICON_SIZE) / 2;
DrawIconEx(lpdis->hDC, rc.left, rc.top, hFlag, 16, 16, 0, NULL, DI_NORMAL);
rc.left += ICON_SIZE + 4;
- Skin_ReleaseIcon(hFlag);
+ IcoLib_ReleaseIcon(hFlag);
}
// Draw text
diff --git a/plugins/SpellChecker/src/spellchecker.cpp b/plugins/SpellChecker/src/spellchecker.cpp
index 6e539a8b19..6f02a86c14 100644
--- a/plugins/SpellChecker/src/spellchecker.cpp
+++ b/plugins/SpellChecker/src/spellchecker.cpp
@@ -73,7 +73,7 @@ static int IconsChanged(WPARAM, LPARAM)
{
StatusIconData sid = { sizeof(sid) };
sid.szModule = MODULE_NAME;
- sid.hIconDisabled = Skin_GetIcon("spellchecker_disabled");
+ sid.hIconDisabled = IcoLib_GetIcon("spellchecker_disabled");
sid.flags = MBF_HIDDEN | MBF_TCHAR;
for (int i = 0; i < languages.getCount(); i++) {
@@ -84,9 +84,9 @@ static int IconsChanged(WPARAM, LPARAM)
TranslateT("Spell Checker"), languages[i]->full_name);
sid.tszTooltip = tmp;
- HICON hIcon = (opts.use_flags) ? Skin_GetIconByHandle(languages[i]->hIcolib) : Skin_GetIcon("spellchecker_enabled");
+ HICON hIcon = (opts.use_flags) ? IcoLib_GetIconByHandle(languages[i]->hIcolib) : IcoLib_GetIcon("spellchecker_enabled");
sid.hIcon = CopyIcon(hIcon);
- Skin_ReleaseIcon(hIcon);
+ IcoLib_ReleaseIcon(hIcon);
Srmm_ModifyIcon(NULL, &sid);
}
@@ -141,7 +141,7 @@ static int ModulesLoaded(WPARAM, LPARAM)
TCHAR path[MAX_PATH];
GetModuleFileName(hInst, path, MAX_PATH);
- SKINICONDESC sid = { 0 };
+ SKINICONDESC sid = { 0 };
sid.flags = SIDF_ALL_TCHAR | SIDF_SORTED;
sid.section.t = LPGENT("Spell Checker")_T("/")LPGENT("Flags");
@@ -164,19 +164,19 @@ static int ModulesLoaded(WPARAM, LPARAM)
sid.iDefaultIndex = 0;
}
else {
- hFlagIcoLib = Skin_GetIcon("spellchecker_unknown");
+ hFlagIcoLib = IcoLib_GetIcon("spellchecker_unknown");
sid.hDefaultIcon = hFlagIcoLib;
sid.defaultFile.t = NULL;
sid.iDefaultIndex = 0;
}
// Oki, lets add to IcoLib, then
- p->hIcolib = Skin_AddIcon(&sid);
+ p->hIcolib = IcoLib_AddIcon(&sid);
if (hFlag != NULL)
DestroyIcon(hFlag);
else
- Skin_ReleaseIcon(hFlagIcoLib);
+ IcoLib_ReleaseIcon(hFlagIcoLib);
}
FreeLibrary(hFlagsDll);
}
@@ -199,7 +199,7 @@ static int ModulesLoaded(WPARAM, LPARAM)
StatusIconData sid = { sizeof(sid) };
sid.szModule = MODULE_NAME;
- sid.hIconDisabled = Skin_GetIcon("spellchecker_disabled");
+ sid.hIconDisabled = IcoLib_GetIcon("spellchecker_disabled");
sid.flags = MBF_TCHAR | MBF_HIDDEN;
for (int i = 0; i < languages.getCount(); i++) {
@@ -209,7 +209,7 @@ static int ModulesLoaded(WPARAM, LPARAM)
mir_sntprintf(tmp, SIZEOF(tmp), _T("%s - %s"),
TranslateT("Spell Checker"), languages[i]->full_name);
sid.tszTooltip = tmp;
- sid.hIcon = (opts.use_flags) ? Skin_GetIconByHandle(languages[i]->hIcolib) : Skin_GetIcon("spellchecker_enabled");
+ sid.hIcon = (opts.use_flags) ? IcoLib_GetIconByHandle(languages[i]->hIcolib) : IcoLib_GetIcon("spellchecker_enabled");
Srmm_AddIcon(&sid);
}
diff --git a/plugins/SpellChecker/src/utils.cpp b/plugins/SpellChecker/src/utils.cpp
index f985951c90..ab777aa39c 100644
--- a/plugins/SpellChecker/src/utils.cpp
+++ b/plugins/SpellChecker/src/utils.cpp
@@ -1506,12 +1506,12 @@ LRESULT CALLBACK MenuWndProc(HWND hwnd, UINT msg, WPARAM wParam, LPARAM lParam)
// Draw icon
if (dict->hIcolib) {
- HICON hFlag = Skin_GetIconByHandle(dict->hIcolib);
+ HICON hFlag = IcoLib_GetIconByHandle(dict->hIcolib);
rc.top = (lpdis->rcItem.bottom + lpdis->rcItem.top - ICON_SIZE) / 2;
DrawIconEx(lpdis->hDC, rc.left, rc.top, hFlag, 16, 16, 0, NULL, DI_NORMAL);
- Skin_ReleaseIcon(hFlag);
+ IcoLib_ReleaseIcon(hFlag);
rc.left += ICON_SIZE + 4;
}
diff --git a/plugins/StartupSilence/src/main.cpp b/plugins/StartupSilence/src/main.cpp
index 4bf0a94d33..dbf89fe3ba 100644
--- a/plugins/StartupSilence/src/main.cpp
+++ b/plugins/StartupSilence/src/main.cpp
@@ -234,7 +234,7 @@ static INT_PTR AdvSt()
if (PopUp == 1) {
lptzText = NonStatusAllow == 1 ? ALL_DISABLED_FLT : ALL_DISABLED;
- ppd.lchIcon = (HICON)CallService(MS_SKIN2_GETICONBYHANDLE, 0, (LPARAM)(NonStatusAllow == 1 ? GetIconHandle(ALL_ENABLED_FLT) : GetIconHandle(MENU_NAME)));
+ ppd.lchIcon = IcoLib_GetIconByHandle((NonStatusAllow == 1) ? GetIconHandle(ALL_ENABLED_FLT) : GetIconHandle(MENU_NAME));
ppd.lchContact = NULL;
ppd.iSeconds = PopUpTime;
wcsncpy_s(ppd.lptzText, lptzText, _TRUNCATE);
@@ -249,7 +249,7 @@ static INT_PTR AdvSt()
if (PopUp == 1) {
lptzText = (DefEnabled == 1 && DefPopup == 1) ? TranslateT(ALL_ENABLED_FLT) : ALL_ENABLED;
- ppd.lchIcon = (HICON)CallService(MS_SKIN2_GETICONBYHANDLE, 0, (LPARAM)((DefEnabled == 1 && DefPopup == 1) ? GetIconHandle(ALL_ENABLED_FLT) : GetIconHandle(MENU_NAME)));
+ ppd.lchIcon = IcoLib_GetIconByHandle((DefEnabled == 1 && DefPopup == 1) ? GetIconHandle(ALL_ENABLED_FLT) : GetIconHandle(MENU_NAME));
wcsncpy_s(ppd.lptzText, lptzText, _TRUNCATE);
PUAddPopupT(&ppd);
}
@@ -270,7 +270,7 @@ static INT_PTR SturtupSilenceEnabled(WPARAM wParam, LPARAM lParam)
if (PopUp == 1) {
TCHAR * lptzText = Enabled == 1 ? S_MODE_CHANGEDON : S_MODE_CHANGEDOFF;
POPUPDATAT ppd = {0};
- ppd.lchIcon = (HICON)CallService(MS_SKIN2_GETICONBYHANDLE, 0, (LPARAM)(Enabled == 1 ? GetIconHandle(ENABLE_SILENCE) : GetIconHandle(DISABLE_SILENCE)));
+ ppd.lchIcon = IcoLib_GetIconByHandle((Enabled == 1) ? GetIconHandle(ENABLE_SILENCE) : GetIconHandle(DISABLE_SILENCE));
ppd.lchContact = NULL;
ppd.iSeconds = PopUpTime;
wcsncpy_s(ppd.lptzText, lptzText, _TRUNCATE);
@@ -346,7 +346,7 @@ HANDLE GetIconHandle(char *szIcon)
{
char szSettingName[64];
mir_snprintf(szSettingName, SIZEOF(szSettingName), "%s_%s", MENU_NAME, szIcon);
- return Skin_GetIconHandle(szSettingName);
+ return IcoLib_GetIconHandle(szSettingName);
}
int InitializeOptions(WPARAM wParam,LPARAM lParam)
diff --git a/plugins/StopSpamPlus/src/opt_proto.cpp b/plugins/StopSpamPlus/src/opt_proto.cpp
index 21ddd4d1d3..9c6875baf4 100644
--- a/plugins/StopSpamPlus/src/opt_proto.cpp
+++ b/plugins/StopSpamPlus/src/opt_proto.cpp
@@ -58,10 +58,10 @@ INT_PTR CALLBACK ProtoDlgProc(HWND hwnd, UINT msg, WPARAM, LPARAM lParam)
HICON Icon;
Icon = (HICON)LoadSkinnedIcon(SKINICON_OTHER_NOTICK);
ImageList_AddIcon(himlCheckBoxes, Icon);
- Skin_ReleaseIcon(Icon);
+ IcoLib_ReleaseIcon(Icon);
Icon = (HICON)LoadSkinnedIcon(SKINICON_OTHER_TICK);
ImageList_AddIcon(himlCheckBoxes, Icon);
- Skin_ReleaseIcon(Icon);
+ IcoLib_ReleaseIcon(Icon);
TreeView_SetImageList(hwndProto, himlCheckBoxes, TVSIL_NORMAL);
}
diff --git a/plugins/TabSRMM/src/buttonsbar.cpp b/plugins/TabSRMM/src/buttonsbar.cpp
index 901fbcb4c8..87b1197344 100644
--- a/plugins/TabSRMM/src/buttonsbar.cpp
+++ b/plugins/TabSRMM/src/buttonsbar.cpp
@@ -1,40 +1,40 @@
#include "commonheaders.h"
-
-#define BBSF_IMBUTTON (1<<0)
-#define BBSF_CHATBUTTON (1<<1)
-#define BBSF_CANBEHIDDEN (1<<2)
-#define BBSF_NTBSWAPED (1<<3)
-#define BBSF_NTBDESTRUCT (1<<4)
-
-struct CustomButtonData : public MZeroedObject
-{
- ~CustomButtonData()
- {
- mir_free(m_pszModuleName);
- mir_free(m_ptszTooltip);
- }
-
- void Accustom(HWND hwnd, TWindowData *dat);
-
- DWORD m_dwPosition; // default order pos of button, counted from window edge (left or right)
-
- DWORD m_dwButtonOrigID; // id of button used while button creation and to store button info in DB
- char *m_pszModuleName; // module name without spaces and underline symbols (e.g. "tabsrmm")
-
- DWORD m_dwButtonCID;
- DWORD m_dwArrowCID; // only use with BBBF_ISARROWBUTTON flag
-
- TCHAR *m_ptszTooltip; // button's tooltip
-
- int m_iButtonWidth; // must be 22 for regular button and 33 for button with arrow
- HANDLE m_hIcon; // Handle to icolib registred icon
-
- bool m_bIMButton, m_bChatButton;
- bool m_bCanBeHidden, m_bHidden, m_bAutoHidden, m_bSeparator, m_bDisabled, m_bPushButton;
- bool m_bLSided, m_bRSided;
- BYTE m_opFlags;
-};
-
+
+#define BBSF_IMBUTTON (1<<0)
+#define BBSF_CHATBUTTON (1<<1)
+#define BBSF_CANBEHIDDEN (1<<2)
+#define BBSF_NTBSWAPED (1<<3)
+#define BBSF_NTBDESTRUCT (1<<4)
+
+struct CustomButtonData : public MZeroedObject
+{
+ ~CustomButtonData()
+ {
+ mir_free(m_pszModuleName);
+ mir_free(m_ptszTooltip);
+ }
+
+ void Accustom(HWND hwnd, TWindowData *dat);
+
+ DWORD m_dwPosition; // default order pos of button, counted from window edge (left or right)
+
+ DWORD m_dwButtonOrigID; // id of button used while button creation and to store button info in DB
+ char *m_pszModuleName; // module name without spaces and underline symbols (e.g. "tabsrmm")
+
+ DWORD m_dwButtonCID;
+ DWORD m_dwArrowCID; // only use with BBBF_ISARROWBUTTON flag
+
+ TCHAR *m_ptszTooltip; // button's tooltip
+
+ int m_iButtonWidth; // must be 22 for regular button and 33 for button with arrow
+ HANDLE m_hIcon; // Handle to icolib registred icon
+
+ bool m_bIMButton, m_bChatButton;
+ bool m_bCanBeHidden, m_bHidden, m_bAutoHidden, m_bSeparator, m_bDisabled, m_bPushButton;
+ bool m_bLSided, m_bRSided;
+ BYTE m_opFlags;
+};
+
static HANDLE hButtonsBarAddButton;
static HANDLE hButtonsBarRemoveButton;
static HANDLE hButtonsBarGetButtonState;
@@ -237,7 +237,7 @@ static INT_PTR CB_SetButtonState(WPARAM wParam, LPARAM lParam)
SetDlgItemTextA(hwndDlg, tempCID, bbdi->pszModuleName);
if (bbdi->hIcon)
- SendDlgItemMessage(hwndDlg, tempCID, BM_SETIMAGE, IMAGE_ICON, (LPARAM)Skin_GetIconByHandle(bbdi->hIcon));
+ SendDlgItemMessage(hwndDlg, tempCID, BM_SETIMAGE, IMAGE_ICON, (LPARAM)IcoLib_GetIconByHandle(bbdi->hIcon));
if (bbdi->pszTooltip)
SendDlgItemMessage(hwndDlg, tempCID, BUTTONADDTOOLTIP, (WPARAM)bbdi->ptszTooltip, (bbdi->bbbFlags & BBBF_ANSITOOLTIP) ? 0 : BATF_TCHAR);
if (bbdi->bbbFlags) {
@@ -471,7 +471,7 @@ static int BuildMenuObjectsTree(HWND hToolBarTree)
}
else {
tvis.item.pszText = TranslateTS(cbd->m_ptszTooltip);
- iImage = ImageList_AddIcon(himgl, Skin_GetIconByHandle(cbd->m_hIcon));
+ iImage = ImageList_AddIcon(himgl, IcoLib_GetIconByHandle(cbd->m_hIcon));
tvis.item.iImage = tvis.item.iSelectedImage = iImage;
}
cbd->m_opFlags = 0;
@@ -499,7 +499,7 @@ static int BuildMenuObjectsTree(HWND hToolBarTree)
}
else {
tvis.item.pszText = TranslateTS(cbd->m_ptszTooltip);
- iImage = ImageList_AddIcon(himgl, Skin_GetIconByHandle(cbd->m_hIcon));
+ iImage = ImageList_AddIcon(himgl, IcoLib_GetIconByHandle(cbd->m_hIcon));
tvis.item.iImage = tvis.item.iSelectedImage = iImage;
}
tvis.item.state = 0;
@@ -808,7 +808,7 @@ void CustomButtonData::Accustom(HWND hwndBtn, TWindowData *dat)
SendMessage(hwndBtn, BUTTONSETASFLATBTN, TRUE, 0);
SendMessage(hwndBtn, BUTTONSETASTHEMEDBTN, CSkin::IsThemed(), 0);
if (m_hIcon)
- SendMessage(hwndBtn, BM_SETIMAGE, IMAGE_ICON, (LPARAM)Skin_GetIconByHandle(m_hIcon));
+ SendMessage(hwndBtn, BM_SETIMAGE, IMAGE_ICON, (LPARAM)IcoLib_GetIconByHandle(m_hIcon));
if (m_ptszTooltip)
SendMessage(hwndBtn, BUTTONADDTOOLTIP, (WPARAM)TranslateTS(m_ptszTooltip), BATF_TCHAR);
SendMessage(hwndBtn, BUTTONSETCONTAINER, (LPARAM)dat->pContainer, 0);
@@ -1155,7 +1155,7 @@ void BB_UpdateIcons(HWND hdlg)
hwndBtn = GetDlgItem(hdlg, cbd->m_dwButtonCID);
if (hwndBtn && cbd->m_hIcon)
- SendMessage(hwndBtn, BM_SETIMAGE, IMAGE_ICON, (LPARAM)Skin_GetIconByHandle(cbd->m_hIcon));
+ SendMessage(hwndBtn, BM_SETIMAGE, IMAGE_ICON, (LPARAM)IcoLib_GetIconByHandle(cbd->m_hIcon));
}
}
@@ -1167,7 +1167,7 @@ void BB_UpdateIcons(HWND hdlg)
hwndBtn = GetDlgItem(hdlg, cbd->m_dwButtonCID);
if (hwndBtn && cbd->m_hIcon)
- SendMessage(hwndBtn, BM_SETIMAGE, IMAGE_ICON, (LPARAM)Skin_GetIconByHandle(cbd->m_hIcon));
+ SendMessage(hwndBtn, BM_SETIMAGE, IMAGE_ICON, (LPARAM)IcoLib_GetIconByHandle(cbd->m_hIcon));
}
}
}
@@ -1406,7 +1406,7 @@ void CB_ChangeButton(HWND hwndDlg, TWindowData *dat, CustomButtonData *cbd)
HWND hwndBtn = GetDlgItem(hwndDlg, cbd->m_dwButtonCID);
if (hwndBtn) {
if (cbd->m_hIcon)
- SendMessage(hwndBtn, BM_SETIMAGE, IMAGE_ICON, (LPARAM)Skin_GetIconByHandle(cbd->m_hIcon));
+ SendMessage(hwndBtn, BM_SETIMAGE, IMAGE_ICON, (LPARAM)IcoLib_GetIconByHandle(cbd->m_hIcon));
if (cbd->m_ptszTooltip)
SendMessage(hwndBtn, BUTTONADDTOOLTIP, (WPARAM)cbd->m_ptszTooltip, BATF_TCHAR);
SendMessage(hwndBtn, BUTTONSETCONTAINER, (LPARAM)dat->pContainer, 0);
diff --git a/plugins/TabSRMM/src/chat/options.cpp b/plugins/TabSRMM/src/chat/options.cpp
index c8754ccab7..094579efa5 100644
--- a/plugins/TabSRMM/src/chat/options.cpp
+++ b/plugins/TabSRMM/src/chat/options.cpp
@@ -350,7 +350,7 @@ HICON LoadIconEx(char *pszIcoLibName)
{
char szTemp[256];
mir_snprintf(szTemp, "chat_%s", pszIcoLibName);
- return Skin_GetIcon(szTemp);
+ return IcoLib_GetIcon(szTemp);
}
static void InitSetting(TCHAR* &ppPointer, const char *pszSetting, const TCHAR *pszDefault)
diff --git a/plugins/TabSRMM/src/chat/window.cpp b/plugins/TabSRMM/src/chat/window.cpp
index a597dac691..5af8dc4a6a 100644
--- a/plugins/TabSRMM/src/chat/window.cpp
+++ b/plugins/TabSRMM/src/chat/window.cpp
@@ -2186,7 +2186,7 @@ INT_PTR CALLBACK RoomWndProc(HWND hwndDlg, UINT uMsg, WPARAM wParam, LPARAM lPar
if (g_Settings.bShowContactStatus && g_Settings.bContactStatusFirst && ui->ContactStatus) {
HICON hIcon = LoadSkinnedProtoIcon(si->pszModule, ui->ContactStatus);
DrawIconEx(dis->hDC, x_offset, dis->rcItem.top + offset - 8, hIcon, 16, 16, 0, NULL, DI_NORMAL);
- Skin_ReleaseIcon(hIcon);
+ IcoLib_ReleaseIcon(hIcon);
x_offset += 18;
}
@@ -2210,7 +2210,7 @@ INT_PTR CALLBACK RoomWndProc(HWND hwndDlg, UINT uMsg, WPARAM wParam, LPARAM lPar
if (g_Settings.bShowContactStatus && !g_Settings.bContactStatusFirst && ui->ContactStatus) {
HICON hIcon = LoadSkinnedProtoIcon(si->pszModule, ui->ContactStatus);
DrawIconEx(dis->hDC, x_offset, dis->rcItem.top + offset - 8, hIcon, 16, 16, 0, NULL, DI_NORMAL);
- Skin_ReleaseIcon(hIcon);
+ IcoLib_ReleaseIcon(hIcon);
x_offset += 18;
}
diff --git a/plugins/TabSRMM/src/globals.cpp b/plugins/TabSRMM/src/globals.cpp
index d64543ff14..8d85c8e0bd 100644
--- a/plugins/TabSRMM/src/globals.cpp
+++ b/plugins/TabSRMM/src/globals.cpp
@@ -271,13 +271,13 @@ int CGlobals::TopToolbarLoaded(WPARAM, LPARAM)
ttb.pszService = MS_TABMSG_TRAYSUPPORT;
ttb.name = "TabSRMM session list";
ttb.pszTooltipUp = LPGEN("TabSRMM session list");
- ttb.hIconHandleUp = Skin_GetIcon("tabSRMM_sb_slist");
+ ttb.hIconHandleUp = IcoLib_GetIcon("tabSRMM_sb_slist");
TopToolbar_AddButton(&ttb);
ttb.name = "TabSRMM Menu";
ttb.pszTooltipUp = LPGEN("TabSRMM menu");
ttb.lParamUp = ttb.lParamDown = 1;
- ttb.hIconHandleUp = Skin_GetIcon("tabSRMM_container");
+ ttb.hIconHandleUp = IcoLib_GetIcon("tabSRMM_container");
TopToolbar_AddButton(&ttb);
return 0;
diff --git a/plugins/TabSRMM/src/msgs.cpp b/plugins/TabSRMM/src/msgs.cpp
index 4f2ee0568a..b9312fa29d 100644
--- a/plugins/TabSRMM/src/msgs.cpp
+++ b/plugins/TabSRMM/src/msgs.cpp
@@ -806,9 +806,9 @@ static int TSAPI SetupIconLibConfig()
sid.iDefaultIndex = ICONBLOCKS[n].idesc[i].uId == -IDI_HISTORY ? 0 : ICONBLOCKS[n].idesc[i].uId; // workaround problem /w icoLib and a resource id of 1 (actually, a Windows problem)
if (n > 0 && n < 4)
- PluginConfig.g_buttonBarIconHandles[j++] = Skin_AddIcon(&sid);
+ PluginConfig.g_buttonBarIconHandles[j++] = IcoLib_AddIcon(&sid);
else
- Skin_AddIcon(&sid);
+ IcoLib_AddIcon(&sid);
}
}
@@ -816,19 +816,19 @@ static int TSAPI SetupIconLibConfig()
sid.pszName = "tabSRMM_clock_symbol";
sid.description.a = LPGEN("Clock symbol (for the info panel clock)");
sid.iDefaultIndex = -IDI_CLOCK;
- Skin_AddIcon(&sid);
+ IcoLib_AddIcon(&sid);
_tcsncpy(szFilename, _T("plugins\\tabsrmm.dll"), MAX_PATH);
sid.pszName = "tabSRMM_overlay_disabled";
sid.description.a = LPGEN("Feature disabled (used as overlay)");
sid.iDefaultIndex = -IDI_FEATURE_DISABLED;
- Skin_AddIcon(&sid);
+ IcoLib_AddIcon(&sid);
sid.pszName = "tabSRMM_overlay_enabled";
sid.description.a = LPGEN("Feature enabled (used as overlay)");
sid.iDefaultIndex = -IDI_FEATURE_ENABLED;
- Skin_AddIcon(&sid);
+ IcoLib_AddIcon(&sid);
return 1;
}
@@ -838,7 +838,7 @@ static int TSAPI LoadFromIconLib()
{
for (int n = 0; n < SIZEOF(ICONBLOCKS); n++)
for (int i = 0; i < ICONBLOCKS[n].nItems; i++)
- *(ICONBLOCKS[n].idesc[i].phIcon) = Skin_GetIcon(ICONBLOCKS[n].idesc[i].szName);
+ *(ICONBLOCKS[n].idesc[i].phIcon) = IcoLib_GetIcon(ICONBLOCKS[n].idesc[i].szName);
PluginConfig.g_buttonBarIcons[0] = LoadSkinnedIcon(SKINICON_OTHER_ADDCONTACT);
PluginConfig.g_buttonBarIcons[1] = LoadSkinnedIcon(SKINICON_OTHER_HISTORY);
@@ -853,10 +853,10 @@ static int TSAPI LoadFromIconLib()
PluginConfig.g_IconGroupOpen = LoadSkinnedIcon(SKINICON_OTHER_GROUPOPEN);
PluginConfig.g_IconGroupClose = LoadSkinnedIcon(SKINICON_OTHER_GROUPSHUT);
- PluginConfig.g_iconOverlayEnabled = Skin_GetIcon("tabSRMM_overlay_enabled");
- PluginConfig.g_iconOverlayDisabled = Skin_GetIcon("tabSRMM_overlay_disabled");
+ PluginConfig.g_iconOverlayEnabled = IcoLib_GetIcon("tabSRMM_overlay_enabled");
+ PluginConfig.g_iconOverlayDisabled = IcoLib_GetIcon("tabSRMM_overlay_disabled");
- PluginConfig.g_iconClock = Skin_GetIcon("tabSRMM_clock_symbol");
+ PluginConfig.g_iconClock = IcoLib_GetIcon("tabSRMM_clock_symbol");
CacheMsgLogIcons();
M.BroadcastMessage(DM_LOADBUTTONBARICONS, 0, 0);
diff --git a/plugins/TipperYM/src/popwin.cpp b/plugins/TipperYM/src/popwin.cpp
index a40103b154..71094462ef 100644
--- a/plugins/TipperYM/src/popwin.cpp
+++ b/plugins/TipperYM/src/popwin.cpp
@@ -364,9 +364,9 @@ LRESULT CALLBACK PopupWindowProc(HWND hwnd, UINT uMsg, WPARAM wParam, LPARAM lPa
iGender = db_get_b(pwd->hContact, szProto, "Gender", 0);
if (iGender == GEN_FEMALE)
- pwd->extraIcons[i].hIcon = Skin_GetIcon("gender_female");
+ pwd->extraIcons[i].hIcon = IcoLib_GetIcon("gender_female");
else if (iGender == GEN_MALE)
- pwd->extraIcons[i].hIcon = Skin_GetIcon("gender_male");
+ pwd->extraIcons[i].hIcon = IcoLib_GetIcon("gender_male");
pwd->extraIcons[i].bDestroy = false;
}
@@ -935,7 +935,7 @@ LRESULT CALLBACK PopupWindowProc(HWND hwnd, UINT uMsg, WPARAM wParam, LPARAM lPa
if (pwd->extraIcons[i].bDestroy)
DestroyIcon(pwd->extraIcons[i].hIcon);
else
- Skin_ReleaseIcon(pwd->extraIcons[i].hIcon);
+ IcoLib_ReleaseIcon(pwd->extraIcons[i].hIcon);
}
mir_free(pwd->clcit.swzText);
diff --git a/plugins/TipperYM/src/subst.cpp b/plugins/TipperYM/src/subst.cpp
index 789621bfe9..4830e729d7 100644
--- a/plugins/TipperYM/src/subst.cpp
+++ b/plugins/TipperYM/src/subst.cpp
@@ -838,7 +838,7 @@ HICON GetJabberActivityIcon(MCONTACT hContact, char *szProto)
char szSetting[128];
mir_snprintf(szSetting, "%s/%s/%s", szProto, "activity", "icon");
if (!db_get_s(hContact, "AdvStatus", szSetting, &dbv)) {
- hIcon = Skin_GetIcon(dbv.pszVal);
+ hIcon = IcoLib_GetIcon(dbv.pszVal);
db_free(&dbv);
}
diff --git a/plugins/TopToolBar/src/toolbar.cpp b/plugins/TopToolBar/src/toolbar.cpp
index 0842ce95e3..d93abb0494 100644
--- a/plugins/TopToolBar/src/toolbar.cpp
+++ b/plugins/TopToolBar/src/toolbar.cpp
@@ -148,7 +148,7 @@ static void Icon2button(TTBButton *but, HANDLE &hIcoLib, HICON &hIcon, bool bIsU
return;
}
- hIcoLib = (HANDLE)CallService(MS_SKIN2_ISMANAGEDICON, WPARAM(hSrc), 0);
+ hIcoLib = IcoLib_IsManaged((HICON)hSrc);
if (!hIcoLib) {
char buf[256];
mir_snprintf(buf, "toptoolbar_%s%s", but->name, bIsUp ? (but->hIconDn ? "%s_up" : "%s") : "%s_dn");
@@ -160,10 +160,10 @@ static void Icon2button(TTBButton *but, HANDLE &hIcoLib, HICON &hIcon, bool bIsU
mir_snprintf(buf, "%s%s", but->name, bIsUp ? "" : " (pressed)");
sid.description.a = buf;
sid.hDefaultIcon = bIsUp ? but->hIconUp : but->hIconDn;
- hIcoLib = Skin_AddIcon(&sid);
+ hIcoLib = IcoLib_AddIcon(&sid);
}
- hIcon = Skin_GetIconByHandle(hIcoLib);
+ hIcon = IcoLib_GetIconByHandle(hIcoLib);
}
TopButtonInt *CreateButton(TTBButton *but)
@@ -516,12 +516,12 @@ int OnIconChange(WPARAM, LPARAM)
continue;
if (b->hIconHandleUp) {
- Skin_ReleaseIcon(b->hIconUp);
- b->hIconUp = Skin_GetIconByHandle(b->hIconHandleUp);
+ IcoLib_ReleaseIcon(b->hIconUp);
+ b->hIconUp = IcoLib_GetIconByHandle(b->hIconHandleUp);
}
if (b->hIconHandleDn) {
- Skin_ReleaseIcon(b->hIconDn);
- b->hIconDn = Skin_GetIconByHandle(b->hIconHandleDn);
+ IcoLib_ReleaseIcon(b->hIconDn);
+ b->hIconDn = IcoLib_GetIconByHandle(b->hIconHandleDn);
}
DestroyWindow(b->hwnd);
b->CreateWnd();
diff --git a/plugins/TopToolBar/src/ttbopt.cpp b/plugins/TopToolBar/src/ttbopt.cpp
index 2a4290323d..6f890d59aa 100644
--- a/plugins/TopToolBar/src/ttbopt.cpp
+++ b/plugins/TopToolBar/src/ttbopt.cpp
@@ -26,9 +26,9 @@ static HTREEITEM AddLine(HWND hTree,TopButtonInt *b, HTREEITEM hItem, HIMAGELIST
}
else {
if (b->hIconHandleUp) {
- HICON hIcon = Skin_GetIconByHandle(b->hIconHandleUp);
+ HICON hIcon = IcoLib_GetIconByHandle(b->hIconHandleUp);
index = ImageList_AddIcon(il, hIcon);
- Skin_ReleaseIcon(hIcon);
+ IcoLib_ReleaseIcon(hIcon);
}
else index = ImageList_AddIcon(il, b->hIconUp);
diff --git a/plugins/TranslitSwitcher/src/Layoutproc.cpp b/plugins/TranslitSwitcher/src/Layoutproc.cpp
index 541ae26732..cb0a760f49 100644
--- a/plugins/TranslitSwitcher/src/Layoutproc.cpp
+++ b/plugins/TranslitSwitcher/src/Layoutproc.cpp
@@ -428,7 +428,7 @@ void SwitchLayout(bool lastword)
CallService(MS_SMILEYADD_BATCHFREE, 0, (LPARAM)smileyPrs);
POPUPDATAT pd = { 0 };
- pd.lchIcon = Skin_GetIcon("Switch Layout and Send");
+ pd.lchIcon = IcoLib_GetIcon("Switch Layout and Send");
mir_tstrncpy(pd.lptzText, buf, SIZEOF(pd.lptzText));
mir_tstrncpy(pd.lptzContactName, TranslateT("TranslitSwitcher"), SIZEOF(pd.lptzContactName));
PUAddPopupT(&pd);
diff --git a/plugins/UserInfoEx/src/Flags/svc_flagsicons.cpp b/plugins/UserInfoEx/src/Flags/svc_flagsicons.cpp
index 1a9ebac3b0..efb5c18697 100644
--- a/plugins/UserInfoEx/src/Flags/svc_flagsicons.cpp
+++ b/plugins/UserInfoEx/src/Flags/svc_flagsicons.cpp
@@ -134,7 +134,7 @@ HICON LoadFlag(int countryNumber)
char szId[20];
mir_snprintf(szId, SIZEOF(szId), (countryNumber == 0xFFFF) ? "%s_0x%X" : "%s_%i", "flags", countryNumber); /* buffer safe */
- return Skin_GetIcon(szId);
+ return IcoLib_GetIcon(szId);
}
HANDLE LoadFlagHandle(int countryNumber)
@@ -403,7 +403,7 @@ void InitIcons()
sid.hDefaultIcon = ImageList_ExtractIcon(NULL, himl, index);
index = CountryNumberToIndex(countries[i].id);
- phIconHandles[index] = Skin_AddIcon(&sid);
+ phIconHandles[index] = IcoLib_AddIcon(&sid);
if (sid.hDefaultIcon!=NULL) DestroyIcon(sid.hDefaultIcon);
mir_free(sid.description.t); sid.description.t = NULL;
}
@@ -422,7 +422,7 @@ void UninitIcons()
/* create identifier */
char szId[20];
mir_snprintf(szId, SIZEOF(szId), (countries[i].id == 0xFFFF) ? "%s0x%X" : "%s%i", "flags_", countries[i].id); /* buffer safe */
- Skin_RemoveIcon(szId);
+ IcoLib_RemoveIcon(szId);
}
mir_free(phIconHandles); /* does NULL check */
}
diff --git a/plugins/UserInfoEx/src/classMAnnivDate.cpp b/plugins/UserInfoEx/src/classMAnnivDate.cpp
index 73fb57c38c..3b166e29b0 100644
--- a/plugins/UserInfoEx/src/classMAnnivDate.cpp
+++ b/plugins/UserInfoEx/src/classMAnnivDate.cpp
@@ -241,7 +241,7 @@ MZodiac MAnnivDate::Zodiac()
for (i = 0; i < 13 && (wDays < zodiac[i].startDays || wDays > zodiac[i].endDays); i++);
MZodiac mZodiac;
- mZodiac.hIcon = Skin_GetIcon(zodiac[i].szZodiacIcon);
+ mZodiac.hIcon = IcoLib_GetIcon(zodiac[i].szZodiacIcon);
mZodiac.pszName = zodiac[i].szZodiac;
return mZodiac;
}
@@ -692,7 +692,7 @@ static WORD AskUser(MCONTACT hContact, MAnnivDate *pOldCustomDate, MAnnivDate *p
MB.cbSize = sizeof(MSGBOX);
MB.hParent = NULL;
- MB.hiLogo = Skin_GetIcon(ICO_DLG_ANNIVERSARY);
+ MB.hiLogo = IcoLib_GetIcon(ICO_DLG_ANNIVERSARY);
MB.hiMsg = NULL;
MB.uType = MB_YESALLNO|MB_ICON_QUESTION|MB_INFOBAR|MB_NOPOPUP;
MB.ptszTitle = LPGENT("Update custom birthday");
diff --git a/plugins/UserInfoEx/src/classPsTreeItem.cpp b/plugins/UserInfoEx/src/classPsTreeItem.cpp
index 8882cc5cef..2231f7c157 100644
--- a/plugins/UserInfoEx/src/classPsTreeItem.cpp
+++ b/plugins/UserInfoEx/src/classPsTreeItem.cpp
@@ -282,7 +282,7 @@ HICON CPsTreeItem::ProtoIcon()
if (!mir_tcsnicmp(pa[i]->tszAccountName, _A2T(_pszName), mir_tstrlen(pa[i]->tszAccountName))) {
CHAR szIconID[MAX_PATH];
mir_snprintf(szIconID, SIZEOF(szIconID), "core_status_%s1", pa[i]->szModuleName);
- HICON hIco = Skin_GetIcon(szIconID);
+ HICON hIco = IcoLib_GetIcon(szIconID);
if (!hIco)
hIco = (HICON)CallProtoService(pa[i]->szModuleName, PS_LOADICON, PLI_PROTOCOL, NULL);
@@ -313,7 +313,7 @@ int CPsTreeItem::Icon(HIMAGELIST hIml, OPTIONSDIALOGPAGE *odp, BYTE bInitIconsOn
LPCSTR pszIconName = IconKey();
// use icolib to handle icons
- HICON hIcon = Skin_GetIcon(pszIconName);
+ HICON hIcon = IcoLib_GetIcon(pszIconName);
if (!hIcon) {
bool bNeedFree = false;
@@ -360,10 +360,10 @@ int CPsTreeItem::Icon(HIMAGELIST hIml, OPTIONSDIALOGPAGE *odp, BYTE bInitIconsOn
sid.hDefaultIcon = ImageList_GetIcon(hIml, 0, ILD_NORMAL), bNeedFree = true;
}
// add file to icolib
- Skin_AddIcon(&sid);
+ IcoLib_AddIcon(&sid);
if (!bInitIconsOnly)
- hIcon = Skin_GetIcon(pszIconName);
+ hIcon = IcoLib_GetIcon(pszIconName);
if (bNeedFree)
DestroyIcon(sid.hDefaultIcon);
}
@@ -600,7 +600,7 @@ void CPsTreeItem::OnIconsChanged(CPsTree *pTree)
RECT rc;
// update tree item icons
- if (pTree->ImageList() && (hIcon = Skin_GetIcon(IconKey())) != NULL) {
+ if (pTree->ImageList() && (hIcon = IcoLib_GetIcon(IconKey())) != NULL) {
_iImage = (_iImage > 0)
? ImageList_ReplaceIcon(pTree->ImageList(), _iImage, hIcon)
: ImageList_AddIcon(pTree->ImageList(), hIcon);
diff --git a/plugins/UserInfoEx/src/ctrl_button.cpp b/plugins/UserInfoEx/src/ctrl_button.cpp
index 45670de8a2..50ff993163 100644
--- a/plugins/UserInfoEx/src/ctrl_button.cpp
+++ b/plugins/UserInfoEx/src/ctrl_button.cpp
@@ -371,7 +371,7 @@ static LRESULT CALLBACK Button_WndProc(HWND hwndBtn, UINT uMsg, WPARAM wParam, L
bct->hFont = (HFONT)GetStockObject(DEFAULT_GUI_FONT);
bct->dwStyle = cs->style;
if (cs->style & MBS_DOWNARROW)
- bct->arrow = Skin_GetIcon(ICO_BTN_DOWNARROW);
+ bct->arrow = IcoLib_GetIcon(ICO_BTN_DOWNARROW);
LoadTheme(bct);
SetWindowLongPtr(hwndBtn, 0, (LONG_PTR)bct);
if (cs->lpszName) SetWindowText(hwndBtn, cs->lpszName);
diff --git a/plugins/UserInfoEx/src/ctrl_contact.cpp b/plugins/UserInfoEx/src/ctrl_contact.cpp
index ccc30ead81..bf4e43afd5 100644
--- a/plugins/UserInfoEx/src/ctrl_contact.cpp
+++ b/plugins/UserInfoEx/src/ctrl_contact.cpp
@@ -151,10 +151,10 @@ static INT_PTR CALLBACK DlgProc_EMail(HWND hDlg, UINT msg, WPARAM wParam, LPARAM
return FALSE;
SetUserData(hDlg, lParam);
- SendDlgItemMessage(hDlg, IDC_HEADERBAR, WM_SETICON, 0, (LPARAM)Skin_GetIcon(ICO_DLG_EMAIL, TRUE));
+ SendDlgItemMessage(hDlg, IDC_HEADERBAR, WM_SETICON, 0, (LPARAM)IcoLib_GetIcon(ICO_DLG_EMAIL, TRUE));
if (db_get_b(NULL, MODNAME, SET_ICONS_BUTTONS, 1)) {
- SendDlgItemMessage(hDlg, IDOK, BM_SETIMAGE, IMAGE_ICON, (LPARAM)Skin_GetIcon(ICO_BTN_OK));
- SendDlgItemMessage(hDlg, IDCANCEL, BM_SETIMAGE, IMAGE_ICON, (LPARAM)Skin_GetIcon(ICO_BTN_CANCEL));
+ SendDlgItemMessage(hDlg, IDOK, BM_SETIMAGE, IMAGE_ICON, (LPARAM)IcoLib_GetIcon(ICO_BTN_OK));
+ SendDlgItemMessage(hDlg, IDCANCEL, BM_SETIMAGE, IMAGE_ICON, (LPARAM)IcoLib_GetIcon(ICO_BTN_CANCEL));
}
if (*cbi->pszVal)
@@ -243,10 +243,10 @@ INT_PTR CALLBACK DlgProc_Phone(HWND hDlg, UINT msg, WPARAM wParam, LPARAM lParam
if (!cbi) return FALSE;
SetUserData(hDlg, lParam);
- SendDlgItemMessage(hDlg, IDC_HEADERBAR, WM_SETICON, 0, (LPARAM)Skin_GetIcon(ICO_DLG_PHONE, TRUE));
+ SendDlgItemMessage(hDlg, IDC_HEADERBAR, WM_SETICON, 0, (LPARAM)IcoLib_GetIcon(ICO_DLG_PHONE, TRUE));
if (db_get_b(NULL, MODNAME, SET_ICONS_BUTTONS, 1)) {
- SendDlgItemMessage(hDlg, IDOK, BM_SETIMAGE, IMAGE_ICON, (LPARAM)Skin_GetIcon(ICO_BTN_OK));
- SendDlgItemMessage(hDlg, IDCANCEL, BM_SETIMAGE, IMAGE_ICON, (LPARAM)Skin_GetIcon(ICO_BTN_CANCEL));
+ SendDlgItemMessage(hDlg, IDOK, BM_SETIMAGE, IMAGE_ICON, (LPARAM)IcoLib_GetIcon(ICO_BTN_OK));
+ SendDlgItemMessage(hDlg, IDCANCEL, BM_SETIMAGE, IMAGE_ICON, (LPARAM)IcoLib_GetIcon(ICO_BTN_CANCEL));
}
// translate Userinfo buttons
@@ -577,17 +577,17 @@ static LRESULT CALLBACK CtrlContactWndProc(HWND hwnd, UINT msg, WPARAM wParam, L
**/
case WM_SETICON:
{
- HICON hIcon = Skin_GetIcon(ICO_BTN_ADD);
+ HICON hIcon = IcoLib_GetIcon(ICO_BTN_ADD);
SendMessage(cbex->hBtnAdd, BM_SETIMAGE, IMAGE_ICON, (LPARAM)hIcon);
SetWindowText(cbex->hBtnAdd, (hIcon ? _T("") : _T("+")));
- hIcon = Skin_GetIcon(ICO_BTN_DELETE);
+ hIcon = IcoLib_GetIcon(ICO_BTN_DELETE);
SendMessage(cbex->hBtnDel, BM_SETIMAGE, IMAGE_ICON, (LPARAM)hIcon);
SetWindowText(cbex->hBtnDel, (hIcon ? _T("") : _T("-")));
if (cbex->pItems && cbex->numItems > 0) {
for (int i = 0; i < cbex->numItems; i++)
- cbex->pItems[i].hIcon = Skin_GetIcon(cbex->pItems[i].pszIcon);
+ cbex->pItems[i].hIcon = IcoLib_GetIcon(cbex->pItems[i].pszIcon);
if (cbex->iSelectedItem >= 0 && cbex->iSelectedItem < cbex->numItems)
SendMessage(cbex->hBtnEdit, BM_SETIMAGE, IMAGE_ICON, (LPARAM)cbex->pItems[cbex->iSelectedItem].hIcon);
@@ -786,7 +786,7 @@ static LRESULT CALLBACK CtrlContactWndProc(HWND hwnd, UINT msg, WPARAM wParam, L
}
mBox.cbSize = sizeof(MSGBOX);
mBox.hParent = hDlgDetails;
- mBox.hiLogo = Skin_GetIcon(ICO_DLG_PHONE);
+ mBox.hiLogo = IcoLib_GetIcon(ICO_DLG_PHONE);
mBox.uType = MB_YESNO|MB_ICON_QUESTION|MB_NOPOPUP;
mBox.ptszTitle = TranslateT("Delete");
mBox.ptszMsg = szMsg;
@@ -955,7 +955,7 @@ static LRESULT CALLBACK CtrlContactWndProc(HWND hwnd, UINT msg, WPARAM wParam, L
// set icon
if ((pItem->wMask & CBEXIM_ICONTEXT) && pItem->pszIcon) {
cbex->pItems[cbex->numItems].pszIcon = pItem->pszIcon;
- cbex->pItems[cbex->numItems].hIcon = Skin_GetIcon(pItem->pszIcon);
+ cbex->pItems[cbex->numItems].hIcon = IcoLib_GetIcon(pItem->pszIcon);
}
// set flags
cbex->pItems[cbex->numItems].wFlags = (pItem->wMask & CBEXIM_CAT) ? pItem->wFlags : 0;
@@ -1000,7 +1000,7 @@ static LRESULT CALLBACK CtrlContactWndProc(HWND hwnd, UINT msg, WPARAM wParam, L
// set icon
if ((pItem->wMask & CBEXIM_ICONTEXT) && pItem->pszIcon) {
cbex->pItems[pItem->iItem].pszIcon = pItem->pszIcon;
- cbex->pItems[pItem->iItem].hIcon = Skin_GetIcon(pItem->pszIcon);
+ cbex->pItems[pItem->iItem].hIcon = IcoLib_GetIcon(pItem->pszIcon);
if (pItem->iItem == cbex->iSelectedItem)
SendMessage(cbex->hBtnEdit, BM_SETIMAGE, IMAGE_ICON, (LPARAM)cbex->pItems[pItem->iItem].hIcon);
}
diff --git a/plugins/UserInfoEx/src/dlg_anniversarylist.cpp b/plugins/UserInfoEx/src/dlg_anniversarylist.cpp
index 9e433a4f30..2c698d806b 100644
--- a/plugins/UserInfoEx/src/dlg_anniversarylist.cpp
+++ b/plugins/UserInfoEx/src/dlg_anniversarylist.cpp
@@ -307,7 +307,7 @@ class CAnnivList
break;
// set icons
- hIcon = Skin_GetIcon(ICO_DLG_ANNIVERSARY);
+ hIcon = IcoLib_GetIcon(ICO_DLG_ANNIVERSARY);
SendDlgItemMessage(hDlg, IDC_HEADERBAR, WM_SETICON, 0, (LPARAM)hIcon);
SendMessage(hDlg, WM_SETICON, ICON_BIG, (LPARAM)hIcon);
@@ -962,7 +962,7 @@ void DlgAnniversaryListOnTopToolBarLoaded()
TTBButton ttb = { sizeof(ttb) };
ttb.dwFlags = TTBBF_VISIBLE | TTBBF_SHOWTOOLTIP;
ttb.pszService = MS_USERINFO_REMINDER_LIST;
- ttb.hIconHandleUp = Skin_GetIconHandle(ICO_COMMON_ANNIVERSARY);
+ ttb.hIconHandleUp = IcoLib_GetIconHandle(ICO_COMMON_ANNIVERSARY);
ttb.name = ttb.pszTooltipUp = LPGEN("Anniversary list");
TopToolbar_AddButton(&ttb);
}
diff --git a/plugins/UserInfoEx/src/dlg_msgbox.cpp b/plugins/UserInfoEx/src/dlg_msgbox.cpp
index e401c411f9..aa3793c929 100644
--- a/plugins/UserInfoEx/src/dlg_msgbox.cpp
+++ b/plugins/UserInfoEx/src/dlg_msgbox.cpp
@@ -108,53 +108,53 @@ static void MakePopupAction(POPUPACTION &pa, int id)
switch (id) {
case IDOK:
- pa.lchIcon = Skin_GetIcon(ICO_BTN_OK);
+ pa.lchIcon = IcoLib_GetIcon(ICO_BTN_OK);
mir_strcpy(pa.lpzTitle, MODNAME"/Ok");
break;
case IDCLOSE:
case IDCANCEL:
- pa.lchIcon = Skin_GetIcon(ICO_BTN_CANCEL);
+ pa.lchIcon = IcoLib_GetIcon(ICO_BTN_CANCEL);
mir_strcpy(pa.lpzTitle, MODNAME"/Cancel");
break;
case IDABORT:
- pa.lchIcon = Skin_GetIcon(ICO_BTN_CANCEL);
+ pa.lchIcon = IcoLib_GetIcon(ICO_BTN_CANCEL);
mir_strcpy(pa.lpzTitle, MODNAME"/Abort");
break;
case IDRETRY:
- pa.lchIcon = Skin_GetIcon(ICO_BTN_UPDATE);
+ pa.lchIcon = IcoLib_GetIcon(ICO_BTN_UPDATE);
mir_strcpy(pa.lpzTitle, MODNAME"/Retry");
break;
case IDIGNORE:
- pa.lchIcon = Skin_GetIcon(ICO_BTN_OK);
+ pa.lchIcon = IcoLib_GetIcon(ICO_BTN_OK);
mir_strcpy(pa.lpzTitle, MODNAME"/Ignore");
break;
case IDYES:
- pa.lchIcon = Skin_GetIcon(ICO_BTN_OK);
+ pa.lchIcon = IcoLib_GetIcon(ICO_BTN_OK);
mir_strcpy(pa.lpzTitle, MODNAME"/Yes");
break;
case IDNO:
- pa.lchIcon = Skin_GetIcon(ICO_BTN_CANCEL);
+ pa.lchIcon = IcoLib_GetIcon(ICO_BTN_CANCEL);
mir_strcpy(pa.lpzTitle, MODNAME"/No");
break;
case IDHELP:
- pa.lchIcon = Skin_GetIcon(ICO_BTN_CANCEL);
+ pa.lchIcon = IcoLib_GetIcon(ICO_BTN_CANCEL);
mir_strcpy(pa.lpzTitle, MODNAME"/Help");
break;
case IDALL:
- pa.lchIcon = Skin_GetIcon(ICO_BTN_OK);
+ pa.lchIcon = IcoLib_GetIcon(ICO_BTN_OK);
mir_strcpy(pa.lpzTitle, MODNAME"/All");
break;
case IDNONE:
- pa.lchIcon = Skin_GetIcon(ICO_BTN_CANCEL);
+ pa.lchIcon = IcoLib_GetIcon(ICO_BTN_CANCEL);
mir_strcpy(pa.lpzTitle, MODNAME"/None");
}
}
@@ -199,7 +199,7 @@ static INT_PTR CALLBACK MsgBoxProc(HWND hDlg, UINT uMsg, WPARAM wParam, LPARAM l
// set infobar's logo icon
SendDlgItemMessage(hDlg, ICO_DLGLOGO, STM_SETIMAGE, IMAGE_ICON,
- (pMsgBox->hiLogo ? (LPARAM)pMsgBox->hiLogo : (LPARAM)Skin_GetIcon(ICO_DLG_DETAILS,TRUE)));
+ (pMsgBox->hiLogo ? (LPARAM)pMsgBox->hiLogo : (LPARAM)IcoLib_GetIcon(ICO_DLG_DETAILS,TRUE)));
// enable headerbar
ShowWindow(GetDlgItem(hDlg, TXT_NAME), SW_SHOW);
@@ -671,7 +671,7 @@ INT_PTR CALLBACK MsgBox(HWND hParent, UINT uType, LPCTSTR pszTitle, LPCTSTR pszI
MSGBOX mb = { 0 };
mb.cbSize = sizeof(MSGBOX);
mb.hParent = hParent;
- mb.hiLogo = Skin_GetIcon(ICO_COMMON_MAIN);
+ mb.hiLogo = IcoLib_GetIcon(ICO_COMMON_MAIN);
mb.hiMsg = NULL;
mb.ptszTitle = TranslateTS(pszTitle);
mb.ptszInfoText = TranslateTS(pszInfo);
@@ -698,7 +698,7 @@ INT_PTR CALLBACK MsgErr(HWND hParent, LPCTSTR pszFormat, ...)
MSGBOX mb = {0};
mb.cbSize = sizeof(MSGBOX);
mb.hParent = hParent;
- mb.hiLogo = Skin_GetIcon(ICO_COMMON_MAIN);
+ mb.hiLogo = IcoLib_GetIcon(ICO_COMMON_MAIN);
mb.hiMsg = NULL;
mb.ptszTitle = tszTitle;
mb.ptszMsg = tszMsg;
diff --git a/plugins/UserInfoEx/src/dlg_propsheet.cpp b/plugins/UserInfoEx/src/dlg_propsheet.cpp
index 16174e982b..cda3ae98e7 100644
--- a/plugins/UserInfoEx/src/dlg_propsheet.cpp
+++ b/plugins/UserInfoEx/src/dlg_propsheet.cpp
@@ -273,7 +273,7 @@ static INT_PTR ShowDialog(WPARAM wParam, LPARAM lParam)
return 1;
}
- HICON hDefIcon = Skin_GetIcon(ICO_TREE_DEFAULT);
+ HICON hDefIcon = IcoLib_GetIcon(ICO_TREE_DEFAULT);
if (!hDefIcon)
hDefIcon = (HICON)LoadImage(ghInst, MAKEINTRESOURCE(IDI_DEFAULT), IMAGE_ICON, metrics.x, metrics.y, 0);
@@ -551,7 +551,7 @@ void DlgContactInfoInitTreeIcons()
metrics.x = GetSystemMetrics(SM_CXSMICON);
metrics.y = GetSystemMetrics(SM_CYSMICON);
if (psh._hImages = ImageList_Create(metrics.x, metrics.y, ILC_COLOR32 | ILC_MASK, 0, 1)) {
- HICON hDefIcon = Skin_GetIcon(ICO_TREE_DEFAULT);
+ HICON hDefIcon = IcoLib_GetIcon(ICO_TREE_DEFAULT);
if (!hDefIcon)
hDefIcon = (HICON)LoadImage(ghInst, MAKEINTRESOURCE(IDI_DEFAULT), IMAGE_ICON, metrics.x, metrics.y, 0);
@@ -715,8 +715,8 @@ static INT_PTR CALLBACK DlgProc(HWND hDlg, UINT uMsg, WPARAM wParam, LPARAM lPar
ShowWindow(GetDlgItem(hDlg, IDC_PAGETITLEBG2), !IsAeroMode());
// set icons
- SendMessage(hDlg, WM_SETICON, ICON_SMALL, (LPARAM)Skin_GetIcon(ICO_COMMON_MAIN));
- SendMessage(hDlg, WM_SETICON, ICON_BIG, (LPARAM)Skin_GetIcon(ICO_COMMON_MAIN, 32));
+ SendMessage(hDlg, WM_SETICON, ICON_SMALL, (LPARAM)IcoLib_GetIcon(ICO_COMMON_MAIN));
+ SendMessage(hDlg, WM_SETICON, ICON_BIG, (LPARAM)IcoLib_GetIcon(ICO_COMMON_MAIN, 32));
DlgProc(hDlg, HM_RELOADICONS, NULL, NULL);
// load basic protocol for current contact (for faster load later on and better handling for owner protocol)
@@ -1144,12 +1144,12 @@ static INT_PTR CALLBACK DlgProc(HWND hDlg, UINT uMsg, WPARAM wParam, LPARAM lPar
IcoLib_SetCtrlIcons(hDlg, idIcon, numIconsToSet);
if (hCtrl = GetDlgItem(hDlg, BTN_IMPORT)) {
- hIcon = Skin_GetIcon(ICO_BTN_IMPORT);
+ hIcon = IcoLib_GetIcon(ICO_BTN_IMPORT);
SendMessage(hCtrl, BM_SETIMAGE, IMAGE_ICON, (LPARAM)hIcon);
SetWindowText(hCtrl, hIcon ? _T("") : _T("I"));
}
if (hCtrl = GetDlgItem(hDlg, BTN_EXPORT)) {
- hIcon = Skin_GetIcon(ICO_BTN_EXPORT);
+ hIcon = IcoLib_GetIcon(ICO_BTN_EXPORT);
SendMessage(hCtrl, BM_SETIMAGE, IMAGE_ICON, (LPARAM)hIcon);
SetWindowText(hCtrl, hIcon ? _T("") : _T("E"));
}
diff --git a/plugins/UserInfoEx/src/ex_import/dlg_ExImModules.cpp b/plugins/UserInfoEx/src/ex_import/dlg_ExImModules.cpp
index a2617a0db1..682110ae8a 100644
--- a/plugins/UserInfoEx/src/ex_import/dlg_ExImModules.cpp
+++ b/plugins/UserInfoEx/src/ex_import/dlg_ExImModules.cpp
@@ -187,8 +187,8 @@ INT_PTR CALLBACK SelectModulesToExport_DlgProc(HWND hDlg, UINT uMsg, WPARAM wPar
SendMessage(hTree, TVM_SETIMAGELIST, TVSIL_NORMAL, (LPARAM)hImages);
bImagesLoaded
- = ((((hIcon = Skin_GetIcon(ICO_LST_MODULES)) != NULL) && 0 == ImageList_AddIcon(hImages, hIcon))
- && (((hIcon = Skin_GetIcon(ICO_LST_FOLDER)) != NULL) && 1 == ImageList_AddIcon(hImages, hIcon)));
+ = ((((hIcon = IcoLib_GetIcon(ICO_LST_MODULES)) != NULL) && 0 == ImageList_AddIcon(hImages, hIcon))
+ && (((hIcon = IcoLib_GetIcon(ICO_LST_FOLDER)) != NULL) && 1 == ImageList_AddIcon(hImages, hIcon)));
}
}
// do the translation stuff
diff --git a/plugins/UserInfoEx/src/mir_icolib.cpp b/plugins/UserInfoEx/src/mir_icolib.cpp
index 2154abdc46..ecdaafe2d1 100644
--- a/plugins/UserInfoEx/src/mir_icolib.cpp
+++ b/plugins/UserInfoEx/src/mir_icolib.cpp
@@ -186,7 +186,7 @@ static void IcoLib_CheckIconPackVersion(LPTSTR szIconPack)
void IcoLib_SetCtrlIcons(HWND hDlg, const ICONCTRL *pCtrl, BYTE numCtrls)
{
for (int i = 0; i < numCtrls; i++) {
- HICON hIcon = Skin_GetIcon(pCtrl[i].pszIcon);
+ HICON hIcon = IcoLib_GetIcon(pCtrl[i].pszIcon);
if (pCtrl[i].idCtrl) {
HWND hCtrl = GetDlgItem(hDlg, pCtrl[i].idCtrl);
switch (pCtrl[i].Message) {
@@ -259,7 +259,7 @@ static HANDLE IcoLib_RegisterIconHandleEx(LPSTR szIconID, LPSTR szDescription, L
sid.hDefaultIcon = hDefIcon;
sid.iDefaultIndex = -1;
}
- hIconHandle = Skin_AddIcon(&sid);
+ hIconHandle = IcoLib_AddIcon(&sid);
}
MIR_FREE(sid.description.t);
MIR_FREE(sid.section.t);
@@ -304,7 +304,7 @@ HANDLE IcoLib_RegisterIconHandle(LPSTR szIconID, LPSTR szDescription, LPSTR szSe
**/
HICON IcoLib_RegisterIcon(LPSTR szIconID, LPSTR szDescription, LPSTR szSection, int idIcon, int Size)
{
- return Skin_GetIconByHandle(IcoLib_RegisterIconHandle(szIconID, szDescription, szSection, idIcon, Size));
+ return IcoLib_GetIconByHandle(IcoLib_RegisterIconHandle(szIconID, szDescription, szSection, idIcon, Size));
}
/**
diff --git a/plugins/UserInfoEx/src/mir_menuitems.cpp b/plugins/UserInfoEx/src/mir_menuitems.cpp
index 1a60f3a48d..08b486726b 100644
--- a/plugins/UserInfoEx/src/mir_menuitems.cpp
+++ b/plugins/UserInfoEx/src/mir_menuitems.cpp
@@ -99,7 +99,7 @@ void RebuildContact()
//cascade all
mi.position = 1000050000;
mi.popupPosition = 1000050000;
- mi.hIcon = Skin_GetIcon(ICO_COMMON_MAIN);
+ mi.hIcon = IcoLib_GetIcon(ICO_COMMON_MAIN);
mi.pszName = MODULELONGNAME;
mhRoot = Menu_AddContactMenuItem(&mi);
hMenuItem[item++] = mhRoot;
@@ -109,7 +109,7 @@ void RebuildContact()
//cascade Ex/Import
mi.position = 1000050100;
mi.popupPosition = 1000050100;
- mi.hIcon = Skin_GetIcon(ICO_BTN_EXIMPORT);
+ mi.hIcon = IcoLib_GetIcon(ICO_BTN_EXIMPORT);
mi.pszName = LPGEN("Export/import contact");
mhExIm = Menu_AddContactMenuItem(&mi);
hMenuItem[item++] = mhExIm;
@@ -127,7 +127,7 @@ void RebuildContact()
mi.pszService = MS_USERINFO_SHOWDIALOG;
mi.pszName = LPGEN("User &details");
mi.position = 1000050000;
- mi.hIcon = Skin_GetIcon(ICO_COMMON_MAIN);
+ mi.hIcon = IcoLib_GetIcon(ICO_COMMON_MAIN);
mi.hotKey = MAKELPARAM(VK_F3, MOD_ALT);
hMenuItem[item++] = Menu_AddContactMenuItem(&mi);
mi.hotKey = NULL;
@@ -141,14 +141,14 @@ void RebuildContact()
mi.pszService = MS_USERINFO_VCARD_EXPORT;
mi.pszName = mhExIm != HGENMENU_ROOT ? LPGEN("&Export") : LPGEN("&Export user details");
mi.position = 1000050200;
- mi.hIcon = Skin_GetIcon(ICO_BTN_EXPORT);
+ mi.hIcon = IcoLib_GetIcon(ICO_BTN_EXPORT);
hMenuItem[item++] = Menu_AddContactMenuItem(&mi);
// Import
mi.pszService = MS_USERINFO_VCARD_IMPORT;
mi.pszName = mhExIm != HGENMENU_ROOT ? LPGEN("&Import") : LPGEN("&Import user details");
mi.position = 1000050300;
- mi.hIcon = Skin_GetIcon(ICO_BTN_IMPORT);
+ mi.hIcon = IcoLib_GetIcon(ICO_BTN_IMPORT);
hMenuItem[item++] = Menu_AddContactMenuItem(&mi);
}
}
@@ -196,7 +196,7 @@ void RebuildMain()
//cascade all
mi.position = 500050000;
mi.popupPosition = 500050000;
- mi.hIcon = Skin_GetIcon(ICO_COMMON_MAIN);
+ mi.hIcon = IcoLib_GetIcon(ICO_COMMON_MAIN);
mi.pszName = MODULELONGNAME;
mhRoot = Menu_AddMainMenuItem(&mi);
hMenuItem[item++] = mhRoot;
@@ -206,7 +206,7 @@ void RebuildMain()
//cascade Ex/Import
mi.position = 500050000;
mi.popupPosition = 500050000;
- mi.hIcon = Skin_GetIcon(ICO_BTN_EXIMPORT);
+ mi.hIcon = IcoLib_GetIcon(ICO_BTN_EXIMPORT);
mi.pszName = LPGEN("Export/import contact");
mhExIm = Menu_AddMainMenuItem(&mi);
hMenuItem[item++] = mhExIm;
@@ -224,7 +224,7 @@ void RebuildMain()
mi.pszService = MS_USERINFO_SHOWDIALOG;
mi.pszName = LPGEN("View/change my &details...");
mi.position = 500050000;
- mi.hIcon = Skin_GetIcon(ICO_COMMON_MAIN);
+ mi.hIcon = IcoLib_GetIcon(ICO_COMMON_MAIN);
hMenuItem[item++] = Menu_AddMainMenuItem(&mi);
}
@@ -235,14 +235,14 @@ void RebuildMain()
mi.pszService = MS_USERINFO_VCARD_EXPORTALL;
mi.pszName = LPGEN("Export all contacts");
mi.position = 500150000;
- mi.hIcon = Skin_GetIcon(ICO_BTN_EXPORT);
+ mi.hIcon = IcoLib_GetIcon(ICO_BTN_EXPORT);
hMenuItem[item++] = Menu_AddMainMenuItem(&mi);
// Import
mi.pszService = MS_USERINFO_VCARD_IMPORTALL;
mi.pszName = LPGEN("Import all contacts");
mi.position = 500151000;
- mi.hIcon = Skin_GetIcon(ICO_BTN_IMPORT);
+ mi.hIcon = IcoLib_GetIcon(ICO_BTN_IMPORT);
hMenuItem[item++] = Menu_AddMainMenuItem(&mi);
}
@@ -258,13 +258,13 @@ void RebuildMain()
mi.pszService = MS_USERINFO_REMINDER_AGGRASIVEBACKUP;
mi.pszName = LPGEN("Backup birthdays");
mi.position = 500253000;
- mi.hIcon = Skin_GetIcon(ICO_BTN_BDAY_BACKUP);
+ mi.hIcon = IcoLib_GetIcon(ICO_BTN_BDAY_BACKUP);
hMenuItem[item++] = Menu_AddMainMenuItem(&mi);
// Check anniversaries
mi.pszService = MS_USERINFO_REMINDER_CHECK;
mi.pszName = LPGEN("Check anniversaries");
mi.position = 500251000;
- mi.hIcon = Skin_GetIcon(ICO_BTN_SEARCH);
+ mi.hIcon = IcoLib_GetIcon(ICO_BTN_SEARCH);
hMenuItem[item++] = Menu_AddMainMenuItem(&mi);
}
else {
@@ -275,7 +275,7 @@ void RebuildMain()
mi.pszService = MS_USERINFO_REFRESH;
mi.pszName = LPGEN("Refresh contact details");
mi.position = 500254000;
- mi.hIcon = Skin_GetIcon(ICO_BTN_UPDATE);
+ mi.hIcon = IcoLib_GetIcon(ICO_BTN_UPDATE);
hMenuItem[item++] = Menu_AddMainMenuItem(&mi);
}
@@ -284,7 +284,7 @@ void RebuildMain()
mi.pszService = MS_USERINFO_REMINDER_LIST;
mi.pszName = LPGEN("Anniversary list");
mi.position = 500252000;
- mi.hIcon = Skin_GetIcon(ICO_COMMON_ANNIVERSARY);
+ mi.hIcon = IcoLib_GetIcon(ICO_COMMON_ANNIVERSARY);
hMenuItem[item++] = Menu_AddMainMenuItem(&mi);
}
}
@@ -341,7 +341,7 @@ void RebuildGroup()
//cascade all
mi.position = 250000;
mi.popupPosition = 250000;
- mi.hIcon = Skin_GetIcon(ICO_COMMON_MAIN);
+ mi.hIcon = IcoLib_GetIcon(ICO_COMMON_MAIN);
mi.pszName = MODULELONGNAME;
mhRoot = Menu_AddGroupMenuItem(0, &mi);
hMenuItem[item++] = mhRoot;
@@ -351,7 +351,7 @@ void RebuildGroup()
//cascade Ex/Import
mi.position = 250100;
mi.popupPosition = 250100;
- mi.hIcon = Skin_GetIcon(ICO_BTN_EXIMPORT);
+ mi.hIcon = IcoLib_GetIcon(ICO_BTN_EXIMPORT);
mi.pszName = LPGEN("Export/import contact");
mhExIm = Menu_AddGroupMenuItem(0, &mi);
hMenuItem[item++] = mhExIm;
@@ -370,14 +370,14 @@ void RebuildGroup()
mi.pszService = MS_USERINFO_VCARD_EXPORTALL;
mi.pszName = LPGEN("Export all contacts");
mi.position = 250200;
- mi.hIcon = Skin_GetIcon(ICO_BTN_EXPORT);
+ mi.hIcon = IcoLib_GetIcon(ICO_BTN_EXPORT);
hMenuItem[item++] = Menu_AddGroupMenuItem(0, &mi);
// Import
mi.pszService = MS_USERINFO_VCARD_IMPORTALL;
mi.pszName = LPGEN("Import all contacts");
mi.position = 250300;
- mi.hIcon = Skin_GetIcon(ICO_BTN_IMPORT);
+ mi.hIcon = IcoLib_GetIcon(ICO_BTN_IMPORT);
hMenuItem[item++] = Menu_AddGroupMenuItem(0, &mi);
}
}
@@ -438,7 +438,7 @@ void RebuildSubGroup()
//cascade all
mi.position = 1050000;
mi.popupPosition = 1050000;
- mi.hIcon = Skin_GetIcon(ICO_COMMON_MAIN);
+ mi.hIcon = IcoLib_GetIcon(ICO_COMMON_MAIN);
mi.pszName = MODULELONGNAME;
mhRoot = Menu_AddSubGroupMenuItem(0, &mi);
hMenuItem[item++] = mhRoot;
@@ -448,7 +448,7 @@ void RebuildSubGroup()
//cascade Ex/Import
mi.position = 1050100;
mi.popupPosition = 1050100;
- mi.hIcon = Skin_GetIcon(ICO_BTN_EXIMPORT);
+ mi.hIcon = IcoLib_GetIcon(ICO_BTN_EXIMPORT);
mi.pszName = LPGEN("Export/import group");
mhExIm = Menu_AddSubGroupMenuItem(0, &mi);
hMenuItem[item++] = mhExIm;
@@ -468,7 +468,7 @@ void RebuildSubGroup()
if (!ServiceExists(mi.pszService)) CreateServiceFunction(mi.pszService, svcExIm_Group_Service);
mi.pszName = mhExIm != HGENMENU_ROOT ? LPGEN("&Export") : LPGEN("&Export group");
mi.position = 1050200;
- mi.hIcon = Skin_GetIcon(ICO_BTN_EXPORT);
+ mi.hIcon = IcoLib_GetIcon(ICO_BTN_EXPORT);
gmp.lParam=0;
gmp.wParam=TRUE;
hMenuItem[item++] = Menu_AddSubGroupMenuItem(&gmp, &mi);
@@ -478,7 +478,7 @@ void RebuildSubGroup()
if (!ServiceExists(mi.pszService)) CreateServiceFunction(mi.pszService, svcExIm_Group_Service);
mi.pszName = mhExIm != HGENMENU_ROOT ? LPGEN("&Import") : LPGEN("&Import group");
mi.position = 1050300;
- mi.hIcon = Skin_GetIcon(ICO_BTN_IMPORT);
+ mi.hIcon = IcoLib_GetIcon(ICO_BTN_IMPORT);
gmp.lParam=0;
gmp.wParam=FALSE;
hMenuItem[item++] = Menu_AddSubGroupMenuItem(&gmp, &mi);
@@ -568,7 +568,7 @@ INT_PTR RebuildAccount(WPARAM wParam, LPARAM lParam)
case 5:
//cascade all
mi.position = 50100;
- mi.hIcon = Skin_GetIcon(ICO_COMMON_MAIN);
+ mi.hIcon = IcoLib_GetIcon(ICO_COMMON_MAIN);
mi.pszName = MODULELONGNAME;
hMenuItemAccount[mItems*i + item] = Menu_AddStatusMenuItem(&mi);
mhRoot = hMenuItemAccount[mItems*i + item++];
@@ -577,7 +577,7 @@ INT_PTR RebuildAccount(WPARAM wParam, LPARAM lParam)
case 9:
//cascade Ex/Import
mi.position = 50100;
- mi.hIcon = Skin_GetIcon(ICO_BTN_EXIMPORT);
+ mi.hIcon = IcoLib_GetIcon(ICO_BTN_EXIMPORT);
mi.pszName = LPGEN("Export/import");
hMenuItemAccount[mItems*i + item] = Menu_AddStatusMenuItem(&mi);
mhRoot = hMenuItemAccount[mItems*i + item++];
@@ -597,7 +597,7 @@ INT_PTR RebuildAccount(WPARAM wParam, LPARAM lParam)
if (!ServiceExists(mi.pszService)) CreateServiceFunction(mi.pszService, svcExIm_Account_Service);
mi.pszName = LPGEN("&Export xml");
mi.position = 50200;
- mi.hIcon = Skin_GetIcon(ICO_BTN_EXPORT);
+ mi.hIcon = IcoLib_GetIcon(ICO_BTN_EXPORT);
hMenuItemAccount[mItems*i + item++] = Menu_AddStatusMenuItem(&mi);
// Import
@@ -605,7 +605,7 @@ INT_PTR RebuildAccount(WPARAM wParam, LPARAM lParam)
if (!ServiceExists(mi.pszService)) CreateServiceFunction(mi.pszService, svcExIm_Account_Service);
mi.pszName = LPGEN("&Import xml");
mi.position = 50300;
- mi.hIcon = Skin_GetIcon(ICO_BTN_IMPORT);
+ mi.hIcon = IcoLib_GetIcon(ICO_BTN_IMPORT);
hMenuItemAccount[mItems*i + item++] = Menu_AddStatusMenuItem(&mi);
}
}
diff --git a/plugins/UserInfoEx/src/psp_anniversary.cpp b/plugins/UserInfoEx/src/psp_anniversary.cpp
index 44fa7e62e3..b4b90ae57b 100644
--- a/plugins/UserInfoEx/src/psp_anniversary.cpp
+++ b/plugins/UserInfoEx/src/psp_anniversary.cpp
@@ -45,10 +45,10 @@ static INT_PTR CALLBACK DlgProc_AnniversaryEditor(HWND hDlg, UINT uMsg, WPARAM w
// set icons
if (db_get_b(NULL, MODNAME, SET_ICONS_BUTTONS, 1)) {
- SendDlgItemMessage(hDlg, IDOK, BM_SETIMAGE, IMAGE_ICON, (LPARAM)Skin_GetIcon(ICO_BTN_OK));
- SendDlgItemMessage(hDlg, IDCANCEL, BM_SETIMAGE, IMAGE_ICON, (LPARAM)Skin_GetIcon(ICO_BTN_CANCEL));
+ SendDlgItemMessage(hDlg, IDOK, BM_SETIMAGE, IMAGE_ICON, (LPARAM)IcoLib_GetIcon(ICO_BTN_OK));
+ SendDlgItemMessage(hDlg, IDCANCEL, BM_SETIMAGE, IMAGE_ICON, (LPARAM)IcoLib_GetIcon(ICO_BTN_CANCEL));
}
- SendDlgItemMessage(hDlg, IDC_HEADERBAR, WM_SETICON, 0, (LPARAM)Skin_GetIcon(ICO_DLG_ANNIVERSARY, TRUE));
+ SendDlgItemMessage(hDlg, IDC_HEADERBAR, WM_SETICON, 0, (LPARAM)IcoLib_GetIcon(ICO_DLG_ANNIVERSARY, TRUE));
// translate controls
SendDlgItemMessage(hDlg, IDOK, BUTTONTRANSLATE, NULL, NULL);
diff --git a/plugins/UserInfoEx/src/psp_base.cpp b/plugins/UserInfoEx/src/psp_base.cpp
index 6ea57ed3b6..eda25cd133 100644
--- a/plugins/UserInfoEx/src/psp_base.cpp
+++ b/plugins/UserInfoEx/src/psp_base.cpp
@@ -26,7 +26,7 @@ void UpDate_CountryIcon(HWND hCtrl, int countryID)
HICON hIcon = LoadFlagIcon(countryID);
HICON hOld = Static_SetIcon(hCtrl, hIcon);
ShowWindow(hCtrl, hIcon ? SW_SHOW : SW_HIDE);
- Skin_ReleaseIcon(hOld);
+ IcoLib_ReleaseIcon(hOld);
}
// Default dialog procedure, which handles common functions
diff --git a/plugins/UserInfoEx/src/psp_contact.cpp b/plugins/UserInfoEx/src/psp_contact.cpp
index 265a8ce014..089f4239c8 100644
--- a/plugins/UserInfoEx/src/psp_contact.cpp
+++ b/plugins/UserInfoEx/src/psp_contact.cpp
@@ -125,11 +125,11 @@ INT_PTR CALLBACK PSPProcContactHome(HWND hDlg, UINT uMsg, WPARAM wParam, LPARAM
case PSN_ICONCHANGED:
{
- HICON hIcon = Skin_GetIcon(ICO_BTN_GOTO);
+ HICON hIcon = IcoLib_GetIcon(ICO_BTN_GOTO);
SendDlgItemMessage(hDlg, BTN_GOTO, BM_SETIMAGE, IMAGE_ICON, (LPARAM)hIcon);
SetDlgItemText(hDlg, BTN_GOTO, hIcon ? _T("") : _T("->"));
- hIcon = Skin_GetIcon(ICO_COMMON_ADDRESS);
+ hIcon = IcoLib_GetIcon(ICO_COMMON_ADDRESS);
SendDlgItemMessage(hDlg, ICO_ADDRESS, STM_SETIMAGE, IMAGE_ICON, (LPARAM)hIcon);
ShowWindow(GetDlgItem(hDlg, ICO_ADDRESS), hIcon ? SW_SHOW : SW_HIDE);
@@ -270,11 +270,11 @@ INT_PTR CALLBACK PSPProcContactWork(HWND hDlg, UINT uMsg, WPARAM wParam, LPARAM
case PSN_ICONCHANGED:
{
- HICON hIcon = Skin_GetIcon(ICO_BTN_GOTO);
+ HICON hIcon = IcoLib_GetIcon(ICO_BTN_GOTO);
SendDlgItemMessage(hDlg, BTN_GOTO, BM_SETIMAGE, IMAGE_ICON, (LPARAM)hIcon);
SetDlgItemText(hDlg, BTN_GOTO, hIcon ? _T("") : _T("->"));
- hIcon = Skin_GetIcon(ICO_COMMON_ADDRESS);
+ hIcon = IcoLib_GetIcon(ICO_COMMON_ADDRESS);
SendDlgItemMessage(hDlg, ICO_ADDRESS, STM_SETIMAGE, IMAGE_ICON, (LPARAM)hIcon);
ShowWindow(GetDlgItem(hDlg, ICO_ADDRESS), hIcon ? SW_SHOW : SW_HIDE);
diff --git a/plugins/UserInfoEx/src/psp_options.cpp b/plugins/UserInfoEx/src/psp_options.cpp
index 7f490cfae8..2d0b2c20c0 100644
--- a/plugins/UserInfoEx/src/psp_options.cpp
+++ b/plugins/UserInfoEx/src/psp_options.cpp
@@ -596,7 +596,7 @@ static INT_PTR CALLBACK DlgProc_ReminderOpts(HWND hDlg, UINT uMsg, WPARAM wParam
TranslateDialogDefault(hDlg);
ShowWindow(GetDlgItem(hDlg, CHECK_REMIND_SECURED), myGlobals.UseDbxTree ? SW_HIDE : SW_SHOW);
- SendDlgItemMessage(hDlg, ICO_BIRTHDAY, STM_SETIMAGE, IMAGE_ICON, (LPARAM)Skin_GetIcon(ICO_DLG_ANNIVERSARY, TRUE));
+ SendDlgItemMessage(hDlg, ICO_BIRTHDAY, STM_SETIMAGE, IMAGE_ICON, (LPARAM)IcoLib_GetIcon(ICO_DLG_ANNIVERSARY, TRUE));
// set colours
SendDlgItemMessage(hDlg, EDIT_REMIND, EM_LIMITTEXT, 2, 0);
@@ -897,7 +897,7 @@ static INT_PTR CALLBACK DlgProc_Popups(HWND hDlg, UINT uMsg, WPARAM wParam, LPAR
// Birthday
mir_tstrncpy(ppd.lptzContactName, TranslateT("Birthday"), SIZEOF(ppd.lptzContactName));
- ppd.lchIcon = Skin_GetIcon(ICO_RMD_DTB0);
+ ppd.lchIcon = IcoLib_GetIcon(ICO_RMD_DTB0);
if (IsDlgButtonChecked(hDlg, CHECK_OPT_POPUP_WINCLR)) {
ppd.colorBack = GetSysColor(COLOR_BTNFACE);
ppd.colorText = GetSysColor(COLOR_WINDOWTEXT);
@@ -910,7 +910,7 @@ static INT_PTR CALLBACK DlgProc_Popups(HWND hDlg, UINT uMsg, WPARAM wParam, LPAR
// Anniversary
mir_tstrncpy(ppd.lptzContactName, TranslateT("Anniversary"), SIZEOF(ppd.lptzContactName));
- ppd.lchIcon = Skin_GetIcon(ICO_RMD_DTAX);
+ ppd.lchIcon = IcoLib_GetIcon(ICO_RMD_DTAX);
if (IsDlgButtonChecked(hDlg, CHECK_OPT_POPUP_WINCLR)) {
ppd.colorBack = GetSysColor(COLOR_BTNFACE);
ppd.colorText = GetSysColor(COLOR_WINDOWTEXT);
diff --git a/plugins/UserInfoEx/src/svc_email.cpp b/plugins/UserInfoEx/src/svc_email.cpp
index bcc90fa7b2..351e36c9f2 100644
--- a/plugins/UserInfoEx/src/svc_email.cpp
+++ b/plugins/UserInfoEx/src/svc_email.cpp
@@ -185,7 +185,7 @@ void SvcEMailRebuildMenu()
// insert contact menuitem
CLISTMENUITEM mi = { sizeof(mi) };
mi.position = -2000010000;
- mi.hIcon = Skin_GetIcon(ICO_BTN_EMAIL);
+ mi.hIcon = IcoLib_GetIcon(ICO_BTN_EMAIL);
mi.pszName = "&E-mail";
mi.pszService = MS_EMAIL_SENDEMAIL;
ghMenuItem = Menu_AddContactMenuItem(&mi);
diff --git a/plugins/UserInfoEx/src/svc_homepage.cpp b/plugins/UserInfoEx/src/svc_homepage.cpp
index 1d3d9205dc..33b847f650 100644
--- a/plugins/UserInfoEx/src/svc_homepage.cpp
+++ b/plugins/UserInfoEx/src/svc_homepage.cpp
@@ -155,7 +155,7 @@ void SvcHomepageRebuildMenu()
// insert contact menuitem
CLISTMENUITEM mi = { sizeof(mi) };
mi.position = -2000010000;
- mi.hIcon = Skin_GetIcon(ICO_BTN_GOTO);
+ mi.hIcon = IcoLib_GetIcon(ICO_BTN_GOTO);
mi.pszName = LPGEN("&Homepage");
mi.pszService = MS_USERINFO_HOMEPAGE_OPENURL;
ghMenuItem = Menu_AddContactMenuItem(&mi);
diff --git a/plugins/UserInfoEx/src/svc_refreshci.cpp b/plugins/UserInfoEx/src/svc_refreshci.cpp
index 1c8e27499f..ddf2672909 100644
--- a/plugins/UserInfoEx/src/svc_refreshci.cpp
+++ b/plugins/UserInfoEx/src/svc_refreshci.cpp
@@ -401,7 +401,7 @@ public:
_popupButtons[0].cbSize = sizeof(POPUPACTION);
_popupButtons[0].flags = PAF_ENABLED;
- _popupButtons[0].lchIcon = Skin_GetIcon(ICO_BTN_DOWNARROW);
+ _popupButtons[0].lchIcon = IcoLib_GetIcon(ICO_BTN_DOWNARROW);
_popupButtons[0].wParam = MAKEWORD(IDSKIP, BN_CLICKED);
_popupButtons[0].lParam = NULL;
mir_strcpy(_popupButtons[0].lpzTitle, MODNAME"/Hide");
@@ -409,7 +409,7 @@ public:
// cancel button
_popupButtons[1].cbSize = sizeof(POPUPACTION);
_popupButtons[1].flags = PAF_ENABLED;
- _popupButtons[1].lchIcon = Skin_GetIcon(ICO_BTN_CANCEL);
+ _popupButtons[1].lchIcon = IcoLib_GetIcon(ICO_BTN_CANCEL);
_popupButtons[1].wParam = MAKEWORD(IDCANCEL, BN_CLICKED);
_popupButtons[1].lParam = NULL;
mir_strcpy(_popupButtons[1].lpzTitle, MODNAME"/Cancel");
@@ -423,7 +423,7 @@ public:
{
POPUPDATAT_V2 pd = { 0 };
pd.cbSize = sizeof(pd);
- pd.lchIcon = Skin_GetIcon(ICO_BTN_UPDATE);
+ pd.lchIcon = IcoLib_GetIcon(ICO_BTN_UPDATE);
pd.iSeconds = -1;
pd.PluginData = this;
pd.PluginWindowProc = CPopupUpdProgress::WndProc;
@@ -613,7 +613,7 @@ class CContactUpdater : public CContactQueue
CLISTMENUITEM clmi = { sizeof(clmi) };
clmi.flags = CMIM_NAME|CMIM_ICON;
clmi.pszName = LPGEN("Refresh contact details");
- clmi.hIcon = Skin_GetIcon(ICO_BTN_UPDATE);
+ clmi.hIcon = IcoLib_GetIcon(ICO_BTN_UPDATE);
Menu_ModifyItem(hMenuItemRefresh, &clmi);
}
}
@@ -730,7 +730,7 @@ public:
CLISTMENUITEM clmi = { sizeof(clmi) };
clmi.flags = CMIM_NAME|CMIM_ICON;
clmi.pszName = LPGEN("Abort Refreshing Contact Details");
- clmi.hIcon = Skin_GetIcon(ICO_BTN_CANCEL);
+ clmi.hIcon = IcoLib_GetIcon(ICO_BTN_CANCEL);
Menu_ModifyItem(hMenuItemRefresh, &clmi);
}
}
diff --git a/plugins/UserInfoEx/src/svc_reminder.cpp b/plugins/UserInfoEx/src/svc_reminder.cpp
index 4c0f839e5a..62b097bf4e 100644
--- a/plugins/UserInfoEx/src/svc_reminder.cpp
+++ b/plugins/UserInfoEx/src/svc_reminder.cpp
@@ -146,19 +146,19 @@ static HICON GetAnnivIcon(const CEvent &evt)
switch (evt._eType) {
case CEvent::BIRTHDAY:
if (evt._wDaysLeft > 9)
- hIcon = Skin_GetIcon(ICO_RMD_DTBX);
+ hIcon = IcoLib_GetIcon(ICO_RMD_DTBX);
else {
mir_snprintf(szIcon, SIZEOF(szIcon), MODNAME"_rmd_dtb%u", evt._wDaysLeft);
- hIcon = Skin_GetIcon(szIcon);
+ hIcon = IcoLib_GetIcon(szIcon);
}
break;
case CEvent::ANNIVERSARY:
if (evt._wDaysLeft > 9)
- hIcon = Skin_GetIcon(ICO_RMD_DTAX);
+ hIcon = IcoLib_GetIcon(ICO_RMD_DTAX);
else {
mir_snprintf(szIcon, SIZEOF(szIcon), MODNAME"_rmd_dta%u", evt._wDaysLeft);
- hIcon = Skin_GetIcon(szIcon);
+ hIcon = IcoLib_GetIcon(szIcon);
}
}
return hIcon;
@@ -319,12 +319,12 @@ static void NotifyFlashCListIcon(MCONTACT hContact, const CEvent &evt)
switch (evt._eType) {
case CEvent::BIRTHDAY:
mir_sntprintf(szMsg, SIZEOF(szMsg), TranslateT("%s has %s today."), DB::Contact::DisplayName(hContact), TranslateT("Birthday"));
- cle.hIcon = Skin_GetIcon(ICO_COMMON_BIRTHDAY);
+ cle.hIcon = IcoLib_GetIcon(ICO_COMMON_BIRTHDAY);
break;
case CEvent::ANNIVERSARY:
mir_sntprintf(szMsg, SIZEOF(szMsg), TranslateT("%s has %s today."), DB::Contact::DisplayName(hContact), TranslateT("an anniversary"));
- cle.hIcon = Skin_GetIcon(ICO_COMMON_ANNIVERSARY);
+ cle.hIcon = IcoLib_GetIcon(ICO_COMMON_ANNIVERSARY);
break;
default:
@@ -684,7 +684,7 @@ void SvcReminderOnTopToolBarLoaded()
ttb.dwFlags = TTBBF_VISIBLE | TTBBF_SHOWTOOLTIP;
ttb.pszService = MS_USERINFO_REMINDER_CHECK;
ttb.name = ttb.pszTooltipUp = LPGEN("Check anniversaries");
- ttb.hIconHandleUp = Skin_GetIconHandle(ICO_COMMON_BIRTHDAY);
+ ttb.hIconHandleUp = IcoLib_GetIconHandle(ICO_COMMON_BIRTHDAY);
TopToolbar_AddButton(&ttb);
}
@@ -738,7 +738,7 @@ static INT_PTR BackupBirthdayService(WPARAM hContact, LPARAM lParam)
MSGBOX mBox;
mBox.cbSize = sizeof(MSGBOX);
mBox.hParent = NULL;
- mBox.hiLogo = Skin_GetIcon(ICO_COMMON_BIRTHDAY);
+ mBox.hiLogo = IcoLib_GetIcon(ICO_COMMON_BIRTHDAY);
mBox.uType = MB_ICON_INFO;
mBox.ptszTitle = TranslateT("Update custom birthday");
mBox.ptszMsg = TranslateT("Backing up and syncing all birthdays complete!");
diff --git a/plugins/Utils.pas/mirutils.pas b/plugins/Utils.pas/mirutils.pas
index 5c25045c11..ab7a275a48 100644
--- a/plugins/Utils.pas/mirutils.pas
+++ b/plugins/Utils.pas/mirutils.pas
@@ -62,7 +62,7 @@ const
function SetButtonIcon(btn:HWND;name:PAnsiChar):HICON;
begin
- result:=CallService(MS_SKIN2_GETICON,0,LPARAM(name));
+ result:=IcoLib_GetIcon(name,0);
SendMessage(btn,BM_SETIMAGE,IMAGE_ICON,result);
end;
diff --git a/plugins/Utils.pas/sedit.pas b/plugins/Utils.pas/sedit.pas
index 7c7010e43b..a935f9f71b 100644
--- a/plugins/Utils.pas/sedit.pas
+++ b/plugins/Utils.pas/sedit.pas
@@ -88,7 +88,7 @@ procedure RegisterIcons;
var
sid:TSKINICONDESC;
begin
- if CallService(MS_SKIN2_GETICON,0,LPARAM(ACI_NEW))<>0 then
+ if IcoLib_GetIcon(ACI_NEW,0)<>0 then
exit;
FillChar(sid,SizeOf(TSKINICONDESC),0);
diff --git a/plugins/Variables/src/help.cpp b/plugins/Variables/src/help.cpp
index 5338f4695d..ffdaa361e0 100644
--- a/plugins/Variables/src/help.cpp
+++ b/plugins/Variables/src/help.cpp
@@ -1217,7 +1217,7 @@ INT_PTR getSkinItemService(WPARAM wParam, LPARAM lParam)
switch (item) {
case VSI_HELPICON:
if (hHelpIcon == NULL)
- hHelpIcon = Skin_GetIcon("vars_help");
+ hHelpIcon = IcoLib_GetIcon("vars_help");
return (INT_PTR)hHelpIcon;
case VSI_HELPTIPTEXT:
diff --git a/plugins/Watrack/i_gui.inc b/plugins/Watrack/i_gui.inc
index 2a219c8140..709584b066 100644
--- a/plugins/Watrack/i_gui.inc
+++ b/plugins/Watrack/i_gui.inc
@@ -12,8 +12,8 @@ begin
if DisablePlugin<>dsPermanent then
ttb.dwFlags:=ttb.dwFlags or TTBBF_PUSHED;
- ttb.hIconDn :=CallService(MS_SKIN2_GETICON,0,tlparam(IcoBtnEnable));
- ttb.hIconUp :=CallService(MS_SKIN2_GETICON,0,tlparam(IcoBtnDisable));
+ ttb.hIconDn :=IcoLib_GetIcon(IcoBtnEnable,0);
+ ttb.hIconUp :=IcoLib_GetIcon(IcoBtnDisable,0);
ttb.wParamUp :=1;
// ttb.wParamDown :=0;
ttb.pszService:=MS_WAT_PLUGINSTATUS;
@@ -37,7 +37,7 @@ begin
mi.cbSize :=sizeof(mi);
mi.szPopupName.a:=PluginShort;
- mi.hIcon :=CallService(MS_SKIN2_GETICON,0,lparam(IcoBtnEnable));
+ mi.hIcon :=IcoLib_GetIcon(IcoBtnEnable,0);
mi.szName.a :='Disable WATrack';
mi.pszService :=MS_WAT_PLUGINSTATUS;
mi.popupPosition:=MenuDisablePos;
@@ -54,12 +54,12 @@ begin
mi.flags :=CMIM_NAME+CMIM_FLAGS+CMIM_ICON+f1;
if f1<>0 then
begin
- mi.hIcon :=CallService(MS_SKIN2_GETICON,0,lparam(IcoBtnDisable));
+ mi.hIcon :=IcoLib_GetIcon(IcoBtnDisable,0);
mi.szName.a:='Enable WATrack';
end
else
begin
- mi.hIcon :=CallService(MS_SKIN2_GETICON,0,lparam(IcoBtnEnable));
+ mi.hIcon :=IcoLib_GetIcon(IcoBtnEnable,0);
mi.szName.a:='Disable WATrack';
end;
CallService(MS_CLIST_MODIFYMENUITEM,hMenuDisable,lparam(@mi));
@@ -91,21 +91,15 @@ begin
mi.cbSize:=sizeof(mi);
mi.flags :=CMIM_ICON;
- mi.hIcon:=CallService(MS_SKIN2_GETICON,0,tlparam(IcoBtnEnable));
+ mi.hIcon:=IcoLib_GetIcon(IcoBtnEnable,0);
CallService(MS_CLIST_MODIFYMENUITEM,hMenuDisable,tlparam(@mi));
-// toptoolbar
+ // toptoolbar
if ServiceExists(MS_TTB_GETBUTTONOPTIONS)<>0 then
begin
-{
- CallService(MS_TTB_GETBUTTONOPTIONS,(ttbInfo shl 16)+TTBO_ALLDATA,tlparam(@ttb));
- ttb.hIconUp:=CallService(MS_SKIN2_GETICON,0,tlparam(IcoBtnInfo));
- ttb.hIconDn:=ttb.hIconUp;
- CallService(MS_TTB_SETBUTTONOPTIONS,(ttbInfo shl 16)+TTBO_ALLDATA,tlparam(@ttb));
-}
CallService(MS_TTB_GETBUTTONOPTIONS,(ttbState shl 16)+TTBO_ALLDATA,tlparam(@ttb));
- ttb.hIconDn:=CallService(MS_SKIN2_GETICON,0,tlparam(IcoBtnEnable));
- ttb.hIconUp:=CallService(MS_SKIN2_GETICON,0,tlparam(IcoBtnDisable));
+ ttb.hIconDn:=IcoLib_GetIcon(IcoBtnEnable,0);
+ ttb.hIconUp:=IcoLib_GetIcon(IcoBtnDisable,0);
CallService(MS_TTB_SETBUTTONOPTIONS,(ttbState shl 16)+TTBO_ALLDATA,tlparam(@ttb));
end;
diff --git a/plugins/Watrack/lastfm/lastfm.pas b/plugins/Watrack/lastfm/lastfm.pas
index 677d7aa4c5..8c552d4b1a 100644
--- a/plugins/Watrack/lastfm/lastfm.pas
+++ b/plugins/Watrack/lastfm/lastfm.pas
@@ -144,7 +144,7 @@ begin
FillChar(mi,SizeOf(mi),0);
mi.cbSize:=sizeof(mi);
mi.flags :=CMIM_ICON;
- mi.hIcon :=CallService(MS_SKIN2_GETICON,0,tlparam(IcoLastFM));
+ mi.hIcon :=IcoLib_GetIcon(IcoLastFM,0);
CallService(MS_CLIST_MODIFYMENUITEM,hMenuLast,tlparam(@mi));
end;
@@ -207,7 +207,7 @@ begin
mi.cbSize :=sizeof(mi);
mi.szPopupName.a:=PluginShort;
- mi.hIcon :=CallService(MS_SKIN2_GETICON,0,lparam(IcoLastFM));
+ mi.hIcon :=IcoLib_GetIcon(IcoLastFM,0);
mi.szName.a :='Disable scrobbling';
mi.pszService :=MS_WAT_LASTFM;
mi.popupPosition:=500050000;
diff --git a/plugins/Watrack/myshows/myshows.pas b/plugins/Watrack/myshows/myshows.pas
index ff9e2975a5..8749d91f2a 100644
--- a/plugins/Watrack/myshows/myshows.pas
+++ b/plugins/Watrack/myshows/myshows.pas
@@ -173,7 +173,7 @@ begin
FillChar(mi,SizeOf(mi),0);
mi.cbSize:=sizeof(mi);
mi.flags :=CMIM_ICON;
- mi.hIcon :=CallService(MS_SKIN2_GETICON,0,tLParam(IcoMyShows));
+ mi.hIcon :=IcoLib_GetIcon(IcoMyShows,0);
CallService(MS_CLIST_MODIFYMENUITEM,hMenuMyShows,tlParam(@mi));
end;
@@ -240,7 +240,7 @@ begin
mi.cbSize :=sizeof(mi);
mi.szPopupName.a:=PluginShort;
- mi.hIcon :=CallService(MS_SKIN2_GETICON,0,tlParam(IcoMyShows));
+ mi.hIcon :=IcoLib_GetIcon(IcoMyShows,0);
mi.szName.a :='Disable scrobbling';
mi.pszService :=MS_WAT_MYSHOWS;
mi.popupPosition:=500050000;
diff --git a/plugins/Watrack/popup/popups.pas b/plugins/Watrack/popup/popups.pas
index eea51ae883..2e95e7f05b 100644
--- a/plugins/Watrack/popup/popups.pas
+++ b/plugins/Watrack/popup/popups.pas
@@ -349,7 +349,7 @@ begin
FillChar(mi,SizeOf(mi),0);
mi.cbSize:=sizeof(mi);
mi.flags :=CMIM_ICON;
- mi.hIcon :=CallService(MS_SKIN2_GETICON,0,tlparam(IcoBtnInfo));
+ mi.hIcon :=IcoLib_GetIcon(IcoBtnInfo,0);
CallService(MS_CLIST_MODIFYMENUITEM,hMenuInfo,tlparam(@mi));
if ActionList<>nil then
begin
@@ -387,7 +387,7 @@ begin
FillChar(ttb,SizeOf(ttb),0);
ttb.cbSize :=SizeOf(ttb);
ttb.dwFlags :=TTBBF_VISIBLE{ or TTBBF_SHOWTOOLTIP};
- ttb.hIconUp :=CallService(MS_SKIN2_GETICON,0,tlparam(IcoBtnInfo));
+ ttb.hIconUp :=IcoLib_GetIcon(IcoBtnInfo,0);
ttb.hIconDn :=ttb.hIconUp;
ttb.pszService:=MS_WAT_SHOWMUSICINFO;
ttb.name :='Music Info';
@@ -486,7 +486,7 @@ begin
FillChar(mi,SizeOf(mi),0);
mi.cbSize :=SizeOf(mi);
mi.szPopupName.a:=PluginShort;
- mi.hIcon :=CallService(MS_SKIN2_GETICON,0,lparam(IcoBtnInfo));
+ mi.hIcon :=IcoLib_GetIcon(IcoBtnInfo,0);
mi.szName.a :='Music Info';
mi.pszService :=MS_WAT_SHOWMUSICINFO;
mi.popupPosition:=MenuInfoPos;
diff --git a/plugins/Watrack/proto/proto.pas b/plugins/Watrack/proto/proto.pas
index 8da9d20b12..e26ce14f17 100644
--- a/plugins/Watrack/proto/proto.pas
+++ b/plugins/Watrack/proto/proto.pas
@@ -459,7 +459,7 @@ begin
mi.cbSize:=sizeof(mi);
mi.flags :=CMIM_ICON;
- mi.hIcon:=CallService(MS_SKIN2_GETICON,0,tlparam(IcoBtnContext));
+ mi.hIcon:=IcoLib_GetIcon(IcoBtnContext,0);
CallService(MS_CLIST_MODIFYMENUITEM,hContactMenuItem,tlparam(@mi));
end;
@@ -506,8 +506,7 @@ begin
mi.cbSize :=sizeof(mi);
mi.szPopupName.a:=PluginShort;
mi.flags :=CMIF_NOTOFFLINE or CMIF_NOTOFFLIST;
-// mi.popupPosition:=MenuUserInfoPos;
- mi.hIcon :=CallService(MS_SKIN2_GETICON,0,lparam(IcoBtnContext));
+ mi.hIcon :=IcoLib_GetIcon(IcoBtnContext,0);
mi.szName.a :='Get user''s Music Info';
mi.pszService :=MS_WAT_GETCONTACTINFO;
hContactMenuItem:=Menu_AddContactMenuItem(@mi);
diff --git a/plugins/Watrack/stat/statlog.pas b/plugins/Watrack/stat/statlog.pas
index 3d82b93223..886a22057c 100644
--- a/plugins/Watrack/stat/statlog.pas
+++ b/plugins/Watrack/stat/statlog.pas
@@ -559,7 +559,7 @@ begin
FillChar(mi,SizeOf(mi),0);
mi.cbSize:=sizeof(mi);
mi.flags :=CMIM_ICON;
- mi.hIcon :=CallService(MS_SKIN2_GETICON,0,tlparam(IcoBtnReport));
+ mi.hIcon :=IcoLib_GetIcon(IcoBtnReport,0);
CallService(MS_CLIST_MODIFYMENUITEM,hMenuReport,tlparam(@mi));
end;
@@ -602,7 +602,7 @@ begin
mi.cbSize :=sizeof(mi);
mi.flags :=0;
mi.szPopupName.a:=PluginShort;
- mi.hIcon :=CallService(MS_SKIN2_GETICON,0,tlparam(IcoBtnReport));
+ mi.hIcon :=IcoLib_GetIcon(IcoBtnReport,0);
mi.szName.a :='Create WATrack report';
mi.pszService :=MS_WAT_MAKEREPORT;
mi.popupPosition:=MenuReportPos;
diff --git a/plugins/Watrack/waticons.pas b/plugins/Watrack/waticons.pas
index 3de092b5c7..de0c5c17d0 100644
--- a/plugins/Watrack/waticons.pas
+++ b/plugins/Watrack/waticons.pas
@@ -190,8 +190,7 @@ end;
function GetIcon(action:integer;stat:integer):cardinal;
begin
- result:=CallService(MS_SKIN2_GETICON,0,
- lparam(CtrlIcoLib[action][stat].name));
+ result:=IcoLib_GetIcon(CtrlIcoLib[action][stat].name,0);
end;
function GetIconDescr(action:integer):pAnsiChar;
diff --git a/plugins/Watrack/watrack.dpr b/plugins/Watrack/watrack.dpr
index c122d50e77..91edbcfd01 100644
--- a/plugins/Watrack/watrack.dpr
+++ b/plugins/Watrack/watrack.dpr
@@ -550,7 +550,7 @@ begin
dbetd.textService:=nil;
dbetd.iconService:=nil;
p:='WATrack_Info';
- dbetd.eventIcon :=CallService(MS_SKIN2_GETICON,0,tlparam(p)); //!! from popups
+ dbetd.eventIcon :=IcoLib_GetIcon(p,0);
for i:=0 to HIGH(cdbetd) do
begin
diff --git a/plugins/Weather/src/weather_contacts.cpp b/plugins/Weather/src/weather_contacts.cpp
index 5eec260dd7..4c4980ed46 100644
--- a/plugins/Weather/src/weather_contacts.cpp
+++ b/plugins/Weather/src/weather_contacts.cpp
@@ -409,10 +409,10 @@ INT_PTR CALLBACK DlgProcChange(HWND hwndDlg, UINT msg, WPARAM wParam, LPARAM lPa
case WM_DESTROY:
wndData = (CntSetWndDataType*)GetWindowLongPtr(hwndDlg, GWLP_USERDATA);
- Skin_ReleaseIcon(wndData->hFile);
- Skin_ReleaseIcon(wndData->hRename);
- Skin_ReleaseIcon(wndData->hSrchAll);
- Skin_ReleaseIcon(wndData->hUserDetail);
+ IcoLib_ReleaseIcon(wndData->hFile);
+ IcoLib_ReleaseIcon(wndData->hRename);
+ IcoLib_ReleaseIcon(wndData->hSrchAll);
+ IcoLib_ReleaseIcon(wndData->hUserDetail);
mir_free(wndData);
SetWindowLongPtr(hwndDlg, GWLP_USERDATA, 0);
diff --git a/plugins/Weather/src/weather_icons.cpp b/plugins/Weather/src/weather_icons.cpp
index 85884aa983..74a25ffbe8 100644
--- a/plugins/Weather/src/weather_icons.cpp
+++ b/plugins/Weather/src/weather_icons.cpp
@@ -46,7 +46,7 @@ HICON LoadIconEx(const char* name, BOOL big)
{
char szSettingName[100];
mir_snprintf(szSettingName, SIZEOF(szSettingName), "%s_%s", WEATHERPROTONAME, name);
- return Skin_GetIcon(szSettingName, big);
+ return IcoLib_GetIcon(szSettingName, big);
}
HANDLE GetIconHandle(const char* name)
@@ -60,5 +60,5 @@ HANDLE GetIconHandle(const char* name)
void ReleaseIconEx(HICON hIcon)
{
- Skin_ReleaseIcon(hIcon);
+ IcoLib_ReleaseIcon(hIcon);
}
diff --git a/plugins/Weather/src/weather_mwin.cpp b/plugins/Weather/src/weather_mwin.cpp
index 485abfeefe..714df36626 100644
--- a/plugins/Weather/src/weather_mwin.cpp
+++ b/plugins/Weather/src/weather_mwin.cpp
@@ -234,7 +234,7 @@ static LRESULT CALLBACK wndProc(HWND hwnd, UINT msg, WPARAM wParam, LPARAM lPara
DeleteObject(hfnt);
}
EndPaint(hwnd, &ps);
- Skin_ReleaseIcon(hIcon);
+ IcoLib_ReleaseIcon(hIcon);
db_free(&dbv);
}
break;
diff --git a/plugins/Weather/src/weather_popup.cpp b/plugins/Weather/src/weather_popup.cpp
index 17ab3696c8..3ae6f80032 100644
--- a/plugins/Weather/src/weather_popup.cpp
+++ b/plugins/Weather/src/weather_popup.cpp
@@ -141,7 +141,7 @@ LRESULT CALLBACK PopupDlgProc(HWND hWnd, UINT message, WPARAM wParam, LPARAM lPa
return TRUE;
case UM_FREEPLUGINDATA:
- Skin_ReleaseIcon((HICON)PUGetPluginData(hWnd));
+ IcoLib_ReleaseIcon((HICON)PUGetPluginData(hWnd));
return FALSE;
}
diff --git a/plugins/Weather/src/weather_userinfo.cpp b/plugins/Weather/src/weather_userinfo.cpp
index befe325ad0..564e8e48ee 100644
--- a/plugins/Weather/src/weather_userinfo.cpp
+++ b/plugins/Weather/src/weather_userinfo.cpp
@@ -108,7 +108,7 @@ INT_PTR CALLBACK DlgProcUIPage(HWND hwndDlg, UINT msg, WPARAM wParam, LPARAM lPa
break;
case WM_DESTROY:
- Skin_ReleaseIcon((HICON)SendDlgItemMessage(hwndDlg, IDC_INFOICON, STM_SETICON, 0, 0));
+ IcoLib_ReleaseIcon((HICON)SendDlgItemMessage(hwndDlg, IDC_INFOICON, STM_SETICON, 0, 0));
DeleteObject((HFONT)SendDlgItemMessage(hwndDlg, IDC_INFO2, WM_GETFONT, 0, 0));
break;
diff --git a/plugins/WhenWasIt/src/dlg_handlers.cpp b/plugins/WhenWasIt/src/dlg_handlers.cpp
index 2200ffddcd..65ba3dcd34 100644
--- a/plugins/WhenWasIt/src/dlg_handlers.cpp
+++ b/plugins/WhenWasIt/src/dlg_handlers.cpp
@@ -403,7 +403,7 @@ INT_PTR CALLBACK DlgProcAddBirthday(HWND hWnd, UINT msg, WPARAM wParam, LPARAM l
WindowList_Add(hAddBirthdayWndsList, hWnd, hContact);
Utils_RestoreWindowPositionNoSize(hWnd, hContact, ModuleName, "BirthdayWnd");
}
- SendMessage(hWnd, WM_SETICON, ICON_BIG, (LPARAM)Skin_GetIconByHandle(hAddBirthdayContact, 1));
+ SendMessage(hWnd, WM_SETICON, ICON_BIG, (LPARAM)IcoLib_GetIconByHandle(hAddBirthdayContact, 1));
{
for (int i = 0; i < cSaveModule; i++)
SendDlgItemMessage(hWnd, IDC_COMPATIBILITY, CB_ADDSTRING, 0, (LPARAM)TranslateTS(szSaveModule[i]));
@@ -475,7 +475,7 @@ INT_PTR CALLBACK DlgProcAddBirthday(HWND hWnd, UINT msg, WPARAM wParam, LPARAM l
case WM_DESTROY:
RefreshContactListIcons(hContact); //the birthday might be changed, refresh icon.
- Skin_ReleaseIcon((HICON)SendMessage(hWnd, WM_GETICON, ICON_BIG, 0));
+ IcoLib_ReleaseIcon((HICON)SendMessage(hWnd, WM_GETICON, ICON_BIG, 0));
Utils_SaveWindowPosition(hWnd, hContact, ModuleName, "BirthdayWnd");
WindowList_Remove(hAddBirthdayWndsList, hWnd);
break;
@@ -716,7 +716,7 @@ INT_PTR CALLBACK DlgProcBirthdays(HWND hWnd, UINT msg, WPARAM wParam, LPARAM lPa
switch (msg) {
case WM_INITDIALOG:
TranslateDialogDefault(hWnd);
- SendMessage(hWnd, WM_SETICON, ICON_BIG, (LPARAM)Skin_GetIconByHandle(hListMenu));
+ SendMessage(hWnd, WM_SETICON, ICON_BIG, (LPARAM)IcoLib_GetIconByHandle(hListMenu));
{
HWND hList = GetDlgItem(hWnd, IDC_BIRTHDAYS_LIST);
@@ -832,7 +832,7 @@ INT_PTR CALLBACK DlgProcBirthdays(HWND hWnd, UINT msg, WPARAM wParam, LPARAM lPa
case WM_DESTROY:
hBirthdaysDlg = NULL;
Utils_SaveWindowPosition(hWnd, NULL, ModuleName, "BirthdayList");
- Skin_ReleaseIcon((HICON)SendMessage(hWnd, WM_GETICON, ICON_BIG, 0));
+ IcoLib_ReleaseIcon((HICON)SendMessage(hWnd, WM_GETICON, ICON_BIG, 0));
lastColumn = -1;
break;
@@ -850,7 +850,7 @@ INT_PTR CALLBACK DlgProcUpcoming(HWND hWnd, UINT msg, WPARAM wParam, LPARAM lPar
{
TranslateDialogDefault(hWnd);
timeout = commonData.cDlgTimeout;
- SendMessage(hWnd, WM_SETICON, ICON_BIG, (LPARAM)Skin_GetIconByHandle(hListMenu));
+ SendMessage(hWnd, WM_SETICON, ICON_BIG, (LPARAM)IcoLib_GetIconByHandle(hListMenu));
HWND hList = GetDlgItem(hWnd, IDC_UPCOMING_LIST);
mir_subclassWindow(hList, BirthdaysListSubclassProc);
@@ -960,7 +960,7 @@ INT_PTR CALLBACK DlgProcUpcoming(HWND hWnd, UINT msg, WPARAM wParam, LPARAM lPar
case WM_DESTROY:
hUpcomingDlg = NULL;
Utils_SaveWindowPosition(hWnd, NULL, ModuleName, "BirthdayListUpcoming");
- Skin_ReleaseIcon((HICON)SendMessage(hWnd, WM_GETICON, ICON_BIG, 0));
+ IcoLib_ReleaseIcon((HICON)SendMessage(hWnd, WM_GETICON, ICON_BIG, 0));
KillTimer(hWnd, UPCOMING_TIMER_ID);
break;
}
diff --git a/plugins/WhenWasIt/src/icons.cpp b/plugins/WhenWasIt/src/icons.cpp
index fbaed89acf..6dd5157fb3 100644
--- a/plugins/WhenWasIt/src/icons.cpp
+++ b/plugins/WhenWasIt/src/icons.cpp
@@ -39,7 +39,7 @@ static HANDLE AddIcon(char *name, char *description, TCHAR *tszPath, int iDefaul
sid.pszName = name;
sid.defaultFile.t = tszPath;
sid.iDefaultIndex = -iDefaultIdx;
- return Skin_AddIcon(&sid);
+ return IcoLib_AddIcon(&sid);
}
int AddIcons()
diff --git a/plugins/WhenWasIt/src/icons.h b/plugins/WhenWasIt/src/icons.h
index df3766b2ad..bf440d01e7 100644
--- a/plugins/WhenWasIt/src/icons.h
+++ b/plugins/WhenWasIt/src/icons.h
@@ -40,7 +40,7 @@ HANDLE GetDTBIconHandle(int dtb);
__forceinline HICON GetDTBIcon(int dtb)
{
- return Skin_GetIconByHandle(GetDTBIconHandle(dtb));
+ return IcoLib_GetIconByHandle(GetDTBIconHandle(dtb));
}
#endif //M_WWI_ICONS_H \ No newline at end of file
diff --git a/plugins/WhenWasIt/src/services.cpp b/plugins/WhenWasIt/src/services.cpp
index 79c699d7de..3e392520c9 100644
--- a/plugins/WhenWasIt/src/services.cpp
+++ b/plugins/WhenWasIt/src/services.cpp
@@ -179,7 +179,7 @@ INT_PTR AddBirthdayService(WPARAM hContact, LPARAM lParam)
void ShowPopupMessage(TCHAR *title, TCHAR *message, HANDLE icon)
{
POPUPDATAT pd = { 0 };
- pd.lchIcon = Skin_GetIconByHandle(icon);
+ pd.lchIcon = IcoLib_GetIconByHandle(icon);
_tcsncpy(pd.lptzContactName, title, MAX_CONTACTNAME - 1);
_tcsncpy(pd.lptzText, message, MAX_SECONDLINE - 1);
pd.colorText = commonData.foreground;
diff --git a/plugins/WinterSpeak/src/MirandaDialog.cpp b/plugins/WinterSpeak/src/MirandaDialog.cpp
index 200f398e41..7bdbec3059 100644
--- a/plugins/WinterSpeak/src/MirandaDialog.cpp
+++ b/plugins/WinterSpeak/src/MirandaDialog.cpp
@@ -33,6 +33,6 @@ int MirandaDialog::ImageList_AddIcon_IconLibLoaded(HIMAGELIST hIml, int iconId)
{
HICON hIcon = LoadSkinnedIcon(iconId);
int res = ImageList_AddIcon(hIml, hIcon);
- Skin_ReleaseIcon(hIcon);
+ IcoLib_ReleaseIcon(hIcon);
return res;
} \ No newline at end of file
diff --git a/plugins/YAMN/src/main.cpp b/plugins/YAMN/src/main.cpp
index a837cda3b7..d56c93f3eb 100644
--- a/plugins/YAMN/src/main.cpp
+++ b/plugins/YAMN/src/main.cpp
@@ -195,12 +195,12 @@ HICON WINAPI g_LoadIconEx( int idx, bool big )
{
if ( idx >= SIZEOF(iconList))
return NULL;
- return Skin_GetIcon(iconList[idx].szName, big);
+ return IcoLib_GetIcon(iconList[idx].szName, big);
}
void WINAPI g_ReleaseIcon( HICON hIcon )
{
- if ( hIcon ) Skin_ReleaseIcon(hIcon);
+ if ( hIcon ) IcoLib_ReleaseIcon(hIcon);
}
static void LoadPlugins()
diff --git a/plugins/YAPP/src/popwin.cpp b/plugins/YAPP/src/popwin.cpp
index 78e2607abe..ac801b8ef4 100644
--- a/plugins/YAPP/src/popwin.cpp
+++ b/plugins/YAPP/src/popwin.cpp
@@ -736,14 +736,14 @@ LRESULT CALLBACK PopupWindowProc(HWND hwnd, UINT uMsg, WPARAM wParam, LPARAM lPa
void PopupData::SetIcon(HICON hNewIcon)
{
if (flags & PDF_ICOLIB) {
- Skin_ReleaseIcon(hIcon);
+ IcoLib_ReleaseIcon(hIcon);
flags &= ~PDF_ICOLIB;
}
hIcon = hNewIcon;
- if ( CallService(MS_SKIN2_ISMANAGEDICON, (WPARAM)hIcon, 0)) {
- CallService(MS_SKIN2_ADDREFICON, (WPARAM)hIcon, 0);
+ if (IcoLib_IsManaged(hIcon)) {
+ IcoLib_AddRef(hIcon);
flags |= PDF_ICOLIB;
}
}
diff --git a/plugins/YAPP/src/yapp.cpp b/plugins/YAPP/src/yapp.cpp
index a499976d91..35c7a61640 100644
--- a/plugins/YAPP/src/yapp.cpp
+++ b/plugins/YAPP/src/yapp.cpp
@@ -96,8 +96,8 @@ int TTBLoaded(WPARAM, LPARAM)
if (db_get_b(0, "Popup", "ModuleIsEnabled", 1))
ttb.dwFlags |= TTBBF_PUSHED;
ttb.name = LPGEN("Toggle Popups");
- ttb.hIconHandleUp = Skin_GetIconHandle(ICO_TB_POPUP_OFF);
- ttb.hIconHandleDn = Skin_GetIconHandle(ICO_TB_POPUP_ON);
+ ttb.hIconHandleUp = IcoLib_GetIconHandle(ICO_TB_POPUP_OFF);
+ ttb.hIconHandleDn = IcoLib_GetIconHandle(ICO_TB_POPUP_ON);
ttb.pszTooltipUp = LPGEN("Enable Popups");
ttb.pszTooltipDn = LPGEN("Disable Popups");
hTTButton = TopToolbar_AddButton(&ttb);
diff --git a/plugins/mRadio/i_tray.inc b/plugins/mRadio/i_tray.inc
index 468cb47992..3d44553244 100644
--- a/plugins/mRadio/i_tray.inc
+++ b/plugins/mRadio/i_tray.inc
@@ -141,7 +141,7 @@ begin
mi.cbSize :=sizeof(mi);
mi.flags :=CMIF_UNICODE;
mi.szName.w:=cPluginName;
- mi.hIcon :=CallService(MS_SKIN2_GETICON,0,lparam(IcoBtnSettings));
+ mi.hIcon :=IcoLib_GetIcon(IcoBtnSettings,0);
if doTray then
trayradioparent:=Menu_AddTrayMenuItem(@mi)
else
@@ -178,7 +178,7 @@ begin
mi.flags:=CMIF_UNICODE or CMIF_ROOTHANDLE;
ico:=IcoBtnOn;
end;
- mi.hIcon :=CallService(MS_SKIN2_GETICON,0,tlparam(ico));
+ mi.hIcon :=IcoLib_GetIcon(ico,0);
mi.szName.w :='Mute';
mi.pszService:=MS_RADIO_MUTE;
mi.position :=1;
@@ -197,7 +197,6 @@ begin
begin
playstr:='Pause';
end;
-// mi.hIcon:=CallService(MS_SKIN2_GETICON,0,tlparam(ico));
mi.szName.w :=playstr;
mi.position :=2;
srvtrayplaypause:=CreateServiceFunction('mRadio/TrayPlayPause',@TrayPlayPause);
@@ -219,7 +218,7 @@ begin
mi.szName.w :='Quick Open';
mi.position :=4;
mi.pszService:=MS_RADIO_QUICKOPEN;
- mi.hIcon :=CallService(MS_SKIN2_GETICON,0,tlparam(IcoBtnOpen));
+ mi.hIcon :=IcoLib_GetIcon(IcoBtnOpen,0);
if doTray then
Menu_AddTrayMenuItem(@mi)
else
@@ -265,7 +264,7 @@ begin
ico:=IcoBtnOn;
end;
mi.flags:=CMIM_FLAGS or CMIM_ICON;
- mi.hIcon:=CallService(MS_SKIN2_GETICON,0,tlparam(ico));
+ mi.hIcon:=IcoLib_GetIcon(ico,0);
CallService(MS_CLIST_MODIFYMENUITEM,traymute,tlparam(@mi));
mi.hIcon:=0;
diff --git a/plugins/mRadio/i_visual.inc b/plugins/mRadio/i_visual.inc
index a2b6574df3..5f56bcd4c7 100644
--- a/plugins/mRadio/i_visual.inc
+++ b/plugins/mRadio/i_visual.inc
@@ -22,12 +22,12 @@ begin
if THANDLE(hContact)<>ActiveContact then
begin
mi.szName.a:='Start broadcasting';
- mi.hIcon:=CallService(MS_SKIN2_GETICON,0,tlparam(IcoBtnOn));
+ mi.hIcon:=IcoLib_GetIcon(IcoBtnOn,0);
end
else
begin
mi.szName.a:='Stop broadcasting';
- mi.hIcon:=CallService(MS_SKIN2_GETICON,0,tlparam(IcoBtnOff));
+ mi.hIcon:=IcoLib_GetIcon(IcoBtnOff,0);
end;
CallService(MS_CLIST_MODIFYMENUITEM,hCMenuItemPlay,tlparam(@mi));
@@ -36,12 +36,12 @@ begin
if Service_RadioRecord(0,1)<>0 then
begin
mi.szName.a:='Stop record';
- mi.hIcon:=CallService(MS_SKIN2_GETICON,0,tlparam(IcoBtnRecDn));
+ mi.hIcon:=IcoLib_GetIcon(IcoBtnRecDn,0);
end
else
begin
mi.szName.a:='Start record';
- mi.hIcon:=CallService(MS_SKIN2_GETICON,0,tlparam(IcoBtnRecUp));
+ mi.hIcon:=IcoLib_GetIcon(IcoBtnRecUp,0);
end;
end;
CallService(MS_CLIST_MODIFYMENUITEM,hCMenuItemRec,tlparam(@mi));
@@ -60,7 +60,7 @@ begin
hCMenuItemRec:=Menu_AddContactMenuItem(@mi);
//!! mi.flags :=CMIF_NOTOFFLINE or CMIF_NOTOFFLIST;
- mi.hIcon :=CallService(MS_SKIN2_GETICON,0,lparam(IcoBtnOn));
+ mi.hIcon :=IcoLib_GetIcon(IcoBtnOn,0);
mi.pszService :=MS_RADIO_PLAYSTOP;
mi.szName.a :='Start/Stop broadcasting';
hCMenuItemPlay:=Menu_AddContactMenuItem(@mi);
diff --git a/plugins/mRadio/rframeapi.pas b/plugins/mRadio/rframeapi.pas
index b00cab0e52..b875ab7ca9 100644
--- a/plugins/mRadio/rframeapi.pas
+++ b/plugins/mRadio/rframeapi.pas
@@ -124,7 +124,7 @@ begin
IDC_RADIO_OPEN: begin
result:=1;
DrawIconEx(PDRAWITEMSTRUCT(lParam)^.hDC,0,0,
- CallService(MS_SKIN2_GETICON,0,TLPARAM(IcoBtnOpen)),
+ IcoLib_GetIcon(IcoBtnOpen,0),
16,16,0,hbr,DI_NORMAL);
end;
@@ -135,7 +135,7 @@ begin
else
tmp:=IcoBtnOn;
DrawIconEx(PDRAWITEMSTRUCT(lParam)^.hDC,0,0,
- CallService(MS_SKIN2_GETICON,0,TLPARAM(tmp)),
+ IcoLib_GetIcon(tmp,0),
16,16,0,hbr,DI_NORMAL);
end;
end;
@@ -232,7 +232,7 @@ begin
begin
cbSize :=SizeOf(Frame);
hWnd :=FrameWnd;
- hIcon :=CallService(MS_SKIN2_GETICON,0,lparam(IcoBtnSettings));
+ hIcon :=IcoLib_GetIcon(IcoBtnSettings,0);
align :=alTop;
height :=tr.bottom-tr.top+2;
Flags :=F_VISIBLE or F_NOBORDER or F_UNICODE;
diff --git a/protocols/AimOscar/src/theme.cpp b/protocols/AimOscar/src/theme.cpp
index b9449f78fb..6d99b8d563 100644
--- a/protocols/AimOscar/src/theme.cpp
+++ b/protocols/AimOscar/src/theme.cpp
@@ -60,14 +60,14 @@ void InitIcons(void)
Icon_Register(hInstance, "Protocols/AIM/"LPGEN("Profile Editor"), iconList+14, 14, "AIM");
}
-HICON LoadIconEx(const char* name, bool big)
+HICON LoadIconEx(const char *name, bool big)
{
char szSettingName[100];
mir_snprintf(szSettingName, SIZEOF(szSettingName), "AIM_%s", name);
- return Skin_GetIcon(szSettingName, big);
+ return IcoLib_GetIcon(szSettingName, big);
}
-HANDLE GetIconHandle(const char* name)
+HANDLE GetIconHandle(const char *name)
{
for (int i=0; i < SIZEOF(iconList); i++)
if ( !mir_strcmp(iconList[i].szName, name))
@@ -76,25 +76,19 @@ HANDLE GetIconHandle(const char* name)
return NULL;
}
-void ReleaseIconEx(const char* name, bool big)
+void ReleaseIconEx(const char *name, bool big)
{
char szSettingName[100];
mir_snprintf(szSettingName, SIZEOF(szSettingName ), "%s_%s", "AIM", name);
- Skin_ReleaseIcon(szSettingName, big);
+ IcoLib_Release(szSettingName, big);
}
-void WindowSetIcon(HWND hWnd, const char* name)
+void Window_SetIcon(HWND hWnd, const char* name)
{
SendMessage(hWnd, WM_SETICON, ICON_BIG, (LPARAM)LoadIconEx( name, true ));
SendMessage(hWnd, WM_SETICON, ICON_SMALL, (LPARAM)LoadIconEx( name ));
}
-void WindowFreeIcon(HWND hWnd)
-{
- Skin_ReleaseIcon((HICON)SendMessage(hWnd, WM_SETICON, ICON_BIG, 0));
- Skin_ReleaseIcon((HICON)SendMessage(hWnd, WM_SETICON, ICON_SMALL, 0));
-}
-
/////////////////////////////////////////////////////////////////////////////////////////
// Extra Icons
diff --git a/protocols/AimOscar/src/theme.h b/protocols/AimOscar/src/theme.h
index e2e6531174..70baf03d61 100644
--- a/protocols/AimOscar/src/theme.h
+++ b/protocols/AimOscar/src/theme.h
@@ -22,11 +22,11 @@ along with this program. If not, see <http://www.gnu.org/licenses/>.
void InitIcons(void);
void InitExtraIcons(void);
-HICON LoadIconEx(const char* name, bool big = false);
-HANDLE GetIconHandle(const char* name);
-void ReleaseIconEx(const char* name, bool big = false);
-void WindowSetIcon(HWND hWnd, const char* name);
-void WindowFreeIcon(HWND hWnd);
+HICON LoadIconEx(const char *name, bool big = false);
+HANDLE GetIconHandle(const char *name);
+void ReleaseIconEx(const char *name, bool big = false);
+
+void Window_SetIcon(HWND hWnd, const char *name);
void add_AT_icons(CAimProto* ppro);
void remove_AT_icons(CAimProto* ppro);
diff --git a/protocols/AimOscar/src/ui.cpp b/protocols/AimOscar/src/ui.cpp
index 597501892f..4904e134eb 100644
--- a/protocols/AimOscar/src/ui.cpp
+++ b/protocols/AimOscar/src/ui.cpp
@@ -1131,7 +1131,7 @@ INT_PTR CAimProto::SvcCreateAccMgrUI(WPARAM, LPARAM lParam)
INT_PTR CALLBACK instant_idle_dialog(HWND hwndDlg, UINT msg, WPARAM wParam, LPARAM lParam)
{
- CAimProto* ppro = (CAimProto*)GetWindowLongPtr(hwndDlg, GWLP_USERDATA);
+ CAimProto *ppro = (CAimProto*)GetWindowLongPtr(hwndDlg, GWLP_USERDATA);
switch (msg) {
case WM_INITDIALOG:
@@ -1140,7 +1140,7 @@ INT_PTR CALLBACK instant_idle_dialog(HWND hwndDlg, UINT msg, WPARAM wParam, LPAR
SetWindowLongPtr(hwndDlg, GWLP_USERDATA, lParam);
ppro = (CAimProto*)lParam;
{
- WindowSetIcon(hwndDlg, "idle");
+ Window_SetIcon(hwndDlg, "idle");
unsigned long it = ppro->getDword(AIM_KEY_IIT, 0);
unsigned long hours = it / 60;
unsigned long minutes = it % 60;
@@ -1154,7 +1154,7 @@ INT_PTR CALLBACK instant_idle_dialog(HWND hwndDlg, UINT msg, WPARAM wParam, LPAR
break;
case WM_DESTROY:
- WindowFreeIcon(hwndDlg);
+ Window_FreeIcon_IcoLib(hwndDlg);
break;
case WM_COMMAND:
@@ -1201,7 +1201,7 @@ INT_PTR CALLBACK join_chat_dialog(HWND hwndDlg, UINT msg, WPARAM wParam, LPARAM
SetWindowLongPtr(hwndDlg, GWLP_USERDATA, lParam);
ppro = (CAimProto*)lParam;
- WindowSetIcon(hwndDlg, "aol");
+ Window_SetIcon(hwndDlg, "aol");
break;
case WM_CLOSE:
@@ -1209,7 +1209,7 @@ INT_PTR CALLBACK join_chat_dialog(HWND hwndDlg, UINT msg, WPARAM wParam, LPARAM
break;
case WM_DESTROY:
- WindowFreeIcon(hwndDlg);
+ Window_FreeIcon_IcoLib(hwndDlg);
break;
case WM_COMMAND:
@@ -1310,7 +1310,7 @@ INT_PTR CALLBACK invite_to_chat_dialog(HWND hwndDlg, UINT msg, WPARAM wParam, LP
SetWindowLongPtr(hwndDlg, GWLP_USERDATA, lParam);
param = (invite_chat_param*)lParam;
- WindowSetIcon(hwndDlg, "aol");
+ Window_SetIcon(hwndDlg, "aol");
SetDlgItemTextA(hwndDlg, IDC_ROOMNAME, param->id);
SetDlgItemTextA(hwndDlg, IDC_MSG, Translate("Join me in this buddy chat!"));
break;
@@ -1320,7 +1320,7 @@ INT_PTR CALLBACK invite_to_chat_dialog(HWND hwndDlg, UINT msg, WPARAM wParam, LP
break;
case WM_NCDESTROY:
- WindowFreeIcon(hwndDlg);
+ Window_FreeIcon_IcoLib(hwndDlg);
delete param;
break;
@@ -1399,7 +1399,7 @@ INT_PTR CALLBACK chat_request_dialog(HWND hwndDlg, UINT msg, WPARAM wParam, LPAR
SetWindowLongPtr(hwndDlg, GWLP_USERDATA, lParam);
param = (invite_chat_req_param*)lParam;
- WindowSetIcon(hwndDlg, "aol");
+ Window_SetIcon(hwndDlg, "aol");
SetDlgItemTextA(hwndDlg, IDC_ROOMNAME, strrchr(param->cnp->id, '-') + 1);
SetDlgItemTextA(hwndDlg, IDC_SCREENNAME, param->name);
@@ -1411,7 +1411,7 @@ INT_PTR CALLBACK chat_request_dialog(HWND hwndDlg, UINT msg, WPARAM wParam, LPAR
break;
case WM_DESTROY:
- WindowFreeIcon(hwndDlg);
+ Window_FreeIcon_IcoLib(hwndDlg);
delete param;
break;
diff --git a/protocols/Dummy/src/dummy_options.cpp b/protocols/Dummy/src/dummy_options.cpp
index c667bd5fff..279140bc29 100644
--- a/protocols/Dummy/src/dummy_options.cpp
+++ b/protocols/Dummy/src/dummy_options.cpp
@@ -31,8 +31,8 @@ INT_PTR CALLBACK DummyAccountProc(HWND hwndDlg, UINT uMsg, WPARAM wParam, LPARAM
ppro = (CDummyProto*)lParam;
SetWindowLongPtr( hwndDlg, GWLP_USERDATA, lParam );
- SendMessage(hwndDlg, WM_SETICON, ICON_BIG, (LPARAM)Skin_GetIconByHandle(ppro->m_hProtoIcon, true));
- SendMessage(hwndDlg, WM_SETICON, ICON_SMALL, (LPARAM)Skin_GetIconByHandle(ppro->m_hProtoIcon));
+ SendMessage(hwndDlg, WM_SETICON, ICON_BIG, (LPARAM)IcoLib_GetIconByHandle(ppro->m_hProtoIcon, true));
+ SendMessage(hwndDlg, WM_SETICON, ICON_SMALL, (LPARAM)IcoLib_GetIconByHandle(ppro->m_hProtoIcon));
{
ptrA tszIdText(ppro->getStringA(DUMMY_ID_TEXT));
if (tszIdText != NULL)
@@ -72,8 +72,8 @@ INT_PTR CALLBACK DummyAccountProc(HWND hwndDlg, UINT uMsg, WPARAM wParam, LPARAM
break;
case WM_DESTROY:
- Skin_ReleaseIcon((HICON)SendMessage(hwndDlg, WM_GETICON, ICON_BIG, 0));
- Skin_ReleaseIcon((HICON)SendMessage(hwndDlg, WM_GETICON, ICON_SMALL, 0));
+ IcoLib_ReleaseIcon((HICON)SendMessage(hwndDlg, WM_GETICON, ICON_BIG, 0));
+ IcoLib_ReleaseIcon((HICON)SendMessage(hwndDlg, WM_GETICON, ICON_SMALL, 0));
break;
}
diff --git a/protocols/FacebookRM/src/captcha.cpp b/protocols/FacebookRM/src/captcha.cpp
index d526d06623..4ff4a2faa9 100644
--- a/protocols/FacebookRM/src/captcha.cpp
+++ b/protocols/FacebookRM/src/captcha.cpp
@@ -39,8 +39,8 @@ static INT_PTR CALLBACK CaptchaFormDlgProc(HWND hwndDlg, UINT msg, WPARAM wParam
switch (msg) {
case WM_INITDIALOG: {
TranslateDialogDefault(hwndDlg);
- SendMessage(hwndDlg, WM_SETICON, ICON_BIG, (LPARAM)Skin_GetIconByHandle(GetIconHandle("key"), TRUE));
- SendMessage(hwndDlg, WM_SETICON, ICON_SMALL, (LPARAM)Skin_GetIconByHandle(GetIconHandle("key")));
+ SendMessage(hwndDlg, WM_SETICON, ICON_BIG, (LPARAM)IcoLib_GetIconByHandle(GetIconHandle("key"), TRUE));
+ SendMessage(hwndDlg, WM_SETICON, ICON_SMALL, (LPARAM)IcoLib_GetIconByHandle(GetIconHandle("key")));
params = (CAPTCHA_FORM_PARAMS*)lParam;
SetDlgItemText(hwndDlg, IDC_INSTRUCTION, TranslateT("Enter the text you see"));
@@ -96,8 +96,8 @@ static INT_PTR CALLBACK CaptchaFormDlgProc(HWND hwndDlg, UINT msg, WPARAM wParam
break;
case WM_DESTROY:
- Skin_ReleaseIcon((HICON)SendMessage(hwndDlg, WM_SETICON, ICON_BIG, 0));
- Skin_ReleaseIcon((HICON)SendMessage(hwndDlg, WM_SETICON, ICON_SMALL, 0));
+ IcoLib_ReleaseIcon((HICON)SendMessage(hwndDlg, WM_SETICON, ICON_BIG, 0));
+ IcoLib_ReleaseIcon((HICON)SendMessage(hwndDlg, WM_SETICON, ICON_SMALL, 0));
break;
}
return FALSE;
diff --git a/protocols/FacebookRM/src/dialogs.cpp b/protocols/FacebookRM/src/dialogs.cpp
index 210a449644..3610b5d19f 100644
--- a/protocols/FacebookRM/src/dialogs.cpp
+++ b/protocols/FacebookRM/src/dialogs.cpp
@@ -193,7 +193,7 @@ INT_PTR CALLBACK FBMindProc(HWND hwnd, UINT message, WPARAM wparam, LPARAM lpara
{
TranslateDialogDefault(hwnd);
- SendMessage(hwnd, WM_SETICON, ICON_SMALL, (LPARAM)Skin_GetIconByHandle(GetIconHandle("mind")));
+ SendMessage(hwnd, WM_SETICON, ICON_SMALL, (LPARAM)IcoLib_GetIconByHandle(GetIconHandle("mind")));
data = reinterpret_cast<post_status_data*>(lparam);
diff --git a/protocols/FacebookRM/src/proto.cpp b/protocols/FacebookRM/src/proto.cpp
index 1170c298be..c88b030eba 100644
--- a/protocols/FacebookRM/src/proto.cpp
+++ b/protocols/FacebookRM/src/proto.cpp
@@ -536,7 +536,7 @@ int FacebookProto::OnToolbarInit(WPARAM, LPARAM)
ttb.pszService = service;
ttb.pszTooltipUp = ttb.name = LPGEN("Share status...");
- ttb.hIconHandleUp = Skin_GetIconByHandle(GetIconHandle("mind"));
+ ttb.hIconHandleUp = IcoLib_GetIconByHandle(GetIconHandle("mind"));
TopToolbar_AddButton(&ttb);
return 0;
@@ -995,7 +995,7 @@ void FacebookProto::InitPopups()
mir_snprintf(name, "%s_%s", m_szModuleName, "Client");
ppc.ptszDescription = desc;
ppc.pszName = name;
- ppc.hIcon = Skin_GetIconByHandle(GetIconHandle("facebook"));
+ ppc.hIcon = IcoLib_GetIconByHandle(GetIconHandle("facebook"));
ppc.colorBack = RGB(191, 0, 0); // red
ppc.colorText = RGB(255, 255, 255); // white
ppc.iSeconds = 0;
@@ -1006,7 +1006,7 @@ void FacebookProto::InitPopups()
mir_snprintf(name, "%s_%s", m_szModuleName, "Newsfeed");
ppc.ptszDescription = desc;
ppc.pszName = name;
- ppc.hIcon = Skin_GetIconByHandle(GetIconHandle("newsfeed"));
+ ppc.hIcon = IcoLib_GetIconByHandle(GetIconHandle("newsfeed"));
ppc.colorBack = RGB(255, 255, 255); // white
ppc.colorText = RGB(0, 0, 0); // black
ppc.iSeconds = 0;
@@ -1017,7 +1017,7 @@ void FacebookProto::InitPopups()
mir_snprintf(name, "%s_%s", m_szModuleName, "Notification");
ppc.ptszDescription = desc;
ppc.pszName = name;
- ppc.hIcon = Skin_GetIconByHandle(GetIconHandle("notification"));
+ ppc.hIcon = IcoLib_GetIconByHandle(GetIconHandle("notification"));
ppc.colorBack = RGB(59, 89, 152); // Facebook's blue
ppc.colorText = RGB(255, 255, 255); // white
ppc.iSeconds = 0;
@@ -1028,7 +1028,7 @@ void FacebookProto::InitPopups()
mir_snprintf(name, "%s_%s", m_szModuleName, "Other");
ppc.ptszDescription = desc;
ppc.pszName = name;
- ppc.hIcon = Skin_GetIconByHandle(GetIconHandle("facebook"));
+ ppc.hIcon = IcoLib_GetIconByHandle(GetIconHandle("facebook"));
ppc.colorBack = RGB(255, 255, 255); // white
ppc.colorText = RGB(0, 0, 0); // black
ppc.iSeconds = 0;
@@ -1039,7 +1039,7 @@ void FacebookProto::InitPopups()
mir_snprintf(name, "%s_%s", m_szModuleName, "Friendship");
ppc.ptszDescription = desc;
ppc.pszName = name;
- ppc.hIcon = Skin_GetIconByHandle(GetIconHandle("friendship"));
+ ppc.hIcon = IcoLib_GetIconByHandle(GetIconHandle("friendship"));
ppc.colorBack = RGB(47, 71, 122); // Facebook's darker blue
ppc.colorText = RGB(255, 255, 255); // white
ppc.iSeconds = 0;
@@ -1050,7 +1050,7 @@ void FacebookProto::InitPopups()
mir_snprintf(name, "%s_%s", m_szModuleName, "Ticker");
ppc.ptszDescription = desc;
ppc.pszName = name;
- ppc.hIcon = Skin_GetIconByHandle(GetIconHandle("newsfeed"));
+ ppc.hIcon = IcoLib_GetIconByHandle(GetIconHandle("newsfeed"));
ppc.colorBack = RGB(255, 255, 255); // white
ppc.colorText = RGB(0, 0, 0); // black
ppc.iSeconds = 0;
@@ -1061,7 +1061,7 @@ void FacebookProto::InitPopups()
mir_snprintf(name, "%s_%s", m_szModuleName, "OnThisDay");
ppc.ptszDescription = desc;
ppc.pszName = name;
- ppc.hIcon = Skin_GetIconByHandle(GetIconHandle("newsfeed"));
+ ppc.hIcon = IcoLib_GetIconByHandle(GetIconHandle("newsfeed"));
ppc.colorBack = RGB(255, 255, 255); // white
ppc.colorText = RGB(0, 0, 0); // black
ppc.iSeconds = 0;
@@ -1129,7 +1129,7 @@ void FacebookProto::MessageRead(MCONTACT hContact)
StatusTextData st = { 0 };
st.cbSize = sizeof(st);
- st.hIcon = Skin_GetIconByHandle(GetIconHandle("read"));
+ st.hIcon = IcoLib_GetIconByHandle(GetIconHandle("read"));
if (isChatRoom(hContact)) {
// Load readers names
diff --git a/protocols/Gadu-Gadu/Gadu-Gadu_10.vcxproj b/protocols/Gadu-Gadu/Gadu-Gadu_10.vcxproj
index 9be0294100..25a5fd62fe 100644
--- a/protocols/Gadu-Gadu/Gadu-Gadu_10.vcxproj
+++ b/protocols/Gadu-Gadu/Gadu-Gadu_10.vcxproj
@@ -83,7 +83,6 @@
<WarningLevel>Level3</WarningLevel>
<DebugInformationFormat>EditAndContinue</DebugInformationFormat>
<DisableSpecificWarnings>4996;%(DisableSpecificWarnings)</DisableSpecificWarnings>
- <ExceptionHandling>false</ExceptionHandling>
</ClCompile>
<ResourceCompile>
<PreprocessorDefinitions>_DEBUG;%(PreprocessorDefinitions)</PreprocessorDefinitions>
@@ -112,7 +111,6 @@
<PrecompiledHeaderFile>gg.h</PrecompiledHeaderFile>
<WarningLevel>Level3</WarningLevel>
<DisableSpecificWarnings>4996;%(DisableSpecificWarnings)</DisableSpecificWarnings>
- <ExceptionHandling>false</ExceptionHandling>
</ClCompile>
<ResourceCompile>
<PreprocessorDefinitions>_DEBUG;%(PreprocessorDefinitions)</PreprocessorDefinitions>
@@ -143,7 +141,6 @@
<PrecompiledHeaderFile>gg.h</PrecompiledHeaderFile>
<WarningLevel>Level3</WarningLevel>
<DisableSpecificWarnings>4996;%(DisableSpecificWarnings)</DisableSpecificWarnings>
- <ExceptionHandling>false</ExceptionHandling>
</ClCompile>
<ResourceCompile>
<PreprocessorDefinitions>NDEBUG;%(PreprocessorDefinitions)</PreprocessorDefinitions>
@@ -177,7 +174,6 @@
<PrecompiledHeaderFile>gg.h</PrecompiledHeaderFile>
<WarningLevel>Level3</WarningLevel>
<DisableSpecificWarnings>4996;%(DisableSpecificWarnings)</DisableSpecificWarnings>
- <ExceptionHandling>false</ExceptionHandling>
</ClCompile>
<ResourceCompile>
<PreprocessorDefinitions>NDEBUG;%(PreprocessorDefinitions)</PreprocessorDefinitions>
diff --git a/protocols/Gadu-Gadu/Gadu-Gadu_12.vcxproj b/protocols/Gadu-Gadu/Gadu-Gadu_12.vcxproj
index f0ee1e4275..e2c3e076ee 100644
--- a/protocols/Gadu-Gadu/Gadu-Gadu_12.vcxproj
+++ b/protocols/Gadu-Gadu/Gadu-Gadu_12.vcxproj
@@ -87,7 +87,6 @@
<WarningLevel>Level3</WarningLevel>
<DebugInformationFormat>EditAndContinue</DebugInformationFormat>
<DisableSpecificWarnings>4996;%(DisableSpecificWarnings)</DisableSpecificWarnings>
- <ExceptionHandling>false</ExceptionHandling>
</ClCompile>
<ResourceCompile>
<PreprocessorDefinitions>_DEBUG;%(PreprocessorDefinitions)</PreprocessorDefinitions>
@@ -117,7 +116,6 @@
<PrecompiledHeaderFile>gg.h</PrecompiledHeaderFile>
<WarningLevel>Level3</WarningLevel>
<DisableSpecificWarnings>4996;%(DisableSpecificWarnings)</DisableSpecificWarnings>
- <ExceptionHandling>false</ExceptionHandling>
</ClCompile>
<ResourceCompile>
<PreprocessorDefinitions>_DEBUG;%(PreprocessorDefinitions)</PreprocessorDefinitions>
@@ -148,7 +146,6 @@
<PrecompiledHeaderFile>gg.h</PrecompiledHeaderFile>
<WarningLevel>Level3</WarningLevel>
<DisableSpecificWarnings>4996;%(DisableSpecificWarnings)</DisableSpecificWarnings>
- <ExceptionHandling>false</ExceptionHandling>
</ClCompile>
<ResourceCompile>
<PreprocessorDefinitions>NDEBUG;%(PreprocessorDefinitions)</PreprocessorDefinitions>
@@ -181,7 +178,6 @@
<PrecompiledHeaderFile>gg.h</PrecompiledHeaderFile>
<WarningLevel>Level3</WarningLevel>
<DisableSpecificWarnings>4996;%(DisableSpecificWarnings)</DisableSpecificWarnings>
- <ExceptionHandling>false</ExceptionHandling>
</ClCompile>
<ResourceCompile>
<PreprocessorDefinitions>NDEBUG;%(PreprocessorDefinitions)</PreprocessorDefinitions>
diff --git a/protocols/Gadu-Gadu/src/gg.h b/protocols/Gadu-Gadu/src/gg.h
index c93923b8a4..a2b2525ef3 100644
--- a/protocols/Gadu-Gadu/src/gg.h
+++ b/protocols/Gadu-Gadu/src/gg.h
@@ -322,9 +322,9 @@ char *gg_avatarhash(char *param);
/* IcoLib functions */
void gg_icolib_init();
-HICON LoadIconEx(const char* name, BOOL big);
+HICON LoadIconEx(const char* name, bool big);
HANDLE GetIconHandle(int iconId);
-void ReleaseIconEx(const char* name, BOOL big);
+void ReleaseIconEx(const char* name, bool big);
void WindowSetIcon(HWND hWnd, const char* name);
void WindowFreeIcon(HWND hWnd);
diff --git a/protocols/Gadu-Gadu/src/icolib.cpp b/protocols/Gadu-Gadu/src/icolib.cpp
index b50d305a5d..a0b9c291de 100644
--- a/protocols/Gadu-Gadu/src/icolib.cpp
+++ b/protocols/Gadu-Gadu/src/icolib.cpp
@@ -48,11 +48,11 @@ void gg_icolib_init()
Icon_Register(hInstance, "Protocols/" GGDEF_PROTO, iconList, SIZEOF(iconList), GGDEF_PROTO);
}
-HICON LoadIconEx(const char* name, BOOL big)
+HICON LoadIconEx(const char* name, bool big)
{
char szSettingName[100];
mir_snprintf(szSettingName, SIZEOF(szSettingName), "%s_%s", GGDEF_PROTO, name);
- return Skin_GetIcon(szSettingName, big);
+ return IcoLib_GetIcon(szSettingName, big);
}
HANDLE GetIconHandle(int iconId)
@@ -63,11 +63,11 @@ HANDLE GetIconHandle(int iconId)
return NULL;
}
-void ReleaseIconEx(const char* name, BOOL big)
+void ReleaseIconEx(const char* name, bool big)
{
char szSettingName[100];
mir_snprintf(szSettingName, SIZEOF(szSettingName), "%s_%s", GGDEF_PROTO, name);
- Skin_ReleaseIcon(szSettingName, big);
+ IcoLib_Release(szSettingName, big);
}
void WindowSetIcon(HWND hWnd, const char* name)
@@ -78,6 +78,6 @@ void WindowSetIcon(HWND hWnd, const char* name)
void WindowFreeIcon(HWND hWnd)
{
- Skin_ReleaseIcon((HICON)SendMessage(hWnd, WM_SETICON, ICON_BIG, 0));
- Skin_ReleaseIcon((HICON)SendMessage(hWnd, WM_SETICON, ICON_SMALL, 0));
+ IcoLib_ReleaseIcon((HICON)SendMessage(hWnd, WM_SETICON, ICON_BIG, 0));
+ IcoLib_ReleaseIcon((HICON)SendMessage(hWnd, WM_SETICON, ICON_SMALL, 0));
}
diff --git a/protocols/Gadu-Gadu/src/links.cpp b/protocols/Gadu-Gadu/src/links.cpp
index 637001281d..c9407b2473 100644
--- a/protocols/Gadu-Gadu/src/links.cpp
+++ b/protocols/Gadu-Gadu/src/links.cpp
@@ -74,7 +74,7 @@ static INT_PTR gg_parselink(WPARAM wParam, LPARAM lParam)
Menu_ModifyItem(gg->hInstanceMenuItem, &mi);
if (mi.hIcon)
- Skin_ReleaseIcon(mi.hIcon);
+ IcoLib_ReleaseIcon(mi.hIcon);
}
if (items > 1) {
diff --git a/protocols/IRCG/src/options.cpp b/protocols/IRCG/src/options.cpp
index 5bd7ac5427..5ca6da4826 100644
--- a/protocols/IRCG/src/options.cpp
+++ b/protocols/IRCG/src/options.cpp
@@ -214,7 +214,7 @@ HICON LoadIconEx(int iconId, bool big)
{
for (int i = 0; i < SIZEOF(iconList); i++)
if (iconList[i].defIconID == iconId)
- return Skin_GetIconByHandle(iconList[i].hIcolib, big);
+ return IcoLib_GetIconByHandle(iconList[i].hIcolib, big);
return NULL;
}
@@ -231,7 +231,7 @@ HANDLE GetIconHandle(int iconId)
void ReleaseIconEx(HICON hIcon)
{
if (hIcon)
- Skin_ReleaseIcon(hIcon);
+ IcoLib_ReleaseIcon(hIcon);
}
void WindowSetIcon(HWND hWnd, int iconId)
diff --git a/protocols/IcqOscarJ/src/icq_firstrun.cpp b/protocols/IcqOscarJ/src/icq_firstrun.cpp
index b223911eb4..cf065c1664 100644
--- a/protocols/IcqOscarJ/src/icq_firstrun.cpp
+++ b/protocols/IcqOscarJ/src/icq_firstrun.cpp
@@ -50,8 +50,8 @@ INT_PTR CALLBACK icq_FirstRunDlgProc(HWND hwndDlg, UINT msg, WPARAM wParam, LPAR
ppro = (CIcqProto*)lParam;
SetWindowLongPtr( hwndDlg, GWLP_USERDATA, lParam );
- SendMessage(hwndDlg, WM_SETICON, ICON_BIG, (LPARAM)Skin_GetIconByHandle(ppro->m_hProtoIcon, true));
- SendMessage(hwndDlg, WM_SETICON, ICON_SMALL, (LPARAM)Skin_GetIconByHandle(ppro->m_hProtoIcon));
+ SendMessage(hwndDlg, WM_SETICON, ICON_BIG, (LPARAM)IcoLib_GetIconByHandle(ppro->m_hProtoIcon, true));
+ SendMessage(hwndDlg, WM_SETICON, ICON_SMALL, (LPARAM)IcoLib_GetIconByHandle(ppro->m_hProtoIcon));
SendDlgItemMessage(hwndDlg, IDC_PW, EM_LIMITTEXT, PASSWORDMAXLEN - 1, 0);
@@ -59,8 +59,8 @@ INT_PTR CALLBACK icq_FirstRunDlgProc(HWND hwndDlg, UINT msg, WPARAM wParam, LPAR
return TRUE;
case WM_DESTROY:
- Skin_ReleaseIcon((HICON)SendMessage(hwndDlg, WM_GETICON, ICON_BIG, 0));
- Skin_ReleaseIcon((HICON)SendMessage(hwndDlg, WM_GETICON, ICON_SMALL, 0));
+ IcoLib_ReleaseIcon((HICON)SendMessage(hwndDlg, WM_GETICON, ICON_BIG, 0));
+ IcoLib_ReleaseIcon((HICON)SendMessage(hwndDlg, WM_GETICON, ICON_SMALL, 0));
break;
case WM_CLOSE:
diff --git a/protocols/IcqOscarJ/src/icq_popups.cpp b/protocols/IcqOscarJ/src/icq_popups.cpp
index ae86931ce7..7c74c31169 100644
--- a/protocols/IcqOscarJ/src/icq_popups.cpp
+++ b/protocols/IcqOscarJ/src/icq_popups.cpp
@@ -248,7 +248,7 @@ int CIcqProto::ShowPopupMsg(MCONTACT hContact, const char *szTitle, const char *
return -1;
}
if (!getByte("PopupsSysIcons", DEFAULT_POPUPS_SYS_ICONS))
- ppd.lchIcon = Skin_GetIconByHandle(m_hProtoIcon);
+ ppd.lchIcon = IcoLib_GetIconByHandle(m_hProtoIcon);
else
ppd.lchIcon = (HICON)LoadImage( NULL, rsIcon, IMAGE_ICON, GetSystemMetrics(SM_CXSMICON), GetSystemMetrics(SM_CYSMICON), LR_SHARED);
diff --git a/protocols/IcqOscarJ/src/icq_xstatus.cpp b/protocols/IcqOscarJ/src/icq_xstatus.cpp
index 0315bd3c01..0e040ddb91 100644
--- a/protocols/IcqOscarJ/src/icq_xstatus.cpp
+++ b/protocols/IcqOscarJ/src/icq_xstatus.cpp
@@ -165,7 +165,7 @@ HICON CIcqProto::getXStatusIcon(int bStatus, UINT flags)
HICON icon = NULL;
if (bStatus > 0 && bStatus <= XSTATUS_COUNT)
- icon = Skin_GetIconByHandle(hXStatusIcons[bStatus-1], (flags & LR_BIGICON) != 0);
+ icon = IcoLib_GetIconByHandle(hXStatusIcons[bStatus-1], (flags & LR_BIGICON) != 0);
return (flags & LR_SHARED || !icon) ? icon : CopyIcon(icon);
}
@@ -756,8 +756,8 @@ static INT_PTR CALLBACK SetXStatusDlgProc(HWND hwndDlg,UINT message,WPARAM wPara
SAFE_FREE(&szValue);
if (dat->bXStatus) {
- Skin_ReleaseIcon((HICON)SendMessage(hwndDlg, WM_GETICON, ICON_BIG, 0));
- Skin_ReleaseIcon((HICON)SendMessage(hwndDlg, WM_GETICON, ICON_SMALL, 0));
+ IcoLib_ReleaseIcon((HICON)SendMessage(hwndDlg, WM_GETICON, ICON_BIG, 0));
+ IcoLib_ReleaseIcon((HICON)SendMessage(hwndDlg, WM_GETICON, ICON_SMALL, 0));
}
}
dat->ppro->updateServerCustomStatus(TRUE);
@@ -901,7 +901,7 @@ void InitXStatusIcons()
sid.pszName = szTemp;
sid.description.a = (LPSTR)nameXStatus[i];
sid.iDefaultIndex = -(IDI_XSTATUS1+i);
- hXStatusIcons[i] = Skin_AddIcon(&sid);
+ hXStatusIcons[i] = IcoLib_AddIcon(&sid);
}
// initialize arrays for CList custom status icons
@@ -1120,7 +1120,7 @@ INT_PTR CIcqProto::RequestAdvStatusIconIdx(WPARAM wParam, LPARAM)
// mark icon index in the array as valid
bXStatusCListIconsValid[bXStatus-1] = TRUE;
- Skin_ReleaseIcon(hXStatusIcon);
+ IcoLib_ReleaseIcon(hXStatusIcon);
}
}
diff --git a/protocols/IcqOscarJ/src/loginpassword.cpp b/protocols/IcqOscarJ/src/loginpassword.cpp
index 6268f76665..c7a448b11f 100644
--- a/protocols/IcqOscarJ/src/loginpassword.cpp
+++ b/protocols/IcqOscarJ/src/loginpassword.cpp
@@ -36,8 +36,8 @@ INT_PTR CALLBACK LoginPasswdDlgProc(HWND hwndDlg, UINT msg, WPARAM wParam, LPARA
ppro = (CIcqProto*)lParam;
SetWindowLongPtr( hwndDlg, GWLP_USERDATA, lParam );
- SendMessage(hwndDlg, WM_SETICON, ICON_BIG, (LPARAM)Skin_GetIconByHandle(ppro->m_hProtoIcon, true));
- SendMessage(hwndDlg, WM_SETICON, ICON_SMALL, (LPARAM)Skin_GetIconByHandle(ppro->m_hProtoIcon));
+ SendMessage(hwndDlg, WM_SETICON, ICON_BIG, (LPARAM)IcoLib_GetIconByHandle(ppro->m_hProtoIcon, true));
+ SendMessage(hwndDlg, WM_SETICON, ICON_SMALL, (LPARAM)IcoLib_GetIconByHandle(ppro->m_hProtoIcon));
{
DWORD dwUin = ppro->getContactUin(NULL);
@@ -52,8 +52,8 @@ INT_PTR CALLBACK LoginPasswdDlgProc(HWND hwndDlg, UINT msg, WPARAM wParam, LPARA
break;
case WM_DESTROY:
- Skin_ReleaseIcon((HICON)SendMessage(hwndDlg, WM_GETICON, ICON_BIG, 0));
- Skin_ReleaseIcon((HICON)SendMessage(hwndDlg, WM_GETICON, ICON_SMALL, 0));
+ IcoLib_ReleaseIcon((HICON)SendMessage(hwndDlg, WM_GETICON, ICON_BIG, 0));
+ IcoLib_ReleaseIcon((HICON)SendMessage(hwndDlg, WM_GETICON, ICON_SMALL, 0));
break;
case WM_CLOSE:
diff --git a/protocols/JabberG/src/jabber_frame.cpp b/protocols/JabberG/src/jabber_frame.cpp
index 150b22e5d4..6c951d2cd7 100644
--- a/protocols/JabberG/src/jabber_frame.cpp
+++ b/protocols/JabberG/src/jabber_frame.cpp
@@ -360,7 +360,7 @@ void CJabberInfoFrame::PaintCompact(HDC hdc)
if (depth == 0) {
if (item.m_hIcolibIcon) {
- HICON hIcon = Skin_GetIconByHandle(item.m_hIcolibIcon);
+ HICON hIcon = IcoLib_GetIconByHandle(item.m_hIcolibIcon);
if (hIcon) {
DrawIconEx(hdc, SZ_FRAMEPADDING, (rc.bottom-cy_icon)/2, hIcon, cx_icon, cy_icon, 0, NULL, DI_NORMAL);
g_ReleaseIcon(hIcon);
@@ -372,7 +372,7 @@ void CJabberInfoFrame::PaintCompact(HDC hdc)
}
else {
if (item.m_hIcolibIcon) {
- HICON hIcon = Skin_GetIconByHandle(item.m_hIcolibIcon);
+ HICON hIcon = IcoLib_GetIconByHandle(item.m_hIcolibIcon);
if (hIcon) {
SetRect(&item.m_rcItem, cx, (rc.bottom-cy_icon)/2, cx+cx_icon, (rc.bottom-cy_icon)/2+cy_icon);
DrawIconEx(hdc, cx, (rc.bottom-cy_icon)/2, hIcon, cx_icon, cy_icon, 0, NULL, DI_NORMAL);
@@ -418,7 +418,7 @@ void CJabberInfoFrame::PaintNormal(HDC hdc)
SetRect(&item.m_rcItem, cx, cy, rc.right - SZ_FRAMEPADDING, cy + line_height);
if (item.m_hIcolibIcon) {
- HICON hIcon = Skin_GetIconByHandle(item.m_hIcolibIcon);
+ HICON hIcon = IcoLib_GetIconByHandle(item.m_hIcolibIcon);
if (hIcon) {
DrawIconEx(hdc, cx, cy + (line_height-cy_icon)/2, hIcon, cx_icon, cy_icon, 0, NULL, DI_NORMAL);
cx += cx_icon + SZ_ICONSPACING;
diff --git a/protocols/JabberG/src/jabber_icolib.cpp b/protocols/JabberG/src/jabber_icolib.cpp
index 6ce5f2385c..22e03e489f 100644
--- a/protocols/JabberG/src/jabber_icolib.cpp
+++ b/protocols/JabberG/src/jabber_icolib.cpp
@@ -94,7 +94,7 @@ CIconPool::CPoolItem::CPoolItem():
CIconPool::CPoolItem::~CPoolItem()
{
if (m_hIcolibItem && m_szIcolibName) {
- CallService(MS_SKIN2_REMOVEICON, 0, (LPARAM)m_szIcolibName);
+ IcoLib_RemoveIcon(m_szIcolibName);
mir_free(m_szIcolibName);
}
@@ -126,7 +126,7 @@ void CIconPool::RegisterIcon(const char *name, TCHAR *filename, int iconid, TCHA
sid.description.t = szDescription;
sid.flags = SIDF_ALL_TCHAR;
sid.iDefaultIndex = iconid;
- item->m_hIcolibItem = Skin_AddIcon(&sid);
+ item->m_hIcolibItem = IcoLib_AddIcon(&sid);
m_items.insert(item);
}
@@ -150,7 +150,7 @@ char *CIconPool::GetIcolibName(const char *name)
HICON CIconPool::GetIcon(const char *name, bool big)
{
if (CPoolItem *item = FindItemByName(name))
- return Skin_GetIconByHandle(item->m_hIcolibItem, big);
+ return IcoLib_GetIconByHandle(item->m_hIcolibItem, big);
return NULL;
}
@@ -186,7 +186,7 @@ HICON CJabberProto::LoadIconEx(const char* name, bool big)
return result;
if (!mir_strcmp(name, "main"))
- return Skin_GetIconByHandle(m_hProtoIcon, big);
+ return IcoLib_GetIconByHandle(m_hProtoIcon, big);
return NULL;
}
@@ -292,9 +292,9 @@ static HICON LoadTransportIcon(char *filename,int i,char *IconName,TCHAR *SectNa
sid.defaultFile.a = szMyPath;
sid.iDefaultIndex = i;
sid.flags = SIDF_TCHAR;
- Skin_AddIcon(&sid);
+ IcoLib_AddIcon(&sid);
}
- return Skin_GetIcon(IconName);
+ return IcoLib_GetIcon(IconName);
}
static HICON LoadSmallIcon(HINSTANCE hInstance, LPCTSTR lpIconName)
@@ -558,13 +558,13 @@ HICON g_LoadIconEx(const char* name, bool big)
{
char szSettingName[100];
mir_snprintf(szSettingName, SIZEOF(szSettingName), "%s_%s", GLOBAL_SETTING_PREFIX, name);
- return Skin_GetIcon(szSettingName, big);
+ return IcoLib_GetIcon(szSettingName, big);
}
void g_ReleaseIcon(HICON hIcon)
{
if (hIcon)
- Skin_ReleaseIcon(hIcon);
+ IcoLib_ReleaseIcon(hIcon);
}
void ImageList_AddIcon_Icolib(HIMAGELIST hIml, HICON hIcon)
diff --git a/protocols/JabberG/src/jabber_misc.cpp b/protocols/JabberG/src/jabber_misc.cpp
index a51eefa6a2..4fe5a32f0c 100644
--- a/protocols/JabberG/src/jabber_misc.cpp
+++ b/protocols/JabberG/src/jabber_misc.cpp
@@ -477,7 +477,7 @@ void CJabberProto::InitPopups(void)
ppc.iSeconds = 60;
m_hPopupClass = Popup_RegisterClass(&ppc);
- Skin_ReleaseIcon(ppc.hIcon);
+ IcoLib_ReleaseIcon(ppc.hIcon);
}
void CJabberProto::MsgPopup(MCONTACT hContact, const TCHAR *szMsg, const TCHAR *szTitle)
diff --git a/protocols/JabberG/src/jabber_userinfo.cpp b/protocols/JabberG/src/jabber_userinfo.cpp
index 7ac15547a1..9c09e5a415 100644
--- a/protocols/JabberG/src/jabber_userinfo.cpp
+++ b/protocols/JabberG/src/jabber_userinfo.cpp
@@ -323,7 +323,7 @@ static void sttFillAdvStatusInfo(CJabberProto *ppro, HWND hwndTree, HTREEITEM ht
mir_sntprintf(szText, _T("%s (%s)"), TranslateTS(szAdvStatusTitle), szAdvStatusText);
else
_tcsncpy_s(szText, TranslateTS(szAdvStatusTitle), _TRUNCATE);
- sttFillInfoLine(hwndTree, htiRoot, Skin_GetIcon(szAdvStatusIcon), szTitle, szText, dwInfoLine);
+ sttFillInfoLine(hwndTree, htiRoot, IcoLib_GetIcon(szAdvStatusIcon), szTitle, szText, dwInfoLine);
}
mir_free(szAdvStatusIcon);
diff --git a/protocols/MRA/src/MraIcons.cpp b/protocols/MRA/src/MraIcons.cpp
index 0bfe17d19b..ee4ca32b7c 100644
--- a/protocols/MRA/src/MraIcons.cpp
+++ b/protocols/MRA/src/MraIcons.cpp
@@ -53,7 +53,7 @@ HICON IconLibGetIconEx(HANDLE hIcon, DWORD dwFlags)
{
HICON hiIcon = NULL;
if (hIcon) {
- hiIcon = Skin_GetIconByHandle(hIcon);
+ hiIcon = IcoLib_GetIconByHandle(hIcon);
if ((dwFlags & LR_SHARED) == 0)
hiIcon = CopyIcon(hiIcon);
}
@@ -116,7 +116,7 @@ void InitXStatusIcons()
sid.description.t = (TCHAR*)lpcszXStatusNameDef[i];
sid.iDefaultIndex = -iCurIndex;
- hXStatusAdvancedStatusIcons[i] = Skin_AddIcon(&sid);
+ hXStatusAdvancedStatusIcons[i] = IcoLib_AddIcon(&sid);
}
}
@@ -126,7 +126,7 @@ void DestroyXStatusIcons()
for (DWORD i = 1; i < MRA_XSTATUS_COUNT+1; i++) {
mir_snprintf(szBuff, SIZEOF(szBuff), "mra_xstatus%ld", i);
- Skin_RemoveIcon(szBuff);
+ IcoLib_RemoveIcon(szBuff);
}
memset(hXStatusAdvancedStatusIcons, 0, sizeof(hXStatusAdvancedStatusIcons));
diff --git a/protocols/MSN/src/msn_lists.cpp b/protocols/MSN/src/msn_lists.cpp
index 22c1f57fde..e16fc7ce19 100644
--- a/protocols/MSN/src/msn_lists.cpp
+++ b/protocols/MSN/src/msn_lists.cpp
@@ -501,7 +501,7 @@ INT_PTR CALLBACK DlgProcMsnServLists(HWND hwndDlg, UINT msg, WPARAM wParam, LPAR
HICON hIcon = LoadSkinnedIcon(SKINICON_OTHER_SMALLDOT);
ImageList_AddIcon(hIml, hIcon);
- Skin_ReleaseIcon(hIcon);
+ IcoLib_ReleaseIcon(hIcon);
hIcon = LoadIconEx("list_lc");
ImageList_AddIcon(hIml, hIcon);
diff --git a/protocols/MSN/src/msn_opts.cpp b/protocols/MSN/src/msn_opts.cpp
index bd94c90779..c5206af9ed 100644
--- a/protocols/MSN/src/msn_opts.cpp
+++ b/protocols/MSN/src/msn_opts.cpp
@@ -54,7 +54,7 @@ HICON LoadIconEx(const char* name, bool big)
{
char szSettingName[100];
mir_snprintf(szSettingName, SIZEOF(szSettingName), "MSN_%s", name);
- return Skin_GetIcon(szSettingName, big);
+ return IcoLib_GetIcon(szSettingName, big);
}
HANDLE GetIconHandle(int iconId)
@@ -70,7 +70,7 @@ void ReleaseIconEx(const char* name, bool big)
{
char szSettingName[100];
mir_snprintf(szSettingName, SIZEOF(szSettingName), "MSN_%s", name);
- Skin_ReleaseIcon(szSettingName, big);
+ IcoLib_Release(szSettingName, big);
}
INT_PTR CALLBACK DlgProcMsnServLists(HWND hwndDlg, UINT msg, WPARAM wParam, LPARAM lParam);
diff --git a/protocols/Omegle/src/communication.cpp b/protocols/Omegle/src/communication.cpp
index 4998a0b344..eb7b739c75 100644
--- a/protocols/Omegle/src/communication.cpp
+++ b/protocols/Omegle/src/communication.cpp
@@ -549,7 +549,7 @@ bool Omegle_client::events()
StatusTextData st = { 0 };
st.cbSize = sizeof(st);
- // st.hIcon = Skin_GetIconByHandle(GetIconHandle("typing_on")); // TODO: typing icon
+ // st.hIcon = IcoLib_GetIconByHandle(GetIconHandle("typing_on")); // TODO: typing icon
mir_sntprintf(st.tszText, SIZEOF(st.tszText), TranslateT("%s is typing."), TranslateT("Stranger"));
@@ -564,7 +564,7 @@ bool Omegle_client::events()
StatusTextData st = { 0 };
st.cbSize = sizeof(st);
- // st.hIcon = Skin_GetIconByHandle(GetIconHandle("typing_off")); // TODO: typing icon
+ // st.hIcon = IcoLib_GetIconByHandle(GetIconHandle("typing_off")); // TODO: typing icon
mir_sntprintf(st.tszText, SIZEOF(st.tszText), TranslateT("%s stopped typing."), TranslateT("Stranger"));
diff --git a/protocols/Sametime/src/sametime.cpp b/protocols/Sametime/src/sametime.cpp
index a3824263dd..bf324f6528 100644
--- a/protocols/Sametime/src/sametime.cpp
+++ b/protocols/Sametime/src/sametime.cpp
@@ -105,18 +105,18 @@ HANDLE GetIconHandle(int iconId)
return NULL;
}
-HICON LoadIconEx(const char* name, BOOL big)
+HICON LoadIconEx(const char* name, bool big)
{
char szSettingName[100];
mir_snprintf(szSettingName, SIZEOF(szSettingName), "%s_%s", "SAMETIME", name);
- return Skin_GetIcon(szSettingName, big);
+ return IcoLib_GetIcon(szSettingName, big);
}
-void ReleaseIconEx(const char* name, BOOL big)
+void ReleaseIconEx(const char* name, bool big)
{
char szSettingName[100];
mir_snprintf(szSettingName, SIZEOF(szSettingName), "%s_%s", "SAMETIME", name);
- Skin_ReleaseIcon(szSettingName, big);
+ IcoLib_Release(szSettingName, big);
}
// Copied from MSN plugin - sent acks need to be from different thread
diff --git a/protocols/Sametime/src/sametime.h b/protocols/Sametime/src/sametime.h
index 22d07668e8..2458028af0 100644
--- a/protocols/Sametime/src/sametime.h
+++ b/protocols/Sametime/src/sametime.h
@@ -42,8 +42,8 @@ void mwResolve_handler_callback(mwServiceResolve* srvc, guint32 id, guint32 code
void SametimeInitIcons(void);
HANDLE GetIconHandle(int iconId);
-HICON LoadIconEx(const char* name, BOOL big);
-void ReleaseIconEx(const char* name, BOOL big);
+HICON LoadIconEx(const char* name, bool big);
+void ReleaseIconEx(const char* name, bool big);
// services (async thread functions)
diff --git a/protocols/SkypeWeb/src/skype_events.cpp b/protocols/SkypeWeb/src/skype_events.cpp
index 8f1339f374..38141ca714 100644
--- a/protocols/SkypeWeb/src/skype_events.cpp
+++ b/protocols/SkypeWeb/src/skype_events.cpp
@@ -46,12 +46,12 @@ INT_PTR CSkypeProto::EventGetIcon(WPARAM wParam, LPARAM lParam)
case SKYPE_DB_EVENT_TYPE_CALL_INFO:
case SKYPE_DB_EVENT_TYPE_INCOMING_CALL:
{
- icon = Skin_GetIconByHandle(GetIconHandle("inc_call"));
+ icon = IcoLib_GetIconByHandle(GetIconHandle("inc_call"));
break;
}
case SKYPE_DB_EVENT_TYPE_ACTION:
{
- icon = Skin_GetIconByHandle(GetIconHandle("me_action"));
+ icon = IcoLib_GetIconByHandle(GetIconHandle("me_action"));
break;
}
default:
@@ -98,7 +98,7 @@ void CSkypeProto::InitPopups()
mir_snprintf(name, "%s_%s", m_szModuleName, "Call");
ppc.ptszDescription = desc;
ppc.pszName = name;
- ppc.hIcon = Skin_GetIconByHandle(GetIconHandle("inc_call"));
+ ppc.hIcon = IcoLib_GetIconByHandle(GetIconHandle("inc_call"));
ppc.colorBack = RGB(255, 255, 255);
ppc.colorText = RGB(0, 0, 0);
ppc.iSeconds = 30;
@@ -109,7 +109,7 @@ void CSkypeProto::InitPopups()
mir_snprintf(name, "%s_%s", m_szModuleName, "Notification");
ppc.ptszDescription = desc;
ppc.pszName = name;
- ppc.hIcon = Skin_GetIconByHandle(GetIconHandle("notify"));
+ ppc.hIcon = IcoLib_GetIconByHandle(GetIconHandle("notify"));
ppc.colorBack = RGB(255, 255, 255);
ppc.colorText = RGB(0, 0, 0);
ppc.iSeconds = 5;
@@ -119,7 +119,7 @@ void CSkypeProto::InitPopups()
mir_snprintf(name, "%s_%s", m_szModuleName, "Error");
ppc.ptszDescription = desc;
ppc.pszName = name;
- ppc.hIcon = Skin_GetIconByHandle(GetIconHandle("error"));
+ ppc.hIcon = IcoLib_GetIconByHandle(GetIconHandle("error"));
ppc.colorBack = RGB(255, 255, 255);
ppc.colorText = RGB(0, 0, 0);
ppc.iSeconds = -1;
diff --git a/protocols/SkypeWeb/src/skype_icons.cpp b/protocols/SkypeWeb/src/skype_icons.cpp
index 7c49c9adad..6dd88d4998 100644
--- a/protocols/SkypeWeb/src/skype_icons.cpp
+++ b/protocols/SkypeWeb/src/skype_icons.cpp
@@ -50,7 +50,7 @@ void CSkypeProto::InitIcons()
sid.description.t = Icons[i].Description;
sid.iDefaultIndex = -Icons[i].IconId;
- Icons[i].Handle = Skin_AddIcon(&sid);
+ Icons[i].Handle = IcoLib_AddIcon(&sid);
}
}
@@ -67,7 +67,7 @@ HANDLE CSkypeProto::GetSkinIconHandle(const char *name)
{
char iconName[100];
mir_snprintf(iconName, SIZEOF(iconName), "%s_%s", MODULE, name);
- HANDLE hIcon = Skin_GetIconHandle(iconName);
+ HANDLE hIcon = IcoLib_GetIconHandle(iconName);
if (hIcon == NULL)
hIcon = GetIconHandle(name);
return hIcon;
@@ -76,5 +76,5 @@ HANDLE CSkypeProto::GetSkinIconHandle(const char *name)
void CSkypeProto::UninitIcons()
{
for (size_t i = 0; i < SIZEOF(Icons); i++)
- Skin_RemoveIcon(Icons[i].Name);
+ IcoLib_RemoveIcon(Icons[i].Name);
} \ No newline at end of file
diff --git a/protocols/SkypeWeb/src/skype_trouter.cpp b/protocols/SkypeWeb/src/skype_trouter.cpp
index 2e0a6e27b1..72f1ded025 100644
--- a/protocols/SkypeWeb/src/skype_trouter.cpp
+++ b/protocols/SkypeWeb/src/skype_trouter.cpp
@@ -150,7 +150,7 @@ void CSkypeProto::OnTrouterEvent(const JSONNode &body, const JSONNode &)
cle.hContact = hContact;
cle.hDbEvent = hEvent;
cle.lParam = SKYPE_DB_EVENT_TYPE_INCOMING_CALL;
- cle.hIcon = Skin_GetIconByHandle(GetIconHandle("inc_call"));
+ cle.hIcon = IcoLib_GetIconByHandle(GetIconHandle("inc_call"));
CMStringA service(FORMAT, "%s/IncomingCallCLE", GetContactProto(hContact));
cle.pszService = service.GetBuffer();
diff --git a/protocols/Steam/src/steam_dialogs.cpp b/protocols/Steam/src/steam_dialogs.cpp
index a201a80a44..39fb287cb3 100644
--- a/protocols/Steam/src/steam_dialogs.cpp
+++ b/protocols/Steam/src/steam_dialogs.cpp
@@ -11,8 +11,8 @@ void CSteamPasswordEditor::OnInitDialog()
{
char iconName[100];
mir_snprintf(iconName, SIZEOF(iconName), "%s_%s", MODULE, "main");
- SendMessage(m_hwnd, WM_SETICON, ICON_BIG, (LPARAM)Skin_GetIcon(iconName, 16));
- SendMessage(m_hwnd, WM_SETICON, ICON_SMALL, (LPARAM)Skin_GetIcon(iconName, 32));
+ SendMessage(m_hwnd, WM_SETICON, ICON_BIG, (LPARAM)IcoLib_GetIcon(iconName, 16));
+ SendMessage(m_hwnd, WM_SETICON, ICON_SMALL, (LPARAM)IcoLib_GetIcon(iconName, 32));
SendMessage(m_password.GetHwnd(), EM_LIMITTEXT, 64, 0);
@@ -49,8 +49,8 @@ void CSteamGuardDialog::OnInitDialog()
{
char iconName[100];
mir_snprintf(iconName, SIZEOF(iconName), "%s_%s", MODULE, "main");
- SendMessage(m_hwnd, WM_SETICON, ICON_BIG, (LPARAM)Skin_GetIcon(iconName, 16));
- SendMessage(m_hwnd, WM_SETICON, ICON_SMALL, (LPARAM)Skin_GetIcon(iconName, 32));
+ SendMessage(m_hwnd, WM_SETICON, ICON_BIG, (LPARAM)IcoLib_GetIcon(iconName, 16));
+ SendMessage(m_hwnd, WM_SETICON, ICON_SMALL, (LPARAM)IcoLib_GetIcon(iconName, 32));
SendMessage(m_text.GetHwnd(), EM_LIMITTEXT, 5, 0);
@@ -96,8 +96,8 @@ void CSteamCaptchaDialog::OnInitDialog()
{
char iconName[100];
mir_snprintf(iconName, SIZEOF(iconName), "%s_%s", MODULE, "main");
- SendMessage(m_hwnd, WM_SETICON, ICON_BIG, (LPARAM)Skin_GetIcon(iconName, 16));
- SendMessage(m_hwnd, WM_SETICON, ICON_SMALL, (LPARAM)Skin_GetIcon(iconName, 32));
+ SendMessage(m_hwnd, WM_SETICON, ICON_BIG, (LPARAM)IcoLib_GetIcon(iconName, 16));
+ SendMessage(m_hwnd, WM_SETICON, ICON_SMALL, (LPARAM)IcoLib_GetIcon(iconName, 32));
SendMessage(m_text.GetHwnd(), EM_LIMITTEXT, 6, 0);
diff --git a/protocols/Steam/src/steam_proto.cpp b/protocols/Steam/src/steam_proto.cpp
index 8841ce81ef..82f398ecb8 100644
--- a/protocols/Steam/src/steam_proto.cpp
+++ b/protocols/Steam/src/steam_proto.cpp
@@ -31,12 +31,12 @@ CSteamProto::CSteamProto(const char* protoName, const TCHAR* userName) :
sid.section.t = sectionName;
sid.description.t = LPGENT("Protocol icon");
sid.iDefaultIndex = -IDI_STEAM;
- Skin_AddIcon(&sid);
+ IcoLib_AddIcon(&sid);
mir_snprintf(settingName, SIZEOF(settingName), "%s_%s", MODULE, "gaming");
sid.description.t = LPGENT("Gaming icon");
sid.iDefaultIndex = -IDI_GAMING;
- Skin_AddIcon(&sid);
+ IcoLib_AddIcon(&sid);
// temporary DB settings
db_set_resident(m_szModuleName, "Status");
diff --git a/protocols/Steam/src/steam_utils.cpp b/protocols/Steam/src/steam_utils.cpp
index df3dd31727..fa43e141b2 100644
--- a/protocols/Steam/src/steam_utils.cpp
+++ b/protocols/Steam/src/steam_utils.cpp
@@ -183,7 +183,7 @@ void CSteamProto::ShowNotification(const TCHAR *caption, const wchar_t *message,
ppd.lchContact = hContact;
wcsncpy(ppd.lpwzContactName, caption, MAX_CONTACTNAME);
wcsncpy(ppd.lpwzText, message, MAX_SECONDLINE);
- ppd.lchIcon = Skin_GetIcon(MODULE"_main");
+ ppd.lchIcon = IcoLib_GetIcon(MODULE"_main");
if (!PUAddPopupT(&ppd))
return;
diff --git a/protocols/Steam/src/steam_xstatus.cpp b/protocols/Steam/src/steam_xstatus.cpp
index eee37f824a..d22cde9c88 100644
--- a/protocols/Steam/src/steam_xstatus.cpp
+++ b/protocols/Steam/src/steam_xstatus.cpp
@@ -22,7 +22,7 @@ void SetContactExtraIcon(MCONTACT hContact, int status)
char iconName[100];
mir_snprintf(iconName, SIZEOF(iconName), "%s_%s", MODULE, "gaming");
- ExtraIcon_SetIcon(hExtraXStatus, hContact, (status > 0) ? Skin_GetIconHandle(iconName) : NULL);
+ ExtraIcon_SetIcon(hExtraXStatus, hContact, (status > 0) ? IcoLib_GetIconHandle(iconName) : NULL);
}
INT_PTR CSteamProto::OnGetXStatusEx(WPARAM wParam, LPARAM lParam)
@@ -98,7 +98,7 @@ HICON CSteamProto::GetXStatusIcon(int status, UINT flags)
char iconName[100];
mir_snprintf(iconName, SIZEOF(iconName), "%s_%s", MODULE, "gaming");
- HICON icon = Skin_GetIcon(iconName, (flags & LR_BIGICON) ? 32 : 16);
+ HICON icon = IcoLib_GetIcon(iconName, (flags & LR_BIGICON) ? 32 : 16);
return (flags & LR_SHARED) ? icon : CopyIcon(icon);
}
@@ -135,7 +135,7 @@ INT_PTR CSteamProto::OnRequestAdvStatusIconIdx(WPARAM wParam, LPARAM)
// mark icon index in the array as valid
xstatusIconsValid.push_back(status);
- Skin_ReleaseIcon(hXStatusIcon);
+ IcoLib_ReleaseIcon(hXStatusIcon);
}
}
diff --git a/protocols/Tlen/src/tlen.cpp b/protocols/Tlen/src/tlen.cpp
index 8ec5c7cb06..c96e67ea08 100644
--- a/protocols/Tlen/src/tlen.cpp
+++ b/protocols/Tlen/src/tlen.cpp
@@ -97,13 +97,13 @@ HICON GetIcolibIcon(int iconId)
{
HANDLE handle = GetIconHandle(iconId);
if (handle != NULL)
- return Skin_GetIconByHandle(handle);
+ return IcoLib_GetIconByHandle(handle);
return NULL;
}
void ReleaseIcolibIcon(HICON hIcon) {
- Skin_ReleaseIcon(hIcon);
+ IcoLib_ReleaseIcon(hIcon);
}
static void TlenRegisterIcons()
diff --git a/protocols/Tox/src/tox_icons.cpp b/protocols/Tox/src/tox_icons.cpp
index 10a228c626..7a56fce4c8 100644
--- a/protocols/Tox/src/tox_icons.cpp
+++ b/protocols/Tox/src/tox_icons.cpp
@@ -30,7 +30,7 @@ void CToxProto::InitIcons()
sid.description.t = Icons[i].Description;
sid.iDefaultIndex = -Icons[i].IconId;
- Icons[i].Handle = Skin_AddIcon(&sid);
+ Icons[i].Handle = IcoLib_AddIcon(&sid);
}
}
@@ -38,7 +38,7 @@ HICON CToxProto::GetIcon(const char *name, int size)
{
for (size_t i = 0; i < SIZEOF(Icons); i++)
if (mir_strcmpi(Icons[i].Name, name) == 0)
- return Skin_GetIconByHandle(Icons[i].Handle, size);
+ return IcoLib_GetIconByHandle(Icons[i].Handle, size);
return NULL;
}
@@ -56,7 +56,7 @@ HANDLE CToxProto::GetSkinIconHandle(const char *name)
{
char iconName[100];
mir_snprintf(iconName, SIZEOF(iconName), "%s_%s", MODULE, name);
- HANDLE hIcon = Skin_GetIconHandle(iconName);
+ HANDLE hIcon = IcoLib_GetIconHandle(iconName);
if (hIcon == NULL)
hIcon = GetIconHandle(name);
@@ -66,5 +66,5 @@ HANDLE CToxProto::GetSkinIconHandle(const char *name)
void CToxProto::UninitIcons()
{
for (size_t i = 0; i < SIZEOF(Icons); i++)
- Skin_RemoveIcon(Icons[i].Name);
+ IcoLib_RemoveIcon(Icons[i].Name);
} \ No newline at end of file
diff --git a/protocols/Tox/src/tox_multimedia.cpp b/protocols/Tox/src/tox_multimedia.cpp
index ff55177d1a..c9c9eb8246 100644
--- a/protocols/Tox/src/tox_multimedia.cpp
+++ b/protocols/Tox/src/tox_multimedia.cpp
@@ -28,8 +28,8 @@ void CToxCallDlgBase::SetIcon(const char *name)
{
char iconName[100];
mir_snprintf(iconName, SIZEOF(iconName), "%s_%s", MODULE, name);
- SendMessage(m_hwnd, WM_SETICON, ICON_BIG, (LPARAM)Skin_GetIcon(iconName, 16));
- SendMessage(m_hwnd, WM_SETICON, ICON_SMALL, (LPARAM)Skin_GetIcon(iconName, 32));
+ SendMessage(m_hwnd, WM_SETICON, ICON_BIG, (LPARAM)IcoLib_GetIcon(iconName, 16));
+ SendMessage(m_hwnd, WM_SETICON, ICON_SMALL, (LPARAM)IcoLib_GetIcon(iconName, 32));
}
void CToxCallDlgBase::SetTitle(const TCHAR *title)
@@ -314,7 +314,7 @@ INT_PTR CToxProto::OnRecvAudioCall(WPARAM hContact, LPARAM lParam)
cle.hContact = hContact;
cle.hDbEvent = hEvent;
cle.lParam = DB_EVENT_CALL;
- cle.hIcon = Skin_GetIconByHandle(GetIconHandle("audio_ring"));
+ cle.hIcon = IcoLib_GetIconByHandle(GetIconHandle("audio_ring"));
TCHAR szTooltip[MAX_PATH];
mir_sntprintf(szTooltip, SIZEOF(szTooltip), TranslateT("Incoming call from %s"), pcli->pfnGetContactDisplayName(hContact, 0));
diff --git a/protocols/Tox/src/tox_options.cpp b/protocols/Tox/src/tox_options.cpp
index 1e5d270231..85af8ca960 100644
--- a/protocols/Tox/src/tox_options.cpp
+++ b/protocols/Tox/src/tox_options.cpp
@@ -376,9 +376,9 @@ void CToxOptionsNodeList::OnInitDialog()
HIMAGELIST hImageList = m_nodes.CreateImageList(LVSIL_SMALL);
HICON icon = LoadSkinnedIcon(SKINICON_OTHER_TYPING);
- ImageList_AddIcon(hImageList, icon); Skin_ReleaseIcon(icon);
+ ImageList_AddIcon(hImageList, icon); IcoLib_ReleaseIcon(icon);
icon = LoadSkinnedIcon(SKINICON_OTHER_DELETE);
- ImageList_AddIcon(hImageList, icon); Skin_ReleaseIcon(icon);
+ ImageList_AddIcon(hImageList, icon); IcoLib_ReleaseIcon(icon);
m_nodes.AddColumn(0, _T("IPv4"), 100);
m_nodes.AddColumn(1, _T("IPv6"), 100);
diff --git a/protocols/Tox/src/tox_utils.cpp b/protocols/Tox/src/tox_utils.cpp
index ccacbc0422..b0f2b46b18 100644
--- a/protocols/Tox/src/tox_utils.cpp
+++ b/protocols/Tox/src/tox_utils.cpp
@@ -46,7 +46,7 @@ void CToxProto::ShowNotification(const TCHAR *caption, const TCHAR *message, int
ppd.lchContact = hContact;
wcsncpy(ppd.lpwzContactName, caption, MAX_CONTACTNAME);
wcsncpy(ppd.lpwzText, message, MAX_SECONDLINE);
- ppd.lchIcon = Skin_GetIcon("Tox_main");
+ ppd.lchIcon = IcoLib_GetIcon("Tox_main");
if (!PUAddPopupT(&ppd))
return;
diff --git a/protocols/VKontakte/src/misc.cpp b/protocols/VKontakte/src/misc.cpp
index 52731675b5..9d59f68017 100644
--- a/protocols/VKontakte/src/misc.cpp
+++ b/protocols/VKontakte/src/misc.cpp
@@ -740,7 +740,7 @@ void CVkProto::SetSrmmReadStatus(MCONTACT hContact)
StatusTextData st = { 0 };
st.cbSize = sizeof(st);
- st.hIcon = Skin_GetIconByHandle(GetIconHandle(IDI_READMSG));
+ st.hIcon = IcoLib_GetIconByHandle(GetIconHandle(IDI_READMSG));
mir_sntprintf(st.tszText, SIZEOF(st.tszText), TranslateT("Message read: %s"), ttime);
CallService(MS_MSG_SETSTATUSTEXT, (WPARAM)hContact, (LPARAM)&st);
}
diff --git a/protocols/VKontakte/src/vk_captcha.cpp b/protocols/VKontakte/src/vk_captcha.cpp
index 5725adb0e2..0c0699900a 100644
--- a/protocols/VKontakte/src/vk_captcha.cpp
+++ b/protocols/VKontakte/src/vk_captcha.cpp
@@ -34,8 +34,8 @@ static INT_PTR CALLBACK CaptchaFormDlgProc(HWND hwndDlg, UINT msg, WPARAM wParam
switch (msg) {
case WM_INITDIALOG: {
TranslateDialogDefault(hwndDlg);
- SendMessage(hwndDlg, WM_SETICON, ICON_BIG, (LPARAM)Skin_GetIconByHandle(GetIconHandle(IDI_KEYS), TRUE));
- SendMessage(hwndDlg, WM_SETICON, ICON_SMALL, (LPARAM)Skin_GetIconByHandle(GetIconHandle(IDI_KEYS)));
+ SendMessage(hwndDlg, WM_SETICON, ICON_BIG, (LPARAM)IcoLib_GetIconByHandle(GetIconHandle(IDI_KEYS), TRUE));
+ SendMessage(hwndDlg, WM_SETICON, ICON_SMALL, (LPARAM)IcoLib_GetIconByHandle(GetIconHandle(IDI_KEYS)));
params = (CAPTCHA_FORM_PARAMS*)lParam;
SetDlgItemText(hwndDlg, IDC_INSTRUCTION, TranslateT("Enter the text you see"));
@@ -91,8 +91,8 @@ static INT_PTR CALLBACK CaptchaFormDlgProc(HWND hwndDlg, UINT msg, WPARAM wParam
break;
case WM_DESTROY:
- Skin_ReleaseIcon((HICON)SendMessage(hwndDlg, WM_SETICON, ICON_BIG, 0));
- Skin_ReleaseIcon((HICON)SendMessage(hwndDlg, WM_SETICON, ICON_SMALL, 0));
+ IcoLib_ReleaseIcon((HICON)SendMessage(hwndDlg, WM_SETICON, ICON_BIG, 0));
+ IcoLib_ReleaseIcon((HICON)SendMessage(hwndDlg, WM_SETICON, ICON_SMALL, 0));
break;
}
return FALSE;
diff --git a/protocols/VKontakte/src/vk_options.cpp b/protocols/VKontakte/src/vk_options.cpp
index a75d44213a..fcbaf37254 100644
--- a/protocols/VKontakte/src/vk_options.cpp
+++ b/protocols/VKontakte/src/vk_options.cpp
@@ -31,8 +31,8 @@ INT_PTR CALLBACK VKAccountProc(HWND hwndDlg, UINT uMsg, WPARAM wParam, LPARAM lP
ppro = (CVkProto*)lParam;
SetWindowLongPtr(hwndDlg, GWLP_USERDATA, lParam);
- SendMessage(hwndDlg, WM_SETICON, ICON_BIG, (LPARAM)Skin_GetIconByHandle(ppro->m_hProtoIcon, 1));
- SendMessage(hwndDlg, WM_SETICON, ICON_SMALL, (LPARAM)Skin_GetIconByHandle(ppro->m_hProtoIcon));
+ SendMessage(hwndDlg, WM_SETICON, ICON_BIG, (LPARAM)IcoLib_GetIconByHandle(ppro->m_hProtoIcon, 1));
+ SendMessage(hwndDlg, WM_SETICON, ICON_SMALL, (LPARAM)IcoLib_GetIconByHandle(ppro->m_hProtoIcon));
{
ptrT tszLogin(ppro->getTStringA("Login"));
if (tszLogin != NULL)
@@ -78,8 +78,8 @@ INT_PTR CALLBACK VKAccountProc(HWND hwndDlg, UINT uMsg, WPARAM wParam, LPARAM lP
break;
case WM_DESTROY:
- Skin_ReleaseIcon((HICON)SendMessage(hwndDlg, WM_GETICON, ICON_BIG, 0));
- Skin_ReleaseIcon((HICON)SendMessage(hwndDlg, WM_GETICON, ICON_SMALL, 0));
+ IcoLib_ReleaseIcon((HICON)SendMessage(hwndDlg, WM_GETICON, ICON_BIG, 0));
+ IcoLib_ReleaseIcon((HICON)SendMessage(hwndDlg, WM_GETICON, ICON_SMALL, 0));
break;
}
@@ -105,8 +105,8 @@ INT_PTR CALLBACK CVkProto::OptionsProc(HWND hwndDlg, UINT uMsg, WPARAM wParam, L
ppro = (CVkProto*)lParam;
SetWindowLongPtr(hwndDlg, GWLP_USERDATA, lParam);
- SendMessage(hwndDlg, WM_SETICON, ICON_BIG, (LPARAM)Skin_GetIconByHandle(ppro->m_hProtoIcon, 1));
- SendMessage(hwndDlg, WM_SETICON, ICON_SMALL, (LPARAM)Skin_GetIconByHandle(ppro->m_hProtoIcon));
+ SendMessage(hwndDlg, WM_SETICON, ICON_BIG, (LPARAM)IcoLib_GetIconByHandle(ppro->m_hProtoIcon, 1));
+ SendMessage(hwndDlg, WM_SETICON, ICON_SMALL, (LPARAM)IcoLib_GetIconByHandle(ppro->m_hProtoIcon));
{
ptrT tszLogin(ppro->getTStringA("Login"));
if (tszLogin != NULL)
@@ -220,8 +220,8 @@ INT_PTR CALLBACK CVkProto::OptionsProc(HWND hwndDlg, UINT uMsg, WPARAM wParam, L
break;
case WM_DESTROY:
- Skin_ReleaseIcon((HICON)SendMessage(hwndDlg, WM_GETICON, ICON_BIG, 0));
- Skin_ReleaseIcon((HICON)SendMessage(hwndDlg, WM_GETICON, ICON_SMALL, 0));
+ IcoLib_ReleaseIcon((HICON)SendMessage(hwndDlg, WM_GETICON, ICON_BIG, 0));
+ IcoLib_ReleaseIcon((HICON)SendMessage(hwndDlg, WM_GETICON, ICON_SMALL, 0));
break;
}
@@ -239,8 +239,8 @@ INT_PTR CALLBACK CVkProto::OptionsAdvProc(HWND hwndDlg, UINT uMsg, WPARAM wParam
ppro = (CVkProto*)lParam;
SetWindowLongPtr(hwndDlg, GWLP_USERDATA, lParam);
- SendMessage(hwndDlg, WM_SETICON, ICON_BIG, (LPARAM)Skin_GetIconByHandle(ppro->m_hProtoIcon, 1));
- SendMessage(hwndDlg, WM_SETICON, ICON_SMALL, (LPARAM)Skin_GetIconByHandle(ppro->m_hProtoIcon));
+ SendMessage(hwndDlg, WM_SETICON, ICON_BIG, (LPARAM)IcoLib_GetIconByHandle(ppro->m_hProtoIcon, 1));
+ SendMessage(hwndDlg, WM_SETICON, ICON_SMALL, (LPARAM)IcoLib_GetIconByHandle(ppro->m_hProtoIcon));
CheckDlgButton(hwndDlg, IDC_HIDECHATS, ppro->m_bHideChats ? BST_CHECKED : BST_UNCHECKED);
CheckDlgButton(hwndDlg, IDC_MESASUREAD, ppro->m_bMesAsUnread ? BST_CHECKED : BST_UNCHECKED);
@@ -340,8 +340,8 @@ INT_PTR CALLBACK CVkProto::OptionsAdvProc(HWND hwndDlg, UINT uMsg, WPARAM wParam
break;
case WM_DESTROY:
- Skin_ReleaseIcon((HICON)SendMessage(hwndDlg, WM_GETICON, ICON_BIG, 0));
- Skin_ReleaseIcon((HICON)SendMessage(hwndDlg, WM_GETICON, ICON_SMALL, 0));
+ IcoLib_ReleaseIcon((HICON)SendMessage(hwndDlg, WM_GETICON, ICON_BIG, 0));
+ IcoLib_ReleaseIcon((HICON)SendMessage(hwndDlg, WM_GETICON, ICON_SMALL, 0));
break;
}
@@ -359,8 +359,8 @@ INT_PTR CALLBACK CVkProto::OptionsFeedsProc(HWND hwndDlg, UINT uMsg, WPARAM wPar
ppro = (CVkProto*)lParam;
SetWindowLongPtr(hwndDlg, GWLP_USERDATA, lParam);
- SendMessage(hwndDlg, WM_SETICON, ICON_BIG, (LPARAM)Skin_GetIconByHandle(ppro->m_hProtoIcon, 1));
- SendMessage(hwndDlg, WM_SETICON, ICON_SMALL, (LPARAM)Skin_GetIconByHandle(ppro->m_hProtoIcon));
+ SendMessage(hwndDlg, WM_SETICON, ICON_BIG, (LPARAM)IcoLib_GetIconByHandle(ppro->m_hProtoIcon, 1));
+ SendMessage(hwndDlg, WM_SETICON, ICON_SMALL, (LPARAM)IcoLib_GetIconByHandle(ppro->m_hProtoIcon));
CheckDlgButton(hwndDlg, IDC_NEWS_ENBL, ppro->m_bNewsEnabled ? BST_CHECKED : BST_UNCHECKED);
CheckDlgButton(hwndDlg, IDC_NOTIF_ENBL, ppro->m_bNotificationsEnabled ? BST_CHECKED : BST_UNCHECKED);
@@ -508,8 +508,8 @@ INT_PTR CALLBACK CVkProto::OptionsFeedsProc(HWND hwndDlg, UINT uMsg, WPARAM wPar
break;
case WM_DESTROY:
- Skin_ReleaseIcon((HICON)SendMessage(hwndDlg, WM_GETICON, ICON_BIG, 0));
- Skin_ReleaseIcon((HICON)SendMessage(hwndDlg, WM_GETICON, ICON_SMALL, 0));
+ IcoLib_ReleaseIcon((HICON)SendMessage(hwndDlg, WM_GETICON, ICON_BIG, 0));
+ IcoLib_ReleaseIcon((HICON)SendMessage(hwndDlg, WM_GETICON, ICON_SMALL, 0));
break;
}
@@ -527,8 +527,8 @@ INT_PTR CALLBACK CVkProto::OptionsViewProc(HWND hwndDlg, UINT uMsg, WPARAM wPara
ppro = (CVkProto*)lParam;
SetWindowLongPtr(hwndDlg, GWLP_USERDATA, lParam);
- SendMessage(hwndDlg, WM_SETICON, ICON_BIG, (LPARAM)Skin_GetIconByHandle(ppro->m_hProtoIcon, 1));
- SendMessage(hwndDlg, WM_SETICON, ICON_SMALL, (LPARAM)Skin_GetIconByHandle(ppro->m_hProtoIcon));
+ SendMessage(hwndDlg, WM_SETICON, ICON_BIG, (LPARAM)IcoLib_GetIconByHandle(ppro->m_hProtoIcon, 1));
+ SendMessage(hwndDlg, WM_SETICON, ICON_SMALL, (LPARAM)IcoLib_GetIconByHandle(ppro->m_hProtoIcon));
CheckDlgButton(hwndDlg, IDC_IMG_OFF, (ppro->m_iIMGBBCSupport == imgNo) ? BST_CHECKED : BST_UNCHECKED);
CheckDlgButton(hwndDlg, IDC_IMG_FULLSIZE, (ppro->m_iIMGBBCSupport == imgFullSize) ? BST_CHECKED : BST_UNCHECKED);
@@ -610,8 +610,8 @@ INT_PTR CALLBACK CVkProto::OptionsViewProc(HWND hwndDlg, UINT uMsg, WPARAM wPara
break;
case WM_DESTROY:
- Skin_ReleaseIcon((HICON)SendMessage(hwndDlg, WM_GETICON, ICON_BIG, 0));
- Skin_ReleaseIcon((HICON)SendMessage(hwndDlg, WM_GETICON, ICON_SMALL, 0));
+ IcoLib_ReleaseIcon((HICON)SendMessage(hwndDlg, WM_GETICON, ICON_BIG, 0));
+ IcoLib_ReleaseIcon((HICON)SendMessage(hwndDlg, WM_GETICON, ICON_SMALL, 0));
break;
}
diff --git a/protocols/VKontakte/src/vk_proto.cpp b/protocols/VKontakte/src/vk_proto.cpp
index 37bf19cac7..af266530a7 100644
--- a/protocols/VKontakte/src/vk_proto.cpp
+++ b/protocols/VKontakte/src/vk_proto.cpp
@@ -208,28 +208,28 @@ void CVkProto::InitMenus()
mir_snprintf(szService, "%s%s", m_szModuleName, PS_SETSTATUSMSG);
mi.pszService = szService;
mi.position = 10009 + PMI_SETSTATUSMSG;
- mi.icolibItem = Skin_GetIconByHandle(GetIconHandle(IDI_STATUS));
+ mi.icolibItem = IcoLib_GetIconByHandle(GetIconHandle(IDI_STATUS));
mi.pszName = LPGEN("Status message");
g_hProtoMenuItems[PMI_SETSTATUSMSG] = Menu_AddProtoMenuItem(&mi);
mir_snprintf(szService, "%s%s", m_szModuleName, PS_WALLPOST);
mi.pszService = szService;
mi.position = 10009 + PMI_WALLPOST;
- mi.icolibItem = Skin_GetIconByHandle(GetIconHandle(IDI_WALL));
+ mi.icolibItem = IcoLib_GetIconByHandle(GetIconHandle(IDI_WALL));
mi.pszName = LPGEN("Send message to my wall");
g_hProtoMenuItems[PMI_WALLPOST] = Menu_AddProtoMenuItem(&mi);
mir_snprintf(szService, "%s%s", m_szModuleName, PS_LOADVKNEWS);
mi.pszService = szService;
mi.position = 10009 + PMI_LOADVKNEWS;
- mi.icolibItem = Skin_GetIconByHandle(GetIconHandle(IDI_NOTIFICATION));
+ mi.icolibItem = IcoLib_GetIconByHandle(GetIconHandle(IDI_NOTIFICATION));
mi.pszName = LPGEN("Load news from VK");
g_hProtoMenuItems[PMI_LOADVKNEWS] = Menu_AddProtoMenuItem(&mi);
mir_snprintf(szService, "%s%s", m_szModuleName, PS_VISITPROFILE);
mi.pszService = szService;
mi.position = 10009 + PMI_VISITPROFILE;
- mi.icolibItem = Skin_GetIconByHandle(GetIconHandle(IDI_VISITPROFILE));
+ mi.icolibItem = IcoLib_GetIconByHandle(GetIconHandle(IDI_VISITPROFILE));
mi.pszName = LPGEN("Visit profile");
g_hProtoMenuItems[PMI_VISITPROFILE] = Menu_AddProtoMenuItem(&mi);
@@ -243,49 +243,49 @@ void CVkProto::InitMenus()
mir_snprintf(szService, "%s%s", m_szModuleName, PS_WALLPOST);
mi.position = -200001000 + CMI_WALLPOST;
- mi.icolibItem = Skin_GetIconByHandle(GetIconHandle(IDI_WALL));
+ mi.icolibItem = IcoLib_GetIconByHandle(GetIconHandle(IDI_WALL));
mi.ptszName = LPGENT("Send message to user\'s wall");
mi.pszService = szService;
g_hContactMenuItems[CMI_WALLPOST] = Menu_AddContactMenuItem(&mi);
mir_snprintf(szService, "%s%s", m_szModuleName, PS_ADDASFRIEND);
mi.position = -200001000 + CMI_ADDASFRIEND;
- mi.icolibItem = Skin_GetIconByHandle(GetIconHandle(IDI_FRIENDADD));
+ mi.icolibItem = IcoLib_GetIconByHandle(GetIconHandle(IDI_FRIENDADD));
mi.ptszName = LPGENT("Add as friend");
mi.pszService = szService;
g_hContactMenuItems[CMI_ADDASFRIEND] = Menu_AddContactMenuItem(&mi);
mir_snprintf(szService, "%s%s", m_szModuleName, PS_DELETEFRIEND);
mi.position = -200001000 + CMI_DELETEFRIEND;
- mi.icolibItem = Skin_GetIconByHandle(GetIconHandle(IDI_FRIENDDEL));
+ mi.icolibItem = IcoLib_GetIconByHandle(GetIconHandle(IDI_FRIENDDEL));
mi.ptszName = LPGENT("Delete from friend list");
mi.pszService = szService;
g_hContactMenuItems[CMI_DELETEFRIEND] = Menu_AddContactMenuItem(&mi);
mir_snprintf(szService, "%s%s", m_szModuleName, PS_BANUSER);
mi.position = -200001000 + CMI_BANUSER;
- mi.icolibItem = Skin_GetIconByHandle(GetIconHandle(IDI_BAN));
+ mi.icolibItem = IcoLib_GetIconByHandle(GetIconHandle(IDI_BAN));
mi.ptszName = LPGENT("Ban user");
mi.pszService = szService;
g_hContactMenuItems[CMI_BANUSER] = Menu_AddContactMenuItem(&mi);
mir_snprintf(szService, "%s%s", m_szModuleName, PS_REPORTABUSE);
mi.position = -200001000 + CMI_REPORTABUSE;
- mi.icolibItem = Skin_GetIconByHandle(GetIconHandle(IDI_ABUSE));
+ mi.icolibItem = IcoLib_GetIconByHandle(GetIconHandle(IDI_ABUSE));
mi.ptszName = LPGENT("Report abuse");
mi.pszService = szService;
g_hContactMenuItems[CMI_REPORTABUSE] = Menu_AddContactMenuItem(&mi);
mir_snprintf(szService, "%s%s", m_szModuleName, PS_DESTROYKICKCHAT);
mi.position = -200001000 + CMI_DESTROYKICKCHAT;
- mi.icolibItem = Skin_GetIconByHandle(GetIconHandle(IDI_FRIENDDEL));
+ mi.icolibItem = IcoLib_GetIconByHandle(GetIconHandle(IDI_FRIENDDEL));
mi.ptszName = LPGENT("Destroy room");
mi.pszService = szService;
g_hContactMenuItems[CMI_DESTROYKICKCHAT] = Menu_AddContactMenuItem(&mi);
mir_snprintf(szService, "%s%s", m_szModuleName, PS_OPENBROADCAST);
mi.position = -200001000 + CMI_OPENBROADCAST;
- mi.icolibItem = Skin_GetIconByHandle(GetIconHandle(IDI_BROADCAST));
+ mi.icolibItem = IcoLib_GetIconByHandle(GetIconHandle(IDI_BROADCAST));
mi.ptszName = LPGENT("Open broadcast");
mi.pszService = szService;
g_hContactMenuItems[CMI_OPENBROADCAST] = Menu_AddContactMenuItem(&mi);
@@ -293,14 +293,14 @@ void CVkProto::InitMenus()
mir_snprintf(szService, "%s%s", m_szModuleName, PS_LOADVKNEWS);
mi.pszService = szService;
mi.position = -200001000 + CMI_LOADVKNEWS;
- mi.icolibItem = Skin_GetIconByHandle(GetIconHandle(IDI_NOTIFICATION));
+ mi.icolibItem = IcoLib_GetIconByHandle(GetIconHandle(IDI_NOTIFICATION));
mi.ptszName = LPGENT("Load news from VK");
g_hContactMenuItems[CMI_LOADVKNEWS] = Menu_AddContactMenuItem(&mi);
// Sync history menu
mir_snprintf(szService, "%s%s", m_szModuleName, PS_GETSERVERHISTORY);
mi.position = -200001000 + CMI_GETSERVERHISTORY;
- mi.icolibItem = Skin_GetIconByHandle(GetIconHandle(IDI_HISTORY));
+ mi.icolibItem = IcoLib_GetIconByHandle(GetIconHandle(IDI_HISTORY));
mi.ptszName = LPGENT("Reload messages from vk.com...");
mi.pszService = szService;
g_hContactMenuItems[CMI_GETSERVERHISTORY] = Menu_AddContactMenuItem(&mi);
@@ -310,42 +310,42 @@ void CVkProto::InitMenus()
mir_snprintf(szService, "%s%s", m_szModuleName, PS_GETSERVERHISTORYLAST1DAY);
mi.position = -200001000 + CMI_GETSERVERHISTORY + 100 + CHMI_GETSERVERHISTORYLAST1DAY;
- mi.icolibItem = Skin_GetIconByHandle(GetIconHandle(IDI_HISTORY));
+ mi.icolibItem = IcoLib_GetIconByHandle(GetIconHandle(IDI_HISTORY));
mi.ptszName = LPGENT("for last 1 day");
mi.pszService = szService;
g_hContactHistoryMenuItems[CHMI_GETSERVERHISTORYLAST1DAY] = Menu_AddContactMenuItem(&mi);
mir_snprintf(szService, "%s%s", m_szModuleName, PS_GETSERVERHISTORYLAST3DAY);
mi.position = -200001000 + CMI_GETSERVERHISTORY + 100 + CHMI_GETSERVERHISTORYLAST3DAY;
- mi.icolibItem = Skin_GetIconByHandle(GetIconHandle(IDI_HISTORY));
+ mi.icolibItem = IcoLib_GetIconByHandle(GetIconHandle(IDI_HISTORY));
mi.ptszName = LPGENT("for last 3 days");
mi.pszService = szService;
g_hContactHistoryMenuItems[CHMI_GETSERVERHISTORYLAST3DAY] = Menu_AddContactMenuItem(&mi);
mir_snprintf(szService, "%s%s", m_szModuleName, PS_GETSERVERHISTORYLAST7DAY);
mi.position = -200001000 + CMI_GETSERVERHISTORY + 100 + CHMI_GETSERVERHISTORYLAST7DAY;
- mi.icolibItem = Skin_GetIconByHandle(GetIconHandle(IDI_HISTORY));
+ mi.icolibItem = IcoLib_GetIconByHandle(GetIconHandle(IDI_HISTORY));
mi.ptszName = LPGENT("for last week");
mi.pszService = szService;
g_hContactHistoryMenuItems[CHMI_GETSERVERHISTORYLAST7DAY] = Menu_AddContactMenuItem(&mi);
mir_snprintf(szService, "%s%s", m_szModuleName, PS_GETSERVERHISTORYLAST30DAY);
mi.position = -200001000 + CMI_GETSERVERHISTORY + 100 + CHMI_GETSERVERHISTORYLAST30DAY;
- mi.icolibItem = Skin_GetIconByHandle(GetIconHandle(IDI_HISTORY));
+ mi.icolibItem = IcoLib_GetIconByHandle(GetIconHandle(IDI_HISTORY));
mi.ptszName = LPGENT("for last 30 days");
mi.pszService = szService;
g_hContactHistoryMenuItems[CHMI_GETSERVERHISTORYLAST30DAY] = Menu_AddContactMenuItem(&mi);
mir_snprintf(szService, "%s%s", m_szModuleName, PS_GETSERVERHISTORYLAST90DAY);
mi.position = -200001000 + CMI_GETSERVERHISTORY + 100 + CHMI_GETSERVERHISTORYLAST90DAY;
- mi.icolibItem = Skin_GetIconByHandle(GetIconHandle(IDI_HISTORY));
+ mi.icolibItem = IcoLib_GetIconByHandle(GetIconHandle(IDI_HISTORY));
mi.ptszName = LPGENT("for last 90 days");
mi.pszService = szService;
g_hContactHistoryMenuItems[CHMI_GETSERVERHISTORYLAST90DAY] = Menu_AddContactMenuItem(&mi);
mir_snprintf(szService, "%s%s", m_szModuleName, PS_GETALLSERVERHISTORY);
mi.position = -200001000 + CMI_GETSERVERHISTORY + 100 + CHMI_GETALLSERVERHISTORY;
- mi.icolibItem = Skin_GetIconByHandle(GetIconHandle(IDI_HISTORY));
+ mi.icolibItem = IcoLib_GetIconByHandle(GetIconHandle(IDI_HISTORY));
mi.ptszName = LPGENT("for all time");
mi.pszService = szService;
g_hContactHistoryMenuItems[CHMI_GETALLSERVERHISTORY] = Menu_AddContactMenuItem(&mi);
@@ -408,7 +408,7 @@ void CVkProto::InitPopups(void)
mir_snprintf(name, "%s_%s", m_szModuleName, "Notification");
ppc.ptszDescription = desc;
ppc.pszName = name;
- ppc.hIcon = Skin_GetIconByHandle(GetIconHandle(IDI_NOTIFICATION));
+ ppc.hIcon = IcoLib_GetIconByHandle(GetIconHandle(IDI_NOTIFICATION));
ppc.colorBack = RGB(190, 225, 255); //Blue
ppc.colorText = RGB(255, 255, 255); //White
ppc.iSeconds = 4;
diff --git a/protocols/WhatsApp/src/proto.cpp b/protocols/WhatsApp/src/proto.cpp
index 4823119505..8dd01e8c35 100644
--- a/protocols/WhatsApp/src/proto.cpp
+++ b/protocols/WhatsApp/src/proto.cpp
@@ -404,7 +404,7 @@ void WhatsAppProto::NotifyEvent(const TCHAR *title, const TCHAR *info, MCONTACT
pd.colorText = colorText;
pd.iSeconds = timeout;
pd.lchContact = contact;
- pd.lchIcon = Skin_GetIconByHandle(m_hProtoIcon); // TODO: Icon test
+ pd.lchIcon = IcoLib_GetIconByHandle(m_hProtoIcon); // TODO: Icon test
pd.PluginData = szUrl;
pd.PluginWindowProc = (WNDPROC)PopupDlgProc;
mir_tstrcpy(pd.lptzContactName, title);
diff --git a/protocols/Xfire/src/main.cpp b/protocols/Xfire/src/main.cpp
index a292edfa43..9a2e1f51f0 100644
--- a/protocols/Xfire/src/main.cpp
+++ b/protocols/Xfire/src/main.cpp
@@ -1411,8 +1411,8 @@ INT_PTR TMLoadIcon(WPARAM wParam, LPARAM lParam)
{
if (LOWORD(wParam) == PLI_PROTOCOL) {
if (wParam & PLIF_ICOLIB)
- return (INT_PTR)Skin_GetIcon("XFIRE_main");
- return (INT_PTR)CopyIcon(Skin_GetIcon("XFIRE_main"));
+ return (INT_PTR)IcoLib_GetIcon("XFIRE_main");
+ return (INT_PTR)CopyIcon(IcoLib_GetIcon("XFIRE_main"));
}
return NULL;
}
diff --git a/protocols/Xfire/src/tools.cpp b/protocols/Xfire/src/tools.cpp
index e499fab901..ebd202f4d7 100644
--- a/protocols/Xfire/src/tools.cpp
+++ b/protocols/Xfire/src/tools.cpp
@@ -94,9 +94,9 @@ int displayPopup(HWND hWnd, LPCSTR lpText, LPCSTR lpCaption, UINT uType, HICON h
ppd.lchIcon = hicon;
if (bIconsNotLoaded) {
- hicNotify = Skin_GetIcon("popup_notify");
- hicWarning = Skin_GetIcon("popup_warning");
- hicError = Skin_GetIcon("popup_error");
+ hicNotify = IcoLib_GetIcon("popup_notify");
+ hicWarning = IcoLib_GetIcon("popup_warning");
+ hicError = IcoLib_GetIcon("popup_error");
bIconsNotLoaded = FALSE;
}
diff --git a/protocols/Yahoo/src/icolib.cpp b/protocols/Yahoo/src/icolib.cpp
index 0734022277..85ec6ec28e 100644
--- a/protocols/Yahoo/src/icolib.cpp
+++ b/protocols/Yahoo/src/icolib.cpp
@@ -37,7 +37,7 @@ HICON CYahooProto::LoadIconEx(const char* name, bool big)
{
char szSettingName[100];
mir_snprintf(szSettingName, SIZEOF(szSettingName), "YAHOO_%s", name);
- return Skin_GetIcon(szSettingName, big);
+ return IcoLib_GetIcon(szSettingName, big);
}
HANDLE CYahooProto::GetIconHandle(int iconId)
@@ -53,5 +53,5 @@ void CYahooProto::ReleaseIconEx(const char* name, bool big)
{
char szSettingName[100];
mir_snprintf(szSettingName, SIZEOF(szSettingName), "YAHOO_%s", name);
- Skin_ReleaseIcon(szSettingName, big);
+ IcoLib_Release(szSettingName, big);
}
diff --git a/src/core/stdchat/src/options.cpp b/src/core/stdchat/src/options.cpp
index 84b1fc6fb4..fc04aca7c2 100644
--- a/src/core/stdchat/src/options.cpp
+++ b/src/core/stdchat/src/options.cpp
@@ -310,7 +310,7 @@ HICON LoadIconEx(char* pszIcoLibName, BOOL big)
{
char szTemp[256];
mir_snprintf(szTemp, "chat_%s", pszIcoLibName);
- return Skin_GetIcon(szTemp, big);
+ return IcoLib_GetIcon(szTemp, big);
}
static void InitSetting(TCHAR** ppPointer, char* pszSetting, TCHAR* pszDefault)
diff --git a/src/core/stdmsg/src/msgdialog.cpp b/src/core/stdmsg/src/msgdialog.cpp
index 1f86aba0ec..fe5f689eb2 100644
--- a/src/core/stdmsg/src/msgdialog.cpp
+++ b/src/core/stdmsg/src/msgdialog.cpp
@@ -1314,7 +1314,7 @@ INT_PTR CALLBACK DlgProcMessage(HWND hwndDlg, UINT msg, WPARAM wParam, LPARAM lP
if ((g_dat.flags & SMF_SHOWTYPINGWIN) && GetForegroundWindow() != hwndDlg) {
HICON hIcon = (HICON)SendMessage(hwndDlg, WM_GETICON, ICON_SMALL, 0);
SendMessage(hwndDlg, WM_SETICON, ICON_SMALL, (LPARAM)hTyping);
- Skin_ReleaseIcon(hIcon);
+ IcoLib_ReleaseIcon(hIcon);
}
dat->showTyping = 1;
}
@@ -1352,7 +1352,7 @@ INT_PTR CALLBACK DlgProcMessage(HWND hwndDlg, UINT msg, WPARAM wParam, LPARAM lP
}
else DrawIconEx(dis->hDC, dis->rcItem.left, dis->rcItem.top, hIcon, GetSystemMetrics(SM_CXSMICON), GetSystemMetrics(SM_CYSMICON), 0, NULL, DI_NORMAL);
- Skin_ReleaseIcon(hIcon);
+ IcoLib_ReleaseIcon(hIcon);
return TRUE;
}
}
diff --git a/src/core/stdmsg/src/msglog.cpp b/src/core/stdmsg/src/msglog.cpp
index 4852cf91d1..22fd62bf67 100644
--- a/src/core/stdmsg/src/msglog.cpp
+++ b/src/core/stdmsg/src/msglog.cpp
@@ -530,14 +530,14 @@ void LoadMsgLogIcons(void)
PBYTE pBmpBits = (PBYTE)mir_alloc(widthBytes * bih.biHeight);
for (int i = 0; i < SIZEOF(pLogIconBmpBits); i++) {
- HICON hIcon = Skin_GetIconByHandle(iconList[i].hIcolib);
+ HICON hIcon = IcoLib_GetIconByHandle(iconList[i].hIcolib);
size_t size = RTFPICTHEADERMAXSIZE + (bih.biSize + widthBytes * bih.biHeight) * 2;
pLogIconBmpBits[i] = (char*)mir_alloc(size);
size_t rtfHeaderSize = mir_snprintf(pLogIconBmpBits[i], size, "{\\pict\\dibitmap0\\wbmbitspixel%u\\wbmplanes1\\wbmwidthbytes%u\\picw%u\\pich%u ", bih.biBitCount, widthBytes, bih.biWidth, bih.biHeight);
HBITMAP hoBmp = (HBITMAP)SelectObject(hdcMem, hBmp);
FillRect(hdcMem, &rc, hBkgBrush);
DrawIconEx(hdcMem, 0, 0, hIcon, bih.biWidth, bih.biHeight, 0, NULL, DI_NORMAL);
- Skin_ReleaseIcon(hIcon);
+ IcoLib_ReleaseIcon(hIcon);
SelectObject(hdcMem, hoBmp);
GetDIBits(hdc, hBmp, 0, bih.biHeight, pBmpBits, (BITMAPINFO*)&bih, DIB_RGB_COLORS);
diff --git a/src/core/stdmsg/src/msgs.cpp b/src/core/stdmsg/src/msgs.cpp
index 80c55f5a4f..b152ed7bb7 100644
--- a/src/core/stdmsg/src/msgs.cpp
+++ b/src/core/stdmsg/src/msgs.cpp
@@ -186,7 +186,7 @@ static int TypingMessage(WPARAM hContact, LPARAM lParam)
cle.ptszTooltip = szTip;
CallServiceSync(MS_CLIST_REMOVEEVENT, hContact, 1);
CallServiceSync(MS_CLIST_ADDEVENT, hContact, (LPARAM)&cle);
- Skin_ReleaseIcon(cle.hIcon);
+ IcoLib_ReleaseIcon(cle.hIcon);
}
}
return 0;
diff --git a/src/mir_app/src/DefaultExtraIcons.cpp b/src/mir_app/src/DefaultExtraIcons.cpp
index 0b41f377e3..38b19bc5d1 100644
--- a/src/mir_app/src/DefaultExtraIcons.cpp
+++ b/src/mir_app/src/DefaultExtraIcons.cpp
@@ -51,7 +51,7 @@ static void SetVisibility(MCONTACT hContact, int apparentMode, bool clear)
// Is chat
hExtraIcon = hExtraChat;
if (apparentMode == ID_STATUS_OFFLINE)
- hIcolib = Skin_GetIconHandle("ChatActivity");
+ hIcolib = IcoLib_GetIconHandle("ChatActivity");
}
else {
// Not chat
diff --git a/src/mir_app/src/IcoLib.h b/src/mir_app/src/IcoLib.h
index e8bd131b1d..2253ec963e 100644
--- a/src/mir_app/src/IcoLib.h
+++ b/src/mir_app/src/IcoLib.h
@@ -94,8 +94,6 @@ IconSourceItem* GetIconSourceItem(const TCHAR* file, int indx, int cxIcon, int c
IcolibItem* IcoLib_FindHIcon(HICON hIcon, bool &big);
IcolibItem* IcoLib_FindIcon(const char* pszIconName);
-HICON IconItem_GetIcon(IcolibItem* item, bool big);
-
int SkinOptionsInit(WPARAM, LPARAM);
extern mir_cs csIconList;
diff --git a/src/mir_app/src/button.cpp b/src/mir_app/src/button.cpp
index 6b69ff1e2d..0c8648f485 100644
--- a/src/mir_app/src/button.cpp
+++ b/src/mir_app/src/button.cpp
@@ -295,7 +295,8 @@ static LRESULT CALLBACK MButtonWndProc(HWND hwnd, UINT msg, WPARAM wParam, LPAR
bct->hwndToolTips = NULL;
}
}
- if (bct->arrow) IcoLib_ReleaseIcon(bct->arrow, 0);
+ if (bct->arrow)
+ IcoLib_ReleaseIcon(bct->arrow);
DestroyTheme(bct);
}
break;
@@ -430,7 +431,7 @@ static LRESULT CALLBACK MButtonWndProc(HWND hwnd, UINT msg, WPARAM wParam, LPAR
}
else {
if (bct->arrow) {
- IcoLib_ReleaseIcon(bct->arrow, 0);
+ IcoLib_ReleaseIcon(bct->arrow);
bct->arrow = NULL;
SetHwndPropInt(bct, OBJID_CLIENT, CHILDID_SELF, PROPID_ACC_ROLE, ROLE_SYSTEM_PUSHBUTTON);
}
diff --git a/src/mir_app/src/chat.h b/src/mir_app/src/chat.h
index a84ed5cf54..26bd0710de 100644
--- a/src/mir_app/src/chat.h
+++ b/src/mir_app/src/chat.h
@@ -76,7 +76,7 @@ int OptionsInit(void);
int OptionsUnInit(void);
void LoadMsgDlgFont(int i, LOGFONT * lf, COLORREF * colour);
void LoadGlobalSettings(void);
-HICON LoadIconEx(char* pszIcoLibName, BOOL big);
+HICON LoadIconEx(char* pszIcoLibName, bool big);
void LoadLogFonts(void);
void SetIndentSize(void);
void RegisterFonts(void);
diff --git a/src/mir_app/src/chat_opts.cpp b/src/mir_app/src/chat_opts.cpp
index 3497d5b22b..3a5252e959 100644
--- a/src/mir_app/src/chat_opts.cpp
+++ b/src/mir_app/src/chat_opts.cpp
@@ -182,11 +182,11 @@ void RegisterFonts(void)
// load icons from the skinning module if available
-HICON LoadIconEx(char* pszIcoLibName, BOOL big)
+HICON LoadIconEx(char* pszIcoLibName, bool big)
{
char szTemp[256];
mir_snprintf(szTemp, "chat_%s", pszIcoLibName);
- return Skin_GetIcon(szTemp, big);
+ return IcoLib_GetIcon(szTemp, big);
}
static void InitSetting(TCHAR** ppPointer, char* pszSetting, TCHAR* pszDefault)
diff --git a/src/mir_app/src/clistmenus.cpp b/src/mir_app/src/clistmenus.cpp
index 78eb3a8433..9581c128c3 100644
--- a/src/mir_app/src/clistmenus.cpp
+++ b/src/mir_app/src/clistmenus.cpp
@@ -518,7 +518,7 @@ INT_PTR StatusMenuCheckService(WPARAM wParam, LPARAM)
DestroyIcon(timi->mi.hIcon);
timi->mi.hIcon = NULL;
}
- else IcoLib_ReleaseIcon(timi->mi.hIcon, 0);
+ else IcoLib_ReleaseIcon(timi->mi.hIcon);
}
}
@@ -939,7 +939,7 @@ void RebuildMenuOrder(void)
mir_snprintf(buf, "ProtocolIcon_%s_%s", pa->szModuleName, tmi.pszName);
MO_SetOptionsMenuItem(hStatusMenuHandles[i].menuhandle[j], OPT_MENUITEMSETUNIQNAME, (INT_PTR)buf);
- IcoLib_ReleaseIcon(tmi.hIcon, 0);
+ IcoLib_ReleaseIcon(tmi.hIcon);
}
}
@@ -985,7 +985,7 @@ void RebuildMenuOrder(void)
mir_snprintf(buf, "Root2ProtocolIcon_%s_%s", pa->szModuleName, tmi.pszName);
MO_SetOptionsMenuItem(hStatusMainMenuHandles[j], OPT_MENUITEMSETUNIQNAME, (INT_PTR)buf);
- IcoLib_ReleaseIcon(tmi.hIcon, 0);
+ IcoLib_ReleaseIcon(tmi.hIcon);
break;
}
}
diff --git a/src/mir_app/src/clui.cpp b/src/mir_app/src/clui.cpp
index 0d4443782b..42f231e425 100644
--- a/src/mir_app/src/clui.cpp
+++ b/src/mir_app/src/clui.cpp
@@ -985,13 +985,13 @@ LRESULT CALLBACK fnContactListWndProc(HWND hwnd, UINT msg, WPARAM wParam, LPARAM
HICON hIcon = LoadSkinProtoIcon(szProto, status);
DrawIconEx(dis->hDC, x, (dis->rcItem.top + dis->rcItem.bottom - g_IconHeight) >> 1, hIcon,
g_IconWidth, g_IconHeight, 0, NULL, DI_NORMAL);
- IcoLib_ReleaseIcon(hIcon, 0);
+ IcoLib_ReleaseIcon(hIcon);
if (Proto_IsAccountLocked(Proto_GetAccount(szProto))) {
hIcon = LoadSkinnedIcon(SKINICON_OTHER_STATUS_LOCKED);
if (hIcon != NULL) {
DrawIconEx(dis->hDC, x, (dis->rcItem.top + dis->rcItem.bottom - g_IconHeight) >> 1, hIcon,
g_IconWidth, g_IconHeight, 0, NULL, DI_NORMAL);
- IcoLib_ReleaseIcon(hIcon, 0);
+ IcoLib_ReleaseIcon(hIcon);
}
}
@@ -1023,7 +1023,7 @@ LRESULT CALLBACK fnContactListWndProc(HWND hwnd, UINT msg, WPARAM wParam, LPARAM
if (dis->itemData == MENU_MIRANDAMENU) {
HICON hIcon = LoadSkinnedIcon(SKINICON_OTHER_MAINMENU);
fnDrawMenuItem(dis, CopyIcon(hIcon), NULL);
- IcoLib_ReleaseIcon(hIcon, NULL);
+ IcoLib_ReleaseIcon(hIcon);
return TRUE;
}
return CallService(MS_CLIST_MENUDRAWITEM, wParam, lParam);
diff --git a/src/mir_app/src/dbutils.cpp b/src/mir_app/src/dbutils.cpp
index 3de2bfb8a2..02a6821b7d 100644
--- a/src/mir_app/src/dbutils.cpp
+++ b/src/mir_app/src/dbutils.cpp
@@ -213,11 +213,11 @@ static INT_PTR DbEventGetIcon(WPARAM wParam, LPARAM lParam)
return (INT_PTR)icon;
}
if (et && et->eventIcon)
- icon = Skin_GetIconByHandle(et->eventIcon);
+ icon = IcoLib_GetIconByHandle(et->eventIcon);
if (!icon) {
char szName[100];
mir_snprintf(szName, SIZEOF(szName), "eventicon_%s%d", dbei->szModule, dbei->eventType);
- icon = Skin_GetIcon(szName);
+ icon = IcoLib_GetIcon(szName);
}
if (!icon) {
diff --git a/src/mir_app/src/genmenu.cpp b/src/mir_app/src/genmenu.cpp
index eac64d523e..41ecec5c04 100644
--- a/src/mir_app/src/genmenu.cpp
+++ b/src/mir_app/src/genmenu.cpp
@@ -335,7 +335,7 @@ int MO_ModifyMenuItem(PMO_IntMenuItem menuHandle, PMO_MenuItem pmi)
if (hIcon != NULL) {
pimi->hIcolibItem = hIcolibItem;
pimi->iconId = ImageList_ReplaceIcon(pimi->parent->m_hMenuIcons, pimi->iconId, hIcon);
- IcoLib_ReleaseIcon(hIcon, 0);
+ IcoLib_ReleaseIcon(hIcon);
}
else pimi->iconId = -1, pimi->hIcolibItem = NULL;
}
@@ -668,7 +668,7 @@ PMO_IntMenuItem MO_AddNewMenuItem(HANDLE menuobjecthandle, PMO_MenuItem pmi)
HICON hIcon = IcoLib_GetIconByHandle(hIcolibItem, false);
p->iconId = ImageList_AddIcon(pmo->m_hMenuIcons, hIcon);
p->hIcolibItem = hIcolibItem;
- IcoLib_ReleaseIcon(hIcon, 0);
+ IcoLib_ReleaseIcon(hIcon);
}
else p->iconId = ImageList_AddIcon(pmo->m_hMenuIcons, pmi->hIcon);
}
@@ -1027,7 +1027,7 @@ static int MO_ReloadIcon(PMO_IntMenuItem pmi, void*)
if (newIcon)
ImageList_ReplaceIcon(pmi->parent->m_hMenuIcons, pmi->iconId, newIcon);
- IcoLib_ReleaseIcon(newIcon, 0);
+ IcoLib_ReleaseIcon(newIcon);
}
return FALSE;
@@ -1085,12 +1085,12 @@ static int MO_RegisterIcon(PMO_IntMenuItem pmi, void*)
sid.pszName = iconame;
sid.description.t = descr;
sid.hDefaultIcon = hIcon;
- pmi->hIcolibItem = IcoLib_AddNewIcon(0, &sid);
+ pmi->hIcolibItem = IcoLib_AddIcon(&sid, 0);
Safe_DestroyIcon(hIcon);
- if (hIcon = Skin_GetIcon(iconame)) {
+ if (hIcon = IcoLib_GetIcon(iconame)) {
ImageList_ReplaceIcon(pmi->parent->m_hMenuIcons, pmi->iconId, hIcon);
- IcoLib_ReleaseIcon(hIcon, 0);
+ IcoLib_ReleaseIcon(hIcon);
}
}
diff --git a/src/mir_app/src/icolib.cpp b/src/mir_app/src/icolib.cpp
index f477997d99..eb85a2ebd9 100644
--- a/src/mir_app/src/icolib.cpp
+++ b/src/mir_app/src/icolib.cpp
@@ -31,10 +31,6 @@ HANDLE hIcons2ChangedEvent, hIconsChangedEvent;
HICON hIconBlank = NULL;
-static HANDLE
- hIcoLib_AddNewIcon, hIcoLib_RemoveIcon, hIcoLib_GetIcon, hIcoLib_GetIcon2,
- hIcoLib_GetIconHandle, hIcoLib_IsManaged, hIcoLib_AddRef, hIcoLib_ReleaseIcon;
-
int iconEventActive = 0;
BOOL bNeedRebuild = FALSE;
@@ -496,9 +492,9 @@ static void IcoLib_FreeIcon(IcolibItem* icon)
}
/////////////////////////////////////////////////////////////////////////////////////////
-// IcoLib_AddNewIcon
+// IcoLib_AddIcon
-MIR_APP_DLL(HANDLE) IcoLib_AddNewIcon(int hLangpack, SKINICONDESC *sid)
+MIR_APP_DLL(HANDLE) IcoLib_AddIcon(SKINICONDESC *sid, int hLangpack)
{
bool utf = (sid->flags & SIDF_UNICODE) != 0;
bool utf_path = (sid->flags & SIDF_PATH_UNICODE) != 0;
@@ -568,6 +564,44 @@ MIR_APP_DLL(HANDLE) IcoLib_AddNewIcon(int hLangpack, SKINICONDESC *sid)
}
/////////////////////////////////////////////////////////////////////////////////////////
+// IcoLib_ReleaseIcon
+
+static int ReleaseIconInternal(IcolibItem *item, bool big)
+{
+ if (item == NULL)
+ return 1;
+
+ IconSourceItem *source = big && !item->cx ? item->source_big : item->source_small;
+ if (source && source->icon_ref_count) {
+ if (iconEventActive)
+ source->icon_ref_count--;
+ else
+ IconSourceItem_ReleaseIcon(source);
+ return 0;
+ }
+
+ return 1;
+}
+
+MIR_APP_DLL(int) IcoLib_ReleaseIcon(HICON hIcon, bool big)
+{
+ if (hIcon == NULL)
+ return 1;
+
+ mir_cslock lck(csIconList);
+ return ReleaseIconInternal(IcoLib_FindHIcon(hIcon, big), big);
+}
+
+MIR_APP_DLL(int) IcoLib_Release(const char *szIconName, bool big)
+{
+ if (szIconName == NULL)
+ return 1;
+
+ mir_cslock lck(csIconList);
+ return ReleaseIconInternal(IcoLib_FindIcon(szIconName), big);
+}
+
+/////////////////////////////////////////////////////////////////////////////////////////
// IcoLib_RemoveIcon
static int IcoLib_RemoveIcon_Internal(int i)
@@ -579,24 +613,22 @@ static int IcoLib_RemoveIcon_Internal(int i)
return 0;
}
-static INT_PTR IcoLib_RemoveIcon(WPARAM wParam, LPARAM lParam)
+MIR_APP_DLL(void) IcoLib_RemoveIcon(const char *pszIconName)
{
- if (wParam) {
- mir_cslock lck(csIconList);
+ mir_cslock lck(csIconList);
- int i = iconList.indexOf((IcolibItem*)wParam);
- if (i != -1)
- return IcoLib_RemoveIcon_Internal(i);
- }
+ int i = iconList.indexOf((IcolibItem*)&pszIconName);
+ if (i != -1)
+ IcoLib_RemoveIcon_Internal(i);
+}
- if (lParam) {
- mir_cslock lck(csIconList);
+MIR_APP_DLL(void) IcoLib_RemoveIconByHandle(HANDLE hIcoLib)
+{
+ mir_cslock lck(csIconList);
- int i = iconList.getIndex((IcolibItem*)&lParam);
- if (i != -1)
- return IcoLib_RemoveIcon_Internal(i);
- }
- return 1; // Failed
+ int i = iconList.getIndex((IcolibItem*)hIcoLib);
+ if (i != -1)
+ IcoLib_RemoveIcon_Internal(i);
}
void KillModuleIcons(int hLangpack)
@@ -666,14 +698,16 @@ HICON IconItem_GetDefaultIcon(IcolibItem* item, bool big)
/////////////////////////////////////////////////////////////////////////////////////////
// IconItem_GetIcon
-HICON IconItem_GetIcon(IcolibItem* item, bool big)
+HICON IconItem_GetIcon(HANDLE hIcoLib, bool big)
{
- DBVARIANT dbv = { 0 };
- HICON hIcon = NULL;
+ IcolibItem *item = (IcolibItem*)hIcoLib;
+ if (item == NULL)
+ return NULL;
big = big && !item->cx;
IconSourceItem* &source = big ? item->source_big : item->source_small;
+ DBVARIANT dbv = { 0 };
if (!source && !db_get_ts(NULL, "SkinIcons", item->name, &dbv)) {
TCHAR tszFullPath[MAX_PATH];
PathToAbsoluteT(dbv.ptszVal, tszFullPath);
@@ -683,6 +717,7 @@ HICON IconItem_GetIcon(IcolibItem* item, bool big)
db_free(&dbv);
}
+ HICON hIcon = NULL;
if (source)
hIcon = IconSourceItem_GetIcon(source);
@@ -763,23 +798,21 @@ MIR_APP_DLL(HANDLE) IcoLib_IsManaged(HICON hIcon)
// lParam: NULL
// wParam: HICON
-static INT_PTR IcoLib_AddRef(WPARAM wParam, LPARAM)
+MIR_APP_DLL(int) IcoLib_AddRef(HICON hIcon)
{
mir_cslock lck(csIconList);
bool big;
- IcolibItem *item = IcoLib_FindHIcon((HICON)wParam, big);
-
- INT_PTR res = 1;
+ IcolibItem *item = IcoLib_FindHIcon(hIcon, big);
if (item) {
IconSourceItem* source = big && !item->cx ? item->source_big : item->source_small;
if (source->icon_ref_count) {
source->icon_ref_count++;
- res = 0;
+ return 0;
}
}
- return res;
+ return 1;
}
static int SkinSystemModulesLoaded(WPARAM, LPARAM)
@@ -791,57 +824,12 @@ static int SkinSystemModulesLoaded(WPARAM, LPARAM)
/////////////////////////////////////////////////////////////////////////////////////////
// Module initialization and finalization procedure
-static INT_PTR sttIcoLib_AddNewIcon(WPARAM wParam, LPARAM lParam)
-{
- return (INT_PTR)IcoLib_AddNewIcon((int)wParam, (SKINICONDESC*)lParam);
-}
-
-static INT_PTR sttIcoLib_GetIcon(WPARAM wParam, LPARAM lParam)
-{
- return (INT_PTR)IcoLib_GetIcon((const char*)lParam, wParam != 0);
-}
-
-static INT_PTR sttIcoLib_GetIconHandle(WPARAM, LPARAM lParam)
-{
- return (INT_PTR)IcoLib_GetIconHandle((const char*)lParam);
-}
-
-static INT_PTR sttIcoLib_GetIconByHandle(WPARAM wParam, LPARAM lParam)
-{
- return (INT_PTR)IcoLib_GetIconByHandle((HANDLE)lParam, wParam != 0);
-}
-
-static INT_PTR sttIcoLib_ReleaseIcon(WPARAM wParam, LPARAM lParam)
-{
- return (INT_PTR)IcoLib_ReleaseIcon((HICON)wParam, (char*)lParam, false);
-}
-
-static INT_PTR sttIcoLib_ReleaseIconBig(WPARAM wParam, LPARAM lParam)
-{
- return (INT_PTR)IcoLib_ReleaseIcon((HICON)wParam, (char*)lParam, true);
-}
-
-static INT_PTR sttIcoLib_IsManaged(WPARAM wParam, LPARAM)
-{
- return (INT_PTR)IcoLib_IsManaged((HICON)wParam);
-}
-
int LoadIcoLibModule(void)
{
bModuleInitialized = TRUE;
hIconBlank = LoadIconEx(g_hInst, MAKEINTRESOURCE(IDI_BLANK), 0);
- hIcoLib_AddNewIcon = CreateServiceFunction("Skin2/Icons/AddIcon", sttIcoLib_AddNewIcon);
- hIcoLib_RemoveIcon = CreateServiceFunction(MS_SKIN2_REMOVEICON, IcoLib_RemoveIcon);
- hIcoLib_GetIcon = CreateServiceFunction(MS_SKIN2_GETICON, sttIcoLib_GetIcon);
- hIcoLib_GetIconHandle = CreateServiceFunction(MS_SKIN2_GETICONHANDLE, sttIcoLib_GetIconHandle);
- hIcoLib_GetIcon2 = CreateServiceFunction(MS_SKIN2_GETICONBYHANDLE, sttIcoLib_GetIconByHandle);
- hIcoLib_IsManaged = CreateServiceFunction(MS_SKIN2_ISMANAGEDICON, sttIcoLib_IsManaged);
- hIcoLib_AddRef = CreateServiceFunction(MS_SKIN2_ADDREFICON, IcoLib_AddRef);
- hIcoLib_ReleaseIcon = CreateServiceFunction(MS_SKIN2_RELEASEICON, sttIcoLib_ReleaseIcon);
- hIcoLib_ReleaseIcon = CreateServiceFunction(MS_SKIN2_RELEASEICONBIG, sttIcoLib_ReleaseIconBig);
-
hIcons2ChangedEvent = CreateHookableEvent(ME_SKIN2_ICONSCHANGED);
hIconsChangedEvent = CreateHookableEvent(ME_SKIN_ICONSCHANGED);
@@ -858,15 +846,6 @@ void UnloadIcoLibModule(void)
DestroyHookableEvent(hIconsChangedEvent);
DestroyHookableEvent(hIcons2ChangedEvent);
- DestroyServiceFunction(hIcoLib_AddNewIcon);
- DestroyServiceFunction(hIcoLib_RemoveIcon);
- DestroyServiceFunction(hIcoLib_GetIcon);
- DestroyServiceFunction(hIcoLib_GetIconHandle);
- DestroyServiceFunction(hIcoLib_GetIcon2);
- DestroyServiceFunction(hIcoLib_IsManaged);
- DestroyServiceFunction(hIcoLib_AddRef);
- DestroyServiceFunction(hIcoLib_ReleaseIcon);
-
for (int i = iconList.getCount() - 1; i >= 0; i--) {
IcolibItem* p = iconList[i];
iconList.remove(i);
diff --git a/src/mir_app/src/meta_addto.cpp b/src/mir_app/src/meta_addto.cpp
index d66c173d7f..0d48ea2c34 100644
--- a/src/mir_app/src/meta_addto.cpp
+++ b/src/mir_app/src/meta_addto.cpp
@@ -199,7 +199,7 @@ static INT_PTR CALLBACK Meta_SelectDialogProc(HWND hwndDlg, UINT msg, WPARAM wPa
case WM_DESTROY:
// Free all allocated memory and return the focus to the CList
HWND clist = GetParent(hwndDlg);
- Skin_ReleaseIcon((HICON)SendMessage(hwndDlg, WM_SETICON, ICON_BIG, 0));
+ IcoLib_ReleaseIcon((HICON)SendMessage(hwndDlg, WM_SETICON, ICON_BIG, 0));
EndDialog(hwndDlg, TRUE);
SetFocus(clist);
return TRUE;
diff --git a/src/mir_app/src/meta_edit.cpp b/src/mir_app/src/meta_edit.cpp
index 85e8154aaa..70f0944e59 100644
--- a/src/mir_app/src/meta_edit.cpp
+++ b/src/mir_app/src/meta_edit.cpp
@@ -428,7 +428,7 @@ static INT_PTR CALLBACK Meta_EditDialogProc(HWND hwndDlg, UINT msg, WPARAM wPara
return TRUE;
case WM_DESTROY:
- Skin_ReleaseIcon((HICON)SendMessage(hwndDlg, WM_SETICON, ICON_BIG, 0));
+ IcoLib_ReleaseIcon((HICON)SendMessage(hwndDlg, WM_SETICON, ICON_BIG, 0));
EndDialog(hwndDlg, IDCANCEL);
break;
}
diff --git a/src/mir_app/src/meta_main.cpp b/src/mir_app/src/meta_main.cpp
index b13c607e64..3add80aee5 100644
--- a/src/mir_app/src/meta_main.cpp
+++ b/src/mir_app/src/meta_main.cpp
@@ -44,7 +44,7 @@ HANDLE GetIconHandle(IconIndex i)
HICON LoadIconEx(IconIndex i)
{
- return Skin_GetIcon(iconList[i].szName);
+ return IcoLib_GetIcon(iconList[i].szName);
}
void UnloadMetacontacts(void)
diff --git a/src/mir_app/src/mir_app.def b/src/mir_app/src/mir_app.def
index c713745838..b23236d6d4 100644
--- a/src/mir_app/src/mir_app.def
+++ b/src/mir_app/src/mir_app.def
@@ -8,7 +8,7 @@ LoadSkinIcon @5
Button_FreeIcon_IcoLib @6
Button_SetIcon_IcoLib @7
GetSkinIconHandle @8
-IcoLib_AddNewIcon @9
+IcoLib_AddIcon @9
IcoLib_GetIcon @10
IcoLib_GetIconByHandle @11
IcoLib_GetIconHandle @12
@@ -19,3 +19,7 @@ Window_SetIcon_IcoLib @16
Window_SetProtoIcon_IcoLib @17
ProtoServiceExists @18
mir_main @19
+IcoLib_RemoveIcon @20
+IcoLib_RemoveIconByHandle @21
+IcoLib_Release @22
+IcoLib_AddRef @23
diff --git a/src/mir_app/src/options_ei.cpp b/src/mir_app/src/options_ei.cpp
index dbac3f75c2..54c2d4fb25 100644
--- a/src/mir_app/src/options_ei.cpp
+++ b/src/mir_app/src/options_ei.cpp
@@ -267,12 +267,12 @@ public:
for (int i = 0; i < registeredExtraIcons.getCount(); i++) {
ExtraIcon *extra = registeredExtraIcons[i];
- HICON hIcon = Skin_GetIcon(extra->getDescIcon());
+ HICON hIcon = IcoLib_GetIcon(extra->getDescIcon());
if (hIcon == NULL)
ImageList_AddIcon(hImageList, hBlankIcon);
else {
ImageList_AddIcon(hImageList, hIcon);
- Skin_ReleaseIcon(hIcon);
+ IcoLib_ReleaseIcon(hIcon);
}
}
m_tree.SetImageList(hImageList, TVSIL_NORMAL);
diff --git a/src/mir_app/src/protocols.cpp b/src/mir_app/src/protocols.cpp
index 2d18d58757..a61a45f930 100644
--- a/src/mir_app/src/protocols.cpp
+++ b/src/mir_app/src/protocols.cpp
@@ -286,12 +286,12 @@ HICON Proto_GetIcon(PROTO_INTERFACE *ppro, int iconIndex)
return (HICON)ppro->m_hProtoIcon;
bool big = (iconIndex & PLIF_SMALL) == 0;
- HICON hIcon = Skin_GetIconByHandle(ppro->m_hProtoIcon, big);
+ HICON hIcon = IcoLib_GetIconByHandle(ppro->m_hProtoIcon, big);
if (iconIndex & PLIF_ICOLIB)
return hIcon;
HICON hIcon2 = CopyIcon(hIcon);
- Skin_ReleaseIcon(hIcon);
+ IcoLib_ReleaseIcon(hIcon);
return hIcon2;
}
diff --git a/src/mir_app/src/protoopts.cpp b/src/mir_app/src/protoopts.cpp
index 8e072db725..8a5d0e7a15 100644
--- a/src/mir_app/src/protoopts.cpp
+++ b/src/mir_app/src/protoopts.cpp
@@ -592,14 +592,14 @@ INT_PTR CALLBACK AccMgrDlgProc(HWND hwndDlg, UINT message, WPARAM wParam, LPARAM
HICON hIcon = LoadSkinnedIcon(tmp);
DrawIconEx(lps->hDC, lps->rcItem.left, lps->rcItem.top, hIcon, cxIcon, cyIcon, 0, hbrBack, DI_NORMAL);
- IcoLib_ReleaseIcon(hIcon, 0);
+ IcoLib_ReleaseIcon(hIcon);
lps->rcItem.left += cxIcon + 2;
if (acc->ppro) {
- hIcon = Skin_GetIconByHandle(acc->ppro->m_hProtoIcon);
+ hIcon = IcoLib_GetIconByHandle(acc->ppro->m_hProtoIcon);
DrawIconEx(lps->hDC, lps->rcItem.left, lps->rcItem.top, hIcon, cxIcon, cyIcon, 0, hbrBack, DI_NORMAL);
- Skin_ReleaseIcon(hIcon);
+ IcoLib_ReleaseIcon(hIcon);
}
lps->rcItem.left += cxIcon + 2;
diff --git a/src/mir_app/src/skin2opts.cpp b/src/mir_app/src/skin2opts.cpp
index c5645c5008..ace1b18781 100644
--- a/src/mir_app/src/skin2opts.cpp
+++ b/src/mir_app/src/skin2opts.cpp
@@ -66,37 +66,6 @@ static HICON ExtractIconFromPath(const TCHAR *path, int cxIcon, int cyIcon)
}
/////////////////////////////////////////////////////////////////////////////////////////
-// IcoLib_ReleaseIcon
-// lParam: pszIconName or NULL
-// wParam: HICON or NULL
-
-MIR_APP_DLL(int) IcoLib_ReleaseIcon(HICON hIcon, char* szIconName, bool big)
-{
- mir_cslock lck(csIconList);
-
- IcolibItem *item = NULL;
- if (szIconName)
- item = IcoLib_FindIcon(szIconName);
-
- if (!item && hIcon) // find by HICON
- item = IcoLib_FindHIcon(hIcon, big);
-
- int res = 1;
- if (item) {
- IconSourceItem* source = big && !item->cx ? item->source_big : item->source_small;
- if (source && source->icon_ref_count) {
- if (iconEventActive)
- source->icon_ref_count--;
- else
- IconSourceItem_ReleaseIcon(source);
- res = 0;
- }
- }
-
- return res;
-}
-
-/////////////////////////////////////////////////////////////////////////////////////////
// IconItem_GetIcon_Preview
HICON IconItem_GetIcon_Preview(IcolibItem* item)
@@ -104,7 +73,7 @@ HICON IconItem_GetIcon_Preview(IcolibItem* item)
HICON hIcon = NULL;
if (!item->temp_reset) {
- HICON hRefIcon = IconItem_GetIcon(item, false);
+ HICON hRefIcon = IcoLib_GetIconByHandle(item, false);
hIcon = CopyIcon(hRefIcon);
if (item->source_small && item->source_small->icon == hRefIcon)
IconSourceItem_ReleaseIcon(item->source_small);
diff --git a/src/mir_app/src/skinicons.cpp b/src/mir_app/src/skinicons.cpp
index 75703b1b52..63ba1b81d3 100644
--- a/src/mir_app/src/skinicons.cpp
+++ b/src/mir_app/src/skinicons.cpp
@@ -160,7 +160,7 @@ int ImageList_AddIcon_IconLibLoaded(HIMAGELIST hIml, int iconId)
{
HICON hIcon = LoadSkinIcon(iconId);
int res = ImageList_AddIcon(hIml, hIcon);
- IcoLib_ReleaseIcon(hIcon, 0);
+ IcoLib_ReleaseIcon(hIcon);
return res;
}
@@ -168,7 +168,7 @@ int ImageList_AddIcon_ProtoIconLibLoaded(HIMAGELIST hIml, const char *szProto, i
{
HICON hIcon = LoadSkinProtoIcon(szProto, iconId);
int res = ImageList_AddIcon(hIml, hIcon);
- IcoLib_ReleaseIcon(hIcon, 0);
+ IcoLib_ReleaseIcon(hIcon);
return res;
}
@@ -183,7 +183,7 @@ int ImageList_ReplaceIcon_NotShared(HIMAGELIST hIml, int iIndex, HINSTANCE hInst
int ImageList_ReplaceIcon_IconLibLoaded(HIMAGELIST hIml, int nIndex, HICON hIcon)
{
int res = ImageList_ReplaceIcon(hIml, nIndex, hIcon);
- IcoLib_ReleaseIcon(hIcon, 0);
+ IcoLib_ReleaseIcon(hIcon);
return res;
}
@@ -201,8 +201,8 @@ MIR_APP_DLL(void) Window_SetProtoIcon_IcoLib(HWND hWnd, const char *szProto, int
MIR_APP_DLL(void) Window_FreeIcon_IcoLib(HWND hWnd)
{
- IcoLib_ReleaseIcon((HICON)SendMessage(hWnd, WM_SETICON, ICON_BIG, 0), NULL);
- IcoLib_ReleaseIcon((HICON)SendMessage(hWnd, WM_SETICON, ICON_SMALL, 0), NULL);
+ IcoLib_ReleaseIcon((HICON)SendMessage(hWnd, WM_SETICON, ICON_BIG, 0));
+ IcoLib_ReleaseIcon((HICON)SendMessage(hWnd, WM_SETICON, ICON_SMALL, 0));
}
MIR_APP_DLL(void) Button_SetIcon_IcoLib(HWND hwndDlg, int itemId, int iconId, const char *tooltip)
@@ -216,7 +216,7 @@ MIR_APP_DLL(void) Button_SetIcon_IcoLib(HWND hwndDlg, int itemId, int iconId, co
MIR_APP_DLL(void) Button_FreeIcon_IcoLib(HWND hwndDlg, int itemId)
{
HICON hIcon = (HICON)SendDlgItemMessage(hwndDlg, itemId, BM_SETIMAGE, IMAGE_ICON, 0);
- IcoLib_ReleaseIcon(hIcon, 0);
+ IcoLib_ReleaseIcon(hIcon);
}
MIR_APP_DLL(HICON) LoadSkinProtoIcon(const char *szProto, int status, bool big)
@@ -317,7 +317,7 @@ MIR_APP_DLL(HICON) LoadSkinProtoIcon(const char *szProto, int status, bool big)
sid.pszName = iconName;
sid.description.t = cli.pfnGetStatusModeDescription(statusIcons[i].id, 0);
sid.iDefaultIndex = statusIcons[i].resource_id;
- IcoLib_AddNewIcon(0, &sid);
+ IcoLib_AddIcon(&sid, 0);
}
}
@@ -417,7 +417,7 @@ int LoadSkinIcons(void)
sid.section.a = mainIcons[i].section == NULL ? LPGEN("Main icons") : (char*)mainIcons[i].section;
sid.description.a = (char*)mainIcons[i].description;
sid.iDefaultIndex = mainIcons[i].resource_id;
- mainIcons[i].hIcolib = IcoLib_AddNewIcon(0, &sid);
+ mainIcons[i].hIcolib = IcoLib_AddIcon(&sid, 0);
}
// Add global icons to list
@@ -430,7 +430,7 @@ int LoadSkinIcons(void)
sid.pszName = iconName;
sid.description.a = (char*)statusIcons[i].description;
sid.iDefaultIndex = statusIcons[i].resource_id;
- statusIcons[i].hIcolib = IcoLib_AddNewIcon(0, &sid);
+ statusIcons[i].hIcolib = IcoLib_AddIcon(&sid, 0);
}
return 0;
}
diff --git a/src/mir_app/src/usedIcons.cpp b/src/mir_app/src/usedIcons.cpp
index 5592e01f82..843f6dd77d 100644
--- a/src/mir_app/src/usedIcons.cpp
+++ b/src/mir_app/src/usedIcons.cpp
@@ -53,10 +53,10 @@ static Icon* FindIcon(const char *icolibName)
usedIcons.insert(icon = new Icon(icolibName));
if (icon->hImage == INVALID_HANDLE_VALUE) {
- HICON hIcon = Skin_GetIcon(icon->name);
+ HICON hIcon = IcoLib_GetIcon(icon->name);
if (hIcon != NULL) {
icon->hImage = ExtraIcon_Add(hIcon);
- Skin_ReleaseIcon(hIcon);
+ IcoLib_ReleaseIcon(hIcon);
}
}
diff --git a/src/mir_core/src/ui_utils.cpp b/src/mir_core/src/ui_utils.cpp
index e80ac05897..fae4fb3f3e 100644
--- a/src/mir_core/src/ui_utils.cpp
+++ b/src/mir_core/src/ui_utils.cpp
@@ -648,7 +648,7 @@ CCtrlMButton::CCtrlMButton(CDlgBase* dlg, int ctrlId, int iCoreIcon, const char*
CCtrlMButton::~CCtrlMButton()
{
- ::Skin_ReleaseIcon(m_hIcon);
+ ::IcoLib_ReleaseIcon(m_hIcon);
}
void CCtrlMButton::OnInit()
@@ -2564,8 +2564,8 @@ INT_PTR CProtoIntDlgBase::DlgProc(UINT msg, WPARAM wParam, LPARAM lParam)
return result;
case WM_DESTROY:
- Skin_ReleaseIcon((HICON)SendMessage(m_hwnd, WM_SETICON, ICON_BIG, 0));
- Skin_ReleaseIcon((HICON)SendMessage(m_hwnd, WM_SETICON, ICON_SMALL, 0));
+ IcoLib_ReleaseIcon((HICON)SendMessage(m_hwnd, WM_SETICON, ICON_BIG, 0));
+ IcoLib_ReleaseIcon((HICON)SendMessage(m_hwnd, WM_SETICON, ICON_SMALL, 0));
m_proto_interface->WindowUnsubscribe(m_hwnd);
break;