diff options
author | Noel Grandin <noel.grandin@collabora.co.uk> | 2018-02-26 17:13:01 +0200 |
---|---|---|
committer | Noel Grandin <noel.grandin@collabora.co.uk> | 2018-02-28 07:34:27 +0100 |
commit | e2cb154195fdc2ffccdb6f5e87cae8b29640b3eb (patch) | |
tree | 7c3d53d78e0867aa879b98d84211d1e73602520f /editeng/source | |
parent | 0ea41fea75cd1ac1d81fa57c4411e75a6b4001f0 (diff) |
convert COL_ constants to be of type Color
Change-Id: I0e25c8950ac26b851ff42f71e1471fcbe4770d48
Reviewed-on: https://gerrit.libreoffice.org/50373
Reviewed-by: Noel Grandin <noel.grandin@collabora.co.uk>
Tested-by: Noel Grandin <noel.grandin@collabora.co.uk>
Diffstat (limited to 'editeng/source')
-rw-r--r-- | editeng/source/accessibility/AccessibleComponentBase.cxx | 4 | ||||
-rw-r--r-- | editeng/source/accessibility/AccessibleEditableTextPara.cxx | 4 | ||||
-rw-r--r-- | editeng/source/editeng/editeng.cxx | 2 | ||||
-rw-r--r-- | editeng/source/items/itemtype.cxx | 2 | ||||
-rw-r--r-- | editeng/source/items/textitem.cxx | 2 |
5 files changed, 7 insertions, 7 deletions
diff --git a/editeng/source/accessibility/AccessibleComponentBase.cxx b/editeng/source/accessibility/AccessibleComponentBase.cxx index ae43a2c55b42..69052ea4dd65 100644 --- a/editeng/source/accessibility/AccessibleComponentBase.cxx +++ b/editeng/source/accessibility/AccessibleComponentBase.cxx @@ -108,13 +108,13 @@ void SAL_CALL AccessibleComponentBase::grabFocus() sal_Int32 SAL_CALL AccessibleComponentBase::getForeground() { - return Color(COL_BLACK).GetColor(); + return sal_Int32(COL_BLACK); } sal_Int32 SAL_CALL AccessibleComponentBase::getBackground() { - return Color(COL_WHITE).GetColor(); + return sal_Int32(COL_WHITE); } diff --git a/editeng/source/accessibility/AccessibleEditableTextPara.cxx b/editeng/source/accessibility/AccessibleEditableTextPara.cxx index ecaf8445eea0..90859aac7a73 100644 --- a/editeng/source/accessibility/AccessibleEditableTextPara.cxx +++ b/editeng/source/accessibility/AccessibleEditableTextPara.cxx @@ -1485,7 +1485,7 @@ namespace accessibility else { Color cr(xComponent->getBackground()); - crChar = cr.IsDark() ? COL_WHITE : COL_BLACK; + crChar = sal_uInt32(cr.IsDark() ? COL_WHITE : COL_BLACK); anyChar <<= crChar; } } @@ -1516,7 +1516,7 @@ namespace accessibility else { Color cr(xComponent->getBackground()); - crCharUnderLine = cr.IsDark() ? COL_WHITE : COL_BLACK; + crCharUnderLine = sal_uInt32(cr.IsDark() ? COL_WHITE : COL_BLACK); anyCharUnderLine <<= crCharUnderLine; } } diff --git a/editeng/source/editeng/editeng.cxx b/editeng/source/editeng/editeng.cxx index 0e5fdd3e596a..bacf77c21767 100644 --- a/editeng/source/editeng/editeng.cxx +++ b/editeng/source/editeng/editeng.cxx @@ -1027,7 +1027,7 @@ bool EditEngine::PostKeyEvent( const KeyEvent& rKeyEvent, EditView* pEditView, v P2.AdjustX(n20 ); P2.AdjustY(nH ); pEditView->GetWindow()->SetLineColor(); - pEditView->GetWindow()->SetFillColor( Color( (n%2) ? COL_YELLOW : COL_LIGHTGREEN ) ); + pEditView->GetWindow()->SetFillColor( (n%2) ? COL_YELLOW : COL_LIGHTGREEN ); pEditView->GetWindow()->DrawRect( tools::Rectangle( P1, P2 ) ); aPos.AdjustY(nH ); } diff --git a/editeng/source/items/itemtype.cxx b/editeng/source/items/itemtype.cxx index 3167a5996870..1fd3d600933b 100644 --- a/editeng/source/items/itemtype.cxx +++ b/editeng/source/items/itemtype.cxx @@ -141,7 +141,7 @@ OUString GetSvxString(const char* pId) OUString GetColorString( const Color& rCol ) { - if (rCol.GetColor() == COL_AUTO) + if (rCol == COL_AUTO) return EditResId(RID_SVXSTR_AUTOMATIC); static const Color aColAry[] = { diff --git a/editeng/source/items/textitem.cxx b/editeng/source/items/textitem.cxx index a5d8b7925558..ed64f8392891 100644 --- a/editeng/source/items/textitem.cxx +++ b/editeng/source/items/textitem.cxx @@ -1726,7 +1726,7 @@ SvStream& SvxColorItem::Store( SvStream& rStrm , sal_uInt16 nItemVersion ) const { if( VERSION_USEAUTOCOLOR == nItemVersion && COL_AUTO == mColor.GetColor() ) - WriteColor( rStrm, Color(COL_BLACK) ); + WriteColor( rStrm, COL_BLACK ); else WriteColor( rStrm, mColor ); return rStrm; |