Greeting.

I am changing the QuickStart menu.  I need to have one
more shortcut to create the HTML document. Also the
list of document name have to be changed as:

Text Document -> MyWriter
Spreadsheet -> MyCalc
...

Method: Adding Shortcut
=======================
File: ./sfx2/source/appl/shutdownicon32.cxx

Add: 
- #define statement for the IDM_WEB
- #define statement for the WEB_URL 
(#define WEB_URL  “private:factory/swriter/web”)

Modify:
- createSystrayMenu() function.
- As writer and web share the same factory, follow the
IsWriter() if statement as example.  Modify and put
IDM_WEB (instead of IDM_WRITER), ICON_HTML_DOCUMENT
(instead of ICON_TEXT_DOCUMENT) and WEB_URL (instead
of WRITER_URL) in there.

Result
======
There is one more item in the QuickStart menu.  If
this item is selected, I can see that a new HTML
document is ready for me to edit.

The icon is correct.

*** The name is NOT correct.



Method: Name it as MyWeb
========================
File: ./svtools/source/misc/imagemgr.src

Modify:
All STR_DESCRIPTION_FACTORY_* description
(ex: STR_DESCRIPTION_FACTORY_WRITER now has a value of
MyWriter)
(ex: STR_DESCRIPTION_FACTORY_WRITERWEB now has a value
of MyWeb)

Result
======
As stated in the above Result section, the name is not
correct.  It shows MyWriter even the icon is correct.

Discussion
==========
In createSystrayMenu() of shutdowniconw32.cxx, I find
out pShutdownIcon->GetUrlDescription() holds the key. 
It basically use GetDescription() from
SvFileInformationManager (from
svtools/source/misc/imagemgr.cxx).  The
GetDescription() will, in turn, use
GetDescriptionByFactory_Impl().  This function will
get STR_DESCRIPTION_FACTORY_*.  (ex:
STR_DESCRIPTION_FACTORY_WRITERWEB) and it will return
whatever listed for STR_DESCRIPTION_FACTORY_WRITERWEB
in svtools/source/misc/localize.sdf (for the
appropriate language).

Question
========
Last time I did this was using cws_srx645_ooo112fix2. 
I did all the modification as listed in the above
Discussion section.  I got the name right as well.

This time is SRC680_m96.  The name is not correct.  It
shows MyWriter.  I think the difference is in
GetDescriptionByFactory_Impl().  In srx645, the if
statement for   web (or swriter/web), in srx645,
   else if ( rFactory.EqualsIgnoreCaseAscii(
"swriter/web" ) ) 
in src680,
   else if ( rFactory.EqualsIgnoreCaseAscii(
"swriter/web", 0, 11 ) ) 

Would this be the problem that it
(GetDescriptionByFactory_Impl()) cannot return
STR_DESCRIPTION_FACTORY_WRITERWEB?  Or I am missing
something here?  I think this is related to the
svtools module in util project?  Or is it related to
installation project?

Thanks!

__________________________________
想即時收到新 email 通知?
下載 Yahoo! Messenger
http://messenger.yahoo.com.hk/

---------------------------------------------------------------------
To unsubscribe, e-mail: [EMAIL PROTECTED]
For additional commands, e-mail: [EMAIL PROTECTED]

Reply via email to