File tree Expand file tree Collapse file tree
java/org/netbeans/modules/python/statusbar Expand file tree Collapse file tree Original file line number Diff line number Diff line change 174174 <verifyIntegrity >true</verifyIntegrity >
175175 <verifyRuntime >warn</verifyRuntime >
176176 <requiresRestart >true</requiresRestart >
177- <author >${dev.name} </author >
177+ <author >albilu </author >
178178 <homePageUrl >https://github.com/albilu/netbeansPython</homePageUrl >
179179 <licenseFile >LICENSE</licenseFile >
180180 <licenseName >GNU General Public License v3.0</licenseName >
812812 </dependency>-->
813813 </dependencies >
814814 <properties >
815- <dev .name>albilu</dev .name>
816815 <netbeans .release.version>RELEASE170</netbeans .release.version>
817- <next .version>1.0 </next .version>
816+ <next .version>1.1 </next .version>
818817 <git .url>https://github.com/albilu/netbeansPython</git .url>
819818 <git .link>https://github.com/albilu/netbeansPython.git</git .link>
820819 <project .build.sourceEncoding>UTF-8</project .build.sourceEncoding>
Original file line number Diff line number Diff line change 77import org .netbeans .api .options .OptionsDisplayer ;
88import org .netbeans .api .project .FileOwnerQuery ;
99import org .netbeans .api .project .Project ;
10- import org .netbeans .modules .python .project .PythonProject ;
1110import org .netbeans .modules .python .PythonUtility ;
1211import org .netbeans .modules .python .packagemanager .PythonPackagesModel ;
12+ import org .netbeans .modules .python .project .PythonProject ;
1313import org .openide .loaders .DataObject ;
1414import org .openide .util .Exceptions ;
1515import org .openide .util .Lookup ;
@@ -101,6 +101,13 @@ public void resultChanged(LookupEvent ev) {
101101 try {
102102 DataObject dataO = (DataObject ) c .iterator ().next ();
103103 Project owner = FileOwnerQuery .getOwner (dataO .getPrimaryFile ());
104+ if ((!dataO .getPrimaryFile ().isFolder () && !dataO .getPrimaryFile ().getMIMEType ()
105+ .equals (PythonUtility .PYTHON_MIME_TYPE ))
106+ || owner == null || !(owner instanceof PythonProject )) {
107+ setVisible (false );
108+ return ;
109+ }
110+ setVisible (true );
104111 if (owner != null && owner instanceof PythonProject ) {
105112 String projectPythonExe = PythonUtility .getProjectPythonExe (owner
106113 .getProjectDirectory ());
Original file line number Diff line number Diff line change @@ -6,4 +6,6 @@ OpenIDE-Module-Display-Category: Editor
66OpenIDE-Module-Requires: org.openide.windows.WindowManager
77OpenIDE-Module-Long-Description: <html>This plugin enables Python Programming Language support for Apache Netbeans.
88 It leverage the Spyder IDE community supported Language Server Protocol. See more details at the
9- <b><a href="https://github.com/albilu/netbeansPython">Full User Guide</a><b></html>
9+ <a href="https://github.com/albilu/netbeansPython">Full User Guide</a>
10+ <br><br>Please Report any bugs at <a href="https://github.com/albilu/netbeansPython/issues">Issues</a>
11+ </html>
You can’t perform that action at this time.
0 commit comments