1
1

* tree.h: Don't include treestore.h. Fix sources to include

treestore.h when needed.
* treestore.h: Eliminate useless typedefs.
Этот коммит содержится в:
Pavel Roskin 2003-10-23 23:57:59 +00:00
родитель f6214df52b
Коммит 849ef55ae7
7 изменённых файлов: 13 добавлений и 16 удалений

Просмотреть файл

@ -1,5 +1,9 @@
2003-10-23 Pavel Roskin <proski@gnu.org>
* tree.h: Don't include treestore.h. Fix sources to include
treestore.h when needed.
* treestore.h: Eliminate useless typedefs.
* treestore.c (tree_store_start_check_cwd): Eliminate.
(tree_store_start_check): Make globally visible.
* dir.c (do_load_dir): Use path supplied as argument. Call

Просмотреть файл

@ -27,7 +27,7 @@
#include "tty.h"
#include "dir.h"
#include "wtools.h"
#include "tree.h"
#include "treestore.h"
/* If true show files starting with a dot */
int show_dot_files = 1;

Просмотреть файл

@ -50,6 +50,7 @@
#include "mouse.h"
#include "option.h"
#include "tree.h"
#include "treestore.h"
#include "cons.saver.h"
#include "subshell.h"
#include "key.h" /* For init_key() and mi_getch() */

Просмотреть файл

@ -45,6 +45,7 @@
#include "help.h"
#include "key.h" /* For mi_getch() */
#include "tree.h"
#include "treestore.h"
#include "cmd.h"
extern int command_prompt;
@ -57,7 +58,7 @@ static int tree_navigation_flag;
struct WTree {
Widget widget;
TreeStore *store;
struct TreeStore *store;
tree_entry *selected_ptr; /* The selected directory */
char search_buffer[256]; /* Current search string */
tree_entry **tree_shown; /* Entries currently on screen */

Просмотреть файл

@ -1,8 +1,6 @@
#ifndef __TREE_H
#define __TREE_H
#include "treestore.h"
#include "dlg.h"
struct WTree;

Просмотреть файл

@ -47,7 +47,7 @@
#define TREE_SIGNATURE "Midnight Commander TreeStore v 2.0"
static TreeStore ts;
static struct TreeStore ts;
static tree_entry *tree_store_add_entry(char *name);
@ -123,7 +123,7 @@ tree_store_whereis(char *name)
return NULL;
}
TreeStore *
struct TreeStore *
tree_store_get(void)
{
return &ts;

Просмотреть файл

@ -17,14 +17,7 @@ typedef struct tree_entry {
struct tree_entry *prev; /* Previous item in the list */
} tree_entry;
typedef struct {
struct tree_entry *base;
struct tree_entry *current;
int base_dir_len;
int sublevel;
} tree_scan;
typedef struct {
struct TreeStore {
tree_entry *tree_first; /* First entry in the list */
tree_entry *tree_last; /* Last entry in the list */
tree_entry *check_start; /* Start of checked subdirectories */
@ -32,9 +25,9 @@ typedef struct {
GList *add_queue; /* List of strings of added directories */
unsigned int loaded:1;
unsigned int dirty:1;
} TreeStore;
};
TreeStore *tree_store_get (void);
struct TreeStore *tree_store_get (void);
int tree_store_load (void);
int tree_store_save (void);
void tree_store_remove_entry (char *name);