Diffstat (limited to 'pwmanager/pwmanager/getmasterpwwnd_emb.cpp') (more/less context) (ignore whitespace changes)
-rw-r--r-- | pwmanager/pwmanager/getmasterpwwnd_emb.cpp | 9 |
1 files changed, 6 insertions, 3 deletions
diff --git a/pwmanager/pwmanager/getmasterpwwnd_emb.cpp b/pwmanager/pwmanager/getmasterpwwnd_emb.cpp index 678f05f..7e4bbb7 100644 --- a/pwmanager/pwmanager/getmasterpwwnd_emb.cpp +++ b/pwmanager/pwmanager/getmasterpwwnd_emb.cpp | |||
@@ -34,58 +34,61 @@ $Id$ | |||
34 | #include <qlineedit.h> | 34 | #include <qlineedit.h> |
35 | #include <qlayout.h> | 35 | #include <qlayout.h> |
36 | #include <qtooltip.h> | 36 | #include <qtooltip.h> |
37 | #include <qwhatsthis.h> | 37 | #include <qwhatsthis.h> |
38 | */ | 38 | */ |
39 | 39 | ||
40 | #include <qwidget.h> | 40 | #include <qwidget.h> |
41 | #include <qlayout.h> | 41 | #include <qlayout.h> |
42 | #include <qlabel.h> | 42 | #include <qlabel.h> |
43 | #include <qlineedit.h> | 43 | #include <qlineedit.h> |
44 | #include <qpushbutton.h> | 44 | #include <qpushbutton.h> |
45 | #include <qapplication.h> | 45 | #include <qapplication.h> |
46 | //Added by qt3to4: | ||
47 | #include <Q3GridLayout> | ||
48 | #include <Q3VBoxLayout> | ||
46 | 49 | ||
47 | /* | 50 | /* |
48 | * Constructs a getMasterPwWnd as a child of 'parent', with the | 51 | * Constructs a getMasterPwWnd as a child of 'parent', with the |
49 | * name 'name' | 52 | * name 'name' |
50 | */ | 53 | */ |
51 | getMasterPwWnd::getMasterPwWnd( QWidget* parent, const char* name) | 54 | getMasterPwWnd::getMasterPwWnd( QWidget* parent, const char* name) |
52 | : KDialogBase( KDialogBase::Plain, i18n( "Master-password" ), | 55 | : KDialogBase( KDialogBase::Plain, i18n( "Master-password" ), |
53 | KDialogBase::Ok | KDialogBase::Cancel, | 56 | KDialogBase::Ok | KDialogBase::Cancel, |
54 | KDialogBase::Ok, parent, name, true ) | 57 | KDialogBase::Ok, parent, name, true ) |
55 | { | 58 | { |
56 | QWidget *page = plainPage(); | 59 | QWidget *page = plainPage(); |
57 | QVBoxLayout *pageLayout = new QVBoxLayout( page ); | 60 | Q3VBoxLayout *pageLayout = new Q3VBoxLayout( page ); |
58 | 61 | ||
59 | pwLineEdit = new QLineEdit( page, "pwLineEdit" ); | 62 | pwLineEdit = new QLineEdit( page, "pwLineEdit" ); |
60 | pwLineEdit->setEchoMode( QLineEdit::Password ); | 63 | pwLineEdit->setEchoMode( QLineEdit::Password ); |
61 | 64 | ||
62 | QLabel* textLabel1 = new QLabel( pwLineEdit, i18n("Please enter the master-password:"), page, "textLabel1" ); | 65 | QLabel* textLabel1 = new QLabel( pwLineEdit, i18n("Please enter the master-password:"), page, "textLabel1" ); |
63 | textLabel1->setAlignment( int( QLabel::WordBreak | QLabel::AlignCenter ) ); | 66 | textLabel1->setAlignment( int( Qt::WordBreak | Qt::AlignCenter ) ); |
64 | pageLayout->addWidget(textLabel1); | 67 | pageLayout->addWidget(textLabel1); |
65 | pageLayout->addWidget(pwLineEdit); | 68 | pageLayout->addWidget(pwLineEdit); |
66 | 69 | ||
67 | QWidget* numberBox = new QWidget( page ); | 70 | QWidget* numberBox = new QWidget( page ); |
68 | #ifndef DESKTOP_VERSION | 71 | #ifndef DESKTOP_VERSION |
69 | if ( QApplication::desktop()->width() > 320 ) { | 72 | if ( QApplication::desktop()->width() > 320 ) { |
70 | numberBox->setFixedHeight(250); | 73 | numberBox->setFixedHeight(250); |
71 | numberBox->setFixedWidth(200); | 74 | numberBox->setFixedWidth(200); |
72 | } | 75 | } |
73 | else{ | 76 | else{ |
74 | numberBox->setFixedHeight(150); | 77 | numberBox->setFixedHeight(150); |
75 | numberBox->setFixedWidth(150); | 78 | numberBox->setFixedWidth(150); |
76 | } | 79 | } |
77 | #endif | 80 | #endif |
78 | 81 | ||
79 | QGridLayout* numberLayout = new QGridLayout( numberBox, 4, 3 ); | 82 | Q3GridLayout* numberLayout = new Q3GridLayout( numberBox, 4, 3 ); |
80 | numberLayout->setMargin( 0 ); | 83 | numberLayout->setMargin( 0 ); |
81 | numberLayout->setSpacing( 0 ); | 84 | numberLayout->setSpacing( 0 ); |
82 | 85 | ||
83 | QPushButton* p1 = new QPushButton( i18n("1"), numberBox ); | 86 | QPushButton* p1 = new QPushButton( i18n("1"), numberBox ); |
84 | numberLayout->addWidget( p1, 0, 0 ); | 87 | numberLayout->addWidget( p1, 0, 0 ); |
85 | QPushButton* p2 = new QPushButton( i18n("2"), numberBox ); | 88 | QPushButton* p2 = new QPushButton( i18n("2"), numberBox ); |
86 | numberLayout->addWidget( p2, 0, 1 ); | 89 | numberLayout->addWidget( p2, 0, 1 ); |
87 | QPushButton* p3 = new QPushButton( i18n("3"), numberBox ); | 90 | QPushButton* p3 = new QPushButton( i18n("3"), numberBox ); |
88 | numberLayout->addWidget( p3, 0, 2 ); | 91 | numberLayout->addWidget( p3, 0, 2 ); |
89 | QPushButton* p4 = new QPushButton( i18n("4"), numberBox ); | 92 | QPushButton* p4 = new QPushButton( i18n("4"), numberBox ); |
90 | numberLayout->addWidget( p4, 1, 0 ); | 93 | numberLayout->addWidget( p4, 1, 0 ); |
91 | QPushButton* p5 = new QPushButton( i18n("5"), numberBox ); | 94 | QPushButton* p5 = new QPushButton( i18n("5"), numberBox ); |