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 #3299 from TomMalbran/tom/fix-issue-2641
Browse files Browse the repository at this point in the history
Fix #2641: Input field change to blank after double click F2 to rename the file - few user will encounter
  • Loading branch information
gruehle committed Apr 24, 2013
2 parents 26e9c90 + bc946e1 commit c449c12
Showing 1 changed file with 6 additions and 1 deletion.
7 changes: 6 additions & 1 deletion src/project/ProjectManager.js
Original file line number Diff line number Diff line change
Expand Up @@ -125,7 +125,7 @@ define(function (require, exports, module) {
* @ see getBaseUrl(), setBaseUrl()
*/
var _projectBaseUrl = "";

/**
* @private
* @type {PreferenceStorage}
Expand Down Expand Up @@ -1305,6 +1305,11 @@ define(function (require, exports, module) {
// First make sure the item in the tree is visible - jsTree's rename API doesn't do anything to ensure inline input is visible
showInTree(entry)
.done(function (selected) {
// Don't try to rename again if we are already renaming
if (_isInRename(selected)) {
return;
}

var isFolder = selected.hasClass("jstree-open") || selected.hasClass("jstree-closed");

_projectTree.one("rename.jstree", function (event, data) {
Expand Down

0 comments on commit c449c12

Please sign in to comment.