mirror of
https://github.com/webbukkit/dynmap.git
synced 2024-11-27 04:35:14 +01:00
Clean up init of coord widget
This commit is contained in:
parent
15cf132ada
commit
80f8aca6f7
1
DynmapCore/.gitignore
vendored
1
DynmapCore/.gitignore
vendored
@ -1 +1,2 @@
|
||||
/build/
|
||||
/bin/
|
@ -2288,8 +2288,9 @@ public class DynmapCore implements DynmapCommonAPI {
|
||||
else { // First time, delete old external texture pack
|
||||
deleteDirectory(new File(df, "texturepacks/standard"));
|
||||
}
|
||||
String curver = this.getDynmapCoreVersion();
|
||||
/* If matched, we're good */
|
||||
if (prevver.equals(this.getDynmapCoreVersion())) {
|
||||
if (prevver.equals(curver) && (!curver.endsWith(("-Dev")))) {
|
||||
return;
|
||||
}
|
||||
/* Get deleted file list */
|
||||
|
@ -6,21 +6,21 @@ componentconstructors['coord'] = function(dynmap, configuration) {
|
||||
chunkfield: $('<span/>'),
|
||||
|
||||
onAdd: function(map) {
|
||||
if(configuration.hidey)
|
||||
if(configuration.hidey)
|
||||
this._container = L.DomUtil.create('div', 'coord-control coord-control-noy');
|
||||
else
|
||||
this._container = L.DomUtil.create('div', 'coord-control');
|
||||
this._map = map;
|
||||
$('<span/>').addClass('coord-control-label').text((configuration.label || 'x,y,z') + ': ').appendTo(this._container);
|
||||
$('<br/>').appendTo(this._container);
|
||||
this.valfield.addClass('coord-control-value').text('').appendTo(this._container);
|
||||
this.valfield.addClass('coord-control-value').text(configuration.hidey ? '---,---' : '---,---,---').appendTo(this._container);
|
||||
if(configuration['show-mcr']) {
|
||||
$('<br/>').appendTo(this._container);
|
||||
this.mcrfield.addClass('coord-control-value').text('').appendTo(this._container);
|
||||
this.mcrfield.addClass('coord-control-value').text('--------').appendTo(this._container);
|
||||
}
|
||||
if(configuration['show-chunk']) {
|
||||
$('<br/>').appendTo(this._container);
|
||||
this.chunkfield.addClass('coord-control-value').text('').appendTo(this._container);
|
||||
this.chunkfield.addClass('coord-control-value').text('Chunk: ---,---').appendTo(this._container);
|
||||
}
|
||||
this._update();
|
||||
return this.getContainer();
|
||||
|
Loading…
Reference in New Issue
Block a user