From fac76d2a4493698cc1a87d78bacd9a8fc23c7c9a Mon Sep 17 00:00:00 2001 From: =?UTF-8?q?Ren=C3=A9=20=27Necoro=27=20Neumann?= Date: Wed, 18 Feb 2009 16:00:54 +0100 Subject: Added an extra 'Portage' tab to the preference dialog and moved all portage related options there --- doc/Changelog | 1 + portato/gui/templates/PreferenceWindow.glade | 47 +++++++++++++++++++++------- 2 files changed, 37 insertions(+), 11 deletions(-) diff --git a/doc/Changelog b/doc/Changelog index 1981cf9..31881b5 100644 --- a/doc/Changelog +++ b/doc/Changelog @@ -6,6 +6,7 @@ next: - remembers the height and width of the preference window - debug improvements - check prerequisites before starting +- reorganize preferences - bugs fixed: #44, #41, #15, #47 0.11.1: diff --git a/portato/gui/templates/PreferenceWindow.glade b/portato/gui/templates/PreferenceWindow.glade index 5fe6a46..5a772fa 100644 --- a/portato/gui/templates/PreferenceWindow.glade +++ b/portato/gui/templates/PreferenceWindow.glade @@ -1,6 +1,6 @@ - + 5 @@ -95,6 +95,31 @@ False + + + + + + + + + + + + + + True + GDK_POINTER_MOTION_MASK | GDK_POINTER_MOTION_HINT_MASK | GDK_BUTTON_PRESS_MASK | GDK_BUTTON_RELEASE_MASK + General + + + tab + False + + + + + True True @@ -192,9 +217,6 @@ - - 1 - @@ -244,7 +266,7 @@ False - 2 + 1 @@ -476,19 +498,22 @@ False - 3 + 2 + + 1 + - + True - GDK_POINTER_MOTION_MASK | GDK_POINTER_MOTION_HINT_MASK | GDK_BUTTON_PRESS_MASK | GDK_BUTTON_RELEASE_MASK - General + Portage tab + 1 False @@ -867,7 +892,7 @@ As an example: <i>app-admin</i>, <i>app-emacs</i>, and & - 1 + 2 @@ -878,7 +903,7 @@ As an example: <i>app-admin</i>, <i>app-emacs</i>, and & tab - 1 + 2 False -- cgit v1.2.3 From 0f26590f30ac676970e69699f231ab222c21a313 Mon Sep 17 00:00:00 2001 From: =?UTF-8?q?Ren=C3=A9=20=27Necoro=27=20Neumann?= Date: Wed, 18 Feb 2009 16:06:08 +0100 Subject: Added database choice to dialog --- portato/gui/templates/PreferenceWindow.glade | 60 +++++++++++++++++++++++++++- 1 file changed, 58 insertions(+), 2 deletions(-) diff --git a/portato/gui/templates/PreferenceWindow.glade b/portato/gui/templates/PreferenceWindow.glade index 5a772fa..9e1d6c5 100644 --- a/portato/gui/templates/PreferenceWindow.glade +++ b/portato/gui/templates/PreferenceWindow.glade @@ -1,6 +1,6 @@ - + 5 @@ -96,7 +96,63 @@ - + + True + 0 + + + True + 5 + 5 + 12 + 5 + + + True + + + True + GDK_POINTER_MOTION_MASK | GDK_POINTER_MOTION_HINT_MASK | GDK_BUTTON_PRESS_MASK | GDK_BUTTON_RELEASE_MASK + True + + + True + GDK_POINTER_MOTION_MASK | GDK_POINTER_MOTION_HINT_MASK | GDK_BUTTON_PRESS_MASK | GDK_BUTTON_RELEASE_MASK + 0 + Used database type + + + + + True + GDK_POINTER_MOTION_MASK | GDK_POINTER_MOTION_HINT_MASK | GDK_BUTTON_PRESS_MASK | GDK_BUTTON_RELEASE_MASK + + + + 1 + + + + + + + + + + + True + <b>Database Options</b> + True + + + label_item + + + + + False + 1 + -- cgit v1.2.3 From aee9ac1390410b1a751978da59ce10d6468cd551 Mon Sep 17 00:00:00 2001 From: =?UTF-8?q?Ren=C3=A9=20=27Necoro=27=20Neumann?= Date: Wed, 18 Feb 2009 16:30:03 +0100 Subject: Show database types in the preferences - though nothing useful can be done atm ;) --- portato/db/__init__.py | 5 +++++ portato/gui/windows/preference.py | 11 +++++++++++ 2 files changed, 16 insertions(+) diff --git a/portato/db/__init__.py b/portato/db/__init__.py index 05dbfcf..d36f900 100644 --- a/portato/db/__init__.py +++ b/portato/db/__init__.py @@ -18,6 +18,11 @@ from ..helper import debug, warning _SESSION = None _TYPE = None +types = { + "sql": (_("SQLite"), _("Uses an SQLite-database to store package information.\nMay take longer to generate at the first time, but has advantages if portato is re-started with an unchanged portage tree. Additionally it allows to use fast SQL expressions for fetching the data.")), + "dict": (_("Hashmap"), _("Uses an in-memory hashmap to store package information.\nHas been used since at least version 0.3.3, but all information has to be regenerated on each startup.")) + } + def _set_type(t): global _TYPE _TYPE = t diff --git a/portato/gui/windows/preference.py b/portato/gui/windows/preference.py index df18e88..c8025d0 100644 --- a/portato/gui/windows/preference.py +++ b/portato/gui/windows/preference.py @@ -20,6 +20,7 @@ from .basic import AbstractDialog from ..dialogs import io_ex_dialog from ..utils import get_color from ...helper import debug +from ... import db class PreferenceWindow (AbstractDialog): """Window displaying some preferences.""" @@ -151,6 +152,16 @@ class PreferenceWindow (AbstractDialog): self.systemTabCombo.set_active(int(self.cfg.get("systemTabPos", section = "GUI"))-1) self.pkgTabCombo.set_active(int(self.cfg.get("packageTabPos", section = "GUI"))-1) + # the database combo + self.databaseCombo = self.tree.get_widget("databaseCombo") + model = gtk.ListStore(str, str, str) + + for k, (name, desc) in db.types.iteritems(): + model.append([name, desc, k]) + + self.databaseCombo.set_model(model) + self.databaseCombo.set_active(0) # XXX: just set one thing active - no meaning yet + self.window.show_all() def _save(self): -- cgit v1.2.3 From edffa4112136c525e5db84ec1b1a59ebd7a4a5c8 Mon Sep 17 00:00:00 2001 From: =?UTF-8?q?Ren=C3=A9=20=27Necoro=27=20Neumann?= Date: Wed, 18 Feb 2009 19:40:18 +0100 Subject: Fix the 'GtkSpinButton' warning --- portato/gui/templates/PreferenceWindow.glade | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/portato/gui/templates/PreferenceWindow.glade b/portato/gui/templates/PreferenceWindow.glade index 9e1d6c5..68718ea 100644 --- a/portato/gui/templates/PreferenceWindow.glade +++ b/portato/gui/templates/PreferenceWindow.glade @@ -755,7 +755,7 @@ True True - 0 0 300 1 10 10 + 0 0 300 1 10 0 True True -- cgit v1.2.3 From 812dbac4e61849a1206544121a95b1a98a300d34 Mon Sep 17 00:00:00 2001 From: =?UTF-8?q?Ren=C3=A9=20=27Necoro=27=20Neumann?= Date: Wed, 18 Feb 2009 22:01:40 +0100 Subject: Converted glade files --- portato/gui/templates/AboutWindow.glade | 56 -- portato/gui/templates/AboutWindow.ui | 55 ++ portato/gui/templates/MailInfoWindow.glade | 224 ----- portato/gui/templates/MailInfoWindow.ui | 220 +++++ portato/gui/templates/MainWindow.glade | 1275 -------------------------- portato/gui/templates/MainWindow.ui | 1122 +++++++++++++++++++++++ portato/gui/templates/PluginWindow.glade | 253 ----- portato/gui/templates/PluginWindow.ui | 239 +++++ portato/gui/templates/PreferenceWindow.glade | 1004 -------------------- portato/gui/templates/PreferenceWindow.ui | 950 +++++++++++++++++++ portato/gui/templates/SearchWindow.glade | 94 -- portato/gui/templates/SearchWindow.ui | 90 ++ portato/gui/templates/SplashScreen.glade | 61 -- portato/gui/templates/SplashScreen.ui | 60 ++ portato/gui/templates/UpdateWindow.glade | 94 -- portato/gui/templates/UpdateWindow.ui | 90 ++ portato/gui/templates/popups.glade | 44 - portato/gui/templates/popups.ui | 42 + 18 files changed, 2868 insertions(+), 3105 deletions(-) delete mode 100644 portato/gui/templates/AboutWindow.glade create mode 100644 portato/gui/templates/AboutWindow.ui delete mode 100644 portato/gui/templates/MailInfoWindow.glade create mode 100644 portato/gui/templates/MailInfoWindow.ui delete mode 100644 portato/gui/templates/MainWindow.glade create mode 100644 portato/gui/templates/MainWindow.ui delete mode 100644 portato/gui/templates/PluginWindow.glade create mode 100644 portato/gui/templates/PluginWindow.ui delete mode 100644 portato/gui/templates/PreferenceWindow.glade create mode 100644 portato/gui/templates/PreferenceWindow.ui delete mode 100644 portato/gui/templates/SearchWindow.glade create mode 100644 portato/gui/templates/SearchWindow.ui delete mode 100644 portato/gui/templates/SplashScreen.glade create mode 100644 portato/gui/templates/SplashScreen.ui delete mode 100644 portato/gui/templates/UpdateWindow.glade create mode 100644 portato/gui/templates/UpdateWindow.ui delete mode 100644 portato/gui/templates/popups.glade create mode 100644 portato/gui/templates/popups.ui diff --git a/portato/gui/templates/AboutWindow.glade b/portato/gui/templates/AboutWindow.glade deleted file mode 100644 index 9c966b2..0000000 --- a/portato/gui/templates/AboutWindow.glade +++ /dev/null @@ -1,56 +0,0 @@ - - - - - - GDK_POINTER_MOTION_MASK | GDK_POINTER_MOTION_HINT_MASK | GDK_BUTTON_PRESS_MASK | GDK_BUTTON_RELEASE_MASK - 5 - About Portato - False - GTK_WIN_POS_CENTER_ON_PARENT - True - GDK_WINDOW_TYPE_HINT_DIALOG - True - True - True - False - Portato - This software is licensed under the terms of the GPLv2. -Copyright (C) 2006-2009 René 'Necoro' Neumann <necoro@necoro.net> - A Portage GUI - http://portato.necoro.net - René 'Necoro' Neumann - -Thanks goto: - - The Porthole team, which often inspired me and gave me hints :) - - franzf, who often tested and gave comments - - the Sabayon-Distro for making Portato the default Portage-GUI - Catalan - Roger Calvó -German - René 'Necoro' Neumann -Polish - Tomasz Osiński -Turkish - Gürkan 'seqizz' Gür - p4r4d0x (inspired by wolfden) - - - - True - GDK_POINTER_MOTION_MASK | GDK_POINTER_MOTION_HINT_MASK | GDK_BUTTON_PRESS_MASK | GDK_BUTTON_RELEASE_MASK - 2 - - - - - - True - GDK_POINTER_MOTION_MASK | GDK_POINTER_MOTION_HINT_MASK | GDK_BUTTON_PRESS_MASK | GDK_BUTTON_RELEASE_MASK - GTK_BUTTONBOX_END - - - False - GTK_PACK_END - - - - - - diff --git a/portato/gui/templates/AboutWindow.ui b/portato/gui/templates/AboutWindow.ui new file mode 100644 index 0000000..20abe2e --- /dev/null +++ b/portato/gui/templates/AboutWindow.ui @@ -0,0 +1,55 @@ + + + + + GDK_POINTER_MOTION_MASK | GDK_POINTER_MOTION_HINT_MASK | GDK_BUTTON_PRESS_MASK | GDK_BUTTON_RELEASE_MASK + 5 + About Portato + False + GTK_WIN_POS_CENTER_ON_PARENT + True + GDK_WINDOW_TYPE_HINT_DIALOG + True + True + True + False + Portato + This software is licensed under the terms of the GPLv2. +Copyright (C) 2006-2009 René 'Necoro' Neumann <necoro@necoro.net> + A Portage GUI + http://portato.necoro.net + René 'Necoro' Neumann + +Thanks goto: + - The Porthole team, which often inspired me and gave me hints :) + - franzf, who often tested and gave comments + - the Sabayon-Distro for making Portato the default Portage-GUI + Catalan - Roger Calvó +German - René 'Necoro' Neumann +Polish - Tomasz Osiński +Turkish - Gürkan 'seqizz' Gür + p4r4d0x (inspired by wolfden) + + + + True + GDK_POINTER_MOTION_MASK | GDK_POINTER_MOTION_HINT_MASK | GDK_BUTTON_PRESS_MASK | GDK_BUTTON_RELEASE_MASK + 2 + + + + + + True + GDK_POINTER_MOTION_MASK | GDK_POINTER_MOTION_HINT_MASK | GDK_BUTTON_PRESS_MASK | GDK_BUTTON_RELEASE_MASK + GTK_BUTTONBOX_END + + + False + GTK_PACK_END + + + + + + diff --git a/portato/gui/templates/MailInfoWindow.glade b/portato/gui/templates/MailInfoWindow.glade deleted file mode 100644 index 11ef33a..0000000 --- a/portato/gui/templates/MailInfoWindow.glade +++ /dev/null @@ -1,224 +0,0 @@ - - - - - - Send Bug Mail ... - True - GTK_WIN_POS_CENTER - 450 - 230 - True - GDK_WINDOW_TYPE_HINT_DIALOG - True - True - True - - - True - - - True - 5 - 2 - 10 - - - - - - True - <b><u>Additional Information</u></b> - -(all optional) - True - GTK_JUSTIFY_CENTER - - - 2 - GTK_FILL - - - - - True - True - - - 1 - 2 - 1 - 2 - GTK_FILL - 5 - - - - - True - True - - - 1 - 2 - 2 - 3 - GTK_FILL - GTK_FILL - 5 - - - - - True - 0 - Email address: - True - - - 2 - 3 - GTK_FILL - GTK_FILL - 5 - - - - - True - 0 - Name: - True - - - 1 - 2 - GTK_FILL - GTK_FILL - 5 - - - - - True - 0 - Comments / -what did you do to hit the bug? - - - 3 - 4 - GTK_FILL - 5 - - - - - True - True - GTK_POLICY_NEVER - GTK_POLICY_AUTOMATIC - GTK_SHADOW_IN - - - 50 - True - True - - - - - 1 - 2 - 3 - 4 - 5 - - - - - True - True - Attaches the logfile to the mail. This log only contains debug information. - Attach _Logfile - True - 0 - True - True - - - 4 - 5 - GTK_FILL - - - - - 5 - - - - - True - True - GTK_BUTTONBOX_SPREAD - - - True - True - True - gtk-cancel - True - 0 - - - - - - True - True - True - 0 - - - - True - 2 - - - True - 1 - gtk-ok - - - - - True - 0 - _Send - True - True - - - 1 - - - - - - - 1 - - - - - False - False - 5 - 1 - - - - - - diff --git a/portato/gui/templates/MailInfoWindow.ui b/portato/gui/templates/MailInfoWindow.ui new file mode 100644 index 0000000..e0aad5c --- /dev/null +++ b/portato/gui/templates/MailInfoWindow.ui @@ -0,0 +1,220 @@ + + + + + Send Bug Mail ... + True + GTK_WIN_POS_CENTER + 450 + 230 + True + GDK_WINDOW_TYPE_HINT_DIALOG + True + True + True + + + True + + + True + 5 + 2 + 10 + + + + + + True + <b><u>Additional Information</u></b> + +(all optional) + True + GTK_JUSTIFY_CENTER + + + 2 + GTK_FILL + + + + + True + True + + + 1 + 2 + 1 + 2 + GTK_FILL + 5 + + + + + True + True + + + 1 + 2 + 2 + 3 + GTK_FILL + GTK_FILL + 5 + + + + + True + 0 + Email address: + True + + + 2 + 3 + GTK_FILL + GTK_FILL + 5 + + + + + True + 0 + Name: + True + + + 1 + 2 + GTK_FILL + GTK_FILL + 5 + + + + + True + 0 + Comments / +what did you do to hit the bug? + + + 3 + 4 + GTK_FILL + 5 + + + + + True + True + GTK_POLICY_NEVER + GTK_POLICY_AUTOMATIC + GTK_SHADOW_IN + + + 50 + True + True + + + + + 1 + 2 + 3 + 4 + 5 + + + + + True + True + Attaches the logfile to the mail. This log only contains debug information. + Attach _Logfile + True + True + True + + + 4 + 5 + GTK_FILL + + + + + 5 + + + + + True + True + GTK_BUTTONBOX_SPREAD + + + True + True + True + gtk-cancel + True + + + + + + True + True + True + + + + True + 2 + + + True + 1 + gtk-ok + + + + + True + 0 + _Send + True + True + + + 1 + + + + + + + 1 + + + + + False + False + 5 + 1 + + + + + + diff --git a/portato/gui/templates/MainWindow.glade b/portato/gui/templates/MainWindow.glade deleted file mode 100644 index ad6b4a0..0000000 --- a/portato/gui/templates/MainWindow.glade +++ /dev/null @@ -1,1275 +0,0 @@ - - - - - - 2 - GTK_WIN_POS_CENTER - - - - - - True - - - True - - - True - _File - True - - - True - - - True - _Preferences - True - - - - - True - 0 - 0 - gtk-preferences - 1 - - - - - - - True - Re_load Portage - True - - - - - - True - 0 - 0 - gtk-refresh - 1 - - - - - - - True - - - - - True - gtk-quit - True - True - - - - - - - - - - True - _Emerge - True - - - True - - - True - _Install - True - - - - - True - GDK_POINTER_MOTION_MASK | GDK_POINTER_MOTION_HINT_MASK | GDK_BUTTON_PRESS_MASK | GDK_BUTTON_RELEASE_MASK | GDK_ENTER_NOTIFY_MASK - gtk-add - - - - - - - True - _Uninstall - True - - - - - True - GDK_POINTER_MOTION_MASK | GDK_POINTER_MOTION_HINT_MASK | GDK_BUTTON_PRESS_MASK | GDK_BUTTON_RELEASE_MASK | GDK_ENTER_NOTIFY_MASK - gtk-remove - - - - - - - True - Update _World - True - - - - - - True - GDK_POINTER_MOTION_MASK | GDK_POINTER_MOTION_HINT_MASK | GDK_BUTTON_PRESS_MASK | GDK_BUTTON_RELEASE_MASK - Show Updatable P_ackages - True - - - - - - True - GDK_POINTER_MOTION_MASK | GDK_POINTER_MOTION_HINT_MASK | GDK_BUTTON_PRESS_MASK | GDK_BUTTON_RELEASE_MASK - Show _Only Installed Packages - True - - - - - - - True - - - - - True - _Sync - True - - - - - True - GDK_POINTER_MOTION_MASK | GDK_POINTER_MOTION_HINT_MASK | GDK_BUTTON_PRESS_MASK | GDK_BUTTON_RELEASE_MASK | GDK_ENTER_NOTIFY_MASK - gtk-refresh - - - - - - - True - Save _Flags - True - - - - True - GDK_POINTER_MOTION_MASK | GDK_POINTER_MOTION_HINT_MASK | GDK_BUTTON_PRESS_MASK | GDK_BUTTON_RELEASE_MASK | GDK_ENTER_NOTIFY_MASK - gtk-save - - - - - - - True - - - - - True - GDK_POINTER_MOTION_MASK | GDK_POINTER_MOTION_HINT_MASK | GDK_BUTTON_PRESS_MASK | GDK_BUTTON_RELEASE_MASK - Emerge _Paused - True - - - - - - True - _Kill Emerge - True - - - - - True - 0 - 0 - gtk-stop - 1 - - - - - - - - - - - False - True - Console - - - True - - - True - _Copy - True - - - - True - 0 - 0 - gtk-copy - 1 - - - - - - - True - _Kill Emerge - True - - - - True - 0 - 0 - gtk-stop - 1 - - - - - - - True - GDK_POINTER_MOTION_MASK | GDK_POINTER_MOTION_HINT_MASK | GDK_BUTTON_PRESS_MASK | GDK_BUTTON_RELEASE_MASK - Emerge _Paused - True - - - - - - - - - True - Plu_gins - True - - - True - - - - - - - True - _? - True - - - True - - - True - _About - True - - - - True - 0 - 0 - gtk-about - 1 - - - - - - - True - GDK_POINTER_MOTION_MASK | GDK_POINTER_MOTION_HINT_MASK | GDK_BUTTON_PRESS_MASK | GDK_BUTTON_RELEASE_MASK - _Plugins - True - - - - True - GDK_POINTER_MOTION_MASK | GDK_POINTER_MOTION_HINT_MASK | GDK_BUTTON_PRESS_MASK | GDK_BUTTON_RELEASE_MASK - gtk-connect - - - - - - - - - - - False - - - - - True - 3 - - - True - - - - - - 5 - - - - - True - True - True - GDK_POINTER_MOTION_MASK | GDK_POINTER_MOTION_HINT_MASK | GDK_BUTTON_PRESS_MASK | GDK_BUTTON_RELEASE_MASK - gtk-delete -