SHA: 8e3aacf61b is a mac only patch, but
some code introduced by which is not wrapped with Q_OS_MAC. So add
the missing Q_OS_MAC here.
Change-Id: I748d46b977740e6116dab5659ad1e47d23262a0f
Reviewed-by: Friedemann Kleint <Friedemann.Kleint@theqtcompany.com>
Offscreen surface support was added in fb3577039c, as the platform
supports FBOs, but we need to return a subclass of QPlatformOffscreenSurface
that returns true for isValid() and a valid surfaceFormat().
Task-number: QTBUG-39759
Change-Id: If6aa9ee1672984bb93a01a5323af8d93b3b0f2b8
Reviewed-by: Richard Moe Gustavsen <richard.gustavsen@theqtcompany.com>
Reviewed-by: Laszlo Agocs <laszlo.agocs@theqtcompany.com>
QOpenGLWindow with createWindowContainer() can be an option
for desktop-only apps in some special cases. Document this.
Task-number: QTBUG-45192
Change-Id: I7c59b7d04d6c0fe58ffe93ac72b204103bef2f4c
Reviewed-by: Gunnar Sletta <gunnar@sletta.org>
The stored context pointer has to be reset to null in
destroy() even when no VAO was created (vao is null).
Otherwise destroying the context that was stored in the VAO
will not lead to resetting the stored pointer, and a subsequent
destruction of the VAO object will try to dereference it.
Task-number: QTBUG-44562
Change-Id: I438bb3954d4bbd8b8d8704f6087479804f0073a7
Reviewed-by: Giuseppe D'Angelo <giuseppe.dangelo@kdab.com>
Reviewed-by: Sean Harmer <sean.harmer@kdab.com>
Rounding the bottom right corner position means that the size
can change when the window moves. For windows we need
to round the size up in order to have a stable geometry.
Task-number: QTBUG-45076
Change-Id: I9a85a5915bfec55b0a7295be137b6fbfd7b53095
Reviewed-by: Friedemann Kleint <Friedemann.Kleint@theqtcompany.com>
Reviewed-by: Laszlo Agocs <laszlo.agocs@theqtcompany.com>
Reviewed-by: Shawn Rutledge <shawn.rutledge@digia.com>
When CSS is set in a head tag then it was not being inherited by the child
tags when the CSS specification indicates that the properties are in fact
inherited. This ensures that those properties are inherited and the non
inheritable ones are unchanged.
A test is added to cover the different situations with inheritance and a
fix is done for the QTextDocumentFragment test which was passing despite
having incorrect defaults.
Task-number: QTBUG-28770
Task-number: QTBUG-34153
Change-Id: I55966240845a885852a04ecb82c61926dea9f800
Reviewed-by: Simon Hausmann <simon.hausmann@theqtcompany.com>
Add a new style hint to QPlatformIntegration: ReplayMousePressOutsidePopup.
Return false for it in the xcb plugin.
This commit restores the behavior which was in Qt 4.
Task-number: QTBUG-34814
Change-Id: I19fee762395a51475cc67b52b368c70679ca736b
Reviewed-by: Shawn Rutledge <shawn.rutledge@digia.com>
Enable native popup on iOS as well as OS X
Change-Id: If99180a017768d9c94241adf2282ee9b3f69cbc1
Reviewed-by: Gabriel de Dietrich <gabriel.dedietrich@theqtcompany.com>
QPlatformMenu::showPopup() is supposed to be non-blocking.
So ensure that we don't start cleaning up the menu items directly
after the call in showNativePopup, but wait until we need to reload
the items, or the combobox is destroyed.
Change-Id: Ie4c9b6425cec44861af38e517fc5ef226e0903c7
Reviewed-by: Gabriel de Dietrich <gabriel.dedietrich@theqtcompany.com>
This change adds missing variables in mkspecs/qconfig.pri about gcc
compiler version when using mingw: QT_GCC_{MAJOR,MINOR,PATCH}_VERSION
This is needed in case CONFIG += c++14 is used.
Task-number: QTBUG-44142
Change-Id: I34c27f9154bb745a8ee75c777a0acbdbc5bda5a9
Reviewed-by: Louai Al-Khanji <louai.al-khanji@theqtcompany.com>
Reviewed-by: Thiago Macieira <thiago.macieira@intel.com>
Reviewed-by: Oswald Buddenhagen <oswald.buddenhagen@theqtcompany.com>
Introduce QDebugStateSaver, use new formatting helpers and
output parent, flags and z only when necessary. Output the
widget contained in QGraphicsProxyWidget.
For example,
QGraphicsProxyWidget (this = 0x1877550 , parent = 0x0 , pos = QPointF(870,491) , z = 1e+30 , flags = ( ItemIsFocusable | ItemUsesExtendedStyleOpton | ItemSendsGeometryChanges | ItemIsPanel ) )
becomes:
QGraphicsProxyWidget(0x1877550, widget=ItemDialog(0x1e29dc0), pos=870,491, z=1e+30, flags=(ItemIsFocusable|ItemUsesExtendedStyleOption|ItemSendsGeometryChanges|ItemIsPanel))
Change-Id: Ia554dc3e2eb6f16d9d9220d1067194a4424b7cf5
Reviewed-by: Kai Koehne <kai.koehne@theqtcompany.com>
Prevent compilers from calculating strlen at compile time
by using a volatile pointer. This corrupted paths if the
installation path is patched for the binary SDK installer.
Task-number: QTBUG-45307
Change-Id: I624b0409e8b27299475a88eb1cbf03ffef9589c6
Reviewed-by: Oswald Buddenhagen <oswald.buddenhagen@theqtcompany.com>
Clang likes to complain when override is not used consistently.
Change-Id: I0fad18a7c3eb068aa1b6786243969aef53d1f42c
Reviewed-by: Friedemann Kleint <Friedemann.Kleint@theqtcompany.com>
Use QDebugStateSaver to store the formatting state and fix the return
statement to return the unmodified stream.
Change-Id: I476d13c5487a89f263dcc11334fc67c85d9433f5
Reviewed-by: Kai Koehne <kai.koehne@theqtcompany.com>
Extract helpers to be able to format classes without type names
and use those for formatting QEvents to reduce clutter.
For example:
QWidgetWindow/"MainWindowClassWindow" QMouseEvent(QEvent::Type(MouseMove), buttons=QFlags<Qt::MouseButtons>(LeftButton), localPos=QPointF(50,116), screenPos=QPointF(948,652))
QWidget/"qt_scrollarea_viewport" QMouseEvent(QEvent::Type(MouseMove), buttons=QFlags<Qt::MouseButtons>(LeftButton), localPos=QPointF(45,32), screenPos=QPointF(948,652))
becomes
QWidgetWindow/"MainWindowClassWindow" QMouseEvent(MouseMove, LeftButton, localPos=50,116, screenPos=948,652)
QWidget/"qt_scrollarea_viewport" QMouseEvent(MouseMove, LeftButton, localPos=45,32, screenPos=948,652)
Change-Id: Ie5441d922962a05caed6b7079a74ea8a2b8a64fb
Reviewed-by: Kai Koehne <kai.koehne@theqtcompany.com>
Until now we applied the geometry in QWidget::setVisible() by
calling QWidget::move() and QWidget::resize(). But these
methods are unreliable when the window is created but not
visible yet. For example, specifying the window position by
"-geometry +0+0" will take no effect.
Apply the geometry directly to QWindow in QWindow::setVisible().
QWidget will update its geometry after the response of the window
system. Besides it allows to specify the geometry for QML
applications.
Task-number: QTBUG-44713
Change-Id: I9a0e110e81e569c81da802729707fec104fef887
Reviewed-by: Friedemann Kleint <Friedemann.Kleint@theqtcompany.com>
Reviewed-by: Shawn Rutledge <shawn.rutledge@digia.com>
It may change after the window has been created.
Change-Id: Ib81a7ad7353b1909cc42684fc70d6b7d2556106f
Reviewed-by: Uli Schlachter <psychon@znc.in>
Reviewed-by: Jørgen Lind <jorgen.lind@theqtcompany.com>
This change is related to 6a7ee92b39
which added handling for SelectionClientClose. Further testing showed
that with e.g. Qt 4 applications the SelectionClientClose is not
emitted, but the selection window seems to be destroyed before the
client is destroyed.
Fur a destroyed selection window the same applies: the clipboard
content is no longer valid and we should emit the changed signal.
Change-Id: Id3778a28b9f5601bf2c6e0106981316e0efa6e7c
Reviewed-by: Gatis Paeglis <gatis.paeglis@digia.com>
Reviewed-by: Uli Schlachter <psychon@znc.in>
While most (all?) touchpads send WM_MOUSEWHEEL for vertical scroll
the story is quite different for horizontal scroll. Some of them
send WM_HSCROLL instead of WM_MOUSEHWHEEL.
Some of them even send left/right key event but those are lost cases.
Task-number: QTBUG-45120
Change-Id: I3bf86e25a6f4f3ba03ac7e89a23f4b7bc432f2de
Reviewed-by: Friedemann Kleint <Friedemann.Kleint@theqtcompany.com>
At least the dismissive action should be on the left, but we can take
the OS X rules as reasonable in cases where a lot of buttons are in use.
Task-number: QTBUG-42808
Change-Id: If45f991a068d47009e02d39fbb3886ff4b31c8e1
Reviewed-by: BogDan Vatra <bogdan@kde.org>
The text was accidentally removed in
1afe110b8f.
Fixes qdoc warning:
qtbase/src/corelib/io/qstandardpaths.cpp:60: warning: Undocumented enum item GenericDataLocation in QStandardPaths::StandardLocation
Change-Id: I7f236c01d85ebf76b67ab7af7e61b8cbedee4c36
Reviewed-by: David Faure <david.faure@kdab.com>
We have two State types in the All QML Types list. One is in QtQuick
and the other is in QtQml, but they are both just listed as "State"
with no way to tell which is which. Now they look like this:
State: QtQml
State: QtQuick
Change-Id: I48bb3deda10a61f565d1aed1910360fea4fb7891
Task-number: QTBUG-45141
Reviewed-by: Topi Reiniö <topi.reinio@digia.com>
Remove the \service and \mainclass commands, and the ditamap stuff.
Also remove all reverences to these commands from qdoc itself.
Change-Id: I8d150acdd56d40e6a4198a021e50f5fe3f3b1194
Task-number: QTBUG-45143
Reviewed-by: Martin Smith <martin.smith@digia.com>
Avoid showing unnecessary "TouchFrame without registered device"
warnings. That should be reserved only for not having a device ready.
The touch point list's emptyiness is a different story - there we
should stop silently as that is not an error.
Change-Id: Icdb8b352351b70a7e1af2d3a1de3001dfb751aae
Reviewed-by: Shawn Rutledge <shawn.rutledge@digia.com>
With reasoning similar to commit v5.5.0-alpha1~123 (Make some
QAbstractItemModel API invokable, 2015-02-25)
Change-Id: If0bf3a756ab1031f906c5bf9c823aafae4c3873c
Reviewed-by: J-P Nurmi <jpnurmi@theqtcompany.com>
Reviewed-by: Stephen Kelly <steveire@gmail.com>
With reasoning similar to commit v5.5.0-alpha1~123 (Make some
QAbstractItemModel API invokable, 2015-02-25)
Change-Id: I77c72f7bb856a1eee966b45950384fe03a8eaac6
Reviewed-by: J-P Nurmi <jpnurmi@theqtcompany.com>
Gitorious is closing down, so point to code.qt.io instead.
Change-Id: Ibc453f05e59cf227a7a7086201b008cf7b576a26
Reviewed-by: Topi Reiniö <topi.reinio@digia.com>
Use the debug operator for enums and flags to format keys and
modifiers.
Change-Id: Id748e4b2202797efcbf3a616d111399929ada8b1
Reviewed-by: Shawn Rutledge <shawn.rutledge@digia.com>
Compilers don't like out parameters.
Effects on Linux GCC 4.9 stripped release builds:
text -584B
data +-0B
relocs +-0
Change-Id: Ie00c89b9edaced3a6adeb2707734c8f5238e67c1
Reviewed-by: Thiago Macieira <thiago.macieira@intel.com>
The function getDateFromJulianDay() is simple arithmetic, but still
~400 bytes in executable size.
Yet GCC inlines this everywhere I looked, which makes some sense,
as different users of the class only use parts of the return
value and the optimizer has a field day removing all that dead
code.
However, that function has only one conditional, so presumably it
executes at full pipeline speed and it doesn't matter that it
calculates too much in some cases. More important is to use the
I-cache more conservatively.
That's what not inlining the function achieves.
The function returns its result in registers and doesn't spill
registers when called (at least on AMD64), so the effect on
runtime should be negligible.
Effects on Linux GCC 4.9 stripped release builds:
text -1536B
data +-0B
relocs +-0
Change-Id: Ia16838102d29ad67ee5efdc8b7b0a26f2f921df1
Reviewed-by: Thiago Macieira <thiago.macieira@intel.com>
Instead of using a QString::arg() cascade, which creates tons of
temporaries, use good 'ol sprintf().
Effects on Linux GCC 4.9 stripped release builds:
text -308B
data +-0B
relocs +-0
Change-Id: I348577491d1399b5040f7ed9e9f6b111a9528e5d
Reviewed-by: Thiago Macieira <thiago.macieira@intel.com>
Save one return statement per function. I don't see why the compiler
can't fuse these itself, but apparently it cannot, since this
transformation saves 72B in text size.
Change-Id: I3a661456554bf451ed53110ad546946ff7b84ec5
Reviewed-by: Thiago Macieira <thiago.macieira@intel.com>
All other similar functions in QDate just return an empty string
in case none of the switch labels would trigger (which would now
cause a compiler warning, after removing the default case label),
so do that here, too.
Saves 44B in text size.
Change-Id: I80ee4975082706adcd15fe89511d08c67e149324
Reviewed-by: Thiago Macieira <thiago.macieira@intel.com>
They're pure whitespace, since in each case there is a fallback
after the switch, anyway, and their presence prevents compiler
warnings about unhandled enumeration values in switch statements,
which is nice-to-have, when adding to the enum, eventually.
No change in executable code size.
Change-Id: I77aecaeff990601f957ec9ee827eff5ead25aaa1
Reviewed-by: Thiago Macieira <thiago.macieira@intel.com>
This will prevent unnecessary warnings about unknown types for signals
or slots that are not even exported to the D-Bus.
Change-Id: Iecda5beca5ebe6665a193245fe1c2578156f6abe
Reviewed-by: Thiago Macieira <thiago.macieira@intel.com>
This allows applications that need additional symbols from the library to
easily obtain them without needing to replicate the library open logic
from qdbus_symbols.cpp.
Change-Id: Ic65ef6684637fbcd1c9f4fe1dc7a57f0624b61a8
Reviewed-by: Thiago Macieira <thiago.macieira@intel.com>
When building the test while qtbase has been installed and the
build dir was removed, the include paths were not found in
frameworks builds.
Change-Id: I32d9e61176a5e19c86095580ddad6914f25ff952
Reviewed-by: Oswald Buddenhagen <oswald.buddenhagen@theqtcompany.com>
Likely culprit for issues in the CI when building iOS tests.
This reverts commit 9a7564edee.
Change-Id: I02ac77a305b5863c9533c97ba06aaafe8f176a22
Reviewed-by: Simon Hausmann <simon.hausmann@theqtcompany.com>
Orca expects text attributes with different names (and sometimes also
different values) than IAccessible2 ones (which Qt uses). So adapt the names
and values accordingly.
[ChangeLog][Accessibility] We now report text attributes correctly on Linux,
so ORCA+F now works properly in QTextEdit and other text controls.
Change-Id: Iad6d38168b309669c00069a6167f4f54cbd64cf0
Task-number: QTBUG-44479
Reviewed-by: Jan Arve Sæther <jan-arve.saether@theqtcompany.com>
NSAccessibility has no explicit analog for
QAccessibleActionInterface::toggleAction(), checking checkboxes/radio
buttons is handled by NSAccessibilityPressAction. So ensure exposing
the action properly on OS X so that VoiceOver users can check/uncheck
checkboxes, select radio buttons etc.
Change-Id: Idc8b048de2313a3e875a929516baf3dded9c68cc
Task-number: QTBUG-44852
Reviewed-by: Jan Arve Sæther <jan-arve.saether@theqtcompany.com>