Merge branch 'develop' into dependabot/npm_and_yarn/gui/develop/electron-28.1.3

This commit is contained in:
DJ2LS 2024-01-17 11:53:33 +01:00 committed by GitHub
commit fe4312007c
No known key found for this signature in database
GPG key ID: B5690EEEBB952194
4 changed files with 22 additions and 15 deletions

View file

@ -38,7 +38,6 @@ import { Scatter } from "vue-chartjs";
let count = ref(0);
let grid = null; // DO NOT use ref(null) as proxies GS will break all logic when comparing structures... see https://github.com/gridstack/gridstack.js/issues/2115
let items = ref([]);
let gridEnabledLocal = ref(true);
class gridWidget {
//Contains the vue component
component2;
@ -356,6 +355,7 @@ onMounted(() => {
},
false,
);
setGridEditState();
});
function onChange(event, changeItems) {
// update item position
@ -432,9 +432,15 @@ function remove(widget) {
grid.removeWidget(selector, false);
saveGridLayout();
}
function disableGrid() {
gridEnabledLocal.value = !gridEnabledLocal.value
if (gridEnabledLocal.value)
function toggleGridEdit() {
//Toggle setting
settingsStore.local.grid_enabled = !settingsStore.local.grid_enabled
setGridEditState();
}
function setGridEditState()
{
//Apply grid state setting (allows/disallows moving, resizing, showing remove icon)
if (settingsStore.local.grid_enabled)
grid.enable();
else
grid.disable();
@ -487,7 +493,7 @@ function quickfill() {
<button
@click="remove(w)"
class="btn-close grid-stack-floaty-btn"
:class="gridEnabledLocal === true ? 'visible':'invisible'"
:class="settingsStore.local.grid_enabled === true ? 'visible':'invisible'"
></button>
<component :is="w.component2" />
</div>
@ -506,12 +512,13 @@ function quickfill() {
<div class="offcanvas-header">
<h5 class="offcanvas-title" id="offcanvasGridItemsLabel">
Manage grid widgets &nbsp;<button
class="btn btn-sm btn-outline-info"
class="btn btn-sm"
:class="settingsStore.local.grid_enabled == true ? 'btn-outline-success' : 'btn-outline-danger'"
type="button"
@click="disableGrid"
@click="toggleGridEdit"
title="Lock/unloack changes to grid"
>
<i class="bi" :class="gridEnabledLocal == true ? 'bi-unlock-fill' : 'bi-lock-fill'"></i>
<i class="bi" :class="settingsStore.local.grid_enabled == true ? 'bi-unlock-fill' : 'bi-lock-fill'"></i>
</button>&nbsp;
</h5>

View file

@ -21,6 +21,7 @@ nconf.defaults({
enable_sys_notification: false,
grid_layout: "[]",
grid_preset: "[]",
grid_enabled: true,
},
});
@ -36,6 +37,7 @@ export const settingsStore = reactive({
enable_sys_notification: false,
grid_layout: "[]",
grid_preset: "[]",
grid_enabled: true,
},
remote: {
AUDIO: {

View file

@ -32,7 +32,7 @@ class FrameHandler():
call_with_ssid = self.config['STATION']['mycall'] + "-" + str(self.config['STATION']['myssid'])
ft = self.details['frame']['frame_type']
print(self.details)
valid = False
# Check for callsign checksum
if ft in ['ARQ_SESSION_OPEN', 'ARQ_SESSION_OPEN_ACK', 'PING', 'PING_ACK']:
valid, mycallsign = helpers.check_callsign(
@ -59,8 +59,6 @@ class FrameHandler():
return valid
def should_respond(self):
return self.is_frame_for_me()

View file

@ -118,7 +118,6 @@ class StateManager:
self.arq_irs_sessions[session.id] = session
return True
def check_if_running_arq_session(self, irs=False):
sessions = self.arq_irs_sessions if irs else self.arq_iss_sessions
@ -130,11 +129,12 @@ class StateManager:
self.remove_arq_irs_session(session_id)
else:
self.remove_arq_iss_session(session_id)
# check if ongoing sessions available
if sessions[session_id].state.name not in ['ENDED', 'ABORTED', 'FAILED']:
# check again if session id exists in session because of cleanup
if session_id in sessions and sessions[session_id].state.name not in ['ENDED', 'ABORTED', 'FAILED']:
print(f"[State Manager] running session...[{session_id}]")
return True
return False
return False
def get_arq_iss_session(self, id):