void BarDescriptorEditorWidget::initGeneralPage()
{
    ProjectExplorer::PanelsWidget *generalPanel = new ProjectExplorer::PanelsWidget(this);
    initPanelSize(generalPanel);
    addWidget(generalPanel);

    // Entry-Point Text and Images
    ProjectExplorer::PropertiesPanel *entryPointPanel = new ProjectExplorer::PropertiesPanel;
    m_entryPointWidget = new BarDescriptorEditorEntryPointWidget;
    entryPointPanel->setDisplayName(tr("Entry-Point Text and Images"));
    entryPointPanel->setWidget(m_entryPointWidget);
    generalPanel->addPropertiesPanel(entryPointPanel);

    // Package Information
    ProjectExplorer::PropertiesPanel *packageInformationPanel = new ProjectExplorer::PropertiesPanel;
    m_packageInformationWidget = new BarDescriptorEditorPackageInformationWidget;
    packageInformationPanel->setDisplayName(tr("Package Information"));
    packageInformationPanel->setWidget(m_packageInformationWidget);
    generalPanel->addPropertiesPanel(packageInformationPanel);

    // Author information
    ProjectExplorer::PropertiesPanel *authorInformationPanel = new ProjectExplorer::PropertiesPanel;
    m_authorInformationWidget = new BarDescriptorEditorAuthorInformationWidget;
    authorInformationPanel->setDisplayName(tr("Author Information"));
    authorInformationPanel->setWidget(m_authorInformationWidget);
    generalPanel->addPropertiesPanel(authorInformationPanel);

    connect(m_entryPointWidget, SIGNAL(changed()), this, SLOT(setDirty()));
    connect(m_packageInformationWidget, SIGNAL(changed()), this, SLOT(setDirty()));
    connect(m_authorInformationWidget, SIGNAL(changed()), this, SLOT(setDirty()));
}
void BarDescriptorEditorWidget::initApplicationPage()
{
    ProjectExplorer::PanelsWidget *applicationPanel = new ProjectExplorer::PanelsWidget(this);
    initPanelSize(applicationPanel);
    addWidget(applicationPanel);

    // General
    ProjectExplorer::PropertiesPanel *generalPanel = new ProjectExplorer::PropertiesPanel;
    m_generalWidget = new BarDescriptorEditorGeneralWidget;
    generalPanel->setDisplayName(tr("General"));
    generalPanel->setWidget(m_generalWidget);
    applicationPanel->addPropertiesPanel(generalPanel);

    //Permissions
    ProjectExplorer::PropertiesPanel *permissionsPanel = new ProjectExplorer::PropertiesPanel;
    m_permissionsWidget = new BarDescriptorEditorPermissionsWidget;
    permissionsPanel->setDisplayName(tr("Permissions"));
    permissionsPanel->setWidget(m_permissionsWidget);
    applicationPanel->addPropertiesPanel(permissionsPanel);

    // Environment
    ProjectExplorer::PropertiesPanel *environmentPanel = new ProjectExplorer::PropertiesPanel;
    m_environmentWidget = new BarDescriptorEditorEnvironmentWidget;
    environmentPanel->setDisplayName(tr("Environment"));
    environmentPanel->setWidget(m_environmentWidget);
    applicationPanel->addPropertiesPanel(environmentPanel);

    connect(m_generalWidget, SIGNAL(changed()), this, SLOT(setDirty()));
    connect(m_permissionsWidget, SIGNAL(changed()), this, SLOT(setDirty()));
    connect(m_environmentWidget, SIGNAL(changed()), this, SLOT(setDirty()));
}
Ejemplo n.º 3
0
ProjectExplorer::PropertiesPanel *Qt4ProjectManager::Internal::UnconfiguredProjectPanel::createPanel(ProjectExplorer::Project *project)
{
    ProjectExplorer::PropertiesPanel *panel = new ProjectExplorer::PropertiesPanel;
    panel->setDisplayName(displayName());
    panel->setIcon(QIcon(QLatin1String(":/projectexplorer/images/unconfigured.png")));

    TargetSetupPageWrapper *w = new TargetSetupPageWrapper(project);
    panel->setWidget(w);
    return panel;
}
void BarDescriptorEditorWidget::initAssetsPage()
{
    ProjectExplorer::PanelsWidget *assetsPanel = new ProjectExplorer::PanelsWidget(this);
    initPanelSize(assetsPanel);
    addWidget(assetsPanel);

    ProjectExplorer::PropertiesPanel *assetsPropertiesPanel = new ProjectExplorer::PropertiesPanel;
    m_assetsWidget = new BarDescriptorEditorAssetsWidget;
    assetsPropertiesPanel->setDisplayName(tr("Assets"));
    assetsPropertiesPanel->setWidget(m_assetsWidget);
    assetsPanel->addPropertiesPanel(assetsPropertiesPanel);

    connect(m_assetsWidget, SIGNAL(changed()), this, SLOT(setDirty()));

    m_entryPointWidget->setAssetsModel(m_assetsWidget->assetsModel());
    connect(m_entryPointWidget, SIGNAL(imageAdded(QString)), m_assetsWidget, SLOT(addAsset(QString)));
    connect(m_entryPointWidget, SIGNAL(imageRemoved(QString)), m_assetsWidget, SLOT(removeAsset(QString)));
}