The code in 4696e9dbaa was incorrect. It is perfectly valid to call
these methods with row=-1 column=1 parent=some_index, this is exactly
what happens in QListView and QTableView. Child row/column is only for
trees.
Move the coordinate mapping from QSortFilterProxyModel into a new
mapDropCoordinatesToSource internal method, used by QAbstractProxyModel.
Task-number: QTBUG-39549
Change-Id: I3312210473d84b639cbe4c01f70ea36437db3e91
Reviewed-by: Friedemann Kleint <Friedemann.Kleint@theqtcompany.com>
Reviewed-by: Stephen Kelly <steveire@gmail.com>
CoreText doesn't seem to provide us with a "maximum advance" value,
but 0 is really wrong, it leads to QLineEdit::minimumSizeHint() being
0 since it's based on maxWidth(). It even led to a negative min width
with setTextMargins(-1, 0, -1, 0).
Change-Id: I4faf8ecfb6d91e9dff66ec63651d003014503cb4
Reviewed-by: Konstantin Ritt <ritt.ks@gmail.com>
Reviewed-by: Tor Arne Vestbø <tor.arne.vestbo@digia.com>
The current implementation returns the DocumentLocation folder.
Since now only cocoa is supported, we can use NSFileManager to get the
correct path.
[ChangeLog][QtCore][OS X] Now QStandardPaths returns the correct path
for the DownloadLocation.
Change-Id: Ic0ea3ebf8585a1e34a7b43c734df78fd3949d4d4
Reviewed-by: Thiago Macieira <thiago.macieira@intel.com>
When compiling with GCC 4.9's LTO, the compiler realizes that the class
looks different in two different compilation units and prints a warning.
Adding the necessary #define will make sure that the warning isn't
printed.
It's possible the warning indicates a real problem, if the class
actually got used in those two plugins. I wouldn't know.
QtPlatformSupport/private/.../qdevicediscovery_p.h:66:7: warning: type ‘struct QDeviceDiscovery’ violates one definition rule
.moc/.../qdevicediscovery_p.h:66:7: note: a type with the same name but different layout is defined in another translation unit
Change-Id: I73ca8e553e392b8d368f0deaa318d3e6635d73e1
Reviewed-by: Laszlo Agocs <laszlo.agocs@digia.com>
The presence of the inline QTestFontEngine's constructor causes a linker
failure because QFontEngineBox isn't exported. I'd say this is a
compiler bug (GCC 4.9), but it's an easy workaround and a difficult
testcase.
typeinfo for QTestFontEngine: error: undefined reference to 'typeinfo for QFontEngineBox'
vtable for QTestFontEngine: error: undefined reference to 'QFontEngineBox::glyphIndex(unsigned int) const'
Change-Id: I84829d111616977d6f3fcbbb48509d1c7d4f5fa6
Reviewed-by: Konstantin Ritt <ritt.ks@gmail.com>
If "encrypted" signal is fired the configuration of ssl is not updated.
If someone wants to perform additional checks on the certificate chain
it is now possible to use peerCertificate and peerCertificateChain.
Change-Id: Id5136a8c52727562c36028eaef721cc9ad86619d
Task-number: QTBUG-40401
Reviewed-by: Richard J. Moore <rich@kde.org>
Apple uses __OSX_AVAILABLE_STARTING in enum values too, which ICC
doesn't like. We need to force at least OS X 10.9 so we don't run into
build errors.
FSEvents.h(279): error: expected a "}"
kFSEventStreamCreateFlagMarkSelf __OSX_AVAILABLE_STARTING(__MAC_10_9, __IPHONE_7_0) = 0x00000020
^
Intel issue ID: 6000071924
Change-Id: Iae1abb8e8e92f228571c5064d96e9d33d3e35173
Reviewed-by: Oswald Buddenhagen <oswald.buddenhagen@theqtcompany.com>
Reviewed-by: Tor Arne Vestbø <tor.arne.vestbo@digia.com>
Reviewed-by: Thiago Macieira <thiago.macieira@intel.com>
Somehow, it doesn't shrink with btrfs, even if you write 1 MB of non-
null data. This does not seem to be a bug in QStorageInfo. strace
confirms that there is a second statvfs call happening.
Change-Id: I9ed99d27d25e191916278e6b8faeae132469fc63
Reviewed-by: Oswald Buddenhagen <oswald.buddenhagen@theqtcompany.com>
QDBusMessage is intended to avoid sending reply messages unless
the message is a method call without the NO_REPLY_EXPECTED flag set.
However, since messages which are not method calls will never have
this flag set, the code will currently cause all non-method call
messages to expect a reply. This patch changes the code to examine
the message type, and to only check for the flag in cases where the
message is a method call.
Change-Id: Ic5bb00df69d3cfb38f60bf6bfd8463fb28cf2c99
Reviewed-by: Thiago Macieira <thiago.macieira@intel.com>
If you write xxxx::min(), min() might be expanded as a macro on silly
environments that follow that poor practice (read: inclusion of
<windows.h> without NOMINMAX). However, if you write (min)() or
(xxx::min)(), it means the same but prevents the expansion as macro.
Task-number: QTBUG-42767
Task-number: QTBUG-31469
Change-Id: If3c93aafd4d0bf63ca15f3d01c2297d58d00f6bc
Reviewed-by: Oswald Buddenhagen <oswald.buddenhagen@theqtcompany.com>
Never start a line with a comma.
Change-Id: Idce1766f2661aa97fd163c02436ef315999985ec
Reviewed-by: Konstantin Ritt <ritt.ks@gmail.com>
Reviewed-by: Lars Knoll <lars.knoll@digia.com>
The testcase always returns the expected result, independently of the
QEventLoop::ExcludeSocketNotifiers flag to processEvents.
In Qt4 the same test uses an intermediate QEventLoop and already runs
it before the QEventLoop::ExcludeSocketNotifiers:
QEventLoop loop;
// allow the TCP/IP stack time to loopback the data,
// so our socket is ready to read
QTimer::singleShot(200, &loop, SLOT(quit()));
loop.exec(QEventLoop::ExcludeSocketNotifiers);
This fixes and improves the test by connecting, processing and
checking the bytesWritten signal for the pending connection socket.
Change-Id: I1b1d2b7b83910c87ba3fe48e29ac9fd585ac62ad
Reviewed-by: Thiago Macieira <thiago.macieira@intel.com>
qdevel is an option used from winrtrunner to indicate a specific
environment to the app. QTestLib needs to ignore that parameter similar
to the Visual Studio generated arguments.
Change-Id: I00a3abe19f1e5b4159e65d26050f04e28f40316f
Reviewed-by: Oliver Wolff <oliver.wolff@theqtcompany.com>
Reviewed-by: Andrew Knight <andrew.knight@theqtcompany.com>
customMenuFont was null, so objects was an empty array, and
NSDictionary throws an exception when being called with arrays
of different sizes.
Task-number: QTBUG-42728
Change-Id: I8cdab449fd8c1d12b65c46dd5617a7f5e3e96c6e
Reviewed-by: Gabriel de Dietrich <gabriel.dedietrich@theqtcompany.com>
Also, no need to create objects to get properties, when the properties
can be had for free.
Make plugin more robust to network-manager or ofono crashes
Change-Id: Ibadb46bd51aa27f130f8d245e8c50aa7bff5f9c8
Reviewed-by: Alex Blasche <alexander.blasche@theqtcompany.com>
Reviewed-by: Timo Jyrinki <timo.jyrinki@canonical.com>
This is in order to skip certain nodes that usually only carry
structural information (such as ListItem nodes). However, because of the
flattening, this structural information is never used on iOS, so we can
just skip the accessible node completely.
Change-Id: I17018c6565f8b39831f2d2944422c6670a438ab9
Reviewed-by: Frederik Gladhorn <frederik.gladhorn@theqtcompany.com>
The weather app had a search field with a clear button as a child.
Because of this bug it didn't report the content of the text edit (but
only the clear button)
Change-Id: I174c6e150e1991fa9aa2a911048590030b5ccc40
Reviewed-by: Frederik Gladhorn <frederik.gladhorn@theqtcompany.com>
Pick up logging rules set by QT_LOGGING_CONF, QT_LOGGING_RULES,
and qtlogging.ini file also for bootstrapped tools. This helps e.g.
in the case of winrtrunner, which uses categorized logging.
Change-Id: I47d392137e17a59cb57b5c0226f282b0ccf29961
Reviewed-by: Oswald Buddenhagen <oswald.buddenhagen@theqtcompany.com>
Reviewed-by: Maurice Kalinowski <maurice.kalinowski@theqtcompany.com>
Do not register new timers after closingDown() has been called. They
might call back into QEventDispatcherWin32 after the object has been
destructed, leading to crashes on exit.
registerSocketNotifier has a similar protection using
QCoreApplication::closingDown(). This however does not work in all cases,
because QEventDispatcher::closingDown() is called in
~QGuiApplication(), while QCoreApplication::is_app_closing is set
in ~QCoreApplication(). In between qt_call_post_routines() is called,
which might trigger new timers to be registered.
Task-number: QTBUG-42772
Change-Id: I91325fb10e38c117c1cbedfee272d0ab6a5ca8fa
Reviewed-by: Friedemann Kleint <Friedemann.Kleint@theqtcompany.com>
Using LocalServerSocket is way much safer than ServerSocket because is
not using ports which might be in use by other applications.
Change-Id: I0e2be0b4561362939950861024f1f95ab819f2c2
Reviewed-by: BogDan Vatra <bogdan@kde.org>
Reviewed-by: Alex Blasche <alexander.blasche@theqtcompany.com>
Reviewed-by: hjk <hjk121@nokiamail.com>
Reviewed-by: Eskil Abrahamsen Blomfeldt <eskil.abrahamsen-blomfeldt@theqtcompany.com>
Change the number of pan points to 1 for these classes as a
workaround until pan/tap gestures are fully fixed.
Task-number: QTBUG-40461
Change-Id: I0d68726a545ee6148f3ab88f2ab7308b10464ecd
Reviewed-by: Shawn Rutledge <shawn.rutledge@digia.com>
Add a convenience function to QApplicationPrivate returning
the source of mouse events to be able to detect synthesized
mouse events.
Change-Id: I09f82ed917586cd3de8b4146fc6638d19d428163
Task-number: QTBUG-40461
Reviewed-by: Shawn Rutledge <shawn.rutledge@digia.com>
The autoscrolling interferes with scrolling pan gestures
and causes the scroll direction to be reversed when moving
outside the window.
Task-number: QTBUG-40461
Change-Id: I30ef848a346418929540c23730ab92f44e4565e2
Reviewed-by: Shawn Rutledge <shawn.rutledge@digia.com>
QRegularExpressionValidator and QRegularExpression disagree on what a
partial match means.
[ChangeLog][QtGui][QRegularExpressionValidator] Allow empty string as
intermediate match
Change-Id: Ia6c55beb54870b1be5c88b6ef3eceebc8ca3f86b
Reviewed-by: Giuseppe D'Angelo <giuseppe.dangelo@kdab.com>
In Qt Quick (or in Qt Widgets when setting QT_NO_FT_CACHE to 1 or
when using OpenGL engine), the alphaRGBMapForGlyph() will be used
to get glyphs, because we need to keep our own cache. Transforms
was not supported in this code path, instead it was turned off
in supportsTransformations().
This patch enables transformations in the alphaRGBMapForGlyph()
and alphaMapForGlyph() code paths as well, since this is needed
for proper rendering with QT_DEVICE_PIXEL_RATIO.
Change-Id: I7d6b79918f7c0bcc051a8343b16b315bfbba59cf
Reviewed-by: Konstantin Ritt <ritt.ks@gmail.com>
Reviewed-by: Lars Knoll <lars.knoll@digia.com>
Whenever the source model of a QSortFilterProxyModel changes, and
the changes involve the sorted column, the implementation removes
the changed rows from the mapping, sorts them, and inserts them back;
in case of identical items, the rows are inserted at the end of the
block of equal rows.
The problem is that if the change doesn't actually happen on the roles
that are used for sorting, then we shuffle the rows, terribly confusing
the user. The typical case is a model with identical checkable rows:
(un)checking one row will move it at the end.
So, instead of trying to be smart with the removal/sort/insert sorted,
simply resort everything under the changed parent index. Since the
sorting used is stable, this keeps the items in the same positions.
Task-number: QTBUG-1548
Change-Id: Id0e61bd49da53b0a3e8aefa6b6893ac41179dc6f
Reviewed-by: David Faure <david.faure@kdab.com>
The qt_memfill32_asm_mips_dsp function is only declared if
QT_COMPILER_SUPPORTS_MIPS_DSP is defined, so we can't reference it
unless the same macro is defined.
Change-Id: Ib959b4b969b699ca78804394206266469b4ebf64
Task-number: QTBUG-36017
Reviewed-by: Paul Olav Tvete <paul.tvete@theqtcompany.com>
Reviewed-by: Thiago Macieira <thiago.macieira@intel.com>
Change-Id: I7147d326b0f5bb218f4dbc013ed82efb4c1e1440
Reviewed-by: Marc Mutz <marc.mutz@kdab.com>
Reviewed-by: Paul Olav Tvete <paul.tvete@theqtcompany.com>
The file qstandardpaths_ios.mm doesn't have an implementation for
this function, only (the wrongly named) qstandardpaths_mac.cpp
does. There's no Foundation API to get the directory name, so
we fall back to the hard-coded strings like all other platforms.
Change-Id: I6dcfeb6a0e5860dd0d4e9a0cd334b2c2181a0004
Reviewed-by: Richard Moe Gustavsen <richard.gustavsen@theqtcompany.com>
Groups: richtext and sharing.
Task-number: QTBUG-42682
Change-Id: I46bd7e5bba0f665519ee4f3c033b971f0836e314
Reviewed-by: Martin Smith <martin.smith@digia.com>
Add a socket based handshake method for gdb. The previous file based
method remains for now and can be activated from Qt creator. It will
be used by older creator builds but has the limitation of not working
on 5.0 devices.
The new mechanism works on pre 5.0 devices too.
Task-number: QTCREATORBUG-13418
Change-Id: Ia3ecd1b144b544f52d90940ca885653bcbc477ac
Reviewed-by: Eskil Abrahamsen Blomfeldt <eskil.abrahamsen-blomfeldt@theqtcompany.com>
Place the rubberband over the tabs instead of where the hidden
subwindows happen to be.
[ChangeLog][QtWidgets][QMdiArea] Fix rubberband position for tabbed mdi windows
Task-number: QTBUG-42612
Change-Id: I41e81ab8b99ab9e0fa533fd4ed1b2a8141d19753
Reviewed-by: Friedemann Kleint <Friedemann.Kleint@theqtcompany.com>
While a POST request with no body may be a pointless thing it does
happen on many websites. Currently this causes QtNetwork to print a
warning to the console and set an invalid content-type. This patch
allows the content-type to be absent when content is.
Task-number: QTBUG-42479
Change-Id: Ia84c89147d2469a9421b9694d062c797987b3194
Reviewed-by: Jocelyn Turcotte <jocelyn.turcotte@digia.com>
Reviewed-by: Thiago Macieira <thiago.macieira@intel.com>