mirror of
https://gitlab.com/klmp200/LO27.git
synced 2024-11-26 17:04:14 +00:00
In the head
This commit is contained in:
parent
7aa0c34b91
commit
33a439646d
@ -1,33 +1,15 @@
|
|||||||
<<<<<<< HEAD
|
|
||||||
/*
|
|
||||||
* @Author: klmp200
|
|
||||||
* @Date: 2016-12-10 01:32:50
|
|
||||||
* @Last Modified by: klmp200
|
|
||||||
* @Last Modified time: 2016-12-10 21:08:25
|
|
||||||
*/
|
|
||||||
=======
|
|
||||||
/***
|
/***
|
||||||
--- CellElemFunc ---
|
--- CellElemFunc ---
|
||||||
---Created by : Naej Doree ---
|
---Created by : Naej Doree ---
|
||||||
***/
|
***/
|
||||||
>>>>>>> 7e928547972ebd5897e1f416cb7a9a885479ed84
|
|
||||||
|
|
||||||
#include <stdio.h>
|
#include <stdio.h>
|
||||||
#include <stdlib.h>
|
#include <stdlib.h>
|
||||||
#include <CellElement.h>
|
#include <CellElement.h>
|
||||||
|
|
||||||
<<<<<<< HEAD
|
|
||||||
cellElement * CreateCellElem(){
|
cellElement * CreateCellElem(){
|
||||||
cellElement * elem = NULL;
|
cellElement * elem = NULL;
|
||||||
elem = (cellElement*) malloc(sizeof(cellElement));
|
elem = (cellElement*) malloc(sizeof(cellElement));
|
||||||
|
|
||||||
=======
|
|
||||||
|
|
||||||
cellElement * CreateCellElem(){
|
|
||||||
cellElement * elem = NULL;
|
|
||||||
elem = (cellElement*) malloc(sizeof(cellElement));
|
|
||||||
|
|
||||||
>>>>>>> 7e928547972ebd5897e1f416cb7a9a885479ed84
|
|
||||||
if (elem == NULL){
|
if (elem == NULL){
|
||||||
return NULL;
|
return NULL;
|
||||||
}
|
}
|
||||||
@ -38,13 +20,7 @@ cellElement * CreateCellElem(){
|
|||||||
elem->nextCol = NULL;
|
elem->nextCol = NULL;
|
||||||
elem->nextRow = NULL;
|
elem->nextRow = NULL;
|
||||||
|
|
||||||
<<<<<<< HEAD
|
|
||||||
|
|
||||||
return elem;
|
return elem;
|
||||||
=======
|
|
||||||
|
|
||||||
return elem;
|
|
||||||
>>>>>>> 7e928547972ebd5897e1f416cb7a9a885479ed84
|
|
||||||
}
|
}
|
||||||
|
|
||||||
void freeCellElem(cellElement * elem){
|
void freeCellElem(cellElement * elem){
|
||||||
@ -56,11 +32,7 @@ int AddNextCol(cellElement* tree){
|
|||||||
|
|
||||||
cellElement * elem = NULL;
|
cellElement * elem = NULL;
|
||||||
elem = (cellElement*) malloc(sizeof(cellElement));
|
elem = (cellElement*) malloc(sizeof(cellElement));
|
||||||
<<<<<<< HEAD
|
|
||||||
|
|
||||||
=======
|
|
||||||
|
|
||||||
>>>>>>> 7e928547972ebd5897e1f416cb7a9a885479ed84
|
|
||||||
if (elem == NULL){
|
if (elem == NULL){
|
||||||
return -1;
|
return -1;
|
||||||
}
|
}
|
||||||
@ -76,11 +48,6 @@ int AddNextCol(cellElement* tree){
|
|||||||
}else{
|
}else{
|
||||||
return -2;
|
return -2;
|
||||||
}
|
}
|
||||||
<<<<<<< HEAD
|
|
||||||
|
|
||||||
=======
|
|
||||||
|
|
||||||
>>>>>>> 7e928547972ebd5897e1f416cb7a9a885479ed84
|
|
||||||
return 1;
|
return 1;
|
||||||
}
|
}
|
||||||
|
|
||||||
@ -89,11 +56,7 @@ int AddNextRow(cellElement* tree){
|
|||||||
|
|
||||||
cellElement * elem = NULL;
|
cellElement * elem = NULL;
|
||||||
elem = (cellElement*) malloc(sizeof(cellElement));
|
elem = (cellElement*) malloc(sizeof(cellElement));
|
||||||
<<<<<<< HEAD
|
|
||||||
|
|
||||||
=======
|
|
||||||
|
|
||||||
>>>>>>> 7e928547972ebd5897e1f416cb7a9a885479ed84
|
|
||||||
if (elem == NULL){
|
if (elem == NULL){
|
||||||
return -1;
|
return -1;
|
||||||
}
|
}
|
||||||
@ -119,10 +82,6 @@ void removeNextCol(cellElement* tree){
|
|||||||
free(elem);
|
free(elem);
|
||||||
elem = NULL;
|
elem = NULL;
|
||||||
tree->nextCol = NULL;
|
tree->nextCol = NULL;
|
||||||
<<<<<<< HEAD
|
|
||||||
|
|
||||||
=======
|
|
||||||
>>>>>>> 7e928547972ebd5897e1f416cb7a9a885479ed84
|
|
||||||
}
|
}
|
||||||
|
|
||||||
}
|
}
|
||||||
@ -135,10 +94,6 @@ void removeNextRow(cellElement* tree){
|
|||||||
free(elem);
|
free(elem);
|
||||||
elem =NULL;
|
elem =NULL;
|
||||||
tree->nextRow = NULL;
|
tree->nextRow = NULL;
|
||||||
<<<<<<< HEAD
|
|
||||||
|
|
||||||
=======
|
|
||||||
>>>>>>> 7e928547972ebd5897e1f416cb7a9a885479ed84
|
|
||||||
}
|
}
|
||||||
|
|
||||||
}
|
}
|
||||||
|
@ -38,7 +38,6 @@ struct cellElement {
|
|||||||
|
|
||||||
};
|
};
|
||||||
typedef struct cellElement cellElement;
|
typedef struct cellElement cellElement;
|
||||||
<<<<<<< HEAD
|
|
||||||
|
|
||||||
cellElement * CreateCellElem();
|
cellElement * CreateCellElem();
|
||||||
void freeCellElem(cellElement * elem);
|
void freeCellElem(cellElement * elem);
|
||||||
@ -49,18 +48,6 @@ int AddNextRow(cellElement* tree);
|
|||||||
void removeNextCol(cellElement* list);
|
void removeNextCol(cellElement* list);
|
||||||
void removeNextRow(cellElement* list);
|
void removeNextRow(cellElement* list);
|
||||||
|
|
||||||
=======
|
|
||||||
|
|
||||||
cellElement * CreateCellElem();
|
|
||||||
void freeCellElem(cellElement * elem);
|
|
||||||
|
|
||||||
int AddNextCol(cellElement* tree);
|
|
||||||
int AddNextRow(cellElement* tree);
|
|
||||||
|
|
||||||
void removeNextCol(cellElement* list);
|
|
||||||
void removeNextRow(cellElement* list);
|
|
||||||
|
|
||||||
>>>>>>> 7e928547972ebd5897e1f416cb7a9a885479ed84
|
|
||||||
void recursivePrint(cellElement * tree);
|
void recursivePrint(cellElement * tree);
|
||||||
|
|
||||||
void FreeCellElement(cellElement* element);
|
void FreeCellElement(cellElement* element);
|
||||||
|
Loading…
Reference in New Issue
Block a user