Move copy version information code to about dialog.

This commit is contained in:
Simon Wells 2016-03-11 11:40:24 -05:00 committed by Wayne Stambaugh
parent 61eb65f0e9
commit 145cd47d5c
20 changed files with 464 additions and 441 deletions

View File

@ -28,26 +28,17 @@
* @brief EDA_BASE_FRAME class implementation.
*/
#include <wx/aboutdlg.h>
#include <wx/fontdlg.h>
#include <wx/clipbrd.h>
#include <wx/statline.h>
#include <wx/platinfo.h>
#include <wx/stdpaths.h>
#include <wx/string.h>
#include <build_version.h>
#include <fctsys.h>
#include <pgm_base.h>
#include <kiface_i.h>
#include <id.h>
#include <eda_doc.h>
#include <wxstruct.h>
#include <macros.h>
#include <menus_helpers.h>
#include <dialog_shim.h>
#include <eda_doc.h>
#include <id.h>
#include <kiface_i.h>
#include <pgm_base.h>
#include <wxstruct.h>
#include <boost/version.hpp>
#include <typeinfo>
/// The default auto save interval is 10 minutes.
#define DEFAULT_AUTO_SAVE_INTERVAL 600
@ -94,10 +85,6 @@ EDA_BASE_FRAME::EDA_BASE_FRAME( wxWindow* aParent, FRAME_T aFrameType,
m_FramePos.x = m_FramePos.y = 0;
Connect( ID_HELP_COPY_VERSION_STRING,
wxEVT_COMMAND_MENU_SELECTED,
wxCommandEventHandler( EDA_BASE_FRAME::CopyVersionInfoToClipboard ) );
Connect( ID_AUTO_SAVE_TIMER, wxEVT_TIMER,
wxTimerEventHandler( EDA_BASE_FRAME::onAutoSaveTimer ) );
@ -484,145 +471,6 @@ void EDA_BASE_FRAME::GetKicadAbout( wxCommandEvent& event )
}
void EDA_BASE_FRAME::AddHelpVersionInfoMenuEntry( wxMenu* aMenu )
{
wxASSERT( aMenu != NULL );
// Copy version string to clipboard for bug report purposes.
AddMenuItem( aMenu, ID_HELP_COPY_VERSION_STRING,
_( "Copy &Version Information" ),
_( "Copy the version string to clipboard to send with bug reports" ),
KiBitmap( copy_button_xpm ) );
}
// This is an enhanced version of the compiler build macro provided by wxWidgets
// in <wx/build.h>. Please do not make any of these strings translatable. They
// are used for conveying troubleshooting information to developers.
#if defined(__GXX_ABI_VERSION)
#define __ABI_VERSION ",compiler with C++ ABI " __WX_BO_STRINGIZE(__GXX_ABI_VERSION)
#else
#define __ABI_VERSION ",compiler without C++ ABI "
#endif
#if defined(__INTEL_COMPILER)
#define __BO_COMPILER ",Intel C++"
#elif defined(__GNUG__)
#define __BO_COMPILER ",GCC " \
__WX_BO_STRINGIZE(__GNUC__) "." \
__WX_BO_STRINGIZE(__GNUC_MINOR__) "." \
__WX_BO_STRINGIZE(__GNUC_PATCHLEVEL__)
#elif defined(__VISUALC__)
#define __BO_COMPILER ",Visual C++"
#elif defined(__BORLANDC__)
#define __BO_COMPILER ",Borland C++"
#elif defined(__DIGITALMARS__)
#define __BO_COMPILER ",DigitalMars"
#elif defined(__WATCOMC__)
#define __BO_COMPILER ",Watcom C++"
#else
#define __BO_COMPILER ",unknown"
#endif
static inline const char* KICAD_BUILD_OPTIONS_SIGNATURE()
{
return
#ifdef __WXDEBUG__
" (debug,"
#else
" (release,"
#endif
__WX_BO_UNICODE __ABI_VERSION __BO_COMPILER __WX_BO_STL
__WX_BO_WXWIN_COMPAT_2_8 ")"
;
}
void EDA_BASE_FRAME::CopyVersionInfoToClipboard( wxCommandEvent& event )
{
if( !wxTheClipboard->Open() )
{
wxMessageBox( _( "Could not open clipboard to write version information." ),
_( "Clipboard Error" ), wxOK | wxICON_EXCLAMATION, this );
return;
}
wxString msg_version;
wxPlatformInfo info;
msg_version = wxT( "Application: " ) + Pgm().App().GetAppName() + wxT( "\n" );
msg_version << wxT( "Version: " ) << GetBuildVersion()
#ifdef DEBUG
<< wxT( " debug" )
#else
<< wxT( " release" )
#endif
<< wxT( " build\n" );
msg_version << wxT( "wxWidgets: Version " ) << FROM_UTF8( wxVERSION_NUM_DOT_STRING )
<< FROM_UTF8( KICAD_BUILD_OPTIONS_SIGNATURE() ) << wxT( "\n" )
<< wxT( "Platform: " ) << wxGetOsDescription() << wxT( ", " )
<< info.GetArchName() << wxT( ", " ) << info.GetEndiannessName()
<< wxT( ", " ) << info.GetPortIdName() << wxT( "\n" );
// Just in case someone builds KiCad with the platform native of Boost instead of
// the version included with the KiCad source.
msg_version << wxT( "Boost version: " ) << ( BOOST_VERSION / 100000 ) << wxT( "." )
<< ( BOOST_VERSION / 100 % 1000 ) << wxT( "." )
<< ( BOOST_VERSION % 100 ) << wxT( "\n" );
msg_version << wxT( " USE_WX_GRAPHICS_CONTEXT=" );
#ifdef USE_WX_GRAPHICS_CONTEXT
msg_version << wxT( "ON\n" );
#else
msg_version << wxT( "OFF\n" );
#endif
msg_version << wxT( " USE_WX_OVERLAY=" );
#ifdef USE_WX_OVERLAY
msg_version << wxT( "ON\n" );
#else
msg_version << wxT( "OFF\n" );
#endif
msg_version << wxT( " KICAD_SCRIPTING=" );
#ifdef KICAD_SCRIPTING
msg_version << wxT( "ON\n" );
#else
msg_version << wxT( "OFF\n" );
#endif
msg_version << wxT( " KICAD_SCRIPTING_MODULES=" );
#ifdef KICAD_SCRIPTING_MODULES
msg_version << wxT( "ON\n" );
#else
msg_version << wxT( "OFF\n" );
#endif
msg_version << wxT( " KICAD_SCRIPTING_WXPYTHON=" );
#ifdef KICAD_SCRIPTING_WXPYTHON
msg_version << wxT( "ON\n" );
#else
msg_version << wxT( "OFF\n" );
#endif
msg_version << wxT( " USE_FP_LIB_TABLE=HARD_CODED_ON\n" );
msg_version << wxT( " BUILD_GITHUB_PLUGIN=" );
#ifdef BUILD_GITHUB_PLUGIN
msg_version << wxT( "ON\n" );
#else
msg_version << wxT( "OFF\n" );
#endif
wxTheClipboard->SetData( new wxTextDataObject( msg_version ) );
wxTheClipboard->Close();
wxMessageBox( msg_version, _( "Version Information (copied to the clipboard)" ) );
}
bool EDA_BASE_FRAME::IsWritable( const wxFileName& aFileName )
{
wxString msg;
@ -734,4 +582,3 @@ void EDA_BASE_FRAME::CheckForAutoSaveFile( const wxFileName& aFileName,
wxRemoveFile( autoSaveFileName.GetFullPath() );
}
}

View File

@ -22,12 +22,11 @@
* 51 Franklin Street, Fifth Floor, Boston, MA 02110-1301, USA
*/
#include <dialog_about.h>
#include <aboutinfo.h>
#include <wx/aboutdlg.h>
#include <wx/textctrl.h>
#include <boost/version.hpp>
#include <wx/aboutdlg.h>
#include <wx/arrimpl.cpp>
#include <wx/textctrl.h>
#include <wx/utils.h>
/* Used icons:
* lang_xx_xpm[]; // Icons of various national flags
@ -36,13 +35,15 @@
* icon_kicad_xpm[]; // Icon of the application
*/
#include <bitmaps.h>
#include <wxstruct.h>
#include <build_version.h>
#include <common.h>
#include <pgm_base.h>
#include <build_version.h>
#include <wxstruct.h>
#include "aboutinfo.h"
#include "dialog_about.h"
#include <wx/arrimpl.cpp>
WX_DEFINE_OBJARRAY( Contributors )
// Helper functions:
@ -74,14 +75,14 @@ static void InitKiCadAboutNew( AboutAppInfo& info )
}
/* Set title */
info.SetAppName( wxT( ".: " ) + Pgm().App().GetAppName() + wxT( " :." ) );
info.SetAppName( Pgm().App().GetAppName() );
/* Copyright information */
info.SetCopyright( wxT( "(C) 1992-2015 KiCad Developers Team" ) );
info.SetCopyright( wxT( "(C) 1992-2016 KiCad Developers Team" ) );
/* KiCad build version */
wxString version;
version << wxT( "Version: " ) << GetBuildVersion()
version << GetBuildVersion()
#ifdef DEBUG
<< wxT( ", debug" )
#else
@ -93,16 +94,13 @@ static void InitKiCadAboutNew( AboutAppInfo& info )
/* wxWidgets version */
wxString libVersion;
libVersion << wxT( "wxWidgets " )
<< wxMAJOR_VERSION << wxT( "." )
<< wxMINOR_VERSION << wxT( "." )
<< wxRELEASE_NUMBER
libVersion << wxGetLibraryVersionInfo().GetVersionString();
/* Unicode or ANSI version */
#if wxUSE_UNICODE
<< wxT( " Unicode " );
libVersion << wxT( " Unicode " );
#else
<< wxT( " ANSI " );
libVersion << wxT( " ANSI " );
#endif
// Just in case someone builds KiCad with the platform native of Boost instead of

View File

@ -22,7 +22,36 @@
* 51 Franklin Street, Fifth Floor, Boston, MA 02110-1301, USA
*/
#include <dialog_about.h>
#include <config.h>
// kicad_curl.h must be included before wx headers, to avoid
// conflicts for some defines, at least on Windows
#ifdef BUILD_GITHUB_PLUGIN
#include <curl/curlver.h>
#include <kicad_curl/kicad_curl.h>
#endif
#include <boost/version.hpp>
#include <wx/clipbrd.h>
#include <wx/msgdlg.h>
/* Pixel information of icons in XPM format.
* All KiCad icons are linked into shared library 'libbitmaps.a'.
* Icons:
* preference_xpm[]; // Icon for 'Developers' tab
* editor_xpm[]; // Icon for 'Doc Writers' tab
* palette_xpm[]; // Icon for 'Artists' tab
* language_xpm[]; // Icon for 'Translators' tab
* right_xpm[]; // Right arrow icon for list items
* info_xpm[]; // Bulb for description tab
* tools_xpm[]; // Sheet of paper icon for license info tab
*/
#include <bitmaps.h>
#include <build_version.h>
#include "dialog_about.h"
///////////////////////////////////////////////////////////////////////////////
/// Class dialog_about methods
@ -43,7 +72,7 @@ dialog_about::dialog_about(wxWindow *parent, AboutAppInfo& appInfo)
m_staticTextAppTitle->SetLabel( info.GetAppName() );
m_staticTextCopyright->SetLabel( info.GetCopyright() );
m_staticTextBuildVersion->SetLabel( info.GetBuildVersion() );
m_staticTextBuildVersion->SetLabel( "Version: " + info.GetBuildVersion() );
m_staticTextLibVersion->SetLabel( info.GetLibVersion() );
DeleteNotebooks();
@ -53,6 +82,8 @@ dialog_about::dialog_about(wxWindow *parent, AboutAppInfo& appInfo)
m_auiNotebook->Update();
SetFocus();
Centre();
Connect( wxID_COPY, wxEVT_COMMAND_BUTTON_CLICKED, wxCommandEventHandler( dialog_about::OnCopyVersionInfo ) );
}
@ -397,3 +428,112 @@ void dialog_about::OnHtmlLinkClicked( wxHtmlLinkEvent& event )
{
::wxLaunchDefaultBrowser( event.GetLinkInfo().GetHref() );
}
void dialog_about::OnCopyVersionInfo( wxCommandEvent& event )
{
if( !wxTheClipboard->Open() )
{
wxMessageBox( _( "Could not open clipboard to write version information." ),
_( "Clipboard Error" ), wxOK | wxICON_EXCLAMATION, this );
return;
}
wxPlatformInfo platform;
// DO NOT translate information in the msg_version string
wxString msg_version;
msg_version << "Application: " << info.GetAppName() << "\n";
msg_version << "Version: " << info.GetBuildVersion() << "\n";
msg_version << "Libraries: " << wxGetLibraryVersionInfo().GetVersionString() << "\n";
#ifdef BUILD_GITHUB_PLUGIN
msg_version << " " << KICAD_CURL::GetVersion() << "\n";
#endif
msg_version << "Platform: " << wxGetOsDescription() << ", "
<< platform.GetArchName() << ", "
<< platform.GetEndiannessName() << ", "
<< platform.GetPortIdName() << "\n";
msg_version << "- Build Info -\n";
msg_version << "wxWidgets: " << wxVERSION_NUM_DOT_STRING << " (";
msg_version << __WX_BO_UNICODE __WX_BO_STL __WX_BO_WXWIN_COMPAT_2_8 ")\n";
msg_version << "Boost: " << ( BOOST_VERSION / 100000 ) << wxT( "." )
<< ( BOOST_VERSION / 100 % 1000 ) << wxT( "." )
<< ( BOOST_VERSION % 100 ) << wxT( "\n" );
#ifdef BUILD_GITHUB_PLUGIN
msg_version << "Curl: " << LIBCURL_VERSION << "\n";
#endif
msg_version << "KiCad - Compiler: ";
#if defined(__clang__)
msg_version << "Clang " << __clang_major__ << "." << __clang_minor__ << "." << __clang_patchlevel__;
#elif defined(__GNUG__)
msg_version << "GCC " << __GNUC__ << "." << __GNUC_MINOR__ << "." << __GNUC_PATCHLEVEL__;
#elif defined(_MSC_VER)
msg_version << "Visual C++ " << _MSC_VER;
#elif defined(__INTEL_COMPILER)
msg_version << "Intel C++ " << __INTEL_COMPILER;
#else
msg_version << "Other Compiler ";
#endif
#if defined(__GXX_ABI_VERSION)
msg_version << " with C++ ABI " << __GXX_ABI_VERSION << "\n";
#else
msg_version << " without C++ ABI\n";
#endif
msg_version << " Settings: ";
#define ON "ON\n"
#define OFF "OFF\n"
msg_version << "USE_WX_GRAPHICS_CONTEXT=";
#ifdef USE_WX_GRAPHICS_CONTEXT
msg_version << ON;
#else
msg_version << OFF;
#endif
msg_version << " USE_WX_OVERLAY=";
#ifdef USE_WX_OVERLAY
msg_version << ON;
#else
msg_version << OFF;
#endif
msg_version << " KICAD_SCRIPTING=";
#ifdef KICAD_SCRIPTING
msg_version << ON;
#else
msg_version << OFF;
#endif
msg_version << " KICAD_SCRIPTING_MODULES=";
#ifdef KICAD_SCRIPTING_MODULES
msg_version << ON;
#else
msg_version << OFF;
#endif
msg_version << " KICAD_SCRIPTING_WXPYTHON=";
#ifdef KICAD_SCRIPTING_WXPYTHON
msg_version << ON;
#else
msg_version << OFF;
#endif
msg_version << " USE_FP_LIB_TABLE=HARD_CODED_ON\n";
msg_version << " BUILD_GITHUB_PLUGIN=";
#ifdef BUILD_GITHUB_PLUGIN
msg_version << ON;
#else
msg_version << OFF;
#endif
wxTheClipboard->SetData( new wxTextDataObject( msg_version ) );
wxTheClipboard->Close();
copyVersionInfo->SetLabel( _( "Copied..." ) );
}

View File

@ -30,21 +30,8 @@
#include <wx/stattext.h>
#include <wx/hyperlink.h>
#include <aboutinfo.h>
#include <dialog_about_base.h>
/* Pixel information of icons in XPM format.
* All KiCad icons are linked into shared library 'libbitmaps.a'.
* Icons:
* preference_xpm[]; // Icon for 'Developers' tab
* editor_xpm[]; // Icon for 'Doc Writers' tab
* palette_xpm[]; // Icon for 'Artists' tab
* language_xpm[]; // Icon for 'Translators' tab
* right_xpm[]; // Right arrow icon for list items
* info_xpm[]; // Bulb for description tab
* tools_xpm[]; // Sheet of paper icon for license info tab
*/
#include <bitmaps.h>
#include "aboutinfo.h"
#include "dialog_about_base.h"
/**
* About dialog to show application specific information.
@ -74,6 +61,7 @@ private:
virtual void OnClose( wxCloseEvent& event );
virtual void OnOkClick( wxCommandEvent& event );
virtual void OnHtmlLinkClicked( wxHtmlLinkEvent& event );
virtual void OnCopyVersionInfo( wxCommandEvent &event );
// Notebook pages
wxFlexGridSizer* CreateFlexGridSizer();

View File

@ -1,5 +1,5 @@
///////////////////////////////////////////////////////////////////////////
// C++ code generated with wxFormBuilder (version Jun 5 2014)
// C++ code generated with wxFormBuilder (version Aug 23 2015)
// http://www.wxformbuilder.org/
//
// PLEASE DO "NOT" EDIT THIS FILE!
@ -44,10 +44,10 @@ dialog_about_base::dialog_about_base( wxWindow* parent, wxWindowID id, const wxS
m_staticTextLibVersion = new wxStaticText( this, wxID_ANY, _("Lib Version Info"), wxDefaultPosition, wxDefaultSize, wxALIGN_CENTRE );
m_staticTextLibVersion->Wrap( -1 );
b_apptitleSizer->Add( m_staticTextLibVersion, 0, wxALIGN_CENTER|wxBOTTOM|wxLEFT|wxRIGHT, 5 );
b_apptitleSizer->Add( m_staticTextLibVersion, 0, wxALIGN_CENTER|wxLEFT|wxRIGHT|wxTOP, 5 );
bSizer3->Add( b_apptitleSizer, 10, wxEXPAND, 5 );
bSizer3->Add( b_apptitleSizer, 10, wxALL|wxEXPAND, 5 );
bSizer3->Add( 0, 0, 2, wxEXPAND, 5 );
@ -55,22 +55,27 @@ dialog_about_base::dialog_about_base( wxWindow* parent, wxWindowID id, const wxS
bSizer1->Add( bSizer3, 0, wxEXPAND, 5 );
wxStaticLine* m_staticline1;
m_staticline1 = new wxStaticLine( this, wxID_ANY, wxDefaultPosition, wxDefaultSize, wxLI_HORIZONTAL );
bSizer1->Add( m_staticline1, 0, wxEXPAND | wxALL, 5 );
m_auiNotebook = new wxAuiNotebook( this, wxID_ANY, wxDefaultPosition, wxDefaultSize, wxAUI_NB_SCROLL_BUTTONS|wxAUI_NB_TAB_FIXED_WIDTH );
m_auiNotebook->SetMinSize( wxSize( 750,350 ) );
bSizer1->Add( m_auiNotebook, 2, wxEXPAND | wxALL, 5 );
bSizer1->Add( m_auiNotebook, 2, wxALL|wxEXPAND, 5 );
m_sdbSizer = new wxStdDialogButtonSizer();
m_sdbSizerOK = new wxButton( this, wxID_OK );
m_sdbSizer->AddButton( m_sdbSizerOK );
m_sdbSizer->Realize();
wxBoxSizer* bSizer4;
bSizer4 = new wxBoxSizer( wxHORIZONTAL );
bSizer1->Add( m_sdbSizer, 0, wxALL|wxALIGN_CENTER_HORIZONTAL, 5 );
bSizer4->Add( 0, 0, 1, wxEXPAND, 5 );
copyVersionInfo = new wxButton( this, wxID_COPY, _("Copy Version Info"), wxDefaultPosition, wxDefaultSize, 0 );
bSizer4->Add( copyVersionInfo, 0, wxALL, 5 );
ok = new wxButton( this, wxID_OK, _("OK"), wxDefaultPosition, wxDefaultSize, 0 );
ok->SetDefault();
bSizer4->Add( ok, 0, wxALL, 5 );
bSizer1->Add( bSizer4, 0, wxBOTTOM|wxEXPAND|wxLEFT|wxRIGHT, 5 );
this->SetSizer( bSizer1 );

View File

@ -44,10 +44,10 @@
<property name="minimum_size">-1,-1</property>
<property name="name">dialog_about_base</property>
<property name="pos"></property>
<property name="size">750,437</property>
<property name="style">wxDEFAULT_DIALOG_STYLE|wxRESIZE_BORDER|wxSTAY_ON_TOP</property>
<property name="size">750,471</property>
<property name="style">wxDEFAULT_DIALOG_STYLE|wxRESIZE_BORDER</property>
<property name="subclass"></property>
<property name="title">About...</property>
<property name="title">About</property>
<property name="tooltip"></property>
<property name="window_extra_style"></property>
<property name="window_name"></property>
@ -93,11 +93,11 @@
<property name="name">bSizer1</property>
<property name="orient">wxVERTICAL</property>
<property name="permission">none</property>
<object class="sizeritem" expanded="0">
<object class="sizeritem" expanded="1">
<property name="border">5</property>
<property name="flag">wxEXPAND</property>
<property name="proportion">0</property>
<object class="wxBoxSizer" expanded="0">
<object class="wxBoxSizer" expanded="1">
<property name="minimum_size"></property>
<property name="name">bSizer3</property>
<property name="orient">wxHORIZONTAL</property>
@ -193,11 +193,11 @@
<event name="OnUpdateUI"></event>
</object>
</object>
<object class="sizeritem" expanded="0">
<object class="sizeritem" expanded="1">
<property name="border">5</property>
<property name="flag">wxEXPAND</property>
<property name="flag">wxALL|wxEXPAND</property>
<property name="proportion">10</property>
<object class="wxBoxSizer" expanded="0">
<object class="wxBoxSizer" expanded="1">
<property name="minimum_size"></property>
<property name="name">b_apptitleSizer</property>
<property name="orient">wxVERTICAL</property>
@ -453,7 +453,7 @@
</object>
<object class="sizeritem" expanded="0">
<property name="border">5</property>
<property name="flag">wxALIGN_CENTER|wxBOTTOM|wxLEFT|wxRIGHT</property>
<property name="flag">wxALIGN_CENTER|wxLEFT|wxRIGHT|wxTOP</property>
<property name="proportion">0</property>
<object class="wxStaticText" expanded="0">
<property name="BottomDockable">1</property>
@ -550,88 +550,7 @@
</object>
<object class="sizeritem" expanded="0">
<property name="border">5</property>
<property name="flag">wxEXPAND | wxALL</property>
<property name="proportion">0</property>
<object class="wxStaticLine" expanded="0">
<property name="BottomDockable">1</property>
<property name="LeftDockable">1</property>
<property name="RightDockable">1</property>
<property name="TopDockable">1</property>
<property name="aui_layer"></property>
<property name="aui_name"></property>
<property name="aui_position"></property>
<property name="aui_row"></property>
<property name="best_size"></property>
<property name="bg"></property>
<property name="caption"></property>
<property name="caption_visible">1</property>
<property name="center_pane">0</property>
<property name="close_button">1</property>
<property name="context_help"></property>
<property name="context_menu">1</property>
<property name="default_pane">0</property>
<property name="dock">Dock</property>
<property name="dock_fixed">0</property>
<property name="docking">Left</property>
<property name="enabled">1</property>
<property name="fg"></property>
<property name="floatable">1</property>
<property name="font"></property>
<property name="gripper">0</property>
<property name="hidden">0</property>
<property name="id">wxID_ANY</property>
<property name="max_size"></property>
<property name="maximize_button">0</property>
<property name="maximum_size"></property>
<property name="min_size"></property>
<property name="minimize_button">0</property>
<property name="minimum_size"></property>
<property name="moveable">1</property>
<property name="name">m_staticline1</property>
<property name="pane_border">1</property>
<property name="pane_position"></property>
<property name="pane_size"></property>
<property name="permission">none</property>
<property name="pin_button">1</property>
<property name="pos"></property>
<property name="resize">Resizable</property>
<property name="show">1</property>
<property name="size"></property>
<property name="style">wxLI_HORIZONTAL</property>
<property name="subclass"></property>
<property name="toolbar_pane">0</property>
<property name="tooltip"></property>
<property name="window_extra_style"></property>
<property name="window_name"></property>
<property name="window_style"></property>
<event name="OnChar"></event>
<event name="OnEnterWindow"></event>
<event name="OnEraseBackground"></event>
<event name="OnKeyDown"></event>
<event name="OnKeyUp"></event>
<event name="OnKillFocus"></event>
<event name="OnLeaveWindow"></event>
<event name="OnLeftDClick"></event>
<event name="OnLeftDown"></event>
<event name="OnLeftUp"></event>
<event name="OnMiddleDClick"></event>
<event name="OnMiddleDown"></event>
<event name="OnMiddleUp"></event>
<event name="OnMotion"></event>
<event name="OnMouseEvents"></event>
<event name="OnMouseWheel"></event>
<event name="OnPaint"></event>
<event name="OnRightDClick"></event>
<event name="OnRightDown"></event>
<event name="OnRightUp"></event>
<event name="OnSetFocus"></event>
<event name="OnSize"></event>
<event name="OnUpdateUI"></event>
</object>
</object>
<object class="sizeritem" expanded="0">
<property name="border">5</property>
<property name="flag">wxEXPAND | wxALL</property>
<property name="flag">wxALL|wxEXPAND</property>
<property name="proportion">2</property>
<object class="wxAuiNotebook" expanded="0">
<property name="BottomDockable">1</property>
@ -722,28 +641,199 @@
</object>
<object class="sizeritem" expanded="1">
<property name="border">5</property>
<property name="flag">wxALL|wxALIGN_CENTER_HORIZONTAL</property>
<property name="flag">wxBOTTOM|wxEXPAND|wxLEFT|wxRIGHT</property>
<property name="proportion">0</property>
<object class="wxStdDialogButtonSizer" expanded="1">
<property name="Apply">0</property>
<property name="Cancel">0</property>
<property name="ContextHelp">0</property>
<property name="Help">0</property>
<property name="No">0</property>
<property name="OK">1</property>
<property name="Save">0</property>
<property name="Yes">0</property>
<object class="wxBoxSizer" expanded="1">
<property name="minimum_size"></property>
<property name="name">m_sdbSizer</property>
<property name="permission">protected</property>
<event name="OnApplyButtonClick"></event>
<event name="OnCancelButtonClick"></event>
<event name="OnContextHelpButtonClick"></event>
<event name="OnHelpButtonClick"></event>
<event name="OnNoButtonClick"></event>
<event name="OnOKButtonClick"></event>
<event name="OnSaveButtonClick"></event>
<event name="OnYesButtonClick"></event>
<property name="name">bSizer4</property>
<property name="orient">wxHORIZONTAL</property>
<property name="permission">none</property>
<object class="sizeritem" expanded="1">
<property name="border">5</property>
<property name="flag">wxEXPAND</property>
<property name="proportion">1</property>
<object class="spacer" expanded="1">
<property name="height">0</property>
<property name="permission">protected</property>
<property name="width">0</property>
</object>
</object>
<object class="sizeritem" expanded="0">
<property name="border">5</property>
<property name="flag">wxALL</property>
<property name="proportion">0</property>
<object class="wxButton" expanded="0">
<property name="BottomDockable">1</property>
<property name="LeftDockable">1</property>
<property name="RightDockable">1</property>
<property name="TopDockable">1</property>
<property name="aui_layer"></property>
<property name="aui_name"></property>
<property name="aui_position"></property>
<property name="aui_row"></property>
<property name="best_size"></property>
<property name="bg"></property>
<property name="caption"></property>
<property name="caption_visible">1</property>
<property name="center_pane">0</property>
<property name="close_button">1</property>
<property name="context_help"></property>
<property name="context_menu">1</property>
<property name="default">0</property>
<property name="default_pane">0</property>
<property name="dock">Dock</property>
<property name="dock_fixed">0</property>
<property name="docking">Left</property>
<property name="enabled">1</property>
<property name="fg"></property>
<property name="floatable">1</property>
<property name="font"></property>
<property name="gripper">0</property>
<property name="hidden">0</property>
<property name="id">wxID_COPY</property>
<property name="label">Copy Version Info</property>
<property name="max_size"></property>
<property name="maximize_button">0</property>
<property name="maximum_size"></property>
<property name="min_size"></property>
<property name="minimize_button">0</property>
<property name="minimum_size"></property>
<property name="moveable">1</property>
<property name="name">copyVersionInfo</property>
<property name="pane_border">1</property>
<property name="pane_position"></property>
<property name="pane_size"></property>
<property name="permission">protected</property>
<property name="pin_button">1</property>
<property name="pos"></property>
<property name="resize">Resizable</property>
<property name="show">1</property>
<property name="size"></property>
<property name="style"></property>
<property name="subclass"></property>
<property name="toolbar_pane">0</property>
<property name="tooltip"></property>
<property name="validator_data_type"></property>
<property name="validator_style">wxFILTER_NONE</property>
<property name="validator_type">wxDefaultValidator</property>
<property name="validator_variable"></property>
<property name="window_extra_style"></property>
<property name="window_name"></property>
<property name="window_style"></property>
<event name="OnButtonClick"></event>
<event name="OnChar"></event>
<event name="OnEnterWindow"></event>
<event name="OnEraseBackground"></event>
<event name="OnKeyDown"></event>
<event name="OnKeyUp"></event>
<event name="OnKillFocus"></event>
<event name="OnLeaveWindow"></event>
<event name="OnLeftDClick"></event>
<event name="OnLeftDown"></event>
<event name="OnLeftUp"></event>
<event name="OnMiddleDClick"></event>
<event name="OnMiddleDown"></event>
<event name="OnMiddleUp"></event>
<event name="OnMotion"></event>
<event name="OnMouseEvents"></event>
<event name="OnMouseWheel"></event>
<event name="OnPaint"></event>
<event name="OnRightDClick"></event>
<event name="OnRightDown"></event>
<event name="OnRightUp"></event>
<event name="OnSetFocus"></event>
<event name="OnSize"></event>
<event name="OnUpdateUI"></event>
</object>
</object>
<object class="sizeritem" expanded="0">
<property name="border">5</property>
<property name="flag">wxALL</property>
<property name="proportion">0</property>
<object class="wxButton" expanded="0">
<property name="BottomDockable">1</property>
<property name="LeftDockable">1</property>
<property name="RightDockable">1</property>
<property name="TopDockable">1</property>
<property name="aui_layer"></property>
<property name="aui_name"></property>
<property name="aui_position"></property>
<property name="aui_row"></property>
<property name="best_size"></property>
<property name="bg"></property>
<property name="caption"></property>
<property name="caption_visible">1</property>
<property name="center_pane">0</property>
<property name="close_button">1</property>
<property name="context_help"></property>
<property name="context_menu">1</property>
<property name="default">1</property>
<property name="default_pane">0</property>
<property name="dock">Dock</property>
<property name="dock_fixed">0</property>
<property name="docking">Left</property>
<property name="enabled">1</property>
<property name="fg"></property>
<property name="floatable">1</property>
<property name="font"></property>
<property name="gripper">0</property>
<property name="hidden">0</property>
<property name="id">wxID_OK</property>
<property name="label">OK</property>
<property name="max_size"></property>
<property name="maximize_button">0</property>
<property name="maximum_size"></property>
<property name="min_size"></property>
<property name="minimize_button">0</property>
<property name="minimum_size"></property>
<property name="moveable">1</property>
<property name="name">ok</property>
<property name="pane_border">1</property>
<property name="pane_position"></property>
<property name="pane_size"></property>
<property name="permission">protected</property>
<property name="pin_button">1</property>
<property name="pos"></property>
<property name="resize">Resizable</property>
<property name="show">1</property>
<property name="size"></property>
<property name="style"></property>
<property name="subclass"></property>
<property name="toolbar_pane">0</property>
<property name="tooltip"></property>
<property name="validator_data_type"></property>
<property name="validator_style">wxFILTER_NONE</property>
<property name="validator_type">wxDefaultValidator</property>
<property name="validator_variable"></property>
<property name="window_extra_style"></property>
<property name="window_name"></property>
<property name="window_style"></property>
<event name="OnButtonClick"></event>
<event name="OnChar"></event>
<event name="OnEnterWindow"></event>
<event name="OnEraseBackground"></event>
<event name="OnKeyDown"></event>
<event name="OnKeyUp"></event>
<event name="OnKillFocus"></event>
<event name="OnLeaveWindow"></event>
<event name="OnLeftDClick"></event>
<event name="OnLeftDown"></event>
<event name="OnLeftUp"></event>
<event name="OnMiddleDClick"></event>
<event name="OnMiddleDown"></event>
<event name="OnMiddleUp"></event>
<event name="OnMotion"></event>
<event name="OnMouseEvents"></event>
<event name="OnMouseWheel"></event>
<event name="OnPaint"></event>
<event name="OnRightDClick"></event>
<event name="OnRightDown"></event>
<event name="OnRightUp"></event>
<event name="OnSetFocus"></event>
<event name="OnSize"></event>
<event name="OnUpdateUI"></event>
</object>
</object>
</object>
</object>
</object>

View File

@ -1,5 +1,5 @@
///////////////////////////////////////////////////////////////////////////
// C++ code generated with wxFormBuilder (version Jun 5 2014)
// C++ code generated with wxFormBuilder (version Aug 23 2015)
// http://www.wxformbuilder.org/
//
// PLEASE DO "NOT" EDIT THIS FILE!
@ -22,7 +22,6 @@
#include <wx/string.h>
#include <wx/stattext.h>
#include <wx/sizer.h>
#include <wx/statline.h>
#include <wx/aui/auibook.h>
#include <wx/button.h>
#include <wx/dialog.h>
@ -43,12 +42,12 @@ class dialog_about_base : public wxDialog
wxStaticText* m_staticTextBuildVersion;
wxStaticText* m_staticTextLibVersion;
wxAuiNotebook* m_auiNotebook;
wxStdDialogButtonSizer* m_sdbSizer;
wxButton* m_sdbSizerOK;
wxButton* copyVersionInfo;
wxButton* ok;
public:
dialog_about_base( wxWindow* parent, wxWindowID id = wxID_ANY, const wxString& title = _("About..."), const wxPoint& pos = wxDefaultPosition, const wxSize& size = wxSize( 750,437 ), long style = wxDEFAULT_DIALOG_STYLE|wxRESIZE_BORDER|wxSTAY_ON_TOP );
dialog_about_base( wxWindow* parent, wxWindowID id = wxID_ANY, const wxString& title = _("About"), const wxPoint& pos = wxDefaultPosition, const wxSize& size = wxSize( 750,471 ), long style = wxDEFAULT_DIALOG_STYLE|wxRESIZE_BORDER );
~dialog_about_base();
};

View File

@ -23,7 +23,7 @@
* 51 Franklin Street, Fifth Floor, Boston, MA 02110-1301, USA
*/
// kicad_curl.h must be included before xw headers, to avoid
// kicad_curl.h must be included before wx headers, to avoid
// conflicts for some defines, at least on Windows
#include <kicad_curl/kicad_curl.h>

View File

@ -26,16 +26,15 @@
* @file cvpcb/menubar.cpp
* @brief (Re)Create the menubar for CvPcb
*/
#include <fctsys.h>
#include <pgm_base.h>
#include <kiface_i.h>
#include <menus_helpers.h>
#include <cvpcb.h>
#include <cvpcb_mainframe.h>
#include <cvpcb_id.h>
#include <common_help_msg.h>
#include <kiface_i.h>
#include <menus_helpers.h>
#include <pgm_base.h>
#include "cvpcb.h"
#include "cvpcb_id.h"
#include "cvpcb_mainframe.h"
/**
@ -111,9 +110,6 @@ void CVPCB_MAINFRAME::ReCreateMenuBar()
// Menu Help:
wxMenu* helpMenu = new wxMenu;
// Version info
AddHelpVersionInfoMenuEntry( helpMenu );
// Manual Contents
AddMenuItem( helpMenu, wxID_HELP, _( "CvPcb &Manual" ),
_( "Open CvPcb Manual" ),

View File

@ -28,18 +28,16 @@
* @brief (Re)Create the main menubar for the schematic frame
*/
#include <fctsys.h>
#include <kiface_i.h>
#include <pgm_base.h>
#include <schframe.h>
#include <general.h>
#include <eeschema_id.h>
#include <hotkeys.h>
#include <menus_helpers.h>
#include <pgm_base.h>
#include <help_common_strings.h>
#include "eeschema_id.h"
#include "general.h"
#include "help_common_strings.h"
#include "hotkeys.h"
#include "schframe.h"
void SCH_EDIT_FRAME::ReCreateMenuBar()
{
@ -497,9 +495,6 @@ void SCH_EDIT_FRAME::ReCreateMenuBar()
// Help Menu:
wxMenu* helpMenu = new wxMenu;
// Version info
AddHelpVersionInfoMenuEntry( helpMenu );
AddMenuItem( helpMenu,
wxID_HELP,
_( "Eeschema &Manual" ),

View File

@ -27,16 +27,16 @@
* @file eeschema/menubar_libedit.cpp
* @brief (Re)Create the main menubar for the component editor frame (LibEdit)
*/
#include <fctsys.h>
#include <menus_helpers.h>
#include <pgm_base.h>
#include <general.h>
#include <libeditframe.h>
#include <eeschema_id.h>
#include <hotkeys.h>
#include "eeschema_id.h"
#include "general.h"
#include "help_common_strings.h"
#include "hotkeys.h"
#include "libeditframe.h"
#include <help_common_strings.h>
#include <menus_helpers.h>
/**
* @brief (Re)Create the menubar for the component editor frame
@ -247,9 +247,6 @@ void LIB_EDIT_FRAME::ReCreateMenuBar()
// Menu Help:
wxMenu* helpMenu = new wxMenu;
// Version info
AddHelpVersionInfoMenuEntry( helpMenu );
// Contents
AddMenuItem( helpMenu,
wxID_HELP,

View File

@ -28,17 +28,17 @@
* @brief Build the toolbars for the library browser.
*/
#include <fctsys.h>
#include <macros.h>
#include <eeschema_id.h>
#include <general.h>
#include <hotkeys.h>
#include <class_library.h>
#include <viewlib_frame.h>
#include <dialog_helpers.h>
#include <macros.h>
#include <menus_helpers.h>
#include <help_common_strings.h>
#include "class_library.h"
#include "eeschema_id.h"
#include "general.h"
#include "help_common_strings.h"
#include "hotkeys.h"
#include "viewlib_frame.h"
void LIB_VIEW_FRAME::ReCreateHToolbar()
@ -242,9 +242,6 @@ void LIB_VIEW_FRAME::ReCreateMenuBar( void )
// Menu Help:
wxMenu* helpMenu = new wxMenu;
// Version info
AddHelpVersionInfoMenuEntry( helpMenu );
// Contents
AddMenuItem( helpMenu, wxID_HELP,
_( "Eeschema &Manual" ),

View File

@ -27,15 +27,16 @@
* @file gerbview/menubar.cpp
* @brief (Re)Create the main menubar for GerbView
*/
#include <fctsys.h>
#include <pgm_base.h>
#include <kiface_i.h>
#include <gerbview.h>
#include <gerbview_frame.h>
#include <gerbview_id.h>
#include <hotkeys.h>
#include <menus_helpers.h>
#include <pgm_base.h>
#include "gerbview.h"
#include "gerbview_frame.h"
#include "gerbview_id.h"
#include "hotkeys.h"
void GERBVIEW_FRAME::ReCreateMenuBar()
@ -215,9 +216,6 @@ void GERBVIEW_FRAME::ReCreateMenuBar()
// Menu Help
wxMenu* helpMenu = new wxMenu;
// Version info
AddHelpVersionInfoMenuEntry( helpMenu );
// Contents
AddMenuItem( helpMenu,
wxID_HELP,

View File

@ -118,8 +118,6 @@ enum main_id
ID_OPT_TOOLBAR,
ID_AUX_TOOLBAR,
ID_HELP_COPY_VERSION_STRING,
ID_EDIT,
ID_NO_TOOL_SELECTED,
ID_SEL_BG_COLOR,

View File

@ -219,21 +219,8 @@ public:
void GetKicadAbout( wxCommandEvent& event );
/**
* Function CopyVersionInfoToClipboard
* copies the version information to the clipboard for bug reporting purposes.
*/
void CopyVersionInfoToClipboard( wxCommandEvent& event );
void PrintMsg( const wxString& text );
/**
* Append the copy version information to clipboard help menu entry to \a aMenu.
*
* @param aMenu - The menu to append.
*/
void AddHelpVersionInfoMenuEntry( wxMenu* aMenu );
/**
* Function LoadSettings
* loads common frame parameters from a configuration file.

View File

@ -402,9 +402,6 @@ void KICAD_MANAGER_FRAME::ReCreateMenuBar()
// Menu Help:
wxMenu* helpMenu = new wxMenu;
// Version info
AddHelpVersionInfoMenuEntry( helpMenu );
// Contents
AddMenuItem( helpMenu, wxID_HELP,
_( "KiCad &Manual" ),

View File

@ -1,8 +1,3 @@
/**
* @file pagelayout_editor/menubar.cpp
* @brief (Re)Create the main menubar for Pl_Editor
*/
/*
* This program source code file is part of KiCad, a free EDA CAD application.
*
@ -27,14 +22,19 @@
* 51 Franklin Street, Fifth Floor, Boston, MA 02110-1301, USA
*/
#include <fctsys.h>
/**
* @file pagelayout_editor/menubar.cpp
* @brief (Re)Create the main menubar for Pl_Editor
*/
#include <pgm_base.h>
#include <kiface_i.h>
#include <pl_editor_frame.h>
#include <pl_editor_id.h>
#include <hotkeys.h>
#include <menus_helpers.h>
#include <pgm_base.h>
#include "hotkeys.h"
#include "pl_editor_frame.h"
#include "pl_editor_id.h"
void PL_EDITOR_FRAME::ReCreateMenuBar()
@ -142,9 +142,6 @@ void PL_EDITOR_FRAME::ReCreateMenuBar()
// Menu Help
wxMenu* helpMenu = new wxMenu;
// Version info
AddHelpVersionInfoMenuEntry( helpMenu );
// Contents
AddMenuItem( helpMenu,
wxID_HELP,

View File

@ -29,17 +29,17 @@
* @file pcbnew/menubar_modedit.cpp
* @brief (Re)Create the main menubar for the module editor
*/
#include <fctsys.h>
#include <pgm_base.h>
#include <pcbnew.h>
#include <wxPcbStruct.h>
#include <module_editor_frame.h>
#include <menus_helpers.h>
#include <pgm_base.h>
#include <wxPcbStruct.h>
#include <pcbnew_id.h>
#include <hotkeys.h>
#include <help_common_strings.h>
#include "help_common_strings.h"
#include "hotkeys.h"
#include "module_editor_frame.h"
#include "pcbnew.h"
#include "pcbnew_id.h"
void FOOTPRINT_EDIT_FRAME::ReCreateMenuBar()
@ -333,9 +333,6 @@ void FOOTPRINT_EDIT_FRAME::ReCreateMenuBar()
//----- Help menu --------------------
wxMenu* helpMenu = new wxMenu;
// Version info
AddHelpVersionInfoMenuEntry( helpMenu );
// Contents
AddMenuItem( helpMenu, wxID_HELP,
_( "Pcbnew &Manual" ),

View File

@ -28,16 +28,18 @@
* @file menubar_pcbframe.cpp
* Pcbnew editor menu bar
*/
#include <fctsys.h>
#include <pgm_base.h>
#include <kiface_i.h>
#include <pcbnew.h>
#include <wxPcbStruct.h>
#include <hotkeys.h>
#include <pcbnew_id.h>
#include <help_common_strings.h>
#include <menus_helpers.h>
#include <kiface_i.h>
#include <pgm_base.h>
#include <wxPcbStruct.h>
#include "help_common_strings.h"
#include "hotkeys.h"
#include "pcbnew.h"
#include "pcbnew_id.h"
void PCB_EDIT_FRAME::ReCreateMenuBar()
{
@ -652,8 +654,6 @@ void PCB_EDIT_FRAME::ReCreateMenuBar()
wxMenu* helpMenu = new wxMenu;
AddHelpVersionInfoMenuEntry( helpMenu );
AddMenuItem( helpMenu, wxID_HELP,
_( "Pcbnew &Manual" ),
_( "Open the Pcbnew Manual" ),

View File

@ -29,17 +29,17 @@
* @brief Build the toolbars for the library browser.
*/
#include <fctsys.h>
#include <macros.h>
#include <pcbnew_id.h>
#include <pcbnew.h>
#include <wxPcbStruct.h>
#include <menus_helpers.h>
#include <hotkeys.h>
#include <dialog_helpers.h>
#include <modview_frame.h>
#include <help_common_strings.h>
#include <macros.h>
#include <menus_helpers.h>
#include <wxPcbStruct.h>
#include "help_common_strings.h"
#include "hotkeys.h"
#include "modview_frame.h"
#include "pcbnew.h"
#include "pcbnew_id.h"
void FOOTPRINT_VIEWER_FRAME::ReCreateHToolbar()
@ -181,9 +181,6 @@ void FOOTPRINT_VIEWER_FRAME::ReCreateMenuBar( void )
// Menu Help:
wxMenu* helpMenu = new wxMenu;
// Version info
AddHelpVersionInfoMenuEntry( helpMenu );
// Contents
AddMenuItem( helpMenu, wxID_HELP,
_( "Pcbnew &Manual" ),