summaryrefslogtreecommitdiff
path: root/desktop
diff options
context:
space:
mode:
Diffstat (limited to 'desktop')
-rw-r--r--desktop/tree.c2
-rw-r--r--desktop/tree.h9
2 files changed, 7 insertions, 4 deletions
diff --git a/desktop/tree.c b/desktop/tree.c
index 748e7b952..e436339f1 100644
--- a/desktop/tree.c
+++ b/desktop/tree.c
@@ -2136,6 +2136,7 @@ bool tree_mouse_action(struct tree *tree, browser_mouse_state mouse, int x,
BROWSER_MOUSE_DRAG_2)) {
/* Drag starting */
tree->textarea_drag_start = true;
+ tree->drag = TREE_TEXTAREA_DRAG;
} else {
/* Other action */
tree->textarea_drag_start = false;
@@ -2533,6 +2534,7 @@ void tree_drag_end(struct tree *tree, browser_mouse_state mouse, int x0, int y0,
switch (tree->drag) {
case TREE_NO_DRAG:
+ case TREE_TEXTAREA_DRAG:
case TREE_UNKNOWN_DRAG:
break;
case TREE_SELECT_DRAG:
diff --git a/desktop/tree.h b/desktop/tree.h
index 032b5e213..e5abe2102 100644
--- a/desktop/tree.h
+++ b/desktop/tree.h
@@ -63,6 +63,7 @@ typedef enum {
TREE_NO_DRAG = 0,
TREE_SELECT_DRAG,
TREE_MOVE_DRAG,
+ TREE_TEXTAREA_DRAG, /** < A drag that is passed to a textarea */
TREE_UNKNOWN_DRAG /** < A drag the tree itself won't handle */
} tree_drag_type;
@@ -134,7 +135,7 @@ struct tree *tree_create(unsigned int flags,
struct node *tree_create_folder_node(struct tree *tree, struct node *parent,
const char *title, bool editable, bool retain_in_memory,
bool deleted);
-struct node *tree_create_leaf_node(struct tree *tree, struct node *parent,
+struct node *tree_create_leaf_node(struct tree *tree, struct node *parent,
const char *title, bool editable, bool retain_in_memory,
bool deleted);
struct node_element *tree_create_node_element(struct node *parent,
@@ -189,9 +190,9 @@ bool tree_mouse_action(struct tree *tree, browser_mouse_state mouse,
void tree_drag_end(struct tree *tree, browser_mouse_state mouse, int x0, int y0,
int x1, int y1);
bool tree_keypress(struct tree *tree, uint32_t key);
-
-int tree_alphabetical_sort(struct node *, struct node *);
+
+int tree_alphabetical_sort(struct node *, struct node *);
void tree_start_edit(struct tree *tree, struct node_element *element);
struct hlcache_handle *tree_load_icon(const char *name);
-
+
#endif