From 3e306348e98348d537f0de45abe1600862fa0eb7 Mon Sep 17 00:00:00 2001 From: Yves Martin Date: Sun, 23 Jan 2011 23:26:43 +0100 Subject: [PATCH] Release 0.4.3-3maemo with patches to disable menus/actions, add ScrollArea and fix desktop shortcut --- debian/changelog | 10 +++ debian/files | 2 +- debian/patches/00list | 3 + debian/patches/40_LessActions.dpatch | 113 ++++++++++++++++++++++++++ debian/patches/50_DesktopFile.dpatch | 19 +++++ debian/patches/60_ScrollAreaInDialogs.dpatch | 101 +++++++++++++++++++++++ 6 files changed, 247 insertions(+), 1 deletion(-) create mode 100755 debian/patches/40_LessActions.dpatch create mode 100755 debian/patches/50_DesktopFile.dpatch create mode 100755 debian/patches/60_ScrollAreaInDialogs.dpatch diff --git a/debian/changelog b/debian/changelog index 004246e..3025113 100644 --- a/debian/changelog +++ b/debian/changelog @@ -1,3 +1,13 @@ +keepassx (0.4.3-3maemo) unstable; urgency=low + + * Disable menus to improve usability + * Database creation is no longer possible + * Group management is no longer possible + * Autotype compilation switch turned off, feature does not work on Maemo5 + * Add scrollable viewports for edit-entry, password-generation and settings dialogs. + + -- Yves Martin Sun, 23 Jun 2011 18:39:00 +0100 + keepassx (0.4.3-1maemo) unstable; urgency=low * Upgrade to 0.4.3 diff --git a/debian/files b/debian/files index 6033dae..3fdd045 100644 --- a/debian/files +++ b/debian/files @@ -1 +1 @@ -keepassx_0.4.3-1maemo_i386.deb user/utilities optional +keepassx_0.4.3-3maemo_i386.deb user/utilities optional diff --git a/debian/patches/00list b/debian/patches/00list index 9a044e5..b7b9af0 100644 --- a/debian/patches/00list +++ b/debian/patches/00list @@ -1,3 +1,6 @@ 10_RemoveSystray.dpatch 20_LargeIcons.dpatch 30_Paths.dpatch +40_LessActions.dpatch +50_DesktopFile.dpatch +60_ScrollAreaInDialogs.dpatch diff --git a/debian/patches/40_LessActions.dpatch b/debian/patches/40_LessActions.dpatch new file mode 100755 index 0000000..216cb70 --- /dev/null +++ b/debian/patches/40_LessActions.dpatch @@ -0,0 +1,113 @@ +#! /bin/sh /usr/share/dpatch/dpatch-run +## 40_LessActions.dpatch by +## +## All lines beginning with `## DP:' are a description of the patch. +## DP: No description. + +@DPATCH@ +diff -urNad keepassx-0.4.3~/src/forms/MainWindow.ui keepassx-0.4.3/src/forms/MainWindow.ui +--- keepassx-0.4.3~/src/forms/MainWindow.ui 2010-12-29 23:01:24.000000000 +0100 ++++ keepassx-0.4.3/src/forms/MainWindow.ui 2011-01-01 12:45:40.000000000 +0100 +@@ -35,7 +35,7 @@ + + + +- true ++ false + + + true +diff -urNad keepassx-0.4.3~/src/mainwindow.cpp keepassx-0.4.3/src/mainwindow.cpp +--- keepassx-0.4.3~/src/mainwindow.cpp 2011-01-01 12:42:43.000000000 +0100 ++++ keepassx-0.4.3/src/mainwindow.cpp 2011-01-01 12:45:40.000000000 +0100 +@@ -95,6 +95,9 @@ + WorkspaceLockedWidget.setupUi(LockedCentralWidget); + LockedCentralWidget->setVisible(false); + ++ // #ifdef Q_WS_MAEMO_5 #endif ++ mobileHideMenus(false); ++ + setupConnections(); + connect(qApp, SIGNAL(commitDataRequest(QSessionManager&)), SLOT(OnShutdown(QSessionManager&))); + +@@ -217,6 +220,69 @@ + connect(WorkspaceLockedWidget.Button_CloseDatabase,SIGNAL(clicked()),this,SLOT(OnLockClose())); + } + ++void KeepassMainWindow::mobileHideMenus(bool enable){ ++ ++menuExport->menuAction()->setVisible(enable); ++menuImport->menuAction()->setVisible(enable); ++ViewMenu->menuAction()->setVisible(enable); ++ ++FileNewAction->setVisible(enable); ++FileSettingsAction->setVisible(enable); ++FileChangeKeyAction->setVisible(enable); ++FileSaveAsAction->setVisible(enable); ++FileCloseAction->setVisible(enable); ++FileChangeKeyAction->setVisible(enable); ++FileUnLockWorkspaceAction->setVisible(enable); ++ ++EditCloneEntryAction->setVisible(enable); ++EditGroupSearchAction->setVisible(enable); ++ViewHideUsernamesAction->setVisible(enable); ++ViewHidePasswordsAction->setVisible(enable); ++ViewColumnsTitleAction->setVisible(enable); ++EditSaveAttachmentAction->setVisible(enable); ++ ++ EditNewGroupAction->setVisible(enable); ++ ViewShowToolbarAction->setVisible(enable); ++ ViewShowEntryDetailsAction->setVisible(enable); ++ ViewHidePasswordsAction->setVisible(enable); ++ ViewHideUsernamesAction->setVisible(enable); ++ ++ menuBookmarks->menuAction()->setVisible(enable); ++ AddBookmarkAction->setVisible(enable); ++ AddThisAsBookmarkAction->setVisible(enable); ++ ManageBookmarksAction->setVisible(enable); ++ ++ menuTool_Button_Sizes->menuAction()->setVisible(enable); ++ ViewToolButtonSize16Action->setVisible(enable); ++ ViewToolButtonSize22Action->setVisible(enable); ++ ViewToolButtonSize28Action->setVisible(enable); ++ ViewShowStatusbarAction->setVisible(enable); ++ ++ menuColumns->menuAction()->setVisible(enable); ++ ViewColumnsTitleAction->setVisible(enable); ++ ViewColumnsUsernameAction->setVisible(enable); ++ ViewColumnsUrlAction->setVisible(enable); ++ ViewColumnsPasswordAction->setVisible(enable); ++ ViewColumnsCommentAction->setVisible(enable); ++ ViewColumnsExpireAction->setVisible(enable); ++ ViewColumnsCreationAction->setVisible(enable); ++ ViewColumnsLastChangeAction->setVisible(enable); ++ ViewColumnsLastAccessAction->setVisible(enable); ++ ViewColumnsAttachmentAction->setVisible(enable); ++ ViewColumnsGroupAction->setVisible(enable); ++ ++menuGroups->menuAction()->setVisible(enable); ++EditNewGroupAction->setVisible(enable); ++EditNewSubgroupAction->setVisible(enable); ++EditEditGroupAction->setVisible(enable); ++EditDeleteGroupAction->setVisible(enable); ++EditGroupSortAction->setVisible(enable); ++ ++ menuHelp->menuAction()->setVisible(enable); ++ HelpHandbookAction->setVisible(enable); ++ HelpAboutAction->setVisible(enable); ++} ++ + void KeepassMainWindow::setupToolbar(){ + toolBar=new QToolBar(this); + toolBar->setMovable(false); +diff -urNad keepassx-0.4.3~/src/mainwindow.h keepassx-0.4.3/src/mainwindow.h +--- keepassx-0.4.3~/src/mainwindow.h 2011-01-01 12:42:43.000000000 +0100 ++++ keepassx-0.4.3/src/mainwindow.h 2011-01-01 12:45:40.000000000 +0100 +@@ -107,6 +107,7 @@ + inline void setupToolbar(); + inline void setupIcons(); + inline void setupConnections(); ++ inline void mobileHideMenus(bool); + inline void setupMenus(); + void setStateFileOpen(bool); + void setStateFileModified(bool); diff --git a/debian/patches/50_DesktopFile.dpatch b/debian/patches/50_DesktopFile.dpatch new file mode 100755 index 0000000..e526ca6 --- /dev/null +++ b/debian/patches/50_DesktopFile.dpatch @@ -0,0 +1,19 @@ +#! /bin/sh /usr/share/dpatch/dpatch-run +## 50_DesktopFile.dpatch by +## +## All lines beginning with `## DP:' are a description of the patch. +## DP: No description. + +@DPATCH@ +diff -urNad keepassx-0.4.3~/share/applications/keepassx.desktop keepassx-0.4.3/share/applications/keepassx.desktop +--- keepassx-0.4.3~/share/applications/keepassx.desktop 2011-01-04 19:00:51.000000000 +0100 ++++ keepassx-0.4.3/share/applications/keepassx.desktop 2011-01-04 19:01:42.000000000 +0100 +@@ -4,7 +4,7 @@ + GenericName[de]=Passwortverwaltung + GenericName[es]=Gestor de contraseñas multiplataforma + GenericName[fr]=Gestionnaire de mot de passe +-Exec=keepassx %f ++Exec=keepassx + Icon=keepassx + Comment=Cross Platform Password Manager + Comment[de]=Passwortverwaltung diff --git a/debian/patches/60_ScrollAreaInDialogs.dpatch b/debian/patches/60_ScrollAreaInDialogs.dpatch new file mode 100755 index 0000000..6c58dff --- /dev/null +++ b/debian/patches/60_ScrollAreaInDialogs.dpatch @@ -0,0 +1,101 @@ +#! /bin/sh /usr/share/dpatch/dpatch-run +## 60_ScrollAreaInDialogs.dpatch by +## +## All lines beginning with `## DP:' are a description of the patch. +## DP: No description. + +@DPATCH@ +diff -urNad keepassx~/src/dialogs/EditEntryDlg.cpp keepassx/src/dialogs/EditEntryDlg.cpp +--- keepassx~/src/dialogs/EditEntryDlg.cpp 2011-01-23 18:20:41.000000000 +0100 ++++ keepassx/src/dialogs/EditEntryDlg.cpp 2011-01-23 22:45:14.000000000 +0100 +@@ -19,6 +19,8 @@ + ***************************************************************************/ + + #include ++#include ++ + #include "SelectIconDlg.h" + #include "PasswordGenDlg.h" + #include "EditEntryDlg.h" +@@ -39,6 +41,18 @@ + setupUi(this); + ModFlag=false; + QMenu *ExpirePresetsMenu=new QMenu(); ++ ++ // YMA add scroll area ++ QWidget* wrapper = new QWidget(); ++ wrapper->setLayout(this->layout()); ++ ++ QScrollArea* scrollArea = new QScrollArea(this); ++ scrollArea->setWidgetResizable(true); ++ scrollArea->setWidget(wrapper); ++ ++ QHBoxLayout* wrapperLayout = new QHBoxLayout(); ++ wrapperLayout->addWidget(scrollArea); ++ this->setLayout(wrapperLayout); + + setGeometry( config->dialogGeometry(this) ); + +diff -urNad keepassx~/src/dialogs/PasswordGenDlg.cpp keepassx/src/dialogs/PasswordGenDlg.cpp +--- keepassx~/src/dialogs/PasswordGenDlg.cpp 2011-01-23 18:20:41.000000000 +0100 ++++ keepassx/src/dialogs/PasswordGenDlg.cpp 2011-01-23 22:45:43.000000000 +0100 +@@ -18,6 +18,7 @@ + * 59 Temple Place - Suite 330, Boston, MA 02111-1307, USA. * + ***************************************************************************/ + ++#include + + #include "dialogs/PasswordGenDlg.h" + #include "dialogs/CollectEntropyDlg.h" +@@ -32,6 +33,19 @@ + : QDialog(parent,fl) + { + setupUi(this); ++ ++ // YMA add scroll area ++ QWidget* wrapper = new QWidget(); ++ wrapper->setLayout(this->layout()); ++ ++ QScrollArea* scrollArea = new QScrollArea(this); ++ scrollArea->setWidgetResizable(true); ++ scrollArea->setWidget(wrapper); ++ ++ QHBoxLayout* wrapperLayout = new QHBoxLayout(); ++ wrapperLayout->addWidget(scrollArea); ++ this->setLayout(wrapperLayout); ++ + connect(ButtonGenerate, SIGNAL(clicked()), SLOT(OnGeneratePw())); + connect(DialogButtons, SIGNAL(rejected()), SLOT(OnCancel())); + connect(DialogButtons, SIGNAL(accepted()), SLOT(OnAccept())); +diff -urNad keepassx~/src/dialogs/SettingsDlg.cpp keepassx/src/dialogs/SettingsDlg.cpp +--- keepassx~/src/dialogs/SettingsDlg.cpp 2011-01-23 18:22:01.000000000 +0100 ++++ keepassx/src/dialogs/SettingsDlg.cpp 2011-01-23 22:45:22.000000000 +0100 +@@ -19,6 +19,8 @@ + + #include + #include ++#include ++ + #include "dialogs/SettingsDlg.h" + #include "dialogs/CustomizeDetailViewDlg.h" + +@@ -28,6 +30,19 @@ + CSettingsDlg::CSettingsDlg(QWidget* parent):QDialog(parent,Qt::Dialog) + { + setupUi(this); ++ ++ // YMA add scroll area ++ QWidget* wrapper = new QWidget(); ++ wrapper->setLayout(this->layout()); ++ ++ QScrollArea* scrollArea = new QScrollArea(this); ++ scrollArea->setWidgetResizable(true); ++ scrollArea->setWidget(wrapper); ++ ++ QHBoxLayout* wrapperLayout = new QHBoxLayout(); ++ wrapperLayout->addWidget(scrollArea); ++ this->setLayout(wrapperLayout); ++ + connect(listWidget, SIGNAL( currentRowChanged(int) ), stackedWidget, SLOT( setCurrentIndex(int) ) ); + + connect(DialogButtons, SIGNAL( accepted() ), this, SLOT( OnOK() ) ); -- 1.7.9.5