From 73253e93327cf4ef0932de1b4afb56af22a0f37e Mon Sep 17 00:00:00 2001 From: pohly Date: Tue, 24 Aug 2004 20:52:45 +0000 Subject: updated source to opie-reader 0.7g --- (limited to 'noncore/apps/opie-reader/my_list.h') diff --git a/noncore/apps/opie-reader/my_list.h b/noncore/apps/opie-reader/my_list.h index f180d3d..52e6472 100644 --- a/noncore/apps/opie-reader/my_list.h +++ b/noncore/apps/opie-reader/my_list.h @@ -1,6 +1,10 @@ #ifndef __MY_LIST_H #define __MY_LIST_H +#ifndef NULL +#define NULL 0 +#endif + template class CList { @@ -30,6 +34,14 @@ class CList } T& first() { return front->data; } T& last() { return back->data; } + T pop() + { + T data = front->data; + node* n = front; + front = front->next; + delete n; + return data; + } T* operator[](int n) { node* current = front; -- cgit v0.9.0.2