diff options
Diffstat (limited to 'forms/source/component')
23 files changed, 48 insertions, 83 deletions
diff --git a/forms/source/component/Button.cxx b/forms/source/component/Button.cxx index da060f997052..65838c5d9a3b 100644 --- a/forms/source/component/Button.cxx +++ b/forms/source/component/Button.cxx @@ -224,7 +224,7 @@ void OButtonModel::read(const Reference<XObjectInputStream>& _rxInStream) throw break; default: - DBG_ERROR("OButtonModel::read : unknown version !"); + OSL_FAIL("OButtonModel::read : unknown version !"); m_eButtonType = FormButtonType_PUSH; m_sTargetURL = ::rtl::OUString(); m_sTargetFrame = ::rtl::OUString(); @@ -480,7 +480,6 @@ IMPL_LINK( OButtonControl, OnClick, void*, EMPTYARG ) // catch exceptions // and catch them on a per-listener basis - if one listener fails, the others still need // to get notified - // 97676 - 21.02.2002 - fs@openoffice.org try { static_cast< XActionListener* >( aIter.next() )->actionPerformed(aEvt); @@ -493,7 +492,7 @@ IMPL_LINK( OButtonControl, OnClick, void*, EMPTYARG ) #endif catch( const Exception& ) { - DBG_ERROR( "OButtonControl::OnClick: caught a exception other than RuntimeException!" ); + OSL_FAIL( "OButtonControl::OnClick: caught a exception other than RuntimeException!" ); } } } diff --git a/forms/source/component/CheckBox.cxx b/forms/source/component/CheckBox.cxx index 11ccbe16690a..5fbf0a8d1086 100644 --- a/forms/source/component/CheckBox.cxx +++ b/forms/source/component/CheckBox.cxx @@ -200,7 +200,7 @@ void SAL_CALL OCheckBoxModel::read(const Reference<stario::XObjectInputStream>& readCommonProperties(_rxInStream); break; default: - DBG_ERROR("OCheckBoxModel::read : unknown version !"); + OSL_FAIL("OCheckBoxModel::read : unknown version !"); defaultCommonProperties(); break; } @@ -257,12 +257,12 @@ sal_Bool OCheckBoxModel::commitControlValueToDbColumn( bool /*_bPostReset*/ ) m_xColumnUpdate->updateBoolean( sal_False ); break; default: - DBG_ERROR("OCheckBoxModel::commitControlValueToDbColumn: invalid value !"); + OSL_FAIL("OCheckBoxModel::commitControlValueToDbColumn: invalid value !"); } } catch(Exception&) { - DBG_ERROR("OCheckBoxModel::commitControlValueToDbColumn: could not commit !"); + OSL_FAIL("OCheckBoxModel::commitControlValueToDbColumn: could not commit !"); } } return sal_True; diff --git a/forms/source/component/ComboBox.cxx b/forms/source/component/ComboBox.cxx index 899289025e7b..4ddf4532f51b 100644 --- a/forms/source/component/ComboBox.cxx +++ b/forms/source/component/ComboBox.cxx @@ -403,7 +403,7 @@ void SAL_CALL OComboBoxModel::read(const Reference<stario::XObjectInputStream>& if (nVersion > 0x0006) { - DBG_ERROR("OComboBoxModel::read : invalid (means unknown) version !"); + OSL_FAIL("OComboBoxModel::read : invalid (means unknown) version !"); m_aListSource = ::rtl::OUString(); m_aBoundColumn <<= (sal_Int16)0; m_aDefaultText = ::rtl::OUString(); @@ -498,7 +498,7 @@ void OComboBoxModel::loadData( bool _bForce ) Reference<XServiceInfo> xServiceInfo(xConnection, UNO_QUERY); if (!xServiceInfo.is() || !xServiceInfo->supportsService(SRV_SDB_CONNECTION)) { - DBG_ERROR("OComboBoxModel::loadData : invalid connection !"); + OSL_FAIL("OComboBoxModel::loadData : invalid connection !"); return; } diff --git a/forms/source/component/Currency.cxx b/forms/source/component/Currency.cxx index ed919f60b0d6..9ae25ed9b4b8 100644 --- a/forms/source/component/Currency.cxx +++ b/forms/source/component/Currency.cxx @@ -137,7 +137,7 @@ void OCurrencyModel::implConstruct() } catch(Exception&) { - DBG_ERROR( "OCurrencyModel::implConstruct: caught an exception while initializing the aggregate!" ); + OSL_FAIL( "OCurrencyModel::implConstruct: caught an exception while initializing the aggregate!" ); } } } diff --git a/forms/source/component/DatabaseForm.cxx b/forms/source/component/DatabaseForm.cxx index 87a2e572a615..e29a2ad14210 100644 --- a/forms/source/component/DatabaseForm.cxx +++ b/forms/source/component/DatabaseForm.cxx @@ -92,7 +92,7 @@ #include <osl/mutex.hxx> #include <ctype.h> -#include <hash_map> +#include <boost/unordered_map.hpp> // compatiblity: DatabaseCursorType is dead, but for compatiblity reasons we still have to write it ... namespace com { @@ -1157,7 +1157,7 @@ bool ODatabaseForm::hasValidParent() const Reference<XResultSet> xResultSet(m_xParent, UNO_QUERY); if (!xResultSet.is()) { - DBG_ERROR("ODatabaseForm::hasValidParent() : no parent resultset !"); + OSL_FAIL("ODatabaseForm::hasValidParent() : no parent resultset !"); return false; } try @@ -2106,8 +2106,7 @@ void ODatabaseForm::reset_impl(bool _bAproveByListeners) aResetGuard.reset(); // ensure that the row isn't modified // (do this _before_ the listeners are notified ! their reaction (maybe asynchronous) may depend - // on the modified state of the row - // 21.02.00 - 73265 - FS) + // on the modified state of the row) if (bInsertRow) m_xAggregateSet->setPropertyValue(PROPERTY_ISMODIFIED, ::cppu::bool2any(sal_Bool(sal_False))); @@ -2340,7 +2339,7 @@ void ODatabaseForm::submit_impl(const Reference<XControl>& Control, const ::com: lcl_dispatch(xFrame,xTransformer,aURLStr,aReferer,aTargetName,aData,osl_getThreadTextEncoding()); } else { - DBG_ERROR("ODatabaseForm::submit_Impl : wrong encoding !"); + OSL_FAIL("ODatabaseForm::submit_Impl : wrong encoding !"); } } @@ -3023,7 +3022,7 @@ void ODatabaseForm::reload_impl(sal_Bool bMoveToFirst, const Reference< XInterac } catch( const SQLException& e ) { - DBG_ERROR("ODatabaseForm::reload_impl : shouldn't executeRowSet catch this exception?"); + OSL_FAIL("ODatabaseForm::reload_impl : shouldn't executeRowSet catch this exception?"); (void)e; } @@ -3596,15 +3595,13 @@ void SAL_CALL ODatabaseForm::moveToInsertRow() throw( SQLException, RuntimeExcep // * in reset_impl // - set the control defaults into the columns if not void // - do _not_ set the columns to NULL if no control default is set - // This fixes both #88888# and #97955# // // Still, there is #72756#. During fixing this bug, DG introduced not calling the aggregate here. So // in theory, we re-introduced #72756#. But the bug described therein does not happen anymore, as the // preliminaries for it changed (no display of guessed values for new records with autoinc fields) // - // BTW: the public Issuezilla bug for #97955# is #i2815# + // BTW: the public Issuezilla bug is #i2815# // - // 16.04.2002 - 97955 - fs@openoffice.org xUpdate->moveToInsertRow(); // then set the default values and the parameters given from the parent @@ -3866,7 +3863,6 @@ Sequence< ::rtl::OUString > SAL_CALL ODatabaseForm::getSupportedServiceNames() t // the compatible names // This is maily to be consistent with the implementation before fixing #97083#, though the // better solution _may_ be to return the compatible names at runtime, too - // 04.03.2002 - fs@openoffice.org } //------------------------------------------------------------------------------ @@ -3939,7 +3935,7 @@ void SAL_CALL ODatabaseForm::write(const Reference<XObjectOutputStream>& _rxOutS eTranslated = bEscapeProcessing ? DataSelectionType_SQL : DataSelectionType_SQLPASSTHROUGH; } break; - default : DBG_ERROR("ODatabaseForm::write : wrong CommandType !"); + default : OSL_FAIL("ODatabaseForm::write : wrong CommandType !"); } } _rxOutStream->writeShort((sal_Int16)eTranslated); // former DataSelectionType @@ -4045,7 +4041,7 @@ void SAL_CALL ODatabaseForm::read(const Reference<XObjectInputStream>& _rxInStre m_xAggregateSet->setPropertyValue(PROPERTY_ESCAPE_PROCESSING, makeAny((sal_Bool)bEscapeProcessing)); } break; - default : DBG_ERROR("ODatabaseForm::read : wrong CommandType !"); + default : OSL_FAIL("ODatabaseForm::read : wrong CommandType !"); } if (m_xAggregateSet.is()) m_xAggregateSet->setPropertyValue(PROPERTY_COMMANDTYPE, makeAny(nCommandType)); diff --git a/forms/source/component/Edit.cxx b/forms/source/component/Edit.cxx index e5f5375f0e1a..c7cdda51722a 100644 --- a/forms/source/component/Edit.cxx +++ b/forms/source/component/Edit.cxx @@ -561,7 +561,6 @@ void OEditModel::write(const Reference<XObjectOutputStream>& _rxOutStream) throw { // -> fuer die Dauer des Speicherns meinem aggregierten Model die alte TextLen einreden // before doing this we have to save the current text value of the aggregate, as this may be affected by resetting the text len - // FS - 08.12.99 - 70606 aCurrentText = m_xAggregateSet->getPropertyValue(PROPERTY_TEXT); m_xAggregateSet->getPropertyValue(PROPERTY_MAXTEXTLEN) >>= nOldTextLen; diff --git a/forms/source/component/File.cxx b/forms/source/component/File.cxx index 4e4b62dc6131..170241c6eba2 100644 --- a/forms/source/component/File.cxx +++ b/forms/source/component/File.cxx @@ -248,7 +248,7 @@ void OFileControlModel::read(const Reference<stario::XObjectInputStream>& _rxInS readHelpTextCompatibly(_rxInStream); break; default: - DBG_ERROR("OFileControlModel::read : unknown version !"); + OSL_FAIL("OFileControlModel::read : unknown version !"); m_sDefaultValue = ::rtl::OUString(); } @@ -294,7 +294,6 @@ void OFileControlModel::_reset() { // release our mutex once (it's acquired in the calling method !), as setting aggregate properties // may cause any uno controls belonging to us to lock the solar mutex, which is potentially dangerous with // our own mutex locked - // FS - 72451 - 31.01.00 MutexRelease aRelease(m_aMutex); m_xAggregateSet->setPropertyValue(PROPERTY_TEXT, makeAny(m_sDefaultValue)); } diff --git a/forms/source/component/Filter.cxx b/forms/source/component/Filter.cxx index 07e964bf5c43..6aff61483a6d 100644 --- a/forms/source/component/Filter.cxx +++ b/forms/source/component/Filter.cxx @@ -256,7 +256,6 @@ namespace frm OControl::initFormControlPeer( getPeer() ); // filter controls are _never_ readonly - // #107013# - 2002-02-03 - fs@openoffice.org Reference< XPropertySet > xModel( getModel(), UNO_QUERY_THROW ); Reference< XPropertySetInfo > xModelPSI( xModel->getPropertySetInfo(), UNO_SET_THROW ); if ( xModelPSI->hasPropertyByName( PROPERTY_READONLY ) ) @@ -757,7 +756,7 @@ namespace frm } else { - DBG_ERROR( "OFilterControl::initialize: unrecognized argument!" ); + OSL_FAIL( "OFilterControl::initialize: unrecognized argument!" ); continue; } diff --git a/forms/source/component/FormComponent.cxx b/forms/source/component/FormComponent.cxx index 0d36f10dc958..53881a3e2ac2 100644 --- a/forms/source/component/FormComponent.cxx +++ b/forms/source/component/FormComponent.cxx @@ -599,7 +599,7 @@ OControlModel::OControlModel( ,m_bNativeLook( sal_False ) // form controls are usually embedded into documents, not dialogs, and in documents // the native look is ugly .... - // #i37342# / 2004-11-19 / frank.schoenheit@sun.com + // #i37342# { DBG_CTOR(OControlModel, NULL); if (_rUnoControlModelTypeName.getLength()) // the is a model we have to aggregate @@ -1680,7 +1680,6 @@ void SAL_CALL OBoundControlModel::write( const Reference<stario::XObjectOutputSt // in anything from data loss to crash. // (use writeCommonProperties instead, this is called in derived classes write-method) // !!! EOIN !!! - // FS - 68876 - 28.09.1999 } //------------------------------------------------------------------------------ @@ -1805,7 +1804,7 @@ sal_Bool OBoundControlModel::convertFastPropertyValue( bModified = tryPropertyValue(_rConvertedValue, _rOldValue, _rValue, m_aControlSource); break; case PROPERTY_ID_BOUNDFIELD: - DBG_ERROR( "OBoundControlModel::convertFastPropertyValue: BoundField should be a read-only property !" ); + OSL_FAIL( "OBoundControlModel::convertFastPropertyValue: BoundField should be a read-only property !" ); throw com::sun::star::lang::IllegalArgumentException(); case PROPERTY_ID_CONTROLLABEL: if (!_rValue.hasValue()) @@ -1861,7 +1860,7 @@ void OBoundControlModel::setFastPropertyValue_NoBroadcast( sal_Int32 nHandle, co OSL_VERIFY( rValue >>= m_aControlSource ); break; case PROPERTY_ID_BOUNDFIELD: - DBG_ERROR("OBoundControlModel::setFastPropertyValue_NoBroadcast : BoundField should be a read-only property !"); + OSL_FAIL("OBoundControlModel::setFastPropertyValue_NoBroadcast : BoundField should be a read-only property !"); throw com::sun::star::lang::IllegalArgumentException(); case PROPERTY_ID_CONTROLLABEL: { @@ -2163,7 +2162,7 @@ void OBoundControlModel::initFromField( const Reference< XRowSet >& _rxRowSet ) transferDbValueToControl(); else // reset the field if the row set is empty - // #i30661# / 2004-12-16 / frank.schoenheit@sun.com + // #i30661# resetNoBroadcast(); } } @@ -2336,7 +2335,6 @@ void OBoundControlModel::doSetControlValue( const Any& _rValue ) // release our mutex once (it's acquired in one of the the calling methods), as setting aggregate properties // may cause any uno controls belonging to us to lock the solar mutex, which is potentially dangerous with // our own mutex locked - // #72451# / 2000-01-31 / frank.schoenheit@sun.com MutexRelease aRelease( m_aMutex ); if ( ( m_nValuePropertyAggregateHandle != -1 ) && m_xAggregateFastSet.is() ) { @@ -2477,10 +2475,7 @@ void OBoundControlModel::reset() throw (RuntimeException) { OSL_ENSURE( sal_False, "OBoundControlModel::reset: caught an SQL exception!" ); } - // don't count the insert row as "invalid" - // @since #i24495# - // @date 2004-05-14 - // @author fs@openoffice.org + // #i24495# - don't count the insert row as "invalid" sal_Bool bSimpleReset = ( !m_xColumn.is() // no connection to a database column @@ -2524,7 +2519,7 @@ void OBoundControlModel::reset() throw (RuntimeException) } catch(Exception&) { - DBG_ERROR("OBoundControlModel::reset: this should have succeeded in all cases!"); + OSL_FAIL("OBoundControlModel::reset: this should have succeeded in all cases!"); } sal_Bool bNeedValueTransfer = sal_True; diff --git a/forms/source/component/FormattedField.cxx b/forms/source/component/FormattedField.cxx index 145671a6e120..000f3ea3f770 100644 --- a/forms/source/component/FormattedField.cxx +++ b/forms/source/component/FormattedField.cxx @@ -127,7 +127,7 @@ StandardFormatsSupplier::StandardFormatsSupplier(const Reference< XMultiServiceF { SetNumberFormatter(m_pMyPrivateFormatter); - // #i29147# - 2004-06-18 - fs@openoffice.org + // #i29147# ::utl::DesktopTerminationObserver::registerTerminationListener( this ); } @@ -184,7 +184,7 @@ void StandardFormatsSupplier::notifyTermination() Reference< XNumberFormatsSupplier > xKeepAlive = this; // when the application is terminating, release our static reference so that we are cleared/destructed // earlier than upon unloading the library - // #i29147# - 2004-06-18 - fs@openoffice.org + // #i29147# s_xDefaultFormatsSupplier = WeakReference< XNumberFormatsSupplier >( ); SetNumberFormatter( NULL ); @@ -480,14 +480,12 @@ void OFormattedModel::describeAggregateProperties( Sequence< Property >& _rAggre // same for FormatKey // (though the paragraph above for the TreatAsNumeric does not hold anymore - we do not have an UI for this. // But we have for the format key ...) - // 25.06.2001 - 87862 - frank.schoenheit@sun.com ModifyPropertyAttributes(_rAggregateProps, PROPERTY_FORMATKEY, 0, PropertyAttribute::TRANSIENT); RemoveProperty(_rAggregateProps, PROPERTY_STRICTFORMAT); // no strict format property for formatted fields: it does not make sense, 'cause // there is no general way to decide which characters/sub strings are allowed during the input of an // arbitraryly formatted control - // 81441 - 12/07/00 - FS } //------------------------------------------------------------------------------ @@ -661,7 +659,7 @@ Reference<XNumberFormatsSupplier> OFormattedModel::calcFormFormatsSupplier() co if (!xNextParentForm.is()) { - DBG_ERROR("OFormattedModel::calcFormFormatsSupplier : have no ancestor which is a form !"); + OSL_FAIL("OFormattedModel::calcFormFormatsSupplier : have no ancestor which is a form !"); return NULL; } @@ -691,7 +689,6 @@ void OFormattedModel::loaded(const EventObject& rEvent) throw ( ::com::sun::star // property requests and one for our own code. This would need a lot of code rewriting // alternative b): The NumberFormatter has to be really threadsafe (with an own mutex), which is // the only "clean" solution for me. - // FS - 69603 - 02.11.99 SolarMutexGuard aGuard; OEditBaseModel::loaded(rEvent); @@ -980,7 +977,7 @@ void OFormattedModel::read(const Reference<XObjectInputStream>& _rxInStream) thr case 2: break; case 3: - DBG_ERROR("FmXFormattedModel::read : unknown effective value type !"); + OSL_FAIL("FmXFormattedModel::read : unknown effective value type !"); } } @@ -1000,7 +997,7 @@ void OFormattedModel::read(const Reference<XObjectInputStream>& _rxInStream) thr } break; default : - DBG_ERROR("OFormattedModel::read : unknown version !"); + OSL_FAIL("OFormattedModel::read : unknown version !"); // dann bleibt das Format des aggregierten Sets, wie es bei der Erzeugung ist : void defaultCommonEditProperties(); break; diff --git a/forms/source/component/FormattedFieldWrapper.cxx b/forms/source/component/FormattedFieldWrapper.cxx index 6ac7740f78b0..118c06921ce1 100644 --- a/forms/source/component/FormattedFieldWrapper.cxx +++ b/forms/source/component/FormattedFieldWrapper.cxx @@ -380,7 +380,7 @@ void OFormattedFieldWrapper::ensureAggregate() Reference< XServiceInfo > xSI(m_xAggregate, UNO_QUERY); if (!xSI.is()) { - DBG_ERROR("OFormattedFieldWrapper::ensureAggregate: the aggregate has no XServiceInfo!"); + OSL_FAIL("OFormattedFieldWrapper::ensureAggregate: the aggregate has no XServiceInfo!"); m_xAggregate.clear(); } } diff --git a/forms/source/component/Grid.cxx b/forms/source/component/Grid.cxx index 701f143c1c0a..7fdb83591834 100644 --- a/forms/source/component/Grid.cxx +++ b/forms/source/component/Grid.cxx @@ -203,7 +203,7 @@ void OGridControlModel::cloneColumns( const OGridControlModel* _pOriginalContain } catch( const Exception& ) { - DBG_ERROR( "OGridControlModel::cloneColumns: caught an exception while cloning the columns!" ); + OSL_FAIL( "OGridControlModel::cloneColumns: caught an exception while cloning the columns!" ); } } @@ -399,7 +399,7 @@ Reference<XPropertySet> OGridControlModel::createColumn(sal_Int32 nTypeId) cons case TYPE_TIMEFIELD: xReturn = new TimeFieldColumn( getContext() ); break; case TYPE_FORMATTEDFIELD: xReturn = new FormattedFieldColumn( getContext() ); break; default: - DBG_ERROR("OGridControlModel::createColumn: Unknown Column"); + OSL_FAIL("OGridControlModel::createColumn: Unknown Column"); break; } return xReturn; diff --git a/forms/source/component/GroupBox.cxx b/forms/source/component/GroupBox.cxx index 702a3aba1905..ccb45d2f8a48 100644 --- a/forms/source/component/GroupBox.cxx +++ b/forms/source/component/GroupBox.cxx @@ -137,7 +137,7 @@ void SAL_CALL OGroupBoxModel::read(const Reference< XObjectInputStream>& _rxInSt if (nVersion > 0x0002) { - DBG_ERROR("OGroupBoxModel::read : unknown version !"); + OSL_FAIL("OGroupBoxModel::read : unknown version !"); } }; diff --git a/forms/source/component/GroupManager.cxx b/forms/source/component/GroupManager.cxx index 7704af43018e..1268bcb5828b 100644 --- a/forms/source/component/GroupManager.cxx +++ b/forms/source/component/GroupManager.cxx @@ -226,12 +226,12 @@ void OGroup::RemoveComponent( const Reference<XPropertySet>& rxElement ) } else { - DBG_ERROR( "OGroup::RemoveComponent: Component nicht in Gruppe" ); + OSL_FAIL( "OGroup::RemoveComponent: Component nicht in Gruppe" ); } } else { - DBG_ERROR( "OGroup::RemoveComponent: Component nicht in Gruppe" ); + OSL_FAIL( "OGroup::RemoveComponent: Component nicht in Gruppe" ); } } diff --git a/forms/source/component/Hidden.cxx b/forms/source/component/Hidden.cxx index 6f1e595d7e79..e71396ec2a39 100644 --- a/forms/source/component/Hidden.cxx +++ b/forms/source/component/Hidden.cxx @@ -178,7 +178,7 @@ void SAL_CALL OHiddenModel::read(const Reference<XObjectInputStream>& _rxInStrea { case 1 : { ::rtl::OUString sDummy; _rxInStream >> sDummy; _rxInStream >> m_sHiddenValue; } break; case 2 : _rxInStream >> m_sHiddenValue; break; - default : DBG_ERROR("OHiddenModel::read : unknown version !"); m_sHiddenValue = ::rtl::OUString(); + default : OSL_FAIL("OHiddenModel::read : unknown version !"); m_sHiddenValue = ::rtl::OUString(); } OControlModel::read(_rxInStream); } diff --git a/forms/source/component/ImageButton.cxx b/forms/source/component/ImageButton.cxx index 926ed5c57e55..c65fea102a12 100644 --- a/forms/source/component/ImageButton.cxx +++ b/forms/source/component/ImageButton.cxx @@ -165,7 +165,7 @@ void OImageButtonModel::read(const Reference<XObjectInputStream>& _rxInStream) t break; default : - DBG_ERROR("OImageButtonModel::read : unknown version !"); + OSL_FAIL("OImageButtonModel::read : unknown version !"); m_eButtonType = FormButtonType_PUSH; m_sTargetURL = ::rtl::OUString(); m_sTargetFrame = ::rtl::OUString(); diff --git a/forms/source/component/ImageControl.cxx b/forms/source/component/ImageControl.cxx index 6caf6f4b530a..e11ace8dd091 100644 --- a/forms/source/component/ImageControl.cxx +++ b/forms/source/component/ImageControl.cxx @@ -180,7 +180,6 @@ OImageControlModel::OImageControlModel( const OImageControlModel* _pOriginal, co osl_incrementInterlockedCount( &m_refCount ); { // simulate a propertyChanged event for the ImageURL - // 2003-05-15 - #109591# - fs@openoffice.org ::osl::MutexGuard aGuard( m_aMutex ); impl_handleNewImageURL_lck( eOther ); } @@ -409,7 +408,7 @@ void OImageControlModel::read(const Reference<XObjectInputStream>& _rxInStream) readCommonProperties(_rxInStream); break; default : - DBG_ERROR("OImageControlModel::read : unknown version !"); + OSL_FAIL("OImageControlModel::read : unknown version !"); m_bReadOnly = sal_False; defaultCommonProperties(); break; @@ -644,7 +643,6 @@ void OImageControlModel::doSetControlValue( const Any& _rValue ) // release our mutex once (it's acquired in the calling method!), as starting the image production may // result in the locking of the solar mutex (unfortunally the default implementation of our aggregate, // VCLXImageControl, does this locking) - // FS - 74438 - 30.03.00 MutexRelease aRelease(m_aMutex); xProducer->startProduction(); } @@ -861,7 +859,7 @@ bool OImageControlControl::implInsertGraphics() // Force bIsLink to be TRUE if we're bound to a field. Though we initialized the file picker with IsLink=TRUE // in this case, and disabled the respective control, there might be picker implementations which do not // respect this, and return IsLink=FALSE here. In this case, "normalize" the flag. - // #i112659# / 2010-08-26 / frank.schoenheit@oracle.com + // #i112659# bIsLink |= bHasField; if ( !bIsLink ) { @@ -877,7 +875,7 @@ bool OImageControlControl::implInsertGraphics() } catch(Exception&) { - DBG_ERROR("OImageControlControl::implInsertGraphics: caught an exception while attempting to execute the FilePicker!"); + OSL_FAIL("OImageControlControl::implInsertGraphics: caught an exception while attempting to execute the FilePicker!"); } return false; } @@ -934,7 +932,6 @@ void OImageControlControl::mousePressed(const ::com::sun::star::awt::MouseEvent& if ( ( e.X < 0 ) || ( e.Y < 0 ) ) { // context menu triggered by keyboard // position it in the center of the control - // 102205 - 16.08.2002 - fs@openoffice.org Reference< XWindow > xWindow( static_cast< ::cppu::OWeakObject* >( this ), UNO_QUERY ); OSL_ENSURE( xWindow.is(), "OImageControlControl::mousePressed: me not a window? How this?" ); if ( xWindow.is() ) @@ -974,7 +971,6 @@ void OImageControlControl::mousePressed(const ::com::sun::star::awt::MouseEvent& // wenn Control nicht gebunden ist, kein Dialog (da die zu schickende URL hinterher sowieso // versanden wuerde) - // FS - #64946# - 19.04.99 Reference<XPropertySet> xBoundField; if (hasProperty(PROPERTY_BOUNDFIELD, xSet)) ::cppu::extractInterface(xBoundField, xSet->getPropertyValue(PROPERTY_BOUNDFIELD)); diff --git a/forms/source/component/ListBox.cxx b/forms/source/component/ListBox.cxx index 734704c33c76..213f58558a6f 100644 --- a/forms/source/component/ListBox.cxx +++ b/forms/source/component/ListBox.cxx @@ -411,7 +411,7 @@ namespace frm void SAL_CALL OListBoxModel::setPropertyValues( const Sequence< ::rtl::OUString >& _rPropertyNames, const Sequence< Any >& _rValues ) throw(PropertyVetoException, IllegalArgumentException, WrappedTargetException, RuntimeException) { // if both SelectedItems and StringItemList are set, care for this - // #i27024# / 2004-04-05 / fs@openoffice.org + // #i27024# const Any* pSelectSequenceValue = NULL; const ::rtl::OUString* pStartPos = _rPropertyNames.getConstArray(); @@ -553,7 +553,7 @@ namespace frm if (nVersion > 0x0004) { - DBG_ERROR("OListBoxModel::read : invalid (means unknown) version !"); + OSL_FAIL("OListBoxModel::read : invalid (means unknown) version !"); ValueList().swap(m_aListSourceValues); m_aBoundColumn <<= (sal_Int16)0; ValueList().swap(m_aBoundValues); diff --git a/forms/source/component/RadioButton.cxx b/forms/source/component/RadioButton.cxx index 68dbd633c85f..0f04b9dd3313 100644 --- a/forms/source/component/RadioButton.cxx +++ b/forms/source/component/RadioButton.cxx @@ -351,7 +351,7 @@ void SAL_CALL ORadioButtonModel::read(const Reference<XObjectInputStream>& _rxIn readCommonProperties(_rxInStream); break; default : - DBG_ERROR("ORadioButtonModel::read : unknown version !"); + OSL_FAIL("ORadioButtonModel::read : unknown version !"); defaultCommonProperties(); break; } @@ -425,7 +425,7 @@ sal_Bool ORadioButtonModel::commitControlValueToDbColumn( bool /*_bPostReset*/ ) } catch(Exception&) { - DBG_ERROR("ORadioButtonModel::commitControlValueToDbColumn: could not commit !"); + OSL_FAIL("ORadioButtonModel::commitControlValueToDbColumn: could not commit !"); } } return sal_True; diff --git a/forms/source/component/clickableimage.cxx b/forms/source/component/clickableimage.cxx index f37c6bbeb89f..dc839f679c4b 100644 --- a/forms/source/component/clickableimage.cxx +++ b/forms/source/component/clickableimage.cxx @@ -296,7 +296,6 @@ namespace frm // * at the UI, show only the mark // * !!!! recognize every SAVEAS on the document, so the absolute URL can be adjusted. This seems // rather impossible !!! - // 89752 - 23.07.2001 - frank.schoenheit@sun.com aURL.Mark = aURL.Complete; aURL.Complete = xModel->getURL(); aURL.Complete += aURL.Mark; @@ -501,7 +500,6 @@ namespace frm osl_incrementInterlockedCount( &m_refCount ); { // simulate a propertyChanged event for the ImageURL - // 2003-05-15 - #109591# - fs@openoffice.org Any aImageURL; getFastPropertyValue( aImageURL, PROPERTY_ID_IMAGE_URL ); _propertyChanged( PropertyChangeEvent( *this, PROPERTY_IMAGE_URL, sal_False, PROPERTY_ID_IMAGE_URL, Any( ), aImageURL ) ); @@ -699,7 +697,6 @@ namespace frm pImgProd->SetImage( sURL ); else // caution: the medium may be NULL if somebody gave us a invalid URL to work with - // 11/24/2000 - 79667 - FS pImgProd->SetImage(String()); m_bDownloading = sal_False; return; @@ -733,7 +730,6 @@ namespace frm } // the SfxMedium is not allowed to be created with an invalid URL, so we have to check this first - // 23.01.2001 - 81927 - FS INetURLObject aUrl(rURL); if (INET_PROT_NOT_VALID == aUrl.GetProtocol()) // we treat an invalid URL like we would treat no URL diff --git a/forms/source/component/formcontrolfont.cxx b/forms/source/component/formcontrolfont.cxx index f1488c85846a..c9837d5ee862 100644 --- a/forms/source/component/formcontrolfont.cxx +++ b/forms/source/component/formcontrolfont.cxx @@ -357,7 +357,7 @@ namespace frm break; default: - DBG_ERROR( "FontControlModel::convertFastPropertyValue: no font aggregate!" ); + OSL_FAIL( "FontControlModel::convertFastPropertyValue: no font aggregate!" ); } return bModified; } @@ -460,7 +460,7 @@ namespace frm break; default: - DBG_ERROR( "FontControlModel::setFastPropertyValue_NoBroadcast: invalid property!" ); + OSL_FAIL( "FontControlModel::setFastPropertyValue_NoBroadcast: invalid property!" ); } } @@ -539,7 +539,7 @@ namespace frm break; default: - DBG_ERROR( "FontControlModel::getPropertyDefaultByHandle: invalid property!" ); + OSL_FAIL( "FontControlModel::getPropertyDefaultByHandle: invalid property!" ); } return aReturn; diff --git a/forms/source/component/imgprod.cxx b/forms/source/component/imgprod.cxx index ceeeccaffa79..39d025719297 100644 --- a/forms/source/component/imgprod.cxx +++ b/forms/source/component/imgprod.cxx @@ -164,7 +164,7 @@ ErrCode ImgProdLockBytes::SetSize( sal_Size nSize ) return SvLockBytes::SetSize( nSize ); else { - DBG_ERROR( "ImgProdLockBytes::SetSize not supported for xInputStream..." ); + OSL_FAIL( "ImgProdLockBytes::SetSize not supported for xInputStream..." ); return ERRCODE_IO_CANTWRITE; } } diff --git a/forms/source/component/propertybaghelper.cxx b/forms/source/component/propertybaghelper.cxx index 508c05ac5ca1..ef09d4841148 100644 --- a/forms/source/component/propertybaghelper.cxx +++ b/forms/source/component/propertybaghelper.cxx @@ -94,7 +94,6 @@ namespace frm ,m_pPropertyArrayHelper( NULL ) ,m_bDisposed( false ) { - // RTL_LOGFILE_CONTEXT_AUTHOR( aLogger, "forms", "dev@dba.openoffice.org", "PropertyBagHelper::PropertyBagHelper" ); } //-------------------------------------------------------------------- @@ -106,14 +105,12 @@ namespace frm //-------------------------------------------------------------------- void PropertyBagHelper::dispose() { - // RTL_LOGFILE_CONTEXT_AUTHOR( aLogger, "forms", "dev@dba.openoffice.org", "PropertyBagHelper::dispose" ); m_bDisposed = true; } //-------------------------------------------------------------------- void PropertyBagHelper::impl_nts_checkDisposed_throw() const { - // RTL_LOGFILE_CONTEXT_AUTHOR( aLogger, "forms", "dev@dba.openoffice.org", "PropertyBagHelper::impl_nts_checkDisposed_throw" ); if ( m_bDisposed ) throw DisposedException(); } @@ -121,14 +118,12 @@ namespace frm //-------------------------------------------------------------------- void PropertyBagHelper::impl_nts_invalidatePropertySetInfo() { - // RTL_LOGFILE_CONTEXT_AUTHOR( aLogger, "forms", "dev@dba.openoffice.org", "PropertyBagHelper::impl_nts_invalidatePropertySetInfo" ); delete m_pPropertyArrayHelper, m_pPropertyArrayHelper = NULL; } //-------------------------------------------------------------------- sal_Int32 PropertyBagHelper::impl_findFreeHandle( const ::rtl::OUString& _rPropertyName ) { - // RTL_LOGFILE_CONTEXT_AUTHOR( aLogger, "forms", "dev@dba.openoffice.org", "PropertyBagHelper::impl_findFreeHandle" ); ::comphelper::OPropertyArrayAggregationHelper& rPropInfo( impl_ts_getArrayHelper() ); // check the preferred handle @@ -168,8 +163,6 @@ namespace frm //-------------------------------------------------------------------- ::comphelper::OPropertyArrayAggregationHelper& PropertyBagHelper::impl_ts_getArrayHelper() const { - // RTL_LOGFILE_CONTEXT_AUTHOR( aLogger, "forms", "dev@dba.openoffice.org", "PropertyBagHelper::impl_ts_getArrayHelper" ); - //::osl::MutexGuard aGuard( m_rContext.getMutex() ); OPropertyArrayAggregationHelper* p = m_pPropertyArrayHelper; if ( !p ) { @@ -204,7 +197,6 @@ namespace frm //-------------------------------------------------------------------- void PropertyBagHelper::addProperty( const ::rtl::OUString& _rName, ::sal_Int16 _nAttributes, const Any& _rInitialValue ) { - // RTL_LOGFILE_CONTEXT_AUTHOR( aLogger, "forms", "dev@dba.openoffice.org", "PropertyBagHelper::addProperty" ); ::osl::MutexGuard aGuard( m_rContext.getMutex() ); impl_nts_checkDisposed_throw(); @@ -232,7 +224,6 @@ namespace frm //-------------------------------------------------------------------- void PropertyBagHelper::removeProperty( const ::rtl::OUString& _rName ) { - // RTL_LOGFILE_CONTEXT_AUTHOR( aLogger, "forms", "dev@dba.openoffice.org", "PropertyBagHelper::removeProperty" ); ::osl::MutexGuard aGuard( m_rContext.getMutex() ); impl_nts_checkDisposed_throw(); @@ -281,7 +272,6 @@ namespace frm //-------------------------------------------------------------------- Sequence< PropertyValue > PropertyBagHelper::getPropertyValues() { - // RTL_LOGFILE_CONTEXT_AUTHOR( aLogger, "forms", "dev@dba.openoffice.org", "PropertyBagHelper::getPropertyValues" ); ::osl::MutexGuard aGuard( m_rContext.getMutex() ); impl_nts_checkDisposed_throw(); @@ -324,7 +314,6 @@ namespace frm //-------------------------------------------------------------------- void PropertyBagHelper::setPropertyValues( const Sequence< PropertyValue >& _rProps ) { - // RTL_LOGFILE_CONTEXT_AUTHOR( aLogger, "forms", "dev@dba.openoffice.org", "PropertyBagHelper::setPropertyValues" ); ::osl::ClearableMutexGuard aGuard( m_rContext.getMutex() ); impl_nts_checkDisposed_throw(); |