Uploaded image for project: 'Qt'
  1. Qt
  2. QTBUG-16478 QtScript API changes for Qt 5
  3. QTBUG-16483

Remove QScriptValue::setProperty() PropertyFlags argument

    XMLWordPrintable

Details

    • Sub-task
    • Resolution: Invalid
    • Not Evaluated
    • 5.0.0
    • Qt Script
    • None

    Description

      Currently QScriptValue::setProperty() can be used for too many things.

      • Creating a property with certain flags (e.g. ReadOnly).
      • Changing the value + flags of a property (e.g. making an existing property Undeletable).
      • Setting the getter or setter of a property (PropertyGetter|PropertySetter flags).
      • Not relevant to this task: Deleting a property.

      Removing the flags argument would help a lot.
      Properties should be created with default (no) attributes, just like in JS.
      If the user needs to control the attributes, and/or define a getter/setter property, additional API should be used for that, inspired by the defineProperty() API in ECMAScript 5.

      Attachments

        No reviews matched the request. Check your Options in the drop-down menu of this sections header.

        Activity

          People

            kenthans Kent Hansen (Inactive)
            kenthans Kent Hansen (Inactive)
            Votes:
            0 Vote for this issue
            Watchers:
            2 Start watching this issue

            Dates

              Created:
              Updated:
              Resolved:

              Gerrit Reviews

                There are no open Gerrit changes