Fix ve.dm.SurfaceFragment#getSelectedNode

Because selectNodes() sometimes returns an array of two items:
the selected node, and a zero-length range in the text node after it.

This would result in getSelectedNode() not recognizing the selected
node, which caused a nasty bug: if you inserted a citation, then
tried to inspect it, the dialog would open in creation mode
and insert a new citation instead.

Change-Id: I9a5ba2c63aa5a9eb682d36e0d0c61428cef5e322
Merge "Fix ve.dm.SurfaceFragment#getSelectedNode"