Kaydet (Commit) 7b87ccf9 authored tarafından Miklos Vajna's avatar Miklos Vajna

drop unnecessary RTFDocumentImpl::isEmpty

Change-Id: I657266697c30be0760971528adb1abf07f03ea23
üst b3a7f6d5
......@@ -3902,11 +3902,6 @@ int RTFDocumentImpl::getGroup() const
return m_nGroup;
}
bool RTFDocumentImpl::isEmpty() const
{
return m_aStates.empty();
}
void RTFDocumentImpl::setDestinationText(OUString& rString)
{
m_aStates.top().aDestinationText.setLength(0);
......
......@@ -424,8 +424,7 @@ namespace writerfilter {
void seek(sal_uInt32 nPos);
uno::Reference<lang::XMultiServiceFactory> getModelFactory();
RTFParserState& getState();
/// If the stack of states is empty.
bool isEmpty() const;
/// Number of states on the stack.
int getGroup() const;
void setDestinationText(rtl::OUString& rString);
/// Resolve a picture: If not inline, then anchored.
......
......@@ -95,7 +95,7 @@ int RTFTokenizer::resolveParse()
if (m_rImport.getGroup() < 0)
return ERROR_GROUP_UNDER;
if (!m_rImport.isEmpty() && m_rImport.getState().nInternalState == INTERNAL_BIN)
if (m_rImport.getGroup() > 0 && m_rImport.getState().nInternalState == INTERNAL_BIN)
{
ret = m_rImport.resolveChars(ch);
if (ret)
......@@ -130,7 +130,7 @@ int RTFTokenizer::resolveParse()
case 0x0a:
break; // ignore these
default:
if (m_rImport.isEmpty())
if (m_rImport.getGroup() == 0)
return ERROR_CHAR_OVER;
if (m_rImport.getState().nInternalState == INTERNAL_NORMAL)
{
......
Markdown is supported
0% or
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment