Commit 2eb7a48c authored by duminil's avatar duminil
Browse files

RegionChooser: Cleaning up

parent 29d11660
......@@ -70,7 +70,7 @@ public void processJob(Geometry poly, String productName, JSObject novaFactoryOp
@Override
public void jobStatusChanged(JobStatusEvent event) {
JobStatus status = (JobStatus) event.getSource();
System.out.println(status);
// System.out.println(status);
if (status == JobStatus.LOCAL) {
novaFactoryOpenLayer.call("updateStatus", "REQUEST HAS BEEN PREPARED");
} else if (status == JobStatus.SENT) {
......
......@@ -97,13 +97,16 @@ protected Integer call() throws Exception {
public void extractZIPtoGML(String zipFilename) throws IOException {
ZipFile zipFile = new ZipFile(zipFilename);
Enumeration<? extends ZipEntry> entries = zipFile.entries();
String userName = System.getProperty("user.name");
while (entries.hasMoreElements()) {
ZipEntry ze = entries.nextElement();
if (ze.getName().toLowerCase().contains("gml")) {
File extractedCityGML = selectSaveFileWithDialog(null, ze.getName(), "");
String zeName = ze.getName();
if (zeName.toLowerCase().contains("gml")) {
File extractedCityGML = selectSaveFileWithDialog(null,
zeName.replace("_GML.", ".").replace(userName, "novaFACTORY"), "");
if (extractedCityGML != null) {
InputStream cityGMLInputStream = zipFile.getInputStream(ze);
System.out.println("Extract zipFile " + zipFilename + " to " + extractedCityGML);
// System.out.println("Extract zipFile " + zipFilename + " to " + extractedCityGML);
FileOutputStream fos = new FileOutputStream(extractedCityGML);
byte[] bytes = new byte[1024];
int length;
......
<html>
<head>
<meta http-equiv="Content-Type" content="text/html;charset=ISO-8859-1">
<meta name="viewport" content="initial-scale=1.0, user-scalable=no" />
<title> Simstadt Region Chooser </title>
<meta name="keywords" content="polygon,creator,google map,v3,draw,paint">
<meta name="description" content="Google Map V3 Polygon Creator for Simstadt">
<link rel="stylesheet" type="text/css" href="style/style.css">
<meta http-equiv="Content-Type" content="text/html;charset=ISO-8859-1">
<meta name="viewport" content="initial-scale=1.0, user-scalable=no" />
<title> Simstadt Region Chooser </title>
<meta name="keywords" content="polygon,creator,google map,v3,draw,paint">
<meta name="description" content="Google Map V3 Polygon Creator for Simstadt">
<link rel="stylesheet" type="text/css" href="style/style.css">
<script type="text/javascript" src="script/proj4.js"></script>
<script type="text/javascript" src="script/jquery-1.4.2.min.js"></script>
<!-- <link rel="stylesheet" href="http://openlayers.org/en/v3.4.0/css/ol.css" type="text/css">
......@@ -17,27 +17,23 @@
<!-- <script src="ol-debug.js" type="text/javascript"></script> -->
<script src="script/ol.js" type="text/javascript"></script>
<script src="script/turf.js" type="text/javascript"></script>
</head>
<body>
<div id="header">
<ul>
<li class="title">
Simstadt Region Chooser
</li>
</ul>
<p>
<span class="instruction">Demo Instruction:</span>
Left click on the map to create markers, when last marker meets first marker, it will form a polygon.
</p>
</div>
<div id="map" class="map" tabindex="0"></div>
<div id="side">
<input id="reset" value="Reset" type="button" class="navi" disabled/>
<div id="dataPanel">
</div>
</div>
<script src="script/simstadt_openlayers.js" type="text/javascript"></script>
<div id="header">
<ul>
<li class="title">
Simstadt Region Chooser
</li>
</ul>
</div>
<div id="map" class="map" tabindex="0"></div>
<div id="side">
<div id="dataPanel">
</div>
</div>
<input id="reset" value="Reset" type="button" class="navi" disabled/>
<script src="script/simstadt_openlayers.js" type="text/javascript"></script>
</body>
</html>
//TODO: Add zoom to extent as control
//TODO: Try to leave everything in 4326
//TODO: Add some tiles for offline mode
var reset_btn = $('#reset')[0];
var dataPanel = $('#dataPanel');
......
......@@ -19,8 +19,9 @@ div#header{
div#map{
width:70%;
height:70%;
height:80%;
float:left;
outline: 0;
}
div#side{
width:30%;
......@@ -29,9 +30,14 @@ div#side{
div#dataPanel{
width:90%;
height:50%;
height:80%;
overflow:auto;
border:2px solid #DDDDDD;
font-family: Consolas,monaco,monospace;
font-size: 12px;
box-sizing:border-box;
-moz-box-sizing:border-box;
-webkit-box-sizing:border-box;
}
div#side input{
width:90%;
......
Supports Markdown
0% or .
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment