Ignore:
Timestamp:
10/23/2008 07:58:28 AM (4 years ago)
Author:
guyru
Message:

about dialog rewrite - part 1

File:
1 edited

Legend:

Unmodified
Added
Removed
  • trunk/src/MainFrame.cpp

    r180 r182  
    3131#include "wxDynamicBitmap.h" 
    3232#include "highscores_dialog.h" 
    33 #include "About.h" 
     33#include "about.h" 
    3434#include "configuration.h" 
    3535#include "settings_dialog.h" 
     
    4141#include <wx/filename.h> 
    4242#include <wx/stdpaths.h> 
     43#include <wx/aboutdlg.h> 
     44#include <wx/mstream.h> 
    4345 
    4446 //include the images for the dice        
     
    5355 
    5456#include "icon32.xpm" 
     57#include "openyahtzee_logo.png.h" 
    5558 
    5659//default values - design 
     
    384387void MainFrame::OnAbout(wxCommandEvent& event) 
    385388{ 
     389        wxAboutDialogInfo info; 
     390        info.SetName(wxT(PACKAGE_NAME)); 
     391        info.SetVersion(wxT(PACKAGE_VERSION)); 
     392        info.SetDescription(wxT("A cross-platform Yahtzee game.")); 
     393        info.SetCopyright(wxT("(C) 2006-2008 Guy Rutenberg")); 
     394        info.SetWebSite(wxT("http://www.openyahtzee.org/")); 
     395 
     396        wxMemoryInputStream istream(openyahtzee_logo_png, sizeof openyahtzee_logo_png); 
     397        wxImage myimage_img(istream, wxBITMAP_TYPE_PNG); 
     398 
     399        wxIcon logo; 
     400        logo.CopyFromBitmap(wxBitmap(myimage_img)); 
     401        info.SetIcon(logo); 
     402 
     403        info.AddDeveloper(wxT("Guy Rutenberg <guyrutenberg@gmail.com>")); 
     404        info.AddArtist(wxT("Seamous Mc\nGill <johndoe@gmail.com>")); 
     405 
     406        //wxAboutBox(info); 
    386407#ifdef PORTABLE 
    387         AboutDialog *about = new AboutDialog(this,wxID_ANY,wxT("About Open Yahtzee PE")); 
     408        about::AboutDialog *about = new about::AboutDialog(this); 
    388409#else 
    389         AboutDialog *about = new AboutDialog(this,wxID_ANY,wxT("About Open Yahtzee")); 
     410        about::AboutDialog *about = new about::AboutDialog(this); 
    390411#endif 
    391412        about->ShowModal(); 
Note: See TracChangeset for help on using the changeset viewer.