use of com.extjs.gxt.ui.client.widget.tips.ToolTipConfig in project activityinfo by bedatadriven.
the class IndicatorLinkPage method linkTip.
private ToolTipConfig linkTip(String text) {
ToolTipConfig config = new ToolTipConfig();
config.setText(text);
config.setAnchor("right");
config.setAnchorOffset(0);
config.setShowDelay(0);
return config;
}
use of com.extjs.gxt.ui.client.widget.tips.ToolTipConfig in project activityinfo by bedatadriven.
the class OutOfSyncStatus method createToolTip.
private void createToolTip() {
if (this.tip == null) {
ToolTipConfig config = new ToolTipConfig();
config.setTitle("Out of Sync");
config.setText("You have recently sent an update directly to the server.<br>" + "Your change will not be visible locally until you synchronize.");
config.setShowDelay(1);
this.tip = new ToolTip(this, config);
}
}
use of com.extjs.gxt.ui.client.widget.tips.ToolTipConfig in project activityinfo by bedatadriven.
the class OutOfSyncStatus method createTip.
private ToolTip createTip() {
ToolTipConfig config = new ToolTipConfig();
config.setAnchor("top");
config.setCloseable(false);
config.setText("Your local database is out of sync with the server. Please wait while synchronization " + "completes");
ToolTip tip = new ToolTip();
tip.update(config);
return tip;
}
use of com.extjs.gxt.ui.client.widget.tips.ToolTipConfig in project activityinfo by bedatadriven.
the class IndicatorSection method toolTip.
private ToolTipConfig toolTip(IndicatorDTO indicator) {
if (Strings.isNullOrEmpty(indicator.getDescription())) {
return null;
}
ToolTipConfig tip = new ToolTipConfig();
tip.setDismissDelay(0);
tip.setShowDelay(100);
tip.setText(indicator.getDescription());
return tip;
}
use of com.extjs.gxt.ui.client.widget.tips.ToolTipConfig in project activityinfo by bedatadriven.
the class IndicatorLinkPage method onIndicatorSelectionChanged.
protected void onIndicatorSelectionChanged() {
IndicatorDTO source = sourceIndicatorGrid.getSelectedItem();
IndicatorDTO dest = destIndicatorGrid.getSelectedItem();
if (source == null || dest == null) {
linkButton.disable();
} else if (source.getId() == dest.getId()) {
// indicators should not be linked to themselves.
linkButton.setVisible(true);
linkButton.disable();
ToolTipConfig config = linkTip(I18N.CONSTANTS.indicatorCannotBeLinkedToItself());
linkButtonTip.update(config);
linkButtonTip.show();
} else {
sourceIndicatorGrid.getRowY(source);
destIndicatorGrid.getRowY(dest);
sourceIndicatorGrid.el().getRight(false);
boolean linked = linkGraph.linked(source, dest);
linkButton.enable();
linkButton.toggle(linked);
linkButtonTip.update(linkTip(linked ? I18N.CONSTANTS.clickToUnlink() : I18N.CONSTANTS.clickToLink()));
linkButtonTip.initTarget(linkButton);
linkButtonTip.show();
}
}
Aggregations