update ooo310-m15
[ooovba.git] / applied_patches / 0449-vba-fix-worksheet-add-activate.diff
blob0f9a83b652a521fb519493c7ea6c8b82a3f0d601
1 diff --git sc/source/ui/vba/vbaworksheets.cxx sc/source/ui/vba/vbaworksheets.cxx
2 index f2c0312..a927236 100644
3 --- sc/source/ui/vba/vbaworksheets.cxx
4 +++ sc/source/ui/vba/vbaworksheets.cxx
5 @@ -252,7 +265,9 @@ ScVbaWorksheets::Add( const uno::Any& Before, const uno::Any& After,
6 m_xSheets->insertNewByName(aStringName, nSheetIndex + i);
7 result = getItemByStringIndex( aStringName );
9 -
10 + uno::Reference< excel::XWorksheet > xNewSheet( result, uno::UNO_QUERY );
11 + if ( xNewSheet.is() )
12 + xNewSheet->Activate();
13 return result;