break;
case LFUN_BEGINNINGBUF:
- if (cur.size() == 1) {
+ if (cur.depth() == 1) {
if (!cur.mark())
cur.clearSelection();
cursorTop(cur);
break;
case LFUN_BEGINNINGBUFSEL:
- if (cur.size() == 1) {
+ if (cur.depth() == 1) {
if (!cur.selection())
cur.resetAnchor();
cursorTop(cur);
break;
case LFUN_ENDBUF:
- if (cur.size() == 1) {
+ if (cur.depth() == 1) {
if (!cur.mark())
cur.clearSelection();
cursorBottom(cur);
break;
case LFUN_ENDBUFSEL:
- if (cur.size() == 1) {
+ if (cur.depth() == 1) {
if (!cur.selection())
cur.resetAnchor();
cursorBottom(cur);