test locale bindings

This commit is contained in:
Sebastian Kügler 2013-04-12 02:06:42 +02:00
parent f66a3608c0
commit 74febc2219
3 changed files with 29 additions and 2 deletions

View File

@ -44,8 +44,12 @@ Item {
id: tx
text: "Test Dialog"
}
PlasmaComponents.TextArea {
LocaleItem {
id: localeItem
anchors { left: parent.left; right: parent.right; top: tx.bottom; }
}
PlasmaComponents.TextArea {
anchors { left: parent.left; right: parent.right; top: localeItem.bottom; }
width: parent.width
height: 80
}

View File

@ -0,0 +1,24 @@
import QtQuick 2.0
import org.kde.plasma.components 2.0 as PlasmaComponents
import org.kde.locale 2.0
Item {
width: childrenRect.width
height: childrenRect.height
Locale {
id: locale
}
Column {
PlasmaComponents.Label {
text: "Locale Time Bindings"
}
PlasmaComponents.Label {
text: locale.formatLocaleTime( "11:12:13", Locale.TimeWithoutAmPm|Locale.TimeWithoutSeconds )
}
PlasmaComponents.Label {
text: locale.formatDateTime("2013-04-12", Locale.ShortDate ,Locale.Seconds )
}
}
}

View File

@ -85,7 +85,6 @@ PlasmaComponents.Page {
menuLoader.item.open(0, height);
}
}
}
}