Select default title when renaming a notebook

The default notebook name is Untitled<x>. It is unlikely the user will want to
keep this name or part of it. Instead, select the text in the input field so the
user can easily type over the name and change it.
This commit is contained in:
Kevin Burke 2013-09-01 21:30:40 -07:00
parent fdc32d54a8
commit 2cf73980c0

View File

@ -52,7 +52,7 @@ var IPython = (function (IPython) {
$([IPython.events]).on('checkpoints_listed.Notebook', function (event, data) {
that.set_last_checkpoint(data[0]);
});
$([IPython.events]).on('checkpoint_created.Notebook', function (event, data) {
that.set_last_checkpoint(data);
});
@ -104,7 +104,7 @@ var IPython = (function (IPython) {
return false;
}
});
that.find('input[type="text"]').focus();
that.find('input[type="text"]').focus().select();
}
});
}