display more details about OS in about dialogue
This commit is contained in:
parent
f8fae139be
commit
2d8e611f2d
|
@ -265,11 +265,16 @@ class fpdb:
|
||||||
dia.set_authors(['Steffen', 'Eratosthenes', 'Carl Gherardi',
|
dia.set_authors(['Steffen', 'Eratosthenes', 'Carl Gherardi',
|
||||||
'Eric Blade', '_mt', 'sqlcoder', 'Bostik', _('and others')])
|
'Eric Blade', '_mt', 'sqlcoder', 'Bostik', _('and others')])
|
||||||
dia.set_program_name("Free Poker Database (FPDB)")
|
dia.set_program_name("Free Poker Database (FPDB)")
|
||||||
|
|
||||||
db_version = ""
|
if (os.name=="posix"):
|
||||||
#if self.db is not None:
|
os_text=str(os.uname())
|
||||||
# db_version = self.db.get_version()
|
elif (os.name=="nt"):
|
||||||
nums = [(_('Operating System'), os.name),
|
import platform
|
||||||
|
os_text=("Windows" + " " + str(platform.win32_ver()))
|
||||||
|
else:
|
||||||
|
os_text="Unknown"
|
||||||
|
|
||||||
|
nums = [(_('Operating System'), os_text),
|
||||||
('Python', sys.version[0:3]),
|
('Python', sys.version[0:3]),
|
||||||
('GTK+', '.'.join([str(x) for x in gtk.gtk_version])),
|
('GTK+', '.'.join([str(x) for x in gtk.gtk_version])),
|
||||||
('PyGTK', '.'.join([str(x) for x in gtk.pygtk_version])),
|
('PyGTK', '.'.join([str(x) for x in gtk.pygtk_version])),
|
||||||
|
@ -281,7 +286,7 @@ class fpdb:
|
||||||
]
|
]
|
||||||
versions = gtk.TextBuffer()
|
versions = gtk.TextBuffer()
|
||||||
w = 20 # width used for module names and version numbers
|
w = 20 # width used for module names and version numbers
|
||||||
versions.set_text('\n'.join([x[0].rjust(w) + ' ' + x[1].ljust(w) for x in nums]))
|
versions.set_text('\n'.join([x[0].rjust(w) + ': ' + x[1].ljust(w) for x in nums]))
|
||||||
view = gtk.TextView(versions)
|
view = gtk.TextView(versions)
|
||||||
view.set_editable(False)
|
view.set_editable(False)
|
||||||
view.set_justification(gtk.JUSTIFY_CENTER)
|
view.set_justification(gtk.JUSTIFY_CENTER)
|
||||||
|
|
Loading…
Reference in New Issue
Block a user