Skip to content
This repository has been archived by the owner on Sep 6, 2021. It is now read-only.

Commit

Permalink
Merge pull request #3690 from rajeshsegu/extension
Browse files Browse the repository at this point in the history
Issue #3679 - File extension now dimmed if created via File > New
  • Loading branch information
jbalsas committed May 3, 2013
2 parents 3b51c65 + c036beb commit a46efac
Show file tree
Hide file tree
Showing 2 changed files with 8 additions and 3 deletions.
9 changes: 7 additions & 2 deletions src/project/ProjectManager.js
Original file line number Diff line number Diff line change
Expand Up @@ -1125,9 +1125,14 @@ define(function (require, exports, module) {
if (isFolder) {
_projectTree.jstree("sort", data.rslt.obj.parent());
}

_projectTree.jstree("select_node", data.rslt.obj, true);


//If the new item is a file, generate the file display entry.
if (!isFolder) {
_projectTree.jstree("set_text", data.rslt.obj, ViewUtils.getFileEntryDisplay(entry));
}

// Notify listeners that the project model has changed
$(exports).triggerHandler("projectFilesChange");

Expand Down
2 changes: 1 addition & 1 deletion src/utils/CollectionUtils.js
Original file line number Diff line number Diff line change
Expand Up @@ -95,7 +95,7 @@ define(function (require, exports, module) {
* @return {boolean} True if the object contains the property
*/
function hasProperty(object, property) {
return Object.prototype.hasOwnProperty.apply(object, [property]);
return Object.prototype.hasOwnProperty.call(object, property);
}

// Define public API
Expand Down

0 comments on commit a46efac

Please sign in to comment.