|
|
@ -9,6 +9,7 @@ import java.util.HashMap; |
|
|
|
import java.util.Map; |
|
|
|
import java.util.Map; |
|
|
|
|
|
|
|
|
|
|
|
import com.fr.base.FRContext; |
|
|
|
import com.fr.base.FRContext; |
|
|
|
|
|
|
|
import com.fr.base.ScreenResolution; |
|
|
|
import com.fr.base.chart.BaseChart; |
|
|
|
import com.fr.base.chart.BaseChart; |
|
|
|
import com.fr.base.chart.BaseChartCollection; |
|
|
|
import com.fr.base.chart.BaseChartCollection; |
|
|
|
import com.fr.base.chart.BasePlot; |
|
|
|
import com.fr.base.chart.BasePlot; |
|
|
@ -114,10 +115,11 @@ public class PolyUtils { |
|
|
|
AddedData addedData = designer.getAddedData(); |
|
|
|
AddedData addedData = designer.getAddedData(); |
|
|
|
for (int count = addedData.getAddedCount() - 1; count >= 0; count--) { |
|
|
|
for (int count = addedData.getAddedCount() - 1; count >= 0; count--) { |
|
|
|
BlockCreator creator = addedData.getAddedAt(count); |
|
|
|
BlockCreator creator = addedData.getAddedAt(count); |
|
|
|
int cx = creator.getX(); |
|
|
|
float times = (float) designer.getResolution()/ScreenResolution.getScreenResolution(); |
|
|
|
int cy = creator.getY(); |
|
|
|
int cx = (int) (creator.getX() * times); |
|
|
|
int cw = creator.getWidth(); |
|
|
|
int cy = (int) (creator.getY() * times); |
|
|
|
int ch = creator.getHeight(); |
|
|
|
int cw = (int) (creator.getWidth() * times); |
|
|
|
|
|
|
|
int ch = (int) (creator.getHeight() * times); |
|
|
|
if (x >= cx && x <= (cx + cw)) { |
|
|
|
if (x >= cx && x <= (cx + cw)) { |
|
|
|
if(y >= cy && y <= (cy + ch)) { |
|
|
|
if(y >= cy && y <= (cy + ch)) { |
|
|
|
return creator; |
|
|
|
return creator; |
|
|
|