496
Programming / Re: Anyone used the EPM - eToolKit to make an MLE for VAC 3.0?
« on: April 22, 2021, 08:29:13 pm »Has anyone successfully used the EPM Etoolkit to create an EPM based MLE in a VisualAge C++ v 3.0 IOC application?
Sample 2 from the etoolkit shows an E-MLE inside of an EFrame inside of an application window. The E-MLE is the actual editor guts; the EFrame adds scroll bars, message line, title bar etc. I lightly modified sample 2 from the etoolkit SDK, compiled with VAC 3.0 and it works - attached as epm_sample2.zip
But when I convert that into a "custom control" as a C++ class, to integrate with the user interface part of the IOC library, part of the E-MLE stops working. It appears to be the part that sends messages, or receives messages related to editor commands. What I THINK is happening is the dispatcher that the IOC uses to intercept and route window messages is somehow not sending the messages to the E-MLE window procedure. Or rather some of the messages, because other messages clearly are getting through.
So has anyone converted a customized PM window/control into a IOC user interface object that can be inserted into various other IOC UI objects?
epm_sample2.zip is the lightly modified Sample 2 from the eToolkit sdk.
testmain.zip contains my class EpmMle (descended from IControl) which is my attempt to integrate an EFrame/E-MLE into a custom control that can be used in IOC. Run testmain.exe from testmain.zip and try issuing a command from the menu; Command - Command Dlg and then type some EPM command, such as SAYERROR 'Hello' You will need the VAC 3.0 runtime libraries to run testmain.exe
I also played around with it and created a very simple editor. What I vaguely remember is that if you want to invoke a editor built-in command, you need to use the "post" window message otherwise EPM will get unsynchronized/run into concurrency issues if it runs on more than one thread (which it will do if you invoke a command that takes a longer time to process).