1 /*****************************************************************************
2 * history.h: vlc_history_t (web-browser-like back/forward history) handling
3 *****************************************************************************
4 * Copyright (C) 2004 Commonwealth Scientific and Industrial Research
5 * Organisation (CSIRO) Australia
6 * Copyright (C) 2004 the VideoLAN team
10 * Authors: Andre Pang <Andre.Pang@csiro.au>
12 * This program is free software; you can redistribute it and/or modify
13 * it under the terms of the GNU General Public License as published by
14 * the Free Software Foundation; either version 2 of the License, or
15 * (at your option) any later version.
17 * This program is distributed in the hope that it will be useful,
18 * but WITHOUT ANY WARRANTY; without even the implied warranty of
19 * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the
20 * GNU General Public License for more details.
22 * You should have received a copy of the GNU General Public License
23 * along with this program; if not, write to the Free Software
24 * Foundation, Inc., 51 Franklin Street, Fifth Floor, Boston MA 02110-1301, USA.
25 *****************************************************************************/
27 #ifndef __VLC_HISTORY_H__
28 #define __VLC_HISTORY_H__
30 #define XARRAY_EMBED_IN_HOST_C_FILE
41 unsigned int i_index; /* current index into history */
45 typedef struct history_item_t history_item_t;
46 typedef struct history_t history_t;
49 /*****************************************************************************
51 *****************************************************************************/
52 history_t * history_New ( void );
53 bool history_GoBackSavingCurrentItem ( history_t *,
55 bool history_GoForwardSavingCurrentItem ( history_t *,
57 bool history_CanGoBack ( history_t * );
58 bool history_CanGoForward ( history_t * );
59 history_item_t * history_Item ( history_t * );
60 void history_Prune ( history_t * );
61 void history_PruneAndInsert ( history_t *,
63 unsigned int history_Count ( history_t * );
64 unsigned int history_Index ( history_t * );
66 history_item_t * historyItem_New ( char *, char * );
68 #endif /* __VLC_HISTORY_H__ */