author | zautrix <zautrix> | 2004-10-19 22:13:43 (UTC) |
---|---|---|
committer | zautrix <zautrix> | 2004-10-19 22:13:43 (UTC) |
commit | 2ab05e776276f02fd688b7041e5ccc5eb4573e50 (patch) (unidiff) | |
tree | b5df81769861183faf4a0198046eb70b8f0df7bb | |
parent | b11fbdc29bf96507c68ee9b6813d76ae37b5fd8f (diff) | |
download | kdepimpi-2ab05e776276f02fd688b7041e5ccc5eb4573e50.zip kdepimpi-2ab05e776276f02fd688b7041e5ccc5eb4573e50.tar.gz kdepimpi-2ab05e776276f02fd688b7041e5ccc5eb4573e50.tar.bz2 |
many small bugfixes
-rw-r--r-- | pwmanager/pwmanager/findwnd_emb.cpp | 6 | ||||
-rw-r--r-- | pwmanager/pwmanager/getmasterpwwnd_emb.cpp | 2 | ||||
-rw-r--r-- | pwmanager/pwmanager/kcmconfigs/pwmconfigwidget.cpp | 11 | ||||
-rw-r--r-- | pwmanager/pwmanager/main.cpp | 7 | ||||
-rw-r--r-- | pwmanager/pwmanager/pwmviewstyle_0.cpp | 4 | ||||
-rw-r--r-- | pwmanager/pwmanager/pwmviewstyle_1.cpp | 4 |
6 files changed, 21 insertions, 13 deletions
diff --git a/pwmanager/pwmanager/findwnd_emb.cpp b/pwmanager/pwmanager/findwnd_emb.cpp index 6db2684..6dcabe8 100644 --- a/pwmanager/pwmanager/findwnd_emb.cpp +++ b/pwmanager/pwmanager/findwnd_emb.cpp | |||
@@ -59,57 +59,57 @@ findWnd::findWnd( QWidget* parent, const char* name ) | |||
59 | QWidget *page = plainPage(); | 59 | QWidget *page = plainPage(); |
60 | QVBoxLayout *layout = new QVBoxLayout( page ); | 60 | QVBoxLayout *layout = new QVBoxLayout( page ); |
61 | layout->setMargin( KDialogBase::marginHint() ); | 61 | layout->setMargin( KDialogBase::marginHint() ); |
62 | layout->setSpacing( KDialogBase::spacingHint() ); | 62 | layout->setSpacing( KDialogBase::spacingHint() ); |
63 | 63 | ||
64 | exactCheckBox = new QCheckBox( i18n( "&Exact match" ), page ); | 64 | exactCheckBox = new QCheckBox( i18n( "&Exact match" ), page ); |
65 | layout->addWidget( exactCheckBox ); | 65 | layout->addWidget( exactCheckBox ); |
66 | 66 | ||
67 | caseSensCheckBox = new QCheckBox( i18n( "&Case sensitive" ), page ); | 67 | caseSensCheckBox = new QCheckBox( i18n( "&Case sensitive" ), page ); |
68 | layout->addWidget( caseSensCheckBox ); | 68 | layout->addWidget( caseSensCheckBox ); |
69 | 69 | ||
70 | 70 | ||
71 | QButtonGroup* buttonGroup1 = new QButtonGroup(1, Qt::Horizontal, i18n( "Search in Column" ), page ); | 71 | QButtonGroup* buttonGroup1 = new QButtonGroup(1, Qt::Horizontal, i18n( "Search in Column" ), page ); |
72 | layout->addWidget( buttonGroup1 ); | 72 | layout->addWidget( buttonGroup1 ); |
73 | 73 | ||
74 | descRadioButton = new QRadioButton( i18n( "&Description" ), buttonGroup1 ); | 74 | descRadioButton = new QRadioButton( i18n( "&Description" ), buttonGroup1 ); |
75 | pwRadioButton = new QRadioButton( i18n( "&Password" ), buttonGroup1 ); | 75 | pwRadioButton = new QRadioButton( i18n( "&Password" ), buttonGroup1 ); |
76 | commentRadioButton = new QRadioButton( i18n( "C&omment" ), buttonGroup1 ); | 76 | commentRadioButton = new QRadioButton( i18n( "C&omment" ), buttonGroup1 ); |
77 | nameRadioButton = new QRadioButton( i18n( "&Username" ), buttonGroup1 ); | 77 | nameRadioButton = new QRadioButton( i18n( "&Username" ), buttonGroup1 ); |
78 | urlRadioButton = new QRadioButton( i18n( "U&RL" ), buttonGroup1 ); | 78 | urlRadioButton = new QRadioButton( i18n( "U&RL" ), buttonGroup1 ); |
79 | launcherRadioButton = new QRadioButton( i18n( "&Launcher" ), buttonGroup1 ); | 79 | launcherRadioButton = new QRadioButton( i18n( "&Launcher" ), buttonGroup1 ); |
80 | descRadioButton->setChecked( TRUE ); | 80 | descRadioButton->setChecked( TRUE ); |
81 | 81 | ||
82 | findLineEdit = new KLineEdit( page ); | 82 | findLineEdit = new KLineEdit( page ); |
83 | QLabel* label = new QLabel( findLineEdit, i18n( "Find:" ), page ); | 83 | // QLabel* label = new QLabel( findLineEdit, i18n( "Find:" ), page ); |
84 | layout->addWidget( label ); | 84 | //layout->addWidget( label ); |
85 | layout->addWidget( findLineEdit ); | 85 | layout->addWidget( findLineEdit ); |
86 | 86 | ||
87 | setButtonText( KDialogBase::Ok, "&Find" ); | 87 | setButtonText( KDialogBase::Ok, "&Find" ); |
88 | setButtonText( KDialogBase::Cancel, "&Close" ); | 88 | setButtonText( KDialogBase::Cancel, "&Close" ); |
89 | 89 | ||
90 | 90 | ||
91 | // resize( QSize(200, 150) ); | 91 | resize( sizeHint() ); |
92 | 92 | ||
93 | 93 | ||
94 | connect( buttonGroup1, SIGNAL( clicked(int) ), this, SLOT( selectionChanged_slot() ) ); | 94 | connect( buttonGroup1, SIGNAL( clicked(int) ), this, SLOT( selectionChanged_slot() ) ); |
95 | connect( findLineEdit, SIGNAL( textChanged(const QString&) ), this, SLOT( selectionChanged_slot() ) ); | 95 | connect( findLineEdit, SIGNAL( textChanged(const QString&) ), this, SLOT( selectionChanged_slot() ) ); |
96 | connect( caseSensCheckBox, SIGNAL( stateChanged(int) ), this, SLOT( selectionChanged_slot() ) ); | 96 | connect( caseSensCheckBox, SIGNAL( stateChanged(int) ), this, SLOT( selectionChanged_slot() ) ); |
97 | connect( exactCheckBox, SIGNAL( stateChanged(int) ), this, SLOT( selectionChanged_slot() ) ); | 97 | connect( exactCheckBox, SIGNAL( stateChanged(int) ), this, SLOT( selectionChanged_slot() ) ); |
98 | 98 | ||
99 | } | 99 | } |
100 | 100 | ||
101 | /* | 101 | /* |
102 | * Destroys the object and frees any allocated resources | 102 | * Destroys the object and frees any allocated resources |
103 | */ | 103 | */ |
104 | findWnd::~findWnd() | 104 | findWnd::~findWnd() |
105 | { | 105 | { |
106 | // no need to delete child widgets, Qt does it all for us | 106 | // no need to delete child widgets, Qt does it all for us |
107 | } | 107 | } |
108 | 108 | ||
109 | void findWnd::findButton_slot() | 109 | void findWnd::findButton_slot() |
110 | { | 110 | { |
111 | qWarning( "findWnd::findButton_slot(): Not implemented yet" ); | 111 | qWarning( "findWnd::findButton_slot(): Not implemented yet" ); |
112 | } | 112 | } |
113 | 113 | ||
114 | void findWnd::selectionChanged_slot() | 114 | void findWnd::selectionChanged_slot() |
115 | { | 115 | { |
diff --git a/pwmanager/pwmanager/getmasterpwwnd_emb.cpp b/pwmanager/pwmanager/getmasterpwwnd_emb.cpp index ff4c28a..7f4ccef 100644 --- a/pwmanager/pwmanager/getmasterpwwnd_emb.cpp +++ b/pwmanager/pwmanager/getmasterpwwnd_emb.cpp | |||
@@ -78,49 +78,49 @@ getMasterPwWnd::getMasterPwWnd( QWidget* parent, const char* name) | |||
78 | QPushButton* p3 = new QPushButton( i18n("3"), numberBox ); | 78 | QPushButton* p3 = new QPushButton( i18n("3"), numberBox ); |
79 | numberLayout->addWidget( p3, 0, 2 ); | 79 | numberLayout->addWidget( p3, 0, 2 ); |
80 | QPushButton* p4 = new QPushButton( i18n("4"), numberBox ); | 80 | QPushButton* p4 = new QPushButton( i18n("4"), numberBox ); |
81 | numberLayout->addWidget( p4, 1, 0 ); | 81 | numberLayout->addWidget( p4, 1, 0 ); |
82 | QPushButton* p5 = new QPushButton( i18n("5"), numberBox ); | 82 | QPushButton* p5 = new QPushButton( i18n("5"), numberBox ); |
83 | numberLayout->addWidget( p5, 1, 1 ); | 83 | numberLayout->addWidget( p5, 1, 1 ); |
84 | QPushButton* p6 = new QPushButton( i18n("6"), numberBox ); | 84 | QPushButton* p6 = new QPushButton( i18n("6"), numberBox ); |
85 | numberLayout->addWidget( p6, 1, 2 ); | 85 | numberLayout->addWidget( p6, 1, 2 ); |
86 | QPushButton* p7 = new QPushButton( i18n("7"), numberBox ); | 86 | QPushButton* p7 = new QPushButton( i18n("7"), numberBox ); |
87 | numberLayout->addWidget( p7, 2, 0 ); | 87 | numberLayout->addWidget( p7, 2, 0 ); |
88 | QPushButton* p8 = new QPushButton( i18n("8"), numberBox ); | 88 | QPushButton* p8 = new QPushButton( i18n("8"), numberBox ); |
89 | numberLayout->addWidget( p8, 2, 1 ); | 89 | numberLayout->addWidget( p8, 2, 1 ); |
90 | QPushButton* p9 = new QPushButton( i18n("9"), numberBox ); | 90 | QPushButton* p9 = new QPushButton( i18n("9"), numberBox ); |
91 | numberLayout->addWidget( p9, 2, 2 ); | 91 | numberLayout->addWidget( p9, 2, 2 ); |
92 | QPushButton* clear = new QPushButton( i18n("x"), numberBox ); | 92 | QPushButton* clear = new QPushButton( i18n("x"), numberBox ); |
93 | numberLayout->addWidget( clear, 3, 0 ); | 93 | numberLayout->addWidget( clear, 3, 0 ); |
94 | QPushButton* p0 = new QPushButton( i18n("0"), numberBox ); | 94 | QPushButton* p0 = new QPushButton( i18n("0"), numberBox ); |
95 | numberLayout->addWidget( p0, 3, 1 ); | 95 | numberLayout->addWidget( p0, 3, 1 ); |
96 | QPushButton* backspace = new QPushButton( i18n("-"), numberBox ); | 96 | QPushButton* backspace = new QPushButton( i18n("-"), numberBox ); |
97 | numberLayout->addWidget( backspace, 3, 2 ); | 97 | numberLayout->addWidget( backspace, 3, 2 ); |
98 | 98 | ||
99 | 99 | ||
100 | pageLayout->addWidget(numberBox); | 100 | pageLayout->addWidget(numberBox); |
101 | 101 | ||
102 | resize( QSize(200, 180) ); | 102 | resize( 200,sizeHint().height() ); |
103 | 103 | ||
104 | connect( p0, SIGNAL( clicked() ), this, SLOT( add0() ) ); | 104 | connect( p0, SIGNAL( clicked() ), this, SLOT( add0() ) ); |
105 | connect( p1, SIGNAL( clicked() ), this, SLOT( add1() ) ); | 105 | connect( p1, SIGNAL( clicked() ), this, SLOT( add1() ) ); |
106 | connect( p2, SIGNAL( clicked() ), this, SLOT( add2() ) ); | 106 | connect( p2, SIGNAL( clicked() ), this, SLOT( add2() ) ); |
107 | connect( p3, SIGNAL( clicked() ), this, SLOT( add3() ) ); | 107 | connect( p3, SIGNAL( clicked() ), this, SLOT( add3() ) ); |
108 | connect( p4, SIGNAL( clicked() ), this, SLOT( add4() ) ); | 108 | connect( p4, SIGNAL( clicked() ), this, SLOT( add4() ) ); |
109 | connect( p5, SIGNAL( clicked() ), this, SLOT( add5() ) ); | 109 | connect( p5, SIGNAL( clicked() ), this, SLOT( add5() ) ); |
110 | connect( p6, SIGNAL( clicked() ), this, SLOT( add6() ) ); | 110 | connect( p6, SIGNAL( clicked() ), this, SLOT( add6() ) ); |
111 | connect( p7, SIGNAL( clicked() ), this, SLOT( add7() ) ); | 111 | connect( p7, SIGNAL( clicked() ), this, SLOT( add7() ) ); |
112 | connect( p8, SIGNAL( clicked() ), this, SLOT( add8() ) ); | 112 | connect( p8, SIGNAL( clicked() ), this, SLOT( add8() ) ); |
113 | connect( p9, SIGNAL( clicked() ), this, SLOT( add9() ) ); | 113 | connect( p9, SIGNAL( clicked() ), this, SLOT( add9() ) ); |
114 | connect( backspace, SIGNAL( clicked() ), this, SLOT( backspace() ) ); | 114 | connect( backspace, SIGNAL( clicked() ), this, SLOT( backspace() ) ); |
115 | connect( clear, SIGNAL( clicked() ), this, SLOT( clear() ) ); | 115 | connect( clear, SIGNAL( clicked() ), this, SLOT( clear() ) ); |
116 | 116 | ||
117 | 117 | ||
118 | 118 | ||
119 | } | 119 | } |
120 | 120 | ||
121 | /* | 121 | /* |
122 | * Destroys the object and frees any allocated resources | 122 | * Destroys the object and frees any allocated resources |
123 | */ | 123 | */ |
124 | getMasterPwWnd::~getMasterPwWnd() | 124 | getMasterPwWnd::~getMasterPwWnd() |
125 | { | 125 | { |
126 | // no need to delete child widgets, Qt does it all for us | 126 | // no need to delete child widgets, Qt does it all for us |
diff --git a/pwmanager/pwmanager/kcmconfigs/pwmconfigwidget.cpp b/pwmanager/pwmanager/kcmconfigs/pwmconfigwidget.cpp index 525bdaa..720dfcc 100644 --- a/pwmanager/pwmanager/kcmconfigs/pwmconfigwidget.cpp +++ b/pwmanager/pwmanager/kcmconfigs/pwmconfigwidget.cpp | |||
@@ -48,57 +48,64 @@ | |||
48 | 48 | ||
49 | #include "pwmconfigwidget.h" | 49 | #include "pwmconfigwidget.h" |
50 | #include "pwmexception.h" | 50 | #include "pwmexception.h" |
51 | 51 | ||
52 | PWMConfigWidget::PWMConfigWidget(PWMPrefs *prefs, QWidget *parent, const char *name ) | 52 | PWMConfigWidget::PWMConfigWidget(PWMPrefs *prefs, QWidget *parent, const char *name ) |
53 | : KPrefsWidget(prefs, parent, name ) | 53 | : KPrefsWidget(prefs, parent, name ) |
54 | { | 54 | { |
55 | QVBoxLayout *topLayout = new QVBoxLayout( this, 0, | 55 | QVBoxLayout *topLayout = new QVBoxLayout( this, 0, |
56 | KDialog::spacingHint() ); | 56 | KDialog::spacingHint() ); |
57 | 57 | ||
58 | QTabWidget *tabWidget = new QTabWidget( this ); | 58 | QTabWidget *tabWidget = new QTabWidget( this ); |
59 | topLayout->addWidget( tabWidget ); | 59 | topLayout->addWidget( tabWidget ); |
60 | 60 | ||
61 | // windowsStyle page | 61 | // windowsStyle page |
62 | ////////////////////////////////////////////////////// | 62 | ////////////////////////////////////////////////////// |
63 | QWidget *windowStylePage = new QWidget( this ); | 63 | QWidget *windowStylePage = new QWidget( this ); |
64 | QGridLayout *windowStyleLayout = new QGridLayout( windowStylePage, 3, 3); | 64 | QGridLayout *windowStyleLayout = new QGridLayout( windowStylePage, 3, 3); |
65 | 65 | ||
66 | int i = 0; | 66 | int i = 0; |
67 | KPrefsWidRadios * windowStyle = addWidRadios(i18n("Window-style:") ,&(prefs->mMainViewStyle), windowStylePage); | 67 | KPrefsWidRadios * windowStyle = addWidRadios(i18n("Window-style:") ,&(prefs->mMainViewStyle), windowStylePage); |
68 | windowStyle->addRadio(i18n("Category on top")); | 68 | windowStyle->addRadio(i18n("Category on top")); |
69 | windowStyle->addRadio(i18n("Category-list left/top")); | 69 | windowStyle->addRadio(i18n("Category-list left/top")); |
70 | windowStyleLayout->addMultiCellWidget( (QWidget*)windowStyle->groupBox(),i,i,0,2); | 70 | windowStyleLayout->addMultiCellWidget( (QWidget*)windowStyle->groupBox(),i,i,0,2); |
71 | ++i; | 71 | ++i; |
72 | |||
73 | QLabel* lab = new QLabel(i18n("<b>Font for Password entries:</b>"), windowStylePage); | ||
74 | windowStyleLayout->addMultiCellWidget( lab,i,i,0,2); | ||
75 | |||
72 | 76 | ||
77 | ++i; | ||
78 | |||
73 | KPrefsWidFont *selEntrFont = | 79 | KPrefsWidFont *selEntrFont = |
74 | addWidFont(i18n("Password"),i18n("Font for Pw entries:"), | 80 | addWidFont(i18n("Password"),i18n("Font:"), |
75 | &(prefs->mEntryFont),windowStylePage); | 81 | &(prefs->mEntryFont),windowStylePage); |
76 | windowStyleLayout->addWidget(selEntrFont->label(),i,0); | 82 | windowStyleLayout->addWidget(selEntrFont->label(),i,0); |
77 | windowStyleLayout->addWidget(selEntrFont->preview(),i,1); | 83 | windowStyleLayout->addWidget(selEntrFont->preview(),i,1); |
78 | windowStyleLayout->addWidget(selEntrFont->button(),i,2); | 84 | windowStyleLayout->addWidget(selEntrFont->button(),i,2); |
79 | ++i; | 85 | ++i; |
80 | 86 | lab = new QLabel(i18n(""), windowStylePage); | |
87 | windowStyleLayout->addMultiCellWidget( lab,i,i,0,2); | ||
81 | 88 | ||
82 | // File page | 89 | // File page |
83 | ////////////////////////////////////////////////////// | 90 | ////////////////////////////////////////////////////// |
84 | QWidget *filePage = new QWidget( this ); | 91 | QWidget *filePage = new QWidget( this ); |
85 | QGridLayout *fileLayout = new QGridLayout( filePage, 3, 2); | 92 | QGridLayout *fileLayout = new QGridLayout( filePage, 3, 2); |
86 | 93 | ||
87 | i = 0; | 94 | i = 0; |
88 | QLabel* kcfg_compression_label = new QLabel(i18n("Compression:"), filePage); | 95 | QLabel* kcfg_compression_label = new QLabel(i18n("Compression:"), filePage); |
89 | fileLayout->addWidget(kcfg_compression_label,i,0); | 96 | fileLayout->addWidget(kcfg_compression_label,i,0); |
90 | kcfg_compression = new QComboBox(filePage, "kcfg_compression"); | 97 | kcfg_compression = new QComboBox(filePage, "kcfg_compression"); |
91 | kcfg_compression->insertItem(i18n("None")); | 98 | kcfg_compression->insertItem(i18n("None")); |
92 | kcfg_compression->insertItem(i18n("gzip")); | 99 | kcfg_compression->insertItem(i18n("gzip")); |
93 | //US not yet supported: kcfg_compression->insertItem(i18n("bzip2")); | 100 | //US not yet supported: kcfg_compression->insertItem(i18n("bzip2")); |
94 | fileLayout->addWidget( kcfg_compression,i,1); | 101 | fileLayout->addWidget( kcfg_compression,i,1); |
95 | ++i; | 102 | ++i; |
96 | 103 | ||
97 | QLabel* kcfg_crypt_label = new QLabel(i18n("Encryption:"), filePage); | 104 | QLabel* kcfg_crypt_label = new QLabel(i18n("Encryption:"), filePage); |
98 | fileLayout->addWidget(kcfg_crypt_label,i,0); | 105 | fileLayout->addWidget(kcfg_crypt_label,i,0); |
99 | kcfg_cryptAlgo = new QComboBox(filePage, "kcfg_cryptAlgo"); | 106 | kcfg_cryptAlgo = new QComboBox(filePage, "kcfg_cryptAlgo"); |
100 | kcfg_cryptAlgo->insertItem(i18n("Blowfish (128 bit)")); | 107 | kcfg_cryptAlgo->insertItem(i18n("Blowfish (128 bit)")); |
101 | #ifdef CONFIG_PWMANAGER_GCRY | 108 | #ifdef CONFIG_PWMANAGER_GCRY |
102 | kcfg_cryptAlgo->insertItem(i18n("AES-128, Rijndael (128 bit)")); | 109 | kcfg_cryptAlgo->insertItem(i18n("AES-128, Rijndael (128 bit)")); |
103 | kcfg_cryptAlgo->insertItem(i18n("AES-192, Rijndael (192 bit)")); | 110 | kcfg_cryptAlgo->insertItem(i18n("AES-192, Rijndael (192 bit)")); |
104 | kcfg_cryptAlgo->insertItem(i18n("AES-256, Rijndael (256 bit)")); | 111 | kcfg_cryptAlgo->insertItem(i18n("AES-256, Rijndael (256 bit)")); |
diff --git a/pwmanager/pwmanager/main.cpp b/pwmanager/pwmanager/main.cpp index 3ae4d55..3f2d055 100644 --- a/pwmanager/pwmanager/main.cpp +++ b/pwmanager/pwmanager/main.cpp | |||
@@ -153,51 +153,52 @@ int main(int argc, char *argv[]) | |||
153 | return EXIT_SUCCESS; | 153 | return EXIT_SUCCESS; |
154 | } | 154 | } |
155 | PwMApplication a; | 155 | PwMApplication a; |
156 | aboutData.setLicenseTextFile(LICENSE_FILE); | 156 | aboutData.setLicenseTextFile(LICENSE_FILE); |
157 | return a.exec(); | 157 | return a.exec(); |
158 | #else | 158 | #else |
159 | 159 | ||
160 | bool exitHelp = false; | 160 | bool exitHelp = false; |
161 | if ( argc > 1 ) { | 161 | if ( argc > 1 ) { |
162 | QString command = argv[1]; | 162 | QString command = argv[1]; |
163 | if ( command == "-help" ){ | 163 | if ( command == "-help" ){ |
164 | printf("PWM/PI command line commands:\n"); | 164 | printf("PWM/PI command line commands:\n"); |
165 | printf(" no command: Start PWM/PI in usual way\n"); | 165 | printf(" no command: Start PWM/PI in usual way\n"); |
166 | printf(" -help: This output\n"); | 166 | printf(" -help: This output\n"); |
167 | printf(" PWM/PI is exiting now. Bye!\n"); | 167 | printf(" PWM/PI is exiting now. Bye!\n"); |
168 | exitHelp = true; | 168 | exitHelp = true; |
169 | } | 169 | } |
170 | } | 170 | } |
171 | if ( ! exitHelp ) { | 171 | if ( ! exitHelp ) { |
172 | 172 | ||
173 | PwMApplication a(argc, argv); | 173 | PwMApplication a(argc, argv); |
174 | 174 | ||
175 | KGlobal::setAppName( "pwmanager" ); | 175 | KGlobal::setAppName( "pwmanager" ); |
176 | #ifndef DESKTOP_VERSION | 176 | #ifndef DESKTOP_VERSION |
177 | //US if ( QApplication::desktop()->width() > 320 ) | 177 | //qDebug("width %d ",QApplication::desktop()->width() ); |
178 | //US KGlobal::iconLoader()->setIconPath(QString(getenv("QPEDIR"))+"/pics/kdepim/pwmanager/icons22/"); | 178 | if ( QApplication::desktop()->width() > 320 ) |
179 | //US else | 179 | KGlobal::iconLoader()->setIconPath(QString(getenv("QPEDIR"))+"/pics/kdepim/pwmanager/icons22/"); |
180 | else | ||
180 | KGlobal::iconLoader()->setIconPath(QString(getenv("QPEDIR"))+"/pics/kdepim/pwmanager/icons16/"); | 181 | KGlobal::iconLoader()->setIconPath(QString(getenv("QPEDIR"))+"/pics/kdepim/pwmanager/icons16/"); |
181 | #else | 182 | #else |
182 | QString fileName ; | 183 | QString fileName ; |
183 | fileName = qApp->applicationDirPath () + "/kdepim/pwmanager/icons22/"; | 184 | fileName = qApp->applicationDirPath () + "/kdepim/pwmanager/icons22/"; |
184 | KGlobal::iconLoader()->setIconPath(QDir::convertSeparators(fileName)); | 185 | KGlobal::iconLoader()->setIconPath(QDir::convertSeparators(fileName)); |
185 | QApplication::addLibraryPath ( qApp->applicationDirPath () ); | 186 | QApplication::addLibraryPath ( qApp->applicationDirPath () ); |
186 | 187 | ||
187 | #endif | 188 | #endif |
188 | KStandardDirs::setAppDir( QDir::convertSeparators(locateLocal("data", "pwmanager"))); | 189 | KStandardDirs::setAppDir( QDir::convertSeparators(locateLocal("data", "pwmanager"))); |
189 | KPimGlobalPrefs::instance()->setGlobalConfig(); | 190 | KPimGlobalPrefs::instance()->setGlobalConfig(); |
190 | 191 | ||
191 | a.newInstance(); | 192 | a.newInstance(); |
192 | 193 | ||
193 | //US KAddressBookMain m ; | 194 | //US KAddressBookMain m ; |
194 | 195 | ||
195 | //US QObject::connect(&a, SIGNAL (appMessage ( const QCString &, const QByteArray & )), ExternalAppHandler::instance(), SLOT (appMessage ( const QCString &, const QByteArray & ))); | 196 | //US QObject::connect(&a, SIGNAL (appMessage ( const QCString &, const QByteArray & )), ExternalAppHandler::instance(), SLOT (appMessage ( const QCString &, const QByteArray & ))); |
196 | /*US | 197 | /*US |
197 | #ifndef DESKTOP_VERSION | 198 | #ifndef DESKTOP_VERSION |
198 | a.showMainWidget( &m ); | 199 | a.showMainWidget( &m ); |
199 | #else | 200 | #else |
200 | a.setMainWidget( &m ); | 201 | a.setMainWidget( &m ); |
201 | m.resize (640, 480 ); | 202 | m.resize (640, 480 ); |
202 | m.show(); | 203 | m.show(); |
203 | #endif | 204 | #endif |
diff --git a/pwmanager/pwmanager/pwmviewstyle_0.cpp b/pwmanager/pwmanager/pwmviewstyle_0.cpp index 7262684..1453d03 100644 --- a/pwmanager/pwmanager/pwmviewstyle_0.cpp +++ b/pwmanager/pwmanager/pwmviewstyle_0.cpp | |||
@@ -10,60 +10,60 @@ | |||
10 | ***************************************************************************/ | 10 | ***************************************************************************/ |
11 | 11 | ||
12 | /*************************************************************************** | 12 | /*************************************************************************** |
13 | * copyright (C) 2004 by Ulf Schenk | 13 | * copyright (C) 2004 by Ulf Schenk |
14 | * This file is originaly based on version 1.0.1 of pwmanager | 14 | * This file is originaly based on version 1.0.1 of pwmanager |
15 | * and was modified to run on embedded devices that run microkde | 15 | * and was modified to run on embedded devices that run microkde |
16 | * | 16 | * |
17 | * $Id$ | 17 | * $Id$ |
18 | **************************************************************************/ | 18 | **************************************************************************/ |
19 | 19 | ||
20 | #include "pwmviewstyle_0.h" | 20 | #include "pwmviewstyle_0.h" |
21 | #include "pwmview.h" | 21 | #include "pwmview.h" |
22 | #include "listviewpwm.h" | 22 | #include "listviewpwm.h" |
23 | #include "commentbox.h" | 23 | #include "commentbox.h" |
24 | 24 | ||
25 | #include <klocale.h> | 25 | #include <klocale.h> |
26 | #include "pwmprefs.h" | 26 | #include "pwmprefs.h" |
27 | 27 | ||
28 | PwMViewStyle_0::PwMViewStyle_0(PwMView *view) | 28 | PwMViewStyle_0::PwMViewStyle_0(PwMView *view) |
29 | : QObject() | 29 | : QObject() |
30 | { | 30 | { |
31 | vbox1 = new QVBox(view); | 31 | vbox1 = new QVBox(view); |
32 | vbox1->setSpacing(3); | 32 | vbox1->setSpacing(3); |
33 | hbox1 = new QHBox(vbox1); | 33 | hbox1 = new QHBox(vbox1); |
34 | hbox1->setSpacing(10); | 34 | hbox1->setSpacing(3); |
35 | categoriesTitle = new QLabel(hbox1); | 35 | categoriesTitle = new QLabel(hbox1); |
36 | categoriesTitle->setText(i18n("Categories:")); | 36 | categoriesTitle->setText(i18n("Categories:")); |
37 | categoriesCombo = new QComboBox(hbox1); | 37 | categoriesCombo = new QComboBox(hbox1); |
38 | renCatButton = new QPushButton(i18n("&Rename"), hbox1); | 38 | renCatButton = new QPushButton(i18n("&Rename"), hbox1); |
39 | delCatButton = new QPushButton(i18n("&Delete"), hbox1); | 39 | delCatButton = new QPushButton(i18n("&Delete"), hbox1); |
40 | #ifndef PWM_EMBEDDED | 40 | #ifndef PWM_EMBEDDED |
41 | splitter1 = new QSplitter(vbox1); | 41 | splitter1 = new QSplitter(vbox1); |
42 | splitter1->setOrientation(Qt::Vertical); | 42 | splitter1->setOrientation(Qt::Vertical); |
43 | #else | 43 | #else |
44 | splitter1 = new KDGanttMinimizeSplitter( Qt::Vertical, vbox1); | 44 | splitter1 = new KDGanttMinimizeSplitter( Qt::Vertical, vbox1); |
45 | splitter1->setMinimizeDirection ( KDGanttMinimizeSplitter::Up ); | 45 | splitter1->setMinimizeDirection ( KDGanttMinimizeSplitter::Down ); |
46 | 46 | ||
47 | //US topLayout->addWidget(mMiniSplitter ); | 47 | //US topLayout->addWidget(mMiniSplitter ); |
48 | #endif | 48 | #endif |
49 | lv = new ListViewPwM(splitter1); | 49 | lv = new ListViewPwM(splitter1); |
50 | commentBox = new CommentBox(splitter1); | 50 | commentBox = new CommentBox(splitter1); |
51 | // set sizes and styles | 51 | // set sizes and styles |
52 | commentBox->resize(commentBox->size().width(), 60); | 52 | commentBox->resize(commentBox->size().width(), 60); |
53 | categoriesTitle->setAlignment(Qt::AlignVCenter | Qt::AlignRight); | 53 | categoriesTitle->setAlignment(Qt::AlignVCenter | Qt::AlignRight); |
54 | // connections | 54 | // connections |
55 | connect(categoriesCombo, SIGNAL(activated(int)), | 55 | connect(categoriesCombo, SIGNAL(activated(int)), |
56 | view, SLOT(shiftToView())); | 56 | view, SLOT(shiftToView())); |
57 | connect(renCatButton, SIGNAL(clicked()), | 57 | connect(renCatButton, SIGNAL(clicked()), |
58 | view, SLOT(renCatButton_slot())); | 58 | view, SLOT(renCatButton_slot())); |
59 | connect(delCatButton, SIGNAL(clicked()), | 59 | connect(delCatButton, SIGNAL(clicked()), |
60 | view, SLOT(delCatButton_slot())); | 60 | view, SLOT(delCatButton_slot())); |
61 | } | 61 | } |
62 | 62 | ||
63 | PwMViewStyle_0::~PwMViewStyle_0() | 63 | PwMViewStyle_0::~PwMViewStyle_0() |
64 | { | 64 | { |
65 | delete vbox1; | 65 | delete vbox1; |
66 | } | 66 | } |
67 | 67 | ||
68 | void PwMViewStyle_0::delCategory(const QString &cat) | 68 | void PwMViewStyle_0::delCategory(const QString &cat) |
69 | { | 69 | { |
diff --git a/pwmanager/pwmanager/pwmviewstyle_1.cpp b/pwmanager/pwmanager/pwmviewstyle_1.cpp index 374c698..a85cece 100644 --- a/pwmanager/pwmanager/pwmviewstyle_1.cpp +++ b/pwmanager/pwmanager/pwmviewstyle_1.cpp | |||
@@ -13,62 +13,62 @@ | |||
13 | * copyright (C) 2004 by Ulf Schenk | 13 | * copyright (C) 2004 by Ulf Schenk |
14 | * This file is originaly based on version 1.0.1 of pwmanager | 14 | * This file is originaly based on version 1.0.1 of pwmanager |
15 | * and was modified to run on embedded devices that run microkde | 15 | * and was modified to run on embedded devices that run microkde |
16 | * | 16 | * |
17 | * $Id$ | 17 | * $Id$ |
18 | **************************************************************************/ | 18 | **************************************************************************/ |
19 | 19 | ||
20 | #include "pwmviewstyle_1.h" | 20 | #include "pwmviewstyle_1.h" |
21 | #include "pwmview.h" | 21 | #include "pwmview.h" |
22 | #include "listviewpwm.h" | 22 | #include "listviewpwm.h" |
23 | #include "commentbox.h" | 23 | #include "commentbox.h" |
24 | 24 | ||
25 | #include <klocale.h> | 25 | #include <klocale.h> |
26 | #include "pwmprefs.h" | 26 | #include "pwmprefs.h" |
27 | 27 | ||
28 | #define INITIAL_CATEGORIES_WIDTH100 | 28 | #define INITIAL_CATEGORIES_WIDTH100 |
29 | 29 | ||
30 | PwMViewStyle_1::PwMViewStyle_1(PwMView *view) | 30 | PwMViewStyle_1::PwMViewStyle_1(PwMView *view) |
31 | : QObject() | 31 | : QObject() |
32 | { | 32 | { |
33 | #ifndef PWM_EMBEDDED | 33 | #ifndef PWM_EMBEDDED |
34 | splitter = new QSplitter(view); | 34 | splitter = new QSplitter(view); |
35 | #else | 35 | #else |
36 | splitter = new KDGanttMinimizeSplitter( Qt::Horizontal, view); | 36 | splitter = new KDGanttMinimizeSplitter( Qt::Horizontal, view); |
37 | splitter->setMinimizeDirection ( KDGanttMinimizeSplitter::Right ); | 37 | splitter->setMinimizeDirection ( KDGanttMinimizeSplitter::Left ); |
38 | 38 | ||
39 | //US topLayout->addWidget(mMiniSplitter ); | 39 | //US topLayout->addWidget(mMiniSplitter ); |
40 | #endif | 40 | #endif |
41 | 41 | ||
42 | vbox1 = new QVBox(splitter); | 42 | vbox1 = new QVBox(splitter); |
43 | categoriesTitle = new QLabel(vbox1); | 43 | categoriesTitle = new QLabel(vbox1); |
44 | categoriesList = new QListBox(vbox1); | 44 | categoriesList = new QListBox(vbox1); |
45 | #ifndef PWM_EMBEDDED | 45 | #ifndef PWM_EMBEDDED |
46 | splitter2 = new QSplitter(splitter); | 46 | splitter2 = new QSplitter(splitter); |
47 | splitter2->setOrientation(Qt::Vertical); | 47 | splitter2->setOrientation(Qt::Vertical); |
48 | #else | 48 | #else |
49 | splitter2 = new KDGanttMinimizeSplitter( Qt::Vertical, splitter); | 49 | splitter2 = new KDGanttMinimizeSplitter( Qt::Vertical, splitter); |
50 | splitter2->setMinimizeDirection ( KDGanttMinimizeSplitter::Right ); | 50 | splitter2->setMinimizeDirection ( KDGanttMinimizeSplitter::Down ); |
51 | 51 | ||
52 | //US topLayout->addWidget(mMiniSplitter ); | 52 | //US topLayout->addWidget(mMiniSplitter ); |
53 | #endif | 53 | #endif |
54 | lv = new ListViewPwM(splitter2); | 54 | lv = new ListViewPwM(splitter2); |
55 | commentBox = new CommentBox(splitter2); | 55 | commentBox = new CommentBox(splitter2); |
56 | // set sizes and styles | 56 | // set sizes and styles |
57 | //UScommentBox->resize(commentBox->size().width(), 60); | 57 | //UScommentBox->resize(commentBox->size().width(), 60); |
58 | QValueList<int> sizes; | 58 | QValueList<int> sizes; |
59 | #ifndef PWM_EMBEDDED | 59 | #ifndef PWM_EMBEDDED |
60 | sizes.push_back(INITIAL_CATEGORIES_WIDTH); | 60 | sizes.push_back(INITIAL_CATEGORIES_WIDTH); |
61 | sizes.push_back(view->height() - INITIAL_CATEGORIES_WIDTH); | 61 | sizes.push_back(view->height() - INITIAL_CATEGORIES_WIDTH); |
62 | #else | 62 | #else |
63 | sizes.append(INITIAL_CATEGORIES_WIDTH); | 63 | sizes.append(INITIAL_CATEGORIES_WIDTH); |
64 | sizes.append(view->height() - INITIAL_CATEGORIES_WIDTH); | 64 | sizes.append(view->height() - INITIAL_CATEGORIES_WIDTH); |
65 | #endif | 65 | #endif |
66 | //USsplitter->setSizes(sizes); | 66 | //USsplitter->setSizes(sizes); |
67 | categoriesTitle->setAlignment(Qt::AlignHCenter); | 67 | categoriesTitle->setAlignment(Qt::AlignHCenter); |
68 | #ifndef PWM_EMBEDDED | 68 | #ifndef PWM_EMBEDDED |
69 | categoriesTitle->setFrameShape(QFrame::MenuBarPanel); | 69 | categoriesTitle->setFrameShape(QFrame::MenuBarPanel); |
70 | #else | 70 | #else |
71 | categoriesTitle->setFrameShape(QFrame::StyledPanel); | 71 | categoriesTitle->setFrameShape(QFrame::StyledPanel); |
72 | #endif | 72 | #endif |
73 | categoriesTitle->setText(i18n("Categories:")); | 73 | categoriesTitle->setText(i18n("Categories:")); |
74 | catCtxMenu = new QPopupMenu(view); | 74 | catCtxMenu = new QPopupMenu(view); |