Ariel Constenla-Haile wrote:
On Monday 24 August 2009, 03:34, Juergen Schmidt wrote:
mmh, an undocumented service ... with a not really known API. I can
image that such a service can be really helpful and we should maybe
think about a well designed and documented one.
So please don't expect that this code will work in the future as well.
You're right, I was going to add at the end of the mail the warning:
all these stuff is internal , that is: not published nor
unpublished API. This means it has no contract to its API clients, and may
change or even not work at all; if you find its behavior changes, you'll have
to look at the implementation
http://svn.services.openoffice.org/opengrok/xref/DEV300_m55/sfx2/source/appl/shutdownicon.hxx
http://svn.services.openoffice.org/opengrok/xref/DEV300_m55/sfx2/source/appl/shutdownicon.cxx
and for win relative stuff:
http://svn.services.openoffice.org/opengrok/xref/DEV300_m55/sfx2/source/appl/shutdowniconw32.cxx
Jan can keep an eye on them while submitting an issue (I guess sfx2 belongs
to the framework team) and wait for it to be fixed.
Hi Ariel and Juergen.
Great links! I grokked the source of shutdowniconw32.cxx and found that
I can post a SHUTDOWN_QUICKSTART_MESSAGE to the Quickstarter listener
window - presto, it goes away. This is the Delphi code that I use to
shut it down.
const
QUICKSTART_CLASSNAME = 'SO Listener Class';
// QUICKSTART_WINDOWNAME = 'SO Listener Window';
// The window name of the listener window is not set to anything
// in the OpenOffice Quickstarter that I have running according to
Microsoft Spy++.
// I run OOO310m11.
QUICKSTART_WINDOWNAME = nil;
SHUTDOWN_QUICKSTART_MESSAGE = 'SO KillTray';
procedure TMainForm.PostExitMessageButtonClick(Sender: TObject);
var
QckStWinHandle: THandle;
ShutdownMsg: DWORD;
begin
QckStWinHandle := FindWindow(QUICKSTART_CLASSNAME,
QUICKSTART_WINDOWNAME);
if QckStWinHandle = 0 then
raise Exception.Create('QuickStarter is not running.');
ShutdownMsg := RegisterWindowMessage( SHUTDOWN_QUICKSTART_MESSAGE );
PostMessage(QckStWinHandle, ShutdownMsg, 0, 0);
end;
I have submitted issue 104476 - let's see what happens.
http://www.openoffice.org/issues/show_bug.cgi?id=104476
Cheers
-- Jan