Show More
@@ -91,7 +91,7 b' define([' | |||
|
91 | 91 | // Create a new notebook in the same path as the current |
|
92 | 92 | // notebook's path. |
|
93 | 93 | var parent = utils.url_path_split(that.notebook.notebook_path)[0]; |
|
94 | that.contents.new(parent, { | |
|
94 | that.contents.new_untitled(parent, { | |
|
95 | 95 | type: "notebook", |
|
96 | 96 | extra_settings: {async: false}, // So we can open a new window afterwards |
|
97 | 97 | success: function (data) { |
@@ -92,15 +92,15 b' define([' | |||
|
92 | 92 | |
|
93 | 93 | |
|
94 | 94 | /** |
|
95 |
* Creates a new |
|
|
95 | * Creates a new untitled file or directory in the specified directory path. | |
|
96 | 96 | * |
|
97 | 97 | * @method new |
|
98 |
* @param {String} path |
|
|
98 | * @param {String} path: the directory in which to create the new file/directory | |
|
99 | 99 | * @param {Object} options: |
|
100 | 100 | * ext: file extension to use |
|
101 | 101 | * type: model type to create ('notebook', 'file', or 'directory') |
|
102 | 102 | */ |
|
103 | Contents.prototype.new = function(path, options) { | |
|
103 | Contents.prototype.new_untitled = function(path, options) { | |
|
104 | 104 | var data = JSON.stringify({ |
|
105 | 105 | ext: options.ext, |
|
106 | 106 | type: options.type |
@@ -64,7 +64,7 b' require([' | |||
|
64 | 64 | var login_widget = new loginwidget.LoginWidget('#login_widget', common_options); |
|
65 | 65 | |
|
66 | 66 | $('#new_notebook').click(function (e) { |
|
67 | contents.new(common_options.notebook_path, { | |
|
67 | contents.new_untitled(common_options.notebook_path, { | |
|
68 | 68 | type: "notebook", |
|
69 | 69 | extra_settings: {async: false}, // So we can open a new window afterwards |
|
70 | 70 | success: function (data) { |
General Comments 0
You need to be logged in to leave comments.
Login now