Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

[CLOSED] Add function to suggest untitled document name #93

Open
core-ai-bot opened this issue Aug 29, 2021 · 4 comments
Open

[CLOSED] Add function to suggest untitled document name #93

core-ai-bot opened this issue Aug 29, 2021 · 4 comments

Comments

@core-ai-bot
Copy link
Member

Issue by chrisbank
Monday Jan 16, 2012 at 21:20 GMT
Originally opened as adobe/brackets#89


This is to fix adobe/brackets#26


chrisbank included the following code: https://github.com/adobe/brackets/pull/89/commits

@core-ai-bot
Copy link
Member Author

Comment by gruehle
Monday Jan 16, 2012 at 23:50 GMT


The async code looks good, but it feels a bit odd putting it in ProjectManager like that. How about doing this async implementation, but back in FileCommandHandlers. The call to ProjectManager.createNewItem() would be made in the done() handler.

@core-ai-bot
Copy link
Member Author

Comment by chrisbank
Tuesday Jan 17, 2012 at 00:12 GMT


If I call ProjectManager.createNewItem() in my done handler, how do I return the results to the caller of handleFileNewInProject?

@core-ai-bot
Copy link
Member Author

Comment by gruehle
Tuesday Jan 17, 2012 at 00:18 GMT


You would need to add a new Deferred in handleFileNewInProject, and return that. The new Deferred would resolve()/reject() based on the result of the Deferred returned from ProjectManager.createNewItem(). Asynchronous coding at it's finest :-)

@core-ai-bot
Copy link
Member Author

Comment by chrisbank
Wednesday Jan 18, 2012 at 04:38 GMT


Should be ready to roll

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

No branches or pull requests

1 participant