-
Notifications
You must be signed in to change notification settings - Fork 2
Commit
This commit does not belong to any branch on this repository, and may belong to a fork outside of the repository.
Merge pull request #193 from saw-leipzig/issue33
Issue33
- Loading branch information
Showing
21 changed files
with
329 additions
and
185 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
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
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
44 changes: 44 additions & 0 deletions
44
src/de/cses/client/bibliography/AnnotatedBibliographyDataDisplay.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,44 @@ | ||
package de.cses.client.bibliography; | ||
|
||
import com.google.gwt.core.shared.GWT; | ||
import com.google.gwt.safehtml.shared.SafeHtml; | ||
import com.google.gwt.user.client.ui.HTML; | ||
import com.sencha.gxt.core.client.XTemplates; | ||
import com.sencha.gxt.widget.core.client.container.MarginData; | ||
|
||
import de.cses.client.ui.AbstractDataDisplay; | ||
import de.cses.shared.AbstractEntry; | ||
import de.cses.shared.AnnotatedBibliographyEntry; | ||
|
||
public class AnnotatedBibliographyDataDisplay extends AbstractDataDisplay { | ||
|
||
AnnotatedBibliographyEntry bibEntry; | ||
|
||
|
||
interface AnnotatedBibliographyViewTemplates extends XTemplates { | ||
|
||
@XTemplate(source = "AnnotatedBibliographyDisplay.html") | ||
SafeHtml display(AnnotatedBibliographyEntry bibEntry); | ||
} | ||
|
||
public AnnotatedBibliographyDataDisplay(AnnotatedBibliographyEntry bibEntry) { | ||
this.bibEntry = bibEntry; | ||
|
||
AnnotatedBibliographyViewTemplates view = GWT.create(AnnotatedBibliographyViewTemplates.class); | ||
HTML htmlWidget = new HTML(view.display(bibEntry)); | ||
htmlWidget.addStyleName("html-data-display"); | ||
add(htmlWidget, new MarginData(0)); | ||
setHeading(bibEntry.getTitleORG()); | ||
} | ||
|
||
@Override | ||
public String getUniqueID() { | ||
return null; | ||
} | ||
|
||
@Override | ||
public AbstractEntry getEntry() { | ||
return bibEntry; | ||
} | ||
|
||
} |
Oops, something went wrong.