Implement split function.
This commit is contained in:
parent
69fb7a7890
commit
66414fe6b8
13
Region.C
13
Region.C
|
@ -179,6 +179,19 @@ Region::handle ( int m )
|
||||||
case 3:
|
case 3:
|
||||||
trim( trimming = RIGHT, X );
|
trim( trimming = RIGHT, X );
|
||||||
break;
|
break;
|
||||||
|
case 2:
|
||||||
|
{
|
||||||
|
/* split */
|
||||||
|
if ( ! copied )
|
||||||
|
{
|
||||||
|
Region *copy = new Region( *this );
|
||||||
|
|
||||||
|
trim( RIGHT, X );
|
||||||
|
copy->trim( LEFT, X );
|
||||||
|
|
||||||
|
_track->add( copy );
|
||||||
|
}
|
||||||
|
}
|
||||||
default:
|
default:
|
||||||
return 0;
|
return 0;
|
||||||
break;
|
break;
|
||||||
|
|
Loading…
Reference in New Issue