mirror of https://github.com/PCSX2/pcsx2.git
Turn an ugly snapshot button into a pretty one!
git-svn-id: http://pcsx2.googlecode.com/svn/trunk@2254 96395faa-99c1-11dd-bbfe-3dabce05a288
This commit is contained in:
parent
03449cf682
commit
474a404dfd
|
@ -108,7 +108,7 @@ void wxDialogWithHelpers::AddOkCancel( wxSizer &sizer, bool hasApply )
|
||||||
{
|
{
|
||||||
SetExtraStyle( wxDIALOG_EX_CONTEXTHELP );
|
SetExtraStyle( wxDIALOG_EX_CONTEXTHELP );
|
||||||
#ifndef __WXMSW__
|
#ifndef __WXMSW__
|
||||||
m_extraButtonSizer += new wxContextHelpButton(this) | StdButton();
|
m_extraButtonSizer += new wxContextHelpButton(this);
|
||||||
#endif
|
#endif
|
||||||
}
|
}
|
||||||
|
|
||||||
|
|
|
@ -405,7 +405,13 @@
|
||||||
<Option weight="0" />
|
<Option weight="0" />
|
||||||
<Option compiler="gcc" use="1" buildCommand="$(SvnRootDir)/tools/bin2app.sh $(SvnRootDir) $file" />
|
<Option compiler="gcc" use="1" buildCommand="$(SvnRootDir)/tools/bin2app.sh $(SvnRootDir) $file" />
|
||||||
</Unit>
|
</Unit>
|
||||||
<Unit filename="../gui/Resources/ConfigIcon_Cpu.h" />
|
<Unit filename="../gui/Resources/ButtonIcon_Camera.h" />
|
||||||
|
<Unit filename="../gui/Resources/ButtonIcon_Camera.png">
|
||||||
|
<Option compile="1" />
|
||||||
|
<Option weight="0" />
|
||||||
|
<Option compiler="gcc" use="1" buildCommand="$(SvnRootDir)/tools/bin2app.sh $(SvnRootDir) $file" />
|
||||||
|
</Unit>
|
||||||
|
<Unit filename="../gui/Resources/ConfigIcon_Cpu.h" />
|
||||||
<Unit filename="../gui/Resources/ConfigIcon_Cpu.png">
|
<Unit filename="../gui/Resources/ConfigIcon_Cpu.png">
|
||||||
<Option compile="1" />
|
<Option compile="1" />
|
||||||
<Option weight="0" />
|
<Option weight="0" />
|
||||||
|
|
|
@ -21,6 +21,9 @@
|
||||||
#include "ModalPopups.h"
|
#include "ModalPopups.h"
|
||||||
#include "Panels/ConfigurationPanels.h"
|
#include "Panels/ConfigurationPanels.h"
|
||||||
|
|
||||||
|
#include "Resources/EmbeddedImage.h"
|
||||||
|
#include "Resources/ButtonIcon_Camera.h"
|
||||||
|
|
||||||
#include <wx/artprov.h>
|
#include <wx/artprov.h>
|
||||||
#include <wx/listbook.h>
|
#include <wx/listbook.h>
|
||||||
#include <wx/listctrl.h>
|
#include <wx/listctrl.h>
|
||||||
|
@ -52,14 +55,12 @@ void Dialogs::ConfigurationDialog::AddPage( const char* label, int iconid )
|
||||||
( labelstr == g_Conf->SettingsTabName ), iconid );
|
( labelstr == g_Conf->SettingsTabName ), iconid );
|
||||||
}
|
}
|
||||||
|
|
||||||
Dialogs::ConfigurationDialog::ConfigurationDialog( wxWindow* parent, int id ) :
|
Dialogs::ConfigurationDialog::ConfigurationDialog( wxWindow* parent, int id )
|
||||||
wxDialogWithHelpers( parent, id, _("PCSX2 Configuration"), true )
|
: wxDialogWithHelpers( parent, id, _("PCSX2 Configuration"), true )
|
||||||
, m_listbook( *new wxListbook( this, wxID_ANY, wxDefaultPosition, wxDefaultSize, s_orient ) )
|
, m_listbook( *new wxListbook( this, wxID_ANY, wxDefaultPosition, wxDefaultSize, s_orient ) )
|
||||||
{
|
{
|
||||||
m_idealWidth = 600;
|
m_idealWidth = 600;
|
||||||
|
|
||||||
SetSizer( new wxBoxSizer( wxVERTICAL ) );
|
|
||||||
|
|
||||||
m_listbook.SetImageList( &wxGetApp().GetImgList_Config() );
|
m_listbook.SetImageList( &wxGetApp().GetImgList_Config() );
|
||||||
const AppImageIds::ConfigIds& cfgid( wxGetApp().GetImgId().Config );
|
const AppImageIds::ConfigIds& cfgid( wxGetApp().GetImgId().Config );
|
||||||
|
|
||||||
|
@ -73,10 +74,15 @@ Dialogs::ConfigurationDialog::ConfigurationDialog( wxWindow* parent, int id ) :
|
||||||
AddPage<PluginSelectorPanel>( wxLt("Plugins"), cfgid.Plugins );
|
AddPage<PluginSelectorPanel>( wxLt("Plugins"), cfgid.Plugins );
|
||||||
AddPage<StandardPathsPanel> ( wxLt("Folders"), cfgid.Paths );
|
AddPage<StandardPathsPanel> ( wxLt("Folders"), cfgid.Paths );
|
||||||
|
|
||||||
|
wxBitmapButton& screenshotButton( *new wxBitmapButton( this, wxID_SAVE, EmbeddedImage<res_ButtonIcon_Camera>().Get() ) );
|
||||||
|
screenshotButton.SetToolTip( _("Saves a snapshot of this settings panel to a PNG file.") );
|
||||||
|
|
||||||
|
SetSizer( new wxBoxSizer( wxVERTICAL ) );
|
||||||
*this += m_listbook;
|
*this += m_listbook;
|
||||||
AddOkCancel( *GetSizer(), true );
|
AddOkCancel( *GetSizer(), true );
|
||||||
*m_extraButtonSizer += new wxButton( this, wxID_SAVE, _("Screenshot!") );
|
|
||||||
|
*m_extraButtonSizer += screenshotButton;
|
||||||
|
|
||||||
FindWindow( wxID_APPLY )->Disable();
|
FindWindow( wxID_APPLY )->Disable();
|
||||||
|
|
||||||
Fit();
|
Fit();
|
||||||
|
@ -168,7 +174,10 @@ void Dialogs::ConfigurationDialog::OnScreenshot_Click( wxCommandEvent& evt )
|
||||||
filenameDefault, L"png", NULL, wxFD_SAVE | wxFD_OVERWRITE_PROMPT, this ) );
|
filenameDefault, L"png", NULL, wxFD_SAVE | wxFD_OVERWRITE_PROMPT, this ) );
|
||||||
|
|
||||||
if( !filename.IsEmpty() )
|
if( !filename.IsEmpty() )
|
||||||
|
{
|
||||||
|
ScopedBusyCursor busy( Cursor_ReallyBusy );
|
||||||
memBmp.SaveFile( filename, wxBITMAP_TYPE_PNG );
|
memBmp.SaveFile( filename, wxBITMAP_TYPE_PNG );
|
||||||
|
}
|
||||||
}
|
}
|
||||||
|
|
||||||
// ----------------------------------------------------------------------------
|
// ----------------------------------------------------------------------------
|
||||||
|
|
Binary file not shown.
After Width: | Height: | Size: 1.4 KiB |
|
@ -533,14 +533,6 @@
|
||||||
<File
|
<File
|
||||||
RelativePath="..\..\Counters.cpp"
|
RelativePath="..\..\Counters.cpp"
|
||||||
>
|
>
|
||||||
<FileConfiguration
|
|
||||||
Name="Release|Win32"
|
|
||||||
>
|
|
||||||
<Tool
|
|
||||||
Name="VCCLCompilerTool"
|
|
||||||
AssemblerOutput="4"
|
|
||||||
/>
|
|
||||||
</FileConfiguration>
|
|
||||||
</File>
|
</File>
|
||||||
<File
|
<File
|
||||||
RelativePath="..\..\Counters.h"
|
RelativePath="..\..\Counters.h"
|
||||||
|
@ -895,30 +887,6 @@
|
||||||
<File
|
<File
|
||||||
RelativePath="..\..\x86\iFPU.cpp"
|
RelativePath="..\..\x86\iFPU.cpp"
|
||||||
>
|
>
|
||||||
<FileConfiguration
|
|
||||||
Name="Debug|Win32"
|
|
||||||
>
|
|
||||||
<Tool
|
|
||||||
Name="VCCLCompilerTool"
|
|
||||||
AssemblerOutput="0"
|
|
||||||
/>
|
|
||||||
</FileConfiguration>
|
|
||||||
<FileConfiguration
|
|
||||||
Name="Devel|Win32"
|
|
||||||
>
|
|
||||||
<Tool
|
|
||||||
Name="VCCLCompilerTool"
|
|
||||||
AssemblerOutput="0"
|
|
||||||
/>
|
|
||||||
</FileConfiguration>
|
|
||||||
<FileConfiguration
|
|
||||||
Name="Release|Win32"
|
|
||||||
>
|
|
||||||
<Tool
|
|
||||||
Name="VCCLCompilerTool"
|
|
||||||
AssemblerOutput="0"
|
|
||||||
/>
|
|
||||||
</FileConfiguration>
|
|
||||||
</File>
|
</File>
|
||||||
<File
|
<File
|
||||||
RelativePath="..\..\x86\iFPU.h"
|
RelativePath="..\..\x86\iFPU.h"
|
||||||
|
@ -986,14 +954,6 @@
|
||||||
<File
|
<File
|
||||||
RelativePath="..\..\x86\ix86-32\iR5900-32.cpp"
|
RelativePath="..\..\x86\ix86-32\iR5900-32.cpp"
|
||||||
>
|
>
|
||||||
<FileConfiguration
|
|
||||||
Name="Devel|Win32"
|
|
||||||
>
|
|
||||||
<Tool
|
|
||||||
Name="VCCLCompilerTool"
|
|
||||||
AssemblerOutput="4"
|
|
||||||
/>
|
|
||||||
</FileConfiguration>
|
|
||||||
</File>
|
</File>
|
||||||
<File
|
<File
|
||||||
RelativePath="..\..\x86\ix86-32\iR5900Arit.cpp"
|
RelativePath="..\..\x86\ix86-32\iR5900Arit.cpp"
|
||||||
|
@ -1241,22 +1201,6 @@
|
||||||
<File
|
<File
|
||||||
RelativePath="..\..\Ipu\IPU.cpp"
|
RelativePath="..\..\Ipu\IPU.cpp"
|
||||||
>
|
>
|
||||||
<FileConfiguration
|
|
||||||
Name="Debug|Win32"
|
|
||||||
>
|
|
||||||
<Tool
|
|
||||||
Name="VCCLCompilerTool"
|
|
||||||
UsePrecompiledHeader="0"
|
|
||||||
/>
|
|
||||||
</FileConfiguration>
|
|
||||||
<FileConfiguration
|
|
||||||
Name="Devel|Win32"
|
|
||||||
>
|
|
||||||
<Tool
|
|
||||||
Name="VCCLCompilerTool"
|
|
||||||
UsePrecompiledHeader="0"
|
|
||||||
/>
|
|
||||||
</FileConfiguration>
|
|
||||||
</File>
|
</File>
|
||||||
<File
|
<File
|
||||||
RelativePath="..\..\Ipu\IPU.h"
|
RelativePath="..\..\Ipu\IPU.h"
|
||||||
|
@ -1935,7 +1879,41 @@
|
||||||
<Filter
|
<Filter
|
||||||
Name="Resources"
|
Name="Resources"
|
||||||
>
|
>
|
||||||
<File
|
<File
|
||||||
|
RelativePath="..\..\gui\Resources\ButtonIcon_Camera.png"
|
||||||
|
>
|
||||||
|
<FileConfiguration
|
||||||
|
Name="Debug|Win32"
|
||||||
|
>
|
||||||
|
<Tool
|
||||||
|
Name="VCCustomBuildTool"
|
||||||
|
Description=""
|
||||||
|
CommandLine=""$(InputDir)\bin2cpp.cmd" $(InputFileName)
"
|
||||||
|
Outputs=""$(InputDir)\$(InputName).h"
|
||||||
|
/>
|
||||||
|
</FileConfiguration>
|
||||||
|
<FileConfiguration
|
||||||
|
Name="Devel|Win32"
|
||||||
|
>
|
||||||
|
<Tool
|
||||||
|
Name="VCCustomBuildTool"
|
||||||
|
Description=""
|
||||||
|
CommandLine=""$(InputDir)\bin2cpp.cmd" $(InputFileName)
"
|
||||||
|
Outputs=""$(InputDir)\$(InputName).h"
|
||||||
|
/>
|
||||||
|
</FileConfiguration>
|
||||||
|
<FileConfiguration
|
||||||
|
Name="Release|Win32"
|
||||||
|
>
|
||||||
|
<Tool
|
||||||
|
Name="VCCustomBuildTool"
|
||||||
|
Description=""
|
||||||
|
CommandLine=""$(InputDir)\bin2cpp.cmd" $(InputFileName)
"
|
||||||
|
Outputs=""$(InputDir)\$(InputName).h"
|
||||||
|
/>
|
||||||
|
</FileConfiguration>
|
||||||
|
</File>
|
||||||
|
<File
|
||||||
RelativePath="..\..\gui\Resources\AppIcon16.png"
|
RelativePath="..\..\gui\Resources\AppIcon16.png"
|
||||||
>
|
>
|
||||||
<FileConfiguration
|
<FileConfiguration
|
||||||
|
|
Loading…
Reference in New Issue