minor fixes
git-svn-id: http://svn.d4science-ii.research-infrastructures.eu/gcube/trunk/portlets/widgets/ckan-metadata-publisher-widget@134113 82a268e6-3cf1-43bd-a215-b396298e98cf
This commit is contained in:
parent
d23ad12b9e
commit
3f136e00a0
|
@ -35,7 +35,7 @@ public class ResourceCellLeft extends AbstractCell<ResourceElementBean>{
|
|||
sb.appendHtmlConstant("</span>");
|
||||
sb.appendHtmlConstant("<span style='margin-left:10px;'>");
|
||||
sb.appendHtmlConstant("<b>");
|
||||
sb.appendEscaped(value.getEditableName());
|
||||
sb.appendEscaped(value.getName());
|
||||
sb.appendHtmlConstant("</b>");
|
||||
sb.appendHtmlConstant("</span>");
|
||||
sb.appendHtmlConstant("</div>");
|
||||
|
|
|
@ -16,21 +16,21 @@
|
|||
<!-- </b:Column> -->
|
||||
<!-- </b:FluidRow> -->
|
||||
<b:FluidRow>
|
||||
<b:Column size="9">
|
||||
<b:Column offset="1" size="10">
|
||||
<b:Breadcrumbs ui:field="breadcrumbs" divider=">"
|
||||
title="Current path">
|
||||
</b:Breadcrumbs>
|
||||
</b:Column>
|
||||
</b:FluidRow>
|
||||
<b:FluidRow>
|
||||
<b:Column size="4" ui:field="leftColumn">
|
||||
<b:Column offset="1" size="4" ui:field="leftColumn">
|
||||
<!-- <b:Button enabled="true" type="LINK" ui:field="goRootButton">Root
|
||||
level</b:Button> -->
|
||||
<!-- <b:Button enabled="true" type="LINK" ui:field="goUpButton">Go up</b:Button> -->
|
||||
<g:VerticalPanel ui:field="leftContainer" width="100%">
|
||||
</g:VerticalPanel>
|
||||
</b:Column>
|
||||
<b:Column size="1" ui:field="centralPanel">
|
||||
<b:Column size="2" ui:field="centralPanel">
|
||||
<g:VerticalPanel ui:field="buttonsPanel">
|
||||
<b:Button ui:field="allToRightButton" name="toRight"
|
||||
enabled="false" title="Add selected files" text=">>" />
|
||||
|
|
|
@ -9,6 +9,8 @@ import com.google.gwt.dom.client.EventTarget;
|
|||
import com.google.gwt.dom.client.Style.Cursor;
|
||||
import com.google.gwt.event.dom.client.ClickEvent;
|
||||
import com.google.gwt.event.dom.client.ClickHandler;
|
||||
import com.google.gwt.event.dom.client.DoubleClickEvent;
|
||||
import com.google.gwt.event.dom.client.DoubleClickHandler;
|
||||
import com.google.gwt.user.client.ui.Anchor;
|
||||
import com.google.gwt.user.client.ui.FlexTable;
|
||||
import com.google.gwt.user.client.ui.HTML;
|
||||
|
@ -71,7 +73,7 @@ public class GcubeDialogExtended extends GCubeDialog {
|
|||
* @param captionText
|
||||
* @param text
|
||||
*/
|
||||
public GcubeDialogExtended(ResourceInfoForm form){
|
||||
public GcubeDialogExtended(final ResourceInfoForm form){
|
||||
|
||||
// add custom style
|
||||
addStyleName("metadata-popup-panel");
|
||||
|
@ -79,6 +81,12 @@ public class GcubeDialogExtended extends GCubeDialog {
|
|||
// create an anchor to close the dialogbox
|
||||
final Anchor closeAnchor = new Anchor("x");
|
||||
closeAnchor.setTitle("Close");
|
||||
closeAnchor.addClickHandler(new ClickHandler() {
|
||||
@Override
|
||||
public void onClick(ClickEvent event) {
|
||||
hide();
|
||||
}
|
||||
});
|
||||
|
||||
// create a panel that will be put into the caption
|
||||
FlexTable captionLayoutTable = new FlexTable();
|
||||
|
@ -99,13 +107,31 @@ public class GcubeDialogExtended extends GCubeDialog {
|
|||
}
|
||||
}
|
||||
});
|
||||
closeAnchor.addClickHandler(new ClickHandler() {
|
||||
|
||||
setWidget(form);
|
||||
HTML widget = (HTML)getWidget();
|
||||
|
||||
widget.addClickHandler(new ClickHandler() {
|
||||
@Override
|
||||
public void onClick(ClickEvent event) {
|
||||
hide();
|
||||
EventTarget target = event.getNativeEvent().getEventTarget();
|
||||
Element targetElement = (Element) target.cast();
|
||||
if (targetElement == form.getElement()) {
|
||||
form.fireEvent(event);
|
||||
}
|
||||
}
|
||||
});
|
||||
add(form);
|
||||
}
|
||||
|
||||
widget.addDoubleClickHandler(new DoubleClickHandler() {
|
||||
|
||||
@Override
|
||||
public void onDoubleClick(DoubleClickEvent event) {
|
||||
EventTarget target = event.getNativeEvent().getEventTarget();
|
||||
Element targetElement = (Element) target.cast();
|
||||
if (targetElement == form.getElement()) {
|
||||
form.fireEvent(event);
|
||||
}
|
||||
}
|
||||
});
|
||||
}
|
||||
}
|
||||
|
|
Loading…
Reference in New Issue