From f2964b9cdb04595e842de329222ffa2b63e5d7f7 Mon Sep 17 00:00:00 2001 From: Noel Grandin Date: Wed, 26 Jul 2017 10:52:51 +0200 Subject: convert SfxGroupId to scoped enum in the process I had to teach the idl compiler to cope with identifiers like SfxGroupID::Math, which has the side effect of requiring a space before a ':' in some of the .sdi files. Change-Id: If256599cb8aa1dfc0a33642c5070c5560702f3ba Reviewed-on: https://gerrit.libreoffice.org/40441 Tested-by: Jenkins Reviewed-by: Noel Grandin --- idl/source/cmptools/lex.cxx | 2 +- idl/source/objects/object.cxx | 2 +- idl/source/objects/slot.cxx | 2 +- 3 files changed, 3 insertions(+), 3 deletions(-) (limited to 'idl') diff --git a/idl/source/cmptools/lex.cxx b/idl/source/cmptools/lex.cxx index 8f1d42f06d21..2f1e550cec58 100644 --- a/idl/source/cmptools/lex.cxx +++ b/idl/source/cmptools/lex.cxx @@ -290,7 +290,7 @@ bool SvTokenStream::MakeToken( SvToken & rToken ) { OStringBuffer aBuf; while( rtl::isAsciiAlphanumeric( static_cast(c) ) - || c == '_' ) + || c == '_' || c == ':') { aBuf.append(c); c = GetFastNextChar(); diff --git a/idl/source/objects/object.cxx b/idl/source/objects/object.cxx index 1efd70bb35a5..bb261c44138f 100644 --- a/idl/source/objects/object.cxx +++ b/idl/source/objects/object.cxx @@ -326,7 +326,7 @@ void SvMetaClass::WriteSfx( SvIdlDataBase & rBase, SvStream & rOutStm ) // at least one dummy WriteTab( rOutStm, 1 ); rOutStm.WriteCharPtr( "SFX_SLOT_ARG(" ).WriteOString( GetName() ) - .WriteCharPtr( ", 0, SfxGroupId(0), " ) + .WriteCharPtr( ", 0, SfxGroupId::NONE, " ) .WriteCharPtr( "SFX_STUB_PTR_EXEC_NONE," ) .WriteCharPtr( "SFX_STUB_PTR_STATE_NONE," ) .WriteCharPtr( "SfxSlotMode::NONE, SfxVoidItem, 0, 0, \"\", SfxSlotMode::NONE )" ) << endl; diff --git a/idl/source/objects/slot.cxx b/idl/source/objects/slot.cxx index ba67221f229d..ff32774ae4c1 100644 --- a/idl/source/objects/slot.cxx +++ b/idl/source/objects/slot.cxx @@ -434,7 +434,7 @@ void SvMetaSlot::WriteSlot( const OString& rShellName, sal_uInt16 nCount, if( !GetGroupId().isEmpty() ) rOutStm.WriteOString( GetGroupId() ); else - rOutStm.WriteCharPtr( "SfxGroupId(0)" ); + rOutStm.WriteCharPtr( "SfxGroupId::NONE" ); rOutStm.WriteChar( ',' ) << endl; WriteTab( rOutStm, 4 ); -- cgit