Skip to content

Commit

Permalink
ide/extras/PathBox: Fixed crash (http://ecere.com/mantis/view.php?id=600
Browse files Browse the repository at this point in the history
) in NewProjectDialog, d1a5360 was missing a null check; Fixed text wrongly selected when modifying location and tabbing.
  • Loading branch information
jerstlouis committed Aug 24, 2011
1 parent 6f89116 commit 361aeb9
Showing 1 changed file with 3 additions and 2 deletions.
5 changes: 3 additions & 2 deletions extras/gui/controls/PathBox.ec
Expand Up @@ -419,7 +419,7 @@ public class PathBox : CommonControl
char fileName[MAX_LOCATION];//, filePath[MAX_LOCATION];
DirectoriesBox dirBox = (DirectoriesBox)parent.parent;
if(dirBox) { dirBox = (DirectoriesBox)dirBox.parent; } // TOFIX: Precomp needs { }
if(!eClass_IsDerived(dirBox._class, class(DirectoriesBox))) dirBox = null;
if(dirBox && !eClass_IsDerived(dirBox._class, class(DirectoriesBox))) dirBox = null;

incref this;

Expand Down Expand Up @@ -564,7 +564,8 @@ public:
char path[MAX_LOCATION];
GetSystemPathBuffer(path, value);
editBox.contents = path;
editBox.SelectAll();
if(active)
editBox.SelectAll();
CheckFileExists();
}
get { return editBox.contents; }
Expand Down

0 comments on commit 361aeb9

Please sign in to comment.