예제 #1
0
파일: avl.c 프로젝트: TheSOB88/Hungry-App
//Stores the line in the LinkedList for the
//node for the specified word, creating the
//node if necessary. Does not store duplicate
//line data.
void avlAddLine( AvlNode *avlNode, int line ) {
	//create head node if head is null
	if( avlNode->head == NULL ) {
		avlNode->head = llNew( line );
		avlNode->tail = avlNode->head;
	//otherwise, make a new node, link the current
	//tail to it, and update the tail pointer
	} else {
		if( line != avlNode->tail->line ) {
			LLNode *newLL = llNew( line );
			avlNode->tail->next = newLL;
			avlNode->tail = newLL;
		}
	}
}
예제 #2
0
// Constructor
Scene::Scene(): Screen(tft) {
	this->llShapes = llNew();
}