CWS-TOOLING: integrate CWS fs33a

This commit is contained in:
Kurt Zenker
2010-09-03 14:39:55 +02:00
2 changed files with 13 additions and 2 deletions

View File

@@ -584,6 +584,7 @@ namespace sfx2
return; return;
::rtl::OUString sFirstVisiblePanelResource; ::rtl::OUString sFirstVisiblePanelResource;
::rtl::OUString sFirstPanelResource;
const Sequence< ::rtl::OUString > aUIElements( aWindowStateConfig.getNodeNames() ); const Sequence< ::rtl::OUString > aUIElements( aWindowStateConfig.getNodeNames() );
for ( const ::rtl::OUString* resource = aUIElements.getConstArray(); for ( const ::rtl::OUString* resource = aUIElements.getConstArray();
@@ -594,6 +595,8 @@ namespace sfx2
if ( !impl_isToolPanelResource( *resource ) ) if ( !impl_isToolPanelResource( *resource ) )
continue; continue;
sFirstPanelResource = *resource;
::utl::OConfigurationNode aResourceNode( aWindowStateConfig.openNode( *resource ) ); ::utl::OConfigurationNode aResourceNode( aWindowStateConfig.openNode( *resource ) );
::svt::PToolPanel pCustomPanel( new CustomToolPanel( aResourceNode, m_xFrame ) ); ::svt::PToolPanel pCustomPanel( new CustomToolPanel( aResourceNode, m_xFrame ) );
@@ -620,6 +623,9 @@ namespace sfx2
sFirstVisiblePanelResource = *resource; sFirstVisiblePanelResource = *resource;
} }
if ( sFirstVisiblePanelResource.getLength() == 0 )
sFirstVisiblePanelResource = sFirstPanelResource;
if ( sFirstVisiblePanelResource.getLength() ) if ( sFirstVisiblePanelResource.getLength() )
{ {
::boost::optional< size_t > aPanelPos( GetPanelPos( sFirstVisiblePanelResource ) ); ::boost::optional< size_t > aPanelPos( GetPanelPos( sFirstVisiblePanelResource ) );

View File

@@ -1344,8 +1344,13 @@ sal_uInt16 SfxObjectShell::ImplGetSignatureState( sal_Bool bScriptingContent )
void SfxObjectShell::ImplSign( sal_Bool bScriptingContent ) void SfxObjectShell::ImplSign( sal_Bool bScriptingContent )
{ {
// Check if it is stored in OASIS format... // Check if it is stored in OASIS format...
if ( GetMedium() && GetMedium()->GetFilter() if ( GetMedium()
&& ( !GetMedium()->GetFilter()->IsOwnFormat() || !GetMedium()->HasStorage_Impl() ) ) && GetMedium()->GetFilter()
&& GetMedium()->GetName().Len()
&& ( !GetMedium()->GetFilter()->IsOwnFormat()
|| !GetMedium()->HasStorage_Impl()
)
)
{ {
// Only OASIS and OOo6.x formats will be handled further // Only OASIS and OOo6.x formats will be handled further
InfoBox( NULL, SfxResId( RID_XMLSEC_INFO_WRONGDOCFORMAT ) ).Execute(); InfoBox( NULL, SfxResId( RID_XMLSEC_INFO_WRONGDOCFORMAT ) ).Execute();