summaryrefslogtreecommitdiffabout
path: root/pwmanager/pwmanager/getmasterpwwnd_emb.cpp
Unidiff
Diffstat (limited to 'pwmanager/pwmanager/getmasterpwwnd_emb.cpp') (more/less context) (ignore whitespace changes)
-rw-r--r--pwmanager/pwmanager/getmasterpwwnd_emb.cpp9
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
@@ -22,82 +22,85 @@
22 22
23$Id$ 23$Id$
24*/ 24*/
25 25
26#include "getmasterpwwnd_emb.h" 26#include "getmasterpwwnd_emb.h"
27 27
28#include "klocale.h" 28#include "klocale.h"
29 29
30/* 30/*
31#include <qvariant.h> 31#include <qvariant.h>
32#include <qpushbutton.h> 32#include <qpushbutton.h>
33#include <qlabel.h> 33#include <qlabel.h>
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 */
51getMasterPwWnd::getMasterPwWnd( QWidget* parent, const char* name) 54getMasterPwWnd::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 );
92 numberLayout->addWidget( p5, 1, 1 ); 95 numberLayout->addWidget( p5, 1, 1 );
93 QPushButton* p6 = new QPushButton( i18n("6"), numberBox ); 96 QPushButton* p6 = new QPushButton( i18n("6"), numberBox );
94 numberLayout->addWidget( p6, 1, 2 ); 97 numberLayout->addWidget( p6, 1, 2 );
95 QPushButton* p7 = new QPushButton( i18n("7"), numberBox ); 98 QPushButton* p7 = new QPushButton( i18n("7"), numberBox );
96 numberLayout->addWidget( p7, 2, 0 ); 99 numberLayout->addWidget( p7, 2, 0 );
97 QPushButton* p8 = new QPushButton( i18n("8"), numberBox ); 100 QPushButton* p8 = new QPushButton( i18n("8"), numberBox );
98 numberLayout->addWidget( p8, 2, 1 ); 101 numberLayout->addWidget( p8, 2, 1 );
99 QPushButton* p9 = new QPushButton( i18n("9"), numberBox ); 102 QPushButton* p9 = new QPushButton( i18n("9"), numberBox );
100 numberLayout->addWidget( p9, 2, 2 ); 103 numberLayout->addWidget( p9, 2, 2 );
101 QPushButton* clear = new QPushButton( i18n("x"), numberBox ); 104 QPushButton* clear = new QPushButton( i18n("x"), numberBox );
102 numberLayout->addWidget( clear, 3, 0 ); 105 numberLayout->addWidget( clear, 3, 0 );
103 QPushButton* p0 = new QPushButton( i18n("0"), numberBox ); 106 QPushButton* p0 = new QPushButton( i18n("0"), numberBox );