Lines 58-77
Link Here
|
58 |
* |
58 |
* |
59 |
* |
59 |
* |
60 |
************************************************************************/ |
60 |
************************************************************************/ |
61 |
#define LEAK_STATIC_DATA |
|
|
62 |
#define TRACE(x) OSL_TRACE(x) |
63 |
#define TRACE(x) |
64 |
|
65 |
#include <list> |
66 |
#include <map> |
67 |
#include <typeinfo> |
68 |
#include <com/sun/star/uno/genfunc.hxx> |
61 |
#include <com/sun/star/uno/genfunc.hxx> |
69 |
#ifndef _TYPELIB_TYPEDESCRIPTION_HXX_ |
|
|
70 |
#include <typelib/typedescription.hxx> |
62 |
#include <typelib/typedescription.hxx> |
71 |
#endif |
|
|
72 |
#ifndef _UNO_DATA_H_ |
73 |
#include <uno/data.h> |
63 |
#include <uno/data.h> |
74 |
#endif |
|
|
75 |
#include "bridges/cpp_uno/shared/bridge.hxx" |
64 |
#include "bridges/cpp_uno/shared/bridge.hxx" |
76 |
#include "bridges/cpp_uno/shared/cppinterfaceproxy.hxx" |
65 |
#include "bridges/cpp_uno/shared/cppinterfaceproxy.hxx" |
77 |
#include "bridges/cpp_uno/shared/types.hxx" |
66 |
#include "bridges/cpp_uno/shared/types.hxx" |
Lines 79-86
Link Here
|
79 |
#include "share.hxx" |
68 |
#include "share.hxx" |
80 |
|
69 |
|
81 |
using namespace com::sun::star::uno; |
70 |
using namespace com::sun::star::uno; |
82 |
using namespace std; |
|
|
83 |
using namespace rtl; |
84 |
|
71 |
|
85 |
namespace |
72 |
namespace |
86 |
{ |
73 |
{ |
Lines 145-152
Link Here
|
145 |
|
132 |
|
146 |
if (!rParam.bOut && bridges::cpp_uno::shared::isSimpleType( pParamTypeDescr )) // value |
133 |
if (!rParam.bOut && bridges::cpp_uno::shared::isSimpleType( pParamTypeDescr )) // value |
147 |
{ |
134 |
{ |
148 |
pCppArgs[nPos] = pUnoArgs[nPos] = |
135 |
pCppArgs[nPos] = pCppStack; |
149 |
CPPU_CURRENT_NAMESPACE::adjustPointer( pCppStack, pParamTypeDescr ); |
136 |
pUnoArgs[nPos] = pCppStack; |
150 |
switch (pParamTypeDescr->eTypeClass) |
137 |
switch (pParamTypeDescr->eTypeClass) |
151 |
{ |
138 |
{ |
152 |
case typelib_TypeClass_HYPER: |
139 |
case typelib_TypeClass_HYPER: |
Lines 286-305
Link Here
|
286 |
// pCallStack: this, params |
273 |
// pCallStack: this, params |
287 |
// eventual [ret*] lies at pCallStack -1 |
274 |
// eventual [ret*] lies at pCallStack -1 |
288 |
// so count down pCallStack by one to keep it simple |
275 |
// so count down pCallStack by one to keep it simple |
289 |
bridges::cpp_uno::shared::CppInterfaceProxy * pCppI |
|
|
290 |
= bridges::cpp_uno::shared::CppInterfaceProxy::castInterfaceToProxy( |
291 |
static_cast< char * >(*pCallStack) - nVtableOffset); |
292 |
if ((nFunctionIndex & 0x80000000) != 0) { |
276 |
if ((nFunctionIndex & 0x80000000) != 0) { |
293 |
nFunctionIndex &= 0x7FFFFFFF; |
277 |
nFunctionIndex &= 0x7FFFFFFF; |
294 |
--pCallStack; |
278 |
--pCallStack; |
295 |
} |
279 |
} |
|
|
280 |
|
281 |
bridges::cpp_uno::shared::CppInterfaceProxy * pCppI |
282 |
= bridges::cpp_uno::shared::CppInterfaceProxy::castInterfaceToProxy( |
283 |
static_cast< char * >(*pCallStack) - nVtableOffset); |
284 |
|
296 |
typelib_InterfaceTypeDescription * pTypeDescr = pCppI->getTypeDescr(); |
285 |
typelib_InterfaceTypeDescription * pTypeDescr = pCppI->getTypeDescr(); |
297 |
|
286 |
|
298 |
OSL_ENSURE( nFunctionIndex < pTypeDescr->nMapFunctionIndexToMemberIndex, |
287 |
OSL_ENSURE( nFunctionIndex < pTypeDescr->nMapFunctionIndexToMemberIndex, |
299 |
"### illegal vtable index!" ); |
288 |
"### illegal vtable index!" ); |
300 |
if (nFunctionIndex >= pTypeDescr->nMapFunctionIndexToMemberIndex) |
289 |
if (nFunctionIndex >= pTypeDescr->nMapFunctionIndexToMemberIndex) |
301 |
{ |
290 |
{ |
302 |
throw RuntimeException( OUString::createFromAscii("illegal vtable index!"), (XInterface *)pCppI ); |
291 |
throw RuntimeException( rtl::OUString::createFromAscii("illegal vtable index!"), (XInterface *)pCppI ); |
303 |
} |
292 |
} |
304 |
|
293 |
|
305 |
// determine called method |
294 |
// determine called method |
Lines 406-412
Link Here
|
406 |
return eRet; |
395 |
return eRet; |
407 |
} |
396 |
} |
408 |
|
397 |
|
409 |
} |
398 |
|
410 |
|
399 |
|
411 |
//================================================================================================== |
400 |
//================================================================================================== |
412 |
/** |
401 |
/** |
Lines 450-456
Link Here
|
450 |
return aType; |
439 |
return aType; |
451 |
} |
440 |
} |
452 |
//__________________________________________________________________________________________________ |
441 |
//__________________________________________________________________________________________________ |
453 |
namespace { |
|
|
454 |
|
442 |
|
455 |
int const codeSnippetSize = 56; |
443 |
int const codeSnippetSize = 56; |
456 |
|
444 |
|