Update Chart Viewer
git-svn-id: https://svn.d4science.research-infrastructures.eu/gcube/trunk/portlets/user/tabular-data-resources-widget@101630 82a268e6-3cf1-43bd-a215-b396298e98cf
This commit is contained in:
parent
66b792dbf9
commit
a29dd08952
|
@ -77,6 +77,8 @@ public class ChartViewerPanel extends FramedPanel {
|
|||
private static final int DRAW_WIDTH_INT = 780;
|
||||
private static final int DRAW_HEIGHT_INT = 380;
|
||||
|
||||
private static final int TOOLBAR_HEIGHT = 30;
|
||||
|
||||
private enum Operation {
|
||||
ZOOMIN, ZOOMOUT, MOVE
|
||||
};
|
||||
|
@ -404,7 +406,6 @@ public class ChartViewerPanel extends FramedPanel {
|
|||
}
|
||||
}, MouseUpEvent.getType());
|
||||
|
||||
|
||||
paint.addDomHandler(new MouseWheelHandler() {
|
||||
|
||||
@Override
|
||||
|
@ -414,15 +415,13 @@ public class ChartViewerPanel extends FramedPanel {
|
|||
}
|
||||
}, MouseWheelEvent.getType());
|
||||
|
||||
|
||||
layout.add(toolBar, new VerticalLayoutData(1, 26, new Margins(0)));
|
||||
layout.add(toolBar, new VerticalLayoutData(1, TOOLBAR_HEIGHT,
|
||||
new Margins(0)));
|
||||
|
||||
layout.add(paint, new VerticalLayoutData(1, 1, new Margins(0)));
|
||||
|
||||
}
|
||||
|
||||
|
||||
|
||||
protected void openInNewWindow() {
|
||||
String link;
|
||||
if (test) {
|
||||
|
@ -474,7 +473,7 @@ public class ChartViewerPanel extends FramedPanel {
|
|||
Log.debug("Offset width:" + DRAW_WIDTH_INT + " height:"
|
||||
+ DRAW_HEIGHT_INT);
|
||||
Log.debug("Fit Scale: " + fitScale);
|
||||
Log.debug("Chart Dimension: "+chartDimension);
|
||||
Log.debug("Chart Dimension: " + chartDimension);
|
||||
chartSprite.setScaling(new Scaling(fitScale.getX(), fitScale.getY()));
|
||||
|
||||
chartScale = fitScale.copy();
|
||||
|
@ -537,8 +536,6 @@ public class ChartViewerPanel extends FramedPanel {
|
|||
}
|
||||
}
|
||||
|
||||
|
||||
|
||||
protected void spriteLeave(SpriteOutEvent event) {
|
||||
Event browseEvent = event.getBrowserEvent();
|
||||
Log.debug("Leave Position: " + browseEvent.getClientX() + ", "
|
||||
|
@ -571,9 +568,9 @@ public class ChartViewerPanel extends FramedPanel {
|
|||
}
|
||||
|
||||
protected void spriteMouseWheel(MouseWheelEvent event) {
|
||||
int deltaY=event.getDeltaY();
|
||||
Log.debug("Wheel: "+deltaY);
|
||||
if(deltaY<0){
|
||||
int deltaY = event.getDeltaY();
|
||||
Log.debug("Wheel: " + deltaY);
|
||||
if (deltaY < 0) {
|
||||
zoomIn();
|
||||
} else {
|
||||
zoomOut();
|
||||
|
@ -582,7 +579,6 @@ public class ChartViewerPanel extends FramedPanel {
|
|||
|
||||
}
|
||||
|
||||
|
||||
protected void actionOnChartSpriteWhenMove() {
|
||||
Log.debug("Operation:" + activeOperation);
|
||||
switch (activeOperation) {
|
||||
|
|
Loading…
Reference in New Issue