mirror of
https://github.com/zhuzichu520/FluentUI.git
synced 2024-10-31 00:07:36 +08:00
update
This commit is contained in:
parent
03771cd7c9
commit
26ad581072
@ -223,7 +223,7 @@ FluScrollablePage{
|
||||
FluMenuItem{
|
||||
text:"Menu_4"
|
||||
onClicked: {
|
||||
console.debug(parent.height)
|
||||
|
||||
}
|
||||
}
|
||||
}
|
||||
@ -241,20 +241,18 @@ FluScrollablePage{
|
||||
Layout.topMargin: -1
|
||||
code:'FluDropDownButton{
|
||||
text:"DropDownButton"
|
||||
items:[
|
||||
FluMenuItem{
|
||||
text:"Menu_1"
|
||||
},
|
||||
FluMenuItem{
|
||||
text:"Menu_2"
|
||||
},
|
||||
FluMenuItem{
|
||||
text:"Menu_3"
|
||||
},
|
||||
FluMenuItem{
|
||||
text:"Menu_4"
|
||||
}
|
||||
]
|
||||
FluMenuItem{
|
||||
text:"Menu_1"
|
||||
},
|
||||
FluMenuItem{
|
||||
text:"Menu_2"
|
||||
},
|
||||
FluMenuItem{
|
||||
text:"Menu_3"
|
||||
},
|
||||
FluMenuItem{
|
||||
text:"Menu_4"
|
||||
}
|
||||
}'
|
||||
}
|
||||
|
||||
|
@ -22,6 +22,10 @@ FluTextBox{
|
||||
id:control_popup
|
||||
y:control.height
|
||||
focus: false
|
||||
// modal: true
|
||||
// Overlay.modal: Item{}
|
||||
|
||||
padding: 0
|
||||
enter: Transition {
|
||||
NumberAnimation {
|
||||
property: "opacity"
|
||||
@ -30,15 +34,12 @@ FluTextBox{
|
||||
duration: FluTheme.enableAnimation ? 83 : 0
|
||||
}
|
||||
}
|
||||
background: FluRectangle{
|
||||
id:container
|
||||
width: control.width
|
||||
contentItem: FluRectangle{
|
||||
radius: [4,4,4,4]
|
||||
FluShadow{
|
||||
radius: 4
|
||||
}
|
||||
color: FluTheme.dark ? Qt.rgba(51/255,48/255,48/255,1) : Qt.rgba(248/255,250/255,253/255,1)
|
||||
height: 38*Math.min(Math.max(list_view.count,1),8)
|
||||
ListView{
|
||||
id:list_view
|
||||
anchors.fill: parent
|
||||
@ -86,6 +87,11 @@ FluTextBox{
|
||||
}
|
||||
}
|
||||
}
|
||||
background: Item{
|
||||
id:container
|
||||
implicitWidth: control.width
|
||||
implicitHeight: 38*Math.min(Math.max(list_view.count,1),8)
|
||||
}
|
||||
}
|
||||
onTextChanged: {
|
||||
loadData()
|
||||
|
@ -75,7 +75,7 @@ Button {
|
||||
color: control.textColor
|
||||
}
|
||||
onClicked: {
|
||||
if(items && menu.count !==0){
|
||||
if(menu.count !==0){
|
||||
var pos = control.mapToItem(null, 0, 0)
|
||||
var containerHeight = menu.count*36
|
||||
if(window.height>pos.y+control.height+containerHeight){
|
||||
|
@ -74,14 +74,11 @@ T.ScrollBar {
|
||||
}
|
||||
,Transition {
|
||||
to: "show"
|
||||
SequentialAnimation{
|
||||
PauseAnimation { duration: 100 }
|
||||
NumberAnimation {
|
||||
target: rect_bar
|
||||
properties: vertical ? "width" : "height"
|
||||
duration: 167
|
||||
easing.type: Easing.OutCubic
|
||||
}
|
||||
NumberAnimation {
|
||||
target: rect_bar
|
||||
properties: vertical ? "width" : "height"
|
||||
duration: 167
|
||||
easing.type: Easing.OutCubic
|
||||
}
|
||||
}
|
||||
]
|
||||
|
Loading…
Reference in New Issue
Block a user