Hi Everyone, This is regarding this bug - https://bugs.freedesktop.org/show_bug.cgi?id=30508 Goal: To be able to open an image(Graphic item) in an external application for advanced editing What is already done: Added a menu item to right click popup on the graphic, coupled the menu item with a method that handles the event.(I have attached a snippet of that method as a preliminary hack for the same) I current way I am implementing is that I save the Graphic a temporary file,then to create a new thread ( using osl_createThread from osl/thread.h ) and from within the new thread execute the external application to open the temp ( using osl_executeProcess from osl/process.h). Then on I poll for the exit of the process and after exit, exit the new thread and main thread updates the graphic with the new temporary image. But the current way blocks the main loop and I end up getting an unresponsive libreoffice window which is not desirable at all. Please advice me how to go about this further. I thought off interrupts but not really sure to proceed. I searched opengrok for interrupt but couldn't find anything helpful. If I have been doing it the wrong way altogether please suggest me how to proceed. Please bear with the varied string classes used in the snippet, will fix them all before submitting the patch. Also Currently I am implementing this in Gnome ( just using eog as the external command), but will give the user the option to choose the application with a file chooser dialog. Many thanks for Thorsten and many others so far who have helped to get me this far. -- regards Suren Learning < Doing Learn By doing.
Attachment:
snippet.cpp
Description: Binary data