summaryrefslogtreecommitdiff
path: root/winaccessibility/source
diff options
context:
space:
mode:
authorMichael Weghorn <m.weghorn@posteo.de>2022-08-05 11:02:40 +0100
committerMichael Weghorn <m.weghorn@posteo.de>2022-08-05 16:36:17 +0200
commit0c3a159807965fa7db548a943a8d67d8bad5b208 (patch)
treeb54e25a92b79a0b344cde5dd57d5a91d6ee93a61 /winaccessibility/source
parenta9c8ac0605fd1d19e1d79b54804b610a64a8a056 (diff)
wina11y: Drop AccObjectManagerAgent::UpdateLocation
That static method doesn't do anything. `_IMPL_WIN` is not defined, so the #ifdef _IMPL_WIN if( pWinManager ) pWinManager->SetLocation( pXAcc, top, left, width, height ); #endif in the method is unused. Since `CMAccessible::accLocation` already retrieves the current location from the underlying `XAccessible` on demand, I don't see a need to update the location manually in the first place, so there should be no need to enable that, code, just drop it. Also drop `AccObjectWinManager::SetLocation` which was unused since `AccObjectManagerAgent::UpdateLocation` (s. above) would have been the only call site. Change-Id: I04d0230d3599466aaa92082caba54da22a3b1a28 Reviewed-on: https://gerrit.libreoffice.org/c/core/+/137857 Tested-by: Jenkins Reviewed-by: Michael Weghorn <m.weghorn@posteo.de>
Diffstat (limited to 'winaccessibility/source')
-rw-r--r--winaccessibility/source/service/AccEventListener.cxx1
-rw-r--r--winaccessibility/source/service/AccObjectManagerAgent.cxx18
-rw-r--r--winaccessibility/source/service/AccObjectWinManager.cxx15
-rw-r--r--winaccessibility/source/service/AccParagraphEventListener.cxx1
4 files changed, 0 insertions, 35 deletions
diff --git a/winaccessibility/source/service/AccEventListener.cxx b/winaccessibility/source/service/AccEventListener.cxx
index 9121974c221e..b6b4e71f3aaa 100644
--- a/winaccessibility/source/service/AccEventListener.cxx
+++ b/winaccessibility/source/service/AccEventListener.cxx
@@ -106,7 +106,6 @@ void AccEventListener::HandleDescriptionChangedEvent()
*/
void AccEventListener::HandleBoundrectChangedEvent()
{
- AccObjectManagerAgent::UpdateLocation(m_xAccessible.get());
pAgent->NotifyAccEvent(UnoMSAAEvent::BOUNDRECT_CHANGED, m_xAccessible.get());
}
diff --git a/winaccessibility/source/service/AccObjectManagerAgent.cxx b/winaccessibility/source/service/AccObjectManagerAgent.cxx
index 5c9cd633d308..e60b3a56992c 100644
--- a/winaccessibility/source/service/AccObjectManagerAgent.cxx
+++ b/winaccessibility/source/service/AccObjectManagerAgent.cxx
@@ -104,24 +104,6 @@ void AccObjectManagerAgent::UpdateAccName( XAccessible* pXAcc, Any newName)
pWinManager->SetAccName( pXAcc, newName );
}
-
-/**
- * Interface of updating MSAA location when UNO location_changed event occurs.
- * @param pXAcc Uno XAccessible interface of control.
- * @param pXAcc Uno The top position of new location.
- * @param pXAcc Uno The left position of new location.
- * @param pXAcc Uno The width of new location.
- * @param pXAcc Uno The width of new location.
- * @return
- */
-void AccObjectManagerAgent::UpdateLocation( XAccessible* /* pXAcc */, long /*top*/, long /*left*/, long /*width*/, long /*height*/ )
-{
-#ifdef _IMPL_WIN
- if( pWinManager )
- pWinManager->SetLocation( pXAcc, top, left, width, height );
-#endif
-}
-
/**
* When a new UNO XAccessible object is found by listener, we create a corresponding
* com object and insert it to our manager list.
diff --git a/winaccessibility/source/service/AccObjectWinManager.cxx b/winaccessibility/source/service/AccObjectWinManager.cxx
index 3a8b1eb06d8a..8349d5c863cd 100644
--- a/winaccessibility/source/service/AccObjectWinManager.cxx
+++ b/winaccessibility/source/service/AccObjectWinManager.cxx
@@ -919,21 +919,6 @@ void AccObjectWinManager::UpdateAction( XAccessible* pXAcc )
}
/**
- * Set corresponding com object's accessible location via XAccessible interface and new
- * location.
- * @param pXAcc XAccessible interface.
- * @return
- */
-void AccObjectWinManager::SetLocation( XAccessible* pXAcc, long /*top*/, long /*left*/, long /*width*/, long /*height*/ )
-{
- AccObject* pObj = GetAccObjByXAcc( pXAcc );
- //get the location from XComponent.
- Reference< XAccessibleContext > pRContext = pXAcc->getAccessibleContext();
- if( pObj )
- pObj->UpdateLocation();
-}
-
-/**
* Set corresponding com object's value via XAccessible interface and new value.
* @param pXAcc XAccessible interface.
* @param pAny new value.
diff --git a/winaccessibility/source/service/AccParagraphEventListener.cxx b/winaccessibility/source/service/AccParagraphEventListener.cxx
index f4c24c3bb0ec..7d6b25a8f248 100644
--- a/winaccessibility/source/service/AccParagraphEventListener.cxx
+++ b/winaccessibility/source/service/AccParagraphEventListener.cxx
@@ -94,7 +94,6 @@ void AccParagraphEventListener::notifyEvent( const css::accessibility::Accessib
*/
void AccParagraphEventListener::HandleCaretChangedEvent(Any, Any)
{
- AccObjectManagerAgent::UpdateLocation(m_xAccessible.get());
pAgent->NotifyAccEvent(UnoMSAAEvent::OBJECT_CARETCHANGE, m_xAccessible.get());
}