added qrv info toast

This commit is contained in:
dj2ls 2022-06-09 21:31:12 +02:00
parent 539b23cf6d
commit a19a6c13c1
4 changed files with 22 additions and 2 deletions

View file

@ -390,7 +390,7 @@ update_chat = function(obj) {
var shortmsg = obj.type;
} else {
var shortmsg = obj.msg;
var maxlength = 40;
var maxlength = 30;
var shortmsg = shortmsg.length > maxlength ? shortmsg.substring(0, maxlength - 3) + "..." : shortmsg;
}

View file

@ -1813,10 +1813,16 @@ ipcRenderer.on('action-show-cq-toast-received', (event, data) => {
// QRV TRANSMITTING
ipcRenderer.on('action-show-qrv-toast-transmitting', (event, data) => {
var toastQRVtransmitting = document.getElementById('toastQRVtransmitting');
var toast = bootstrap.Toast.getOrCreateInstance(toastQRVtransmitting); // Returns a Bootstrap toast instance
toast.show();
});
// QRV RECEIVED
ipcRenderer.on('action-show-qrv-toast-received', (event, data) => {
var toastQRVreceiving = document.getElementById('toastQRVreceiving');
var toast = bootstrap.Toast.getOrCreateInstance(toastQRVreceiving); // Returns a Bootstrap toast instance
toast.show();
});
// BEACON TRANSMITTING

View file

@ -102,6 +102,20 @@
<button type="button" class="btn-close btn-close-white me-2 m-auto" data-bs-dismiss="toast" aria-label="Close"></button>
</div>
</div>
<!-- RECEIVING QRV -->
<div class="toast align-items-center text-white bg-primary border-0" id="toastQRVreceiving" role="alert" aria-live="assertive" aria-atomic="true">
<div class="d-flex">
<div class="toast-body">Receiving a QRV signal!</div>
<button type="button" class="btn-close btn-close-white me-2 m-auto" data-bs-dismiss="toast" aria-label="Close"></button>
</div>
</div>
<!-- TRANSMITTING QRV -->
<div class="toast align-items-center text-white bg-primary border-0" id="toastQRVtransmitting" role="alert" aria-live="assertive" aria-atomic="true">
<div class="d-flex">
<div class="toast-body">Transmitting a QRV signal!</div>
<button type="button" class="btn-close btn-close-white me-2 m-auto" data-bs-dismiss="toast" aria-label="Close"></button>
</div>
</div>
<!-- RECEIVING BEACON -->
<div class="toast align-items-center text-white bg-primary border-0" id="toastBEACONreceiving" role="alert" aria-live="assertive" aria-atomic="true">
<div class="d-flex">

View file

@ -1040,7 +1040,7 @@ class DATA:
# we need to wait until sending "transmitted" state
# gui database is too slow for handling this within 0.001 seconds
# so let's sleep a little
time.sleep(0.1)
time.sleep(0.2)
self.send_data_to_socket_queue(
freedata="tnc-message",
arq="transmission",