99d97479f0
* gscreen.c (panel_setup_drag_scroll): Made it not return anything, since scrolling is independent from any other prelighting actions. (panel_tree_drag_begin): Do not print debugging message. (panel_drag_data_get): Assert that we were requested a valid data type. (panel_create_tree_view): Only specify GTK_DEST_DEFAULT_DROP for the tree, since we want to present the correct feedback when the user is hovering over the blank area in the tree. (panel_build_selected_file_list): Made it return char *. (panel_tree_drag_end): Free dtree->drag_dir, not dtree->current_path. (tree_drag_open_directory): Use panel->drag_tree_node instead of the coordinates hack. 1999-04-15 Federico Mena Quintero <federico@nuclecu.unam.mx> * gscreen.c (panel_setup_drag_scroll): Made it not return anything, since scrolling is independent from any other prelighting actions. (panel_tree_drag_begin): Do not print debugging message. (panel_drag_data_get): Assert that we were requested a valid data type.
59 строки
1.6 KiB
C
59 строки
1.6 KiB
C
#ifndef _GTK_DTREE_H
|
|
#define _GTK_DTREE_H
|
|
|
|
#include <gtk/gtkctree.h>
|
|
|
|
#define GTK_TYPE_DTREE (gtk_dtree_get_type ())
|
|
#define GTK_DTREE(obj) (GTK_CHECK_CAST ((obj), GTK_TYPE_DTREE, GtkDTree))
|
|
#define GTK_DTREE_CLASS(klass) (GTK_CHECK_CLASS_CAST ((klass), GTK_TYPE_DTREE, GtkDTreeClass))
|
|
#define GTK_IS_DTREE(obj) (GTK_CHECK_TYPE ((obj), GTK_TYPE_DTREE))
|
|
#define GTK_IS_DTREE_CLASS(klass) (GTK_CHECK_CLASS_TYPE ((klass), GTK_TYPE_DTREE))
|
|
|
|
typedef struct {
|
|
GtkCTree ctree;
|
|
|
|
char *current_path;
|
|
char *requested_path;
|
|
|
|
int visible;
|
|
int scan_level;
|
|
|
|
char *drag_dir;
|
|
GList *auto_expanded_nodes;
|
|
|
|
GtkCTreeNode *root_node; /* root node */
|
|
GtkCTreeNode *last_node; /* last visited node */
|
|
|
|
/* Pixmaps for showing directories */
|
|
GdkPixmap *pixmap_open;
|
|
GdkPixmap *pixmap_close;
|
|
|
|
/* Masks */
|
|
GdkBitmap *bitmap_open;
|
|
GdkBitmap *bitmap_close;
|
|
|
|
unsigned short internal;
|
|
unsigned short loading_dir;
|
|
int *show_dot_files;
|
|
unsigned short removing_rows;
|
|
} GtkDTree;
|
|
|
|
typedef struct {
|
|
GtkCTreeClass parent_class;
|
|
|
|
void (* directory_changed) (GtkDTree *dtree, char *directory);
|
|
void (* scan_begin) (GtkDTree *dtree);
|
|
void (* scan_end) (GtkDTree *dtree);
|
|
} GtkDTreeClass;
|
|
|
|
guint gtk_dtree_get_type (void);
|
|
GtkWidget *gtk_dtree_new (void);
|
|
gboolean gtk_dtree_select_dir (GtkDTree *dtree,
|
|
char *directory);
|
|
char *gtk_dtree_get_row_path (GtkDTree *ctree,
|
|
GtkCTreeNode *row,
|
|
gint column);
|
|
void gtk_dtree_construct (GtkDTree *dtree);
|
|
|
|
#endif
|