[Libreoffice-commits] .: padmin/source sot/source svl/inc svtools/inc svtools/source unotools/inc unotools/source vcl/inc vcl/source
Joseph Powers
jpowers at kemper.freedesktop.org
Tue Nov 16 21:23:14 PST 2010
padmin/source/adddlg.cxx | 6
padmin/source/padialog.cxx | 20 +-
padmin/source/padialog.hrc | 6
padmin/source/padialog.src | 24 ++-
sot/source/base/exchange.cxx | 6
svl/inc/cntwids.hrc | 30 ----
svtools/inc/contextmenuhelper.hxx | 26 +--
svtools/inc/imagemgr.hxx | 10 -
svtools/inc/ivctrl.hxx | 22 +--
svtools/inc/svtools/svtools.hrc | 3
svtools/inc/svtools/toolboxcontroller.hxx | 23 +--
svtools/source/brwbox/editbrowsebox.cxx | 28 +--
svtools/source/brwbox/editbrowsebox.src | 14 +
svtools/source/brwbox/editbrowseboximpl.hxx | 2
svtools/source/config/colorcfg.cxx | 25 +--
svtools/source/contnr/ivctrl.cxx | 43 +-----
svtools/source/contnr/templwin.cxx | 2
svtools/source/contnr/templwin.hxx | 2
svtools/source/misc/imagemgr.cxx | 2
svtools/source/misc/imagemgr.src | 2
svtools/source/uno/contextmenuhelper.cxx | 131 ++++++++----------
svtools/source/uno/toolboxcontroller.cxx | 36 +----
unotools/inc/unotools/lingucfg.hxx | 12 -
unotools/source/config/lingucfg.cxx | 48 +++---
vcl/inc/vcl/svids.hrc | 1
vcl/source/src/images.src | 7
vcl/source/window/menu.cxx | 200 +++++++++++++---------------
27 files changed, 321 insertions(+), 410 deletions(-)
New commits:
commit a28d80615c8a82280d5b97fd372ce2332fd58581
Author: Joseph Powers <jpowers27 at cox.net>
Date: Tue Nov 16 19:03:56 2010 -0800
HC Cleanup - libs-gui
diff --git a/padmin/source/adddlg.cxx b/padmin/source/adddlg.cxx
index efbd2e8..1dbbfb4 100644
--- a/padmin/source/adddlg.cxx
+++ b/padmin/source/adddlg.cxx
@@ -2,7 +2,7 @@
/*************************************************************************
*
* DO NOT ALTER OR REMOVE COPYRIGHT NOTICES OR THIS FILE HEADER.
- *
+ *
* Copyright 2000, 2010 Oracle and/or its affiliates.
*
* OpenOffice.org - a multi-platform office productivity suite
@@ -153,7 +153,7 @@ void APChooseDriverPage::updateDrivers( bool bRefresh, const rtl::OUString& rSel
std::list< rtl::OUString > aDrivers;
psp::PPDParser::getKnownPPDDrivers( aDrivers, bRefresh );
-
+
rtl::OUString aSelectDriver( psp::PPDParser::getPPDPrinterName( rSelectDriver ) );
rtl::OUString aSelectedEntry;
@@ -270,7 +270,7 @@ IMPL_LINK( APChooseDriverPage, ClickBtnHdl, PushButton*, pButton )
std::list< rtl::OUString > aDirs;
// get only psprint's directories, not eventual system dirs
psp::getPrinterPathList( aDirs, NULL );
- std::list< rtl::OUString >::iterator dir;
+ std::list< rtl::OUString >::iterator dir;
for( dir = aDirs.begin(); dir != aDirs.end(); ++dir )
{
::std::list< String > aFiles;
diff --git a/padmin/source/padialog.cxx b/padmin/source/padialog.cxx
index 9ee6676..85a1d52 100644
--- a/padmin/source/padialog.cxx
+++ b/padmin/source/padialog.cxx
@@ -2,7 +2,7 @@
/*************************************************************************
*
* DO NOT ALTER OR REMOVE COPYRIGHT NOTICES OR THIS FILE HEADER.
- *
+ *
* Copyright 2000, 2010 Oracle and/or its affiliates.
*
* OpenOffice.org - a multi-platform office productivity suite
@@ -110,8 +110,8 @@ PADialog::PADialog( Window* pParent, BOOL /*bAdmin*/ ) :
void PADialog::updateSettings()
{
m_aPrinterImg = Image( BitmapEx( PaResId( RID_BMP_SMALL_PRINTER ) ) );
- m_aFaxImg = Image( BitmapEx( PaResId( RID_BMP_SMALL_FAX ) ) );
- m_aPdfImg = Image( BitmapEx( PaResId( RID_BMP_SMALL_PDF ) ) );
+ m_aFaxImg = Image( BitmapEx( PaResId( RID_BMP_SMALL_FAX ) ) );
+ m_aPdfImg = Image( BitmapEx( PaResId( RID_BMP_SMALL_PDF ) ) );
}
void PADialog::Init()
@@ -119,7 +119,7 @@ void PADialog::Init()
// #i79787# initially ensure printer discovery has ended
m_rPIManager.checkPrintersChanged( true );
m_aCUPSCB.Check( m_rPIManager.isCUPSDisabled() );
-
+
UpdateDevice();
UpdateText();
@@ -364,7 +364,7 @@ public:
{}
virtual ~SpaPrinterController()
{}
-
+
virtual int getPageCount() const { return 1; }
virtual Sequence< PropertyValue > getPageParameters( int i_nPage ) const;
virtual void printPage( int i_nPage ) const;
@@ -374,22 +374,22 @@ public:
Sequence< PropertyValue > SpaPrinterController::getPageParameters( int ) const
{
Sequence< PropertyValue > aRet( 1 );
-
+
Size aPageSize( getPrinter()->GetPaperSizePixel() );
aPageSize = getPrinter()->PixelToLogic( aPageSize, MapMode( MAP_100TH_MM ) );
-
+
awt::Size aSize;
aSize.Width = aPageSize.Width();
aSize.Height = aPageSize.Height();
aRet[0].Value = makeAny(aSize);
-
+
return aRet;
}
void SpaPrinterController::printPage( int ) const
{
const double DELTA = 5.0;
-
+
boost::shared_ptr<Printer> pPrinter( getPrinter() );
PrinterInfo aInfo( psp::PrinterInfoManager::get().getPrinterInfo( pPrinter->GetName() ) );
@@ -699,7 +699,7 @@ void PADialog::RenameDevice()
void PADialog::UpdateDevice()
{
m_aDevicesLB.Clear();
-
+
m_rPIManager.listPrinters( m_aPrinters );
::std::list< OUString >::iterator it;
for( it = m_aPrinters.begin(); it != m_aPrinters.end(); ++it )
diff --git a/padmin/source/padialog.hrc b/padmin/source/padialog.hrc
index c835847..10b038e 100644
--- a/padmin/source/padialog.hrc
+++ b/padmin/source/padialog.hrc
@@ -1,7 +1,7 @@
/*************************************************************************
*
* DO NOT ALTER OR REMOVE COPYRIGHT NOTICES OR THIS FILE HEADER.
- *
+ *
* Copyright 2000, 2010 Oracle and/or its affiliates.
*
* OpenOffice.org - a multi-platform office productivity suite
@@ -190,13 +190,9 @@
#define RID_TXT_FONT_REGULAR 1095
#define RID_BMP_SMALL_PRINTER 1096
-// free
#define RID_BMP_SMALL_FAX 1098
-// free
#define RID_BMP_SMALL_PDF 1100
-// free
#define RID_BMP_PRINTER 1102
-// free
#define RID_AFMERROR_OK 1300
#define RID_AFMERROR_NO_FONT_NAME 1301
diff --git a/padmin/source/padialog.src b/padmin/source/padialog.src
index 41966b7..620411d 100644
--- a/padmin/source/padialog.src
+++ b/padmin/source/padialog.src
@@ -1,7 +1,7 @@
/*************************************************************************
*
* DO NOT ALTER OR REMOVE COPYRIGHT NOTICES OR THIS FILE HEADER.
- *
+ *
* Copyright 2000, 2010 Oracle and/or its affiliates.
*
* OpenOffice.org - a multi-platform office productivity suite
@@ -164,7 +164,7 @@ ModalDialog RID_PADIALOG
Size = MAP_APPFONT( 168, 8 );
Text [ en-US ] = "Disable CUPS Support";
};
-
+
FixedLine RID_PA_FL_SEPBUTTON
{
Pos = MAP_APPFONT( 0, 176 );
@@ -265,7 +265,7 @@ ModalDialog RID_PADIALOG
Size = MAP_APPFONT( 60, 12 );
Text [ en-US ] = "Test ~Page";
};
-
+
PushButton RID_PA_BTN_FONTS
{
Pos = MAP_APPFONT( 80, 181 );
@@ -284,7 +284,7 @@ ModalDialog RID_PADIALOG
Text [ en-US ] = "Default printer";
};
String RID_PA_STR_RENAME
- {
+ {
Text [ en-US ] = "Rename";
};
Text [ en-US ] = "Printer Administration";
@@ -437,10 +437,12 @@ ModalDialog RID_FONTNAMEDIALOG
};
Text [ en-US ] = "Fonts";
};
+
String RID_BXT_TESTPAGE
{
Text [ en-US ] = "Test page";
};
+
String RID_BXT_ENVIRONMENT
{
Text [ en-US ] = "Wrong environment";
@@ -480,34 +482,42 @@ String RID_AFMERROR_OK
{
Text [ en-US ] = "No error";
};
+
String RID_AFMERROR_NO_FONT_NAME
{
Text [ en-US ] = "The metric does not contain a 'FontName' entry.";
};
+
String RID_AFMERROR_NO_FULL_NAME
{
Text [ en-US ] = "The metric does not contain a 'FullName' entry.";
};
+
String RID_AFMERROR_NO_FAMILY_NAME
{
Text [ en-US ] = "The metric does not contain a 'FamilyName' entry.";
};
+
String RID_AFMERROR_MOVETO_FAILED
{
Text [ en-US ] = "The converted metric could not be written.";
};
+
String RID_AFMERROR_STREAM_READ_FAILED
{
Text [ en-US ] = "The metric could not be read.";
};
+
String RID_AFMERROR_STREAM_WRITE_FAILED
{
Text [ en-US ] = "A temporary file could not be created.";
};
+
STRING RID_AFMERROR_NOT_A_METRIC
{
Text [ en-US ] = "The file does not contain a metric.";
};
+
String RID_AFMERROR_BOX_TXT
{
Text [ en-US ] = "The metric\n\n%s\n\ncould not be converted for the following reason:\n\n";
@@ -799,19 +809,19 @@ TabPage RID_ADDP_PAGE_CHOOSEDEV
Pos = MAP_APPFONT ( 40, 40 );
Size = MAP_APPFONT( 180, 10 );
Text [ en-US ] = "Add a ~printer";
- };
+ };
RadioButton RID_ADDP_CHDEV_BTN_FAX
{
Pos = MAP_APPFONT ( 40, 50 );
Size = MAP_APPFONT( 180, 10 );
Text [ en-US ] = "Connect a fa~x device";
- };
+ };
RadioButton RID_ADDP_CHDEV_BTN_PDF
{
Pos = MAP_APPFONT ( 40, 60 );
Size = MAP_APPFONT( 180, 10 );
Text [ en-US ] = "Connect a P~DF converter";
- };
+ };
RadioButton RID_ADDP_CHDEV_BTN_OLD
{
Pos = MAP_APPFONT ( 40, 70 );
diff --git a/sot/source/base/exchange.cxx b/sot/source/base/exchange.cxx
index 4b34b98..2af7255 100644
--- a/sot/source/base/exchange.cxx
+++ b/sot/source/base/exchange.cxx
@@ -2,7 +2,7 @@
/*************************************************************************
*
* DO NOT ALTER OR REMOVE COPYRIGHT NOTICES OR THIS FILE HEADER.
- *
+ *
* Copyright 2000, 2010 Oracle and/or its affiliates.
*
* OpenOffice.org - a multi-platform office productivity suite
@@ -210,8 +210,8 @@ namespace
/*136 SOT_FORMATSTR_ID_STARCALC_8_TEMPLATE*/ { MIMETYPE_OASIS_OPENDOCUMENT_SPREADSHEET_TEMPLATE_ASCII, "Calc 8 Template", &::getCppuType( (const Sequence< sal_Int8 >*) 0 ) },
/*137 SOT_FORMATSTR_ID_STARCHART_8_TEMPLATE*/ { MIMETYPE_OASIS_OPENDOCUMENT_CHART_TEMPLATE_ASCII, "Chart 8 Template", &::getCppuType( (const Sequence< sal_Int8 >*) 0 ) },
/*138 SOT_FORMATSTR_ID_STARMATH_8_TEMPLATE*/ { MIMETYPE_OASIS_OPENDOCUMENT_FORMULA_TEMPLATE_ASCII, "Math 8 Template", &::getCppuType( (const Sequence< sal_Int8 >*) 0 ) },
- /*139 SOT_FORMATSTR_ID_STARBASE_8*/ { MIMETYPE_OASIS_OPENDOCUMENT_DATABASE_ASCII, "StarBase 8", &::getCppuType( (const Sequence< sal_Int8 >*) 0 ) },
- /*140 SOT_FORMAT_GDIMETAFILE*/ { "application/x-openoffice-highcontrast-gdimetafile;windows_formatname=\"GDIMetaFile\"", "High Contrast GDIMetaFile", &::getCppuType( (const Sequence< sal_Int8 >*) 0 ) },
+ /*139 SOT_FORMATSTR_ID_STARBASE_8*/ { MIMETYPE_OASIS_OPENDOCUMENT_DATABASE_ASCII, "StarBase 8", &::getCppuType( (const Sequence< sal_Int8 >*) 0 ) },
+ /*140 SOT_FORMAT_GDIMETAFILE*/ { "application/x-openoffice-highcontrast-gdimetafile;windows_formatname=\"GDIMetaFile\"", "High Contrast GDIMetaFile", &::getCppuType( (const Sequence< sal_Int8 >*) 0 ) },
};
return &aInstance[0];
}
diff --git a/svl/inc/cntwids.hrc b/svl/inc/cntwids.hrc
index 90986e3..7546a1c 100644
--- a/svl/inc/cntwids.hrc
+++ b/svl/inc/cntwids.hrc
@@ -1,7 +1,7 @@
/*************************************************************************
*
* DO NOT ALTER OR REMOVE COPYRIGHT NOTICES OR THIS FILE HEADER.
- *
+ *
* Copyright 2000, 2010 Oracle and/or its affiliates.
*
* OpenOffice.org - a multi-platform office productivity suite
@@ -77,7 +77,6 @@
#define WID_TO (WID_CHAOS_START + 24)
#define WID_FROM (WID_CHAOS_START + 25)
#define WID_TITLE (WID_CHAOS_START + 26)
-#define WID_SUBJECT WID_TITLE // only here to prevent panic, should be removed
#define WID_MESSAGEBODY (WID_CHAOS_START + 27)
#define WID_REFERENCES (WID_CHAOS_START + 28)
@@ -137,8 +136,6 @@
//PROP FOLDER VIEW
#define WID_DUMMY_PROPFOLDERVIEW1 (WID_CHAOS_START + 65)
#define WID_THREADING (WID_CHAOS_START + 66)
-#define WID_MSG_COLUMN_INFO /* obsolete */ (WID_CHAOS_START + 67)
-#define WID_FLD_COLUMN_INFO /* obsolete */ (WID_CHAOS_START + 68)
#define WID_FOLDERVIEW_MODE (WID_CHAOS_START + 69)
#define WID_MESSAGEVIEW_MODE (WID_CHAOS_START + 70)
#define WID_SENTMESSAGEVIEW_MODE (WID_CHAOS_START + 71)
@@ -153,8 +150,6 @@
//PROP FOLDER DIR
#define WID_DUMMY_FOLDERDIR1 (WID_CHAOS_START + 79)
#define WID_TOTALCONTENTCOUNT (WID_CHAOS_START + 80)
-#define WID_NEWSGROUPCOUNT /* ??? */ (WID_CHAOS_START + 81)
-#define WID_ARTICLECOUNT /* ??? */ (WID_CHAOS_START + 82)
#define WID_KNOWN_RANGES (WID_CHAOS_START + 83)
#define WID_IMAPFOLDERINFO (WID_CHAOS_START + 84)
@@ -176,23 +171,9 @@
#define WID_PASSWORD (WID_CHAOS_START + 92)
#define WID_SERVERNAME (WID_CHAOS_START + 93)
#define WID_SERVERPORT (WID_CHAOS_START + 94)
-// obsolete
-#define WID_MAILSEND_USERNAME (WID_CHAOS_START + 95)
-#define WID_MAILSEND_PASSWORD (WID_CHAOS_START + 96)
-#define WID_MAILSEND_SERVERNAME (WID_CHAOS_START + 97)
-#define WID_NEWSSEND_USERNAME (WID_CHAOS_START + 98)
-#define WID_NEWSSEND_PASSWORD (WID_CHAOS_START + 99)
-#define WID_NEWSSEND_SERVERNAME (WID_CHAOS_START + 100)
-// end obsolete
#define WID_SERVERBASE (WID_CHAOS_START + 101)
-// not used
-#define WID_SMTP_GATEWAY (WID_CHAOS_START + 102)
// -> ..._DEFAULT
-// obsolete
-#define WID_FROM_DEFAULT (WID_CHAOS_START + 103)
-// obsolete
-#define WID_REPLY_TO_DEFAULT (WID_CHAOS_START + 104)
#define WID_AUTOUPDATE_INTERVAL (WID_CHAOS_START + 105)
#define WID_UPDATE_ENABLED (WID_CHAOS_START + 106)
@@ -243,13 +224,6 @@
#define WID_STORE_MSGS_TIMELIMIT (WID_CHAOS_START + 124)
// PROP BOX
-#define WID_MSG_COLUMN_WIDTHS /* obsolete */(WID_CHAOS_START + 125)
-
-#ifdef OLD_CHAOS
-
-#define WID_CHAOS_END (WID_CHAOS_START + 125)
-
-#else
//////////////////////////////////////////////////////////////////////////
// WID's added after SO 4.0 release ( SUPD > 364 )
@@ -501,6 +475,4 @@
// END
#define WID_CHAOS_END (WID_CHAOS_START + 253)
-#endif /* OLD_CHAOS */
-
#endif /* !_CNTWIDS_HRC */
diff --git a/svtools/inc/contextmenuhelper.hxx b/svtools/inc/contextmenuhelper.hxx
index 1bcf1c1..c6f30e2 100644
--- a/svtools/inc/contextmenuhelper.hxx
+++ b/svtools/inc/contextmenuhelper.hxx
@@ -2,7 +2,7 @@
/*************************************************************************
*
* DO NOT ALTER OR REMOVE COPYRIGHT NOTICES OR THIS FILE HEADER.
- *
+ *
* Copyright 2000, 2010 Oracle and/or its affiliates.
*
* OpenOffice.org - a multi-platform office productivity suite
@@ -46,12 +46,12 @@ namespace svt
/**
Context menu helper class.
- Fills images and labels for a provided popup menu or
- com.sun.star.awt.XPopupMenu.
-
+ Fills images and labels for a provided popup menu or
+ com.sun.star.awt.XPopupMenu.
+
PRECONDITION:
- All commands must be set via SetItemCommand and are part
- of the configuration files
+ All commands must be set via SetItemCommand and are part
+ of the configuration files
(see org.openoffice.Office.UI.[Module]Commands.xcu)
*/
struct ExecuteInfo;
@@ -72,38 +72,38 @@ class SVT_DLLPUBLIC ContextMenuHelper
// methods to create a popup menu referenced by resource URL
// NOT IMPLEMENTED YET!
::com::sun::star::uno::Reference< ::com::sun::star::awt::XPopupMenu > create( const ::rtl::OUString& aPopupMenuResourceURL );
-
+
// method to create and execute a popup menu referenced by a resource URL
// NOT IMPLEMENTED YET!
bool createAndExecute( const Point& aPos, const ::rtl::OUString& aPopupMenuResourceURL );
private:
// asynchronous link to prevent destruction while on stack
- DECL_STATIC_LINK( ContextMenuHelper, ExecuteHdl_Impl, ExecuteInfo* );
-
+ DECL_STATIC_LINK( ContextMenuHelper, ExecuteHdl_Impl, ExecuteInfo* );
+
// no copy-ctor and operator=
ContextMenuHelper( const ContextMenuHelper& );
const ContextMenuHelper& operator=( const ContextMenuHelper& );
// show context menu and dispatch command automatically
void executePopupMenu( const Point& aPos, PopupMenu* pMenu );
-
+
// fill image and label for every menu item on the provided menu
void completeMenuProperties( Menu* pMenu );
// dispatch provided command
bool dispatchCommand( const ::com::sun::star::uno::Reference< ::com::sun::star::frame::XFrame >& xFrame, const ::rtl::OUString& aCommandURL );
-
+
// methods to retrieve a single command URL dependent value from a
// ui configuratin manager
- Image getImageFromCommandURL( const ::rtl::OUString& aCmdURL, bool bHiContrast ) const;
+ Image getImageFromCommandURL( const ::rtl::OUString& aCmdURL ) const;
rtl::OUString getLabelFromCommandURL( const ::rtl::OUString& aCmdURL ) const;
// creates an association between current module/controller bound to the
// provided frame and their ui configuration managers.
bool associateUIConfigurationManagers();
-
+
// resets associations to create associations again on-demand.
// Usefull for implementations which recycle frames. Normal
// implementations can profit from caching and should set
diff --git a/svtools/inc/imagemgr.hxx b/svtools/inc/imagemgr.hxx
index 0d53d6f..79e28a9 100644
--- a/svtools/inc/imagemgr.hxx
+++ b/svtools/inc/imagemgr.hxx
@@ -2,7 +2,7 @@
/*************************************************************************
*
* DO NOT ALTER OR REMOVE COPYRIGHT NOTICES OR THIS FILE HEADER.
- *
+ *
* Copyright 2000, 2010 Oracle and/or its affiliates.
*
* OpenOffice.org - a multi-platform office productivity suite
@@ -75,10 +75,10 @@ private:
SVT_DLLPRIVATE static String GetDescription_Impl( const INetURLObject& rObject, sal_Bool bDetectFolder );
public:
- SVT_DLLPUBLIC static Image GetImage( const INetURLObject& rURL, sal_Bool bBig );
- SVT_DLLPUBLIC static Image GetFileImage( const INetURLObject& rURL, sal_Bool bBig );
- SVT_DLLPUBLIC static Image GetImageNoDefault( const INetURLObject& rURL, sal_Bool bBig );
- SVT_DLLPUBLIC static Image GetFolderImage( const svtools::VolumeInfo& rInfo, sal_Bool bBig );
+ SVT_DLLPUBLIC static Image GetImage( const INetURLObject& rURL, sal_Bool bBig = sal_False );
+ SVT_DLLPUBLIC static Image GetFileImage( const INetURLObject& rURL, sal_Bool bBig = sal_False );
+ SVT_DLLPUBLIC static Image GetImageNoDefault( const INetURLObject& rURL, sal_Bool bBig = sal_False );
+ SVT_DLLPUBLIC static Image GetFolderImage( const svtools::VolumeInfo& rInfo, sal_Bool bBig = sal_False );
SVT_DLLPUBLIC static String GetDescription( const INetURLObject& rObject );
SVT_DLLPUBLIC static String GetFileDescription( const INetURLObject& rObject );
diff --git a/svtools/inc/ivctrl.hxx b/svtools/inc/ivctrl.hxx
index 73b7dd3..652a5c4 100644
--- a/svtools/inc/ivctrl.hxx
+++ b/svtools/inc/ivctrl.hxx
@@ -2,7 +2,7 @@
/*************************************************************************
*
* DO NOT ALTER OR REMOVE COPYRIGHT NOTICES OR THIS FILE HEADER.
- *
+ *
* Copyright 2000, 2010 Oracle and/or its affiliates.
*
* OpenOffice.org - a multi-platform office productivity suite
@@ -73,7 +73,6 @@ enum SvxIconChoiceCtrlPositionMode
class SvxIconChoiceCtrlEntry
{
Image aImage;
- Image aImageHC;
String aText;
String aQuickHelpText;
@@ -123,16 +122,13 @@ class SvxIconChoiceCtrlEntry
public:
SvxIconChoiceCtrlEntry( USHORT nFlags = 0 );
SvxIconChoiceCtrlEntry( const String& rText, const Image& rImage, USHORT nFlags = 0 );
- SvxIconChoiceCtrlEntry( const String& rText, const Image& rImage, const Image& rImageHC, USHORT nFlags = 0 );
~SvxIconChoiceCtrlEntry () {}
void SetImage ( const Image& rImage ) { aImage = rImage; }
- void SetImageHC ( const Image& rImage ) { aImageHC = rImage; }
Image GetImage () const { return aImage; }
- Image GetImageHC () const { return aImageHC; }
void SetText ( const String& rText ) { aText = rText; }
String GetText () const { return aText; }
- String SVT_DLLPUBLIC GetDisplayText() const;
+ String SVT_DLLPUBLIC GetDisplayText() const;
void SetQuickHelpText( const String& rText ) { aQuickHelpText = rText; }
String GetQuickHelpText() const { return aQuickHelpText; }
void SetUserData ( void* _pUserData ) { pUserData = _pUserData; }
@@ -303,14 +299,12 @@ public:
SvxIconChoiceCtrlEntry* InsertEntry( ULONG nPos = LIST_APPEND,
const Point* pPos = 0,
USHORT nFlags = 0 );
- SvxIconChoiceCtrlEntry* InsertEntry( const String& rText, const Image& rImage,
- ULONG nPos = LIST_APPEND,
- const Point* pPos = 0,
- USHORT nFlags = 0 );
- SvxIconChoiceCtrlEntry* InsertEntry( const String& rText, const Image& rImage, const Image& rImageHC,
- ULONG nPos = LIST_APPEND,
- const Point* pPos = 0,
- USHORT nFlags = 0 );
+ SvxIconChoiceCtrlEntry* InsertEntry( const String& rText,
+ const Image& rImage,
+ ULONG nPos = LIST_APPEND,
+ const Point* pPos = 0,
+ USHORT nFlags = 0
+ );
/** creates automatic mnemonics for all icon texts in the control
*/
diff --git a/svtools/inc/svtools/svtools.hrc b/svtools/inc/svtools/svtools.hrc
index e25ba53..ef7f6d2 100644
--- a/svtools/inc/svtools/svtools.hrc
+++ b/svtools/inc/svtools/svtools.hrc
@@ -317,9 +317,6 @@
#define RID_SVTOOLS_IMAGELIST_BIG (RID_SVTOOLS_IMAGELIST_START + 1)
#define RID_SVTOOLS_IMAGELIST_SMALL (RID_SVTOOLS_IMAGELIST_START + 2)
#define RID_SVTOOLS_IMAGELIST_EDITBROWSEBOX (RID_SVTOOLS_IMAGELIST_START + 3)
-/// free
-/// free
-/// free
#define RID_FILEPICKER_IMAGES (RID_SVTOOLS_IMAGELIST_START + 7)
//.............................................................................
diff --git a/svtools/inc/svtools/toolboxcontroller.hxx b/svtools/inc/svtools/toolboxcontroller.hxx
index e79123d..8141f09 100644
--- a/svtools/inc/svtools/toolboxcontroller.hxx
+++ b/svtools/inc/svtools/toolboxcontroller.hxx
@@ -2,7 +2,7 @@
/*************************************************************************
*
* DO NOT ALTER OR REMOVE COPYRIGHT NOTICES OR THIS FILE HEADER.
- *
+ *
* Copyright 2000, 2010 Oracle and/or its affiliates.
*
* OpenOffice.org - a multi-platform office productivity suite
@@ -78,15 +78,15 @@ class SVT_DLLPUBLIC ToolboxController : public ::com::sun::star::frame::XStatusL
const ::com::sun::star::uno::Reference< ::com::sun::star::frame::XFrame >& xFrame,
const rtl::OUString& aCommandURL );
ToolboxController();
- virtual ~ToolboxController();
-
+ virtual ~ToolboxController();
+
::com::sun::star::uno::Reference< ::com::sun::star::frame::XFrame > getFrameInterface() const;
::com::sun::star::uno::Reference< ::com::sun::star::lang::XMultiServiceFactory > getServiceManager() const;
::com::sun::star::uno::Reference< ::com::sun::star::frame::XLayoutManager > getLayoutManager() const;
void updateStatus( const rtl::OUString aCommandURL );
void updateStatus();
-
+
// XInterface
virtual ::com::sun::star::uno::Any SAL_CALL queryInterface( const ::com::sun::star::uno::Type& aType ) throw (::com::sun::star::uno::RuntimeException);
virtual void SAL_CALL acquire() throw ();
@@ -94,19 +94,19 @@ class SVT_DLLPUBLIC ToolboxController : public ::com::sun::star::frame::XStatusL
// XInitialization
virtual void SAL_CALL initialize( const ::com::sun::star::uno::Sequence< ::com::sun::star::uno::Any >& aArguments ) throw (::com::sun::star::uno::Exception, ::com::sun::star::uno::RuntimeException);
-
+
// XUpdatable
virtual void SAL_CALL update() throw (::com::sun::star::uno::RuntimeException);
-
+
// XComponent
virtual void SAL_CALL dispose() throw (::com::sun::star::uno::RuntimeException);
virtual void SAL_CALL addEventListener( const ::com::sun::star::uno::Reference< ::com::sun::star::lang::XEventListener >& xListener ) throw (::com::sun::star::uno::RuntimeException);
virtual void SAL_CALL removeEventListener( const ::com::sun::star::uno::Reference< ::com::sun::star::lang::XEventListener >& aListener ) throw (::com::sun::star::uno::RuntimeException);
-
+
// XEventListener
using cppu::OPropertySetHelper::disposing;
virtual void SAL_CALL disposing( const com::sun::star::lang::EventObject& Source ) throw ( ::com::sun::star::uno::RuntimeException );
-
+
// XStatusListener
virtual void SAL_CALL statusChanged( const ::com::sun::star::frame::FeatureStateEvent& Event ) throw ( ::com::sun::star::uno::RuntimeException ) = 0;
@@ -124,7 +124,7 @@ class SVT_DLLPUBLIC ToolboxController : public ::com::sun::star::frame::XStatusL
virtual ::cppu::IPropertyArrayHelper& SAL_CALL getInfoHelper();
// OPropertyArrayUsageHelper //shizhoubo
virtual ::cppu::IPropertyArrayHelper* createArrayHelper( ) const;
-
+
const rtl::OUString& getCommandURL() const { return m_aCommandURL; }
const rtl::OUString& getModuleName() const;
@@ -140,7 +140,7 @@ class SVT_DLLPUBLIC ToolboxController : public ::com::sun::star::frame::XStatusL
{
Listener( const ::com::sun::star::util::URL& rURL, const ::com::sun::star::uno::Reference< ::com::sun::star::frame::XDispatch >& rDispatch ) :
aURL( rURL ), xDispatch( rDispatch ) {}
-
+
::com::sun::star::util::URL aURL;
::com::sun::star::uno::Reference< ::com::sun::star::frame::XDispatch > xDispatch;
};
@@ -149,7 +149,7 @@ class SVT_DLLPUBLIC ToolboxController : public ::com::sun::star::frame::XStatusL
com::sun::star::uno::Reference< com::sun::star::frame::XDispatch >,
::rtl::OUStringHash,
::std::equal_to< ::rtl::OUString > > URLToDispatchMap;
-
+
// methods to support status forwarder, known by the old sfx2 toolbox controller implementation
void addStatusListener( const rtl::OUString& aCommandURL );
void removeStatusListener( const rtl::OUString& aCommandURL );
@@ -157,7 +157,6 @@ class SVT_DLLPUBLIC ToolboxController : public ::com::sun::star::frame::XStatusL
void unbindListener();
sal_Bool isBound() const;
sal_Bool hasBigImages() const;
- sal_Bool isHighContrast() const;
::com::sun::star::uno::Reference< ::com::sun::star::util::XURLTransformer > getURLTransformer() const;
::com::sun::star::uno::Reference< ::com::sun::star::awt::XWindow > getParent() const;
diff --git a/svtools/source/brwbox/editbrowsebox.cxx b/svtools/source/brwbox/editbrowsebox.cxx
index a4fe8e0..75b00f5 100644
--- a/svtools/source/brwbox/editbrowsebox.cxx
+++ b/svtools/source/brwbox/editbrowsebox.cxx
@@ -2,7 +2,7 @@
/*************************************************************************
*
* DO NOT ALTER OR REMOVE COPYRIGHT NOTICES OR THIS FILE HEADER.
- *
+ *
* Copyright 2000, 2010 Oracle and/or its affiliates.
*
* OpenOffice.org - a multi-platform office productivity suite
@@ -159,7 +159,7 @@ namespace svt
{
DBG_CTOR(EditBrowseBox,NULL);
- impl_construct();
+ impl_construct();
}
//==================================================================
@@ -254,7 +254,7 @@ namespace svt
nPaintRow = nRow;
return sal_True;
}
-
+
//------------------------------------------------------------------------------
IMPL_LINK(EditBrowseBox, StartEditHdl, void*, EMPTYARG)
{
@@ -296,7 +296,7 @@ namespace svt
{
if ( !m_aStatusImages.GetImageCount() )
{
- const_cast<EditBrowseBox*>(this)->m_aStatusImages = ImageList(SvtResId(RID_SVTOOLS_IMAGELIST_EDITBROWSEBOX));
+ const_cast<EditBrowseBox*>(this)->m_aStatusImages = ImageList( SvtResId( RID_SVTOOLS_IMAGELIST_EDITBROWSEBOX ) );
}
Image aImage;
@@ -820,7 +820,7 @@ namespace svt
{
ImplInitSettings( sal_True, sal_True, sal_True );
Invalidate();
- }
+ }
}
//------------------------------------------------------------------------------
@@ -930,9 +930,9 @@ namespace svt
{
Window& rWindow = GetDataWindow();
// don't paint too much
- // update the status immediatly if possible
+ // update the status immediatly if possible
if ((nEditRow >= 0) && (GetBrowserFlags() & EBBF_NO_HANDLE_COLUMN_CONTENT) == 0)
- {
+ {
Rectangle aRect = GetFieldRectPixel(nEditRow, 0, sal_False );
// status cell should be painted if and only if text is displayed
// note: bPaintStatus is mutable, but Solaris has problems with assigning
@@ -940,16 +940,16 @@ namespace svt
pTHIS->bPaintStatus = static_cast< sal_Bool >
(( GetBrowserFlags() & EBBF_HANDLE_COLUMN_TEXT ) == EBBF_HANDLE_COLUMN_TEXT );
rWindow.Paint(aRect);
- pTHIS->bPaintStatus = sal_True;
- }
-
+ pTHIS->bPaintStatus = sal_True;
+ }
+
// don't paint during row change
- rWindow.EnablePaint(sal_False);
+ rWindow.EnablePaint(sal_False);
// the last veto chance for derived classes
if (!pTHIS->CursorMoving(nNewRow, nNewColId))
{
- pTHIS->InvalidateStatusCell(nEditRow);
+ pTHIS->InvalidateStatusCell(nEditRow);
rWindow.EnablePaint(sal_True);
return sal_False;
}
@@ -958,7 +958,7 @@ namespace svt
rWindow.EnablePaint(sal_True);
return sal_True;
}
- }
+ }
else
return pTHIS->CursorMoving(nNewRow, nNewColId);
}
@@ -996,7 +996,7 @@ namespace svt
if (nEditRow != nNewRow)
{
if ((GetBrowserFlags() & EBBF_NO_HANDLE_COLUMN_CONTENT) == 0)
- InvalidateStatusCell(nNewRow);
+ InvalidateStatusCell(nNewRow);
nEditRow = nNewRow;
}
ActivateCell();
diff --git a/svtools/source/brwbox/editbrowsebox.src b/svtools/source/brwbox/editbrowsebox.src
index d8bb13c..beb2236 100644
--- a/svtools/source/brwbox/editbrowsebox.src
+++ b/svtools/source/brwbox/editbrowsebox.src
@@ -1,7 +1,7 @@
/*************************************************************************
*
* DO NOT ALTER OR REMOVE COPYRIGHT NOTICES OR THIS FILE HEADER.
- *
+ *
* Copyright 2000, 2010 Oracle and/or its affiliates.
*
* OpenOffice.org - a multi-platform office productivity suite
@@ -42,9 +42,15 @@ ImageList RID_SVTOOLS_IMAGELIST_EDITBROWSEBOX
Blue = 0xFFFF;
};
IdList = {
- IMG_EBB_CURRENT; IMG_EBB_MODIFIED;
- IMG_EBB_NEW;IMG_EBB_DELETED;IMG_EBB_CURRENTNEW;
- IMG_EBB_PRIMARYKEY; IMG_EBB_CURRENT_PRIMARYKEY; IMG_EBB_FILTER;IMG_EBB_HEADERFOOTER;
+ IMG_EBB_CURRENT;
+ IMG_EBB_MODIFIED;
+ IMG_EBB_NEW;
+ IMG_EBB_DELETED;
+ IMG_EBB_CURRENTNEW;
+ IMG_EBB_PRIMARYKEY;
+ IMG_EBB_CURRENT_PRIMARYKEY;
+ IMG_EBB_FILTER;
+ IMG_EBB_HEADERFOOTER;
};
IdCount = { 9; };
};
diff --git a/svtools/source/brwbox/editbrowseboximpl.hxx b/svtools/source/brwbox/editbrowseboximpl.hxx
index 46edd68..ec5bdcd 100644
--- a/svtools/source/brwbox/editbrowseboximpl.hxx
+++ b/svtools/source/brwbox/editbrowseboximpl.hxx
@@ -2,7 +2,7 @@
/*************************************************************************
*
* DO NOT ALTER OR REMOVE COPYRIGHT NOTICES OR THIS FILE HEADER.
- *
+ *
* Copyright 2000, 2010 Oracle and/or its affiliates.
*
* OpenOffice.org - a multi-platform office productivity suite
diff --git a/svtools/source/config/colorcfg.cxx b/svtools/source/config/colorcfg.cxx
index defba52..659d939 100644
--- a/svtools/source/config/colorcfg.cxx
+++ b/svtools/source/config/colorcfg.cxx
@@ -2,7 +2,7 @@
/*************************************************************************
*
* DO NOT ALTER OR REMOVE COPYRIGHT NOTICES OR THIS FILE HEADER.
- *
+ *
* Copyright 2000, 2010 Oracle and/or its affiliates.
*
* OpenOffice.org - a multi-platform office productivity suite
@@ -64,10 +64,10 @@ namespace svtools
static const sal_Char cColor[] = "/Color";
static const sal_Char cColorSchemes[] = "ColorSchemes/";
sal_Int32 nColorRefCount_Impl = 0;
-namespace
+namespace
{
- struct ColorMutex_Impl
- : public rtl::Static< ::osl::Mutex, ColorMutex_Impl > {};
+ struct ColorMutex_Impl
+ : public rtl::Static< ::osl::Mutex, ColorMutex_Impl > {};
}
ColorConfig_Impl* ColorConfig::m_pImpl = NULL;
@@ -462,7 +462,7 @@ Color ColorConfig::GetDefaultColor(ColorConfigEntry eEntry)
0x000000, // SQLOPERATOR
0x0000E6, // SQLKEYWORD
0x259D9D, // SQLPARAMTER
- 0x969696,// SQLCOMMENT
+ 0x969696,// SQLCOMMENT
};
Color aRet;
switch(eEntry)
@@ -477,18 +477,13 @@ Color ColorConfig::GetDefaultColor(ColorConfigEntry eEntry)
case SPELL :
case DRAWDRAWING :
- case SMARTTAGS :
- {
- const StyleSettings& rStyleSettings = Application::GetSettings().GetStyleSettings();
- aRet = rStyleSettings.GetHighContrastMode() ?
- rStyleSettings.GetDialogTextColor().GetColor() : aAutoColors[eEntry];
- }
- break;
+ case SMARTTAGS :
+ aRet = aAutoColors[eEntry];
+ break;
case DRAWFILL :
- aRet = /*rStyleSettings.GetHighContrastMode() ?
- rStyleSettings.OutlineMode??? : */ aAutoColors[eEntry];
- break;
+ aRet = aAutoColors[eEntry];
+ break;
case FONTCOLOR :
aRet = Application::GetSettings().GetStyleSettings().GetWindowTextColor();
diff --git a/svtools/source/contnr/ivctrl.cxx b/svtools/source/contnr/ivctrl.cxx
index 3894928..b52b272 100644
--- a/svtools/source/contnr/ivctrl.cxx
+++ b/svtools/source/contnr/ivctrl.cxx
@@ -2,7 +2,7 @@
/*************************************************************************
*
* DO NOT ALTER OR REMOVE COPYRIGHT NOTICES OR THIS FILE HEADER.
- *
+ *
* Copyright 2000, 2010 Oracle and/or its affiliates.
*
* OpenOffice.org - a multi-platform office productivity suite
@@ -46,20 +46,6 @@ SvxIconChoiceCtrlEntry::SvxIconChoiceCtrlEntry( const String& rText, const Image
{
aText = rText;
aImage = rImage;
- aImageHC = rImage;
- pUserData = NULL;
-
- nFlags = _nFlags;
- eTextMode = IcnShowTextShort;
- pblink = 0;
- pflink = 0;
-}
-
-SvxIconChoiceCtrlEntry::SvxIconChoiceCtrlEntry( const String& rText, const Image& rImage, const Image& rImageHC, USHORT _nFlags )
-{
- aText = rText;
- aImage = rImage;
- aImageHC = rImageHC;
pUserData = NULL;
nFlags = _nFlags;
@@ -94,15 +80,6 @@ void SvxIconChoiceCtrlEntry::LockPos( BOOL bLock )
nFlags &= ~ICNVIEW_FLAG_POS_LOCKED;
}
-/*sal_Unicode SvxIconChoiceCtrlEntry::GetMnemonicChar() const
-{
- sal_Unicode cChar = 0;
- xub_StrLen nPos = aText.Search( '~' );
- if ( nPos != STRING_NOTFOUND && nPos < ( aText.Len() ) - 1 )
- cChar = aText.GetChar( nPos + 1 );
- return cChar;
-}*/
-
String SvxIconChoiceCtrlEntry::GetDisplayText() const
{
return MnemonicGenerator::EraseAllMnemonicChars( aText );
@@ -177,43 +154,41 @@ SvxIconChoiceCtrlEntry* SvtIconChoiceCtrl::InsertEntry( const String& rText, con
return pEntry;
}
-SvxIconChoiceCtrlEntry* SvtIconChoiceCtrl::InsertEntry( const String& rText, const Image& rImage, const Image& rImageHC, ULONG nPos, const Point* pPos, USHORT nFlags )
-{
- SvxIconChoiceCtrlEntry* pEntry = new SvxIconChoiceCtrlEntry( rText, rImage, rImageHC, nFlags);
-
- _pImp->InsertEntry( pEntry, nPos, pPos );
-
- return pEntry;
-}
-
BOOL SvtIconChoiceCtrl::EditedEntry( SvxIconChoiceCtrlEntry*, const XubString&, BOOL )
{
return TRUE;
}
+
BOOL SvtIconChoiceCtrl::EditingEntry( SvxIconChoiceCtrlEntry* )
{
return TRUE;
}
+
void SvtIconChoiceCtrl::DrawEntryImage( SvxIconChoiceCtrlEntry* pEntry, const Point& rPos, OutputDevice& rDev )
{
- rDev.DrawImage( rPos, GetSettings().GetStyleSettings().GetHighContrastMode() ? pEntry->GetImageHC() : pEntry->GetImage() );
+ rDev.DrawImage( rPos, pEntry->GetImage() );
}
+
String SvtIconChoiceCtrl::GetEntryText( SvxIconChoiceCtrlEntry* pEntry, BOOL )
{
return pEntry->GetText();
}
+
BOOL SvtIconChoiceCtrl::HasBackground() const
{
return FALSE;
}
+
BOOL SvtIconChoiceCtrl::HasFont() const
{
return FALSE;
}
+
BOOL SvtIconChoiceCtrl::HasFontTextColor() const
{
return TRUE;
}
+
BOOL SvtIconChoiceCtrl::HasFontFillColor() const
{
return TRUE;
diff --git a/svtools/source/contnr/templwin.cxx b/svtools/source/contnr/templwin.cxx
index 21508b6..5a7c61c 100644
--- a/svtools/source/contnr/templwin.cxx
+++ b/svtools/source/contnr/templwin.cxx
@@ -2,7 +2,7 @@
/*************************************************************************
*
* DO NOT ALTER OR REMOVE COPYRIGHT NOTICES OR THIS FILE HEADER.
- *
+ *
* Copyright 2000, 2010 Oracle and/or its affiliates.
*
* OpenOffice.org - a multi-platform office productivity suite
diff --git a/svtools/source/contnr/templwin.hxx b/svtools/source/contnr/templwin.hxx
index 3163c5e..a8e11fa 100644
--- a/svtools/source/contnr/templwin.hxx
+++ b/svtools/source/contnr/templwin.hxx
@@ -2,7 +2,7 @@
/*************************************************************************
*
* DO NOT ALTER OR REMOVE COPYRIGHT NOTICES OR THIS FILE HEADER.
- *
+ *
* Copyright 2000, 2010 Oracle and/or its affiliates.
*
* OpenOffice.org - a multi-platform office productivity suite
diff --git a/svtools/source/misc/imagemgr.cxx b/svtools/source/misc/imagemgr.cxx
index 938204b..f22358f 100644
--- a/svtools/source/misc/imagemgr.cxx
+++ b/svtools/source/misc/imagemgr.cxx
@@ -2,7 +2,7 @@
/*************************************************************************
*
* DO NOT ALTER OR REMOVE COPYRIGHT NOTICES OR THIS FILE HEADER.
- *
+ *
* Copyright 2000, 2010 Oracle and/or its affiliates.
*
* OpenOffice.org - a multi-platform office productivity suite
diff --git a/svtools/source/misc/imagemgr.src b/svtools/source/misc/imagemgr.src
index 3d66a21..723de62 100644
--- a/svtools/source/misc/imagemgr.src
+++ b/svtools/source/misc/imagemgr.src
@@ -1,7 +1,7 @@
/*************************************************************************
*
* DO NOT ALTER OR REMOVE COPYRIGHT NOTICES OR THIS FILE HEADER.
- *
+ *
* Copyright 2000, 2010 Oracle and/or its affiliates.
*
* OpenOffice.org - a multi-platform office productivity suite
diff --git a/svtools/source/uno/contextmenuhelper.cxx b/svtools/source/uno/contextmenuhelper.cxx
index 13391a6..4d163f6 100644
--- a/svtools/source/uno/contextmenuhelper.cxx
+++ b/svtools/source/uno/contextmenuhelper.cxx
@@ -2,7 +2,7 @@
/*************************************************************************
*
* DO NOT ALTER OR REMOVE COPYRIGHT NOTICES OR THIS FILE HEADER.
- *
+ *
* Copyright 2000, 2010 Oracle and/or its affiliates.
*
* OpenOffice.org - a multi-platform office productivity suite
@@ -44,7 +44,7 @@
#include <com/sun/star/ui/ImageType.hpp>
#include <com/sun/star/beans/PropertyValue.hpp>
-#include <osl/conditn.hxx>
+#include <osl/conditn.hxx>
#include <cppuhelper/weak.hxx>
#include <comphelper/processfactory.hxx>
#include <osl/mutex.hxx>
@@ -53,7 +53,7 @@
#include <toolkit/unohlp.hxx>
#include <toolkit/awt/vclxwindow.hxx>
#include <toolkit/awt/vclxmenu.hxx>
-
+
using namespace ::com::sun::star;
namespace svt
@@ -75,13 +75,13 @@ class StateEventHelper : public ::com::sun::star::frame::XStatusListener,
virtual uno::Any SAL_CALL queryInterface( const uno::Type& aType ) throw ( uno::RuntimeException);
virtual void SAL_CALL acquire() throw ();
virtual void SAL_CALL release() throw ();
-
+
// XEventListener
virtual void SAL_CALL disposing(const lang::EventObject& Source) throw( uno::RuntimeException );
-
+
// XStatusListener
virtual void SAL_CALL statusChanged(const frame::FeatureStateEvent& Event) throw( uno::RuntimeException );
-
+
private:
StateEventHelper();
StateEventHelper( const StateEventHelper& );
@@ -91,7 +91,7 @@ class StateEventHelper : public ::com::sun::star::frame::XStatusListener,
::rtl::OUString m_aCommandURL;
uno::Reference< frame::XDispatchProvider > m_xDispatchProvider;
uno::Reference< util::XURLTransformer > m_xURLTransformer;
- osl::Condition m_aCondition;
+ osl::Condition m_aCondition;
};
StateEventHelper::StateEventHelper(
@@ -113,13 +113,13 @@ uno::Any SAL_CALL StateEventHelper::queryInterface(
const uno::Type& aType )
throw ( uno::RuntimeException )
{
- uno::Any a = ::cppu::queryInterface(
+ uno::Any a = ::cppu::queryInterface(
aType,
SAL_STATIC_CAST( XStatusListener*, this ));
-
+
if( a.hasValue() )
return a;
-
+
return ::cppu::OWeakObject::queryInterface( aType );
}
@@ -135,7 +135,7 @@ throw ()
::cppu::OWeakObject::release();
}
-void SAL_CALL StateEventHelper::disposing(
+void SAL_CALL StateEventHelper::disposing(
const lang::EventObject& )
throw ( uno::RuntimeException )
{
@@ -145,7 +145,7 @@ throw ( uno::RuntimeException )
m_aCondition.set();
}
-void SAL_CALL StateEventHelper::statusChanged(
+void SAL_CALL StateEventHelper::statusChanged(
const frame::FeatureStateEvent& Event )
throw ( uno::RuntimeException )
{
@@ -157,9 +157,9 @@ throw ( uno::RuntimeException )
bool StateEventHelper::isCommandEnabled()
{
// Be sure that we cannot die during condition wait
- uno::Reference< frame::XStatusListener > xSelf(
+ uno::Reference< frame::XStatusListener > xSelf(
SAL_STATIC_CAST( frame::XStatusListener*, this ));
-
+
uno::Reference< frame::XDispatch > xDispatch;
util::URL aTargetURL;
{
@@ -167,7 +167,7 @@ bool StateEventHelper::isCommandEnabled()
if ( m_xDispatchProvider.is() && m_xURLTransformer.is() )
{
::rtl::OUString aSelf( RTL_CONSTASCII_USTRINGPARAM( "_self" ));
-
+
aTargetURL.Complete = m_aCommandURL;
m_xURLTransformer->parseStrict( aTargetURL );
@@ -193,7 +193,7 @@ bool StateEventHelper::isCommandEnabled()
// add/remove ourself to retrieve status by callback
xDispatch->addStatusListener( xSelf, aTargetURL );
xDispatch->removeStatusListener( xSelf, aTargetURL );
-
+
// wait for anwser
m_aCondition.wait();
}
@@ -208,19 +208,19 @@ bool StateEventHelper::isCommandEnabled()
SolarMutexGuard aSolarGuard;
bResult = m_bCurrentCommandEnabled;
}
-
+
return bResult;
}
/*************************************************************************/
-
+
struct ExecuteInfo
{
uno::Reference< frame::XDispatch > xDispatch;
util::URL aTargetURL;
uno::Sequence< beans::PropertyValue > aArgs;
};
-
+
static const PopupMenu* lcl_FindPopupFromItemId( const PopupMenu* pPopupMenu, sal_uInt16 nItemId )
{
if ( pPopupMenu )
@@ -234,7 +234,7 @@ static const PopupMenu* lcl_FindPopupFromItemId( const PopupMenu* pPopupMenu, sa
else
{
const PopupMenu* pResult( 0 );
-
+
const PopupMenu* pSubPopup = pPopupMenu->GetPopupMenu( i );
if ( pPopupMenu )
pResult = lcl_FindPopupFromItemId( pSubPopup, nItemId );
@@ -259,7 +259,7 @@ static ::rtl::OUString lcl_GetItemCommandRecursive( const PopupMenu* pPopupMenu,
/*************************************************************************/
ContextMenuHelper::ContextMenuHelper(
- const uno::Reference< frame::XFrame >& xFrame,
+ const uno::Reference< frame::XFrame >& xFrame,
bool bAutoRefresh ) :
m_xWeakFrame( xFrame ),
m_aSelf( RTL_CONSTASCII_USTRINGPARAM( "_self" )),
@@ -272,22 +272,22 @@ ContextMenuHelper::~ContextMenuHelper()
{
}
-void
-ContextMenuHelper::completeAndExecute(
- const Point& aPos,
+void
+ContextMenuHelper::completeAndExecute(
+ const Point& aPos,
PopupMenu& rPopupMenu )
{
SolarMutexGuard aSolarGuard;
-
+
associateUIConfigurationManagers();
completeMenuProperties( &rPopupMenu );
executePopupMenu( aPos, &rPopupMenu );
resetAssociations();
}
-void
-ContextMenuHelper::completeAndExecute(
- const Point& aPos,
+void
+ContextMenuHelper::completeAndExecute(
+ const Point& aPos,
const uno::Reference< awt::XPopupMenu >& xPopupMenu )
{
SolarMutexGuard aSolarGuard;
@@ -307,17 +307,17 @@ ContextMenuHelper::completeAndExecute(
}
}
-uno::Reference< awt::XPopupMenu >
-ContextMenuHelper::create(
+uno::Reference< awt::XPopupMenu >
+ContextMenuHelper::create(
const ::rtl::OUString& /*aPopupMenuResourceId*/ )
{
// NOT IMPLEMENTED YET!
return uno::Reference< awt::XPopupMenu >();
}
-bool
-ContextMenuHelper::createAndExecute(
- const Point& /*aPos*/,
+bool
+ContextMenuHelper::createAndExecute(
+ const Point& /*aPos*/,
const ::rtl::OUString& /*aPopupMenuResourceId*/ )
{
// NOT IMPLEMENTED YET!
@@ -326,8 +326,8 @@ ContextMenuHelper::createAndExecute(
// private member
-void
-ContextMenuHelper::executePopupMenu(
+void
+ContextMenuHelper::executePopupMenu(
const Point& rPos,
PopupMenu* pMenu )
{
@@ -354,19 +354,19 @@ ContextMenuHelper::executePopupMenu(
}
bool
-ContextMenuHelper::dispatchCommand(
+ContextMenuHelper::dispatchCommand(
const uno::Reference< ::frame::XFrame >& rFrame,
const ::rtl::OUString& aCommandURL )
{
if ( !m_xURLTransformer.is() )
{
- m_xURLTransformer = uno::Reference< util::XURLTransformer >(
+ m_xURLTransformer = uno::Reference< util::XURLTransformer >(
::comphelper::getProcessServiceFactory()->createInstance(
rtl::OUString( RTL_CONSTASCII_USTRINGPARAM(
"com.sun.star.util.URLTransformer" ))),
uno::UNO_QUERY );
}
-
+
util::URL aTargetURL;
uno::Reference< frame::XDispatch > xDispatch;
if ( m_xURLTransformer.is() )
@@ -374,7 +374,7 @@ ContextMenuHelper::dispatchCommand(
aTargetURL.Complete = aCommandURL;
m_xURLTransformer->parseStrict( aTargetURL );
- uno::Reference< frame::XDispatchProvider > xDispatchProvider(
+ uno::Reference< frame::XDispatchProvider > xDispatchProvider(
rFrame, uno::UNO_QUERY );
if ( xDispatchProvider.is() )
{
@@ -434,9 +434,9 @@ ContextMenuHelper::associateUIConfigurationManagers()
uno::Reference< ui::XUIConfigurationManagerSupplier > xSupplier( xModel, uno::UNO_QUERY );
if ( xSupplier.is() )
{
- uno::Reference< ui::XUIConfigurationManager > xDocUICfgMgr(
+ uno::Reference< ui::XUIConfigurationManager > xDocUICfgMgr(
xSupplier->getUIConfigurationManager(), uno::UNO_QUERY );
- m_xDocImageMgr = uno::Reference< ui::XImageManager >(
+ m_xDocImageMgr = uno::Reference< ui::XImageManager >(
xDocUICfgMgr->getImageManager(), uno::UNO_QUERY );
}
}
@@ -446,7 +446,7 @@ ContextMenuHelper::associateUIConfigurationManagers()
rtl::OUString( RTL_CONSTASCII_USTRINGPARAM(
"com.sun.star.frame.ModuleManager" ))),
uno::UNO_QUERY );
-
+
uno::Reference< ui::XImageManager > xModuleImageManager;
rtl::OUString aModuleId;
if ( xModuleManager.is() )
@@ -461,11 +461,11 @@ ContextMenuHelper::associateUIConfigurationManagers()
uno::UNO_QUERY );
if ( xModuleCfgMgrSupplier.is() )
{
- uno::Reference< ui::XUIConfigurationManager > xUICfgMgr(
+ uno::Reference< ui::XUIConfigurationManager > xUICfgMgr(
xModuleCfgMgrSupplier->getUIConfigurationManager( aModuleId ));
if ( xUICfgMgr.is() )
{
- m_xModuleImageMgr = uno::Reference< ui::XImageManager >(
+ m_xModuleImageMgr = uno::Reference< ui::XImageManager >(
xUICfgMgr->getImageManager(), uno::UNO_QUERY );
}
}
@@ -503,21 +503,17 @@ ContextMenuHelper::associateUIConfigurationManagers()
return true;
}
-Image
-ContextMenuHelper::getImageFromCommandURL(
- const ::rtl::OUString& aCmdURL,
- bool bHiContrast ) const
+Image
+ContextMenuHelper::getImageFromCommandURL( const ::rtl::OUString& aCmdURL ) const
{
Image aImage;
sal_Int16 nImageType( ui::ImageType::COLOR_NORMAL|
ui::ImageType::SIZE_DEFAULT );
- if ( bHiContrast )
- nImageType |= ui::ImageType::COLOR_HIGHCONTRAST;
-
+
uno::Sequence< uno::Reference< graphic::XGraphic > > aGraphicSeq;
uno::Sequence< ::rtl::OUString > aImageCmdSeq( 1 );
aImageCmdSeq[0] = aCmdURL;
-
+
if ( m_xDocImageMgr.is() )
{
try
@@ -537,14 +533,14 @@ ContextMenuHelper::getImageFromCommandURL(
{
}
}
-
+
if ( m_xModuleImageMgr.is() )
{
try
{
aGraphicSeq = m_xModuleImageMgr->getImages( nImageType, aImageCmdSeq );
uno::Reference< ::com::sun::star::graphic::XGraphic > xGraphic = aGraphicSeq[0];
- aImage = Image( xGraphic );
+ aImage = Image( xGraphic );
if ( !!aImage )
return aImage;
@@ -562,11 +558,11 @@ ContextMenuHelper::getImageFromCommandURL(
}
rtl::OUString
-ContextMenuHelper::getLabelFromCommandURL(
+ContextMenuHelper::getLabelFromCommandURL(
const ::rtl::OUString& aCmdURL ) const
{
::rtl::OUString aLabel;
-
+
if ( m_xUICommandLabels.is() )
{
try
@@ -601,30 +597,29 @@ ContextMenuHelper::getLabelFromCommandURL(
return aLabel;
}
-void
-ContextMenuHelper::completeMenuProperties(
+void
+ContextMenuHelper::completeMenuProperties(
Menu* pMenu )
{
// Retrieve some settings necessary to display complete context
// menu correctly.
const StyleSettings& rSettings = Application::GetSettings().GetStyleSettings();
bool bShowMenuImages( rSettings.GetUseImagesInMenus() );
- bool bIsHiContrast( rSettings.GetHighContrastMode() );
-
+
if ( pMenu )
{
uno::Reference< frame::XFrame > xFrame( m_xWeakFrame );
uno::Reference< frame::XDispatchProvider > xDispatchProvider( xFrame, uno::UNO_QUERY );
-
+
if ( !m_xURLTransformer.is() )
{
- m_xURLTransformer = uno::Reference< util::XURLTransformer >(
+ m_xURLTransformer = uno::Reference< util::XURLTransformer >(
::comphelper::getProcessServiceFactory()->createInstance(
rtl::OUString( RTL_CONSTASCII_USTRINGPARAM(
"com.sun.star.util.URLTransformer" ))),
uno::UNO_QUERY );
}
-
+
for ( sal_uInt16 nPos = 0; nPos < pMenu->GetItemCount(); nPos++ )
{
sal_uInt16 nId = pMenu->GetItemId( nPos );
@@ -634,12 +629,12 @@ ContextMenuHelper::completeMenuProperties(
if ( pMenu->GetItemType( nPos ) != MENUITEM_SEPARATOR )
{
::rtl::OUString aCmdURL( pMenu->GetItemCommand( nId ));
-
+
if ( bShowMenuImages )
{
Image aImage;
if ( aCmdURL.getLength() > 0 )
- aImage = getImageFromCommandURL( aCmdURL, bIsHiContrast );
+ aImage = getImageFromCommandURL( aCmdURL );
pMenu->SetItemImage( nId, aImage );
}
else
@@ -652,8 +647,8 @@ ContextMenuHelper::completeMenuProperties(
}
// Use helper to retrieve state of the command URL
- StateEventHelper* pHelper = new StateEventHelper(
- xDispatchProvider,
+ StateEventHelper* pHelper = new StateEventHelper(
+ xDispatchProvider,
m_xURLTransformer,
aCmdURL );
@@ -667,7 +662,7 @@ ContextMenuHelper::completeMenuProperties(
IMPL_STATIC_LINK_NOINSTANCE( ContextMenuHelper, ExecuteHdl_Impl, ExecuteInfo*, pExecuteInfo )
{
- // Release solar mutex to prevent deadlocks with clipboard thread
+ // Release solar mutex to prevent deadlocks with clipboard thread
const sal_uInt32 nRef = Application::ReleaseSolarMutex();
try
{
diff --git a/svtools/source/uno/toolboxcontroller.cxx b/svtools/source/uno/toolboxcontroller.cxx
index 285b2ae..b79ae18 100644
--- a/svtools/source/uno/toolboxcontroller.cxx
+++ b/svtools/source/uno/toolboxcontroller.cxx
@@ -2,7 +2,7 @@
/*************************************************************************
*
* DO NOT ALTER OR REMOVE COPYRIGHT NOTICES OR THIS FILE HEADER.
- *
+ *
* Copyright 2000, 2010 Oracle and/or its affiliates.
*
* OpenOffice.org - a multi-platform office productivity suite
@@ -41,7 +41,7 @@
#include <toolkit/unohlp.hxx>
#include <vcl/toolbox.hxx>
-//shizhobo
+//shizhobo
#include <com/sun/star/beans/PropertyAttribute.hpp>
const int TOOLBARCONTROLLER_PROPHANDLE_SUPPORTSVISIABLE = 1;
const int TOOLBARCONTROLLER_PROPCOUNT = 1;
@@ -87,7 +87,7 @@ struct ToolboxController_Impl
};
ToolboxController::ToolboxController(
-
+
const Reference< XMultiServiceFactory >& rServiceManager,
const Reference< XFrame >& xFrame,
const ::rtl::OUString& aCommandURL ) :
@@ -190,7 +190,7 @@ throw ( RuntimeException )
,static_cast<XMultiPropertySet*>(this)
,static_cast<XFastPropertySet*>(this));
if (!a.hasValue())
- return OWeakObject::queryInterface( rType );
+ return OWeakObject::queryInterface( rType );
}
return a;
}
@@ -209,7 +209,7 @@ void SAL_CALL ToolboxController::initialize( const Sequence< Any >& aArguments )
throw ( Exception, RuntimeException )
{
bool bInitialized( true );
-
+
{
SolarMutexGuard aSolarMutexGuard;
@@ -223,7 +223,7 @@ throw ( Exception, RuntimeException )
{
SolarMutexGuard aSolarMutexGuard;
m_bInitialized = sal_True;
- //shizhoubo add
+ //shizhoubo add
m_bSupportVisiable = sal_False;
PropertyValue aPropValue;
for ( int i = 0; i < aArguments.getLength(); i++ )
@@ -261,13 +261,13 @@ throw ( Exception, RuntimeException )
void SAL_CALL ToolboxController::update()
throw ( RuntimeException )
-{
+{
{
SolarMutexGuard aSolarMutexGuard;
if ( m_bDisposed )
throw DisposedException();
}
-
+
// Bind all registered listeners to their dispatch objects
bindListener();
}
@@ -673,22 +673,6 @@ sal_Bool ToolboxController::hasBigImages() const
return SvtMiscOptions().AreCurrentSymbolsLarge();
}
-sal_Bool ToolboxController::isHighContrast() const
-{
- sal_Bool bHighContrast( sal_False );
-
- Reference< XWindow > xWindow = m_pImpl->m_xParentWindow;
- if ( xWindow.is() )
- {
- SolarMutexGuard aSolarMutexGuard;
- Window* pWindow = VCLUnoHelper::GetWindow( xWindow );
- if ( pWindow )
- bHighContrast = ( ((ToolBox *)pWindow)->GetSettings().GetStyleSettings().GetHighContrastMode() );
- }
-
- return bHighContrast;
-}
-
void ToolboxController::updateStatus()
{
bindListener();
@@ -755,7 +739,7 @@ void ToolboxController::dispatchCommand( const OUString& sCommandURL, const Sequ
try
{
Reference< XDispatchProvider > xDispatchProvider( m_xFrame, UNO_QUERY_THROW );
- URL aURL;
+ URL aURL;
aURL.Complete = sCommandURL;
getURLTransformer()->parseStrict( aURL );
@@ -826,7 +810,7 @@ throw( com::sun::star::uno::Exception)
{
OPropertyContainer::setFastPropertyValue_NoBroadcast(nHandle, aValue);
if (TOOLBARCONTROLLER_PROPHANDLE_SUPPORTSVISIABLE == nHandle)
- {
+ {
sal_Bool rValue(sal_False);
if (( aValue >>= rValue ) && m_bInitialized)
this->setSupportVisiableProperty( rValue );
diff --git a/unotools/inc/unotools/lingucfg.hxx b/unotools/inc/unotools/lingucfg.hxx
index 0b4ab94..a50f057 100644
--- a/unotools/inc/unotools/lingucfg.hxx
+++ b/unotools/inc/unotools/lingucfg.hxx
@@ -2,7 +2,7 @@
/*************************************************************************
*
* DO NOT ALTER OR REMOVE COPYRIGHT NOTICES OR THIS FILE HEADER.
- *
+ *
* Copyright 2000, 2010 Oracle and/or its affiliates.
*
* OpenOffice.org - a multi-platform office productivity suite
@@ -228,11 +228,11 @@ public:
std::vector< SvtLinguConfigDictionaryEntry > GetActiveDictionariesByFormat( const rtl::OUString &rFormatName );
// functions returning file URLs to the respective images (if found) and empty string otherwise
- ::rtl::OUString GetSpellAndGrammarDialogImage( const ::rtl::OUString &rServiceImplName, bool bHighContrast = false ) const;
- ::rtl::OUString GetSpellAndGrammarContextSuggestionImage( const ::rtl::OUString &rServiceImplName, bool bHighContrast = false ) const;
- ::rtl::OUString GetSpellAndGrammarContextDictionaryImage( const ::rtl::OUString &rServiceImplName, bool bHighContrast = false ) const;
- ::rtl::OUString GetThesaurusDialogImage( const ::rtl::OUString &rServiceImplName, bool bHighContrast = false ) const;
- ::rtl::OUString GetSynonymsContextImage( const ::rtl::OUString &rServiceImplName, bool bHighContrast = false ) const;
+ ::rtl::OUString GetSpellAndGrammarDialogImage( const ::rtl::OUString &rServiceImplName ) const;
+ ::rtl::OUString GetSpellAndGrammarContextSuggestionImage( const ::rtl::OUString &rServiceImplName ) const;
+ ::rtl::OUString GetSpellAndGrammarContextDictionaryImage( const ::rtl::OUString &rServiceImplName ) const;
+ ::rtl::OUString GetThesaurusDialogImage( const ::rtl::OUString &rServiceImplName ) const;
+ ::rtl::OUString GetSynonymsContextImage( const ::rtl::OUString &rServiceImplName ) const;
bool HasVendorImages( const char *pImageName ) const;
bool HasGrammarChecker() const;
diff --git a/unotools/source/config/lingucfg.cxx b/unotools/source/config/lingucfg.cxx
index ab5be38..e82c070 100644
--- a/unotools/source/config/lingucfg.cxx
+++ b/unotools/source/config/lingucfg.cxx
@@ -2,7 +2,7 @@
/*************************************************************************
*
* DO NOT ALTER OR REMOVE COPYRIGHT NOTICES OR THIS FILE HEADER.
- *
+ *
* Copyright 2000, 2010 Oracle and/or its affiliates.
*
* OpenOffice.org - a multi-platform office productivity suite
@@ -1364,13 +1364,13 @@ rtl::OUString SvtLinguConfig::GetVendorImageUrl_Impl(
rtl::OUString SvtLinguConfig::GetSpellAndGrammarDialogImage(
- const rtl::OUString &rServiceImplName,
- bool bHighContrast ) const
+ const rtl::OUString &rServiceImplName
+) const
{
rtl::OUString aRes;
if (rServiceImplName.getLength() > 0)
{
- rtl::OUString aImageName( A2OU( bHighContrast ? "SpellAndGrammarDialogImage_HC" : "SpellAndGrammarDialogImage" ));
+ rtl::OUString aImageName( A2OU( "SpellAndGrammarDialogImage" ));
rtl::OUString aPath( GetVendorImageUrl_Impl( rServiceImplName, aImageName ) );
aRes = aPath;
}
@@ -1379,13 +1379,13 @@ rtl::OUString SvtLinguConfig::GetSpellAndGrammarDialogImage(
rtl::OUString SvtLinguConfig::GetSpellAndGrammarContextSuggestionImage(
- const rtl::OUString &rServiceImplName,
- bool bHighContrast ) const
+ const rtl::OUString &rServiceImplName
+) const
{
rtl::OUString aRes;
if (rServiceImplName.getLength() > 0)
{
- rtl::OUString aImageName( A2OU( bHighContrast ? "SpellAndGrammarContextMenuSuggestionImage_HC" : "SpellAndGrammarContextMenuSuggestionImage" ));
+ rtl::OUString aImageName( A2OU( "SpellAndGrammarContextMenuSuggestionImage" ));
rtl::OUString aPath( GetVendorImageUrl_Impl( rServiceImplName, aImageName ) );
aRes = aPath;
}
@@ -1394,13 +1394,13 @@ rtl::OUString SvtLinguConfig::GetSpellAndGrammarContextSuggestionImage(
rtl::OUString SvtLinguConfig::GetSpellAndGrammarContextDictionaryImage(
- const rtl::OUString &rServiceImplName,
- bool bHighContrast ) const
+ const rtl::OUString &rServiceImplName
+) const
{
rtl::OUString aRes;
if (rServiceImplName.getLength() > 0)
{
- rtl::OUString aImageName( A2OU( bHighContrast ? "SpellAndGrammarContextMenuDictionaryImage_HC" : "SpellAndGrammarContextMenuDictionaryImage" ));
+ rtl::OUString aImageName( A2OU( "SpellAndGrammarContextMenuDictionaryImage" ));
rtl::OUString aPath( GetVendorImageUrl_Impl( rServiceImplName, aImageName ) );
aRes = aPath;
}
@@ -1408,35 +1408,35 @@ rtl::OUString SvtLinguConfig::GetSpellAndGrammarContextDictionaryImage(
}
-::rtl::OUString SvtLinguConfig::GetThesaurusDialogImage(
- const ::rtl::OUString &rServiceImplName,
- bool bHighContrast ) const
+::rtl::OUString SvtLinguConfig::GetThesaurusDialogImage(
+ const ::rtl::OUString &rServiceImplName
+) const
{
rtl::OUString aRes;
if (rServiceImplName.getLength() > 0)
{
- rtl::OUString aImageName( A2OU( bHighContrast ? "ThesaurusDialogImage_HC" : "ThesaurusDialogImage" ));
+ rtl::OUString aImageName( A2OU( "ThesaurusDialogImage" ));
rtl::OUString aPath( GetVendorImageUrl_Impl( rServiceImplName, aImageName ) );
aRes = aPath;
}
return aRes;
}
-
-::rtl::OUString SvtLinguConfig::GetSynonymsContextImage(
- const ::rtl::OUString &rServiceImplName,
- bool bHighContrast ) const
+
+::rtl::OUString SvtLinguConfig::GetSynonymsContextImage(
+ const ::rtl::OUString &rServiceImplName
+) const
{
rtl::OUString aRes;
if (rServiceImplName.getLength() > 0)
{
- rtl::OUString aImageName( A2OU( bHighContrast ? "SynonymsContextMenuImage_HC" : "SynonymsContextMenuImage" ));
+ rtl::OUString aImageName( A2OU( "SynonymsContextMenuImage" ));
rtl::OUString aPath( GetVendorImageUrl_Impl( rServiceImplName, aImageName ) );
aRes = aPath;
}
return aRes;
}
-
+
bool SvtLinguConfig::HasVendorImages( const char *pImageName ) const
{
@@ -1466,9 +1466,9 @@ bool SvtLinguConfig::HasVendorImages( const char *pImageName ) const
{
bRes = true;
break;
- }
- }
- }
+ }
+ }
+ }
}
catch (uno::Exception &)
{
@@ -1477,7 +1477,7 @@ bool SvtLinguConfig::HasVendorImages( const char *pImageName ) const
}
return bRes;
}
-
+
bool SvtLinguConfig::HasGrammarChecker() const
{
diff --git a/vcl/inc/vcl/svids.hrc b/vcl/inc/vcl/svids.hrc
index e44f8f3..7e86474 100644
--- a/vcl/inc/vcl/svids.hrc
+++ b/vcl/inc/vcl/svids.hrc
@@ -54,7 +54,6 @@
#define SV_RESID_BITMAP_SCROLLMSK 1050
#define SV_RESID_BITMAP_SCROLLBMP 1051
#define SV_RESID_BITMAP_CLOSEDOC 1052
-#define SV_RESID_BITMAP_CLOSEDOCHC 1053
#define SV_DISCLOSURE_PLUS 1060
#define SV_DISCLOSURE_MINUS 1061
diff --git a/vcl/source/src/images.src b/vcl/source/src/images.src
index 542100f..35b52f4 100644
--- a/vcl/source/src/images.src
+++ b/vcl/source/src/images.src
@@ -1,7 +1,7 @@
/*************************************************************************
*
* DO NOT ALTER OR REMOVE COPYRIGHT NOTICES OR THIS FILE HEADER.
- *
+ *
* Copyright 2000, 2010 Oracle and/or its affiliates.
*
* OpenOffice.org - a multi-platform office productivity suite
@@ -120,11 +120,6 @@ Bitmap SV_RESID_BITMAP_CLOSEDOC
File = "closedoc.bmp";
};
-Bitmap SV_RESID_BITMAP_CLOSEDOCHC
-{
- File = "closedochc.bmp";
-};
-
Bitmap SV_RESID_BITMAP_SPLITHPIN
{
File = "splhpin.bmp";
diff --git a/vcl/source/window/menu.cxx b/vcl/source/window/menu.cxx
index e4e2716..be74bf3 100644
--- a/vcl/source/window/menu.cxx
+++ b/vcl/source/window/menu.cxx
@@ -2,7 +2,7 @@
/*************************************************************************
*
* DO NOT ALTER OR REMOVE COPYRIGHT NOTICES OR THIS FILE HEADER.
- *
+ *
* Copyright 2000, 2010 Oracle and/or its affiliates.
*
* OpenOffice.org - a multi-platform office productivity suite
@@ -188,7 +188,7 @@ struct MenuItemData
return bChecked || ( nBits & ( MIB_RADIOCHECK | MIB_CHECKABLE | MIB_AUTOCHECK ) );
}
};
-
+
MenuItemData::~MenuItemData()
{
if( pAutoSubMenu )
@@ -374,7 +374,7 @@ MenuItemData* MenuItemList::SearchItem( xub_Unicode cSelectChar, KeyCode aKeyCod
KeyCode mnKeyCode;
xub_Unicode mnUnicode = pData->aText.GetChar(n+1);
Window* pDefWindow = ImplGetDefaultWindow();
- if( (pDefWindow && pDefWindow->ImplGetFrame()->MapUnicodeToKeyCode( mnUnicode, Application::GetSettings().GetUILanguage(), mnKeyCode )
+ if( (pDefWindow && pDefWindow->ImplGetFrame()->MapUnicodeToKeyCode( mnUnicode, Application::GetSettings().GetUILanguage(), mnKeyCode )
&& aKeyCode.GetCode() == mnKeyCode.GetCode())
|| (ascii && rI18nHelper.MatchMnemonic( pData->aText, ascii ) ) )
@@ -430,7 +430,7 @@ USHORT MenuItemList::GetItemCount( KeyCode aKeyCode ) const
// if MapUnicodeToKeyCode fails or is unsupported we try the pure ascii mapping of the keycodes
// so we have working shortcuts when ascii mnemonics are used
Window* pDefWindow = ImplGetDefaultWindow();
- if( (pDefWindow && pDefWindow->ImplGetFrame()->MapUnicodeToKeyCode( pData->aText.GetChar(n+1), Application::GetSettings().GetUILanguage(), mnKeyCode )
+ if( (pDefWindow && pDefWindow->ImplGetFrame()->MapUnicodeToKeyCode( pData->aText.GetChar(n+1), Application::GetSettings().GetUILanguage(), mnKeyCode )
&& aKeyCode.GetCode() == mnKeyCode.GetCode())
|| ( ascii && rI18nHelper.MatchMnemonic( pData->aText, ascii ) ) )
nItems++;
@@ -488,7 +488,7 @@ private:
DECL_LINK( ShowHideListener, VclWindowEvent* );
void StateChanged( StateChangedType nType );
- void DataChanged( const DataChangedEvent& rDCEvt );
+ void DataChanged( const DataChangedEvent& rDCEvt );
protected:
Region ImplCalcClipRegion( BOOL bIncludeLogo = TRUE ) const;
void ImplInitClipRegion();
@@ -562,7 +562,6 @@ public:
Size getMinSize();
Image maImage;
- Image maImageHC;
};
DecoToolBox::DecoToolBox( Window* pParent, WinBits nStyle ) :
@@ -600,7 +599,7 @@ void DecoToolBox::calcMinSize()
if( GetItemCount() == 0 )
{
ResMgr* pResMgr = ImplGetResMgr();
-
+
Bitmap aBitmap;
if( pResMgr )
aBitmap = Bitmap( ResId( SV_RESID_BITMAP_CLOSEDOC, *pResMgr ) );
@@ -616,7 +615,7 @@ void DecoToolBox::calcMinSize()
}
}
aTbx.SetOutStyle( TOOLBOX_STYLE_FLAT );
- maMinSize = aTbx.CalcWindowSizePixel();
+ maMinSize = aTbx.CalcWindowSizePixel();
}
Size DecoToolBox::getMinSize()
@@ -640,19 +639,18 @@ void DecoToolBox::SetImages( long nMaxHeight, bool bForce )
Color aEraseColor( 255, 255, 255, 255 );
BitmapEx aBmpExDst( maImage.GetBitmapEx() );
- BitmapEx aBmpExSrc( GetSettings().GetStyleSettings().GetHighContrastMode() ?
- maImageHC.GetBitmapEx() : aBmpExDst );
-
+ BitmapEx aBmpExSrc( aBmpExDst );
+
aEraseColor.SetTransparency( 255 );
aBmpExDst.Erase( aEraseColor );
aBmpExDst.SetSizePixel( Size( lastSize, lastSize ) );
-
+
Rectangle aSrcRect( Point(0,0), maImage.GetSizePixel() );
- Rectangle aDestRect( Point((lastSize - maImage.GetSizePixel().Width())/2,
- (lastSize - maImage.GetSizePixel().Height())/2 ),
+ Rectangle aDestRect( Point((lastSize - maImage.GetSizePixel().Width())/2,
+ (lastSize - maImage.GetSizePixel().Height())/2 ),
maImage.GetSizePixel() );
-
+
aBmpExDst.CopyPixel( aDestRect, aSrcRect, &aBmpExSrc );
SetItemImage( IID_DOCUMENTCLOSE, Image( aBmpExDst ) );
}
@@ -676,7 +674,7 @@ private:
USHORT m_nId;
Link m_aSelectLink;
Link m_aHighlightLink;
-
+
AddButtonEntry() : m_nId( 0 ) {}
};
@@ -691,7 +689,7 @@ private:
DecoToolBox aCloser;
PushButton aFloatBtn;
PushButton aHideBtn;
-
+
std::map< USHORT, AddButtonEntry > m_aAddButtons;
void HighlightItem( USHORT nPos, BOOL bHighlight );
@@ -701,7 +699,7 @@ private:
void ImplCreatePopup( BOOL bPreSelectFirst );
BOOL ImplHandleKeyEvent( const KeyEvent& rKEvent, BOOL bFromMenu = TRUE );
Rectangle ImplGetItemRect( USHORT nPos );
-
+
void ImplInitStyleSettings();
DECL_LINK( CloserHdl, PushButton* );
@@ -742,7 +740,7 @@ public:
void SetAutoPopup( BOOL bAuto ) { mbAutoPopup = bAuto; }
void ImplLayoutChanged();
Size MinCloseButtonSize();
-
+
// add an arbitrary button to the menubar (will appear next to closer)
USHORT AddMenuBarButton( const Image&, const Link&, const String&, USHORT nPos );
void SetMenuBarButtonHighlightHdl( USHORT nId, const Link& );
@@ -793,7 +791,7 @@ static BOOL ImplHandleHelpEvent( Window* pMenuWindow, Menu* pMenu, USHORT nHighl
{
if( ! pMenu )
return FALSE;
-
+
BOOL bDone = FALSE;
USHORT nId = 0;
@@ -846,7 +844,7 @@ static BOOL ImplHandleHelpEvent( Window* pMenuWindow, Menu* pMenu, USHORT nHighl
// den Hilfe-Index
String aCommand = pMenu->GetItemCommand( nId );
ULONG nHelpId = pMenu->GetHelpId( nId );
-
+
if ( aCommand.Len() )
pHelp->Start( aCommand, NULL );
else if ( nHelpId )
@@ -913,7 +911,7 @@ Menu::Menu( BOOL bMenubar )
Menu::~Menu()
{
DBG_DTOR( Menu, NULL );
-
+
vcl::LazyDeletor<Menu>::Undelete( this );
ImplCallEventListeners( VCLEVENT_OBJECT_DYING, ITEMPOS_INVALID );
@@ -994,7 +992,7 @@ void Menu::ImplLoadRes( const ResId& rResId )
ResMgr* pMgr = rResId.GetResMgr();
if( ! pMgr )
return;
-
+
rResId.SetRT( RSC_MENU );
GetRes( rResId );
@@ -1103,7 +1101,7 @@ void Menu::Deactivate()
if( !aDelData.isDeleted() )
{
bInCallback = FALSE;
-
+
if ( this == pStartMenu )
GetpApp()->HideHelpStatusText();
}
@@ -1283,7 +1281,7 @@ void Menu::InsertItem( const ResId& rResId, USHORT nPos )
ResMgr* pMgr = rResId.GetResMgr();
if( ! pMgr )
return;
-
+
ULONG nObjMask;
GetRes( rResId.SetRT( RSC_MENUITEM ) );
@@ -1623,7 +1621,7 @@ void Menu::SetPopupMenu( USHORT nItemId, PopupMenu* pMenu )
// data exchange
pData->pSubMenu = pMenu;
-
+
// #112023# Make sure pStartedFrom does not point to invalid (old) data
if ( pData->pSubMenu )
pData->pSubMenu->pStartedFrom = 0;
@@ -1908,7 +1906,7 @@ static inline Image ImplRotImage( const Image& rImage, long nAngle10 )
{
Image aRet;
BitmapEx aBmpEx( rImage.GetBitmapEx() );
-
+
aBmpEx.Rotate( nAngle10, COL_WHITE );
return Image( aBmpEx );
@@ -1935,7 +1933,7 @@ static inline Image ImplMirrorImage( const Image& rImage )
{
Image aRet;
BitmapEx aBmpEx( rImage.GetBitmapEx() );
-
+
aBmpEx.Mirror( BMP_MIRROR_HORZ );
return Image( aBmpEx );
@@ -2024,7 +2022,7 @@ const XubString& Menu::GetHelpCommand( USHORT nItemId ) const
else
return ImplGetSVEmptyStr();
}
-
+
void Menu::SetHelpText( USHORT nItemId, const XubString& rStr )
{
MenuItemData* pData = pItemList->GetData( nItemId );
@@ -2039,7 +2037,7 @@ const XubString& Menu::ImplGetHelpText( USHORT nItemId ) const
if ( pData )
{
- if ( !pData->aHelpText.Len() &&
+ if ( !pData->aHelpText.Len() &&
(( pData->nHelpId ) || ( pData->aCommandStr.Len() )))
{
Help* pHelp = Application::GetHelp();
@@ -2155,7 +2153,7 @@ BOOL Menu::ImplIsVisible( USHORT nPos ) const
// check for separator
if( pNextData && pNextData->bVisible && pNextData->eType == MENUITEM_SEPARATOR )
bVisible = FALSE;
-
+
if( bVisible )
{
for( n = nPos; n > 0; n-- )
@@ -2175,7 +2173,7 @@ BOOL Menu::ImplIsVisible( USHORT nPos ) const
// Fuer den Menubar nicht erlaubt, weil ich nicht mitbekomme
// ob dadurch ein Eintrag verschwindet oder wieder da ist.
- if ( bVisible && !bIsMenuBar && ( nMenuFlags & MENU_FLAG_HIDEDISABLEDENTRIES ) &&
+ if ( bVisible && !bIsMenuBar && ( nMenuFlags & MENU_FLAG_HIDEDISABLEDENTRIES ) &&
!( nMenuFlags & MENU_FLAG_ALWAYSSHOWDISABLEDENTRIES ) )
{
if( !pData ) // e.g. nPos == ITEMPOS_INVALID
@@ -2213,7 +2211,7 @@ BOOL Menu::ImplIsSelectable( USHORT nPos ) const
// check general visibility first
if ( pData && ( pData->nBits & MIB_NOSELECT ) )
bSelectable = FALSE;
-
+
return bSelectable;
}
@@ -2258,14 +2256,14 @@ void Menu::SelectItem( USHORT nItemId )
}
void Menu::SetAccessible( const ::com::sun::star::uno::Reference< ::com::sun::star::accessibility::XAccessible >& rxAccessible )
-{
+{
mxAccessible = rxAccessible;
}
long Menu::ImplGetNativeCheckAndRadioSize( Window* pWin, long& rCheckHeight, long& rRadioHeight, long &rMaxWidth ) const
{
rMaxWidth = rCheckHeight = rRadioHeight = 0;
-
+
if( ! bIsMenuBar )
{
ImplControlValue aVal;
@@ -2519,7 +2517,7 @@ Size Menu::ImplCalcSize( Window* pWin )
{
nTextPos = (USHORT)(2*nExtra);
aSz.Height() = nFontHeight+6;
-
+
// get menubar height from native methods if supported
if( pWindow->IsNativeControlSupported( CTRL_MENUBAR, PART_ENTIRE_CONTROL ) )
{
@@ -2565,10 +2563,10 @@ static void ImplPaintCheckBackground( Window* i_pWindow, const Rectangle& i_rRec
ImplControlValue aControlValue;
Rectangle aCtrlRegion( i_rRect );
ControlState nState = CTRL_STATE_PRESSED | CTRL_STATE_ENABLED;
-
+
aControlValue.setTristateVal( BUTTONVALUE_ON );
-
- bNativeOk = i_pWindow->DrawNativeControl( CTRL_TOOLBAR, PART_BUTTON,
+
+ bNativeOk = i_pWindow->DrawNativeControl( CTRL_TOOLBAR, PART_BUTTON,
aCtrlRegion, nState, aControlValue,
rtl::OUString() );
}
@@ -2597,7 +2595,7 @@ void Menu::ImplPaint( Window* pWin, USHORT nBorder, long nStartY, MenuItemData*
if ( pLogo )
aTopLeft.X() = pLogo->aBitmap.GetSizePixel().Width();
-
+
int nOuterSpace = 0;
if( !bIsMenuBar )
{
@@ -2679,23 +2677,23 @@ void Menu::ImplPaint( Window* pWin, USHORT nBorder, long nStartY, MenuItemData*
ControlPart nPart = ((pData->nBits & MIB_RADIOCHECK)
? PART_MENU_ITEM_RADIO_MARK
: PART_MENU_ITEM_CHECK_MARK);
-
+
ControlState nState = 0;
-
+
if ( pData->bChecked )
nState |= CTRL_STATE_PRESSED;
-
+
if ( pData->bEnabled )
nState |= CTRL_STATE_ENABLED;
-
+
if ( bHighlighted )
nState |= CTRL_STATE_SELECTED;
-
+
long nCtrlHeight = (pData->nBits & MIB_RADIOCHECK) ? nCheckHeight : nRadioHeight;
aTmpPos.X() = aOuterCheckRect.Left() + (aOuterCheckRect.GetWidth() - nCtrlHeight)/2;
aTmpPos.Y() = aOuterCheckRect.Top() + (aOuterCheckRect.GetHeight() - nCtrlHeight)/2;
-
- Rectangle aCheckRect( aTmpPos, Size( nCtrlHeight, nCtrlHeight ) );
+
+ Rectangle aCheckRect( aTmpPos, Size( nCtrlHeight, nCtrlHeight ) );
pWin->DrawNativeControl( CTRL_MENU_POPUP, nPart,
aCheckRect,
nState,
@@ -2705,7 +2703,7 @@ void Menu::ImplPaint( Window* pWin, USHORT nBorder, long nStartY, MenuItemData*
else if ( pData->bChecked ) // by default do nothing for unchecked items
{
ImplPaintCheckBackground( pWin, aOuterCheckRect, pThisItemOnly && bHighlighted );
-
+
SymbolType eSymbol;
Size aSymbolSize;
if ( pData->nBits & MIB_RADIOCHECK )
@@ -3206,7 +3204,7 @@ BOOL Menu::GetSystemMenuData( SystemMenuData* pData ) const
bool Menu::IsHighlighted( USHORT nItemPos ) const
{
bool bRet = false;
-
+
if( pWindow )
{
if( bIsMenuBar )
@@ -3214,7 +3212,7 @@ bool Menu::IsHighlighted( USHORT nItemPos ) const
else
bRet = ( nItemPos == static_cast< MenuFloatingWindow * > (pWindow)->GetHighlightedItem() );
}
-
+
return bRet;
}
@@ -3323,7 +3321,7 @@ Window* MenuBar::ImplCreate( Window* pParent, Window* pWindow, MenuBar* pMenu )
// depending on the native implementation or the displayable flag
// the menubar windows is supressed (ie, height=0)
- if( !((MenuBar*) pMenu)->IsDisplayable() ||
+ if( !((MenuBar*) pMenu)->IsDisplayable() ||
( pMenu->ImplGetSalMenu() && pMenu->ImplGetSalMenu()->VisibleMenuBar() ) )
nHeight = 0;
@@ -3347,7 +3345,7 @@ BOOL MenuBar::ImplHandleKeyEvent( const KeyEvent& rKEvent, BOOL bFromMenu )
BOOL bDone = FALSE;
// No keyboard processing when system handles the menu or our menubar is invisible
- if( !IsDisplayable() ||
+ if( !IsDisplayable() ||
( ImplGetSalMenu() && ImplGetSalMenu()->VisibleMenuBar() ) )
return bDone;
@@ -3392,11 +3390,11 @@ BOOL MenuBar::HandleMenuActivateEvent( Menu *pMenu ) const
ImplMenuDelData aDelData( this );
pMenu->pStartedFrom = (Menu*)this;
- pMenu->bInCallback = TRUE;
+ pMenu->bInCallback = TRUE;
pMenu->Activate();
-
+
if( !aDelData.isDeleted() )
- pMenu->bInCallback = FALSE;
+ pMenu->bInCallback = FALSE;
}
return TRUE;
}
@@ -3408,10 +3406,10 @@ BOOL MenuBar::HandleMenuDeActivateEvent( Menu *pMenu ) const
ImplMenuDelData aDelData( this );
pMenu->pStartedFrom = (Menu*)this;
- pMenu->bInCallback = TRUE;
+ pMenu->bInCallback = TRUE;
pMenu->Deactivate();
if( !aDelData.isDeleted() )
- pMenu->bInCallback = FALSE;
+ pMenu->bInCallback = FALSE;
}
return TRUE;
}
@@ -3484,7 +3482,7 @@ void MenuBar::RemoveMenuBarButton( USHORT nId )
BOOL MenuBar::HandleMenuButtonEvent( Menu *, USHORT i_nButtonId ) const
{
- return static_cast<MenuBarWindow*>(pWindow)->HandleMenuButtonEvent( i_nButtonId );
+ return static_cast<MenuBarWindow*>(pWindow)->HandleMenuButtonEvent( i_nButtonId );
}
// -----------------------------------------------------------------------
@@ -3771,7 +3769,7 @@ USHORT PopupMenu::ImplExecute( Window* pW, const Rectangle& rRect, ULONG nPopupM
if ( bRealExecute )
{
pWin->ImplAddDel( &aDelData );
-
+
ImplDelData aModalWinDel;
pW->ImplAddDel( &aModalWinDel );
pW->ImplIncModalCount();
@@ -3943,7 +3941,7 @@ MenuFloatingWindow::MenuFloatingWindow( Menu* pMen, Window* pParent, WinBits nSt
aSubmenuCloseTimer.SetTimeout( GetSettings().GetMouseSettings().GetMenuDelay() );
aSubmenuCloseTimer.SetTimeoutHdl( LINK( this, MenuFloatingWindow, SubmenuClose ) );
aScrollTimer.SetTimeoutHdl( LINK( this, MenuFloatingWindow, AutoScroll ) );
-
+
AddEventListener( LINK( this, MenuFloatingWindow, ShowHideListener ) );
}
@@ -3955,7 +3953,7 @@ void MenuFloatingWindow::doShutdown()
// otherwise the entry will not be read when the menu is opened again
if( nHighlightedItem != ITEMPOS_INVALID )
pMenu->ImplCallEventListeners( VCLEVENT_MENU_DEHIGHLIGHT, nHighlightedItem );
-
+
if( !bKeyInput && pMenu && pMenu->pStartedFrom && !pMenu->pStartedFrom->bIsMenuBar )
{
// #102461# remove highlight in parent
@@ -3974,12 +3972,12 @@ void MenuFloatingWindow::doShutdown()
pPWin->HighlightItem( i, FALSE );
}
}
-
+
// free the reference to the accessible component
SetAccessible( ::com::sun::star::uno::Reference< ::com::sun::star::accessibility::XAccessible >() );
-
+
aHighlightChangedTimer.Stop();
-
+
// #95056# invalidate screen area covered by system window
// so this can be taken into account if the commandhandler performs a scroll operation
if( GetParent() )
@@ -4047,7 +4045,7 @@ void MenuFloatingWindow::ImplHighlightItem( const MouseEvent& rMEvt, BOOL bMBDow
{
if( ! pMenu )
return;
-
+
long nY = nScrollerHeight;
long nMouseY = rMEvt.GetPosPixel().Y();
Size aOutSz = GetOutputSizePixel();
@@ -4180,7 +4178,7 @@ IMPL_LINK( MenuFloatingWindow, HighlightChanged, Timer*, pTimer )
{
if( ! pMenu )
return 0;
-
+
MenuItemData* pItemData = pMenu->pItemList->GetDataFromPos( nHighlightedItem );
if ( pItemData )
{
@@ -4256,7 +4254,7 @@ IMPL_LINK( MenuFloatingWindow, ShowHideListener, VclWindowEvent*, pEvent )
{
if( ! pMenu )
return 0;
-
+
if( pEvent->GetId() == VCLEVENT_WINDOW_SHOW )
pMenu->ImplCallEventListeners( VCLEVENT_MENU_SHOW, ITEMPOS_INVALID );
else if( pEvent->GetId() == VCLEVENT_WINDOW_HIDE )
@@ -4359,7 +4357,7 @@ void MenuFloatingWindow::EndExecute()
ImplGetSVData()->maWinData.mbNoDeactivate = FALSE;
}
}
-
+
// Wenn von woanders gestartet, dann ab dort aufraumen:
MenuFloatingWindow* pCleanUpFrom = this;
MenuFloatingWindow* pWin = this;
@@ -4483,7 +4481,7 @@ void MenuFloatingWindow::ImplScroll( BOOL bUp )
{
KillActivePopup();
Update();
-
+
if( ! pMenu )
return;
@@ -4648,7 +4646,7 @@ void MenuFloatingWindow::HighlightItem( USHORT nPos, BOOL bHighlight )
{
if( ! pMenu )
return;
-
+
Size aSz = GetOutputSizePixel();
long nStartY = ImplGetStartY();
long nY = nScrollerHeight+nStartY;
@@ -4659,7 +4657,7 @@ void MenuFloatingWindow::HighlightItem( USHORT nPos, BOOL bHighlight )
int nOuterSpace = ImplGetSVData()->maNWFData.mnMenuFormatExtraBorder;
nY += nOuterSpace;
-
+
USHORT nCount = (USHORT)pMenu->pItemList->Count();
for ( USHORT n = 0; n < nCount; n++ )
{
@@ -4679,7 +4677,7 @@ void MenuFloatingWindow::HighlightItem( USHORT nPos, BOOL bHighlight )
long nFontHeight = GetTextHeight();
aItemRect.Right() -= nFontHeight + nFontHeight/4;
}
-
+
if( IsNativeControlSupported( CTRL_MENU_POPUP, PART_ENTIRE_CONTROL ) )
{
Size aPxSize( GetOutputSizePixel() );
@@ -4724,7 +4722,7 @@ void MenuFloatingWindow::HighlightItem( USHORT nPos, BOOL bHighlight )
}
else
SetFillColor( GetSettings().GetStyleSettings().GetMenuColor() );
-
+
DrawRect( aItemRect );
}
pMenu->ImplPaint( this, nScrollerHeight, nStartY, pData, bHighlight );
@@ -4742,7 +4740,7 @@ Rectangle MenuFloatingWindow::ImplGetItemRect( USHORT nPos )
{
if( ! pMenu )
return Rectangle();
-
+
Rectangle aRect;
Size aSz = GetOutputSizePixel();
long nStartY = ImplGetStartY();
@@ -4780,7 +4778,7 @@ void MenuFloatingWindow::ImplCursorUpDown( BOOL bUp, BOOL bHomeEnd )
{
if( ! pMenu )
return;
-
+
const StyleSettings& rSettings = GetSettings().GetStyleSettings();
USHORT n = nHighlightedItem;
@@ -5026,7 +5024,7 @@ void MenuFloatingWindow::Paint( const Rectangle& )
{
if( ! pMenu )
return;
-
+
if( IsNativeControlSupported( CTRL_MENU_POPUP, PART_ENTIRE_CONTROL ) )
{
SetClipRegion();
@@ -5055,7 +5053,7 @@ void MenuFloatingWindow::ImplDrawScroller( BOOL bUp )
{
if( ! pMenu )
return;
-
+
SetClipRegion();
Size aOutSz = GetOutputSizePixel();
@@ -5165,31 +5163,27 @@ MenuBarWindow::MenuBarWindow( Window* pParent ) :
if( pResMgr )
{
BitmapEx aBitmap( ResId( SV_RESID_BITMAP_CLOSEDOC, *pResMgr ) );
- BitmapEx aBitmapHC( ResId( SV_RESID_BITMAP_CLOSEDOCHC, *pResMgr ) );
-
aCloser.maImage = Image( aBitmap );
- aCloser.maImageHC = Image( aBitmapHC );
-
+
aCloser.SetOutStyle( TOOLBOX_STYLE_FLAT );
aCloser.SetBackground();
aCloser.SetPaintTransparent( TRUE );
aCloser.SetParentClipMode( PARENTCLIPMODE_NOCLIP );
-
- aCloser.InsertItem( IID_DOCUMENTCLOSE,
- GetSettings().GetStyleSettings().GetHighContrastMode() ? aCloser.maImageHC : aCloser.maImage, 0 );
+
+ aCloser.InsertItem( IID_DOCUMENTCLOSE, aCloser.maImage, 0 );
aCloser.SetSelectHdl( LINK( this, MenuBarWindow, CloserHdl ) );
aCloser.AddEventListener( LINK( this, MenuBarWindow, ToolboxEventHdl ) );
aCloser.SetQuickHelpText( IID_DOCUMENTCLOSE, XubString( ResId( SV_HELPTEXT_CLOSEDOCUMENT, *pResMgr ) ) );
-
+
aFloatBtn.SetClickHdl( LINK( this, MenuBarWindow, FloatHdl ) );
aFloatBtn.SetSymbol( SYMBOL_FLOAT );
aFloatBtn.SetQuickHelpText( XubString( ResId( SV_HELPTEXT_RESTORE, *pResMgr ) ) );
-
+
aHideBtn.SetClickHdl( LINK( this, MenuBarWindow, HideHdl ) );
aHideBtn.SetSymbol( SYMBOL_HIDE );
aHideBtn.SetQuickHelpText( XubString( ResId( SV_HELPTEXT_MINIMIZE, *pResMgr ) ) );
}
-
+
ImplInitStyleSettings();
AddEventListener( LINK( this, MenuBarWindow, ShowHideListener ) );
@@ -5244,7 +5238,7 @@ IMPL_LINK( MenuBarWindow, CloserHdl, PushButton*, EMPTYARG )
{
if( ! pMenu )
return 0;
-
+
if( aCloser.GetCurItemId() == IID_DOCUMENTCLOSE )
{
// #i106052# call close hdl asynchronously to ease handler implementation
@@ -5271,7 +5265,7 @@ IMPL_LINK( MenuBarWindow, ToolboxEventHdl, VclWindowEvent*, pEvent )
{
if( ! pMenu )
return 0;
-
+
MenuBar::MenuBarButtonCallbackArg aArg;
aArg.nId = 0xffff;
aArg.bHighlight = (pEvent->GetId() == VCLEVENT_TOOLBOX_HIGHLIGHT);
@@ -5295,7 +5289,7 @@ IMPL_LINK( MenuBarWindow, ShowHideListener, VclWindowEvent*, pEvent )
{
if( ! pMenu )
return 0;
-
+
if( pEvent->GetId() == VCLEVENT_WINDOW_SHOW )
pMenu->ImplCallEventListeners( VCLEVENT_MENU_SHOW, ITEMPOS_INVALID );
else if( pEvent->GetId() == VCLEVENT_WINDOW_HIDE )
@@ -5433,7 +5427,7 @@ void MenuBarWindow::MouseMove( const MouseEvent& rMEvt )
}
USHORT nEntry = ImplFindEntry( rMEvt.GetPosPixel() );
- if ( ( nEntry != ITEMPOS_INVALID )
+ if ( ( nEntry != ITEMPOS_INVALID )
#ifdef OS2
&& ( ImplHilite(rMEvt) )
#endif
@@ -5445,7 +5439,7 @@ void MenuBarWindow::ChangeHighlightItem( USHORT n, BOOL bSelectEntry, BOOL bAllo
{
if( ! pMenu )
return;
-
+
// #57934# ggf. das aktive Popup sofort schliessen, damit TH's Hintergrundsicherung funktioniert.
MenuItemData* pNextData = pMenu->pItemList->GetDataFromPos( n );
if ( pActivePopup && pActivePopup->ImplGetWindow() && ( !pNextData || ( pActivePopup != pNextData->pSubMenu ) ) )
@@ -5528,7 +5522,7 @@ void MenuBarWindow::HighlightItem( USHORT nPos, BOOL bHighlight )
{
if( ! pMenu )
return;
-
+
long nX = 0;
ULONG nCount = pMenu->pItemList->Count();
for ( ULONG n = 0; n < nCount; n++ )
@@ -5559,7 +5553,7 @@ void MenuBarWindow::HighlightItem( USHORT nPos, BOOL bHighlight )
aControlValue,
OUString() );
ImplAddNWFSeparator( this, aControlValue );
-
+
// draw selected item
DrawNativeControl( CTRL_MENUBAR, PART_MENU_ITEM,
aRect,
@@ -5619,7 +5613,7 @@ Rectangle MenuBarWindow::ImplGetItemRect( USHORT nPos )
aRect = Rectangle( Point( nX, 1 ), Size( pData->aSz.Width(), GetOutputSizePixel().Height()-2 ) );
break;
}
-
+
nX += pData->aSz.Width();
}
}
@@ -5636,7 +5630,7 @@ BOOL MenuBarWindow::ImplHandleKeyEvent( const KeyEvent& rKEvent, BOOL bFromMenu
{
if( ! pMenu )
return FALSE;
-
+
if ( pMenu->bInCallback )
return TRUE; // schlucken
@@ -5682,7 +5676,7 @@ BOOL MenuBarWindow::ImplHandleKeyEvent( const KeyEvent& rKEvent, BOOL bFromMenu
else
n = pMenu->GetItemCount()-1;
}
-
+
// handling gtk like (aka mbOpenMenuOnF10)
// do not highlight an item when opening a sub menu
// unless there already was a higlighted sub menu item
@@ -5806,7 +5800,7 @@ void MenuBarWindow::Paint( const Rectangle& )
{
if( ! pMenu )
return;
-
+
// no VCL paint if native menus
if( pMenu->ImplGetSalMenu() && pMenu->ImplGetSalMenu()->VisibleMenuBar() )
{
@@ -5936,7 +5930,7 @@ void MenuBarWindow::ImplLayoutChanged()
// depending on the native implementation or the displayable flag
// the menubar windows is supressed (ie, height=0)
- if( !((MenuBar*) pMenu)->IsDisplayable() ||
+ if( !((MenuBar*) pMenu)->IsDisplayable() ||
( pMenu->ImplGetSalMenu() && pMenu->ImplGetSalMenu()->VisibleMenuBar() ) )
nHeight = 0;
@@ -6012,7 +6006,7 @@ USHORT MenuBarWindow::AddMenuBarButton( const Image& i_rImage, const Link& i_rLi
std::map< USHORT, AddButtonEntry >::const_iterator it;
if( i_nPos > m_aAddButtons.size() )
i_nPos = static_cast<USHORT>(m_aAddButtons.size());
- do
+ do
{
nId++;
it = m_aAddButtons.find( nId );
@@ -6027,10 +6021,10 @@ USHORT MenuBarWindow::AddMenuBarButton( const Image& i_rImage, const Link& i_rLi
aFloatBtn.IsVisible(),
aHideBtn.IsVisible() );
ImplLayoutChanged();
-
+
if( pMenu->mpSalMenu )
pMenu->mpSalMenu->AddMenuBarButton( SalMenuButtonItem( nId, i_rImage, i_rToolTip ) );
-
+
return nId;
}
@@ -6055,7 +6049,7 @@ Rectangle MenuBarWindow::GetMenuBarButtonRectPixel( USHORT nId )
return Rectangle();
}
}
-
+
if( aRect.IsEmpty() )
{
aRect = aCloser.GetItemRect( nId );
More information about the Libreoffice-commits
mailing list