Kaydet (Commit) 106a1b4e authored tarafından Ricardo Montania's avatar Ricardo Montania Kaydeden (comit) Noel Power

sal_Bool to bool conversion in accessibility

Change-Id: I79967eea535dc4bd11e725dc854ae8a8f97a2905
Reviewed-on: https://gerrit.libreoffice.org/701Reviewed-by: 's avatarNoel Power <noel.power@suse.com>
Tested-by: 's avatarNoel Power <noel.power@suse.com>
üst 63a75509
...@@ -51,21 +51,21 @@ namespace accessibility ...@@ -51,21 +51,21 @@ namespace accessibility
virtual Rectangle GetDropDownPosSizePixel( ) const = 0; virtual Rectangle GetDropDownPosSizePixel( ) const = 0;
virtual Rectangle GetBoundingRectangle( sal_uInt16 nItem ) const = 0; virtual Rectangle GetBoundingRectangle( sal_uInt16 nItem ) const = 0;
virtual Rectangle GetWindowExtentsRelative( Window* pRelativeWindow ) = 0; virtual Rectangle GetWindowExtentsRelative( Window* pRelativeWindow ) = 0;
virtual sal_Bool IsActive() const = 0; virtual bool IsActive() const = 0;
virtual sal_Bool IsEntryVisible( sal_uInt16 nPos ) const = 0; virtual bool IsEntryVisible( sal_uInt16 nPos ) const = 0;
virtual sal_uInt16 GetDisplayLineCount() const = 0; virtual sal_uInt16 GetDisplayLineCount() const = 0;
virtual void GetMaxVisColumnsAndLines( sal_uInt16& rnCols, sal_uInt16& rnLines ) const = 0; virtual void GetMaxVisColumnsAndLines( sal_uInt16& rnCols, sal_uInt16& rnLines ) const = 0;
virtual WinBits GetStyle() const = 0; virtual WinBits GetStyle() const = 0;
virtual sal_Bool IsMultiSelectionEnabled() const = 0; virtual bool IsMultiSelectionEnabled() const = 0;
virtual sal_uInt16 GetTopEntry() const = 0; virtual sal_uInt16 GetTopEntry() const = 0;
virtual sal_Bool IsEntryPosSelected( sal_uInt16 nPos ) const = 0; virtual bool IsEntryPosSelected( sal_uInt16 nPos ) const = 0;
virtual sal_uInt16 GetEntryCount() const = 0; virtual sal_uInt16 GetEntryCount() const = 0;
virtual void Select() = 0; virtual void Select() = 0;
virtual void SelectEntryPos( sal_uInt16 nPos, sal_Bool bSelect = sal_True ) = 0; virtual void SelectEntryPos( sal_uInt16 nPos, bool bSelect = sal_True ) = 0;
virtual sal_uInt16 GetSelectEntryCount() const = 0; virtual sal_uInt16 GetSelectEntryCount() const = 0;
virtual void SetNoSelection() = 0; virtual void SetNoSelection() = 0;
virtual sal_uInt16 GetSelectEntryPos( sal_uInt16 nSelIndex = 0 ) const = 0; virtual sal_uInt16 GetSelectEntryPos( sal_uInt16 nSelIndex = 0 ) const = 0;
virtual sal_Bool IsInDropDown() const = 0; virtual bool IsInDropDown() const = 0;
virtual Rectangle GetEntryCharacterBounds( const sal_Int32 _nEntryPos, const sal_Int32 _nCharacterIndex ) const = 0; virtual Rectangle GetEntryCharacterBounds( const sal_Int32 _nEntryPos, const sal_Int32 _nCharacterIndex ) const = 0;
virtual long GetIndexForPoint( const Point& rPoint, sal_uInt16& nPos ) const = 0; virtual long GetIndexForPoint( const Point& rPoint, sal_uInt16& nPos ) const = 0;
virtual ::com::sun::star::uno::Reference< ::com::sun::star::datatransfer::clipboard::XClipboard > virtual ::com::sun::star::uno::Reference< ::com::sun::star::datatransfer::clipboard::XClipboard >
......
...@@ -81,19 +81,19 @@ public: ...@@ -81,19 +81,19 @@ public:
return m_aComboListBox.GetWindowExtentsRelative( pRelativeWindow ); return m_aComboListBox.GetWindowExtentsRelative( pRelativeWindow );
} }
// ----------------------------------------------------------------------------- // -----------------------------------------------------------------------------
virtual sal_Bool IsActive() const virtual bool IsActive() const
{ {
return m_aComboListBox.IsActive(); return m_aComboListBox.IsActive();
} }
// ----------------------------------------------------------------------------- // -----------------------------------------------------------------------------
virtual sal_Bool IsEntryVisible( sal_uInt16 nPos ) const virtual bool IsEntryVisible( sal_uInt16 nPos ) const
{ {
sal_uInt16 nTopEntry = m_aComboListBox.GetTopEntry(); sal_uInt16 nTopEntry = m_aComboListBox.GetTopEntry();
sal_uInt16 nLines = m_aComboListBox.GetDisplayLineCount(); sal_uInt16 nLines = m_aComboListBox.GetDisplayLineCount();
return ( nPos >= nTopEntry && nPos < ( nTopEntry + nLines ) ); return ( nPos >= nTopEntry && nPos < ( nTopEntry + nLines ) );
} }
// ----------------------------------------------------------------------------- // -----------------------------------------------------------------------------
virtual sal_uInt16 GetDisplayLineCount() const virtual sal_uInt16 GetDisplayLineCount() const
{ {
return m_aComboListBox.GetDisplayLineCount(); return m_aComboListBox.GetDisplayLineCount();
} }
...@@ -108,37 +108,37 @@ public: ...@@ -108,37 +108,37 @@ public:
return m_aComboListBox.GetStyle(); return m_aComboListBox.GetStyle();
} }
// ----------------------------------------------------------------------------- // -----------------------------------------------------------------------------
virtual sal_Bool IsMultiSelectionEnabled() const virtual bool IsMultiSelectionEnabled() const
{ {
return m_aComboListBox.IsMultiSelectionEnabled(); return m_aComboListBox.IsMultiSelectionEnabled();
} }
// ----------------------------------------------------------------------------- // -----------------------------------------------------------------------------
virtual sal_uInt16 GetTopEntry() const virtual sal_uInt16 GetTopEntry() const
{ {
return m_aComboListBox.GetTopEntry(); return m_aComboListBox.GetTopEntry();
} }
// ----------------------------------------------------------------------------- // -----------------------------------------------------------------------------
virtual sal_Bool IsEntryPosSelected( sal_uInt16 nPos ) const virtual bool IsEntryPosSelected( sal_uInt16 nPos ) const
{ {
return m_aComboListBox.IsEntryPosSelected(nPos); return m_aComboListBox.IsEntryPosSelected(nPos);
} }
// ----------------------------------------------------------------------------- // -----------------------------------------------------------------------------
virtual sal_uInt16 GetEntryCount() const virtual sal_uInt16 GetEntryCount() const
{ {
return m_aComboListBox.GetEntryCount(); return m_aComboListBox.GetEntryCount();
} }
// ----------------------------------------------------------------------------- // -----------------------------------------------------------------------------
virtual void Select() virtual void Select()
{ {
m_aComboListBox.Select(); m_aComboListBox.Select();
} }
// ----------------------------------------------------------------------------- // -----------------------------------------------------------------------------
virtual void SelectEntryPos( sal_uInt16 nPos, sal_Bool bSelect = sal_True ) virtual void SelectEntryPos( sal_uInt16 nPos, bool bSelect = sal_True )
{ {
m_aComboListBox.SelectEntryPos(nPos,bSelect); m_aComboListBox.SelectEntryPos(nPos,bSelect);
} }
// ----------------------------------------------------------------------------- // -----------------------------------------------------------------------------
virtual sal_uInt16 GetSelectEntryCount() const virtual sal_uInt16 GetSelectEntryCount() const
{ {
return m_aComboListBox.GetSelectEntryCount(); return m_aComboListBox.GetSelectEntryCount();
} }
...@@ -148,12 +148,12 @@ public: ...@@ -148,12 +148,12 @@ public:
m_aComboListBox.SetNoSelection(); m_aComboListBox.SetNoSelection();
} }
// ----------------------------------------------------------------------------- // -----------------------------------------------------------------------------
virtual sal_uInt16 GetSelectEntryPos( sal_uInt16 nSelIndex = 0 ) const virtual sal_uInt16 GetSelectEntryPos( sal_uInt16 nSelIndex = 0 ) const
{ {
return m_aComboListBox.GetSelectEntryPos(nSelIndex); return m_aComboListBox.GetSelectEntryPos(nSelIndex);
} }
// ----------------------------------------------------------------------------- // -----------------------------------------------------------------------------
virtual sal_Bool IsInDropDown() const virtual bool IsInDropDown() const
{ {
return m_aComboListBox.IsInDropDown(); return m_aComboListBox.IsInDropDown();
} }
......
...@@ -319,7 +319,7 @@ Reference<XAccessible> VCLXAccessibleList::CreateChild (sal_Int32 i) ...@@ -319,7 +319,7 @@ Reference<XAccessible> VCLXAccessibleList::CreateChild (sal_Int32 i)
if ( xChild.is() ) if ( xChild.is() )
{ {
// Just add the SELECTED state. // Just add the SELECTED state.
sal_Bool bNowSelected = sal_False; bool bNowSelected = false;
if ( m_pListBoxHelper ) if ( m_pListBoxHelper )
bNowSelected = m_pListBoxHelper->IsEntryPosSelected ((sal_uInt16)i); bNowSelected = m_pListBoxHelper->IsEntryPosSelected ((sal_uInt16)i);
VCLXAccessibleListItem* pItem = static_cast< VCLXAccessibleListItem* >(xChild.get()); VCLXAccessibleListItem* pItem = static_cast< VCLXAccessibleListItem* >(xChild.get());
...@@ -330,7 +330,7 @@ Reference<XAccessible> VCLXAccessibleList::CreateChild (sal_Int32 i) ...@@ -330,7 +330,7 @@ Reference<XAccessible> VCLXAccessibleList::CreateChild (sal_Int32 i)
sal_uInt16 nTopEntry = 0; sal_uInt16 nTopEntry = 0;
if ( m_pListBoxHelper ) if ( m_pListBoxHelper )
nTopEntry = m_pListBoxHelper->GetTopEntry(); nTopEntry = m_pListBoxHelper->GetTopEntry();
sal_Bool bVisible = ( nPos>=nTopEntry && nPos<( nTopEntry + m_nVisibleLineCount ) ); bool bVisible = ( nPos>=nTopEntry && nPos<( nTopEntry + m_nVisibleLineCount ) );
pItem->SetVisible( m_bVisible && bVisible ); pItem->SetVisible( m_bVisible && bVisible );
} }
......
Markdown is supported
0% or
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment