Commit
This commit does not belong to any branch on this repository, and may belong to a fork outside of the repository.
Browse files
Browse the repository at this point in the history
Created Bioclipse Search viewpart
- Loading branch information
Showing
7 changed files
with
135 additions
and
0 deletions.
There are no files selected for viewing
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,7 @@ | ||
<?xml version="1.0" encoding="UTF-8"?> | ||
<classpath> | ||
<classpathentry kind="con" path="org.eclipse.jdt.launching.JRE_CONTAINER/org.eclipse.jdt.internal.debug.ui.launcher.StandardVMType/JavaSE-1.7"/> | ||
<classpathentry kind="con" path="org.eclipse.pde.core.requiredPlugins"/> | ||
<classpathentry kind="src" path="src"/> | ||
<classpathentry kind="output" path="bin"/> | ||
</classpath> |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,28 @@ | ||
<?xml version="1.0" encoding="UTF-8"?> | ||
<projectDescription> | ||
<name>net.bioclipse.ui.search</name> | ||
<comment></comment> | ||
<projects> | ||
</projects> | ||
<buildSpec> | ||
<buildCommand> | ||
<name>org.eclipse.jdt.core.javabuilder</name> | ||
<arguments> | ||
</arguments> | ||
</buildCommand> | ||
<buildCommand> | ||
<name>org.eclipse.pde.ManifestBuilder</name> | ||
<arguments> | ||
</arguments> | ||
</buildCommand> | ||
<buildCommand> | ||
<name>org.eclipse.pde.SchemaBuilder</name> | ||
<arguments> | ||
</arguments> | ||
</buildCommand> | ||
</buildSpec> | ||
<natures> | ||
<nature>org.eclipse.pde.PluginNature</nature> | ||
<nature>org.eclipse.jdt.core.javanature</nature> | ||
</natures> | ||
</projectDescription> |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,10 @@ | ||
Manifest-Version: 1.0 | ||
Bundle-ManifestVersion: 2 | ||
Bundle-Name: Search | ||
Bundle-SymbolicName: net.bioclipse.ui.search;singleton:=true | ||
Bundle-Version: 1.0.0.qualifier | ||
Bundle-RequiredExecutionEnvironment: JavaSE-1.7 | ||
Require-Bundle: org.eclipse.e4.ui.di, | ||
org.eclipse.swt, | ||
org.eclipse.ui, | ||
org.eclipse.core.runtime;bundle-version="3.10.0" |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,5 @@ | ||
source.. = src/ | ||
output.. = bin/ | ||
bin.includes = META-INF/,\ | ||
.,\ | ||
plugin.xml |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,16 @@ | ||
<?xml version="1.0" encoding="UTF-8"?> | ||
<?eclipse version="3.4"?> | ||
<plugin> | ||
<extension | ||
point="org.eclipse.ui.views"> | ||
<view | ||
class="net.bioclipse.ui.search.BioclipseUISearchPart" | ||
id="net.bioclipse.search.BioclipseSearch" | ||
name="Search" | ||
category="net.bioclipse.ui.category" | ||
icon="" | ||
allowMultiple="false" | ||
restorable="true"> | ||
</view> | ||
</extension> | ||
</plugin> |
46 changes: 46 additions & 0 deletions
46
plugins/net.bioclipse.ui.search/src/net/bioclipse/ui/search/BioclipseSearch.java
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,46 @@ | ||
package net.bioclipse.ui.search; | ||
|
||
import javax.annotation.PostConstruct; | ||
import javax.annotation.PreDestroy; | ||
|
||
import org.eclipse.e4.ui.di.Focus; | ||
import org.eclipse.swt.widgets.Composite; | ||
import org.eclipse.swt.widgets.Table; | ||
import org.eclipse.swt.SWT; | ||
import org.eclipse.swt.widgets.TableColumn; | ||
|
||
public class BioclipseSearch { | ||
private Table table; | ||
|
||
public BioclipseSearch() { | ||
} | ||
|
||
/** | ||
* Create contents of the view part. | ||
*/ | ||
@PostConstruct | ||
public void createControls(Composite parent) { | ||
|
||
table = new Table(parent, SWT.BORDER | SWT.FULL_SELECTION); | ||
table.setHeaderVisible(true); | ||
table.setLinesVisible(true); | ||
|
||
TableColumn tblclmnSearch = new TableColumn(table, SWT.NONE); | ||
tblclmnSearch.setWidth(100); | ||
tblclmnSearch.setText("Search"); | ||
|
||
TableColumn tblclmnhits = new TableColumn(table, SWT.NONE); | ||
tblclmnhits.setWidth(100); | ||
tblclmnhits.setText("#hits"); | ||
} | ||
|
||
@PreDestroy | ||
public void dispose() { | ||
} | ||
|
||
@Focus | ||
public void setFocus() { | ||
// TODO Set the focus to control | ||
} | ||
|
||
} |
23 changes: 23 additions & 0 deletions
23
plugins/net.bioclipse.ui.search/src/net/bioclipse/ui/search/BioclipseUISearchPart.java
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,23 @@ | ||
package net.bioclipse.ui.search; | ||
|
||
import org.eclipse.swt.widgets.Composite; | ||
import org.eclipse.ui.part.ViewPart; | ||
|
||
public class BioclipseUISearchPart extends ViewPart { | ||
|
||
private BioclipseSearch search; | ||
|
||
public BioclipseUISearchPart() { | ||
this.search = new BioclipseSearch(); | ||
} | ||
|
||
@Override | ||
public void createPartControl(Composite arg0) { | ||
search.createControls(arg0); | ||
} | ||
|
||
@Override | ||
public void setFocus() { | ||
search.setFocus(); | ||
} | ||
} |