Print Page | Close Window

Flow Graoh version 16.1.0

Printed From: Codejock Forums
Category: Codejock Products
Forum Name: General Discussion
Forum Description: Topics Related to Visual C++ MFC Development in General
URL: http://forum.codejock.com/forum_posts.asp?TID=21618
Printed Date: 20 April 2024 at 6:18am
Software Version: Web Wiz Forums 12.04 - http://www.webwizforums.com


Topic: Flow Graoh version 16.1.0
Posted By: lrenoux
Subject: Flow Graoh version 16.1.0
Date Posted: 30 April 2013 at 11:20am
Lot of bugs in the new release 16.1.0.

1. File format has changed and no ascendant compatibility has been given.
2. New file format doesn't remember size of node.
3. API to add a connection point to a node has been changed (AddNamedConnectionPoints), but we have no access to the connection point created. Sample FlowGraphSample has some bugs due to this restriction like being unable to rename the connection point created.

and so on ...

Tickets has been opened.

Could we waiting for a hot patch ?



Replies:
Posted By: ilya
Date Posted: 31 May 2013 at 1:57pm
1. There's no backward compatibility for old file format
2. Will fix it the next release
3. Yes, API is changed. See 
Workspace\Support\FlowGraph\NewFlowGraphDoc.pdf


Posted By: lrenoux
Date Posted: 14 June 2013 at 4:55am
1. No backward compatibility is just amazing : do you think you sold a library to don't be used ! With tinyXml library, it remains some problems with node size but if it can help someone ...

TiXmlDocument* pXMLSchedulers = new TiXmlDocument( "Schedulers.xml" );
TiXmlDocument* pXMLFlowGraph = new TiXmlDocument( "FlowGraph.xml" );
map <string, pair<string,string> > connectionPointMap;

if ( pXMLSchedulers->LoadFile( TIXML_ENCODING_UTF8 ))
{
TiXmlNode* pSchedulers =  pXMLSchedulers->FirstChild("Schedulers");

if (pSchedulers)
{
TiXmlElement flowGraph("FlowGraph");

flowGraph.SetAttribute("CompactMode","1");

TiXmlNode *pFlowGraph = pXMLFlowGraph->InsertEndChild(flowGraph);

TiXmlNode* pPages = pSchedulers->FirstChild("Pages");

while (pPages != NULL)
{
TiXmlNode *pPagesClone = pPages->Clone();

pFlowGraph->LinkEndChild(pPagesClone);

TiXmlNode *pPage = pPagesClone->FirstChild("Page");

while (pPage)
{
TiXmlNode *pNode = pPage->FirstChild("Node");

while (pNode)
{
string idNode = Util::Convert("%ld",pNode);

TiXmlElement *pNodeElement = pNode->ToElement();
pNodeElement->SetAttribute("Id",idNode.c_str());

// don't know how to calc real size.
pNodeElement->SetAttribute("UserSize","200, 200");

TiXmlNode *pConnectionPoint = pNode->FirstChild("ConnectionPoint");

uint index = 0;

while (pConnectionPoint)
{
TiXmlElement* pConnectionPointElement = pConnectionPoint->ToElement();

// Create name attribute
CString newPointName;
newPointName.Format(_T("%ld"), Timer().Start());

pConnectionPointElement->SetAttribute("Name",newPointName);

// Memorize Id to reconnect
string idConnectionPoint = pConnectionPointElement->Attribute("Id");

connectionPointMap[idConnectionPoint]=make_pair(idNode,Util::Convert("%d",index));

pConnectionPointElement->RemoveAttribute("Id");

pConnectionPoint = pConnectionPoint->NextSibling("ConnectionPoint");

index++;
}

pNode = pNode->NextSibling("Node");
}

TiXmlNode *pConnection = pPage->FirstChild("Connection");

while (pConnection)
{
TiXmlElement *pConnectionElement = pConnection->ToElement();

string input = pConnectionElement->Attribute("Input");
string output = pConnectionElement->Attribute("Output");

if (connectionPointMap.find(input) == connectionPointMap.end() || connectionPointMap.find(output) == connectionPointMap.end())
{
assert(false);
continue;
}

pConnectionElement->SetAttribute("InputNode",connectionPointMap[input].first.c_str());
pConnectionElement->SetAttribute("InputPointIndex",connectionPointMap[input].second.c_str());

pConnectionElement->SetAttribute("OutputNode",connectionPointMap[output].first.c_str());
pConnectionElement->SetAttribute("OutputPointIndex",connectionPointMap[output].second.c_str());

pConnectionElement->RemoveAttribute("Input");
pConnectionElement->RemoveAttribute("Output");

pConnection = pConnection->NextSibling("Connection");
}

pPage = pPage->NextSibling("Page");
}

pPages = pPages->NextSibling("Pages");
}
}
}

bool ret = pXMLFlowGraph->SaveFile();

delete pXMLSchedulers;
delete pXMLFlowGraph;

2. Ok. When is the next release ?

3. No. This is not an api changed but a bug. Your sample try to give a chance to the user to rename a connecting point added. With theses changes, you can't (no return with the new method AddNamedConnectionPoints) and the sample code is wrong, trying to rename not the connection point added but the last selected.

4. I have opened so many tickets with no return that it seems that my english is not understood.

Cheers,

L.


Posted By: ilya
Date Posted: 17 June 2013 at 11:22am
AddNamedConnectionPoints doesn't return any values.
16.2 release with FlowGraph issues fixed is released on 14 of June 2013
Please read the document called 'NewFlowGraphDoc.pdf', it describes new approach towards connection points and default nodes.
Your support tickets will be answered.


Posted By: lrenoux
Date Posted: 19 June 2013 at 3:32am
This is not serious.

Release 16.2.0 is a great regression ! Nothing has changed except the size node saved in file format (oh !), but new bugs come to us. Just try to start FlowGraphSample, just move a node and finally File/New or Ctrl+N and click somewhere in the page or change in combobox 'Flow Graph Diagrams' type, always resulting in a crash or assert or whatever.

And please don't tell me to read the documentation, the API AddNamedConnectionPoints is not used correctly in YOUR sample because of changes.

FlowGraphSampleView.cpp : line 1021
else if (nCommand == ID_CONNECTIONPOINT_ADD)
{
static int iConnectionPointN = 0;

CString newPointName;
newPointName.Format(_T("New connection point %d"), iConnectionPointN++);

pNode->AddNamedConnectionPoints(newPointName, xtpFlowGraphPointInputAndOutput);
m_wndControl.RedrawControl();
m_wndControl.RenameConnectionPoint(pConnectionPoint); <=== WRONG CODE
}

Tickets opened with no answer (no mail returns with id, created here  https://www.codejock.com/support/" rel="nofollow - https://www.codejock.com/support/ ).

Disappointed.




Posted By: ilya
Date Posted: 27 June 2013 at 8:37am
The crash is fixed and will be available soon in 16.2.1


Posted By: lrenoux
Date Posted: 15 July 2013 at 6:07am
Some news for the next release date (16.2.1) ?



Print Page | Close Window

Forum Software by Web Wiz Forums® version 12.04 - http://www.webwizforums.com
Copyright ©2001-2021 Web Wiz Ltd. - https://www.webwiz.net