summaryrefslogtreecommitdiff
path: root/desktop/hotlist.c
diff options
context:
space:
mode:
authorMichael Drake <tlsa@netsurf-browser.org>2014-05-24 15:09:20 +0100
committerMichael Drake <tlsa@netsurf-browser.org>2014-05-24 15:09:20 +0100
commitce4d52e72aa0fc09bd2207db175bc83c278bb0c6 (patch)
tree727c26d80b67d1c1371bec6b0533768b64a22abd /desktop/hotlist.c
parent610fafc0f9cd9f1c9c78911047d1fa91ca676da5 (diff)
downloadnetsurf-ce4d52e72aa0fc09bd2207db175bc83c278bb0c6.tar.gz
netsurf-ce4d52e72aa0fc09bd2207db175bc83c278bb0c6.tar.bz2
Fix hotlist and global_history _get_selection functions.
Broken when selection was folder, rather than entry. Renamed tree_node_flags lables to avoid TREE_NODE_NONE name clash.
Diffstat (limited to 'desktop/hotlist.c')
-rw-r--r--desktop/hotlist.c5
1 files changed, 3 insertions, 2 deletions
diff --git a/desktop/hotlist.c b/desktop/hotlist.c
index f9a390e1a..aa4370e96 100644
--- a/desktop/hotlist.c
+++ b/desktop/hotlist.c
@@ -1501,10 +1501,11 @@ bool hotlist_has_selection(void)
bool hotlist_get_selection(nsurl **url, const char **title)
{
struct hotlist_entry *e;
+ enum treeview_node_type type;
void *v;
- treeview_get_selection(hl_ctx.tree, &v);
- if (v == NULL) {
+ type = treeview_get_selection(hl_ctx.tree, &v);
+ if (type != TREE_NODE_ENTRY || v == NULL) {
*url = NULL;
*title = NULL;
return false;