Catchs more events into the iframe diagrams.net - draw.io

I would like to know if in app.diagram.net (embedded) it was possible to capture events via postMessage() from the app to the client and vice versa?
Here is what I am looking for:
the "drag and drop" event of a shape on the canvas
the right click on an element
Or the setting in the librairies of upstream elements in the iframe config to handle postMessage()
I thank you in advance,
Have a nice evening.

Related

displaying an icon in the notification bar for a windows service?

i am using the code from this website to create a basic service
http://code.msdn.microsoft.com/windowsdesktop/CppWindowsService-cacf4948
and i want this service to appear as an icon in the toolbar.
would i be able to start and stop the service from the icon?
right now i have to go into the SCM to start and stop the service and it takes too long to scroll down the list and find the service then start or stop it.
some websites are saying this can't be done because you can't interact with a service
is this true?
i don't care if this is a bad idea or shouldn't be done. i just want to know the code if can it be done so can someone please help?
I got a "Please avoid extended discussions in comments" message, so I'm proposing this answer.
Write a icon tray application; this link gives an example of how to do this (also see the "Related Articles" on the right of the article).
When you (right-) click on the tray icon, the icon tray application should determine if the service is already running; if yes, pop up a menu item to stop the service, otherwise pop up a menu item to start the service.
Answers to this StackOverflow question has pointers to how you can manage services using the Windows API.

Using a web site button control via C/++

I use www.jango.com as PC music player and want to steer it remotly via my smartphone. I have a server program for controling the PC and an app as client.
I want to use the server program for example to press the play/pause or fast forward button in jango.com running inside the chrome webbrowser.
A simple way would be to simulate a windows mouse click at a specified position within the chrome window. But it would have the disadvantage that it would only work if the jango tab is active and will of course fail if the site changes it's layout and probably due to a lot other reasons.
So I'm thinking about generating kind of the same http request as the browser does if one clicks the button for real. Or somehow accessing the html elemnt
Please consider thatm while having a C/++ background, I lack any web/JS programming skills and would be in favor keeping it this way as much as possible.
Thank you for any suggestions!
The solution is to use an user script for the musik player web site which is able to trigger the buttons in question. Than websockets can be used to communicate between the user script and the c++ server program.

CDHTMLDialog : Notification not received when HTML loaded via Frameset tags

I am using CDHTMLDialog from MFC to get Click notifications from HTML Element in Web pages. However I am not getting any notification, if the Webpage has Frameset Tags. Please let me know the steps on how to get notifications.
Thanks,
Edwin.
The MFC DHTML event macros are not designed for elements inside frames. The MFC implementation only look for elements in the top level document.
Hook up the event sink manually with the MFC source as a reference. See Handling HTML Element Events and How to get the WebBrowser object model of an HTML frame

winapi - Hooking an app's taskbar tab events

I'm having trouble hooking event messages sent when a user left/right clicks on the app's tackbar tab. I have tried implementing OnNcLButtonDown and the like but no events are ever triggered when I click on the app's tab. Is there a possible COM solutions?
There is an undocumented windows message: code 0x0313 that is send when a user right clicks on the app's taskbar button. Dunno whether its stable to hook though.

MFC : How to capture a link click event in a web browser control?

I have an MFC application that has a webcontrol. When clickable links are clicked, it opens using IE, not the default browser.
Questions :
Is there a way to force it to open using the default browser?
If not, how do I capture the Link Click event so I could just manipulate the click event later?
Thanks...
No, not as far as I know.
Check out the articles on http://ehsanakhgari.org/article/visual-c/webbrowser-goodies . It has a number of articles that show how to set up an event sink using IDocHostUIHandler etc. to handle events like clicking of links. I'm not sure which interface to implement, it's been years since I last did this. Then, you use ShellExecute() with a url as the third parameter to open a url with the default browser.
You can capture click events by using "HRESULT STDMETHODCALLTYPE Invoke" see MSDN for more details.
And here's a great example that shows how to open your URL using the default browser in the same window, or opening a new window > http://www.codeproject.com/KB/IP/urlnewwindow.aspx