113
edits
Cesardaher (talk | contribs) |
Cesardaher (talk | contribs) |
||
Line 205: | Line 205: | ||
</pre> | </pre> | ||
To deal with the duplicate tweets, in this version I also changed | To deal with the duplicate tweets, in this version I also changed the code in a way that each tweet collected is reassigned as another variable right before the next search. That way, if the new tweets are equal to the previous ones, the lit up pin is not changed. | ||
<pre> | |||
//reassign new tweet and previous tweet | |||
old_msg = search_msg; | |||
search_msg = std::string(text.c_str(), text.length()); | |||
//change indexes if there is a new tweet | |||
if (search_msg != old_msg){ | |||
rowIndex(findDirVer(search_msg.c_str())); | |||
columnIndex(findDirHor(search_msg.c_str())); | |||
} | |||
</pre> |
edits