Warning, /network/smb4k/plasmoid/package/contents/ui/PopupDialog.qml is written in an unsupported language. File is not indexed.

0001 /*
0002     SPDX-FileCopyrightText: 2017-2023 Alexander Reinholdt <alexander.reinholdt@kdemail.net>
0003 
0004     SPDX-License-Identifier: GPL-2.0-or-later
0005 */
0006 
0007 import QtQuick 2.3
0008 import QtQuick.Layouts 1.3
0009 import org.kde.plasma.core 2.0 as PlasmaCore
0010 import org.kde.plasma.plasmoid 2.0
0011 import org.kde.plasma.components 2.0 as PlasmaComponents
0012 
0013 FocusScope {
0014   id: popupDialog
0015   anchors.fill: parent
0016   
0017   ColumnLayout {
0018     anchors.fill: parent
0019     
0020     //
0021     // Tab bar
0022     //
0023     PlasmaComponents.TabBar {
0024       id: tabBar
0025       
0026       Layout.maximumWidth: parent.width
0027       Layout.fillWidth: true
0028       Layout.fillHeight: false
0029           
0030       PlasmaComponents.TabButton {
0031         id: browserTabButton
0032         text: i18n("Network Neighborhood")
0033         iconSource: "network-workgroup-symbolic"
0034         tab: networkBrowserPage
0035       }
0036           
0037       PlasmaComponents.TabButton {
0038         id: sharesTabButton
0039         text: i18n("Mounted Shares")
0040         iconSource: "folder-network-symbolic"
0041         tab: sharesViewPage
0042       }
0043         
0044       PlasmaComponents.TabButton {
0045         id: bookmarkTabButton
0046         text: i18n("Bookmarks")
0047         iconSource: "bookmarks"
0048         tab: bookmarksPage
0049       }
0050         
0051       PlasmaComponents.TabButton {
0052         id: profilesTabButton
0053         text: i18n("Profiles")
0054         iconSource: "format-list-unordered"
0055         tab: profilesPage
0056       }
0057       
0058       PlasmaComponents.TabButton {
0059         id: configurationTabButton
0060         text: i18n("Configuration")
0061         iconSource: "configure"
0062         tab: configurationPage
0063       }
0064     }
0065       
0066     //
0067     // Tab group
0068     //
0069     PlasmaComponents.TabGroup {
0070       id: tabGroup
0071       
0072       Layout.fillWidth: true
0073       Layout.fillHeight: true
0074       
0075       currentTab: networkBrowserPage
0076         
0077       NetworkBrowserPage {
0078         id: networkBrowserPage
0079       }
0080           
0081       SharesViewPage {
0082         id: sharesViewPage
0083       }
0084           
0085       BookmarksPage {
0086         id: bookmarksPage
0087       }
0088           
0089       ProfilesPage {
0090         id: profilesPage
0091       }
0092       
0093       ConfigurationPage {
0094         id: configurationPage
0095       }
0096     }
0097     
0098 //     //
0099 //     // Information
0100 //     //
0101 //     PlasmaComponents.Label {
0102 //       id: infoLabel
0103 //       
0104 //       Layout.fillWidth: true
0105 //       Layout.fillHeight: false
0106 //       
0107 //       color: "red"
0108 //       text: "lalala"
0109 //     }
0110   }
0111   
0112   //
0113   // Connections
0114   //
0115   Connections {
0116     target: iface
0117     function onBusy() { busy() }
0118     function onIdle() { idle() }
0119   }
0120   
0121   //
0122   // Busy indicator
0123   //
0124   PlasmaComponents.BusyIndicator {
0125     id: busyIndicator
0126     running: false
0127     visible: false
0128     anchors.verticalCenter: parent.verticalCenter
0129     anchors.horizontalCenter: parent.horizontalCenter
0130   }
0131   
0132   //
0133   // Functions
0134   //
0135   function busy() {
0136     busyIndicator.visible = true
0137     busyIndicator.running = true
0138   }
0139   
0140   function idle() {
0141     busyIndicator.visible = false
0142     busyIndicator.running = false
0143   }
0144 }