ooo-build r11305 - in trunk: . patches/src680
- From: noelpwer svn gnome org
- To: svn-commits-list gnome org
- Subject: ooo-build r11305 - in trunk: . patches/src680
- Date: Thu, 17 Jan 2008 17:44:39 +0000 (GMT)
Author: noelpwer
Date: Thu Jan 17 17:44:39 2008
New Revision: 11305
URL: http://svn.gnome.org/viewvc/ooo-build?rev=11305&view=rev
Log:
2008-01-17 Noel Power <noel power novell com>
* patches/src680/apply: fix for n#353687
* patches/src680/default-autotext-and-form-name.diff:
Added:
trunk/patches/src680/default-autotext-and-form-name.diff
Modified:
trunk/ChangeLog
trunk/patches/src680/apply
Modified: trunk/patches/src680/apply
==============================================================================
--- trunk/patches/src680/apply (original)
+++ trunk/patches/src680/apply Thu Jan 17 17:44:39 2008
@@ -1314,7 +1314,9 @@
sc-export-shape-hlink-bindings.diff, n#304739, noelpwer
# Application.Caller
-api-application-caller.diff, noelpwer
+api-application-caller.diff, n#339941, noelpwer
+default-autotext-and-form-name.diff, n#353687
+
# add support for passing a caller to basic when calling a script
# via the scripting framework - note depends on vbaevents-services-sources.diff
basic-caller-support.diff
Added: trunk/patches/src680/default-autotext-and-form-name.diff
==============================================================================
--- (empty file)
+++ trunk/patches/src680/default-autotext-and-form-name.diff Thu Jan 17 17:44:39 2008
@@ -0,0 +1,100 @@
+diff -rup /data4/LatestSourceOnly/ooo-build/build/ooh680-m1/sc/source/filter/excel/xiescher.cxx sc/source/filter/excel/xiescher.cxx
+--- /data4/LatestSourceOnly/ooo-build/build/ooh680-m1/sc/source/filter/excel/xiescher.cxx 2008-01-17 16:28:44.000000000 +0000
++++ sc/source/filter/excel/xiescher.cxx 2008-01-17 15:03:09.000000000 +0000
+@@ -598,8 +598,35 @@ sal_Size XclImpDrawObjBase::DoGetProgres
+ return 1;
+ }
+
+-void XclImpDrawObjBase::DoProcessSdrObj( SdrObject& /*rSdrObj*/ ) const
++void XclImpDrawObjBase::DoProcessSdrObj( SdrObject& rSdrObj ) const
+ {
++ if ( rSdrObj.GetName().Len() == 0 )
++ {
++ // create a default name based on the shape id and shape type
++ sal_uInt32 nID = ( mnShapeId & 0x000003ff );
++ String sID = String::CreateFromInt32( nID );
++ switch ( mnObjType )
++ {
++ case EXC_OBJ_CMO_DRAWING:
++ rSdrObj.SetName( String( RTL_CONSTASCII_USTRINGPARAM("AutoShape ") ).Append( sID ) );
++ break;
++ case EXC_OBJ_CMO_RECTANGLE:
++ rSdrObj.SetName( String( RTL_CONSTASCII_USTRINGPARAM("Rectangle ") ).Append( sID ) );
++ break;
++ case EXC_OBJ_CMO_LINE:
++ rSdrObj.SetName( String( RTL_CONSTASCII_USTRINGPARAM("Line ") ).Append( sID ) );
++ break;
++ case EXC_OBJ_CMO_ELLIPSE:
++ rSdrObj.SetName( String( RTL_CONSTASCII_USTRINGPARAM("Oval ") ).Append( sID ) );
++ break;
++ case EXC_OBJ_CMO_TEXT:
++ rSdrObj.SetName( String( RTL_CONSTASCII_USTRINGPARAM("Text Box ") ).Append( sID ) );
++ break;
++ default:
++ DBG_ERROR1( "XclImpDrawObjBase::ProcessSdrObject - unknown object type 0x%04hX", mnObjId );
++ break;
++ }
++ }
+ // trace if object is not printable
+ if( !IsPrintable() )
+ GetTracer().TraceObjectNotPrintable();
+@@ -914,7 +941,7 @@ void XclImpTbxControlObj::DoProcessSdrOb
+ // #118053# #i51348# set internal name of the control (use name from SdrObject, if extant)
+ OUString aCtrlName = rSdrObj.GetName();
+ if( aCtrlName.getLength() == 0 )
+- aCtrlName = XclControlObjHelper::GetTbxControlName( GetObjType() );
++ aCtrlName = XclControlObjHelper::GetTbxControlName( GetObjType(), GetShapeId() );
+ if( aCtrlName.getLength() > 0 )
+ aPropSet.SetProperty( CREATE_OUSTRING( "Name" ), aCtrlName );
+
+diff -rup /data4/LatestSourceOnly/ooo-build/build/ooh680-m1/sc/source/filter/excel/xlescher.cxx sc/source/filter/excel/xlescher.cxx
+--- /data4/LatestSourceOnly/ooo-build/build/ooh680-m1/sc/source/filter/excel/xlescher.cxx 2007-05-22 20:51:34.000000000 +0100
++++ sc/source/filter/excel/xlescher.cxx 2008-01-17 15:37:51.000000000 +0000
+@@ -342,23 +342,24 @@ OUString XclControlObjHelper::GetTbxServ
+ return aName;
+ }
+
+-OUString XclControlObjHelper::GetTbxControlName( sal_uInt16 nCtrlType )
++OUString XclControlObjHelper::GetTbxControlName( sal_uInt16 nCtrlType, sal_uInt32 nShapeId )
+ {
+ OUString aName;
++ OUString sID = OUString::valueOf( static_cast< sal_Int32 >( nShapeId ) & 0x000003ff );
+ switch( nCtrlType )
+ {
+- case EXC_OBJ_CMO_BUTTON: aName = CREATE_OUSTRING( "CommandButton" ); break;
+- case EXC_OBJ_CMO_CHECKBOX: aName = CREATE_OUSTRING( "CheckBox" ); break;
+- case EXC_OBJ_CMO_OPTIONBUTTON: aName = CREATE_OUSTRING( "OptionButton" ); break;
+- case EXC_OBJ_CMO_LABEL: aName = CREATE_OUSTRING( "Label" ); break;
+- case EXC_OBJ_CMO_LISTBOX: aName = CREATE_OUSTRING( "ListBox" ); break;
+- case EXC_OBJ_CMO_GROUPBOX: aName = CREATE_OUSTRING( "GroupBox" ); break;
+- case EXC_OBJ_CMO_COMBOBOX: aName = CREATE_OUSTRING( "ComboBox" ); break;
+- case EXC_OBJ_CMO_SPIN: aName = CREATE_OUSTRING( "SpinButton" ); break;
+- case EXC_OBJ_CMO_SCROLLBAR: aName = CREATE_OUSTRING( "ScrollBar" ); break;
++ case EXC_OBJ_CMO_BUTTON: aName = CREATE_OUSTRING( "Button " ); break;
++ case EXC_OBJ_CMO_CHECKBOX: aName = CREATE_OUSTRING( "Check Box " ); break;
++ case EXC_OBJ_CMO_OPTIONBUTTON: aName = CREATE_OUSTRING( "Option Button " ); break;
++ case EXC_OBJ_CMO_LABEL: aName = CREATE_OUSTRING( "Label " ); break;
++ case EXC_OBJ_CMO_LISTBOX: aName = CREATE_OUSTRING( "List Box " ); break;
++ case EXC_OBJ_CMO_GROUPBOX: aName = CREATE_OUSTRING( "Group Box " ); break;
++ case EXC_OBJ_CMO_COMBOBOX: aName = CREATE_OUSTRING( "Drop Down " ); break;
++ case EXC_OBJ_CMO_SPIN: aName = CREATE_OUSTRING( "Spinner " ); break;
++ case EXC_OBJ_CMO_SCROLLBAR: aName = CREATE_OUSTRING( "Scroll Bar " ); break;
+ default: DBG_ERRORFILE( "XclControlObjHelper::GetTbxControlName - unknown control type" );
+ }
+- return aName;
++ return aName = aName += sID;
+ }
+
+ OUString XclControlObjHelper::GetTbxListenerType( sal_uInt16 nCtrlType )
+diff -rup /data4/LatestSourceOnly/ooo-build/build/ooh680-m1/sc/source/filter/inc/xlescher.hxx sc/source/filter/inc/xlescher.hxx
+--- /data4/LatestSourceOnly/ooo-build/build/ooh680-m1/sc/source/filter/inc/xlescher.hxx 2007-01-22 13:22:23.000000000 +0000
++++ sc/source/filter/inc/xlescher.hxx 2008-01-17 15:39:12.000000000 +0000
+@@ -278,7 +278,7 @@ public:
+ /** Returns the component service name for the passed control type. */
+ static ::rtl::OUString GetTbxServiceName( sal_uInt16 nCtrlType );
+ /** Returns a default control name for the passed control type. */
+- static ::rtl::OUString GetTbxControlName( sal_uInt16 nCtrlType );
++ static ::rtl::OUString GetTbxControlName( sal_uInt16 nCtrlType, sal_uInt32 nShapeId );
+
+ /** Returns the listener type (interface name) for macro events for the passed control type. */
+ static ::rtl::OUString GetTbxListenerType( sal_uInt16 nCtrlType );
[
Date Prev][
Date Next] [
Thread Prev][
Thread Next]
[
Thread Index]
[
Date Index]
[
Author Index]