summaryrefslogtreecommitdiffstats
path: root/src/plugins/platforms/android/androidjnimenu.cpp
Commit message (Collapse)AuthorAgeFilesLines
* Android: eradicate Q_FOREACH loops [rvalues]Marc Mutz2016-04-251-1/+2
| | | | | | | | | | | | | ... by replacing them with C++11 range-for loops. This is the simplest of the patch series: Q_FOREACH took a copy, so we do, too. Except we don't, since we're just catching the return value that comes out of the function (RVO). We can't feed the rvalues into range-for, because they are non-const and would thus detach. Change-Id: Ia086b1f3d072dd56c3545780490be03346df2880 Reviewed-by: BogDan Vatra <bogdan@kdab.com>
* Android: eradicate Q_FOREACH loops [needing qAsConst()]Marc Mutz2016-04-251-2/+2
| | | | | | | | | ... by replacing them with C++11 range-for loops. To avoid detaches of these mutable Qt containers, wrap the container in qAsConst(). Change-Id: I9158c507f9249a7322b11c982bfcab1e6ed4a38a Reviewed-by: Olivier Goffart (Woboq GmbH) <ogoffart@woboq.com>
* Android: eradicate Q_FOREACH loops [already const]Marc Mutz2016-04-251-1/+1
| | | | | | | | | ... (or trivially marked const) local variables, parameters, or data members with trivial loop bodies, by replacing them with C++11 range-for loops. Change-Id: I25e9e2148abd7676305ebd18754dc647f217e48b Reviewed-by: Olivier Goffart (Woboq GmbH) <ogoffart@woboq.com>
* Android: Fix crash, don't add null visible menus to pendingContextMenusBogDan Vatra2016-02-041-1/+2
| | | | | | | Regression introduced in e3689949ba5b23decb0ea85741a3f4829696788e Change-Id: I9d3e37733d933e037f04d3a6efaf05607e16d9c5 Reviewed-by: Christian Stromme <christian.stromme@theqtcompany.com>
* Updated license headersJani Heikkinen2016-01-151-13/+19
| | | | | | | | | | | From Qt 5.7 -> LGPL v2.1 isn't an option anymore, see http://blog.qt.io/blog/2016/01/13/new-agreement-with-the-kde-free-qt-foundation/ Updated license headers to use new LGPL header instead of LGPL21 one (in those files which will be under LGPL v3) Change-Id: I046ec3e47b1876cd7b4b0353a576b352e3a946d9 Reviewed-by: Lars Knoll <lars.knoll@theqtcompany.com>
* Android: Remove support for API < 16BogDan Vatra2015-12-101-8/+1
| | | | | | | | | Starting with Qt 5.7 we removed support for API < 16 (Android v4.1) [ChangeLog][Android] Support for Android API < 16 was removed. Change-Id: I8bf396a9d70ab0996965e0c9f629800aa1fa6a45 Reviewed-by: Eskil Abrahamsen Blomfeldt <eskil.abrahamsen-blomfeldt@theqtcompany.com>
* Fix android menubar's menu not opening at the first press.Michal Klocek2015-02-231-0/+4
| | | | | | | | | | In case of selected item in submenu, call aboutToHide() on still visible menus. This will allow quickquickcontrols to act poperly when menus are closed. Task-number: QTBUG-42188 Change-Id: I9f11fa7cc63f50d7863566d0ee52a62c7036ddaa Reviewed-by: Alex Blasche <alexander.blasche@theqtcompany.com>
* Update copyright headersJani Heikkinen2015-02-111-6/+6
| | | | | | | | | | | | | | | | | | Qt copyrights are now in The Qt Company, so we could update the source code headers accordingly. In the same go we should also fix the links to point to qt.io. Outdated header.LGPL removed (use header.LGPL21 instead) Old header.LGPL3 renamed to header.LGPL3-COMM to match actual licensing combination. New header.LGPL-COMM taken in the use file which were using old header.LGPL3 (src/plugins/platforms/android/extract.cpp) Added new header.LGPL3 containing Commercial + LGPLv3 + GPLv2 license combination Change-Id: I6f49b819a8a20cc4f88b794a8f6726d975e8ffbe Reviewed-by: Matti Paaso <matti.paaso@theqtcompany.com>
* Merge remote-tracking branch 'origin/5.4' into devFrederik Gladhorn2014-11-241-22/+5
|\ | | | | | | | | | | | | | | | | | | | | | | Conflicts: src/corelib/io/qiodevice.cpp src/plugins/bearer/linux_common/qofonoservice_linux.cpp src/plugins/bearer/linux_common/qofonoservice_linux_p.h src/plugins/platforms/android/qandroidplatformtheme.cpp src/tools/bootstrap/bootstrap.pro src/widgets/styles/qmacstyle_mac.mm Change-Id: Ia02aab6c4598ce74e9c30bb4666d5e2ef000f99b
| * Android: Simplify the jni code in QtAndroidMenuChristian Strømme2014-11-031-22/+5
| | | | | | | | | | | | | | | | This is one of several fixes where the goal is to simplify the jni code by letting QJNI manage the environment. Change-Id: Ia714e25fbb3fcd170150392e822b0a3fc3812818 Reviewed-by: Eskil Abrahamsen Blomfeldt <eskil.abrahamsen-blomfeldt@theqtcompany.com>
* | Merge remote-tracking branch 'origin/5.4' into devFrederik Gladhorn2014-10-091-20/+43
|\| | | | | | | Change-Id: I05fcd8dc66d9ad0dc76bb7f5bae05c9876bfba14
| * Use PopupMenu when possible.BogDan Vatra2014-10-011-20/+43
| | | | | | | | | | | | | | | | | | | | | | | | On API-11+ we are going to use PopupMenu instead of ContextMenu to show context menus. A PopupMenu displays a Menu in a modal popup window anchored to a View. The popup will appear below the anchor view if there is room, or above it if there is not. Task-number: QTBUG-39736 Change-Id: Ie412ab0935b868348ce5c8bb0bf53571ffefd582 Reviewed-by: J-P Nurmi <jpnurmi@digia.com> Reviewed-by: Paul Olav Tvete <paul.tvete@digia.com>
* | Merge remote-tracking branch 'origin/5.4' into devOswald Buddenhagen2014-09-291-18/+10
|\| | | | | | | | | | | | | | | | | | | | | Conflicts: src/corelib/tools/qbytearray.cpp src/gui/image/qimage.cpp src/gui/image/qppmhandler.cpp src/gui/kernel/qguiapplication.cpp src/gui/painting/qpaintengine_raster.cpp Change-Id: I7c1a8e7ebdfd7f7ae767fdb932823498a7660765
| * Update license headers and add new license filesMatti Paaso2014-09-241-18/+10
| | | | | | | | | | | | | | | | | | - Renamed LICENSE.LGPL to LICENSE.LGPLv21 - Added LICENSE.LGPLv3 - Removed LICENSE.GPL Change-Id: Iec3406e3eb3f133be549092015cefe33d259a3f2 Reviewed-by: Iikka Eklund <iikka.eklund@digia.com>
* | Android: use qEnvironmentVariableIntValue()Marc Mutz2014-09-121-1/+1
|/ | | | | | | | It doesn't allocate memory, so cannot throw and is a lot faster than qgetenv(). Change-Id: I6d79852613228658f9093a272edf9b434e60286c Reviewed-by: Paul Olav Tvete <paul.tvete@digia.com>
* Forward menu button events to Qt if there is no visible menubar.BogDan Vatra2014-08-161-0/+9
| | | | | | Task-number: QTBUG-32334 Change-Id: If1b4517f233b04d4c6c165cbfe62c8cf7b624c60 Reviewed-by: Paul Olav Tvete <paul.tvete@digia.com>
* Android: Fix namespace usageChristian Strømme2014-06-301-0/+4
| | | | | | | This change makes it possible to set a Qt namespace for Android builds. Change-Id: I79f4ae8200223f36f97e2849aae49e45b8850d23 Reviewed-by: Eskil Abrahamsen Blomfeldt <eskil.abrahamsen-blomfeldt@digia.com>
* Android: Don't crash on 100+ combo box itemsEskil Abrahamsen Blomfeldt2014-01-201-7/+8
| | | | | | | | | | | | | | | | Local references are valid until the original native method returns (if it's a Java thread), or until the current thread is detached from the VM. This means that we have to manually manage local references and delete them when they are no longer in use, otherwise we will leak memory and flood JNI's local reference array. [ChangeLog][Android] Fixed crash on populating large combo boxes or menus. Task-number: QTBUG-36074 Change-Id: I7095bd1472f759be98183737a8d3912fa9763f30 Reviewed-by: Christian Stromme <christian.stromme@digia.com>
* Support multiple native surfaces on Android.BogDan Vatra2014-01-171-0/+429
Support for multiple native surfaces is needed by applications that need to mix raster windows with GL windows. Rework the raster and opengl implementation, get rid of eglfs and fbconvenience dependencies. Create a single android platform plugin. [ChangeLog][Android] Rework the raster and opengl implementation. [ChangeLog][Android] Create a single android platform plugin. Task-number: QTBUG-34650 Change-Id: I9b1ab51554823329dda8cfbf8fef27c38f917c7b Reviewed-by: Paul Olav Tvete <paul.tvete@digia.com>