Results 1 to 2 of 2

Thread: Change state property within a current state?

  1. #1
    Join Date
    Oct 2011
    Location
    Toronto Canada
    Posts
    97
    Thanks
    7
    Thanked 1 Time in 1 Post
    Qt products
    Qt4 Qt/Embedded
    Platforms
    Unix/X11 Windows

    Default Change state property within a current state?

    Is there a way to change a state property to use the default property

    example: default button_inactive is visible then when i change the state it changes to button_active

    how could i change the current state(keep everything else the same) and just change button_active back to button_inactive

    Qt Code:
    1. PropertyChanges { target: back_normal; x: 222; y: 5; }
    2. PropertyChanges { target: back_inactive; x: -(parent.width * 500); }
    To copy to clipboard, switch view to plain text mode 

    default would be back_inactive x: 222; y: 5

  2. #2
    Join Date
    Jan 2006
    Location
    Warsaw, Poland
    Posts
    33,364
    Thanks
    3
    Thanked 5,013 Times in 4,791 Posts
    Qt products
    Qt3 Qt4 Qt5 Qt/Embedded
    Platforms
    Unix/X11 Windows Android Maemo/MeeGo
    Wiki edits
    10

    Default Re: Change state property within a current state?

    You change the state by assigning the state name to object's "state" property.
    Your biological and technological distinctiveness will be added to our own. Resistance is futile.

    Please ask Qt related questions on the forum and not using private messages or visitor messages.


Similar Threads

  1. Finding the current state of a QStateMachine
    By pherthyl in forum Qt Programming
    Replies: 3
    Last Post: 18th July 2012, 16:14
  2. QStateMachine state change problem
    By QTie in forum Qt Programming
    Replies: 0
    Last Post: 6th June 2011, 10:09
  3. How to get the current state of QStateMachine
    By QTie in forum Qt Programming
    Replies: 2
    Last Post: 1st June 2011, 14:23
  4. State Machine returning to previous state
    By akiross in forum Qt Programming
    Replies: 2
    Last Post: 10th May 2011, 01:39
  5. Replies: 0
    Last Post: 19th December 2010, 17:03

Bookmarks

Posting Permissions

  • You may not post new threads
  • You may not post replies
  • You may not post attachments
  • You may not edit your posts
  •  
Digia, Qt and their respective logos are trademarks of Digia Plc in Finland and/or other countries worldwide.