feat(Form/ActionBar): use style file

This commit is contained in:
Ronan Abhamon 2016-09-27 17:34:19 +02:00
parent 2509d01cb6
commit bcf304f1b4
5 changed files with 26 additions and 12 deletions

View file

@ -62,6 +62,7 @@
<file>ui/modules/Linphone/Styles/DialogStyle.qml</file>
<file>ui/modules/Linphone/Styles/ForceScrollBarStyle.qml</file>
<file>ui/modules/Linphone/Styles/Form/AbstractTextButtonStyle.qml</file>
<file>ui/modules/Linphone/Styles/Form/ActionBarStyle.qml</file>
<file>ui/modules/Linphone/Styles/Form/ExclusiveButtonsStyle.qml</file>
<file>ui/modules/Linphone/Styles/Form/SmallButtonStyle.qml</file>
<file>ui/modules/Linphone/Styles/Form/TextButtonAStyle.qml</file>

View file

@ -1,10 +1,13 @@
import QtQuick 2.7
import Linphone.Styles 1.0
// ===================================================================
// Bar which can contains ActionButtons.
// ===================================================================
Row {
property int iconSize
spacing: 8
property int iconSize
spacing: ActionBarStyle.spacing
}

View file

@ -8,16 +8,19 @@ import Linphone 1.0
// ===================================================================
Button {
property int iconSize
property alias icon: icon.icon
property alias icon: icon.icon
property int iconSize
// Ugly hack, use current size, ActionBar size,
// or other parent height.
height: iconSize || parent.iconSize || parent.height
width: iconSize || parent.iconSize || parent.height
flat: true
Icon {
anchors.fill: parent
id: icon
}
// Ugly hack, use current size, ActionBar size,
// or other parent height.
height: iconSize || parent.iconSize || parent.height
width: iconSize || parent.iconSize || parent.height
Icon {
id: icon
anchors.fill: parent
}
}

View file

@ -0,0 +1,6 @@
pragma Singleton
import QtQuick 2.7
QtObject {
property int spacing: 8
}

View file

@ -12,6 +12,7 @@ singleton SearchBoxStyle 1.0 SearchBoxStyle.qml
singleton TimelineStyle 1.0 TimelineStyle.qml
singleton AbstractTextButtonStyle 1.0 Form/AbstractTextButtonStyle.qml
singleton ActionBarStyle 1.0 Form/ActionBarStyle.qml
singleton ExclusiveButtonsStyle 1.0 Form/ExclusiveButtonsStyle.qml
singleton SmallButtonStyle 1.0 Form/SmallButtonStyle.qml
singleton TextButtonAStyle 1.0 Form/TextButtonAStyle.qml