forked from Public/monero-gui
StandardButton/StandardDropdown QML development
This commit is contained in:
committed by
moneromooo-monero
parent
8295b9dffd
commit
3d5fee0a2f
@@ -27,6 +27,7 @@
|
||||
// THE USE OF THIS SOFTWARE, EVEN IF ADVISED OF THE POSSIBILITY OF SUCH DAMAGE.
|
||||
|
||||
import QtQuick 2.0
|
||||
import "." 1.0
|
||||
|
||||
Item {
|
||||
id: dropdown
|
||||
@@ -175,10 +176,10 @@ Item {
|
||||
anchors.right: col2Text.left
|
||||
anchors.leftMargin: 12 * scaleRatio
|
||||
anchors.rightMargin: column2.length > 0 ? 12 * scaleRatio: 0
|
||||
font.family: "Arial"
|
||||
font.family: Style.fontRegular.name
|
||||
font.bold: true
|
||||
font.pixelSize: 12 * scaleRatio
|
||||
color: "#FFFFFF"
|
||||
font.pixelSize: 14 * scaleRatio
|
||||
color: itemArea.containsMouse || index === column.currentIndex || itemArea.containsMouse ? "#FA6800" : "#FFFFFF"
|
||||
text: qsTr(column1) + translationManager.emptyString
|
||||
}
|
||||
|
||||
@@ -187,8 +188,8 @@ Item {
|
||||
anchors.verticalCenter: parent.verticalCenter
|
||||
anchors.right: parent.right
|
||||
anchors.rightMargin: 45 * scaleRatio
|
||||
font.family: "Arial"
|
||||
font.pixelSize: 12 * scaleRatio
|
||||
font.family: Style.fontRegular.name
|
||||
font.pixelSize: 14 * scaleRatio
|
||||
color: "#FFFFFF"
|
||||
text: column2
|
||||
}
|
||||
@@ -211,6 +212,8 @@ Item {
|
||||
id: itemArea
|
||||
anchors.fill: parent
|
||||
hoverEnabled: true
|
||||
cursorShape: Qt.PointingHandCursor
|
||||
|
||||
onClicked: {
|
||||
dropdown.expanded = false
|
||||
column.currentIndex = index
|
||||
|
||||
Reference in New Issue
Block a user