Qt
Internal/Contributor docs for the Qt SDK. <b>Note:</b> These are NOT official API docs; those are found <a href='https://doc.qt.io/'>here</a>.
Loading...
Searching...
No Matches
qandroidplatformmenubar.h
Go to the documentation of this file.
1// Copyright (C) 2012 BogDan Vatra <bogdan@kde.org>
2// SPDX-License-Identifier: LicenseRef-Qt-Commercial OR LGPL-3.0-only OR GPL-2.0-only OR GPL-3.0-only
3
4#ifndef QANDROIDPLATFORMMENUBAR_H
5#define QANDROIDPLATFORMMENUBAR_H
6
7#include <qpa/qplatformmenu.h>
8#include <qhash.h>
9#include <qlist.h>
10#include <qmutex.h>
11
13
16{
17public:
18 typedef QList<QAndroidPlatformMenu *> PlatformMenusType;
19public:
22
23 void insertMenu(QPlatformMenu *menu, QPlatformMenu *before) override;
24 void removeMenu(QPlatformMenu *menu) override;
25 void syncMenu(QPlatformMenu *menu) override;
26 void handleReparent(QWindow *newParentWindow) override;
27 QPlatformMenu *menuForTag(quintptr tag) const override;
28 QPlatformMenu *menuForId(int menuId) const;
29 int menuId(QPlatformMenu *menu) const;
30
31 QWindow *parentWindow() const override;
34
35private:
36 PlatformMenusType m_menus;
37 QWindow *m_parentWindow;
38 QMutex m_menusListMutex;
39
40 int m_nextMenuId = 0;
41 QHash<int, QPlatformMenu *> m_menuHash;
42};
43
45
46#endif // QANDROIDPLATFORMMENUBAR_H
PlatformMenusType menus() const
QWindow * parentWindow() const override
void insertMenu(QPlatformMenu *menu, QPlatformMenu *before) override
void handleReparent(QWindow *newParentWindow) override
void syncMenu(QPlatformMenu *menu) override
int menuId(QPlatformMenu *menu) const
QPlatformMenu * menuForId(int menuId) const
QPlatformMenu * menuForTag(quintptr tag) const override
void removeMenu(QPlatformMenu *menu) override
QList< QAndroidPlatformMenu * > PlatformMenusType
\inmodule QtCore
Definition qmutex.h:281
\inmodule QtGui
Definition qwindow.h:63
Combined button and popup list for selecting options.
AudioChannelLayoutTag tag
size_t quintptr
Definition qtypes.h:167
QMenu menu
[5]