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 204 Lines • ▼ Show 20 Line(s) | 234 | onClicked: { | |||
234 | if (notificationItem.hasConfigureAction) { | 235 | if (notificationItem.hasConfigureAction) { | ||
235 | notificationItem.action("settings"); | 236 | notificationItem.action("settings"); | ||
236 | } else { | 237 | } else { | ||
237 | configure() | 238 | configure() | ||
238 | } | 239 | } | ||
239 | } | 240 | } | ||
240 | } | 241 | } | ||
241 | 242 | | |||
242 | PlasmaComponents.ToolButton { | 243 | QQC2.RoundButton { | ||
243 | id: closeButton | 244 | id: closeButton | ||
244 | 245 | implicitWidth: units.iconSizes.smallMedium | |||
245 | width: units.iconSizes.smallMedium | 246 | implicitHeight: implicitWidth | ||
246 | height: width | | |||
247 | flat: compact | | |||
248 | | ||||
249 | iconSource: "window-close" | | |||
250 | 247 | | |||
251 | onClicked: close() | 248 | onClicked: close() | ||
252 | } | | |||
253 | 249 | | |||
250 | PlasmaCore.IconItem { | ||||
251 | anchors.fill: parent | ||||
252 | source: "window-close" | ||||
253 | } | ||||
254 | } | ||||
254 | } | 255 | } | ||
255 | 256 | | |||
256 | RowLayout { | 257 | RowLayout { | ||
257 | id: bottomPart | 258 | id: bottomPart | ||
258 | Layout.alignment: Qt.AlignTop | 259 | Layout.alignment: Qt.AlignTop | ||
259 | spacing: units.smallSpacing | 260 | spacing: units.smallSpacing | ||
260 | 261 | | |||
261 | // Force the whole thing to collapse if the children are invisible | 262 | // Force the whole thing to collapse if the children are invisible | ||
▲ Show 20 Lines • Show All 169 Lines • Show Last 20 Lines |