SDK implementation Separator

Source: Internet
Author: User

 

 

Separation bar in Windows is a widely used control, which is used by most Explorer-style applications. However, there is very little relevant information about its complete implementation, So I implemented it myself, hoping to help SDK enthusiasts.
In fact, the separator is also a very common window, it also has its own window class, its own window process-just like all the predefined controls. That is to say, to create a separator, you also need to register the window class and create a window.

The following is the registration window class code
Void RegisterSplitter (void)
{
WNDCLASS wc;
Wc. cbClsExtra = 0;
Wc. cbWndExtra = 0;
Wc. hbrBackground = (HBRUSH) COLOR_BTNSHADOW;
Wc. hCursor = LoadCursor (NULL, IDC_SIZEWE );
Wc. hIcon = NULL;
Wc. hInstance = hInst;
Wc. lpfnWndProc = (WNDPROC) ProcSplitter; // This is a window process. For the CWnd class of MFC, what is the process?
Wc. lpszClassName = "MySplitter haha ";
Wc. lpszMenuName = NULL;
Wc. style = 0;
RegisterClass (& wc );
}

20051028

Contact Us

The content source of this page is from Internet, which doesn't represent Alibaba Cloud's opinion; products and services mentioned on that page don't have any relationship with Alibaba Cloud. If the content of the page makes you feel confusing, please write us an email, we will handle the problem within 5 days after receiving your email.

If you find any instances of plagiarism from the community, please send an email to: info-contact@alibabacloud.com and provide relevant evidence. A staff member will contact you within 5 working days.

A Free Trial That Lets You Build Big!

Start building with 50+ products and up to 12 months usage for Elastic Compute Service

  • Sales Support

    1 on 1 presale consultation

  • After-Sales Support

    24/7 Technical Support 6 Free Tickets per Quarter Faster Response

  • Alibaba Cloud offers highly flexible support services tailored to meet your exact needs.