mvdMaplaApplication.cxx 2.96 KB
Newer Older
1 2 3 4 5 6 7 8 9 10 11 12 13 14 15 16 17 18 19
/*
 * Copyright (C) 2005-2017 Centre National d'Etudes Spatiales (CNES)
 *
 * This file is part of Orfeo Toolbox
 *
 *     https://www.orfeo-toolbox.org/
 *
 * Licensed under the Apache License, Version 2.0 (the "License");
 * you may not use this file except in compliance with the License.
 * You may obtain a copy of the License at
 *
 *     http://www.apache.org/licenses/LICENSE-2.0
 *
 * Unless required by applicable law or agreed to in writing, software
 * distributed under the License is distributed on an "AS IS" BASIS,
 * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
 * See the License for the specific language governing permissions and
 * limitations under the License.
 */
20

21
#include "mvdMaplaApplication.h"
22 23 24 25 26 27 28 29 30 31 32 33 34 35


/*****************************************************************************/
/* INCLUDE SECTION                                                           */

//
// Qt includes (sorted by alphabetic order)
//// Must be included before system/custom includes.

//
// System includes (sorted by alphabetic order)

//
// OTB includes (sorted by alphabetic order)
36
#include "otbWrapperApplicationRegistry.h"
37 38 39 40 41

//
// Monteverdi includes (sorted by alphabetic order)

//
42
#ifdef OTB_USE_QT
43
#include "mvdOTBApplicationsModel.h"
44 45 46 47 48 49 50 51
#endif

//
// Class implementation.
namespace mvd
{

/*
52
  TRANSLATOR mvd::MaplaApplication
53 54 55 56 57 58 59 60 61 62 63 64 65 66 67 68 69

  Necessary for lupdate to be aware of C++ namespaces.

  Context comment for translator.
*/

/*****************************************************************************/
/* CONSTANTS                                                                 */

/*****************************************************************************/
/* STATIC IMPLEMENTATION SECTION                                             */


/*****************************************************************************/
/* CLASS IMPLEMENTATION SECTION                                              */

/*******************************************************************************/
70 71
MaplaApplication
::MaplaApplication( QApplication* qtApp ) :
72 73 74 75 76
  I18nApplication( qtApp )
{
}

/*******************************************************************************/
77 78
MaplaApplication
::~MaplaApplication()
79
{
80
  otb::Wrapper::ApplicationRegistry::CleanRegistry();
81 82 83 84
}

/*******************************************************************************/
void
85
MaplaApplication
86 87 88 89
::virtual_InitializeCore()
{
  I18nApplication::virtual_InitializeCore();

90
  setObjectName( "MaplaApplication" );
91 92

  InitializeCore(
93 94 95 96
    "Monteverdi Application Launcher",
    QString( "OTB %1" ).arg( OTB_VERSION_STRING ),
    "OrfeoToolBox",
    "orfeo-toolbox.org"
97
  );
98
}
99

100 101
/*******************************************************************************/
void
102
MaplaApplication
103 104
::Foo()
{
105 106 107 108 109 110 111
  SetModel( new OTBApplicationsModel( this ) );
}

/*******************************************************************************/
/* SLOTS                                                                       */

} // end namespace 'mvd'