MCPcopy Create free account
hub / github.com/TranslucentTB/TranslucentTB / LoadThemedIcon

Method LoadThemedIcon

TranslucentTB/tray/trayicon.cpp:32–45  ·  view source on GitHub ↗

Source from the content-addressed store, hash-verified

30}
31
32void TrayIcon::LoadThemedIcon()
33{
34 if (const HRESULT hr = LoadIconMetric(hinstance(), GetThemedIcon(), LIM_SMALL, m_Icon.put()); SUCCEEDED(hr))
35 {
36 m_IconData.uFlags |= NIF_ICON;
37 m_IconData.hIcon = m_Icon.get();
38 }
39 else
40 {
41 m_IconData.uFlags &= ~NIF_ICON;
42 m_Icon.reset();
43 HresultHandle(hr, spdlog::level::warn, L"Failed to load tray icon.");
44 }
45}
46
47bool TrayIcon::Notify(DWORD message, NOTIFYICONDATA *data)
48{

Callers

nothing calls this directly

Calls 2

putMethod · 0.80
getMethod · 0.80

Tested by

no test coverage detected