Commit Graph

288 Commits

Author SHA1 Message Date
hjk
1ba91e3040 ProjectExplorer: Apply static pattern to ProjectExplorerPlugin
Adjust caller sites and surroundings.

Change-Id: I6c3c80e42f35eabedc1f89c8c42cca1025aca12f
Reviewed-by: Daniel Teske <daniel.teske@digia.com>
2014-09-26 08:50:00 +02:00
hjk
b26a17f30d CppTools: Change CppModelManager implementation pattern
Replace the CppModelManagerInterface/derived CppModelManager
combo by a more common CppModelManager/CppModelManagerPrivate
pimpl pattern.

Change-Id: Ia4582845ed94d5ef60b8571bab9b2260c6290287
Reviewed-by: Nikolai Kosjar <nikolai.kosjar@digia.com>
2014-09-19 13:17:55 +02:00
Erik Verbruggen
7290c43da1 C++: update project info once after finishing adding all project parts.
So that recalculating the information is not O(n^2) but linear.

Change-Id: I69903e0b5ad321d071804d782ad634a3f300e71a
Reviewed-by: Daniel Teske <daniel.teske@digia.com>
Reviewed-by: Nikolai Kosjar <nikolai.kosjar@digia.com>
2014-09-12 17:42:32 +02:00
Christian Kandeler
0c3eeab464 RemoteLinux: Create run configs by target name, not by project file.
The current approach fails for all build systems where one project file
can define more than one executable.

Change-Id: Ieda413975709fbd6e7ea87b185aa962f63cb7c1f
Reviewed-by: Daniel Teske <daniel.teske@digia.com>
2014-09-09 17:53:14 +02:00
Erik Verbruggen
30f8555a93 CMakeProject: put different languages into separate project parts.
This is in preparation for changes to the ProjectParts, where one part
can only hold files for 1 language.

Change-Id: I669e4f5b20e6553caad3a9ea2ed0e7c4455a8db7
Reviewed-by: Nikolai Kosjar <nikolai.kosjar@digia.com>
2014-08-21 13:12:52 +02:00
Nikolai Kosjar
6b5298faf9 CppTools: Move Project{Part,Info} to new cppprojects.{h,cpp}
Change-Id: Ieff216017b9da1e6a12121688ea9572bdd81fd9b
Reviewed-by: Erik Verbruggen <erik.verbruggen@digia.com>
2014-08-20 10:28:35 +02:00
Oswald Buddenhagen
f3a61e8bf7 Merge remote-tracking branch 'origin/3.2'
Conflicts:
	qtcreator.pri
	qtcreator.qbs
	src/plugins/android/androidglobal.h

Change-Id: I3367bf2ea47c088989175dddeed2210294346f4c
2014-08-05 14:24:23 +02:00
Daniel Teske
92cdd7045b CmakeProject: Don't crash on addKit + cancel
This was introduced by adding the remote linux support for 3.0 in
328a24edee. If the user cancels the
run cmake dialog, no buildconfiguration is created. The adding of kit
should then not happen. A target without a buildconfiguration should
not happen.

Task-number: QTCREATORBUG-12773
Change-Id: Ic43c5cc13f9e114ea24cc97154a6c084125f6318
Reviewed-by: Christian Stenger <christian.stenger@digia.com>
2014-08-01 07:40:09 +02:00
Daniel Teske
3d4caa3908 ProjectExplorer: Fix Project::displayName changes
The only project manager that actually sometimes changes the displayname
is the cmake project manager. And that one failed to emit the right
signal. And since the signal was never emitted a few places handled the
signal wrongly.

Change-Id: I4aa75dc3032efe49263143dbadb7585a378b9be9
Reviewed-by: Tobias Hunger <tobias.hunger@digia.com>
2014-07-22 16:51:47 +02:00
BogDan Vatra
d9516fb9a0 BuildConfiguration: Introduce signal buildTypeChanged()
Needed by android plugin.

Change-Id: I46543d4889e0e740697439e18e9c1ea0d3fef222
Reviewed-by: Tobias Hunger <tobias.hunger@digia.com>
Reviewed-by: BogDan Vatra <bogdan@kde.org>
2014-07-21 11:31:47 +02:00
Eike Ziller
c571ecbd51 Merge remote-tracking branch 'origin/3.2'
Conflicts:
	src/plugins/git/changeselectiondialog.cpp
	src/plugins/git/changeselectiondialog.h
	src/plugins/git/gerrit/gerritplugin.cpp
	src/plugins/git/gitclient.cpp
	src/plugins/git/gitclient.h
	src/plugins/git/gitsettings.cpp
	src/plugins/git/gitsettings.h
	src/plugins/git/mergetool.cpp

Change-Id: Icd1b2741da96395ed1b41903f453049a303e4791
2014-07-18 14:04:51 +02:00
Daniel Teske
65c113bcbc CMakeProject: Handle subdirectories with different defines/include paths
While we do know all the parts, we don't know to which part each file
belongs. So we guess that based on file system proximity.

Task-number: QTCREATORBUG-12359
Change-Id: I9d2a2ca0171b4e43f4a65d2f4b7b318f4e8b451c
Reviewed-by: Daniel Teske <daniel.teske@digia.com>
2014-07-17 19:13:54 +02:00
Daniel Teske
b0af82ebc9 CMakeProject: Make CMakeLists.txt and *.cmake use different mime types
Since we want to treat them differently.

Task-number: QTCREATORBUG-12461
Change-Id: Ia72b8045390ceec693fa416f65010a4c4dbecce1
Reviewed-by: Eike Ziller <eike.ziller@digia.com>
2014-07-17 16:38:30 +02:00
Leena Miettinen
7203eb46e5 CMake: fix capitalization of the "Run CMake..." button
Change-Id: I5402d29e6916110934411848542b1776178615e1
Reviewed-by: Daniel Teske <daniel.teske@digia.com>
2014-07-17 15:40:17 +02:00
Erik Verbruggen
3d33886e53 C++: fix include/framework path handling.
Instead of having two lists of paths, now only one list is used where
both include paths and framework paths can be mixed. This reflects the
way the compiler is invoked, and retains the (correct) search order.

Task-number: QTCREATORBUG-11599
Change-Id: I373953e3e305df5b7a0d10920e12d146584adf9f
Reviewed-by: Nikolai Kosjar <nikolai.kosjar@digia.com>
2014-07-04 13:51:36 +02:00
Nikita Baryshnikov
b204c4dba2 CMake fix deployment data
Fix potential index out of range assertion in QStringList if contents of
QtCreatorDeployment.txt would be unexpected(will not contain ':')

Change-Id: Ia6ae282ef450e7c56a512b13da801854caec0dfb
Reviewed-by: Daniel Teske <daniel.teske@digia.com>
2014-07-01 11:30:51 +02:00
hjk
93ccf4f266 IDocument: Make mimeType a value member
Change-Id: I2e90ccf0a45ae8d00bcd00ec77fe0d9776f2f119
Reviewed-by: Eike Ziller <eike.ziller@digia.com>
2014-07-01 10:54:55 +02:00
Nikita Baryshnikov
24d82a86ab Cmake fix warning
QTextStream: No device

Change-Id: I059f163d82bea0719b9781d0e20c691606047326
Reviewed-by: Orgad Shaneh <orgads@gmail.com>
Reviewed-by: Daniel Teske <daniel.teske@digia.com>
2014-06-30 10:28:43 +02:00
Nikita Baryshnikov
12103e0f67 Reinvent deprecated qSort as Utils::sort
Change-Id: I4f6011cc2b6127037249aabc2426a88ad7108ebf
Reviewed-by: Orgad Shaneh <orgads@gmail.com>
Reviewed-by: Daniel Teske <daniel.teske@digia.com>
Reviewed-by: hjk <hjk121@nokiamail.com>
2014-06-19 14:00:32 +02:00
hjk
6e584b5b49 DocumentModel: Make interface static
Move item model implementation to private, adjust user code.

Change-Id: Ifbe94e7c7b9b1e8be1b4c531958dbd7a9413af13
Reviewed-by: Eike Ziller <eike.ziller@digia.com>
2014-05-13 11:48:30 +02:00
Tobias Hunger
dc61b989ac Project: Use Utils::FileName as return type for projectDirectory(...)
Change-Id: I3ea10aa204b1ea41702edab09884b416cd6d9e06
Reviewed-by: Daniel Teske <daniel.teske@digia.com>
2014-05-06 11:48:10 +02:00
Tobias Hunger
8d5e4b32a8 Project: Use Utils::FileName as return type for projectFilePath()
Change-Id: If304d5e95cd9ac714100abaae35d60e3e1050eb2
Reviewed-by: Daniel Teske <daniel.teske@digia.com>
2014-05-06 11:30:45 +02:00
Eike Ziller
cab8e4aa03 Merge remote-tracking branch 'origin/3.1'
Conflicts:
	qtcreator.pri
	qtcreator.qbs
	src/plugins/qtsupport/qtversionmanager.cpp
	src/shared/qbs

Change-Id: If7a93fb018799fe6ada76e79c24ab5b43dfa6fc2
2014-04-02 13:24:34 +02:00
Daniel Teske
fc2fad44e0 CMakeProjectManager: Ensure that toolchain paths are last
Task-number: QTCREATORBUG-3959
Change-Id: I93a19af8309933a51d26f94980088c0f244cc84f
Reviewed-by: Nikolai Kosjar <nikolai.kosjar@digia.com>
2014-04-01 16:25:05 +02:00
Oswald Buddenhagen
f013c41d05 Merge remote-tracking branch 'origin/3.1'
Conflicts:
	src/plugins/cmakeprojectmanager/cmakeopenprojectwizard.cpp

Change-Id: Icce6e8dd9b3afd9a0fe836e9babfb7a17cee9c4d
2014-03-27 18:20:00 +01:00
Daniel Teske
5a6d5d6649 CMakeOpenProjectWizard: Set a parent
Task-number: QTCREATORBUG-11856
Change-Id: Ie80352683e2a8276f70191db2a3b333275e2648f
Reviewed-by: Robert Loehning <robert.loehning@digia.com>
2014-03-26 17:53:07 +01:00
Eike Ziller
5dd8d7cd9c Editors: Move id() from editor to document.
Change-Id: Ib81076842ab1c16832224790194b001206404d64
Reviewed-by: hjk <hjk121@nokiamail.com>
Reviewed-by: Eike Ziller <eike.ziller@digia.com>
2014-03-05 16:27:52 +01:00
Stephen Kelly
424a5c1489 Fix 'Run CMake' button text.
It raises a dialog, so it needs an ellipsis.

Change-Id: Ifb668e7a4419c6eaba080b99e64e57cb9730e071
Reviewed-by: Tobias Nätterlund <tobias.naetterlund@kdab.com>
Reviewed-by: Daniel Teske <daniel.teske@digia.com>
Reviewed-by: hjk <hjk121@nokiamail.com>
Reviewed-by: Nicolas Arnaud-Cormos <nicolas@kdab.com>
2014-03-05 13:06:48 +01:00
Erik Verbruggen
c4ef72dd39 CMake: work-around for CodeBlocks lack of framework support.
CodeBlocks is utterly ignorant of frameworks on Mac, and won't report
framework paths. The work-around is to check if the include path ends in
".framework", and if so, add the parent directory as framework path.

Task-number: QTCREATORBUG-11445
Change-Id: I794dd72d755d5593e36ebf59543d0a5e9fda3cce
Reviewed-by: Daniel Teske <daniel.teske@digia.com>
Reviewed-by: Eike Ziller <eike.ziller@digia.com>
2014-02-27 12:32:57 +01:00
Daniel Teske
fba7dcdbaa ProjectExplorer: Introduce compareSortedLists
Which compares two sorted lists and returns a diff between them.

Change-Id: I278bd43f1bd999bae6575cbf38cddbdf3ff82418
Reviewed-by: Daniel Teske <daniel.teske@digia.com>
2014-02-19 17:43:41 +01:00
Daniel Teske
d809037302 ProjectNodes: Move (add|remove)(File|Folder)Node to FolderNode
The reason they were on ProjectNode is that the signals are emitted
on the projectnode, but since I moved addFiles and others to FolderNode,
this makes more sense.

Change-Id: I918ca4d93dab78c8bb93dff03f53d1a6fbe21340
Reviewed-by: Daniel Teske <daniel.teske@digia.com>
2014-02-19 16:00:24 +01:00
Eike Ziller
236ea9efb9 Merge remote-tracking branch 'origin/3.0'
Conflicts:
	share/qtcreator/debugger/dumper.cpp
	share/qtcreator/debugger/dumper_p.h
	share/qtcreator/debugger/test/main.cpp
	src/plugins/debugger/gdb/classicgdbengine.cpp
	src/plugins/debugger/gdb/pythongdbengine.cpp
	src/plugins/debugger/lldblib/guest/lldbengineguest.cpp
	src/plugins/debugger/lldblib/guest/lldbengineguest.h
	src/plugins/debugger/lldblib/guest/main.cpp
	src/plugins/debugger/lldblib/ipcengineguest.cpp
	src/plugins/debugger/lldblib/ipcengineguest.h
	src/plugins/debugger/lldblib/ipcenginehost.cpp
	src/plugins/debugger/lldblib/ipcenginehost.h
	src/plugins/debugger/lldblib/lldbenginehost.cpp
	src/plugins/debugger/lldblib/lldboptionspage.cpp
	src/plugins/qbsprojectmanager/qbsstep.cpp
	src/plugins/qbsprojectmanager/qbsstep.h
	src/plugins/qmlprofiler/canvas/qdeclarativecanvas.cpp
	src/plugins/qmlprofiler/canvas/qdeclarativecanvas_p.h
	src/plugins/qmlprofiler/canvas/qdeclarativecontext2d.cpp
	src/plugins/qmlprofiler/canvas/qdeclarativecontext2d_p.h
	src/plugins/qmlprofiler/canvas/qmlprofilercanvas.cpp
	src/plugins/qnx/blackberrycheckdevmodestep.cpp
	src/plugins/qtsupport/debugginghelper.cpp

Change-Id: Ie9fd0a885fb6264a6a8a72daee071b75bcbd2e9d
2014-01-08 11:01:06 +01:00
Robert Loehning
746c5d8863 Incremented year in copyright info
Change-Id: Ib5423fdd064e4546f848c0b640b0ed0514c26d3a
Reviewed-by: Leena Miettinen <riitta-leena.miettinen@digia.com>
Reviewed-by: Kai Koehne <kai.koehne@digia.com>
2014-01-08 08:29:47 +01:00
Erik Verbruggen
ea1a92484a C++: split defines into project-defined and toolchain-defined.
So we can ignore possibly problematic toolchain-defines, while can still
unconditionally apply project-defines.

Change-Id: I7cb96f35a963d080011fe888ef71bfc098dd33ef
Reviewed-by: Nikolai Kosjar <nikolai.kosjar@digia.com>
2013-12-10 11:42:41 +01:00
hjk
f463c4dade ProjectExplorer: Make Project::id value based
Change-Id: Ie210d2a068158c6caaac66aae58cbd886f61c18d
Reviewed-by: Tobias Hunger <tobias.hunger@digia.com>
2013-10-14 13:35:59 +02:00
Daniel Teske
e462c9620d ProjectPart: Add meta information
Add displayname and project file path and a pointer back to the
project.

Change-Id: Ic9a18f52a6291493bd3a95fd3456ed0e1a3c63e3
Reviewed-by: Erik Verbruggen <erik.verbruggen@digia.com>
2013-10-01 16:31:36 +02:00
Tobias Hunger
d2adc30335 BuildConfigurationFactory: Refactor code
Refactor the code of the build configuration factories. The idea is to
generalize the code so much that we can allow plugins to install
custom build configuration factories for the platforms they support.

To support this use case the following changes where done here:
 * BuildInfo class was introduced to describe one build configuration that
   can be created by a factory.
 * Factories report a list of BuildInfo to describe what they can produce.
   This fixes the need for factories to implicitly create one buildconfiguration
   and then create another one 'officially' to support debug and release build
   configurations to be set up for projects.
 * Do no longer work around factories to create build configurations.

Change-Id: Ic372e4a9b5c582633b467d130538948472b89d91
Reviewed-by: Daniel Teske <daniel.teske@digia.com>
2013-09-17 12:00:01 +02:00
Oleksii Serdiuk
328a24edee CMake: Make CMake plugin work with RemoteLinux plugin.
Modified CMake plugin to work correctly with RemoteLinux plugin.
Because of not being able to extract files to be installed from CMake
project, only executable targets are automatically added to deployment
files. All other files have to be specified in CMakeDeployment.txt file
which should be placed into root of CMake project. The file format is:
> deployment/prefix
> relative/source/file1:relative/destination/dir1
> ...
> relative/source/filen:relative/destination/dirn

Where:
- deployment/prefix is (absolute) path prefix to which files will be
  deployed on the remote machine.
- relative/source/file is file path relative to CMake project root.
  Plain files - no directories or wildcards supported.
- relative/destination/dir is destination directory path relative to
  deployment/prefix.

Change-Id: I0831636c1b9aac3ff16bb6293104c512d2abfb5a
Reviewed-by: Daniel Teske <daniel.teske@digia.com>
2013-09-16 13:30:54 +02:00
Tobias Hunger
fc2740291c Cmake: Improve handling of build targets in makestep
* Update build targets as they change in CMakeLists.txt
* Do not set "all" since that is the default anyway
* Signal widget whenever the list of targets to build changes

Change-Id: Ie90be143fa345e03576632ab39a5dc5f75b19daf
Reviewed-by: Daniel Teske <daniel.teske@digia.com>
2013-09-12 13:51:27 +02:00
Tobias Hunger
cbe42ddca9 Cmake: Remove dead code
Change-Id: I3e99afd3ce4a39c9ffeb7b7b21b3454e88dffe74
Reviewed-by: Daniel Teske <daniel.teske@digia.com>
2013-09-12 13:50:10 +02:00
Tobias Hunger
f69b994896 CMake: Move watcher setup
TO BE SQUASHED LATER!

Change-Id: I055ba795f9b47e7046edc6cb34d3d91ec4419eca
Reviewed-by: Daniel Teske <daniel.teske@digia.com>
2013-09-12 11:38:13 +02:00
Tobias Hunger
d18b61b85d Core::Id: Remove some explicit casts to Core::Id
Change-Id: Ibe505c8331f7d1280fdb8784a00321742f5d94cb
Reviewed-by: hjk <hjk121@nokiamail.com>
2013-09-03 11:57:23 +02:00
Friedemann Kleint
84cfc4f914 Reduce usage of QStringRef::toString() in project manager/cmake.
Change-Id: I5d60c663d8a258334dde9b93b4f76a4bea760a70
Reviewed-by: Daniel Teske <daniel.teske@digia.com>
2013-08-29 11:49:50 +02:00
Tobias Hunger
a7bb77288d BC: Move builddirectory handling into BC itself
Use setBuildDirectory() in the different BuildConfigurations instead
of reimplementing that over and over again.

Change-Id: Ic355fdb4624c71667ce470b3e2865c9a8722ef09
Reviewed-by: Daniel Teske <daniel.teske@digia.com>
Reviewed-by: Tobias Hunger <tobias.hunger@digia.com>
2013-08-28 11:41:38 +02:00
Tobias Hunger
5345c96ea5 UiCodeModelManager: Clean up API
Task-number: QTCREATORBUG-9763

Change-Id: Ie138f63b8abd5333262debf311aa3ebbd88c81d5
Reviewed-by: hjk <hjk121@nokiamail.com>
2013-08-02 12:07:40 +02:00
Tobias Hunger
07d486ce94 PluginManager: Do not use instance() when that is not needed
Change-Id: I68e1b20561098c375557be6db1fb528e0ae040f6
Reviewed-by: hjk <hjk121@nokiamail.com>
2013-08-02 11:52:40 +02:00
Tobias Hunger
78d3191363 UiCodeModel: Simplify usage
Change-Id: Id274db9ed3022364e7b65788f8313ae6cfa73326
Reviewed-by: Tobias Hunger <tobias.hunger@digia.com>
2013-08-01 14:23:00 +02:00
Nikolai Kosjar
fdaddec7d1 CppTools: Clean up CppModelManager(Interface)
* Const correctness
* Better variable names
* Sort order of includes and forward declarations
* Comment fixes
* Cosmetic/Whitespace changes

Change-Id: Ieb137266ac7eddedb00c37f8b2cc8677d67e4bdd
Reviewed-by: David Schulz <david.schulz@digia.com>
2013-07-31 14:34:08 +02:00
Oswald Buddenhagen
6896546ba5 Merge remote-tracking branch 'origin/2.8'
Conflicts:
	src/plugins/cpptools/cppmodelmanager.cpp

Change-Id: I0e69dfad951eb81d8008f5ca05e8fb6999ae2c8a
2013-07-25 13:18:31 +02:00
Nikolai Kosjar
072b7c5718 CppTools: Check if project has changed before reparsing
This introduces an API change for the project managers. Those are not
expected to call updateSourceFiles() anymore.

Task-number: QTCREATORBUG-9581
Change-Id: I77befd29fb851c9acf87204d571da00183c9cd05
Reviewed-by: Erik Verbruggen <erik.verbruggen@digia.com>
2013-07-22 08:33:52 +02:00