radioapp/radiouiengine/src/radiostation.cpp
changeset 50 c44f9bb56771
parent 41 3a6b55c6390c
equal deleted inserted replaced
48:e14766a36cdc 50:c44f9bb56771
   180  */
   180  */
   181 void RadioStation::setName( const QString& name )
   181 void RadioStation::setName( const QString& name )
   182 {
   182 {
   183     // Name emptiness is checked because this name setter is used by incoming RDS PS name
   183     // Name emptiness is checked because this name setter is used by incoming RDS PS name
   184     // and empty names should be ignored
   184     // and empty names should be ignored
   185     if ( !name.isEmpty() && !mData->isRenamedByUser() && mData->mName.compare( name ) != 0 ) {
   185     if ( !name.isEmpty() && !mData->isRenamedByUser() && mData->mName.compare( name.trimmed() ) != 0 ) {
   186         mData->mName = name.trimmed();
   186         mData->mName = name.trimmed();
   187         mData->mChangeFlags |= RadioStation::PersistentDataChanged | RadioStation::NameChanged;
   187         mData->mChangeFlags |= RadioStation::PersistentDataChanged | RadioStation::NameChanged;
   188         mData->setStationHasSentRds( true );
   188         mData->setStationHasSentRds( true );
   189 
   189 
   190         // Save the time when PS name changed and if the last change was too close to the current time
   190         // Save the time when PS name changed and if the last change was too close to the current time