Public Member Functions | Static Public Attributes

QmitkExtAppWorkbenchAdvisor Class Reference

#include <QmitkExtAppWorkbenchAdvisor.h>

Inheritance diagram for QmitkExtAppWorkbenchAdvisor:
Inheritance graph
[legend]
Collaboration diagram for QmitkExtAppWorkbenchAdvisor:
Collaboration graph
[legend]

List of all members.

Public Member Functions

void Initialize (berry::IWorkbenchConfigurer::Pointer configurer)
berry::WorkbenchWindowAdvisorCreateWorkbenchWindowAdvisor (berry::IWorkbenchWindowConfigurer::Pointer configurer)
std::string GetInitialWindowPerspectiveId ()

Static Public Attributes

static const std::string DEFAULT_PERSPECTIVE_ID = "org.mitk.extapp.defaultperspective"

Detailed Description

Definition at line 32 of file QmitkExtAppWorkbenchAdvisor.h.


Member Function Documentation

berry::WorkbenchWindowAdvisor * QmitkExtAppWorkbenchAdvisor::CreateWorkbenchWindowAdvisor ( berry::IWorkbenchWindowConfigurer::Pointer  configurer ) [virtual]

Implements berry::WorkbenchAdvisor.

Definition at line 49 of file QmitkExtAppWorkbenchAdvisor.cpp.

References QmitkExtWorkbenchWindowAdvisor::SetWindowIcon().

{
  QmitkExtWorkbenchWindowAdvisor* advisor = new
    QmitkExtWorkbenchWindowAdvisor(this, configurer);
  advisor->SetWindowIcon(":/QmitkExtApplication/icon_research.xpm");
  return advisor;
  //return new QmitkExtWorkbenchWindowAdvisor(this, configurer);
}
std::string QmitkExtAppWorkbenchAdvisor::GetInitialWindowPerspectiveId (  ) [virtual]

Implements berry::WorkbenchAdvisor.

Definition at line 59 of file QmitkExtAppWorkbenchAdvisor.cpp.

References DEFAULT_PERSPECTIVE_ID.

void QmitkExtAppWorkbenchAdvisor::Initialize ( berry::IWorkbenchConfigurer::Pointer  configurer ) [virtual]

Reimplemented from berry::QtWorkbenchAdvisor.

Definition at line 28 of file QmitkExtAppWorkbenchAdvisor.cpp.

References QmitkExtApplicationPlugin::GetBundleContext(), QmitkExtApplicationPlugin::GetDefault(), QmitkExtApplicationPlugin::GetQtHelpCollectionFile(), berry::QtAssistantUtil::RegisterQCHFiles(), berry::QtAssistantUtil::SetDefaultHelpUrl(), and berry::QtAssistantUtil::SetHelpColletionFile().

{
  berry::QtWorkbenchAdvisor::Initialize(configurer);

  configurer->SetSaveAndRestore(true);

  QString collectionFile = QmitkExtApplicationPlugin::GetDefault()->GetQtHelpCollectionFile();
  if (!collectionFile.isEmpty())
  {
    berry::IBundleContext::Pointer context = QmitkExtApplicationPlugin::GetDefault()->GetBundleContext();
    typedef std::vector<berry::IBundle::Pointer> BundleContainer;
    BundleContainer bundles;
    context->ListBundles(bundles);
    berry::QtAssistantUtil::RegisterQCHFiles(collectionFile, bundles);
  }

  berry::QtAssistantUtil::SetHelpColletionFile(collectionFile);
  berry::QtAssistantUtil::SetDefaultHelpUrl("qthelp://org.mitk.gui.qt.extapplication/bundle/index.html");
}

Member Data Documentation

const std::string QmitkExtAppWorkbenchAdvisor::DEFAULT_PERSPECTIVE_ID = "org.mitk.extapp.defaultperspective" [static]

Definition at line 36 of file QmitkExtAppWorkbenchAdvisor.h.

Referenced by GetInitialWindowPerspectiveId().


The documentation for this class was generated from the following files:
 All Classes Namespaces Files Functions Variables Typedefs Enumerations Enumerator Properties Friends Defines