2021-12-23 16:02:41 +00:00
|
|
|
// SPDX-FileCopyrightText: 2014-2019 Marco Martin <mart@kde.org>
|
|
|
|
|
// SPDX-FileCopyrightText: 2015-2021 Bhushan Shah <bshah@kde.org>
|
|
|
|
|
// SPDX-FileCopyrightText: 2021 Devin Lin <devin@kde.org>
|
|
|
|
|
// SPDX-License-Identifier: GPL-2.0-or-later
|
|
|
|
|
|
2021-01-27 13:20:15 +00:00
|
|
|
let topFound = false
|
|
|
|
|
let bottomFound = false
|
|
|
|
|
|
|
|
|
|
for (let i in panels()) {
|
|
|
|
|
print(panels()[i].type)
|
2023-03-05 21:02:33 +00:00
|
|
|
if (panels()[i].type === "org.kde.plasma.mobile.panel") {
|
2021-01-27 13:20:15 +00:00
|
|
|
topFound = true;
|
2023-03-05 21:02:33 +00:00
|
|
|
} else if (panels()[i].type === "org.kde.plasma.mobile.taskpanel") {
|
2021-01-28 10:05:33 +00:00
|
|
|
bottomFound = true;
|
2021-01-27 13:20:15 +00:00
|
|
|
}
|
|
|
|
|
}
|
|
|
|
|
|
|
|
|
|
if (!topFound) {
|
2021-02-26 03:56:25 +00:00
|
|
|
// keep widget list synced with the layout.js
|
2024-07-15 21:07:26 +00:00
|
|
|
loadTemplate("org.kde.plasma.mobile.defaultStatusBar");
|
2021-01-27 13:20:15 +00:00
|
|
|
}
|
|
|
|
|
if (!bottomFound) {
|
2024-07-15 21:07:26 +00:00
|
|
|
loadTemplate("org.kde.plasma.mobile.defaultNavigationPanel");
|
2021-01-27 13:20:15 +00:00
|
|
|
}
|