~ubuntu-branches/debian/jessie/ugene/jessie

« back to all changes in this revision

Viewing changes to src/plugins_3rdparty/gor4/src/GorIVPlugin.cpp

  • Committer: Package Import Robot
  • Author(s): Steffen Moeller
  • Date: 2011-11-02 13:29:07 UTC
  • mfrom: (1.2.1) (3.1.11 natty)
  • Revision ID: package-import@ubuntu.com-20111102132907-o34gwnt0uj5g6hen
Tags: 1.9.8+repack-1
* First release to Debian
  - added README.Debian
  - increased policy version to 3.9.2
  - added URLs for version control system
* Added debug package.

Show diffs side-by-side

added added

removed removed

Lines of Context:
 
1
/**
 
2
 * UGENE - Integrated Bioinformatics Tools.
 
3
 * Copyright (C) 2008-2011 UniPro <ugene@unipro.ru>
 
4
 * http://ugene.unipro.ru
 
5
 *
 
6
 * This program is free software; you can redistribute it and/or
 
7
 * modify it under the terms of the GNU General Public License
 
8
 * as published by the Free Software Foundation; either version 2
 
9
 * of the License, or (at your option) any later version.
 
10
 *
 
11
 * This program is distributed in the hope that it will be useful,
 
12
 * but WITHOUT ANY WARRANTY; without even the implied warranty of
 
13
 * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the
 
14
 * GNU General Public License for more details.
 
15
 *
 
16
 * You should have received a copy of the GNU General Public License
 
17
 * along with this program; if not, write to the Free Software
 
18
 * Foundation, Inc., 51 Franklin Street, Fifth Floor, Boston,
 
19
 * MA 02110-1301, USA.
 
20
 */
 
21
 
 
22
#include <QtGui/QMenu>
 
23
#include <QtGui/QAction>
 
24
#include <QtGui/QMessageBox>
 
25
#include <QtCore/QMap>
 
26
#include <QtCore/QFile>
 
27
 
 
28
#include <U2Core/GAutoDeleteList.h>
 
29
#include <U2Gui/GUIUtils.h>
 
30
#include <U2View/AnnotatedDNAView.h>
 
31
#include <U2View/ADVConstants.h>
 
32
#include <U2View/ADVSequenceObjectContext.h>
 
33
#include <U2View/ADVUtils.h>
 
34
#include <U2Core/AppContext.h>
 
35
#include <U2Algorithm/SecStructPredictAlgRegistry.h>
 
36
#include <U2Core/BioStruct3D.h>
 
37
#include <U2Core/AnnotationSettings.h>
 
38
#include <U2Algorithm/SecStructPredictTask.h>
 
39
 
 
40
#include "GorIVPlugin.h"
 
41
#include "GorIVAlgTask.h"
 
42
#include "gor.h"
 
43
 
 
44
namespace U2 {
 
45
 
 
46
extern "C" Q_DECL_EXPORT Plugin* U2_PLUGIN_INIT_FUNC() {
 
47
    SecStructPredictPlugin* plug = new SecStructPredictPlugin();
 
48
    return plug;
 
49
}
 
50
 
 
51
SecStructPredictPlugin::SecStructPredictPlugin() : Plugin(tr("GORIV"), tr("GORIV protein secondary structure prediction")) {
 
52
    // Register GORIV algorithm
 
53
    SecStructPredictAlgRegistry* registry = AppContext::getSecStructPredictAlgRegistry();
 
54
    SecStructPredictTaskFactory* taskFactory = new GorIVAlgTask::Factory;
 
55
    registry->registerAlgorithm(taskFactory, GorIVAlgTask::taskName);
 
56
 
 
57
    //Register GORIV annotation settings
 
58
    AnnotationSettingsRegistry* asr =AppContext::getAnnotationsSettingsRegistry();
 
59
    AnnotationSettings* as = new AnnotationSettings(GORIV_ANNOTATION_NAME, true, QColor(102,255, 0), true);
 
60
    as->nameQuals.append(BioStruct3D::SecStructTypeQualifierName);
 
61
    asr->changeSettings(QList<AnnotationSettings*>() << as, false);
 
62
}
 
63
 
 
64
SecStructPredictPlugin::~SecStructPredictPlugin() {
 
65
}
 
66
 
 
67
 
 
68
}//namespace
 
69