Commit 35d847e3 authored by David Brown's avatar David Brown
Browse files

Added saving of state of hotlist (directories are open or closed)

parent 7d541185
......@@ -2748,8 +2748,15 @@ static _kernel_oserror * hotlist_save_entries(FILE * fileptr, hotlist_item * lis
if (type == 0 || (type == 1 && list->flags & HOTLIST_G_IS_SELECTED))
{
HotlistWrite(fprintf(fileptr, "<h4>%s</h4>\n", list->name));
if (list->flags & HOTLIST_D_IS_OPEN)
{
HotlistWrite(fprintf(fileptr, "<ul><!--open-->\n"));
}
else
{
HotlistWrite(fprintf(fileptr, "<ul>\n"));
}
}
/* Recursive call for the directory contents First, */
/* write the entry header. */
......@@ -3103,6 +3110,11 @@ static _kernel_oserror * hotlist_load_directory(FILE * fileptr, hotlist_item * t
e = hotlist_new_directory(target, next_directory_name, HOTLIST_POSITION_END, &new_dir);
if (e) goto hotlist_load_directory_exit;
if (strstr(string_buffer, "<!--open-->") != NULL)
{
new_dir->flags |= HOTLIST_D_IS_OPEN;
}
free(next_directory_name);
next_directory_name = NULL;
......@@ -5553,6 +5565,7 @@ static void hotlist_get_selected_shape_r(hotlist_item * list,
}
else
{
/* This section run for first selected item found only */
box->xmin = newxmin;
box->xmax = newxmax;
box->ymax = -(*itemno) * item_height;
......
Markdown is supported
0% or .
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment