Wt examples: composer/AddresseeEdit.h Source File

Wt examples 4.10.4

Loading...
Searching...
No Matches
AddresseeEdit.h
Go to the documentation of this file.
1// This may look like C code, but it's really -*- C++ -*-
2/*
3 * Copyright (C) 2008 Emweb bv, Herent, Belgium.
4 *
5 * See the LICENSE file for terms of use.
6 */
7#ifndef ADDRESSEE_EDIT_H_
8#define ADDRESSEE_EDIT_H_
9
10#include <Wt/WTextArea.h>
11
12#include "Contact.h"
13
14using namespace Wt;
15
16 namespace Wt {
17 class WTableCell;
18}
19
20class Label;
21
26
31 class AddresseeEdit : public WTextArea
32{
33public:
39 AddresseeEdit(const WString& label, WContainerWidget *labelParent);
40
43 void setAddressees(const std::vector<Contact>& contacts);
44
47 std::vector<Contact> addressees() const;
48
50 virtual void setHidden(bool hidden, const WAnimation& animation);
51
52private:
54 Label *label_;
55
57 bool parse(std::vector<Contact>& contacts) const;
58};
59
61
62
63#endif // ADDRESSEE_EDIT_H_
Contact.h
AddresseeEdit
An edit field for an email addressee.
Definition AddresseeEdit.h:32
AddresseeEdit::AddresseeEdit
AddresseeEdit(const WString &label, WContainerWidget *labelParent)
Create a new addressee edit with the given label.
Definition AddresseeEdit.C:16
AddresseeEdit::setHidden
virtual void setHidden(bool hidden, const WAnimation &animation)
Reimplement hide() and show() to also hide() and show() the label.
Definition AddresseeEdit.C:82
AddresseeEdit::addressees
std::vector< Contact > addressees() const
Get a list of addressees.
Definition AddresseeEdit.C:74
AddresseeEdit::label_
Label * label_
The label associated with this edit.
Definition AddresseeEdit.h:54
AddresseeEdit::parse
bool parse(std::vector< Contact > &contacts) const
Parse the addressees into a list of contacts.
Definition AddresseeEdit.C:40
AddresseeEdit::setAddressees
void setAddressees(const std::vector< Contact > &contacts)
Set a list of addressees.
Definition AddresseeEdit.C:27
Label
A label.
Definition Label.h:25
Wt
Definition AddresseeEdit.h:16