mirror of
https://github.com/chibicitiberiu/rainmeter-studio.git
synced 2024-02-24 04:33:31 +00:00
Reduced system resource usage.
This commit is contained in:
@ -230,11 +230,10 @@ CMeterWindow::~CMeterWindow()
|
||||
*/
|
||||
int CMeterWindow::Initialize(CRainmeter& Rainmeter)
|
||||
{
|
||||
WNDCLASSEX wc = {sizeof(WNDCLASSEX)};
|
||||
|
||||
m_Rainmeter = &Rainmeter;
|
||||
|
||||
// Register the windowclass
|
||||
WNDCLASSEX wc = {sizeof(WNDCLASSEX)};
|
||||
wc.style = CS_NOCLOSE | CS_DBLCLKS;
|
||||
wc.lpfnWndProc = WndProc;
|
||||
wc.hInstance = m_Rainmeter->GetInstance();
|
||||
|
@ -53,17 +53,9 @@ CTrayWindow::CTrayWindow(HINSTANCE instance) : m_Instance(instance),
|
||||
m_TrayPos(),
|
||||
m_TrayIconEnabled(true)
|
||||
{
|
||||
WNDCLASS wc;
|
||||
|
||||
wc.style = 0;
|
||||
WNDCLASS wc = {0};
|
||||
wc.lpfnWndProc = (WNDPROC)WndProc;
|
||||
wc.cbClsExtra = 0;
|
||||
wc.cbWndExtra = 0;
|
||||
wc.hInstance = instance;
|
||||
wc.hIcon = LoadIcon(instance, MAKEINTRESOURCE(IDI_WINDOW));
|
||||
wc.hCursor = LoadCursor(NULL, IDC_ARROW);
|
||||
wc.hbrBackground = (HBRUSH)GetStockObject(WHITE_BRUSH);
|
||||
wc.lpszMenuName = NULL;
|
||||
wc.lpszClassName = L"RainmeterTrayClass";
|
||||
|
||||
RegisterClass(&wc);
|
||||
|
Reference in New Issue
Block a user