Commit Graph

909 Commits

Author SHA1 Message Date
Orgad Shaneh
cd6302502b QmlJS: Revert CodeFormatter::stateToString return type to QString
Change-Id: I532327126dfdbe4d338d7afd0bcbe5e27ba206d9
Reviewed-by: Thomas Hartmann <Thomas.Hartmann@digia.com>
Reviewed-by: Fawzi Mohamed <fawzi.mohamed@digia.com>
2012-11-28 23:18:42 +01:00
Orgad Shaneh
a44aa55502 Add whitespace after control keywords
find -name \*.cpp -o -name \*.h | \
  xargs sed -Ei 's/ (for|foreach|if|switch|while)\(/ \1 (/g'

Change-Id: I9efdff4bf0c8c01a52baaaeb75198483c77b0390
Reviewed-by: hjk <qthjk@ovi.com>
2012-11-28 20:20:46 +01:00
Orgad Shaneh
3747e941ad Clean up whitespace before EOL
Change-Id: I385544a10b9be66589b0d1a48594128035836c8a
Reviewed-by: hjk <qthjk@ovi.com>
2012-11-28 20:17:51 +01:00
David Schulz
2db4fb4bea Fix: build failure for qmljscheck an qmljscodeformatter
Change-Id: Iba9686506d971f92e525361e93d648dc940fe2d2
Reviewed-by: Orgad Shaneh <orgads@gmail.com>
2012-11-28 15:11:08 +01:00
Friedemann Kleint
e3d3cf987c Compile fix (QT_NO_CAST_FROM_ASCII).
Change-Id: I4db4135758f5cec8435fe0f11ab7141068b7cee3
Reviewed-by: Orgad Shaneh <orgads@gmail.com>
Reviewed-by: Friedemann Kleint <Friedemann.Kleint@digia.com>
2012-11-28 12:37:50 +01:00
Orgad Shaneh
5ea0937167 QmlJS: Compile with QT_NO_CAST_FROM_ASCII
Change-Id: I0c5654a978f47a4db5428936fd44633f21394830
Reviewed-by: Friedemann Kleint <Friedemann.Kleint@digia.com>
Reviewed-by: Thomas Hartmann <Thomas.Hartmann@digia.com>
2012-11-28 11:11:47 +01:00
Thomas Hartmann
279cc09cc0 QmlJS::SimpleReader: simple bugfix (initialisation)
The user can use readFromSource repeatedly.

Change-Id: Ibb7da95743ae6ecfd4492bb0163ff3599d5bcdb5
Reviewed-by: Thomas Hartmann <Thomas.Hartmann@digia.com>
2012-11-21 14:19:57 +01:00
Thomas Hartmann
6cf321a316 QmlJS:SimpleReader: adding support for arrays
Also adding test.

Change-Id: Idaf0aeacbb6f78e5c8404db740c2a8b7b297dad2
Reviewed-by: Thomas Hartmann <Thomas.Hartmann@digia.com>
2012-11-21 13:58:58 +01:00
Marcel Krems
2ed22524a7 QmlJS: Fixed potential crash in SimpleReader.
Change-Id: I21f5824e6d51391aa439188d70f9a8e0456f2f51
Reviewed-by: Thomas Hartmann <Thomas.Hartmann@digia.com>
2012-11-14 07:03:41 +01:00
Thomas Hartmann
5debabc410 QmlJS: adding SimpleReader
SimpleReader is a !simple! parser for json like qml files.
SimpleReader only parses literal properties for e.g. configuration
files.

SimpleAbstractStreamReader allows event based parsing and SimpleReader
stores the parsed data in a reference counted tree structure.

Change-Id: I0f6422a97f5c356149c516f227f8bbd7b736a6d0
Reviewed-by: Joerg Bornemann <joerg.bornemann@digia.com>
2012-11-07 16:42:28 +01:00
Thomas Hartmann
33721a85fe Fix linking for MSVC
This was not linking for the debugger plugin.
Since the class has no actual symbol we cannot export it.

Change-Id: I7db7a779e30ca2b2870296874a3d35992be3f5fb
Reviewed-by: Aurindam Jana <aurindam.jana@digia.com>
2012-10-10 12:20:55 +02:00
Thomas Hartmann
587adf5084 QmlJSEditor: crash fix
The typeStack has to stay in sync and initializers for
properties do not have a type.

Change-Id: I49f7d1679d083c994fd692a1c36e33ba7fce17ff
Reviewed-by: Joerg Bornemann <joerg.bornemann@digia.com>
2012-10-10 11:26:06 +02:00
Aurindam Jana
1d04c4c3df Debugger: Remove the dependence on QmlJSTools
Change-Id: I26765134c19b9a6cf1e7ad26f313e2d4f8faf258
Reviewed-by: Christiaan Janssen <christiaan.janssen@digia.com>
2012-10-09 18:22:00 +02:00
Eike Ziller
d5d1c5e394 Merge remote-tracking branch 'origin/2.6'
Conflicts:
	src/libs/utils/fileutils.cpp
	src/plugins/remotelinux/deployablefilesperprofile.cpp
	src/plugins/remotelinux/genericdirectuploadservice.cpp
	src/tools/qtcreatorcrashhandler/main.cpp

Change-Id: I830287691e7085fe9c94597e23ec7be64eb8be42
2012-10-09 11:50:17 +02:00
Thomas Hartmann
880ab20751 QmlJS: Fix rewriter for signal parameters
Task-number: QTCREATORBUG-7931

I had to fix a bug in the QmlJsParser.
The source location for the
propertyTypeToken was not initialized in all cases.

I also updated qmljs.g.

Change-Id: Idd0880f70578867cf5f97666aede654e00cfc744
Reviewed-by: Joerg Bornemann <joerg.bornemann@digia.com>
Reviewed-by: Christian Kamm <kamm@incasoftware.de>
2012-10-08 10:27:02 +02:00
Eike Ziller
6fd252b0a5 Merge remote-tracking branch 'origin/2.6'
Conflicts:
	share/qtcreator/qml/qmlpuppet/commands/endpuppetcommand.cpp
	share/qtcreator/qml/qmlpuppet/commands/endpuppetcommand.h
	src/plugins/debugger/qtmessageloghandler.cpp
	src/plugins/debugger/qtmessageloghandler.h
	src/plugins/debugger/qtmessagelogwindow.cpp
	src/plugins/madde/maemodeployconfigurationwidget.cpp
	src/plugins/madde/maemodeployconfigurationwidget.h
	src/plugins/remotelinux/deployablefilesperprofile.cpp
	src/plugins/remotelinux/deployablefilesperprofile.h
	src/plugins/remotelinux/deploymentinfo.cpp
	src/plugins/remotelinux/deploymentinfo.h
	src/plugins/remotelinux/deploymentsettingsassistant.cpp
	src/plugins/remotelinux/profilesupdatedialog.cpp
	src/plugins/remotelinux/remotelinuxdeploymentdatamodel.h
	tests/auto/icheckbuild/ichecklib.cpp
	tests/auto/icheckbuild/ichecklib_global.h
	tests/auto/icheckbuild/parsemanager.cpp
	tests/auto/icheckbuild/parsemanager.h
	tests/manual/ssh/tunnel/tunnel.h

Change-Id: I04d7761df6bd936ad00e0547974284c967d39580
2012-10-05 21:20:50 +02:00
hjk
386ca7c8dd Adjust license headers
Change-Id: Ice592c6de9951ee3b2c4cb52ed0bb3b6770e0825
Reviewed-by: Eike Ziller <eike.ziller@digia.com>
2012-10-05 17:12:56 +02:00
Orgad Shaneh
614bb33589 qbs files: Consolidate includePaths in QtcLibrary and QtcPlugin
Avoid using "." as includePath when it is unneeded

Change-Id: I9bc6f4ebe50409f49782520033fd5f098aed10d0
Reviewed-by: Christian Kandeler <christian.kandeler@digia.com>
2012-10-05 10:18:56 +02:00
Orgad Shaneh
a00b291484 qbs files: Sort files
Change-Id: I6514deb70162bd52687e6143813bcf1325a797db
Reviewed-by: Christian Kandeler <christian.kandeler@digia.com>
2012-10-03 09:26:34 +02:00
Thomas Hartmann
d48756d75b QmljsInterpreter: avoid ambiguities about major import version
Both CppComponentValues are created and available in the code model.
In case of a context lookup it seems to be random which one is taken.

This patch ensures that the code model only contains the object
with the highest version.

Change-Id: Icd1ac1c7d62e277bbd8a2747c3504457be5dd8d6
Reviewed-by: Christian Kamm <kamm@incasoftware.de>
2012-09-26 11:54:18 +02:00
Eike Ziller
b947861c59 Merge remote-tracking branch 'origin/2.6'
Conflicts:
	qtcreator.qbp
	src/libs/QtcLibrary.qbs
	src/plugins/QtcPlugin.qbs
	src/tools/QtcTool.qbs

Change-Id: I3acea26888febe8f96d2131932266ed88b9f55f5
2012-09-19 18:02:46 +02:00
Christian Kandeler
6d17da175f Fix qbs build for Qt 5.
Make sure newly deprecated stuff is still available.

Change-Id: I9ebdfcd9a5ecee125a3c73f5f3254ae319d8b282
Reviewed-by: Joerg Bornemann <joerg.bornemann@digia.com>
2012-09-17 17:29:16 +02:00
Thomas Hartmann
e5699c0925 QmlJS.Check: Warnings for qml code not supported by Qt Quick Designer
This patch adds several warnings for qml code not supported by Qt Quick
Designer.

* WarnImperativeCodeNotEditableInVisualDesigner:
   This warns about imperative code affecting a visual property.
   e.g.: "x = 10;"

* WarnUnsupportedTypeInVisualDesigner:
    This warns about types which are currently not supported.

* WarnReferenceToParentItemNotSupportedByDesigner:
    This warns about things like: "width: parent.width" in
    the root item.

* WarnUndefinedValueForDesigner:
    This warns about visual properties that cannot be evaluated in
    the local context.
    e.g.: "x: somethingNotDefinedInTheLocalContext.x"

* WarnStatesOnlyInRootItemForDesigner:
    This warns about states not defined in the root item.

All the Qt Quick designer related warnings are disabled by default
in Check.

Change-Id: If31a8199fb95dc8bf6ac613634a2e442e436e267
Reviewed-by: Christian Kamm <kamm@incasoftware.de>
2012-09-17 14:45:56 +02:00
Eike Ziller
5ac721dd58 Merge remote-tracking branch 'origin/2.6'
Conflicts:
	qtcreator.pri
	qtcreator.qbp
	src/libs/utils/utils.pro

Change-Id: I6f0aba746f915d8c51dcf9372f7d9f593562fc2b
2012-09-11 14:02:03 +02:00
Christian Kamm
0df5933539 QmlJS indenter: Fix wrong indentation after list<> typed properties.
Task-number: QTCREATORBUG-7726
Change-Id: If709a9a71cfed69e2f14af92c114f79d11d03145
Reviewed-by: Thomas Hartmann <Thomas.Hartmann@nokia.com>
2012-09-10 14:21:57 +02:00
Thomas Hartmann
80409cad95 QmlJS: Document script to generate parser copy.
Change-Id: Ib35f718fef7a9621247dbc468bcfa4f3ea425c50
Reviewed-by: Thomas Hartmann <Thomas.Hartmann@nokia.com>
2012-09-10 13:09:30 +02:00
Tobias Hunger
8da8d21c18 Remove some unused member variables
Change-Id: I4b1bcfe8da32bd48c601d1efdb7c3aac1d39cbce
Reviewed-by: Leandro Melo <leandro.melo@nokia.com>
2012-08-22 16:18:54 +02:00
Kai Koehne
5064933944 Avoid adding the same DEFINE multiple times to the command line
E.g. on MSVC, QT_CREATOR was passed 14 times ...

Change-Id: Ife39267b0d6f2def1706b823abfd0226325437ae
Reviewed-by: Eike Ziller <eike.ziller@nokia.com>
2012-08-21 11:57:22 +02:00
hjk
6a7cf405bd rename QtDebug to QDebug
More uniform.

Change-Id: I1c6057981f4c2b3170a4e69f0674fe4caf1143a2
Reviewed-by: Robert Loehning <robert.loehning@nokia.com>
2012-08-06 14:55:08 +02:00
Christian Kamm
cf2540c9a4 QmlJS: Fix parser generation scripts to adjust export of QmlDirParser.
Change-Id: I721d8ce4fdd4ca09bf2ee68a8e54aa7351664e3a
Reviewed-by: Christian Kamm <christian.d.kamm@nokia.com>
2012-08-01 07:51:10 +02:00
Christian Kamm
a14ed0793c QmlJS: Update to latest QmlJS parser from Qt 5.
Using qtdeclarative revision c9b7582a2e7ad9fcd03dd999c3b7a16b72803238

Change-Id: I9c942fa04c3fab5ef57b38e13471d0a4e2e8a2bf
Reviewed-by: Roberto Raggi <roberto.raggi@nokia.com>
2012-07-31 11:05:03 +02:00
Eike Ziller
e0e8cf3ada Contact -> qt-project.org
Change-Id: I7134d7de30bcf9f9dcfad42520dd45ee083a852d
Reviewed-by: Oswald Buddenhagen <oswald.buddenhagen@nokia.com>
2012-07-19 13:23:21 +02:00
Yuchen Deng
0d20c5b796 Fix qbs code style
Change-Id: Ia3e4df528d391580064efbeeab75016335a4299d
Reviewed-by: Joerg Bornemann <joerg.bornemann@nokia.com>
2012-06-19 11:22:40 +02:00
Christian Kandeler
ad3e94f67c Fix qbs build.
Change-Id: I235ef625162755192b3f499a2e46bbdb28ca5842
Reviewed-by: Kai Koehne <kai.koehne@nokia.com>
2012-05-09 16:48:54 +02:00
Aurindam Jana
d4c2c3f214 QmlJSInterpreter: QML Plugin types
A Component in .qmltypes can have an array of exports which
may differ in type names and versions.
Consider the type names to be aliases and create a CppComponentValue
for each of the alias corresponding to the best available version.

Change-Id: I759ae0c68441e805b0502bf2d203c524bf1a7a7c
Reviewed-by: Fawzi Mohamed <fawzi.mohamed@nokia.com>
2012-05-07 17:07:29 +02:00
Aurindam Jana
2ad4a291b6 QmlJSBind: Set Root Object
Avoid re-setting the root object of the document.

Task-Number: QTCREATORBUG-7379

Change-Id: I9d2209bf2e3dba8d9784fffe087859bddebeb16f
Reviewed-by: Fawzi Mohamed <fawzi.mohamed@nokia.com>
Reviewed-by: Christian Kamm <christian.d.kamm@nokia.com>
2012-05-03 13:50:11 +02:00
Aurindam Jana
c908a4b9e6 QmlJSInterpreter: Register QML Types
A Component in .qmltypes can have an array of exports which
may differ in type names too (possibly because of type deprecation).
Consider the type names to be aliases and create a CppComponentValue
for each of the alias.

Change-Id: I70cadab465aec3e7842abd7050549c77fb8342fc
Reviewed-by: Marco Bubke <marco.bubke@nokia.com>
Reviewed-by: Alessandro Portale <alessandro.portale@nokia.com>
2012-04-30 16:48:57 +02:00
Bradley T. Hughes
fb9146a9c3 Compile after qt5/qtbase commit 75a0c7f9
Commit 75a0c7f9b52cde47f20fdc1b89e1264d60350848 in qt5/qtbase changed
some QRegExp methods to be non-const (they were previously const). This
change makes Qt Creator compile again.

Change-Id: Ibc98c678126c3b3189df7fcc043463b940951445
Reviewed-by: Friedemann Kleint <Friedemann.Kleint@nokia.com>
Reviewed-by: Thiago Macieira <thiago.macieira@intel.com>
Reviewed-by: Daniel Teske <daniel.teske@nokia.com>
2012-04-30 14:32:08 +02:00
Oswald Buddenhagen
822233629d Merge remote-tracking branch 'origin/2.5'
Conflicts:
	qtcreator.pri
	src/libs/utils/utils.qbs
	src/plugins/projectexplorer/miniprojecttargetselector.cpp
	src/plugins/qmljseditor/qmljseditor.qbs
	src/plugins/qmljsinspector/qmljsinspector.qbs

Change-Id: Ib239d50c21cb06d3a8e821e03dc093552f40ffab
2012-04-19 16:13:09 +02:00
Joerg Bornemann
0834958063 qbs files updated
Property bindings in ProductModules now need explicit Depends items.
Also, some Qt dependencies were propagated wrongly and are now
added explicitely.

Change-Id: I58cd389eb0ab106004b1d575438d1ad2ff36189f
Reviewed-by: Marco Bubke <marco.bubke@nokia.com>
2012-04-18 17:10:55 +02:00
Joerg Bornemann
96a7fbe3ae qbs files: use Qt5 module dependencies
Renamed gui -> widgets.
Renamed declarative -> quick1.

With qbs the usage of qt.widgets and qt.quick1 with Qt4 is supported.

Change-Id: I6cadaf34527f1f880d74ced7d2d18dd9801b7de1
Reviewed-by: Alessandro Portale <alessandro.portale@nokia.com>
2012-04-10 18:02:39 +02:00
Orgad Shaneh
06aa0363b0 Qbs: Libraries capitalized and relocated in bin on Windows
Change-Id: I994027ef50f5f7c4ff1b2bef06d9f8db037243e4
Reviewed-by: Marco Bubke <marco.bubke@nokia.com>
Reviewed-by: Joerg Bornemann <joerg.bornemann@nokia.com>
2012-04-04 14:16:12 +02:00
Kai Koehne
174678e049 QmlJS: Initialize variable properly
Change-Id: Ie9447e040c228b42766969ed8d80b33f67cccc46
Reviewed-by: Fawzi Mohamed <fawzi.mohamed@nokia.com>
2012-03-14 13:04:57 +01:00
Kai Koehne
1f9a55e0b0 QmlJS: Fix warning text when loading .qmltypes file
Change-Id: Ia9509087fad6a63de2c6f35a012f5542c6bc2c98
Reviewed-by: Fawzi Mohamed <fawzi.mohamed@nokia.com>
2012-03-13 12:24:39 +01:00
Kai Koehne
712928ff08 QmlJS: Actually print warning for .qmltypes file
Change-Id: I93030362168719c126818006839e9fae0ca673ce
Reviewed-by: Fawzi Mohamed <fawzi.mohamed@nokia.com>
2012-03-13 12:24:32 +01:00
Christian Kamm
ab64c1aef3 QmlJS indenter: Improve indentation of function expressions.
As discussed with Tor Arne and Fawzi in
http://codereview.qt-project.org/#change,18080

Change-Id: Ia0482d2ed3ddd61fa002e2c76b948301af52a795
Reviewed-by: Tor Arne Vestbø <tor.arne.vestbo@nokia.com>
Reviewed-by: Fawzi Mohamed <fawzi.mohamed@nokia.com>
2012-03-06 17:26:46 +01:00
Tobias Hunger
339b34a5df Add missing copyright headers
Change-Id: I71f9050a7de9c7b07bcd7d96c8e5fc64a8565fb0
Reviewed-by: Tobias Hunger <tobias.hunger@nokia.com>
2012-03-05 10:12:08 +01:00
Christian Kamm
658e80d1b8 QmlJS indenter: Improve handling of function expressions.
Task-number: QTCREATORBUG-7001

Change-Id: I254b84153b042c81008314bbebc800edfe201b89
Reviewed-by: Tor Arne Vestbø <tor.arne.vestbo@nokia.com>
Reviewed-by: Fawzi Mohamed <fawzi.mohamed@nokia.com>
(cherry picked from commit fcaf3d4f4c)
2012-03-01 17:00:02 +01:00
Robert Loehning
ff58b3102c QmlJS indenter: Fix hang with invalid code.
Task-number: QTCREATORBUG-7005

(cherry picked from commit 0c597a6f07)

Change-Id: I2e343fbcc6931530e7db142bf6e268dac696970f
Reviewed-by: Christian Kamm <christian.d.kamm@nokia.com>
2012-03-01 08:27:40 +01:00
Leandro Melo
b266472a4c Remove unused class member
Change-Id: I35120b106f4e246d196e2306c8043d7657f98bf3
Reviewed-by: Fawzi Mohamed <fawzi.mohamed@nokia.com>
2012-02-23 11:20:39 +01:00