Kaydet (Commit) f1904906 authored tarafından Stephan Bergmann's avatar Stephan Bergmann

Remove unused function params

Change-Id: I0db4352ab7a14b4a62bebb650d1956c4a177b67f
üst bd53697b
...@@ -221,22 +221,6 @@ namespace svt { namespace table ...@@ -221,22 +221,6 @@ namespace svt { namespace table
/** checks whether a given cell content fits into a given target area on a given device. /** checks whether a given cell content fits into a given target area on a given device.
@param i_colPos
denotes the column which the cell content would be painted into. Your renderer implementation
would only need this parameter if rendering is done differently for different columns.
@param i_rowPos
denotes the row which the cell content would be painted into. Your renderer implementation
would only need this parameter if rendering is done differently for different rows.
@param i_active
is <TRUE/> if and only if the renderer should assume the cell content would be painted for the active
cell.
@param i_selected
is <TRUE/> if and only if the renderer should assume the cell content would be painted for a selected
cell.
@param i_targetDevice @param i_targetDevice
denotes the target device for the assumed rendering operation denotes the target device for the assumed rendering operation
...@@ -249,8 +233,6 @@ namespace svt { namespace table ...@@ -249,8 +233,6 @@ namespace svt { namespace table
*/ */
virtual bool FitsIntoCell( virtual bool FitsIntoCell(
::com::sun::star::uno::Any const & i_cellContent, ::com::sun::star::uno::Any const & i_cellContent,
ColPos const i_colPos, RowPos const i_rowPos,
bool const i_active, bool const i_selected,
OutputDevice& i_targetDevice, Rectangle const & i_targetArea OutputDevice& i_targetDevice, Rectangle const & i_targetArea
) const = 0; ) const = 0;
...@@ -258,10 +240,6 @@ namespace svt { namespace table ...@@ -258,10 +240,6 @@ namespace svt { namespace table
@param i_cellValue @param i_cellValue
the value for which an attempt for a string conversion should be made the value for which an attempt for a string conversion should be made
@param i_colPos
the column position of the cell in question
@param i_rowPos
the row position of the cell in question
@param o_cellString @param o_cellString
the cell content, formatted as string the cell content, formatted as string
@return @return
...@@ -269,7 +247,6 @@ namespace svt { namespace table ...@@ -269,7 +247,6 @@ namespace svt { namespace table
*/ */
virtual bool GetFormattedCellString( virtual bool GetFormattedCellString(
::com::sun::star::uno::Any const & i_cellValue, ::com::sun::star::uno::Any const & i_cellValue,
ColPos const i_colPos, RowPos const i_rowPos,
OUString & o_cellString OUString & o_cellString
) const = 0; ) const = 0;
......
...@@ -87,13 +87,10 @@ namespace svt { namespace table ...@@ -87,13 +87,10 @@ namespace svt { namespace table
virtual void HideCellCursor( vcl::Window& _rView, const Rectangle& _rCursorRect) SAL_OVERRIDE; virtual void HideCellCursor( vcl::Window& _rView, const Rectangle& _rCursorRect) SAL_OVERRIDE;
virtual bool FitsIntoCell( virtual bool FitsIntoCell(
::com::sun::star::uno::Any const & i_cellContent, ::com::sun::star::uno::Any const & i_cellContent,
ColPos const i_colPos, RowPos const i_rowPos,
bool const i_active, bool const i_selected,
OutputDevice& i_targetDevice, Rectangle const & i_targetArea OutputDevice& i_targetDevice, Rectangle const & i_targetArea
) const SAL_OVERRIDE; ) const SAL_OVERRIDE;
virtual bool GetFormattedCellString( virtual bool GetFormattedCellString(
::com::sun::star::uno::Any const & i_cellValue, ::com::sun::star::uno::Any const & i_cellValue,
ColPos const i_colPos, RowPos const i_rowPos,
OUString & o_cellString OUString & o_cellString
) const SAL_OVERRIDE; ) const SAL_OVERRIDE;
......
...@@ -558,8 +558,8 @@ namespace svt { namespace table ...@@ -558,8 +558,8 @@ namespace svt { namespace table
} }
bool GridTableRenderer::FitsIntoCell( Any const & i_cellContent, ColPos const i_colPos, RowPos const i_rowPos, bool GridTableRenderer::FitsIntoCell( Any const & i_cellContent,
bool const i_active, bool const i_selected, OutputDevice& i_targetDevice, Rectangle const & i_targetArea ) const OutputDevice& i_targetDevice, Rectangle const & i_targetArea ) const
{ {
if ( !i_cellContent.hasValue() ) if ( !i_cellContent.hasValue() )
return true; return true;
...@@ -593,20 +593,14 @@ namespace svt { namespace table ...@@ -593,20 +593,14 @@ namespace svt { namespace table
if ( nTextWidth > aTargetArea.GetWidth() ) if ( nTextWidth > aTargetArea.GetWidth() )
return false; return false;
OSL_UNUSED( i_active );
OSL_UNUSED( i_selected );
OSL_UNUSED( i_rowPos );
OSL_UNUSED( i_colPos );
return true; return true;
} }
bool GridTableRenderer::GetFormattedCellString( Any const & i_cellValue, ColPos const i_colPos, RowPos const i_rowPos, OUString & o_cellString ) const bool GridTableRenderer::GetFormattedCellString( Any const & i_cellValue, OUString & o_cellString ) const
{ {
o_cellString = m_pImpl->aStringConverter.convertToString( i_cellValue ); o_cellString = m_pImpl->aStringConverter.convertToString( i_cellValue );
OSL_UNUSED( i_colPos );
OSL_UNUSED( i_rowPos );
return true; return true;
} }
......
...@@ -2041,7 +2041,7 @@ namespace svt { namespace table ...@@ -2041,7 +2041,7 @@ namespace svt { namespace table
m_pModel->getCellContent( i_col, i_row, aCellValue ); m_pModel->getCellContent( i_col, i_row, aCellValue );
OUString sCellStringContent; OUString sCellStringContent;
m_pModel->getRenderer()->GetFormattedCellString( aCellValue, i_col, i_row, sCellStringContent ); m_pModel->getRenderer()->GetFormattedCellString( aCellValue, sCellStringContent );
return sCellStringContent; return sCellStringContent;
} }
......
...@@ -97,19 +97,16 @@ namespace svt { namespace table ...@@ -97,19 +97,16 @@ namespace svt { namespace table
pTableModel->getCellContent( hitCol, hitRow, aCellToolTip ); pTableModel->getCellContent( hitCol, hitRow, aCellToolTip );
// use the cell content as tool tip only if it doesn't fit into the cell. // use the cell content as tool tip only if it doesn't fit into the cell.
bool const activeCell = ( hitRow == m_rTableControl.getCurrentRow() ) && ( hitCol == m_rTableControl.getCurrentColumn() );
bool const selectedCell = m_rTableControl.isRowSelected( hitRow );
Rectangle const aWindowRect( Point( 0, 0 ), GetOutputSizePixel() ); Rectangle const aWindowRect( Point( 0, 0 ), GetOutputSizePixel() );
TableCellGeometry const aCell( m_rTableControl, aWindowRect, hitCol, hitRow ); TableCellGeometry const aCell( m_rTableControl, aWindowRect, hitCol, hitRow );
Rectangle const aCellRect( aCell.getRect() ); Rectangle const aCellRect( aCell.getRect() );
PTableRenderer const pRenderer = pTableModel->getRenderer(); PTableRenderer const pRenderer = pTableModel->getRenderer();
if ( pRenderer->FitsIntoCell( aCellToolTip, hitCol, hitRow, activeCell, selectedCell, *this, aCellRect ) ) if ( pRenderer->FitsIntoCell( aCellToolTip, *this, aCellRect ) )
aCellToolTip.clear(); aCellToolTip.clear();
} }
pTableModel->getRenderer()->GetFormattedCellString( aCellToolTip, hitCol, hitRow, sHelpText ); pTableModel->getRenderer()->GetFormattedCellString( aCellToolTip, sHelpText );
if ( sHelpText.indexOf( '\n' ) >= 0 ) if ( sHelpText.indexOf( '\n' ) >= 0 )
nHelpStyle = QuickHelpFlags::TipStyleBalloon; nHelpStyle = QuickHelpFlags::TipStyleBalloon;
......
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