forked from qt-creator/qt-creator
Use QObjectList alias
Change-Id: I11d4071088e2b44c37d4a8ac59945fe49fe68351 Reviewed-by: hjk <hjk@qt.io>
This commit is contained in:
@@ -17,7 +17,7 @@ struct Group
|
||||
{
|
||||
Group(Utils::Id id) : id(id) {}
|
||||
Utils::Id id;
|
||||
QList<QObject *> items; // Command * or ActionContainer *
|
||||
QObjectList items; // Command * or ActionContainer *
|
||||
};
|
||||
|
||||
class ActionContainerPrivate : public ActionContainer
|
||||
|
||||
@@ -376,7 +376,7 @@ void FormEditorData::fullInit()
|
||||
/**
|
||||
* This will initialize our TabOrder, Signals and slots and Buddy editors.
|
||||
*/
|
||||
const QList<QObject *> plugins = QPluginLoader::staticInstances() + m_formeditor->pluginInstances();
|
||||
const QObjectList plugins = QPluginLoader::staticInstances() + m_formeditor->pluginInstances();
|
||||
for (QObject *plugin : plugins) {
|
||||
if (QDesignerFormEditorPluginInterface *formEditorPlugin = qobject_cast<QDesignerFormEditorPluginInterface*>(plugin)) {
|
||||
if (!formEditorPlugin->isInitialized())
|
||||
|
||||
@@ -99,7 +99,7 @@ private:
|
||||
QMenu *m_filterMenu = nullptr;
|
||||
QToolButton *m_aggregateButton = nullptr;
|
||||
QToolButton *m_tracePointsButton = nullptr;
|
||||
QList<QObject *> m_objectsToDelete;
|
||||
QObjectList m_objectsToDelete;
|
||||
|
||||
PerfProfilerTraceView *m_traceView = nullptr;
|
||||
PerfProfilerStatisticsView *m_statisticsView = nullptr;
|
||||
|
||||
@@ -150,7 +150,7 @@ class GenericModel : public TreeModel<GenericItem, GenericItem>
|
||||
public:
|
||||
GenericModel(QObject *parent) : TreeModel(parent) { }
|
||||
|
||||
void rebuild(const QList<QObject *> &objects)
|
||||
void rebuild(const QObjectList &objects)
|
||||
{
|
||||
clear();
|
||||
for (QObject * const e : objects)
|
||||
@@ -249,8 +249,8 @@ public:
|
||||
explicit ProjectListView(QWidget *parent = nullptr) : SelectorView(parent)
|
||||
{
|
||||
const auto model = new GenericModel(this);
|
||||
model->rebuild(transform<QList<QObject *>>(ProjectManager::projects(),
|
||||
[](Project *p) { return p; }));
|
||||
model->rebuild(transform<QObjectList>(ProjectManager::projects(),
|
||||
[](Project *p) { return p; }));
|
||||
connect(ProjectManager::instance(), &ProjectManager::projectAdded,
|
||||
this, [this, model](Project *project) {
|
||||
const GenericItem *projectItem = model->addItemForObject(project);
|
||||
@@ -322,7 +322,7 @@ signals:
|
||||
void changeActiveProjectConfiguration(QObject *pc);
|
||||
|
||||
public:
|
||||
void setProjectConfigurations(const QList<QObject *> &list, QObject *active)
|
||||
void setProjectConfigurations(const QObjectList &list, QObject *active)
|
||||
{
|
||||
theModel()->rebuild(list);
|
||||
resetOptimalWidth();
|
||||
@@ -1194,13 +1194,13 @@ void MiniProjectTargetSelector::changeStartupProject(Project *project)
|
||||
}
|
||||
|
||||
if (project) {
|
||||
QList<QObject *> list;
|
||||
QObjectList list;
|
||||
const QList<Target *> targets = project->targets();
|
||||
for (Target *t : targets)
|
||||
list.append(t);
|
||||
m_listWidgets[TARGET]->setProjectConfigurations(list, project->activeTarget());
|
||||
} else {
|
||||
m_listWidgets[TARGET]->setProjectConfigurations(QList<QObject *>(), nullptr);
|
||||
m_listWidgets[TARGET]->setProjectConfigurations({}, nullptr);
|
||||
}
|
||||
|
||||
updateActionAndSummary();
|
||||
@@ -1239,17 +1239,17 @@ void MiniProjectTargetSelector::activeTargetChanged(Target *target)
|
||||
this, &MiniProjectTargetSelector::updateActionAndSummary);
|
||||
|
||||
if (m_target) {
|
||||
QList<QObject *> bl;
|
||||
QObjectList bl;
|
||||
for (BuildConfiguration *bc : target->buildConfigurations())
|
||||
bl.append(bc);
|
||||
m_listWidgets[BUILD]->setProjectConfigurations(bl, target->activeBuildConfiguration());
|
||||
|
||||
QList<QObject *> dl;
|
||||
QObjectList dl;
|
||||
for (DeployConfiguration *dc : target->deployConfigurations())
|
||||
dl.append(dc);
|
||||
m_listWidgets[DEPLOY]->setProjectConfigurations(dl, target->activeDeployConfiguration());
|
||||
|
||||
QList<QObject *> rl;
|
||||
QObjectList rl;
|
||||
for (RunConfiguration *rc : target->runConfigurations())
|
||||
rl.append(rc);
|
||||
m_listWidgets[RUN]->setProjectConfigurations(rl, target->activeRunConfiguration());
|
||||
@@ -1278,9 +1278,9 @@ void MiniProjectTargetSelector::activeTargetChanged(Target *target)
|
||||
connect(m_target, &Target::activeRunConfigurationChanged,
|
||||
this, &MiniProjectTargetSelector::activeRunConfigurationChanged);
|
||||
} else {
|
||||
m_listWidgets[BUILD]->setProjectConfigurations(QList<QObject *>(), nullptr);
|
||||
m_listWidgets[DEPLOY]->setProjectConfigurations(QList<QObject *>(), nullptr);
|
||||
m_listWidgets[RUN]->setProjectConfigurations(QList<QObject *>(), nullptr);
|
||||
m_listWidgets[BUILD]->setProjectConfigurations({}, nullptr);
|
||||
m_listWidgets[DEPLOY]->setProjectConfigurations({}, nullptr);
|
||||
m_listWidgets[RUN]->setProjectConfigurations({}, nullptr);
|
||||
m_buildConfiguration = nullptr;
|
||||
m_deployConfiguration = nullptr;
|
||||
m_runConfiguration = nullptr;
|
||||
|
||||
@@ -693,7 +693,7 @@ void Edit3DView::createSeekerSliderAction()
|
||||
QPoint Edit3DView::resolveToolbarPopupPos(Edit3DAction *action) const
|
||||
{
|
||||
QPoint pos;
|
||||
const QList<QObject *> &objects = action->action()->associatedObjects();
|
||||
const QObjectList &objects = action->action()->associatedObjects();
|
||||
for (QObject *obj : objects) {
|
||||
if (auto button = qobject_cast<QToolButton *>(obj)) {
|
||||
if (auto toolBar = qobject_cast<QWidget *>(button->parent())) {
|
||||
|
||||
@@ -75,7 +75,7 @@ private:
|
||||
void addSpacing(int width);
|
||||
void setupCurrentFrameValidator();
|
||||
|
||||
QList<QObject *> m_grp;
|
||||
QObjectList m_grp;
|
||||
|
||||
QLabel *m_timelineLabel = nullptr;
|
||||
QLabel *m_stateLabel = nullptr;
|
||||
|
||||
@@ -56,7 +56,7 @@ private:
|
||||
void createRightControls();
|
||||
void addSpacing(int width);
|
||||
|
||||
QList<QObject *> m_grp;
|
||||
QObjectList m_grp;
|
||||
|
||||
QComboBox *m_transitionComboBox = nullptr;
|
||||
QSlider *m_scale = nullptr;
|
||||
|
||||
Reference in New Issue
Block a user