I've done some work on this in the Outline enhancements branch. I've got a class of helper functions which implement the changes to the underlying document. If you're interested in seeing what I've done, take a look at the "DataManager.h" (http://bazaar.launchpad.net/~lyx-outline-devel/lyx-outline/trunk/view/head:/src/frontends/qt4/DataManager.h) and DataManager.cpp (http://bazaar.launchpad.net/~lyx-outline-devel/lyx-outline/trunk/view/head:/src/frontends/qt4/DataManager.cpp) files in the outline branch.
The branch in the link also has implementations for most of the Outline enhancements I originally proposed for LyX. I just haven't had time to sufficiently clean them up and submit code patches in bite sized intervals. Cheers, Rob