ninja-ide/ninja-ide — pull request #1813 by 4544fa8d (2014-08-08 07:13:01+00:00)
Title: Fix for "Find Usages" menu item in code editor

Hello :)

I've encountered a problem with "Find Usages" menu item in context menu of code editor.

How to recreate problem
====================
1. Create new blank (not saved) file
2. Write some content
3. Use "Find Usages" on any word.
4. Error:
Traceback (most recent call last):
File "/xxx/ninja-ide/ninja_ide/gui/tools_dock/tools_dock.py", line 163, in show_find_occurrences
self._findInFilesWidget.find_occurrences(word)
File "/xxx/ninja-ide/ninja_ide/gui/tools_dock/find_in_files.py", line 507, in find_occurrences
self._find_widget.dir_combo.addItem(nproject.path)
AttributeError: 'NoneType' object has no attribute 'path'

My patch fixes it and gives user additional information on how to use "Find Usages".