Skip to content
  • Categories
  • Recent
  • Tags
  • Popular
  • Users
  • Groups
  • Search
  • Get Qt Extensions
  • Unsolved
Collapse
Brand Logo
  1. Home
  2. Qt Development
  3. QML and Qt Quick
  4. Popup Qt Quick event handler issue

Popup Qt Quick event handler issue

Scheduled Pinned Locked Moved Unsolved QML and Qt Quick
1 Posts 1 Posters 36 Views
  • Oldest to Newest
  • Newest to Oldest
  • Most Votes
Reply
  • Reply as topic
Log in to reply
This topic has been deleted. Only users with topic management privileges can see it.
  • T Offline
    T Offline
    Tai Hoang
    wrote last edited by
    #1

    Hi guys, i use 2 popup like below code in qml. i want that when popup2 open, btn1 is not hovered and change it background to green. How can i do that? Thanks in advance for any help

    Popup {
    	id: popup1
    	width: 200
    	height: 300
    	modal: true
    	focus: true
    	contentItem: Rectangle {
    		id: popup1Container
    		Button {
    			id: btn1
    			background: Rectangle {
    				color: btn1.hovered ? "red" : green
    			}
    			onClicked: popup2.open()
    		}
    	}
    }
    
    Popup {
    	id: popup2
    	width: 200
    	height: 300
    	modal: true
    	focus: true
    	contentItem: Rectangle {
    		id: popup1Container
    		Button {
    			id: btn2
    		}
    	}
    }
    
    1 Reply Last reply
    0

    • Login

    • Login or register to search.
    • First post
      Last post
    0
    • Categories
    • Recent
    • Tags
    • Popular
    • Users
    • Groups
    • Search
    • Get Qt Extensions
    • Unsolved