[hg] main-silver: #221446: 16s - org.netbeans.modules.db.sql.edi...

  • From: Jaroslav Havlin < >
  • To:
  • Subject: [hg] main-silver: #221446: 16s - org.netbeans.modules.db.sql.edi...
  • Date: Mon, 26 Nov 2012 17:35:03 -0800

changeset a17a862cecef in main-silver ((none))
details: http://hg.netbeans.org/main-silver/rev/a17a862cecef
description:
        #221446: 16s - 
org.netbeans.modules.db.sql.editor.ui.actions.RunSQLAction.isActionEnabled()

diffstat:

 
db.sql.editor/src/org/netbeans/modules/db/sql/editor/ui/actions/RunSQLAction.java
 |  5 +++--
 1 files changed, 3 insertions(+), 2 deletions(-)

diffs (15 lines):

diff --git 
a/db.sql.editor/src/org/netbeans/modules/db/sql/editor/ui/actions/RunSQLAction.java
 
b/db.sql.editor/src/org/netbeans/modules/db/sql/editor/ui/actions/RunSQLAction.java
--- 
a/db.sql.editor/src/org/netbeans/modules/db/sql/editor/ui/actions/RunSQLAction.java
+++ 
b/db.sql.editor/src/org/netbeans/modules/db/sql/editor/ui/actions/RunSQLAction.java
@@ -112,8 +112,9 @@
             return false;
         }
         for (DataObject d : files) {
-            if (FileUtil.getMIMEType(d.getPrimaryFile()) != null
-                    && 
FileUtil.getMIMEType(d.getPrimaryFile()).equals("text/x-sql")) { // NOI18N
+            if (d.getLookup().lookup(SQLExecuteCookie.class) != null
+                    || (FileUtil.getMIMEType(d.getPrimaryFile()) != null
+                    && 
FileUtil.getMIMEType(d.getPrimaryFile()).equals("text/x-sql"))) { // NOI18N
                 return true;
             }
         }

[hg] main-silver: #221446: 16s - org.netbeans.modules.db.sql.edi...

Jaroslav Havlin 11/27/2012

Project Features

About this Project

DB was started in November 2009, is owned by Antonin Nebuzelsky, and has 113 members.
By use of this website, you agree to the NetBeans Policies and Terms of Use (revision 20131025.e7cbc9d). © 2013, Oracle Corporation and/or its affiliates. Sponsored by Oracle logo
 
 
Close
loading
Please Confirm
Close