~ubuntu-branches/ubuntu/wily/tora/wily-proposed

« back to all changes in this revision

Viewing changes to tosecurityroleui.cpp

  • Committer: Bazaar Package Importer
  • Author(s): Albin Tonnerre
  • Date: 2007-05-29 13:13:36 UTC
  • mfrom: (1.2.4 upstream)
  • Revision ID: james.westby@ubuntu.com-20070529131336-85ygaddivvmkd3xc
Tags: 1.3.21pre22-1ubuntu1
* Merge from Debian unstable. Remaining Ubuntu changes:
  - debian/rules: call dh_iconcache
  - Remove g++ build dependency
* Modify Maintainer value to match Debian-Maintainer-Field Spec

Show diffs side-by-side

added added

removed removed

Lines of Context:
1
 
/****************************************************************************
2
 
** Form implementation generated from reading ui file 'tosecurityroleui.ui'
3
 
**
4
 
** Created: Mon Feb 20 12:46:41 2006
5
 
**      by: The User Interface Compiler ($Id: qt/main.cpp   3.3.4   edited Nov 24 2003 $)
6
 
**
7
 
** WARNING! All changes made in this file will be lost!
8
 
****************************************************************************/
9
 
 
10
 
#include "tosecurityroleui.h"
11
 
 
12
 
#include <qvariant.h>
13
 
#include <qpushbutton.h>
14
 
#include <qlineedit.h>
15
 
#include <qlabel.h>
16
 
#include <qtabwidget.h>
17
 
#include <qlayout.h>
18
 
#include <qtooltip.h>
19
 
#include <qwhatsthis.h>
20
 
 
21
 
/*
22
 
 *  Constructs a toSecurityRoleUI as a child of 'parent', with the
23
 
 *  name 'name' and widget flags set to 'f'.
24
 
 */
25
 
toSecurityRoleUI::toSecurityRoleUI( QWidget* parent, const char* name, WFlags fl )
26
 
    : QWidget( parent, name, fl )
27
 
{
28
 
    if ( !name )
29
 
        setName( "toSecurityRoleUI" );
30
 
    toSecurityRoleUILayout = new QGridLayout( this, 1, 1, 11, 6, "toSecurityRoleUILayout"); 
31
 
 
32
 
    Name = new QLineEdit( this, "Name" );
33
 
 
34
 
    toSecurityRoleUILayout->addWidget( Name, 0, 1 );
35
 
 
36
 
    NameLabel = new QLabel( this, "NameLabel" );
37
 
 
38
 
    toSecurityRoleUILayout->addWidget( NameLabel, 0, 0 );
39
 
 
40
 
    Authentication = new QTabWidget( this, "Authentication" );
41
 
    Authentication->setSizePolicy( QSizePolicy( (QSizePolicy::SizeType)7, (QSizePolicy::SizeType)1, 0, 0, Authentication->sizePolicy().hasHeightForWidth() ) );
42
 
 
43
 
    PasswordTab = new QWidget( Authentication, "PasswordTab" );
44
 
    PasswordTabLayout = new QGridLayout( PasswordTab, 1, 1, 11, 6, "PasswordTabLayout"); 
45
 
 
46
 
    TextLabel4 = new QLabel( PasswordTab, "TextLabel4" );
47
 
 
48
 
    PasswordTabLayout->addWidget( TextLabel4, 0, 0 );
49
 
 
50
 
    Password = new QLineEdit( PasswordTab, "Password" );
51
 
    Password->setEchoMode( QLineEdit::Password );
52
 
 
53
 
    PasswordTabLayout->addWidget( Password, 0, 1 );
54
 
 
55
 
    Password2 = new QLineEdit( PasswordTab, "Password2" );
56
 
    Password2->setEchoMode( QLineEdit::Password );
57
 
 
58
 
    PasswordTabLayout->addWidget( Password2, 1, 1 );
59
 
 
60
 
    TextLabel4_2 = new QLabel( PasswordTab, "TextLabel4_2" );
61
 
 
62
 
    PasswordTabLayout->addWidget( TextLabel4_2, 1, 0 );
63
 
    Spacer1 = new QSpacerItem( 20, 20, QSizePolicy::Expanding, QSizePolicy::Minimum );
64
 
    PasswordTabLayout->addItem( Spacer1, 1, 2 );
65
 
    Authentication->insertTab( PasswordTab, QString::fromLatin1("") );
66
 
 
67
 
    ExternalTab = new QWidget( Authentication, "ExternalTab" );
68
 
    ExternalTabLayout = new QGridLayout( ExternalTab, 1, 1, 11, 6, "ExternalTabLayout"); 
69
 
 
70
 
    TextLabel3 = new QLabel( ExternalTab, "TextLabel3" );
71
 
 
72
 
    ExternalTabLayout->addWidget( TextLabel3, 0, 0 );
73
 
    Authentication->insertTab( ExternalTab, QString::fromLatin1("") );
74
 
 
75
 
    GlobalTab = new QWidget( Authentication, "GlobalTab" );
76
 
    GlobalTabLayout = new QGridLayout( GlobalTab, 1, 1, 11, 6, "GlobalTabLayout"); 
77
 
 
78
 
    TextLabel3_2 = new QLabel( GlobalTab, "TextLabel3_2" );
79
 
 
80
 
    GlobalTabLayout->addWidget( TextLabel3_2, 0, 0 );
81
 
    Authentication->insertTab( GlobalTab, QString::fromLatin1("") );
82
 
 
83
 
    NoneTab = new QWidget( Authentication, "NoneTab" );
84
 
    NoneTabLayout = new QGridLayout( NoneTab, 1, 1, 11, 6, "NoneTabLayout"); 
85
 
 
86
 
    TextLabel1 = new QLabel( NoneTab, "TextLabel1" );
87
 
 
88
 
    NoneTabLayout->addWidget( TextLabel1, 0, 0 );
89
 
    Authentication->insertTab( NoneTab, QString::fromLatin1("") );
90
 
 
91
 
    toSecurityRoleUILayout->addMultiCellWidget( Authentication, 1, 1, 0, 1 );
92
 
    Spacer1_2 = new QSpacerItem( 20, 20, QSizePolicy::Minimum, QSizePolicy::Expanding );
93
 
    toSecurityRoleUILayout->addItem( Spacer1_2, 2, 1 );
94
 
    languageChange();
95
 
    resize( QSize(576, 480).expandedTo(minimumSizeHint()) );
96
 
    clearWState( WState_Polished );
97
 
 
98
 
    // buddies
99
 
    NameLabel->setBuddy( Name );
100
 
    TextLabel4->setBuddy( Password );
101
 
    TextLabel4_2->setBuddy( Password2 );
102
 
}
103
 
 
104
 
/*
105
 
 *  Destroys the object and frees any allocated resources
106
 
 */
107
 
toSecurityRoleUI::~toSecurityRoleUI()
108
 
{
109
 
    // no need to delete child widgets, Qt does it all for us
110
 
}
111
 
 
112
 
/*
113
 
 *  Sets the strings of the subwidgets using the current
114
 
 *  language.
115
 
 */
116
 
void toSecurityRoleUI::languageChange()
117
 
{
118
 
    setCaption( tr( "Form2" ) );
119
 
    NameLabel->setText( tr( "&Name" ) );
120
 
    TextLabel4->setText( tr( "Enter Password" ) );
121
 
    TextLabel4_2->setText( tr( "Confirm Password" ) );
122
 
    Authentication->changeTab( PasswordTab, tr( "&Password" ) );
123
 
    TextLabel3->setText( tr( "Role authenticated by the operating system" ) );
124
 
    Authentication->changeTab( ExternalTab, tr( "&External" ) );
125
 
    TextLabel3_2->setText( tr( "Role authenticated globally" ) );
126
 
    Authentication->changeTab( GlobalTab, tr( "&Global" ) );
127
 
    TextLabel1->setText( tr( "No password required for role" ) );
128
 
    Authentication->changeTab( NoneTab, tr( "None" ) );
129
 
}
130