changeset 4:c0da99091e1d grumpy-goblin

Check out the new About Dialog.
author sirebral
date Wed, 15 Jul 2009 02:09:11 -0500
parents 28ad6bd3ac71
children 5a2c95067daf
files orpg/main.py orpg/templates/about.html
diffstat 2 files changed, 39 insertions(+), 80 deletions(-) [+]
line wrap: on
line diff
--- a/orpg/main.py	Tue Jul 14 21:25:00 2009 -0500
+++ b/orpg/main.py	Wed Jul 15 02:09:11 2009 -0500
@@ -598,42 +598,54 @@
 
     #Help Menu
     def OnMB_HelpAbout(self):
-        "The about box.  We're making it n HTML about box because it's pretty cool!"
-        "Inspired by the wxWindows about.cpp sample."
-        topSizer = wx.BoxSizer( wx.VERTICAL )
-        dlg = wx.Dialog( self, -1, "About" )
-        html = AboutHTMLWindow( dlg, -1, wx.DefaultPosition, wx.Size(400, 200), wx.html.HW_SCROLLBAR_NEVER )
-        html.SetBorders( 0 )
-        replace_text = "VeRsIoNrEpLaCeMeNtStRiNg"
-        about_file = open(orpg.dirpath.dir_struct["template"]+"about.html","r")
-        about_text = about_file.read()
-        about_file.close()
-        display_text = string.replace(about_text,replace_text,VERSION)
-        html.SetPage(display_text)
-        html.SetSize( wx.Size(html.GetInternalRepresentation().GetWidth(),
-                             html.GetInternalRepresentation().GetHeight()) )
-        topSizer.Add( html, 1, wx.ALL, 10 )
-        topSizer.Add( wx.StaticLine( dlg, -1), 0, wx.EXPAND | wx.LEFT | wx.RIGHT, 10 )
-        Okay = wx.Button( dlg, wx.ID_OK, "Okay" )
-        Okay.SetDefault()
-        topSizer.Add( Okay, 0, wx.ALL | wx.ALIGN_RIGHT, 15 )
-        dlg.SetAutoLayout( True )
-        dlg.SetSizer( topSizer )
-        topSizer.Fit( dlg )
-        dlg.ShowModal()
-        dlg.Destroy()
+
+        description = """OpenRPG is a Virtual Game Table that allows users to connect via a network and play table
+top games with friends.  'Traipse' is an OpenRPG distro that is easy to setup and provides superb 
+functionality.  OpenRPG is originally designed by Chris Davis."""
+
+        license = """OpenRPG is free software; you can redistribute it and/or modify it 
+under the terms of the GNU General Public License as published by the Free Software Foundation; 
+either version 2 of the License, or (at your option) any later version.
+
+OpenRPG and Traipse 'OpenRPG' is distributed in the hope that it will be useful, but WITHOUT ANY WARRANTY; 
+without even the implied warranty of MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE.  
+See the GNU General Public License for more details. You should have received a copy of 
+the GNU General Public License along with Traipse 'OpenRPG'; if not, write to 
+the Free Software Foundation, Inc., 59 Temple Place, Suite 330, Boston, MA  02111-1307  USA
+
+'Traipse' and the 'Traipse' Logo are trademarks of Mad Mathematics Laboratories."""
+
+        info = wx.AboutDialogInfo()
+        info.SetIcon(wx.Icon(orpg.dirpath.dir_struct["icon"]+'splash.gif', wx.BITMAP_TYPE_GIF))
+        info.SetName('Traipse')
+        info.SetVersion('OpenRPG ' + VERSION)
+        info.SetDescription(description)
+        info.SetCopyright('(C) 2009 Mad Math Labs')
+        info.SetWebSite('http://www.openrpg.com')
+        info.SetLicence(license)
+        orpg_devs = ['Thomas Baleno', 'Andrew Bennett', 'Lex Berezhny', 'Ted Berg',
+		'Bernhard Bergbauer', 'Chris Blocher', 'David Byron', 'Ben Collins-Sussman', 'Robin Cook', 'Greg Copeland',
+		'Chris Davis', 'Michael Edwards', 'Andrew Ettinger', 'Todd Faris', 'Dj Gilcrease',
+        'Christopher Hickman', 'Paul Hosking', 'Brian Manning', 'Scott Mackay', 'Jesse McConnell', 
+		'Brian Osman', 'Rome Reginelli', 'Christopher Rouse', 'Dave Sanders', 'Tyler Starke', 'Mark Tarrabain']
+        for dev in orpg_devs:
+            info.AddDeveloper(dev)
+        #info.AddDocWriter('jan bodnar')
+        #info.AddArtist('The Tango crew')
+        #info.AddTranslator('jan bodnar')
+        wx.AboutBox(info)
 
     def OnMB_HelpOnlineUserGuide(self):
         wb = webbrowser.get()
-        wb.open("https://www.assembla.com/wiki/show/openrpg/User_Manual")
+        wb.open("https://www.assembla.com/wiki/show/traipse/User_Manual")
 
     def OnMB_HelpChangeLog(self):
         wb = webbrowser.get()
-        wb.open("http://www.assembla.com/spaces/milestones/index/openrpg?spaces_tool_id=Milestones")
+        wb.open("http://www.assembla.com/spaces/milestones/index/traipse_dev?spaces_tool_id=Milestones")
 
     def OnMB_HelpReportaBug(self):
         wb = webbrowser.get()
-        wb.open("http://www.assembla.com/spaces/tickets/index/openrpg?spaces_tool_id=Tickets")
+        wb.open("http://www.assembla.com/spaces/tickets/index/traipse_dev?spaces_tool_id=Tickets")
 
 
     #################################
--- a/orpg/templates/about.html	Tue Jul 14 21:25:00 2009 -0500
+++ /dev/null	Thu Jan 01 00:00:00 1970 +0000
@@ -1,53 +0,0 @@
-<!DOCTYPE HTML PUBLIC "-//IETF//DTD HTML//EN">
-<html>
-  <body bgcolor="#FFFFFF">
-    <table cellspacing=3 cellpadding=4 width="100%">
-      <tr>
-	<td bgcolor="#101010" align="bottom">
-	  <center><a href="http://www.openrpg.com"><img src="images/splash.gif"></a></center>
-	</td>
-      </tr>
-      <tr>
-	<td bgcolor="#101010" align="center">
-	  <font size="+4" color="#FFFFFF"><b><br>Version VeRsIoNrEpLaCeMeNtStRiNg<br></b></font>
-	</td>
-      </tr>
-      <tr>
-	<td bgcolor="#73A183" align="center">
-	  <b><font size="+1">Special thanks to Chris Davis for this endeavor</a></font></b>
-	  <p>
-	  <table cellpadding="0" cellspacing="0" width="100%">
-	    <tr>
-	      <td align="center" width="100%">
-		Of course, many thanks goes to all of those who contributed.
-		<BR>
-		The developers in alphabetical order are:
-		<BR>
-		Thomas Baleno, Andrew Bennett, Lex Berezhny, Ted Berg,
-		Bernhard Bergbauer, Chris Blocher, David Byron, Ben Collins-Sussman, Robin Cook, Greg Copeland,
-		Chris Davis, Michael Edwards, Andrew Ettinger, Todd Faris, Dj Gilcrease,
-        Christopher Hickman, Paul Hosking, Brian Manning, Scott Mackay, Jesse McConnell, 
-		Brian Osman, Rome Reginelli, Christopher Rouse, Dave Sanders, Tyler Starke, and Mark Tarrabain.
-	      </td>
-	    </tr>
-	    <tr>
-	      <td align="center" width="100%">
-		<a href="http://www.python.org"><img src="images/python55.gif"></a>
-		<a href="http://www.wxwindows.org"><img src="images/wxWinButton.png"></a>
-		<a href="http://www.wxpython.org"><img src="images/wxPyButton.png"></a>
-		<a href="http://www.sourceforge.net"><img src="images/sflogo.png"></a>
-	      </td>
-	    </tr>
-	    <tr>
-	      <td align="center" width="100%">
-		This product is licensed under the <a href="http://www.gnu.org">GNU</a> <a href="http://www.gnu.org/philosophy/license-list.html">GPL License.</a>
-	      </td>
-	    </tr>
-	  </table>
-	</td>
-      </tr>
-    </table>
-
-<!-- Created: Fri Jun  1 17:32:22 CDT 2001 -->
-  </body>
-</html>