summaryrefslogtreecommitdiff
path: root/toolkit/source
diff options
context:
space:
mode:
Diffstat (limited to 'toolkit/source')
-rw-r--r--toolkit/source/awt/vclxaccessiblecomponent.cxx8
-rw-r--r--toolkit/source/awt/vclxwindow.cxx4
-rw-r--r--toolkit/source/helper/property.cxx1
-rw-r--r--toolkit/source/layout/core/box-base.cxx5
-rw-r--r--toolkit/source/layout/core/box-base.hxx2
5 files changed, 17 insertions, 3 deletions
diff --git a/toolkit/source/awt/vclxaccessiblecomponent.cxx b/toolkit/source/awt/vclxaccessiblecomponent.cxx
index 7a3b9ff5b2ec..175289d1ac84 100644
--- a/toolkit/source/awt/vclxaccessiblecomponent.cxx
+++ b/toolkit/source/awt/vclxaccessiblecomponent.cxx
@@ -490,10 +490,18 @@ void VCLXAccessibleComponent::FillAccessibleStateSet( utl::AccessibleStateSetHel
getAccessibleRole() == accessibility::AccessibleRole::DIALOG ) ) // #i18891#
rStateSet.AddState( accessibility::AccessibleStateType::ACTIVE );
+ // #104290# MT: This way, a ComboBox doesn't get state FOCUSED.
+ // I also don't understand
+ // a) why WINDOW_FIRSTCHILD is used here (which btw is a border window in the case of a combo box)
+ // b) why HasFocus() is nout "enough" for a compound control
+ /*
Window* pChild = pWindow->GetWindow( WINDOW_FIRSTCHILD );
if ( ( !pWindow->IsCompoundControl() && pWindow->HasFocus() ) ||
( pWindow->IsCompoundControl() && pChild && pChild->HasFocus() ) )
rStateSet.AddState( accessibility::AccessibleStateType::FOCUSED );
+ */
+ if ( pWindow->HasFocus() || ( pWindow->IsCompoundControl() && pWindow->HasChildPathFocus() ) )
+ rStateSet.AddState( accessibility::AccessibleStateType::FOCUSED );
if ( pWindow->IsWait() )
rStateSet.AddState( accessibility::AccessibleStateType::BUSY );
diff --git a/toolkit/source/awt/vclxwindow.cxx b/toolkit/source/awt/vclxwindow.cxx
index 045a46729961..248571819067 100644
--- a/toolkit/source/awt/vclxwindow.cxx
+++ b/toolkit/source/awt/vclxwindow.cxx
@@ -2163,6 +2163,10 @@ void VCLXWindow::setProperty( const ::rtl::OUString& PropertyName, const ::com::
aProp <<= (sal_Bool) mpImpl->isEnableVisible();
break;
+ case BASEPROPERTY_HIGHCONTRASTMODE:
+ aProp <<= (sal_Bool) GetWindow()->GetSettings().GetStyleSettings().GetHighContrastMode();
+ break;
+
case BASEPROPERTY_TEXT:
case BASEPROPERTY_LABEL:
case BASEPROPERTY_TITLE:
diff --git a/toolkit/source/helper/property.cxx b/toolkit/source/helper/property.cxx
index dd22ea331830..7ede81d485d7 100644
--- a/toolkit/source/helper/property.cxx
+++ b/toolkit/source/helper/property.cxx
@@ -185,6 +185,7 @@ ImplPropertyInfo* ImplGetPropertyInfos( sal_uInt16& rElementCount )
DECL_PROP_2 ( "HelpText", HELPTEXT, ::rtl::OUString, BOUND, MAYBEDEFAULT ),
DECL_PROP_2 ( "HelpURL", HELPURL, ::rtl::OUString, BOUND, MAYBEDEFAULT ),
DECL_PROP_2 ( "HideInactiveSelection", HIDEINACTIVESELECTION, bool, BOUND, MAYBEDEFAULT ),
+ DECL_PROP_2 ( "HighContrastMode", HIGHCONTRASTMODE, bool, BOUND, MAYBEDEFAULT ),
DECL_PROP_2 ( "HScroll", HSCROLL, bool, BOUND, MAYBEDEFAULT ),
DECL_PROP_2 ( "HardLineBreaks", HARDLINEBREAKS, bool, BOUND, MAYBEDEFAULT ),
DECL_PROP_2 ( "ImageAlign", IMAGEALIGN, sal_Int16, BOUND, MAYBEDEFAULT),
diff --git a/toolkit/source/layout/core/box-base.cxx b/toolkit/source/layout/core/box-base.cxx
index dbe9163e2117..d203e63ce2ed 100644
--- a/toolkit/source/layout/core/box-base.cxx
+++ b/toolkit/source/layout/core/box-base.cxx
@@ -104,15 +104,16 @@ Box_Base::addChild (uno::Reference <awt::XLayoutConstrains> const& xChild)
}
Box_Base::ChildData*
-Box_Base::removeChildData( std::list< ChildData* > lst, css::uno::Reference< css::awt::XLayoutConstrains > const& xChild )
+Box_Base::removeChildData( std::list< ChildData* >& lst, css::uno::Reference< css::awt::XLayoutConstrains > const& xChild )
{
for ( std::list< ChildData* >::iterator it = lst.begin();
it != lst.end(); it++ )
{
if ( (*it)->mxChild == xChild )
{
+ ChildData* pRet = *it;
lst.erase( it );
- return *it;
+ return pRet;
}
}
return 0;
diff --git a/toolkit/source/layout/core/box-base.hxx b/toolkit/source/layout/core/box-base.hxx
index 4f50f55bf5c4..685e0e35e8b6 100644
--- a/toolkit/source/layout/core/box-base.hxx
+++ b/toolkit/source/layout/core/box-base.hxx
@@ -62,7 +62,7 @@ protected:
virtual ChildData *createChild( css::uno::Reference< css::awt::XLayoutConstrains > const& xChild ) = 0;
virtual ChildProps *createChildProps( ChildData* pData ) = 0;
- ChildData *removeChildData( std::list< ChildData *>, css::uno::Reference< css::awt::XLayoutConstrains > const& Child );
+ ChildData *removeChildData( std::list< ChildData *>&, css::uno::Reference< css::awt::XLayoutConstrains > const& Child );
public:
void AddChild( const css::uno::Reference< css::awt::XLayoutConstrains >& Child);