~ubuntu-branches/ubuntu/trusty/clustalx/trusty

« back to all changes in this revision

Viewing changes to SearchForString.cpp

  • Committer: Bazaar Package Importer
  • Author(s): Charles Plessy, Steffen Moeller, Charles Plessy
  • Date: 2009-10-21 13:25:44 UTC
  • mfrom: (1.1.1 upstream)
  • Revision ID: james.westby@ubuntu.com-20091021132544-r4hbcnjxp354wxh0
Tags: 2.0.12-1
* New upstream release (LP: #423648, #393769):
  - Uses Qt instead of lesstif.
  - Includes new code for UPGMA guide trees.
  - Includes iterative alignment facility.

[ Steffen Moeller ]
* New upstream release.
* Updated watch file (Closes: #550893).
* Removed LICENSE from debian/clustalx.docs
* rename to clustalx seems no longer required in debian/rules
* moved clustalx.1 into debian folder (eases working with svn-buildpackage)
* added German translation to desktop file

[ Charles Plessy ]
* Updated my email address.
* debian/copyright made machine-readable.
* Added various informations in debian/upstream-metadata.yaml.
* Switched to Debhelper 7.
  (debian/rules, debian/control, debian/patches, debian/compat)
* Removed useless Debhelper file debian/clustalx.dirs.
* Updated package description.
* Hardcoded the localisation of accessory files in /usr/share/clustalx.
  (debian/patches/hardcode-accessory-file-locations.patch)
* Documented in debian/README.source that the documentation for quilt
  is in /usr/share/doc/quilt.
* Added upstream changelog downloaded from upstream website
  (debian/rules, debian/CHANGELOG.upstream).
* Incremented Standards-Version to reflect conformance with Policy 3.8.3
  (debian/control, no other changes needed).
* Updated homepage in debian/clustalw.1.

Show diffs side-by-side

added added

removed removed

Lines of Context:
 
1
/**
 
2
 * Changes: 
 
3
 * 12-4-07, Mark Larkin, Removed destructor. No need to delete QObjects. 
 
4
 */
 
5
#include "SearchForString.h"
 
6
#include <QPushButton>
 
7
#include <QGroupBox>
 
8
#include <QLineEdit>
 
9
#include <QVBoxLayout>
 
10
 
 
11
SearchForString::SearchForString()
 
12
{
 
13
    searchString = new QLineEdit("");
 
14
    searchFromStart = new QPushButton(tr("Search From Start"));
 
15
    searchFromStart->setSizePolicy(QSizePolicy::Maximum, QSizePolicy::Maximum);
 
16
    searchAgain = new QPushButton(tr("Search Again"));
 
17
    searchAgain->setSizePolicy(QSizePolicy::Maximum, QSizePolicy::Maximum);
 
18
    closeButton = new QPushButton(tr("Close"));
 
19
    closeButton->setSizePolicy(QSizePolicy::Maximum, QSizePolicy::Maximum);
 
20
    
 
21
    connect(searchFromStart, SIGNAL(clicked()), this, SIGNAL(searchFromStartSignal()));
 
22
    connect(searchAgain, SIGNAL(clicked()), this, SIGNAL(searchAgainSignal()));
 
23
    connect(closeButton, SIGNAL(clicked()), this, SLOT(cancel()));
 
24
    
 
25
    mainLayout = new QVBoxLayout;
 
26
    mainLayout->addWidget(searchString);
 
27
    mainLayout->addWidget(searchFromStart);
 
28
    mainLayout->addWidget(searchAgain);
 
29
    mainLayout->addWidget(closeButton);
 
30
    setLayout(mainLayout);
 
31
}
 
32
 
 
33
QString SearchForString::getSearchString()
 
34
{
 
35
    return searchString->text();
 
36
}
 
37
 
 
38
void SearchForString::cancel()
 
39
{
 
40
    setResult(QDialog::Rejected);
 
41
    close();
 
42
}