remove old test panel

This commit is contained in:
Marco Martin 2013-08-19 17:08:03 +02:00
parent 9aba51f7a3
commit 5e376058c8
4 changed files with 0 additions and 136 deletions

View File

@ -91,5 +91,4 @@ target_link_libraries(plasma-shell
install(TARGETS plasma-shell ${INSTALL_TARGETS_DEFAULT_ARGS})
add_subdirectory(applets)
add_subdirectory(containments)
add_subdirectory(qmlpackages)

View File

@ -1,2 +0,0 @@
plasma_install_package(testpanel org.kde.panel plasma/plasmoids containment)

View File

@ -1,103 +0,0 @@
/*
* Copyright 2013 Marco Martin <mart@kde.org>
*
* This program is free software; you can redistribute it and/or modify
* it under the terms of the GNU General Public License as published by
* the Free Software Foundation; either version 2 of the License, or
* (at your option) any later version.
*
* This program is distributed in the hope that it will be useful,
* but WITHOUT ANY WARRANTY; without even the implied warranty of
* MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the
* GNU General Public License for more details.
*
* You should have received a copy of the GNU General Public License
* along with this program; if not, write to the Free Software
* Foundation, Inc., 51 Franklin Street, Fifth Floor, Boston, MA 2.010-1301, USA.
*/
import QtQuick 2.1
import QtQuick.Layouts 1.0
import org.kde.plasma.core 2.0 as PlasmaCore
import org.kde.plasma.components 2.0 as PlasmaComponents
Item {
id: root
width: 640
height: 48
property Item toolBox
Connections {
target: plasmoid
onAppletAdded: {
var container = appletContainerComponent.createObject((plasmoid.formFactor == PlasmaCore.Types.Vertical) ? column : row)
print("Applet added in test panel: " + applet)
applet.parent = container
container.applet = applet
applet.anchors.fill = applet.parent
applet.visible = true
container.visible = true
}
onFormFactorChanged: {
if (plasmoid.formFactor == PlasmaCore.Types.Vertical) {
for (var container in row.children) {
var item = row.children[0];
item.parent = column
item.width = column.width
}
} else {
for (var container in column.children) {
var item = column.children[0];
item.parent = row
item.height = row.height
}
}
}
}
Component {
id: appletContainerComponent
Item {
id: container
visible: false
Layout.preferredWidth: Math.min(root.width, root.height)
Layout.preferredHeight: Layout.preferredWidth
property Item applet
PlasmaComponents.BusyIndicator {
z: 1000
visible: applet && applet.length > 0 && applet[0].busy
running: visible
anchors.centerIn: parent
}
}
}
RowLayout {
id: row
anchors {
top: parent.top
bottom: parent.bottom
left: parent.left
}
}
ColumnLayout {
id: column
anchors {
top: parent.top
left: parent.left
right: parent.right
}
}
Component.onCompleted: {
print("Test Panel loaded")
print(plasmoid)
}
}

View File

@ -1,30 +0,0 @@
[Desktop Entry]
Encoding=UTF-8
Keywords=
Name=Panel Test
Name[de]=Kontrollleistentest
Name[es]=Prueba de panel
Name[fi]=Paneelitesti
Name[fr]=Test du panneau
Name[mr]=
Name[nl]=Test van paneel
Name[pt]=Teste de Painel
Name[pt_BR]=Teste de painel
Name[sk]=Test panelu
Name[sv]=Paneltest
Name[uk]=Тестування панелі
Name[x-test]=xxPanel Testxx
Type=Service
X-KDE-ServiceTypes=Plasma/Applet,Plasma/Containment
X-Plasma-API=declarativeappletscript
X-KDE-ParentApp=
X-KDE-PluginInfo-Author=Marco Martin
X-KDE-PluginInfo-Category=
X-KDE-PluginInfo-Email=mart@kde.org
X-KDE-PluginInfo-License=GPLv2+
X-KDE-PluginInfo-Name=org.kde.panel
X-KDE-PluginInfo-Version=
X-KDE-PluginInfo-Website=
X-Plasma-MainScript=ui/main.qml
X-Plasma-ContainmentType=Panel