diff options
-rw-r--r-- | sot/source/base/exchange.cxx | 4 |
1 files changed, 1 insertions, 3 deletions
diff --git a/sot/source/base/exchange.cxx b/sot/source/base/exchange.cxx index 8b3541f09ad1..0d9cf8b52001 100644 --- a/sot/source/base/exchange.cxx +++ b/sot/source/base/exchange.cxx @@ -253,16 +253,14 @@ SotClipboardFormatId SotExchange::RegisterFormatName( const OUString& rName ) return static_cast<SotClipboardFormatId>(i + static_cast<int>(SotClipboardFormatId::USER_END) + 1); } - // nMax ist der neue Platz DataFlavor* pNewFlavor = new DataFlavor; - pNewFlavor->MimeType = rName; pNewFlavor->HumanPresentableName = rName; pNewFlavor->DataType = cppu::UnoType<OUString>::get(); rL.push_back( pNewFlavor ); - return static_cast<SotClipboardFormatId>(static_cast<int>(nMax) + static_cast<int>(SotClipboardFormatId::USER_END) + 1); + return static_cast<SotClipboardFormatId>(static_cast<int>(rL.size()-1) + static_cast<int>(SotClipboardFormatId::USER_END) + 1); } SotClipboardFormatId SotExchange::RegisterFormatMimeType( const OUString& rMimeType ) |