From 38a7fdbeff355e5df5c6552306a23d46074e3e0a Mon Sep 17 00:00:00 2001
From: necoro <>
Date: Fri, 24 Nov 2006 11:37:48 +0000
Subject: Added a save-flags-menu
---
geneticone/gui/gtk/dialogs.py | 2 +-
geneticone/gui/gtk/glade/geneticone.glade | 390 +++++++++++++++---------------
geneticone/gui/gtk/windows.py | 8 +
3 files changed, 208 insertions(+), 192 deletions(-)
(limited to 'geneticone/gui/gtk')
diff --git a/geneticone/gui/gtk/dialogs.py b/geneticone/gui/gtk/dialogs.py
index 7607fd4..ba74524 100644
--- a/geneticone/gui/gtk/dialogs.py
+++ b/geneticone/gui/gtk/dialogs.py
@@ -29,7 +29,7 @@ def blocked_dialog (blocked, blocks):
return ret
def not_root_dialog ():
- errorMB = gtk.MessageDialog(None, gtk.DIALOG_MODAL, gtk.MESSAGE_ERROR, gtk.BUTTONS_OK, "You cannot (un)merge without being root.")
+ errorMB = gtk.MessageDialog(None, gtk.DIALOG_MODAL, gtk.MESSAGE_ERROR, gtk.BUTTONS_OK, "You are not root.")
ret = errorMB.run()
errorMB.destroy()
return ret
diff --git a/geneticone/gui/gtk/glade/geneticone.glade b/geneticone/gui/gtk/glade/geneticone.glade
index fa060df..89f5950 100644
--- a/geneticone/gui/gtk/glade/geneticone.glade
+++ b/geneticone/gui/gtk/glade/geneticone.glade
@@ -93,6 +93,14 @@
+
+
+
@@ -223,72 +231,48 @@
4
2
-
+
True
- GTK_POLICY_AUTOMATIC
- GTK_POLICY_AUTOMATIC
+ 1
+ True
-
+
True
+ True
+ Installed
+ True
+
+
+ False
+
-
-
- 2
- 2
- 3
- 5
- 5
-
-
-
-
- True
-
+
+ True
+ True
+ Masked
+ True
+
+
+
+ False
+ 1
+
+
+
+
+ True
+ True
+ Testing
+ True
+
+
+
+ False
+ 2
+
-
-
- 1
- 2
- GTK_FILL
- 5
-
-
-
-
- True
- GTK_JUSTIFY_CENTER
- True
-
-
- 2
- GTK_FILL
-
- 10
-
-
-
-
- True
- True
- <span foreground='red'><b>MISSING KEYWORD</b></span>
- True
-
-
- 1
- 2
- 1
- 2
- GTK_FILL
-
-
-
-
- True
- True
- <b>Installed, but not in portage anymore</b>
- True
1
@@ -342,55 +326,79 @@
-
+
+ True
+ True
+ <b>Installed, but not in portage anymore</b>
+ True
+
+
+ 1
+ 2
+ 1
+ 2
+ GTK_FILL
+
+
+
+
+ True
+ True
+ <span foreground='red'><b>MISSING KEYWORD</b></span>
+ True
+
+
+ 1
+ 2
+ 1
+ 2
+ GTK_FILL
+
+
+
+
+ True
+ GTK_JUSTIFY_CENTER
+ True
+
+
+ 2
+ GTK_FILL
+
+ 10
+
+
+
+
True
- 1
- True
-
-
- True
- True
- Installed
- True
-
-
-
- False
-
-
-
- True
- True
- Masked
- True
-
-
-
- False
- 1
-
+
+
+
+ 1
+ 2
+ GTK_FILL
+ 5
+
+
+
+
+ True
+ GTK_POLICY_AUTOMATIC
+ GTK_POLICY_AUTOMATIC
-
+
True
- True
- Testing
- True
-
-
- False
- 2
-
- 1
2
- 1
- 2
- GTK_FILL
+ 2
+ 3
+ 5
+ 5
@@ -774,186 +782,186 @@
-
+
True
- 0
- 5
- <u><i>Masking Keywords</i></u>
- True
- True
- 7
- 8
- 5
-
-
-
-
- True
- 0
- 5
- <u><i>Testing Keywords</i></u>
- True
- True
-
-
- 4
- 5
- 5
+ 1
+ 2
+ 3
+ 4
-
+
True
0
- 5
- <u><i>Use-Flags</i></u>
- True
+ File name to use, if package.use is a directory:
True
- 1
- 2
- 6
+ 3
+ 4
-
+
True
-
-
- True
- 0
- GTK_SHADOW_OUT
-
-
- True
- 0
- <u>You may use the following placeholders:</u>
-
-<i>$(cat)</i>: category
-<i>$(pkg)</i>: package name
-<i>$(cat-1)/$(cat-2)</i>: first/second part of the category
- True
-
-
-
-
-
- label_item
-
-
-
-
+ Add only exact version to package.use
+ True
2
+ 2
+ 3
-
+
True
- Add only exact version to package.mask/package.unmask
+ Add only exact version to package.keywords
True
2
- 8
- 9
+ 5
+ 6
-
+
True
0
- File name to use, if package.mask/package.unmask is a directory:
+ File name to use, if package.keywords is a directory:
True
- 9
- 10
+ 6
+ 7
-
+
True
1
2
- 9
- 10
+ 6
+ 7
-
+
True
1
2
- 6
- 7
+ 9
+ 10
-
+
True
0
- File name to use, if package.keywords is a directory:
+ File name to use, if package.mask/package.unmask is a directory:
True
- 6
- 7
+ 9
+ 10
-
+
True
- Add only exact version to package.keywords
+ Add only exact version to package.mask/package.unmask
True
2
- 5
- 6
+ 8
+ 9
-
+
True
- Add only exact version to package.use
- True
+
+
+ True
+ 0
+ GTK_SHADOW_OUT
+
+
+ True
+ 0
+ <u>You may use the following placeholders:</u>
+
+<i>$(cat)</i>: category
+<i>$(pkg)</i>: package name
+<i>$(cat-1)/$(cat-2)</i>: first/second part of the category
+ True
+
+
+
+
+
+ label_item
+
+
+
+
2
- 2
- 3
-
+
True
0
- File name to use, if package.use is a directory:
+ 5
+ <u><i>Use-Flags</i></u>
+ True
True
- 3
- 4
+ 1
+ 2
+ 6
-
+
+ True
+ 0
+ 5
+ <u><i>Testing Keywords</i></u>
+ True
+ True
+
+
+ 4
+ 5
+ 5
+
+
+
+
True
+ 0
+ 5
+ <u><i>Masking Keywords</i></u>
+ True
+ True
- 1
- 2
- 3
- 4
+ 7
+ 8
+ 5
diff --git a/geneticone/gui/gtk/windows.py b/geneticone/gui/gtk/windows.py
index 8623e51..ee50ca4 100644
--- a/geneticone/gui/gtk/windows.py
+++ b/geneticone/gui/gtk/windows.py
@@ -812,6 +812,14 @@ class MainWindow (Window):
self.queue.sync(cmd)
else:
self.queue.sync()
+
+ def cb_save_flags_clicked (self, action):
+ if not backend.am_i_root():
+ not_root_dialog()
+ else:
+ flags.write_use_flags()
+ flags.write_testing()
+ flags.write_masked()
@Window.watch_cursor
def cb_reload_clicked (self, action):
--
cgit v1.2.3-70-g09d2