include/vcl/customweld.hxx | 1 - sfx2/source/control/templatedlglocalview.cxx | 2 +- sfx2/source/control/templatelocalview.cxx | 2 +- sfx2/source/control/thumbnailview.cxx | 18 +++++++++--------- svtools/source/control/valueset.cxx | 22 +++++++++++----------- svx/source/dialog/weldeditview.cxx | 2 -- 6 files changed, 22 insertions(+), 25 deletions(-)
New commits: commit 4ec79158f80abff3078b7a7143760493d4eb47ad Author: Michael Weghorn <[email protected]> AuthorDate: Wed Nov 26 23:25:01 2025 +0100 Commit: Michael Weghorn <[email protected]> CommitDate: Thu Nov 27 10:35:37 2025 +0100 svx a11y: Don't report ACTIVE state in WeldEditAccessible offapi/com/sun/star/accessibility/AccessibleStateType.idl describes that state as /** Indicates a window is currently the active window. */ const hyper ACTIVE = 1; , which does not apply here, and neither does the documentation of the AT-SPI2 equivalent ATSPI_STATE_ACTIVE [1] nor IAccessible2's IA2_STATE_ACTIVE [2] make sense for the WeldEditAccessible. (That is what the LO state gets mapped to in the a11y bridges.) Therefore, drop the logic for conditionally reporting that state. [1] https://docs.gtk.org/atspi2/enum.StateType.html#active [2] https://accessibility.linuxfoundation.org/a11yspecs/ia2/docs/html/_accessible_states_8idl.html#aafecbfb195aaf7050dc8f75a7833bd5fabf466265c1f5b45dd53c86deb28220bc Change-Id: Ifef9f921dd59e10a9a76474699d32b8a14212ba7 Reviewed-on: https://gerrit.libreoffice.org/c/core/+/194667 Tested-by: Jenkins Reviewed-by: Michael Weghorn <[email protected]> Code-Style: Michael Weghorn <[email protected]> diff --git a/svx/source/dialog/weldeditview.cxx b/svx/source/dialog/weldeditview.cxx index a45cd7b49095..085aa7b52aeb 100644 --- a/svx/source/dialog/weldeditview.cxx +++ b/svx/source/dialog/weldeditview.cxx @@ -761,8 +761,6 @@ public: nStateSet |= css::accessibility::AccessibleStateType::SELECTABLE; if (m_pController->HasFocus()) nStateSet |= css::accessibility::AccessibleStateType::FOCUSED; - if (m_pController->IsActive()) - nStateSet |= css::accessibility::AccessibleStateType::ACTIVE; if (m_pController->IsVisible()) nStateSet |= css::accessibility::AccessibleStateType::SHOWING; if (m_pController->IsReallyVisible()) commit acf15cf9269df816d36177096171e47a01c454fc Author: Michael Weghorn <[email protected]> AuthorDate: Wed Nov 26 23:19:53 2025 +0100 Commit: Michael Weghorn <[email protected]> CommitDate: Thu Nov 27 10:35:25 2025 +0100 Drop CustomWidgetController::IsUpdateMode This static method always simply returns true, so checking that doesn't add any value. Drop it. Change-Id: Ic6277b6e49413808fd71a0a519df8744c17079e6 Reviewed-on: https://gerrit.libreoffice.org/c/core/+/194666 Code-Style: Michael Weghorn <[email protected]> Reviewed-by: Michael Weghorn <[email protected]> Tested-by: Jenkins diff --git a/include/vcl/customweld.hxx b/include/vcl/customweld.hxx index df8b788eada2..2987d72511ba 100644 --- a/include/vcl/customweld.hxx +++ b/include/vcl/customweld.hxx @@ -52,7 +52,6 @@ public: return; m_pDrawingArea->queue_draw(); } - static bool IsUpdateMode() { return true; } void Invalidate(const tools::Rectangle& rRect) { if (!m_pDrawingArea) diff --git a/sfx2/source/control/templatedlglocalview.cxx b/sfx2/source/control/templatedlglocalview.cxx index 420cfed15654..771493e38cfe 100644 --- a/sfx2/source/control/templatedlglocalview.cxx +++ b/sfx2/source/control/templatedlglocalview.cxx @@ -388,7 +388,7 @@ bool TemplateDlgLocalView::KeyInput(const KeyEvent& rKEvt) } } - if (IsReallyVisible() && IsUpdateMode()) + if (IsReallyVisible()) Invalidate(); return true; } diff --git a/sfx2/source/control/templatelocalview.cxx b/sfx2/source/control/templatelocalview.cxx index de5fbbf607b0..6801b65e4362 100644 --- a/sfx2/source/control/templatelocalview.cxx +++ b/sfx2/source/control/templatelocalview.cxx @@ -752,7 +752,7 @@ bool TemplateLocalView::KeyInput( const KeyEvent& rKEvt ) } } - if (IsReallyVisible() && IsUpdateMode()) + if (IsReallyVisible()) Invalidate(); return true; } diff --git a/sfx2/source/control/thumbnailview.cxx b/sfx2/source/control/thumbnailview.cxx index d39b80a57623..b42cfeaf3267 100644 --- a/sfx2/source/control/thumbnailview.cxx +++ b/sfx2/source/control/thumbnailview.cxx @@ -221,7 +221,7 @@ bool ThumbnailView::MouseMove(const MouseEvent& rMEvt) { ThumbnailViewItem *pItem = mFilteredItemList[i]; ::tools::Rectangle aToInvalidate(pItem->updateHighlight(pItem->mbVisible && !rMEvt.IsLeaveWindow(), aPoint)); - if (!aToInvalidate.IsEmpty() && IsReallyVisible() && IsUpdateMode()) + if (!aToInvalidate.IsEmpty() && IsReallyVisible()) Invalidate(aToInvalidate); } @@ -618,7 +618,7 @@ bool ThumbnailView::ImplHasAccessibleListeners() const IMPL_LINK_NOARG(ThumbnailView, ImplScrollHdl, weld::ScrolledWindow&, void) { CalculateItemPositions(true); - if (IsReallyVisible() && IsUpdateMode()) + if (IsReallyVisible()) Invalidate(); } @@ -1027,7 +1027,7 @@ void ThumbnailView::Resize() CustomWidgetController::Resize(); CalculateItemPositions(); - if ( IsReallyVisible() && IsUpdateMode() ) + if (IsReallyVisible()) Invalidate(); } @@ -1070,7 +1070,7 @@ void ThumbnailView::RemoveItem( sal_uInt16 nItemId ) CalculateItemPositions(); - if ( IsReallyVisible() && IsUpdateMode() ) + if (IsReallyVisible()) Invalidate(); } @@ -1083,7 +1083,7 @@ void ThumbnailView::Clear() CalculateItemPositions(); - if ( IsReallyVisible() && IsUpdateMode() ) + if (IsReallyVisible()) Invalidate(); } @@ -1150,10 +1150,10 @@ void ThumbnailView::SelectItem( sal_uInt16 nItemId ) pItem->setSelection(true); maItemStateHdl.Call(pItem); - if (IsReallyVisible() && IsUpdateMode()) + if (IsReallyVisible()) Invalidate(); - bool bNewOut = IsReallyVisible() && IsUpdateMode(); + bool bNewOut = IsReallyVisible(); // if necessary scroll to the visible area if (mbScroll && nItemId && mnCols) @@ -1171,7 +1171,7 @@ void ThumbnailView::SelectItem( sal_uInt16 nItemId ) if ( bNewOut ) { - if ( IsReallyVisible() && IsUpdateMode() ) + if (IsReallyVisible()) Invalidate(); } @@ -1215,7 +1215,7 @@ void ThumbnailView::deselectItems() } } - if (IsReallyVisible() && IsUpdateMode()) + if (IsReallyVisible()) Invalidate(); } diff --git a/svtools/source/control/valueset.cxx b/svtools/source/control/valueset.cxx index 9a58e1f1cc9b..46da587e0232 100644 --- a/svtools/source/control/valueset.cxx +++ b/svtools/source/control/valueset.cxx @@ -285,7 +285,7 @@ void ValueSet::LoseFocus() void ValueSet::Resize() { mbFormat = true; - if ( IsReallyVisible() && IsUpdateMode() ) + if (IsReallyVisible()) Invalidate(); CustomWidgetController::Resize(); } @@ -526,7 +526,7 @@ void ValueSet::QueueReformat() queue_resize(); RecalcScrollBar(); mbFormat = true; - if ( IsReallyVisible() && IsUpdateMode() ) + if (IsReallyVisible()) Invalidate(); } @@ -600,7 +600,7 @@ void ValueSet::Clear() RecalcScrollBar(); mbFormat = true; - if ( IsReallyVisible() && IsUpdateMode() ) + if (IsReallyVisible()) Invalidate(); } @@ -739,7 +739,7 @@ void ValueSet::SelectItem( sal_uInt16 nItemId ) mnSelItemId = nItemId; mbNoSelection = false; - bool bNewOut = !mbFormat && IsReallyVisible() && IsUpdateMode(); + bool bNewOut = !mbFormat && IsReallyVisible(); bool bNewLine = false; if (weld::DrawingArea* pNeedsFormatToScroll = !mnCols ? GetDrawingArea() : nullptr) @@ -836,7 +836,7 @@ void ValueSet::SetNoSelection() mbNoSelection = true; mbHighlight = false; - if (IsReallyVisible() && IsUpdateMode()) + if (IsReallyVisible()) Invalidate(); } @@ -1561,7 +1561,7 @@ void ValueSet::SetItemImage( sal_uInt16 nItemId, const Image& rImage ) pItem->meType = VALUESETITEM_IMAGE; pItem->maImage = rImage; - if ( !mbFormat && IsReallyVisible() && IsUpdateMode() ) + if (!mbFormat && IsReallyVisible()) { const tools::Rectangle aRect = ImplGetItemRect(nPos); Invalidate(aRect); @@ -1581,7 +1581,7 @@ void ValueSet::SetItemColor( sal_uInt16 nItemId, const Color& rColor ) pItem->meType = VALUESETITEM_COLOR; pItem->maColor = rColor; - if ( !mbFormat && IsReallyVisible() && IsUpdateMode() ) + if (!mbFormat && IsReallyVisible()) { const tools::Rectangle aRect = ImplGetItemRect(nPos); Invalidate( aRect ); @@ -1746,7 +1746,7 @@ void ValueSet::SetEdgeBlending(bool bNew) mbEdgeBlending = bNew; mbFormat = true; - if (GetDrawingArea() && IsReallyVisible() && IsUpdateMode()) + if (GetDrawingArea() && IsReallyVisible()) { Invalidate(); } @@ -1869,7 +1869,7 @@ void ValueSet::SetItemData( sal_uInt16 nItemId, void* pData ) if ( pItem->meType == VALUESETITEM_USERDRAW ) { - if ( !mbFormat && IsReallyVisible() && IsUpdateMode() ) + if (!mbFormat && IsReallyVisible()) { const tools::Rectangle aRect = ImplGetItemRect(nPos); Invalidate(aRect); @@ -1908,7 +1908,7 @@ void ValueSet::SetItemText(sal_uInt16 nItemId, const OUString& rText) pItem->maText = rText; - if (!mbFormat && IsReallyVisible() && IsUpdateMode()) + if (!mbFormat && IsReallyVisible()) { sal_uInt16 nTempId = mnSelItemId; @@ -1981,7 +1981,7 @@ void ValueSet::SetColor(const Color& rColor) { maColor = rColor; mbFormat = true; - if (IsReallyVisible() && IsUpdateMode()) + if (IsReallyVisible()) Invalidate(); }
