summaryrefslogtreecommitdiff
path: root/forms
diff options
context:
space:
mode:
authorThomas Arnhold <thomas@arnhold.org>2011-03-12 11:29:14 +0100
committerThomas Arnhold <thomas@arnhold.org>2011-03-12 14:12:11 +0100
commit5ad692096323fcdf03823352b70bb7e71660919c (patch)
treefd3b578bd023400fc9daeed37cad2dbe4a5c9004 /forms
parent678cbfa572eacbbdbd989b0d7c39ac6d33583e2a (diff)
Move OSL_ENSURE(false,...) to OSL_FAIL(...)
Diffstat (limited to 'forms')
-rw-r--r--forms/source/component/ComboBox.cxx2
-rw-r--r--forms/source/component/FormComponent.cxx6
-rw-r--r--forms/source/component/Grid.cxx2
-rw-r--r--forms/source/component/ImageControl.cxx6
-rw-r--r--forms/source/component/ListBox.cxx12
-rw-r--r--forms/source/component/refvaluecomponent.cxx2
-rw-r--r--forms/source/solar/control/navtoolbar.cxx2
-rw-r--r--forms/source/xforms/datatypes.cxx2
-rw-r--r--forms/source/xforms/model.cxx2
-rw-r--r--forms/source/xforms/model_ui.cxx8
10 files changed, 22 insertions, 22 deletions
diff --git a/forms/source/component/ComboBox.cxx b/forms/source/component/ComboBox.cxx
index 4ddf4532f51b..f2c8cbfa2ccf 100644
--- a/forms/source/component/ComboBox.cxx
+++ b/forms/source/component/ComboBox.cxx
@@ -668,7 +668,7 @@ void OComboBoxModel::loadData( bool _bForce )
}
break;
default:
- OSL_ENSURE( false, "OComboBoxModel::loadData: unreachable!" );
+ OSL_FAIL( "OComboBoxModel::loadData: unreachable!" );
break;
}
}
diff --git a/forms/source/component/FormComponent.cxx b/forms/source/component/FormComponent.cxx
index 53881a3e2ac2..6cf05e78359e 100644
--- a/forms/source/component/FormComponent.cxx
+++ b/forms/source/component/FormComponent.cxx
@@ -992,7 +992,7 @@ Any OControlModel::getPropertyDefaultByHandle( sal_Int32 _nHandle ) const
if ( m_aPropertyBagHelper.hasDynamicPropertyByHandle( _nHandle ) )
m_aPropertyBagHelper.getDynamicPropertyDefaultByHandle( _nHandle, aReturn );
else
- OSL_ENSURE( false, "OControlModel::convertFastPropertyValue: unknown handle!" );
+ OSL_FAIL( "OControlModel::convertFastPropertyValue: unknown handle!" );
}
return aReturn;
}
@@ -1050,7 +1050,7 @@ sal_Bool OControlModel::convertFastPropertyValue(
if ( m_aPropertyBagHelper.hasDynamicPropertyByHandle( _nHandle ) )
bModified = m_aPropertyBagHelper.convertDynamicFastPropertyValue( _nHandle, _rValue, _rConvertedValue, _rOldValue );
else
- OSL_ENSURE( false, "OControlModel::convertFastPropertyValue: unknown handle!" );
+ OSL_FAIL( "OControlModel::convertFastPropertyValue: unknown handle!" );
break;
}
return bModified;
@@ -1084,7 +1084,7 @@ void OControlModel::setFastPropertyValue_NoBroadcast(sal_Int32 _nHandle, const A
if ( m_aPropertyBagHelper.hasDynamicPropertyByHandle( _nHandle ) )
m_aPropertyBagHelper.setDynamicFastPropertyValue( _nHandle, _rValue );
else
- OSL_ENSURE( false, "OControlModel::setFastPropertyValue_NoBroadcast: unknown handle!" );
+ OSL_FAIL( "OControlModel::setFastPropertyValue_NoBroadcast: unknown handle!" );
break;
}
}
diff --git a/forms/source/component/Grid.cxx b/forms/source/component/Grid.cxx
index 7fdb83591834..274e77fbd407 100644
--- a/forms/source/component/Grid.cxx
+++ b/forms/source/component/Grid.cxx
@@ -256,7 +256,7 @@ Reference< XRowSet > SAL_CALL OGridControlModel::getRowSet( ) throw (RuntimeExc
//------------------------------------------------------------------------------
void SAL_CALL OGridControlModel::setRowSet( const Reference< XRowSet >& /*_rxDataSource*/ ) throw (RuntimeException)
{
- OSL_ENSURE( false, "OGridControlModel::setRowSet: not supported!" );
+ OSL_FAIL( "OGridControlModel::setRowSet: not supported!" );
}
//--------------------------------------------------------------------
diff --git a/forms/source/component/ImageControl.cxx b/forms/source/component/ImageControl.cxx
index e11ace8dd091..23cb10bd064e 100644
--- a/forms/source/component/ImageControl.cxx
+++ b/forms/source/component/ImageControl.cxx
@@ -488,7 +488,7 @@ sal_Bool OImageControlModel::impl_handleNewImageURL_lck( ValueChangeInstigator _
break;
case ImageStoreInvalid:
- OSL_ENSURE( false, "OImageControlModel::impl_handleNewImageURL_lck: image storage type type!" );
+ OSL_FAIL( "OImageControlModel::impl_handleNewImageURL_lck: image storage type type!" );
break;
}
@@ -588,7 +588,7 @@ Any OImageControlModel::translateDbColumnToControlValue()
return makeAny( sImageLink );
}
case ImageStoreInvalid:
- OSL_ENSURE( false, "OImageControlModel::translateDbColumnToControlValue: invalid field type!" );
+ OSL_FAIL( "OImageControlModel::translateDbColumnToControlValue: invalid field type!" );
break;
}
return Any();
@@ -630,7 +630,7 @@ void OImageControlModel::doSetControlValue( const Any& _rValue )
break;
case ImageStoreInvalid:
- OSL_ENSURE( false, "OImageControlModel::doSetControlValue: invalid field type!" );
+ OSL_FAIL( "OImageControlModel::doSetControlValue: invalid field type!" );
break;
} // switch ( lcl_getImageStoreType( getFieldType() ) )
diff --git a/forms/source/component/ListBox.cxx b/forms/source/component/ListBox.cxx
index 213f58558a6f..ac56e7fd8395 100644
--- a/forms/source/component/ListBox.cxx
+++ b/forms/source/component/ListBox.cxx
@@ -339,7 +339,7 @@ namespace frm
break;
case PROPERTY_ID_VALUE_SEQ :
- OSL_ENSURE( false, "ValueItemList is read-only!" );
+ OSL_FAIL( "ValueItemList is read-only!" );
throw PropertyVetoException();
case PROPERTY_ID_DEFAULT_SELECT_SEQ :
@@ -390,7 +390,7 @@ namespace frm
break;
case PROPERTY_ID_VALUE_SEQ :
- OSL_ENSURE( false, "ValueItemList is read-only!" );
+ OSL_FAIL( "ValueItemList is read-only!" );
throw PropertyVetoException();
case PROPERTY_ID_DEFAULT_SELECT_SEQ :
@@ -894,7 +894,7 @@ namespace frm
}
break;
default:
- OSL_ENSURE( false, "OListBoxModel::loadData: unreachable!" );
+ OSL_FAIL( "OListBoxModel::loadData: unreachable!" );
break;
}
}
@@ -996,7 +996,7 @@ namespace frm
size_t selectedValue = aSelectedIndices[0];
if ( selectedValue >= aValues.size() )
{
- OSL_ENSURE( false, "OListBoxModel::getFirstSelectedValue: inconsistent selection/valuelist!" );
+ OSL_FAIL( "OListBoxModel::getFirstSelectedValue: inconsistent selection/valuelist!" );
return s_aEmptyVaue;
}
@@ -1035,7 +1035,7 @@ namespace frm
Reference< XPropertySet > xBoundField( getField() );
if ( !xBoundField.is() )
{
- OSL_ENSURE( false, "OListBoxModel::translateDbColumnToControlValue: no field? How could that happen?!" );
+ OSL_FAIL( "OListBoxModel::translateDbColumnToControlValue: no field? How could that happen?!" );
return Any();
}
@@ -1143,7 +1143,7 @@ namespace frm
default:
break;
}
- OSL_ENSURE( false, "lcl_getCurrentExchangeType: unsupported (unexpected) exchange type!" );
+ OSL_FAIL( "lcl_getCurrentExchangeType: unsupported (unexpected) exchange type!" );
return eEntry;
}
}
diff --git a/forms/source/component/refvaluecomponent.cxx b/forms/source/component/refvaluecomponent.cxx
index ab32ff5bcce3..9fdf49d5117d 100644
--- a/forms/source/component/refvaluecomponent.cxx
+++ b/forms/source/component/refvaluecomponent.cxx
@@ -218,7 +218,7 @@ namespace frm
}
else
{
- OSL_ENSURE( false, "OReferenceValueComponent::translateExternalValueToControlValue: unexpected value type!" );
+ OSL_FAIL( "OReferenceValueComponent::translateExternalValueToControlValue: unexpected value type!" );
}
return makeAny( nState );
diff --git a/forms/source/solar/control/navtoolbar.cxx b/forms/source/solar/control/navtoolbar.cxx
index b1c6f0d3a588..b408b7052578 100644
--- a/forms/source/solar/control/navtoolbar.cxx
+++ b/forms/source/solar/control/navtoolbar.cxx
@@ -102,7 +102,7 @@ namespace frm
if ( pAsciiCommandName != NULL )
return ::rtl::OUString( RTL_CONSTASCII_USTRINGPARAM( ".uno:" ) ) + ::rtl::OUString::createFromAscii( pAsciiCommandName );
- OSL_ENSURE( false, "lcl_getCommandURL: unknown FormFeature!" );
+ OSL_FAIL( "lcl_getCommandURL: unknown FormFeature!" );
return ::rtl::OUString();
}
}
diff --git a/forms/source/xforms/datatypes.cxx b/forms/source/xforms/datatypes.cxx
index 329e65b76cc8..c8c76c8d848f 100644
--- a/forms/source/xforms/datatypes.cxx
+++ b/forms/source/xforms/datatypes.cxx
@@ -503,7 +503,7 @@ namespace xforms
break;
default:
- OSL_ENSURE( false, "OValueLimitedType::_explainInvalid: unknown reason!" );
+ OSL_FAIL( "OValueLimitedType::_explainInvalid: unknown reason!" );
break;
}
diff --git a/forms/source/xforms/model.cxx b/forms/source/xforms/model.cxx
index 26074f2a1c6f..e463a4b9e3ad 100644
--- a/forms/source/xforms/model.cxx
+++ b/forms/source/xforms/model.cxx
@@ -385,7 +385,7 @@ bool Model::setSimpleContent( const XNode_t& xConstNode,
default:
{
- OSL_ENSURE( false, "bound to unknown node type?" );
+ OSL_FAIL( "bound to unknown node type?" );
}
break;
diff --git a/forms/source/xforms/model_ui.cxx b/forms/source/xforms/model_ui.cxx
index f78bccfea00b..1ed98a49a709 100644
--- a/forms/source/xforms/model_ui.cxx
+++ b/forms/source/xforms/model_ui.cxx
@@ -257,7 +257,7 @@ OUString Model::getDefaultBindingExpressionForNode(
default:
// unknown type? fail!
- OSL_ENSURE( false, "unknown node type!" );
+ OSL_FAIL( "unknown node type!" );
xCurrent.set( NULL );
aBuffer.makeStringAndClear();
// we'll remove the slash below
@@ -332,7 +332,7 @@ OUString Model::getNodeDisplayName( const XNode_t& xNode,
default:
// unknown type? fail!
- OSL_ENSURE( false, "unknown node type!" );
+ OSL_FAIL( "unknown node type!" );
break;
}
@@ -355,7 +355,7 @@ OUString Model::getNodeName( const XNode_t& xNode )
case NodeType_DOCUMENT_NODE:
default:
// unknown type? fail!
- OSL_ENSURE( false, "no name for this node type!" );
+ OSL_FAIL( "no name for this node type!" );
break;
}
@@ -684,7 +684,7 @@ Model::XNode_t Model::renameNode( const XNode_t& xNode,
}
else
{
- OSL_ENSURE( false, "can't rename this node type" );
+ OSL_FAIL( "can't rename this node type" );
}
// adjust bindings (if necessary):