Propogate the size changes on delete back up the heirarchy.
This commit is contained in:
parent
d6e5852814
commit
e97848de8d
@ -6,5 +6,5 @@
|
|||||||
-> more configuration options (speed and drive choice done)
|
-> more configuration options (speed and drive choice done)
|
||||||
-> fix combo theme
|
-> fix combo theme
|
||||||
-> move callbacks to buttons instead of swallow (done except for welcome page)
|
-> move callbacks to buttons instead of swallow (done except for welcome page)
|
||||||
-> send combo popup children the focus out signal
|
|
||||||
-> figure out what to do about dnd, should it be consolidated into one system, how to handle internel, etc.
|
-> figure out what to do about dnd, should it be consolidated into one system, how to handle internel, etc.
|
||||||
|
-> don't load the sources all at one time (lots of memory consumed -- for my entire development tree containing 154256 files, ecdb uses 46mb)
|
||||||
|
@ -198,7 +198,7 @@ ecdb_custom_filelist_model_filter(Ewl_Filelist_Directory *dir)
|
|||||||
ecore_list_first_goto(dir->rfiles);
|
ecore_list_first_goto(dir->rfiles);
|
||||||
while ((file = ecore_list_next(dir->rfiles)))
|
while ((file = ecore_list_next(dir->rfiles)))
|
||||||
{
|
{
|
||||||
if (ecore_file_file_get(file->name)[0] != '.')
|
if ((file->name) && (ecore_file_file_get(file->name)[0] != '.'))
|
||||||
{
|
{
|
||||||
ecore_list_append(dir->files, file);
|
ecore_list_append(dir->files, file);
|
||||||
nf++;
|
nf++;
|
||||||
@ -208,7 +208,7 @@ ecdb_custom_filelist_model_filter(Ewl_Filelist_Directory *dir)
|
|||||||
ecore_list_first_goto(dir->rdirs);
|
ecore_list_first_goto(dir->rdirs);
|
||||||
while ((file = ecore_list_next(dir->rdirs)))
|
while ((file = ecore_list_next(dir->rdirs)))
|
||||||
{
|
{
|
||||||
if (ecore_file_file_get(file->name)[0] != '.')
|
if ((file->name) && (ecore_file_file_get(file->name)[0] != '.'))
|
||||||
{
|
{
|
||||||
ecore_list_append(dir->dirs, file);
|
ecore_list_append(dir->dirs, file);
|
||||||
nd++;
|
nd++;
|
||||||
|
@ -123,6 +123,7 @@ void
|
|||||||
ecdb_source_child_remove(Ecdb_Source *src, Ecdb_Source *child)
|
ecdb_source_child_remove(Ecdb_Source *src, Ecdb_Source *child)
|
||||||
{
|
{
|
||||||
Ecdb_Source **temp;
|
Ecdb_Source **temp;
|
||||||
|
Ecdb_Source *s;
|
||||||
int i, cidx, f;
|
int i, cidx, f;
|
||||||
|
|
||||||
if (src == child)
|
if (src == child)
|
||||||
@ -149,7 +150,18 @@ ecdb_source_child_remove(Ecdb_Source *src, Ecdb_Source *child)
|
|||||||
FREE(src->children);
|
FREE(src->children);
|
||||||
src->children = temp;
|
src->children = temp;
|
||||||
src->num_children--;
|
src->num_children--;
|
||||||
src->size -= child->size;
|
|
||||||
|
// Propogate the size changes back up to the root
|
||||||
|
s = src;
|
||||||
|
do {
|
||||||
|
s->size -= child->size;
|
||||||
|
|
||||||
|
if (s->parent)
|
||||||
|
s = s->parent;
|
||||||
|
else
|
||||||
|
break;
|
||||||
|
} while (1);
|
||||||
|
|
||||||
child->parent = NULL;
|
child->parent = NULL;
|
||||||
}
|
}
|
||||||
|
|
||||||
|
Loading…
Reference in New Issue
Block a user