r230 - in branches/work_303: core doc

jls17 at arinside.org jls17 at arinside.org
Wed Oct 5 04:24:09 CDT 2011


Author: jls17
Date: Wed Oct  5 04:24:07 2011
New Revision: 230
URL: http://arinside.org/changeset/230

Log:
- added default constructor to CARVui
- added overlay-support to fields and vuis

Modified:
   branches/work_303/core/ARVui.cpp
   branches/work_303/core/ARVui.h
   branches/work_303/doc/DocFieldDetails.cpp
   branches/work_303/doc/DocVuiDetails.cpp

Modified: branches/work_303/core/ARVui.cpp
==============================================================================
--- branches/work_303/core/ARVui.cpp	Wed Oct  5 00:54:04 2011	(r229)
+++ branches/work_303/core/ARVui.cpp	Wed Oct  5 04:24:07 2011	(r230)
@@ -19,6 +19,13 @@
 #include "../lists/ARVUIList.h"
 #include "ARProplistHelper.h"
 
+CARVui::CARVui()
+: CARServerObject(-1)
+{
+	vuiList = NULL;
+	vuiIndex = -1;
+}
+
 // TODO: write a description about how to use both types of calling this constructor
 CARVui::CARVui(unsigned int SchemaInsideId, unsigned int vuiId, int SchemaVuiIndex)
 : CARServerObject(vuiId), schema(SchemaInsideId)

Modified: branches/work_303/core/ARVui.h
==============================================================================
--- branches/work_303/core/ARVui.h	Wed Oct  5 00:54:04 2011	(r229)
+++ branches/work_303/core/ARVui.h	Wed Oct  5 04:24:07 2011	(r230)
@@ -22,6 +22,7 @@
 	public CARServerObject
 {
 public:
+	CARVui();
 	CARVui(unsigned int schemaInsideId, unsigned int vuiId, int SchemaVuiIndex = -1);
 	CARVui(unsigned int schemaInsideId, const std::string& vuiLabel);
 	~CARVui(void);

Modified: branches/work_303/doc/DocFieldDetails.cpp
==============================================================================
--- branches/work_303/doc/DocFieldDetails.cpp	Wed Oct  5 00:54:04 2011	(r229)
+++ branches/work_303/doc/DocFieldDetails.cpp	Wed Oct  5 04:24:07 2011	(r230)
@@ -38,6 +38,8 @@
 
 		CWebPage webPage(file->GetFileName(), this->field.GetName(), rootLevel, this->pInside->appConfig);
 
+		int overlayType = field.GetOverlayType();
+
 		//ContentHead informations
 		stringstream contHeadStrm;
 		contHeadStrm << CWebUtil::LinkToSchemaIndex(this->rootLevel) << endl;
@@ -45,8 +47,36 @@
 		contHeadStrm << MenuSeparator << CWebUtil::Link(this->schema.GetName(), CPageParams(PAGE_DETAILS, &schema), "", rootLevel) << endl;
 		contHeadStrm << MenuSeparator << CAREnum::DataType(this->field.GetDataType()) << " " << CWebUtil::Link("Field",  CPageParams(PAGE_DETAILS, &schema), "", rootLevel) << endl;
 		contHeadStrm << MenuSeparator << CWebUtil::ObjName(this->field.GetName()) << endl;
-		contHeadStrm << " (Id: " << this->field.GetFieldId() << ")" << endl;
-		webPage.AddContentHead(contHeadStrm.str());
+		contHeadStrm << " (Id: " << this->field.GetFieldId() << ")" << CAREnum::GetOverlayTypeString(overlayType) << endl;
+		
+		CARField overlayObj;
+
+#if AR_CURRENT_API_VERSION >= AR_API_VERSION_764
+		if (pInside->appConfig.bOverlaySupport && overlayType > 0)
+		{
+			string correspondingName;
+			switch (overlayType)
+			{
+			case AR_OVERLAID_OBJECT:
+				correspondingName = this->schema.GetOverlayName();
+				break;
+			case AR_OVERLAY_OBJECT:
+				correspondingName = this->schema.GetOverlayBaseName();
+				break;
+			}
+
+			CARSchema correspondingSchema(correspondingName);
+			CARField correspondingObject(correspondingSchema.GetInsideId(), field.GetFieldId());
+			overlayObj = correspondingObject;	
+		}
+#endif
+		
+		webPage.AddContentHead(contHeadStrm.str(), PlaceOverlayLink(overlayType, overlayObj));
+
+#if AR_CURRENT_API_VERSION >= AR_API_VERSION_764
+		if (pInside->overlayMode == 1 && overlayType == AR_OVERLAID_OBJECT)
+			webPage.AddContent(pInside->PlaceOverlaidNotice(overlayObj, rootLevel));
+#endif
 
 		//Field property table
 		CTable tblFieldprops("commonPropList", "TblObjectList");

Modified: branches/work_303/doc/DocVuiDetails.cpp
==============================================================================
--- branches/work_303/doc/DocVuiDetails.cpp	Wed Oct  5 00:54:04 2011	(r229)
+++ branches/work_303/doc/DocVuiDetails.cpp	Wed Oct  5 04:24:07 2011	(r230)
@@ -37,6 +37,8 @@
 
 		CWebPage webPage(file->GetFileName(), this->vui.GetName(), this->rootLevel, this->pInside->appConfig);
 
+		int overlayType = this->vui.GetOverlayType();
+
 		//ContentHead informations
 		stringstream contHeadStrm;
 		contHeadStrm << CWebUtil::LinkToSchemaIndex(this->rootLevel) << endl;
@@ -44,8 +46,36 @@
 		contHeadStrm << MenuSeparator << CWebUtil::Link(this->schema.GetName(), CPageParams(PAGE_DETAILS, &this->schema), "", rootLevel);
 		contHeadStrm << MenuSeparator << CWebUtil::Link("View", CPageParams(PAGE_OVERVIEW, AR_STRUCT_ITEM_XML_VUI, &this->schema), "", rootLevel) << endl;
 		contHeadStrm << MenuSeparator << CWebUtil::ObjName(this->vui.GetName()) << endl;
-		contHeadStrm << " (Id: " << this->vui.GetInsideId() << ")" << endl;
-		webPage.AddContentHead(contHeadStrm.str());
+		contHeadStrm << " (Id: " << this->vui.GetInsideId() << ")" << CAREnum::GetOverlayTypeString(overlayType) << endl;
+		
+		CARVui overlayObj;
+
+#if AR_CURRENT_API_VERSION >= AR_API_VERSION_764
+		if (pInside->appConfig.bOverlaySupport && overlayType > 0)
+		{
+			string correspondingName;
+			switch (overlayType)
+			{
+			case AR_OVERLAID_OBJECT:
+				correspondingName = this->schema.GetOverlayName();
+				break;
+			case AR_OVERLAY_OBJECT:
+				correspondingName = this->schema.GetOverlayBaseName();
+				break;
+			}
+
+			CARSchema correspondingSchema(correspondingName);
+			CARVui correspondingObject(correspondingSchema.GetInsideId(), vui.GetInsideId());
+			overlayObj = correspondingObject;	
+		}
+#endif
+		
+		webPage.AddContentHead(contHeadStrm.str(), PlaceOverlayLink(overlayType, overlayObj));
+
+#if AR_CURRENT_API_VERSION >= AR_API_VERSION_764
+		if (pInside->overlayMode == 1 && overlayType == AR_OVERLAID_OBJECT)
+			webPage.AddContent(pInside->PlaceOverlaidNotice(overlayObj, rootLevel));
+#endif
 
 		//Properties
 		webPage.AddContent(CARProplistHelper::GetList(this->vui.GetDisplayProps(), this));


More information about the arinside-src mailing list