mirror of
https://thingvellir.net/git/overte
synced 2025-03-27 23:52:03 +01:00
display helper text when server stopped
This commit is contained in:
parent
a30d7ee697
commit
919305e759
3 changed files with 17 additions and 0 deletions
|
@ -203,6 +203,7 @@ header {
|
|||
margin-left: @title-margin-left;
|
||||
|
||||
#go-server-button {
|
||||
float: left;
|
||||
box-shadow: 0px 2px 3px rgba(0, 0, 0, 0.5);
|
||||
cursor: pointer;
|
||||
border: none;
|
||||
|
@ -220,6 +221,12 @@ header {
|
|||
width: 50px;
|
||||
}
|
||||
}
|
||||
|
||||
#server-stopped-text {
|
||||
float: left;
|
||||
margin: 20px 0px 0px 20px;
|
||||
color: red;
|
||||
}
|
||||
}
|
||||
}
|
||||
}
|
||||
|
|
|
@ -76,6 +76,9 @@
|
|||
<button id="go-server-button">
|
||||
<img src="images/go-hmd.svg" />
|
||||
</button>
|
||||
<div id="server-stopped-text">
|
||||
<span>Server stopped<br>Click "Restart"</span>
|
||||
</div>
|
||||
</div>
|
||||
</div>
|
||||
<div id="manage-server">
|
||||
|
|
|
@ -56,6 +56,7 @@ $(function() {
|
|||
var sendingGroup = arg;
|
||||
var stopButton = $('#manage-server #stop');
|
||||
var goButton = $('#go-server-button');
|
||||
var serverStopped = $('#server-stopped-text');
|
||||
|
||||
switch (sendingGroup.state) {
|
||||
case HFProcess.ProcessGroupStates.STOPPED:
|
||||
|
@ -66,6 +67,9 @@ $(function() {
|
|||
// disable the go button
|
||||
goButton.addClass('disabled');
|
||||
|
||||
// show the server stopped text
|
||||
serverStopped.show();
|
||||
|
||||
break;
|
||||
case HFProcess.ProcessGroupStates.STARTED:
|
||||
// if the process group is going, the stop button should be active
|
||||
|
@ -74,6 +78,9 @@ $(function() {
|
|||
// enable the go button
|
||||
goButton.removeClass('disabled');
|
||||
|
||||
// hide the server stopped text
|
||||
serverStopped.hide();
|
||||
|
||||
break;
|
||||
}
|
||||
}
|
||||
|
|
Loading…
Reference in a new issue