IRootContainer header comment does not have enough information. | developer.brewmp.com IRootContainer header comment does not have enough information. | developer.brewmp.com

Developer

IRootContainer header comment does not have enough information.

Forums:

  Platform: 1.0.2.410  Simulator: 7.6

 

* First Complain:  IRootContainer header comment does not have enough information.  In BUIW sample code, c_ViewPortTouchApp, it has a code line, that query IWidget interface from    a IRootContainer object:          ERR_TRY( IRootContainer_QueryInterface(pMe->picRoot, AEEIID_IWidget, (void**)&pMe->piwRoot) );      However, I search thoroughly in the platform header files, there is no information tells    you IRootContainer provides IWiget interface.    In the definition of INHERIT_IRootContainer, you only know IRootContainer is a singly inherited from   IXYContainer.   What class hierarchy graph you can get from macro is:           IQI             \             IContainer                  \               IXYContainer                      \                 IRootContainer      Next, QIDL document says it doesn't support multiple inheritance, so we think all of the Brew MP   components doesn't support multiple inheritance. However, why does IRootContainer can support    both IContainer and IWidget double interfaces?     Second Complain:   The BUIW sample code provided by Qualcomm Official webpage is too few that I cannot find sample code of using   Button Widget.   The final solution I can find is from PVS:     C:\Program Files\Qualcomm\Brew MP SDK\Platforms\1.0.2.365 Pro\pvs\platform\ui\widgets\src\utwidgets\   Third Complain:    The BUIW sample code is written in C, and it contains too much boilerplate code.     A very simple operation needs to take 4 to 5 lines, which just can be simplified to 1 line     by C++.

First Complain:
IRootContainer header comment does not have enough information.
In BUIW sample code, c_ViewPortTouchApp, it has a code line, that query IWidget interface from
a IRootContainer object:

ERR_TRY( IRootContainer_QueryInterface(pMe->picRoot, AEEIID_IWidget, (void**)&pMe->piwRoot) );

However, I search thoroughly in the platform header files, there is no information tells
you IRootContainer provides IWiget interface.
In the definition of INHERIT_IRootContainer, you only know IRootContainer is a singly inherited from
IXYContainer.
What class hierarchy graph you can get from macro is:

IQI
\
IContainer
\
IXYContainer
\
IRootContainer

Next, QIDL document says it doesn't support multiple inheritance, so we think all of the Brew MP
components doesn't support multiple inheritance. However, why does IRootContainer can support
both IContainer and IWidget double interfaces?
Second Complain:
The BUIW sample code provided by Qualcomm Official webpage is too few that I cannot find sample code of using
Button Widget.
The final solution I can find is from PVS:
C:\Program Files\Qualcomm\Brew MP SDK\Platforms\1.0.2.365 Pro\pvs\platform\ui\widgets\src\utwidgets\
Third Complain:
The BUIW sample code is written in C, and it contains too much boilerplate code.
A very simple operation needs to take 4 to 5 lines, which just can be simplified to 1 line
by C++.

First Complain:
IRootContainer header comment does not have enough information.
In BUIW sample code, c_ViewPortTouchApp, it has a code line, that query IWidget interface from
a IRootContainer object:

ERR_TRY( IRootContainer_QueryInterface(pMe->picRoot, AEEIID_IWidget, (void**)&pMe->piwRoot) );

However, I search thoroughly in the platform header files, there is no information tells
you IRootContainer provides IWiget interface.
In the definition of INHERIT_IRootContainer, you only know IRootContainer is a singly inherited from
IXYContainer.
What class hierarchy graph you can get from macro is:

IQI
\
IContainer
\
IXYContainer
\
IRootContainer

Next, QIDL document says it doesn't support multiple inheritance, so we think all of the Brew MP
components doesn't support multiple inheritance. However, why does IRootContainer can support
both IContainer and IWidget double interfaces?
Second Complain:
The BUIW sample code provided by Qualcomm Official webpage is too few that I cannot find sample code of using
Button Widget.
The final solution I can find is from PVS:
C:\Program Files\Qualcomm\Brew MP SDK\Platforms\1.0.2.365 Pro\pvs\platform\ui\widgets\src\utwidgets\
Third Complain:
The BUIW sample code is written in C, and it contains too much boilerplate code.
A very simple operation needs to take 4 to 5 lines, which just can be simplified to 1 line
by C++.

All containers are in turn widgets as well and exposes IWidget which can be retrieved by using QueryInterface function. This widget is used to manage the drawing of the container.
Though it is not explicitly mentioned in headers, you can refer widgets tech guide for details: https://developer.brewmp.com/resources/tech-guides/widgets-technology-gu... widgets are used in sample "Viewport Rubberbanding Sample Code": https://developer.brewmp.com/file/576089/c_viewportrubberbanding_1.0.0.zip
 
BUIW sample code is to give an idea about widgets usage (and not a complete code) and most of the developers use C, hence it is in C. But it can be easily ported to C++.

All containers are in turn widgets as well and exposes IWidget which can be retrieved by using QueryInterface function. This widget is used to manage the drawing of the container.
Though it is not explicitly mentioned in headers, you can refer widgets tech guide for details: https://developer.brewmp.com/resources/tech-guides/widgets-technology-gu... widgets are used in sample "Viewport Rubberbanding Sample Code": https://developer.brewmp.com/file/576089/c_viewportrubberbanding_1.0.0.zip
 
BUIW sample code is to give an idea about widgets usage (and not a complete code) and most of the developers use C, hence it is in C. But it can be easily ported to C++.

I would like to add that it is planned to include an interface hierarchy in the Widget Technology Guide to improve the understanding of the relationship between the different interfaces.
Thanks,Jason

I would like to add that it is planned to include an interface hierarchy in the Widget Technology Guide to improve the understanding of the relationship between the different interfaces.
Thanks,Jason