[Fwd: Zoom in time too long] [message #255900] |
Fri, 09 May 2008 02:14 |
Eclipse User |
|
|
|
Originally posted by: sneha29.gmail.com
Hi,
Sorry for the incomplete information in previous mail.
In the code sneippet given below,
'root' is an object of draw2d.ScalableLayeredPane.
Thanks,
Sneha
-------- Original Message --------
Subject: Zoom in time too long
Date: Fri, 09 May 2008 11:39:07 +0530
From: sneha <sneha29@gmail.com>
Organization: EclipseCorner
Newsgroups: eclipse.newcomer
Hi,
I have created an RCP application which displays draw2d figures.
However, the zoom in action takes a longer time than the zoom out action.
Following is the code snippet for both the actions:
Zoomin Action:
zoomInAction=new Action() {
public void run() {
logger.debug("Getting current scale...");
double currentScale=root.getScale();
double newScale=currentScale*1.25;
root.setScale(newScale);
}
zoomOutAction=new Action() {
public void run() {
logger.debug("Getting current scale...");
double currentScale=root.getScale();
double newScale=currentScale*0.8;
root.setScale(newScale);
}
As seen above, the code for both the actions is almost the same, except
for the multiplying factor. However the zoom in action is much slower
than the zoom out action.
I am not able to understand the reason for this behavior.
Has anybody come across such problem or is it a known issue?
Any pointers to look for this issue would be of great help.
Thanks,
Sneha
|
|
|
Powered by
FUDForum. Page generated in 0.07735 seconds