Home > Software engineering >  Covered cmfctoolbarbutton cannot execute virtual functions
Covered cmfctoolbarbutton cannot execute virtual functions

Time:09-19

Cmfctoolbar menu bar to join the edit box, cmfctoolbarbutton effect in order to make the virtual functions, I added two declare_serial and implement_serial macros, effective results virtual functions, but can't edit box input, don't even show the edit box, the whole is white,

CodePudding user response:

Is anyone here?? ! ????? ! ??

CodePudding user response:

"c + + notes" Part13 MFC CMFCToolBar embedded in the ComboBox and EditCtrl


CodePudding user response:

In main frame can also response, actually I want to achieve is to the user in the menu bar after the edit box input digital press enter to perform some operations, if use your response this way, you can know which edit box is the user input, but unable to capture the return message,

CodePudding user response:

refer to the second floor zgl7903 response:
"c + + notes" Part13 MFC CMFCToolBar embedded in the ComboBox and EditCtrl

I directly to rewrite the translatemessage cmfctoolbar virtual functions can also capture the return message, but not know in which the user is edit box, press the return key

CodePudding user response:

GetFocus?

CodePudding user response:

reference 5 floor zgl7903 reply:
GetFocus?

The tried, was cmfctoolbar: : translatemessage judgment after user press enter inside, call getfocus, but access to handle with all edit box handle are not equal, and cmfctoolbar also not equal to, also don't know whether get to that window

CodePudding user response:

reference 5 floor zgl7903 reply:
GetFocus?

I'm going to edit box in the main frame response setfocus and killfocus news, and then save the edit box has the focus, then inside cmfctoolbar translatemessage capture return messages, it is ok to both communication and synchronization problems will just not sure, but tried it on as if no, do not know is not reliable,
  • Related