1
2
3
4
5 #ifndef MC__LAYOUT_H
6 #define MC__LAYOUT_H
7
8 #include "lib/global.h"
9 #include "lib/widget.h"
10
11 #include "panel.h"
12
13
14
15 typedef enum
16 {
17 view_listing = 0,
18 view_info = 1,
19 view_tree = 2,
20 view_quick = 3,
21 view_nothing = 4,
22 } panel_view_mode_t;
23
24
25
26
27
28 typedef struct
29 {
30 gboolean horizontal_split;
31
32
33 gboolean vertical_equal;
34 int left_panel_size;
35
36
37 gboolean horizontal_equal;
38 int top_panel_size;
39 } panels_layout_t;
40
41
42
43 extern int output_lines;
44 extern gboolean command_prompt;
45 extern gboolean menubar_visible;
46 extern int output_start_y;
47 extern gboolean xterm_title;
48 extern gboolean free_space;
49 extern gboolean nice_rotating_dash;
50
51 extern int ok_to_refresh;
52
53 extern panels_layout_t panels_layout;
54
55
56 void layout_change (void);
57 void layout_box (void);
58 void panel_update_cols (Widget * widget, panel_display_t frame_size);
59 void setup_panels (void);
60 void panels_split_equal (void);
61 void panels_split_more (void);
62 void panels_split_less (void);
63 void destroy_panels (void);
64 void setup_cmdline (void);
65 void create_panel (int num, panel_view_mode_t type);
66 void swap_panels (void);
67 panel_view_mode_t get_panel_type (int idx);
68 MC_MOCKABLE panel_view_mode_t get_current_type (void);
69 panel_view_mode_t get_other_type (void);
70 int get_current_index (void);
71 int get_other_index (void);
72 const char *get_nth_panel_name (int num);
73
74 Widget *get_panel_widget (int idx);
75
76 WPanel *get_other_panel (void);
77
78 void save_panel_dir (int idx);
79 char *get_panel_dir_for (const WPanel * widget);
80
81 void set_hintbar (const char *str);
82
83
84 void use_dash (gboolean flag);
85 void rotate_dash (gboolean show);
86
87 #ifdef ENABLE_SUBSHELL
88 gboolean do_load_prompt (void);
89 int load_prompt (int fd, void *unused);
90 #endif
91
92 void update_xterm_title_path (void);
93 void update_terminal_cwd (void);
94
95 void title_path_prepare (char **path, char **login);
96
97
98
99 #endif