Changeset View
Changeset View
Standalone View
Standalone View
applets/notifications/package/contents/ui/NotificationItem.qml
Show All 13 Lines | |||||
14 | * | 14 | * | ||
15 | * You should have received a copy of the GNU Library General Public | 15 | * You should have received a copy of the GNU Library General Public | ||
16 | * License along with this program; if not, write to the | 16 | * License along with this program; if not, write to the | ||
17 | * Free Software Foundation, Inc., | 17 | * Free Software Foundation, Inc., | ||
18 | * 51 Franklin Street, Fifth Floor, Boston, MA 02110-1301, USA. | 18 | * 51 Franklin Street, Fifth Floor, Boston, MA 02110-1301, USA. | ||
19 | */ | 19 | */ | ||
20 | 20 | | |||
21 | import QtQuick 2.5 | 21 | import QtQuick 2.5 | ||
22 | import QtQuick.Controls 2.5 as QQC2 | ||||
22 | import QtQuick.Layouts 1.1 | 23 | import QtQuick.Layouts 1.1 | ||
23 | import QtQuick.Controls.Private 1.0 | 24 | import QtQuick.Controls.Private 1.0 | ||
24 | 25 | | |||
25 | import org.kde.plasma.core 2.0 as PlasmaCore | 26 | import org.kde.plasma.core 2.0 as PlasmaCore | ||
26 | import org.kde.plasma.components 2.0 as PlasmaComponents | 27 | import org.kde.plasma.components 2.0 as PlasmaComponents | ||
27 | import org.kde.plasma.extras 2.0 as PlasmaExtras | 28 | import org.kde.plasma.extras 2.0 as PlasmaExtras | ||
28 | import org.kde.kquickcontrolsaddons 2.0 | 29 | import org.kde.kquickcontrolsaddons 2.0 | ||
29 | 30 | | |||
▲ Show 20 Lines • Show All 192 Lines • ▼ Show 20 Line(s) | 222 | onClicked: { | |||
222 | if (notificationItem.hasConfigureAction) { | 223 | if (notificationItem.hasConfigureAction) { | ||
223 | notificationItem.action("settings"); | 224 | notificationItem.action("settings"); | ||
224 | } else { | 225 | } else { | ||
225 | configure() | 226 | configure() | ||
226 | } | 227 | } | ||
227 | } | 228 | } | ||
228 | } | 229 | } | ||
229 | 230 | | |||
230 | PlasmaComponents.ToolButton { | 231 | QQC2.RoundButton { | ||
231 | id: closeButton | 232 | id: closeButton | ||
232 | 233 | implicitWidth: units.iconSizes.smallMedium | |||
233 | width: units.iconSizes.smallMedium | 234 | implicitHeight: implicitHeight | ||
234 | height: width | | |||
235 | flat: compact | | |||
236 | | ||||
237 | iconSource: "window-close" | | |||
238 | 235 | | |||
239 | onClicked: close() | 236 | onClicked: close() | ||
240 | } | | |||
241 | 237 | | |||
238 | PlasmaCore.IconItem { | ||||
239 | anchors.fill: parent | ||||
240 | source: "window-close" | ||||
241 | } | ||||
242 | } | ||||
242 | } | 243 | } | ||
243 | 244 | | |||
244 | RowLayout { | 245 | RowLayout { | ||
245 | id: bottomPart | 246 | id: bottomPart | ||
246 | Layout.alignment: Qt.AlignTop | 247 | Layout.alignment: Qt.AlignTop | ||
247 | spacing: units.smallSpacing | 248 | spacing: units.smallSpacing | ||
248 | 249 | | |||
249 | // Force the whole thing to collapse if the children are invisible | 250 | // Force the whole thing to collapse if the children are invisible | ||
▲ Show 20 Lines • Show All 169 Lines • Show Last 20 Lines |