Cwnd -- 4

Source: Internet
Author: User
Tags ole

15. menu functions (Table 6.16)

Table 6. 16 menu member functions of cwnd classes

Member Functions

Description

Getmenu

Returns the pointer to the specified menu.

Setmenu

Set the menu to the specified menu

Drawmenubar

Redraw menu bar

Getsystemmenu

Allow application access control menu for copying and Modification

Continued table 6.16

Member Functions

Description

Hilitemenuitem

Highlight top-level menu items or remove the highlight display of top-level menu items

16. tooltip functions (Table 6.17)

Table 6. 17 tooltip functions for cwnd classes

Member Functions

Description

Enabletooltip

Allow tooltip controls

Canceltooltip

Disable tooltip controls

Filtertooltipmessage

Obtains the title or text associated with a widget in the dialog box.

Ontoolhittest

Determines whether a vertex is in the rectangle bound to the specified tool and obtains information about the tool.

17. timer functions (Table 6.18)

Table 6. 18 timer member functions of cwnd type

Member Functions

Description

Settimer

Install the system timer and send the wm_timer message when the timer is triggered.

Killtimer

Eliminate system timers

18. Prompt function (Table 6.19)

Table 6. Prompt member functions for 19 types of cwnd

Member Functions

Description

Flashwindow

Flashing window once

MessageBox

Create and display a window that includes the message and title provided by the application

19. Window message functions (Table 6.20)

Table 6. 20 window message member functions of cwnd type

Member Functions

Description

Getcurrentmessage

Returns the pointer to the message being processed in the window. Only whenOnmessageCall the member function in the message processing function.

Default

Call the default Window Process, which provides default processing for messages not processed by all applications

Pretranslatemessage

Used by cwinapp to filter window messages before they are sent to translatemessage and dispatchmessage

Continued table 6.20

Member Functions

Description

Sendmessage

Sends a message to the cwnd object until the object processes the message.

Postmessage

Put a message into the message queue of the program. Return immediately without waiting for the window to process the message.

Sendpolicymessage

Sends the specified message to the window and returns the message as quickly as possible. This depends on how the calling thread creates the window.

20. Clipboard functions (Table 6.21)

Table 6. 21-class cwnd clipboard Functions

Member Functions

Description

Changeconboardchain

Remove the cwnd object from the clipboard viewer chain

Setclipboardviewer

Add the cwnd object to the window chain. These windows will receive a notification when the clipboard content changes.

Openclipboard

Open the clipboard. Other programs can change the clipboard only when the Windows closeclipboard function is called.

Getclipboardowner

Obtains the pointer of the current clipboard owner.

Getopenclipboardwindow

Returns the pointer to the window that currently opens the clipboard.

Getclipboardviewer

Returns the pointer to the first window in the clipboard viewer chain.

21. Ole controls and functions (Table 6.22)

Table 6. 22 ole control functions of cwnd classes

Member Functions

Description

Setproperty

Set OLE Control Properties

Onambientproperty

Implement environment attribute values

Getcontrolunknown

Returns a pointer to an unknown ole control.

Getproperty

Obtains the properties of an ole control.

Invokehelper

Call ole control methods or properties

22. Reload functions (Table 6.23)

 

Table 6. 23 reload-able member functions of cwnd classes

Member Functions

Description

Windowproc

Provides a window process for the cwnd object. The default Window Process sends messages through message ing

Defwindowproc

Call the default Window Process, which provides default processing for all window messages not processed by the application

Postncdestroy

Called by the onncdestroy function after the window is destroyed

Onnotify

It is called by the Framework to notify the parent window of an event occurring in a control or the required information of the control.

Onchildnotify

The parent window is called to give the notification control a chance to respond to the notification.

Dodataexchange

It is used for dialog box data exchange and verification. Called by updatedata

Other functions include message processing functions for various window messages. These functions are numerous and will not be described here. Almost all the message processing functions defined in the cwnd class have the same naming method. The format is prefix on and corresponding message name, for example, the processing function of the wm_paint message is named onpaint in the cwnd class. Therefore, you only need to know the message to be processed, and the processing function name of the message can be quickly deduced.

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.