@@ -1398,14 +1398,10 @@ public static class ByReference extends _VARDESC implements
1398
1398
public VARIANT .ByReference lpvarValue ;
1399
1399
1400
1400
public _VARDESC () {
1401
- setType ("lpvarValue" );
1402
- this .read ();
1403
1401
}
1404
1402
1405
1403
public _VARDESC (Pointer pointer ) {
1406
1404
super (pointer );
1407
- setType ("lpvarValue" );
1408
- this .read ();
1409
1405
}
1410
1406
1411
1407
/**
@@ -1431,9 +1427,15 @@ public VARDESC() {
1431
1427
1432
1428
public VARDESC (Pointer pointer ) {
1433
1429
super (pointer );
1434
- this ._vardesc .setType ("lpvarValue" );
1435
1430
this .read ();
1436
1431
}
1432
+
1433
+ @ Override
1434
+ public void read () {
1435
+ readField ("varkind" );
1436
+ this ._vardesc .setType (varkind .value == VARKIND .VAR_CONST ? "lpvarValue" : "oInst" );
1437
+ super .read ();
1438
+ }
1437
1439
}
1438
1440
1439
1441
@ FieldOrder ({"tdesc" , "_elemdesc" })
@@ -1654,14 +1656,10 @@ public static class _TYPEDESC extends Union {
1654
1656
public HREFTYPE hreftype ;
1655
1657
1656
1658
public _TYPEDESC () {
1657
- this .setType ("hreftype" );
1658
- this .read ();
1659
1659
}
1660
1660
1661
1661
public _TYPEDESC (Pointer pointer ) {
1662
1662
super (pointer );
1663
- this .setType ("hreftype" );
1664
- this .read ();
1665
1663
}
1666
1664
1667
1665
public TYPEDESC .ByReference getLptdesc () {
@@ -1687,18 +1685,34 @@ public HREFTYPE getHreftype() {
1687
1685
public VARTYPE vt ;
1688
1686
1689
1687
public TYPEDESC () {
1690
- this .read ();
1691
1688
}
1692
1689
1693
1690
public TYPEDESC (Pointer pointer ) {
1694
1691
super (pointer );
1695
- this .read ();
1696
1692
}
1697
1693
1698
1694
public TYPEDESC (_TYPEDESC _typedesc , VARTYPE vt ) {
1699
1695
this ._typedesc = _typedesc ;
1700
1696
this .vt = vt ;
1701
1697
}
1698
+
1699
+ @ Override
1700
+ public void read () {
1701
+ readField ("vt" );
1702
+ switch (vt .intValue ()) {
1703
+ case Variant .VT_PTR :
1704
+ case Variant .VT_SAFEARRAY :
1705
+ _typedesc .setType ("lptdesc" );
1706
+ break ;
1707
+ case Variant .VT_CARRAY :
1708
+ _typedesc .setType ("lpadesc" );
1709
+ break ;
1710
+ case Variant .VT_USERDEFINED :
1711
+ _typedesc .setType ("hreftype" );
1712
+ break ;
1713
+ }
1714
+ super .read ();
1715
+ }
1702
1716
}
1703
1717
1704
1718
@ FieldOrder ({"dwReserved" , "wIDLFlags" })
0 commit comments