FAQ Search Today's Posts Mark Forums Read
» Video Reviews

» Linux Archive

Linux-archive is a website aiming to archive linux email lists and to make them easily accessible for linux users/developers.


» Sponsor

» Partners

» Sponsor

Go Back   Linux Archive > Redhat > Fedora SELinux Support

 
 
LinkBack Thread Tools
 
Old 12-14-2009, 05:29 PM
Chris Lumens
 
Default Add ignore all/reinit all buttons to reinitialization dialogs (#512011).

I'm not sure how I feel about this from a UI perspective, but take a look and
let me know what you think. It does make some sense to me, at least if you
have a ton of disks.

- Chris

_______________________________________________
Anaconda-devel-list mailing list
Anaconda-devel-list@redhat.com
https://www.redhat.com/mailman/listinfo/anaconda-devel-list
 
Old 12-14-2009, 05:29 PM
Chris Lumens
 
Default Add ignore all/reinit all buttons to reinitialization dialogs (#512011).

In conjunction with the filtering UI patches, this is meant to help setups
where you have a whole lot of disks and don't want to see one dialog after
another for every single disk.
---
storage/devicetree.py | 45 ++++++++++++++++++++++++++++++++++++++++-----
1 files changed, 40 insertions(+), 5 deletions(-)

diff --git a/storage/devicetree.py b/storage/devicetree.py
index 6e1eb98..bc4a97e 100644
--- a/storage/devicetree.py
+++ b/storage/devicetree.py
@@ -126,8 +126,18 @@ def getLUKSPassphrase(intf, device, globalPassphrase):

return (passphrase, isglobal)

+ignoreAllDisks = False
+reinitAllDisks = False
+
# Don't really know where to put this.
def questionInitializeDisk(intf=None, path=None, description=None):
+ global ignoreAllDisks, reinitAllDisks
+
+ if ignoreAllDisks:
+ return False
+ elif reinitAllDisks:
+ return True
+
retVal = False # The less destructive default
if not intf or not path:
pass
@@ -154,15 +164,33 @@ def questionInitializeDisk(intf=None, path=None, description=None):
'description': description, 'details': details},
type="custom",
custom_buttons = [ _("_Ignore drive"),
- _("_Re-initialize drive") ],
+ _("Ignore _all"),
+ _("_Re-initialize drive"),
+ _("Re-initialize a_ll") ],
custom_icon="question")
if rc == 0:
pass
- else:
+ elif rc == 1:
+ ignoreAllDisks = True
+ elif rc == 2:
+ retVal = True
+ elif rc == 3:
+ reinitAllDisks = True
retVal = True
+
return retVal

+ignoreAllLVMs = False
+reinitAllLVMs = False
+
def questionReinitILVM(intf=None, pv_names=None, lv_name=None, vg_name=None):
+ global ignoreAllLVMs, reinitAllLVMs
+
+ if ignoreAllLVMs:
+ return False
+ elif reinitAllLVMs:
+ return True
+
retVal = False # The less destructive default
if not intf or not pv_names or (lv_name is None and vg_name is None):
pass
@@ -181,12 +209,19 @@ def questionReinitILVM(intf=None, pv_names=None, lv_name=None, vg_name=None):
"contents.") % na,
type="custom",
custom_buttons = [ _("_Ignore"),
- _("_Re-initialize") ],
+ _("Ignore _all"),
+ _("_Re-initialize"),
+ _("Re-initialize a_ll") ],
custom_icon="question")
if rc == 0:
pass
- else:
- retVal = True # thie means clobber.
+ elif rc == 1:
+ ignoreAllLVMs = True
+ elif rc == 2:
+ retVal = True
+ elif rc == 3:
+ reinitAllLVMs = True
+ retVal = True

return retVal

--
1.6.5.1

_______________________________________________
Anaconda-devel-list mailing list
Anaconda-devel-list@redhat.com
https://www.redhat.com/mailman/listinfo/anaconda-devel-list
 

Thread Tools




All times are GMT. The time now is 01:45 AM.

VBulletin, Copyright ©2000 - 2014, Jelsoft Enterprises Ltd.
Content Relevant URLs by vBSEO ©2007, Crawlability, Inc.
Copyright 2007 - 2008, www.linux-archive.org