Testcase: trying to use an existing build dir which was
made for /d/foo where /d is a symlink to $HOME/d.
To help understanding the problem, the error message now prints
both source dirs, the one found in the builddir and the one we expected.
Change-Id: I9a24fbd6ef3cf8108c5edba0d2a5b99ecdea0e89
Reviewed-by: Tobias Hunger <tobias.hunger@qt.io>
The functionality in that class is covered by initializers and
Utils::unique, so there is no need to keep a custom class.
This way FileNameList plays way nicer with utils/algorithm.h.
Change-Id: I8eeae6aca0558ecd998920c4fdfc5ea56bf75501
Reviewed-by: Orgad Shaneh <orgads@gmail.com>
Reviewed-by: Eike Ziller <eike.ziller@theqtcompany.com>
On a case insensitive file system, we want to e.g.
open 'foo.H' when switching between header and source from 'foo.cpp'
if that is how the file appears on the file system.
Since there doesn't seem to be a way to normalize the full path without
resolving symlinks, do it for each path component in turn.
Also add a header for the mac specific utility functions.
Task-number: QTCREATORBUG-13507
Change-Id: I6cf51fed698d12ac56fa1ec051da1b893bb0b065
Reviewed-by: Christian Stenger <christian.stenger@theqtcompany.com>
Reviewed-by: Morten Johan Sørvig <morten.sorvig@theqtcompany.com>
Reviewed-by: Eike Ziller <eike.ziller@theqtcompany.com>
Extend drop support with variant values. A drop may be a file drop or a
value drop or both.
Rename Utils::FileDropSupport to Utils::DropSupport and add methods to
add not only files but any QVariant value to the mime data. Project
explorer adds dragged nodes (which will be needed for future ModelEditor
plugin).
Change-Id: I799542c60fdecb3e64af0d3ba47b6caa9adbcfd7
Reviewed-by: Eike Ziller <eike.ziller@theqtcompany.com>
... by keying on Utils::FileName
Task-number: QTCREATORBUG-12390
Change-Id: Ia98afb5a9160a7fd9225a2f9e02539ff3c35ae86
Reviewed-by: Nikolai Kosjar <nikolai.kosjar@theqtcompany.com>
This can use the faster route through QFileInfo::exist now.
Change-Id: Idb41b5d5185d7f02eacba498fb01f483d95e8d57
Reviewed-by: Eike Ziller <eike.ziller@theqtcompany.com>
Reviewed-by: Christian Stenger <christian.stenger@digia.com>
Fill the line and column information in the location returned by
QmlOutlineModel::sourceLocation for that.
The drag & drop code also needed a way to override the executed drop
action for file drops, because the QML outline supports move-drags, which
would lead to the items being removed from the outline when dragged onto
a split...
Change-Id: I2478abc7d5aa2f3aa676cdd609ecb69a50adce8c
Reviewed-by: Daniel Teske <daniel.teske@digia.com>
Reviewed-by: Fawzi Mohamed <fawzi.mohamed@digia.com>
Switching from Ant to Gradle brings lots of advantages:
- it is way faster when rebuilding (25-50% faster than ant).
- it enables first class Android Studio integration.
- adding Android Extras libs (e.g. Google Play services, OBB, etc.) to
your project is now painless.
[ChangeLog][Android] Added Gradle support to build the APK.
Change-Id: Iee492954f8ffb2c22e6ab14a8a25faf644de9a51
Reviewed-by: Daniel Teske <daniel.teske@digia.com>
This adds a "Utils" object to the Js runtime offered by the
JsExpander that adds some useful functions.
Mostly file name mangling and finding preferred extension
from the MIME type database.
Change-Id: I907dae7f295167667ac2ae81461bbff16dc98ef4
Reviewed-by: Daniel Teske <daniel.teske@digia.com>
Especially when this gets more complicated with additional fancy windows
mime types and custom mime type for opening a file at a specific
location (dropping from Outline, Type Hierarchy et al), we should not
create that complex mime data everywhere by hand.
Change-Id: I37f6ceb287b0cd055501fdd033ac29816434a020
Reviewed-by: Daniel Teske <daniel.teske@digia.com>
We have fileNameCaseSensitivity and withExecutableSuffix et al.
Change-Id: I79bd2cd57e258c3f15673a661a49bab597d7afa4
Reviewed-by: Daniel Teske <daniel.teske@digia.com>
The QMakeEvaluator uses it's own more accurate version of
isAbsolutePath. If we pass in a path that qt thinks is
absolute, e.g. "C:dev", but the qmake evaluator disagrees,
creator crashes. Import these functions from the qmake
evaluator into Utils::FileUtils and use them to prepare
the builddirectory.
Task-number: QTCREATORBUG-12034
Change-Id: Ida28688558f3186db25e3ab73bd39cabc91c1ff0
Reviewed-by: Oswald Buddenhagen <oswald.buddenhagen@digia.com>
Reviewed-by: David Schulz <david.schulz@digia.com>
According to Ossi the only safe characters in a path for qmake are
alphanumerical, underscore, dot and dash.
Task-number: QTCREATORBUG-10980
Change-Id: Ibacbfeb7f04f1f0524093f1d8fce637ea4ae6fd6
Reviewed-by: Daniel Teske <daniel.teske@digia.com>
Reviewed-by: Tobias Hunger <tobias.hunger@digia.com>
Until now we used GetShortPathName which relies on having 8.3 paths.
This short path names are converted into long names which also corrects
the case. The 8.3 paths can be manually deactivated via the fsutil. When
this is done GetShortPathName does not return a convertible path string.
If the case isn't corrected on windows we are opening multiple editors for
the same file. For example, when reaching a breakpoint when using cdb or
opening an entry from the issue panel generated by the msvc compile.
Task-number: QTCREATORBUG-11199
Change-Id: Ic04055685e0e9bbe0d45cde20563929b7370695d
Reviewed-by: Orgad Shaneh <orgads@gmail.com>
Reviewed-by: Eike Ziller <eike.ziller@digia.com>
Reviewed-by: Friedemann Kleint <Friedemann.Kleint@digia.com>
The function's operation of simply appending the string as is would be
fine if FileNames were strings. But they aren't, so the function name
should be intentionally ugly to stand out.
Change-Id: I85e16844e2d69cacb6566c538182b84300c45161
Reviewed-by: Tobias Hunger <tobias.hunger@digia.com>
Reviewed-by: Daniel Teske <daniel.teske@digia.com>
This patch fixes ~1100 warnings from qdoc
Change-Id: Ia9555db675acbf8083b2f87d9855a62a3a34ccb9
Reviewed-by: Leena Miettinen <riitta-leena.miettinen@digia.com>
Use \a for all attributes in function descriptions
to avoid QDoc errors. Do not use \param, because
it is not a valid QDoc command.
Do not use \returns as it does not exist.
Do not use \brief for functions. It is not obligatory, so
rather than add them for all functions, let's consistenly leave them out.
Fix typos, grammar and style issues, and punctuation.
Change-Id: Ib8f296f93976265bb93dbeab40c5b47156518122
Reviewed-by: hjk <hjk121@nokiamail.com>
QDoc does some magic with the \class and \namespaces
and \brief commands, so the following wording must be used:
"The xxx class yyy ..."
Change-Id: Id231f30e8464898b776888d5423523de404aae34
Reviewed-by: Eike Ziller <eike.ziller@digia.com>
This will silence some warnings about removing files with empty
filenames which we get due to trying to remove a file we never
managed to open.
Calling finalize() unconditionally is the right thing to do here
as that processes and/or displays on error message to the user
if there is any.
Change-Id: Ibe7d07233f2c2698e53a7ad21041bc5cc4fcac0e
Reviewed-by: Oswald Buddenhagen <oswald.buddenhagen@digia.com>
Forward-declare QGraphicsOpacityEffect in DetailsButton,
QProcessEnvironment in Environment, QFileInfo in fileutils,
QUrl in IWelcomePage, FancyLineEdit in PathChooser and
remove unneeded headers.
Change-Id: I7d5f273530dd2059bbdaf0899f0a3bc7e49e8482
Reviewed-by: hjk <hjk121@nokiamail.com>
Qt 4.8.0 or later is required to build Qt Creator.
Change-Id: I4d836d0f17fe8f0e3fc5757d4f08111b87edee67
Reviewed-by: Friedemann Kleint <Friedemann.Kleint@digia.com>
Reviewed-by: Oswald Buddenhagen <oswald.buddenhagen@digia.com>